:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #18302f;
  background: #f6f4ed;
  font-synthesis: none;
}

* { box-sizing: border-box; }
body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  background-color: #f8f5ed;
  background-image: linear-gradient(#fffdf81f, #fffdf81f), url("site-background.webp");
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; max-width: 1220px; margin: auto; padding: 22px 28px; }
.brand { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.brand > span:last-child { display: grid; gap: 1px; }
.brand small { color: #697a75; font-size: .7rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.brand strong { font-size: 1rem; }
.exit-button { border: 1px solid #c8d7d2; background: #fffaf2; color: #18302f; border-radius: 999px; padding: 10px 16px; font-weight: 800; cursor: pointer; }
main { width: min(1164px, calc(100% - 40px)); min-height: calc(100vh - 154px); margin: 34px auto 52px; }
.welcome { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(340px, .85fr); gap: 56px; align-items: center; }
.hero-copy { padding: 24px 0; }
.eyebrow { margin: 0 0 12px; color: #0f766e; font-weight: 900; text-transform: uppercase; letter-spacing: .1em; font-size: .74rem; }
h1, h2, p { text-wrap: pretty; }
h1 { max-width: 760px; margin: 0; font-size: clamp(2.8rem, 6.2vw, 5.7rem); line-height: .98; letter-spacing: -.065em; }
h2 { margin: 0; font-size: clamp(1.45rem, 3vw, 2rem); letter-spacing: -.035em; }
.lead { max-width: 690px; margin: 26px 0; color: #52645f; font-size: clamp(1.06rem, 2vw, 1.28rem); line-height: 1.65; }
.facts { display: flex; flex-wrap: wrap; gap: 12px; }
.facts span { min-width: 122px; padding: 13px 16px; border: 1px solid #d6ddd8; border-radius: 15px; background: #ffffff80; color: #5b6d68; }
.facts strong { color: #18302f; font-size: 1.15rem; }
.start-card { overflow: hidden; border: 1px solid #d9ded9; border-radius: 28px; background: #fffdf8; box-shadow: 0 28px 80px #173b2e14; }
.start-card-top { padding: 30px 32px 22px; background: #ddefe7; }
.start-card-top p:last-child { margin: 12px 0 0; color: #536963; line-height: 1.55; }
form { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; padding: 28px 32px 8px; }
label { display: grid; gap: 7px; color: #455953; font-size: .84rem; font-weight: 800; }
label:nth-child(3), form .primary { grid-column: 1 / -1; }
input { width: 100%; min-height: 48px; border: 1px solid #cbd7d2; border-radius: 13px; background: white; padding: 11px 13px; outline: none; }
input:focus { border-color: #0f766e; box-shadow: 0 0 0 4px #0f766e18; }
.primary { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 52px; border: 0; border-radius: 14px; background: #0f766e; color: white; padding: 12px 18px; font-weight: 900; cursor: pointer; box-shadow: 0 12px 28px #0f766e25; }
.primary:hover { background: #0b625c; transform: translateY(-1px); }
.privacy { margin: 10px 32px 26px; color: #7b8a85; font-size: .78rem; text-align: center; }
.roles-preview { grid-column: 1 / -1; padding-top: 10px; border-top: 1px solid #d8ded9; }
.roles-preview > p { margin: 0 0 13px; color: #7a8783; font-size: .82rem; font-weight: 800; }
.roles-preview > div { display: flex; flex-wrap: wrap; gap: 8px; }
.roles-preview span { padding: 7px 11px; border-radius: 999px; background: #e9ece7; color: #42534f; font-size: .8rem; font-weight: 800; }
.roles-preview .other-pill { background: #f3e2c7; color: #80531a; }
.quiz-shell, .result-shell { max-width: 1040px; margin: auto; padding: clamp(24px, 5vw, 52px); border: 1px solid #d8ded9; border-radius: 30px; background: #fffdf8ed; backdrop-filter: blur(14px); box-shadow: 0 28px 80px #173b2e14; }
.quiz-topline { display: flex; align-items: start; justify-content: space-between; gap: 20px; }
.quiz-topline h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
.quiz-topline > strong { white-space: nowrap; padding: 8px 12px; border-radius: 999px; background: #ddefe7; color: #0b625c; }
.progress { height: 7px; margin: 24px 0 34px; overflow: hidden; border-radius: 99px; background: #e7e7df; }
.progress span { display: block; width: 3%; height: 100%; border-radius: inherit; background: #0f766e; transition: width .3s ease; }
.message { min-height: 24px; color: #0f766e; font-weight: 800; }
.result-shell > .primary { margin: 28px auto 0; }
footer { display: flex; justify-content: space-between; gap: 24px; max-width: 1220px; margin: auto; padding: 22px 28px 30px; color: #7a8783; font-size: .78rem; }
[hidden] { display: none !important; }

.question-card { display: grid; grid-template-columns: minmax(260px, .88fr) minmax(360px, 1.12fr); gap: clamp(24px, 4vw, 44px); align-items: start; }
.question-image { position: sticky; top: 18px; overflow: hidden; margin: 0; min-height: 440px; border-radius: 24px; background: #ddefe7; }
.question-image img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.question-image::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 52%, #102f2bb8); }
.question-image figcaption { position: absolute; z-index: 1; left: 18px; right: 18px; bottom: 18px; color: white; font-size: .78rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.question-body h2 { margin: 0 0 25px; font-size: clamp(1.55rem, 3.4vw, 2.35rem); line-height: 1.16; letter-spacing: -.035em; }
.answers { display: grid; gap: 9px; }
.answer { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 54px; border: 1px solid #d5ddd8; border-radius: 15px; background: #fff; color: #334b46; padding: 10px 14px; text-align: left; font-weight: 800; cursor: pointer; transition: border-color .15s, background .15s, transform .15s; }
.answer:hover, .answer:focus-visible { border-color: #0f766e; background: #eef9f5; transform: translateX(3px); outline: none; }
.answer.selected { border-color: #0f766e; background: #ddefe7; }
.answer-dot { flex: 0 0 auto; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: #edf1ee; color: #536963; }
.answer.selected .answer-dot { background: #0f766e; color: white; }
.question-nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 18px; color: #8a9691; font-size: .76rem; }
.back-button, .secondary-button, .print-button { border: 1px solid #cad7d2; border-radius: 13px; background: white; color: #27423d; padding: 10px 14px; font-weight: 900; cursor: pointer; }
.back-button:disabled { opacity: .35; cursor: default; }

.result-shell { max-width: 1100px; }
.result-hero { position: relative; overflow: hidden; min-height: 410px; border-radius: 26px; background: #153f3a; color: white; isolation: isolate; }
.result-hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background-image: var(--result-image); background-size: cover; background-position: center; }
.result-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, #102f2ff2 0%, #102f2fd9 48%, #102f2f35 100%); }
.result-copy { width: min(690px, 100%); padding: clamp(28px, 5vw, 54px); }
.result-hero .eyebrow { color: #9fe4d2; }
.result-title-row { display: flex; align-items: start; gap: 18px; }
.result-icon { flex: 0 0 auto; display: grid; place-items: center; min-width: 58px; height: 58px; border-radius: 18px; background: var(--accent); color: white; font-weight: 900; }
.result-hero h1 { max-width: 670px; font-size: clamp(2rem, 5vw, 4.2rem); letter-spacing: -.055em; }
.result-lead { margin: 18px 0; color: #eef8f5; font-size: 1.05rem; line-height: 1.6; }
.result-note { max-width: 610px; margin-top: 22px; padding: 13px 15px; border: 1px solid #ffffff2f; border-radius: 13px; background: #ffffff12; color: #d8ebe6; font-size: .8rem; line-height: 1.5; }
.recommendation-card, .score-section, .outside-section { margin-top: 22px; padding: clamp(22px, 4vw, 34px); border: 1px solid #dbe2dd; border-radius: 23px; background: white; }
.recommendation-card { background: linear-gradient(135deg, #ddefe7, #f7fcfa); }
.recommendation-card.warm { background: linear-gradient(135deg, #f5e2c7, #fff9ef); }
.recommendation-card p { max-width: 780px; color: #546762; line-height: 1.65; }
.section-label { margin: 0 0 8px; color: #0f766e; font-size: .72rem; font-weight: 900; letter-spacing: .09em; text-transform: uppercase; }
.skill-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.skill-chips span { padding: 8px 11px; border-radius: 999px; background: white; color: #35554e; font-size: .8rem; font-weight: 900; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.section-heading > span { color: #7b8a85; font-size: .8rem; }
.score-list { display: grid; gap: 10px; }
.score-row { display: grid; grid-template-columns: minmax(240px, .8fr) minmax(260px, 1.2fr); gap: 24px; align-items: center; padding: 12px; border-radius: 16px; }
.score-row.top-score { background: #f0f8f5; }
.score-meta, .score-value { display: flex; align-items: center; gap: 12px; }
.score-meta > div { display: grid; gap: 3px; }
.score-meta small { color: #84918d; }
.mini-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; background: color-mix(in srgb, var(--accent) 16%, white); color: var(--accent); font-weight: 900; }
.score-value { display: grid; grid-template-columns: 1fr 52px; }
.score-value > strong { text-align: right; }
.bar { overflow: hidden; height: 10px; border-radius: 99px; background: #ecefe9; }
.bar span { display: block; height: 100%; border-radius: inherit; background: var(--accent); }
.outside-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.outside-grid article { position: relative; overflow: hidden; min-height: 190px; padding: 16px; border-radius: 18px; background-image: linear-gradient(180deg, #15352f12 25%, #15352fee 90%), var(--tile-image); background-size: cover; background-position: center; color: white; }
.outside-grid article > span { display: inline-block; padding: 5px 8px; border-radius: 999px; background: #fff; color: #173832; font-size: .75rem; font-weight: 900; }
.outside-grid h3 { margin: 62px 0 6px; font-size: .95rem; line-height: 1.15; }
.outside-grid p { margin: 0; color: #dfece8; font-size: .7rem; line-height: 1.35; }
.result-actions { display: flex; justify-content: center; gap: 10px; margin: 24px 0 4px; }
.print-button { background: #183f39; color: white; border-color: #183f39; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; } }
@media (max-width: 820px) {
  main { margin-top: 6px; }
  .welcome { grid-template-columns: 1fr; gap: 28px; }
  .hero-copy { padding-bottom: 0; }
  .roles-preview { order: 3; }
  .question-card { grid-template-columns: 1fr; }
  .question-image { position: relative; min-height: 280px; }
  .outside-grid { grid-template-columns: repeat(2, 1fr); }
  .score-row { grid-template-columns: 1fr; gap: 10px; }
}
@media (max-width: 520px) {
  .topbar { padding: 16px 18px; }
  .brand small { display: none; }
  main { width: min(100% - 24px, 1164px); }
  h1 { font-size: clamp(2.45rem, 14vw, 4rem); }
  .facts { display: grid; grid-template-columns: 1fr 1fr; }
  .facts span:last-child { grid-column: 1 / -1; }
  .start-card-top, form { padding-left: 22px; padding-right: 22px; }
  form { grid-template-columns: 1fr; }
  label:nth-child(3), form .primary { grid-column: auto; }
  .privacy { margin-left: 22px; margin-right: 22px; }
  footer { display: grid; padding: 18px; }
  .quiz-shell, .result-shell { padding: 18px; border-radius: 22px; }
  .question-image { min-height: 220px; border-radius: 18px; }
  .question-nav span { display: none; }
  .section-heading { align-items: start; display: grid; }
  .outside-grid { grid-template-columns: 1fr; }
  .outside-grid article { min-height: 210px; }
  .result-title-row { display: grid; }
  .result-actions { display: grid; }
}

@media print {
  body { background: white; }
  .topbar, footer, .result-actions, #returnButton { display: none !important; }
  main { width: 100%; margin: 0; }
  .result-shell { border: 0; box-shadow: none; padding: 0; }
  .result-hero { min-height: 0; print-color-adjust: exact; }
  .outside-grid { grid-template-columns: repeat(3, 1fr); }
}
