    html { overflow-x: hidden; }
    body { padding: 32px 24px; }
body.pussy-power-mode {
      --bg: #ffebf0;
      --surface: #ffffff;
      --border: rgba(190, 24, 93, 0.18);
      --text: #831843;
      --text-secondary: #9d174d;
      --accent: #be185d;
      --accent-hover: #9d174d;
      --accent-soft: rgba(190, 24, 93, 0.14);
      --skill-ring-level: #be185d;
      --skill-ring-xp: #c2410c;
      --wrong: #b91c1c;
      --wrong-soft: rgba(185, 28, 28, 0.14);
      --circle-track: rgba(190, 24, 93, 0.15);
      --practice-color: #be185d;
      --clinical-color: #c2185b;
      --shadow: 0 1px 3px rgba(190, 24, 93, 0.08);
      --shadow-card: 0 4px 20px rgba(190, 24, 93, 0.12);
    }
    body.pussy-power-mode .card,
    body.pussy-power-mode .cabinet-card { background: var(--surface); border-color: var(--border); }
    body.pussy-power-mode .streak-card {
      --streak-accent: #be185d;
      --streak-soft: rgba(190, 24, 93, 0.14);
    }
    body.pussy-power-mode .league-card {
      --league-accent: #be185d;
      --league-soft: rgba(190, 24, 93, 0.14);
    }
    .pussy-power-banner { display: none; position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 10000; font-family: 'Quicksand', sans-serif; font-size: 1rem; font-weight: 600; color: var(--accent); pointer-events: none; cursor: pointer; transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease; }
    body.pussy-power-mode .pussy-power-banner { display: block; color: var(--accent); pointer-events: auto; }
    .pussy-power-banner.pussy-power-banner--hidden { transform: translate(-50%, -100%); opacity: 0; pointer-events: none; }
    .zoomer-mode-banner { display: none; position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 10000; font-family: 'Quicksand', sans-serif; font-size: 1rem; font-weight: 600; color: var(--accent); pointer-events: none; cursor: pointer; transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.35s ease; align-items: center; gap: 8px; }
    body.zoomer-mode .zoomer-mode-banner { display: flex; color: var(--accent); pointer-events: auto; }
    .zoomer-mode-banner.zoomer-mode-banner--hidden { transform: translate(-50%, -100%); opacity: 0; pointer-events: none; }
    .zoomer-mode-banner img { height: 28px; width: auto; display: block; }
    .zoomer-trigger { opacity: 0.28; font-size: 0.75rem; color: var(--text-secondary); background: none; border: none; cursor: pointer; padding: 4px 6px; margin: 0; font-family: inherit; text-decoration: none; transition: opacity 0.2s ease; }
    .zoomer-trigger:hover { opacity: 0.5; }
    #btnPussyPower.pressed { border-color: #be185d; background: rgba(190, 24, 93, 0.12); box-shadow: inset 0 1px 3px rgba(0,0,0,0.08); filter: saturate(1.1); }
    #btnPussyPower:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    body.pussy-power-mode .progress-circle-badge { background: var(--accent); }
    body.pussy-power-mode .league-card .league-table .league-row:nth-child(1) .league-rank { background: linear-gradient(135deg, #ec4899, #be185d); color: #fff; }
    body.pussy-power-mode .league-card .league-table .league-row:nth-child(2) .league-rank { background: linear-gradient(135deg, #f9a8d4, #ec4899); color: #fff; }
    body.pussy-power-mode .league-card .league-table .league-row:nth-child(3) .league-rank { background: linear-gradient(135deg, #fbcfe8, #f9a8d4); color: #831843; }
    body.pussy-power-mode .league-card .league-row-promo { background: rgba(34, 197, 94, 0.09); border-left-color: rgba(34, 197, 94, 0.5); }
    body.pussy-power-mode .league-card .league-row-danger { background: rgba(239, 68, 68, 0.09); border-left-color: rgba(239, 68, 68, 0.45); }
    body.pussy-power-mode .league-card .league-rules-list .league-rule-pts { color: var(--accent); }
    body.pussy-power-mode .streak-card .streak-flame.flame-low { color: var(--streak-accent); }
    body.pussy-power-mode .modal-overlay { background: rgba(190, 24, 93, 0.18); }
    body.pussy-power-mode .progress-circle-wrap.filled.practice .progress-circle-svg { filter: drop-shadow(0 0 10px rgba(190, 24, 93, 0.4)); }
    body.pussy-power-mode .progress-circle-wrap.filled.clinical .progress-circle-svg { filter: drop-shadow(0 0 10px rgba(194, 24, 120, 0.4)); }
    body.pussy-power-mode .progress-circle-wrap.complete.practice .progress-circle-svg { filter: drop-shadow(0 0 14px rgba(190, 24, 93, 0.55)); }
    body.pussy-power-mode .progress-circle-wrap.complete.clinical .progress-circle-svg { filter: drop-shadow(0 0 14px rgba(194, 24, 120, 0.55)); }
    .container { max-width: 560px; margin: 0 auto; }
    .header { margin-bottom: 24px; }
    .header h1 { font-size: 1.5rem; margin: 0 0 6px; color: var(--text); letter-spacing: -0.02em; }
    .header p { margin: 0; font-size: 0.9375rem; color: var(--text-secondary); }
    .card {
      background: var(--surface);
      border: 1px solid var(--border);
      border-radius: var(--radius);
      padding: 24px;
      margin-bottom: 20px;
      box-shadow: var(--shadow);
      transition: box-shadow 0.25s var(--ease);
    }
    .card:hover { box-shadow: var(--shadow-card); }
    #progressBlock,
    #progressBlock .card,
    #progressBlock .progress-card-header,
    #progressBlock .progress-list-sortable,
    #progressBlock .all-catalog-subject { box-shadow: none !important; }
    #progressBlock .card:hover,
    #progressBlock .all-catalog-subject:hover { box-shadow: none !important; }
    #progressBlock .all-catalog-subject-body { background: var(--surface) !important; }
    .card h2 { font-size: 1.125rem; margin: 0 0 14px; color: var(--text); }
    .btn-primary {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 8px;
      width: 100%;
      padding: 14px 24px;
      border: none;
      border-radius: var(--radius-sm);
      font-size: 0.9375rem;
      font-weight: 600;
      font-family: inherit;
      cursor: pointer;
      background: var(--accent);
      color: #fff;
      text-decoration: none;
      transition: background 0.2s var(--ease);
    }
    .btn-primary:hover { background: var(--accent-hover); }
    .btn-secondary {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      padding: 10px 18px;
      border: 2px solid var(--border);
      border-radius: var(--radius-sm);
      font-size: 0.875rem;
      font-weight: 600;
      font-family: inherit;
      cursor: pointer;
      background: var(--surface);
      color: var(--text-secondary);
      text-decoration: none;
      transition: border-color 0.2s var(--ease), color 0.2s var(--ease);
    }
    .btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
    .entitlements-list { margin-top: 4px; }
    .entitlements-row {
      display: flex;
      align-items: center;
      gap: 12px;
      padding: 12px 0;
      border-bottom: 1px solid var(--border);
      flex-wrap: wrap;
    }
    .entitlements-row:last-child { border-bottom: none; padding-bottom: 0; }
    .entitlements-row:first-child { padding-top: 4px; }
    .entitlements-row-name {
      flex: 1;
      min-width: 0;
      font-weight: 600;
      font-size: 0.9375rem;
      color: var(--text);
      line-height: 1.35;
    }
    .entitlements-row-meta {
      font-size: 0.8125rem;
      color: var(--text-secondary);
      white-space: nowrap;
    }
    .entitlements-row .btn-secondary { flex-shrink: 0; }

    /* Объединённый блок «Мои подписки» */
    .subs-list { margin-top: 2px; }
    .subs-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 6px 12px;
      padding: 14px 0;
      border-bottom: 1px solid var(--border);
    }
    .subs-row:last-child { border-bottom: none; padding-bottom: 0; }
    .subs-row:first-child { padding-top: 4px; }
    .subs-row-name {
      flex: 1;
      min-width: 140px;
      font-weight: 600;
      font-size: 0.9375rem;
      color: var(--text);
      line-height: 1.35;
    }
    .subs-row--expired .subs-row-name { color: var(--text-secondary); font-weight: 500; }
    .subs-pill {
      flex-shrink: 0;
      display: inline-flex;
      align-items: center;
      gap: 5px;
      font-size: 0.6875rem;
      font-weight: 700;
      padding: 4px 10px;
      border-radius: 999px;
      letter-spacing: 0.01em;
      white-space: nowrap;
    }
    .subs-pill::before {
      content: '';
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: currentColor;
    }
    .subs-pill--active  { background: rgba(13, 148, 136, 0.13); color: #0d7a70; }
    .subs-pill--soon    { background: rgba(217, 119, 6, 0.16);  color: #b45309; }
    .subs-pill--paused  { background: rgba(100, 116, 139, 0.16); color: #475569; }
    .subs-pill--failed  { background: rgba(220, 38, 38, 0.13);  color: #c2362f; }
    .subs-pill--expired { background: rgba(100, 116, 139, 0.12); color: #64748b; }
    .subs-row-meta {
      flex-basis: 100%;
      font-size: 0.8125rem;
      color: var(--text-secondary);
      line-height: 1.4;
      margin-top: -2px;
    }
    .subs-row--failed .subs-row-meta { color: #c2362f; }
    .subs-row-actions {
      flex-basis: 100%;
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
      margin-top: 4px;
    }
    .subs-row-actions .btn-secondary,
    .subs-row-actions .btn-primary {
      font-size: 0.8125rem;
      padding: 6px 12px;
      flex-shrink: 0;
    }
    .subs-catalog-pop { flex-basis: 100%; width: 100%; }
    .subs-expired-toggle {
      display: block;
      margin: 12px 0 0;
      padding: 4px 0;
      background: none;
      border: none;
      font: inherit;
      font-size: 0.8125rem;
      color: var(--text-secondary);
      cursor: pointer;
      text-decoration: underline;
      text-underline-offset: 2px;
    }
    .subs-expired-toggle:hover { color: var(--accent); }

    /* Секция «Оплата и счёт» внутри блока «Мои подписки» */
    .subs-pay {
      margin-top: 22px;
      padding-top: 18px;
      border-top: 1px solid var(--border);
    }
    .subs-pay-title {
      margin: 0;
      font-size: 0.9375rem;
      font-weight: 700;
      color: var(--text);
    }
    .subs-pay > div:empty { display: none; }
    .subs-pay .card,
    .subs-pay .card:hover {
      border: none;
      box-shadow: none;
      background: transparent;
      border-radius: 0;
      padding: 16px 0;
      margin: 0;
    }
    .subs-pay > div:not(:last-child) .card { border-bottom: 1px solid var(--border); }
    .subs-pay .card h2 {
      font-size: 0.9375rem;
      font-weight: 600;
      margin: 0 0 6px;
      color: var(--text);
    }

    /* Сворачивание блока «Мои подписки» */
    .subs-card-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
      cursor: pointer;
      margin-bottom: 14px;
      user-select: none;
    }
    .subs-card-head h2 { margin: 0; }
    .subs-card-head[aria-expanded="false"] { margin-bottom: 0; }
    .subs-card-head:focus-visible {
      outline: 2px solid var(--accent);
      outline-offset: 3px;
      border-radius: 6px;
    }
    .subs-chevron {
      flex-shrink: 0;
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--text-secondary);
      transition: transform 0.22s var(--ease), color 0.15s var(--ease);
    }
    .subs-card-head:hover .subs-chevron { color: var(--accent); }
    .subs-card-head[aria-expanded="false"] .subs-chevron { transform: rotate(-90deg); }

    /* Универсальное сворачивание карточек кабинета */
    .card-fold-head { cursor: pointer; user-select: none; }
    h2.card-fold-head {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 12px;
    }
    .card-fold-head[aria-expanded="false"] { margin-bottom: 0 !important; }
    .card-fold-head:focus-visible {
      outline: 2px solid var(--accent);
      outline-offset: 3px;
      border-radius: 6px;
    }
    .card-fold-chevron {
      flex-shrink: 0;
      align-self: center;
      margin-left: auto;
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--text-secondary);
      transition: transform 0.22s var(--ease), color 0.15s var(--ease);
    }
    .card-fold-head:hover .card-fold-chevron { color: var(--accent); }
    .card-fold-head[aria-expanded="false"] .card-fold-chevron { transform: rotate(-90deg); }

    .input { width: 100%; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 1rem; font-family: inherit; }
    .input:focus { outline: none; border-color: var(--accent); }
    .form-group { margin-bottom: 16px; }
    .form-group label { display: block; font-size: 0.875rem; color: var(--text-secondary); margin-bottom: 6px; }
    .error-msg { color: var(--wrong); font-size: 0.875rem; margin-top: 8px; padding: 10px; background: var(--wrong-soft); border-radius: var(--radius-sm); }
    .cabinet-header { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; }
    .cabinet-title { font-size: 1.25rem; font-weight: 700; margin: 0; }
    .cabinet-subtitle { word-break: break-word; }
    .cabinet-contact-toggle { display: inline-flex; align-items: center; gap: 6px; margin: 4px 0 0; padding: 4px 8px; background: transparent; border: 1px solid transparent; border-radius: var(--radius-sm); font-family: inherit; font-size: 0.875rem; color: var(--text-secondary); cursor: pointer; text-align: left; max-width: 100%; transition: background 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease); }
    .cabinet-contact-toggle:hover { background: var(--accent-soft); color: var(--accent); border-color: var(--accent-soft); }
    .cabinet-contact-toggle:focus-visible { outline: none; border-color: var(--accent); }
    .cabinet-contact-toggle-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60ch; }
    .cabinet-contact-toggle-chev { display: inline-block; font-size: 0.75rem; line-height: 1; transition: transform 0.18s var(--ease); opacity: 0.7; }
    .cabinet-contact-details[data-expanded="1"] .cabinet-contact-toggle-chev { transform: rotate(180deg); }
    .cabinet-auth-badge { display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; flex-shrink: 0; line-height: 0; }
    .cabinet-auth-badge[hidden] { display: none; }
    .cabinet-auth-badge svg { width: 16px; height: 16px; display: block; }
    .cabinet-auth-badge[data-provider="email"] svg,
    .cabinet-auth-badge[data-provider="phone"] svg,
    .cabinet-auth-badge[data-provider="apple"] svg { color: var(--text-secondary); }
    /* #cabinetInfo вынесен прямым потомком .cabinet-header — отдельная полноширинная
       строка под аватаром/кнопками, чтобы раскрытый список не зажимался в узкую
       колонку и не переносил email/тел по слогам. Видимостью рулит JS-тоггл. */
    .cabinet-info { flex-basis: 100%; width: 100%; order: 5; margin: 8px 0 0; font-size: 0.8125rem; color: var(--text-secondary); opacity: 0.9; line-height: 1.4; word-break: break-word; overflow: hidden; }
    .cabinet-info-group { margin-top: 10px; }
    .cabinet-info-group:first-child { margin-top: 0; }
    .cabinet-info-group-label { font-size: 0.625rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-secondary); opacity: 0.7; margin-bottom: 3px; }
    .cabinet-info span { display: block; margin-top: 2px; word-break: break-word; overflow-wrap: anywhere; }
    .cabinet-info span:first-child { margin-top: 0; }
    .cabinet-info-group-label + span { margin-top: 0; }
    .cabinet-info span + span::before { content: none; }
    .cabinet-info-copy { cursor: pointer; border-radius: 4px; padding: 2px 4px; margin: -2px -4px; transition: background 0.15s var(--ease); }
    .cabinet-info-copy:hover { background: var(--accent-soft); color: var(--accent); }
    .cabinet-info-copy.copied { background: var(--accent-soft); color: var(--accent); }
    @media (max-width: 768px) {
      .cabinet-info .cabinet-info-token { max-width: 14ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
      /* Лента «Сегодня» — это до 14 карточек подряд. Стандартный padding 24 +
         margin 20 на каждой давал ~900px чистого хрома. На мобиле ужимаем. */
      .card { padding: 16px; margin-bottom: 12px; }
      .plan-panel { margin-bottom: 12px; }
      .plan-panel > .plan-toolbar { padding: 12px 16px; }
      .plan-panel > .plan-rest-in-dev { padding: 10px 16px; }
      .card h2 { font-size: 1.0625rem; margin-bottom: 10px; }
    }
    .cabinet-avatar-wrap { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
    .cabinet-avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--accent-soft); display: flex; align-items: center; justify-content: center; font-size: 2rem; line-height: 1; flex-shrink: 0; border: 2px solid var(--border); cursor: pointer; transition: border-color 0.2s var(--ease), transform 0.15s var(--ease); }
    .cabinet-avatar:hover { border-color: var(--accent); transform: scale(1.03); }
    .cabinet-edit-btn { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface); color: var(--text-secondary); cursor: pointer; transition: border-color 0.2s var(--ease), color 0.2s var(--ease); text-decoration: none; position: relative; }
    .cabinet-edit-btn:hover { border-color: var(--accent); color: var(--accent); }
    .cabinet-edit-btn svg { width: 18px; height: 18px; }
    /* Компактная шапка на телефоне: аватар + заголовок + кнопки в одну строку,
       логин — узкий сворачиваемый чип под заголовком. Экономит ~2 строки по высоте. */
    @media (max-width: 768px) {
      .cabinet-header { flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
      .cabinet-avatar-wrap { flex: 1 1 auto; min-width: 0; gap: 10px; flex-wrap: nowrap; }
      .cabinet-avatar { width: 42px; height: 42px; font-size: 1.4rem; }
      .cabinet-id { min-width: 0; }
      .cabinet-title { font-size: 1.05rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
      .cabinet-contact-toggle { margin: 2px 0 0; padding: 2px 6px; font-size: 0.75rem; max-width: 100%; }
      .cabinet-contact-toggle-label { max-width: 22ch; }
      .cabinet-header-actions { flex-shrink: 0; gap: 4px; }
      .cabinet-edit-btn { width: 34px; height: 34px; }
      .cabinet-edit-btn svg { width: 16px; height: 16px; }
      .cabinet-header-actions .btn-secondary { padding: 7px 10px; font-size: 0.8125rem; }
      /* Шестерёнка в шапке стоит слева, поэтому right:0 уводил попап за левый край экрана.
         На мобиле раскрываем от левого края кнопки вправо и не даём вылезти за вьюпорт. */
      .cabinet-more-menu { right: auto; left: 0; max-width: calc(100vw - 24px); }
    }
    /* «Ещё» — попап с редко используемыми разделами, чтобы шапка кабинета не разъезжалась 7 иконками */
    .cabinet-more-wrap { position: relative; display: inline-flex; }
    #btnCabinetMore[aria-expanded="true"] { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
    .cabinet-more-dot { position: absolute; top: 6px; right: 7px; width: 7px; height: 7px; border-radius: 50%; background: #dc2626; box-shadow: 0 0 0 2px var(--surface); pointer-events: none; }
    .cabinet-more-menu {
      position: absolute; top: calc(100% + 8px); right: 0;
      min-width: 240px; padding: 6px;
      background: var(--surface);
      border: 1px solid var(--border); border-radius: 12px;
      box-shadow: 0 12px 32px rgba(0,0,0,0.12);
      z-index: 250;
      opacity: 0; transform: translateY(-4px) scale(0.98);
      pointer-events: none;
      transition: opacity .15s var(--ease), transform .15s var(--ease);
    }
    .cabinet-more-menu.open {
      opacity: 1; transform: translateY(0) scale(1);
      pointer-events: auto;
    }
    .cabinet-more-item {
      display: flex; align-items: center; gap: 10px;
      padding: 9px 10px; border-radius: 8px;
      color: var(--text); text-decoration: none;
      font-size: 0.9375rem; font-weight: 500;
      transition: background .15s var(--ease), color .15s var(--ease);
      width: auto; height: auto; border: none; background: none;
    }
    .cabinet-more-item:hover { background: var(--accent-soft); color: var(--accent); }
    .cabinet-more-item:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
    .cabinet-more-item-icon {
      width: 24px; height: 24px; flex: 0 0 24px;
      display: inline-flex; align-items: center; justify-content: center;
      color: var(--text-secondary); line-height: 1;
    }
    .cabinet-more-item:hover .cabinet-more-item-icon { color: var(--accent); }
    .cabinet-more-item-icon svg { width: 18px; height: 18px; display: block; }
    .cabinet-more-item-label { flex: 1; min-width: 0; }
    .cabinet-more-item-badge {
      background: #dc2626; color: #fff;
      font-size: 0.6875rem; font-weight: 700;
      min-width: 18px; height: 18px;
      border-radius: 9px; padding: 0 6px;
      display: inline-flex; align-items: center; justify-content: center;
    }
    /* Перебиваем шапочные стили cabinet-lab-trainer-btn внутри пункта меню — там фон/анимация не нужны */
    .cabinet-more-item.cabinet-lab-trainer-btn,
    .cabinet-more-item.cabinet-accelerator-btn {
      background: none; overflow: visible;
      width: auto; height: auto; border: none;
    }
    .cabinet-more-item.cabinet-lab-trainer-btn::after,
    .cabinet-more-item.cabinet-lab-trainer-btn::before { display: none; content: none; }
    .cabinet-more-item.cabinet-lab-trainer-btn:hover,
    .cabinet-more-item.cabinet-accelerator-btn:hover { background: var(--accent-soft); }
    .cabinet-more-item .cabinet-lab-trainer-anim { width: 22px; height: 22px; }
    .cabinet-more-item .cabinet-lab-trainer-anim svg { width: 22px; height: 22px; }
    /* Симулятор терапевта в шапке — мини-сцена в духе Lottie (SVG + CSS) */
    .cabinet-lab-trainer-btn {
      position: relative; overflow: hidden;
      background: linear-gradient(145deg, rgba(45, 212, 191, 0.12) 0%, rgba(129, 140, 248, 0.1) 55%, rgba(167, 139, 250, 0.08) 100%);
    }
    .cabinet-lab-trainer-btn:hover {
      background: linear-gradient(145deg, rgba(45, 212, 191, 0.2) 0%, rgba(129, 140, 248, 0.14) 55%, rgba(167, 139, 250, 0.1) 100%);
    }
    body.pussy-power-mode .cabinet-lab-trainer-btn {
      background: linear-gradient(145deg, rgba(236, 72, 153, 0.12) 0%, rgba(244, 114, 182, 0.1) 100%);
    }
    body.pussy-power-mode .cabinet-lab-trainer-btn:hover {
      background: linear-gradient(145deg, rgba(236, 72, 153, 0.2) 0%, rgba(244, 114, 182, 0.14) 100%);
    }
    .cabinet-lab-trainer-btn .cabinet-lab-trainer-anim {
      display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; pointer-events: none;
    }
    .cabinet-lab-trainer-btn svg { width: 26px; height: 26px; display: block; }
    .cab-lt-blob-a { animation: lt-sim-blob-a 3.6s ease-in-out infinite; transform-origin: 11px 12px; }
    .cab-lt-blob-b { animation: lt-sim-blob-b 2.9s ease-in-out infinite -0.6s; transform-origin: 21px 18px; }
    .cab-lt-heart { animation: lt-sim-heart 2.6s ease-in-out infinite; transform-origin: 16px 20px; }
    .cab-lt-ecg { animation: lt-sim-ecg 2.2s linear infinite; }
    .cabinet-lab-trainer-btn::after {
      content: ''; position: absolute; inset: -50% -80%; pointer-events: none;
      background: linear-gradient(100deg, transparent 42%, rgba(255, 255, 255, 0.45) 50%, transparent 58%);
      animation: lt-sim-shine 4s ease-in-out infinite;
    }
    @media (prefers-reduced-motion: reduce) {
      .cabinet-lab-trainer-btn .cab-lt-blob-a, .cabinet-lab-trainer-btn .cab-lt-blob-b,
      .cabinet-lab-trainer-btn .cab-lt-heart, .cabinet-lab-trainer-btn .cab-lt-ecg,
      .cabinet-lab-trainer-btn::after { animation: none !important; }
    }
    .cabinet-accelerator-btn { color: var(--accent); }
    .cabinet-accelerator-btn:hover { border-color: var(--accent); color: var(--accent); }
    .cabinet-accelerator-btn svg { width: 20px; height: 20px; }
    .modal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); display: none; align-items: center; justify-content: center; z-index: 500; padding: 20px; backdrop-filter: blur(4px); }
    .modal-overlay.visible { display: flex; }
    .linked-accounts-list { display: flex; flex-direction: column; gap: 8px; }
    .linked-account-row { display: flex; align-items: flex-start; gap: 12px; padding: 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
    .linked-account-row.linked { border-color: rgba(13,148,136,0.35); background: rgba(13,148,136,0.04); }
    .linked-account-icon { flex-shrink: 0; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 8px; background: var(--bg); }
    .linked-account-icon svg { width: 20px; height: 20px; }
    .linked-account-body { flex: 1; min-width: 0; }
    .linked-account-title { font-weight: 600; font-size: 0.9375rem; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
    .linked-account-status { font-size: 0.6875rem; font-weight: 600; padding: 2px 8px; border-radius: 999px; letter-spacing: 0.02em; text-transform: uppercase; }
    .linked-account-status.on { background: rgba(13,148,136,0.14); color: var(--accent); }
    .linked-account-status.off { background: rgba(100,116,139,0.12); color: var(--text-secondary); }
    .linked-account-desc { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 2px; }
    .linked-account-value { font-size: 0.8125rem; color: var(--text); margin-top: 2px; word-break: break-word; }
    .linked-account-action { flex-shrink: 0; align-self: center; }
    .linked-account-action button { font-size: 0.8125rem; padding: 6px 12px; border-radius: var(--radius-sm); border: 1px solid var(--accent); background: transparent; color: var(--accent); cursor: pointer; font-weight: 600; }
    .linked-account-action button:hover { background: var(--accent); color: #fff; }
    .linked-account-action button[disabled] { opacity: 0.5; cursor: default; }
    .linked-tg-open { display: inline-block; }
    .modal-card { position: relative; background: var(--surface); border-radius: var(--radius); padding: 24px; max-width: 400px; width: 100%; max-height: 80vh; overflow-y: auto; overflow-x: hidden; box-shadow: 0 8px 32px rgba(0,0,0,0.12); }
    /* Переиспользуемый крестик закрытия для любой .modal-card. Sticky, чтобы
       оставаться в углу при прокрутке длинной модалки. */
    .modal-card-x {
      position: sticky; top: -4px; float: right; margin: -8px -8px 0 8px; z-index: 2;
      width: 36px; height: 36px; padding: 0; border: none; border-radius: var(--radius-sm);
      background: transparent; color: var(--text-secondary); font-size: 1.5rem; line-height: 1; cursor: pointer;
      display: flex; align-items: center; justify-content: center; transition: color 0.2s var(--ease), background 0.2s var(--ease);
    }
    .modal-card-x:hover { color: var(--text); background: var(--bg); }
    .modal-card h3 { margin: 0 0 16px; font-size: 1.125rem; }
    /* Статус привязки СБП (v2) в модалке */
    .sbp-bind-status {
      display: none;
      align-items: flex-start;
      gap: 14px;
      padding: 14px 16px;
      margin: 0 0 14px;
      border-radius: 12px;
      border: 1px solid var(--border);
      background: var(--bg);
      box-shadow: 0 1px 0 rgba(0,0,0,0.04);
    }
    .sbp-bind-status.sbp-bind-status--visible { display: flex; }
    .sbp-bind-status-ico {
      flex-shrink: 0;
      width: 44px;
      height: 44px;
      border-radius: 12px;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .sbp-bind-status-ico svg { width: 24px; height: 24px; display: block; }
    .sbp-bind-status-body { min-width: 0; flex: 1; }
    .sbp-bind-status-title { font-weight: 600; font-size: 0.9375rem; margin: 0 0 4px; color: var(--text); line-height: 1.3; }
    .sbp-bind-status-sub { font-size: 0.8125rem; margin: 0; color: var(--text-secondary); line-height: 1.45; }
    .sbp-bind-status--awaiting_scan .sbp-bind-status-ico { background: rgba(13, 148, 136, 0.12); color: var(--accent); }
    .sbp-bind-status--awaiting_bank .sbp-bind-status-ico { background: rgba(217, 119, 6, 0.12); color: #b45309; }
    .sbp-bind-status--finalizing .sbp-bind-status-ico { background: rgba(13, 148, 136, 0.12); color: var(--accent); }
    .sbp-bind-status--qr_expired .sbp-bind-status-ico,
    .sbp-bind-status--declined .sbp-bind-status-ico { background: rgba(220, 38, 38, 0.1); color: var(--wrong, #c00); }
    .sbp-bind-status--awaiting_bank { border-color: rgba(217, 119, 6, 0.28); background: linear-gradient(135deg, rgba(217, 119, 6, 0.06) 0%, var(--bg) 100%); }
    .sbp-bind-status--awaiting_scan { border-color: rgba(13, 148, 136, 0.25); background: linear-gradient(135deg, rgba(13, 148, 136, 0.07) 0%, var(--bg) 100%); }
    .sbp-bind-status--finalizing .sbp-bind-status-ico .sbp-bind-spin { animation: sbp-bind-spin 0.9s linear infinite; transform-origin: center; }
    @keyframes sbp-bind-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
    .sbp-bind-status--awaiting_bank .sbp-bind-status-title::after {
      content: '';
      display: inline-block;
      width: 6px;
      height: 6px;
      margin-left: 8px;
      border-radius: 50%;
      background: #d97706;
      vertical-align: middle;
      animation: sbp-bind-pulse 1.4s ease-in-out infinite;
    }
    @keyframes sbp-bind-pulse { 0%, 100% { opacity: 0.35; transform: scale(0.85); } 50% { opacity: 1; transform: scale(1); } }
    .sbp-bind-status-refresh { margin-top: 12px; }
    .sbp-bind-status-refresh .btn-primary { width: 100%; }
    /* Модалка оплаты СБП — редизайн */
    .modal-card.sbp-payment-modal {
      max-width: 420px; padding: 0; overflow: hidden; box-shadow: 0 12px 40px rgba(0,0,0,0.14), 0 0 0 1px var(--border);
      display: flex; flex-direction: column; max-height: 85vh;
    }
    .sbp-payment-modal .sbp-payment-modal-header {
      padding: 20px 48px 16px 26px; border-bottom: 1px solid var(--border); background: linear-gradient(180deg, var(--accent-soft) 0%, transparent 100%);
      flex-shrink: 0; position: relative;
    }
    .sbp-payment-modal .sbp-payment-modal-header h3 {
      margin: 0 0 8px; font-size: 1.25rem; font-weight: 700; letter-spacing: -0.02em; color: var(--text);
    }
    .sbp-payment-modal .sbp-payment-modal-body { padding: 20px 26px 26px; flex: 1; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }
    .sbp-payment-modal .sbp-payment-modal-body .section-label { font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 12px; }
    .sbp-payment-modal .sbp-payment-modal-body .section-label a { font-weight: 600; }
    .sbp-plan-choices { display: flex; flex-direction: column; gap: 10px; margin-bottom: 4px; }
    .sbp-plan-option {
      border: 2px solid var(--border); border-radius: var(--radius-sm); padding: 14px 16px; cursor: pointer;
      transition: border-color 0.2s var(--ease), background 0.2s var(--ease), box-shadow 0.2s var(--ease);
      background: var(--surface);
    }
    .sbp-plan-option:hover { border-color: rgba(0,0,0,0.12); background: var(--bg); box-shadow: 0 1px 4px rgba(0,0,0,0.04); }
    .sbp-plan-option.selected {
      border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent);
    }
    .sbp-plan-option .plan-price { font-size: 1.0625rem; font-weight: 700; color: var(--text); display: block; margin-bottom: 2px; }
    .sbp-plan-option .plan-title { font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.35; }
    /* Апсейл «часто берут вместе» */
    .sbp-upsell { margin-top: 4px; }
    .sbp-upsell__title { font-weight: 600; color: var(--text) !important; }
    .sbp-upsell__list { display: flex; flex-direction: column; gap: 8px; }
    .sbp-upsell__item {
      display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer;
      border: 1.5px solid var(--border); border-radius: var(--radius-sm); background: var(--surface);
      transition: border-color 0.2s var(--ease), background 0.2s var(--ease);
    }
    .sbp-upsell__item:hover { border-color: rgba(0,0,0,0.12); background: var(--bg); }
    .sbp-upsell__item--on { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent); }
    .sbp-upsell__cb { width: 18px; height: 18px; flex-shrink: 0; accent-color: var(--accent); cursor: pointer; }
    .sbp-upsell__info { display: flex; align-items: baseline; justify-content: space-between; flex: 1; gap: 10px; min-width: 0; }
    .sbp-upsell__name { font-size: 0.9375rem; font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .sbp-upsell__price { font-size: 0.9375rem; font-weight: 700; color: var(--accent); flex-shrink: 0; }
    .sbp-upsell__add { flex-shrink: 0; padding: 7px 16px !important; font-size: 0.8125rem; box-shadow: none !important; }
    .sbp-upsell__add:disabled { opacity: 0.7; cursor: default; }
    .sbp-course-desc { margin: 0 0 10px; font-size: 0.875rem; color: var(--text); line-height: 1.5; }
    .sbp-course-stats { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
    .sbp-course-stat { font-size: 0.8125rem; color: var(--text-secondary); background: var(--bg); border: 1px solid var(--border); border-radius: 20px; padding: 3px 10px; white-space: nowrap; }
    .sbp-course-more-btn { display: inline-block; margin-bottom: 14px; font-size: 0.875rem; font-weight: 600; }
    #sbpPaymentModalCourseInfo { padding-bottom: 4px; border-bottom: 1px solid var(--border); margin-bottom: 14px; }
    .sbp-payment-modal .sbp-payment-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 16px; }
    .sbp-payment-modal .btn-primary {
      background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
      box-shadow: 0 2px 8px rgba(13, 148, 136, 0.35); padding: 12px 20px;
    }
    .sbp-payment-modal .btn-primary:hover { box-shadow: 0 4px 14px rgba(13, 148, 136, 0.4); }
    .sbp-payment-modal .sbp-payment-modal-close { margin-top: 16px; width: 100%; padding: 10px; color: var(--text-secondary); border-color: var(--border); }
    .sbp-payment-modal .sbp-payment-modal-close:hover { color: var(--text); border-color: rgba(0,0,0,0.15); background: var(--bg); }
    .sbp-payment-modal .sbp-payment-modal-x {
      position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; padding: 0; border: none; border-radius: var(--radius-sm);
      background: transparent; color: var(--text-secondary); font-size: 1.5rem; line-height: 1; cursor: pointer;
      display: flex; align-items: center; justify-content: center; transition: color 0.2s var(--ease), background 0.2s var(--ease);
    }
    .sbp-payment-modal .sbp-payment-modal-x:hover { color: var(--text); background: var(--bg); }
    body.pussy-power-mode .sbp-payment-modal .btn-primary { box-shadow: 0 2px 8px rgba(190, 24, 93, 0.35); }
    body.pussy-power-mode .sbp-payment-modal .btn-primary:hover { box-shadow: 0 4px 14px rgba(190, 24, 93, 0.4); }
    #editProfileModal .input:not(:placeholder-shown) { max-width: 200px; transition: max-width 0.2s ease; }
    #editProfileModal .input:placeholder-shown { max-width: none; }
    .avatar-picker { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 16px; }
    .avatar-picker-emoji { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--border); background: var(--bg); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; cursor: pointer; transition: border-color 0.2s var(--ease), transform 0.15s var(--ease); }
    .avatar-picker-emoji:hover { border-color: var(--accent); transform: scale(1.08); }
    .avatar-picker-emoji.selected { border-color: var(--accent); background: var(--accent-soft); }
    .link-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; align-items: center; }
    .link-row a { font-size: 0.875rem; white-space: nowrap; }
    .progress-item { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 16px; }
    .progress-item:last-child { margin-bottom: 0; }
    .progress-item-drag-handle {
      flex-shrink: 0; width: 24px; margin-top: 4px; cursor: grab; color: var(--text-secondary);
      display: flex; align-items: center; justify-content: center; user-select: none; touch-action: none;
      border-radius: 4px; padding: 4px; transition: color 0.15s, background 0.15s;
    }
    .progress-item-drag-handle:hover { color: var(--text); background: var(--surface); }
    .progress-item-drag-handle:active { cursor: grabbing; }
    .progress-item.progress-item-dragging { opacity: 0.6; }
    .progress-item.progress-item-drag-over { border-top: 2px solid var(--accent); margin-top: -2px; padding-top: 2px; }
    .progress-item-left { flex: 1; min-width: 0; overflow: hidden; }
    .progress-item-left p { word-break: break-word; overflow-wrap: break-word; }
    .progress-methodology-link { color: inherit; font-weight: 600; text-decoration: none; }
    .progress-methodology-link:hover { color: var(--accent); text-decoration: underline; }
    .progress-item-circles { display: flex; align-items: center; gap: 14px; flex-shrink: 0; margin-top: 2px; }
    .progress-circle-wrap { display: flex; flex-direction: column; align-items: center; gap: 4px; position: relative; }
    .progress-circle-link { display: flex; flex-direction: column; align-items: center; gap: 4px; text-decoration: none; color: inherit; cursor: pointer; border-radius: 50%; transition: transform 0.2s var(--ease), opacity 0.2s var(--ease); position: relative; }
    .progress-circle-badge { position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: #dc2626; color: #fff; font-size: 0.6875rem; font-weight: 700; display: flex; align-items: center; justify-content: center; line-height: 1; box-shadow: 0 1px 3px rgba(0,0,0,0.2); pointer-events: none; }
    .progress-to-repeat { font-size: 0.75rem; color: var(--accent); margin-top: 2px; }
    .progress-to-repeat a { font-weight: 600; text-decoration: none; color: var(--accent); }
    .progress-to-repeat a:hover { text-decoration: underline; }
    .progress-stat-link { color: var(--accent); text-decoration: none; }
    .progress-stat-link:hover { text-decoration: underline; }
    .progress-circle-link:hover { opacity: 0.9; transform: scale(1.05); }
    .progress-circle-link:active { transform: scale(0.98); }
    .progress-circle-wrap .progress-circle-label { font-size: 0.6875rem; color: var(--text-secondary); font-weight: 500; }
    .progress-circle-svg { width: 44px; height: 44px; display: block; }
    .progress-circle-svg .progress-circle-track { fill: none; stroke: var(--circle-track); stroke-width: 3; }
    .progress-circle-svg .progress-circle-stroke { fill: none; stroke-width: 3; stroke-linecap: round; stroke-dasharray: var(--circle-circumference); transition: stroke-dashoffset 1s cubic-bezier(0.33, 1, 0.68, 1); }
    .progress-circle-svg.practice .progress-circle-stroke { stroke: var(--practice-color); }
    .progress-circle-svg.clinical .progress-circle-stroke { stroke: var(--clinical-color); }
    .progress-circle-wrap .progress-circle-svg { transition: filter 0.4s var(--ease); }
    .progress-circle-wrap.filled.practice .progress-circle-svg { filter: drop-shadow(0 0 10px rgba(194, 65, 12, 0.45)); }
    .progress-circle-wrap.filled.clinical .progress-circle-svg { filter: drop-shadow(0 0 10px rgba(109, 40, 217, 0.45)); }
    .progress-circle-wrap.complete.practice .progress-circle-svg,
    .progress-circle-wrap.complete.clinical .progress-circle-svg {
      animation: progress-complete 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) 1 both;
    }
    .progress-circle-wrap.complete.practice .progress-circle-svg { filter: drop-shadow(0 0 14px rgba(194, 65, 12, 0.55)); }
    .progress-circle-wrap.complete.clinical .progress-circle-svg { filter: drop-shadow(0 0 14px rgba(109, 40, 217, 0.55)); }
    .progress-circle-check {
      opacity: 0;
      transform: scale(0.5);
      transition: opacity 0.25s var(--ease), transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    }
    .progress-circle-wrap.filled.complete .progress-circle-check {
      opacity: 1;
      transform: scale(1);
    }
    .progress-circle-wrap.filled.complete.practice .progress-circle-check { stroke: #fff; }
    .progress-circle-wrap.filled.complete.clinical .progress-circle-check { stroke: #fff; }
    /* Недоступные предметы/разделы (апсейл) */
    .progress-item.locked { opacity: 0.75; pointer-events: none; }
    .progress-item.locked .progress-methodology-link { color: var(--text-secondary); cursor: default; }
    .progress-item.locked .progress-methodology-link:hover { text-decoration: none; color: var(--text-secondary); }
    .progress-item.locked .progress-circle-wrap .progress-circle-track { stroke: var(--border); }
    .progress-item.locked .progress-circle-wrap .progress-circle-stroke { stroke: var(--text-secondary); opacity: 0.4; }
    .progress-item.locked .progress-circle-label { color: var(--text-secondary); }
    .progress-item.locked .progress-circle-link { cursor: default; }
    .progress-item.locked .progress-circle-link:hover { transform: none; opacity: 1; }
    /* Все предметы и разделы: приятный каталог и кнопки покупки */
    .card.card-all-catalog { padding: 28px 26px; box-shadow: none !important; }
    .card.card-all-catalog:hover { box-shadow: none !important; }
    .card-all-catalog .all-catalog-subject,
    .card-all-catalog .all-catalog-subject:hover { box-shadow: none !important; }
    .card-all-catalog h2 { font-size: 1.25rem; font-weight: 700; margin: 0 0 6px; letter-spacing: -0.02em; color: var(--text); }
    .card-all-catalog .section-label:first-of-type { font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 20px; display: block; }
    .catalog-promo-banner { margin: 0 0 14px; padding: 11px 14px; background: linear-gradient(180deg, #f5f3ff, #ede9fe); border: 1px solid #ddd6fe; border-radius: 12px; font-size: 0.875rem; color: var(--text); line-height: 1.45; }
    .catalog-promo-banner code { font-weight: 700; letter-spacing: 0.3px; color: var(--accent); }
    .all-catalog-subject {
      margin-bottom: 12px; border-radius: var(--radius-sm); border: 1px solid var(--border);
      background: var(--surface); overflow: hidden; transition: box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
    }
    .all-catalog-subject:last-child { margin-bottom: 0; }
    .all-catalog-subject:hover { box-shadow: var(--shadow); border-color: rgba(0,0,0,0.08); }
    .all-catalog-subject-header {
      display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 16px 18px; border: none; background: none;
      font-size: 1.0625rem; font-weight: 600; color: var(--text); text-align: left; cursor: pointer; font-family: inherit;
      transition: color 0.2s var(--ease), background 0.15s var(--ease); flex-wrap: wrap;
    }
    .all-catalog-subject-header:hover { color: var(--accent); background: var(--accent-soft); }
    .all-catalog-subject-header .all-catalog-subject-icon {
      font-size: 0.875rem; color: var(--text-secondary); transition: transform 0.25s var(--ease); flex-shrink: 0;
      width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; background: var(--bg);
      margin-top: 2px;
    }
    .all-catalog-subject-header.expanded .all-catalog-subject-icon { transform: rotate(90deg); color: var(--accent); background: var(--accent-soft); }
    .all-catalog-subject-header .all-catalog-subject-name { flex: 1; min-width: 0; }
    .all-catalog-subject-header .section-label { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 500; flex-shrink: 0; }
    .all-catalog-subject-emoji { font-size: 1.3rem; flex-shrink: 0; width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; background: var(--accent-soft); margin-top: 0; }
    .all-catalog-subject-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
    .all-catalog-subject-title-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
    .all-catalog-subject-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 0.8125rem; font-weight: 400; color: var(--text-secondary); }
    .all-catalog-subject-meta-item { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
    .all-catalog-subject-price { font-weight: 600; color: var(--accent); font-size: 0.8125rem; flex-shrink: 0; background: var(--accent-soft); padding: 4px 10px; border-radius: 6px; white-space: nowrap; }
    .all-catalog-subject-benefit { font-size: 0.8125rem; color: var(--text-secondary); font-weight: 400; width: 100%; padding-left: 48px; margin-top: -2px; }
    .all-catalog-subject-body { display: none; padding: 0 18px 18px; border-top: 1px solid var(--border); background: var(--bg); }
    .all-catalog-subject-body.visible { display: block; }
    .all-catalog-subject.catalog-subject-highlight { background: var(--accent-soft); box-shadow: 0 0 0 2px var(--accent); border-color: var(--accent); }
    .all-catalog-subject-body .progress-item { margin-bottom: 10px; }
    .all-catalog-subject-body .progress-item:last-child { margin-bottom: 0; }
    /* Группы разделов в «Ваш прогресс» — в стилистике карточек предметов */
    .all-catalog-subject-body .progress-section-group {
      margin-bottom: 10px; border-radius: var(--radius-sm); border: 1px solid var(--border);
      background: var(--surface); overflow: hidden; transition: box-shadow 0.2s var(--ease), border-color 0.2s var(--ease);
    }
    .all-catalog-subject-body .progress-section-group:last-child { margin-bottom: 0; }
    .all-catalog-subject-body .progress-section-group:hover { box-shadow: var(--shadow); border-color: rgba(0,0,0,0.08); }
    .progress-section-group-header {
      display: flex; align-items: center; gap: 10px; width: 100%; padding: 12px 16px; border: none; background: none;
      font-size: 0.9375rem; font-weight: 600; color: var(--text); text-align: left; cursor: pointer; font-family: inherit;
      transition: color 0.2s var(--ease), background 0.15s var(--ease);
    }
    .progress-section-group-header:hover { color: var(--accent); background: var(--accent-soft); }
    .progress-section-group-header .progress-section-group-icon {
      font-size: 0.75rem; color: var(--text-secondary); transition: transform 0.25s var(--ease); flex-shrink: 0;
      width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; background: var(--bg);
    }
    .progress-section-group-header.expanded .progress-section-group-icon { transform: rotate(90deg); color: var(--accent); background: var(--accent-soft); }
    .progress-section-group-header .progress-section-group-name { flex: 1; min-width: 0; }
    .progress-section-group-header .section-label { font-size: 0.75rem; color: var(--text-secondary); font-weight: 500; flex-shrink: 0; }
    .progress-section-group-body { display: none; padding: 12px 16px 14px; border-top: 1px solid var(--border); background: var(--bg); }
    .progress-section-group-body.visible { display: block; }
    .progress-section-group-body .progress-item { margin-bottom: 8px; }
    .progress-section-group-body .progress-item:last-child { margin-bottom: 0; }
    /* Кнопка оплаты по СБП в каталоге — акцентная, привлекательная */
    .catalog-sbp-btn {
      display: inline-flex; align-items: center; justify-content: center; gap: 10px; width: 100%;
      padding: 14px 20px; margin-top: 16px; margin-bottom: 16px; border: none; border-radius: var(--radius-sm);
      font-size: 0.9375rem; font-weight: 600; font-family: inherit; cursor: pointer;
      background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
      color: #fff; text-decoration: none; transition: transform 0.15s var(--ease), box-shadow 0.2s var(--ease), opacity 0.2s;
      box-shadow: 0 2px 8px rgba(13, 148, 136, 0.35);
    }
    .catalog-sbp-btn:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(13, 148, 136, 0.4); opacity: 1; }
    .catalog-sbp-btn:active { transform: translateY(0); }
    .catalog-sbp-btn .catalog-sbp-icon { font-size: 1.125rem; opacity: 0.95; }
    body.pussy-power-mode .catalog-sbp-btn { box-shadow: 0 2px 8px rgba(190, 24, 93, 0.35); }
    body.pussy-power-mode .catalog-sbp-btn:hover { box-shadow: 0 4px 14px rgba(190, 24, 93, 0.4); }
    /* Строки разделов в каталоге (недоступные) — мягкие карточки */
    .all-catalog-subject-body .progress-item.locked {
      padding: 12px 14px; border-radius: var(--radius-sm); background: var(--surface);
      border: 1px solid var(--border); opacity: 1; margin-bottom: 8px;
    }
    .all-catalog-subject-body .progress-item.locked .progress-item-left .section-label { color: var(--text-secondary); font-size: 0.8125rem; }
    .all-catalog-subject-body .progress-item.locked .progress-item-left p:last-child { font-weight: 600; color: var(--text); font-size: 0.9375rem; margin: 2px 0 0; }
    .all-catalog-subject-body .progress-item.locked .progress-circle-wrap {
      background: var(--bg); border-radius: 20px; padding: 6px 10px; border: 1px solid var(--border);
    }
    .all-catalog-subject-body .progress-item.locked .progress-circle-wrap .progress-circle-svg { width: 36px; height: 36px; }
    .all-catalog-subject-body .progress-item.locked .progress-circle-label { font-size: 0.625rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; color: var(--text-secondary); }
    .all-catalog-subject-drag-handle {
      flex-shrink: 0; width: 24px; cursor: grab; color: var(--text-secondary);
      display: flex; align-items: center; justify-content: center; user-select: none; touch-action: none;
      border-radius: 4px; padding: 4px; transition: color 0.15s, background 0.15s;
    }
    .all-catalog-subject-drag-handle:hover { color: var(--text); background: var(--surface); }
    .all-catalog-subject-drag-handle:active { cursor: grabbing; }
    .all-catalog-subject.all-catalog-subject-dragging { opacity: 0.6; }
    .all-catalog-subject.all-catalog-subject-drag-over { border-top: 2px solid var(--accent); margin-top: -2px; padding-top: 2px; }
    .personal-recs-card { position: relative; overflow: hidden; }
    .personal-recs-hero { padding: 16px; border-radius: var(--radius-sm); margin-bottom: 16px; background: linear-gradient(135deg, rgba(59, 130, 246, 0.08) 0%, rgba(59, 130, 246, 0.02) 100%); border: 1px solid rgba(59, 130, 246, 0.12); }
    .personal-recs-hero-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 4px; }
    .personal-recs-hero-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .personal-rec-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; margin-bottom: 8px; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border); transition: border-color 0.15s, box-shadow 0.15s; text-decoration: none; color: inherit; }
    a.personal-rec-item { cursor: pointer; }
    .personal-rec-item:hover { border-color: rgba(59, 130, 246, 0.3); box-shadow: 0 2px 8px rgba(59, 130, 246, 0.08); }
    .personal-rec-icon { font-size: 1.25rem; flex-shrink: 0; line-height: 1; margin-top: 2px; }
    .personal-rec-body { flex: 1; min-width: 0; }
    .personal-rec-title { font-weight: 600; font-size: 0.9375rem; color: var(--text); margin: 0 0 2px; }
    .personal-rec-reason { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.4; }
    .personal-rec-label { font-size: 0.6875rem; font-weight: 600; padding: 2px 8px; border-radius: 10px; flex-shrink: 0; align-self: center; white-space: nowrap; }
    .personal-rec-label--weak_section, .personal-rec-label--section_review { color: #d97706; background: #fef3c7; }
    .personal-rec-label--untouched_owned, .personal-rec-label--subject_start { color: #059669; background: #d1fae5; }
    .personal-rec-label--cf_section, .personal-rec-label--cf_subject, .personal-rec-label--subject { color: rgba(59,130,246,0.8); background: rgba(59,130,246,0.08); }
    .kg-card { position: relative; overflow: hidden; }
    .kg-hero { padding: 16px; border-radius: var(--radius-sm); margin-bottom: 16px; background: linear-gradient(135deg, rgba(239, 68, 68, 0.08) 0%, rgba(239, 68, 68, 0.02) 100%); border: 1px solid rgba(239, 68, 68, 0.12); }
    .kg-hero-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 4px; }
    .kg-hero-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .kg-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; margin-bottom: 8px; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border); transition: border-color 0.15s, box-shadow 0.15s; text-decoration: none; cursor: pointer; }
    .kg-item:hover { border-color: rgba(239, 68, 68, 0.3); box-shadow: 0 2px 8px rgba(239, 68, 68, 0.08); }
    .kg-icon { font-size: 1.25rem; flex-shrink: 0; line-height: 1; margin-top: 2px; }
    .kg-body { flex: 1; min-width: 0; }
    .kg-title { font-weight: 600; font-size: 0.9375rem; color: var(--text); margin: 0 0 2px; }
    .kg-subject { font-size: 0.75rem; color: var(--text-secondary); margin: 0 0 4px; }
    .kg-reason { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.4; }
    .kg-accuracy { font-size: 0.6875rem; font-weight: 600; padding: 2px 8px; border-radius: 10px; flex-shrink: 0; align-self: center; }
    .kg-accuracy-low { color: rgba(239, 68, 68, 0.8); background: rgba(239, 68, 68, 0.08); }
    .kg-accuracy-mid { color: rgba(234, 179, 8, 0.8); background: rgba(234, 179, 8, 0.08); }
    .kg-accuracy-ok { color: rgba(34, 197, 94, 0.8); background: rgba(34, 197, 94, 0.08); }
    .srs-card { position: relative; overflow: hidden; }
    .srs-hero { padding: 16px; border-radius: var(--radius-sm); margin-bottom: 16px; background: linear-gradient(135deg, rgba(139, 92, 246, 0.08) 0%, rgba(139, 92, 246, 0.02) 100%); border: 1px solid rgba(139, 92, 246, 0.12); display: flex; align-items: center; gap: 16px; }
    .srs-hero-icon { font-size: 2rem; line-height: 1; flex-shrink: 0; }
    .srs-hero-body { flex: 1; min-width: 0; }
    .srs-hero-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 4px; }
    .srs-hero-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .srs-hero-count { font-size: 1.75rem; font-weight: 800; color: rgba(139, 92, 246, 0.85); flex-shrink: 0; line-height: 1; }
    .srs-section-row { display: flex; align-items: center; gap: 10px; padding: 10px 14px; margin-bottom: 6px; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border); text-decoration: none; cursor: pointer; transition: border-color 0.15s; }
    .srs-section-row:hover { border-color: rgba(139, 92, 246, 0.3); }
    .srs-section-name { flex: 1; font-size: 0.9375rem; font-weight: 500; color: var(--text); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .srs-section-count { font-size: 0.8125rem; font-weight: 600; color: rgba(139, 92, 246, 0.7); background: rgba(139, 92, 246, 0.08); padding: 2px 10px; border-radius: 10px; flex-shrink: 0; }
    .srs-start-btn { display: block; width: 100%; padding: 12px; margin-top: 12px; text-align: center; font-size: 0.9375rem; font-weight: 600; color: #fff; background: rgba(139, 92, 246, 0.85); border: none; border-radius: var(--radius-sm); cursor: pointer; text-decoration: none; transition: background 0.15s; }
    .srs-start-btn:hover { background: rgba(139, 92, 246, 1); }
    /* Симулятор терапевта — мини-сцена в духе Lottie (CSS + SVG, без внешней библиотеки) */
    .clinical-tools-inner { display: flex; flex-direction: column; gap: 14px; }
    .clinical-tools-chips { display: flex; flex-wrap: wrap; gap: 8px; }
    .lab-trainer-sim-card {
      display: flex; align-items: center; gap: 16px; padding: 14px 16px; border-radius: 16px; text-decoration: none; color: inherit;
      background: linear-gradient(135deg, rgba(45, 212, 191, 0.14) 0%, rgba(59, 130, 246, 0.08) 48%, rgba(167, 139, 250, 0.1) 100%);
      border: 1px solid rgba(45, 212, 191, 0.28); box-shadow: 0 4px 20px rgba(15, 118, 110, 0.08);
      transition: transform 0.35s cubic-bezier(0.34, 1.2, 0.64, 1), box-shadow 0.3s ease, border-color 0.25s ease;
    }
    .lab-trainer-sim-card:hover {
      transform: translateY(-2px) scale(1.01);
      border-color: rgba(45, 212, 191, 0.45);
      box-shadow: 0 8px 28px rgba(15, 118, 110, 0.14), 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
    }
    .lab-trainer-sim-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
    body.pussy-power-mode .lab-trainer-sim-card {
      background: linear-gradient(135deg, rgba(236, 72, 153, 0.12) 0%, rgba(244, 114, 182, 0.08) 50%, rgba(190, 24, 93, 0.06) 100%);
      border-color: rgba(236, 72, 153, 0.32);
      box-shadow: 0 4px 20px rgba(190, 24, 93, 0.1);
    }
    body.pussy-power-mode .lab-trainer-sim-card:hover {
      border-color: rgba(236, 72, 153, 0.48);
      box-shadow: 0 8px 28px rgba(190, 24, 93, 0.16), 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
    }
    .lab-trainer-sim-anim {
      flex-shrink: 0; width: 72px; height: 72px; border-radius: 20px;
      background: linear-gradient(160deg, rgba(255, 255, 255, 0.95) 0%, rgba(240, 253, 250, 0.9) 100%);
      border: 1px solid rgba(45, 212, 191, 0.2); display: flex; align-items: center; justify-content: center;
      box-shadow: 0 2px 12px rgba(13, 148, 136, 0.12) inset, 0 4px 14px rgba(15, 118, 110, 0.08);
      overflow: hidden; position: relative;
    }
    body.pussy-power-mode .lab-trainer-sim-anim {
      background: linear-gradient(160deg, rgba(255, 255, 255, 0.98) 0%, rgba(253, 242, 248, 0.95) 100%);
      border-color: rgba(236, 72, 153, 0.22);
      box-shadow: 0 2px 12px rgba(190, 24, 93, 0.08) inset, 0 4px 14px rgba(190, 24, 93, 0.08);
    }
    .lab-trainer-sim-anim svg { width: 64px; height: 64px; display: block; }
    @keyframes lt-sim-blob-a {
      0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.55; }
      45% { transform: translate(2px, -3px) scale(1.07); opacity: 0.85; }
    }
    @keyframes lt-sim-blob-b {
      0%, 100% { transform: translate(0, 0) scale(1); opacity: 0.4; }
      50% { transform: translate(-3px, 2px) scale(1.12); opacity: 0.7; }
    }
    @keyframes lt-sim-heart {
      0%, 100% { transform: scale(1); }
      15% { transform: scale(1.12); }
      30% { transform: scale(1); }
      45% { transform: scale(1.08); }
      60% { transform: scale(1); }
    }
    @keyframes lt-sim-ecg {
      0% { stroke-dashoffset: 40; }
      100% { stroke-dashoffset: 0; }
    }
    @keyframes lt-sim-shine {
      0% { transform: translateX(-100%) rotate(12deg); opacity: 0; }
      35% { opacity: 0.35; }
      100% { transform: translateX(160%) rotate(12deg); opacity: 0; }
    }
    .lt-sim-blob-a { animation: lt-sim-blob-a 4s ease-in-out infinite; transform-origin: 28px 32px; }
    .lt-sim-blob-b { animation: lt-sim-blob-b 3.2s ease-in-out infinite -0.8s; transform-origin: 52px 44px; }
    .lt-sim-heart { animation: lt-sim-heart 2.8s ease-in-out infinite; transform-origin: 40px 38px; }
    .lt-sim-ecg { animation: lt-sim-ecg 2.4s linear infinite; }
    .lab-trainer-sim-anim::after {
      content: ''; position: absolute; inset: -40% -60%; pointer-events: none;
      background: linear-gradient(105deg, transparent 40%, rgba(255, 255, 255, 0.55) 50%, transparent 60%);
      animation: lt-sim-shine 4.5s ease-in-out infinite;
    }
    @media (prefers-reduced-motion: reduce) {
      .lt-sim-blob-a, .lt-sim-blob-b, .lt-sim-heart, .lt-sim-ecg, .lab-trainer-sim-anim::after { animation: none !important; }
      .lab-trainer-sim-card:hover { transform: none; }
    }
    .lab-trainer-sim-text { flex: 1; min-width: 0; text-align: left; }
    .lab-trainer-sim-kicker { font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: rgba(13, 148, 136, 0.85); margin: 0 0 4px; }
    body.pussy-power-mode .lab-trainer-sim-kicker { color: rgba(190, 24, 93, 0.85); }
    .lab-trainer-sim-title { font-size: 1.0625rem; font-weight: 700; color: var(--text); margin: 0 0 4px; letter-spacing: -0.02em; }
    .lab-trainer-sim-desc { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .lab-trainer-sim-go { flex-shrink: 0; font-size: 1.35rem; color: rgba(13, 148, 136, 0.75); line-height: 1; transition: transform 0.25s cubic-bezier(0.34, 1.2, 0.64, 1); }
    body.pussy-power-mode .lab-trainer-sim-go { color: rgba(190, 24, 93, 0.7); }
    .lab-trainer-sim-card:hover .lab-trainer-sim-go { transform: translateX(4px); }
    @media (max-width: 420px) {
      .lab-trainer-sim-card { flex-direction: column; align-items: stretch; text-align: center; }
      .lab-trainer-sim-text { text-align: center; }
      .lab-trainer-sim-anim { align-self: center; }
      .lab-trainer-sim-go { align-self: center; margin-top: 4px; }
      .lab-trainer-sim-card:hover .lab-trainer-sim-go { transform: translateY(2px); }
    }
    .nba-card { position: relative; overflow: hidden; }
    .nba-header { padding: 16px; border-radius: var(--radius-sm); margin-bottom: 16px; background: linear-gradient(135deg, rgba(16, 185, 129, 0.08) 0%, rgba(16, 185, 129, 0.02) 100%); border: 1px solid rgba(16, 185, 129, 0.12); }
    .nba-header-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 4px; }
    .nba-header-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .nba-item { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px; margin-bottom: 6px; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border); text-decoration: none; cursor: pointer; transition: border-color 0.15s, box-shadow 0.15s; position: relative; }
    .nba-item:hover { border-color: rgba(16, 185, 129, 0.3); box-shadow: 0 1px 4px rgba(16, 185, 129, 0.06); }
    .nba-rank { width: 24px; height: 24px; border-radius: 50%; background: rgba(16, 185, 129, 0.1); color: rgba(16, 185, 129, 0.85); font-size: 0.75rem; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; margin-top: 2px; }
    .nba-body { flex: 1; min-width: 0; }
    .nba-title { font-size: 0.9375rem; font-weight: 600; color: var(--text); margin: 0 0 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .nba-subtitle { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; line-height: 1.4; }
    .nba-meta { display: flex; align-items: center; gap: 8px; flex-shrink: 0; align-self: center; }
    .nba-time { font-size: 0.6875rem; font-weight: 600; color: var(--text-secondary); background: var(--surface); padding: 2px 8px; border-radius: 10px; white-space: nowrap; }
    .nba-dismiss { width: 20px; height: 20px; border: none; background: none; color: var(--text-secondary); cursor: pointer; opacity: 0; transition: opacity 0.15s, color 0.15s; font-size: 0.875rem; padding: 0; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
    .nba-item:hover .nba-dismiss { opacity: 0.6; }
    .nba-dismiss:hover { opacity: 1 !important; color: rgba(239, 68, 68, 0.8); }
    .nba-source-srs .nba-rank { background: rgba(139, 92, 246, 0.1); color: rgba(139, 92, 246, 0.85); }
    .nba-source-knowledge_gap .nba-rank { background: rgba(239, 68, 68, 0.1); color: rgba(239, 68, 68, 0.85); }
    .nba-source-plan .nba-rank { background: rgba(59, 130, 246, 0.1); color: rgba(59, 130, 246, 0.85); }
    .nba-source-cf .nba-rank { background: rgba(245, 158, 11, 0.1); color: rgba(245, 158, 11, 0.85); }
    .nba-source-bookmark .nba-rank { background: rgba(168, 85, 247, 0.1); color: rgba(168, 85, 247, 0.85); }
    .nba-source-untouched .nba-rank { background: rgba(20, 184, 166, 0.1); color: rgba(20, 184, 166, 0.85); }
    .factflash-today-card { position: relative; overflow: hidden; }
    .factflash-today-hero { font-size: 0.875rem; color: var(--text-secondary); margin: 0 0 12px; line-height: 1.45; }
    .factflash-today-stack { min-height: 180px; }
    .factflash-today-face { padding: 20px; border-radius: var(--radius-sm); background: linear-gradient(135deg, rgba(245, 158, 11, 0.08) 0%, rgba(245, 158, 11, 0.02) 100%); border: 1px solid rgba(245, 158, 11, 0.18); display: flex; flex-direction: column; gap: 10px; }
    .factflash-today-crumb { font-size: 0.75rem; font-weight: 600; color: rgba(245, 158, 11, 0.95); text-transform: uppercase; letter-spacing: 0.04em; margin: 0; }
    .factflash-today-question { font-size: 1.0625rem; font-weight: 600; color: var(--text); margin: 0; line-height: 1.4; }
    .factflash-today-question p { font-size: inherit; font-weight: inherit; color: inherit; line-height: inherit; }
    .factflash-today-hint { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; font-style: italic; }
    .factflash-today-hint p { font-size: inherit; color: inherit; font-style: inherit; }
    .factflash-today-reveal { align-self: flex-start; margin-top: 4px; padding: 10px 18px; border-radius: var(--radius-sm); border: 1px solid rgba(245, 158, 11, 0.35); background: transparent; color: rgba(245, 158, 11, 0.95); font-size: 0.875rem; font-weight: 600; font-family: inherit; cursor: pointer; transition: background 0.15s, border-color 0.15s; }
    .factflash-today-reveal:hover { background: rgba(245, 158, 11, 0.08); border-color: rgba(245, 158, 11, 0.55); }
    .factflash-today-answer { padding: 14px 16px; border-radius: var(--radius-sm); background: var(--bg); border: 1px solid var(--border); margin-top: 4px; }
    .factflash-today-answer-text { font-size: 0.9375rem; color: var(--text); line-height: 1.5; }
    .factflash-today-answer-text p { font-size: inherit; color: inherit; line-height: inherit; margin: 0.45em 0; }
    .factflash-today-answer-text > p:first-child { margin-top: 0; }
    .factflash-today-answer-text > p:last-child { margin-bottom: 0; }
    .factflash-today-answer-text ul, .factflash-today-answer-text ol { margin: 0.4em 0; padding-left: 1.4em; }
    .factflash-today-context { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 8px; }
    .factflash-today-context p { font-size: inherit; color: inherit; line-height: 1.45; margin: 0.35em 0; }
    .factflash-today-context > p:first-child { margin-top: 0; }
    .factflash-today-context > p:last-child { margin-bottom: 0; }
    .factflash-today-grade { display: flex; gap: 10px; margin-top: 8px; }
    .factflash-today-btn { flex: 1; padding: 12px 18px; border-radius: var(--radius-sm); border: 1px solid var(--border); font-size: 0.9375rem; font-weight: 600; font-family: inherit; cursor: pointer; transition: background 0.15s, border-color 0.15s, transform 0.15s; background: var(--bg); color: var(--text); }
    .factflash-today-btn:hover { transform: translateY(-1px); }
    .factflash-today-btn:disabled { opacity: 0.5; cursor: default; transform: none; }
    .factflash-today-btn-forgot { border-color: rgba(239, 68, 68, 0.35); color: rgba(239, 68, 68, 0.95); }
    .factflash-today-btn-forgot:hover { background: rgba(239, 68, 68, 0.08); border-color: rgba(239, 68, 68, 0.55); }
    .factflash-today-btn-remember { border-color: rgba(16, 185, 129, 0.35); color: rgba(16, 185, 129, 0.95); }
    .factflash-today-btn-remember:hover { background: rgba(16, 185, 129, 0.08); border-color: rgba(16, 185, 129, 0.55); }
    .factflash-today-counter { font-size: 0.75rem; color: var(--text-secondary); text-align: center; margin: 12px 0 0; }
    .factflash-today-empty { padding: 24px; text-align: center; color: var(--text-secondary); border-radius: var(--radius-sm); background: rgba(16, 185, 129, 0.06); border: 1px dashed rgba(16, 185, 129, 0.25); }
    .factflash-today-empty-icon { display: inline-block; width: 36px; height: 36px; line-height: 36px; border-radius: 50%; background: rgba(16, 185, 129, 0.15); color: rgba(16, 185, 129, 0.95); font-size: 1.25rem; font-weight: 700; margin-bottom: 8px; }
    .factflash-today-empty p { margin: 0; font-size: 0.9375rem; }
    .recommended-catalog-item {
      display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border);
      font-size: 0.9375rem; color: var(--text-secondary);
    }
    .recommended-catalog-item:last-child { border-bottom: none; }
    .recommended-catalog-item .recommended-catalog-name { font-weight: 600; color: var(--text); }
    .recommended-premium { margin-bottom: 20px; padding: 16px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); transition: border-color 0.2s, box-shadow 0.2s; }
    .recommended-premium:hover { border-color: var(--accent); box-shadow: 0 2px 12px rgba(13, 148, 136, 0.10); }
    .recommended-premium:last-child { margin-bottom: 0; }
    .recommended-premium-title { font-size: 1.0625rem; font-weight: 700; margin: 0 0 6px; color: var(--text); }
    .recommended-premium-benefit { font-size: 0.9375rem; margin: 0 0 4px; color: var(--text); }
    .recommended-premium-point { font-size: 0.8125rem; color: var(--text-secondary); margin: 0 0 12px; }
    .recommended-premium-cta { display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px; border: none; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 600; font-family: inherit; cursor: pointer; background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%); color: #fff; transition: transform 0.15s var(--ease), box-shadow 0.2s var(--ease); }
    .recommended-premium-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35); }
    .recommended-premium-cta:active { transform: translateY(0); }
    body.pussy-power-mode .recommended-premium:hover { border-color: var(--accent); box-shadow: 0 2px 12px rgba(190, 24, 93, 0.12); }
    body.pussy-power-mode .recommended-premium-cta { box-shadow: 0 2px 8px rgba(190, 24, 93, 0.3); }
    body.pussy-power-mode .recommended-premium-cta:hover { box-shadow: 0 4px 14px rgba(190, 24, 93, 0.4); }
    .recommended-asen-quote { font-size: 0.875rem; font-style: italic; color: var(--text-secondary); margin: 16px 0 0; padding: 12px 14px; background: var(--bg); border-radius: var(--radius-sm); border-left: 3px solid var(--border); }
    .recommended-footer-note { font-size: 0.75rem; color: var(--text-secondary); margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--border); }

    /* --- Recommended (Asen) — анимации + badge + skeleton ---------------- */
    .recommended-premium-badge {
      display: inline-flex; align-items: center; gap: 6px;
      margin: 4px 0 12px; padding: 4px 10px;
      background: var(--accent-soft); color: var(--accent);
      border-radius: 999px;
      font-size: 0.75rem; font-weight: 600; line-height: 1.2;
      max-width: 100%;
    }
    .recommended-premium-badge-dot {
      width: 6px; height: 6px; border-radius: 50%;
      background: var(--accent);
      box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.55);
    }
    .recommended-premium-badge-num { font-variant-numeric: tabular-nums; font-weight: 700; }
    .recommended-premium-badge-label { color: var(--accent); opacity: 0.95; font-weight: 500; }
    /* Курсовой бейдж — нейтральнее term-overlap: курс это «дальше по программе»,
       а не «уже близко тебе», поэтому без акцентного цвета и без пульса. */
    .recommended-premium-badge--course { background: rgba(100, 116, 139, 0.12); color: var(--text-secondary); }
    .recommended-premium-badge--course .recommended-premium-badge-dot { background: var(--text-secondary); box-shadow: none; }
    .recommended-premium-badge--course .recommended-premium-badge-label { color: var(--text-secondary); }
    body.pussy-power-mode .recommended-premium-badge { background: rgba(190, 24, 93, 0.10); color: var(--accent); }
    body.pussy-power-mode .recommended-premium-badge-dot { background: var(--accent); box-shadow: 0 0 0 0 rgba(190, 24, 93, 0.55); }

    .recommended-skeleton-card { position: relative; overflow: hidden; }
    .recommended-skeleton-title,
    .recommended-skeleton-sub,
    .recommended-skeleton-line {
      position: relative; overflow: hidden;
      background: var(--bg); border-radius: 8px;
    }
    .recommended-skeleton-title { height: 22px; width: 78%; margin: 0 0 8px; }
    .recommended-skeleton-sub { height: 14px; width: 52%; margin: 0 0 18px; }
    .recommended-skeleton-item {
      margin-bottom: 16px; padding: 16px;
      border-radius: var(--radius-sm);
      background: var(--surface); border: 1px solid var(--border);
    }
    .recommended-skeleton-item:last-child { margin-bottom: 0; }
    .recommended-skeleton-line--title { height: 18px; width: 42%; margin: 0 0 10px; }
    .recommended-skeleton-line--text { height: 14px; width: 86%; margin: 0 0 14px; }
    .recommended-skeleton-line--cta { height: 36px; width: 124px; border-radius: var(--radius-sm); }

    @media (prefers-reduced-motion: no-preference) {
      @keyframes rec-card-enter {
        from { opacity: 0; transform: translateY(12px); }
        to   { opacity: 1; transform: translateY(0); }
      }
      .recommended-premium-enter {
        animation: rec-card-enter 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
        animation-delay: calc(var(--stagger-idx, 0) * 80ms);
        will-change: opacity, transform;
      }
      @keyframes rec-badge-pop {
        0%   { opacity: 0; transform: scale(0.85); }
        60%  { opacity: 1; transform: scale(1.06); }
        100% { opacity: 1; transform: scale(1); }
      }
      .recommended-premium-badge {
        animation: rec-badge-pop 0.38s cubic-bezier(0.22, 1, 0.36, 1) both;
        animation-delay: calc(var(--stagger-idx, 0) * 80ms + 220ms);
      }
      @keyframes rec-badge-pulse {
        0%, 100% { box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.55); }
        50%      { box-shadow: 0 0 0 6px rgba(13, 148, 136, 0); }
      }
      .recommended-premium-badge-dot { animation: rec-badge-pulse 2.4s ease-out infinite; animation-delay: 800ms; }
      body.pussy-power-mode .recommended-premium-badge-dot {
        animation-name: rec-badge-pulse-pink;
      }
      @keyframes rec-badge-pulse-pink {
        0%, 100% { box-shadow: 0 0 0 0 rgba(190, 24, 93, 0.55); }
        50%      { box-shadow: 0 0 0 6px rgba(190, 24, 93, 0); }
      }
      @keyframes rec-quote-reveal {
        from { opacity: 0; transform: translateY(6px); filter: blur(2px); }
        to   { opacity: 1; transform: translateY(0);   filter: blur(0); }
      }
      .recommended-asen-quote-fresh {
        animation: rec-quote-reveal 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
        animation-delay: 380ms;
      }
      @keyframes rec-shimmer {
        0%   { transform: translateX(-100%); }
        100% { transform: translateX(100%); }
      }
      .recommended-skeleton-title::after,
      .recommended-skeleton-sub::after,
      .recommended-skeleton-line::after {
        content: ""; position: absolute; inset: 0;
        background: linear-gradient(90deg,
          transparent 0%,
          rgba(255, 255, 255, 0.55) 50%,
          transparent 100%);
        animation: rec-shimmer 1.4s linear infinite;
      }
      .recommended-skeleton-item { animation: rec-card-enter 0.45s cubic-bezier(0.22, 1, 0.36, 1) both; animation-delay: calc(var(--stagger-idx, 0) * 80ms); }
      .recommended-premium { transition: border-color 0.2s var(--ease), box-shadow 0.25s var(--ease), transform 0.18s var(--ease); }
      .recommended-premium:hover { transform: translateY(-2px); }
    }
    @media (prefers-reduced-motion: reduce) {
      .recommended-premium-enter,
      .recommended-premium-badge,
      .recommended-premium-badge-dot,
      .recommended-asen-quote-fresh,
      .recommended-skeleton-item,
      .recommended-skeleton-title::after,
      .recommended-skeleton-sub::after,
      .recommended-skeleton-line::after { animation: none !important; opacity: 1 !important; transform: none !important; filter: none !important; }
    }

    @keyframes progress-complete {
      0% { transform: scale(1); }
      30% { transform: scale(1.18); }
      60% { transform: scale(1.08); }
      100% { transform: scale(1); }
    }
    :root {
      --circle-track: rgba(0,0,0,0.06);
      --practice-color: #c2410c;
      --clinical-color: #6d28d9;
      --circle-circumference: 119.38;
    }
    .progress-bar-wrap { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; margin-top: 6px; }
    .progress-bar-fill { height: 100%; background: var(--accent); border-radius: 4px; width: 0; transition: width 1.1s cubic-bezier(0.33, 1, 0.68, 1); }
    .progress-cta { margin-top: 16px; }
    .help-block { margin-top: 24px; padding: 16px 0; border-top: 1px solid var(--border); }
    .help-text { margin: 0; font-size: 0.9375rem; color: var(--text-secondary); }
    .section-label { font-size: 0.75rem; color: var(--text-secondary); margin-bottom: 4px; }
    /* Полоса прогресса всего трека (сверху блока плана) */
    .plan-track-progress { margin-bottom: 18px; padding-bottom: 16px; border-bottom: 1px solid var(--border); }
    .plan-track-progress-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 8px; }
    .plan-track-progress-bar-wrap { height: 10px; background: var(--border); border-radius: 5px; overflow: hidden; margin-bottom: 8px; }
    .plan-track-progress-bar-fill { height: 100%; background: var(--accent); border-radius: 5px; transition: width 0.5s ease; }
    .plan-track-progress-stats { font-size: 0.9375rem; font-weight: 600; color: var(--text-secondary); }
    .plan-track-progress-stats .plan-track-percent { color: var(--text); }
    .plan-sub-end-line { font-size: 0.8125rem; color: var(--text-secondary); margin-top: 6px; }
    /* Завершённые планы — Мои достижения */
    .plan-completed-block { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--border); }
    .plan-completed-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 12px; }
    .plan-completed-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
    .plan-completed-card { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--radius-sm); background: rgba(22, 163, 74, 0.08); border: 1px solid rgba(22, 163, 74, 0.2); font-size: 0.9375rem; }
    .plan-completed-name { font-weight: 600; color: var(--text); }
    .plan-completed-badge { color: #16a34a; font-weight: 600; }
    .plan-completed-date { color: var(--text-secondary); font-size: 0.8125rem; }
    .plan-completed-cta { margin-top: 4px; }
    /* Тосты микродостижений */
    .plan-micro-toast-container { position: fixed; top: 16px; right: 16px; z-index: 10000; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
    .plan-micro-toast { padding: 12px 18px; border-radius: var(--radius-sm); background: var(--surface); border: 1px solid var(--border); box-shadow: 0 4px 12px rgba(0,0,0,0.15); font-size: 0.9375rem; font-weight: 600; color: var(--text); animation: plan-micro-toast-in 0.25s ease; pointer-events: auto; }
    @keyframes plan-micro-toast-in { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
    /* План: Сегодня — карточка в стиле 21st.dev to-do card */
    .plan-card .plan-today-section { margin: 18px 0; border-radius: 14px; overflow: hidden; border: 1px solid rgba(0,0,0,0.06); background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,0.04); transition: box-shadow 0.3s var(--ease); }
    .plan-card .plan-today-section-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; background: linear-gradient(180deg, #fde047, #fef08a); border-bottom: 1px solid rgba(0,0,0,0.06); }
    .plan-card .plan-today-section.all-done .plan-today-section-header { background: linear-gradient(180deg, #34d399, #6ee7b7); }
    .plan-card .plan-today-heading { margin: 0; font-size: 0.9375rem; font-weight: 600; color: #111827; letter-spacing: 0; text-transform: none; }
    .plan-card .plan-today-count { font-size: 0.75rem; font-weight: 500; color: #1f2937; background: rgba(0,0,0,0.1); padding: 3px 8px; border-radius: 6px; white-space: nowrap; }
    .plan-card .plan-today-body { padding: 14px 14px 12px; background-color: #fff; background-image: radial-gradient(rgba(0,0,0,0.06) 1px, transparent 1px); background-size: 10px 10px; }
    .plan-card .plan-today-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
    .plan-card .plan-today-item { display: flex; align-items: flex-start; gap: 12px; padding: 6px 8px; border-radius: 8px; transition: background 0.2s var(--ease); }
    .plan-card .plan-today-check { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 6px; border: 1px solid #d1d5db; background: #fff; margin-top: 1px; transition: transform 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease); }
    .plan-card .plan-today-check svg { width: 12px; height: 9px; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; fill: none; opacity: 0; transition: opacity 0.2s var(--ease); }
    .plan-card .plan-today-check.plan-today-check-link { cursor: pointer; }
    .plan-card .plan-today-check.plan-today-check-link:hover { border-color: var(--accent); background: rgba(190, 24, 93, 0.08); transform: scale(1.08); }
    .plan-card .plan-today-item.plan-item-done .plan-today-check.plan-today-check-link:hover { background: #111827; border-color: var(--accent); }
    .plan-card .plan-today-check.plan-today-check-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .plan-card .plan-today-item.plan-item-done { background: #f1f5f9; }
    .plan-card .plan-today-item.plan-item-done .plan-today-check { background: #111827; border-color: #111827; transform: scale(0.95); }
    .plan-card .plan-today-item.plan-item-done .plan-today-check svg { opacity: 1; }
    .plan-card .plan-today-item.plan-item-done .plan-today-text { font-weight: 600; color: #111827; transform: translateX(2px); }
    .plan-card .plan-today-item.plan-item-done .plan-today-text a { color: #111827; text-decoration: none; }
    .plan-card .plan-today-item.plan-item-done .plan-today-text a:hover { color: var(--accent); }
    .plan-card .plan-today-text { font-size: 0.9375rem; color: var(--text); line-height: 1.4; flex: 1; min-width: 0; transition: transform 0.2s var(--ease); }
    .plan-card .plan-today-text-strike { background-image: linear-gradient(currentColor, currentColor); background-repeat: no-repeat; background-position: 0 calc(50% + 1px); background-size: 100% 1.6px; }
    .plan-card .plan-today-item.plan-item-just-completed .plan-today-text-strike { animation: plan-strike-bg 0.55s cubic-bezier(0.65, 0, 0.35, 1) 0.08s both; }
    .plan-card .plan-today-item.plan-item-just-completed .plan-today-check { animation: plan-check-pop 0.45s cubic-bezier(0.34, 1.56, 0.64, 1) both; }
    .plan-card .plan-today-item.plan-item-just-completed { animation: plan-row-flash 0.7s ease-out both; }
    @keyframes plan-strike-bg { from { background-size: 0% 1.6px; } to { background-size: 100% 1.6px; } }
    @keyframes plan-check-pop { 0% { transform: scale(1); } 45% { transform: scale(1.28); } 100% { transform: scale(0.95); } }
    @keyframes plan-row-flash { 0% { background: rgba(34, 197, 94, 0.18); } 100% { background: #f1f5f9; } }
    @media (prefers-reduced-motion: reduce) {
      .plan-card .plan-today-item.plan-item-just-completed .plan-today-text-strike,
      .plan-card .plan-today-item.plan-item-just-completed .plan-today-check,
      .plan-card .plan-today-item.plan-item-just-completed { animation: none !important; }
    }
    /* Текущий урок внутри списка — эмодзи, тайтл, мета, кнопка */
    .plan-card .plan-today-item.plan-item-current { flex-direction: column; padding: 10px 8px 12px; gap: 8px; }
    .plan-card .plan-today-item.plan-item-current .plan-current-wrap { margin: 0; padding: 0; border: none; display: flex; flex-direction: column; gap: 6px; width: 100%; }
    .plan-card .plan-today-item.plan-item-current .plan-current-head { display: flex; align-items: center; gap: 10px; }
    .plan-card .plan-today-item.plan-item-current .plan-current-emoji { font-size: 1.1rem; line-height: 1; flex-shrink: 0; }
    .plan-card .plan-today-item.plan-item-current .plan-current-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0; flex: 1; min-width: 0; overflow-wrap: anywhere; }
    .plan-card .plan-today-item.plan-item-current .plan-current-title-link { color: var(--text); text-decoration: none; cursor: pointer; }
    .plan-card .plan-today-item.plan-item-current .plan-current-title-link:hover { color: var(--accent); text-decoration: underline; }
    .plan-card .plan-today-item.plan-item-current .plan-current-meta { font-size: 0.8125rem; color: var(--text-secondary); margin: 0 0 0 30px; }
    .plan-card .plan-today-item.plan-item-current .plan-continue-btn { align-self: flex-start; margin-left: 30px; }
    /* «Далее» — приглушённая строка со следующим уроком */
    .plan-card .plan-today-item.plan-item-next { opacity: 0.78; padding: 6px 8px; }
    .plan-card .plan-today-item.plan-item-next .plan-today-next-label { display: inline-block; font-size: 0.6875rem; font-weight: 600; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; margin-right: 6px; }
    .plan-card .plan-today-item.plan-item-next a { color: var(--text); font-weight: 500; text-decoration: none; }
    .plan-card .plan-today-item.plan-item-next a:hover { color: var(--accent); text-decoration: underline; }
    /* Кнопка «Продолжить» — внутри plan-item-current и блоков-рекомендаций */
    .plan-card .plan-continue-btn { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 600; background: var(--accent); color: #fff; text-decoration: none; border: none; cursor: pointer; transition: background 0.2s var(--ease); }
    .plan-card .plan-continue-btn:hover { background: var(--accent-hover); color: #fff; }
    .plan-card .plan-reminder-inline { margin: 0 0 14px; padding: 12px 14px; border-radius: var(--radius-sm); background: linear-gradient(135deg, rgba(13, 148, 136, 0.08), rgba(13, 148, 136, 0.03)); border: 1px solid rgba(13, 148, 136, 0.2); }
    /* «Напоминания» переехали в самый низ панели — отбиваем сверху, снизу хватает паддинга карточки. */
    .plan-card .plan-reminder-inline-bottom { margin: 18px 0 0; }
    .plan-card .plan-reminder-inline-title { margin: 0 0 8px; font-size: 0.8125rem; font-weight: 700; color: var(--text); text-transform: uppercase; letter-spacing: 0.02em; }
    .plan-card .plan-reminder-inline .plan-reminder-intensity { width: 100%; max-width: 320px; accent-color: var(--accent); }
    .plan-card .plan-reminder-inline .plan-reminder-labels { display: flex; justify-content: space-between; max-width: 320px; margin-top: 6px; font-size: 0.8rem; color: var(--text-secondary); }
    .plan-card .plan-reminder-inline .plan-reminder-current { margin: 8px 0 0; font-size: 0.875rem; color: var(--text-secondary); }
    .plan-card .plan-progress-wrap { background: linear-gradient(135deg, rgba(22, 163, 74, 0.08), rgba(22, 163, 74, 0.04)); border-radius: var(--radius-sm); padding: 14px 16px; margin-bottom: 12px; font-size: 0.875rem; border: 1px solid rgba(22, 163, 74, 0.15); }
    .plan-card .plan-progress-steps { font-weight: 700; color: var(--text); margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
    .plan-card .plan-progress-steps::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: #16a34a; flex-shrink: 0; box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.3); }
    .plan-card .plan-progress-time { color: var(--text-secondary); margin-bottom: 2px; }
    .plan-card .plan-progress-finish { color: var(--text-secondary); font-size: 0.8125rem; }
    .plan-card .plan-expand-row { display: flex; align-items: center; gap: 8px; width: 100%; }
    .plan-card .plan-expand-btn { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; padding: 10px 0; border: none; background: none; font-size: 0.875rem; color: var(--accent); font-weight: 600; cursor: pointer; font-family: inherit; text-align: left; }
    .plan-card .plan-expand-btn:hover { color: var(--accent-hover); }
    .plan-card .plan-expand-btn .plan-expand-icon { transition: transform 0.2s var(--ease); }
    .plan-card .plan-expand-btn.expanded .plan-expand-icon { transform: rotate(90deg); }
    .plan-card .plan-full-list { display: none; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
    .plan-card .plan-full-list.visible { display: block; }
    .plan-card.plan-card-typing-pending .plan-today-section,
    .plan-card.plan-card-typing-pending .plan-progress-wrap { opacity: 0; }
    .plan-card .plan-typing-cursor { display: inline; animation: plan-typing-blink 0.7s step-end infinite; }
    @keyframes plan-typing-blink { 50% { opacity: 0; } }
    .plan-card .plan-full-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; margin-bottom: 6px; border-radius: var(--radius-sm); font-size: 0.9375rem; background: var(--bg); border: 1px solid transparent; transition: background 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease); }
    .plan-card .plan-full-item:last-child { margin-bottom: 0; }
    .plan-card .plan-full-item:hover { background: var(--surface); }
    .plan-card .plan-full-item.plan-item-done { background: rgba(22, 163, 74, 0.06); color: var(--text-secondary); }
    .plan-card .plan-full-item.plan-item-done:hover { background: rgba(22, 163, 74, 0.1); }
    .plan-card .plan-full-item.plan-item-done .plan-step-done { background: #16a34a; color: #fff; }
    .plan-card .plan-full-item .plan-item-reset-btn { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; padding: 0; border: none; border-radius: var(--radius-sm); background: transparent; color: var(--text-secondary); font-size: 1rem; line-height: 1; cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease); }
    .plan-card .plan-full-item .plan-item-reset-btn:hover { background: var(--accent-soft); color: var(--accent); }
    .plan-card .plan-full-item .plan-step-indicator { flex-shrink: 0; width: 22px; height: 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 0.75rem; font-weight: 700; }
    .plan-card .plan-full-item .plan-step-num { background: var(--border); color: var(--text-secondary); }
    .plan-card .plan-full-item:not(.plan-item-done):hover .plan-step-num { background: var(--accent); color: #fff; }
    .plan-card .plan-full-item .plan-drag { color: var(--text-secondary); cursor: grab; flex-shrink: 0; font-size: 0.875rem; opacity: 0.7; }
    .plan-card .plan-full-item .plan-drag:active { cursor: grabbing; }
    .plan-card .plan-full-item.plan-item-dragging { opacity: 0.6; }
    .plan-card .plan-full-item.plan-item-drag-over { box-shadow: inset 0 2px 0 0 var(--accent); }
    .plan-card .plan-full-item .plan-item-remove-btn { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; padding: 0; border: none; border-radius: var(--radius-sm); background: transparent; color: var(--text-secondary); font-size: 1.125rem; line-height: 1; cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease); }
    .plan-card .plan-full-item .plan-item-remove-btn:hover { background: rgba(220, 38, 38, 0.1); color: #dc2626; }
    .plan-card .plan-full-item .plan-item-markdone-btn,
    .plan-card .plan-full-item .plan-item-unmark-btn { flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; padding: 0; border: none; border-radius: var(--radius-sm); background: transparent; color: var(--text-secondary); font-size: 1rem; line-height: 1; cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease); }
    .plan-card .plan-full-item .plan-item-markdone-btn:hover { background: var(--accent-soft); color: var(--accent); }
    .plan-card .plan-full-item .plan-item-markdone-btn:disabled,
    .plan-card .plan-full-item .plan-item-unmark-btn:disabled { opacity: 0.5; cursor: default; }
    .plan-card .plan-today-item.plan-item-current .plan-mark-done-btn { align-self: flex-start; margin-left: 30px; margin-top: 6px; display: inline-flex; align-items: center; gap: 6px; padding: 9px 16px; border-radius: var(--radius-sm); font-size: 0.8125rem; font-weight: 600; background: var(--accent-soft); color: var(--accent); border: 1px solid var(--accent); cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease); }
    .plan-card .plan-today-item.plan-item-current .plan-mark-done-btn:hover { background: var(--accent); color: #fff; }
    .plan-card .plan-today-item.plan-item-current .plan-mark-done-btn:disabled { opacity: 0.6; cursor: default; }
    .plan-video-modal-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,0.66); display: flex; align-items: center; justify-content: center; padding: 16px; animation: planVideoFade 0.15s var(--ease); }
    @keyframes planVideoFade { from { opacity: 0; } to { opacity: 1; } }
    .plan-video-modal { width: 100%; max-width: 860px; background: var(--surface, #fff); border-radius: var(--radius-md, 14px); overflow: hidden; box-shadow: 0 24px 64px rgba(0,0,0,0.4); display: flex; flex-direction: column; }
    .plan-video-modal-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--border); }
    .plan-video-modal-title { flex: 1; min-width: 0; font-weight: 600; font-size: 0.95rem; color: var(--text-primary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .plan-video-modal-close { flex-shrink: 0; width: 32px; height: 32px; border: none; background: transparent; color: var(--text-secondary); font-size: 1.5rem; line-height: 1; cursor: pointer; border-radius: var(--radius-sm); transition: background 0.2s var(--ease); }
    .plan-video-modal-close:hover { background: var(--accent-soft); color: var(--text-primary); }
    .plan-video-modal-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; }
    .plan-video-modal-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
    .plan-video-modal-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; flex-wrap: wrap; }
    .plan-video-modal-ext { font-size: 0.8125rem; color: var(--text-secondary); text-decoration: none; }
    .plan-video-modal-ext:hover { color: var(--accent); text-decoration: underline; }
    .plan-video-modal-done { display: inline-flex; align-items: center; gap: 6px; padding: 10px 18px; border-radius: var(--radius-sm); font-size: 0.875rem; font-weight: 600; background: var(--accent); color: #fff; border: none; cursor: pointer; transition: background 0.2s var(--ease); }
    .plan-video-modal-done:hover { background: var(--accent-hover); }
    .plan-video-modal-done:disabled { opacity: 0.6; cursor: default; }
    /* Рейтинг урока после отметки «просмотрено» */
    .plan-rate { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; width: 100%; }
    .plan-rate-q { font-size: 0.875rem; color: var(--text-secondary); margin-right: auto; }
    .plan-rate-btn { font-size: 1.25rem; line-height: 1; padding: 8px 14px; border-radius: var(--radius-sm); background: var(--surface-2, #f2f2f7); border: 1px solid var(--border, rgba(60,60,67,0.14)); cursor: pointer; transition: transform 0.12s var(--ease), background 0.2s var(--ease); }
    .plan-rate-btn:hover { transform: translateY(-1px); background: var(--surface-3, #e9e9ef); }
    .plan-rate-up:hover { background: rgba(52,199,89,0.16); }
    .plan-rate-down:hover { background: rgba(255,59,48,0.14); }
    .plan-rate-skip { font-size: 0.8125rem; color: var(--text-secondary); background: none; border: none; cursor: pointer; }
    .plan-rate-skip:hover { color: var(--accent); text-decoration: underline; }
    .plan-rate-reasons { gap: 7px; }
    .plan-rate-chip { font-size: 0.8125rem; padding: 6px 12px; border-radius: 999px; background: var(--surface-2, #f2f2f7); border: 1px solid var(--border, rgba(60,60,67,0.18)); color: var(--text-primary, #1c1c1e); cursor: pointer; transition: background 0.15s var(--ease), border-color 0.15s var(--ease); }
    .plan-rate-chip:hover { border-color: var(--accent); color: var(--accent); }
    .plan-rate-chip-skip { color: var(--text-secondary); }
    .plan-card .plan-full-item .plan-item-link.plan-video-open::before { content: '▶ '; color: var(--accent); font-size: 0.7em; }
    .plan-card .plan-full-item .plan-item-title { flex: 1; min-width: 0; }
    .plan-card .plan-full-item .plan-item-title .plan-item-link { color: var(--text); font-weight: 500; text-decoration: none; }
    .plan-card .plan-full-item .plan-item-title .plan-item-link:hover { color: var(--accent); text-decoration: underline; }
    .plan-card .plan-full-item.plan-item-done .plan-item-title .plan-item-link { color: var(--text-secondary); }
    .plan-card .plan-full-item.plan-item-bonus { border-left: 3px solid rgba(217, 119, 6, 0.5); padding-left: 12px; }
    .plan-card .plan-full-item.plan-item-bonus .plan-item-title .plan-item-link { color: #b45309; }
    .plan-card .plan-full-item.plan-item-bonus.plan-item-done .plan-item-title .plan-item-link { color: var(--text-secondary); }
    .plan-card .plan-full-item .plan-item-deadline { font-size: 0.8125rem; color: var(--text-secondary); flex-shrink: 0; }
    .plan-card .plan-full-item .plan-edit-deadline { margin-left: 8px; font-size: 0.75rem; color: var(--accent); cursor: pointer; background: none; border: none; padding: 0; font-family: inherit; }
    .plan-card .plan-full-item .plan-edit-deadline:hover { text-decoration: underline; }
    .plan-card .plan-full-item .plan-item-deadline.plan-edit-deadline { margin-left: 0; font-size: 0.8125rem; color: var(--text-secondary); border-bottom: 1px dashed var(--border, rgba(0,0,0,0.25)); line-height: 1.2; }
    .plan-card .plan-full-item .plan-item-deadline.plan-edit-deadline:hover { text-decoration: none; color: var(--accent); border-bottom-color: var(--accent); }
    .plan-deadline-modal-card .plan-deadline-date-input { min-height: 44px; font-size: 1rem; cursor: pointer; }
    .plan-card .plan-full-group { margin-bottom: 14px; }
    .plan-card .plan-full-group:last-child { margin-bottom: 0; }
    .plan-card .plan-full-group-title { font-size: 0.6875rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 6px; padding-left: 2px; }
    .plan-card .plan-full-group-today .plan-full-group-title { color: var(--accent); }
    .plan-card .plan-full-group-today .plan-full-item { border-left: 3px solid var(--accent); padding-left: 10px; margin-left: -2px; }
    .plan-card .plan-full-group-tomorrow .plan-full-group-title { color: #0ea5e9; }
    .plan-card .plan-full-group-tomorrow .plan-full-item { border-left: 3px solid rgba(14, 165, 233, 0.5); padding-left: 10px; margin-left: -2px; }
    .plan-card .plan-full-group-week .plan-full-group-title { color: var(--text-secondary); }
    .plan-card .plan-full-group-week .plan-full-item { border-left: 3px solid var(--border); padding-left: 10px; margin-left: -2px; }
    .plan-card .plan-full-group-month .plan-full-group-title { color: var(--text-secondary); opacity: 0.9; }
    .plan-card .plan-full-group-month .plan-full-item { border-left: 3px solid transparent; padding-left: 10px; margin-left: -2px; }
    .plan-card .plan-full-group-later .plan-full-group-title { color: var(--text-secondary); opacity: 0.75; }
    .plan-card .plan-full-group-later .plan-full-item { opacity: 0.9; }
    .plan-card .plan-full-group-past .plan-full-group-title { color: var(--text-secondary); opacity: 0.8; }
    .plan-card .plan-full-group-past .plan-full-item { border-left: 3px solid rgba(128, 128, 128, 0.4); padding-left: 10px; margin-left: -2px; opacity: 0.95; }
    .plan-section { margin-bottom: 24px; }
    .plan-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 16px; padding: 14px 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
    .plan-toolbar .plan-toolbar-label { font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); margin: 0; white-space: nowrap; }
    .plan-toolbar .plan-toolbar-select-wrap { flex: 1; min-width: 0; max-width: 360px; }
    .plan-toolbar select.plan-toolbar-select { width: 100%; padding: 10px 36px 10px 14px; font-size: 0.9375rem; font-weight: 500; color: var(--text); background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }
    .plan-toolbar select.plan-toolbar-select:hover { border-color: var(--accent); }
    .plan-toolbar select.plan-toolbar-select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 2px var(--accent-soft); }
    .plan-toolbar .plan-toolbar-add { flex-shrink: 0; display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; font-size: 0.875rem; font-weight: 600; font-family: inherit; color: var(--accent); background: var(--surface); border: 2px solid var(--accent); border-radius: var(--radius-sm); cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease); white-space: nowrap; }
    .plan-toolbar .plan-toolbar-add:hover { background: var(--accent); color: #fff; }
    .plan-toolbar .plan-toolbar-add:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--accent-soft); }
    .plan-toolbar .plan-toolbar-add svg { flex-shrink: 0; width: 18px; height: 18px; opacity: 0.9; }
    .plan-toolbar .plan-toolbar-more-wrap { position: relative; flex-shrink: 0; }
    .plan-toolbar .plan-toolbar-more-btn {
      display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; padding: 0 14px;
      font-size: 0.875rem; font-weight: 600; line-height: 1; font-family: inherit;
      color: var(--text-secondary); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
      cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
    }
    .plan-toolbar .plan-toolbar-more-btn svg { width: 18px; height: 18px; flex-shrink: 0; }
    .plan-toolbar .plan-toolbar-more-label { white-space: nowrap; }
    .plan-toolbar .plan-toolbar-more-btn:hover { color: var(--text); border-color: var(--accent); background: var(--bg); }
    .plan-toolbar .plan-toolbar-more-btn:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--accent-soft); }
    .plan-toolbar .plan-toolbar-more-btn[aria-expanded="true"] { border-color: var(--accent); color: var(--accent); }
    .plan-toolbar .plan-toolbar-dropdown {
      display: none; position: absolute; right: 0; top: calc(100% + 6px); z-index: 50; min-width: 240px;
      padding: 6px; margin: 0; list-style: none; background: var(--surface); border: 1px solid var(--border);
      border-radius: var(--radius-sm); box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    }
    .plan-toolbar .plan-toolbar-dropdown.is-open { display: block; }
    .plan-toolbar .plan-toolbar-menu-item {
      display: flex; align-items: center; gap: 10px; width: 100%; margin: 0; padding: 10px 12px;
      font-size: 0.875rem; font-weight: 500; font-family: inherit; text-align: left; color: var(--text);
      background: transparent; border: none; border-radius: var(--radius-sm); cursor: pointer;
      transition: background 0.15s var(--ease);
    }
    .plan-toolbar .plan-toolbar-menu-item:hover { background: var(--bg); }
    .plan-toolbar .plan-toolbar-menu-item:focus-visible { outline: none; box-shadow: inset 0 0 0 2px var(--accent-soft); }
    .plan-toolbar .plan-toolbar-menu-item:disabled { opacity: 0.55; cursor: not-allowed; }
    .plan-toolbar .plan-toolbar-menu-item-danger { color: #b91c1c; }
    .plan-toolbar .plan-toolbar-menu-item-danger:hover { background: rgba(220, 38, 38, 0.08); }
    .plan-toolbar .plan-toolbar-menu-icon { flex-shrink: 0; width: 20px; height: 20px; color: #0088cc; }
    .plan-toolbar .plan-toolbar-menu-item-danger .plan-toolbar-menu-icon { color: #dc2626; }
    .plan-toolbar .plan-toolbar-menu-x { width: 20px; flex-shrink: 0; text-align: center; font-weight: 700; }
    /* Прайм-CTA «Создать следующий план» — заметная, приятная кнопка-таблетка */
    .plan-create-next-bar { flex-direction: column; align-items: center; justify-content: center; gap: 10px; margin-top: 20px; margin-bottom: 20px; }
    .plan-create-next-bar .plan-toolbar-add {
      position: relative; flex: 0 0 auto; overflow: hidden;
      display: inline-flex; align-items: center; gap: 12px;
      padding: 15px 30px; font-size: 1rem; font-weight: 700; font-family: inherit; line-height: 1.1;
      color: #fff; background: linear-gradient(135deg, var(--accent) 0%, #2f9e80 52%, #1f8f93 100%); background-size: 170% 170%; background-position: 0% 50%;
      border: none; border-radius: 16px; cursor: pointer;
      box-shadow: 0 10px 24px -8px rgba(31,143,128,0.55), 0 2px 6px rgba(0,0,0,0.08);
      transition: transform 0.18s var(--ease), box-shadow 0.25s var(--ease), background-position 0.6s var(--ease);
    }
    /* блик пробегает на hover */
    .plan-create-next-bar .plan-toolbar-add::before {
      content: ''; position: absolute; top: 0; left: -70%; width: 45%; height: 100%;
      background: linear-gradient(100deg, transparent, rgba(255,255,255,0.38), transparent);
      transform: skewX(-18deg); transition: left 0.6s var(--ease); pointer-events: none;
    }
    .plan-create-next-bar .plan-toolbar-add:hover { transform: translateY(-2px); box-shadow: 0 16px 32px -10px rgba(31,143,128,0.6), 0 4px 12px rgba(0,0,0,0.1); background-position: 100% 50%; }
    .plan-create-next-bar .plan-toolbar-add:hover::before { left: 130%; }
    .plan-create-next-bar .plan-toolbar-add:active { transform: translateY(0); box-shadow: 0 6px 16px -8px rgba(31,143,128,0.5); }
    .plan-create-next-bar .plan-toolbar-add:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(255,255,255,0.7), 0 0 0 6px var(--accent); }
    .plan-create-next-bar .plan-toolbar-add .plan-toolbar-add-ico { flex-shrink: 0; width: 22px; height: 22px; opacity: 1; }
    /* лёгкое «дыхание» иконки, чтобы тянуло нажать */
    .plan-create-next-bar .plan-toolbar-add:hover .plan-toolbar-add-ico { animation: planAddPulse 1.1s var(--ease) infinite; }
    @keyframes planAddPulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.14) rotate(90deg); } }
    /* бейдж-напоминание: предметы без плана. Висит на углу ОБЁРТКИ, а не кнопки —
       у кнопки overflow:hidden (для блика), он бы срезал бейдж. */
    .plan-create-next-bar .plan-toolbar-add-wrap { position: relative; display: inline-flex; }
    .plan-add-badge {
      position: absolute; top: -9px; right: -9px; min-width: 24px; height: 24px; padding: 0 6px;
      display: inline-flex; align-items: center; justify-content: center;
      font-size: 0.8125rem; font-weight: 800; line-height: 1; color: #fff; background: #ef5350;
      border: 2.5px solid var(--surface, #fff); border-radius: 999px; box-sizing: border-box;
      box-shadow: 0 2px 6px rgba(239,83,80,0.5); z-index: 2;
      animation: planAddBadgePop 0.35s var(--ease) both, planAddBadgePulse 2s var(--ease) 0.6s infinite;
    }
    @keyframes planAddBadgePop { from { transform: scale(0); } to { transform: scale(1); } }
    @keyframes planAddBadgePulse { 0%,100% { box-shadow: 0 2px 6px rgba(239,83,80,0.5); } 50% { box-shadow: 0 2px 14px rgba(239,83,80,0.85); } }
    .plan-create-next-hint { display: block; text-align: center; font-size: 0.8125rem; color: var(--text-secondary); max-width: 420px; line-height: 1.5; }
    .plan-create-next-hint b { color: var(--text); font-weight: 700; overflow-wrap: anywhere; }
    .plan-create-next-hint-dot { display: inline-block; vertical-align: middle; width: 8px; height: 8px; margin-right: 7px; border-radius: 50%; background: #ef5350; box-shadow: 0 0 0 0 rgba(239,83,80,0.5); animation: planHintDot 2s var(--ease) infinite; }
    @keyframes planHintDot { 0% { box-shadow: 0 0 0 0 rgba(239,83,80,0.45); } 70% { box-shadow: 0 0 0 7px rgba(239,83,80,0); } 100% { box-shadow: 0 0 0 0 rgba(239,83,80,0); } }
    @media (prefers-reduced-motion: reduce) {
      .plan-create-next-bar .plan-toolbar-add:hover .plan-toolbar-add-ico,
      .plan-add-badge, .plan-create-next-hint-dot { animation: none; }
      .plan-create-next-bar .plan-toolbar-add::before { display: none; }
    }
    .plan-rest-in-dev { font-size: 0.8125rem; color: var(--text-secondary); margin: 0 0 14px; padding: 10px 14px; background: var(--surface-hover); border: 1px solid var(--border); border-radius: var(--radius-sm); }
    .plan-rest-in-dev-badge { background: rgba(217, 119, 6, 0.12); border-color: rgba(217, 119, 6, 0.35); color: var(--warning, #b45309); font-weight: 600; }
    /* ---------- Единый panel-контейнер плана ---------- */
    /* Тулбар, бейдж «в разработке» и карточка с прогрессом/календарём — секции
       одной карточки. Внутри panel'а каждая часть теряет собственный card-хром
       (фон/рамку/тень/скругление/отступы) и разделяется тонким бордером. */
    .plan-panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); margin-bottom: 20px; overflow: hidden; transition: box-shadow 0.25s var(--ease); }
    .plan-panel:hover { box-shadow: var(--shadow-card); }
    .plan-panel > .plan-toolbar { background: transparent; border: 0; border-bottom: 1px solid var(--border); border-radius: 0; box-shadow: none; margin: 0; padding: 12px 24px; flex-wrap: nowrap; gap: 10px; }
    /* Компактный header плана в одну строку: раздел слева, маленькое «⋯ Ещё» справа.
       Бьём по специфичности мобильные правила .plan-toolbar (full-width кнопка). */
    .plan-panel > .plan-toolbar .plan-toolbar-label { order: 0; flex: 1 1 auto; min-width: 0; width: auto; margin: 0; white-space: normal; overflow-wrap: anywhere; font-size: 0.9375rem; font-weight: 600; color: var(--text); }
    .plan-panel > .plan-toolbar .plan-toolbar-select-wrap { order: 0; flex: 1 1 auto; min-width: 0; max-width: 360px; }
    .plan-panel > .plan-toolbar .plan-toolbar-more-wrap { order: 5; flex: 0 0 auto; margin-left: auto; }
    /* Иконка-«⋯» вместо широкой кнопки «Ещё» — минимальный footprint, не теснит раздел. */
    .plan-panel > .plan-toolbar .plan-toolbar-more-btn { width: auto; min-height: 0; padding: 6px 8px; }
    .plan-panel > .plan-toolbar .plan-toolbar-more-label { display: none; }
    .plan-panel > .plan-toolbar .plan-toolbar-more-btn svg { width: 18px; height: 18px; }
    .plan-panel > .plan-rest-in-dev { margin: 0; border-radius: 0; border-left: 0; border-right: 0; border-top: 0; border-bottom: 1px solid var(--border); padding: 12px 24px; }
    .plan-panel > .plan-rest-in-dev-badge { border-bottom-color: rgba(217, 119, 6, 0.35); }
    .plan-panel > .card.plan-card { background: transparent; border: 0; border-radius: 0; box-shadow: none; margin: 0; }
    .plan-panel > .card.plan-card:hover { box-shadow: none; }
    @media (max-width: 520px) {
      .plan-toolbar .plan-toolbar-select-wrap { min-width: 100%; flex: 1 1 100%; max-width: none; }
      .plan-toolbar .plan-toolbar-label { display: block; width: 100%; margin-bottom: 4px; }
      .plan-toolbar .plan-toolbar-more-wrap { flex: 1 1 100%; }
      .plan-toolbar .plan-toolbar-more-btn { width: 100%; justify-content: center; }
      .plan-toolbar .plan-toolbar-add { flex: 1 1 100%; justify-content: center; }
      .plan-toolbar .plan-toolbar-dropdown { right: auto; left: 0; width: 100%; min-width: 0; }
    }
    /* === Чипы-вкладки предметов (мультипредметный план) === */
    .plan-subj-chips { display: flex; align-items: center; gap: 8px; padding: 12px 24px 0; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
    .plan-subj-chips::-webkit-scrollbar { display: none; }
    .plan-subj-chip { display: inline-flex; align-items: center; gap: 7px; flex: 0 0 auto; padding: 7px 14px; font-size: 0.875rem; font-weight: 600; font-family: inherit; color: var(--text-secondary); background: var(--bg); border: 1px solid var(--border); border-radius: 999px; cursor: pointer; white-space: nowrap; transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease); }
    .plan-subj-chip:hover { border-color: var(--accent); color: var(--text); }
    .plan-subj-chip.is-active { background: var(--accent); border-color: var(--accent); color: #fff; }
    .plan-subj-chip.is-active .plan-subj-chip-badge { background: rgba(255,255,255,0.25); color: #fff; }
    .plan-subj-chip.is-completed { opacity: 0.6; }
    .plan-subj-chip:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--accent-soft); }
    .plan-subj-chip-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 19px; height: 19px; padding: 0 5px; font-size: 0.6875rem; font-weight: 700; color: #fff; background: var(--accent); border-radius: 999px; }
    .plan-subj-chip-done { font-size: 0.75rem; color: var(--success, #10b981); }
    /* Тулбар без содержимого (режим «Все»: нет ни label, ни «Ещё») не оставляет пустую полосу */
    .plan-panel > .plan-toolbar:empty { display: none; }
    /* Папки по предметам в блоке «Сегодня» (режим «Все») */
    .plan-card .plan-today-subj-head { display: flex; align-items: center; gap: 8px; padding: 10px 8px 2px; font-size: 0.8125rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.03em; }
    .plan-card .plan-today-subj-head:first-child { padding-top: 2px; }
    .plan-card .plan-today-subj-name { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
    .plan-card .plan-today-subj-count { flex: 0 0 auto; font-weight: 600; font-size: 0.75rem; color: var(--text-secondary); opacity: 0.8; }
    .plan-card .plan-today-subj-empty { padding: 2px 8px 6px 28px; font-size: 0.8125rem; color: var(--text-secondary); opacity: 0.75; list-style: none; }
    /* Точка предмета в полном списке (режим «Все») */
    .plan-full-subj-dot { margin-top: 7px; }
    /* === План: блок создания — hero create-flow polish === */
    .plan-empty-card { position: relative; overflow: hidden; }
    .plan-empty-card::before {
      content: ''; position: absolute; top: -180px; right: -160px;
      width: 460px; height: 460px;
      background: radial-gradient(circle, var(--accent-soft) 0%, transparent 65%);
      pointer-events: none; opacity: 0.85; z-index: 0;
    }
    .plan-empty-card::after {
      content: ''; position: absolute; bottom: -200px; left: -140px;
      width: 380px; height: 380px;
      background: radial-gradient(circle, rgba(190, 24, 93, 0.06) 0%, transparent 70%);
      pointer-events: none; z-index: 0;
    }
    .plan-empty-card > * { position: relative; z-index: 1; }
    .plan-empty-card .plan-empty-title { font-size: 1.375rem; font-weight: 700; letter-spacing: -0.015em; color: var(--text); margin: 2px 0 8px; line-height: 1.2; }
    .plan-empty-card .plan-empty-desc { font-size: 0.9375rem; color: var(--text-secondary); margin-bottom: 22px; line-height: 1.55; max-width: 64ch; }
    .plan-empty-card .plan-create-form { display: flex; flex-direction: column; gap: 20px; }
    .plan-empty-card .plan-create-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
    .plan-empty-card .plan-create-row.plan-create-row-subjects { align-items: flex-start; }
    .plan-empty-card .plan-create-field { flex: 1; min-width: 140px; }
    .plan-empty-card .plan-create-field label { display: block; font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 6px; letter-spacing: -0.005em; }
    .plan-empty-card .plan-create-field input,
    .plan-empty-card .plan-create-field select {
      width: 100%; padding: 11px 14px;
      border: 1px solid var(--border); border-radius: 12px;
      font-size: 0.9375rem; background: var(--bg); color: var(--text);
      box-sizing: border-box;
      transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease);
    }
    .plan-empty-card .plan-create-field input:focus { background: var(--surface); }
    .plan-empty-card .plan-create-field input:hover { border-color: rgba(190, 24, 93, 0.32); }
    .plan-empty-card .plan-create-field input:focus,
    .plan-empty-card .plan-create-field input:focus-visible {
      outline: none; border-color: var(--accent);
      box-shadow: 0 0 0 4px var(--accent-soft);
    }
    .plan-empty-card .plan-create-field input[type="date"] { padding-left: 14px; padding-right: 16px; text-align: left; min-height: 2.875rem; }
    .plan-empty-card .plan-create-submit {
      align-self: stretch; width: 100%;
      padding: 16px 24px;
      font-size: 1rem; font-weight: 700; letter-spacing: -0.01em;
      background: linear-gradient(180deg, var(--accent), var(--accent-hover));
      color: #fff; border: none; border-radius: 14px;
      cursor: pointer;
      box-shadow: 0 8px 22px rgba(190, 24, 93, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.18);
      transition: transform 0.18s var(--ease), box-shadow 0.2s var(--ease), filter 0.15s var(--ease);
      margin-top: 4px;
    }
    .plan-empty-card .plan-create-submit:hover {
      transform: translateY(-2px);
      box-shadow: 0 14px 32px rgba(190, 24, 93, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.22);
      filter: brightness(1.04);
    }
    .plan-empty-card .plan-create-submit:active { transform: translateY(0); }
    .plan-empty-card .plan-create-submit:disabled { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; filter: none; }

    /* Карточка доступа для продуктов без методички (USMLE и т.п.) */
    .plan-empty-card .access-only-list { display: flex; flex-direction: column; gap: 12px; margin-top: 16px; }
    .plan-empty-card .access-only-item {
      display: flex; align-items: center; gap: 16px;
      padding: 16px 18px; border: 1px solid var(--border); border-radius: 14px;
      background: var(--surface);
    }
    .plan-empty-card .access-only-text { flex: 1 1 auto; min-width: 0; }
    .plan-empty-card .access-only-name { margin: 0 0 4px; font-size: 1rem; font-weight: 700; letter-spacing: -0.01em; }
    .plan-empty-card .access-only-desc { margin: 0; font-size: 0.875rem; color: var(--text-secondary); line-height: 1.5; }
    .plan-empty-card .access-only-cta {
      flex: 0 0 auto; padding: 12px 20px;
      font-size: 0.9375rem; font-weight: 700; letter-spacing: -0.01em;
      background: linear-gradient(180deg, var(--accent), var(--accent-hover));
      color: #fff; border: none; border-radius: 12px; cursor: pointer; white-space: nowrap;
      box-shadow: 0 6px 18px rgba(190, 24, 93, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.18);
      transition: transform 0.18s var(--ease), box-shadow 0.2s var(--ease), filter 0.15s var(--ease);
    }
    .plan-empty-card .access-only-cta:hover { transform: translateY(-2px); filter: brightness(1.04); }
    .plan-empty-card .access-only-cta:active { transform: translateY(0); }
    .plan-empty-card .access-only-cta:disabled { opacity: 0.55; cursor: not-allowed; transform: none; box-shadow: none; filter: none; }
    @media (max-width: 560px) {
      .plan-empty-card .access-only-item { flex-direction: column; align-items: stretch; gap: 12px; }
      .plan-empty-card .access-only-cta { width: 100%; }
    }
    .plan-empty-card .plan-create-weekdays-wrap { margin-top: 4px; }
    .plan-empty-card .plan-create-weekdays-wrap > label { display: block; font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 8px; letter-spacing: -0.005em; }
    .plan-empty-card .plan-create-weekdays { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
    .plan-empty-card .plan-create-weekdays .plan-weekday-cb {
      display: inline-flex; align-items: center; gap: 8px;
      padding: 9px 16px;
      border: 1.5px solid var(--border); border-radius: 999px;
      background: var(--bg); cursor: pointer;
      font-size: 0.875rem; font-weight: 500;
      min-height: 40px;
      transition: border-color 0.15s var(--ease), background 0.2s var(--ease), color 0.15s var(--ease), transform 0.15s var(--ease), box-shadow 0.2s var(--ease);
    }
    .plan-empty-card .plan-create-weekdays .plan-weekday-cb:hover { border-color: var(--accent); transform: translateY(-1px); box-shadow: 0 3px 10px rgba(190, 24, 93, 0.1); }
    .plan-empty-card .plan-create-weekdays .plan-weekday-cb:has(.plan-weekday-input:checked) {
      background: linear-gradient(180deg, var(--accent), var(--accent-hover));
      border-color: var(--accent); color: #fff; font-weight: 600;
      box-shadow: 0 5px 14px rgba(190, 24, 93, 0.24);
    }
    .plan-empty-card .plan-create-weekdays .plan-weekday-input {
      margin: 0; width: 1.125rem; height: 1.125rem; accent-color: var(--accent);
      -webkit-appearance: none; appearance: none;
      background: var(--surface);
      border: 1.5px solid var(--border);
      border-radius: 5px;
      flex-shrink: 0;
      transition: background 0.15s var(--ease), border-color 0.15s var(--ease);
    }
    .plan-empty-card .plan-create-weekdays .plan-weekday-input:checked {
      background: rgba(255, 255, 255, 0.95);
      border-color: rgba(255, 255, 255, 0.95);
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23be185d' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
      background-size: 70% 70%;
      background-position: center;
      background-repeat: no-repeat;
    }
    .plan-empty-card .plan-create-error { font-size: 0.875rem; color: #dc2626; margin-top: 8px; display: none; padding: 10px 14px; background: rgba(220, 38, 38, 0.07); border: 1px solid rgba(220, 38, 38, 0.18); border-radius: 10px; }
    .plan-empty-card .plan-create-error.visible { display: block; }
    .plan-empty-card .plan-create-sections-wrap { margin-top: 4px; }
    .plan-empty-card .plan-create-row.plan-create-row-subjects .plan-create-sections-wrap { margin-top: 0; }
    .plan-empty-card .plan-create-sections-wrap > label { display: block; font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 10px; letter-spacing: -0.005em; }
    .plan-empty-card .plan-create-sections {
      display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
      gap: 10px; max-height: 420px; overflow-y: auto;
      padding: 4px 6px 6px 0;
      scroll-behavior: smooth;
    }
    .plan-empty-card .plan-create-sections::-webkit-scrollbar { width: 6px; }
    .plan-empty-card .plan-create-sections::-webkit-scrollbar-thumb { background: var(--accent-soft); border-radius: 3px; }
    .plan-empty-card .plan-create-sections .plan-section-cb-wrap {
      display: flex; align-items: center; gap: 12px;
      padding: 13px 14px;
      border: 1.5px solid var(--border); border-radius: 12px;
      background: var(--bg);
      cursor: pointer; font-size: 0.9375rem; line-height: 1.35;
      min-height: 52px;
      transition: border-color 0.18s var(--ease), background 0.18s var(--ease), box-shadow 0.2s var(--ease), transform 0.15s var(--ease);
      animation: plan-section-fade-in 0.32s var(--ease) backwards;
    }
    .plan-empty-card .plan-create-sections .plan-section-cb-wrap:hover {
      border-color: rgba(190, 24, 93, 0.4);
      box-shadow: 0 4px 14px rgba(190, 24, 93, 0.08);
      transform: translateY(-1px);
    }
    .plan-empty-card .plan-create-sections .plan-section-cb-wrap:active { transform: translateY(0) scale(0.99); }
    .plan-empty-card .plan-create-sections .plan-section-cb-wrap:has(.plan-section-cb:checked) {
      background: linear-gradient(180deg, var(--accent-soft), rgba(190, 24, 93, 0.05));
      border-color: var(--accent);
      color: var(--accent);
      font-weight: 600;
      box-shadow: 0 2px 12px rgba(190, 24, 93, 0.14);
    }
    .plan-empty-card .plan-create-sections .plan-section-cb {
      margin: 0;
      width: 1.375rem; height: 1.375rem;
      flex-shrink: 0;
      -webkit-appearance: none; appearance: none;
      background: var(--surface);
      border: 2px solid var(--border);
      border-radius: 7px;
      cursor: pointer;
      transition: background 0.18s var(--ease), border-color 0.15s var(--ease), transform 0.18s var(--ease);
    }
    .plan-empty-card .plan-create-sections .plan-section-cb:hover { border-color: var(--accent); }
    .plan-empty-card .plan-create-sections .plan-section-cb:checked {
      background: var(--accent);
      border-color: var(--accent);
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
      background-size: 70% 70%; background-position: center; background-repeat: no-repeat;
      transform: scale(1.06);
    }
    @keyframes plan-section-fade-in {
      from { opacity: 0; transform: translateY(6px); }
      to { opacity: 1; transform: translateY(0); }
    }
    /* Раскрывающиеся разделы с выбором тем (нозологий) внутри */
    .plan-empty-card .plan-create-sections.plan-create-sections-tree {
      display: flex; flex-direction: column; gap: 8px;
      max-height: 520px;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-row {
      flex: 0 0 auto;
      border: 1.5px solid var(--border); border-radius: 12px;
      background: var(--bg); overflow: hidden;
      transition: border-color 0.18s var(--ease), box-shadow 0.2s var(--ease);
      animation: plan-section-fade-in 0.32s var(--ease) backwards;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-row.selected {
      border-color: var(--accent);
      box-shadow: 0 2px 12px rgba(190, 24, 93, 0.12);
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-head {
      display: flex; align-items: center; gap: 12px;
      padding: 12px 14px; min-height: 52px;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-toggle {
      flex: 1; display: flex; align-items: center; gap: 10px;
      background: none; border: none; cursor: pointer; padding: 0;
      text-align: left; font: inherit; color: var(--text);
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-name {
      flex: 1; font-size: 0.9375rem; font-weight: 600; line-height: 1.3;
      letter-spacing: -0.005em;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-row.selected .plan-section-name { color: var(--accent); }
    .plan-empty-card .plan-create-sections-tree .plan-section-badge {
      font-size: 0.75rem; font-weight: 600; color: var(--text-secondary);
      padding: 2px 9px; border-radius: 999px; background: rgba(0, 0, 0, 0.05);
      white-space: nowrap;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-badge:empty { display: none; }
    .plan-empty-card .plan-create-sections-tree .plan-section-badge.full { color: var(--accent); background: var(--accent-soft); }
    .plan-empty-card .plan-create-sections-tree .plan-section-badge.partial { color: #b45309; background: rgba(245, 158, 11, 0.16); }
    .plan-empty-card .plan-create-sections-tree .plan-section-chevron {
      display: flex; color: var(--text-secondary);
      transition: transform 0.2s var(--ease);
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-chevron svg { width: 18px; height: 18px; }
    .plan-empty-card .plan-create-sections-tree .plan-section-row.expanded .plan-section-chevron { transform: rotate(180deg); }
    .plan-empty-card .plan-create-sections-tree .plan-section-cb:indeterminate {
      background: var(--accent); border-color: var(--accent);
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round'%3E%3Cline x1='5' y1='12' x2='19' y2='12'/%3E%3C/svg%3E");
      background-size: 70% 70%; background-position: center; background-repeat: no-repeat;
    }
    .plan-empty-card .plan-create-sections-tree .plan-section-lessons {
      padding: 10px 14px 12px; border-top: 1px dashed var(--border);
      display: flex; flex-direction: column; gap: 8px;
    }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-loading { font-size: 0.875rem; color: var(--text-secondary); padding: 4px 2px; }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-controls { display: flex; gap: 8px; flex-wrap: wrap; }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-bulk {
      font-size: 0.8125rem; font-weight: 600; color: var(--accent);
      background: var(--accent-soft); border: none; border-radius: 8px;
      padding: 5px 11px; cursor: pointer; transition: background 0.15s var(--ease);
      width: auto;
    }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-bulk:hover { background: rgba(190, 24, 93, 0.16); }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-filter {
      width: 100%; padding: 8px 11px; border: 1.5px solid var(--border);
      border-radius: 8px; font-size: 0.875rem; background: var(--surface); color: var(--text);
      box-sizing: border-box;
    }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-filter:focus { outline: none; border-color: var(--accent); }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-list { display: flex; flex-direction: column; gap: 2px; max-height: 300px; overflow-y: auto; }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-list::-webkit-scrollbar { width: 6px; }
    .plan-empty-card .plan-create-sections-tree .plan-lessons-list::-webkit-scrollbar-thumb { background: var(--accent-soft); border-radius: 3px; }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-cb-wrap {
      display: flex; align-items: center; gap: 10px;
      padding: 8px; border-radius: 8px; cursor: pointer;
      font-size: 0.875rem; line-height: 1.3; color: var(--text);
      transition: background 0.15s var(--ease);
    }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-cb-wrap:hover { background: var(--accent-soft); }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-cb {
      width: 1.125rem; height: 1.125rem; min-height: 0; flex: 0 0 auto; margin: 0; padding: 0;
      box-sizing: border-box;
      -webkit-appearance: none; appearance: none;
      background: var(--surface); border: 2px solid var(--border);
      border-radius: 6px; cursor: pointer;
      transition: background 0.15s var(--ease), border-color 0.15s var(--ease);
    }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-cb:hover { border-color: var(--accent); }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-cb:checked {
      background: var(--accent); border-color: var(--accent);
      background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
      background-size: 70% 70%; background-position: center; background-repeat: no-repeat;
    }
    .plan-empty-card .plan-create-sections-tree .plan-lesson-name { flex: 1; }
    .plan-empty-card .plan-create-sections-placeholder {
      font-size: 0.9375rem; color: var(--text-secondary);
      padding: 18px 16px;
      border: 1.5px dashed var(--border); border-radius: 12px;
      background: rgba(255, 255, 255, 0.6);
      text-align: center;
    }
    /* Live preview ticker */
    .plan-create-preview {
      display: flex; align-items: center; gap: 12px;
      padding: 12px 16px; border-radius: 12px;
      background: linear-gradient(180deg, rgba(190, 24, 93, 0.07), rgba(190, 24, 93, 0.03));
      border: 1px solid var(--accent-soft);
      font-size: 0.9375rem; color: var(--text);
      margin-top: 4px;
      opacity: 0; transform: translateY(4px);
      transition: opacity 0.28s var(--ease), transform 0.28s var(--ease);
      pointer-events: none;
    }
    .plan-create-preview.visible { opacity: 1; transform: translateY(0); }
    .plan-create-preview-dot {
      width: 9px; height: 9px; border-radius: 50%;
      background: var(--accent);
      box-shadow: 0 0 0 4px var(--accent-soft);
      animation: plan-preview-pulse 1.9s var(--ease) infinite;
      flex-shrink: 0;
    }
    .plan-create-preview-text { line-height: 1.4; }
    .plan-create-preview-text strong { color: var(--accent); font-weight: 700; }
    @keyframes plan-preview-pulse {
      0%, 100% { box-shadow: 0 0 0 4px var(--accent-soft); }
      50% { box-shadow: 0 0 0 8px rgba(190, 24, 93, 0.05); }
    }
    @media (max-width: 640px) {
      .plan-empty-card .plan-create-sections { grid-template-columns: 1fr; max-height: 460px; gap: 8px; }
      .plan-empty-card .plan-create-sections .plan-section-cb-wrap { padding: 12px; min-height: 52px; }
      .plan-empty-card .plan-empty-title { font-size: 1.25rem; }
      .plan-empty-card .plan-create-submit { padding: 15px 20px; font-size: 0.9375rem; }
    }
    .plan-empty-card .plan-subject-native-select { position: absolute; left: -9999px; opacity: 0; pointer-events: none; width: 1px; height: 1px; }
    .plan-empty-card .plan-subject-picker { border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); padding: 10px; display: flex; flex-direction: column; gap: 10px; }
    .plan-empty-card .plan-subject-picker-group-title { margin: 0 0 6px; font-size: 0.75rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; }
    .plan-empty-card .plan-subject-picker-list { display: flex; flex-wrap: wrap; gap: 8px; }
    .plan-empty-card #planCreateLockedSubjects {
      display: flex;
      flex-direction: column;
      flex-wrap: nowrap;
      gap: 8px;
      max-height: 260px;
      overflow-y: auto;
      overflow-x: hidden;
      padding-right: 4px;
    }
    .plan-empty-card .plan-subject-chip { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 6px 10px; font-size: 0.8125rem; line-height: 1.2; cursor: pointer; transition: border-color .15s, background .15s, color .15s; }
    .plan-empty-card .plan-subject-chip:hover { border-color: var(--accent); }
    .plan-empty-card .plan-subject-chip.active { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
    .plan-empty-card .plan-subject-locked-item { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; border: 1px dashed var(--border); border-radius: var(--radius-sm); padding: 8px 10px; background: var(--surface); }
    .plan-empty-card .plan-subject-locked-name { border: none; background: transparent; color: var(--text-secondary); cursor: pointer; text-align: left; padding: 0; font-size: 0.8125rem; flex: 1 1 140px; min-width: 0; }
    .plan-empty-card .plan-subject-locked-name:hover { color: var(--text); }
    .plan-empty-card .plan-subject-reco-badge { display: inline-flex; align-items: center; font-size: 0.6875rem; font-weight: 700; border-radius: 999px; border: 1px solid rgba(217, 119, 6, 0.35); background: rgba(217, 119, 6, 0.1); color: #b45309; padding: 3px 7px; white-space: nowrap; }
    .plan-empty-card .plan-subject-cta { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 999px; padding: 5px 9px; font-size: 0.75rem; cursor: pointer; white-space: nowrap; margin-left: auto; }
    .plan-empty-card .plan-subject-cta:hover { border-color: var(--accent); color: var(--accent); }
    .plan-empty-card .plan-no-owned-wrap { display: none; border: 1px solid rgba(217, 119, 6, 0.25); background: rgba(217, 119, 6, 0.08); border-radius: var(--radius-sm); padding: 12px; margin-top: 4px; }
    .plan-empty-card .plan-no-owned-wrap.visible { display: block; }
    .plan-empty-card .plan-no-owned-title { margin: 0 0 4px; font-size: 0.875rem; font-weight: 700; color: #9a3412; }
    .plan-empty-card .plan-no-owned-desc { margin: 0; font-size: 0.8125rem; color: var(--text-secondary); }
    .plan-subject-teaser-popover { position: fixed; z-index: 300; max-width: 320px; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: 0 10px 24px rgba(0,0,0,0.12); padding: 12px; }
    .plan-subject-teaser-popover h4 { margin: 0 0 6px; font-size: 0.9375rem; }
    .plan-subject-teaser-popover p { margin: 0 0 6px; font-size: 0.8125rem; color: var(--text-secondary); }
    .plan-subject-teaser-popover p:last-child { margin-bottom: 0; }
    .plan-subject-teaser-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 310; display: none; align-items: flex-end; justify-content: center; padding: 0; }
    .plan-subject-teaser-overlay.visible { display: flex; }
    .plan-subject-teaser-sheet { width: 100%; max-width: 560px; background: var(--surface); border-radius: var(--radius) var(--radius) 0 0; padding: 16px 18px 22px; box-shadow: 0 -6px 24px rgba(0,0,0,0.16); }
    .plan-subject-teaser-sheet h4 { margin: 0 0 8px; font-size: 1rem; }
    .plan-subject-teaser-sheet p { margin: 0 0 8px; font-size: 0.875rem; color: var(--text-secondary); line-height: 1.4; }
    .plan-subject-teaser-actions { display: flex; gap: 8px; margin-top: 10px; }
    @media (min-width: 769px) {
      .plan-subject-teaser-overlay { align-items: center; padding: 20px; }
      .plan-subject-teaser-sheet { border-radius: var(--radius); max-width: 380px; }
    }
    .plan-create-next-form-container { margin-top: 20px; display: none; }
    .plan-create-next-form-container.visible { display: block; }
    .empty-msg { color: var(--text-secondary); font-size: 0.9375rem; padding: 16px 0; }
    .all-scales-wrap { font-size: 0.875rem; }
    .scale-section { margin-bottom: 16px; }
    .scale-section:last-child { margin-bottom: 0; }
    .scale-section-title { font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); margin: 0 0 6px; }
    .scale-section-body { background: var(--bg); border-radius: var(--radius-sm); padding: 10px 12px; }
    .scale-row { padding: 4px 0; color: var(--text); word-break: break-word; }
    .scale-row + .scale-row { border-top: 1px solid var(--border); }
    .stats-card { --stats-accent: var(--accent); --stats-soft: var(--accent-soft); border-left: 4px solid var(--stats-accent); overflow: hidden; }
    .stats-title-row { display: flex; align-items: center; gap: 10px; }
    .stats-title-row h2 { flex: 1 1 auto; min-width: 0; }
    .stats-share-btn { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 6px 13px; border-radius: 999px; border: 1.5px solid var(--stats-soft); background: var(--stats-soft); color: var(--stats-accent); font-size: 0.8125rem; font-weight: 600; font-family: inherit; cursor: pointer; line-height: 1; transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease; }
    .stats-share-btn:hover { background: rgba(13, 148, 136, 0.18); border-color: var(--stats-accent); }
    .stats-share-btn:active { transform: scale(0.96); }
    .stats-share-btn svg { flex: 0 0 auto; }
    @media (max-width: 480px) { .stats-share-btn span { display: none; } .stats-share-btn { padding: 7px; } }
    .stats-hero { background: linear-gradient(135deg, var(--stats-soft) 0%, rgba(13, 148, 136, 0.04) 100%); border-radius: var(--radius-sm); padding: 16px 18px; margin-bottom: 20px; border: 1px solid rgba(13, 148, 136, 0.12); }
    .stats-hero-icon { font-size: 1.5rem; line-height: 1; margin-bottom: 8px; display: block; }
    .stats-hero-title { font-size: 1rem; font-weight: 700; color: var(--text); margin: 0 0 4px; letter-spacing: -0.02em; }
    .stats-hero-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0; line-height: 1.45; }
    .stats-metrics { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 12px; margin-bottom: 20px; }
    .stats-metric { background: var(--bg); border-radius: var(--radius-sm); padding: 14px 12px; text-align: center; border: 1px solid var(--border); transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease); }
    .stats-metric:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
    .stats-metric-value { font-size: 1.5rem; font-weight: 800; line-height: 1; color: var(--stats-accent); letter-spacing: -0.03em; display: block; margin-bottom: 4px; font-variant-numeric: tabular-nums; }
    .stats-metric-label { font-size: 0.75rem; color: var(--text-secondary); font-weight: 500; text-transform: uppercase; letter-spacing: 0.04em; }
    .stats-section-title { font-size: 0.8125rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; margin: 0 0 12px; padding-bottom: 6px; border-bottom: 1px solid var(--border); }
    .stats-by-subject { margin-bottom: 20px; }
    .stats-subject { background: var(--bg); border-radius: var(--radius-sm); margin-bottom: 10px; border: 1px solid var(--border); overflow: hidden; }
    .stats-subject:last-child { margin-bottom: 0; }
    .stats-subject-header { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; user-select: none; -webkit-user-select: none; }
    .stats-subject-header:hover { background: rgba(0,0,0,0.02); }
    .stats-subject-toggle { width: 18px; height: 18px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; color: var(--text-secondary); transition: transform 0.25s var(--ease); font-size: 0.75rem; }
    .stats-subject.open .stats-subject-toggle { transform: rotate(90deg); }
    .stats-subject-name { font-weight: 600; font-size: 0.9375rem; color: var(--text); flex: 1; min-width: 0; }
    .stats-subject-summary { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
    .stats-subject-summary-pct { font-size: 0.8125rem; font-weight: 700; color: var(--stats-accent); font-variant-numeric: tabular-nums; }
    .stats-subject-summary-count { font-size: 0.6875rem; color: var(--text-secondary); }
    .stats-subject-minibar { width: 48px; height: 5px; background: var(--surface); border-radius: 999px; overflow: hidden; border: 1px solid var(--border); flex-shrink: 0; }
    .stats-subject-minibar-fill { height: 100%; border-radius: 999px; background: var(--stats-accent); }
    .stats-subject-body { padding: 0 14px 14px; display: none; }
    .stats-subject.open .stats-subject-body { display: block; }
    .stats-pills { display: flex; flex-wrap: wrap; gap: 8px; }
    .stats-pill { font-size: 0.75rem; padding: 5px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); color: var(--text-secondary); display: inline-flex; align-items: center; gap: 5px; }
    .stats-pill.stats-pill-theory { border-color: rgba(13, 148, 136, 0.35); background: rgba(13, 148, 136, 0.08); color: var(--stats-accent); }
    .stats-pill.stats-pill-practice { border-color: rgba(194, 65, 12, 0.35); background: rgba(194, 65, 12, 0.08); color: #c2410c; }
    .stats-pill.stats-pill-memorization { border-color: rgba(109, 40, 217, 0.35); background: rgba(109, 40, 217, 0.08); color: #6d28d9; }
    .stats-pill.stats-pill-section { font-weight: 600; color: var(--text); background: transparent; border: none; padding-left: 0; }
    .stats-pill-num { font-weight: 700; font-variant-numeric: tabular-nums; }
    .stats-count-num { font-variant-numeric: tabular-nums; }
    .stats-memorization-block { background: linear-gradient(135deg, rgba(109, 40, 217, 0.08) 0%, rgba(109, 40, 217, 0.02) 100%); border-radius: var(--radius-sm); padding: 14px 16px; margin-bottom: 20px; border: 1px solid rgba(109, 40, 217, 0.15); }
    .stats-memorization-block .stats-section-title { color: #6d28d9; border-bottom-color: rgba(109, 40, 217, 0.2); }
    .stats-profile-wrap { margin-bottom: 24px; }
    /* 5 колец: на широком — один ряд, на узком — 3+2 (вместо ломаного 4+1). */
    .stats-profile-rings {
      display: grid;
      grid-template-columns: repeat(5, minmax(0, 1fr));
      gap: 10px 6px;
    }
    @media (max-width: 560px) {
      /* 6-колоночный трюк: 3 в первом ряду (span 2 каждое), 4-й и 5-й
       * центрируем смещением — иначе вторая строка липнет к левому краю. */
      .stats-profile-rings { grid-template-columns: repeat(6, minmax(0, 1fr)); }
      .stats-profile-ring { grid-column: span 2; }
      .stats-profile-ring:nth-child(4) { grid-column: 2 / span 2; }
      .stats-profile-ring:nth-child(5) { grid-column: 4 / span 2; }
    }
    .stats-profile-ring {
      display: flex;
      flex-direction: column;
      align-items: center;
      padding: 10px 4px 8px;
      border-radius: 14px;
      transition: background 200ms var(--ease);
    }
    .stats-profile-ring:hover { background: rgba(15, 23, 25, 0.035); }
    .stats-profile-ring svg {
      width: 76px;
      height: 76px;
      transform: rotate(-90deg);
      display: block;
      overflow: visible;
    }
    /* Видимый «трек» — иначе пустая часть кольца сливается с белым фоном
     * карточки и арка выглядит висящей в воздухе. */
    .stats-profile-ring .ring-bg {
      fill: none;
      stroke: rgba(15, 23, 25, 0.08);
      stroke-width: 7;
    }
    .stats-profile-ring .ring-fg {
      fill: none;
      stroke-width: 7;
      stroke-linecap: round;
      transition: stroke-dashoffset 1.4s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .stats-profile-ring .ring-fg.c0 { stroke: #0d9488; }
    .stats-profile-ring .ring-fg.c1 { stroke: #c2410c; }
    .stats-profile-ring .ring-fg.c2 { stroke: #6d28d9; }
    .stats-profile-ring .ring-fg.c3 { stroke: #2563eb; }
    .stats-profile-ring .ring-fg.c4 { stroke: #d97706; }
    .stats-profile-pct {
      font-size: 1.0625rem;
      font-weight: 800;
      color: var(--text);
      margin-top: 8px;
      font-variant-numeric: tabular-nums;
      line-height: 1;
      letter-spacing: -0.01em;
    }
    .stats-profile-name {
      font-size: 0.75rem;
      font-weight: 600;
      color: var(--text);
      margin-top: 4px;
      text-align: center;
      line-height: 1.2;
    }
    .stats-profile-sub {
      font-size: 0.625rem;
      color: var(--text-secondary);
      margin-top: 2px;
      text-align: center;
      opacity: 0.75;
      font-variant-numeric: tabular-nums;
    }
    body.pussy-power-mode .stats-profile-ring .ring-fg.c0 { stroke: var(--accent); }
    .stats-memorization-summary { font-size: 0.9375rem; color: var(--text); margin: 0 0 8px; line-height: 1.4; }
    .stats-memorization-detail { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; }
    .stats-video-block { margin-bottom: 0; }
    .stats-video-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg); border-radius: var(--radius-sm); margin-bottom: 8px; border: 1px solid var(--border); }
    .stats-video-item:last-child { margin-bottom: 0; }
    .stats-video-item-icon { font-size: 1.25rem; flex-shrink: 0; }
    .stats-video-item-text { flex: 1; min-width: 0; font-size: 0.875rem; color: var(--text); }
    .stats-video-item-count { font-weight: 700; color: var(--stats-accent); font-size: 0.9375rem; }
    .stats-empty-msg { text-align: center; padding: 24px 16px; color: var(--text-secondary); font-size: 0.9375rem; }
    .stats-empty-msg .stats-empty-icon { font-size: 2rem; margin-bottom: 8px; opacity: 0.6; display: block; }

    /* --- Heatmap calendar --- */
    .stats-heatmap-wrap { margin-bottom: 20px; position: relative; }
    .stats-heatmap-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 8px; }
    .stats-heatmap-sub { font-size: 0.72rem; color: var(--text-secondary); margin-left: 8px; }
    .stats-heatmap-toggle { background: none; border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px; font-size: 0.72rem; color: var(--stats-accent, #0d9488); cursor: pointer; transition: background .15s, border-color .15s; }
    .stats-heatmap-toggle:hover { background: rgba(13, 148, 136, 0.08); border-color: var(--stats-accent, #0d9488); }
    .stats-heatmap-scroll { overflow-x: auto; padding-bottom: 4px; }
    .stats-heatmap-grid { display: grid; grid-template-columns: repeat(13, 1fr); grid-auto-flow: row; gap: 3px; }
    .stats-heatmap-cell { aspect-ratio: 1; border-radius: 3px; background: var(--surface); border: 1px solid var(--border); position: relative; cursor: default; transition: transform 0.12s var(--ease); min-width: 12px; }
    .stats-heatmap-cell:hover { transform: scale(1.4); z-index: 2; outline: 1px solid var(--stats-accent, #0d9488); outline-offset: 1px; }
    .stats-heatmap-cell.future { opacity: 0; pointer-events: none; }
    .stats-heatmap-cell.today { box-shadow: 0 0 0 2px var(--stats-accent, #0d9488); }
    .stats-heatmap-l0 { background: var(--surface); border-color: var(--border); }
    .stats-heatmap-l1 { background: rgba(13, 148, 136, 0.18); border-color: rgba(13, 148, 136, 0.28); }
    .stats-heatmap-l2 { background: rgba(13, 148, 136, 0.45); border-color: rgba(13, 148, 136, 0.55); }
    .stats-heatmap-l3 { background: rgba(13, 148, 136, 0.85); border-color: rgba(13, 148, 136, 0.95); }
    .stats-heatmap-tooltip-fixed { position: absolute; pointer-events: none; background: var(--text); color: var(--bg); font-size: 0.7rem; line-height: 1.3; padding: 6px 9px; border-radius: 6px; white-space: nowrap; opacity: 0; transition: opacity .12s; z-index: 20; transform: translate(-50%, -100%); }
    .stats-heatmap-tooltip-fixed.is-shown { opacity: 1; }
    .stats-heatmap-legend { display: flex; align-items: center; gap: 4px; margin-top: 8px; font-size: 0.6875rem; color: var(--text-secondary); justify-content: flex-end; }
    .stats-heatmap-legend-box { width: 12px; height: 12px; border-radius: 2px; border: 1px solid var(--border); }
    .stats-heatmap-months { display: grid; grid-template-columns: repeat(13, 1fr); gap: 3px; margin-bottom: 4px; }
    .stats-heatmap-month { font-size: 0.5625rem; color: var(--text-secondary); text-align: center; text-transform: uppercase; letter-spacing: 0.03em; }
    body.pussy-power-mode .stats-heatmap-l1 { background: rgba(190, 24, 93, 0.18); border-color: rgba(190, 24, 93, 0.28); }
    body.pussy-power-mode .stats-heatmap-l2 { background: rgba(190, 24, 93, 0.45); border-color: rgba(190, 24, 93, 0.55); }
    body.pussy-power-mode .stats-heatmap-l3 { background: rgba(190, 24, 93, 0.85); border-color: rgba(190, 24, 93, 0.95); }

    /* --- Trends block --- */
    .stats-trends { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin-bottom: 20px; }
    .stats-trend-card { background: var(--bg); border-radius: var(--radius-sm); padding: 14px 12px; border: 1px solid var(--border); text-align: center; }
    .stats-trend-label { font-size: 0.6875rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; margin-bottom: 6px; }
    .stats-trend-value { font-size: 1.25rem; font-weight: 800; color: var(--text); font-variant-numeric: tabular-nums; margin-bottom: 4px; }
    .stats-trend-delta { font-size: 0.75rem; font-weight: 600; display: inline-flex; align-items: center; gap: 3px; padding: 2px 8px; border-radius: 999px; }
    .stats-trend-delta.up { color: #059669; background: rgba(5, 150, 105, 0.1); }
    .stats-trend-delta.down { color: #dc2626; background: rgba(220, 38, 38, 0.1); }
    .stats-trend-delta.neutral { color: var(--text-secondary); background: var(--surface); }

    /* --- Progress bars for sections --- */
    .stats-section-progress { margin-bottom: 10px; }
    .stats-section-progress:last-child { margin-bottom: 0; }
    .stats-progress-header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 4px; }
    .stats-progress-name { font-size: 0.8125rem; font-weight: 600; color: var(--text); }
    .stats-progress-pct { font-size: 0.75rem; font-weight: 700; color: var(--stats-accent); font-variant-numeric: tabular-nums; }
    .stats-progress-bar-wrap { height: 8px; background: var(--surface); border-radius: 999px; overflow: hidden; border: 1px solid var(--border); }
    .stats-progress-bar-fill { height: 100%; border-radius: 999px; transition: width 1.2s cubic-bezier(0.22, 1, 0.36, 1); background: linear-gradient(90deg, var(--stats-accent), rgba(13, 148, 136, 0.65)); }
    .stats-progress-detail { font-size: 0.6875rem; color: var(--text-secondary); margin-top: 3px; display: flex; gap: 10px; flex-wrap: wrap; }

    /* --- Personal records --- */
    .stats-records { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-bottom: 20px; }
    .stats-record { background: linear-gradient(135deg, rgba(234, 179, 8, 0.08) 0%, rgba(234, 179, 8, 0.02) 100%); border: 1px solid rgba(234, 179, 8, 0.2); border-radius: var(--radius-sm); padding: 12px 10px; text-align: center; }
    .stats-record-icon { font-size: 1.25rem; margin-bottom: 4px; display: block; }
    .stats-record-value { font-size: 1.25rem; font-weight: 800; color: #b45309; display: block; font-variant-numeric: tabular-nums; line-height: 1.2; }
    .stats-record-label { font-size: 0.6875rem; color: var(--text-secondary); margin-top: 4px; line-height: 1.3; }
    body.pussy-power-mode .stats-record { background: linear-gradient(135deg, rgba(190, 24, 93, 0.08) 0%, rgba(190, 24, 93, 0.02) 100%); border-color: rgba(190, 24, 93, 0.2); }
    body.pussy-power-mode .stats-record-value { color: #be185d; }

    /* --- Accuracy breakdown --- */
    .stats-accuracy { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
    .stats-accuracy-item { text-align: center; padding: 12px 8px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); }
    .stats-accuracy-pct { font-size: 1.35rem; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
    .stats-accuracy-pct.theory { color: var(--stats-accent); }
    .stats-accuracy-pct.practice { color: #c2410c; }
    .stats-accuracy-pct.clinical { color: #6d28d9; }
    .stats-accuracy-label { font-size: 0.6875rem; color: var(--text-secondary); margin-top: 4px; text-transform: uppercase; letter-spacing: 0.03em; font-weight: 600; }
    .stats-accuracy-count { font-size: 0.625rem; color: var(--text-secondary); margin-top: 2px; }

    /* --- SRS widget --- */
    .stats-srs { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px; margin-bottom: 20px; }
    .stats-srs-item { text-align: center; padding: 12px 8px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); }
    .stats-srs-value { font-size: 1.25rem; font-weight: 800; color: var(--text); display: block; font-variant-numeric: tabular-nums; }
    .stats-srs-value.due { color: #dc2626; }
    .stats-srs-value.learning { color: #d97706; }
    .stats-srs-value.mastered { color: #059669; }
    .stats-srs-label { font-size: 0.6875rem; color: var(--text-secondary); margin-top: 3px; }

    .profile-reminder-card { background: linear-gradient(135deg, rgba(13, 148, 136, 0.08) 0%, rgba(13, 148, 136, 0.03) 100%); border: 1px solid rgba(13, 148, 136, 0.2); border-left: 4px solid var(--accent); border-radius: var(--radius-sm); padding: 14px 18px; margin-bottom: 20px; }
    .profile-reminder-card .profile-reminder-icon { font-size: 1.25rem; margin-bottom: 6px; display: block; }
    .profile-reminder-card .profile-reminder-title { font-size: 0.9375rem; font-weight: 700; color: var(--text); margin: 0 0 6px; }
    .profile-reminder-card .profile-reminder-desc { font-size: 0.875rem; color: var(--text-secondary); margin: 0 0 12px; line-height: 1.45; }
    .profile-reminder-card .profile-reminder-btn { display: inline-block; font-size: 0.875rem; font-weight: 600; color: var(--accent); text-decoration: none; background: none; border: none; padding: 0; cursor: pointer; font-family: inherit; }
    .profile-reminder-card .profile-reminder-btn:hover { text-decoration: underline; }
    body.pussy-power-mode .stats-card { --stats-accent: var(--accent); --stats-soft: rgba(190, 24, 93, 0.12); }
    body.pussy-power-mode .stats-hero { background: linear-gradient(135deg, var(--stats-soft) 0%, rgba(190, 24, 93, 0.04) 100%); border-color: rgba(190, 24, 93, 0.15); }
    body.pussy-power-mode .stats-metric-value { color: var(--accent); }
    .divider { margin: 20px 0; border: none; border-top: 1px solid var(--border); }
    .contact-request-card .section-label { margin-bottom: 12px; }
    #loadingBlock, #loginBlock, #cabinetBlock { display: none; }
    #loadingBlock.visible, #loginBlock.visible, #cabinetBlock.visible { display: block; }
    .telegram-widget-wrap { margin: 14px 0; }
    .auth-link { color: var(--accent); font-weight: 600; text-decoration: none; }
    .auth-link:hover { text-decoration: underline; }
    .vpn-instruction-toggle { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; padding: 0; border: none; background: none; color: var(--accent); font-size: 0.875rem; font-weight: 600; cursor: pointer; font-family: inherit; text-decoration: none; }
    .vpn-instruction-toggle:hover { text-decoration: underline; }
    .vpn-instruction-toggle::before { content: ''; display: inline-block; width: 0; height: 0; border-left: 5px solid currentColor; border-top: 4px solid transparent; border-bottom: 4px solid transparent; margin-right: 4px; transition: transform 0.2s ease; }
    .vpn-instruction-toggle[aria-expanded="true"]::before { transform: rotate(90deg); }
    .vpn-instruction-body { display: none; margin-top: 12px; padding: 16px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 0.9rem; }
    .vpn-instruction-body.show { display: block; }
    .vpn-instruction-body h2 { font-size: 1.125rem; margin: 0 0 12px; }
    .vpn-instruction-body h3 { font-size: 1rem; margin: 16px 0 8px; }
    .vpn-instruction-body p, .vpn-instruction-body li { margin: 0 0 6px; line-height: 1.45; color: var(--text-secondary); }
    .vpn-instruction-body ul { margin: 0 0 12px; padding-left: 20px; }
    .vpn-instruction-body hr { border: none; border-top: 1px solid var(--border); margin: 16px 0; }
    .vpn-instruction-body code { font-family: ui-monospace, monospace; font-size: 0.875em; background: rgba(0,0,0,0.06); padding: 2px 6px; border-radius: 4px; }
    .vpn-instruction-body .note { font-size: 0.8125rem; margin-top: 16px; }
    .vpn-instruction-subscription-link { padding: 12px 14px; background: rgba(13, 148, 136, 0.08); border: 1px solid rgba(13, 148, 136, 0.25); border-radius: var(--radius-sm); font-size: 0.9rem; }
    /* Урезанный кабинет по ссылке из ТГ (source=speedup): только привязка счёта и блок VPN */
    body.cabinet-speedup-only #contactRequestBlock,
    body.cabinet-speedup-only .widgets-row,
    body.cabinet-speedup-only #planSection,
    body.cabinet-speedup-only #skillTreeBlock,
    body.cabinet-speedup-only .pussy-power-banner,
    body.cabinet-speedup-only #progressBlock,
    body.cabinet-speedup-only #zenPaymentAltBlock,
    body.cabinet-speedup-only #entitlementsBlock,
    body.cabinet-speedup-only #subscriptionsBlock,
    body.cabinet-speedup-only #referralBlock,
    body.cabinet-speedup-only #nasledieBlock,
    body.cabinet-speedup-only #profileReminderBlock,
    body.cabinet-speedup-only #allScalesBlock,
    body.cabinet-speedup-only #methodologyBlock,
    body.cabinet-speedup-only #sectionLinksBlock,
    body.cabinet-speedup-only #recommendedCatalogBlock,
    body.cabinet-speedup-only #allCatalogBlock,
    body.cabinet-speedup-only #emptyCabinetMsg { display: none !important; }
    body.cabinet-speedup-only #btnEditProfile,
    body.cabinet-speedup-only #btnAccelerator,
    body.cabinet-speedup-only #btnPussyPower { display: none !important; }
    body.cabinet-speedup-only .cabinet-full-link { display: inline-flex !important; align-items: center; margin-right: 8px; }
    .vpn-instruction-subscription-link .subscription-link-url { display: block; word-break: break-all; margin-top: 6px; color: var(--accent); }
    .vpn-instruction-subscription-link .copy-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 8px 14px; font-size: 0.875rem; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: pointer; color: var(--text); }
    .vpn-instruction-subscription-link .copy-link:hover { border-color: var(--accent); color: var(--accent); }
    .cabinet-zen-alt-card .section-label { line-height: 1.5; }
    .auth-tabs { display: flex; gap: 0; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
    .auth-tab { padding: 10px 16px; font-size: 0.9375rem; font-weight: 600; color: var(--text-secondary); background: none; border: none; border-bottom: 2px solid transparent; margin-bottom: -1px; cursor: pointer; font-family: inherit; border-radius: var(--radius-sm) var(--radius-sm) 0 0; transition: color 0.2s var(--ease), border-color 0.2s var(--ease); }
    .auth-tab:hover { color: var(--text); }
    .auth-tab.active { color: var(--accent); border-bottom-color: var(--accent); }
    .streak-card { --streak-accent: #d97706; --streak-soft: rgba(217, 119, 6, 0.12); }
    .streak-card.today-done { border-left: 4px solid var(--accent); }
    .streak-card .streak-header { display: flex; align-items: center; gap: 10px; margin: 0 0 16px; }
    .streak-card .streak-flame { width: 26px; height: 26px; flex-shrink: 0; transition: color 0.3s var(--ease), opacity 0.3s var(--ease), transform 0.3s var(--ease); }
    .streak-card .streak-flame.flame-zero { color: var(--text-secondary); opacity: 0.5; }
    .streak-card .streak-flame.flame-low { color: #ea580c; opacity: 1; }
    .streak-card .streak-flame.flame-high { color: var(--streak-accent); opacity: 1; animation: streak-flame-pulse 2s ease-in-out infinite; }
    @keyframes streak-flame-pulse { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: 0.92; transform: scale(1.02); } }
    .streak-card .streak-hero { margin-bottom: 14px; }
    .streak-card .streak-number-wrap { margin-bottom: 2px; }
    .streak-card .streak-number { font-size: 2.5rem; font-weight: 800; line-height: 1; letter-spacing: -0.03em; transition: transform 0.3s var(--ease), color 0.3s var(--ease); }
    .streak-card .streak-number.has-streak { color: var(--streak-accent); }
    .streak-card .streak-number.zero { color: var(--text-secondary); }
    .streak-card .streak-label { font-size: 0.9375rem; color: var(--text-secondary); margin: 0; font-weight: 500; }
    .streak-card .streak-meta { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin-bottom: 14px; }
    .streak-card .streak-longest { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; }
    .streak-card .streak-countdown { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; padding: 6px 12px; background: var(--streak-soft); border-radius: var(--radius-sm); font-weight: 500; display: inline-flex; align-items: center; gap: 6px; }
    .streak-card .streak-countdown .streak-countdown-value { color: var(--streak-accent); font-weight: 700; }
    .streak-card .streak-hint { font-size: 0.9375rem; color: var(--text-secondary); margin: 0 0 16px; line-height: 1.4; }
    .streak-card .streak-cta { margin-top: auto; padding-top: 4px; }
    .streak-card .streak-cta .btn-primary { text-decoration: none; }
    .widgets-row { display: flex; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; align-items: stretch; }
    .widgets-row > div { min-width: 0; display: flex; }
    .widgets-row > div:first-child { flex: 0 1 200px; max-width: 220px; }
    .widgets-row > div:last-child { flex: 1 1 280px; }
    .widgets-row .card { margin-bottom: 0; flex: 1; display: flex; flex-direction: column; min-height: 0; }
    @media (max-width: 560px) {
      .widgets-row > div { flex: 1 1 100%; max-width: none; }
    }
    .pussy-power-hero {
      display: none;
      font-family: 'Cormorant Garamond', Georgia, serif;
      font-size: clamp(2rem, 6vw, 3rem);
      font-weight: 700;
      letter-spacing: 0.02em;
      color: var(--accent);
      text-align: center;
      margin: 24px 0 28px;
      line-height: 1.2;
    }
    body.pussy-power-mode .pussy-power-hero { display: block; }
    .league-card { --league-accent: #b45309; --league-soft: rgba(180, 83, 9, 0.1); border-left: 4px solid var(--league-accent); position: relative; }
    .league-card .league-streak-badge { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border-radius: 50%; background: rgba(217, 119, 6, 0.15); border: 2px solid rgba(217, 119, 6, 0.4); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; flex-shrink: 0; font-size: 0.75rem; font-weight: 700; color: #b45309; line-height: 1; }
    .league-card .league-streak-badge .league-streak-badge-flame { font-size: 1.1rem; line-height: 1; }
    .league-card.league-card-has-streak-badge .league-header { padding-right: 52px; }
    body.pussy-power-mode .league-card .league-streak-badge { background: rgba(190, 24, 93, 0.14); border-color: rgba(190, 24, 93, 0.4); color: var(--accent); }
    .widgets-row > div:first-child:empty { display: none; }
    .widgets-row:has(> div:first-child:empty) > div:last-child { flex: 1 1 100%; max-width: none; }
    .league-card .league-header { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; line-height: 1.3; flex-wrap: wrap; }
    .league-card .league-header .league-title { word-break: break-word; }
    .league-card .league-header .league-emoji { font-size: 1.5rem; line-height: 1; flex-shrink: 0; }
    .league-card .league-header .league-emoji-progress { margin-bottom: 0; }
    .league-card .league-icon { width: 26px; height: 26px; flex-shrink: 0; color: var(--league-accent); }
    .league-card .league-meta { margin-bottom: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
    .league-card .league-global-rank { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px 6px 8px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 0.8125rem; color: var(--text); text-decoration: none; font-weight: 500; transition: background 0.15s var(--ease), border-color 0.15s var(--ease), transform 0.15s var(--ease); }
    .league-card .league-global-rank:hover { background: var(--league-soft); border-color: var(--league-accent); transform: translateY(-1px); }
    .league-card .league-global-rank:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .league-card .league-global-rank-icon { font-size: 0.9375rem; line-height: 1; }
    .league-card .league-global-rank-label { color: var(--text-secondary); }
    .league-card .league-global-rank-pos { color: var(--league-accent); font-weight: 700; }
    .league-card .league-global-rank-estimated .league-global-rank-pos { color: var(--text-secondary); font-weight: 600; }
    .league-card .league-global-rank-total { color: var(--text-secondary); font-weight: 500; }
    .league-card .league-global-rank-chevron { color: var(--text-secondary); font-size: 1rem; line-height: 1; margin-left: 2px; transition: transform 0.15s var(--ease); }
    .league-card .league-global-rank:hover .league-global-rank-chevron { transform: translateX(2px); color: var(--league-accent); }
    .league-card .league-emoji-progress { display: flex; align-items: center; justify-content: center; gap: 4px; margin-bottom: 14px; flex-wrap: wrap; }
    .league-card .league-emoji-progress .league-emoji-step { font-size: 1.25rem; line-height: 1; padding: 4px; border-radius: 50%; transition: transform 0.2s var(--ease), background 0.2s var(--ease); opacity: 0.6; }
    .league-card .league-emoji-progress .league-emoji-step.current { opacity: 1; transform: scale(1.25); background: var(--league-soft); }
    .league-card .league-emoji-progress .league-emoji-arrow { font-size: 0.875rem; color: var(--text-secondary); opacity: 0.7; line-height: 1; }
    .league-card .league-time-left { font-size: 0.8125rem; color: var(--text-secondary); margin: 0; padding: 6px 12px; background: var(--league-soft); border-radius: var(--radius-sm); display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
    .league-card .league-time-left .league-time-value { color: var(--league-accent); font-weight: 700; }
    .league-card .league-table { margin: 0; }
    .league-card .league-row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--radius-sm); margin-bottom: 6px; transition: background 0.2s var(--ease); }
    .league-card .league-row:last-child { margin-bottom: 0; }
    .league-card .league-row-me { background: var(--accent-soft); border-left: 3px solid var(--accent); font-weight: 500; }
    .league-card .league-avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--bg); border: 2px solid var(--border); font-size: 1.2rem; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; line-height: 1; }
    .league-card .league-row-me .league-avatar { border-color: var(--accent); background: var(--surface); }
    .league-card .league-rank { min-width: 26px; height: 26px; border-radius: 50%; background: var(--border); color: var(--text-secondary); font-size: 0.8125rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
    .league-card .league-row:first-child .league-rank { background: linear-gradient(135deg, #f59e0b, #d97706); color: #fff; min-width: 28px; height: 28px; font-size: 0.875rem; }
    .league-card .league-row:nth-child(2) .league-rank { background: linear-gradient(135deg, #94a3b8, #64748b); color: #fff; }
    .league-card .league-row:nth-child(3) .league-rank { background: linear-gradient(135deg, #b45309, #92400e); color: #fff; }
    .league-card .league-name { flex: 1; margin: 0; font-size: 0.9375rem; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .league-card .league-row-me .league-name { font-weight: 600; }
    .league-card .league-score { font-size: 1rem; font-weight: 700; color: var(--text); flex-shrink: 0; min-width: 1.5em; text-align: right; }
    .league-card .league-promotion-hint { font-size: 0.8125rem; color: var(--text-secondary); margin: 12px 0 0; line-height: 1.35; }
    .league-card .league-row-promo { background: rgba(34, 197, 94, 0.07); border-left: 3px solid rgba(34, 197, 94, 0.45); }
    .league-card .league-row-danger { background: rgba(239, 68, 68, 0.07); border-left: 3px solid rgba(239, 68, 68, 0.4); }
    .league-card a.league-row-link { color: inherit; text-decoration: none; cursor: pointer; }
    .league-card a.league-row-link:hover { background: var(--bg); }
    .league-card a.league-row-link.league-row-me:hover { background: var(--accent-soft); filter: brightness(0.98); }
    .league-card a.league-row-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .league-card .league-row-me.league-row-promo { background: linear-gradient(135deg, rgba(34, 197, 94, 0.10), var(--accent-soft)); }
    .league-card .league-row-me.league-row-danger { background: linear-gradient(135deg, rgba(239, 68, 68, 0.10), var(--accent-soft)); }
    .league-card .league-zone-label { font-size: 0.6875rem; text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; padding: 3px 0 2px 14px; margin: 8px 0 2px; }
    .league-card .league-zone-label-promo { color: #16a34a; }
    .league-card .league-zone-label-danger { color: #dc2626; }
    .league-card .league-row-collapsed { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; background: transparent; border: 1px dashed var(--border); border-radius: var(--radius-sm); padding: 8px 14px; margin-bottom: 6px; font-family: inherit; font-size: 0.8125rem; font-weight: 500; color: var(--text-secondary); cursor: pointer; transition: background 0.15s var(--ease), color 0.15s var(--ease), border-color 0.15s var(--ease); }
    .league-card .league-row-collapsed:hover { background: var(--bg); color: var(--text); border-color: var(--text-secondary); }
    .league-card .league-row-collapsed:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .league-card .league-row-collapsed .league-collapsed-dots { letter-spacing: 3px; font-weight: 700; opacity: 0.45; }
    .league-card .league-row-collapsed .league-collapsed-chevron { font-size: 0.7rem; opacity: 0.7; }
    .league-card .league-cta-active { margin-top: 14px; }
    .league-card .league-rules-toggle { display: inline-flex; align-items: center; gap: 4px; margin-top: 10px; padding: 0; border: none; background: none; color: var(--text-secondary); font-size: 0.8125rem; font-weight: 500; cursor: pointer; transition: color 0.15s var(--ease); }
    .league-card .league-rules-toggle:hover { color: var(--text); }
    .league-card .league-rules-toggle .league-rules-chevron { transition: transform 0.2s var(--ease); font-size: 0.75rem; }
    .league-card .league-rules-toggle.open .league-rules-chevron { transform: rotate(180deg); }
    .league-card .league-rules-content { max-height: 0; overflow: hidden; transition: max-height 0.3s var(--ease), opacity 0.3s var(--ease); opacity: 0; }
    .league-card .league-rules-content.open { max-height: 300px; opacity: 1; }
    .league-card .league-rules-list { margin: 8px 0 0; padding: 10px 14px; background: var(--bg); border-radius: var(--radius-sm); border: 1px solid var(--border); font-size: 0.8125rem; line-height: 1.55; color: var(--text-secondary); }
    .league-card .league-rules-list .league-rule-row { display: flex; justify-content: space-between; align-items: center; padding: 3px 0; }
    .league-card .league-rules-list .league-rule-row + .league-rule-row { border-top: 1px solid var(--border); }
    .league-card .league-rules-list .league-rule-pts { font-weight: 700; color: var(--league-accent); white-space: nowrap; margin-left: 8px; }
    .league-card .league-rules-list .league-rule-cap { font-size: 0.75rem; color: var(--text-secondary); opacity: 0.7; margin-top: 4px; padding-top: 4px; border-top: 1px dashed var(--border); }
    /* P2: Tier change modal */
    .league-tier-modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 10001; align-items: center; justify-content: center; }
    .league-tier-modal-overlay.visible { display: flex; }
    .league-tier-modal { background: var(--surface); border-radius: var(--radius); padding: 32px 28px; max-width: 360px; width: 92vw; text-align: center; box-shadow: 0 16px 48px rgba(0,0,0,0.2); animation: ltm-in 0.4s var(--ease); }
    @keyframes ltm-in { from { opacity: 0; transform: scale(0.85) translateY(20px); } to { opacity: 1; transform: none; } }
    .league-tier-modal .ltm-emoji { font-size: 3.5rem; margin-bottom: 12px; display: block; }
    .league-tier-modal .ltm-title { font-size: 1.25rem; font-weight: 700; margin: 0 0 8px; }
    .league-tier-modal .ltm-title-up { color: #16a34a; }
    .league-tier-modal .ltm-title-down { color: #dc2626; }
    .league-tier-modal .ltm-body { font-size: 0.9375rem; color: var(--text-secondary); line-height: 1.5; margin: 0 0 8px; }
    .league-tier-modal .ltm-tiers { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 16px 0; font-size: 1.1rem; }
    .league-tier-modal .ltm-tier-from { opacity: 0.5; text-decoration: line-through; }
    .league-tier-modal .ltm-tier-arrow { color: var(--text-secondary); font-size: 1.5rem; }
    .league-tier-modal .ltm-tier-to { font-weight: 700; }
    .league-tier-modal .ltm-btn { margin-top: 20px; }
    .league-tier-modal .ltm-btn .btn-primary { width: 100%; padding: 12px; font-size: 1rem; }
    /* P3: League history timeline */
    .league-history-toggle { display: block; width: 100%; text-align: left; background: none; border: none; font-size: 0.85rem; color: var(--accent); cursor: pointer; padding: 6px 0 0; font-weight: 600; }
    .league-history-toggle .league-rules-chevron { transition: transform 0.2s; display: inline-block; font-size: 0.7em; }
    .league-history-toggle.open .league-rules-chevron { transform: rotate(180deg); }
    .league-history-content { max-height: 0; overflow: hidden; transition: max-height 0.35s var(--ease); }
    .league-history-content.open { max-height: 600px; }
    .league-history-list { padding: 10px 0 4px; }
    .league-history-row { display: flex; align-items: center; gap: 8px; font-size: 0.82rem; padding: 5px 0; border-bottom: 1px solid var(--border); }
    .league-history-row:last-child { border-bottom: none; }
    .league-history-week { color: var(--text-secondary); min-width: 85px; flex-shrink: 0; }
    .league-history-tier { font-weight: 600; min-width: 90px; }
    .league-history-score { color: var(--accent); font-weight: 700; min-width: 40px; text-align: right; }
    .league-history-rank { color: var(--text-secondary); font-size: 0.78rem; min-width: 45px; }
    .league-history-dir { font-size: 0.9rem; min-width: 20px; text-align: center; }
    /* P3: Branch leaderboard tabs */
    .league-branch-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 8px; }
    .league-branch-tab { padding: 4px 10px; font-size: 0.78rem; border-radius: 12px; border: 1px solid var(--border); background: none; color: var(--text-secondary); cursor: pointer; transition: all 0.15s; font-weight: 500; }
    .league-branch-tab:hover { border-color: var(--accent); color: var(--accent); }
    .league-branch-tab.active { background: var(--accent); color: #fff; border-color: var(--accent); }
    .league-branch-board { margin-top: 6px; }
    .league-branch-row { display: flex; align-items: center; gap: 8px; padding: 5px 6px; font-size: 0.85rem; border-radius: 6px; }
    .league-branch-row.is-me { background: var(--accent-soft); font-weight: 600; }
    .league-branch-rank { width: 20px; text-align: center; font-weight: 700; color: var(--text-secondary); }
    .league-branch-name { flex: 1; }
    .league-branch-xp { font-weight: 700; color: var(--accent); }
    .league-branch-empty { font-size: 0.82rem; color: var(--text-secondary); padding: 8px 0; }
    .skill-tree-wrap { margin-bottom: 20px; }
    .skill-tree-wrap .card { border-left: 4px solid var(--accent); }
    .skill-tree-central { padding: 12px 14px; background: var(--accent-soft); border-radius: var(--radius-sm); margin-bottom: 14px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
    .skill-tree-central .skill-tree-central-name { font-weight: 700; font-size: 1rem; color: var(--text); }
    .skill-tree-central .skill-tree-central-level { font-size: 1.25rem; font-weight: 700; color: var(--accent); }
    .skill-tree-branch { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 10px 12px; border-radius: var(--radius-sm); margin-bottom: 6px; border: 1px solid var(--border); }
    .skill-tree-branch.skill-tree-branch-locked { opacity: 0.85; background: var(--bg); }
    .skill-tree-branch-name { font-size: 0.9375rem; font-weight: 500; color: var(--text); }
    .skill-tree-branch-stats { font-size: 0.8125rem; color: var(--text-secondary); }
    .skill-tree-branch-level { font-weight: 700; color: var(--accent); min-width: 1.5em; text-align: right; }
    .skill-tree-upsell { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--border); font-size: 0.8125rem; color: var(--text-secondary); }
    .skill-tree-upsell-item { margin-top: 2px; }
    .skill-tree-upsell-item strong { color: var(--accent); }
    /* Skill tree — radial sectors (compact cabinet version) */
    .st-sector-wrap {
      padding: 16px 0 4px;
      border-radius: var(--radius-sm);
      margin: 0 -4px;
    }
    .st-sector-svg {
      display: block;
      width: 100%;
      max-width: 380px;
      height: auto;
      margin: 0 auto;
      touch-action: manipulation;
    }
    .st-sec-fill { transition: filter .3s var(--ease), opacity .3s var(--ease); }
    .st-sec-fill:hover { filter: brightness(1.15); }
    .st-sec-fill.active { filter: brightness(1.2) drop-shadow(0 0 6px var(--accent)); }
    .st-sec-fill.dim { opacity: .45; }
    .st-sec-hit { cursor: pointer; }
    .st-full-link {
      display: block; text-align: center; margin-top: 10px;
      font-size: .8125rem; color: var(--accent); font-weight: 500;
      text-decoration: none; transition: opacity .2s;
    }
    .st-full-link:hover { opacity: .8; text-decoration: underline; }

    /* Skill tree — compact preview (mobile-style). Заменяет полный круг на
       плотную карточку «основной навык + 3 ветки», полную диаграмму прячет под кнопку. */
    .skill-tree-card { padding: 16px; }
    .stc-compact {
      background: linear-gradient(135deg, var(--accent-soft, rgba(13,148,136,0.08)) 0%, rgba(255,255,255,0.4) 100%);
      border: 1px solid var(--accent-soft, rgba(13,148,136,0.18));
      border-radius: 16px;
      padding: 14px 14px 12px;
      cursor: pointer;
      transition: transform .15s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
      -webkit-user-select: none;
      user-select: none;
    }
    .stc-compact:hover { box-shadow: 0 6px 18px rgba(13,148,136,0.08); border-color: var(--accent); }
    .stc-compact:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .stc-compact.expanded { box-shadow: 0 6px 18px rgba(13,148,136,0.10); }
    .stc-header { display: flex; align-items: center; gap: 10px; }
    .stc-emoji-box {
      width: 40px; height: 40px; flex: 0 0 40px;
      background: var(--accent); color: #fff;
      border-radius: 12px;
      display: flex; align-items: center; justify-content: center;
      font-size: 22px; line-height: 1;
      box-shadow: 0 4px 12px rgba(0,0,0,0.10);
    }
    .stc-title-col { flex: 1; min-width: 0; }
    .stc-eyebrow {
      font-size: 9.5px; letter-spacing: 1.4px; font-weight: 800;
      color: color-mix(in srgb, var(--accent) 65%, transparent);
      text-transform: uppercase;
    }
    .stc-title {
      font-size: 16px; font-weight: 800; letter-spacing: -0.3px;
      color: var(--text); line-height: 1.15; margin-top: 2px;
      white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    }
    .stc-growth-badge {
      display: inline-flex; align-items: center; gap: 3px;
      background: #16a34a; color: #fff;
      padding: 3px 8px; border-radius: 99px;
      font-size: 10.5px; font-weight: 800; letter-spacing: -0.1px;
      box-shadow: 0 3px 10px rgba(22,163,74,0.35);
      flex: 0 0 auto;
    }
    .stc-level-row {
      display: flex; align-items: baseline; gap: 6px;
      margin-top: 14px;
    }
    .stc-level-label {
      font-size: 12px; font-weight: 700;
      color: color-mix(in srgb, var(--accent) 70%, transparent);
    }
    .stc-level-num {
      font-size: 30px; font-weight: 800; letter-spacing: -1.2px;
      color: var(--accent); line-height: 1; margin-left: 2px;
    }
    .stc-level-max {
      font-size: 14px; font-weight: 700;
      color: color-mix(in srgb, var(--accent) 40%, transparent);
    }
    .stc-level-pct {
      margin-left: auto; font-size: 13px; font-weight: 800; color: var(--accent);
    }
    .stc-progress-bar {
      height: 7px; margin-top: 6px;
      background: color-mix(in srgb, var(--accent) 12%, transparent);
      border-radius: 99px; overflow: hidden;
    }
    .stc-progress-fill {
      height: 100%; background: var(--accent);
      border-radius: 99px;
      transition: width .6s var(--ease);
    }
    .stc-mini-label { margin-top: 14px; margin-bottom: 8px; }
    .stc-mini-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 8px; }
    .stc-mini-card {
      background: rgba(255,255,255,0.78);
      border: 1px solid transparent;
      border-radius: 12px;
      padding: 8px;
      cursor: pointer;
      transition: transform .15s var(--ease), box-shadow .2s var(--ease), border-color .2s var(--ease);
      min-width: 0;
    }
    .stc-mini-card:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(0,0,0,0.06); }
    .stc-mini-card:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .stc-mini-card.leveled {
      border-color: rgba(245,158,11,0.6);
      box-shadow: 0 4px 14px rgba(245,158,11,0.25);
    }
    .stc-mini-card.grew { border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
    .stc-mini-card.locked { opacity: .55; }
    .stc-mini-top { display: flex; align-items: center; gap: 4px; }
    .stc-mini-emoji { font-size: 18px; line-height: 1; }
    .stc-mini-lv {
      margin-left: auto;
      font-size: 11px; font-weight: 800; color: var(--accent);
    }
    .stc-mini-card.locked .stc-mini-lv { color: rgba(0,0,0,0.4); }
    .stc-mini-name {
      font-size: 11.5px; font-weight: 600;
      color: rgba(0,0,0,0.85); letter-spacing: -0.1px;
      margin-top: 4px; line-height: 1.15;
      white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    }
    .stc-mini-card.locked .stc-mini-name { color: rgba(0,0,0,0.45); }
    .stc-mini-bar {
      height: 4px; margin-top: 6px;
      background: rgba(0,0,0,0.06); border-radius: 99px; overflow: hidden;
    }
    .stc-mini-bar-fill {
      height: 100%; background: var(--accent);
      border-radius: 99px;
      transition: width .6s var(--ease);
    }
    .stc-mini-card.locked .stc-mini-bar-fill { background: #94a3b8; }
    .stc-expand-btn {
      display: flex; align-items: center; justify-content: center; gap: 6px;
      width: 100%; margin-top: 12px;
      background: none; border: none;
      color: var(--text-secondary);
      font-size: 13px; font-weight: 600; font-family: inherit;
      padding: 8px 12px; border-radius: 8px;
      cursor: pointer;
      transition: background .15s var(--ease), color .15s var(--ease);
    }
    .stc-expand-btn:hover { background: rgba(0,0,0,0.04); color: var(--accent); }
    .stc-expand-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .stc-expand-arrow { font-size: 14px; line-height: 1; transition: transform .2s var(--ease); }
    .stc-details-pane.collapsed { display: none; }
    /* Legacy spider compat — kept for remaining CSS refs */
    .skill-tree-spider-wrap {
      padding: 24px 0;
      background: linear-gradient(180deg, rgba(255,255,255,0.6) 0%, transparent 100%);
      border-radius: var(--radius-sm);
      margin: 0 -4px;
      overflow: visible;
    }
    .skill-tree-spider-svg {
      display: block;
      width: 100%;
      max-width: 440px;
      height: auto;
      margin: 0 auto;
      touch-action: manipulation;
      filter: drop-shadow(0 2px 12px rgba(13, 148, 136, 0.06));
      overflow: visible;
    }
    .skill-tree-spider-svg .spider-ray {
      stroke: #e2e8f0;
      stroke-width: 1.5;
      transition: stroke 0.25s var(--ease), opacity 0.25s var(--ease);
    }
    .skill-tree-spider-svg .spider-ray.active {
      stroke: var(--accent);
      stroke-width: 2;
      opacity: 0.92;
    }
    .skill-tree-spider-svg .spider-ray.dim {
      stroke: #cbd5e1;
      opacity: 0.6;
    }
    .skill-tree-spider-svg .spider-node {
      cursor: pointer;
      transform-origin: center;
    }
    .skill-tree-spider-svg .spider-node:focus { outline: none; }
    .skill-tree-spider-svg .spider-node .spider-node-circle {
      fill: url(#skill-tree-node-gradient);
      stroke: #e2e8f0;
      stroke-width: 2;
      transition: fill 0.2s var(--ease), stroke 0.2s var(--ease), stroke-width 0.2s var(--ease), filter 0.2s var(--ease);
    }
    /* Активные (можно прокачивать) узлы — выделяем цветом; при затемнении (.dim) сохраняем лёгкий акцент */
    .skill-tree-spider-svg .spider-node:not(.locked) .spider-node-circle {
      stroke: rgba(13, 148, 136, 0.6);
      stroke-width: 2.5;
      filter: drop-shadow(0 1px 4px rgba(13, 148, 136, 0.15));
    }
    .skill-tree-spider-svg .spider-node:hover .spider-node-circle {
      fill: #fff;
      stroke: var(--accent);
      stroke-width: 2.5;
    }
    .skill-tree-spider-svg .spider-node.active .spider-node-circle {
      fill: #fff;
      stroke: var(--accent);
      stroke-width: 2.5;
      filter: drop-shadow(0 2px 6px rgba(13, 148, 136, 0.15));
    }
    .skill-tree-spider-svg .spider-node.pressed .spider-node-circle {
      opacity: 0.92;
    }
    .skill-tree-spider-svg .spider-node.locked .spider-node-circle {
      fill: #f1f5f9;
      stroke: #cbd5e1;
    }
    .skill-tree-spider-svg .spider-node.dim .spider-node-circle {
      fill: #f8fafc;
      stroke: #e2e8f0;
      opacity: 0.88;
    }
    .skill-tree-spider-svg .spider-node.dim:not(.locked) .spider-node-circle {
      stroke: rgba(13, 148, 136, 0.42);
      filter: drop-shadow(0 1px 3px rgba(13, 148, 136, 0.1));
    }
    .skill-tree-spider-svg .spider-ring-bg,
    .skill-tree-spider-svg .spider-ring-fill {
      fill: none;
      stroke-width: 5;
      stroke-linecap: round;
      transition: stroke-dasharray 2s cubic-bezier(0.33, 1, 0.68, 1), stroke 0.25s var(--ease), opacity 0.25s var(--ease);
    }
    .skill-tree-spider-svg .spider-ring-bg { stroke: #e2e8f0; opacity: 0.6; }
    .skill-tree-spider-svg .spider-ring-fill { stroke: var(--skill-ring-level); opacity: 0.92; }
    @keyframes spider-locked-idle {
      0%, 100% { opacity: 0.5; }
      50% { opacity: 0.32; }
    }
    .skill-tree-spider-svg .spider-node.locked .spider-ring-bg {
      stroke: #cbd5e1;
      opacity: 0.5;
      animation: spider-locked-idle 2.2s ease-in-out infinite;
    }
    .skill-tree-spider-svg .spider-node.locked .spider-ring-outer-bg {
      animation: spider-locked-idle 2.2s ease-in-out infinite;
    }
    .skill-tree-spider-svg .spider-node.locked .spider-ring-fill,
    .skill-tree-spider-svg .spider-node.locked .spider-ring-outer-fill { stroke: #94a3b8; opacity: 0.4; }
    .skill-tree-spider-svg .spider-node.active .spider-ring-fill { stroke: var(--skill-ring-level); opacity: 1; }
    .skill-tree-spider-svg .spider-ring-outer-bg,
    .skill-tree-spider-svg .spider-ring-outer-fill {
      fill: none;
      stroke-width: 3;
      stroke-linecap: round;
      transition: stroke-dasharray 2s cubic-bezier(0.33, 1, 0.68, 1), stroke 0.25s var(--ease), opacity 0.25s var(--ease);
    }
    .skill-tree-spider-svg .spider-ring-outer-bg { stroke: #e2e8f0; opacity: 0.5; }
    .skill-tree-spider-svg .spider-ring-outer-fill { stroke: var(--skill-ring-xp); opacity: 0.9; }
    .skill-tree-spider-svg .spider-node.locked .spider-ring-outer-fill { stroke: #94a3b8; opacity: 0.5; }
    .skill-tree-spider-svg .spider-node.active .spider-ring-outer-fill { stroke: var(--skill-ring-xp); opacity: 1; }
    .skill-tree-spider-svg .spider-node.dim .spider-ring-outer-fill { stroke: #94a3b8; opacity: 0.6; }
    .skill-tree-spider-svg .spider-node.dim .spider-ray { stroke: #cbd5e1; opacity: 0.6; }
    .skill-tree-spider-svg .spider-node.dim .spider-ring-fill { stroke: #94a3b8; opacity: 0.6; }
    .skill-tree-spider-svg .spider-node.dim .spider-node-label { opacity: 0.65; fill: var(--text-secondary); }
    .skill-tree-spider-svg .spider-node .spider-node-emoji {
      font-size: 24px;
      font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
      fill: var(--text);
      pointer-events: none;
    }
    .skill-tree-spider-svg .spider-node.active .spider-node-emoji { fill: var(--accent); }
    .skill-tree-spider-svg .spider-node.dim .spider-node-emoji { opacity: 0.7; fill: var(--text-secondary); }
    .skill-tree-spider-svg .spider-node text.spider-node-lv {
      font-family: inherit;
      font-weight: 700;
      fill: var(--text);
      font-size: 14px;
      text-anchor: middle;
      dominant-baseline: central;
      pointer-events: none;
      letter-spacing: -0.02em;
    }
    .skill-tree-spider-svg .spider-node.locked text.spider-node-lv { fill: #64748b; }
    .skill-tree-spider-svg .spider-node.active text.spider-node-lv { fill: var(--accent); }
    .skill-tree-spider-svg .spider-node text.spider-node-xp {
      font-size: 9px;
      font-weight: 500;
      fill: var(--text-secondary);
      text-anchor: middle;
      dominant-baseline: central;
      pointer-events: none;
    }
    .skill-tree-spider-svg .spider-node.active text.spider-node-xp { fill: var(--accent); opacity: 0.9; }
    .skill-tree-spider-svg .spider-node .spider-node-label {
      font-size: 9px;
      font-weight: 600;
      fill: var(--text-secondary);
      opacity: 0;
      transition: opacity 0.25s var(--ease);
      letter-spacing: 0.02em;
    }
    .skill-tree-spider-svg .spider-node.active .spider-node-label { opacity: 1; fill: var(--accent); }
    .skill-tree-spider-svg .spider-node.locked .spider-node-lock { opacity: 1; }
    .skill-tree-spider-svg .spider-node .spider-node-lock {
      font-size: 10px; opacity: 0; pointer-events: none;
      font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
    }
    .skill-tree-spider-svg .spider-node.locked.recommended .spider-node-circle {
      filter: drop-shadow(0 0 6px rgba(13, 148, 136, 0.5)); stroke: var(--accent); stroke-width: 2;
    }
    .skill-tree-spider-svg .spider-node.locked.recommended .spider-ring-fill { stroke: var(--accent); opacity: 0.75; }
    /* На фронте скрыты подписи «Диагностика» и «Психология» */
    .skill-tree-spider-svg .spider-node[data-node-id="diagnostics"] .spider-node-label,
    .skill-tree-spider-svg .spider-node[data-node-id="mental_health"] .spider-node-label { display: none; }
    .skill-tree-spider-svg .spider-center .spider-center-bg {
      stroke: rgba(255, 255, 255, 0.28);
      stroke-width: 2.5;
      transition: stroke 0.2s var(--ease), stroke-width 0.2s var(--ease);
    }
    .skill-tree-spider-svg .spider-center:hover .spider-center-bg {
      stroke: rgba(255, 255, 255, 0.5);
      stroke-width: 3;
    }
    .skill-tree-spider-svg .spider-center text {
      fill: #fff;
      font-weight: 700;
      text-anchor: middle;
      pointer-events: none;
      letter-spacing: -0.02em;
    }
    .skill-tree-spider-svg .spider-center .spider-center-emoji {
      font-size: 26px;
      font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
      fill: rgba(255,255,255,0.95);
      pointer-events: none;
    }
    .skill-tree-spider-svg .spider-center .spider-center-sub {
      font-size: 11px;
      font-weight: 600;
      fill: rgba(255,255,255,0.95);
      letter-spacing: 0.02em;
    }
    .skill-tree-spider-svg .spider-center .spider-center-lv {
      font-size: 12px;
      font-weight: 700;
    }
    .skill-tree-spider-svg .spider-center .spider-center-xp {
      font-size: 10px;
      font-weight: 500;
      fill: rgba(255,255,255,0.85);
    }
    .skill-tree-spider-callout {
      display: none;
      align-items: center;
      justify-content: center;
      gap: 6px;
      margin-top: 10px;
      padding: 8px 14px;
      background: var(--accent);
      color: #fff;
      border-radius: var(--radius-sm);
      font-size: 0.875rem;
      font-weight: 600;
      max-width: 280px;
      margin-left: auto;
      margin-right: auto;
      box-shadow: 0 2px 12px rgba(13, 148, 136, 0.25);
    }
    .skill-tree-spider-callout.visible { display: flex; }
    .skill-tree-spider-callout .callout-arrow { opacity: 0.9; font-size: 0.75rem; }
    .skill-tree-spider-boost { margin-top: 8px; padding: 10px 0 0; border-top: 1px solid var(--border); font-size: 0.875rem; color: var(--text); }
    .skill-tree-spider-boost.visible { display: block; }
    .skill-tree-spider-boost:not(.visible) { display: none; }
    .skill-tree-spider-boost-title { font-weight: 600; margin-bottom: 6px; color: var(--text); }
    .skill-tree-spider-boost-list { margin: 0; padding-left: 18px; line-height: 1.5; }
    .skill-tree-spider-boost-list li { margin-bottom: 2px; }
    .skill-tree-spider-boost-list li.locked { color: var(--text-secondary); }
    .skill-tree-spider-boost-list.skill-tree-step-list li { color: var(--text); }
    .skill-tree-spider-boost-list.skill-tree-step-list a { color: var(--text); font-weight: 600; text-decoration: none; }
    .skill-tree-spider-boost-list.skill-tree-step-list a:hover { text-decoration: underline; }
    .skill-tree-step-reason { display: block; margin-top: 2px; padding-left: 0; font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.4; }
    .skill-tree-spider-legend { font-size: 0.8125rem; color: var(--text-secondary); text-align: center; margin-top: 10px; line-height: 1.4; }
    body.skill-tree-sheet-open { overflow: hidden; }
    .skill-tree-sheet-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 9000; display: none; align-items: flex-end; justify-content: center; opacity: 0; visibility: hidden; transition: opacity 0.22s var(--ease), visibility 0.22s var(--ease); }
    .skill-tree-sheet-overlay.visible { display: flex; opacity: 1; visibility: visible; }
    .skill-tree-sheet { background: var(--surface); border-radius: var(--radius) var(--radius) 0 0; max-height: 85vh; width: 100%; max-width: 560px; display: flex; flex-direction: column; box-shadow: 0 -4px 24px rgba(0,0,0,0.12); transform: translateY(100%); transition: transform 0.25s var(--ease); }
    .skill-tree-sheet.visible { transform: translateY(0); }
    .skill-tree-sheet-header { flex-shrink: 0; display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--border); }
    .skill-tree-sheet-title { margin: 0; font-size: 1.125rem; font-weight: 600; color: var(--text); }
    .skill-tree-sheet-close { width: 40px; height: 40px; border: none; background: transparent; font-size: 1.5rem; color: var(--text-secondary); cursor: pointer; border-radius: var(--radius-sm); line-height: 1; padding: 0; }
    .skill-tree-sheet-close:hover { background: var(--bg); color: var(--text); }
    .skill-tree-sheet-body { flex: 1; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: 16px 20px; }
    .skill-tree-sheet-body:focus { outline: none; }
    .skill-tree-sheet-p { margin: 0 0 12px; font-size: 0.9375rem; color: var(--text); }
    .skill-tree-sheet-weak { margin: 0 0 8px; font-size: 0.875rem; color: var(--text-secondary); }
    .skill-tree-sheet-actions { margin-top: 12px; }
    .skill-tree-sheet-upsell { margin: 12px 0 4px; font-size: 0.875rem; color: var(--text-secondary); }
    .skill-tree-sheet-upsell-link { display: block; margin: 4px 0; font-size: 0.875rem; color: var(--accent); }
    .skill-tree-cta-wrap { margin-top: 12px; }
    .skill-tree-empty-ctas { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
    .skill-tree-empty-ctas p { margin: 0 0 10px; }
    .skill-tree-empty-ctas .btn-primary { display: inline-block; margin-bottom: 8px; }
    .skill-tree-empty-ctas .btn-secondary { display: inline-block; }
    .skill-tree-sheet-more { margin-top: 16px; border-top: 1px solid var(--border); padding-top: 12px; }
    .skill-tree-sheet-subject { padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 0.9375rem; }
    .skill-tree-sheet-subject.locked { color: var(--text-secondary); }
    .skill-tree-sheet-hint { margin: 4px 0 0; font-size: 0.875rem; color: var(--accent); font-weight: 500; }
    .skill-tree-sheet-value-line { margin: 0 0 12px; font-size: 0.9375rem; color: var(--text-secondary); }
    .skill-tree-sheet-cta-hint { margin: 6px 0 0; font-size: 0.8125rem; color: var(--text-secondary); }
    .skill-tree-recommended-wrap { margin-bottom: 14px; padding: 12px 14px; background: var(--accent-soft); border-radius: var(--radius-sm); border-left: 4px solid var(--accent); }
    .skill-tree-recommended-title { margin: 0 0 10px; font-size: 0.875rem; font-weight: 600; color: var(--text); }
    .skill-tree-step-study { margin: 0 0 10px; font-size: 0.875rem; color: var(--text); }
    .skill-tree-step-study .skill-tree-recommended-name { font-weight: 600; color: var(--accent); text-decoration: none; }
    .skill-tree-step-study .skill-tree-recommended-name:hover { text-decoration: underline; }
    .skill-tree-recommended-item { margin-bottom: 12px; font-size: 0.875rem; }
    .skill-tree-recommended-item:last-child { margin-bottom: 0; }
    .skill-tree-recommended-name { font-weight: 600; color: var(--accent); }
    .skill-tree-recommended-reason { margin: 4px 0 0; padding-left: 14px; font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.4; }
    .skill-tree-recommended-forecast { margin: 2px 0 0; padding-left: 14px; font-size: 0.8125rem; color: var(--accent); font-weight: 500; }
    .skill-tree-recommended-item:hover { opacity: 0.9; }
    .skill-tree-spider-boost .skill-tree-recommended-item { margin-top: 8px; }
    .skill-tree-spider-boost .skill-tree-recommended-item:first-of-type { margin-top: 4px; }
    @media (max-width: 640px) {
      body { padding: 20px 16px; padding-left: max(16px, env(safe-area-inset-left)); padding-right: max(16px, env(safe-area-inset-right)); overflow-x: hidden; }
      .container { max-width: 100%; overflow-x: hidden; }
      .card { padding: 18px 16px; margin-bottom: 16px; }
      .card h2 { font-size: 1.0625rem; margin-bottom: 12px; }
      .btn-primary { min-height: 48px; }
      .link-row { gap: 6px; }
      .link-row a { white-space: normal; }
      .progress-item { gap: 12px; align-items: flex-start; }
      .progress-item-left { padding-right: 4px; }
      /* На узком экране: Практика и Клиника вертикально и чуть мельче */
      .progress-item-circles { flex-direction: column; gap: 6px; flex-shrink: 0; align-items: flex-start; }
      .progress-circle-svg { width: 34px; height: 34px; }
      .progress-circle-wrap .progress-circle-label { font-size: 0.5625rem; }
      .progress-bar-wrap { min-width: 0; }
      .help-block { margin-top: 20px; padding-top: 16px; padding-left: 0; padding-right: 0; }
      .all-catalog-subject-body .progress-item-left p { word-break: break-word; overflow-wrap: break-word; }
      .card-all-catalog { padding: 18px 16px; }
      .all-catalog-subject-body .progress-item.locked .progress-circle-wrap .progress-circle-svg { width: 30px; height: 30px; }
      .all-catalog-subject-body .progress-item.locked .progress-circle-label { font-size: 0.5625rem; }
      .all-catalog-subject-emoji { width: 32px; height: 32px; font-size: 1.1rem; border-radius: 8px; }
      .all-catalog-subject-header { gap: 10px; padding: 14px 14px; }
      .all-catalog-subject-benefit { padding-left: 42px; font-size: 0.75rem; }
      .all-catalog-subject-price { font-size: 0.75rem; padding: 3px 8px; }
      .all-catalog-subject-meta { gap: 4px 10px; font-size: 0.75rem; }
      .recommended-premium { padding: 14px; }
      .recommended-premium-cta { padding: 10px 16px; font-size: 0.8125rem; width: 100%; justify-content: center; }
    }
    /* Очень маленькие экраны (бюджетные Android ~320px) */
    @media (max-width: 360px) {
      body { padding: 14px 10px; }
      .container { max-width: 100%; }
      .card { padding: 14px 12px; margin-bottom: 12px; }
      .card h2 { font-size: 1rem; }
      .cabinet-header { gap: 6px; margin-bottom: 12px; }
      .cabinet-title { font-size: 1rem; }
      .cabinet-avatar { width: 38px; height: 38px; font-size: 1.25rem; }
      .cabinet-avatar-wrap { gap: 8px; }
      .cabinet-header-actions { gap: 3px; }
      .cabinet-edit-btn { width: 32px; height: 32px; }
      .cabinet-header-actions .btn-secondary { padding: 6px 8px; font-size: 0.75rem; }
      .all-catalog-subject-header { gap: 8px; padding: 12px 10px; font-size: 0.9375rem; }
      .all-catalog-subject-emoji { width: 28px; height: 28px; font-size: 1rem; border-radius: 7px; }
      .all-catalog-subject-name { font-size: 0.9375rem; word-break: break-word; overflow-wrap: break-word; }
      .all-catalog-subject-meta { gap: 3px 8px; font-size: 0.6875rem; }
      .all-catalog-subject-price { font-size: 0.6875rem; padding: 2px 6px; }
      .all-catalog-subject-benefit { padding-left: 38px; font-size: 0.6875rem; }
      .all-catalog-subject-body { padding: 0 10px 12px; }
      .card-all-catalog { padding: 14px 10px; }
      .entitlements-row { gap: 8px; padding: 10px 0; }
      .entitlements-row-name { font-size: 0.875rem; }
      .subs-row { gap: 6px 8px; padding: 12px 0; }
      .subs-row-name { font-size: 0.875rem; min-width: 100px; }
      .subs-row-actions .btn-secondary,
      .subs-row-actions .btn-primary { flex: 1 1 auto; text-align: center; }
      .btn-primary { padding: 12px 16px; font-size: 0.9375rem; }
      .widgets-row { gap: 10px; }
      .header h1 { font-size: 1.25rem; }
      .header p { font-size: 0.875rem; }
    }
    /* Bug report: selection popup and modal */
    .bug-report-popup { display: none; position: fixed; z-index: 9999; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow-card); padding: 6px 0; min-width: 180px; }
    .bug-report-popup.visible { display: block; }
    .bug-report-popup button { display: block; width: 100%; padding: 10px 16px; border: none; background: none; font-size: 0.9375rem; font-family: inherit; color: var(--text); text-align: left; cursor: pointer; }
    .bug-report-popup button:hover { background: var(--accent-soft); color: var(--accent); }
    .bug-report-modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.4); z-index: 10000; align-items: center; justify-content: center; padding: 24px; box-sizing: border-box; }
    .bug-report-modal-overlay.visible { display: flex; }
    .bug-report-modal { background: var(--surface); border-radius: var(--radius); padding: 24px; max-width: 480px; width: 100%; max-height: 90vh; overflow: auto; box-shadow: 0 8px 32px rgba(0,0,0,0.15); }
    .bug-report-modal h3 { margin: 0 0 16px; font-size: 1.125rem; }
    .bug-report-modal .field { margin-bottom: 16px; }
    .bug-report-modal .field label { display: block; font-size: 0.875rem; font-weight: 500; margin-bottom: 6px; color: var(--text-secondary); }
    .bug-report-modal .field .readonly { font-size: 0.875rem; padding: 10px; background: var(--bg); border-radius: var(--radius-sm); border: 1px solid var(--border); max-height: 80px; overflow-y: auto; white-space: pre-wrap; word-break: break-word; }
    .bug-report-modal .field textarea { width: 100%; min-height: 100px; padding: 10px; border-radius: var(--radius-sm); border: 1px solid var(--border); font-size: 0.9375rem; font-family: inherit; resize: vertical; box-sizing: border-box; }
    .bug-report-modal .screenshot-zone { margin-bottom: 16px; padding: 12px; border: 1px dashed var(--border); border-radius: var(--radius-sm); background: var(--bg); font-size: 0.8125rem; color: var(--text-secondary); }
    .bug-report-modal .screenshot-zone .hint { margin-bottom: 8px; }
    .bug-report-modal .screenshot-preview-wrap { position: relative; display: inline-block; margin-top: 8px; }
    .bug-report-modal .screenshot-preview { max-width: 100%; max-height: 120px; border-radius: var(--radius-sm); display: block; }
    .bug-report-modal .screenshot-remove { position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border: none; border-radius: 50%; background: rgba(0,0,0,0.6); color: #fff; font-size: 18px; line-height: 1; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; }
    .bug-report-modal .screenshot-remove:hover { background: rgba(0,0,0,0.85); }
    .bug-report-modal .actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 20px; }
    .bug-report-modal .actions button { padding: 10px 20px; border-radius: var(--radius-sm); font-size: 0.9375rem; font-weight: 600; font-family: inherit; cursor: pointer; }
    .bug-report-modal .actions .btn-cancel { border: 1px solid var(--border); background: var(--surface); color: var(--text); }
    .bug-report-modal .actions .btn-submit { border: none; background: var(--accent); color: #fff; }
    .bug-report-modal .actions .btn-submit:hover { background: var(--accent-hover); }
    .bug-report-modal .actions .btn-submit:disabled { opacity: 0.6; cursor: not-allowed; }
    /* iOS-style push notifications stack */
    .pending-notifs-wrap { position: relative; margin-bottom: 26px; }
    .pending-notifs-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; padding: 0 4px; }
    .pending-notifs-count { font-size: 0.75rem; color: var(--text-secondary); font-weight: 600; letter-spacing: 0.01em; }
    .pending-notifs-dismiss-all { background: none; border: none; color: var(--text-secondary); font-size: 0.75rem; font-weight: 500; cursor: pointer; padding: 4px 10px; border-radius: 999px; transition: background 0.15s, color 0.15s; font-family: inherit; }
    .pending-notifs-dismiss-all:hover { background: rgba(239,68,68,0.08); color: rgba(220,38,38,0.9); }
    .pending-notifs-stack { position: relative; display: flex; flex-direction: column; gap: 10px; }
    /* Свёрнутая стопка: верхняя карточка в потоке задаёт высоту, остальные подглядывают снизу. */
    .pending-notifs-stack.collapsed { display: block; position: relative; }
    .pending-notifs-stack.collapsed .pending-notif { transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1), opacity 0.35s; }
    .pending-notifs-stack.collapsed .pending-notif:nth-child(1) { position: relative; z-index: 3; }
    .pending-notifs-stack.collapsed .pending-notif:nth-child(n+2) { position: absolute; left: 0; right: 0; top: 0; height: 100%; overflow: hidden; }
    .pending-notifs-stack.collapsed .pending-notif:nth-child(2) { transform: translateY(8px) scale(0.97); z-index: 2; opacity: 0.85; }
    .pending-notifs-stack.collapsed .pending-notif:nth-child(3) { transform: translateY(16px) scale(0.94); z-index: 1; opacity: 0.6; }
    .pending-notifs-stack.collapsed .pending-notif:nth-child(n+4) { transform: translateY(16px) scale(0.94); z-index: 0; opacity: 0; pointer-events: none; }

    .pending-notif {
      position: relative;
      display: grid;
      grid-template-columns: 38px 1fr auto;
      grid-template-rows: auto auto auto;
      grid-template-areas: "icon title time" "icon body body" "icon action action";
      column-gap: 12px;
      row-gap: 2px;
      padding: 12px 14px;
      background: rgba(255,255,255,0.72);
      -webkit-backdrop-filter: blur(22px) saturate(1.6);
      backdrop-filter: blur(22px) saturate(1.6);
      border: 1px solid rgba(255,255,255,0.6);
      border-radius: 18px;
      box-shadow: 0 1px 2px rgba(15,23,42,0.04), 0 8px 24px -8px rgba(15,23,42,0.12);
      animation: pending-notif-in 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
    }
    .pending-notif.leaving { animation: pending-notif-out 0.28s cubic-bezier(0.4, 0, 1, 1) forwards; }
    @keyframes pending-notif-in { from { opacity: 0; transform: translateY(-6px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
    @keyframes pending-notif-out { to { opacity: 0; transform: translateX(40px) scale(0.96); } }

    .pending-notif-icon { grid-area: icon; width: 38px; height: 38px; border-radius: 10px; background: linear-gradient(135deg, var(--accent) 0%, #0f766e 100%); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 1.1rem; box-shadow: 0 2px 6px rgba(13,148,136,0.3); flex-shrink: 0; }
    .pending-notif-title { grid-area: title; font-weight: 600; font-size: 0.9375rem; margin: 0; color: var(--text); letter-spacing: -0.01em; line-height: 1.3; display: flex; align-items: flex-start; gap: 6px; min-width: 0; padding-right: 18px; }
    .pending-notif-title-text { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
    .pending-notif-count { font-size: 0.6875rem; font-weight: 600; background: rgba(13,148,136,0.14); color: var(--accent); padding: 2px 7px; border-radius: 999px; letter-spacing: 0.02em; flex-shrink: 0; margin-top: 1px; }
    .pending-notif-time { grid-area: time; font-size: 0.75rem; color: var(--text-secondary); align-self: start; white-space: nowrap; padding-top: 2px; padding-right: 22px; }
    .pending-notif-body { grid-area: body; font-size: 0.8125rem; color: var(--text-secondary); margin: 4px 0 0; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
    .pending-notif-action { grid-area: action; margin-top: 10px; display: flex; flex-wrap: wrap; gap: 8px; }
    .pending-notif-action a {
      display: inline-flex; align-items: center; gap: 4px;
      font-size: 0.8125rem; font-weight: 600;
      color: var(--accent); text-decoration: none;
      padding: 6px 12px; border-radius: 999px;
      background: rgba(13,148,136,0.08);
      transition: background 0.15s;
    }
    .pending-notif-action a:hover { background: rgba(13,148,136,0.14); }
    .pending-notif-action a::after { content: "›"; font-size: 1rem; line-height: 1; }
    .pending-notif-action a.pending-notif-action-secondary {
      color: var(--text-secondary); background: transparent;
      border: 1px solid rgba(15,23,42,0.12); font-weight: 500;
    }
    .pending-notif-action a.pending-notif-action-secondary:hover { background: rgba(15,23,42,0.04); }
    .pending-notif-action a.pending-notif-action-secondary::after { content: ""; }

    .pending-notif-dismiss {
      position: absolute; top: 8px; right: 8px;
      width: 22px; height: 22px;
      background: rgba(15,23,42,0.06); border: none;
      border-radius: 50%;
      font-size: 0.875rem; line-height: 1;
      color: var(--text-secondary);
      cursor: pointer; padding: 0;
      display: flex; align-items: center; justify-content: center;
      opacity: 0; transition: opacity 0.15s, background 0.15s, color 0.15s;
    }
    .pending-notif:hover .pending-notif-dismiss,
    .pending-notif:focus-within .pending-notif-dismiss { opacity: 1; }
    @media (hover: none) { .pending-notif-dismiss { opacity: 1; } }
    .pending-notif-dismiss:hover { background: rgba(239,68,68,0.14); color: rgba(220,38,38,0.9); }

    body.pussy-power .pending-notif-icon { background: linear-gradient(135deg, #db2777 0%, #9d174d 100%); box-shadow: 0 2px 6px rgba(219,39,119,0.3); }
    body.pussy-power .pending-notif-count { background: rgba(219,39,119,0.14); color: #db2777; }
    body.pussy-power .pending-notif-action a { color: #db2777; background: rgba(219,39,119,0.08); }
    body.pussy-power .pending-notif-action a:hover { background: rgba(219,39,119,0.14); }
    .skip-link { position: absolute; top: -40px; left: 0; background: var(--accent); color: #fff; padding: 8px 16px; z-index: 100000; font-size: 0.875rem; border-radius: 0 0 8px 0; transition: top 0.2s; text-decoration: none; }
    .skip-link:focus { top: 0; }

    /* Липкая полоса внутри .container: без отрицательных margin — иначе на широком экране ряд табов «уезжает» на всю ширину окна и даёт горизонтальный скролл страницы */
    .cabinet-nav-sticky-wrap { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 200; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; margin: 0; padding: 0; pointer-events: none; }
    .cabinet-nav-sticky-wrap .cabinet-nav { pointer-events: auto; }
    .cabinet-nav { position: relative; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; background: rgba(240,244,248,0.82); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid rgba(0,0,0,0.05); display: none; transition: box-shadow 0.2s; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; overscroll-behavior-x: contain; }
    .cabinet-nav::-webkit-scrollbar { display: none; }
    .cabinet-nav.scrolled { box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
    /* Затухание по краям — намёк, что бар прокручивается (mask по видимой ширине скроллера). */
    .cabinet-nav.is-fade-left.is-fade-right { -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%); mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 24px), transparent 100%); }
    .cabinet-nav.is-fade-left:not(.is-fade-right) { -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px); mask-image: linear-gradient(90deg, transparent 0, #000 24px); }
    .cabinet-nav.is-fade-right:not(.is-fade-left) { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent 100%); mask-image: linear-gradient(90deg, #000 calc(100% - 24px), transparent 100%); }
    .cabinet-nav-inner { display: flex; gap: 6px; padding: 10px 14px; width: max-content; min-width: min-content; flex-shrink: 0; }
    .cabinet-nav-tab { flex-shrink: 0; padding: 6px 14px; border-radius: 20px; font-size: 0.8125rem; font-weight: 500; color: var(--text-secondary); background: transparent; border: 1.5px solid transparent; cursor: pointer; transition: background 0.18s ease, color 0.18s ease; white-space: nowrap; line-height: 1.3; font-family: inherit; }
    .cabinet-nav-tab:hover { background: rgba(13,148,136,0.07); color: var(--text); }
    .cabinet-nav-tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
    .cabinet-nav-tab.active { background: var(--accent-soft, rgba(13,148,136,0.12)); color: var(--accent); border-color: transparent; box-shadow: none; font-weight: 600; }
    /* Меню «Ещё» */
    .cabinet-nav-more { display: inline-flex; align-items: center; gap: 4px; }
    .cabinet-nav-more-caret { font-size: 0.7em; opacity: 0.55; transition: transform 0.18s ease; }
    .cabinet-nav-more[aria-expanded="true"] .cabinet-nav-more-caret { transform: rotate(180deg); }
    .cabinet-nav-more-menu { position: absolute; top: calc(100% + 6px); right: 12px; z-index: 210; min-width: 184px; max-height: 62vh; overflow-y: auto; -webkit-overflow-scrolling: touch; background: var(--surface, #fff); border: 1px solid rgba(0,0,0,0.07); border-radius: 14px; box-shadow: 0 12px 32px rgba(0,0,0,0.14); padding: 6px; display: none; pointer-events: auto; }
    .cabinet-nav-more-menu.open { display: block; animation: cabNavMenuIn 0.16s ease; }
    @keyframes cabNavMenuIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
    .cabinet-nav-more-item { display: block; width: 100%; text-align: left; padding: 9px 12px; border: 0; background: transparent; border-radius: 9px; font-size: 0.875rem; font-weight: 500; color: var(--text); cursor: pointer; font-family: inherit; white-space: nowrap; }
    .cabinet-nav-more-item:hover { background: rgba(13,148,136,0.08); color: var(--accent); }
    body.pussy-power .cabinet-nav { background: rgba(253,242,248,0.82); }
    body.pussy-power .cabinet-nav-tab.active { background: rgba(219,39,119,0.13); color: #db2777; border-color: transparent; box-shadow: none; }
    body.pussy-power .cabinet-nav-tab:hover { background: rgba(219,39,119,0.08); }
    body.pussy-power .cabinet-nav-more-item:hover { background: rgba(219,39,119,0.08); color: #db2777; }
    body.cabinet-speedup-only .cabinet-nav { display: none !important; }
    body.cabinet-speedup-only .cabinet-nav-sticky-wrap { display: none !important; }
    body.cabinet-speedup-only #cabinetScrollFabWrap { display: none !important; }
    @media (max-width: 640px) { .cabinet-nav-tab { padding: 5px 11px; font-size: 0.75rem; } .cabinet-nav-inner { gap: 4px; padding: 8px 12px; } .cabinet-nav-more-menu { right: 8px; } }

    /* Слева внизу: справа тот же угол занят кнопкой AI-тьютора 🎓 (z-index 1200), она перекрывала ⬆️⬇️ */
    #cabinetScrollFabWrap {
      display: none;
      position: fixed;
      z-index: 280;
      left: max(14px, env(safe-area-inset-left, 0px));
      right: auto;
      bottom: max(22px, env(safe-area-inset-bottom, 0px));
      flex-direction: column;
      gap: 10px;
      align-items: center;
      pointer-events: none;
    }
    #cabinetScrollFabWrap.visible {
      display: flex;
      pointer-events: auto;
    }
    .cabinet-scroll-fab-btn {
      width: 50px;
      height: 50px;
      border-radius: 50%;
      border: 1px solid var(--border);
      background: var(--surface);
      box-shadow: var(--shadow-card);
      font-size: 1.2rem;
      line-height: 1;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 0;
      font-family: inherit;
      transition: transform 0.15s var(--ease), box-shadow 0.2s var(--ease), opacity 0.15s ease;
    }
    .cabinet-scroll-fab-btn:hover:not(:disabled) { transform: scale(1.06); box-shadow: 0 6px 24px rgba(0,0,0,0.12); }
    .cabinet-scroll-fab-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
    .cabinet-scroll-fab-btn:disabled { opacity: 0.32; cursor: default; transform: none; box-shadow: var(--shadow); }
    body.pussy-power-mode .cabinet-scroll-fab-btn:focus-visible { outline-color: var(--accent); }

    .reorder-btn { display:none; background:var(--accent-soft); border:none; border-radius:6px; width:28px; height:24px; cursor:pointer; color:var(--accent); font-size:0.75rem; font-weight:700; padding:0; line-height:1; }
    .reorder-btn:hover { background:var(--accent); color:#fff; }
    @media (hover: none) { .reorder-btn { display:inline-block; } }
    .progress-item-drag-handle:focus-within ~ .reorder-btn, .progress-item:hover .reorder-btn,
    .plan-drag-handle:focus-within ~ .reorder-btn, .plan-full-item:hover .reorder-btn,
    .all-catalog-subject-drag-handle:focus-within ~ .reorder-btn, .all-catalog-subject:hover .reorder-btn { display:inline-block; }

    /* ===== TELEGRAM CONNECT TOAST ===== */
    .tg-toast {
      position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(120px);
      z-index: 9999; width: calc(100% - 32px); max-width: 440px;
      background: #fff; border-radius: 20px; padding: 0; overflow: hidden;
      box-shadow: 0 16px 60px rgba(0,0,0,.14), 0 4px 16px rgba(0,0,0,.06);
      border: 1px solid rgba(13,148,136,.08);
      opacity: 0; pointer-events: none;
      transition: transform .7s cubic-bezier(.16,1,.3,1), opacity .5s ease;
    }
    .tg-toast.visible { transform: translateX(-50%) translateY(0); opacity: 1; pointer-events: auto; }
    .tg-toast-gradient {
      height: 4px;
      background: linear-gradient(90deg, #0d9488, #14b8a6, #5eead4, #14b8a6, #0d9488);
      background-size: 200% 100%; animation: tgGradientMove 3s linear infinite;
    }
    @keyframes tgGradientMove { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
    .tg-toast-body { padding: 18px 20px; display: flex; align-items: flex-start; gap: 14px; }
    .tg-toast-icon {
      width: 48px; height: 48px; border-radius: 14px; flex-shrink: 0;
      background: linear-gradient(135deg, #0088cc, #0077b5);
      display: flex; align-items: center; justify-content: center;
      font-size: 1.4rem; color: #fff;
      box-shadow: 0 4px 12px rgba(0,136,204,.25);
    }
    .tg-toast-content { flex: 1; min-width: 0; }
    .tg-toast-title { font-size: .9375rem; font-weight: 700; color: #1e293b; margin: 0 0 4px; line-height: 1.3; }
    .tg-toast-desc { font-size: .8125rem; color: #64748b; margin: 0; line-height: 1.5; }
    .tg-toast-actions { display: flex; gap: 8px; padding: 0 20px 18px; }
    .tg-toast-btn {
      flex: 1; padding: 12px 16px; font-family: inherit; font-size: .875rem; font-weight: 600;
      border: none; border-radius: 12px; cursor: pointer; text-align: center;
      text-decoration: none; display: flex; align-items: center; justify-content: center; gap: 6px;
      transition: transform .25s cubic-bezier(.34,1.56,.64,1), box-shadow .25s ease;
    }
    .tg-toast-btn:hover { transform: translateY(-1px); }
    .tg-toast-btn.primary {
      background: linear-gradient(135deg, #0088cc, #0077b5); color: #fff;
      box-shadow: 0 4px 14px rgba(0,136,204,.3);
    }
    .tg-toast-btn.primary:hover { box-shadow: 0 6px 20px rgba(0,136,204,.4); }
    .tg-toast-btn.secondary { background: #f1f5f9; color: #64748b; }
    .tg-toast-btn.secondary:hover { background: #e2e8f0; color: #475569; }
    .tg-toast-close {
      position: absolute; top: 14px; right: 14px;
      width: 26px; height: 26px; border-radius: 50%; border: none;
      background: #f1f5f9; color: #94a3b8; font-size: .85rem;
      cursor: pointer; display: flex; align-items: center; justify-content: center;
      transition: background .2s, color .2s;
    }
    .tg-toast-close:hover { background: #e2e8f0; color: #64748b; }
    @media (max-width: 480px) {
      .tg-toast { bottom: 12px; border-radius: 16px; }
      .tg-toast-body { padding: 14px 16px; gap: 12px; }
      .tg-toast-actions { padding: 0 16px 14px; }
      .tg-toast-icon { width: 42px; height: 42px; font-size: 1.2rem; border-radius: 12px; }
    }
    @media (prefers-reduced-motion: reduce) {
      .tg-toast { transition: none; }
      .tg-toast-gradient { animation: none; }
      .tutor-thinking-shimmer,
      .tutor-thinking-text,
      .tutor-thinking-dots span,
      .tutor-answer-skeleton-bar,
      .tutor-answer-skeleton-text,
      .tutor-answer-skeleton--live,
      .tutor-answer-skeleton-dots span,
      .rag-msg-typing .tutor-icon-pulse { animation: none; }
      .tutor-thinking-shimmer { opacity: 0.75; }
      .tutor-answer-skeleton-bar { opacity: 0.75; }
    }

    /* AI-тьютор: стили панели как у AI-чата методички */
    .rag-fab {
      position: fixed;
      bottom: 24px;
      z-index: 100;
      height: 52px;
      min-width: 52px;
      padding: 0 20px 0 16px;
      border-radius: 26px;
      border: none;
      background: var(--accent);
      color: #fff;
      font-size: 0.95rem;
      font-weight: 600;
      cursor: pointer;
      box-shadow: 0 6px 20px rgba(0,0,0,0.18);
      display: none;
      align-items: center;
      justify-content: center;
      gap: 8px;
      font-family: inherit;
      right: 16px;
      transition: transform 0.15s ease, box-shadow 0.15s ease;
    }
    .rag-fab.visible { display: inline-flex; }
    .rag-fab:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(0,0,0,0.24); }
    .rag-fab:active { transform: translateY(0); }
    .rag-fab:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
    .rag-fab .rag-fab-icon { font-size: 1.2rem; line-height: 1; filter: drop-shadow(0 1px 1px rgba(0,0,0,0.25)); }
    .rag-fab .rag-fab-label { white-space: nowrap; letter-spacing: 0.01em; }
    /* Первый заход: мягкий «дышащий» пульс, чтобы глаз зацепил вход в ИИ. */
    .rag-fab.rag-fab-pulse { animation: ragFabPulse 1.8s ease-in-out 3; }
    @keyframes ragFabPulse {
      0%, 100% { box-shadow: 0 6px 20px rgba(0,0,0,0.18); }
      50% { box-shadow: 0 6px 20px rgba(0,0,0,0.18), 0 0 0 8px var(--accent-soft); }
    }
    @media (prefers-reduced-motion: reduce) {
      .rag-fab.rag-fab-pulse { animation: none; }
    }
    /* На узких экранах — компактная круглая иконка без подписи (не теснит стек FAB-ов). */
    @media (max-width: 768px) {
      .rag-fab { width: 52px; padding: 0; border-radius: 50%; }
      .rag-fab .rag-fab-label { display: none; }
    }
    .rag-panel-overlay {
      position: fixed;
      left: 0; top: 0; right: 0; bottom: 0;
      background: rgba(0,0,0,0.35);
      z-index: 101;
      display: none;
    }
    .rag-panel-overlay.visible { display: block; }
    .rag-panel {
      position: fixed;
      right: 12px;
      bottom: 80px;
      width: min(480px, calc(100vw - 24px));
      height: min(600px, 80vh);
      max-height: 80vh;
      background: var(--surface);
      border-radius: 16px;
      box-shadow: 0 4px 24px rgba(0,0,0,0.15), 0 0 1px rgba(0,0,0,0.08);
      z-index: 102;
      display: flex;
      flex-direction: column;
      overflow: hidden;
      opacity: 0;
      visibility: hidden;
      transform: translateY(8px) scale(0.98);
      transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
    }
    .rag-panel.open {
      opacity: 1;
      visibility: visible;
      transform: translateY(0) scale(1);
    }
    .rag-panel-header-wrap {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 16px 20px 4px;
      flex-shrink: 0;
    }
    .rag-panel-header { font-weight: 600; font-size: 1rem; margin: 0; }
    .rag-panel-clear {
      background: none;
      border: none;
      padding: 6px 8px;
      cursor: pointer;
      font-size: 1rem;
      opacity: 0.7;
      border-radius: var(--radius-sm);
    }
    .rag-panel-clear:hover { opacity: 1; background: var(--accent-soft); }
    .rag-panel-subheader {
      margin: 0 16px 10px;
      padding: 0 0 10px;
      border-bottom: 1px solid var(--border);
      font-size: 0.8125rem;
      line-height: 1.35;
      color: var(--text-secondary);
      flex-shrink: 0;
      overflow-wrap: break-word;
      word-wrap: break-word;
    }
    .rag-chat-scroll-wrap {
      flex: 1;
      min-height: 0;
      position: relative;
      display: flex;
      flex-direction: column;
    }
    .rag-chat-messages {
      flex: 1;
      overflow-y: auto;
      padding: 12px 16px;
      display: flex;
      flex-direction: column;
      gap: 12px;
    }
    .rag-scroll-to-bottom {
      position: absolute;
      bottom: 68px;
      right: 12px;
      padding: 6px 12px;
      font-size: 0.75rem;
      border-radius: 20px;
      border: 1px solid var(--border);
      background: var(--surface);
      color: var(--text-secondary);
      cursor: pointer;
      box-shadow: 0 2px 10px rgba(0,0,0,0.12);
      opacity: 0;
      visibility: hidden;
      transition: opacity 0.2s ease, visibility 0.2s ease;
    }
    .rag-scroll-to-bottom.visible { opacity: 1; visibility: visible; }
    .rag-scroll-to-bottom:hover { background: var(--accent-soft); color: var(--accent); }
    .rag-msg {
      display: flex;
      align-items: flex-start;
      gap: 8px;
      max-width: 92%;
    }
    .rag-msg-user { align-self: flex-end; flex-direction: row-reverse; }
    .rag-msg-ai { align-self: flex-start; }
    .rag-msg-bubble {
      padding: 10px 12px;
      border-radius: 14px;
      font-size: 0.9375rem;
      line-height: 1.45;
      word-break: break-word;
      border: 1px solid rgba(0,0,0,0.08);
    }
    .rag-msg-user .rag-msg-bubble {
      background: var(--accent-soft);
      color: var(--text);
      border-color: var(--accent);
    }
    .rag-msg-ai .rag-msg-bubble {
      background: var(--surface);
      color: var(--text);
      /* Пустой ответ между tool-call и стримом не схлопывается в «узкий овал» */
      min-width: min(100%, 200px);
    }
    .rag-msg-ai-icon {
      flex-shrink: 0;
      width: 28px;
      height: 28px;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 0.9rem;
      color: var(--text-secondary);
      transform-origin: center center;
    }
    .rag-msg-typing .rag-msg-bubble { padding: 12px 18px; }
    /* Плейсхолдер «думает» до первого токена стрима / tool call */
    .tutor-thinking {
      display: flex;
      flex-direction: column;
      gap: 10px;
      padding: 2px 0 4px;
      min-height: 2.25rem;
      justify-content: center;
      align-items: stretch;
      width: 100%;
      min-width: 0;
      box-sizing: border-box;
    }
    .tutor-thinking--compact { gap: 8px; min-height: 2rem; }
    .tutor-thinking-shimmer {
      width: 100%;
      min-width: 120px;
      height: 4px;
      min-height: 4px;
      max-height: 4px;
      flex-shrink: 0;
      border-radius: 4px;
      max-width: 100%;
      box-sizing: border-box;
      overflow: hidden;
      background: linear-gradient(
        90deg,
        var(--accent-soft, #ecfdf5) 0%,
        var(--accent, #14b8a6) 48%,
        var(--accent-soft, #ecfdf5) 100%
      );
      background-size: 220% 100%;
      animation: tutor-shimmer-slide 2.1s ease-in-out infinite;
      opacity: 0.9;
    }
    @keyframes tutor-shimmer-slide {
      0% { background-position: 100% 0; }
      100% { background-position: -100% 0; }
    }
    .tutor-thinking-text {
      font-size: 0.8125rem;
      color: var(--text-secondary);
      line-height: 1.35;
      animation: tutor-text-breathe 2.4s ease-in-out infinite;
    }
    @keyframes tutor-text-breathe {
      0%, 100% { opacity: 0.55; }
      50% { opacity: 1; }
    }
    .tutor-thinking-dots {
      display: flex;
      align-items: center;
      gap: 5px;
      margin-top: 2px;
    }
    .tutor-thinking-dots span {
      width: 5px;
      height: 5px;
      border-radius: 50%;
      background: var(--accent, #14b8a6);
      opacity: 0.55;
      animation: tutor-dot-wave 1.3s ease-in-out infinite both;
    }
    .tutor-thinking-dots span:nth-child(2) { animation-delay: 0.15s; }
    .tutor-thinking-dots span:nth-child(3) { animation-delay: 0.3s; }
    @keyframes tutor-dot-wave {
      0%, 70%, 100% { transform: translateY(0); opacity: 0.35; }
      35% { transform: translateY(-4px); opacity: 1; }
    }
    .rag-msg-typing .tutor-icon-pulse {
      animation: tutor-icon-pulse 2s ease-in-out infinite;
      transform-origin: center center;
    }
    @keyframes tutor-icon-pulse {
      0%, 100% { opacity: 0.4; transform: scale(1); }
      50% { opacity: 1; transform: scale(1.06); }
    }
    /* Между «думает» и первым токеном / после старта tool — не пустой пузырь */
    .tutor-answer-skeleton {
      display: flex;
      flex-direction: column;
      gap: 8px;
      align-items: stretch;
      width: 100%;
      min-width: 0;
      padding: 2px 0;
    }
    .tutor-answer-skeleton--live {
      animation: tutor-skeleton-live-glow 2.8s ease-in-out infinite;
    }
    @keyframes tutor-skeleton-live-glow {
      0%, 100% { opacity: 1; filter: saturate(1); }
      50% { opacity: 0.94; filter: saturate(1.15); }
    }
    .tutor-answer-skeleton-bar {
      width: 100%;
      min-width: 120px;
      height: 4px;
      min-height: 4px;
      max-height: 4px;
      flex-shrink: 0;
      border-radius: 4px;
      box-sizing: border-box;
      overflow: hidden;
      background: linear-gradient(
        90deg,
        var(--accent-soft, #ecfdf5) 0%,
        var(--accent, #14b8a6) 48%,
        var(--accent-soft, #ecfdf5) 100%
      );
      background-size: 220% 100%;
      animation: tutor-shimmer-slide 2.1s ease-in-out infinite;
      opacity: 0.85;
    }
    .tutor-answer-skeleton-bar--secondary {
      opacity: 0.5;
      height: 3px;
      min-height: 3px;
      max-height: 3px;
      animation: tutor-shimmer-slide 2.8s ease-in-out infinite;
      animation-delay: 0.65s;
    }
    .tutor-answer-skeleton-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 8px 10px;
      min-height: 1.35em;
    }
    .tutor-answer-skeleton-text {
      font-size: 0.8125rem;
      color: var(--text-secondary);
      line-height: 1.35;
      animation: tutor-text-breathe 2.4s ease-in-out infinite;
      transition: opacity 0.25s ease;
    }
    .tutor-answer-skeleton-dots {
      display: inline-flex;
      align-items: center;
      gap: 5px;
    }
    .tutor-answer-skeleton-dots span {
      width: 5px;
      height: 5px;
      border-radius: 50%;
      background: var(--accent, #14b8a6);
      opacity: 0.35;
      animation: tutor-skel-dot 0.9s ease-in-out infinite both;
    }
    .tutor-answer-skeleton-dots span:nth-child(2) { animation-delay: 0.12s; }
    .tutor-answer-skeleton-dots span:nth-child(3) { animation-delay: 0.24s; }
    @keyframes tutor-skel-dot {
      0%, 100% { opacity: 0.25; transform: translateY(0) scale(0.9); }
      50% { opacity: 1; transform: translateY(-3px) scale(1.05); }
    }
    .rag-typing-dots span {
      display: inline-block;
      width: 6px;
      height: 6px;
      border-radius: 50%;
      background: var(--text-secondary);
      margin: 0 2px;
      animation: rag-typing-bounce 1.4s ease-in-out infinite both;
    }
    .rag-typing-dots span:nth-child(2) { animation-delay: 0.2s; }
    .rag-typing-dots span:nth-child(3) { animation-delay: 0.4s; }
    @keyframes rag-typing-bounce {
      0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
      40% { transform: scale(1); opacity: 1; }
    }
    .ai-chat-answer {
      font-size: 0.9rem;
      line-height: 1.65;
      word-break: break-word;
    }
    .ai-chat-answer p { margin: 0 0 0.6em 0; }
    .ai-chat-answer p:last-child { margin-bottom: 0; }
    .ai-chat-answer ul, .ai-chat-answer ol { margin: 0.4em 0; padding-left: 1.4em; }
    .ai-chat-answer li { margin-bottom: 0.3em; }
    .ai-chat-answer strong { font-weight: 600; }
    .ai-chat-answer a {
      color: var(--accent);
      text-decoration: underline;
      text-underline-offset: 2px;
      word-break: break-word;
    }
    .ai-chat-answer a:hover { filter: brightness(0.92); }
    .ai-chat-answer code {
      font-family: 'JetBrains Mono', 'Consolas', monospace;
      font-size: 0.85em;
      padding: 2px 5px;
      border-radius: 4px;
      background: rgba(0,0,0,0.06);
    }
    .ai-chat-answer h1, .ai-chat-answer h2, .ai-chat-answer h3 {
      font-size: 0.95rem;
      font-weight: 600;
      margin: 0.8em 0 0.3em 0;
    }
    .ai-chat-answer table {
      width: 100%;
      border-collapse: collapse;
      margin: 0.5em 0;
      font-size: 0.85rem;
    }
    .ai-chat-answer th, .ai-chat-answer td {
      padding: 6px 10px;
      text-align: left;
      border: 1px solid var(--border);
    }
    .ai-chat-answer th { background: #f8fafc; font-weight: 600; }
    .ai-chat-welcome {
      display: flex;
      flex-direction: column;
      align-items: center;
      justify-content: center;
      flex: 1;
      min-height: 120px;
      padding: 24px 20px;
      text-align: center;
      gap: 16px;
    }
    .ai-chat-welcome-icon {
      font-size: 2rem;
      width: 52px;
      height: 52px;
      border-radius: 50%;
      background: var(--accent-soft);
      display: flex;
      align-items: center;
      justify-content: center;
      color: var(--accent);
    }
    .ai-chat-welcome-title { font-weight: 600; font-size: 1rem; margin: 0; color: var(--text); }
    .ai-chat-welcome-sub {
      font-size: 0.8125rem;
      color: var(--text-secondary);
      margin: 0;
      line-height: 1.4;
    }
    .ai-chat-chips {
      display: flex;
      flex-wrap: wrap;
      gap: 6px;
      justify-content: center;
      padding: 0 4px;
    }
    .ai-chat-chip {
      display: inline-block;
      padding: 7px 14px;
      font-size: 0.8125rem;
      border-radius: 20px;
      border: 1px solid var(--border);
      background: var(--surface);
      color: var(--text);
      cursor: pointer;
      transition: all 0.15s ease;
      line-height: 1.3;
      text-align: left;
    }
    .ai-chat-chip:hover {
      border-color: var(--accent);
      background: var(--accent-soft);
      color: var(--accent);
    }
    .ai-chat-rate-info {
      font-size: 0.6875rem;
      color: var(--text-secondary);
      text-align: center;
      padding: 0 16px 2px;
      opacity: 0.7;
      flex-shrink: 0;
    }
    .ai-chat-rate-info.low { color: #dc2626; opacity: 1; font-weight: 500; }
    .rag-chat-input-wrap {
      flex-shrink: 0;
      padding: 10px 12px 12px;
      border-top: 1px solid var(--border);
      display: flex;
      gap: 6px;
      align-items: flex-end;
      background: var(--surface);
      min-width: 0;
    }
    /* Оболочка: иначе длинный placeholder/текст ломает flex и вылезает за кнопки */
    .rag-chat-input-field {
      flex: 1 1 0;
      min-width: 0;
      display: flex;
      align-items: flex-end;
    }
    .rag-chat-input-wrap textarea {
      width: 100%;
      min-width: 0;
      min-height: 40px;
      max-height: 120px;
      padding: 9px 12px;
      border: 1px solid var(--border);
      border-radius: 20px;
      font-size: 0.875rem;
      line-height: 1.4;
      font-family: inherit;
      resize: none;
      box-sizing: border-box;
      overflow-x: hidden;
      overflow-y: auto;
      word-wrap: break-word;
      overflow-wrap: break-word;
    }
    .rag-chat-input-wrap textarea:focus { outline: none; border-color: var(--accent); }
    .rag-chat-send {
      flex-shrink: 0;
      width: 40px;
      height: 40px;
      border-radius: 50%;
      border: none;
      background: var(--accent);
      color: #fff;
      font-size: 1.2rem;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
    }
    .rag-chat-send:hover { filter: brightness(1.05); }
    .rag-chat-send:disabled { opacity: 0.5; cursor: not-allowed; }
    .rag-chat-stop {
      flex-shrink: 0;
      width: 40px;
      height: 40px;
      border-radius: 50%;
      border: 2px solid var(--accent);
      background: var(--surface);
      color: var(--accent);
      font-size: 0.9rem;
      cursor: pointer;
      display: none;
      align-items: center;
      justify-content: center;
    }
    .rag-chat-stop:hover { background: var(--accent-soft); }
    .rag-chat-stop.active { display: flex; }
    @media (max-width: 767px) {
      .rag-panel.rag-mobile-sheet {
        right: 0;
        left: 0;
        bottom: 0;
        top: auto;
        width: 100%;
        height: 92vh;
        max-height: 92vh;
        border-radius: 16px 16px 0 0;
        transform: translateY(100%);
      }
      .rag-panel.rag-mobile-sheet.open { transform: translateY(0); }
    }
    /* Выше липкой .cabinet-nav (200) и прочих слоёв кабинета */
    #cabinetTutorFab.rag-fab { z-index: 1200; }
    #cabinetTutorOverlay.rag-panel-overlay { z-index: 1201; }
    #cabinetTutorPanel.rag-panel { z-index: 1202; }
    /* Tutor AI v2: feedback thumbs + bug report */
    .ai-chat-feedback { display: flex; gap: 6px; margin-top: 6px; }
    .ai-fb-btn {
      background: none; border: 1px solid var(--border); border-radius: 6px;
      padding: 2px 8px; font-size: 0.8rem; cursor: pointer; opacity: 0.5;
      transition: opacity 0.2s, border-color 0.2s, background 0.2s;
    }
    .ai-fb-btn:hover { opacity: 0.85; border-color: var(--accent); }
    .ai-fb-btn.active { opacity: 1; border-color: var(--accent); background: var(--accent-soft); }
    .ai-fb-btn.ai-fb-flag { font-size: 0.9rem; }
    .ai-chat-report-form {
      margin-top: 8px; padding: 10px 12px;
      border: 1px solid var(--border); border-radius: 10px;
      background: var(--bg-soft, rgba(0,0,0,0.02));
      display: flex; flex-direction: column; gap: 8px;
    }
    .ai-report-title { font-size: 0.85rem; font-weight: 600; color: var(--text-primary); }
    .ai-report-chips { display: flex; flex-wrap: wrap; gap: 6px; }
    .ai-report-chip {
      background: none; border: 1px solid var(--border); border-radius: 999px;
      padding: 4px 10px; font-size: 0.78rem; cursor: pointer; opacity: 0.75;
      transition: opacity 0.15s, border-color 0.15s, background 0.15s;
      color: var(--text-primary);
    }
    .ai-report-chip:hover { opacity: 1; border-color: var(--accent); }
    .ai-report-chip.active { opacity: 1; border-color: var(--accent); background: var(--accent-soft); }
    .ai-report-text {
      width: 100%; min-height: 64px; resize: vertical;
      border: 1px solid var(--border); border-radius: 8px;
      padding: 8px 10px; font: inherit; font-size: 0.85rem;
      background: var(--bg, #fff); color: var(--text-primary); box-sizing: border-box;
    }
    .ai-report-text:focus { outline: none; border-color: var(--accent); }
    .ai-report-actions { display: flex; gap: 8px; justify-content: flex-end; }
    .ai-report-cancel, .ai-report-submit {
      border: 1px solid var(--border); border-radius: 8px;
      padding: 4px 12px; font-size: 0.82rem; cursor: pointer; background: var(--bg, #fff);
      color: var(--text-primary);
    }
    .ai-report-submit { background: var(--accent); color: var(--accent-contrast, #fff); border-color: var(--accent); }
    .ai-report-submit:hover { opacity: 0.9; }
    .ai-report-hint { color: var(--danger, #c0392b); font-size: 0.78rem; }
    .ai-report-thanks {
      margin-top: 8px; padding: 8px 12px; font-size: 0.82rem;
      color: var(--text-secondary); border: 1px dashed var(--border); border-radius: 8px;
    }
    /* Tutor AI v2: tool status */
    .ai-chat-tool-status {
      font-size: 0.75rem; color: var(--text-secondary); padding: 4px 12px;
      display: none; animation: tutor-tool-pulse 1.2s ease-in-out infinite;
    }
    @keyframes tutor-tool-pulse { 0%,100%{opacity:0.5} 50%{opacity:1} }
    /* Tutor AI: виджет квиза Практика/Клиника */
    .ai-chat-widgets { display: flex; flex-direction: column; gap: 12px; margin-top: 10px; }
    .ai-chat-quiz {
      border: 1px solid var(--border);
      border-radius: 12px;
      padding: 12px 14px;
      background: var(--accent-soft);
      text-align: left;
    }
    .ai-chat-quiz-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 8px; }
    .ai-chat-quiz-badge {
      font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
      padding: 3px 8px; border-radius: 6px; background: var(--accent); color: #fff;
    }
    .ai-chat-quiz-section { font-size: 0.75rem; color: var(--text-secondary); }
    .ai-chat-quiz-q { font-size: 0.9rem; line-height: 1.5; margin-bottom: 10px; color: var(--text); }
    .ai-chat-quiz-q p:last-child { margin-bottom: 0; }
    .ai-chat-quiz-opts { display: flex; flex-direction: column; gap: 6px; }
    .ai-chat-quiz-opt {
      text-align: left; width: 100%; padding: 10px 12px; border-radius: 10px;
      border: 1px solid var(--border); background: var(--surface); color: var(--text);
      font-size: 0.875rem; line-height: 1.35; cursor: pointer; font-family: inherit;
      transition: border-color 0.15s, background 0.15s;
    }
    .ai-chat-quiz-opt:hover:not(:disabled) { border-color: var(--accent); background: #fff; }
    .ai-chat-quiz-opt:disabled { opacity: 0.65; cursor: default; }
    .ai-chat-quiz-result { margin-top: 10px; padding: 10px 12px; border-radius: 10px; font-size: 0.875rem; line-height: 1.45; }
    .ai-chat-quiz-result-ok { background: rgba(34, 197, 94, 0.12); border: 1px solid rgba(34, 197, 94, 0.35); color: var(--text); }
    .ai-chat-quiz-result-bad { background: rgba(239, 68, 68, 0.08); border: 1px solid rgba(239, 68, 68, 0.25); color: var(--text); }
    .ai-chat-quiz-result-err { background: rgba(0,0,0,0.04); border: 1px solid var(--border); color: var(--text-secondary); }
    .ai-chat-quiz-hint { font-size: 0.875rem; color: var(--text-secondary); margin: 0; }
    .ai-chat-quiz-cta { margin-top: 10px; display: flex; justify-content: flex-end; }
    .ai-chat-quiz-cta-link {
      display: inline-flex;
      align-items: center;
      gap: 4px;
      padding: 8px 14px;
      border-radius: 999px;
      border: 1px solid var(--accent);
      background: var(--accent);
      color: #fff;
      font-size: 0.875rem;
      font-weight: 600;
      text-decoration: none;
      transition: background 0.15s ease, border-color 0.15s ease;
    }
    .ai-chat-quiz-cta-link:hover { background: var(--accent-strong, var(--accent)); }
    /* Tutor AI: виджет плана */
    .ai-chat-plan {
      border: 1px solid var(--border);
      border-radius: 12px;
      padding: 12px 14px;
      background: linear-gradient(165deg, var(--accent-soft) 0%, var(--surface) 55%);
      text-align: left;
    }
    .ai-chat-plan-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
    .ai-chat-plan-badge {
      font-size: 0.6875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em;
      padding: 3px 8px; border-radius: 6px; background: var(--text-secondary); color: #fff;
    }
    .ai-chat-plan-title { font-size: 0.95rem; font-weight: 600; color: var(--text); margin: 0; flex: 1; min-width: 0; }
    .ai-chat-plan-progress-wrap { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; margin-bottom: 6px; }
    .ai-chat-plan-progress-fill { height: 100%; background: var(--accent); border-radius: 4px; transition: width 0.35s ease; }
    .ai-chat-plan-stats { font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 10px; line-height: 1.4; }
    .ai-chat-plan-stats strong { color: var(--text); font-weight: 600; }
    .ai-chat-plan-subend { font-size: 0.75rem; color: var(--text-secondary); margin: -4px 0 10px; }
    .ai-chat-plan-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
    .ai-chat-plan-item {
      font-size: 0.875rem; line-height: 1.4; padding: 8px 10px; border-radius: 8px;
      background: var(--surface); border: 1px solid var(--border);
      box-sizing: border-box;
    }
    .ai-chat-plan-item--link {
      text-decoration: none; color: inherit; cursor: pointer; display: block;
      transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    }
    .ai-chat-plan-item--link:hover {
      border-color: var(--accent); background: #fff; box-shadow: 0 1px 6px rgba(0,0,0,0.06);
    }
    .ai-chat-plan-item--done {
      border-color: rgba(22, 163, 74, 0.35);
      background: rgba(22, 163, 74, 0.07);
    }
    .ai-chat-plan-item--done.ai-chat-plan-item--link:hover {
      border-color: rgba(22, 163, 74, 0.5);
      background: rgba(22, 163, 74, 0.11);
    }
    .ai-chat-plan-item-inner { display: flex; align-items: flex-start; gap: 10px; }
    .ai-chat-plan-done-mark {
      flex-shrink: 0; width: 22px; text-align: center; font-size: 0.95rem;
      font-weight: 700; color: #16a34a; line-height: 1.35; margin-top: 1px;
    }
    .ai-chat-plan-item-body { flex: 1; min-width: 0; }
    .ai-chat-plan-item-name { font-weight: 500; color: var(--text); }
    .ai-chat-plan-item--done .ai-chat-plan-item-name {
      text-decoration: line-through; color: var(--text-secondary); font-weight: 500;
    }
    .ai-chat-plan-item-meta { font-size: 0.75rem; color: var(--text-secondary); margin-top: 4px; }
    .ai-chat-plan-empty { font-size: 0.875rem; color: var(--text-secondary); margin: 0; }
    .ai-chat-plan-cta {
      display: inline-block; margin-top: 12px; font-size: 0.8125rem; font-weight: 600;
      color: var(--accent); text-decoration: none;
    }
    .ai-chat-plan-cta:hover { text-decoration: underline; }
    /* Tutor AI: AI-предложение по плану (карточка с «Применить») */
    .ai-chat-plan-proposal {
      border: 1px solid var(--accent);
      background: linear-gradient(165deg, var(--accent-soft) 0%, var(--surface) 65%);
    }
    .ai-chat-plan-proposal--delete { border-color: rgba(239, 68, 68, 0.45); background: linear-gradient(165deg, rgba(239,68,68,0.08) 0%, var(--surface) 70%); }
    .ai-chat-plan-proposal-badge { background: var(--accent); color: #fff; }
    .ai-chat-plan-proposal--delete .ai-chat-plan-proposal-badge { background: #ef4444; }
    .ai-chat-plan-proposal-summary { font-size: 0.875rem; color: var(--text); margin: 0 0 10px; line-height: 1.45; }
    .ai-chat-plan-proposal-warn {
      font-size: 0.8125rem; color: var(--text); margin: 0 0 10px; padding: 8px 10px;
      background: rgba(239, 68, 68, 0.08); border: 1px solid rgba(239, 68, 68, 0.25); border-radius: 8px;
    }
    .ai-chat-plan-proposal-foot { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
    .ai-chat-plan-proposal-apply {
      flex: 1 1 auto; min-width: 140px; padding: 9px 16px;
      background: var(--accent); color: #fff; border: 1px solid var(--accent);
      border-radius: 8px; font-size: 0.875rem; font-weight: 600; cursor: pointer;
      font-family: inherit; transition: opacity 0.15s, transform 0.15s;
    }
    .ai-chat-plan-proposal-apply:hover:not(:disabled) { opacity: 0.92; }
    .ai-chat-plan-proposal-apply:disabled { opacity: 0.5; cursor: default; }
    .ai-chat-plan-proposal-apply--danger { background: #ef4444; border-color: #ef4444; }
    .ai-chat-plan-proposal-cancel {
      flex: 0 1 auto; min-width: 100px; padding: 9px 16px;
      background: transparent; color: var(--text-secondary);
      border: 1px solid var(--border); border-radius: 8px;
      font-size: 0.875rem; font-weight: 500; cursor: pointer; font-family: inherit;
      transition: border-color 0.15s, color 0.15s;
    }
    .ai-chat-plan-proposal-cancel:hover:not(:disabled) { border-color: var(--text-secondary); color: var(--text); }
    .ai-chat-plan-proposal-cancel:disabled { opacity: 0.5; cursor: default; }
    .ai-chat-plan-proposal-status {
      margin: 10px 0 0; padding: 8px 10px; border-radius: 8px;
      font-size: 0.8125rem; line-height: 1.4;
      background: rgba(0,0,0,0.04); border: 1px solid var(--border); color: var(--text-secondary);
    }
    .ai-chat-plan-proposal-status--ok {
      background: rgba(22, 163, 74, 0.08);
      border-color: rgba(22, 163, 74, 0.3); color: var(--text);
    }
    .ai-chat-plan-proposal-status--err {
      background: rgba(239, 68, 68, 0.08);
      border-color: rgba(239, 68, 68, 0.3); color: var(--text);
    }
    .ai-chat-plan-proposal-status-link {
      color: var(--accent); font-weight: 600; text-decoration: none; margin-left: 4px;
    }
    .ai-chat-plan-proposal-status-link:hover { text-decoration: underline; }
    /* Tutor AI: карточки RAG-источников (откуда взят ответ) */
    .ai-chat-sources {
      border: 1px solid var(--border); border-radius: 12px;
      padding: 10px 12px; background: var(--surface);
    }
    .ai-chat-sources-head { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
    .ai-chat-sources-icon { font-size: 0.95rem; line-height: 1; }
    .ai-chat-sources-title {
      font-size: 0.6875rem; font-weight: 600; text-transform: uppercase;
      letter-spacing: 0.04em; color: var(--text-secondary);
    }
    .ai-chat-sources-list { display: flex; flex-direction: column; gap: 6px; }
    .ai-chat-sources-item {
      display: flex; align-items: flex-start; gap: 10px;
      padding: 8px 10px; border-radius: 8px;
      background: var(--surface); border: 1px solid var(--border);
      box-sizing: border-box;
    }
    .ai-chat-sources-item--link {
      text-decoration: none; color: inherit; cursor: pointer;
      transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
    }
    .ai-chat-sources-item--link:hover {
      border-color: var(--accent); background: #fff;
      box-shadow: 0 1px 6px rgba(0,0,0,0.06);
    }
    .ai-chat-sources-item--locked { opacity: 0.7; }
    .ai-chat-sources-num {
      flex-shrink: 0; font-size: 0.75rem; font-weight: 600;
      color: var(--accent); margin-top: 1px; min-width: 22px;
    }
    .ai-chat-sources-body { flex: 1; min-width: 0; }
    .ai-chat-sources-name {
      font-size: 0.875rem; font-weight: 500; color: var(--text);
      line-height: 1.35; word-wrap: break-word;
    }
    .ai-chat-sources-meta {
      font-size: 0.75rem; color: var(--text-secondary); margin-top: 3px; line-height: 1.35;
    }
    .ai-chat-sources-arrow {
      flex-shrink: 0; color: var(--text-secondary); font-size: 0.95rem; margin-top: 1px;
      transition: transform 0.15s, color 0.15s;
    }
    .ai-chat-sources-item--link:hover .ai-chat-sources-arrow {
      color: var(--accent); transform: translateX(2px);
    }
    /* Tutor AI v2: mic & attach buttons */
    .rag-chat-mic, .rag-chat-attach {
      flex-shrink: 0; width: 36px; height: 36px; border-radius: 50%;
      border: 1px solid var(--border); background: var(--surface); color: var(--text-secondary);
      font-size: 1rem; cursor: pointer; display: flex; align-items: center; justify-content: center;
      transition: border-color 0.2s, color 0.2s, background 0.2s;
    }
    .rag-chat-mic:hover, .rag-chat-attach:hover { border-color: var(--accent); color: var(--accent); }
    .rag-chat-mic.recording { border-color: #ef4444; color: #ef4444; background: rgba(239,68,68,0.08); animation: tutor-mic-pulse 1s ease-in-out infinite; }
    @keyframes tutor-mic-pulse { 0%,100%{box-shadow:0 0 0 0 rgba(239,68,68,0.3)} 50%{box-shadow:0 0 0 6px rgba(239,68,68,0)} }
    .rag-chat-attach.has-image { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

    /* ── Onboarding overlay ────────────────────────────────────────── */
    /* flex-direction: column — чтобы #obPreviewStrip и #onboardingCard
       стекались сверху вниз; align-items: center сохраняет горизонтальное
       центрирование, justify-content: center центрирует пару по вертикали. */
    .onboarding-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.45); display: none; flex-direction: column; align-items: center; justify-content: center; gap: 12px; z-index: 600; padding: 16px; backdrop-filter: blur(6px); }
    .onboarding-overlay.visible { display: flex; }
    .onboarding-card { position: relative; background: var(--surface); border-radius: var(--radius); padding: 28px 24px 24px; max-width: 440px; width: 100%; max-height: 75vh; overflow-y: auto; box-shadow: 0 12px 40px rgba(0,0,0,0.18); animation: obSlideUp 0.35s var(--ease); }
    /* Если первый ребёнок — .ob-chrome, он сам наберёт top-spacing через padding и sticky,
       поэтому ужимаем card padding-top, чтобы close-кнопка визуально оставалась у самого верха. */
    .onboarding-card:has(> .ob-chrome:first-child) { padding-top: 6px; }

    /* Live plan-preview strip — растёт чипами по мере онбординга, чтобы юзер
       видел: «вот что я отвечаю → вот что попадает в план». */
    .ob-preview-strip { background: var(--surface); border-radius: var(--radius); padding: 10px 14px; max-width: 440px; width: 100%; box-shadow: 0 6px 24px rgba(0,0,0,0.14); display: flex; flex-direction: column; gap: 6px; box-sizing: border-box; animation: obSlideUp 0.35s var(--ease); }
    .ob-prev-title { font-size: 0.6875rem; font-weight: 700; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.06em; }
    .ob-prev-chips { display: flex; flex-wrap: wrap; gap: 6px; }
    .ob-prev-chip { display: inline-flex; align-items: center; gap: 5px; padding: 4px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--text); font-size: 0.8125rem; font-weight: 500; line-height: 1.2; animation: obChipIn 0.35s var(--ease); }
    .ob-prev-chip.priority { background: var(--wrong-soft, rgba(220,38,38,0.12)); color: var(--wrong, #b91c1c); }
    .ob-prev-chip.pulse { animation: obChipPulse 0.55s var(--ease); }
    .ob-prev-chip-icon { font-size: 0.875rem; line-height: 1; }
    @keyframes obChipIn { from { opacity: 0; transform: translateY(-6px) scale(0.92); } to { opacity: 1; transform: translateY(0) scale(1); } }
    @keyframes obChipPulse { 0% { transform: scale(1); } 50% { transform: scale(1.1); box-shadow: 0 0 0 6px rgba(13,148,136,0.18); } 100% { transform: scale(1); box-shadow: none; } }

    /* Deadline-step (между goal и self-assessment) */
    .ob-deadline-quick { display: flex; flex-direction: column; gap: 8px; margin: 14px 0 12px; }
    .ob-deadline-chip { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px 14px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-family: inherit; text-align: left; transition: border-color 0.15s, background 0.15s; }
    .ob-deadline-chip:hover { border-color: var(--accent); background: var(--accent-soft); }
    .ob-deadline-chip.selected { border-color: var(--accent); background: var(--accent-soft); }
    .ob-deadline-chip-title { font-size: 0.9375rem; font-weight: 600; color: var(--text); }
    .ob-deadline-chip-hint { font-size: 0.8125rem; color: var(--text-secondary); }
    .ob-deadline-custom { margin: 8px 0 12px; }
    .ob-deadline-custom label { display: block; font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 6px; }
    .ob-deadline-custom input { width: 100%; padding: 10px 12px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-family: inherit; font-size: 0.9375rem; box-sizing: border-box; background: var(--surface); color: var(--text); }
    .ob-deadline-custom input:focus { outline: none; border-color: var(--accent); }

    /* Gap-summary под «Стартовой картой» — какие именно разделы попадут в план. */
    .ob-gap-summary { margin: 12px 0 16px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-alt, var(--accent-soft)); font-size: 0.875rem; color: var(--text); line-height: 1.45; }
    .ob-gap-summary-row { display: flex; align-items: flex-start; gap: 8px; }
    .ob-gap-summary-row + .ob-gap-summary-row { margin-top: 6px; }
    .ob-gap-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; margin-top: 7px; }
    .ob-gap-summary-row.weak .ob-gap-dot { background: var(--wrong, #b91c1c); }
    .ob-gap-summary-row.strong .ob-gap-dot { background: #16a34a; }
    .ob-gap-summary-note { margin-top: 6px; color: var(--text-secondary); font-size: 0.8125rem; }
    /* Подсказка под «Стартовой картой» — что задания живут в блоках Практика/Клиника. */
    .ob-gap-tip { margin: 0 0 16px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--accent-soft); font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.5; }
    .ob-gap-tip strong { color: var(--text); }

    /* Inline plan-editor (финальный шаг онбординга) — компактная форма
       цель/срок/дни/разделы прямо в модалке, без редиректа на страницу. */
    .ob-edit-field { margin: 0 0 14px; }
    .ob-edit-field > label { display: block; font-size: 0.8125rem; color: var(--text-secondary); margin: 0 0 6px; font-weight: 600; }
    .ob-edit-counter { font-size: 0.75rem; color: var(--text-secondary); font-weight: 400; margin-left: 4px; }
    .ob-edit-input { width: 100%; padding: 10px 12px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-family: inherit; font-size: 0.9375rem; box-sizing: border-box; background: var(--surface); color: var(--text); }
    .ob-edit-input:focus { outline: none; border-color: var(--accent); }
    .ob-edit-weekdays { display: flex; flex-wrap: wrap; gap: 6px; }
    .ob-edit-wd { display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border: 1.5px solid var(--border); border-radius: 999px; font-size: 0.8125rem; cursor: pointer; background: var(--surface); transition: border-color 0.15s, background 0.15s; }
    .ob-edit-wd input { margin: 0; }
    .ob-edit-wd:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
    .ob-edit-sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
    .ob-edit-sec-head > label { margin-bottom: 6px; }
    .ob-edit-sec-all { flex-shrink: 0; background: none; border: none; padding: 0 0 6px; font-family: inherit; font-size: 0.8125rem; font-weight: 600; color: var(--accent); cursor: pointer; }
    .ob-edit-sec-all:hover { text-decoration: underline; }
    .ob-edit-sections { max-height: 200px; overflow-y: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 4px 8px; background: var(--surface); }
    .ob-edit-sec { display: flex; align-items: center; gap: 8px; padding: 6px 4px; border-bottom: 1px solid var(--border); cursor: pointer; }
    .ob-edit-sec:last-child { border-bottom: none; }
    .ob-edit-sec input { flex-shrink: 0; }
    .ob-edit-sec-name { flex: 1; font-size: 0.875rem; color: var(--text); line-height: 1.3; }
    .ob-edit-sec-prio { font-size: 0.6875rem; padding: 2px 6px; border-radius: 999px; font-weight: 600; flex-shrink: 0; }
    .ob-edit-sec-prio.failed { background: var(--wrong-soft); color: var(--wrong, #b91c1c); }
    .ob-edit-sec-prio.unsure { background: rgba(245,158,11,0.16); color: #b45309; }
    .ob-edit-empty { font-size: 0.875rem; color: var(--text-secondary); padding: 12px 8px; text-align: center; }

    /* ВУЗ/курс/факультет в редакторе плана */
    .ob-edit-uni-row { display: flex; gap: 8px; margin-top: 6px; }
    .ob-edit-uni-row #obEditCourse { flex: 0 0 80px; }
    .ob-edit-uni-row #obEditFaculty { flex: 1; }
    .ob-edit-field > label.ob-edit-notstudy { display: flex; align-items: center; gap: 6px; margin: 8px 0 0; font-size: 0.8125rem; font-weight: 400; color: var(--text-secondary); cursor: pointer; }
    .ob-edit-notstudy input { margin: 0; flex-shrink: 0; }

    /* Динамичный лоадер сборки плана + «адаптация под ВУЗ» */
    .ob-assemble-overlay { position: absolute; inset: 0; min-height: 100%; z-index: 6; background: var(--surface); border-radius: var(--radius); display: flex; align-items: center; justify-content: center; padding: 28px 24px; animation: obAssembleFade 0.25s var(--ease); }
    .ob-assemble { text-align: center; max-width: 320px; width: 100%; }
    .ob-assemble-orbit { position: relative; width: 72px; height: 72px; margin: 0 auto 22px; }
    .ob-assemble-orbit span { position: absolute; inset: 0; border-radius: 50%; border: 3px solid transparent; border-top-color: var(--accent); animation: obAssembleSpin 1.1s linear infinite; }
    .ob-assemble-orbit span:nth-child(2) { inset: 11px; border-top-color: var(--accent-soft); animation-duration: 1.5s; animation-direction: reverse; }
    .ob-assemble-orbit span:nth-child(3) { inset: 22px; border-top-color: var(--accent); opacity: 0.55; animation-duration: 0.85s; }
    .ob-assemble-title { font-size: 1.25rem; font-weight: 700; color: var(--text); margin: 0 0 6px; }
    .ob-assemble-adapt { font-size: 0.875rem; color: var(--text-secondary); margin: 0 0 14px; line-height: 1.4; }
    .ob-assemble-adapt b { color: var(--accent); }
    .ob-assemble-beat { font-size: 0.9375rem; color: var(--text); margin: 0 0 18px; min-height: 1.4em; line-height: 1.4; }
    .ob-assemble-beat.is-in { animation: obAssembleBeatIn 0.4s var(--ease); }
    .ob-assemble-ic { margin-right: 6px; }
    .ob-assemble-bar { height: 6px; border-radius: 999px; background: var(--border); overflow: hidden; }
    .ob-assemble-bar-fill { height: 100%; width: 6%; border-radius: 999px; background: var(--accent); transition: width 2.6s cubic-bezier(.22,.61,.36,1); }
    @keyframes obAssembleSpin { to { transform: rotate(360deg); } }
    @keyframes obAssembleBeatIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
    @keyframes obAssembleFade { from { opacity: 0; } to { opacity: 1; } }
    @media (prefers-reduced-motion: reduce) {
      .ob-assemble-orbit span { animation: none; }
      .ob-assemble-beat.is-in { animation: none; }
      .ob-assemble-bar-fill { transition: none; }
    }

    /* Telegram-link block в plan-edit (рендерится только если tg_username не сохранён) */
    .ob-tg-link { padding: 12px 14px; border-radius: var(--radius-sm); background: var(--accent-soft); border: 1px solid var(--border); }
    .ob-tg-link > label { color: var(--text); }
    .ob-tg-link .ob-edit-counter { color: var(--wrong, #b91c1c); font-weight: 600; }
    .ob-tg-link-hint { font-size: 0.8125rem; color: var(--text-secondary); margin: 0 0 8px; line-height: 1.4; }
    .ob-tg-link-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 8px; }
    .ob-tg-link-btn { padding: 8px 14px; font-size: 0.8125rem; border-radius: 8px; border: 1.5px solid var(--accent); background: var(--surface); color: var(--accent); cursor: pointer; font-family: inherit; font-weight: 500; transition: background 0.15s, color 0.15s, opacity 0.15s; }
    .ob-tg-link-btn:hover:not(:disabled) { background: var(--accent); color: #fff; }
    .ob-tg-link-btn:disabled { opacity: 0.6; cursor: default; }
    .ob-tg-link-state { font-size: 0.8125rem; color: var(--text-secondary); flex: 1; min-width: 0; line-height: 1.35; }
    .ob-tg-link-state.ok { color: #16a34a; font-weight: 500; }

    /* Plan-origin banner — над формой генератора, объясняет откуда префилл. */
    .ob-plan-origin { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; margin: 0 0 16px; border-radius: var(--radius-sm); background: var(--accent-soft); border: 1px solid var(--border); }
    .ob-plan-origin-icon { font-size: 1.125rem; line-height: 1; padding-top: 2px; }
    .ob-plan-origin-body { flex: 1; min-width: 0; }
    .ob-plan-origin-title { font-size: 0.875rem; font-weight: 600; color: var(--text); margin-bottom: 2px; }
    .ob-plan-origin-bits { font-size: 0.8125rem; color: var(--text); margin-bottom: 4px; }
    .ob-plan-origin-hint { font-size: 0.75rem; color: var(--text-secondary); }
    .ob-plan-origin-dismiss { background: transparent; border: none; color: var(--text-secondary); font-size: 1.125rem; line-height: 1; cursor: pointer; padding: 0 4px; align-self: flex-start; font-family: inherit; }
    .ob-plan-origin-dismiss:hover { color: var(--text); }

    /* Sticky chrome-row с close/back прижат к верху карточки во время скролла.
       Раньше .ob-close-x/.ob-back-btn были position:absolute внутри scrollable .onboarding-card —
       на мобильном форма плана не помещается в 75vh, юзер скроллил, и крестик уезжал вверх. */
    .ob-chrome { position: sticky; top: 0; z-index: 3; display: flex; align-items: center; gap: 8px; margin: 0 -24px 4px; padding: 0 12px; background: var(--surface); min-height: 36px; }
    .ob-chrome:empty { display: none; }
    .ob-close-x { margin-left: auto; width: 32px; height: 32px; border-radius: 8px; border: none; background: transparent; color: var(--text-secondary); font-size: 1.25rem; line-height: 1; cursor: pointer; padding: 0; display: flex; align-items: center; justify-content: center; font-family: inherit; flex-shrink: 0; }
    .ob-close-x:hover { background: var(--accent-soft); color: var(--text); }
    .ob-back-btn { height: 28px; padding: 0 10px; border-radius: 8px; border: none; background: transparent; color: var(--text-secondary); font-size: 0.8125rem; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; font-family: inherit; flex-shrink: 0; }
    .ob-back-btn:hover { background: var(--accent-soft); color: var(--text); }
    .ob-skip-link { display: block; text-align: center; margin-top: 12px; font-size: 0.8125rem; color: var(--text-secondary); cursor: pointer; background: none; border: none; padding: 8px; font-family: inherit; width: 100%; }
    .ob-skip-link:hover { color: var(--accent); text-decoration: underline; }
    @keyframes obSlideUp { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
    .onboarding-card h2 { font-size: 1.25rem; margin: 0 0 6px; font-weight: 700; color: var(--text); }
    .onboarding-card .ob-subtitle { font-size: 0.9375rem; color: var(--text-secondary); margin: 0 0 20px; line-height: 1.45; }
    .ob-progress-bar { height: 4px; background: var(--accent-soft); border-radius: 2px; margin-bottom: 20px; overflow: hidden; }
    .ob-progress-fill { height: 100%; background: var(--accent); border-radius: 2px; transition: width 0.5s ease; }
    .ob-quiz-q { font-size: 0.9375rem; font-weight: 600; color: var(--text); margin: 0 0 12px; line-height: 1.45; }
    .ob-quiz-section-tag { display: inline-block; font-size: 0.75rem; color: var(--text-secondary); background: var(--accent-soft); padding: 2px 8px; border-radius: 4px; margin-bottom: 8px; }
    .ob-quiz-option { display: block; width: 100%; text-align: left; padding: 12px 16px; margin-bottom: 8px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; font-family: inherit; font-size: 0.9375rem; line-height: 1.4; transition: border-color 0.15s, background 0.15s; color: var(--text); }
    .ob-quiz-option:hover { border-color: var(--accent); background: var(--accent-soft); }
    .ob-quiz-option.selected { border-color: var(--accent); background: var(--accent-soft); }
    .ob-quiz-option.correct { border-color: var(--correct, #16a34a); background: rgba(34,197,94,0.1); pointer-events: none; }
    .ob-quiz-option.wrong { border-color: var(--wrong); background: var(--wrong-soft); pointer-events: none; }
    .ob-quiz-option.disabled { pointer-events: none; opacity: 0.6; }

    /* Self-assessment (Где ты сейчас?) */
    .ob-assess-legend { display: flex; gap: 12px; flex-wrap: wrap; font-size: 0.75rem; color: var(--text-secondary); margin: 8px 0 12px; }
    .ob-assess-legend-item { display: inline-flex; align-items: center; gap: 4px; }
    .ob-assess-legend-item::before { content: ''; width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
    .ob-assess-legend-item.ob-assess-know::before { background: #16a34a; }
    .ob-assess-legend-item.ob-assess-unsure::before { background: #f59e0b; }
    .ob-assess-legend-item.ob-assess-unknown::before { background: #dc2626; }
    .ob-assess-list { max-height: 44vh; overflow-y: auto; margin: 0 -4px 12px; padding: 0 4px; }
    .ob-assess-row { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border); }
    .ob-assess-row:last-child { border-bottom: none; }
    .ob-assess-name { flex: 1; min-width: 0; font-size: 0.875rem; color: var(--text); line-height: 1.3; }
    .ob-assess-marks { display: flex; gap: 6px; flex-shrink: 0; }
    .ob-assess-mark { width: 32px; height: 32px; border-radius: 8px; border: 1.5px solid var(--border); background: var(--surface); cursor: pointer; font-family: inherit; font-size: 0.9375rem; font-weight: 600; line-height: 1; display: flex; align-items: center; justify-content: center; padding: 0; color: var(--text-secondary); transition: border-color 0.15s, background 0.15s, color 0.15s; }
    .ob-assess-mark.ob-mark-know:hover, .ob-assess-mark.ob-mark-know.selected { border-color: #16a34a; background: rgba(22,163,74,0.12); color: #15803d; }
    .ob-assess-mark.ob-mark-unsure:hover, .ob-assess-mark.ob-mark-unsure.selected { border-color: #f59e0b; background: rgba(245,158,11,0.14); color: #b45309; }
    .ob-assess-mark.ob-mark-unknown:hover, .ob-assess-mark.ob-mark-unknown.selected { border-color: #dc2626; background: rgba(220,38,38,0.12); color: #b91c1c; }
    /* Прилипает к низу скроллящейся карточки — «Пропустить» и «Дальше» видны
       сразу, без долистывания длинного списка разделов (фидбэк Паши). */
    .ob-assess-actions { display: flex; flex-direction: column; gap: 6px; position: sticky; bottom: 0; background: var(--surface); padding: 8px 0 4px; margin-bottom: -4px; box-shadow: 0 -10px 14px -10px rgba(0,0,0,0.14); }
    .ob-assess-actions .ob-skip-link { margin-top: 0; }

    /* Coach-marks (tour after onboarding) */
    .ob-coachmark { position: absolute; z-index: 700; max-width: 320px; background: var(--surface); border: 1.5px solid var(--accent); border-radius: var(--radius); box-shadow: 0 8px 24px rgba(0,0,0,0.18); padding: 14px 16px; font-family: inherit; }
    .ob-coachmark h4 { margin: 0 0 6px; font-size: 0.9375rem; font-weight: 600; color: var(--text); }
    .ob-coachmark p { margin: 0 0 12px; font-size: 0.8125rem; color: var(--text); line-height: 1.45; }
    .ob-coach-arrow { position: absolute; width: 12px; height: 12px; background: var(--surface); border-left: 1.5px solid var(--accent); border-top: 1.5px solid var(--accent); transform: rotate(45deg); top: -7px; left: 24px; }
    .ob-coach-actions { display: flex; gap: 8px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
    .ob-coach-actions-right { display: inline-flex; gap: 8px; align-items: center; }
    .ob-coach-actions .btn-primary, .ob-coach-actions .btn-secondary { padding: 6px 14px; font-size: 0.8125rem; }
    .ob-coach-locate { background: transparent; border: 1px solid var(--border); color: var(--text-secondary); border-radius: 8px; cursor: pointer; font-family: inherit; }
    .ob-coach-locate:hover { color: var(--text); border-color: var(--accent); }
    .ob-coach-highlight { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: var(--radius-sm); transition: outline 0.2s; }
    /* Post-онбординг по возвратам — карточка-нудж снизу справа. */
    .ob-intro-card { position: fixed; right: 20px; bottom: 20px; z-index: 720; width: 320px; max-width: calc(100vw - 32px); background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--accent); border-radius: var(--radius); box-shadow: 0 10px 30px rgba(0,0,0,0.22); padding: 14px 16px; font-family: inherit; animation: obIntroIn 0.32s cubic-bezier(0.22,1,0.36,1); }
    @keyframes obIntroIn { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
    .ob-intro-card.ob-intro-out { animation: obIntroOut 0.22s ease forwards; }
    @keyframes obIntroOut { to { opacity: 0; transform: translateY(16px); } }
    .ob-intro-card .ob-intro-step-num { font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.03em; text-transform: uppercase; color: var(--accent); margin: 0 0 4px; }
    .ob-intro-card h4 { margin: 0 0 6px; font-size: 0.9375rem; font-weight: 600; color: var(--text); padding-right: 20px; }
    .ob-intro-card p { margin: 0 0 12px; font-size: 0.8125rem; color: var(--text); line-height: 1.45; }
    .ob-intro-card .ob-intro-close { position: absolute; top: 8px; right: 10px; background: none; border: none; font-size: 1.15rem; line-height: 1; color: var(--text-secondary); cursor: pointer; padding: 2px 4px; }
    .ob-intro-card .ob-intro-close:hover { color: var(--text); }
    .ob-intro-card .ob-coach-actions { display: flex; gap: 8px; justify-content: flex-end; }
    @media (max-width: 480px) { .ob-intro-card { right: 12px; left: 12px; bottom: 12px; width: auto; } }
    @media (prefers-reduced-motion: reduce) { .ob-intro-card, .ob-intro-card.ob-intro-out { animation: none; } }
    /* Карточка, «упавшая» в блок уведомлений. */
    .ob-intro-notif [data-ob-intro-locate] { cursor: pointer; }

    .ob-gap-list { margin: 16px 0; }
    .ob-gap-item { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); }
    .ob-gap-item:last-child { border-bottom: none; }
    .ob-gap-badge { width: 40px; height: 40px; border-radius: 10px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; font-size: 0.8125rem; font-weight: 700; }
    .ob-gap-badge.strong { background: rgba(34,197,94,0.12); color: #16a34a; }
    .ob-gap-badge.weak { background: var(--wrong-soft); color: var(--wrong); }
    .ob-gap-name { font-size: 0.9375rem; font-weight: 500; color: var(--text); flex: 1; }
    .ob-gap-label { font-size: 0.75rem; color: var(--text-secondary); font-weight: 600; }
    .ob-gap-label.weak { color: var(--wrong, #b91c1c); }
    .ob-gap-label.strong { color: #16a34a; }
    .ob-score-big { text-align: center; margin: 20px 0; }
    .ob-score-big .ob-score-num { font-size: 2.5rem; font-weight: 700; color: var(--accent); }
    .ob-score-big .ob-score-total { font-size: 1.25rem; color: var(--text-secondary); }
    .ob-streak-intro { text-align: center; padding: 20px 0 8px; }
    .ob-streak-fire { font-size: 3rem; margin-bottom: 8px; }

    /* ── Onboarding checklist banner ───────────────────────────────── */
    .ob-checklist-banner { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px; margin-bottom: 20px; box-shadow: var(--shadow); }
    .ob-checklist-banner h3 { font-size: 0.875rem; font-weight: 600; color: var(--text-secondary); margin: 0 0 10px; text-transform: uppercase; letter-spacing: 0.04em; }
    .ob-checklist-items { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 16px; }
    @media (max-width: 480px) { .ob-checklist-items { grid-template-columns: 1fr; } }
    .ob-checklist-item { display: flex; align-items: center; gap: 8px; font-size: 0.875rem; color: var(--text); padding: 4px 0; }
    .ob-checklist-item.done { color: var(--text-secondary); }
    .ob-checklist-item .ob-check { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--border); display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.6875rem; }
    .ob-checklist-item.done .ob-check { background: var(--accent); border-color: var(--accent); color: #fff; }
    .ob-checklist-item a { color: var(--accent); text-decoration: none; cursor: pointer; }
    .ob-checklist-item a:hover { text-decoration: underline; }
    .ob-checklist-dismiss { display: inline-block; font-size: 0.75rem; color: var(--text-secondary); cursor: pointer; margin-top: 8px; background: none; border: none; padding: 0; font-family: inherit; }
    .ob-checklist-dismiss:hover { color: var(--accent); }
    /* Схлопнутый «Твой старт» (≥80% выполнено) — одна строка с чевроном. */
    .ob-checklist-collapsible .ob-checklist-summary { display: flex; align-items: center; gap: 8px; width: 100%; background: none; border: none; padding: 0; margin: 0; font-family: inherit; font-size: 0.875rem; font-weight: 600; color: var(--text); cursor: pointer; text-align: left; }
    .ob-checklist-collapsible .ob-checklist-summary .ob-check { width: 18px; height: 18px; border-radius: 50%; background: var(--accent); border: 1.5px solid var(--accent); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: 0.6875rem; }
    .ob-checklist-summary-text { flex: 1; }
    .ob-checklist-summary-chev { font-size: 0.75rem; opacity: 0.7; transition: transform 0.18s var(--ease); }
    .ob-checklist-collapsible:not(.ob-checklist-collapsed) .ob-checklist-summary-chev { transform: rotate(180deg); }
    .ob-checklist-collapsible.ob-checklist-collapsed .ob-checklist-items,
    .ob-checklist-collapsible.ob-checklist-collapsed .ob-checklist-dismiss { display: none; }
    .ob-checklist-collapsible:not(.ob-checklist-collapsed) .ob-checklist-items { margin-top: 12px; }

    /* ── New welcome-flow: goal-check, self-assessment, coach-marks ── */
    .ob-error { color: var(--wrong, #b91c1c); font-size: 0.8125rem; margin: 8px 0 0; min-height: 1em; }
    .ob-hint { font-size: 0.8125rem; color: var(--text-secondary); margin: 8px 0 0; }
    .ob-quiz-counter { font-size: 0.75rem; color: var(--text-secondary); margin: 12px 0 0; text-align: center; }

    /* Goal-check (multi-select grid) */
    .ob-goal-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin: 16px 0 4px; }
    .ob-goal-option { position: relative; display: grid; grid-template-columns: 36px 1fr 18px; align-items: start; gap: 10px; width: 100%; padding: 14px 14px 14px 14px; border: 1.5px solid var(--border); border-radius: var(--radius-md, 12px); background: var(--surface); cursor: pointer; font-family: inherit; transition: border-color 0.15s, background 0.15s, transform 0.12s, box-shadow 0.15s; text-align: left; box-shadow: 0 1px 2px rgba(0,0,0,.02); }
    .ob-goal-option:hover { border-color: var(--accent); background: var(--accent-soft); }
    .ob-goal-option:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(190, 24, 93, 0.15); }
    .ob-goal-option.selected { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 1px 3px rgba(190, 24, 93, 0.1); }
    .ob-goal-emoji { font-size: 22px; line-height: 1; display: flex; align-items: center; justify-content: center; }
    .ob-goal-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
    .ob-goal-title { display: block; font-size: 0.9375rem; font-weight: 600; color: var(--text); line-height: 1.3; }
    .ob-goal-hint { display: block; font-size: 0.8125rem; color: var(--text-secondary); line-height: 1.35; }
    .ob-goal-pick { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--border); background: var(--surface); transition: border-color 0.15s, background 0.15s; position: relative; margin-top: 2px; }
    .ob-goal-option.selected .ob-goal-pick { border-color: var(--accent); background: var(--accent); }
    .ob-goal-option.selected .ob-goal-pick::after { content: ''; position: absolute; left: 4px; top: 1px; width: 5px; height: 9px; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
    .ob-goal-custom { margin: 12px 0 0; }
    .ob-goal-custom label { display: block; font-size: 0.8125rem; color: var(--text-secondary); margin-bottom: 6px; }
    .ob-goal-custom input { width: 100%; padding: 10px 12px; border: 1.5px solid var(--border); border-radius: var(--radius-sm); font-family: inherit; font-size: 0.9375rem; box-sizing: border-box; background: var(--surface); color: var(--text); }
    .ob-goal-custom input:focus { outline: none; border-color: var(--accent); }
    @media (max-width: 480px) { .ob-goal-grid { grid-template-columns: 1fr; } }

/* ============================================================
   Cabinet loading skeleton — «сборочная» анимация
   ============================================================ */

.cabinet-loading-wrap { padding: 0; }
.cabinet-loading-wrap.visible {
  display: block;
  animation: cab-skel-stage 0.4s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes cab-skel-stage {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Плавный переход «Собираем кабинет…» → реальный кабинет.
   Важно: без transform в keyframes — иначе translateY(0) после fill:both
   делает #cabinetBlock containing block для position:fixed потомков,
   и модалки вроде editProfileModal уезжают в центр документа, а не viewport. */
#cabinetBlock.visible {
  animation: cabinet-block-in 0.5s ease-out both;
}
@keyframes cabinet-block-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

.cab-skel {
  max-width: 720px;
  margin: 0 auto;
  padding: 12px 12px 56px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: var(--accent, #be185d);
  --skel-tint: 190, 24, 93;
}

/* ── Status pill ── */
.cab-skel-status {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  gap: 9px;
  padding: 7px 14px 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(var(--skel-tint), 0.18);
  background: var(--surface, #fff);
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--text-secondary, #6b7280);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 0 0 4px rgba(var(--skel-tint), 0.04);
  margin: 4px 0 2px;
  opacity: 0;
  transform: translateY(-8px) scale(0.92);
  animation: cab-skel-status-in 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) 0.05s forwards;
}
@keyframes cab-skel-status-in {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.cab-skel-status-text {
  transition: opacity 0.28s ease, transform 0.28s ease;
}
.cab-skel-status-text.is-swapping {
  opacity: 0;
  transform: translateY(-4px);
}
@media (prefers-reduced-motion: reduce) {
  .cab-skel-status-text { transition: opacity 0.28s ease; }
  .cab-skel-status-text.is-swapping { transform: none; }
}
.cab-skel-status-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent, #be185d);
  animation: cab-skel-dot-pulse 1.8s cubic-bezier(0.4, 0, 0.6, 1) infinite 0.7s;
}
@keyframes cab-skel-dot-pulse {
  0%, 100% { transform: scale(0.85); box-shadow: 0 0 0 0 rgba(var(--skel-tint), 0.5); }
  50%      { transform: scale(1.15); box-shadow: 0 0 0 7px rgba(var(--skel-tint), 0); }
}
.cab-skel-status-dots {
  display: inline-flex;
  gap: 3px;
  align-items: flex-end;
  margin-left: -2px;
  height: 0.9em;
}
.cab-skel-status-dots i {
  width: 3px; height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.3;
  animation: cab-skel-text-dots 1.4s ease-in-out infinite;
}
.cab-skel-status-dots i:nth-child(2) { animation-delay: 0.18s; }
.cab-skel-status-dots i:nth-child(3) { animation-delay: 0.36s; }
@keyframes cab-skel-text-dots {
  0%, 80%, 100% { opacity: 0.3; transform: translateY(0); }
  40%           { opacity: 1;   transform: translateY(-3px); }
}

/* ── Card — лёгкий «stamp-in» с overshoot ── */
.cab-skel-card {
  position: relative;
  background: var(--surface, #fff);
  border: 1px solid rgba(var(--skel-tint), 0.14);
  border-radius: 16px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow:
    0 1px 2px rgba(0, 0, 0, 0.02),
    0 4px 18px -10px rgba(var(--skel-tint), 0.08);
  overflow: hidden;
  opacity: 0;
  transform: translateY(14px) scale(0.965);
  animation: cab-skel-card-in 0.7s cubic-bezier(0.22, 1.4, 0.36, 1) forwards;
  animation-delay: var(--cab-skel-delay, 0ms);
}
@keyframes cab-skel-card-in {
  0%   { opacity: 0; transform: translateY(14px) scale(0.965); }
  60%  { opacity: 1; transform: translateY(0) scale(1.012); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

/* Глянцевая полоса, проезжающая по карточке после её «выезда». */
.cab-skel-card::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    105deg,
    transparent 35%,
    rgba(255, 255, 255, 0.65) 50%,
    transparent 65%
  );
  transform: translateX(-110%);
  animation: cab-skel-sweep 3.2s cubic-bezier(0.6, 0, 0.4, 1) infinite;
  animation-delay: calc(var(--cab-skel-delay, 0ms) + 700ms);
  pointer-events: none;
  mix-blend-mode: screen;
}
@keyframes cab-skel-sweep {
  0%   { transform: translateX(-110%); }
  70%  { transform: translateX(130%); }
  100% { transform: translateX(130%); }
}

/* ── Shape (line / pill / dot / bar) — «pop-in» с bounce, потом shimmer ── */
.cab-skel-shape {
  background: linear-gradient(
    90deg,
    rgba(var(--skel-tint), 0.07) 0%,
    rgba(var(--skel-tint), 0.18) 50%,
    rgba(var(--skel-tint), 0.07) 100%
  );
  background-size: 240% 100%;
  background-position: 100% 0;
  border-radius: 6px;
  flex-shrink: 0;
  opacity: 0;
  transform: scale(0.4);
  transform-origin: center;
  animation:
    cab-skel-pop 0.55s cubic-bezier(0.34, 1.5, 0.5, 1) forwards,
    cab-skel-shimmer 2.6s ease-in-out infinite;
  animation-delay:
    calc(var(--cab-skel-delay, 0ms) + 350ms + (var(--cab-skel-i, 0) * 70ms)),
    calc(var(--cab-skel-delay, 0ms) + 900ms);
}
@keyframes cab-skel-pop {
  0%   { opacity: 0; transform: scale(0.4); }
  60%  { opacity: 1; transform: scale(1.04); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes cab-skel-shimmer {
  0%   { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

/* Линии/бары/пиллы — вытягиваются от левого края, чтобы выглядело как «прорисовка». */
.cab-skel-line,
.cab-skel-pill,
.cab-skel-chip,
.cab-skel-bar {
  transform-origin: left center;
  transform: scaleX(0.04);
}
.cab-skel-line,
.cab-skel-pill,
.cab-skel-chip,
.cab-skel-bar {
  animation:
    cab-skel-grow-x 0.55s cubic-bezier(0.22, 1.2, 0.36, 1) forwards,
    cab-skel-shimmer 2.6s ease-in-out infinite;
  animation-delay:
    calc(var(--cab-skel-delay, 0ms) + 350ms + (var(--cab-skel-i, 0) * 70ms)),
    calc(var(--cab-skel-delay, 0ms) + 900ms);
}
@keyframes cab-skel-grow-x {
  0%   { opacity: 0; transform: scaleX(0.04); }
  60%  { opacity: 1; transform: scaleX(1.02); }
  100% { opacity: 1; transform: scaleX(1); }
}

/* Стаггер: каждая строка в .cab-skel-rows — слегка позже предыдущей. */
.cab-skel-card-head             { --cab-skel-i: 0; }
.cab-skel-rows > *:nth-child(1) { --cab-skel-i: 1; }
.cab-skel-rows > *:nth-child(2) { --cab-skel-i: 2; }
.cab-skel-rows > *:nth-child(3) { --cab-skel-i: 3; }
.cab-skel-rows > *:nth-child(4) { --cab-skel-i: 4; }
.cab-skel-card-head { display: flex; align-items: center; gap: 10px; }
.cab-skel-card-head .cab-skel-pill--right { margin-left: auto; }

.cab-skel-line       { height: 10px; width: 100%; border-radius: 5px; }
.cab-skel-line--sm   { height: 8px; opacity: 0.7; }
.cab-skel-line--w15  { width: 15%;  min-width: 36px; }
.cab-skel-line--w35  { width: 35%; }
.cab-skel-line--w40  { width: 40%; }
.cab-skel-line--w45  { width: 45%; }
.cab-skel-line--w50  { width: 50%; }
.cab-skel-line--w55  { width: 55%; }
.cab-skel-line--w60  { width: 60%; }
.cab-skel-line--w65  { width: 65%; }
.cab-skel-line--w70  { width: 70%; }

.cab-skel-chip { width: 64px; height: 24px; border-radius: 999px; }
.cab-skel-pill { width: 70px; height: 22px; border-radius: 999px; }
.cab-skel-pill--sm { width: 56px; height: 18px; }
.cab-skel-dot  { width: 18px; height: 18px; border-radius: 50%; }

.cab-skel-rows {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cab-skel-rows--wide { gap: 18px; }
.cab-skel-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.cab-skel-row .cab-skel-line { flex: 1 1 auto; min-width: 0; }
.cab-skel-row .cab-skel-pill { margin-left: auto; }
.cab-skel-row--lg { gap: 14px; }
.cab-skel-row-stack {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
}
.cab-skel-tile { width: 44px; height: 44px; border-radius: 12px; }

/* ── Widgets row (streak + лига) ── */
.cab-skel-widgets {
  display: flex;
  gap: 12px;
  align-items: stretch;
}
.cab-skel-card-streak {
  flex: 0 0 200px;
  align-items: center;
  text-align: center;
  justify-content: center;
  padding: 24px 18px;
}
.cab-skel-card-streak .cab-skel-emoji {
  width: 44px; height: 44px; border-radius: 50%;
}
.cab-skel-card-streak .cab-skel-line { margin: 0 auto; }
.cab-skel-card-league { flex: 1 1 auto; min-width: 0; }
.cab-skel-league-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cab-skel-league-rows > *:nth-child(1) { --cab-skel-i: 1; }
.cab-skel-league-rows > *:nth-child(2) { --cab-skel-i: 2; }
.cab-skel-league-rows > *:nth-child(3) { --cab-skel-i: 3; }
.cab-skel-rank { width: 26px; height: 26px; border-radius: 50%; }

/* ── Spider — самая «вкусная» анимация: лучи рисуются из центра,
       узлы по очереди впрыгивают на концы. ── */
.cab-skel-spider {
  /* Квадрат: проценты узлов (.cab-skel-node) живут в той же системе координат,
     что и SVG-вьюбокс 200×200 (xMidYMid meet). Иначе на нестандартной ширине
     узлы сползают с концов лучей и скелетон выглядит кривым. */
  position: relative;
  width: 100%;
  max-width: 240px;
  aspect-ratio: 1 / 1;
  margin: 4px auto 6px;
}
.cab-skel-spider-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--accent, #be185d);
  overflow: visible;
}
.cab-skel-spoke {
  /* Длина каждого луча в SVG-координатах ≈ 80 (см. координаты в HTML). */
  stroke-dasharray: 80;
  stroke-dashoffset: 80;
  opacity: 0;
  animation: cab-skel-spoke-draw 0.65s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  animation-delay: calc(var(--cab-skel-delay, 0ms) + 400ms + (var(--cab-skel-i, 0) * 90ms));
}
.cab-skel-spoke--1 { --cab-skel-i: 0; }
.cab-skel-spoke--2 { --cab-skel-i: 1; }
.cab-skel-spoke--3 { --cab-skel-i: 2; }
.cab-skel-spoke--4 { --cab-skel-i: 3; }
.cab-skel-spoke--5 { --cab-skel-i: 4; }
.cab-skel-spoke--6 { --cab-skel-i: 5; }
@keyframes cab-skel-spoke-draw {
  0%   { stroke-dashoffset: 80; opacity: 0; }
  20%  {                         opacity: 0.7; }
  100% { stroke-dashoffset: 0;  opacity: 0.55; }
}

.cab-skel-node {
  position: absolute;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  background: radial-gradient(
    circle at 30% 30%,
    rgba(var(--skel-tint), 0.45) 0%,
    rgba(var(--skel-tint), 0.22) 60%,
    rgba(var(--skel-tint), 0.12) 100%
  );
  box-shadow: 0 0 0 0 rgba(var(--skel-tint), 0.25);
  opacity: 0;
  transform: scale(0);
  animation:
    cab-skel-node-pop 0.55s cubic-bezier(0.34, 1.7, 0.5, 1) forwards,
    cab-skel-node-breathe 3.2s ease-in-out infinite;
  animation-delay:
    calc(var(--cab-skel-delay, 0ms) + 700ms + (var(--cab-skel-i, 0) * 90ms)),
    calc(var(--cab-skel-delay, 0ms) + 1300ms);
}
@keyframes cab-skel-node-pop {
  0%   { opacity: 0; transform: scale(0); box-shadow: 0 0 0 0 rgba(var(--skel-tint), 0.4); }
  60%  { opacity: 1; transform: scale(1.15); box-shadow: 0 0 0 8px rgba(var(--skel-tint), 0); }
  100% { opacity: 1; transform: scale(1); box-shadow: 0 0 0 0 rgba(var(--skel-tint), 0); }
}
@keyframes cab-skel-node-breathe {
  0%, 100% { filter: brightness(1) saturate(1); }
  50%      { filter: brightness(1.08) saturate(1.15); }
}
/* Узлы расположены вокруг центра. Translate в animation сохраняем через position+inset. */
/* Координаты концов лучей в SVG: центр (100,100), радиус 80, шестиугольник.
   Делим на 200 → проценты квадратного контейнера, центрируем поправкой -12px (½×24). */
.cab-skel-node--center { width: 40px; height: 40px; top: calc(50% - 20px);   left: calc(50% - 20px);   --cab-skel-i: 0; }
.cab-skel-node--n1 { top: calc(10% - 12px); left: calc(50% - 12px);   --cab-skel-i: 1; }
.cab-skel-node--n2 { top: calc(30% - 12px); left: calc(84.5% - 12px); --cab-skel-i: 2; }
.cab-skel-node--n3 { top: calc(70% - 12px); left: calc(84.5% - 12px); --cab-skel-i: 3; }
.cab-skel-node--n4 { top: calc(90% - 12px); left: calc(50% - 12px);   --cab-skel-i: 4; }
.cab-skel-node--n5 { top: calc(70% - 12px); left: calc(15.5% - 12px); --cab-skel-i: 5; }
.cab-skel-node--n6 { top: calc(30% - 12px); left: calc(15.5% - 12px); --cab-skel-i: 6; }

/* ── Progress — бары заполняются от 0 до своей ширины ── */
.cab-skel-progress-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.cab-skel-rows--wide > *:nth-child(1) { --cab-skel-i: 1; }
.cab-skel-rows--wide > *:nth-child(2) { --cab-skel-i: 2; }
.cab-skel-rows--wide > *:nth-child(3) { --cab-skel-i: 3; }
.cab-skel-progress-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.cab-skel-bar {
  height: 8px;
  border-radius: 4px;
  width: 100%;
}
.cab-skel-bar--w65 { width: 65%; }
.cab-skel-bar--w80 { width: 80%; }

/* ── Reduced motion: всё статично, никаких прыжков ── */
@media (prefers-reduced-motion: reduce) {
  .cab-skel-status,
  .cab-skel-card,
  .cab-skel-shape,
  .cab-skel-line,
  .cab-skel-pill,
  .cab-skel-chip,
  .cab-skel-bar,
  .cab-skel-node,
  .cab-skel-spoke,
  .cab-skel-status-dot,
  .cab-skel-status-dots i,
  .cab-skel-card::after { animation: none !important; }
  .cab-skel-card,
  .cab-skel-status,
  .cab-skel-shape,
  .cab-skel-node { opacity: 1; transform: none; }
  .cab-skel-line, .cab-skel-pill, .cab-skel-chip, .cab-skel-bar { transform: scaleX(1); opacity: 1; }
  .cab-skel-spoke { stroke-dashoffset: 0; opacity: 0.5; }
}

/* Inline-вариант скелетона: рисуется как плейсхолдер ВНУТРИ уже видимого
   кабинета (когда chain ещё не дорисовал блок). Никаких bounce-in и sweep —
   только мягкий шиммер, чтобы продолжать «то же» визуальное состояние,
   которое было на «Собираем кабинет». */
.cab-skel-card.cab-skel-inline {
  opacity: 1;
  transform: none;
  animation: cab-skel-inline-fade 0.35s ease-out both;
  margin-bottom: 16px;
}
@keyframes cab-skel-inline-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.cab-skel-inline::after { display: none; }
.cab-skel-inline .cab-skel-shape,
.cab-skel-inline .cab-skel-line,
.cab-skel-inline .cab-skel-pill,
.cab-skel-inline .cab-skel-chip,
.cab-skel-inline .cab-skel-bar,
.cab-skel-inline .cab-skel-dot,
.cab-skel-inline .cab-skel-rank,
.cab-skel-inline .cab-skel-tile,
.cab-skel-inline .cab-skel-node {
  opacity: 1;
  transform: none;
  animation: cab-skel-shimmer 2.6s ease-in-out infinite;
}
.cab-skel-inline .cab-skel-spoke {
  stroke-dasharray: none;
  stroke-dashoffset: 0;
  opacity: 0.45;
  animation: none;
}
.cab-skel-inline .cab-skel-node {
  animation: cab-skel-node-breathe 3.2s ease-in-out infinite;
}

@media (max-width: 560px) {
  .cab-skel { padding: 8px 8px 40px; gap: 12px; }
  .cab-skel-widgets { flex-direction: column; }
  .cab-skel-card-streak { flex: 1; padding: 18px; }
  .cab-skel-card { padding: 16px; border-radius: 14px; }
  .cab-skel-spider { max-width: 220px; }
  .cab-skel-inline .cab-skel-spider { max-width: 200px; }
}

/* Quick action row — three buttons under streak (league / SRS / AI-tutor),
   копирует мобильный паттерн. Лига и SRS раскрываются inline; AI-тьютор
   открывает существующую rag-panel через клик по cabinetTutorFab. */
.cab-quick-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 0 0 20px;
}
.cab-quick-btn {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 8px;
  min-height: 96px;
  background: var(--surface, #fff);
  border: 1px solid var(--border);
  border-radius: 14px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.18s var(--ease), background 0.18s var(--ease), transform 0.12s var(--ease), color 0.18s var(--ease);
}
.cab-quick-btn:hover { border-color: var(--accent); background: rgba(13, 148, 136, 0.06); }
.cab-quick-btn:active { transform: translateY(1px); }
.cab-quick-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cab-quick-btn.is-active { border-color: var(--accent); background: rgba(13, 148, 136, 0.1); }
.cab-quick-btn-league .cab-quick-icon { color: #d97706; }
.cab-quick-btn-league.is-active { background: rgba(217, 119, 6, 0.12); border-color: #d97706; }
.cab-quick-btn-srs .cab-quick-icon { color: #16a34a; }
.cab-quick-btn-srs.is-active { background: rgba(22, 163, 74, 0.1); border-color: #16a34a; }
.cab-quick-btn-tutor .cab-quick-icon { color: #2563eb; }
.cab-quick-btn-tutor:hover { background: rgba(37, 99, 235, 0.08); border-color: #2563eb; }
.cab-quick-icon { font-size: 1.6rem; line-height: 1; display: inline-flex; align-items: center; justify-content: center; }
.cab-quick-icon svg { display: block; }
.cab-quick-label { font-size: 0.875rem; line-height: 1.15; text-align: center; }
.cab-quick-badge {
  position: absolute; top: 8px; right: 10px;
  min-width: 22px; height: 22px; padding: 0 7px;
  border-radius: 11px; background: var(--accent); color: #fff;
  font-size: 0.72rem; font-weight: 700;
  display: none; align-items: center; justify-content: center; line-height: 1;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}
.cab-quick-badge.visible { display: inline-flex; }
.cab-quick-badge-league { background: #d97706; }
.cab-quick-badge-srs { background: #16a34a; }
.cab-quick-pane[hidden] { display: none; }
.cab-quick-pane.expanded {
  display: block;
  animation: cab-quick-expand 0.26s var(--ease);
}
@keyframes cab-quick-expand {
  from { opacity: 0; transform: translateY(-6px); }
  to { opacity: 1; transform: translateY(0); }
}
body.cabinet-speedup-only .cab-quick-row,
body.cabinet-speedup-only #leagueBlock,
body.cabinet-speedup-only #srsReviewBlock { display: none !important; }
@media (max-width: 480px) {
  .cab-quick-row { gap: 8px; margin-bottom: 16px; }
  .cab-quick-btn { padding: 14px 4px; min-height: 88px; }
  .cab-quick-icon { font-size: 1.4rem; }
  .cab-quick-label { font-size: 0.8rem; }
  .cab-quick-badge { top: 6px; right: 8px; min-width: 20px; height: 20px; padding: 0 6px; font-size: 0.68rem; }
}

/* ===== STICKY CONTINUE BAR (mobile only) ===== */
.cabinet-continue-bar { display: none; }
@media (max-width: 720px) {
  .cabinet-continue-bar {
    position: fixed;
    left: 10px;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom, 0px));
    z-index: 250;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: var(--accent);
    color: #fff;
    text-decoration: none;
    border-radius: 14px;
    box-shadow: 0 10px 28px rgba(13, 148, 136, 0.32), 0 2px 8px rgba(0, 0, 0, 0.08);
    font-family: inherit;
    font-size: 0.9375rem;
    line-height: 1.2;
    transform: translateY(0);
    transition: transform 0.25s var(--ease), opacity 0.2s ease;
  }
  .cabinet-continue-bar:not([hidden]) { display: flex; }
  .cabinet-continue-bar:active { transform: translateY(1px); }
  .cabinet-continue-bar-icon {
    width: 32px; height: 32px; border-radius: 50%;
    background: rgba(255, 255, 255, 0.22);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
  }
  .cabinet-continue-bar-text {
    flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px;
    overflow: hidden;
  }
  .cabinet-continue-bar-title { font-weight: 600; }
  .cabinet-continue-bar-subtitle {
    font-size: 0.75rem;
    opacity: 0.88;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .cabinet-continue-bar-subtitle:empty { display: none; }
  .cabinet-continue-bar-arrow { font-size: 1.15rem; opacity: 0.85; flex-shrink: 0; }

  body.has-cabinet-continue-bar { padding-bottom: calc(72px + env(safe-area-inset-bottom, 0px)); }
  body.has-cabinet-continue-bar #cabinetScrollFabWrap {
    bottom: calc(72px + max(10px, env(safe-area-inset-bottom, 0px)));
  }
  body.has-cabinet-continue-bar .rag-fab {
    bottom: calc(72px + max(10px, env(safe-area-inset-bottom, 0px)) + 6px);
  }
  body.has-cabinet-continue-bar .ob-video-fab {
    bottom: calc(72px + max(10px, env(safe-area-inset-bottom, 0px)) + 6px + 48px);
  }
  /* Помодоро-🍅 — на целый слот (52px) ВЫШЕ видео-FAB, иначе томат садится
     ему на кнопку плеера (жёсткий bottom:176 даёт всего ~4px зазора). */
  body.has-cabinet-continue-bar #pomoRoot {
    bottom: calc(72px + max(10px, env(safe-area-inset-bottom, 0px)) + 6px + 48px + 52px);
  }
}

/* ===================================================================
   Mobile bottom tab bar (cab-tabbar)
   Группирует длинную ленту кабинета в 4 вью на телефоне.
   Включается только из JS (body.cab-tabbar-on) на ширине <=768px.
   =================================================================== */
#cabTabBar {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 120;
  background: var(--surface);
  border-top: 1px solid var(--border);
  box-shadow: 0 -2px 16px rgba(0, 0, 0, 0.06);
  padding: 6px 6px calc(6px + env(safe-area-inset-bottom, 0px));
  box-sizing: border-box;
}
body.cab-tabbar-on #cabTabBar { display: block; }
/* Когда открыт модал / шторка / панель тьютора — бар прячем, чтобы не лез поверх */
body.cab-tabbar-on:has(.modal-overlay.visible) #cabTabBar,
body.cab-tabbar-on:has(.rag-panel-overlay.visible) #cabTabBar,
body.cab-tabbar-on:has(.skill-tree-sheet-overlay.visible) #cabTabBar,
body.cab-tabbar-on:has(.onboarding-overlay.visible) #cabTabBar { display: none; }
/* Пока открыт оверлей онбординга — прячем плавающие кнопки справа (фидбэк-«?»,
   AI-тьютор 🎓, welcome-видео, скролл-стрелки): они с z-index выше оверлея и
   лезли поверх карточки плана (фидбэк Паши). */
body:has(.onboarding-overlay.visible) .fbk-fab,
body:has(.onboarding-overlay.visible) #cabinetTutorFab,
body:has(.onboarding-overlay.visible) .ob-video-fab,
body:has(.onboarding-overlay.visible) #cabinetScrollFabWrap { display: none !important; }
.cab-tab-inner {
  display: flex;
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  gap: 2px;
}
.cab-tab-btn {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 6px 2px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  color: var(--text-secondary);
  border-radius: 12px;
  transition: color 0.15s ease, background 0.15s ease, transform 0.08s ease;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
  will-change: transform;
}
.cab-tab-btn .cab-tab-ico { font-size: 1.35rem; line-height: 1; transition: transform 0.15s ease; }
.cab-tab-btn .cab-tab-lbl { font-size: 0.6875rem; font-weight: 600; letter-spacing: -0.01em; line-height: 1; }
/* Вжатие: палец давит — кнопка проседает и темнеет, отпустил — отскок */
.cab-tab-btn:active { background: var(--accent-soft); transform: scale(0.88); transition-duration: 0.04s; }
.cab-tab-btn:active .cab-tab-ico { transform: scale(0.92); }
.cab-tab-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
/* Выбранная вкладка читается как залитая пилюля, а не просто перекрашенный текст */
.cab-tab-btn.active { color: var(--accent); background: var(--accent-soft); }
.cab-tab-btn.active .cab-tab-ico { transform: translateY(-1px); }
.cab-tab-btn.active:active .cab-tab-ico { transform: translateY(-1px) scale(0.92); }
body.pussy-power .cab-tab-btn.active { color: #db2777; background: rgba(219, 39, 119, 0.1); }
body.pussy-power .cab-tab-btn:active { background: rgba(219, 39, 119, 0.16); }

/* Навигацию на мобиле ведёт нижний бар — верхние пилюли и ⬆⬇-кнопки убираем */
body.cab-tabbar-on .cabinet-nav-sticky-wrap { display: none !important; }
body.cab-tabbar-on #cabinetScrollFabWrap { display: none !important; }
/* Прячем всё, что не в активном вью */
body.cab-tabbar-on .cab-vblock:not(.cab-vblock-active) { display: none !important; }
/* Воздух над баром, чтобы последний блок не уезжал под него */
body.cab-tabbar-on #cabinetBlock { padding-bottom: 84px; }
/* «Продолжить обучение» оставляем — приподнимаем над таб-баром
   (нижний отступ тела уже даёт has-cabinet-continue-bar, доп. не нужен) */
body.cab-tabbar-on .cabinet-continue-bar { bottom: calc(58px + env(safe-area-inset-bottom, 0px)) !important; }
/* Кнопка AI-тьютора — над баром (а если есть «Продолжить» — ещё выше) */
body.cab-tabbar-on .rag-fab { bottom: calc(max(24px, env(safe-area-inset-bottom, 0px)) + 70px) !important; }
body.cab-tabbar-on.has-cabinet-continue-bar .rag-fab { bottom: calc(120px + env(safe-area-inset-bottom, 0px)) !important; }
body.cab-tabbar-on.has-cabinet-continue-bar .ob-video-fab { bottom: calc(172px + env(safe-area-inset-bottom, 0px)) !important; }
/* Значок «?» опроса (.fbk-fab) — статичный bottom:124px, поднимаем над всем стеком */
body.cab-tabbar-on .fbk-fab { bottom: calc(82px + env(safe-area-inset-bottom, 0px)) !important; }
body.cab-tabbar-on.has-cabinet-continue-bar .fbk-fab { bottom: calc(224px + env(safe-area-inset-bottom, 0px)) !important; }
/* Помодоро-🍅 — топ правого стека: на 52px выше самого высокого FAB в каждом
   состоянии бара, чтобы не накрывал видео-плеер/«?» (его bottom:176 — для десктопа). */
body.cab-tabbar-on #pomoRoot { bottom: calc(max(24px, env(safe-area-inset-bottom, 0px)) + 70px + 52px) !important; }
body.cab-tabbar-on.has-cabinet-continue-bar #pomoRoot { bottom: calc(224px + env(safe-area-inset-bottom, 0px) + 52px) !important; }

/* На десктопе бар не существует ни при каких классах */
@media (min-width: 769px) {
  #cabTabBar { display: none !important; }
}

/* Возвращенец: истёкший доступ — read-only тизер сохранённого прогресса + продление */
.returning-lapsed { border-color: var(--accent-soft); }
.returning-lapsed-title { font-size: 1.25rem; margin: 0 0 8px; color: var(--text); }
.returning-lapsed-sub { margin: 0 0 18px; color: var(--text-muted, #6b7280); line-height: 1.5; }
.returning-lapsed-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.returning-lapsed-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px;
  background: var(--accent-soft); opacity: 0.85;
}
.returning-lapsed-item .rl-lock { font-size: 1rem; flex: 0 0 auto; filter: grayscale(0.2); }
.returning-lapsed-item .rl-text { min-width: 0; }
.returning-lapsed-item .rl-title { font-weight: 600; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.returning-lapsed-item .rl-sub { font-size: 0.8125rem; color: var(--text-muted, #6b7280); margin-top: 2px; }
.returning-lapsed-cta { display: inline-block; }

.sbp-promo-badge {
  margin: 8px 0 12px;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.875rem;
  line-height: 1.45;
  background: rgba(13,148,136,0.08);
  border: 1px solid rgba(13,148,136,0.22);
  color: var(--text);
}
.sbp-promo-badge--error {
  background: rgba(220,38,38,0.07);
  border-color: rgba(220,38,38,0.22);
  color: var(--wrong, #c00);
}
.kr-extra-materials { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; padding: 10px 12px; margin: 4px 0 8px; background: var(--accent-soft); border: 1px solid var(--border); border-radius: var(--radius-sm, 8px); }
.kr-extra-materials-label { font-size: 0.8125rem; font-weight: 600; color: var(--text-secondary); }
.kr-extra-materials-links { display: flex; flex-wrap: wrap; gap: 8px 12px; }
.kr-extra-link { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8125rem; font-weight: 600; color: var(--accent); text-decoration: none; padding: 5px 10px; border: 1px solid var(--border); border-radius: var(--radius-sm, 8px); background: var(--surface); transition: background 0.15s ease, border-color 0.15s ease; }
.kr-extra-link:hover { background: var(--accent-soft); border-color: var(--accent); }
.kr-extra-link svg { flex-shrink: 0; }
