/* ============================================================
   ИИван Кеноби × Т-Банк — Карта продукта
   Системная карта / архитектурная схема. Строгая, техническая.
   Графит + тёплый белый + жёлтый акцент.
   ============================================================ */

:root {
  /* Light (default) */
  --bg: #F4F2EC;
  --surface: #FBFAF6;
  --surface-2: #EFEDE5;
  --grid: #E3E0D6;
  --border: #D2CEC2;
  --border-strong: #B4AF9F;
  --ink: #23211C;
  --ink-2: #4C4A42;
  --muted: #6F6C61;
  --faint: #A8A497;
  --accent: #E6A400;          /* warm yellow */
  --accent-ink: #7A5A00;
  --accent-soft: #F6E4B0;
  --graphite: #2B2A26;
  --link: #8A6A0C;

  /* epistemic tiers */
  --exp: #3F6E4E;   /* опыт — green */
  --exp-bg: #E4EEE4;
  --hyp: #B07514;   /* гипотеза — amber */
  --hyp-bg: #F6E9CC;
  --str: #4A5C86;   /* стратегия — slate blue */
  --str-bg: #E3E8F2;

  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --sans: "Space Grotesk", "Inter", system-ui, -apple-system, sans-serif;
  --body: "Inter", system-ui, -apple-system, sans-serif;

  --maxw: 1240px;
  --radius: 4px;
  --shadow: 0 1px 2px rgba(30,28,22,.06), 0 2px 8px rgba(30,28,22,.05);
  --shadow-lg: 0 8px 30px rgba(30,28,22,.12);
  --nav-h: 60px;
}

[data-theme="dark"] {
  --bg: #16150F;
  --surface: #1D1C15;
  --surface-2: #24231A;
  --grid: #29281F;
  --border: #34332A;
  --border-strong: #4A4839;
  --ink: #ECE9DE;
  --ink-2: #C6C2B4;
  --muted: #928E7F;
  --faint: #625F52;
  --accent: #F2B32A;
  --accent-ink: #F2B32A;
  --accent-soft: #3A3016;
  --graphite: #0F0E09;
  --link: #F2B32A;

  --exp: #7FB98C;  --exp-bg: #1E2C21;
  --hyp: #E4B45B;  --hyp-bg: #322813;
  --str: #93A8D6;  --str-bg: #1E2436;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 2px 8px rgba(0,0,0,.3);
  --shadow-lg: 0 10px 34px rgba(0,0,0,.5);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

body {
  margin: 0;
  font-family: var(--body);
  color: var(--ink);
  background-color: var(--bg);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 44px 44px;
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  transition: background-color .3s, color .3s;
}

h1,h2,h3,h4 { font-family: var(--sans); font-weight: 600; line-height: 1.15; color: var(--ink); letter-spacing: -0.01em; }
p { color: var(--ink-2); }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }

.mono { font-family: var(--mono); }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- Skip link ---------- */
.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: #23211C; padding: 10px 16px; z-index: 200; border-radius: 4px; }
.skip:focus { left: 12px; top: 12px; }

/* ---------- Nav ---------- */
.nav {
  position: sticky; top: 24px; z-index: 100;
  height: var(--nav-h);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
}
.nav .wrap { display: flex; align-items: center; gap: 20px; width: 100%; }
.brand { display: flex; align-items: center; gap: 10px; font-family: var(--sans); font-weight: 600; color: var(--ink); font-size: 15px; white-space: nowrap; }
.brand svg { display: block; }
.brand-name { display: inline-block; letter-spacing: 0; font-kerning: normal; }
.brand .sub { color: var(--muted); font-weight: 400; font-family: var(--mono); font-size: 11px; letter-spacing: .04em; }
.nav-links { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.nav-links a {
  font-family: var(--mono); font-size: 12.5px; color: var(--muted);
  padding: 7px 10px; border-radius: 4px; letter-spacing: .01em;
}
.nav-links a:hover { color: var(--ink); background: var(--surface-2); text-decoration: none; }
.theme-toggle {
  background: var(--surface-2); border: 1px solid var(--border); color: var(--ink);
  width: 38px; height: 34px; border-radius: 5px; cursor: pointer; display: grid; place-items: center;
  transition: background .2s;
}
.theme-toggle:hover { background: var(--accent-soft); }
.theme-toggle svg { width: 17px; height: 17px; }
.nav-burger { display: none; background: none; border: 1px solid var(--border); border-radius: 5px; width: 38px; height: 34px; cursor: pointer; color: var(--ink); }

@media (max-width: 900px) {
  .nav-links { position: fixed; top: var(--nav-h); left: 0; right: 0; flex-direction: column; background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 16px 16px; gap: 2px; display: none; }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 11px 8px; border-bottom: 1px solid var(--grid); }
  .nav-burger { display: grid; place-items: center; margin-left: auto; }
  .nav .theme-toggle { order: 3; }
}

/* ---------- Hero ---------- */
.hero { padding: 76px 0 56px; border-bottom: 1px solid var(--border); position: relative; }
.eyebrow { font-family: var(--mono); font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--accent-ink); display: inline-flex; align-items: center; gap: 8px; }
.eyebrow::before { content: ""; width: 24px; height: 1px; background: var(--accent); }
.hero h1 { font-size: clamp(30px, 5vw, 54px); margin: 20px 0 10px; max-width: 16ch; }
.hero .lede { font-size: clamp(17px, 2vw, 20px); max-width: 62ch; color: var(--ink-2); }
.hero-meta { display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 30px; font-family: var(--mono); font-size: 12.5px; color: var(--muted); }
.hero-meta b { color: var(--ink); font-weight: 600; }
.core-callout {
  margin-top: 34px; padding: 20px 22px; border: 1px solid var(--border-strong);
  border-left: 4px solid var(--accent); background: var(--surface); border-radius: var(--radius);
  max-width: 74ch;
}
.core-callout strong { color: var(--ink); }

/* ---------- Ambition / market scale ---------- */
.ambition {
  background: var(--graphite);
  color: #F4F2EC;
  border-bottom-color: color-mix(in srgb, #F4F2EC 18%, transparent);
}
.ambition .eyebrow { color: var(--accent); }
.ambition h2 {
  color: #F4F2EC;
  font-size: clamp(28px, 4vw, 46px);
  max-width: 18ch;
  margin: 22px 0 14px;
}
.ambition-lede {
  color: #C8C4B8;
  font-size: clamp(17px, 2vw, 20px);
  max-width: 70ch;
  margin: 0 0 36px;
}
.horizon-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(244,242,236,.2);
  border-bottom: 1px solid rgba(244,242,236,.2);
}
.horizon {
  padding: 26px 26px 28px 0;
}
.horizon + .horizon {
  border-left: 1px solid rgba(244,242,236,.2);
  padding-left: 26px;
}
.h-num {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.horizon h3 { color: #F4F2EC; font-size: 19px; margin: 12px 0 10px; }
.horizon p { color: #AAA69A; font-size: 14px; min-height: 68px; }
.h-result {
  display: block;
  color: #F4F2EC;
  font-size: 13px;
  padding-top: 14px;
  border-top: 1px dashed rgba(244,242,236,.2);
}
.societal-statement {
  display: grid;
  grid-template-columns: 190px 1fr;
  gap: 28px;
  align-items: start;
  margin-top: 34px;
}
.societal-statement span {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.societal-statement p {
  color: #F4F2EC;
  font-family: var(--sans);
  font-size: clamp(18px, 2.3vw, 25px);
  line-height: 1.35;
  margin: 0;
  max-width: 46ch;
}
@media (max-width: 760px) {
  .horizon-grid { grid-template-columns: 1fr; }
  .horizon { padding: 24px 0; }
  .horizon + .horizon { border-left: 0; border-top: 1px solid rgba(244,242,236,.2); padding-left: 0; }
  .horizon p { min-height: 0; }
  .societal-statement { grid-template-columns: 1fr; gap: 10px; }
}

/* ---------- Section base ---------- */
section { padding: 62px 0; border-bottom: 1px solid var(--border); scroll-margin-top: 72px; }
.sec-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 8px; flex-wrap: wrap; }
.sec-num { font-family: var(--mono); font-size: 13px; color: var(--accent-ink); font-weight: 600; }
.sec-head h2 { font-size: clamp(22px, 3vw, 32px); margin: 0; }
.sec-intro { color: var(--muted); max-width: 74ch; margin: 4px 0 28px; }

/* ---------- Legend chips ---------- */
.tier { display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 20px; letter-spacing: .02em; text-transform: uppercase; border: 1px solid transparent; }
.tier .dot { width: 7px; height: 7px; border-radius: 50%; }
.tier.exp { color: var(--exp); background: var(--exp-bg); border-color: color-mix(in srgb, var(--exp) 30%, transparent); }
.tier.exp .dot { background: var(--exp); }
.tier.hyp { color: var(--hyp); background: var(--hyp-bg); border-color: color-mix(in srgb, var(--hyp) 30%, transparent); }
.tier.hyp .dot { background: var(--hyp); }
.tier.str { color: var(--str); background: var(--str-bg); border-color: color-mix(in srgb, var(--str) 30%, transparent); }
.tier.str .dot { background: var(--str); }

.legend-bar { display: flex; flex-wrap: wrap; gap: 12px 22px; align-items: center; padding: 14px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 26px; }
.legend-bar .lg-title { font-family: var(--mono); font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.legend-item { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ink-2); }
.legend-item .tier { pointer-events: none; }

/* ---------- Cards / grids ---------- */
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 860px) { .g2,.g3,.g4 { grid-template-columns: 1fr; } }
@media (min-width:861px) and (max-width:1050px){ .g4 { grid-template-columns: repeat(2,1fr);} .g3{grid-template-columns:repeat(2,1fr);} }

.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px; position: relative; transition: border-color .2s, transform .2s, box-shadow .2s;
}
.card:hover { border-color: var(--border-strong); box-shadow: var(--shadow); }
.card h3 { font-size: 17px; margin: 0 0 8px; }
.card p { margin: 0 0 4px; font-size: 14.5px; }
.card .k { font-family: var(--mono); font-size: 11px; color: var(--faint); letter-spacing: .08em; text-transform: uppercase; display: block; margin-bottom: 10px; }
.card ul { margin: 8px 0 0; padding-left: 18px; font-size: 14px; color: var(--ink-2); }
.card ul li { margin-bottom: 5px; }
.card .tier { margin-bottom: 12px; }

/* problem cards */
.prob { border-top: 3px solid var(--border-strong); }
.prob h3 { display: flex; gap: 10px; align-items: flex-start; }
.prob .idx { font-family: var(--mono); color: var(--accent-ink); font-size: 14px; flex: none; }

/* data pipeline */
.pipe { display: grid; grid-template-columns: repeat(5,1fr); gap: 14px; }
@media (max-width: 900px){ .pipe { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px){ .pipe { grid-template-columns: 1fr; } }
.pipe-node { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; }
.pipe-node .n { font-family: var(--mono); font-size: 11px; color: var(--accent-ink); }
.pipe-node h4 { margin: 6px 0 6px; font-size: 15px; }
.pipe-node p { font-size: 13px; margin: 0; color: var(--muted); }
.pipe-node .svc { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); font-size: 12.5px; color: var(--ink-2); }
.pipe-node .svc b { color: var(--ink); font-weight: 600; }

/* ---------- Interactive Map ---------- */
.map-shell { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.map-controls { display: flex; flex-wrap: wrap; gap: 8px; padding: 14px 16px; border-bottom: 1px solid var(--border); align-items: center; }
.map-controls .lbl { font-family: var(--mono); font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; margin-right: 4px; }
.filter-btn {
  font-family: var(--mono); font-size: 12px; padding: 6px 12px; border-radius: 20px; cursor: pointer;
  border: 1px solid var(--border); background: var(--bg); color: var(--muted); transition: all .18s;
}
.filter-btn:hover { color: var(--ink); border-color: var(--border-strong); }
.filter-btn.active { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.filter-btn[data-layer="data"].active { background: #3F6E9E; border-color: #3F6E9E; color:#fff;}
.filter-btn[data-layer="core"].active { background: var(--accent); border-color: var(--accent); color: #23211C; }
.filter-btn[data-layer="analytics"].active { background: #6B4FA0; border-color:#6B4FA0; color:#fff;}
.filter-btn[data-layer="results"].active { background: #3F6E4E; border-color:#3F6E4E; color:#fff;}
.filter-btn[data-layer="addons"].active { background: #1F776D; border-color:#1F776D; color:#fff;}
.filter-btn[data-layer="risk"].active { background: #A6482E; border-color:#A6482E; color:#fff;}

.map-body { display: grid; grid-template-columns: 1fr 340px; }
@media (max-width: 980px){ .map-body { grid-template-columns: 1fr; } }
.map-svg-wrap { position: relative; min-height: 460px; background:
  radial-gradient(circle at 1px 1px, var(--grid) 1px, transparent 0) 0 0 / 28px 28px; }
#productMap { width: 100%; height: auto; display: block; }

.node { cursor: pointer; }
.node-box { transition: opacity .25s, stroke-width .15s; }
.node-label { font-family: var(--mono); font-size: 11px; fill: var(--ink); pointer-events: none; font-weight: 500; }
.node-sub { font-family: var(--body); font-size: 9px; fill: var(--muted); pointer-events: none; }
.edge { stroke: var(--border-strong); stroke-width: 1.4; fill: none; transition: opacity .25s, stroke .2s, stroke-width .2s; }
.edge.neighbor-edge { fill: none; }
.map-svg-wrap.dim .node.faded { opacity: .18; }
.map-svg-wrap.dim .edge.faded { opacity: .08; }
.node.highlight .node-box { stroke-width: 2.4; }
.edge.highlight { stroke: var(--accent); stroke-width: 2.6; opacity: 1 !important; }

.map-detail { border-left: 1px solid var(--border); padding: 20px; background: var(--surface-2); }
@media (max-width: 980px){ .map-detail { border-left: none; border-top: 1px solid var(--border); } }
.map-detail .empty { color: var(--muted); font-size: 14px; }
.map-detail h3 { font-size: 18px; margin: 10px 0 6px; }
.map-detail .layer-tag { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--accent-ink); }
.map-detail p { font-size: 14px; }
.map-detail .conn { margin-top: 14px; }
.map-detail .conn .ct { font-family: var(--mono); font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 6px; }
.map-detail .conn-list { display: flex; flex-wrap: wrap; gap: 6px; }
.map-detail .chip { font-size: 12px; padding: 3px 9px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); cursor: pointer; color: var(--ink-2); }
.map-detail .chip:hover { border-color: var(--accent); color: var(--ink); }
.map-note { padding: 12px 16px; font-size: 12.5px; color: var(--muted); border-top: 1px solid var(--border); font-family: var(--body); }

/* ---------- Product interface showcase ---------- */
.interface { background: color-mix(in srgb, var(--surface-2) 46%, var(--bg)); }
.decision-flow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 0 0 42px;
  padding: 14px 18px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
}
.decision-flow b { color: var(--accent-ink); font-weight: 600; }
.interface-showcase { display: grid; gap: 64px; }
.screen-figure {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, .7fr);
  gap: 34px;
  align-items: center;
  margin: 0;
}
.screen-figure-reverse { grid-template-columns: minmax(280px, .7fr) minmax(0, 1.7fr); }
.screen-figure-reverse .screen-frame { order: 2; }
.screen-figure-reverse .screen-copy { order: 1; }
.screen-frame {
  overflow: hidden;
  border: 1px solid var(--border-strong);
  border-radius: calc(var(--radius) + 2px);
  background: #11130f;
  box-shadow: 0 20px 50px rgba(22, 21, 18, .16);
}
.screen-frame img { width: 100%; height: auto; display: block; }
.screen-copy { padding: 8px 0; }
.screen-label {
  display: block;
  margin-bottom: 14px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-ink);
}
.screen-copy h3 { margin: 0 0 12px; font-size: clamp(20px, 2.3vw, 27px); line-height: 1.16; }
.screen-copy p { margin: 0 0 16px; color: var(--muted); font-size: 14.5px; }
.screen-points { margin: 0; padding: 0; list-style: none; }
.screen-points li {
  position: relative;
  padding: 9px 0 9px 18px;
  border-top: 1px solid var(--border);
  color: var(--ink-2);
  font-size: 13.5px;
}
.screen-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 6px;
  height: 6px;
  background: var(--accent);
}
.interface-note {
  max-width: none;
  margin: 40px 0 0;
  padding-top: 16px;
  border-top: 1px dashed var(--border);
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11px;
}
@media (max-width: 900px) {
  .interface-showcase { gap: 48px; }
  .screen-figure, .screen-figure-reverse { grid-template-columns: 1fr; gap: 22px; }
  .screen-figure-reverse .screen-frame, .screen-figure-reverse .screen-copy { order: initial; }
}
@media (max-width: 560px) {
  .decision-flow { align-items: flex-start; flex-direction: column; margin-bottom: 32px; }
  .decision-flow b { transform: rotate(90deg); }
  .interface-showcase { gap: 40px; }
  .screen-frame {
    margin-inline: calc(var(--gutter) * -.45);
    border-radius: 0;
  }
  .screen-copy h3 { font-size: 21px; }
}

/* ---------- Branches ---------- */
.branch { border-left: 3px solid var(--accent); }
.branch .who { font-size: 13px; color: var(--muted); margin-top: 8px; }
.branch .who b { color: var(--ink); font-weight: 600; }

/* ---------- Add-on ecosystem ---------- */
.ecosystem { background: color-mix(in srgb, var(--surface-2) 58%, var(--bg)); }
.addon-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 14px;
}
.addon {
  grid-column: span 4;
  display: flex;
  flex-direction: column;
  min-height: 250px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.addon-lead { grid-column: span 7; min-height: 330px; background: var(--graphite); }
.addon-lead + .addon { grid-column: span 5; }
.addon-wide { grid-column: span 6; min-height: 230px; }
.addon-top { display: flex; justify-content: space-between; gap: 14px; align-items: center; margin-bottom: 22px; }
.addon-num, .addon-type, .addon-owner, .addon-link {
  font-family: var(--mono);
  font-size: 11px;
}
.addon-num { color: var(--accent-ink); font-weight: 600; }
.addon-type { color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.addon h3 { margin: 0 0 10px; font-size: 19px; }
.addon p { margin: 0 0 14px; font-size: 14px; }
.addon ul { margin: 2px 0 18px; padding-left: 18px; color: #C8C4B8; font-size: 13.5px; }
.addon-owner { color: var(--ink); margin-top: auto; padding-top: 12px; font-weight: 600; }
.addon-link { color: var(--muted); border-top: 1px dashed var(--border); margin-top: 14px; padding-top: 12px; }
.addon-lead h3, .addon-lead .addon-owner { color: #F4F2EC; }
.addon-lead p { color: #C8C4B8; }
.addon-lead .addon-num { color: var(--accent); }
.addon-lead .addon-type, .addon-lead .addon-link { color: #AAA69A; }
.addon-lead .addon-link { border-top-color: rgba(244,242,236,.2); }
.ecosystem-flow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 22px;
  padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-2);
}
.ecosystem-flow b { color: var(--accent-ink); font-weight: 600; }
@media (max-width: 900px) {
  .addon, .addon-lead, .addon-lead + .addon, .addon-wide { grid-column: span 6; }
}
@media (max-width: 620px) {
  .addon, .addon-lead, .addon-lead + .addon, .addon-wide { grid-column: 1 / -1; min-height: 0; }
  .ecosystem-flow { align-items: flex-start; flex-direction: column; }
  .ecosystem-flow b { transform: rotate(90deg); }
}

/* ---------- Team ---------- */
.person { display: flex; flex-direction: column; }
.person .avatar { width: 44px; height: 44px; border-radius: 50%; background: var(--accent-soft); color: var(--accent-ink); display: grid; place-items: center; font-family: var(--sans); font-weight: 600; font-size: 16px; margin-bottom: 12px; border: 1px solid var(--border-strong); }
.person h3 { font-size: 16px; margin: 0; }
.person .role { font-family: var(--mono); font-size: 12px; color: var(--accent-ink); margin: 4px 0 10px; }
.person p { font-size: 13.5px; margin: 0; }
.team-graph {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-areas:
    "ivan . . ilya"
    "ruban core core denis"
    "alekhin core core tatiana"
    ". oshemkov marshov .";
  gap: 22px;
  margin-bottom: 34px;
}
.team-links {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
  z-index: 0;
}
.team-links-primary line {
  stroke: color-mix(in srgb, var(--accent-ink) 58%, var(--border));
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}
.team-links-secondary line {
  stroke: var(--border-strong);
  stroke-width: 1;
  stroke-dasharray: 5 7;
  vector-effect: non-scaling-stroke;
}
.team-node, .team-core { z-index: 1; }
.team-node { min-height: 208px; box-shadow: 0 8px 24px rgba(22, 21, 18, .07); }
.team-node::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  border: 2px solid var(--accent);
  background: var(--surface);
  transform: rotate(45deg);
}
.node-ivan { grid-area: ivan; }
.node-ruban { grid-area: ruban; }
.node-ilya { grid-area: ilya; }
.node-denis { grid-area: denis; }
.node-tatiana { grid-area: tatiana; }
.node-alekhin { grid-area: alekhin; }
.node-oshemkov { grid-area: oshemkov; }
.node-marshov { grid-area: marshov; }
.node-ivan::after, .node-ruban::after, .node-alekhin::after { right: -6px; top: 50%; }
.node-ilya::after, .node-denis::after, .node-tatiana::after { left: -6px; top: 50%; }
.node-oshemkov::after, .node-marshov::after { top: -6px; left: 50%; }
.team-core {
  grid-area: core;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 438px;
  padding: 34px;
  border: 1px solid #383a32;
  background:
    radial-gradient(circle at 1px 1px, rgba(245, 178, 27, .14) 1px, transparent 0) 0 0 / 24px 24px,
    var(--graphite);
  color: #f4f2ec;
  box-shadow: 0 18px 46px rgba(22, 21, 18, .2);
}
.team-core-kicker {
  margin-bottom: 14px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
}
.team-core strong { font-family: var(--sans); font-size: clamp(26px, 3.4vw, 42px); line-height: 1; }
.team-core p { max-width: 48ch; margin: 18px 0 24px; color: #c8c4b8; font-size: 14px; }
.team-core-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.team-core-tags span {
  padding: 5px 9px;
  border: 1px solid rgba(244, 242, 236, .24);
  font-family: var(--mono);
  font-size: 11px;
  color: #e2ded3;
}
@media (max-width: 980px) {
  .team-graph {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas:
      "core core"
      "ivan ilya"
      "ruban alekhin"
      "denis tatiana"
      "oshemkov marshov";
  }
  .team-links, .team-node::after { display: none; }
  .team-core { min-height: 300px; }
}
@media (max-width: 620px) {
  .team-graph {
    grid-template-columns: 1fr;
    grid-template-areas:
      "core"
      "ivan"
      "ilya"
      "ruban"
      "alekhin"
      "denis"
      "tatiana"
      "oshemkov"
      "marshov";
    gap: 14px;
  }
  .team-core { min-height: 280px; padding: 26px; }
  .team-node { min-height: 0; }
}

/* ---------- Accordion (expertise) ---------- */
.acc-item { border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 10px; background: var(--surface); overflow: hidden; }
.acc-head { width: 100%; text-align: left; background: none; border: none; padding: 16px 18px; cursor: pointer; display: flex; align-items: center; gap: 14px; font-family: var(--sans); font-size: 16px; font-weight: 600; color: var(--ink); }
.acc-head:hover { background: var(--surface-2); }
.acc-head .tier { margin-left: auto; margin-right: 6px; }
.acc-head .plus { font-family: var(--mono); font-size: 18px; color: var(--accent-ink); transition: transform .2s; flex: none; }
.acc-item.open .acc-head .plus { transform: rotate(45deg); }
.acc-body { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.acc-item.open .acc-body { max-height: 900px; }
.acc-body .inner { padding: 4px 18px 20px 46px; font-size: 14.5px; color: var(--ink-2); }
.acc-body ul { padding-left: 18px; }

/* ---------- Tabs (roadmap) ---------- */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 22px; }
.tab-btn { font-family: var(--mono); font-size: 13px; padding: 9px 16px; border: 1px solid var(--border); background: var(--surface); border-radius: var(--radius); cursor: pointer; color: var(--muted); }
.tab-btn.active { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fade .3s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px);} to { opacity: 1; transform: none; } }

.phase { display: grid; grid-template-columns: 130px 1fr; gap: 20px; padding: 22px 0; border-bottom: 1px dashed var(--border); }
@media (max-width: 640px){ .phase { grid-template-columns: 1fr; gap: 6px; } }
.phase .p-when { font-family: var(--mono); font-size: 13px; color: var(--accent-ink); }
.phase .p-when .st { display: block; color: var(--faint); font-size: 11px; margin-top: 4px; }
.phase h3 { margin: 0 0 6px; font-size: 18px; }
.phase p { margin: 0 0 8px; font-size: 14.5px; }
.phase .goals { font-size: 13.5px; color: var(--ink-2); }
.phase .goals li { margin-bottom: 4px; }

/* ---------- Guardrails ---------- */
.rail { border-left: 3px solid var(--exp); }
.rail.warn { border-left-color: var(--hyp); }
.rail h3 { font-size: 16px; display:flex; gap:10px; align-items:center;}
.rail .ic { flex:none; }

/* ---------- Portfolio ---------- */
.port { display: grid; grid-template-columns: repeat(2,1fr); gap: 14px; }
@media (max-width: 720px){ .port { grid-template-columns: 1fr; } }
.port-item { padding: 16px 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.port-item h4 { margin: 0 0 4px; font-size: 15px; }
.port-item p { margin: 0; font-size: 13.5px; color: var(--muted); }
.verify { font-family: var(--mono); font-size: 10.5px; color: var(--hyp); border: 1px solid color-mix(in srgb, var(--hyp) 40%, transparent); background: var(--hyp-bg); padding: 2px 7px; border-radius: 12px; display: inline-block; margin-top: 8px; }

/* ---------- Callout / note ---------- */
.note { padding: 16px 18px; background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--accent); border-radius: var(--radius); font-size: 14px; color: var(--ink-2); }

/* ---------- Footer ---------- */
footer { padding: 40px 0 60px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center; }
footer p { font-size: 13px; color: var(--muted); margin: 0; font-family: var(--mono); }
footer .disc { max-width: 60ch; font-family: var(--body); }

.kicker { font-family: var(--mono); font-size: 11px; color: var(--faint); letter-spacing: .1em; text-transform: uppercase; }

/* Тельняшка — оранжевые/белые полоски одинаковой ширины, тонкие, во всю ширину */
.telnyashka-stripes {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 24px;
  width: 100%;
  background:
    linear-gradient(to bottom,
      #E6A400 0 20%, #FFFFFF 20% 40%,
      #E6A400 40% 60%, #FFFFFF 60% 80%,
      #E6A400 80% 100%);
}
