.fun-profile-shell {
  width: min(1120px, calc(100% - 32px));
  max-width: none;
  margin: 24px auto 60px;
  padding: 0;
  color: #0f172a;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

.fun-profile-shell .calc-page-head {
  margin-bottom: 20px;
}

.fun-profile-shell .calc-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  color: #6b737c;
  font-size: 12px;
}

.fun-profile-shell .calc-breadcrumbs a {
  color: #6b737c;
  text-decoration: none;
}

.fun-profile-shell .calc-breadcrumbs a:hover,
.fun-profile-shell .calc-breadcrumbs a:focus-visible {
  color: #2f6fdf;
  text-decoration: underline;
}

.fun-profile-shell .calc-card {
  max-width: 100%;
  overflow: hidden;
  box-sizing: border-box;
  border: 1px solid rgba(20, 24, 30, 0.08);
  border-radius: 12px;
  background: #ffffff;
  padding: 20px;
  box-shadow: 0 18px 34px -30px rgba(15, 23, 42, 0.7);
}

.fun-profile-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.96fr) minmax(340px, 1.04fr);
  gap: 22px;
  align-items: start;
  background:
    radial-gradient(circle at 12% 8%, rgba(251, 191, 36, 0.18), transparent 32%),
    radial-gradient(circle at 88% 12%, rgba(59, 130, 246, 0.14), transparent 28%),
    linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
}

.fun-profile-kicker {
  margin: 0 0 8px;
  color: #b45309;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.fun-profile-hero h1 {
  margin: 0 0 12px;
  color: #101828;
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
}

.fun-profile-shell .calc-page-intro {
  margin: 0;
  max-width: 720px;
  color: #4b535d;
  font-size: 15px;
  line-height: 1.6;
}

.fun-profile-form {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid #ead7b4;
  border-radius: 18px;
  background: #fffaf0;
}

.fun-profile-validation {
  margin: 0;
  color: #b42318;
  font-size: 13px;
  font-weight: 700;
}

.fun-profile-input-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.fun-profile-input-grid label {
  display: grid;
  gap: 6px;
  color: #334155;
  font-size: 14px;
  font-weight: 700;
}

.fun-profile-input-grid input,
.fun-profile-input-grid select {
  width: 100%;
  min-height: 48px;
  box-sizing: border-box;
  border: 1px solid #d5c4a7;
  border-radius: 12px;
  background: #ffffff;
  color: #0f172a;
  font: inherit;
  font-size: 16px;
  padding: 0 14px;
}

.fun-profile-input-grid input:focus,
.fun-profile-input-grid select:focus {
  border-color: #ca8a04;
  outline: none;
  box-shadow: 0 0 0 3px rgba(202, 138, 4, 0.14);
}

.fun-profile-shell .time-date-picker {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: stretch;
  min-width: 0;
  overflow: visible;
  border: 1px solid #d5c4a7;
  border-radius: 12px;
  background: #ffffff;
}

.fun-profile-shell .time-date-picker.is-open {
  z-index: 80;
}

.fun-profile-shell .time-date-picker input[type="hidden"] {
  display: none;
}

.fun-profile-shell .time-date-picker-display {
  grid-column: 1;
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 12px 0 0 12px;
  background: transparent;
  color: #0f172a;
  font: inherit;
  font-size: 16px;
  line-height: 1;
  text-align: left;
  padding: 0 38px 0 14px;
  cursor: pointer;
  user-select: text;
  min-width: 0;
}

.fun-profile-shell .time-date-picker-display.is-empty {
  color: #9aa3af;
}

.fun-profile-shell .time-date-picker-display::placeholder {
  color: #9aa3af;
}

.fun-profile-shell .time-date-picker-display:focus {
  outline: none;
}

.fun-profile-shell .time-date-picker:focus-within {
  border-color: #ca8a04;
  box-shadow: 0 0 0 3px rgba(202, 138, 4, 0.14);
}

.fun-profile-shell .time-date-field-icon {
  position: absolute;
  right: 82px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  line-height: 1;
  color: #7c6a4d;
  pointer-events: none;
  z-index: 2;
}

.fun-profile-shell .time-date-picker.is-typing .time-date-field-icon {
  opacity: 0;
}

.fun-profile-shell .fun-profile-date-affix {
  grid-column: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  min-width: 74px;
  padding: 0 12px;
  border-left: 1px solid #d5c4a7;
  border-radius: 0 12px 12px 0;
  background: #f9f1df;
  color: #8b5e12;
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
}

.fun-profile-shell .time-date-picker-popover {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: min(360px, 100%);
  z-index: 60;
  background: #ffffff;
  border: 1px solid #d5c4a7;
  border-radius: 14px;
  box-shadow: 0 18px 34px -30px rgba(15, 23, 42, 0.7);
  padding: 12px;
}

.fun-profile-shell .time-date-picker-head {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 6px;
  margin-bottom: 12px;
}

.fun-profile-shell .time-date-picker-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 6px;
  min-width: 0;
  width: 100%;
}

.fun-profile-shell .time-date-picker-controls select {
  width: 100%;
  min-height: 32px;
  border: 1px solid #d5c4a7;
  border-radius: 8px;
  background-color: #ffffff;
  -webkit-appearance: none;
  appearance: none;
  color: #0f172a;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-overflow: ellipsis;
  padding: 0 22px 0 8px;
  min-width: 0;
  background-image:
    linear-gradient(45deg, transparent 50%, #334155 50%),
    linear-gradient(135deg, #334155 50%, transparent 50%);
  background-position: calc(100% - 10px) 13px, calc(100% - 6px) 13px;
  background-size: 4px 4px, 4px 4px;
  background-repeat: no-repeat;
}

.fun-profile-shell .time-date-picker-controls select:focus {
  outline: none;
  border-color: #ca8a04;
}

.fun-profile-shell .time-date-picker-nav {
  width: 28px;
  height: 28px;
  border: 1px solid #d5c4a7;
  border-radius: 999px;
  background: #fffaf0;
  color: #8b5e12;
  display: grid;
  place-items: center;
  padding: 0;
  cursor: pointer;
  position: relative;
  line-height: 1;
  flex-shrink: 0;
}

.fun-profile-shell .time-date-picker-nav::before {
  content: "\203A";
  font-size: 17px;
  font-weight: 700;
  color: #8b5e12;
  transform: translateY(-1px);
}

.fun-profile-shell .time-date-picker-nav[data-picker-action="prev-month"]::before {
  content: "\2039";
}

.fun-profile-shell .time-date-picker-nav:hover,
.fun-profile-shell .time-date-picker-nav:focus-visible {
  border-color: #ca8a04;
}

.fun-profile-shell .time-date-picker-weekdays {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
  margin-bottom: 12px;
}

.fun-profile-shell .time-date-picker-weekdays span {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: #64748b;
}

.fun-profile-shell .time-date-picker-days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px 4px;
}

.fun-profile-shell .time-date-picker-day {
  min-height: 30px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #0f172a;
  font-size: 13px;
  font-weight: 600;
  padding: 0;
  cursor: pointer;
}

.fun-profile-shell .time-date-picker-day:hover,
.fun-profile-shell .time-date-picker-day:focus-visible {
  border-color: #d5c4a7;
  background: #fffaf0;
}

.fun-profile-shell .time-date-picker-day.is-outside {
  color: #94a3b8;
}

.fun-profile-shell .time-date-picker-day.is-selected {
  background: #b45309;
  border-color: #b45309;
  color: #ffffff;
}

.fun-profile-shell .time-date-picker-day.is-today:not(.is-selected) {
  border-color: #ca8a04;
}

.fun-profile-shell .time-date-picker-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

.fun-profile-shell .time-date-picker-today {
  border: 0;
  background: transparent;
  color: #b45309;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.fun-profile-shell .time-date-picker-confirm {
  border: 1px solid #b45309;
  background: #b45309;
  color: #ffffff;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  padding: 8px 12px;
  cursor: pointer;
}

.fun-profile-shell .time-date-picker-confirm:disabled,
.fun-profile-shell .time-date-picker-confirm.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.fun-profile-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.fun-profile-btn {
  min-height: 42px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 0 16px;
  background: #ffffff;
  color: #0f172a;
  font: inherit;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
}

.fun-profile-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.fun-profile-btn-primary {
  border-color: #b45309;
  background: #b45309;
  color: #ffffff;
}

.fun-profile-btn-secondary:hover:not(:disabled),
.fun-profile-btn-secondary:focus-visible:not(:disabled) {
  border-color: #b45309;
}

.fun-profile-result-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.72fr);
  gap: 16px;
  margin-top: 16px;
}

.fun-profile-result-card,
.fun-profile-breakdown-card {
  display: grid;
  gap: 14px;
  align-content: start;
}

.fun-profile-result-label {
  margin: 0;
  color: #64748b;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.fun-profile-meter {
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: #f1f5f9;
  border: 1px solid #dbe5f4;
}

.fun-profile-meter-fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #f59e0b 0%, #d97706 44%, #2563eb 100%);
  transition: width 0.28s ease;
}

.fun-profile-primary {
  margin: 0;
  color: #0f172a;
  font-size: clamp(44px, 8vw, 84px);
  font-weight: 850;
  line-height: 0.98;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.fun-profile-result-card h2,
.fun-profile-breakdown-card h2 {
  margin: 0;
  color: #111827;
  font-size: 22px;
  line-height: 1.25;
}

.fun-profile-result-card p,
.fun-profile-breakdown-card p {
  margin: 0;
}

.fun-profile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fun-profile-tags span {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  border-radius: 999px;
  background: #f8edd8;
  color: #92400e;
  font-size: 13px;
  font-weight: 800;
  padding: 0 12px;
}

.fun-profile-metric-list {
  display: grid;
  gap: 10px;
}

.fun-profile-metric-list article {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #ffffff;
}

.fun-profile-metric-list span {
  color: #475569;
  font-size: 14px;
  font-weight: 700;
}

.fun-profile-metric-list strong {
  color: #0f172a;
  font-size: 14px;
  text-align: right;
}

.fun-profile-highlights {
  margin: 0;
  padding-left: 18px;
  color: #374151;
}

.fun-profile-highlights li {
  margin: 2px 0;
  font-size: 15px;
  line-height: 1.65;
  padding-bottom: 4px;
}

.fun-profile-reference {
  margin-top: 16px;
}

.fun-profile-reference h2 {
  margin: 16px 0 8px;
  color: #151a1f;
  font-size: 1.45rem;
  font-weight: 600;
  line-height: 1.3;
}

.fun-profile-reference h2:first-child {
  margin-top: 0;
}

.fun-profile-reference p {
  margin: 0;
  color: #374151;
  font-size: 15px;
  line-height: 1.65;
}

.fun-profile-reference p + p {
  margin-top: 12px;
}

.fun-profile-reference ul {
  margin: 10px 0 0;
  padding-left: 18px;
  color: #1f2937;
}

.fun-profile-reference li {
  margin: 2px 0;
  color: #374151;
  font-size: 15px;
  line-height: 1.65;
  padding-bottom: 4px;
}

.fun-profile-reference a {
  color: #0f172a;
  font-weight: 500;
  text-decoration: none;
}

.fun-profile-reference a:hover,
.fun-profile-reference a:focus-visible {
  color: #1f5cc9;
  text-decoration: none;
}

.fun-profile-reference .calc-faq {
  display: grid;
  gap: 10px;
}

.fun-profile-reference .calc-faq-item {
  border: 1px solid #d4d9e1;
  border-radius: 12px;
  background: #ffffff;
  overflow: hidden;
}

.fun-profile-reference .calc-faq-item summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
  color: #0f172a;
  font-size: 18px;
  font-weight: 600;
}

.fun-profile-reference .calc-faq-item summary::-webkit-details-marker {
  display: none;
}

.fun-profile-reference .calc-faq-item > p {
  margin: 0;
  padding: 0 14px 14px;
}

@media (max-width: 860px) {
  .fun-profile-hero,
  .fun-profile-result-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .fun-profile-shell {
    width: calc(100% - 20px);
    margin-top: 20px;
    margin-bottom: 42px;
  }

  .fun-profile-input-grid {
    grid-template-columns: 1fr;
  }

  .fun-profile-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
}
