:root {
  color-scheme: light;
  --ink: #173936;
  --ink-soft: #49605d;
  --paper: #f4f0e8;
  --paper-light: #fbfaf6;
  --card: #fffdf8;
  --coral: #ef6b4d;
  --coral-dark: #d9573d;
  --mint: #bad8c7;
  --mint-dark: #5f9a7f;
  --line: rgba(23, 57, 54, 0.15);
  --shadow: 0 24px 70px rgba(43, 54, 47, 0.12);
  --radius-lg: 32px;
  --radius-md: 22px;
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  background:
    radial-gradient(circle at 83% 8%, rgba(186, 216, 199, 0.62), transparent 25rem),
    linear-gradient(180deg, #f7f3ec 0%, var(--paper) 100%);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

button,
input {
  font: inherit;
}

button {
  -webkit-tap-highlight-color: transparent;
}

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  color: white;
  background: var(--ink);
  border-radius: 10px;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header,
.site-footer,
.screen {
  width: min(calc(100% - 40px), var(--max-width));
  margin-inline: auto;
}

.site-header {
  min-height: 110px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 13px;
  color: var(--ink);
  font-size: 0.78rem;
  line-height: 1.08;
  letter-spacing: 0.025em;
  text-decoration: none;
}

.brand strong {
  font-size: 0.88rem;
}

.brand-mark {
  position: relative;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(23, 57, 54, 0.2);
  border-radius: 50%;
}

.brand-mark span {
  position: absolute;
  width: 4px;
  border-radius: 4px;
  background: var(--coral);
  transform-origin: 50% 14px;
}

.brand-mark span:nth-child(1) { height: 19px; transform: rotate(-48deg) translateY(-2px); }
.brand-mark span:nth-child(2) { height: 24px; transform: rotate(0deg) translateY(-3px); }
.brand-mark span:nth-child(3) { height: 17px; transform: rotate(48deg) translateY(-1px); }

.privacy-note {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.privacy-note i {
  width: 8px;
  height: 8px;
  background: var(--mint-dark);
  border-radius: 50%;
  box-shadow: 0 0 0 5px rgba(95, 154, 127, 0.13);
}

.screen {
  display: none;
  min-height: calc(100vh - 220px);
}

.screen.is-active {
  display: grid;
  animation: screen-in 450ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
}

@keyframes screen-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.intro-screen {
  grid-template-columns: minmax(0, 1.2fr) minmax(360px, 0.8fr);
  align-items: center;
  gap: clamp(40px, 8vw, 100px);
  padding: 40px 0 90px;
}

.eyebrow,
.panel-label,
.dimension-label {
  margin: 0 0 18px;
  color: var(--coral-dark);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.19em;
}

h1,
h2,
p {
  margin-top: 0;
}

h1,
h2 {
  text-wrap: balance;
}

h1 {
  margin-bottom: 28px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3.25rem, 7vw, 6.75rem);
  font-weight: 400;
  line-height: 0.94;
  letter-spacing: -0.055em;
}

h1 em,
.section-title h2 em {
  color: var(--coral);
  font-weight: 400;
}

.lead {
  max-width: 650px;
  margin-bottom: 34px;
  color: var(--ink-soft);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.75;
}

.button {
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 750;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, opacity 180ms ease;
}

.button:not(:disabled):hover {
  transform: translateY(-2px);
}

.button:focus-visible,
.text-button:focus-visible,
.answer-option:focus-within {
  outline: 3px solid rgba(239, 107, 77, 0.3);
  outline-offset: 3px;
}

.button-primary {
  color: white;
  background: var(--coral);
  box-shadow: 0 12px 30px rgba(239, 107, 77, 0.24);
}

.button-primary:not(:disabled):hover {
  background: var(--coral-dark);
  box-shadow: 0 16px 38px rgba(239, 107, 77, 0.3);
}

.button-secondary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.5);
  border-color: var(--line);
}

.button:disabled {
  opacity: 0.38;
  cursor: not-allowed;
  box-shadow: none;
}

.microcopy {
  margin: 18px 0 0;
  color: #74817e;
  font-size: 0.76rem;
}

.microcopy span {
  margin-inline: 7px;
  color: var(--coral);
}

.topic-orbit {
  position: relative;
  width: min(100%, 460px);
  aspect-ratio: 1;
  margin-inline: auto;
  border: 1px solid rgba(23, 57, 54, 0.13);
  border-radius: 50%;
}

.topic-orbit::before,
.topic-orbit::after {
  content: "";
  position: absolute;
  inset: 14%;
  border: 1px dashed rgba(23, 57, 54, 0.13);
  border-radius: 50%;
}

.topic-orbit::after {
  inset: 32%;
  border-style: solid;
}

.orbit-center {
  position: absolute;
  z-index: 2;
  inset: 50% auto auto 50%;
  width: 132px;
  height: 132px;
  display: grid;
  place-content: center;
  text-align: center;
  background: var(--ink);
  color: white;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 20px 44px rgba(23, 57, 54, 0.23);
}

.orbit-center span {
  font-family: Georgia, serif;
  font-size: 3.4rem;
  line-height: 0.8;
}

.orbit-center small {
  margin-top: 9px;
  color: #d9e8df;
  font-size: 0.7rem;
  letter-spacing: 0.07em;
  line-height: 1.25;
  text-transform: uppercase;
}

.topic {
  position: absolute;
  z-index: 3;
  padding: 9px 14px;
  background: rgba(255, 253, 248, 0.92);
  border: 1px solid rgba(23, 57, 54, 0.12);
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(43, 54, 47, 0.08);
  font-size: 0.76rem;
  font-weight: 750;
}

.topic::before {
  content: "";
  width: 6px;
  height: 6px;
  display: inline-block;
  margin-right: 7px;
  background: var(--coral);
  border-radius: 50%;
  vertical-align: 1px;
}

.topic-1 { top: 1%; left: 50%; transform: translateX(-50%); }
.topic-2 { top: 24%; right: -5%; }
.topic-3 { right: 3%; bottom: 14%; }
.topic-4 { bottom: 0; left: 50%; transform: translateX(-50%); }
.topic-5 { bottom: 17%; left: -3%; }
.topic-6 { top: 24%; left: -7%; }

.quiz-screen {
  grid-template-rows: auto auto 1fr auto;
  width: min(calc(100% - 40px), 900px);
  padding: 26px 0 80px;
}

.quiz-topbar,
.quiz-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.text-button {
  padding: 8px 0;
  color: var(--ink-soft);
  background: transparent;
  border: 0;
  font-size: 0.85rem;
  cursor: pointer;
}

.question-count {
  margin: 0;
  color: #7a8985;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.question-count span {
  color: var(--ink);
}

.progress-track {
  width: 100%;
  height: 4px;
  margin-top: 14px;
  overflow: hidden;
  background: rgba(23, 57, 54, 0.1);
  border-radius: 99px;
}

.progress-track span {
  width: 5.56%;
  height: 100%;
  display: block;
  background: var(--coral);
  border-radius: inherit;
  transition: width 300ms ease;
}

.question-card {
  align-self: center;
  width: min(100%, 760px);
  margin: 46px auto;
  padding: clamp(28px, 5vw, 54px);
  background: rgba(255, 253, 248, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.question-card h2 {
  max-width: 660px;
  margin-bottom: 32px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.75rem, 4vw, 2.7rem);
  font-weight: 400;
  line-height: 1.16;
  letter-spacing: -0.025em;
}

.question-card h2:focus {
  outline: none;
}

.answers {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  border: 0;
}

.answer-option {
  position: relative;
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.58);
  cursor: pointer;
  transition: border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.answer-option:hover {
  transform: translateY(-1px);
  border-color: rgba(239, 107, 77, 0.55);
}

.answer-option.is-selected {
  border-color: var(--coral);
  background: rgba(239, 107, 77, 0.08);
}

.answer-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.answer-key {
  width: 27px;
  height: 27px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: var(--ink-soft);
  border: 1px solid rgba(23, 57, 54, 0.2);
  border-radius: 8px;
  font-size: 0.72rem;
  font-weight: 800;
}

.answer-option.is-selected .answer-key {
  color: white;
  background: var(--coral);
  border-color: var(--coral);
}

.answer-text {
  font-size: 0.93rem;
  font-weight: 700;
}

.answer-hint {
  margin: 18px 0 0;
  color: #7a8985;
  font-size: 0.78rem;
  text-align: center;
}

.quiz-actions .button {
  min-width: 146px;
}

.results-screen {
  padding: 30px 0 90px;
}

.results-screen.is-active {
  display: block;
}

.results-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 44px;
}

.results-heading h1 {
  margin: 0;
  font-size: clamp(2.8rem, 6vw, 5.6rem);
}

.result-overview {
  display: grid;
  grid-template-columns: 0.82fr 1.45fr;
  gap: 20px;
}

.profile-panel,
.chart-panel {
  background: rgba(255, 253, 248, 0.82);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}

.profile-panel {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: clamp(28px, 4vw, 44px);
}

.score-ring {
  --score: 0;
  position: relative;
  width: 170px;
  height: 170px;
  display: grid;
  place-items: center;
  margin-bottom: 40px;
  background: conic-gradient(var(--coral) calc(var(--score) * 1%), rgba(23, 57, 54, 0.1) 0);
  border-radius: 50%;
  transform: rotate(-90deg);
}

.score-ring::before {
  content: "";
  position: absolute;
  width: 136px;
  height: 136px;
  background: var(--card);
  border-radius: 50%;
}

.score-ring div {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: baseline;
  transform: rotate(90deg);
}

.score-ring strong {
  font-family: Georgia, serif;
  font-size: 3.6rem;
  font-weight: 400;
  line-height: 1;
}

.score-ring span {
  color: var(--ink-soft);
  font-size: 0.78rem;
}

.profile-copy .panel-label,
.panel-heading .panel-label {
  margin-bottom: 10px;
}

.profile-copy h2,
.panel-heading h2,
.section-title h2 {
  margin-bottom: 12px;
  font-family: Georgia, serif;
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 400;
  line-height: 1.12;
}

.profile-copy > p:not(.panel-label) {
  color: var(--ink-soft);
  font-size: 0.94rem;
}

.profile-copy .scale-note {
  margin: 25px 0 0;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 0.76rem !important;
}

.chart-panel {
  padding: clamp(28px, 4vw, 42px);
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.legend {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-soft);
  font-size: 0.72rem;
  white-space: nowrap;
}

.legend i {
  width: 9px;
  height: 9px;
  background: var(--coral);
  border-radius: 50%;
}

.visual-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.95fr) minmax(240px, 1.05fr);
  align-items: center;
  gap: 22px;
  margin-top: 14px;
}

.radar-wrap {
  min-width: 0;
}

#radar-chart {
  width: 100%;
  height: auto;
  overflow: visible;
}

.radar-grid polygon,
.radar-grid line {
  fill: none;
  stroke: rgba(23, 57, 54, 0.12);
  stroke-width: 1;
}

.radar-shape {
  fill: rgba(239, 107, 77, 0.24);
  stroke: var(--coral);
  stroke-width: 2.4;
  stroke-linejoin: round;
  transition: points 450ms ease;
}

.radar-dots circle {
  fill: var(--paper-light);
  stroke: var(--coral);
  stroke-width: 2;
}

.radar-labels text {
  fill: var(--ink-soft);
  font-size: 10px;
  font-weight: 700;
  text-anchor: middle;
}

.radar-labels text:nth-child(2),
.radar-labels text:nth-child(3) { text-anchor: start; }
.radar-labels text:nth-child(5),
.radar-labels text:nth-child(6) { text-anchor: end; }

.dimension-row + .dimension-row {
  margin-top: 16px;
}

.dimension-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 6px;
  font-size: 0.78rem;
}

.dimension-meta strong {
  font-size: 0.8rem;
}

.dimension-meta span {
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}

.bar-track {
  height: 7px;
  overflow: hidden;
  background: rgba(23, 57, 54, 0.09);
  border-radius: 99px;
}

.bar-track i {
  width: 0;
  height: 100%;
  display: block;
  background: linear-gradient(90deg, var(--mint-dark), var(--coral));
  border-radius: inherit;
  transition: width 750ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.priority-section {
  padding: clamp(70px, 9vw, 110px) 0 40px;
}

.section-title {
  max-width: 650px;
  margin-bottom: 34px;
}

.section-title h2 {
  margin-bottom: 14px;
  font-size: clamp(2rem, 4vw, 3.25rem);
}

.section-title > p:last-child {
  color: var(--ink-soft);
}

.priority-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.priority-card {
  position: relative;
  min-height: 270px;
  padding: 28px;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.priority-card::after {
  content: attr(data-rank);
  position: absolute;
  right: -2px;
  bottom: -34px;
  color: rgba(23, 57, 54, 0.045);
  font-family: Georgia, serif;
  font-size: 9.5rem;
  line-height: 1;
}

.priority-index {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 28px;
  color: white;
  background: var(--coral);
  border-radius: 50%;
  font-size: 0.72rem;
  font-weight: 800;
}

.priority-card h3 {
  margin: 0 0 10px;
  font-family: Georgia, serif;
  font-size: 1.45rem;
  font-weight: 400;
}

.priority-card p {
  position: relative;
  z-index: 2;
  margin-bottom: 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
  line-height: 1.65;
}

.priority-card .action-label {
  display: block;
  margin-bottom: 5px;
  color: var(--mint-dark);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.12em;
}

.disclaimer {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-top: 38px;
  padding: 24px 26px;
  color: var(--ink);
  background: rgba(186, 216, 199, 0.26);
  border: 1px solid rgba(95, 154, 127, 0.25);
  border-radius: 18px;
}

.disclaimer > span {
  width: 27px;
  height: 27px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  color: white;
  background: var(--mint-dark);
  border-radius: 50%;
  font-family: Georgia, serif;
  font-weight: 700;
}

.disclaimer p {
  margin: 4px 0 0;
  color: var(--ink-soft);
  font-size: 0.84rem;
  line-height: 1.6;
}

.result-footer-actions {
  display: flex;
  justify-content: center;
  padding-top: 36px;
}

.site-footer {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 40px;
  padding: 34px 0 42px;
  color: #72807d;
  border-top: 1px solid var(--line);
  font-size: 0.72rem;
}

.site-footer p {
  max-width: 720px;
  margin: 0;
}

.site-footer p:last-child {
  flex: 0 0 auto;
}

.toast {
  position: fixed;
  z-index: 20;
  right: 22px;
  bottom: 22px;
  max-width: 340px;
  padding: 13px 17px;
  color: white;
  background: var(--ink);
  border-radius: 12px;
  box-shadow: var(--shadow);
  font-size: 0.82rem;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 200ms ease, transform 200ms ease;
}

.toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 900px) {
  .intro-screen {
    grid-template-columns: 1fr;
    padding-top: 30px;
  }

  .intro-copy {
    max-width: 720px;
  }

  .topic-orbit {
    width: min(86vw, 460px);
    margin-top: 20px;
  }

  .result-overview {
    grid-template-columns: 1fr;
  }

  .profile-panel {
    flex-direction: row;
    align-items: center;
    gap: 34px;
  }

  .score-ring {
    flex: 0 0 auto;
    margin-bottom: 0;
  }

  .priority-grid {
    grid-template-columns: 1fr;
  }

  .priority-card {
    min-height: 0;
  }
}

@media (max-width: 680px) {
  .site-header,
  .site-footer,
  .screen {
    width: min(calc(100% - 28px), var(--max-width));
  }

  .site-header {
    min-height: 86px;
  }

  .privacy-note {
    font-size: 0;
  }

  .intro-screen {
    min-height: auto;
    padding: 46px 0 80px;
  }

  h1 {
    font-size: clamp(3rem, 14vw, 4.6rem);
  }

  .topic-orbit {
    width: min(83vw, 380px);
  }

  .orbit-center {
    width: 112px;
    height: 112px;
  }

  .topic {
    padding: 7px 10px;
    font-size: 0.67rem;
  }

  .topic-2 { right: -3%; }
  .topic-5 { left: -2%; }
  .topic-6 { left: -4%; }

  .quiz-screen {
    min-height: calc(100vh - 130px);
    padding: 12px 0 42px;
  }

  .question-card {
    margin-block: 30px;
    padding: 28px 20px;
    border-radius: 24px;
  }

  .answers {
    grid-template-columns: 1fr;
  }

  .answer-option {
    min-height: 56px;
  }

  .quiz-actions .button {
    min-width: 0;
    padding-inline: 18px;
  }

  .results-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .results-heading .restart-button {
    display: none;
  }

  .profile-panel {
    flex-direction: column;
    align-items: flex-start;
  }

  .score-ring {
    width: 148px;
    height: 148px;
  }

  .score-ring::before {
    width: 118px;
    height: 118px;
  }

  .visual-grid {
    grid-template-columns: 1fr;
  }

  .radar-wrap {
    width: min(100%, 360px);
    margin-inline: auto;
  }

  .panel-heading {
    flex-direction: column;
  }

  .priority-section {
    padding-top: 70px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
