/* ==========================================================================
   Skylitic — site styles
   Palette, type and layout follow BRAND_GUIDELINES.md (repo root).
   Feel: clean, premium but restrained, text-led, subtle motion only.
   ========================================================================== */

:root {
  /* --- Navy --- */
  --navy:            #1b2d4f;
  --navy-dark:       #111e35;
  --navy-mid:        #253f6a;

  /* --- Amber --- */
  --amber:           #b07020;
  --amber-light:     #c8822a;
  --amber-pale:      #f7ecd8;

  /* --- Neutrals --- */
  --cream:           #f4f1ec;
  --white:           #ffffff;

  /* --- Applied roles --- */
  --bg:              var(--white);
  --bg-subtle:       var(--cream);
  --bg-raised:       var(--white);
  --bg-invert:       var(--navy);

  --text:            #1a1f2b;
  --text-secondary:  #3a4258;
  /* Muted clears AA on white (4.8:1) but only 4.3:1 on cream, so body copy in
     cream sections uses --text-secondary. Muted is for small labels on white. */
  --text-muted:      #6a7285;
  --text-invert:     var(--cream);

  --border:          #ddd8d2;
  --border-light:    #e8e3dd;

  --brand:           var(--navy);
  --brand-hover:     var(--navy-dark);
  --brand-contrast:  var(--white);

  --accent:          var(--amber);       /* graphics: rules, chips, marks */
  --accent-text:     #8a5718;            /* amber as TEXT; true amber is 3.6:1
                                            on cream and fails AA at small sizes */

  /* --- Scale --- */
  --radius:          10px;
  --radius-lg:       16px;
  --maxw:            70rem;
  --maxw-prose:      42rem;
  --shadow-sm:       0 1px 2px rgba(17, 30, 53, .05);
  --shadow:          0 1px 2px rgba(17, 30, 53, .04), 0 10px 30px rgba(17, 30, 53, .06);

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto,
          "Helvetica Neue", Arial, sans-serif;

  color-scheme: light dark;
}

/* Dark mode is derived, not specified in the guidelines: navy-dark becomes the
   ground, cream becomes the text, amber lifts to stay legible. Same brand,
   inverted — not a different palette. */
@media (prefers-color-scheme: dark) {
  :root {
    --bg:             #0d1626;
    --bg-subtle:      #14223a;
    --bg-raised:      #14223a;
    --bg-invert:      #070d18;

    --text:           #f4f1ec;
    --text-secondary: #c6cddb;
    --text-muted:     #94a0b6;
    --text-invert:    var(--cream);

    --border:         #26375a;
    --border-light:   #1f2e4c;

    --brand:          #9db6de;
    --brand-hover:    #bccce9;
    --brand-contrast: #0d1626;

    --accent:         var(--amber-light);
    --accent-text:    #dda257;

    --shadow-sm:      0 1px 2px rgba(0, 0, 0, .3);
    --shadow:         0 1px 2px rgba(0, 0, 0, .3), 0 10px 30px rgba(0, 0, 0, .35);
  }
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5rem; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-secondary);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.7;                      /* generous body leading */
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Strong, compact headings. */
h1, h2, h3, h4 {
  color: var(--text);
  line-height: 1.15;
  letter-spacing: -.021em;
  margin: 0 0 .55em;
  font-weight: 650;
}
h1 { font-size: clamp(2.35rem, 5.6vw, 3.75rem); letter-spacing: -.033em; line-height: 1.08; }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.35rem); letter-spacing: -.026em; }
h3 { font-size: 1.1875rem; }
h4 { font-size: 1.0625rem; }

p { margin: 0 0 1.15em; }
p:last-child { margin-bottom: 0; }

a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-hover); }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

img, svg { max-width: 100%; height: auto; }

strong { color: var(--text); font-weight: 620; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 1.5rem; }
@media (max-width: 30rem) { .wrap { padding-inline: 1rem; } }

.prose { max-width: var(--maxw-prose); }
.center { text-align: center; margin-inline: auto; }

.skip-link {
  position: absolute; left: -9999px;
  background: var(--navy); color: var(--white);
  padding: .65rem 1.1rem; border-radius: var(--radius); z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* Small uppercase label with light tracking — the brand's eyebrow treatment. */
.eyebrow {
  display: block;
  font-size: .75rem; font-weight: 640;
  letter-spacing: .13em; text-transform: uppercase;
  color: var(--accent-text);
  margin-bottom: 1.1rem;
}

.rule {
  width: 42px; height: 3px; border-radius: 2px;
  background: var(--accent); border: 0; margin: 0 0 1.6rem;
}
.center .rule, .rule.center { margin-inline: auto; }

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky; top: 0; z-index: 30;
  border-bottom: 1px solid var(--border-light);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; min-height: 4.5rem;
}

.brand { display: inline-flex; align-items: center; text-decoration: none; line-height: 0; }
.brand .logo { height: 34px; width: auto; display: block; transition: opacity .18s ease; }
.brand:hover .logo { opacity: .78; }

.nav { display: flex; align-items: center; gap: 1.75rem; }
.nav a {
  color: var(--text-secondary); text-decoration: none;
  font-size: .9375rem; font-weight: 520; white-space: nowrap;
  transition: color .15s ease;
}
.nav a:hover { color: var(--text); }
.nav .btn { color: var(--brand-contrast); }

/* Below 62rem the anchor links go and only the CTA remains — a four-link bar
   does not survive a phone, and a hamburger is more machinery than this needs. */
@media (max-width: 62rem) {
  .nav a:not(.btn) { display: none; }
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .78rem 1.5rem; border-radius: var(--radius);
  font-weight: 600; font-size: .9688rem; text-decoration: none;
  border: 1px solid transparent; cursor: pointer; white-space: nowrap;
  transition: background-color .18s ease, border-color .18s ease,
              color .18s ease, transform .18s ease;
}
.btn:active { transform: translateY(1px); }
.btn-sm { padding: .55rem 1.1rem; font-size: .9063rem; }

.btn-primary { background: var(--navy); color: var(--white); }
.btn-primary:hover { background: var(--navy-mid); color: var(--white); }

.btn-secondary { background: transparent; color: var(--text); border-color: var(--border); }
.btn-secondary:hover { color: var(--text); border-color: var(--text-muted); background: var(--bg-subtle); }

.btn-invert { background: var(--amber); color: #1a1207; }
.btn-invert:hover { background: var(--amber-light); color: #1a1207; }

.btn-ghost-invert { background: transparent; color: var(--cream); border-color: rgba(244, 241, 236, .3); }
.btn-ghost-invert:hover { color: var(--cream); border-color: rgba(244, 241, 236, .6); }

@media (prefers-color-scheme: dark) {
  .btn-primary { background: var(--brand); color: var(--brand-contrast); }
  .btn-primary:hover { background: var(--brand-hover); color: var(--brand-contrast); }
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero { padding: clamp(4.5rem, 10vw, 8rem) 0 clamp(3.5rem, 7vw, 5.5rem); }
.hero .wrap { max-width: 54rem; }
.hero .eyebrow { margin-bottom: 1.35rem; }

/* The brand line, set as three beats. */
.brandline { display: flex; flex-wrap: wrap; gap: 0 .35em; }
.brandline span { position: relative; }
.brandline .dot { color: var(--accent); }

.hero .lede {
  font-size: clamp(1.1875rem, 2.2vw, 1.375rem);
  color: var(--text-secondary);
  max-width: 40rem;
  margin-top: 1.5rem;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: .85rem; margin-top: 2.5rem; }
.hero-note { margin-top: 1.5rem; font-size: .9375rem; color: var(--text-muted); }

/* --------------------------------------------------------------------------
   Sections
   -------------------------------------------------------------------------- */

.section { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.section-alt { background: var(--bg-subtle); border-block: 1px solid var(--border-light); }
.section-invert { background: var(--bg-invert); color: rgba(244, 241, 236, .82); }
/* In light mode the navy band separates itself from white. In dark mode there
   is far less room between the band and the page, so it needs edges. */
@media (prefers-color-scheme: dark) {
  .section-invert { border-block: 1px solid var(--border); }
}
.section-invert h2, .section-invert h3, .section-invert strong { color: var(--cream); }
.section-invert .eyebrow { color: var(--amber-light); }

.section-head { max-width: 42rem; margin-bottom: 3rem; }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head p { color: var(--text-secondary); font-size: 1.0938rem; margin-bottom: 0; }
.section-invert .section-head p { color: rgba(244, 241, 236, .78); }

.grid { display: grid; gap: 1.25rem; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(16.5rem, 1fr)); }

/* --------------------------------------------------------------------------
   Cards — restrained surfaces, soft borders, subtle shadow
   -------------------------------------------------------------------------- */

.card {
  background: var(--bg-raised);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 1.85rem;
  box-shadow: var(--shadow-sm);
}
.card h3 { margin-bottom: .4rem; }
.card p { color: var(--text-secondary); font-size: .9938rem; }

.card .icon {
  width: 38px; height: 38px; border-radius: 10px; margin-bottom: 1.15rem;
  background: var(--amber-pale); color: #7d4e14;
  display: grid; place-items: center;
}
@media (prefers-color-scheme: dark) {
  .card .icon { background: rgba(200, 130, 42, .16); color: var(--amber-light); }
}

/* --- Numbered steps: See / Solve / Soar --- */
.step { position: relative; }
.step .num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 2.1rem; height: 2.1rem; border-radius: 50%;
  background: var(--amber-pale); color: #7d4e14;
  font-size: .8125rem; font-weight: 700; letter-spacing: .02em;
  margin-bottom: 1.15rem;
}
@media (prefers-color-scheme: dark) {
  .step .num { background: rgba(200, 130, 42, .16); color: var(--amber-light); }
}
.step h3 { font-size: 1.3125rem; }
.step h3 .dot { color: var(--accent); }

/* --------------------------------------------------------------------------
   Audience / fit lists
   -------------------------------------------------------------------------- */

.tags { display: flex; flex-wrap: wrap; gap: .55rem; list-style: none; margin: 0; padding: 0; }
.tags li {
  border: 1px solid var(--border); border-radius: 999px;
  padding: .42rem 1.05rem; font-size: .9063rem;
  color: var(--text-secondary); background: var(--bg-raised);
}

.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: .85rem; }
.checklist li { position: relative; padding-left: 1.9rem; color: var(--text-secondary); }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .58em;
  width: .5rem; height: .5rem; border-radius: 50%;
  background: var(--accent);
}
.section-invert .checklist li { color: rgba(244, 241, 236, .82); }

/* Split layout: heading column + content column */
.split { display: grid; gap: 2.5rem clamp(2rem, 6vw, 5rem); align-items: start; }
@media (min-width: 56rem) { .split { grid-template-columns: 1fr 1.25fr; } }
.split .section-head { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

details.faq { border-top: 1px solid var(--border-light); padding: 1.25rem 0; }
details.faq:last-of-type { border-bottom: 1px solid var(--border-light); }
details.faq summary {
  cursor: pointer; font-weight: 600; color: var(--text); list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 1.25rem;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: "+"; color: var(--accent-text); font-weight: 400;
  font-size: 1.4rem; line-height: 1; flex: 0 0 auto;
}
details.faq[open] summary::after { content: "\2212"; }
details.faq > *:not(summary) { margin-top: .9rem; color: var(--text-secondary); }

/* --------------------------------------------------------------------------
   Closing CTA
   -------------------------------------------------------------------------- */

.cta { text-align: center; }
.cta .wrap { max-width: 44rem; }
.cta h2 { color: var(--cream); }
.cta p { color: rgba(244, 241, 236, .8); font-size: 1.0938rem; }
.cta-actions { display: flex; flex-wrap: wrap; gap: .85rem; justify-content: center; margin-top: 2rem; }
.cta-email { margin-top: 1.75rem; font-size: .9375rem; color: rgba(244, 241, 236, .65); }
.cta-email a { color: var(--cream); }

/* --------------------------------------------------------------------------
   Document pages (privacy, and product pages later)
   -------------------------------------------------------------------------- */

.page-header { padding: clamp(3rem, 7vw, 4.5rem) 0 1.5rem; }
.page-header .updated { color: var(--text-muted); font-size: .9375rem; margin: 0; }

.doc { padding-bottom: 5.5rem; }
.doc h2 { margin-top: 2.85rem; font-size: 1.375rem; }
.doc h2:first-child { margin-top: 0; }
.doc ul, .doc ol { margin: 0 0 1.15em; padding-left: 1.35rem; }
.doc li { margin-bottom: .4em; }
.doc li::marker { color: var(--text-muted); }

.callout {
  border: 1px solid var(--border-light);
  border-left: 3px solid var(--accent);
  background: var(--bg-subtle);
  border-radius: var(--radius);
  padding: 1.25rem 1.4rem;
  margin: 0 0 2rem;
}

.contact-card {
  border: 1px solid var(--border-light); border-radius: var(--radius-lg);
  background: var(--bg-raised); padding: 1.85rem; margin-bottom: 2rem;
  box-shadow: var(--shadow-sm);
}
.contact-card .email { font-size: 1.1875rem; font-weight: 640; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--border-light);
  background: var(--bg-subtle);
  padding: 3rem 0 2.5rem;
  font-size: .9375rem;
  color: var(--text-muted);
}
.site-footer .top {
  display: flex; flex-wrap: wrap; gap: 2rem;
  justify-content: space-between; align-items: flex-start;
  padding-bottom: 2rem; margin-bottom: 1.75rem;
  border-bottom: 1px solid var(--border-light);
}
.site-footer .logo { height: 30px; width: auto; display: block; }
.site-footer .tagline { margin: .9rem 0 0; color: var(--text-secondary); max-width: 22rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 1.5rem; }
.site-footer a { color: var(--text-secondary); text-decoration: none; }
.site-footer a:hover { color: var(--text); }
.site-footer .legal {
  display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between;
}
.site-footer .legal p { margin: 0; }

/* --------------------------------------------------------------------------
   Motion — subtle only, and off entirely when the OS asks
   -------------------------------------------------------------------------- */

/* Visible by default. assets/boot.js adds `js` before paint, and only when
   motion is wanted, so content is never hidden from anyone who would not get
   it faded back in — no JS, no IntersectionObserver, or reduced motion. */
html.js .reveal { opacity: 0; transform: translateY(14px); }
html.js .reveal.in {
  opacity: 1; transform: none;
  transition: opacity .6s ease, transform .6s ease;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html.js .reveal { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   Placeholder marker — delete the markup AND this rule when content is final.
   -------------------------------------------------------------------------- */

.todo {
  outline: 1px dashed color-mix(in srgb, var(--accent) 60%, transparent);
  outline-offset: 3px;
  border-radius: 3px;
}
.todo-block { margin-top: 2rem; }

/* Who-we-help column */
.fit-sub { margin: 2.25rem 0 .9rem; font-size: .8125rem; font-weight: 640;
           letter-spacing: .1em; text-transform: uppercase; color: var(--text-muted); }
.fit-note { margin-top: 1.75rem; padding-top: 1.5rem; border-top: 1px solid var(--border-light);
            color: var(--text-muted); font-size: .9688rem; }
