/* Apogee page styles. Everything is scoped under .apogee so it can't
   leak into the shared header/footer; colors come from /styles.css. */
.apogee [id] { scroll-margin-top: 100px; }
.apogee :focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; }
.apogee a { color: var(--orange); }
.apogee a:hover { color: white; }
.apogee .measure { max-width: 42rem; }
.apogee p { color: var(--paper-muted); margin: 0 0 16px; }
.apogee strong { color: white; font-weight: 600; }

.apogee section { padding-block: 96px; background: var(--ink); }
.apogee section.tint { background: var(--ink-deep); }

.apogee h2 {
  color: white; font-size: clamp(2rem, 4vw, 3.2rem); font-weight: 400;
  letter-spacing: -0.035em; line-height: 1.15; margin: 0 0 22px;
}
.apogee h3 { color: white; font-size: 1.15rem; font-weight: 600; margin: 0 0 8px; }

/* Buttons */
.apogee .btn {
  display: inline-block; font: inherit; font-size: 1rem; font-weight: 700;
  padding: 14px 24px; border-radius: 9px; text-decoration: none;
  border: 2px solid var(--orange); cursor: pointer; line-height: 1.2;
}
.apogee .btn-primary { background: var(--orange); color: var(--ink-deep); }
.apogee .btn-primary:hover { background: white; border-color: white; color: var(--ink-deep); }
.apogee .btn-secondary { background: transparent; color: var(--paper); border-color: rgba(185, 203, 212, 0.45); }
.apogee .btn-secondary:hover { background: var(--ink-soft); border-color: var(--paper); color: white; }
.apogee .btn[disabled],
.apogee .btn[disabled]:hover { opacity: .45; cursor: not-allowed; background: var(--orange); border-color: var(--orange); }
.apogee .actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Hero */
.apogee .ap-hero { position: relative; padding-block: 90px; }
.apogee .ap-hero::after {
  content: ""; position: absolute; inset: auto 0 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}
.apogee .ap-hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.apogee .ap-hero h1 {
  color: white; font-size: clamp(2.6rem, 5.5vw, 4.4rem); font-weight: 400;
  letter-spacing: -0.045em; line-height: 1.02; margin: 0 0 24px;
}
.apogee .lede { font-size: clamp(1.15rem, 1.9vw, 1.4rem); line-height: 1.55; margin: 0 0 32px; max-width: 34rem; }
.apogee .orbit-fig { margin: 0; }
.apogee .orbit { display: block; width: 100%; height: auto; }
.apogee .orbit-fig figcaption { font-size: 0.95rem; color: var(--paper-muted); text-align: center; max-width: 26rem; margin: 8px auto 0; }
.apogee .orbit-label { font-size: 15px; fill: var(--paper-muted); }
.apogee .orbit-label.strong { fill: white; font-weight: 700; }
.apogee .orbit .halo { paint-order: stroke; stroke: #062b3a; stroke-width: 7px; stroke-linejoin: round; }
.apogee .orbit-value { font-size: 19px; fill: var(--paper-muted); }
.apogee .orbit-value.gold { fill: var(--orange); font-weight: 700; font-size: 21px; }

/* Content sections */
.apogee .problem-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 34px 38px; margin-top: 44px; }
.apogee .problem-grid div { border-top: 1px solid var(--line); padding-top: 23px; }
.apogee .problem-grid p { font-size: 0.98rem; }

.apogee .steps { list-style: none; padding: 0; margin: 44px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; counter-reset: step; }
.apogee .steps li { counter-increment: step; padding: 0 28px 0 0; }
.apogee .steps li::before {
  content: counter(step, decimal-leading-zero); display: block; margin-bottom: 18px;
  color: var(--orange); font-size: 0.8rem; letter-spacing: 0.18em;
}
.apogee .steps li p { font-size: 0.98rem; }
.apogee .note { margin-top: 28px; }

.apogee .team,
.apogee .fit { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start; }
.apogee .team ul,
.apogee .fit ul,
.apogee .about ul { margin: 0; padding-left: 1.2em; color: var(--paper-muted); }
.apogee .team li { margin-bottom: 14px; }
.apogee .fit li,
.apogee .about li { margin-bottom: 8px; }

/* Scorecard */
.apogee .privacy { font-size: 0.95rem; }

/* Progress bar along the bottom edge of the sticky header */
.quiz-progress {
  position: absolute; left: 0; right: 0; bottom: -1px; height: 6px;
  background: rgba(83, 120, 199, 0.18);
}
.quiz-progress span {
  display: block; width: 0; height: 100%; background: var(--orange);
  transition: width 0.35s ease;
}

.apogee .quiz { padding-block: 64px 96px; min-height: 70vh; }
.apogee .quiz h1 {
  color: white; font-size: clamp(2rem, 4.5vw, 3.2rem); font-weight: 400;
  letter-spacing: -0.035em; line-height: 1.1; margin: 0 0 14px;
}
.apogee .quiz-intro { margin-bottom: 36px; }
.apogee .quiz-meta {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin: 0 0 10px; color: var(--paper-muted); font-size: 0.9rem;
}
.apogee .quiz-meta .area-name { color: var(--orange); font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; font-size: 0.78rem; }
.apogee .quiz-card {
  background: linear-gradient(160deg, rgba(83, 120, 199, 0.10), transparent 45%), var(--card);
  border: 1px solid rgba(83, 120, 199, 0.22); border-radius: var(--radius);
  padding: 28px 24px 24px;
}
.apogee .quiz-card h2 { font-size: clamp(1.35rem, 2.6vw, 1.75rem); letter-spacing: -0.02em; margin: 0 0 20px; }
.apogee .quiz-card h2:focus { outline: none; }
.apogee .options { display: grid; gap: 10px; }
.apogee .option {
  display: block; width: 100%; text-align: left; font: inherit; font-size: 1rem; line-height: 1.4;
  padding: 14px 18px; border-radius: 9px; cursor: pointer;
  color: var(--paper); background: var(--ink-deep);
  border: 1px solid rgba(185, 203, 212, 0.22);
  transition: background 0.15s ease, border-color 0.15s ease;
}
.apogee .option:hover { background: var(--ink-soft); border-color: var(--paper-muted); }
.apogee .option[aria-pressed="true"] { border-color: var(--orange); background: rgba(226, 88, 34, 0.14); color: white; }
.apogee .quiz-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 20px; }
.apogee .link-btn {
  font: inherit; font-size: 0.95rem; background: none; border: 0; padding: 6px 0;
  color: var(--paper-muted); cursor: pointer;
}
.apogee .link-btn:hover { color: white; }
.apogee .link-btn[disabled] { visibility: hidden; }

/* Scorecard results */
.apogee #results { display: none; padding-top: 16px; }
.apogee #results.show { display: block; }
.apogee #results:focus { outline: none; }
.apogee .overall { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; }
.apogee .overall .num { color: white; font-size: 4rem; font-weight: 400; letter-spacing: -0.04em; line-height: 1; }
.apogee .overall .band { color: var(--orange); font-size: 1.3rem; font-weight: 700; }
.apogee .area-result { padding: 20px 0; border-bottom: 1px solid rgba(83, 120, 199, 0.22); }
.apogee .area-result .row { display: flex; justify-content: space-between; gap: 16px; align-items: baseline; color: var(--paper); }
.apogee .area-result .row strong { font-size: 1.1rem; }
.apogee .meter { height: 10px; background: var(--ink-soft); border-radius: 5px; margin: 10px 0 12px; overflow: hidden; }
.apogee .meter span { display: block; height: 100%; background: var(--orange); border-radius: 5px; }
.apogee .area-result p { font-size: 0.98rem; margin: 0; }

/* Email capture on the results */
.apogee .capture {
  margin-top: 36px; padding: 28px 24px;
  background: linear-gradient(160deg, rgba(226, 88, 34, 0.12), transparent 50%), var(--card);
  border: 1px solid rgba(226, 88, 34, 0.45); border-radius: var(--radius);
}
.apogee .capture h3 { font-size: 1.35rem; line-height: 1.3; margin-bottom: 10px; }
.apogee .capture .section-kicker,
.apogee .quiz-intro .section-kicker { color: var(--orange); }
.apogee .capture .section-kicker { margin-bottom: 8px; }
.apogee .capture form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; margin-top: 20px; }
.apogee .capture .field { display: grid; gap: 6px; }
.apogee .capture label { color: var(--paper); font-size: 0.92rem; font-weight: 600; }
.apogee .capture input {
  font: inherit; font-size: 1rem; padding: 12px 14px; border-radius: 9px;
  color: white; background: var(--ink-deep); border: 1px solid rgba(185, 203, 212, 0.35);
}
.apogee .capture input:focus { outline: 3px solid var(--orange); outline-offset: 1px; border-color: var(--orange); }
.apogee .capture .btn { grid-column: 1 / -1; justify-self: start; }
.apogee .capture .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.apogee .form-note { grid-column: 1 / -1; font-size: 0.88rem; margin: 0; }
.apogee .form-status { grid-column: 1 / -1; color: #ff9d76; font-weight: 600; margin: 0; }
.apogee .form-status:empty { display: none; }
.apogee .capture-done:focus { outline: none; }
.apogee .capture-done p { margin: 0; }

/* About, brokers, contact */
.apogee .about { display: grid; grid-template-columns: 1fr 1.4fr; gap: 56px; }
.apogee .brokers { border-left: 4px solid var(--orange); padding-left: 24px; }
.apogee .disclaimer { padding-block: 0 48px; }
.apogee .disclaimer p { margin: 0; font-size: 0.9rem; }

@media (max-width: 900px) {
  .apogee .ap-hero-grid,
  .apogee .team,
  .apogee .fit,
  .apogee .about { grid-template-columns: 1fr; gap: 32px; }
  .apogee .ap-hero { padding-block: 60px 64px; }
  .apogee .orbit-fig { max-width: 440px; width: 100%; justify-self: center; }
  .apogee .problem-grid { grid-template-columns: 1fr; gap: 26px; }
  .apogee .steps { grid-template-columns: 1fr 1fr; gap: 34px 0; }
  .apogee section { padding-block: 72px; }
}
@media (max-width: 520px) {
  .apogee .steps { grid-template-columns: 1fr; }
  .apogee .capture form { grid-template-columns: 1fr; }
  .apogee .btn { width: 100%; text-align: center; }
}
