/* ─────────────────────────────────────────
   Chion · /app — product landing page
   Brand system + product showcase aesthetic
   ───────────────────────────────────────── */

:root {
  --chion-black: #0A0A0A;
  --chion-white: #FAFAFA;
  --chion-blue: #2D5BFF;
  --chion-mint: #4ADE80;
  --term-red: #FF6B6B;
  --term-yellow: #FFB800;

  --gray-100: #E4E4E7;
  --gray-200: #D4D4D8;
  --gray-300: #A1A1AA;
  --gray-500: #71717A;
  --gray-600: #52525B;
  --gray-700: #3F3F46;
  --gray-800: #27272A;
  --gray-900: #18181B;

  --accent: var(--chion-blue);

  --font-en: 'Geist', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-cn: 'PingFang SC', 'Source Han Sans CN', 'Microsoft YaHei', sans-serif;
  --font-mono: 'Geist Mono', 'JetBrains Mono', 'SF Mono', 'Menlo', monospace;

  --container: 1200px;
  --gutter: 2rem;
  --section-y: 7rem;
}

/* Theme tokens */
:root[data-theme="dark"] {
  --bg: var(--chion-black);
  --fg: var(--chion-white);
  --fg-muted: var(--gray-500);
  --fg-dim: var(--gray-700);
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --grid-dot: rgba(255, 255, 255, 0.04);
  --bg-card: rgba(255, 255, 255, 0.025);
  --bg-elevated: rgba(255, 255, 255, 0.04);
  --bg-input: rgba(255, 255, 255, 0.04);
  --nav-bg: rgba(10, 10, 10, 0.75);
  --footer-bg: rgba(0, 0, 0, 0.3);
}

:root[data-theme="light"] {
  --bg: var(--chion-white);
  --fg: var(--chion-black);
  --fg-muted: var(--gray-500);
  --fg-dim: var(--gray-300);
  --line: rgba(0, 0, 0, 0.08);
  --line-strong: rgba(0, 0, 0, 0.16);
  --grid-dot: rgba(0, 0, 0, 0.05);
  --bg-card: rgba(0, 0, 0, 0.015);
  --bg-elevated: rgba(0, 0, 0, 0.03);
  --bg-input: rgba(0, 0, 0, 0.03);
  --nav-bg: rgba(250, 250, 250, 0.85);
  --footer-bg: rgba(255, 255, 255, 0.5);
}

/* Language visibility */
:root[data-lang="en"] [lang="zh"] { display: none !important; }
:root[data-lang="zh"] [lang="en"] { display: none !important; }
:root[data-lang="zh"] body { font-family: var(--font-cn); }

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-en);
  font-feature-settings: 'ss01', 'ss03';
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  position: relative;
}

a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; background: none; border: none; cursor: pointer; }

/* ─── Background ─── */
.bg-grid {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image: radial-gradient(circle, var(--grid-dot) 1px, transparent 1.2px);
  background-size: 32px 32px;
}

.bg-gradient {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 60% 50% at 30% 0%, rgba(45, 91, 255, 0.20), transparent 60%),
    radial-gradient(ellipse 50% 40% at 70% 50%, rgba(45, 91, 255, 0.10), transparent 60%);
  animation: gradient-drift 24s ease-in-out infinite alternate;
}

@keyframes gradient-drift {
  0%   { transform: translate(0, 0)    scale(1); }
  50%  { transform: translate(2%, -1%) scale(1.05); }
  100% { transform: translate(-2%, 1%) scale(0.98); }
}

.nav, .hero, .section, .footer { position: relative; z-index: 1; }

/* ─── Nav ─── */
.nav {
  position: sticky; top: 0; z-index: 100;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 3rem;
  padding: 1rem var(--gutter);
  background: var(--nav-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}

.nav-brand {
  display: flex; align-items: baseline; gap: 0.5rem;
  font-weight: 500;
}

.nav-brand-en {
  font-size: 1.05rem; letter-spacing: -0.02em; color: var(--fg);
}

.nav-brand-cn {
  font-family: var(--font-cn);
  font-size: 0.9rem; font-weight: 300;
  letter-spacing: 0.2em; color: var(--fg-muted);
}

.nav-links {
  display: flex; justify-content: center; gap: 2rem;
}

.nav-link {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

:root[data-lang="zh"] .nav-link {
  font-family: var(--font-cn);
  font-size: 0.85rem;
  letter-spacing: 0.15em;
  text-transform: none;
}

.nav-link:hover { color: var(--fg); }

/* Cross-domain link variant */
.nav-divider {
  width: 1px;
  height: 14px;
  background: var(--line-strong);
  margin: 0 0.25rem;
  display: inline-block;
  align-self: center;
}

.nav-link-ext {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.ext-arrow {
  font-size: 0.85em;
  color: var(--fg-dim);
  transition: transform 0.2s ease, color 0.2s ease;
  display: inline-block;
}

.nav-link-ext:hover .ext-arrow {
  color: var(--accent);
  transform: translate(2px, -2px);
}

.nav-actions {
  display: flex; align-items: center; gap: 0.5rem;
}

/* ─── Toggles ─── */
.nav-toggles {
  display: flex; align-items: center; gap: 0.4rem;
  margin-left: 0.5rem;
  padding-left: 0.75rem;
  border-left: 1px solid var(--line);
}

.toggle-btn {
  width: 34px; height: 34px;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--fg-muted);
  cursor: pointer;
  transition: all 0.2s ease;
}

.toggle-btn:hover {
  color: var(--fg);
  border-color: var(--line-strong);
  background: var(--bg-elevated);
}

.toggle-text {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
}

.toggle-icon { display: block; }

.toggle-show-when-en, .toggle-show-when-zh,
.toggle-show-when-dark, .toggle-show-when-light {
  display: none;
}

:root[data-lang="en"] .toggle-show-when-en { display: inline; }
:root[data-lang="zh"] .toggle-show-when-zh { display: inline; }
:root[data-theme="dark"] .toggle-show-when-dark { display: block; }
:root[data-theme="light"] .toggle-show-when-light { display: block; }

.nav-action {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.5rem 0.9rem;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 6px;
  transition: all 0.2s ease;
}

.nav-action-ghost {
  color: var(--fg-muted);
}
.nav-action-ghost:hover { color: var(--fg); }

.nav-action-primary {
  background: var(--fg);
  color: var(--bg);
}

.nav-action-primary:hover {
  background: var(--accent);
  color: var(--chion-white);
}

.nav-action .arrow { transition: transform 0.2s ease; }
.nav-action:hover .arrow { transform: translateX(2px); }

/* ─── Hero ─── */
.hero {
  max-width: var(--container);
  margin: 0 auto;
  padding: 5rem var(--gutter) 4rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--fg-muted);
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-card);
}

.eyebrow-bracket { color: var(--fg-dim); }

.status-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--chion-mint);
  box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5);
  animation: pulse 2s ease-out infinite;
  flex-shrink: 0;
}

.status-dot-mini {
  width: 5px; height: 5px;
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5); transform: scale(1); }
  50% { box-shadow: 0 0 0 6px rgba(74, 222, 128, 0); transform: scale(1.1); }
}

.title {
  font-size: clamp(2.5rem, 7vw, 5.5rem);
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1.05;
  max-width: 22ch;
}

.title-em {
  background: linear-gradient(120deg, var(--accent), #6B8AFF);
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.lede {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  line-height: 1.55;
  color: var(--fg-muted);
  max-width: 50ch;
}

.lede-cn {
  font-family: var(--font-cn);
  display: block;
  margin-top: 0.5rem;
  letter-spacing: 0.04em;
  color: var(--fg-dim);
  font-size: 0.92em;
}

/* ─── Buttons ─── */
.cta-row {
  display: flex; gap: 0.75rem; flex-wrap: wrap; justify-content: center;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.5rem;
  font-family: var(--font-en);
  font-size: 0.92rem;
  font-weight: 500;
  letter-spacing: -0.005em;
  border-radius: 6px;
  transition: all 0.2s ease;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn-large {
  padding: 1rem 1.75rem;
  font-size: 1rem;
}

.btn-primary {
  background: var(--accent);
  color: var(--chion-white);
  box-shadow: 0 4px 20px -4px rgba(45, 91, 255, 0.4);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 28px -4px rgba(45, 91, 255, 0.55);
}

.btn-ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--line-strong);
}

.btn-ghost:hover {
  border-color: var(--fg);
  background: var(--bg-elevated);
}

.btn-full { width: 100%; }

.btn-arrow { transition: transform 0.2s ease; }
.btn:hover .btn-arrow { transform: translateX(2px); }

.btn-play {
  display: inline-flex; align-items: center; justify-content: center;
  width: 18px; height: 18px;
  background: var(--accent);
  color: var(--chion-white);
  border-radius: 50%;
  font-size: 0.55rem;
  padding-left: 1px;
}

/* ─── Product preview window ───
   Always dark (independent of page theme),
   like a code editor / terminal embedded on the page.
   Internal colors are hardcoded for dark background.
*/
.preview {
  width: 100%;
  max-width: 1000px;
  margin-top: 2rem;
  border-radius: 12px;
  background: #0E0E10;
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 30px 80px -20px rgba(45, 91, 255, 0.3),
    0 50px 100px -30px rgba(0, 0, 0, 0.5);
  transform-style: preserve-3d;
  color: rgba(255, 255, 255, 0.92);
}

.preview-frame { display: flex; flex-direction: column; }

.preview-header {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.term-dot {
  width: 12px; height: 12px; border-radius: 50%;
  background: #3F3F46;
}
.term-dot-r { background: var(--term-red); }
.term-dot-y { background: var(--term-yellow); }
.term-dot-g { background: var(--chion-mint); }

.preview-url {
  margin-left: 1rem;
  color: rgba(255, 255, 255, 0.55);
  letter-spacing: 0.02em;
}

.preview-status {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 0.4rem;
  color: var(--chion-mint);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.preview-body {
  display: grid;
  grid-template-columns: 200px 1fr;
  min-height: 320px;
}

.preview-sidebar {
  padding: 1.25rem 1rem;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  font-family: var(--font-mono);
  font-size: 0.78rem;
}

.preview-sidebar-section { margin-bottom: 1.5rem; }

.preview-sidebar-label {
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 0.6rem;
}

.preview-sidebar-item {
  padding: 0.35rem 0.6rem;
  margin-bottom: 0.15rem;
  color: rgba(255, 255, 255, 0.55);
  border-radius: 4px;
  cursor: default;
  transition: all 0.2s ease;
}

.preview-sidebar-item.active {
  background: rgba(255, 255, 255, 0.06);
  color: rgba(255, 255, 255, 0.95);
}

.preview-main {
  padding: 1.25rem 1.5rem;
  text-align: left;
}

.preview-main-header {
  display: flex; justify-content: space-between; align-items: center;
  padding-bottom: 0.8rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.preview-breadcrumb { color: rgba(255, 255, 255, 0.55); }
.preview-saved      { color: var(--chion-mint); font-size: 0.68rem; }

.preview-main-body {
  display: flex; flex-direction: column; gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.6;
}

.preview-line {
  display: flex; gap: 0.6rem; align-items: flex-start;
}

.preview-prefix {
  color: #6B8AFF;
  flex-shrink: 0;
  font-weight: 500;
}

.preview-prefix-out { color: rgba(255, 255, 255, 0.35); }

.preview-text       { color: rgba(255, 255, 255, 0.95); }
.preview-text-muted { color: rgba(255, 255, 255, 0.55); }

.preview-cursor {
  display: inline-block;
  background: #6B8AFF;
  color: transparent;
  width: 0.5em;
  margin-left: 1px;
  animation: blink 1s steps(2) infinite;
}

@keyframes blink { 50% { opacity: 0; } }

@media (max-width: 720px) {
  .preview-body { grid-template-columns: 1fr; min-height: auto; }
  .preview-sidebar { display: none; }
}

/* ─── Sections ─── */
.section {
  max-width: var(--container);
  margin: 0 auto;
  padding: var(--section-y) var(--gutter);
  border-top: 1px solid var(--line);
}

.section-header {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 2.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem; letter-spacing: 0.15em; text-transform: uppercase;
}

.section-num { color: var(--fg-muted); }

.section-label {
  color: var(--fg);
  position: relative; padding-left: 0.75rem;
}

.section-label::before {
  content: ''; position: absolute; left: -1rem; top: 50%;
  width: 1.5rem; height: 1px;
  background: var(--line-strong);
  transform: translateY(-50%);
}

.section-title {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 4rem;
  max-width: 28ch;
}

.section-title-muted { color: var(--fg-muted); }

/* ─── Features ─── */
.features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.feature {
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg-card);
  display: flex; flex-direction: column; gap: 1rem;
  transition: all 0.2s ease;
}

.feature:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
  background: var(--bg-elevated);
}

.feature-num {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.feature-title {
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--fg);
}

.feature-body {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--fg-muted);
  flex: 1;
}

.feature-tags {
  display: flex; gap: 0.4rem; flex-wrap: wrap;
}

.tag {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  padding: 0.25rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--fg-muted);
  letter-spacing: 0.04em;
}

@media (max-width: 880px) { .features { grid-template-columns: 1fr; } }

/* ─── Stats ─── */
.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3rem 2rem;
  border-top: 1px solid var(--line);
  padding-top: 3rem;
}

.stat { display: flex; flex-direction: column; gap: 0.5rem; }

.stat-num {
  font-family: var(--font-en);
  font-size: clamp(3rem, 6vw, 4.5rem);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1;
  color: var(--fg);
  background: linear-gradient(120deg, var(--fg), var(--accent));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.stat-label {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fg);
}

.stat-body {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--fg-muted);
}

@media (max-width: 720px) { .stats { grid-template-columns: 1fr; } }

/* ─── Pricing ─── */
.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.plan {
  position: relative;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg-card);
  display: flex; flex-direction: column; gap: 1.5rem;
  transition: all 0.2s ease;
}

.plan:hover {
  border-color: var(--line-strong);
  transform: translateY(-2px);
}

.plan-featured {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(45, 91, 255, 0.08), rgba(45, 91, 255, 0.02));
  box-shadow: 0 8px 30px -10px rgba(45, 91, 255, 0.3);
}

.plan-badge {
  position: absolute;
  top: 1rem; right: 1rem;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  padding: 0.25rem 0.5rem;
  background: var(--accent);
  color: var(--chion-white);
  border-radius: 4px;
}

.plan-header { display: flex; flex-direction: column; gap: 0.5rem; }

.plan-name {
  font-size: 1.25rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.plan-price { display: flex; align-items: baseline; gap: 0.25rem; }

.plan-amount {
  font-size: 2.25rem;
  font-weight: 500;
  letter-spacing: -0.04em;
  color: var(--fg);
}

.plan-period {
  font-size: 0.85rem;
  color: var(--fg-muted);
}

.plan-tagline {
  font-size: 0.88rem;
  color: var(--fg-muted);
  line-height: 1.45;
}

.plan-features {
  display: flex; flex-direction: column; gap: 0.55rem;
  flex: 1;
}

.plan-features li {
  font-size: 0.88rem;
  color: var(--fg);
  padding-left: 1.25rem;
  position: relative;
  line-height: 1.45;
}

.plan-features li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 1.4em;
  line-height: 1;
}

@media (max-width: 880px) { .plans { grid-template-columns: 1fr; } }

/* ─── Final CTA ─── */
.cta-final {
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
  gap: 1.5rem;
  border-top: 1px solid var(--line);
}

.cta-final-title {
  font-size: clamp(3rem, 8vw, 6rem);
  font-weight: 500;
  letter-spacing: -0.05em;
  line-height: 1;
  display: flex; flex-direction: column; gap: 0.4rem;
  align-items: center;
}

.cta-final-cn {
  font-family: var(--font-cn);
  font-size: 0.4em;
  font-weight: 300;
  letter-spacing: 0.1em;
  color: var(--fg-muted);
}

.cta-final-lede {
  font-size: 1.05rem;
  color: var(--fg-muted);
  margin-bottom: 1rem;
}

/* ─── Footer ─── */
.footer {
  border-top: 1px solid var(--line);
  background: var(--footer-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0 var(--gutter);
}

.footer-top {
  max-width: var(--container);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 2fr;
  gap: 4rem;
  padding: 4rem 0 3rem;
}

.footer-brand-block {
  display: flex; flex-direction: column; gap: 1rem;
}

.footer-brand {
  display: flex; align-items: baseline; gap: 0.6rem;
}

.footer-brand-en {
  font-size: 1.4rem; font-weight: 500; letter-spacing: -0.03em;
  color: var(--fg);
}

.footer-brand-cn {
  font-family: var(--font-cn);
  font-size: 1rem; font-weight: 300; letter-spacing: 0.3em;
  color: var(--fg-muted);
}

.footer-tagline {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--fg-muted);
  max-width: 24rem;
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.footer-col-title {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--fg-muted);
  margin-bottom: 1rem;
  font-weight: 500;
}

.footer-col-list { display: flex; flex-direction: column; gap: 0.6rem; }

.footer-link {
  font-size: 0.85rem;
  color: var(--fg-muted);
  transition: color 0.2s ease;
}

.footer-link:hover { color: var(--fg); }
.footer-link-active { color: var(--accent); }

.footer-bottom {
  max-width: var(--container);
  margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1.25rem;
  padding: 1.5rem 0;
  border-top: 1px solid var(--line);
}

.footer-copy {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  color: var(--fg-muted);
}

.footer-domains { display: flex; gap: 1.5rem; }
.footer-domains .footer-link {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}

/* ─── Mobile ─── */
@media (max-width: 880px) {
  .nav { grid-template-columns: 1fr auto; }
  .nav-links { display: none; }
  .nav-action-ghost { display: none; }

  .footer-top { grid-template-columns: 1fr; gap: 2.5rem; }
  .footer-cols { grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
}

@media (max-width: 560px) {
  :root { --gutter: 1.25rem; --section-y: 4.5rem; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 1rem; }
}

/* ─────────────────────────────────────────
   Studio-shared interactions
   - Reading progress bar
   - Mouse-follow ambient glow
   - Splash intro curtain
   - Wordmark hover wave
   - Nav link underline draw
   - Scroll-triggered reveals
   - Card 3D tilt
   ───────────────────────────────────────── */

.progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 1px;
  width: 0;
  background: linear-gradient(90deg, transparent, var(--accent) 80%, var(--accent));
  z-index: 200;
  pointer-events: none;
  transition: width 0.08s linear;
  box-shadow: 0 0 8px rgba(45, 91, 255, 0.5);
}

.mouse-glow {
  position: fixed;
  top: 0; left: 0;
  width: 480px; height: 480px;
  margin-left: -240px; margin-top: -240px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  transition: opacity 0.4s ease;
  will-change: transform;
}
:root[data-theme="dark"] .mouse-glow {
  background: radial-gradient(circle, rgba(45, 91, 255, 0.10), rgba(45, 91, 255, 0.03) 40%, transparent 70%);
  mix-blend-mode: screen;
}
:root[data-theme="light"] .mouse-glow {
  background: radial-gradient(circle, rgba(45, 91, 255, 0.10), rgba(45, 91, 255, 0.03) 40%, transparent 70%);
  mix-blend-mode: multiply;
}
.mouse-glow-hidden { opacity: 0; }

.splash {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--chion-black);
  pointer-events: none;
  animation: splash-rise 1.4s cubic-bezier(0.7, 0, 0.3, 1) 0.6s forwards;
}
:root[data-theme="light"] .splash { background: var(--chion-white); }
.splash-mark {
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(45, 91, 255, 0.6), 0 0 30px rgba(45, 91, 255, 0.4);
  animation:
    splash-pulse 1.2s cubic-bezier(0.22, 1, 0.36, 1) infinite,
    splash-mark-fade 0.6s cubic-bezier(0.7, 0, 0.3, 1) 0.7s forwards;
  font-size: 0;
}
@keyframes splash-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(45, 91, 255, 0.6), 0 0 30px rgba(45, 91, 255, 0.4); }
  50% { box-shadow: 0 0 0 14px rgba(45, 91, 255, 0), 0 0 30px rgba(45, 91, 255, 0.4); }
}
@keyframes splash-mark-fade {
  to { opacity: 0; transform: scale(0.5); }
}
@keyframes splash-rise {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-101%); }
}

.nav-brand-en .word-letter {
  display: inline-block;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.nav-brand:hover .word-letter { transform: translateY(-3px); }
.nav-brand:hover .word-letter:nth-child(1) { transition-delay: 0s; }
.nav-brand:hover .word-letter:nth-child(2) { transition-delay: 0.05s; }
.nav-brand:hover .word-letter:nth-child(3) { transition-delay: 0.10s; }
.nav-brand:hover .word-letter:nth-child(4) { transition-delay: 0.15s; }
.nav-brand:hover .word-letter:nth-child(5) { transition-delay: 0.20s; }

.nav-link { position: relative; }
.nav-link::before {
  content: '';
  position: absolute;
  bottom: -3px; left: 0; right: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}
.nav-link:hover::before { transform: scaleX(1); }

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}
.reveal.in-view { opacity: 1; transform: translateY(0); }

/* Feature card 3D tilt (applied via JS) */
.feature {
  transform-origin: center center;
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1),
              border-color 0.3s ease, background 0.3s ease;
  will-change: transform;
  position: relative;
  overflow: hidden;
}

/* Feature hover scrub bar */
.feature::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  height: 2px;
  width: var(--scrub, 0%);
  background: var(--accent);
  transition: width 0.12s linear;
  pointer-events: none;
}

html { scroll-padding-top: 80px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
