/* ===========================================================
   Faye Mac "Glow Up" Quiz — styles.css
   Design tokens + components + layout. Edit colours/type/motion
   here only; no values are hardcoded elsewhere. See README.
   =========================================================== */

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Lexend";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("../assets/fonts/Lexend-Variable-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Tokens ---------- */
:root {
  /* Brand: three colours only */
  --lilac: #C5A9D1;
  --black: #000000;
  --white: #FFFFFF;
  /* Derived lilac ramp */
  --lilac-tint: #F3ECF6;
  --lilac-mist: #FAF6FB;
  --lilac-soft: #DCC9E4;
  --lilac-deep: #9B79AD;
  --plum: #6B4380;
  --glow-rgb: 197, 169, 209;
  --glow-deep-rgb: 155, 121, 173;

  /* Semantic */
  --surface-page: var(--lilac-tint);
  --surface-card: var(--white);
  --text-strong: var(--black);
  --text-body: var(--black);
  --text-muted: var(--plum);
  --text-link: var(--plum);
  --feedback-error: var(--plum);
  --feedback-error-bg: #F6EEF8;

  /* Type badge colourways */
  --badge-winger-bg: var(--lilac);
  --badge-secret-bg: var(--white);
  --badge-ceiling-bg: var(--lilac-soft);
  --badge-guesser-bg: var(--lilac-tint);

  /* Fonts */
  --font-family: "Lexend", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --weight-light: 300;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-bold: 700;
  --weight-black: 800;
  --text-display-xl: 40px;
  --text-display-l: 32px;
  --text-display-m: 26px;
  --text-display-s: 21px;
  --text-body-l: 18px;
  --text-body: 16px;
  --text-small: 14px;
  --text-label: 12px;
  --leading-display: 1.04;
  --leading-body: 1.5;
  --tracking-display: 0.01em;
  --tracking-label: 0.18em;
  --tracking-button: 0.04em;

  /* Spacing / radii */
  --space-2: 8px;
  --space-4: 16px;
  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-pill: 999px;
  --gutter: 20px;
  --tap-min: 44px;
  --tap-tile: 56px;
  --button-h: 56px;
  --input-h: 52px;
  --skew: -12deg;
  --border-fine: 1.5px;
  --border-chunky: 2px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);

  /* Effects */
  --glow-sm: 0 0 18px 2px rgba(var(--glow-rgb), .55);
  --glow-md: 0 0 36px 6px rgba(var(--glow-rgb), .6);
  --glow-text: 0 0 24px rgba(var(--glow-rgb), .9);
  --halo: radial-gradient(closest-side, rgba(var(--glow-rgb), .75), rgba(var(--glow-rgb), .28) 55%, rgba(var(--glow-rgb), 0));
  --halo-white: radial-gradient(closest-side, rgba(255, 255, 255, .85), rgba(255, 255, 255, 0));
  --shadow-chunky: 0 4px 0 0 var(--lilac-deep);
  --shadow-chunky-pressed: 0 1px 0 0 var(--lilac-deep);
  --shadow-card: 0 10px 30px -12px rgba(var(--glow-deep-rgb), .45);
  --focus-ring: 0 0 0 3px var(--white), 0 0 0 5px var(--plum);

  /* Motion */
  --dur-fast: 150ms;
  --dur-base: 200ms;
  --dur-slow: 250ms;
  --dur-screen: 320ms;
  --dur-confetti: 1200ms;
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --ease-out: cubic-bezier(.22, 1, .36, 1);
}

@media (min-width: 768px) {
  :root { --text-display-xl: 52px; --text-display-l: 38px; }
}

@media (prefers-reduced-motion: reduce) {
  :root { --dur-fast: 0ms; --dur-base: 0ms; --dur-slow: 0ms; --dur-screen: 0ms; --dur-confetti: 0ms; }
  *, *::before, *::after { animation-duration: 0ms !important; animation-iteration-count: 1 !important; transition-duration: 0ms !important; }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font-family);
  color: var(--text-body);
  background: var(--surface-page);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overscroll-behavior-y: none;
}
a { color: var(--text-link); text-underline-offset: 3px; }
a:hover { color: var(--black); }
button, input, textarea { font-family: inherit; }
:focus-visible { outline: none; box-shadow: var(--focus-ring); }
ul { margin: 0; padding: 0; list-style: none; }
img { max-width: 100%; display: block; }

@keyframes fm-glow-pulse { 0%, 100% { opacity: .7; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }
@keyframes fm-sparkle { 0% { opacity: 0; transform: scale(.2) rotate(-45deg); } 60% { opacity: 1; transform: scale(1.25) rotate(8deg); } 100% { opacity: 1; transform: scale(1) rotate(0); } }
@keyframes fm-pop { 0% { transform: scale(1); } 40% { transform: scale(1.06) rotate(-1deg); } 100% { transform: scale(1); } }
@keyframes fm-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes fm-land { 0% { opacity: 0; transform: scale(.7); } 70% { opacity: 1; transform: scale(1.06); } 100% { transform: scale(1); } }
@keyframes fm-confetti { 0% { opacity: 1; transform: translate(0, 0) rotate(0); } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) rotate(var(--rot)); } }
@keyframes fm-drift { 0%, 100% { transform: translate(0, 0); } 50% { transform: translate(6px, -8px); } }
@keyframes fm-shake { 0%, 100% { transform: none; } 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* ---------- App shell ---------- */
#fm-app {
  position: relative;
  height: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  container-type: inline-size;
  container-name: fm-app;
}

/* ---------- Screen / backdrop ---------- */
.fm-screen {
  position: relative;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--lilac-mist);
}
.fm-screen--lilac { background: var(--lilac); }
.fm-screen__inner {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  padding: calc(16px + var(--safe-top)) var(--gutter) calc(24px + var(--safe-bottom));
}
.fm-screen__inner--flush { padding: 0; }

.fm-backdrop { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.fm-backdrop__halo { position: absolute; width: 420px; height: 420px; border-radius: 50%; background: var(--halo); transition: opacity 600ms var(--ease-out); }
.fm-backdrop__halo--on-lilac { background: var(--halo-white); }
.fm-backdrop__halo--a { right: -30%; top: -14%; opacity: .55; }
.fm-backdrop__halo--b { left: -40%; bottom: -18%; width: 460px; height: 460px; opacity: .4; }
.fm-backdrop__shape { position: absolute; transition: transform 600ms var(--ease-spring); }

/* ---------- Shapes ---------- */
.fm-shape { display: block; overflow: visible; }
.fm-shape--glow { filter: drop-shadow(0 0 10px rgba(var(--glow-rgb), .95)); }

/* ---------- Headline / highlight ---------- */
.fm-headline {
  margin: 0;
  font-family: var(--font-family);
  font-weight: var(--weight-light);
  font-size: var(--text-display-l);
  line-height: var(--leading-display);
  letter-spacing: var(--tracking-display);
  text-transform: uppercase;
  color: var(--text-strong);
}
.fm-headline--xl { font-size: var(--text-display-xl); }
.fm-headline--s { font-size: var(--text-display-s); }
.fm-highlight { font-weight: var(--weight-black); }
.fm-highlight--block {
  position: relative;
  display: inline-block;
  padding: 0 .18em;
  z-index: 0;
}
.fm-highlight--block::before {
  content: "";
  position: absolute;
  inset: .06em 0 .02em;
  background: var(--lilac);
  transform: skewX(var(--skew));
  z-index: -1;
  box-shadow: var(--glow-sm);
}
.fm-highlight--on-lilac::before { background: var(--white); box-shadow: none; }

/* ---------- Buttons ---------- */
.fm-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: var(--button-h);
  padding: 0 28px;
  border-radius: var(--radius-pill);
  border: var(--border-chunky) solid var(--lilac);
  background: var(--lilac);
  color: var(--black);
  font-family: var(--font-family);
  font-weight: var(--weight-black);
  font-size: 16px;
  letter-spacing: var(--tracking-button);
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--glow-sm);
  transition: transform var(--dur-fast) var(--ease-spring), box-shadow var(--dur-base) var(--ease-out), background var(--dur-fast);
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}
.fm-btn:active { transform: scale(.97); background: var(--lilac-soft); box-shadow: var(--glow-md); }
.fm-btn--full { display: flex; width: 100%; }
.fm-btn--sm { min-height: 44px; padding: 0 20px; font-size: 14px; }
.fm-btn--on-lilac { background: var(--white); border-color: var(--white); box-shadow: none; }
.fm-btn--on-lilac:active { background: var(--lilac-tint); }
.fm-btn--secondary { background: var(--white); border-color: var(--black); box-shadow: none; }
.fm-btn--secondary:active { background: var(--lilac-tint); }
.fm-btn--ghost {
  background: transparent; border-color: transparent; box-shadow: none; padding: 0 14px;
  font-weight: var(--weight-medium); text-transform: none; text-decoration: underline; text-underline-offset: 4px; color: var(--plum);
}
.fm-btn--ghost:active { background: rgba(var(--glow-rgb), .18); }
.fm-btn[disabled], .fm-btn[aria-disabled="true"] { opacity: .45; cursor: not-allowed; pointer-events: none; }
.fm-btn__chevron { flex: none; }

.fm-back {
  width: 44px; height: 44px; border-radius: 50%; border: var(--border-fine) solid var(--black);
  background: var(--white); display: grid; place-items: center; cursor: pointer; flex: none; padding: 0;
  transition: transform var(--dur-fast) var(--ease-spring), background var(--dur-fast);
}
.fm-back:active { transform: scale(.92); background: var(--lilac-soft); }
.fm-back[disabled] { opacity: .35; pointer-events: none; }

/* ---------- Landing ---------- */
.fm-landing__logo { height: 50px; align-self: flex-start; margin-bottom: 18px; }
.fm-landing__label { align-self: flex-start; position: relative; padding: 6px 14px; margin-bottom: 4px; }
.fm-landing__label::before { content: ""; position: absolute; inset: 0; background: var(--white); transform: skewX(var(--skew)); }
.fm-landing__label span { position: relative; font-size: var(--text-label); letter-spacing: var(--tracking-label); font-weight: var(--weight-bold); text-transform: uppercase; }
.fm-landing__top { display: flex; flex-direction: column; gap: 16px; animation: fm-rise 400ms var(--ease-out) both; }
.fm-landing__subhead { margin: 0; font-size: var(--text-body-l); line-height: 1.4; font-weight: var(--weight-medium); }
.fm-landing__body { margin: 0; font-size: 15px; line-height: 1.5; }
.fm-landing__bottom { margin-top: auto; display: flex; flex-direction: column; gap: 14px; padding-top: 12px; }
.fm-landing__proof { margin: 0; font-size: 13px; text-align: center; font-weight: var(--weight-medium); }

.fm-photo-slot { position: relative; width: 100%; height: 200px; margin: 14px 0 0; }
.fm-photo-slot__frame {
  position: absolute; inset: 0; border-radius: var(--radius-lg); overflow: hidden;
  border: var(--border-fine) solid var(--black); box-shadow: var(--glow-md); background: var(--lilac-soft);
}
.fm-photo-slot__frame img { width: 100%; height: 100%; object-fit: cover; object-position: center 18%; filter: grayscale(1) contrast(1.05); }
.fm-photo-slot__shape { position: absolute; }
.fm-photo-slot--empty .fm-photo-slot__halo { position: absolute; left: 50%; top: 50%; width: 110%; height: 110%; transform: translate(-50%, -50%); background: var(--halo-white); border-radius: 50%; }
.fm-photo-slot--broken .fm-photo-slot__frame,
.fm-photo-slot--broken .fm-photo-slot__shape { display: none; }

/* ---------- Progress meter ---------- */
.fm-meter { display: flex; flex-direction: column; gap: 10px; flex: 1; }
.fm-meter__row { display: flex; justify-content: space-between; font-size: var(--text-label); letter-spacing: var(--tracking-label); text-transform: uppercase; font-weight: var(--weight-bold); }
.fm-meter__pct { color: var(--plum); font-variant-numeric: tabular-nums; }
.fm-meter__track-wrap { position: relative; height: 22px; margin: 0 8px; }
.fm-meter__track { position: absolute; left: 0; right: 0; top: 6px; height: 10px; background: var(--white); border: var(--border-fine) solid var(--black); transform: skewX(var(--skew)); }
.fm-meter__fill {
  position: absolute; left: 0; top: 6px; height: 10px; background: var(--lilac);
  border-top: var(--border-fine) solid var(--black); border-bottom: var(--border-fine) solid var(--black); border-left: var(--border-fine) solid var(--black);
  transform: skewX(var(--skew)); box-shadow: var(--glow-sm); transition: width var(--dur-screen) var(--ease-spring);
}
.fm-meter__dot { position: absolute; top: 11px; animation: fm-sparkle var(--dur-slow) var(--ease-spring) both; }
.fm-meter__head { position: absolute; top: 0; transition: left var(--dur-screen) var(--ease-spring); animation: fm-sparkle var(--dur-slow) var(--ease-spring) both; }
.fm-meter__micro { min-height: 20px; font-size: 14px; line-height: 1.4; color: var(--plum); font-weight: var(--weight-medium); animation: fm-rise var(--dur-slow) var(--ease-out); }

/* ---------- Question ---------- */
.fm-q-head { display: flex; gap: 14px; align-items: flex-start; }
.fm-q-body { display: flex; flex-direction: column; gap: 20px; flex: 1; padding-top: 22px; animation: fm-rise var(--dur-screen) var(--ease-out) both; }
.fm-q-body--compact { gap: 14px; }
.fm-q-optional { font-size: var(--text-label); letter-spacing: var(--tracking-label); text-transform: uppercase; font-weight: var(--weight-bold); color: var(--plum); }
.fm-q-title { margin: 0; font-size: 27px; line-height: 1.2; font-weight: var(--weight-bold); letter-spacing: -0.005em; }
.fm-q-title--compact { font-size: 23px; }
.fm-q-sub { margin: 0; font-size: 15px; color: var(--plum); font-weight: var(--weight-medium); }
.fm-q-answers { display: flex; flex-direction: column; gap: 12px; margin-top: 6px; }
.fm-q-answers--compact { gap: 9px; margin-top: 0; }

.fm-reassure {
  position: relative; display: flex; gap: 14px; align-items: center; padding: 14px 16px;
  background: var(--white); border-radius: var(--radius-md); box-shadow: var(--glow-sm);
  animation: fm-rise 400ms var(--ease-out) both;
}
.fm-reassure__icon { position: relative; width: 36px; height: 36px; flex: none; display: grid; place-items: center; }
.fm-reassure__icon::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; background: var(--halo); animation: fm-glow-pulse 3s ease-in-out infinite; }
.fm-reassure p { position: relative; margin: 0; font-size: 15px; line-height: 1.45; font-weight: var(--weight-medium); }

/* ---------- Answer tile ---------- */
.fm-tile {
  position: relative; width: 100%; min-height: var(--tap-tile); padding: 15px 48px 15px 18px;
  display: flex; align-items: center; gap: 12px; text-align: left; cursor: pointer;
  border-radius: var(--radius-md); border: var(--border-fine) solid var(--black);
  background: var(--white); color: var(--black);
  font-family: var(--font-family); font-size: 16px; line-height: 1.3; font-weight: var(--weight-regular);
  box-shadow: var(--shadow-chunky);
  transition: transform var(--dur-fast) var(--ease-spring), box-shadow var(--dur-base) var(--ease-out), background var(--dur-fast);
  -webkit-tap-highlight-color: transparent;
}
.fm-tile:active { transform: translateY(3px); box-shadow: var(--shadow-chunky-pressed); background: var(--lilac-tint); }
.fm-tile--compact { min-height: 50px; padding: 11px 44px 11px 16px; font-size: 15px; }
.fm-tile__bar { width: 10px; height: 18px; flex: none; background: var(--lilac); transform: skewX(var(--skew)); transition: background var(--dur-fast); }
.fm-tile__sparkle { position: absolute; right: 16px; top: 50%; margin-top: -9px; animation: fm-sparkle var(--dur-slow) var(--ease-spring) both; }
.fm-tile[aria-checked="true"] {
  background: var(--lilac); border-color: var(--lilac-deep); font-weight: var(--weight-bold);
  box-shadow: 0 2px 0 0 var(--lilac-deep), var(--glow-md); transform: rotate(-1.2deg) translateY(1px);
  animation: fm-pop var(--dur-slow) var(--ease-spring);
}
.fm-tile[aria-checked="true"] .fm-tile__bar { background: var(--black); }
.fm-tile[disabled] { opacity: .55; pointer-events: none; }

/* ---------- Text area (Q13) ---------- */
.fm-textarea-wrap { display: flex; flex-direction: column; gap: 12px; }
.fm-textarea {
  padding: 16px; border-radius: var(--radius-md); border: var(--border-fine) solid var(--black);
  background: var(--white); font-family: var(--font-family); font-size: 16px; line-height: 1.5; color: var(--black);
  resize: none; outline: none; width: 100%; transition: box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-fast);
}
.fm-textarea:focus { border-width: 2px; border-color: var(--plum); box-shadow: var(--glow-sm); }
.fm-textarea-count { align-self: flex-end; font-size: 13px; color: var(--plum); font-variant-numeric: tabular-nums; }
.fm-textarea-count--near { color: var(--black); font-weight: var(--weight-bold); }

/* ---------- Warming interstitial ---------- */
.fm-warming { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 36px; text-align: center; }
.fm-warming__orb { position: relative; width: 200px; height: 200px; display: grid; place-items: center; }
.fm-warming__halo { position: absolute; inset: -50px; border-radius: 50%; background: var(--halo); animation: fm-glow-pulse 1.2s ease-in-out infinite; transform: scale(1.15); }
.fm-warming__plus { animation: fm-sparkle 600ms var(--ease-spring) both; }
.fm-warming__title { font-size: var(--text-display-m); font-weight: var(--weight-light); text-transform: uppercase; line-height: 1.05; }
.fm-warming__meter { width: 100%; }

/* ---------- Fields ---------- */
.fm-field { display: flex; flex-direction: column; gap: 6px; }
.fm-field__label { font-size: var(--text-small); font-weight: var(--weight-medium); color: var(--black); }
.fm-field__optional { color: var(--plum); font-weight: var(--weight-regular); }
.fm-field__input {
  height: var(--input-h); padding: 0 16px; border-radius: var(--radius-md); border: var(--border-fine) solid var(--black);
  background: var(--white); font-family: var(--font-family); font-size: 16px; color: var(--black); outline: none; width: 100%;
  transition: box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-fast);
}
.fm-field__input:focus { border-width: 2px; border-color: var(--plum); box-shadow: var(--glow-sm); }
.fm-field--error .fm-field__input { border-color: var(--plum); border-width: 2px; background: var(--feedback-error-bg); animation: fm-shake var(--dur-slow) var(--ease-out); }
.fm-field__msg { display: flex; align-items: center; gap: 6px; font-size: 13px; line-height: 1.35; color: var(--plum); }
.fm-field--error .fm-field__msg { font-weight: var(--weight-bold); }

/* ---------- Checkbox ---------- */
.fm-check { display: flex; flex-direction: column; gap: 6px; }
.fm-check__row { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; min-height: 44px; padding: 4px 0; }
.fm-check__input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fm-check__box {
  width: 26px; height: 26px; flex: none; border-radius: var(--radius-sm); display: grid; place-items: center; margin-top: 1px;
  border: 2px solid var(--black); background: var(--white); transform: scale(.96);
  transition: all var(--dur-base) var(--ease-spring);
}
.fm-check__input:checked + .fm-check__box { background: var(--lilac); border-color: var(--lilac-deep); box-shadow: var(--glow-sm); transform: scale(1); }
.fm-check__input:focus-visible + .fm-check__box { box-shadow: var(--focus-ring); }
.fm-check--error .fm-check__box { border-color: var(--plum); background: var(--feedback-error-bg); }
.fm-check__label { font-size: 14px; line-height: 1.45; color: var(--black); }
.fm-check__msg { font-size: 13px; color: var(--plum); font-weight: var(--weight-bold); padding-left: 38px; }

/* Landing: desktop-only elements hidden on mobile, shown in the container query below */
.fm-landing__cta-row, .fm-landing__body--desktop-only, .fm-landing__proof-desktop { display: none; }

/* ---------- Gate ---------- */
.fm-gate-head { display: flex; flex-direction: column; gap: 8px; text-align: center; }
.fm-gate-head h1 { margin: 0; font-size: var(--text-display-m); font-weight: var(--weight-light); text-transform: uppercase; line-height: 1.05; }
.fm-gate-head p { margin: 0; font-size: 16px; color: var(--plum); font-weight: var(--weight-medium); }
.fm-gate-teaser { position: relative; height: 150px; display: flex; justify-content: center; align-items: center; margin-bottom: 8px; }
.fm-gate-head--aside { display: none; }
.fm-gate-form { display: flex; flex-direction: column; gap: 16px; }
.fm-gate-form a { font-size: 13px; }
.fm-gate-privacy { margin: 0; font-size: 13px; text-align: center; }

/* ---------- Score dial ---------- */
.fm-dial { position: relative; flex: none; }
.fm-dial__halo { position: absolute; border-radius: 50%; background: var(--halo); }
.fm-dial__center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.fm-dial__score { font-family: var(--font-family); font-weight: var(--weight-black); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; color: var(--black); line-height: 1; }
.fm-dial__score--settled { text-shadow: var(--glow-text); }
.fm-dial__score--masked { color: var(--lilac-deep); }
.fm-dial__label { letter-spacing: .1em; text-transform: uppercase; font-weight: var(--weight-bold); color: var(--plum); white-space: nowrap; }

/* ---------- Verdict badge ---------- */
.fm-verdict { display: inline-flex; align-items: center; gap: 10px; }
.fm-verdict__box { position: relative; padding: 10px 20px; }
.fm-verdict__box::before { content: ""; position: absolute; inset: 0; background: var(--lilac); border: var(--border-fine) solid var(--black); transform: skewX(var(--skew)); box-shadow: var(--glow-sm); }
.fm-verdict__text { position: relative; font-family: var(--font-family); font-weight: var(--weight-black); font-size: 15px; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }

/* ---------- Type badge ---------- */
.fm-badge { position: relative; flex: none; border-radius: 50%; }
.fm-badge__halo { position: absolute; background: var(--halo); border-radius: 50%; pointer-events: none; }
.fm-badge__disc { position: absolute; inset: 0; border-radius: 50%; overflow: hidden; box-shadow: var(--glow-md); }
.fm-badge--silhouette .fm-badge__disc { background: var(--lilac-tint); filter: blur(1.5px); box-shadow: none; }
.fm-badge__art { position: absolute; }

/* ---------- Confetti ---------- */
.fm-confetti { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; z-index: 5; }
.fm-confetti__piece { position: absolute; opacity: 0; animation: fm-confetti var(--dur-confetti) var(--ease-out) forwards; }

/* ---------- Result ---------- */
.fm-result { position: relative; min-height: 100%; background: var(--lilac-mist); }
.fm-result__hero { position: relative; overflow: hidden; background: var(--lilac); padding: calc(20px + var(--safe-top)) var(--gutter) 28px; }
.fm-result__hero-inner { position: relative; max-width: 520px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px; }
.fm-result__top { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.fm-result__reveal { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
.fm-result__you-are { font-size: 20px; font-weight: var(--weight-bold); }
.fm-result__type-row { display: flex; flex-direction: column; align-items: center; gap: 16px; opacity: 0; }
.fm-result__type-row--in { opacity: 1; animation: fm-land 500ms var(--ease-spring) both; }
.fm-result__type-info { display: flex; flex-direction: column; gap: 6px; align-items: center; }
.fm-result__type-name { font-size: 26px; line-height: 1.1; }
.fm-result__tagline { margin: 0; font-size: 16px; line-height: 1.4; font-weight: var(--weight-medium); max-width: 380px; }
.fm-result__body { position: relative; max-width: 520px; margin: 0 auto; padding: 28px var(--gutter) calc(40px + var(--safe-bottom)); display: flex; flex-direction: column; gap: 44px; }
.fm-result__columns, .fm-result__copy-stack, .fm-result__bridge-row { display: flex; flex-direction: column; gap: 36px; }

.fm-quote { margin: 0; position: relative; padding: 20px 22px; background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-card); }
.fm-quote__kicker { font-size: var(--text-label); letter-spacing: var(--tracking-label); text-transform: uppercase; font-weight: var(--weight-bold); color: var(--plum); margin-bottom: 8px; }
.fm-quote p { margin: 0; font-size: 18px; line-height: 1.45; font-weight: var(--weight-medium); }

.fm-copy-card { display: flex; flex-direction: column; gap: 12px; }
.fm-copy-card h3 { margin: 0; display: flex; align-items: center; gap: 10px; font-size: var(--text-display-s); font-weight: var(--weight-light); text-transform: uppercase; letter-spacing: .02em; }
.fm-copy-card p { margin: 0; font-size: 16px; line-height: 1.55; }

.fm-bridge { display: flex; flex-direction: column; gap: 16px; }
.fm-bridge p { margin: 0; font-size: 17px; line-height: 1.5; font-weight: var(--weight-medium); max-width: 480px; }

/* ---------- Hero CTA (above the fold) ---------- */
.fm-hero-cta { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 10px; opacity: 0; transform: translateY(10px); transition: opacity 300ms var(--ease-out), transform 400ms var(--ease-spring); }
.fm-hero-cta--in { opacity: 1; transform: none; }
.fm-hero-cta__kicker { margin: 0; font-size: 13px; font-weight: var(--weight-bold); letter-spacing: .06em; text-transform: uppercase; }

/* ---------- Video block ---------- */
.fm-video { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.fm-video__frame { position: relative; aspect-ratio: 4 / 5; max-height: 420px; width: 100%; border-radius: var(--radius-lg); overflow: hidden; border: var(--border-fine) solid var(--black); background: var(--lilac-soft); box-shadow: var(--glow-md); }
.fm-video__frame iframe, .fm-video__frame video { border: 0; width: 100%; height: 100%; object-fit: cover; }
.fm-video__play { position: absolute; inset: 0; border: 0; padding: 0; cursor: pointer; background: var(--lilac); display: grid; place-items: center; }
.fm-video__play-halo { position: absolute; width: 220px; height: 220px; background: var(--halo-white); border-radius: 50%; }
.fm-video__play-btn { position: relative; width: 76px; height: 76px; border-radius: 50%; background: var(--white); border: var(--border-fine) solid var(--black); display: grid; place-items: center; box-shadow: var(--glow-md); animation: fm-glow-pulse 2.4s ease-in-out infinite; }
.fm-video figcaption { font-size: 13px; color: var(--plum); font-weight: var(--weight-medium); }

/* ---------- Next step block ---------- */
.fm-next { position: relative; background: var(--white); border: var(--border-fine) solid var(--black); border-radius: var(--radius-lg); padding: 28px 22px 22px; box-shadow: var(--shadow-card), var(--glow-sm); overflow: hidden; }
.fm-next__corner { position: absolute; right: -14px; top: -14px; }
.fm-next__tag { position: relative; display: inline-flex; align-items: center; gap: 8px; font-size: var(--text-label); letter-spacing: var(--tracking-label); text-transform: uppercase; font-weight: var(--weight-bold); color: var(--plum); }
.fm-next__inner { position: relative; display: flex; flex-direction: column; gap: 16px; }
.fm-next__heading { margin: 0; font-weight: var(--weight-black); font-size: var(--text-display-m); line-height: 1.05; text-transform: uppercase; }
.fm-next__heading--vsl { font-weight: var(--weight-light); }
.fm-next__chips { display: flex; flex-wrap: wrap; gap: 8px; }
.fm-next__chip { padding: 6px 12px; background: var(--lilac-tint); border-radius: var(--radius-xs); font-size: 14px; font-weight: var(--weight-bold); }
.fm-next__bullets { display: flex; flex-direction: column; gap: 10px; }
.fm-next__bullets li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; line-height: 1.45; }
.fm-next__bullets li .fm-shape { margin-top: 5px; flex: none; }

/* ---------- Share ---------- */
.fm-share { display: flex; flex-direction: column; gap: 12px; }
.fm-share__label { font-size: var(--text-label); letter-spacing: var(--tracking-label); text-transform: uppercase; font-weight: var(--weight-bold); text-align: center; }
.fm-share__row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }

.fm-footer-logo { height: 44px; align-self: center; margin-top: 8px; opacity: .9; }

/* ---------- Desktop (container query: the quiz's own width, works in iframes) ---------- */
@container fm-app (min-width: 900px) {
  .fm-screen__inner { max-width: 1040px; padding: 32px 40px 56px; }
  .fm-screen__inner--narrow { max-width: 880px; }
  .fm-screen__inner--gate { max-width: 1040px; }

  .fm-landing__logo { height: 64px; margin-bottom: 0; }
  .fm-landing__grid { flex: 1; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 64px; align-items: center; padding: 24px 0; }
  .fm-landing__grid--no-photo { grid-template-columns: minmax(0, 1fr); }
  .fm-landing__top { max-width: 760px; gap: 24px; }
  .fm-landing__subhead { font-size: 22px; max-width: 560px; }
  .fm-landing__body { font-size: 17px; max-width: 520px; }
  .fm-landing__bottom { display: none; }
  .fm-landing__body--desktop-only { display: block; }
  .fm-landing__cta-row { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; margin-top: 8px; }
  .fm-landing__cta-row .fm-btn { min-width: 300px; }
  .fm-landing__proof-desktop { display: inline; font-size: 14px; font-weight: var(--weight-medium); }
  .fm-photo-slot { height: 560px; }

  .fm-q-body { flex-direction: column; gap: 28px; padding-top: 48px; }
  .fm-q-title { font-size: 38px; }
  .fm-q-answers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }

  .fm-gate-grid { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 64px; align-items: center; }
  .fm-gate-form { background: var(--white); border: var(--border-fine) solid var(--black); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-card), var(--glow-sm); }
  .fm-gate-form .fm-gate-head { display: none; }
  .fm-gate-fields-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .fm-gate-teaser { height: 280px; }
  .fm-gate-head--aside { text-align: left; display: flex; flex-direction: column; gap: 8px; }
  .fm-gate-head--aside h1 { font-size: 44px; }

  .fm-result__hero { padding: 64px var(--gutter) 72px; }
  .fm-result__hero-inner { max-width: 1040px; display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 72px; padding: 0 40px; text-align: left; }
  .fm-result__reveal { align-items: flex-start; text-align: left; }
  .fm-result__type-name { font-size: 38px; }
  .fm-result__tagline { font-size: 18px; }
  .fm-result__type-row { flex-direction: row; align-items: center; gap: 28px; }
  .fm-result__type-info { align-items: flex-start; }
  .fm-result__body { max-width: 1040px; padding: 56px 40px 64px; gap: 56px; }
  .fm-result__columns { display: grid; grid-template-columns: 360px minmax(0, 1fr); gap: 40px; align-items: start; }
  .fm-result__columns--no-video { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .fm-result__columns--no-video .fm-quote { grid-column: 1 / -1; }
  .fm-result__copy-stack { display: flex; flex-direction: column; gap: 28px; }
  .fm-result__bridge-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
  .fm-bridge p { font-size: 19px; }
  .fm-share { max-width: 520px; width: 100%; align-self: center; }
}
