/* The Booking Score, /score/. Builds on site.css tokens and components. */

/* The quiz is a focused task: no footer competing with it. */
body.score-running .foot { display: none; }

.sc [hidden] { display: none !important; }

/* ---------- landing ---------- */

.sc-hero__actions { display: grid; gap: 14px; justify-items: start; margin-top: 30px; }
.sc-hero .hero__grid { padding-bottom: 48px; }
.sc-hero .proof { margin-top: 0; }

.sc-sample { padding: 22px; }
.sc-sample__top { display: flex; justify-content: space-between; gap: 12px; font-family: var(--font-mono); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.sc-sample__score { margin-top: 14px; font-family: var(--font-display); font-style: italic; font-weight: 900; line-height: 0.85; font-size: 112px; }
.sc-sample__score small { margin-left: 8px; font-size: 36px; color: var(--muted-2); }

.sc-rating { display: inline-block; margin-top: 14px; padding: 6px 10px; background: var(--ink); color: var(--yellow); font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; }

.sc-bars { display: grid; gap: 12px; margin-top: 20px; }
.sc-bars li { display: grid; grid-template-columns: 1fr auto; gap: 5px 12px; align-items: baseline; }
.sc-bars__label { font-size: 15px; font-weight: 800; }
.sc-bars__label em { margin-left: 6px; padding: 1px 5px; background: var(--yellow); font-family: var(--font-mono); font-size: 10px; font-style: normal; font-weight: 700; text-transform: uppercase; }
.sc-bars__n { font-family: var(--font-mono); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }
.sc-bars__track { grid-column: 1 / -1; display: block; height: 8px; background: var(--paper-deep); }
.sc-bars__track span { display: block; height: 100%; background: var(--ink); transform-origin: left; animation: sc-grow 0.7s var(--ease) both; }

@keyframes sc-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.sc-faq { border-top: 1.5px solid var(--line); }

/* ---------- quiz ---------- */

.sq { min-height: calc(100dvh - var(--top-h)); padding: 28px 0 56px; }
.sq__meta { display: flex; justify-content: space-between; gap: 16px; font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.sq__progress { height: 8px; margin-top: 12px; background: var(--paper-deep); }
.sq__progress span { display: block; height: 100%; background: var(--ink); transition: width 0.3s var(--ease); }
.sq__title { margin-top: 36px; font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase; font-size: clamp(38px, 6vw, 60px); line-height: 0.95; text-wrap: balance; outline: none; }
.sq__hint { margin-top: 14px; font-size: 17px; color: var(--muted); }
.sq__opts { display: grid; gap: 10px; margin-top: 28px; }
.sq__opt { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 60px; padding: 12px 16px; border: var(--stroke) solid var(--ink); border-radius: var(--r-sm); background: var(--white); color: var(--ink); font: inherit; font-size: 17px; font-weight: 700; line-height: 1.25; text-align: left; cursor: pointer; transition: background-color 0.15s var(--ease), transform 0.15s var(--ease); }
.sq__opt:active { transform: scale(0.99); }
.sq__opt.is-on { background: var(--yellow); }
@media (hover: hover) { .sq__opt:hover { background: var(--yellow); } }
.sq__key { display: none; flex: none; place-items: center; width: 26px; height: 26px; border: 1.5px solid var(--ink); font-family: var(--font-mono); font-size: 12px; font-weight: 700; }
@media (min-width: 720px) and (hover: hover) { .sq__key { display: grid; } }
.sq__nav { display: flex; align-items: center; justify-content: space-between; min-height: 42px; margin-top: 24px; }
.sq__back { padding: 8px 0; border: 0; background: none; color: var(--muted); font: inherit; font-weight: 800; text-decoration: underline; text-underline-offset: 4px; cursor: pointer; }

.sq--load { display: grid; align-items: center; }
.sq__loader { height: 8px; margin-top: 32px; background: var(--paper-deep); overflow: hidden; }
.sq__loader span { display: block; width: 40%; height: 100%; background: var(--ink); animation: sq-slide 1.1s ease-in-out infinite alternate; }
@keyframes sq-slide { from { transform: translateX(0); } to { transform: translateX(150%); } }

/* ---------- result ---------- */

.sr-hero { padding-bottom: 48px; }
.sr-hero__grid { display: grid; gap: 32px; align-items: center; }
.sr-score { margin-top: 10px; font-family: var(--font-display); font-style: italic; font-weight: 900; line-height: 0.82; font-size: clamp(150px, 26vw, 240px); outline: none; }
.sr-score small { margin-left: 10px; font-size: 0.26em; }
.sr-hero .lede { margin-top: 20px; }
.sr-breakdown { padding: 22px; }
.sr-label { font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }

.sr-leaks { display: grid; gap: 16px; }
.sr-leak { display: grid; gap: 10px; align-content: start; padding: 24px; }
.sr-leak__top { display: flex; justify-content: space-between; gap: 12px; font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--muted); }
.sr-leak h3 { font-size: 32px; line-height: 0.98; }
.sr-leak p { font-size: 16px; color: var(--ink-2); }
.sr-leak__fix { margin-top: 6px; padding-top: 12px; border-top: 1.5px solid var(--line); font-weight: 700; }
.sr-leak__fix strong { display: block; margin-bottom: 4px; font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em; text-transform: uppercase; }

.sr-first__text { margin-top: 18px; max-width: 34em; font-size: clamp(21px, 2.6vw, 28px); font-weight: 700; line-height: 1.3; }

.sr-lead { display: grid; gap: 28px; align-items: start; }
.sr-lead .sect-head__lede { margin-top: 14px; }
.sr-form { padding: 24px; }
.sr-form form { display: grid; gap: 14px; }
.sr-form .field { position: relative; }
.sr-consent { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; font-weight: 600; cursor: pointer; }
.sr-consent input { flex: none; width: 20px; height: 20px; margin-top: 1px; accent-color: var(--ink); }
.sr-done { display: grid; gap: 10px; outline: none; }
.sr-done__title { font-family: var(--font-display); font-style: italic; font-weight: 900; text-transform: uppercase; font-size: 42px; line-height: 0.95; }
.sr-actions { margin-top: 28px; }

.sr-locked { display: grid; gap: 8px; margin-top: 22px; }
.sr-locked li { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; border: var(--stroke) dashed var(--ink); border-radius: var(--r-sm); font-family: var(--font-mono); font-size: 12px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.sr-report { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.sr-report .sr-done__title { font-size: 34px; }

.sr-tail { display: flex; flex-wrap: wrap; gap: 14px 32px; align-items: center; }
.sr-tail .textlink { padding: 0; border: 0; background: none; font: inherit; font-weight: 800; cursor: pointer; }
.sr-note { font-size: 14px; font-weight: 700; color: var(--muted); }

@media (min-width: 1000px) {
	.sc-hero .hero__grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 64px; }
	.sr-hero__grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 64px; }
	.sr-leaks { grid-template-columns: repeat(3, 1fr); }
	.sr-lead { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 64px; }
}

@media (prefers-reduced-motion: reduce) {
	.sc-bars__track span, .sq__loader span { animation: none; }
	.sq__opt, .sq__progress span { transition: none; }
}
