/* ============================================================
   SWORN SLEEP — professional pass
   Cream and navy carry the site. Gold is an accent, only ever
   on cream or navy. Red white and blue winged logo is the hero.
   Navy #0B1D33 | Gold #D4AF37 | Ivory #F2E9D8 | Crimson #8B1E2D
   Headlines: Cormorant Garamond | Body: Montserrat
   ============================================================ */

:root {
  --navy: #0B1D33;
  --navy-2: #122B47;
  --gold: #D4AF37;
  --gold-2: #C8A02C;
  --ivory: #F2E9D8;
  --ivory-2: #E5D9BE;
  --crimson: #8B1E2D;
  --ink: #14212F;
  --serif: 'Cormorant Garamond', serif;
  --sans: 'Montserrat', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--ivory);
  line-height: 1.65;
  font-size: 16px;
}

img { max-width: 100%; display: block; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.08; color: var(--navy); }

h1 { font-size: clamp(2.7rem, 7.5vw, 4.8rem); letter-spacing: 0.01em; }
h2 { font-size: clamp(1.9rem, 5vw, 2.9rem); margin-bottom: 1.2rem; }
h3 { font-size: 1.35rem; margin-bottom: 0.4rem; }

.center { text-align: center; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.wrap-narrow { max-width: 780px; }

.section { padding: 92px 0; }
.section-ivory { background: var(--ivory); color: var(--ink); }
.section-navy { background: var(--navy); color: var(--ivory); }
.section-navy h2, .section-navy h3 { color: var(--ivory); }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.9rem;
}
.eyebrow-crimson { color: var(--crimson); }
.eyebrow-gold { color: var(--gold); }

/* ---------- buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 16px 34px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  border: 1px solid transparent;
}
.btn-navy { background: var(--navy); color: var(--ivory); border-color: var(--navy); }
.btn-navy:hover { background: var(--crimson); border-color: var(--crimson); }
.btn-outline-navy { background: transparent; color: var(--navy); border-color: var(--navy); }
.btn-outline-navy:hover { background: var(--navy); color: var(--ivory); }
.btn-gold { background: var(--gold); color: var(--navy); border-color: var(--gold); }
.btn-gold:hover { background: var(--ivory); border-color: var(--ivory); }
.btn-small { padding: 10px 22px; font-size: 0.72rem; }


/* ---------- header ---------- */
.topbar {
  background: var(--ivory);
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 24px;
  border-bottom: 1px solid rgba(11, 29, 51, 0.15);
  position: sticky; top: 0; z-index: 50;
}
.topbar-logo { height: 44px; width: auto; }

/* ---------- hero ---------- */
.hero {
  background: var(--ivory);
  text-align: center;
  padding: 72px 24px 88px;
}
.hero-logo { width: min(340px, 70vw); height: auto; margin: 0 auto 40px; }
.hero h1 { margin-bottom: 1.3rem; }
.hero-sub {
  font-size: clamp(1rem, 2.4vw, 1.2rem);
  max-width: 560px; margin: 0 auto 2.2rem;
  color: var(--ink);
}
.hero-ctas { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 3rem; }
.hero-origin {
  font-size: 0.7rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--crimson);
  border-top: 1px solid rgba(11, 29, 51, 0.2);
  display: inline-block; padding-top: 18px;
}

/* ---------- the enemy ---------- */
#enemy { border-top: 1px solid rgba(11, 29, 51, 0.12); }
.enemy-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 34px; margin: 3rem 0;
}
.enemy-item { border-top: 2px solid var(--crimson); padding-top: 18px; }
.enemy-item h3 { color: var(--crimson); }
.enemy-item p { font-size: 0.93rem; }
.enemy-close {
  font-family: var(--serif); font-size: clamp(1.5rem, 3.5vw, 2.1rem);
  font-weight: 600; text-align: center; margin-top: 1rem; color: var(--navy);
}

/* ---------- founder ---------- */
.founder-card {
  display: grid; grid-template-columns: 260px 1fr; gap: 40px;
  align-items: center; margin: 2.5rem 0;
}
.founder-photo-img {
  width: 100%; height: auto;
  border: 1px solid rgba(242, 233, 216, 0.3);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35);
}
.founder-story { margin-bottom: 1.4rem; }
.founder-story p {
  font-size: 0.98rem; color: rgba(242, 233, 216, 0.92);
  margin-bottom: 0.9rem; line-height: 1.75;
}
.founder-story p:first-child::first-letter {
  font-family: var(--serif); font-size: 2.6rem; font-weight: 600;
  color: var(--gold); float: left; line-height: 0.8;
  padding-right: 8px; padding-top: 4px;
}
.founder-name { font-weight: 700; letter-spacing: 0.06em; }
.founder-title { font-size: 0.8rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold); }
.founder-close {
  font-family: var(--serif); font-size: clamp(1.4rem, 3.2vw, 1.9rem);
  text-align: center; color: var(--ivory); font-weight: 600; font-style: italic;
}

/* ---------- sworn rate oath card ---------- */
.oath-card {
  background: #FBF6EA;
  border: 1px solid var(--navy);
  padding: 56px 40px;
  text-align: center;
  box-shadow: 0 1px 0 rgba(11, 29, 51, 0.08), 0 14px 34px rgba(11, 29, 51, 0.08);
}
.oath-logo { width: min(230px, 60vw); height: auto; margin: 0 auto 26px; }
.oath-body { max-width: 540px; margin: 0 auto 1.4rem; }
.oath-kicker {
  font-family: var(--serif); font-size: 1.35rem; font-weight: 600;
  color: var(--crimson); font-style: italic;
}

/* ---------- what we built ---------- */
.built-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px;
  margin-top: 2.5rem; align-items: start;
}
.layer-diagram { width: 100%; height: auto; }
.d-label {
  font-family: var(--sans); font-size: 11.5px; font-weight: 600;
  text-anchor: middle; letter-spacing: 0.04em;
}
.d-dark { fill: var(--navy); }
.d-light { fill: var(--ivory); }
.d-sub { font-weight: 400; font-size: 9.5px; fill: rgba(242, 233, 216, 0.7); }

.origin-line {
  font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--gold); text-align: center; margin: 1.2rem 0 1.4rem;
}
.badge-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.badge {
  font-size: 0.7rem; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  border: 1px solid rgba(242, 233, 216, 0.5); color: var(--ivory);
  padding: 7px 14px;
}
.section-ivory .badge { border-color: var(--navy); color: var(--navy); }

.model-card {
  background: var(--navy-2);
  border: 1px solid rgba(242, 233, 216, 0.2);
  padding: 34px;
}
.model-eyebrow { font-size: 0.68rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold); margin-bottom: 0.4rem; }
.model-name { font-size: 1.9rem; color: var(--ivory); }
.model-desc { font-size: 0.92rem; color: rgba(242, 233, 216, 0.85); margin: 0.8rem 0 1.5rem; }

.meter { margin-bottom: 14px; }
.meter-label {
  display: flex; justify-content: space-between;
  font-size: 0.68rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--ivory); margin-bottom: 5px;
}
.meter-track { height: 6px; background: rgba(242, 233, 216, 0.15); }
.meter-fill { height: 100%; background: var(--gold); width: 0; transition: width 1s ease; }

.model-list { list-style: none; margin-top: 1.4rem; }
.model-list li {
  font-size: 0.88rem; color: rgba(242, 233, 216, 0.9);
  padding: 8px 0 8px 24px; position: relative;
  border-top: 1px solid rgba(242, 233, 216, 0.15);
}
.model-list li::before { content: "★"; position: absolute; left: 0; color: var(--gold); font-size: 0.7rem; top: 11px; }

.onlyus { margin-top: 30px; border-left: 2px solid var(--gold); padding-left: 22px; }
.onlyus-title {
  font-family: var(--serif); font-size: 1.3rem; font-weight: 600; color: var(--ivory); margin-bottom: 0.6rem;
}
.onlyus ul { list-style: none; }
.onlyus li { font-size: 0.9rem; color: rgba(242, 233, 216, 0.9); padding: 5px 0; }

.flag-strip { margin-top: 40px; }

/* ---------- stores ---------- */
#stores h2 { text-align: center; }
#stores .eyebrow { text-align: center; }
.stores-sub { max-width: 520px; margin: 0 auto 2.5rem; text-align: center; }
.store-strip {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
}
.store-card {
  display: block; text-decoration: none;
  border: 1px solid rgba(11, 29, 51, 0.35); padding: 18px 16px;
  color: var(--ink); background: #FBF6EA;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.store-card:hover { background: var(--navy); color: var(--ivory); border-color: var(--navy); }
.store-card .store-name { font-weight: 700; font-size: 0.85rem; letter-spacing: 0.04em; }
.store-card .store-addr { font-size: 0.75rem; opacity: 0.75; margin-top: 3px; }
.stores-link { text-align: center; margin-top: 2rem; font-size: 0.9rem; }
.stores-link a { color: var(--crimson); font-weight: 600; }

/* ---------- waitlist ---------- */
.section-waitlist { text-align: center; }
.waitlist-logo { width: min(210px, 55vw); height: auto; margin: 0 auto 30px; }
.waitlist-sub { max-width: 480px; margin: 0 auto 2.2rem; color: rgba(242, 233, 216, 0.88); }
.waitlist-form { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.waitlist-form input {
  font-family: var(--sans); padding: 15px 18px; font-size: 0.95rem;
  border: 1px solid rgba(242, 233, 216, 0.5); background: transparent; color: var(--ivory);
  min-width: 260px;
}
.waitlist-form input::placeholder { color: rgba(242, 233, 216, 0.5); }
.waitlist-done { margin-top: 1.5rem; color: var(--gold); font-weight: 600; }
.waitlist-done.waitlist-error { color: var(--crimson); }

/* ---------- faq ---------- */
.faq-list details {
  border-bottom: 1px solid rgba(11, 29, 51, 0.2);
  padding: 6px 0;
}
.faq-list summary {
  font-family: var(--serif); font-size: 1.25rem; font-weight: 600;
  cursor: pointer; padding: 14px 0; color: var(--navy); list-style: none;
  display: flex; justify-content: space-between; align-items: center;
}
.faq-list summary::after { content: "+"; color: var(--crimson); font-size: 1.5rem; font-family: var(--sans); }
.faq-list details[open] summary::after { content: "\00d7"; }
.faq-list details p { padding: 0 0 18px; font-size: 0.93rem; max-width: 640px; }

/* ---------- footer ---------- */
.footer {
  background: var(--navy); text-align: center; padding: 64px 24px 48px;
}
.footer-logo { height: 54px; width: auto; margin: 0 auto 20px; }
.footer-line { font-family: var(--serif); font-size: 1.2rem; color: var(--ivory); font-style: italic; margin-bottom: 1.2rem; }
.footer-fine { font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(242, 233, 216, 0.55); }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .meter-fill { transition: none; }
}

/* ---------- mobile ---------- */
@media (max-width: 760px) {
  .section { padding: 64px 0; }
  .built-grid { grid-template-columns: 1fr; gap: 40px; }
  .founder-card { grid-template-columns: 1fr; }
  .founder-photo-img { max-width: 280px; margin: 0 auto; }
  .oath-card { padding: 40px 22px; }
  .hero { padding: 48px 20px 64px; }
  .topbar-logo { height: 36px; }
}
