/* ============================================================
   Компас - кабинет инвестора и советника
   Дизайн-система: тёплая бумага, глубокий зелёный, крупные числа
   ============================================================ */

/* ---------- 1. Токены ---------- */
:root {
  /* поверхность */
  --paper: #F4F1EA;
  --paper-2: #EDE8DE;
  --card: #FFFFFF;
  --card-soft: #FBF9F4;

  /* текст */
  --ink: #121C18;
  --ink-2: #37433D;
  --muted: #6D7A73;
  --muted-2: #8C978F;

  /* линии */
  --line: #E5DFD3;
  --line-2: #D8D1C3;
  --line-strong: #C9C1B0;

  /* бренд */
  --brand: #0F5C46;
  --brand-600: #14795C;
  --brand-400: #3F9B7C;
  --brand-soft: #E3EFE9;
  --brand-ink: #0B1712;

  /* акценты */
  --gold: #A97B2C;
  --gold-soft: #F4E9D6;
  --coral: #B44A32;
  --coral-soft: #F8E4DD;
  --blue: #35548F;
  --blue-soft: #E6EAF3;

  /* классы активов */
  --c-stock: #17694F;
  --c-bonds: #3E7D9A;
  --c-cash: #C08A3E;
  --c-crypto: #7A5C9B;
  --c-reits: #8A9757;
  --c-alt: #B0674C;

  /* формы */
  --r-xs: 8px;
  --r-sm: 12px;
  --r-md: 16px;
  --r-lg: 20px;
  --r-xl: 26px;
  --r-pill: 999px;

  /* тени */
  --sh-1: 0 1px 2px rgba(18, 28, 24, .05), 0 1px 1px rgba(18, 28, 24, .03);
  --sh-2: 0 2px 4px rgba(18, 28, 24, .04), 0 14px 34px -22px rgba(18, 28, 24, .35);
  --sh-3: 0 30px 70px -30px rgba(18, 28, 24, .45);

  /* движение */
  --ease: cubic-bezier(.22, .8, .28, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --t-fast: 160ms;
  --t: 240ms;

  /* шрифты */
  --font-display: 'Unbounded', 'Golos Text', system-ui, sans-serif;
  --font-body: 'Golos Text', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --sidebar-w: 268px;
  --topbar-h: 76px;
}

/* ---------- 2. База ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(900px 500px at 80% -10%, rgba(15, 92, 70, .07), transparent 70%),
    radial-gradient(700px 400px at 10% 105%, rgba(169, 123, 44, .06), transparent 70%);
}

h1, h2, h3, h4, p, figure { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }

::selection { background: var(--brand-soft); color: var(--brand-ink); }

:focus-visible {
  outline: 2px solid var(--brand-600);
  outline-offset: 3px;
  border-radius: 6px;
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- 3. Каркас ---------- */
.app {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* ---------- 4. Сайдбар ---------- */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  padding: 22px 16px 18px;
  background:
    radial-gradient(360px 260px at 20% 0%, rgba(63, 155, 124, .16), transparent 70%),
    linear-gradient(180deg, #13211C 0%, #0E1A15 100%);
  color: #E8EFEA;
  z-index: 40;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 4px 8px 22px;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #1E8A68, #0F5C46);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18), 0 8px 20px -10px rgba(31, 169, 124, .8);
  color: #EAF5EF;
  flex: none;
}
.brand-mark svg { width: 21px; height: 21px; }

.brand-name {
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -.02em;
  line-height: 1.1;
}
.brand-sub {
  font-size: 11.5px;
  color: rgba(232, 239, 234, .55);
  letter-spacing: .02em;
  margin-top: 3px;
}

.nav { flex: 1; overflow-y: auto; margin: 0 -6px; padding: 0 6px; }
.nav::-webkit-scrollbar { width: 6px; }
.nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); border-radius: 99px; }

.nav-label {
  font-size: 10.5px;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: rgba(232, 239, 234, .42);
  padding: 16px 12px 8px;
  font-weight: 600;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 42px;
  padding: 9px 12px;
  border-radius: 12px;
  color: rgba(232, 239, 234, .78);
  font-size: 14.5px;
  font-weight: 500;
  cursor: pointer;
  border: 0;
  background: none;
  width: 100%;
  text-align: left;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease);
}
.nav-item svg { width: 19px; height: 19px; flex: none; opacity: .8; }
.nav-item:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.nav-item:active { transform: scale(.99); }

.nav-item.active {
  background: #F4F1EA;
  color: var(--brand-ink);
  font-weight: 600;
  box-shadow: 0 10px 24px -16px rgba(0, 0, 0, .8);
}
.nav-item.active svg { opacity: 1; color: var(--brand-600); }

.nav-count {
  margin-left: auto;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .12);
  color: #fff;
  font-size: 11.5px;
  font-weight: 600;
  display: grid;
  place-items: center;
}
.nav-item.active .nav-count { background: var(--brand); color: #fff; }

.sidebar-foot {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding-top: 14px;
  margin-top: 12px;
}

.plan-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .08);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease);
  width: 100%;
  text-align: left;
  color: inherit;
}
.plan-chip:hover { background: rgba(255, 255, 255, .1); }
.plan-chip .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: #6FCFA4;
  box-shadow: 0 0 0 4px rgba(111, 207, 164, .18);
  flex: none;
}
.plan-chip-title { font-size: 13px; font-weight: 600; }
.plan-chip-sub { font-size: 11.5px; color: rgba(232, 239, 234, .55); margin-top: 2px; }
.plan-chip .chev { margin-left: auto; opacity: .5; }

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 10px 2px;
}
.user-chip .avatar { width: 34px; height: 34px; font-size: 12.5px; }
.user-chip-name { font-size: 13.5px; font-weight: 600; color: #fff; }
.user-chip-role { font-size: 11.5px; color: rgba(232, 239, 234, .5); }

/* ---------- 5. Верхняя панель ---------- */
.main { min-width: 0; display: flex; flex-direction: column; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 0 32px;
  background: rgba(244, 241, 234, .86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}

.burger { display: none; }

.topbar-title { min-width: 0; }
.topbar-crumbs {
  font-size: 11.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted-2);
  font-weight: 600;
}
.topbar-sub {
  font-size: 13.5px;
  color: var(--muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.role-switch {
  display: flex;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  padding: 3px;
  gap: 2px;
}
.role-switch button {
  border: 0;
  background: none;
  padding: 7px 14px;
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  min-height: 36px;
  transition: all var(--t-fast) var(--ease);
  white-space: nowrap;
}
.role-switch button.on {
  background: var(--card);
  color: var(--ink);
  box-shadow: var(--sh-1);
}

.icon-btn {
  position: relative;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: var(--card);
  display: grid;
  place-items: center;
  cursor: pointer;
  color: var(--ink-2);
  transition: all var(--t-fast) var(--ease);
}
.icon-btn:hover { border-color: var(--line-2); background: #fff; transform: translateY(-1px); }
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn .badge-dot {
  position: absolute;
  top: 8px; right: 9px;
  min-width: 17px; height: 17px;
  padding: 0 4px;
  border-radius: 99px;
  background: var(--coral);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid var(--paper);
}

.avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .01em;
  background: var(--brand-soft);
  color: var(--brand);
  border: 1px solid #D3E6DC;
  flex: none;
  cursor: pointer;
}
.avatar--dark { background: linear-gradient(145deg, #1D7A5E, #0E4E3B); color: #EAF5EF; border-color: transparent; }

/* ---------- 6. Контент ---------- */
.view {
  padding: 28px 32px 72px;
  max-width: 1280px;
  width: 100%;
  animation: viewIn 420ms var(--ease-out) both;
}
@keyframes viewIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.page-head {
  display: flex;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.page-head-main { min-width: 0; flex: 1; }
.eyebrow {
  font-size: 11.5px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-600);
  font-weight: 700;
  margin-bottom: 8px;
}
.page-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 2.4vw, 32px);
  font-weight: 500;
  letter-spacing: -.03em;
  line-height: 1.15;
}
.page-sub {
  color: var(--muted);
  font-size: 15px;
  margin-top: 8px;
  max-width: 62ch;
}
.page-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.section-head {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 30px 0 14px;
}
.section-title {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 500;
  letter-spacing: -.02em;
}
.section-sub { font-size: 13.5px; color: var(--muted); margin-top: 3px; }
.section-link { margin-left: auto; }

/* ---------- 7. Сетка и карточки ---------- */
.grid { display: grid; gap: 18px; }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cols-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.cols-1-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.stack { display: flex; flex-direction: column; gap: 18px; }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 22px;
  box-shadow: var(--sh-1);
  position: relative;
  min-width: 0;
}
.card--flat { box-shadow: none; background: var(--card-soft); }
.card--pad { padding: 26px; }
.card--hover { transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease), border-color var(--t) var(--ease); }
.card--hover:hover { transform: translateY(-2px); box-shadow: var(--sh-2); border-color: var(--line-2); }

.card-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 18px; }
.card-title { font-size: 15.5px; font-weight: 600; letter-spacing: -.01em; }
.card-sub { font-size: 13px; color: var(--muted); margin-top: 3px; }
.card-head .right { margin-left: auto; }

.hint {
  display: flex;
  gap: 9px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
  background: var(--card-soft);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 11px 13px;
}
.hint svg { width: 16px; height: 16px; flex: none; margin-top: 1px; color: var(--brand-600); }

/* ---------- 8. Кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  border: 1px solid transparent;
  background: var(--brand);
  color: #F1F7F3;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease);
  white-space: nowrap;
  text-align: center;
}
.btn svg { width: 17px; height: 17px; }
.btn:hover { background: #0C4E3B; transform: translateY(-1px); box-shadow: 0 10px 22px -14px rgba(15, 92, 70, .9); }
.btn:active { transform: translateY(0) scale(.99); }

.btn--ghost { background: var(--card); color: var(--ink); border-color: var(--line-2); }
.btn--ghost:hover { background: #fff; border-color: var(--line-strong); box-shadow: var(--sh-1); }

.btn--soft { background: var(--brand-soft); color: var(--brand); border-color: #CDE4D9; }
.btn--soft:hover { background: #D8EAE1; box-shadow: none; }

.btn--dark { background: var(--ink); color: #F4F1EA; }
.btn--dark:hover { background: #1D2B25; }

.btn--sm { min-height: 36px; padding: 7px 13px; font-size: 13px; }
.btn--xs { min-height: 30px; padding: 4px 10px; font-size: 12.5px; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

.link-btn {
  border: 0;
  background: none;
  padding: 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--brand-600);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}
.link-btn svg { width: 15px; height: 15px; flex: none; }
.link-btn:hover { color: var(--brand); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 9. Чипы и бейджи ---------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 600;
  background: var(--paper-2);
  color: var(--ink-2);
  border: 1px solid transparent;
  white-space: nowrap;
}
.chip svg { width: 13px; height: 13px; }
.chip--ok { background: var(--brand-soft); color: #0B5A43; }
.chip--warn { background: var(--gold-soft); color: #8A5F17; }
.chip--risk { background: var(--coral-soft); color: #96361F; }
.chip--soft { background: var(--paper-2); color: var(--muted); }
.chip--brand { background: var(--brand); color: #F1F7F3; }
.chip--line { background: transparent; border-color: var(--line-2); color: var(--muted); }
.chip--dot::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: currentColor; opacity: .8;
}

/* ---------- 10. Метрики ---------- */
.metric-label {
  font-size: 11.5px;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--muted-2);
  font-weight: 600;
}
.metric-value {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -.035em;
  line-height: 1.15;
  margin-top: 7px;
  font-variant-numeric: tabular-nums;
}
.metric-value small { font-size: 14px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.metric-note { font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.trend { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; font-weight: 600; }
.trend--up { color: var(--brand-600); }
.trend--down { color: var(--coral); }
.trend svg { width: 13px; height: 13px; }

.kpi-row { display: flex; gap: 26px; flex-wrap: wrap; }
.kpi-row > * { min-width: 120px; }

/* ---------- 11. Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-xl);
  background:
    radial-gradient(560px 300px at 88% 0%, rgba(63, 155, 124, .38), transparent 65%),
    radial-gradient(400px 240px at 0% 100%, rgba(169, 123, 44, .18), transparent 70%),
    linear-gradient(135deg, #123B2D 0%, #0D2119 60%, #0B1A14 100%);
  color: #EAF2EC;
  padding: 30px 32px;
  box-shadow: 0 30px 60px -40px rgba(11, 23, 18, .9), inset 0 1px 0 rgba(255, 255, 255, .07);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 30px;
  align-items: center;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: .35;
  pointer-events: none;
}
.hero > * { position: relative; z-index: 1; }
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.2vw, 30px);
  font-weight: 500;
  letter-spacing: -.035em;
  line-height: 1.2;
  max-width: 22ch;
}
.hero-sub { color: rgba(234, 242, 236, .72); font-size: 14.5px; margin-top: 10px; max-width: 46ch; }
.hero-metrics {
  display: flex;
  gap: 34px;
  margin-top: 26px;
  flex-wrap: wrap;
}
.hero-metric .metric-label { color: rgba(234, 242, 236, .55); }
.hero-metric .metric-value { color: #fff; font-size: 23px; }
.hero-metric .metric-note { color: rgba(234, 242, 236, .6); }

.hero-side { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.score-ring { position: relative; width: 132px; height: 132px; }
.score-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.score-ring .val {
  position: absolute; inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-family: var(--font-display);
  font-weight: 500;
  letter-spacing: -.04em;
  color: #fff;
  line-height: 1;
}
.score-ring .val b { font-weight: 500; font-size: 34px; }
.score-ring .val span { font-size: 11px; color: rgba(255, 255, 255, .5); font-family: var(--font-body); font-weight: 500; letter-spacing: .02em; }
.score-cap { font-size: 11.5px; letter-spacing: .1em; text-transform: uppercase; color: rgba(234, 242, 236, .55); font-weight: 600; }
.score-note { font-size: 12.5px; color: rgba(234, 242, 236, .8); text-align: center; max-width: 20ch; }

/* ---------- 12. Путь ---------- */
.stepper { display: flex; flex-direction: column; }
.step {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--card);
  margin-bottom: 10px;
  transition: border-color var(--t) var(--ease), transform var(--t) var(--ease), box-shadow var(--t) var(--ease);
}
.step:hover { border-color: var(--line-2); transform: translateX(2px); box-shadow: var(--sh-1); }
.step--current { border-color: var(--brand-400); background: linear-gradient(90deg, #F0F8F4, #fff 55%); box-shadow: 0 0 0 3px rgba(63, 155, 124, .1); }
.step-num {
  width: 44px; height: 44px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 500;
  background: var(--paper-2);
  color: var(--muted);
  border: 1px solid var(--line);
}
.step--done .step-num { background: var(--brand-soft); color: var(--brand); border-color: #CFE6DB; }
.step--current .step-num { background: var(--brand); color: #fff; border-color: var(--brand); box-shadow: 0 8px 18px -10px rgba(15, 92, 70, .8); }
.step-title { font-size: 15px; font-weight: 600; display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.step-desc { font-size: 13px; color: var(--muted); margin-top: 3px; }
.step-meta { font-size: 12px; color: var(--muted-2); margin-top: 5px; }
.step-side { display: flex; align-items: center; gap: 12px; }

.progress-wrap { display: flex; align-items: center; gap: 12px; }
.progress {
  height: 8px;
  background: var(--paper-2);
  border-radius: 99px;
  overflow: hidden;
  flex: 1;
  min-width: 60px;
}
.progress-bar {
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--brand-600), var(--brand-400));
  transition: width 700ms var(--ease-out);
}
.progress-bar--gold { background: linear-gradient(90deg, #B98A34, #D6AC60); }
.progress-bar--coral { background: linear-gradient(90deg, #B44A32, #D2745C); }
.progress-val { font-size: 12.5px; font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; min-width: 38px; text-align: right; }
.progress--slim { height: 6px; }

/* ---------- 13. Цели ---------- */
.goal-card { display: flex; flex-direction: column; gap: 14px; }
.goal-top { display: flex; gap: 13px; align-items: flex-start; }
.goal-icon {
  width: 42px; height: 42px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: var(--brand-soft);
  color: var(--brand);
  flex: none;
}
.goal-icon svg { width: 21px; height: 21px; }
.goal-title { font-size: 15px; font-weight: 600; line-height: 1.3; }
.goal-when { font-size: 12.5px; color: var(--muted); margin-top: 3px; }
.goal-money { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.goal-sum { font-family: var(--font-display); font-size: 22px; letter-spacing: -.03em; }
.goal-of { font-size: 12.5px; color: var(--muted); }
.goal-foot {
  display: flex; align-items: center; gap: 12px;
  padding-top: 13px;
  border-top: 1px dashed var(--line);
  font-size: 12.5px;
  color: var(--muted);
}
.goal-foot .right { margin-left: auto; }

/* ---------- 14. Таблицы ---------- */
.table-wrap { overflow-x: auto; margin: 0 -6px; padding: 0 6px; }
table.data {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  min-width: 580px;
}
table.data th {
  text-align: left;
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted-2);
  font-weight: 600;
  padding: 0 12px 10px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
table.data td {
  padding: 13px 12px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr { transition: background var(--t-fast) var(--ease); }
table.data tbody tr:hover { background: var(--card-soft); }
table.data .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.data .strong { font-weight: 600; }
table.data .muted { color: var(--muted); }
table.data .right { text-align: right; }
.cell-main { display: flex; align-items: center; gap: 11px; }
.cell-title { font-weight: 600; }
.cell-sub { font-size: 12px; color: var(--muted); margin-top: 2px; }

/* ---------- 15. Списки, напоминания ---------- */
.list { display: flex; flex-direction: column; }
.list-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.list-row:last-child { border-bottom: 0; }
.list-row > svg { width: 18px; height: 18px; flex: none; color: var(--muted-2); }
.list-row > .goal-icon { flex: none; }
.list-row .grow { min-width: 0; flex: 1; }

.date-block {
  width: 46px;
  flex: none;
  text-align: center;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--card-soft);
  padding: 6px 0 5px;
}
.date-block .d { font-family: var(--font-display); font-size: 16px; line-height: 1; letter-spacing: -.02em; }
.date-block .m { font-size: 10px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); margin-top: 3px; }
.date-block--soon { border-color: #E9CFA4; background: var(--gold-soft); }
.date-block--soon .m { color: #8A5F17; }
.date-block--done { opacity: .5; }

.reminder-title { font-size: 14px; font-weight: 600; }
.reminder-note { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.reminder-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }

.check {
  width: 26px; height: 26px;
  border-radius: 8px;
  border: 1.5px solid var(--line-2);
  background: var(--card);
  display: grid;
  place-items: center;
  cursor: pointer;
  color: transparent;
  transition: all var(--t-fast) var(--ease);
  flex: none;
}
.check svg { width: 15px; height: 15px; }
.check:hover { border-color: var(--brand-400); background: var(--brand-soft); }
.check.on { background: var(--brand); border-color: var(--brand); color: #fff; }

.channel {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; color: var(--muted);
  background: var(--paper-2);
  border-radius: 99px;
  padding: 3px 9px;
}
.channel svg { width: 12px; height: 12px; }

/* ---------- 16. Донат и легенда ---------- */
.donut-wrap { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; }
.donut { position: relative; width: 205px; height: 205px; flex: none; }
.donut svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.donut-center {
  position: absolute; inset: 0;
  display: grid; place-content: center; text-align: center;
}
.donut-center .lbl { font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted-2); font-weight: 600; }
.donut-center .val { font-family: var(--font-display); font-size: 16px; line-height: 1.15; letter-spacing: -.04em; margin-top: 3px; max-width: 118px; margin-left: auto; margin-right: auto; white-space: nowrap; }

.legend { display: flex; flex-direction: column; gap: 10px; min-width: 190px; flex: 1; }
.legend-row { display: flex; align-items: center; gap: 10px; font-size: 13.5px; }
.swatch { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.legend-name { color: var(--ink-2); }
.legend-val { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; }
.legend-pct { color: var(--muted); font-size: 12px; width: 46px; text-align: right; font-variant-numeric: tabular-nums; }

/* ---------- 17. Графики ---------- */
.chart { width: 100%; height: auto; overflow: visible; }
.chart-legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 14px; font-size: 12.5px; color: var(--muted); }
.chart-legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; margin-right: 7px; }

.bars { display: flex; flex-direction: column; gap: 14px; }
.bar-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) 84px; gap: 14px; align-items: center; font-size: 13.5px; }
.bar-track { height: 10px; background: var(--paper-2); border-radius: 99px; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 99px; background: var(--brand-400); opacity: .85; transition: width 600ms var(--ease-out); }
.bar-val { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- 18. Планы ---------- */
.plan-card { display: flex; flex-direction: column; gap: 16px; position: relative; }
.plan-card--pop { border-color: var(--brand-400); box-shadow: 0 0 0 3px rgba(63, 155, 124, .12), var(--sh-2); }
.plan-badge {
  position: absolute; top: -12px; left: 22px;
  background: var(--brand); color: #fff;
  font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 12px; border-radius: 99px; font-weight: 700;
}
.plan-name { font-family: var(--font-display); font-size: 19px; letter-spacing: -.02em; }
.plan-tag { font-size: 13px; color: var(--muted); }
.plan-price { display: flex; align-items: baseline; gap: 6px; }
.plan-price .p { font-family: var(--font-display); font-size: 32px; letter-spacing: -.04em; }
.plan-price .per { font-size: 13px; color: var(--muted); }
.plan-features { display: flex; flex-direction: column; gap: 10px; font-size: 13.5px; }
.plan-features li { display: flex; gap: 9px; align-items: flex-start; color: var(--ink-2); }
.plan-features svg { width: 16px; height: 16px; flex: none; color: var(--brand-600); margin-top: 2px; }
.plan-card .btn { margin-top: auto; }

/* ---------- 19. Советник ---------- */
.client-row { cursor: pointer; }
.client-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center;
  font-size: 12.5px; font-weight: 700;
  background: var(--paper-2); color: var(--ink-2);
  flex: none;
  border: 1px solid var(--line);
}
.client-avatar--risk { background: var(--coral-soft); color: #96361F; border-color: #EFCBBF; }
.client-avatar--ok { background: var(--brand-soft); color: var(--brand); border-color: #CFE6DB; }

.mini-progress { width: 84px; height: 6px; background: var(--paper-2); border-radius: 99px; overflow: hidden; }
.mini-progress > i { display: block; height: 100%; background: var(--brand-400); border-radius: 99px; }

.cabinet-banner {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 18px;
  border-radius: var(--r-md);
  background: var(--gold-soft);
  border: 1px solid #E7CB9E;
  margin-bottom: 20px;
  font-size: 13.5px;
  color: #6E4A12;
  flex-wrap: wrap;
}
.cabinet-banner strong { font-weight: 700; }
.cabinet-banner > svg { width: 18px; height: 18px; flex: none; }
.cabinet-banner .right { margin-left: auto; }

/* ---------- 20. Модалка, тост ---------- */
.modal-layer {
  position: fixed; inset: 0; z-index: 100;
  display: none;
  align-items: center; justify-content: center;
  padding: 24px;
  background: rgba(11, 20, 16, .45);
  backdrop-filter: blur(3px);
}
.modal-layer.open { display: flex; animation: fadeIn 200ms var(--ease) both; }
@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }

.modal {
  width: min(560px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  background: var(--card);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-3);
  padding: 26px;
  animation: modalIn 260ms var(--ease-out) both;
}
@keyframes modalIn { from { opacity: 0; transform: translateY(14px) scale(.98) } to { opacity: 1; transform: none } }
.modal-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 20px; }
.modal-title { font-family: var(--font-display); font-size: 20px; letter-spacing: -.02em; font-weight: 500; }
.modal-sub { font-size: 13.5px; color: var(--muted); margin-top: 5px; }
.modal-close { margin-left: auto; }

.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 16px; }
.field label { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.field .help { font-size: 12px; color: var(--muted); }
.input, select.input, textarea.input {
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  border: 1px solid var(--line-2);
  border-radius: var(--r-sm);
  background: var(--card);
  font: inherit;
  font-size: 15px;
  color: var(--ink);
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
  appearance: none;
}
.input:hover { border-color: var(--line-strong); }
.input:focus { outline: none; border-color: var(--brand-400); box-shadow: 0 0 0 3px rgba(63, 155, 124, .16); }
textarea.input { min-height: 90px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.modal-foot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }

.toast-layer {
  position: fixed;
  bottom: 24px; left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  display: flex; flex-direction: column; gap: 10px;
  align-items: center;
  pointer-events: none;
}
.toast {
  display: flex; align-items: center; gap: 10px;
  background: var(--ink);
  color: #F4F1EA;
  padding: 12px 18px;
  border-radius: 99px;
  font-size: 13.5px;
  font-weight: 500;
  box-shadow: var(--sh-3);
  animation: toastIn 300ms var(--ease-out) both;
}
.toast svg { width: 16px; height: 16px; color: #6FCFA4; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) } to { opacity: 1; transform: none } }

/* ---------- 21. Разное ---------- */
.row-flex { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.mt-0 { margin-top: 0 } .mt-8 { margin-top: 8px } .mt-14 { margin-top: 14px } .mt-20 { margin-top: 20px }
.mb-0 { margin-bottom: 0 } .mb-14 { margin-bottom: 14px }
.muted { color: var(--muted) }
.small { font-size: 12.5px }
.strong { font-weight: 600 }
.num-t { font-variant-numeric: tabular-nums }
.divider { height: 1px; background: var(--line); margin: 16px 0; border: 0 }
.foot-note { font-size: 12px; color: var(--muted-2); margin-top: 14px; line-height: 1.5 }

.stat-strip { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.stat-strip > div { background: var(--card); padding: 18px 20px; }
.stat-strip .metric-value { font-size: 21px; }

.empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--muted);
  font-size: 14px;
}

/* ---------- 21b. Точечные компоненты ---------- */
.goal-add {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 230px;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--r-lg);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  padding: 24px;
  transition: border-color var(--t) var(--ease), background var(--t) var(--ease), color var(--t) var(--ease);
}
.goal-add svg { width: 26px; height: 26px; }
.goal-add span { font-weight: 600; color: var(--ink-2); font-size: 15px; }
.goal-add small { font-size: 12.5px; text-align: center; max-width: 30ch; line-height: 1.4; }
.goal-add:hover { border-color: var(--brand-400); color: var(--brand); background: rgba(63, 155, 124, .05); }

.cell-input {
  width: 126px;
  min-height: 38px;
  padding: 7px 11px;
  text-align: right;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
  border-radius: 10px;
}

.bar-row--edit { grid-template-columns: minmax(110px, .9fr) minmax(90px, 1.2fr) 132px; }
.bar-row--edit .bar-fill { background: var(--brand-400); }

.client-row { cursor: pointer; }

.muted svg { width: 16px; height: 16px; opacity: .7; }

/* ---------- 22. Адаптив ---------- */
@media (max-width: 1180px) {
  .cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 1024px) {
  :root { --sidebar-w: 248px; }
  .view { padding: 24px 24px 64px; }
  .topbar { padding: 0 24px; }
  .cols-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cols-2-1, .cols-1-2 { grid-template-columns: minmax(0, 1fr); }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .hero-side { flex-direction: row; justify-content: flex-start; align-items: center; gap: 18px; }
  .score-note { text-align: left; max-width: 28ch; }
}

@media (max-width: 900px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .sidebar {
    position: fixed;
    left: 0; top: 0; bottom: 0;
    width: 284px;
    transform: translateX(-104%);
    transition: transform 320ms var(--ease-out);
    box-shadow: 0 0 80px rgba(0, 0, 0, .5);
  }
  .app.nav-open .sidebar { transform: none; }
  .app.nav-open::after {
    content: "";
    position: fixed; inset: 0; z-index: 35;
    background: rgba(11, 20, 16, .45);
    backdrop-filter: blur(2px);
  }
  .burger { display: grid; }
  .topbar { padding: 0 18px; gap: 10px; }
  .topbar-crumbs { display: none; }
  .role-switch button { padding: 7px 11px; font-size: 12.5px; }
}

@media (max-width: 760px) {
  .view { padding: 20px 16px 80px; }
  .cols-2, .cols-3, .cols-4 { grid-template-columns: minmax(0, 1fr); }
  .page-head { gap: 14px; margin-bottom: 18px; flex-direction: column; align-items: stretch; }
  .page-head-main { width: 100%; }
  .page-actions { width: 100%; }
  .topbar-crumbs { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .page-actions .btn { flex: 1; }
  .hero { padding: 24px 22px; border-radius: 22px; }
  .hero-metrics { gap: 20px 28px; }
  .step { grid-template-columns: 44px minmax(0, 1fr); gap: 14px; padding: 16px; }
  .step-side { grid-column: 1 / -1; justify-content: space-between; padding-left: 58px; }
  .bar-row { grid-template-columns: 120px minmax(0, 1fr) 74px; }
  .bar-row--edit { grid-template-columns: minmax(0, 1fr) 118px; }
  .bar-row--edit .bar-track { grid-column: 1 / -1; grid-row: 2; }
  .donut-wrap { flex-direction: column; align-items: flex-start; }
  .donut { width: 100%; max-width: 220px; margin: 0 auto; }
  .form-row { grid-template-columns: 1fr; }
  .topbar { height: 68px; }
  .score-ring { width: 108px; height: 108px; }
  .score-ring .val { font-size: 28px; }
  .toast-layer { left: 16px; right: 16px; transform: none; align-items: stretch; }
  .toast { justify-content: center; }
  .stat-strip { grid-template-columns: minmax(0, 1fr); }
  .cabinet-banner { font-size: 13px; }
}

@media (max-width: 420px) {
  .role-switch button { padding: 6px 9px; font-size: 12px; }
  .metric-value { font-size: 23px; }
  .goal-sum { font-size: 20px; }
}

/* ---------- 23. Меньше движения ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .view { animation: none; }
}

/* ---------- 24. Компактные метрики и мобильная шапка ---------- */
.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}
.mini-stats .metric-value { font-size: 22px; }
.mini-stats .metric-note { font-size: 11.5px; }

@media (max-width: 760px) {
  .topbar { gap: 8px; }
  .topbar-crumbs { display: block; font-size: 10px; letter-spacing: .07em; }
  .topbar-sub { display: none; }
  .topbar-title { flex: 1; min-width: 0; }
  .topbar-right { gap: 8px; }
  .topbar .avatar { width: 40px; height: 40px; font-size: 13px; }
  .topbar .icon-btn { width: 42px; height: 42px; }
  .mini-stats { gap: 6px; }
  .mini-stats .metric-value { font-size: 12.5px; letter-spacing: -.03em; }
  .mini-stats .metric-label { font-size: 9.5px; letter-spacing: .04em; }
  .mini-stats .metric-note { display: none; }
}

@media (max-width: 400px) {
  .role-switch button { padding: 6px 8px; font-size: 11.5px; }
  .topbar { padding: 0 12px; }
  .view { padding: 16px 12px 72px; }
}

/* ---------- 25. Консультации ---------- */
.consult-card { display: flex; flex-direction: column; gap: 10px; }
.consult-card .between { gap: 12px; }
.consult-card .between > div:first-child { min-width: 0; }
.consult-card .small { line-height: 1.3; }
.consult-mini {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--card-soft);
}
.consult-mini .goal-icon { width: 38px; height: 38px; border-radius: 11px; }
.consult-mini .goal-icon svg { width: 19px; height: 19px; }

.segmented {
  display: flex;
  gap: 4px;
  background: var(--paper-2);
  padding: 4px;
  border-radius: 12px;
}
.segmented button {
  flex: 1;
  min-height: 38px;
  border: 0;
  background: none;
  border-radius: 9px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.segmented button:hover { color: var(--ink-2); }
.segmented button.on { background: var(--card); color: var(--ink); box-shadow: var(--sh-1); }

@media (max-width: 760px) {
  .consult-mini { flex-wrap: wrap; }
  .consult-mini .btn { width: 100%; }
}

/* ---------- 26. Бюджет 50/30/20 ---------- */
.rule-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.rule-col { padding: 16px; border: 1px solid var(--line); border-radius: 14px; background: var(--card-soft); }
.rule-name { font-weight: 600; font-size: 14px; }
.rule-target { font-size: 11.5px; color: var(--muted); background: var(--paper-2); padding: 3px 9px; border-radius: 99px; font-weight: 600; }
.rule-bar { position: relative; height: 10px; background: var(--paper-2); border-radius: 99px; margin: 14px 0 10px; }
.rule-fill { height: 100%; border-radius: 99px; opacity: .85; }
.rule-mark { position: absolute; top: -4px; width: 2px; height: 18px; background: var(--ink); border-radius: 2px; }

.exp-list { display: flex; flex-direction: column; }
.exp-group { border-bottom: 1px solid var(--line); padding-bottom: 8px; }
.exp-group:last-child { border-bottom: 0; }
.exp-head { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto auto 54px 20px; gap: 10px; align-items: center; width: 100%; background: none; border: 0; padding: 10px 4px; cursor: pointer; text-align: left; min-height: 54px; }
.exp-icon { width: 34px; height: 34px; border-radius: 10px; background: var(--paper-2); display: grid; place-items: center; color: var(--ink-2); }
.exp-icon svg { width: 17px; height: 17px; }
.exp-name { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.exp-tag { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); background: var(--paper-2); padding: 3px 8px; border-radius: 99px; white-space: nowrap; }
.exp-amount { font-weight: 600; font-variant-numeric: tabular-nums; }
.exp-share { font-size: 12px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.exp-chev svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.exp-chev.open svg { transform: rotate(180deg); }
.exp-track { height: 6px; background: var(--paper-2); border-radius: 99px; margin: 0 4px 6px 44px; overflow: hidden; }
.exp-fill { height: 100%; background: var(--brand-400); border-radius: 99px; opacity: .8; }
.exp-items { padding: 6px 4px 4px 44px; display: flex; flex-direction: column; gap: 8px; }
.exp-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 13.5px; color: var(--ink-2); }
.coef-card .metric-value { letter-spacing: -.02em; }

@media (max-width: 760px) {
  .rule-grid { grid-template-columns: minmax(0, 1fr); }
  .exp-head { grid-template-columns: 34px minmax(0, 1fr) auto 20px; }
  .exp-tag, .exp-share { display: none; }
  .exp-track { margin-left: 0; }
  .exp-items { padding-left: 0; }
}

/* ---------- 27. SWOT и матрица приоритетов ---------- */
.swot-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.swot-box { border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.swot-title { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; margin-bottom: 9px; }
.swot-box--s { border-color: #CFE6DB; background: #F2F8F4; }
.swot-box--s .swot-title { color: #0F5C46; }
.swot-box--w { border-color: #EFCBBF; background: #FBF1ED; }
.swot-box--w .swot-title { color: #96361F; }
.swot-box--o { border-color: #E7CB9E; background: #FBF5EA; }
.swot-box--o .swot-title { color: #8A5F17; }
.swot-box--t { border-color: #C9D3E9; background: #F2F5FB; }
.swot-box--t .swot-title { color: #35548F; }
.swot-box--now { border-color: #CFE6DB; background: #F2F8F4; }
.swot-box--now .swot-title { color: #0F5C46; }
.swot-box--imp { border-color: #E7CB9E; background: #FBF5EA; }
.swot-box--imp .swot-title { color: #8A5F17; }
.swot-box--urg { border-color: #C9D3E9; background: #F2F5FB; }
.swot-box--urg .swot-title { color: #35548F; }
.swot-box--later .swot-title { color: #6D7A73; }
.swot-box ul { display: flex; flex-direction: column; gap: 6px; }
.swot-box li { font-size: 13px; color: var(--ink-2); line-height: 1.4; padding-left: 13px; position: relative; }
.swot-box li::before { content: ""; position: absolute; left: 0; top: 7px; width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: .4; }

@media (max-width: 760px) {
  .swot-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ---------- 28. Режим интерфейса: новичок и профи ---------- */
.level-switch {
  margin: 10px 6px 0;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .08);
}
.level-title {
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(232, 239, 234, .42);
  font-weight: 600;
  margin-bottom: 8px;
}
.level-switch .segmented { background: rgba(0, 0, 0, .28); padding: 3px; }
.level-switch .segmented button { min-height: 32px; font-size: 12px; color: rgba(232, 239, 234, .7); }
.level-switch .segmented button.on { background: #F4F1EA; color: var(--brand-ink); }
.level-hint { font-size: 11px; color: rgba(232, 239, 234, .5); margin-top: 8px; line-height: 1.35; }

.level-novice .pro-only { display: none !important; }
.level-pro .novice-only { display: none !important; }
.level-novice .base-card { grid-column: 1 / -1; }

/* ---------- 29. Вход и регистрация ---------- */
.app-auth { min-height: 100vh; }
.auth { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); min-height: 100vh; background: var(--paper); }

.auth-side {
  position: relative;
  padding: 40px 44px 32px;
  display: flex;
  flex-direction: column;
  color: #EAF2EC;
  background:
    radial-gradient(600px 380px at 80% 10%, rgba(63, 155, 124, .34), transparent 65%),
    radial-gradient(420px 280px at 0% 100%, rgba(169, 123, 44, .16), transparent 70%),
    linear-gradient(135deg, #123B2D 0%, #0D2119 60%, #0B1A14 100%);
  overflow: hidden;
}
.auth-side::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(255,255,255,.07) 1px, transparent 1px);
  background-size: 24px 24px; opacity: .35;
}
.auth-brand { display: flex; align-items: center; gap: 12px; position: relative; z-index: 1; }
.auth-brand .brand-name { font-family: var(--font-display); font-size: 16px; }
.auth-brand .brand-sub { font-size: 11.5px; color: rgba(234,242,236,.55); margin-top: 2px; }
.auth-side-body { margin-top: auto; margin-bottom: auto; position: relative; z-index: 1; max-width: 420px; padding: 40px 0; }
.auth-side-body h1 { font-family: var(--font-display); font-size: clamp(28px, 3vw, 42px); font-weight: 500; line-height: 1.14; letter-spacing: -.035em; }
.auth-side-body p { color: rgba(234,242,236,.72); font-size: 16px; margin-top: 16px; }
.auth-points { margin-top: 26px; display: flex; flex-direction: column; gap: 12px; }
.auth-points li { display: flex; align-items: center; gap: 10px; font-size: 14.5px; color: rgba(234,242,236,.85); }
.auth-points svg { width: 18px; height: 18px; color: #7FD8B4; flex: none; }
.auth-side-foot { position: relative; z-index: 1; font-size: 12px; color: rgba(234,242,236,.45); }

.auth-main { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.auth-card {
  width: min(460px, 100%);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 24px;
  padding: 30px 30px 26px;
  box-shadow: 0 30px 70px -50px rgba(18, 28, 24, .5);
}
.auth-head h2 { font-family: var(--font-display); font-size: 26px; font-weight: 500; letter-spacing: -.03em; margin-top: 6px; }
.auth-head p { color: var(--muted); font-size: 14px; margin-top: 8px; margin-bottom: 20px; }
.auth-card .field { margin-bottom: 14px; }
.auth-card .btn { margin-top: 4px; }
.auth-error, .auth-ok {
  display: flex; gap: 9px; align-items: flex-start;
  padding: 11px 13px; border-radius: 12px; font-size: 13px; margin-bottom: 14px;
}
.auth-error { background: var(--coral-soft); color: #8F351F; border: 1px solid #EFCBBF; }
.auth-ok { background: var(--brand-soft); color: #0B5A43; border: 1px solid #CFE6DB; }
.auth-error svg, .auth-ok svg { width: 16px; height: 16px; flex: none; margin-top: 1px; }

.auth-links { margin-top: 16px; text-align: center; font-size: 13.5px; color: var(--muted); display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--muted-2); font-size: 12px; }
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.auth-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.auth-demo { margin-top: 20px; padding: 14px; border: 1px dashed var(--line-2); border-radius: 14px; background: var(--card-soft); }
.auth-demo-title { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 600; margin-bottom: 10px; }
.auth-note { display: flex; gap: 8px; margin-top: 18px; font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.auth-note svg { width: 15px; height: 15px; flex: none; margin-top: 1px; color: var(--brand-600); }

.check-row { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--ink-2); margin: 6px 0 14px; cursor: pointer; }
.check-row input { width: 17px; height: 17px; margin-top: 2px; accent-color: var(--brand); flex: none; }
.link-inline { border: 0; background: none; padding: 0; color: var(--brand-600); font: inherit; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }

.pw-meter { margin-top: 8px; }
.pw-bars { display: flex; gap: 5px; }
.pw-bars span { height: 5px; flex: 1; border-radius: 99px; background: var(--paper-2); transition: background .2s; }
.pw-label { font-size: 11.5px; margin-top: 6px; }

.code-input { letter-spacing: .5em; font-size: 20px; text-align: center; font-variant-numeric: tabular-nums; }

.option-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 16px; }
.option {
  display: flex; gap: 12px; align-items: flex-start; text-align: left;
  padding: 14px 16px; border: 1px solid var(--line-2); border-radius: 14px;
  background: var(--card); cursor: pointer; transition: all .18s var(--ease);
}
.option:hover { border-color: var(--line-strong); background: var(--card-soft); }
.option.on { border-color: var(--brand-400); background: #F2F8F4; box-shadow: 0 0 0 3px rgba(63,155,124,.12); }
.option-dot { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line-strong); flex: none; margin-top: 2px; }
.option.on .option-dot { border-color: var(--brand); background: radial-gradient(circle at center, var(--brand) 45%, transparent 47%); }
.option-title { display: block; font-weight: 600; font-size: 14.5px; }
.option-sub { display: block; font-size: 12.5px; color: var(--muted); margin-top: 3px; }

.ob-progress { height: 5px; background: var(--paper-2); border-radius: 99px; margin-top: 20px; overflow: hidden; }
.ob-progress span { display: block; height: 100%; background: var(--brand-400); border-radius: 99px; transition: width .3s var(--ease); }

.rec-box { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: 16px; background: var(--brand-soft); border: 1px solid #CFE6DB; }
.rec-icon { width: 44px; height: 44px; border-radius: 12px; background: var(--brand); color: #fff; display: grid; place-items: center; flex: none; }
.rec-icon svg { width: 22px; height: 22px; }
.rec-title { font-weight: 700; font-size: 15px; }

.chip-select { display: flex; flex-wrap: wrap; gap: 7px; }
.chip-opt { border: 1px solid var(--line-2); background: var(--card); border-radius: 99px; padding: 7px 12px; font-size: 12.5px; color: var(--ink-2); cursor: pointer; min-height: 34px; }
.chip-opt:hover { border-color: var(--line-strong); }
.chip-opt.on { background: var(--brand); border-color: var(--brand); color: #fff; }

.pending-box { background: var(--card-soft); border: 1px solid var(--line); border-radius: 14px; padding: 16px; margin-bottom: 18px; }

.auth-modal { position: fixed; inset: 0; z-index: 300; background: rgba(11,20,16,.5); backdrop-filter: blur(3px); display: flex; align-items: center; justify-content: center; padding: 20px; }
.auth-modal-card { width: min(560px, 100%); max-height: 86vh; overflow-y: auto; background: var(--card); border-radius: 20px; padding: 24px; box-shadow: var(--sh-3); }
.auth-modal-card h3 { font-family: var(--font-display); font-size: 19px; font-weight: 500; }

@media (max-width: 900px) {
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth-side { padding: 26px 22px; min-height: auto; }
  .auth-side-body { padding: 26px 0 8px; }
  .auth-side-body h1 { font-size: 27px; }
  .auth-side-body p { font-size: 14px; }
  .auth-points { display: none; }
  .auth-main { padding: 22px 16px 40px; align-items: flex-start; }
  .auth-card { padding: 24px 20px; border-radius: 20px; }
}


/* ---------- 30. Рефералы и аналитика ---------- */
.ref-code { font-family: var(--font-display); font-size: 30px; letter-spacing: .02em; margin-top: 6px; }
.ref-link { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ref-link-text { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; color: var(--ink-2); word-break: break-all; }
.ref-qr { width: 92px; height: 92px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); display: grid; place-items: center; color: var(--brand); flex: none; }
.ref-qr svg { width: 40px; height: 40px; }
.funnel-bar { height: 12px; background: var(--paper-2); border-radius: 99px; overflow: hidden; margin-top: 8px; }
.funnel-bar span { display: block; height: 100%; background: linear-gradient(90deg, var(--brand-600), var(--brand-400)); border-radius: 99px; }

/* ---------- 31. О проекте, риски, админ-журнал ---------- */
.auth-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.about-link { display: block; margin: 14px auto 0; border: 0; background: none; color: var(--muted); font-size: 12.5px; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.about-link:hover { color: var(--brand-600); }
.auth-side-foot { display: flex; flex-direction: column; gap: 6px; }
.foot-link { border: 0; background: none; padding: 0; color: rgba(234,242,236,.7); font-size: 12px; text-align: left; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.foot-link:hover { color: #fff; }

.about-points { display: flex; flex-direction: column; gap: 12px; margin: 4px 0 16px; }
.about-point { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--card-soft); }
.about-icon { width: 36px; height: 36px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; flex: none; }
.about-icon svg { width: 18px; height: 18px; }
.about-title { font-size: 13.5px; font-weight: 700; }
.about-sub { font-size: 12px; color: var(--muted); margin-top: 3px; line-height: 1.45; }
.risk-box { border: 1px solid #E8D3B8; background: #FBF4E8; border-radius: 14px; padding: 14px; margin-bottom: 16px; }
.risk-title { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 13px; color: #7A4E12; }
.risk-title svg { width: 16px; height: 16px; }
.risk-text { font-size: 11.5px; color: #6E5A3A; line-height: 1.5; margin-top: 8px; }
.about-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.journal-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.journal-filters { display: flex; gap: 6px; flex-wrap: wrap; }
.journal-filters .chip-opt { padding: 6px 11px; font-size: 12px; }

.quick-card { display: flex; align-items: center; gap: 12px; text-align: left; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); cursor: pointer; }
.quick-card:hover { border-color: var(--line-strong); background: var(--card-soft); }
.quick-icon { width: 38px; height: 38px; border-radius: 11px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; flex: none; }
.quick-icon svg { width: 18px; height: 18px; }
.quick-title { display: block; font-weight: 700; font-size: 13px; }
.quick-sub { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }

@media (max-width: 520px) {
  .auth-grid3 { grid-template-columns: 1fr; }
  .about-actions { grid-template-columns: 1fr; }
}

.side-risk { display: flex; gap: 7px; align-items: flex-start; width: 100%; text-align: left; border: 0; background: none; color: rgba(234,242,236,.5); font-size: 10.5px; line-height: 1.35; padding: 0 2px 10px; cursor: pointer; }
.side-risk svg { width: 13px; height: 13px; flex: none; margin-top: 1px; }
.side-risk:hover { color: rgba(234,242,236,.8); }

/* ---------- 32. Согласие на cookie ---------- */
.consent-bar {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 400;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  max-width: 980px; margin: 0 auto;
  background: #121C18; color: #EAF2EC;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px; padding: 14px 16px;
  box-shadow: 0 24px 60px -30px rgba(0,0,0,.6);
}
.consent-text { font-size: 12.5px; line-height: 1.45; color: rgba(234,242,236,.8); max-width: 640px; }
.consent-text strong { color: #fff; }
.consent-text a { color: #9BE3C2; text-underline-offset: 2px; }
.consent-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.consent-actions .btn--ghost { background: rgba(255,255,255,.08); color: #fff; border-color: rgba(255,255,255,.16); }
@media (max-width: 640px) { .consent-bar { left: 10px; right: 10px; bottom: 10px; padding: 12px; } .consent-actions { width: 100%; } .consent-actions .btn { flex: 1; } }
