/* ============================================================
   JARY AI — Corporate site
   Design system: light, neutral, corporate, one accent
   ============================================================ */

:root {
  /* ---- Neutrals (essentially neutral, faint cool cast) ---- */
  --bg:        #FAFAFB;
  --surface:   #FFFFFF;
  --surface-2: #F3F3F6;
  --surface-3: #ECECF1;
  --ink:       #141318;
  --ink-2:     #595963;
  --ink-3:     #8E8E9A;
  --line:      #E6E6EC;
  --line-2:    #D7D7DF;

  /* ---- Accent (tweakable) ---- */
  --accent:        #5B2EE5;
  --accent-strong: #4A22C7;
  --accent-soft:   #EEE9FD;
  --accent-ink:    #FFFFFF;

  /* ---- Brand mark gradient (logo only — never recolor) ---- */
  --brand-a: #F0356D;
  --brand-b: #B14FE6;

  /* ---- Type ---- */
  --font-display: "Schibsted Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-text:    "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-mono:    "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --font-brand:   -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;

  /* ---- Geometry ---- */
  --r-sm: 8px;
  --r:    14px;
  --r-lg: 22px;
  --maxw: 1200px;
  --gutter: clamp(20px, 5vw, 64px);

  /* ---- Shadow ---- */
  --shadow-sm: 0 1px 2px rgba(20,19,24,.04), 0 1px 1px rgba(20,19,24,.03);
  --shadow:    0 4px 24px -8px rgba(20,19,24,.12), 0 2px 8px -4px rgba(20,19,24,.08);
  --shadow-lg: 0 24px 60px -20px rgba(20,19,24,.22), 0 8px 24px -12px rgba(20,19,24,.12);

  --ease: cubic-bezier(.22,.61,.36,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  letter-spacing: -0.003em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.025em;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

/* ---- Layout primitives ---- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
section { position: relative; }
.section-pad { padding-block: clamp(72px, 11vw, 152px); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.eyebrow::before {
  content: "";
  width: 22px; height: 1px;
  background: var(--accent);
  opacity: .55;
}

.lead { color: var(--ink-2); font-size: clamp(1.05rem, 1.6vw, 1.3rem); line-height: 1.5; }
.muted { color: var(--ink-2); }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  --pad-y: 13px; --pad-x: 22px;
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  font-family: var(--font-text);
  font-weight: 600; font-size: 15.5px; letter-spacing: -0.01em;
  padding: var(--pad-y) var(--pad-x);
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .25s var(--ease), background .25s var(--ease), border-color .25s var(--ease), box-shadow .25s var(--ease), color .2s var(--ease);
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--accent-strong); box-shadow: var(--shadow); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--ink); background: var(--surface); transform: translateY(-1px); }
.btn-lg { --pad-y: 16px; --pad-x: 28px; font-size: 16.5px; }
.btn .arr { transition: transform .3s var(--ease); }
.btn:hover .arr { transform: translateX(3px); }

.txtlink {
  display: inline-flex; align-items: center; gap: 7px;
  font-weight: 600; color: var(--accent); font-size: 15px;
}
.txtlink .arr { transition: transform .3s var(--ease); }
.txtlink:hover .arr { transform: translateX(4px); }

/* ============================================================
   Header / nav
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background .3s var(--ease);
}
.site-header.scrolled { border-bottom-color: var(--line); }
.nav {
  height: 70px;
  display: flex; align-items: center; justify-content: space-between; gap: 28px;
}
.nav-links { display: flex; align-items: center; gap: 30px; }
.nav-links a {
  font-size: 15px; font-weight: 500; color: var(--ink-2);
  transition: color .2s var(--ease); position: relative;
}
.nav-links a:hover { color: var(--ink); }
.nav-cta { display: flex; align-items: center; gap: 14px; }
.nav-toggle { display: none; }

/* Brand mark */
.brand { display: inline-flex; align-items: center; gap: 11px; flex: none; }
.brand-logo-img { height: 30px; width: auto; display: block; flex: none; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(135deg, var(--brand-a), var(--brand-b));
  position: relative; flex: none;
  box-shadow: 0 2px 10px -2px color-mix(in srgb, var(--brand-a) 50%, transparent);
}
.brand-mark::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(135deg, transparent 38%, rgba(255,255,255,.92) 38%, rgba(255,255,255,.92) 50%, transparent 50%);
  border-radius: inherit;
}
.brand-word { font-family: var(--font-text); font-weight: 600; font-size: 18.5px; letter-spacing: -0.012em; white-space: nowrap; }
.brand-word b { font-weight: 600; }
.brand-word span { color: var(--ink-2); font-weight: 500; }

/* ============================================================
   Hero
   ============================================================ */
.hero { padding-top: clamp(56px, 9vw, 110px); padding-bottom: clamp(40px, 6vw, 72px); overflow: hidden; }
.hero-grid {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(32px, 5vw, 72px); align-items: center;
}
.hero h1 {
  font-size: clamp(2.7rem, 6vw, 5rem);
  letter-spacing: -0.035em;
}
.hero h1 .accentword { color: var(--accent); }
.hero-sub { margin-top: 26px; max-width: 30ch; }
.hero-actions { margin-top: 36px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-tag {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono); font-size: 12.5px; letter-spacing: .04em; color: var(--ink-2);
  background: var(--surface); border: 1px solid var(--line);
  padding: 7px 14px 7px 11px; border-radius: 100px; margin-bottom: 26px;
  box-shadow: var(--shadow-sm);
}
.hero-tag .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }

/* Hero visual — cycling product scenes */
.hero-visual {
  position: relative; aspect-ratio: 4/4.4; border-radius: var(--r-lg);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-lg);
  overflow: hidden; display: flex; flex-direction: column;
}
.hv-bar { height: 46px; flex: 0 0 auto; border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: 7px; padding-inline: 16px; }
.hv-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--surface-3); }
.hv-app { margin-left: auto; display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-mono); font-size: 11px; letter-spacing: .02em; color: var(--ink-2); }
.hv-app i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.hv-app b { font-family: var(--font-mono); font-weight: 500; color: var(--ink); }

/* stage holds the three cross-faded scenes */
.hv-stage { position: relative; flex: 1 1 auto; min-height: 0; }
.hv-scene { position: absolute; inset: 0; padding: 20px; display: flex; flex-direction: column; gap: 14px; opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease), transform .5s var(--ease); pointer-events: none; }
.hv-scene.active { opacity: 1; transform: none; }

/* shared: prompt row, mid, footer */
.hv-ask { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.hv-ava { width: 30px; height: 30px; border-radius: 8px; background: linear-gradient(135deg, var(--brand-a), var(--brand-b)); flex: 0 0 auto; }
.hv-q { font-family: var(--font-mono); font-size: 12px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hv-scene-mid { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; justify-content: center; gap: 11px; }
.hv-foot { flex: 0 0 auto; display: flex; align-items: baseline; gap: 9px; border-top: 1px solid var(--line); padding-top: 13px; }
.hv-count { font-family: var(--font-display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; color: var(--ink); }
.hv-footlabel { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-3); line-height: 1.45; }

/* AskJary — building a second brain */
.hv-learn { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-2); }
.hv-pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 var(--accent-soft); animation: hvPing 1.6s var(--ease) infinite; flex: 0 0 auto; }
.hv-memlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.hv-memlist li { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--ink); background: var(--surface-2); border: 1px solid var(--line); border-radius: 9px; padding: 9px 12px; opacity: 0; transform: translateX(-8px); }
.hv-scene.active .hv-memlist li { animation: hvSlideIn .45s var(--ease) forwards; }
.hv-scene.active .hv-memlist li:nth-child(1){animation-delay:.30s}
.hv-scene.active .hv-memlist li:nth-child(2){animation-delay:.55s}
.hv-scene.active .hv-memlist li:nth-child(3){animation-delay:.80s}
.hv-scene.active .hv-memlist li:nth-child(4){animation-delay:1.05s}
.hv-scene.active .hv-memlist li:nth-child(5){animation-delay:1.30s}
.hv-di { width: 16px; height: 16px; border-radius: 5px; background: var(--accent-soft); border: 1px solid var(--accent); flex: 0 0 auto; position: relative; }
.hv-di::after { content: ""; position: absolute; left: 4px; top: 1px; width: 5px; height: 9px; border: solid var(--accent); border-width: 0 2px 2px 0; transform: rotate(42deg); }
.hv-mt { flex: 1 1 auto; }
.hv-memlist em { font-family: var(--font-mono); font-style: normal; font-size: 10px; letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }

/* SalesOS — auto-engage queue */
.hv-leads { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.hv-leads li { display: flex; align-items: center; gap: 11px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 9px; padding: 8px 11px; opacity: 0; transform: translateX(-8px); }
.hv-scene.active .hv-leads li { animation: hvSlideIn .4s var(--ease) forwards; }
.hv-scene.active .hv-leads li:nth-child(1){animation-delay:.30s}
.hv-scene.active .hv-leads li:nth-child(2){animation-delay:.55s}
.hv-scene.active .hv-leads li:nth-child(3){animation-delay:.80s}
.hv-scene.active .hv-leads li:nth-child(4){animation-delay:1.05s}
.hv-lav { width: 28px; height: 28px; border-radius: 50%; background: var(--surface-3); color: var(--ink-2); font-family: var(--font-mono); font-size: 10px; display: grid; place-items: center; flex: 0 0 auto; }
.hv-lname { flex: 1 1 auto; display: flex; flex-direction: column; font-size: 13px; color: var(--ink); line-height: 1.25; min-width: 0; }
.hv-lname small { font-family: var(--font-mono); font-size: 10px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hv-pill { font-family: var(--font-mono); font-size: 10px; letter-spacing: .03em; padding: 4px 9px; border-radius: 999px; flex: 0 0 auto; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent); position: relative; padding-left: 19px; }
.hv-pill::before { content: ""; position: absolute; left: 8px; top: 50%; width: 4px; height: 7px; border: solid var(--accent); border-width: 0 1.5px 1.5px 0; transform: translateY(-60%) rotate(42deg); }

/* ProjectOS — mini Gantt */
.hv-gantt { display: flex; flex-direction: column; gap: 12px; }
.hv-grow { display: grid; grid-template-columns: 84px 1fr; align-items: center; gap: 10px; }
.hv-gl { font-family: var(--font-mono); font-size: 10.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hv-track { position: relative; height: 16px; border-radius: 6px; background: var(--surface-2); border: 1px solid var(--line); }
.hv-bar1 { position: absolute; top: 2px; bottom: 2px; left: var(--l); width: 0; background: linear-gradient(90deg, var(--brand-a), var(--brand-b)); border-radius: 5px; opacity: .9; }
.hv-scene.active .hv-bar1 { animation: hvBarGrow .6s var(--ease) forwards; }
.hv-scene.active .hv-grow:nth-child(1) .hv-bar1{animation-delay:.30s}
.hv-scene.active .hv-grow:nth-child(2) .hv-bar1{animation-delay:.55s}
.hv-scene.active .hv-grow:nth-child(3) .hv-bar1{animation-delay:.80s}
.hv-scene.active .hv-grow:nth-child(4) .hv-bar1{animation-delay:1.05s}
.hv-mile, .hv-ship { position: absolute; top: 50%; left: var(--at); width: 11px; height: 11px; transform: translate(-50%,-50%) scale(0); }
.hv-mile { background: var(--accent); border-radius: 2px; transform: translate(-50%,-50%) rotate(45deg) scale(0); }
.hv-ship { background: var(--surface); border: 2px solid var(--ink-2); border-radius: 3px; }
.hv-scene.active .hv-mile { animation: hvMile .4s var(--ease) forwards; }
.hv-scene.active .hv-ship { animation: hvPop .4s var(--ease) forwards; }
.hv-scene.active .hv-grow:nth-child(1) .hv-mile,
.hv-scene.active .hv-grow:nth-child(1) .hv-ship{animation-delay:.70s}
.hv-scene.active .hv-grow:nth-child(2) .hv-mile,
.hv-scene.active .hv-grow:nth-child(2) .hv-ship{animation-delay:.95s}
.hv-scene.active .hv-grow:nth-child(3) .hv-mile,
.hv-scene.active .hv-grow:nth-child(3) .hv-ship{animation-delay:1.20s}
.hv-scene.active .hv-grow:nth-child(4) .hv-mile,
.hv-scene.active .hv-grow:nth-child(4) .hv-ship{animation-delay:1.45s}
.hv-chiprow { display: flex; gap: 8px; flex-wrap: wrap; }
.hv-chip { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: .03em; color: var(--ink-2); background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 4px 8px; }
.hv-chip.on { color: var(--accent); border-color: var(--accent); background: var(--accent-soft); }

@keyframes hvSlideIn { to { opacity: 1; transform: translateX(0); } }
@keyframes hvBarGrow { to { width: var(--w); } }
@keyframes hvPop { to { transform: translate(-50%,-50%) scale(1); } }
@keyframes hvMile { to { transform: translate(-50%,-50%) rotate(45deg) scale(1); } }
@keyframes hvPing { 0% { box-shadow: 0 0 0 0 var(--accent-soft); } 70%,100% { box-shadow: 0 0 0 7px transparent; } }
@media (prefers-reduced-motion: reduce) {
  .hv-pulse { animation: none; }
  .hv-scene.active .hv-memlist li, .hv-scene.active .hv-leads li { animation: none; opacity: 1; transform: none; }
  .hv-scene.active .hv-bar1 { animation: none; width: var(--w); }
  .hv-scene.active .hv-mile { animation: none; transform: translate(-50%,-50%) rotate(45deg) scale(1); }
  .hv-scene.active .hv-ship { animation: none; transform: translate(-50%,-50%) scale(1); }
}

/* ============================================================
   Trust strip
   ============================================================ */
.trust { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.trust-inner { display: flex; align-items: center; gap: clamp(24px, 5vw, 60px); padding-block: 26px; flex-wrap: wrap; }
.trust-label { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); }
.trust-logos { display: flex; align-items: center; gap: clamp(22px, 4vw, 48px); flex-wrap: wrap; }
.trust-logos span { font-family: var(--font-display); font-weight: 600; font-size: 16px; color: var(--ink-2); letter-spacing: -0.02em; white-space: nowrap; }

/* ============================================================
   Generic section header
   ============================================================ */
.sec-head { max-width: 56ch; margin-bottom: clamp(40px, 5vw, 64px); }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head.center .eyebrow { justify-content: center; }
.sec-head h2 { font-size: clamp(2rem, 4vw, 3.2rem); margin-top: 20px; }
.sec-head p { margin-top: 20px; }

/* ============================================================
   Thesis (problem -> framework)
   ============================================================ */
.thesis { background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.thesis-quote {
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.7rem, 3.4vw, 2.9rem); letter-spacing: -0.03em; line-height: 1.1;
  max-width: 20ch;
}
.thesis-quote em { font-style: normal; color: var(--accent); }
.layers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-top: 56px; }
.layer {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r);
  padding: 22px; transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.layer:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--line-2); }
.layer .lk { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .1em; text-transform: uppercase; }
.layer h4 { font-size: 1.35rem; margin: 12px 0 8px; }
.layer p { font-size: 14.5px; color: var(--ink-2); }
.layer .glyph { width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--line-2); display: grid; place-items: center; }
.layer .glyph i { width: 12px; height: 12px; background: var(--accent); display: block; }
.layer:nth-child(1) .glyph i { border-radius: 50%; }
.layer:nth-child(2) .glyph i { border-radius: 2px; }
.layer:nth-child(3) .glyph i { transform: rotate(45deg); }
.layer:nth-child(4) .glyph i { border-radius: 50%; background: transparent; border: 3px solid var(--accent); }

/* ============================================================
   Pillars (three products)
   ============================================================ */
.pillars-stack { display: grid; gap: 20px; }
/* GRID layout variant */
body.pillars-grid .pillars-stack { grid-template-columns: repeat(3, 1fr); }
body.pillars-grid .pillar { grid-template-columns: 1fr; }
body.pillars-grid .pillar-visual { order: -1; aspect-ratio: 16/10; }
body.pillars-grid .pillar-body { padding: 28px; }

.pillar {
  display: grid; grid-template-columns: 1fr 1fr; align-items: stretch;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  overflow: hidden; transition: box-shadow .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease);
}
.pillar:hover { box-shadow: var(--shadow-lg); border-color: var(--line-2); }
.pillar:nth-child(even) .pillar-visual { order: -1; }
body.pillars-grid .pillar:nth-child(even) .pillar-visual { order: -1; }
.pillar-body { padding: clamp(28px, 4vw, 52px); display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
.pillar-kicker { display: flex; align-items: center; gap: 12px; }
.pillar-num { font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); }
.pillar-name { font-size: clamp(1.7rem, 2.6vw, 2.4rem); letter-spacing: -0.03em; }
.pillar-name span { color: var(--ink-3); font-weight: 600; }
.pillar-desc { color: var(--ink-2); font-size: 1.02rem; }
.pillar-feats { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 2px; }
.pillar-feats span {
  font-size: 13px; color: var(--ink-2); background: var(--surface-2);
  border: 1px solid var(--line); border-radius: 100px; padding: 6px 13px;
}
.pillar-foot { margin-top: auto; padding-top: 8px; }
.pillar-visual { position: relative; background: var(--surface-2); border-left: 1px solid var(--line); min-height: 280px; overflow: hidden; }
body.pillars-grid .pillar-visual { border-left: none; border-bottom: 1px solid var(--line); }

/* striped placeholder fill */
.ph {
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(45deg, var(--surface-3) 0 10px, transparent 10px 20px);
  display: grid; place-items: center;
}
.ph .ph-tag {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-3);
  background: var(--surface); border: 1px dashed var(--line-2); border-radius: 7px; padding: 7px 12px;
  letter-spacing: .02em;
}
.pillar-visual image-slot { position: absolute; inset: 0; width: 100%; height: 100%; }

/* Real product screenshot inside a pillar visual (browser-framed) */
.pillar-shot { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--surface); }
.pillar-shot .shot-bar { display: flex; align-items: center; gap: 7px; padding: 11px 14px; border-bottom: 1px solid var(--line); background: var(--surface); flex: 0 0 auto; }
.pillar-shot .shot-bar span { width: 9px; height: 9px; border-radius: 50%; background: var(--surface-3); }
.pillar-shot img { flex: 1 1 auto; min-height: 0; width: 100%; object-fit: cover; object-position: top left; display: block; }

/* App mock (coded product-UI panel) */
.appmock { position: absolute; inset: 0; padding: clamp(18px, 3vw, 30px); display: flex; align-items: center; }
.appwin { width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); overflow: hidden; }
.appbar { display: flex; align-items: center; gap: 10px; padding: 12px 15px; border-bottom: 1px solid var(--line); }
.appbar .dots { display: flex; gap: 6px; }
.appbar .dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--surface-3); display: block; }
.appbar .title { font-family: var(--font-mono); font-size: 11px; color: var(--ink-3); letter-spacing: .03em; }
.appbar .brainpill { margin-left: auto; display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-mono); font-size: 10px; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent); border-radius: 100px; padding: 3px 9px; }
.appbar .brainpill i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); display: block; }
.appbody { padding: 16px; display: grid; gap: 12px; }
.msg { display: grid; grid-template-columns: 26px 1fr; gap: 10px; align-items: start; }
.msg .av { width: 26px; height: 26px; border-radius: 7px; flex: none; }
.msg .av.user { background: var(--surface-3); }
.msg .av.jary { background: linear-gradient(135deg, var(--brand-a), var(--brand-b)); }
.bubble { border-radius: 10px; padding: 10px 12px; font-size: 12.5px; line-height: 1.45; }
.bubble.user { background: var(--surface-2); color: var(--ink-2); }
.bubble.jary { background: var(--surface); border: 1px solid var(--line); color: var(--ink); }
.bubble .ln { height: 7px; border-radius: 4px; background: var(--surface-3); margin: 6px 0; }
.bubble .ln.w1 { width: 92%; } .bubble .ln.w2 { width: 70%; } .bubble .ln.w3 { width: 80%; }
.actioncard { border: 1px solid var(--accent); background: var(--accent-soft); border-radius: 10px; padding: 11px 12px; display: grid; gap: 9px; }
.actioncard .ah2 { font-family: var(--font-mono); font-size: 10px; letter-spacing: .05em; color: var(--accent); text-transform: uppercase; }
.actioncard .arow { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.actioncard .atxt { font-size: 12px; font-weight: 600; color: var(--ink); }
.actioncard .abtns { display: flex; gap: 7px; }
.actioncard .abtn { font-size: 10.5px; font-weight: 600; border-radius: 6px; padding: 4px 10px; }
.actioncard .abtn.ok { background: var(--accent); color: #fff; }
.actioncard .abtn.no { background: var(--surface); border: 1px solid var(--line-2); color: var(--ink-2); }
.appchips { display: flex; gap: 7px; flex-wrap: wrap; padding-top: 2px; }
.appchips span { font-family: var(--font-mono); font-size: 9.5px; color: var(--ink-2); background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 3px 7px; }

/* Mock helpers — KPI tiles, banners, health rows (xOS product mocks) */
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.kpi { border: 1px solid var(--line); border-radius: 9px; padding: 10px 11px; background: var(--surface-2); }
.kpi .kl { font-family: var(--font-mono); font-size: 9px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); }
.kpi .kv { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; letter-spacing: -0.02em; margin-top: 3px; }
.kpi .kv small { font-size: .52em; color: var(--ink-3); font-weight: 600; }
.kpi .kv .up { color: #1f9d57; } .kpi .kv .dn { color: #d99a16; }
.sla { display: flex; align-items: center; gap: 9px; border-radius: 8px; padding: 9px 11px; font-size: 11.5px; font-weight: 600; background: color-mix(in srgb, #e5484d 11%, var(--surface)); color: #b5363a; border: 1px solid color-mix(in srgb, #e5484d 28%, var(--surface)); }
.sla .d { width: 7px; height: 7px; border-radius: 50%; background: #e5484d; flex: none; }
.hrow { display: grid; grid-template-columns: auto 1fr auto; gap: 11px; align-items: center; border: 1px solid var(--line); border-radius: 9px; padding: 11px 12px; }
.hdot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.hdot.green { background: #1f9d57; } .hdot.amber { background: #d99a16; } .hdot.red { background: #e5484d; }
.hmeta { font-family: var(--font-mono); font-size: 10px; color: var(--ink-3); }
.conf { font-family: var(--font-mono); font-size: 11px; font-weight: 500; color: var(--accent); }
.mrow { display: flex; align-items: center; gap: 8px; }

/* Brand logo drop-slot (header + footer) */
.brand-logo { width: 30px; height: 30px; flex: none; border-radius: 8px; overflow: hidden; }
.brand-logo::part(empty) { font-size: 0; }

/* xOS mini-grid inside pillar visual */
.xos-grid { position: absolute; inset: 0; padding: 26px; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-content: center; }
.xos-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; box-shadow: var(--shadow-sm); transition: transform .3s var(--ease); }
.xos-card:hover { transform: translateY(-3px); }
.xos-card .xt { font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: -0.02em; }
.xos-card .xd { font-size: 12px; color: var(--ink-2); margin-top: 4px; line-height: 1.45; }
.xos-card .xglyph { width: 26px; height: 26px; border-radius: 7px; background: var(--accent-soft); border: 1px solid var(--accent); margin-bottom: 11px; }
.xos-card.more { background: var(--accent-soft); border-color: var(--accent); display: grid; place-items: center; }
.xos-card.more .xt { color: var(--accent); }

/* Academy track ladder inside pillar visual */
.acad-ladder { position: absolute; inset: 0; padding: 30px 26px; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.acad-step { display: flex; align-items: stretch; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; box-shadow: var(--shadow-sm); transition: transform .3s var(--ease); }
.acad-step[data-step="2"] { margin-left: 26px; }
.acad-step[data-step="3"] { margin-left: 52px; background: var(--accent-soft); border-color: var(--accent); }
.acad-step:hover { transform: translateY(-3px); }
.acad-rail { display: flex; align-items: center; }
.acad-num { font-family: var(--font-mono); font-size: 12px; color: var(--ink-3); width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--line-2); border-radius: 8px; }
.acad-step[data-step="3"] .acad-num { color: var(--accent); border-color: var(--accent); }
.acad-name { font-family: var(--font-display); font-weight: 700; font-size: 16px; letter-spacing: -0.02em; }
.acad-step[data-step="3"] .acad-name { color: var(--accent); }
.acad-meta { font-size: 12px; color: var(--ink-2); margin-top: 3px; line-height: 1.45; }

/* ============================================================
   ATP — 90-day program
   ============================================================ */
.atp { background: var(--ink); color: #F4F4F6; }
.atp .eyebrow { color: #C7B6FF; }
.atp .eyebrow::before { background: #C7B6FF; }
.atp h2 { color: #fff; font-size: clamp(2rem, 4vw, 3.2rem); }
.atp .lead { color: #ADADB8; }
.atp-head { display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: end; margin-bottom: 56px; }
.atp-badge {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; color: #C7B6FF;
  border: 1px solid #34333D; border-radius: 100px; padding: 8px 15px; display: inline-flex; gap: 9px; align-items: center;
}
.phases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.phase {
  border: 1px solid #2C2B34; border-radius: var(--r); padding: 26px; background: #1B1A21;
  transition: transform .3s var(--ease), border-color .3s var(--ease), background .3s var(--ease);
}
.phase:hover { transform: translateY(-4px); border-color: #45434F; background: #1F1E26; }
.phase .pw { font-family: var(--font-mono); font-size: 11px; color: #7E7D8C; letter-spacing: .1em; text-transform: uppercase; }
.phase h4 { color: #fff; font-size: 1.4rem; margin: 12px 0 10px; }
.phase p { font-size: 14.5px; color: #A6A6B2; }
.phase .pnum { font-family: var(--font-display); font-weight: 700; font-size: 2.6rem; color: #34333D; line-height: 1; letter-spacing: -.04em; }
.atp-deliver { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 10px; }
.atp-deliver span { font-size: 13.5px; color: #C9C9D2; border: 1px solid #2C2B34; border-radius: 100px; padding: 7px 14px; }
.atp-deliver span b { color: #fff; font-weight: 600; }

/* ============================================================
   Why Jary — differentiators
   ============================================================ */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.feat {
  border: 1px solid var(--line); border-radius: var(--r); padding: 28px; background: var(--surface);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.feat:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.feat .fnum { font-family: var(--font-mono); font-size: 12px; color: var(--accent); letter-spacing: .08em; }
.feat h4 { font-size: 1.3rem; margin: 14px 0 9px; }
.feat p { font-size: 14.5px; color: var(--ink-2); }

/* ============================================================
   Stats
   ============================================================ */
.stats { background: var(--surface-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat { border-left: 2px solid var(--accent); padding-left: 20px; }
.stat .sn { font-family: var(--font-display); font-weight: 700; font-size: clamp(2.4rem, 4vw, 3.4rem); letter-spacing: -0.04em; line-height: 1; }
.stat .sn small { font-size: .5em; font-weight: 600; color: var(--ink-3); margin-left: 2px; }
.stat .sl { margin-top: 12px; font-size: 14px; color: var(--ink-2); }

/* ============================================================
   CTA band
   ============================================================ */
.cta-band { padding-block: clamp(72px, 10vw, 140px); text-align: center; }
.cta-card {
  background: var(--ink); color: #fff; border-radius: var(--r-lg);
  padding: clamp(44px, 7vw, 88px) var(--gutter); position: relative; overflow: hidden;
}
.cta-card::before {
  content: ""; position: absolute; width: 480px; height: 480px; border-radius: 50%;
  top: -60%; left: 50%; transform: translateX(-50%);
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 60%, transparent), transparent 62%);
  opacity: .5; pointer-events: none;
}
.cta-card h2 { font-size: clamp(2.1rem, 4.5vw, 3.6rem); color: #fff; position: relative; }
.cta-card p { color: #B7B7C2; margin: 20px auto 0; max-width: 46ch; position: relative; }
.cta-card .hero-actions { justify-content: center; position: relative; }
.cta-card .btn-ghost { color: #fff; border-color: #3A3942; }
.cta-card .btn-ghost:hover { border-color: #fff; background: transparent; }
.cta-tag { font-family: var(--font-mono); font-size: 12.5px; color: #9B8CFF; letter-spacing: .04em; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer { background: var(--bg); padding-block: 64px 40px; border-top: 1px solid var(--line); }
.foot-top { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 40px; padding-bottom: 48px; border-bottom: 1px solid var(--line); }
.foot-brand p { color: var(--ink-2); font-size: 14.5px; margin-top: 16px; max-width: 34ch; }
.foot-col h5 { font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 16px; font-weight: 500; }
.foot-col a { display: block; font-size: 14.5px; color: var(--ink-2); padding: 5px 0; transition: color .2s var(--ease); }
.foot-col a:hover { color: var(--ink); }
.foot-bottom { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 28px; flex-wrap: wrap; }
.foot-bottom small { color: var(--ink-3); font-size: 13px; }
.foot-meta { display: flex; gap: 22px; flex-wrap: wrap; }
.foot-meta span { font-size: 13px; color: var(--ink-3); }

/* ============================================================
   Reveal-on-scroll
   ============================================================ */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .07s; }
.reveal[data-d="2"] { transition-delay: .14s; }
.reveal[data-d="3"] { transition-delay: .21s; }
.reveal[data-d="4"] { transition-delay: .28s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 460px; }
  .layers { grid-template-columns: repeat(2, 1fr); }
  .atp-head { grid-template-columns: 1fr; gap: 24px; }
  .phases { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 36px 24px; }
  .pillar, body.pillars-grid .pillars-stack { grid-template-columns: 1fr; }
  .pillar-visual, .pillar:nth-child(even) .pillar-visual { order: -1; min-height: 240px; }
  .foot-top { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  .layers { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; }
  .foot-top { grid-template-columns: 1fr; }
  .hero-tag { margin-bottom: 18px; }
}

/* Nav collapses earlier so 5 links never crowd the CTAs */
@media (max-width: 940px) {
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-links.open {
    display: flex; position: absolute; top: 70px; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 4px;
    background: var(--surface); border-bottom: 1px solid var(--line);
    padding: 16px var(--gutter) 22px;
  }
  .nav-links.open a { padding: 10px 0; font-size: 17px; width: 100%; }
}

/* Hide tweaks react root entirely until mounted */
#tweaks-root:empty { display: none; }

/* ============================ MEGA MENU ============================ */
.nav-item { position: relative; display: inline-flex; align-items: center; }
.mega-trigger { display: inline-flex; align-items: center; gap: 5px; }
.mega-caret { font-size: 9px; opacity: .65; transition: transform .2s var(--ease); }
.nav-item:hover .mega-caret,
.nav-item:focus-within .mega-caret { transform: rotate(180deg); }

.mega-panel {
  position: fixed; left: 0; right: 0; top: 70px; z-index: 90;
  background: var(--surface);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  box-shadow: 0 26px 50px -28px rgba(20, 19, 24, .22);
  opacity: 0; visibility: hidden; transform: translateY(-10px);
  transition: opacity .22s var(--ease), transform .22s var(--ease), visibility .22s;
}
.nav-item:hover > .mega-panel,
.nav-item:focus-within > .mega-panel { opacity: 1; visibility: visible; transform: none; }

.mega-grid {
  display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 22px;
  padding: 26px 0 30px; align-items: stretch;
}
.mega-grid-3 { grid-template-columns: 1.3fr 1fr 1fr; }
.mega-lead { display: flex; flex-direction: column; }
.mega-eyebrow { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); }
.mega-lead h4 { font-size: 1.15rem; letter-spacing: -0.01em; margin: 9px 0 6px; }
.mega-lead p { color: var(--ink-2); font-size: 13.5px; line-height: 1.5; margin: 0 0 14px; }
.mega-all { margin-top: auto; color: var(--accent); font-weight: 600; font-size: 14px; }
.mega-card {
  display: flex; flex-direction: column; gap: 4px; padding: 15px 16px;
  border: 1px solid var(--hairline); border-radius: 14px; background: var(--bg);
  transition: border-color .2s var(--ease), transform .2s var(--ease), background .2s var(--ease);
}
.mega-card:hover { border-color: var(--accent); transform: translateY(-2px); background: var(--surface); }
.mega-card-t { font-weight: 600; color: var(--ink); font-size: 15px; }
.mega-card-d { color: var(--ink-2); font-size: 13px; line-height: 1.4; }

@media (max-width: 940px) {
  .nav-item { display: block; width: 100%; }
  .mega-trigger { width: 100%; }
  .mega-panel {
    position: static; opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; background: transparent;
  }
  .mega-panel .wrap { padding: 0; }
  .mega-grid { grid-template-columns: 1fr; gap: 2px; padding: 2px 0 8px 14px; }
  .mega-lead { display: none; }
  .mega-card { border: 0; padding: 8px 0; border-radius: 0; background: transparent; }
  .mega-card:hover { transform: none; background: transparent; }
  .mega-card-d { display: none; }
}

@media (max-width: 940px) {
  .nav-links.open { max-height: calc(100vh - 70px); overflow-y: auto; }
}

/* ============================ MOBILE OPTIMISATION ============================ */
html { scroll-padding-top: 86px; }                 /* anchor jumps clear the sticky header */
body { overflow-x: clip; }                         /* prevent horizontal jiggle (sticky-safe) */
* { -webkit-tap-highlight-color: rgba(91, 46, 229, .12); }
img, svg, video { max-width: 100%; height: auto; }

/* Comfortable tap targets + tighter rhythm on phones */
@media (max-width: 640px) {
  .btn { min-height: 46px; }
  .nav-toggle { min-width: 46px; min-height: 46px; }
  /* Declutter header: drop the secondary CTA, keep the primary compact (NOT the hamburger) */
  .nav-cta .btn-ghost:not(.nav-toggle) { display: none; }
  .nav-cta .btn-primary { padding: 9px 14px !important; font-size: 14px; }
  .nav-cta .btn-primary .arr { display: none; }
  .nav { gap: 14px; }
  /* Full-width, stacked hero CTAs are far easier to tap */
  .hero-actions, .page-hero-actions { flex-direction: column; align-items: stretch; gap: 10px; }
  .hero-actions .btn, .page-hero-actions .btn { width: 100%; justify-content: center; }
}

@media (max-width: 560px) {
  :root { --gutter: 18px; }
  .section-pad { padding-block: clamp(48px, 12vw, 80px); }
  .owns { grid-template-columns: 1fr; }
  /* Bigger touch rows in the open mobile menu */
  .nav-links.open a { padding: 12px 0; }
  .mega-card { min-height: 44px; }
}

/* ============================ UNIVERSAL PROMO BANNER ============================ */
.promo-banner {
  position: fixed; z-index: 150; right: 22px; bottom: 22px; left: auto;
  display: flex; align-items: center; gap: 13px;
  width: 380px; max-width: calc(100vw - 44px); padding: 15px 16px;
  background: var(--surface); color: var(--ink);
  border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 18px 44px -16px rgba(20, 19, 24, .28);
  opacity: 0; transform: translateY(16px); pointer-events: none;
  transition: opacity .3s var(--ease), transform .3s var(--ease);
}
.promo-banner.show { opacity: 1; transform: none; pointer-events: auto; }
.promo-ico { flex: none; width: 44px; height: 44px; font-size: 24px;
  display: grid; place-items: center; border-radius: 12px; background: var(--accent-soft); }
.promo-body { flex: 1 1 auto; min-width: 0; }
.promo-badge { display: inline-block; font-family: var(--font-mono); font-size: 10px;
  letter-spacing: .07em; text-transform: uppercase; color: var(--accent);
  background: var(--accent-soft); padding: 2px 7px; border-radius: 999px; margin-bottom: 5px; }
.promo-title { font-size: 15px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; }
.promo-title b { color: var(--accent); font-weight: 700; }
.promo-sub { font-size: 12.5px; color: var(--ink-2); line-height: 1.4; margin-top: 3px; }
.promo-cta { flex: none; display: inline-flex; align-items: center; gap: 6px;
  background: var(--brand-a); color: #fff; font-weight: 700; font-size: 13.5px;
  letter-spacing: -0.01em; padding: 11px 16px; border-radius: 8px; white-space: nowrap;
  box-shadow: 0 6px 16px -6px color-mix(in srgb, var(--brand-a) 70%, transparent);
  transition: background .2s var(--ease), transform .15s var(--ease); }
.promo-cta:hover { background: #D62A5E; transform: translateY(-1px); }
.promo-cta:active { transform: translateY(0); }
.promo-x { position: absolute; top: 6px; right: 9px; border: 0; background: none;
  font-size: 20px; line-height: 1; color: var(--ink-3); cursor: pointer; padding: 4px; }
.promo-x:hover { color: var(--ink); }

@media (max-width: 560px) {
  .promo-banner { right: 12px; left: 12px; bottom: 12px; width: auto; max-width: none;
    flex-wrap: wrap; row-gap: 12px; }
  .promo-body { flex: 1 1 60%; }
  .promo-cta { flex: 1 1 100%; width: 100%; justify-content: center; min-height: 46px; }
}
@media (prefers-reduced-motion: reduce) {
  .promo-banner { transition: opacity .2s linear; transform: none; }
}

/* ============================ LANGUAGE TOGGLE ============================ */
.lang-toggle {
  display: inline-flex; align-items: center; gap: 2px; flex: none;
  padding: 4px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); cursor: pointer; font-family: var(--font-text); line-height: 1;
}
.lang-toggle span {
  font-size: 12px; font-weight: 600; color: var(--ink-3);
  padding: 5px 9px; border-radius: 999px; transition: background .2s var(--ease), color .2s var(--ease);
}
.lang-toggle span.on { background: var(--accent); color: var(--accent-ink); }
.lang-toggle:hover { border-color: var(--accent); }
html[lang="zh-Hant"] body { font-family: var(--font-text), "PingFang HK", "Noto Sans HK", "Microsoft JhengHei", sans-serif; }
@media (max-width: 640px) {
  .lang-toggle { order: -1; }
  .lang-toggle span { padding: 6px 9px; }
}

/* ============================ FOOTER SOCIAL ============================ */
.foot-social { display: flex; gap: 14px; margin-top: 16px; }
.foot-social a { color: var(--ink-3); display: inline-flex; transition: color .2s var(--ease), transform .2s var(--ease); }
.foot-social a:hover { color: var(--accent); transform: translateY(-2px); }
.foot-social svg { width: 18px; height: 18px; display: block; flex: none; }

/* ============================ HERO · SECOND BRAIN / LLM WIKI ============================ */
.bw { position: absolute; inset: 0; padding: 16px 20px 18px; display: flex; flex-direction: column; gap: 10px; }
.bw-actors { flex: 0 0 auto; display: flex; align-items: center; gap: 9px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-2); }
.bw-actor { display: inline-flex; align-items: center; gap: 7px; }
.bw-ava { width: 17px; height: 17px; border-radius: 5px; flex: none; transition: box-shadow .25s var(--ease); }
.bw-ava.you { background: var(--ink); }
.bw-ava.agent { background: linear-gradient(135deg, var(--brand-a), var(--brand-b)); }
.bw-actor.active .bw-ava { box-shadow: 0 0 0 4px var(--accent-soft); }
.bw-actor.active { color: var(--ink); }
.bw-link { color: var(--ink-3); }
.bw-actors-label { margin-left: auto; color: var(--ink-3); }

.bw-graph { flex: 1 1 auto; min-height: 0; display: grid; place-items: center; }
.bw-graph svg { width: 100%; height: 100%; max-height: 168px; overflow: visible; }
.bw-edge { stroke: var(--line-2); stroke-width: 1.5; opacity: 0; transition: opacity .45s var(--ease); }
.bw-edge.on { opacity: 1; }
.bw-node circle { transform-box: fill-box; transform-origin: center; transform: scale(0); transition: transform .45s var(--ease); }
.bw-node.on circle { transform: scale(1); }
.bw-node.you circle { fill: var(--ink); }
.bw-node.agent circle { fill: var(--accent); }
.bw-core circle { fill: url(#bwgrad); }
.bw-core { animation: bwCore 2.6s var(--ease) infinite; transform-box: fill-box; transform-origin: center; }
@keyframes bwCore { 0%,100% { opacity: 1; } 50% { opacity: .82; } }

.bw-now { flex: 0 0 auto; display: flex; align-items: center; gap: 9px; min-height: 22px; }
.bw-chip { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: .05em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; flex: none; }
.bw-chip.you { color: var(--ink); background: var(--surface-3); }
.bw-chip.agent { color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent); }
.bw-act { font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bw-foot { flex: 0 0 auto; display: flex; align-items: baseline; gap: 9px; border-top: 1px solid var(--line); padding-top: 11px; }
@media (prefers-reduced-motion: reduce) { .bw-core { animation: none; } .bw-edge, .bw-node circle { transition: none; } }
