/* ═══════════════════════════════════════════════════════════
   LingoEye landing — static product story
   Brand: temple gold #C9A84C · dark surfaces · metallic gold
   Mobile-first; open space over card grids
   ═══════════════════════════════════════════════════════════ */

:root {
  --gold: #c9a84c;
  --gold-light: #f2e3c6;
  --gold-pale: #fff9e6;
  --gold-mid: #d4af37;
  --gold-deep: #7a6640;
  --bg: #0a0908;
  --bg-elevated: #100e0b;
  --surface-quiet: #16130f;
  --text: #f5f0e8;
  --text-secondary: #c4bbb0;
  --text-hint: rgba(245, 240, 232, 0.55);
  --border-gold: rgba(201, 168, 76, 0.4);
  --border-hair: rgba(201, 168, 76, 0.18);
  --radius-phone: 22px;
  --radius-pill: 999px;
  --shadow-soft: 0 16px 48px rgba(0, 0, 0, 0.5);
  --wrap: min(1120px, calc(100% - 2rem));
  --measure: 38rem;
  --header-h: 64px;
  --section-y: clamp(3.25rem, 7vw, 5.5rem);
  --gold-gradient: linear-gradient(
    135deg,
    #f2e3c6 0%,
    #c9a84c 22%,
    #fff9e6 40%,
    #d4af37 58%,
    #7a6640 78%,
    #f2e3c6 100%
  );
  /* System stack + Khmer-capable fallbacks (no external font deps) */
  --font-body: system-ui, -apple-system, "Segoe UI", "Leelawadee UI",
    "Noto Sans Khmer", "Khmer UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: system-ui, -apple-system, "Segoe UI", "Helvetica Neue",
    Arial, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 1.02rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--gold-light);
  text-decoration: none;
}

a:hover {
  color: var(--gold-pale);
  text-decoration: underline;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--gold);
  color: #111;
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 0.5rem;
  top: 0.5rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: var(--wrap);
  margin-inline: auto;
}

/* ── Header ──────────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 9, 8, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-hair);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand:hover {
  text-decoration: none;
  color: var(--gold-light);
}

.brand-logo {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.brand-name {
  font-family: var(--font-display);
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 1.12rem;
  letter-spacing: 0.04em;
}

.header-nav {
  display: none;
  gap: 1.4rem;
  font-size: 0.88rem;
  letter-spacing: 0.02em;
}

.header-nav a {
  color: var(--text-secondary);
  text-decoration: none;
}

.header-nav a:hover {
  color: var(--gold-light);
}

/* ── Buttons ─────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: var(--radius-pill);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease),
    filter 0.15s var(--ease);
  white-space: nowrap;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
  filter: brightness(1.05);
}

.btn-gold {
  background: var(--gold-gradient);
  color: #1a1408;
  box-shadow: 0 4px 22px rgba(201, 168, 76, 0.32);
}

.btn-gold:hover {
  color: #1a1408;
}

.btn-lg {
  padding: 0.95rem 1.7rem;
  font-size: 1.02rem;
}

.btn-sm {
  padding: 0.48rem 1rem;
  font-size: 0.82rem;
}

/* ── Shared section chrome ───────────────────────────────── */

.section {
  padding: var(--section-y) 0;
}

.section-title {
  margin: 0 0 0.75rem;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4.8vw, 2.45rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 700;
  max-width: 18ch;
}

.section-lead {
  margin: 0;
  color: var(--text-secondary);
  max-width: var(--measure);
  font-size: 1.06rem;
  line-height: 1.65;
}

.gold-text {
  display: block;
  margin-top: 0.35rem;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  font-family: var(--font-display);
  color: var(--gold);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 1rem;
}

.lede {
  color: var(--text-secondary);
  font-size: 1.08rem;
  max-width: 34rem;
  line-height: 1.65;
}

.fine-print {
  color: var(--text-hint);
  font-size: 0.84rem;
  margin: 0.75rem 0 0;
  letter-spacing: 0.01em;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}

/* ── Phone frame ─────────────────────────────────────────── */

.phone-frame {
  position: relative;
  width: min(100%, 280px);
  margin-inline: auto;
  border-radius: var(--radius-phone);
  padding: 3px;
  border: 2px solid transparent;
  background-image: linear-gradient(#0a0908, #0a0908), var(--gold-gradient);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  box-shadow: var(--shadow-soft);
}

.phone-frame-mode {
  width: min(100%, 240px);
  flex-shrink: 0;
}

.phone-screen {
  width: 100%;
  border-radius: 18px;
  aspect-ratio: auto;
  object-fit: contain;
  background: #000;
  display: block;
}

/* ── Hero ────────────────────────────────────────────────── */

.hero {
  padding-top: clamp(1.75rem, 4vw, 2.75rem);
  padding-bottom: var(--section-y);
  background:
    radial-gradient(ellipse 85% 55% at 50% -12%, rgba(201, 168, 76, 0.16), transparent 58%),
    var(--bg);
}

.hero-grid {
  display: grid;
  gap: 2.75rem;
  align-items: center;
}

.hero h1 {
  margin: 0 0 1.15rem;
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 5.8vw, 2.85rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
  font-weight: 750;
  max-width: 16ch;
}

.hero-cta {
  margin-top: 1.85rem;
}

.hero-media .phone-frame {
  width: min(100%, 300px);
}

/* ── Phone screenshot carousel (progressive enhancement) ─── */

.phone-carousel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  width: 100%;
}

.phone-carousel-frame {
  width: min(100%, 300px);
}

.phone-carousel-viewport {
  position: relative;
  width: 100%;
  /* First slide defines height; absolute siblings share it with JS on */
  overflow: hidden;
  border-radius: 18px;
  background: #000;
}

.phone-carousel-slide {
  margin: 0;
  width: 100%;
}

.phone-carousel-slide[hidden] {
  display: none;
}

.phone-carousel-slide.is-active {
  display: block;
}

.phone-carousel-slide .phone-screen {
  width: 100%;
  border-radius: 18px;
}

.phone-carousel-caption {
  margin: 0;
  max-width: 22rem;
  text-align: center;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--text-secondary);
  min-height: 2.6em;
}

.phone-carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
}

.phone-carousel-controls[hidden] {
  display: none;
}

.phone-carousel-btn {
  appearance: none;
  border: 1px solid var(--border-gold);
  background: var(--surface-quiet);
  color: var(--gold-light);
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 50%;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 0 0.1rem;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
}

.phone-carousel-btn:hover {
  border-color: var(--gold);
  background: #1c1812;
}

.phone-carousel-btn:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.phone-carousel-dots {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.phone-carousel-dot {
  appearance: none;
  border: 0;
  padding: 0;
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 50%;
  background: rgba(201, 168, 76, 0.28);
  cursor: pointer;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}

.phone-carousel-dot[aria-selected="true"] {
  background: var(--gold);
  transform: scale(1.2);
}

.phone-carousel-dot:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* ── Story: awkward five seconds ─────────────────────────── */

.story {
  border-block: 1px solid var(--border-hair);
  background: var(--bg-elevated);
}

/* Uses shared .wrap gutters/padding like every other section.
   Reading measure lives on the prose/title, not a second column width. */
.story-wrap .section-title,
.story-wrap .story-prose,
.story-wrap .story-close {
  max-width: 36rem;
}

.story-title {
  margin-bottom: 1.75rem;
}

.story-prose {
  display: grid;
  gap: 0.35rem;
  margin: 0 0 2rem;
  padding-left: 1.1rem;
  border-left: 2px solid rgba(201, 168, 76, 0.45);
}

.story-prose p {
  margin: 0;
  font-size: clamp(1.15rem, 2.8vw, 1.35rem);
  line-height: 1.55;
  color: var(--text-secondary);
  font-weight: 450;
  letter-spacing: -0.01em;
}

.story-prose .story-beat {
  color: var(--gold-light);
  font-weight: 650;
  margin: 0.55rem 0;
  letter-spacing: 0.04em;
}

.story-close {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, 2.4vw, 1.2rem);
  line-height: 1.5;
  color: var(--text);
  font-weight: 600;
  max-width: 32rem;
  letter-spacing: -0.015em;
}

/* ── Market scenario + rhythm ────────────────────────────── */

.market-intro {
  margin-bottom: 2.5rem;
  max-width: 40rem;
}

.market-layout {
  display: grid;
  gap: 2.75rem;
  align-items: start;
}

.market-scene {
  padding-top: 0.25rem;
}

.market-scene-label {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
}

.need-list {
  list-style: none;
  margin: 0 0 1.25rem;
  padding: 0;
  display: grid;
  gap: 0;
}

.need-list li {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 3vw, 1.45rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.35;
  color: var(--gold-pale);
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--border-hair);
}

.need-list li:first-child {
  border-top: 1px solid var(--border-hair);
}

.market-note {
  margin: 0;
  color: var(--text-hint);
  font-size: 0.95rem;
  max-width: 28rem;
  line-height: 1.55;
}

.rhythm {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0;
  border-top: 1px solid var(--border-hair);
}

.rhythm-step {
  display: grid;
  grid-template-columns: 3.25rem 1fr;
  gap: 0.85rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--border-hair);
}

.rhythm-num {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--gold);
  padding-top: 0.2rem;
}

.rhythm-title {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--gold-light);
}

.rhythm-body p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.98rem;
  max-width: 28rem;
}

/* ── Modes showcase (static; future switcher-ready) ─────── */

.modes {
  background: var(--bg-elevated);
  border-block: 1px solid var(--border-hair);
}

.modes-intro {
  margin-bottom: 2.5rem;
  max-width: 40rem;
}

.mode-list {
  display: grid;
  gap: 3rem;
}

.mode-panel {
  display: grid;
  gap: 1.5rem;
  align-items: center;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid var(--border-hair);
}

.mode-panel:last-child {
  padding-bottom: 0;
  border-bottom: none;
}

.mode-kicker {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-deep);
}

.mode-name {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3.5vw, 1.9rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--text);
}

.mode-tagline {
  margin: 0 0 0.85rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--gold-light);
  letter-spacing: -0.01em;
}

.mode-desc {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.98rem;
  max-width: 32rem;
  line-height: 1.6;
}

/* Pair of phones (e.g. Quick Translate type UI + Sayings) */
.mode-media {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
  align-items: center;
}

/* ── Result: one object → language ───────────────────────── */

.result-grid {
  display: grid;
  gap: 2.75rem;
  align-items: center;
}

.result-copy .section-title {
  max-width: 14ch;
}

.result-points {
  list-style: none;
  margin: 1.75rem 0 0;
  padding: 0;
  display: grid;
  gap: 0;
  max-width: 28rem;
}

.result-points li {
  display: grid;
  gap: 0.15rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border-hair);
}

.result-points li:first-child {
  border-top: 1px solid var(--border-hair);
}

.result-points strong {
  font-family: var(--font-display);
  color: var(--gold-light);
  font-size: 0.98rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.result-points span {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.result-media {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  align-items: center;
}

/* ── Trust strip (pricing + privacy, compact) ────────────── */

.trust {
  padding: 0 0 var(--section-y);
}

.trust-strip {
  list-style: none;
  margin: 0;
  padding: 1.35rem 0;
  display: grid;
  gap: 1.25rem;
  border-block: 1px solid var(--border-gold);
}

.trust-strip li {
  display: grid;
  gap: 0.2rem;
}

.trust-label {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--gold-light);
}

.trust-detail {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.45;
}

/* Quiet first-person note — not a founder/about section */
.quiet-note {
  margin: 1.75rem auto 0;
  max-width: 36rem;
  text-align: center;
  color: var(--text-hint);
  font-size: 0.95rem;
  line-height: 1.65;
  font-style: italic;
}

/* ── Final CTA / access ──────────────────────────────────── */

.access {
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(201, 168, 76, 0.12), transparent 55%),
    var(--bg);
  padding-bottom: clamp(4rem, 8vw, 6rem);
}

.access-block {
  max-width: 36rem;
  margin-inline: auto;
  text-align: center;
}

.access-block .eyebrow {
  text-align: center;
}

.access-title {
  max-width: 16ch;
  margin-inline: auto;
  margin-bottom: 1rem;
}

.access-lead {
  margin-inline: auto;
  margin-bottom: 1.5rem;
}

.access-facts {
  text-align: left;
  margin: 0 auto 1rem;
  max-width: 28rem;
  padding-left: 1.15rem;
  color: var(--text-secondary);
}

.access-facts li {
  margin-bottom: 0.45rem;
}

.access-facts strong {
  color: var(--gold-light);
}

.access-note {
  margin-bottom: 1.5rem;
}

.access-block .btn {
  margin-top: 0.25rem;
}

/* Ensure HTML hidden attribute is respected if any CTA is toggled later */
[hidden] {
  display: none !important;
}

/* ── Footer ──────────────────────────────────────────────── */

.site-footer {
  padding: 3rem 0 2.5rem;
  border-top: 1px solid var(--border-hair);
  background: #070605;
}

.footer-inner {
  display: grid;
  gap: 2rem;
}

.footer-brand {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
}

.footer-brand p {
  margin: 0.35rem 0 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
  max-width: 28rem;
}

.footer-heading {
  margin: 0 0 0.65rem;
  font-family: var(--font-display);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gold);
}

.footer-notes ul {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.footer-notes li {
  margin-bottom: 0.4rem;
}

.footer-meta {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 1.25rem;
}

.footer-meta p {
  margin: 0 0 0.4rem;
}

/* ── Khmer glyph safety (in text nodes if ever present) ──── */

:lang(km),
.km,
[lang="km"] {
  font-family: "Leelawadee UI", "Noto Sans Khmer", "Khmer UI", "Segoe UI",
    system-ui, sans-serif;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

/* ── Desktop ─────────────────────────────────────────────── */

@media (min-width: 720px) {
  .header-nav {
    display: flex;
  }

  .hero-grid {
    grid-template-columns: 1.15fr 0.85fr;
    gap: 3.5rem;
  }

  .hero h1 {
    max-width: 14ch;
  }

  .market-layout {
    grid-template-columns: 1fr 1fr;
    gap: 3.5rem;
    align-items: start;
  }

  .mode-panel {
    grid-template-columns: 1.15fr 0.85fr;
    gap: 2.5rem;
    padding-bottom: 3rem;
  }

  .mode-panel:nth-child(even) {
    direction: rtl;
  }

  .mode-panel:nth-child(even) > * {
    direction: ltr;
  }

  .mode-panel .phone-frame,
  .mode-panel .mode-media {
    justify-self: end;
  }

  .mode-panel:nth-child(even) .phone-frame,
  .mode-panel:nth-child(even) .mode-media {
    justify-self: start;
  }

  .mode-media {
    flex-direction: row;
    justify-content: center;
    align-items: flex-start;
  }

  .mode-media .phone-frame-mode {
    width: min(100%, 200px);
  }

  .result-grid {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }

  .result-media {
    flex-direction: row;
    justify-content: center;
    align-items: flex-start;
  }

  .phone-frame-offset {
    margin-top: 2.75rem;
    margin-left: -1.25rem;
  }

  .trust-strip {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem 2rem;
    padding: 1.75rem 0;
  }

  .footer-inner {
    grid-template-columns: 1.2fr 1.4fr;
  }

  .footer-meta {
    grid-column: 1 / -1;
  }
}

@media (min-width: 960px) {
  .hero-media .phone-frame,
  .phone-carousel-frame {
    width: 320px;
  }

  .result-media .phone-frame {
    width: 240px;
  }

  .mode-panel .phone-frame {
    width: 250px;
  }
}

/* ── Reduced motion ──────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn,
  .phone-carousel-btn,
  .phone-carousel-dot {
    transition: none;
  }
}
