/* ==========================================================================
   Page-level styles — hero, homepage sections, page-specific blocks
   ========================================================================== */

/* ==========================================================================
   1. HERO — the lantern field
   ========================================================================== */

.hero {
  position: relative;
  overflow: hidden;
  padding-top: var(--sp-16);
  padding-bottom: var(--sp-20);
  background:
    radial-gradient(ellipse 120% 80% at 50% 108%, rgba(255, 212, 138, 0.16), transparent 62%),
    radial-gradient(ellipse 90% 60% at 18% 6%, rgba(58, 76, 115, 0.55), transparent 62%),
    linear-gradient(180deg, var(--sky-950) 0%, var(--sky-900) 55%, var(--sky-950) 100%);
  isolation: isolate;
}
@media (min-width: 768px) {
  .hero { padding-top: var(--sp-20); padding-bottom: var(--sp-24); }
}

/* Homepage banner photo.
   Only the geometry lives here. The background-image itself MUST be set inline
   on the element in index.html: a url() written anywhere in this stylesheet
   resolves against assets/css/, not the page, and would 404. Layout for the
   layered stack (photo at the bottom, the warm + cool glows above it, and the
   left-to-right / top-to-bottom scrims that keep the left-aligned copy
   readable over the lit temple) is:

     linear-gradient(90deg,  rgba(7,11,22,.62) 0%, rgba(7,11,22,.16) 52%, rgba(7,11,22,0) 82%),
     linear-gradient(180deg, rgba(7,11,22,.40) 0%, rgba(7,11,22,.20) 38%, rgba(7,11,22,.82) 78%, rgba(7,11,22,.94) 100%),
     radial-gradient(ellipse 120% 80% at 50% 108%, rgba(255,212,138,.16), transparent 62%),
     radial-gradient(ellipse 90% 60% at 18% 6%, rgba(58,76,115,.55), transparent 62%),
     url('assets/img/home-hero.webp')
*/
.hero--image {
  background-color: var(--sky-950);
  background-size: cover;
  background-position: center 60%;
  background-repeat: no-repeat;
}

/* Animated lantern field, drawn behind the copy */
.hero__lanterns {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.lantern {
  position: absolute;
  bottom: -12%;
  width: var(--l-size, 12px);
  height: auto;
  border-radius: 50% 50% 42% 42%;
  background: radial-gradient(circle at 50% 42%,
    #FFF8E6 0%,
    var(--glow-300) 38%,
    rgba(245, 185, 66, 0.75) 68%,
    rgba(224, 155, 33, 0) 100%);
  filter: blur(0.3px);
  opacity: 0;
  animation: lantern-rise var(--l-dur, 22s) linear var(--l-delay, 0s) infinite;
  will-change: transform, opacity;
}
@keyframes lantern-rise {
  0%   { transform: translate3d(0, 0, 0) scale(0.85);        opacity: 0; }
  8%   { opacity: var(--l-op, 0.75); }
  50%  { transform: translate3d(var(--l-drift, 24px), -46vh, 0) scale(1); }
  88%  { opacity: var(--l-op, 0.75); }
  100% { transform: translate3d(0, -92vh, 0) scale(0.92);    opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .lantern { animation: none; opacity: 0.28; }
}

/* Horizon glow line — where the lanterns are released from */
.hero__horizon {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 34%;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent, rgba(255, 212, 138, 0.07));
  mask-image: linear-gradient(180deg, transparent, #000);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000);
}

.hero__inner {
  position: relative;
  z-index: 2;
  max-width: 52rem;
}

.hero h1 {
  margin-bottom: var(--sp-6);
  font-size: clamp(2.5rem, 7vw, 4.5rem);
  line-height: 1.06;
  letter-spacing: -0.03em;
}
.hero h1 .accent {
  display: block;
  color: var(--glow-300);
  font-style: italic;
  font-variation-settings: 'SOFT' 40, 'WONK' 1;
}

.hero__lead {
  max-width: 46ch;
  margin-bottom: var(--sp-8);
  font-size: var(--fs-lg);
  line-height: var(--lh-relaxed);
  color: var(--text-secondary);
}
@media (min-width: 768px) { .hero__lead { font-size: var(--fs-xl); } }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-4);
  margin-bottom: var(--sp-10);
}

/* Trust row under the CTAs */
.hero__trust {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-5) var(--sp-8);
  list-style: none;
  margin: 0;
  padding: var(--sp-6) 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}
.hero__trust li {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--fs-sm);
  color: var(--text-muted);
  margin: 0;
}
.hero__trust svg { color: var(--glow-500); flex-shrink: 0; }

/* ==========================================================================
   2. HOMEPAGE — narrative blocks
   ========================================================================== */

/* The opening narrative paragraph (large, editorial) */
.opening {
  max-width: 46rem;
}
.opening p {
  font-size: var(--fs-lg);
  line-height: var(--lh-relaxed);
  color: var(--text-secondary);
  margin-bottom: var(--sp-6);
}
@media (min-width: 768px) {
  .opening p { font-size: var(--fs-xl); }
}
.opening p:first-of-type {
  color: var(--glow-200);
}

/* Two-column: sticky label + content */
.split {
  display: grid;
  gap: var(--sp-8);
  grid-template-columns: 1fr;
}
@media (min-width: 1024px) {
  .split { grid-template-columns: 20rem 1fr; gap: var(--sp-16); }
  .split__aside { position: sticky; top: 7rem; align-self: start; }
}
.split__aside h2 { margin-bottom: var(--sp-4); }
.split__aside .eyebrow { margin-bottom: var(--sp-3); }

/* Question list — "what the photos don't show" */
.questions {
  list-style: none;
  margin: 0 0 var(--sp-8);
  padding: 0;
  counter-reset: q;
}
.questions li {
  position: relative;
  counter-increment: q;
  padding: var(--sp-5) 0 var(--sp-5) var(--sp-12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  line-height: var(--lh-snug);
  letter-spacing: -0.012em;
  color: var(--glow-100);
  margin: 0;
}
.questions li::before {
  content: counter(q, decimal-leading-zero);
  position: absolute;
  left: 0; top: calc(var(--sp-5) + 0.15em);
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  color: var(--glow-500);
}
.questions li:first-child { border-top: 1px solid rgba(255, 255, 255, 0.07); }

/* CAD spotlight — a wide feature block */
.spotlight {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-xl);
  border: 1px solid rgba(255, 212, 138, 0.18);
  background: var(--sky-900);
}
.spotlight__media {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--sky-800);
}
@media (min-width: 768px) { .spotlight__media { aspect-ratio: 21 / 9; } }
.spotlight__media img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.spotlight__media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 11, 22, 0.15) 0%, rgba(7, 11, 22, 0.92) 100%);
}
.spotlight__body {
  position: relative;
  z-index: 2;
  margin-top: -14rem;
  padding: var(--sp-8) var(--sp-6) var(--sp-10);
  max-width: 46rem;
}
@media (min-width: 768px) {
  .spotlight__body { margin-top: -18rem; padding: var(--sp-10) var(--sp-10) var(--sp-12); }
}
.spotlight__body h2 { margin-bottom: var(--sp-5); }
.spotlight__body p {
  font-size: var(--fs-md);
  line-height: var(--lh-relaxed);
  color: var(--text-secondary);
  margin-bottom: var(--sp-5);
}
.spotlight__tag {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-1) var(--sp-4);
  margin-bottom: var(--sp-5);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--text-on-glow);
  background: var(--glow-300);
  border-radius: var(--r-full);
}

/* ==========================================================================
   3. INNER PAGE HERO (shorter variant)
   ========================================================================== */

.page-hero {
  position: relative;
  overflow: hidden;
  padding-top: var(--sp-12);
  padding-bottom: var(--sp-12);
  background:
    radial-gradient(ellipse 100% 70% at 50% 120%, rgba(255, 212, 138, 0.13), transparent 65%),
    linear-gradient(180deg, var(--sky-900) 0%, var(--sky-950) 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
@media (min-width: 768px) {
  .page-hero { padding-top: var(--sp-16); padding-bottom: var(--sp-16); }
}
.page-hero--plain {
  background: linear-gradient(180deg, var(--sky-900) 0%, var(--sky-950) 100%);
}

/* Image-backed page hero.
   The background-image (scrim gradient + photo) must be set INLINE on the
   element. Any url() written in this stylesheet — in a declaration or in a CSS
   custom property — resolves against assets/css/, not the page, so it would be
   requested from assets/css/assets/img/... and 404. */
/* Framing sits low (65%) so the visible band is the dense field of lanterns.
   The upper third of these photos is near-empty night sky, which reads as a
   blank backdrop; the busy lower band also masks upscaling softness. */
.page-hero--image {
  background-size: cover;
  background-position: center 65%;
  background-repeat: no-repeat;
}

/* ==========================================================================
   4. QUICK-ANSWER BLOCK (GEO/AI-friendly summary)
   ========================================================================== */

.quick-answer {
  padding: var(--sp-6);
  border-radius: var(--r-lg);
  border: 1px solid rgba(255, 212, 138, 0.20);
  background: rgba(255, 212, 138, 0.05);
  margin-block: var(--sp-8);
}
.quick-answer__label {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  margin-bottom: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--glow-300);
}
.quick-answer p {
  margin: 0;
  font-size: var(--fs-md);
  line-height: var(--lh-relaxed);
  color: var(--text-primary);
}

/* ==========================================================================
   5. ALTERNATIVES — event blocks
   ========================================================================== */

.event {
  padding-top: var(--sp-10);
  padding-bottom: var(--sp-10);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}
.event:first-of-type { border-top: none; padding-top: 0; }

.event__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--sp-2) var(--sp-4);
  margin-bottom: var(--sp-4);
}
.event__name {
  margin: 0;
  font-size: clamp(1.375rem, 2.6vw, 2rem);
  letter-spacing: -0.018em;
}
.event__tagline {
  font-size: var(--fs-sm);
  color: var(--glow-500);
  font-weight: var(--fw-medium);
}

.event__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) var(--sp-6);
  margin-bottom: var(--sp-5);
  font-size: var(--fs-xs);
  color: var(--text-muted);
}
.event__meta span { display: inline-flex; align-items: center; gap: var(--sp-2); }

/* "Choose X if" list inside event blocks */
.pick-list {
  list-style: none;
  margin: var(--sp-5) 0;
  padding: var(--sp-5) var(--sp-6);
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, 0.035);
  border-left: 3px solid var(--glow-500);
}
.pick-list__title {
  display: block;
  margin-bottom: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--glow-300);
}
.pick-list li {
  position: relative;
  padding-left: var(--sp-5);
  margin-bottom: var(--sp-2);
  font-size: var(--fs-sm);
  line-height: var(--lh-relaxed);
  color: var(--text-secondary);
}
.pick-list li:last-child { margin-bottom: 0; }
.pick-list li::before {
  content: '';
  position: absolute;
  left: 0; top: 0.62em;
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--glow-500);
}

/* Anchored "jump to" nav for long pages */
.jump-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2);
  padding: var(--sp-4) 0;
  margin-bottom: var(--sp-8);
  border-top: 1px solid rgba(255, 255, 255, 0.07);
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}
.jump-nav a {
  padding: var(--sp-2) var(--sp-4);
  font-size: var(--fs-xs);
  font-weight: var(--fw-medium);
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: var(--r-full);
  transition: all var(--t-fast);
}
.jump-nav a:hover {
  color: var(--glow-300);
  border-color: var(--glow-500);
  background: rgba(255, 212, 138, 0.07);
}

/* ==========================================================================
   6. DECISION QUIZ
   ========================================================================== */

.quiz {
  padding: var(--sp-8);
  border-radius: var(--r-xl);
  border: 1px solid rgba(255, 212, 138, 0.20);
  background: linear-gradient(170deg, var(--sky-800), var(--sky-900));
}
@media (min-width: 768px) { .quiz { padding: var(--sp-10); } }

.quiz__progress {
  display: flex;
  gap: var(--sp-2);
  margin-bottom: var(--sp-8);
}
.quiz__dot {
  flex: 1;
  height: 3px;
  border-radius: var(--r-full);
  background: rgba(255, 255, 255, 0.12);
  transition: background var(--t-normal);
}
.quiz__dot[data-done='true'] { background: var(--glow-400); }

.quiz__question {
  margin: 0 0 var(--sp-6);
  font-size: clamp(1.25rem, 2.6vw, 1.75rem);
  letter-spacing: -0.018em;
}
.quiz__options { display: grid; gap: var(--sp-3); }

.quiz__option {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  width: 100%;
  min-height: 3.5rem;
  padding: var(--sp-4) var(--sp-5);
  text-align: left;
  font-family: inherit;
  font-size: var(--fs-base);
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: all var(--t-fast);
}
.quiz__option:hover {
  border-color: var(--glow-500);
  background: rgba(255, 212, 138, 0.09);
  transform: translateX(3px);
}
.quiz__option svg { flex-shrink: 0; color: var(--glow-500); }
.quiz__option:hover svg { color: var(--glow-300); }

.quiz__back {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  margin-top: var(--sp-6);
  padding: var(--sp-2) 0;
  min-height: 2.75rem;
  background: none;
  border: none;
  font-family: inherit;
  font-size: var(--fs-sm);
  color: var(--text-muted);
  cursor: pointer;
}
.quiz__back:hover { color: var(--glow-300); }

.quiz__result { display: none; }
.quiz__result[data-active='true'] { display: block; }
.quiz__panel { display: none; }
.quiz__panel[data-active='true'] { display: block; }

.quiz__verdict {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: var(--sp-2) var(--sp-4);
  margin-bottom: var(--sp-5);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: var(--ls-wide);
  text-transform: uppercase;
  color: var(--text-on-glow);
  background: var(--glow-300);
  border-radius: var(--r-full);
}
.quiz__result h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: var(--sp-4);
}
.quiz__result p {
  font-size: var(--fs-md);
  line-height: var(--lh-relaxed);
  margin-bottom: var(--sp-6);
  max-width: 54ch;
}
.quiz__result .btn { margin-top: var(--sp-2); }

/* ==========================================================================
   7. LEGAL PAGES
   ========================================================================== */

.legal {
  counter-reset: sec;
}
.legal h2 {
  margin-top: var(--sp-12);
  margin-bottom: var(--sp-4);
  font-family: var(--font-body);
  font-size: var(--fs-lg);
  font-weight: var(--fw-semi);
  letter-spacing: 0;
  color: var(--glow-100);
}
.legal h2:first-of-type { margin-top: 0; }
.legal p, .legal li {
  font-size: var(--fs-sm);
  line-height: var(--lh-relaxed);
  color: var(--text-muted);
}
.legal .updated {
  display: inline-block;
  padding: var(--sp-2) var(--sp-4);
  margin-bottom: var(--sp-8);
  font-size: var(--fs-xs);
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.05);
  border-radius: var(--r-full);
}

/* ==========================================================================
   8. ABOUT — credentials strip
   ========================================================================== */

.creds {
  display: grid;
  gap: 1px;
  grid-template-columns: 1fr;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--r-lg);
  overflow: hidden;
}
@media (min-width: 640px) { .creds { grid-template-columns: repeat(3, 1fr); } }
.creds__item {
  padding: var(--sp-8) var(--sp-6);
  background: var(--sky-900);
  text-align: center;
}
.creds__num {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 2.75rem);
  line-height: 1;
  color: var(--glow-300);
  letter-spacing: -0.03em;
  margin-bottom: var(--sp-2);
}
.creds__label {
  font-size: var(--fs-sm);
  color: var(--text-muted);
  line-height: var(--lh-normal);
}

/* Contact page layout */
.contact-grid {
  display: grid;
  gap: var(--sp-10);
  grid-template-columns: 1fr;
}
@media (min-width: 1024px) {
  .contact-grid { grid-template-columns: 1.4fr 1fr; gap: var(--sp-16); }
}
.contact-aside {
  padding: var(--sp-8);
  border-radius: var(--r-lg);
  background: var(--sky-900);
  border: 1px solid rgba(255, 255, 255, 0.08);
  align-self: start;
}
@media (min-width: 1024px) { .contact-aside { position: sticky; top: 7rem; } }
.contact-aside h2 {
  font-size: var(--fs-lg);
  font-family: var(--font-body);
  letter-spacing: 0;
  margin-bottom: var(--sp-4);
}
.contact-aside ul { list-style: none; margin: 0; padding: 0; }
.contact-aside li {
  display: flex;
  gap: var(--sp-3);
  padding: var(--sp-4) 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  font-size: var(--fs-sm);
  color: var(--text-muted);
  line-height: var(--lh-relaxed);
  margin: 0;
}
.contact-aside li:last-child { border-bottom: none; padding-bottom: 0; }
.contact-aside li svg { flex-shrink: 0; color: var(--glow-500); margin-top: 0.2em; }
.contact-aside strong { display: block; color: var(--text-primary); margin-bottom: var(--sp-1); }

/* ==========================================================================
   9. 404 / UTILITY
   ========================================================================== */

.center-page {
  min-height: 62vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding-block: var(--sp-20);
}
