:root {
  --ink: #0a1526;
  --muted: #526076;
  --blue: #244eef;
  --blue-dark: #1736b3;
  --paper: #f7f6f2;
  --white: #fff;
  --line: rgba(10,21,38,.14);
  --error: #b23030;
  --display: "Schibsted Grotesk", system-ui, sans-serif;
  --body: "Instrument Sans", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); -webkit-font-smoothing: antialiased; }
button, input, textarea { font: inherit; }
button, label { -webkit-tap-highlight-color: transparent; }
button { font-family: "Schibsted Grotesk", system-ui, sans-serif; font-weight: 600; }
.honeypot-field { position: absolute; overflow: hidden; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
:focus-visible { outline: 3px solid #ffbd59; outline-offset: 3px; }

.audit-header { position: fixed; inset: 0 0 auto; z-index: 20; display: flex; height: 74px; align-items: center; padding: 0 clamp(1.25rem,4vw,4rem); background: rgba(247,246,242,.9); border-bottom: 1px solid var(--line); backdrop-filter: blur(16px); }
.audit-brand { display: inline-flex; min-height: 44px; margin-right: auto; align-items: center; color: var(--ink); text-decoration: none; }
.brand-mark { display: block; width: 116px; height: auto; }
.audit-trust { display: flex; align-items: center; gap: .6rem; color: var(--muted); font-size: .8rem; }
.audit-trust span { width: .5rem; height: .5rem; border-radius: 50%; background: #36b978; box-shadow: 0 0 0 4px rgba(54,185,120,.13); }
.close-audit { display: grid; width: 42px; height: 42px; margin-left: 1.5rem; place-items: center; border: 1px solid var(--line); border-radius: 5px; color: var(--ink); font-size: 1.5rem; text-decoration: none; }

.audit-layout { min-height: 100vh; padding-top: 74px; display: grid; grid-template-columns: minmax(340px, 37vw) 1fr; }
.audit-aside { position: sticky; top: 74px; display: flex; height: calc(100vh - 74px); padding: clamp(2.5rem,5vw,5rem); flex-direction: column; overflow: hidden; background: var(--ink); color: var(--white); }
.audit-aside::after { content: none; }
.aside-kicker, .step-kicker { margin: 0 0 1.1rem; color: #7189ff; font-size: .75rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.audit-aside h1 { max-width: 12ch; margin: 0 0 1.5rem; font-family: var(--display); font-size: clamp(2.2rem,4vw,4rem); font-weight: 500; letter-spacing: -.05em; line-height: .98; }
.audit-aside > div > p:last-child { max-width: 36ch; color: #aeb9c9; line-height: 1.55; }
.progress-steps { position: relative; z-index: 1; margin: auto 0; padding: 0; list-style: none; }
.progress-steps li { display: flex; gap: 1rem; padding: .85rem 0; border-bottom: 1px solid rgba(255,255,255,.13); color: #778398; font-size: .9rem; transition: color .2s ease; }
.progress-steps li span { color: #52617a; font-size: .72rem; }
.progress-steps li.is-current { color: var(--white); }
.progress-steps li.is-current span, .progress-steps li.is-complete span { color: #7890ff; }
.progress-steps li.is-complete { color: #aeb9c9; }
.aside-note { position: relative; z-index: 1; margin: 0; color: #7f8ba0; font-size: .75rem; }

.form-panel { display: grid; min-width: 0; padding: clamp(2rem,6vw,6rem); place-items: center; background: var(--paper); }
#audit-form { width: min(100%, 760px); }
.form-step { display: none; animation: step-in .38s ease both; }
.form-step.is-active { display: block; }
.form-step h2 { max-width: 16ch; margin: 0 0 1rem; font-family: var(--display); font-size: clamp(2.35rem,5vw,4.8rem); font-weight: 500; letter-spacing: -.055em; line-height: .98; }
.step-lead { max-width: 55ch; margin-bottom: 2rem; color: var(--muted); font-size: 1.05rem; line-height: 1.55; }
.welcome-step h2 { max-width: 14ch; }
.promise-list { display: flex; flex-wrap: wrap; gap: .55rem; margin: 2.4rem 0 3rem; }
.promise-list span { padding: .48rem .8rem; border: 1px solid rgba(36,78,239,.2); border-radius: 3px; background: rgba(36,78,239,.055); color: var(--blue-dark); font-size: .78rem; }
.mobile-progress { display: none; }

.field-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; margin-top: 2.4rem; }
.field { display: flex; flex-direction: column; gap: .55rem; }
.field.full { grid-column: 1 / -1; }
.field > span, legend { color: var(--ink); font-weight: 600; }
.field em { color: #7c8799; font-size: .75rem; font-style: normal; font-weight: 400; }
.field input, .field textarea { width: 100%; padding: 1rem 1.05rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(255,255,255,.78); color: var(--ink); outline: 0; transition: border-color .2s, box-shadow .2s, background .2s; }
.field input:focus, .field textarea:focus { border-color: var(--blue); background: var(--white); box-shadow: 0 0 0 4px rgba(36,78,239,.09); }
.field textarea { resize: vertical; }
.field small { display: none; color: var(--error); }
.field.is-invalid input { border-color: var(--error); }
.field.is-invalid small { display: block; }
.form-privacy-note { margin: 1rem 0 0; color: var(--muted); font-size: .78rem; line-height: 1.5; }
.form-privacy-note a { color: var(--blue-dark); }

.choice-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .7rem; margin-top: 2.2rem; }
.choice input, .inline-choices input, .outcome-choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice > span { display: flex; min-height: 84px; align-items: center; gap: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(255,255,255,.65); cursor: pointer; transition: border-color .2s, background .2s; }
.choice i { color: var(--blue); font-size: .7rem; font-style: normal; }
.choice:hover > span { border-color: rgba(36,78,239,.45); }
.choice input:checked + span { border-color: var(--blue); background: rgba(36,78,239,.08); box-shadow: 0 0 0 1px var(--blue); }
.choice input:focus-visible + span, .inline-choices input:focus-visible + span, .outcome-choice input:focus-visible + span { outline: 3px solid #ffbd59; outline-offset: 3px; }
.choice-error { display: none; margin: .8rem 0 0; color: var(--error); font-size: .85rem; }
.choice-error.is-visible { display: block; }

.question-block { margin: 1.8rem 0; }
fieldset { margin: 0; padding: 0; border: 0; }
legend { margin-bottom: .8rem; }
.inline-choices { display: flex; flex-wrap: wrap; gap: .55rem; }
.inline-choices label span { display: block; padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(255,255,255,.72); cursor: pointer; }
.inline-choices input:checked + span { border-color: var(--blue); background: var(--blue); color: var(--white); }

.outcome-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1rem; margin-top: 2.2rem; }
.outcome-card { display: flex; min-height: 300px; padding: 1.5rem; flex-direction: column; border: 1px solid var(--line); border-radius: 5px; background: rgba(255,255,255,.74); cursor: pointer; transition: border-color .2s, box-shadow .2s; }
.outcome-card > i { display: grid; width: 44px; height: 44px; margin-bottom: auto; place-items: center; border-radius: 5px; background: rgba(36,78,239,.08); color: var(--blue); font-size: 1.3rem; font-style: normal; }
.outcome-card strong { margin: 2rem 0 .6rem; font-family: var(--display); font-size: 1.45rem; letter-spacing: -.03em; }
.outcome-card small { min-height: 3.2rem; color: var(--muted); line-height: 1.5; }
.outcome-card b { margin-top: 1.5rem; color: var(--blue); font-size: .82rem; }
.outcome-choice:hover .outcome-card { border-color: rgba(36,78,239,.45); box-shadow: 8px 8px 0 #e7e6e2; }
.outcome-choice input:checked + .outcome-card { border-color: var(--blue); box-shadow: 0 0 0 2px var(--blue); }

.form-actions { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-top: 2.4rem; padding-top: 1.25rem; border-top: 1px solid var(--line); }
.single-action { justify-content: flex-end; border-top: 0; }
.primary-action, .back-action { min-height: 52px; border-radius: 5px; cursor: pointer; }
.primary-action { display: inline-flex; align-items: center; gap: 1.6rem; padding: .9rem 1.3rem; border: 1px solid var(--blue); background: var(--blue); color: var(--white); font-family: var(--display); font-weight: 600; transition: transform .2s, background .2s; }
.primary-action:hover { background: var(--blue-dark); }
.back-action { padding: .8rem 0; border: 0; background: transparent; color: var(--muted); }
.back-action:hover { color: var(--ink); }

.security-note { display: flex; gap: 1rem; margin: 2rem 0; padding: 1rem; border: 1px solid rgba(54,185,120,.3); border-radius: 5px; background: rgba(54,185,120,.07); }
.security-note > span { display: grid; flex: 0 0 28px; height: 28px; place-items: center; border-radius: 50%; background: #36b978; color: #fff; }
.security-note p { margin: 0; color: var(--muted); font-size: .9rem; }
.security-note strong { display: block; margin-bottom: .25rem; color: var(--ink); }
.submit-status { min-height: 1.5rem; color: var(--blue-dark); font-size: .88rem; }
.calendar-shell { width: 100%; height: 720px; min-height: 720px; margin-top: 2rem; border: 1px solid var(--line); border-radius: 5px; overflow: hidden; background: #fff; }
.calendar-shell iframe { display: block; width: 100%; height: 100%; min-height: 720px; border: 0; }
.calendar-placeholder { display: flex; min-height: 720px; align-items: center; justify-content: center; padding: 2rem; flex-direction: column; text-align: center; }
.calendar-placeholder > span { color: var(--blue); font-size: 2rem; }
.calendar-placeholder strong { margin: 1rem 0 .5rem; font-family: var(--display); font-size: 1.35rem; }
.calendar-placeholder p { max-width: 44ch; color: var(--muted); line-height: 1.5; }
.calendar-load-message { margin: 1rem 0 0; color: var(--muted); font-size: .9rem; line-height: 1.5; }
.calendar-fallback { display: inline-flex; min-height: 44px; margin-top: .75rem; align-items: center; color: var(--blue); font-family: var(--display); font-weight: 600; text-underline-offset: 4px; }

@keyframes step-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

@media (max-width: 900px) {
  .audit-layout { grid-template-columns: 1fr; }
  .audit-aside { display: none; }
  .form-panel { min-height: calc(100vh - 74px); padding: 2rem 1.25rem 3rem; place-items: start center; }
  .mobile-progress { display: flex; width: min(100%,760px); margin-bottom: 2.5rem; align-items: center; gap: 1rem; color: var(--muted); font-size: .75rem; }
  .mobile-progress > div { flex: 1; height: 3px; overflow: hidden; border-radius: 99px; background: rgba(10,21,38,.1); }
  .mobile-progress i { display: block; width: 0; height: 100%; background: var(--blue); transition: width .3s ease; }
}

@media (max-width: 700px) {
  .calendar-shell { height: 680px; min-height: 680px; }
  .calendar-shell iframe, .calendar-placeholder { min-height: 680px; }
}

@media (max-width: 600px) {
  .audit-header { height: 66px; padding-inline: 1rem; }
  .audit-trust { font-size: .7rem; }
  .close-audit { width: 38px; height: 38px; margin-left: .8rem; }
  .audit-layout { padding-top: 66px; }
  .form-panel { min-height: calc(100vh - 66px); }
  .form-step h2 { font-size: clamp(2.15rem,10vw,3.3rem); }
  .field-grid, .choice-grid, .outcome-grid { grid-template-columns: 1fr; }
  .choice > span { min-height: 66px; }
  .outcome-card { min-height: 220px; }
  .form-actions { align-items: stretch; flex-direction: column-reverse; }
  .form-actions .primary-action { width: 100%; justify-content: space-between; }
  .back-action { min-height: 44px; }
  .single-action { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
