/* =========================================================================
   Sparrows — design system
   Palette: white + light blue, black text. Editorial, calm, spacious.
   Fonts: Schibsted Grotesk (display, UI, body) · IBM Plex Mono (metadata)
   ========================================================================= */

:root {
  /* type — Poetic-style: Inter (UI/text), Inter Tight (display) */
  --font-display: "Inter Tight", "Inter", Arial, Helvetica, sans-serif;
  --font-ui: "Inter", Arial, Helvetica, sans-serif;
  --font-body: "Inter", Arial, Helvetica, sans-serif;
  --font-mn: "Inter", Arial, Helvetica, sans-serif;

  /* ink */
  --ink: #0a0a0a;
  --ink-pure: #000000;
  --ink-soft: #505050;
  --muted: #7b8794;

  /* surfaces */
  --canvas: #ffffff;
  --card: #ffffff;
  --white: #ffffff;

  /* light blue scale */
  --blue-50:  #eff6fd;
  --blue-100: #e1eefb;
  --blue-200: #c8e0f7;
  --blue-300: #a8cef2;
  --blue-400: #78b0e6;
  --blue-500: #3f83d6;
  --blue-600: #2c6cbe;

  /* lines + shadow */
  --line: #e5edf6;
  --line-strong: #d5e2f0;
  --shadow-sm: 0 1px 2px rgba(16, 42, 74, .04), 0 1px 3px rgba(16, 42, 74, .06);
  --shadow-md: 0 6px 20px rgba(16, 42, 74, .06), 0 2px 6px rgba(16, 42, 74, .05);
  --shadow-lg: 0 24px 60px rgba(16, 42, 74, .10), 0 8px 20px rgba(16, 42, 74, .06);

  /* layout */
  --pad: clamp(20px, 6vw, 120px);
  --maxw: 1200px;
  --radius: 18px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; font-optical-sizing: auto; font-kerning: normal; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--canvas);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
:lang(mn), .mn { font-family: var(--font-mn); }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
h1, h2, h3, h4 { font-family: var(--font-display); font-weight: 700; letter-spacing: -0.05em; margin: 0; line-height: .98; }
p { margin: 0; }

/* ---- layout helpers ---- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad); }
.section { padding-block: clamp(56px, 9vw, 120px); }
.section-tight { padding-block: clamp(40px, 6vw, 72px); }
.center { text-align: center; }
.stack-sm > * + * { margin-top: 14px; }

.eyebrow {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--blue-600);
}
.section-title { font-size: clamp(30px, 4.4vw, 46px); letter-spacing: -0.05em; }
.section-lead { color: var(--ink-soft); font-size: clamp(16px, 1.6vw, 19px); max-width: 620px; }
.center .section-lead { margin-inline: auto; }

/* =========================================================================
   Buttons + badge
   ========================================================================= */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-ui); font-weight: 500; font-size: 15px; letter-spacing: -0.01em;
  padding: 12px 22px; border-radius: 999px; border: 1px solid transparent;
  transition: transform .18s ease, background .18s ease, box-shadow .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; }
.btn-dark { background: var(--ink-pure); color: #fff; }
.btn-dark:hover { transform: translateY(-1px); box-shadow: 0 8px 22px rgba(0,0,0,.22); }
.btn-blue { background: var(--blue-500); color: #fff; }
.btn-blue:hover { background: var(--blue-600); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: rgba(10,10,10,.14); }
.btn-ghost:hover { background: rgba(10,10,10,.04); border-color: rgba(10,10,10,.28); }
.btn-light { background: #fff; color: var(--ink); border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.btn-light:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-lg { padding: 15px 28px; font-size: 16px; }
.link-arrow { font-family: var(--font-ui); font-weight: 500; color: var(--ink); display: inline-flex; align-items: center; gap: 6px; }
.link-arrow svg { width: 15px; height: 15px; transition: transform .18s ease; }
.link-arrow:hover svg { transform: translateX(3px); }

.badge {
  display: inline-flex; align-items: center; gap: 9px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 999px; padding: 5px 14px 5px 5px;
  font-family: var(--font-body); font-size: 14px; color: var(--ink-soft);
  box-shadow: var(--shadow-sm);
}
.badge .tag {
  display: inline-flex; align-items: center; gap: 5px;
  background: #0e1311; color: #fff; border-radius: 999px;
  padding: 4px 10px; font-size: 12px; font-weight: 500;
}
.badge .tag svg { width: 12px; height: 12px; }

/* =========================================================================
   Navigation (injected by app.js)
   ========================================================================= */
.site-nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  transition: background .25s ease, box-shadow .25s ease, border-color .25s ease;
  border-bottom: 1px solid transparent;
}
.site-nav.scrolled,
body:not(.has-hero) .site-nav {
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom-color: var(--line);
}
.nav-inner {
  display: flex; align-items: center; gap: 34px;
  padding: 16px var(--pad);
  max-width: 1440px; margin-inline: auto;
}
.brand { display: inline-flex; align-items: center; gap: 9px; font-family: var(--font-ui); font-weight: 700; font-size: 19px; letter-spacing: -0.02em; }
.brand .mark { width: 22px; height: 22px; color: var(--blue-500); }
.nav-menu { display: flex; align-items: center; gap: 28px; margin-left: 8px; }
.nav-menu a, .nav-drop > button {
  font-family: var(--font-ui); font-weight: 500; font-size: 16px; letter-spacing: -0.012em;
  color: var(--ink); background: none; border: 0; padding: 6px 0; display: inline-flex; align-items: center; gap: 5px;
  opacity: .82; transition: opacity .15s ease;
}
.nav-menu a:hover, .nav-drop > button:hover, .nav-menu a.active { opacity: 1; }
.nav-menu a.active { color: var(--blue-600); }
.nav-drop { position: relative; }
.nav-drop > button svg { width: 13px; height: 13px; transition: transform .2s ease; }
.nav-drop.open > button svg { transform: rotate(180deg); }
.nav-drop-panel {
  position: absolute; top: calc(100% + 12px); left: -14px; min-width: 264px;
  background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg);
  padding: 8px; opacity: 0; visibility: hidden; transform: translateY(-6px); transition: all .18s ease;
}
.nav-drop:hover .nav-drop-panel, .nav-drop.open .nav-drop-panel { opacity: 1; visibility: visible; transform: none; }
.nav-drop-panel a { display: flex; gap: 12px; padding: 10px 12px; border-radius: 10px; opacity: 1; }
.nav-drop-panel a:hover { background: var(--blue-50); }
.nav-drop-panel .di { width: 34px; height: 34px; flex: none; border-radius: 9px; background: var(--blue-50); color: var(--blue-600); display: grid; place-items: center; }
.nav-drop-panel .di svg { width: 17px; height: 17px; }
.nav-drop-panel .dt { font-family: var(--font-ui); font-weight: 600; font-size: 14px; color: var(--ink); line-height: 1.3; }
.nav-drop-panel .dd { font-size: 12.5px; color: var(--muted); }
.nav-spacer { flex: 1; }
.nav-cta { display: flex; align-items: center; gap: 12px; }
.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid rgba(19, 24, 38, .13);
  border-radius: 999px;
  background: rgba(255, 255, 255, .72);
}
.lang-switch button {
  min-width: 31px;
  height: 28px;
  padding: 0 7px;
  border: 0;
  border-radius: 999px;
  color: var(--ink-soft);
  background: transparent;
  font-family: var(--font-ui);
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .04em;
  cursor: pointer;
}
.lang-switch button:hover { color: var(--ink); }
.lang-switch button.is-active { color: #fff; background: var(--ink); }
html[lang="mn"] .display,
html[lang="mn"] .pp-display,
html[lang="mn"] .page-hero h1,
html[lang="mn"] .section-title { letter-spacing: -.035em; }
html[lang="mn"] body { font-kerning: normal; }
.nav-login { font-family:var(--font-ui); font-size:14px; font-weight:500; color:var(--ink-soft); padding:9px 4px; }
.nav-login:hover { color:var(--ink); }
.nav-toggle { display: none; background: none; border: 0; width: 40px; height: 40px; border-radius: 10px; }
.nav-toggle:hover { background: rgba(10,10,10,.05); }
.nav-toggle svg { width: 22px; height: 22px; margin-inline: auto; }

/* =========================================================================
   Hero — one decisive viewport: promise, product family, proof
   ========================================================================= */
.hero { position: relative; height: 100svh; min-height: 760px; background: var(--canvas); }
.hero-sticky { position: relative; height: 100%; min-height: 760px; overflow: hidden; }
.hero-bg {
  position: absolute; inset: 0;
  width: 100%; height: 100%; max-width: none;
  object-fit: cover; object-position: center 58%;
  z-index: 0; opacity: 1; filter: contrast(1.1) saturate(.92);
  animation: heroIn 1s ease both;
}
.hero-bg.no-fade { animation: none; }
@keyframes heroIn { from { opacity: 0; } to { opacity: 1; } }
.hero-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,255,255,.86) 0%, rgba(255,255,255,.62) 34%, rgba(255,255,255,.12) 72%),
    linear-gradient(to bottom, rgba(255,255,255,.05) 68%, rgba(255,255,255,.78) 100%);
}
.hero-phase {
  position: absolute; inset: 0; z-index: 3;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: center;
  text-align: left;
  padding: 88px max(24px, calc((100vw - 1140px) / 2)) 188px;
}
.hero-p1 { opacity: 1; }
.hero h1 {
  font-size: clamp(54px, 7vw, 94px);
  letter-spacing: -0.06em; line-height: .91; max-width: 9.5ch;
  text-shadow: 0 1px 34px rgba(255,255,255,.6);
}
.hero-eyebrow {
  margin-bottom: 18px; font-family: var(--font-ui); font-size: 12px; font-weight: 600;
  letter-spacing: .13em; text-transform: uppercase; color: var(--blue-600);
}
.hero-sub {
  max-width: 39ch; margin-top: 24px; font-family: var(--font-body); font-size: clamp(17px,1.5vw,20px);
  line-height: 1.5; color: #323944;
}
.hero .hero-cta { display: flex; gap: 12px; align-items: center; margin-top: 30px; flex-wrap: wrap; justify-content: flex-start; }
.hero .hero-note { font-family: var(--font-ui); font-size: 13px; color: var(--ink-soft); margin-top: 24px; letter-spacing: .02em; }
.hero .hero-note .mn { color: var(--blue-600); }
.hero-products {
  position: absolute; left: max(24px, calc((100vw - 1140px) / 2));
  right: max(24px, calc((100vw - 1140px) / 2)); bottom: 24px;
  display: grid; grid-template-columns: repeat(4,1fr); overflow: hidden;
  border: 1px solid rgba(214,223,235,.92); border-radius: 18px;
  background: rgba(255,255,255,.82); box-shadow: 0 18px 50px rgba(36,53,78,.09);
  backdrop-filter: blur(16px);
}
.hero-products a { position:relative; min-width:0; padding:16px 18px; color:var(--ink); }
.hero-products a + a { border-left:1px solid rgba(220,227,236,.9); }
.hero-products span,.hero-products small,.hero-products b { display:block; font-family:var(--font-ui); }
.hero-products span { font-size:14px; font-weight:650; }
.hero-products small { margin-top:4px; color:var(--ink-soft); font-size:11.5px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.hero-products b { margin-top:10px; color:var(--blue-600); font-size:9.5px; font-weight:600; letter-spacing:.07em; text-transform:uppercase; }
.hero-products a::after { content:"↗"; position:absolute; right:16px; top:16px; color:#8e99a8; font-size:12px; opacity:0; transform:translate(-3px,3px); transition:.2s ease; }
.hero-products a:hover::after { opacity:1; transform:none; }
.scroll-cue {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 3;
  font-family: var(--font-ui); font-size: 11px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--ink-soft); display: flex; flex-direction: column; align-items: center; gap: 8px;
  display: none;
}
.scroll-cue .bar { width: 1px; height: 32px; background: linear-gradient(var(--ink-soft), transparent); }
/* fallback when JS can't pin (reduced-motion / no-JS): stack both phases statically */
.hero.no-pin { height: 100svh; min-height:760px; }

/* =========================================================================
   Wordmark strip
   ========================================================================= */
.strip { border-block: 1px solid var(--line); background: rgba(255,255,255,.5); }
.strip .cap { font-family: var(--font-ui); font-size: 13px; letter-spacing: .04em; color: var(--muted); text-align: center; }
.strip-marks { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: clamp(22px, 5vw, 60px); margin-top: 20px; }
.strip-marks span { font-family: var(--font-display); font-weight: 700; font-size: clamp(18px, 2.4vw, 26px); letter-spacing: -0.04em; color: #9aa7b6; transition: color .2s ease; }
.strip-marks span:hover { color: var(--blue-600); }
.strip-marks .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--blue-200); }

/* =========================================================================
   Stats
   ========================================================================= */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(20px, 5vw, 64px); }
.stat .n { font-family: var(--font-display); font-weight: 700; font-size: clamp(40px, 6vw, 64px); letter-spacing: -0.05em; line-height: 1; }
.stat .n b { color: var(--blue-500); font-weight: 700; }
.stat .l { font-family: var(--font-ui); font-size: 14px; color: var(--ink-soft); margin-top: 10px; }

/* =========================================================================
   Principles (3 columns)
   ========================================================================= */
.cols3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 48px); margin-top: 52px; }
.feat .ico { width: 42px; height: 42px; border-radius: 12px; background: var(--blue-50); color: var(--blue-600); display: grid; place-items: center; }
.feat .ico svg { width: 21px; height: 21px; }
.feat h3 { font-size: 19px; letter-spacing: -0.03em; margin-top: 18px; }
.feat p { color: var(--ink-soft); font-size: 15px; margin-top: 9px; }

/* =========================================================================
   Bento product grid
   ========================================================================= */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; margin-top: 52px; }
.p-card {
  position: relative; overflow: hidden;
  background: var(--card); border: 1px solid var(--line); border-radius: 22px;
  padding: 26px; display: flex; flex-direction: column;
  box-shadow: var(--shadow-sm); transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
  min-height: 320px;
}
.p-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
.p-card .p-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.p-card .p-name { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.04em; }
.p-card .p-glyph { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--blue-50); color: var(--blue-600); }
.p-card .p-glyph svg { width: 17px; height: 17px; }
.p-tag { font-family: var(--font-ui); font-size: 11.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; padding: 4px 9px; border-radius: 999px; }
.p-tag.live { background: #e7f6ec; color: #1f8a4c; }
.p-tag.dev { background: var(--blue-50); color: var(--blue-600); }
.p-tag.soon { background: #f3f4f6; color: #6b7280; }
.p-card .p-desc { color: var(--ink-soft); font-size: 15px; margin-top: 12px; max-width: 46ch; }
.p-card .p-foot { margin-top: auto; padding-top: 20px; display: flex; align-items: center; justify-content: space-between; }
.p-card .p-sector { font-family: var(--font-ui); font-size: 12.5px; color: var(--muted); }
.p-viz { margin-top: 20px; border-radius: 14px; background: linear-gradient(160deg, var(--blue-50), #fff); border: 1px solid var(--line); padding: 16px; }

.p-dealy { grid-column: span 4; }
.p-bestshot { grid-column: span 2; }
.p-construction { grid-column: span 2; }
.p-camp { grid-column: span 4; }

/* mini-visualization primitives */
.viz-row { display: flex; align-items: center; gap: 10px; }
.viz-chip { font-family: var(--font-ui); font-size: 11px; font-weight: 600; padding: 5px 9px; border-radius: 8px; background: #fff; border: 1px solid var(--line); color: var(--ink-soft); }
.viz-chip.g { background: #eafaf0; border-color: #cdefd8; color: #1f8a4c; }
.viz-bars { display: flex; align-items: flex-end; gap: 7px; height: 66px; }
.viz-bars i { flex: 1; border-radius: 5px 5px 0 0; background: var(--blue-200); }
.viz-bars i.hi { background: var(--blue-500); }
.viz-stat { font-family: var(--font-display); font-weight: 700; font-size: 26px; letter-spacing: -0.04em; }
.viz-stat b { color: #1f8a4c; }
.viz-line { height: 8px; border-radius: 999px; background: var(--blue-100); overflow: hidden; }
.viz-line span { display: block; height: 100%; background: var(--blue-500); border-radius: 999px; }
.viz-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.viz-grid i { aspect-ratio: 1; border-radius: 4px; background: var(--blue-100); }
.viz-grid i.on { background: var(--blue-400); }
.viz-grid i.book { background: var(--blue-600); }
.gantt { display: flex; flex-direction: column; gap: 8px; }
.gantt .g-row { display: flex; align-items: center; gap: 8px; }
.gantt .g-lbl { font-family: var(--font-ui); font-size: 10.5px; color: var(--muted); width: 46px; flex: none; }
.gantt .g-track { flex: 1; height: 10px; background: var(--blue-50); border-radius: 999px; position: relative; }
.gantt .g-track span { position: absolute; top: 0; bottom: 0; border-radius: 999px; background: var(--blue-400); }
.gantt .g-track span.b { background: var(--blue-600); }

/* =========================================================================
   Studio / narrative
   ========================================================================= */
.studio-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.studio-card { background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-md); overflow: hidden; }
.studio-card .sc-img { aspect-ratio: 16/10; background: linear-gradient(160deg, var(--blue-100), var(--blue-50)); position: relative; }
.steps { display: flex; flex-direction: column; gap: 14px; margin-top: 28px; }
.step { display: flex; gap: 16px; align-items: flex-start; }
.step .num { width: 34px; height: 34px; flex: none; border-radius: 10px; background: #0e1311; color: #fff; font-family: var(--font-ui); font-weight: 600; display: grid; place-items: center; font-size: 14px; }
.step h4 { font-family: var(--font-display); font-size: 18px; letter-spacing: -0.03em; }
.step p { color: var(--ink-soft); font-size: 14.5px; margin-top: 4px; }

/* =========================================================================
   CTA band
   ========================================================================= */
.cta {
  position: relative; overflow: hidden; border-radius: 28px;
  background: radial-gradient(120% 160% at 50% -20%, var(--blue-500), var(--blue-600));
  color: #fff; text-align: center; padding: clamp(48px, 7vw, 84px) var(--pad);
}
.cta h2 { color: #fff; font-size: clamp(30px, 4.6vw, 50px); letter-spacing: -0.05em; }
.cta p { color: rgba(255,255,255,.86); margin-top: 16px; font-size: 18px; max-width: 560px; margin-inline: auto; }
.cta .hero-cta { display: flex; gap: 14px; justify-content: center; margin-top: 30px; flex-wrap: wrap; }
.cta .btn-light { border-color: transparent; }

/* =========================================================================
   Footer
   ========================================================================= */
.site-footer { border-top: 1px solid var(--line); background: #fff; }
.foot-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr); gap: 40px; padding-block: 64px 40px; }
.foot-brand .brand { font-size: 20px; }
.foot-brand p { color: var(--ink-soft); font-size: 14px; margin-top: 16px; max-width: 34ch; }
.foot-brand .mn { color: var(--muted); font-size: 13px; margin-top: 10px; }
.foot-col h5 { font-family: var(--font-ui); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 16px; }
.foot-col a { display: block; font-size: 14.5px; color: var(--ink-soft); padding: 6px 0; }
.foot-col a:hover { color: var(--blue-600); }
.foot-bottom { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 22px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); flex-wrap: wrap; }

/* =========================================================================
   Sub-page hero (products / about / contact / login)
   ========================================================================= */
.page-hero { padding-top: 132px; padding-bottom: 24px; position: relative; }
.page-hero.accent { background: linear-gradient(180deg, var(--blue-50), var(--canvas)); border-bottom: 1px solid var(--line); }
.page-hero h1 { font-size: clamp(38px, 6vw, 64px); letter-spacing: -0.055em; max-width: 18ch; }
.page-hero .lead { color: var(--ink-soft); font-size: clamp(17px, 2vw, 20px); max-width: 620px; margin-top: 20px; font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; }
.page-hero .hero-cta { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.crumb { font-family: var(--font-ui); font-size: 13px; color: var(--blue-600); letter-spacing: .02em; margin-bottom: 18px; display: inline-flex; gap: 8px; align-items: center; }

/* content blocks reused on skeleton pages */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.card-plain { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 28px; box-shadow: var(--shadow-sm); }
.mock { border-radius: 16px; border: 1px solid var(--line); background: linear-gradient(160deg, var(--blue-50), #fff); min-height: 300px; box-shadow: var(--shadow-md); position: relative; overflow: hidden; }
.mock .mock-bar { height: 38px; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 6px; padding: 0 14px; background: #fff; }
.mock .mock-bar i { width: 10px; height: 10px; border-radius: 50%; background: var(--blue-200); }
.mock .mock-body { padding: 18px; display: grid; gap: 12px; }
.mock .mock-body .ln { height: 12px; border-radius: 6px; background: var(--blue-100); }
.mock .mock-body .ln.s { width: 60%; }
.mock .mock-body .ln.m { width: 80%; }

.feature-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 24px; }
.feature-list .fi { display: flex; gap: 12px; align-items: flex-start; }
.feature-list .fi .ck { width: 24px; height: 24px; flex: none; border-radius: 7px; background: var(--blue-50); color: var(--blue-600); display: grid; place-items: center; }
.feature-list .fi .ck svg { width: 14px; height: 14px; }
.feature-list .fi b { font-family: var(--font-ui); font-weight: 600; font-size: 15px; }
.feature-list .fi p { color: var(--ink-soft); font-size: 13.5px; margin-top: 2px; }

/* login chooser */
.chooser { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 40px; }
.svc {
  display: flex; gap: 16px; align-items: flex-start;
  background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 22px;
  box-shadow: var(--shadow-sm); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.svc:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: var(--blue-200); }
.svc .svc-glyph { width: 46px; height: 46px; flex: none; border-radius: 12px; background: var(--blue-50); color: var(--blue-600); display: grid; place-items: center; }
.svc .svc-glyph svg { width: 23px; height: 23px; }
.svc h3 { font-family: var(--font-display); font-size: 20px; letter-spacing: -0.03em; display: flex; align-items: center; gap: 10px; }
.svc p { color: var(--ink-soft); font-size: 14px; margin-top: 6px; }
.svc .svc-host { font-family: var(--font-ui); font-size: 12px; color: var(--muted); margin-top: 12px; display: inline-flex; align-items: center; gap: 6px; }

/* contact form */
.form { display: grid; gap: 16px; max-width: 560px; }
.form .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: grid; gap: 7px; }
.field label { font-family: var(--font-ui); font-size: 13px; font-weight: 500; color: var(--ink); }
.field input, .field select, .field textarea {
  font-family: var(--font-body); font-size: 15px; color: var(--ink);
  padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line-strong); background: #fff; width: 100%;
}
.field textarea { min-height: 130px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--blue-300); outline-offset: 1px; border-color: var(--blue-400); }

/* =========================================================================
   Portfolio — stacked bento (flagship horizontals + 2-up verticals)
   ========================================================================= */
.folio { display: flex; flex-direction: column; gap: 18px; margin-top: 52px; }
.folio-card {
  position: relative; overflow: hidden; border-radius: 26px;
  border: 1px solid var(--line); background: var(--card); color: inherit; text-decoration: none;
  box-shadow: var(--shadow-sm); transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.folio-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
.folio-wide { display: grid; grid-template-columns: 1.02fr 1.12fr; align-items: stretch; min-height: 396px; }
.folio-wide .fc-body { padding: 46px; display: flex; flex-direction: column; justify-content: center; }
.folio-wide .fc-viz {
  position: relative; display: flex; align-items: center; justify-content: center; padding: 34px;
  background: linear-gradient(150deg, var(--blue-50), #fff); border-left: 1px solid var(--line);
}
.folio-dark { background: #0b0f14; border-color: #1b2430; color: #fff; }
.folio-dark:hover { border-color: #2b3948; }
.folio-dark .fc-viz { background: radial-gradient(130% 120% at 72% 26%, #172233, #0b0f14); border-left: 1px solid #1b2430; }

.fc-cat { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-ui); font-size: 12.5px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.folio-dark .fc-cat { color: rgba(255,255,255,.58); }
.fc-cat .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--blue-400); }
.fc-cat .dot.live { background: #22c55e; }
.fc-cat .dot.dev { background: var(--blue-400); }
.fc-name { font-family: var(--font-display); font-weight: 700; font-size: clamp(30px, 4vw, 46px); letter-spacing: -0.05em; margin-top: 14px; line-height: 1; }
.fc-name.sm { font-size: clamp(24px, 3vw, 31px); }
.folio-dark .fc-name { color: #fff; }
.fc-desc { color: var(--ink-soft); font-size: 16px; line-height: 1.5; margin-top: 15px; max-width: 44ch; }
.folio-dark .fc-desc { color: rgba(255,255,255,.72); }
.fc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 22px; }
.fc-chips span { font-family: var(--font-ui); font-size: 12.5px; font-weight: 500; color: var(--ink-soft); background: #fff; border: 1px solid var(--line-strong); border-radius: 999px; padding: 6px 12px; }
.folio-dark .fc-chips span { color: #dbe6f2; background: rgba(255,255,255,.05); border-color: rgba(255,255,255,.16); }
.fc-cta { margin-top: 26px; font-family: var(--font-ui); font-weight: 600; font-size: 15px; display: inline-flex; align-items: center; gap: 8px; color: var(--blue-600); }
.folio-dark .fc-cta { color: #8fbaf0; }
.fc-cta svg { width: 15px; height: 15px; transition: transform .18s ease; }
.folio-card:hover .fc-cta svg { transform: translateX(3px); }
.fc-viz .dg { width: 100%; max-width: 440px; }
.fc-metric { margin-top: 24px; font-family: var(--font-display); font-weight: 700; font-size: 15px; letter-spacing: -0.02em; }

.folio-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.folio-half { padding: 32px; display: flex; flex-direction: column; }
.folio-half .fc-desc { font-size: 15px; }
.folio-half .fc-viz.sm { margin-top: 22px; border-radius: 14px; background: linear-gradient(160deg, var(--blue-50), #fff); border: 1px solid var(--line); padding: 16px; }
.folio-half .fc-cta { margin-top: auto; padding-top: 22px; }

/* =========================================================================
   Node / edge diagram system (dg)
   ========================================================================= */
.dg { display: block; width: 100%; height: auto; }
.dg-edge { fill: none; stroke: var(--blue-300); stroke-width: 2; }
.dg-edge.flow { stroke: var(--blue-400); stroke-dasharray: 4 7; animation: dgdash 1.4s linear infinite; }
.dg-node { fill: #fff; stroke: var(--line-strong); }
.dg-node.on { fill: var(--blue-50); stroke: var(--blue-300); }
.dg-hub { fill: #0e1311; stroke: none; }
.dg-lab { font-family: var(--font-ui); font-weight: 500; font-size: 13px; fill: var(--ink); }
.dg-lab.mut { fill: var(--muted); font-size: 11.5px; }
.dg-lab.inv { fill: #fff; }
.dg-ico { fill: none; stroke: var(--blue-600); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.dg-ico.inv { stroke: #fff; }
.dg-pos { fill: #0f3d24; } .dg-pos-t { fill: #37d98a; font-family: var(--font-ui); font-weight: 600; font-size: 12px; }
@keyframes dgdash { to { stroke-dashoffset: -22; } }
/* dark-card variants */
.folio-dark .dg-edge { stroke: rgba(120,176,230,.42); }
.folio-dark .dg-edge.flow { stroke: var(--blue-400); }
.folio-dark .dg-node { fill: rgba(255,255,255,.055); stroke: rgba(255,255,255,.18); }
.folio-dark .dg-node.on { fill: rgba(63,131,214,.24); stroke: rgba(120,176,230,.55); }
.folio-dark .dg-hub { fill: var(--blue-500); }
.folio-dark .dg-lab { fill: #eef4fb; }
.folio-dark .dg-lab.mut { fill: rgba(255,255,255,.5); }
.folio-dark .dg-ico { stroke: #bcd6f5; }

/* =========================================================================
   Thesis — "data moving as one"
   ========================================================================= */
.thesis-panel { margin-top: 44px; background: linear-gradient(162deg, var(--blue-50), #fff 62%); border: 1px solid var(--line); border-radius: 26px; padding: clamp(20px, 3vw, 34px); box-shadow: var(--shadow-sm); }
.thesis-legend { display: flex; flex-wrap: wrap; gap: 14px 26px; justify-content: center; margin-top: 20px; font-family: var(--font-ui); font-size: 12.5px; color: var(--ink-soft); }
.thesis-legend span { display: inline-flex; align-items: center; gap: 8px; }
.thesis-legend .k { width: 12px; height: 12px; border-radius: 4px; }
.thesis-legend .k.scatter { background: var(--blue-200); }
.thesis-legend .k.core { background: #0e1311; }
.thesis-legend .k.one { background: var(--blue-500); }

/* =========================================================================
   Feature bento (product pages) — image-3 style
   ========================================================================= */
.diagram-card { background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: clamp(20px, 3vw, 30px); box-shadow: var(--shadow-md); }
.fbento { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: minmax(150px, auto); gap: 16px; margin-top: 44px; }
.fb { position: relative; overflow: hidden; border-radius: 20px; border: 1px solid var(--line); padding: 26px; background: #fff; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.fb h4 { font-family: var(--font-display); font-size: 20px; letter-spacing: -0.03em; }
.fb p { color: var(--ink-soft); font-size: 14.5px; margin-top: 8px; line-height: 1.45; }
.fb .fb-grow { margin-top: auto; }
.fb--wide { grid-column: span 2; }
.fb--tall { grid-row: span 2; }
.fb--blue { background: linear-gradient(158deg, var(--blue-500), var(--blue-600)); border-color: transparent; color: #fff; }
.fb--blue h4, .fb--blue p { color: #fff; }
.fb--blue p { color: rgba(255,255,255,.85); }
.fb--dark { background: #0b0f14; border-color: #1b2430; color: #fff; }
.fb--dark h4 { color: #fff; } .fb--dark p { color: rgba(255,255,255,.66); }
.fb--teal { background: linear-gradient(160deg, #d3f2ea, #eafbf6); border-color: #cdeee6; }
.fb-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.fb-chips b { font-family: var(--font-ui); font-weight: 600; font-size: 13px; color: #fff; background: var(--blue-500); border-radius: 999px; padding: 8px 14px; display: inline-flex; align-items: center; gap: 7px; }
.fb-chips b.ghost { background: #fff; color: var(--blue-600); border: 1px solid var(--blue-200); }
.fb-mock { margin-top: 18px; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px; box-shadow: var(--shadow-sm); }
.fb-mock .row { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-family: var(--font-ui); font-size: 12px; color: var(--ink-soft); padding: 5px 0; }
.fb-mock .row b { font-weight: 600; color: var(--ink); }
.fb-mock .tag-ok { font-family: var(--font-ui); font-weight: 600; font-size: 11px; color: #1f8a4c; background: #e7f6ec; border-radius: 999px; padding: 4px 9px; display: inline-flex; align-items: center; gap: 5px; }
.fb-portrait { margin: 18px -26px -26px; height: 210px; background: linear-gradient(160deg, var(--blue-400), var(--blue-600)); position: relative; }

/* =========================================================================
   Responsive for new components
   ========================================================================= */
@media (max-width: 900px) {
  .folio-wide { grid-template-columns: 1fr; min-height: 0; }
  .folio-wide .fc-viz { border-left: 0; border-top: 1px solid var(--line); order: 2; }
  .folio-dark .fc-viz { border-top: 1px solid #1b2430; }
  .folio-wide .fc-body { padding: 34px; order: 1; }
  .folio-row { grid-template-columns: 1fr; }
  .fbento { grid-template-columns: 1fr 1fr; }
  .fb--tall { grid-row: span 1; }
}
@media (max-width: 620px) {
  .fbento { grid-template-columns: 1fr; }
  .fb--wide { grid-column: span 1; }
}
@media (prefers-reduced-motion: reduce) {
  .dg-edge.flow { animation: none !important; }
  .scroll-cue { display: none !important; }
}

/* =========================================================================
   Reveal animation + reduced motion
   ========================================================================= */
.reveal { opacity: 0; transform: translateY(18px); }
.reveal.in { opacity: 1; transform: none; transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.2,1); }

/* =========================================================================
   Mobile drawer
   ========================================================================= */
.nav-drawer { display: none; }

@media (max-width: 1024px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .p-dealy, .p-bestshot, .p-construction, .p-camp { grid-column: span 1; }
  .studio-grid, .split { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .nav-menu, .nav-cta .nav-login { display: none; }
  .nav-cta .lang-switch { display: none; }
  .nav-toggle { display: block; }
  .nav-inner { gap: 16px; }
  .stats { grid-template-columns: 1fr; gap: 28px; text-align: center; }
  .cols3 { grid-template-columns: 1fr; }
  .chooser { grid-template-columns: 1fr; }
  .feature-list, .form .row { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .hero { height:100svh; min-height:820px; }
  .hero-sticky { min-height:820px; }
  .hero-bg { object-position:61% 58%; filter:contrast(1.14) saturate(.9); }
  .hero-scrim { background:linear-gradient(to bottom,rgba(255,255,255,.58) 0%,rgba(255,255,255,.78) 55%,rgba(255,255,255,.9) 100%); }
  .hero-phase { justify-content:flex-start; padding:132px 24px 218px; }
  .hero h1 { font-size:clamp(48px,15vw,62px); max-width:8.8ch; letter-spacing:-.055em; }
  .hero-eyebrow { margin-bottom:14px; font-size:10px; }
  .hero-sub { margin-top:18px; font-size:16px; max-width:31ch; }
  .hero .hero-cta { margin-top:22px; gap:9px; }
  .hero .hero-cta .btn { padding:12px 16px; font-size:14px; }
  .hero .hero-note { margin-top:16px; max-width:28ch; font-size:11.5px; line-height:1.4; }
  .hero-products { left:14px; right:14px; bottom:16px; grid-template-columns:1fr 1fr; border-radius:15px; }
  .hero-products a { padding:12px 13px; }
  .hero-products a + a { border-left:1px solid rgba(220,227,236,.9); }
  .hero-products a:nth-child(3) { border-left:0; }
  .hero-products a:nth-child(n+3) { border-top:1px solid rgba(220,227,236,.9); }
  .hero-products span { font-size:12px; }
  .hero-products small { font-size:10px; }
  .hero-products b { margin-top:7px; font-size:8.5px; }

  .nav-drawer.open { display: block; position: fixed; inset: 0; z-index: 60; }
  .nav-drawer .scrim { position: absolute; inset: 0; background: rgba(8,20,38,.34); }
  .nav-drawer .sheet {
    position: absolute; top: 0; right: 0; bottom: 0; width: min(84vw, 340px);
    background: #fff; box-shadow: var(--shadow-lg); padding: 22px; display: flex; flex-direction: column; gap: 6px;
    transform: translateX(0);
  }
  .nav-drawer .sheet .dclose { align-self: flex-end; background: none; border: 0; width: 40px; height: 40px; }
  .nav-drawer .sheet a { font-family: var(--font-ui); font-weight: 500; font-size: 17px; padding: 12px 8px; border-radius: 10px; }
  .nav-drawer .sheet a:hover { background: var(--blue-50); }
  .nav-drawer .sheet hr { border: 0; border-top: 1px solid var(--line); margin: 10px 0; }
  .nav-drawer .sheet .btn { justify-content: center; margin-top: 4px; }
  .nav-drawer .sheet .lang-switch { align-self: flex-start; margin: 8px 0 0 8px; }
}
@media (max-width: 620px) {
  .bento { grid-template-columns: 1fr; }
  .p-card { min-height: 0; }
}
@media (max-width: 460px) {
  .foot-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .hero-bg { opacity: 1 !important; animation: none !important; }
}
