/* ══════════════════════════════════════════════════════════
   Four Realities Radar v2 — Style
   Design tokens: inherited BYTE-FOR-BYTE from v1 style.css
   Additional rules: tab-bar, views, responsive
   ══════════════════════════════════════════════════════════ */

/* Fonts loaded async in index.html — no @import here */

/* ── Design tokens — v1 verbatim ── */
:root {
  --paper:      #f0ede8;
  --grid-minor: #d8d4cc;
  --grid-major: #c2bdb5;
  --ink:        #1e2640;
  --accent:     #3a5bcf;
  --terracotta: #c45c4a;
  --olive:      #6b8e4e;
  --amber:      #d49b3a;
  --faded:      rgba(30,38,64,0.12);
  --faded-strong: rgba(30,38,64,0.25);
  /* a11y: readable muted text >= 4.5:1 on #f0ede8 */
  --ink-muted:  #4a5170;
  --row-alt:    rgba(30,38,64,0.035);
  --mono: 'IBM Plex Mono', 'SF Mono', 'Fira Code', monospace;
  --sans: 'Space Grotesk', system-ui, -apple-system, sans-serif;

  /* Quadrant colors — matching v1 exactly */
  --q-cs: #3a5bcf;   /* ЦС — централизованная синтетика, синий */
  --q-cz: #6b8e4e;   /* ЦЗ — централизованная земля,    олива */
  --q-ds: #c45c4a;   /* ДС — децентрализованная синтетика, терракот */
  --q-dz: #d49b3a;   /* ДЗ — децентрализованная земля,    охра */
}

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

html {
  scroll-behavior: smooth;
}

/* ── Body — paper-grid background (v1 cross-hatch pattern) ── */
html, body {
  min-height: 100vh;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.55;
}

/* Paper grid: cross-hatch 28px minor, 140px major — matching v1 spec */
body {
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid-minor) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-minor) 1px, transparent 1px),
    linear-gradient(var(--grid-major) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-major) 1px, transparent 1px);
  background-size: 28px 28px, 28px 28px, 140px 140px, 140px 140px;
  background-position: -1px -1px;
}

/* ── Page container ── */
.page {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 32px 80px;
}

/* ── Site header ── */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 0 16px;
  border-bottom: 2px solid var(--ink);
  margin-bottom: 0;
}

.site-header__left {
  display: flex;
  align-items: center;
}

.site-header__title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--ink);
}

.site-header__right {
  display: flex;
  align-items: center;
}

.site-header__badge {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--accent);
}

/* ── Tab bar ── */
.tab-bar {
  display: flex;
  align-items: stretch;
  height: 64px;
  border-bottom: 2px solid var(--ink);
  background: var(--paper);
  gap: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.tab-bar::-webkit-scrollbar {
  display: none;
}

.tab-bar__tab {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 22px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  background: transparent;
  border: none;
  border-right: 1px solid var(--faded-strong);
  color: var(--ink-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.12s, color 0.12s;
  flex-shrink: 0;
}

.tab-bar__tab:hover {
  background: rgba(30,38,64,0.04);
  color: var(--ink);
}

.tab-bar__tab.is-active {
  background: var(--ink);
  color: var(--paper);
}

.tab-bar__tab.is-active .tab-bar__dot {
  outline: 2px solid rgba(240,237,232,0.6);
  outline-offset: 1px;
}

.tab-bar__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}

.tab-bar__label {
  flex-shrink: 0;
}

/* ── View areas ── */
.views {
  min-height: 60vh;
}

.view {
  padding: 32px 0 40px;
}

.view[hidden] {
  display: none !important;
}

/* View stub (shown when module not loaded yet) */
.view-stub {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 40px 0;
}

.view-stub__kicker {
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
}

.view-stub__message {
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
  max-width: 640px;
  line-height: 1.35;
}

.view-stub__note {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-muted);
  border-left: 3px solid var(--faded-strong);
  padding-left: 14px;
  line-height: 1.6;
}

/* ── Sticker — reusable class (drop-shadow without blur = sharp paper-shadow) ── */
.sticker {
  display: inline-block;
  padding: 10px 14px;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.45;
  word-break: break-word;
  filter: drop-shadow(0 8px 0 rgba(30,38,64,0.14));
}

.sticker.s-orange    { background: #ffba5c; color: #2a1a00; }
.sticker.s-red       { background: #e8656e; color: #2a0006; }
.sticker.s-yellow    { background: #ffef90; color: #302a00; }
.sticker.s-blue      { background: #a3d5ff; color: #002036; }
.sticker.s-turquoise { background: #7fd7ce; color: #002920; }
.sticker.s-white     { background: #ffffff; color: var(--ink); border: 2px solid var(--ink); }

/* ── Utility classes ── */
.terminal-text {
  font-family: var(--mono);
}

/* ── Shared panel/card from v1 ── */
.panel {
  background: var(--paper);
  border: 2px solid var(--ink);
  padding: 20px 24px;
  margin-bottom: 24px;
  box-shadow: 6px 6px 0 var(--faded);
}

.panel-kicker {
  display: inline-block;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--ink-muted);
}

.field-label {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--ink-muted);
  font-weight: 600;
  margin-bottom: 8px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 10px 18px;
  border: 2px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  transition: all .12s;
  text-decoration: none;
}

.btn:hover:not(:disabled) {
  background: var(--ink);
  color: var(--paper);
}

.btn:disabled {
  opacity: .4;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--ink);
  color: var(--paper);
}

.btn-primary:hover:not(:disabled) {
  background: var(--accent);
  border-color: var(--accent);
}

.btn-ghost {
  border-style: dashed;
}

.btn-mini {
  font-size: 11px;
  padding: 6px 10px;
  letter-spacing: 1px;
}

/* World color pills */
.q-code {
  display: inline-block;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 11px;
  padding: 2px 6px;
  margin-right: 6px;
  border-radius: 2px;
  color: var(--paper);
}
.q-code.cs { background: var(--q-cs); }
.q-code.cz { background: var(--q-cz); }
.q-code.ds { background: var(--q-ds); }
.q-code.dz { background: var(--q-dz); }

/* ── Site footer ── */
.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  margin-top: 48px;
  border-top: 1px dashed var(--faded-strong);
  font-size: 11px;
  color: var(--ink-muted);
  flex-wrap: wrap;
}

.site-footer__meta {
  color: var(--accent);
}

/* ── Status line ── */
.status-line {
  font-size: 12px;
  padding: 9px 12px;
  border-left: 3px solid var(--faded-strong);
  background: rgba(30,38,64,0.03);
  color: var(--ink-muted);
  font-family: var(--mono);
  line-height: 1.45;
  margin-top: 10px;
}

.status-line.is-ok    { border-left-color: var(--olive);      color: #38542a; }
.status-line.is-error { border-left-color: var(--terracotta); color: #7c3340; }

/* ── P0 Radar view ── */
.radar-view,
.radar-empty {
  display: grid;
  gap: 18px;
}

.radar-view.is-personal {
  gap: 12px;
}

.radar-empty h1,
.radar-view h1 {
  font-family: var(--sans);
  font-size: clamp(32px, 5vw, 58px);
  line-height: .95;
  letter-spacing: -.5px;
}

.radar-empty p,
.radar-view-head p {
  max-width: 780px;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 1.7;
}

.radar-view-head p code {
  padding: 1px 5px;
  border: 1px solid var(--faded-strong);
  background: #fffdf8;
}

.radar-view-head p a {
  color: var(--accent);
  text-decoration: underline;
}

.radar-view-head {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--ink);
}

.radar-view.is-personal .radar-view-head {
  position: relative;
  display: block;
  min-height: 116px;
  padding-right: 330px;
  padding-bottom: 12px;
}

.radar-view.is-personal h1 {
  font-size: clamp(34px, 4.2vw, 52px);
  line-height: .92;
}

.radar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-end;
}

.radar-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.radar-stat {
  min-height: 78px;
  padding: 12px;
  border: 1px solid var(--faded-strong);
  background: #fffdf8;
}

.radar-stat strong {
  display: block;
  font-family: var(--sans);
  font-size: 30px;
  line-height: 1;
}

.radar-stat span {
  display: block;
  margin-top: 8px;
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.radar-stats--compact .radar-stat {
  min-height: 50px;
  padding: 8px 12px;
}

.radar-stats--compact .radar-stat strong {
  font-size: 22px;
}

.radar-stats--compact .radar-stat span {
  margin-top: 5px;
}

.personal-query {
  max-width: 920px;
  padding: 11px 15px;
  background: #ffba5c;
  border: 2px solid var(--ink);
  box-shadow: 5px 5px 0 rgba(30,38,64,0.14);
}

.personal-query__kicker {
  margin-bottom: 5px;
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: #6b4a16;
}

.personal-query__text {
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.32;
  color: #2a1a00;
}

.radar-control-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.radar-control-card {
  min-height: 74px;
  padding: 10px 12px;
  border: 1px solid var(--faded-strong);
  background: rgba(255,253,248,0.78);
}

.radar-control-card span {
  display: block;
  margin-bottom: 4px;
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.radar-control-card strong {
  display: block;
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.12;
}

.radar-control-card p {
  margin-top: 5px;
  color: var(--ink-muted);
  font-size: 10.5px;
  line-height: 1.35;
}

.radar-mount {
  width: 100%;
  height: min(680px, calc(100vh - 260px));
  min-height: 560px;
  position: relative;
  overflow: hidden;
  border: 2px solid var(--ink);
  background: #f8f4eb;
  box-shadow: 7px 7px 0 var(--faded);
}

.radar-view.is-shared .radar-mount {
  height: clamp(600px, 70vh, 760px);
  min-height: 600px;
}

.radar-mount--personal {
  height: clamp(500px, 58vh, 640px);
  min-height: 500px;
}

.radar-board-svg,
.personal-map-svg {
  display: block;
  width: 100%;
  height: 100%;
}

.board-node {
  cursor: pointer;
  transition: opacity .14s;
}

.board-node:hover,
.board-node.is-highlighted {
  opacity: .82;
}

.board-node.is-highlighted rect,
.board-node.is-highlighted circle,
.board-node:hover rect,
.board-node:hover circle {
  stroke: var(--accent);
  stroke-width: 4px;
}

.board-label {
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 700;
  fill: var(--ink);
  dominant-baseline: middle;
}

.board-type,
.board-center-kicker,
.board-center-subtitle,
.board-world-caption {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  fill: var(--ink-muted);
}

.board-weight,
.board-multi,
.board-world-count {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 800;
  fill: var(--accent);
}

.board-world-code {
  font-family: var(--mono);
  font-size: 34px;
  font-weight: 800;
  fill: #fff;
}

.board-world-count {
  font-size: 20px;
  fill: var(--ink);
}

.board-world-caption {
  font-size: 11px;
}

.board-center-title {
  font-family: var(--sans);
  font-size: 24px;
  font-weight: 800;
  fill: var(--ink);
}

.board-center-subtitle {
  font-size: 11px;
}

.board-edge {
  pointer-events: none;
}

.radar-insights {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, .9fr);
  gap: 14px;
}

.radar-insights__block {
  min-width: 0;
  padding: 16px;
  border: 2px solid var(--ink);
  background: rgba(255,253,248,0.82);
  box-shadow: 6px 6px 0 var(--faded);
}

.radar-insights__head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--faded-strong);
}

.radar-insights h2 {
  font-family: var(--sans);
  font-size: 24px;
  line-height: 1;
}

.radar-insight-list,
.radar-lever-list {
  display: grid;
  gap: 9px;
}

.radar-insight-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 11px;
  align-items: start;
  padding: 11px;
  border: 1px solid var(--faded-strong);
  background: var(--paper);
  cursor: pointer;
}

.radar-insight-card:hover {
  border-color: var(--accent);
}

.radar-insight-rank {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 2px solid var(--ink);
  background: #fffdf8;
  color: var(--accent);
  font-weight: 800;
}

.radar-insight-card strong {
  display: block;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.15;
}

.radar-insight-card p,
.radar-lever-card p,
.radar-insights-note,
.radar-insight-empty {
  color: var(--ink-muted);
  font-size: 11px;
  line-height: 1.45;
}

.radar-insight-card p {
  margin-top: 4px;
}

.radar-world-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 8px;
}

.radar-world-chip {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 7px;
  border: 1px solid var(--ink);
  background: var(--chip-color);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
}

.radar-lever-card {
  min-height: 96px;
  padding: 12px;
  border: 1px solid var(--faded-strong);
  background: #fffdf8;
}

.radar-lever-card span {
  display: block;
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.1px;
  text-transform: uppercase;
}

.radar-lever-card strong {
  display: block;
  margin-top: 7px;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.18;
}

.radar-lever-card p,
.radar-insights-note {
  margin-top: 8px;
}

.radar-insights-note code {
  padding: 1px 4px;
  border: 1px solid var(--faded-strong);
  background: #fffdf8;
}

.radar-insight-empty {
  padding: 14px;
  border: 1px dashed var(--faded-strong);
  background: rgba(240,237,232,.72);
}

.personal-title,
.personal-row-label,
.personal-world-caption {
  font-family: var(--mono);
  font-weight: 800;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  fill: var(--ink-muted);
}

.personal-title {
  font-size: 14px;
  fill: var(--ink);
}

.personal-row-label {
  font-size: 11px;
}

.personal-world-caption {
  font-size: 10px;
}

.personal-label {
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 800;
  fill: var(--ink);
  dominant-baseline: middle;
}

.personal-edge {
  pointer-events: none;
  stroke-width: 2;
}

.personal-node {
  cursor: pointer;
}

.personal-node:hover,
.personal-node.is-highlighted {
  opacity: .84;
}

.personal-node:hover rect,
.personal-node:hover circle,
.personal-node.is-highlighted rect,
.personal-node.is-highlighted circle {
  stroke: var(--accent);
  stroke-width: 4px;
}

.process-board {
  margin-top: 10px;
  padding: 18px;
  border: 2px solid var(--ink);
  background:
    radial-gradient(circle at 12% 12%, rgba(255, 186, 92, 0.24), transparent 28%),
    radial-gradient(circle at 86% 18%, rgba(163, 213, 255, 0.28), transparent 32%),
    rgba(255, 253, 248, 0.74);
  box-shadow: 7px 7px 0 var(--faded);
}

.process-board__head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 170px;
  gap: 16px;
  align-items: start;
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--faded-strong);
}

.process-board h2 {
  margin: 4px 0 6px;
  font-family: var(--sans);
  font-size: clamp(26px, 3vw, 42px);
  line-height: .95;
  letter-spacing: -.3px;
}

.process-board p {
  max-width: 820px;
  color: var(--ink-muted);
  font-size: 12px;
  line-height: 1.65;
}

.process-board__badge {
  padding: 12px;
  border: 2px solid var(--ink);
  background: var(--paper);
  text-align: right;
  box-shadow: 4px 4px 0 rgba(30,38,64,.12);
}

.process-board__badge span,
.process-board__badge small {
  display: block;
  color: var(--ink-muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.process-board__badge strong {
  display: block;
  margin: 4px 0;
  font-family: var(--sans);
  font-size: 42px;
  line-height: .9;
}

.process-waves {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  margin-top: 14px;
}

.process-wave {
  min-width: 0;
  padding: 12px;
  border: 1px solid var(--faded-strong);
  background: rgba(240, 237, 232, .74);
}

.process-wave--w1 { border-top: 5px solid var(--q-cs); }
.process-wave--w2 { border-top: 5px solid var(--q-ds); }
.process-wave--w3 { border-top: 5px solid var(--q-dz); }

.process-wave__title {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.process-wave__title strong {
  font-family: var(--sans);
  font-size: 19px;
  line-height: 1;
}

.process-wave__title span {
  max-width: 130px;
  color: var(--ink-muted);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 1px;
  text-align: right;
  text-transform: uppercase;
}

.process-lanes {
  display: grid;
  gap: 8px;
}

.process-lane {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 8px 10px;
  align-items: start;
  padding: 9px;
  border: 1px solid rgba(30,38,64,.22);
  background: #fffdf8;
}

.process-lane b {
  grid-row: span 2;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1;
}

.process-lane strong {
  min-width: 0;
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.12;
}

.process-lane span {
  min-width: 0;
  color: var(--ink-muted);
  font-size: 10px;
  line-height: 1.45;
}

.radar-view.is-personal .radar-actions {
  position: absolute;
  top: 0;
  right: 0;
  max-width: 310px;
}

.radar-canvas {
  overflow: hidden;
  border: 2px solid var(--ink);
  background: #f8f4eb;
  box-shadow: 7px 7px 0 var(--faded);
}

.radar-canvas svg {
  display: block;
  width: 100%;
  height: auto;
}

.node,
.edge-hit,
.card-hit,
.radar-leverage-card {
  cursor: pointer;
}

.node:hover .node-shape,
.card-hit:hover rect {
  stroke: var(--accent);
  stroke-width: 4;
}

.radar-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, .85fr);
  gap: 18px;
}

.radar-grid h2 {
  margin-bottom: 10px;
  font-family: var(--sans);
  font-size: 22px;
}

.radar-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.radar-leverage-card {
  min-height: 126px;
  padding: 12px;
  border: 2px solid var(--ink);
  background: #fff;
  box-shadow: 5px 5px 0 rgba(30,38,64,.12);
}

.radar-leverage-card:hover {
  border-color: var(--accent);
}

.radar-card-kicker {
  color: var(--ink-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.radar-leverage-card strong {
  display: block;
  margin: 8px 0 6px;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.14;
}

.radar-leverage-card p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 12px;
  line-height: 1.45;
}

.radar-review {
  display: grid;
  gap: 8px;
}

.radar-review-item {
  padding: 10px 12px;
  border-left: 3px solid var(--amber);
  background: #fffdf8;
}

.radar-review-item strong {
  display: block;
  font-size: 13px;
  line-height: 1.35;
}

.radar-review-item span {
  display: block;
  margin-top: 5px;
  color: var(--ink-muted);
  font-size: 11px;
}

/* ── Responsive ── */

/* Tablet: ≤ 900px */
@media (max-width: 900px) {
  .page {
    padding: 0 20px 60px;
  }

  .panel {
    padding: 16px;
  }

  .radar-view-head,
  .radar-grid,
  .radar-insights {
    grid-template-columns: 1fr;
    display: grid;
  }

  .radar-view.is-personal .radar-view-head {
    display: grid;
    min-height: 0;
    padding-right: 0;
  }

  .radar-view.is-personal .radar-actions {
    position: static;
    max-width: none;
  }

  .radar-actions {
    justify-content: flex-start;
  }

  .radar-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .radar-control-strip {
    grid-template-columns: 1fr;
  }

  .process-board__head,
  .process-waves {
    grid-template-columns: 1fr;
  }

  .process-board__badge {
    text-align: left;
  }
}

/* Mobile: ≤ 760px — single column, tab-bar scrollable strip */
@media (max-width: 760px) {
  .page {
    padding: 0 14px 60px;
  }

  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 14px 0 12px;
  }

  .tab-bar {
    height: auto;
    min-height: 48px;
    padding: 6px 0;
  }

  .tab-bar__tab {
    padding: 8px 14px;
    font-size: 11px;
    gap: 7px;
  }

  .tab-bar__dot {
    width: 10px;
    height: 10px;
  }

  .view {
    padding: 20px 0 32px;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .radar-stats,
  .radar-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .radar-mount,
  .radar-mount--personal {
    height: 58vh;
    min-height: 420px;
  }

  .radar-view.is-shared .radar-mount {
    height: 62vh;
    min-height: 440px;
  }

  .radar-insights__head {
    display: grid;
    align-items: start;
  }
}

/* Very small: ≤ 400px */
@media (max-width: 400px) {
  .tab-bar__tab {
    padding: 8px 10px;
    font-size: 10px;
  }
}
