/* Thalas — austere, perfume-house, Northern-European cold. (spec §4) */

:root {
  --ink:    #1a2632;
  --sea:    #2d4a5a;
  --mist:   #7c97a3;
  --bone:   #f4f1ea;
  --paper:  #fbfaf6;
  --line:   #c9cdc8;
  --salt:   #e8e3d6;
  --accent: #3a6b7e;

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans:  "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;

  --maxw: 1140px;
  --gutter: clamp(1.25rem, 5vw, 4rem);
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 400;
  color: var(--ink);
  background-color: var(--paper);
  line-height: 1.6;
  /* Faint coordinate-grid pattern (spec §4) — almost invisible */
  background-image:
    linear-gradient(to right,  rgba(124,151,163,0.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(124,151,163,0.06) 1px, transparent 1px);
  background-size: 64px 64px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

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

a { color: var(--sea); text-decoration: none; }
a:hover { color: var(--accent); text-decoration: underline; }

/* --- Layout helpers --- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.narrow { max-width: 720px; }
.center { text-align: center; }
.section { padding-block: clamp(3.5rem, 9vw, 7rem); }

.visually-hidden, .skip-link:not(:focus) {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: 1rem; z-index: 100;
  background: var(--ink); color: var(--paper); padding: 0.6rem 1rem; border-radius: 2px;
}

/* --- Type --- */
.eyebrow, .label, .nav-status, .coord-motif, .zip-label, .deposit-or {
  font-family: var(--sans);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--mist);
}
.label { display: block; margin-bottom: 1.25rem; }
.label.center { text-align: center; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.1; margin: 0; }

.hero-headline {
  font-size: clamp(2.75rem, 8vw, 5rem);
  font-weight: 500; letter-spacing: 0.01em; margin: 0.5rem 0 1.25rem;
}
.final-heading { font-size: clamp(2.25rem, 6vw, 3.5rem); margin-bottom: 1rem; }

/* --- Nav --- */
.site-nav { border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; justify-content: space-between; padding-block: 1.25rem; }
.wordmark, .footer-mark {
  font-family: var(--serif); font-size: 1.5rem; letter-spacing: 0.35em;
  text-transform: uppercase; color: var(--ink);
}

/* --- Hero --- */
.hero { padding-block: clamp(2.5rem, 7vw, 5.5rem); position: relative; }

/* Scroll affordance — subtle, signals the page continues below the fold */
.scroll-cue { display: none; }
@media (min-width: 880px) {
  .scroll-cue {
    display: inline-flex; flex-direction: column; align-items: center; gap: 0.35rem;
    position: absolute; left: 50%; bottom: 1.5rem; transform: translateX(-50%);
    color: var(--mist); text-decoration: none;
  }
  .scroll-cue:hover { color: var(--sea); text-decoration: none; }
}
.scroll-cue-label { font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.22em; }
.scroll-cue svg { animation: scroll-nudge 1.9s ease-in-out infinite; }
@keyframes scroll-nudge { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(5px); } }
@media (prefers-reduced-motion: reduce) { .scroll-cue svg { animation: none; } }
.hero-grid { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
.hero-subhead { font-size: 1.12rem; color: var(--sea); max-width: 42ch; }
.hero-price-note { margin-top: 1.25rem; font-size: 0.85rem; color: var(--mist); letter-spacing: 0.08em; }
.hero-figure { margin: 0; }
.hero-figure img { border-radius: 2px; box-shadow: 0 18px 60px rgba(26,38,50,0.18); margin-inline: auto; }
.coord-motif { margin-top: 0.9rem; text-align: center; }

@media (min-width: 880px) {
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; }
  /* ~80vh (not 100) so the next section peeks above the fold = obviously scrollable */
  .hero { min-height: 80vh; display: flex; align-items: center; padding-bottom: 4.5rem; }
}

/* --- The gap --- */
.gap { background: var(--bone); border-block: 1px solid var(--line); }
.gap-body { font-family: var(--serif); font-size: clamp(1.6rem, 4vw, 2.4rem); line-height: 1.3; color: var(--ink); }
.gap-grid { display: grid; gap: clamp(1.75rem, 5vw, 3.5rem); align-items: center; }
.gap-figure { margin: 0; }
.gap-figure img { border-radius: 2px; margin-inline: auto; max-width: 360px; }
@media (min-width: 760px) { .gap-grid { grid-template-columns: 0.8fr 1.2fr; } }

/* --- Pillars --- */
.pillar-grid { display: grid; gap: clamp(1.75rem, 4vw, 3rem); grid-template-columns: 1fr; }
@media (min-width: 620px) { .pillar-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 960px) { .pillar-grid { grid-template-columns: repeat(4, 1fr); } }
.pillar-icon { color: var(--accent); display: inline-flex; }
.pillar-name { font-size: 1.5rem; margin: 0.85rem 0 0.5rem; }
.pillar-body { color: var(--sea); font-size: 0.97rem; }

/* --- Origin --- */
.origin { background: var(--ink); color: var(--bone); }
.origin .label { color: var(--mist); }
.origin-grid { display: grid; gap: clamp(2rem, 5vw, 4rem); align-items: center; }
@media (min-width: 880px) { .origin-grid { grid-template-columns: 0.9fr 1.1fr; } }
.origin-para { color: #cdd6db; font-size: 1.05rem; }
.origin-closer { font-family: var(--serif); font-size: 1.5rem; color: var(--bone); margin-top: 1.5rem; }
.origin-figure { margin: 0; }
.origin-figure img { border-radius: 2px; box-shadow: 0 14px 50px rgba(0,0,0,0.35); }
.origin .coord-motif { color: var(--mist); margin-top: 0.75rem; }
.provenance-figure { margin: 2.25rem 0 0; }
.provenance-figure img { border-radius: 2px; border: 1px solid rgba(124,151,163,0.25); }

/* --- How to use (unisex two-up) --- */
.how-figures { display: grid; gap: clamp(1rem, 3vw, 2rem); margin-top: clamp(2rem, 5vw, 3rem); grid-template-columns: 1fr; }
@media (min-width: 620px) { .how-figures { grid-template-columns: 1fr 1fr; } }
.how-figures figure { margin: 0; }
.how-figures img { width: 100%; border-radius: 2px; object-fit: cover; }

/* --- Final CTA figure --- */
.final-figure { margin: 0 auto 2.5rem; max-width: 640px; }
.final-figure img { width: 100%; border-radius: 2px; box-shadow: 0 14px 50px rgba(26,38,50,0.18); }

/* --- How to use --- */
.how-body { font-size: 1.15rem; color: var(--sea); }

/* --- FAQ --- */
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item summary {
  cursor: pointer; list-style: none; padding: 1.25rem 0;
  font-family: var(--serif); font-size: 1.4rem; color: var(--ink);
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: var(--mist); font-family: var(--sans); font-weight: 300; }
.faq-item[open] summary::after { content: "–"; }
.faq-item p { margin: 0 0 1.4rem; color: var(--sea); max-width: 60ch; }

/* --- Final CTA --- */
.final-cta { background: var(--bone); border-top: 1px solid var(--line); }
.final-sub { color: var(--sea); max-width: 46ch; margin-inline: auto; margin-bottom: 2rem; }

/* --- Forms --- */
.waitlist-form { margin-top: 2rem; display: flex; gap: 0.6rem; flex-wrap: wrap; max-width: 480px; }
.waitlist-form.stacked { flex-direction: column; margin-inline: auto; align-items: stretch; }
.final-cta .waitlist-form { margin-inline: auto; }

.waitlist-form input[type="email"],
.waitlist-form input[type="text"] {
  flex: 1 1 240px; min-width: 0;
  font-family: var(--sans); font-size: 1rem;
  padding: 0.85rem 1rem; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line); border-radius: 2px;
}
/* In the stacked (final) form the column layout turns flex-basis into HEIGHT,
   which made inputs too tall — size them to their content instead. */
.waitlist-form.stacked input[type="email"],
.waitlist-form.stacked input[type="text"] { flex: 0 0 auto; }
.waitlist-form input::placeholder { color: var(--mist); }
.waitlist-form input:focus-visible,
.waitlist-form button:focus-visible,
a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}

.waitlist-form button {
  font-family: var(--sans); font-weight: 500; font-size: 0.82rem;
  text-transform: uppercase; letter-spacing: 0.16em;
  padding: 0.9rem 1.6rem; cursor: pointer;
  color: var(--paper); background: var(--ink);
  border: 1px solid var(--ink); border-radius: 2px;
  transition: background-color 0.2s ease;
}
.waitlist-form button:hover { background: var(--sea); border-color: var(--sea); }
.waitlist-form button:disabled { opacity: 0.5; cursor: progress; }

.zip-label { margin-top: 0.5rem; }
.hp-field { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }

.form-fineprint { flex-basis: 100%; margin: 0.6rem 0 0; font-size: 0.78rem; color: var(--mist); letter-spacing: 0.02em; }
.form-fineprint a { color: var(--sea); text-decoration: underline; }
.form-fineprint a:hover { color: var(--accent); }
.form-message { flex-basis: 100%; margin: 0.4rem 0 0; font-size: 0.9rem; min-height: 1.2em; }
.form-message.is-error { color: #8a3b3b; }
.form-success { font-family: var(--serif); font-size: 1.5rem; color: var(--accent); margin: 2rem 0 0; }

/* --- Deposit (§7) --- */
.deposit-block { margin-top: 2.25rem; }
.deposit-or { margin: 0 0 0.75rem; }
.deposit-button {
  font-family: var(--sans); font-weight: 500; font-size: 0.82rem;
  text-transform: uppercase; letter-spacing: 0.14em;
  padding: 0.9rem 1.6rem; cursor: pointer; color: var(--ink);
  background: transparent; border: 1px solid var(--ink); border-radius: 2px;
}
.deposit-button:hover { background: var(--ink); color: var(--paper); }
.deposit-disclosure { margin-top: 0.9rem; font-size: 0.85rem; color: var(--mist); max-width: 44ch; margin-inline: auto; }

/* --- Image placeholders (clearly marked, spec §4) --- */
.img-placeholder {
  width: 100%; display: flex; align-items: center; justify-content: center;
  background: repeating-linear-gradient(45deg, var(--salt), var(--salt) 12px, var(--bone) 12px, var(--bone) 24px);
  border: 1px dashed var(--mist); border-radius: 2px;
  color: var(--sea); font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 2rem; text-align: center;
}

/* --- Footer --- */
.site-footer { background: var(--ink); color: var(--mist); padding-block: clamp(2.5rem, 6vw, 4rem); }
.footer-mark { color: var(--bone); margin-bottom: 1rem; }
.footer-note { color: var(--bone); font-size: 1.05rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.5rem; margin: 1.25rem 0; }
.footer-links a { color: var(--mist); font-size: 0.85rem; letter-spacing: 0.06em; }
.footer-links a:hover { color: var(--bone); }
.footer-privacy-note, .footer-year { font-size: 0.78rem; color: var(--mist); opacity: 0.8; }
.footer-greek { font-family: var(--serif); font-style: italic; color: var(--mist); margin-top: 1.5rem; letter-spacing: 0.05em; }

/* --- Simple content pages (privacy/terms/insights) --- */
.doc { max-width: 720px; }
.doc h1 { font-size: clamp(2rem, 5vw, 3rem); margin-bottom: 1.5rem; }
.doc h2 { font-family: var(--serif); font-size: 1.5rem; margin: 2rem 0 0.5rem; }
.doc p, .doc li { color: var(--sea); }
.doc .flag { background: var(--salt); border-left: 3px solid var(--accent); padding: 0.85rem 1rem; font-size: 0.9rem; }
.doc .back { display: inline-block; margin-top: 2.5rem; }

/* --- Insights dashboard --- */
.stat-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); margin: 1.5rem 0 2.5rem; }
.stat { border: 1px solid var(--line); border-radius: 2px; padding: 1.25rem; background: var(--paper); }
.stat .n { font-family: var(--serif); font-size: 2.25rem; color: var(--ink); }
.stat .k { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.16em; color: var(--mist); }
table.data { width: 100%; border-collapse: collapse; font-size: 0.92rem; }
table.data th, table.data td { text-align: left; padding: 0.6rem 0.75rem; border-bottom: 1px solid var(--line); }
table.data th { color: var(--mist); text-transform: uppercase; letter-spacing: 0.1em; font-size: 0.72rem; font-weight: 500; }
