/* Shared styles for index / product / about (v5 look). Subpages use subpage.css. */
/* Self-hosted fonts (latin subset, variable) */
@font-face { font-family: 'Inter'; font-weight: 400 800; font-style: normal; font-display: swap; src: url(/fonts/inter-latin.woff2) format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-weight: 400 500; font-style: normal; font-display: swap; src: url(/fonts/jbmono-latin.woff2) format('woff2'); }

:root {
  /* Product brand tokens (docs/03-ui-ux/01-design-tokens.md) */
  --bg-app: #F4F6F8;
  --bg-surface: #FFFFFF;
  --bg-subtle: #F9FAFB;
  --bg-hover: #F3F4F6;
  --border: #E5E7EB;
  --border-strong: #D1D5DB;
  --text-primary: #111827;
  --text-secondary: #5B6472;
  --text-tertiary: #9CA3AF;
  --accent: #2563EB;
  --accent-hover: #1D4ED8;
  --accent-soft: #DBEAFE;
  --accent-text-on-soft: #1E40AF;

  --ink: #0A1024;        /* deep navy: heading text, video letterbox */

  --radius-sm: 6px;  --radius-md: 10px;  --radius-lg: 12px;  --radius-xl: 16px;
  --shadow-sm: 0 1px 3px 0 rgba(16,24,40,0.06), 0 1px 2px -1px rgba(16,24,40,0.04);
  --shadow-md: 0 8px 20px -6px rgba(16,24,40,0.10), 0 2px 6px -2px rgba(16,24,40,0.06);
  --shadow-lg: 0 24px 48px -12px rgba(16,24,40,0.16), 0 6px 14px -6px rgba(16,24,40,0.08);

  --maxw: 1120px;
  --ease: cubic-bezier(0.22, 0.72, 0.18, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text-primary); background: var(--bg-surface);
  line-height: 1.5; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -9999px; top: 8px; background: #fff; color: var(--ink); padding: 8px 14px; border-radius: var(--radius-md); z-index: 100; }
.skip:focus { left: 8px; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 15px; font-weight: 600; line-height: 1; padding: 14px 22px;
  border-radius: var(--radius-md); border: 1px solid transparent; cursor: pointer;
  transition: background .2s var(--ease), transform .15s var(--ease), box-shadow .25s var(--ease);
  white-space: nowrap;
}
.btn .ico { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.btn:hover .ico { transform: translateX(4px); }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: 0 10px 24px -8px rgba(37,99,235,0.6); }
.btn-sm { padding: 9px 15px; font-size: 14px; }

/* ---- Nav (light, shared with subpages) ---- */
nav { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,0.92); backdrop-filter: saturate(180%) blur(12px); -webkit-backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--border); }
nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 64px; gap: 16px; }
.logo { display: flex; align-items: center; gap: 9px; font-size: 19px; letter-spacing: -0.02em; color: var(--ink); }
.logo .mark { width: 26px; height: 26px; flex: none; }
.logo b { font-weight: 700; }
.logo .lien { font-weight: 700; color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a:not(.btn) { font-size: 14px; font-weight: 500; color: var(--text-secondary); transition: color .15s var(--ease); }
.nav-links a:not(.btn):hover { color: var(--ink); }

/* ---- Hero (8px spacing scale) ---- */
.hero { text-align: center; padding: 88px 0 0; background: var(--bg-surface); overflow: hidden; }
h1 { font-size: clamp(44px, 8vw, 72px); font-weight: 800; line-height: 1.02; letter-spacing: -0.04em; color: var(--ink); text-wrap: balance; margin: 0 auto 24px; }
h1 em { font-style: normal; color: var(--accent); }
.hero .sub { font-size: clamp(17px, 2.2vw, 20px); color: var(--text-secondary); max-width: 40ch; text-wrap: balance; margin: 0 auto 32px; line-height: 1.5; }
.cta-note { margin-top: 16px; font-size: 13px; color: var(--text-secondary); }

/* ---- Page hero (product / about) ---- */
.page-hero { text-align: center; padding: 88px 0 72px; background: var(--bg-surface); }
.page-hero h1 { font-size: clamp(40px, 7vw, 64px); font-weight: 800; line-height: 1.04; letter-spacing: -0.04em; color: var(--ink); text-wrap: balance; margin: 0 auto 24px; }
.page-hero h1 em { font-style: normal; color: var(--accent); }
.page-hero .sub { font-size: clamp(17px, 2.2vw, 20px); color: var(--text-secondary); max-width: 44ch; margin: 0 auto 32px; text-wrap: balance; }
@media (max-width: 640px) { .page-hero { padding: 56px 0 48px; } }

/* ---- Product window around the video ---- */
.stage { position: relative; margin-top: 56px; padding-bottom: 96px; }
.stage::before { content: ""; position: absolute; left: 50%; top: -40px; width: min(1100px, 120%); height: 80%; transform: translateX(-50%); pointer-events: none;
  background: radial-gradient(closest-side, rgba(37,99,235,0.14), rgba(37,99,235,0.05) 55%, transparent 100%); }
.stage .wrap { max-width: 1168px; }
.window { position: relative; max-width: var(--maxw); margin: 0 auto; border-radius: var(--radius-xl); overflow: hidden; background: var(--bg-surface); border: 1px solid var(--border);
  box-shadow: 0 1px 2px rgba(16,24,40,0.06), 0 8px 24px -8px rgba(16,24,40,0.12), 0 40px 80px -24px rgba(37,99,235,0.22); }
.window .bar { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 16px; background: var(--bg-subtle); border-bottom: 1px solid var(--border); }
.window .bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--border-strong); }
.player { position: relative; background: var(--ink); }
.player video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: var(--ink); }
.play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 88px; height: 88px; border-radius: 50%; border: 0; cursor: pointer; background: rgba(255,255,255,0.96); color: var(--accent); display: grid; place-items: center;
  box-shadow: 0 8px 32px rgba(10,16,36,0.25), 0 0 0 8px rgba(255,255,255,0.35); transition: transform .2s var(--ease), box-shadow .2s var(--ease); }
.play:hover { transform: translate(-50%, -50%) scale(1.06); }
.play[hidden] { display: none; }
.play svg { width: 32px; height: 32px; margin-left: 4px; }

/* ---- Stage comparison: today vs with PracticeLien ---- */
.compare { border-top: 1px solid var(--border); background: var(--bg-app); padding: 88px 0; }
.compare h2 { text-align: center; font-size: clamp(26px, 3.2vw, 36px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; color: var(--ink); text-wrap: balance; }
.compare .card { max-width: 1040px; margin: 48px auto 0; background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-xl); box-shadow: var(--shadow-sm); overflow: hidden; }
.compare .row3 { display: grid; grid-template-columns: 200px minmax(0, 1fr) minmax(0, 1fr); gap: 0 40px; padding: 28px 32px; align-items: start; }
.compare .head { padding-block: 16px; background: var(--bg-subtle); font-size: 12px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-secondary); }
.compare .head .w { color: var(--accent); }
.compare ol { list-style: none; }
.compare li { border-top: 1px solid var(--border); }
.compare h3 { font-size: 17px; font-weight: 700; letter-spacing: -0.012em; color: var(--ink); }
.compare .lbl { display: block; margin-top: 8px; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-secondary); }
.compare .val { display: block; margin-top: 2px; font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 13px; font-weight: 500; color: var(--accent); }
.compare .cell { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; line-height: 1.5; }
.compare .cell svg { width: 16px; height: 16px; flex: none; margin-top: 3px; }
.compare .today { color: var(--text-secondary); }
.compare .today svg { color: var(--text-secondary); opacity: .7; }
.compare .with { color: var(--ink); }
.compare .with svg { color: var(--accent); }
.compare .k { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.compare .caption { margin-top: 32px; text-align: center; font-size: 15px; color: var(--text-secondary); }
@media (max-width: 900px) {
  .compare .row3 { grid-template-columns: 160px minmax(0, 1fr) minmax(0, 1fr); gap: 0 24px; padding: 24px; }
}
@media (max-width: 760px) {
  .compare .row3.head { display: none; }
  .compare .row3 { display: block; padding: 24px 20px; }
  .compare .stg { margin-bottom: 16px; }
  .compare .cell + .cell { margin-top: 12px; }
  .compare .k { position: static; width: auto; height: auto; margin: 0 0 2px; clip: auto; clip-path: none; white-space: normal; display: block; font-size: 11px; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; }
  .compare .today .k { color: var(--text-secondary); }
  .compare .with .k { color: var(--accent); }
}

/* ---- Final CTA ---- */
.final { text-align: center; padding: 96px 0; background: var(--bg-surface); }
.final h2 { font-size: clamp(28px, 4vw, 44px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; color: var(--ink); margin-bottom: 32px; }

/* ---- Footer ---- */
footer { background: var(--bg-surface); color: var(--text-secondary); padding: 46px 0; font-size: 14px; border-top: 1px solid var(--border); }
footer .wrap { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 18px; }
footer .brand { display: flex; align-items: center; gap: 9px; color: var(--ink); font-weight: 700; letter-spacing: -0.02em; font-size: 16px; }
footer .brand .mark { width: 22px; height: 22px; flex: none; }
footer .brand .lien { color: var(--accent); }
footer .brand .co { color: var(--text-secondary); font-weight: 400; letter-spacing: 0; font-size: 14px; margin-left: 2px; }
footer .links { display: flex; gap: 22px; flex-wrap: wrap; }
footer .links a:hover { color: var(--ink); }

/* ---- Responsive ---- */
@media (max-width: 640px) {
  nav .wrap { padding: 0 16px; gap: 8px; }
  .logo { font-size: 17px; }
  .nav-links { gap: 12px; }
  .nav-links a:not(.btn) { font-size: 13px; }
  .btn-sm { padding: 8px 11px; font-size: 13px; }
  .nav-links a, nav .btn { white-space: nowrap; }
  .nav-links a.nav-page { display: none; }
  .hero { padding-top: 56px; }
  .stage { margin-top: 40px; padding-bottom: 64px; }
  .play { width: 64px; height: 64px; }
  .play svg { width: 24px; height: 24px; }
  .compare { padding: 56px 0; }
  .final { padding: 64px 0; }
  footer .wrap { flex-direction: column; align-items: flex-start; }
  footer .brand { flex-wrap: wrap; }
  footer .brand .co { flex-basis: 100%; margin: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
