@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("/fonts/manrope-cyrillic-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  src: url("/fonts/manrope-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* Цвета берутся из темы Telegram (--tg-theme-*), если приложение открыто в Telegram. */
:root {
  --accent: #e6452a;
  --accent-ink: #ffffff;
  --accent-soft: rgba(230, 69, 42, .1);
  --bg: var(--tg-theme-secondary-bg-color, #f3f0ea);
  --surface: var(--tg-theme-bg-color, #fffdf9);
  --text: var(--tg-theme-text-color, #18212a);
  --muted: var(--tg-theme-hint-color, #5f6873);
  --line: rgba(24, 33, 42, .1);
  --field: rgba(24, 33, 42, .05);
  --good: #1f8a4c;
  --good-soft: rgba(31, 138, 76, .12);
  --warn: #9a6a00;
  --warn-soft: rgba(214, 156, 20, .15);
  --bad: var(--tg-theme-destructive-text-color, #c0352b);
  --bad-soft: rgba(192, 53, 43, .1);
  --radius: 18px;
  --tabbar-h: 64px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: var(--tg-theme-secondary-bg-color, #0f151c);
  --surface: var(--tg-theme-bg-color, #18212b);
  --text: var(--tg-theme-text-color, #eef1f4);
  --muted: var(--tg-theme-hint-color, #95a1ad);
  --line: rgba(255, 255, 255, .1);
  --field: rgba(255, 255, 255, .07);
  --accent-soft: rgba(240, 96, 70, .16);
  --good: #52c47f;
  --good-soft: rgba(82, 196, 127, .14);
  --warn: #e6b84f;
  --warn-soft: rgba(230, 184, 79, .14);
  --bad: var(--tg-theme-destructive-text-color, #ff7a6b);
  --bad-soft: rgba(255, 122, 107, .12);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font: 15px/1.45 Manrope, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.hidden { display: none !important; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.app { width: min(100%, 720px); margin: 0 auto; padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 16px); }

/* Шапка */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(12px); }
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark { display: grid; place-items: center; flex: 0 0 32px; width: 32px; height: 32px; color: #fff; background: var(--accent); border-radius: 10px; font-weight: 800; }
.brand-name { font-weight: 800; letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.user-chip { max-width: 45%; padding: 5px 10px; color: var(--muted); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.notice { display: grid; gap: 6px; margin: 16px; padding: 16px; background: var(--warn-soft); border-radius: var(--radius); }
.notice span { color: var(--muted); font-size: 14px; }

.views { padding: 0 16px; }
.view-heading h2, .chat-head h2 { margin: 6px 0 12px; font-size: 22px; letter-spacing: -.03em; }

/* Вводный блок — одна строка вместо целого экрана */
.intro { margin: 4px 0 14px; }
.intro h1 { margin: 0; font-size: 20px; line-height: 1.2; letter-spacing: -.03em; }
.intro h1 em { color: var(--accent); font-style: normal; }
.intro-copy { display: -webkit-box; margin: 6px 0 0; overflow: hidden; color: var(--muted); font-size: 13px; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }

/* Поиск и фильтры */
.catalog-tools { position: sticky; top: 56px; z-index: 10; display: grid; gap: 10px; margin: 0 -16px; padding: 4px 16px 10px; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(12px); }
.search { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px; color: var(--muted); background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.search:focus-within { border-color: var(--accent); }
.search input { flex: 1; min-width: 0; height: 100%; color: var(--text); background: none; border: 0; outline: none; }
.chips { display: flex; gap: 8px; margin: 0 -16px; padding: 0 16px; overflow-x: auto; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: 0 0 auto; height: 34px; padding: 0 14px; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.chip.active { color: #fff; background: var(--text); border-color: var(--text); }
:root[data-theme="dark"] .chip.active { color: var(--bg); }
.result-count { min-height: 0; margin: 0 0 8px; color: var(--muted); font-size: 12px; }
.result-count:empty { display: none; }

/* Сетка товаров: компактные карточки по две в ряд */
.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 560px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.product-card { display: flex; flex-direction: column; min-width: 0; padding: 0; overflow: hidden; color: inherit; text-align: left; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); transition: transform .15s ease; }
.product-card:active { transform: scale(.98); }
.product-media { position: relative; aspect-ratio: 3 / 2; background: var(--accent-soft); }
.product-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.product-placeholder { display: grid; place-items: center; height: 100%; color: var(--accent); background: linear-gradient(135deg, rgba(230, 69, 42, .16), rgba(230, 69, 42, .04)); }
.product-placeholder svg { width: 40px; height: 40px; stroke-width: 1.6; opacity: .85; }
.product-placeholder.course { color: #4a5bd4; background: linear-gradient(135deg, rgba(74, 91, 212, .18), rgba(74, 91, 212, .04)); }
:root[data-theme="dark"] .product-placeholder.course { color: #9aa6ff; }
.sheet-media .product-placeholder svg { width: 64px; height: 64px; }
.product-tag { position: absolute; top: 8px; left: 8px; padding: 3px 8px; color: var(--text); background: color-mix(in srgb, var(--surface) 88%, transparent); border-radius: 999px; font-size: 11px; font-weight: 700; }
.product-info { display: grid; gap: 4px; padding: 10px 12px 12px; }
.product-title { display: -webkit-box; min-height: 2.6em; margin: 0; overflow: hidden; font-size: 14px; font-weight: 700; line-height: 1.3; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.product-price { font-size: 16px; font-weight: 800; letter-spacing: -.02em; }
.product-stock { color: var(--muted); font-size: 12px; }
.product-stock.out { color: var(--bad); font-weight: 600; }
.product-card.unavailable .product-media { filter: grayscale(.8); opacity: .7; }

.empty { display: grid; justify-items: center; gap: 8px; padding: 36px 20px; color: var(--muted); text-align: center; background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty strong { color: var(--text); }
.product-grid .empty { grid-column: 1 / -1; }
.skeleton-card { aspect-ratio: 3 / 4; border-radius: var(--radius); background: linear-gradient(90deg, var(--surface) 0%, var(--field) 50%, var(--surface) 100%); background-size: 200% 100%; animation: shimmer 1.2s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }

/* Кнопки */
.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border: 0; border-radius: 14px; font-weight: 700; }
.button.primary { color: var(--accent-ink); background: var(--accent); }
.button.secondary { color: var(--text); background: var(--field); }
.button.ghost { color: var(--text); background: transparent; border: 1px solid var(--line); }
.button.danger { color: var(--bad); background: var(--bad-soft); }
.button.small { min-height: 38px; padding: 0 14px; font-size: 13px; border-radius: 12px; }
.button:disabled { color: var(--muted); background: var(--field); cursor: not-allowed; }
.button.block { width: 100%; }

/* Нижняя шторка с товаром */
.sheet { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(10, 14, 18, .45); animation: fade .2s ease; }
.sheet-panel { position: relative; width: min(100%, 560px); max-height: 92vh; overflow-y: auto; padding: 0 0 calc(16px + var(--safe-bottom)); background: var(--surface); border-radius: 22px 22px 0 0; animation: slide-up .24s ease; overscroll-behavior: contain; }
@keyframes slide-up { from { transform: translateY(40px); opacity: .6; } to { transform: none; opacity: 1; } }
@keyframes fade { from { opacity: 0; } }
.sheet-close { position: absolute; top: 12px; right: 12px; z-index: 2; display: grid; place-items: center; width: 36px; height: 36px; color: var(--text); background: color-mix(in srgb, var(--surface) 85%, transparent); border: 0; border-radius: 50%; }
.sheet-media { aspect-ratio: 16 / 10; background: var(--accent-soft); }
.sheet-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sheet-media .product-placeholder { font-size: 56px; }
.sheet-content { display: grid; gap: 14px; padding: 16px; }
.sheet-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.pill { display: inline-flex; align-items: center; padding: 4px 10px; color: var(--muted); background: var(--field); border-radius: 999px; font-size: 12px; font-weight: 600; }
.pill.good { color: var(--good); background: var(--good-soft); }
.pill.warn { color: var(--warn); background: var(--warn-soft); }
.pill.bad { color: var(--bad); background: var(--bad-soft); }
.pill.accent { color: var(--accent); background: var(--accent-soft); }
.sheet-content h3 { margin: 0; font-size: 22px; line-height: 1.2; letter-spacing: -.03em; }
.sheet-description { margin: 0; color: var(--muted); }
.sheet-price { font-size: 26px; font-weight: 800; letter-spacing: -.03em; }
.field-label { margin: 0 0 8px; color: var(--muted); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.methods { display: grid; gap: 8px; }
.method { display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: var(--field); border: 2px solid transparent; border-radius: 14px; cursor: pointer; }
.method input { position: absolute; opacity: 0; }
.method .radio { flex: 0 0 18px; width: 18px; height: 18px; border: 2px solid var(--muted); border-radius: 50%; }
.method:has(input:checked) { background: var(--accent-soft); border-color: var(--accent); }
.method:has(input:checked) .radio { border: 5px solid var(--accent); }
.method:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.method strong { display: block; font-size: 14px; }
.method small { color: var(--muted); font-size: 12px; }
.codes-toggle { justify-self: start; padding: 0; color: var(--accent); background: none; border: 0; font-weight: 700; font-size: 14px; }
.codes { display: grid; gap: 8px; }
.input { width: 100%; height: 46px; padding: 0 14px; color: var(--text); background: var(--field); border: 1px solid transparent; border-radius: 12px; outline: none; text-transform: uppercase; }
.input::placeholder { text-transform: none; }
.input:focus { border-color: var(--accent); }
.payment-off { padding: 12px 14px; color: var(--warn); background: var(--warn-soft); border-radius: 14px; font-size: 14px; }
.sheet-actions { position: sticky; bottom: calc(-16px - var(--safe-bottom)); display: grid; gap: 8px; margin: 0 -16px; padding: 12px 16px calc(12px + var(--safe-bottom)); background: var(--surface); border-top: 1px solid var(--line); }

/* Заказы */
#orders-chips { margin-bottom: 12px; }
.orders-list { display: grid; gap: 10px; }
.order-card { display: grid; gap: 10px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.order-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.order-top strong { display: block; font-size: 15px; line-height: 1.3; }
.order-top small { color: var(--muted); font-size: 12px; }
.order-amount { flex: 0 0 auto; font-weight: 800; }
.order-status-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; }
.order-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.order-actions .button { flex: 1; }
.access { display: grid; gap: 6px; padding: 12px; background: var(--good-soft); border-radius: 14px; }
.access-code { display: flex; align-items: center; justify-content: space-between; gap: 10px; font: 700 16px/1.2 ui-monospace, "DM Mono", monospace; letter-spacing: .04em; }
.access-code button { flex: 0 0 auto; padding: 6px 10px; color: var(--good); background: var(--surface); border: 0; border-radius: 10px; font: 600 12px Manrope, system-ui, sans-serif; }
.access p { margin: 0; color: var(--text); font-size: 13px; white-space: pre-line; }

/* Доставка и оферта */
.delivery-block { display: grid; gap: 10px; }
.recipient { display: grid; gap: 8px; }
.input.plain { text-transform: none; }
.input.area { height: auto; padding: 12px 14px; resize: none; line-height: 1.35; }
.terms { display: flex; align-items: flex-start; gap: 10px; color: var(--muted); font-size: 13px; line-height: 1.4; }
.terms input { flex: 0 0 20px; width: 20px; height: 20px; margin: 0; accent-color: var(--accent); }
.link { padding: 0; color: var(--accent); background: none; border: 0; font: inherit; font-weight: 700; text-decoration: underline; }
.sheet-total { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 6px; padding: 12px 14px; background: var(--field); border-radius: 14px; color: var(--muted); font-size: 13px; }
.sheet-total strong { color: var(--text); font-size: 18px; }
.legal { z-index: 70; }
.legal-text { color: var(--text); font-size: 14px; line-height: 1.55; white-space: pre-wrap; }

/* Перевод на карту */
.transfer { display: grid; gap: 10px; padding: 12px; background: var(--field); border-radius: 14px; }
.transfer-row { display: flex; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 13px; }
.transfer-row strong { color: var(--text); }
.transfer-card { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px; background: var(--surface); border: 1px dashed var(--accent); border-radius: 12px; }
.transfer-number { white-space: nowrap; font: 700 16px/1.2 ui-monospace, "SF Mono", monospace; letter-spacing: .04em; }
.transfer-card button { flex: 0 0 auto; padding: 7px 11px; color: #fff; background: var(--accent); border: 0; border-radius: 10px; font: 700 12px Manrope, system-ui, sans-serif; }
.transfer-note { margin: 0; color: var(--muted); font-size: 13px; }

/* Чат */
.view-chat { display: flex; flex-direction: column; height: calc(100dvh - 56px - var(--tabbar-h) - var(--safe-bottom) - 16px); }
.chat-head { display: flex; align-items: center; gap: 12px; padding: 4px 0 10px; border-bottom: 1px solid var(--line); }
.chat-head h2 { margin: 0; font-size: 17px; }
.chat-subtitle { margin: 2px 0 0; color: var(--muted); font-size: 12px; }
.team-avatar { display: grid; place-items: center; flex: 0 0 40px; width: 40px; height: 40px; color: #fff; background: var(--text); border-radius: 50%; font-weight: 800; }
:root[data-theme="dark"] .team-avatar { color: var(--bg); }
.messages { flex: 1; display: flex; flex-direction: column; gap: 6px; padding: 14px 0; overflow-y: auto; overscroll-behavior: contain; }
.message { max-width: 82%; padding: 9px 12px 6px; background: var(--surface); border: 1px solid var(--line); border-radius: 16px 16px 16px 6px; white-space: pre-wrap; overflow-wrap: anywhere; }
.message.own { align-self: flex-end; color: #fff; background: var(--accent); border-color: transparent; border-radius: 16px 16px 6px 16px; }
.message time { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; text-align: right; }
.message.own time { color: rgba(255, 255, 255, .8); }
.message img, .message video { display: block; width: 100%; max-height: 280px; margin: -3px -6px 6px; width: calc(100% + 12px); object-fit: cover; border-radius: 12px; background: var(--field); }
.day-separator { align-self: center; margin: 8px 0; padding: 3px 10px; color: var(--muted); background: var(--field); border-radius: 999px; font-size: 11px; }
.composer { display: flex; align-items: flex-end; gap: 8px; padding: 10px 0 0; border-top: 1px solid var(--line); }
.composer-field { flex: 1; display: grid; gap: 4px; min-width: 0; }
.composer textarea { width: 100%; max-height: 140px; min-height: 44px; padding: 11px 14px; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: 22px; outline: none; resize: none; line-height: 1.35; }
.composer textarea:focus { border-color: var(--accent); }
.attachment-name { padding: 4px 10px; color: var(--muted); background: var(--field); border-radius: 10px; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.attach, .send { display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px; border-radius: 50%; }
.attach { position: relative; color: var(--text); background: var(--field); cursor: pointer; }
.attach input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.attach:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.send { color: #fff; background: var(--accent); border: 0; }
.send:disabled { opacity: .5; }

/* Нижняя навигация */
.tabbar { position: fixed; left: 50%; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(4, 1fr); width: min(100%, 720px); height: calc(var(--tabbar-h) + var(--safe-bottom)); padding-bottom: var(--safe-bottom); background: color-mix(in srgb, var(--surface) 94%, transparent); border-top: 1px solid var(--line); backdrop-filter: blur(14px); transform: translateX(-50%); }
.tab { position: relative; display: grid; place-items: center; align-content: center; gap: 2px; color: var(--muted); background: none; border: 0; font-size: 11px; font-weight: 700; }
.tab svg { width: 22px; height: 22px; }
.tab.active { color: var(--accent); }
.badge { position: absolute; top: 8px; left: calc(50% + 6px); min-width: 18px; height: 18px; padding: 0 5px; color: #fff; background: var(--accent); border-radius: 9px; font-size: 11px; line-height: 18px; text-align: center; }

/* Уведомления */
.toast-root { position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 12px); z-index: 60; display: grid; gap: 8px; width: min(100% - 32px, 480px); transform: translateX(-50%); pointer-events: none; }
.toast { padding: 12px 14px; color: #fff; background: rgba(24, 33, 42, .94); border-radius: 14px; font-size: 14px; box-shadow: 0 10px 30px rgba(0, 0, 0, .2); animation: slide-up .2s ease; }
.toast.error { background: #a8291f; }
.toast.success { background: #1c7a44; }

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* Номер карты не должен распирать карточку заказа на узких экранах */
.order-card, .transfer, .transfer-card { min-width: 0; }
.transfer-number { min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: clamp(13px, 4.2vw, 16px); }

/* Этап 2: корзина, варианты, приглашения */
.variants { display: flex; flex-wrap: wrap; gap: 8px; }
.variant { position: relative; display: grid; gap: 2px; min-width: 96px; padding: 9px 12px; background: var(--field); border: 2px solid transparent; border-radius: 12px; cursor: pointer; }
.variant input { position: absolute; opacity: 0; }
.variant strong { font-size: 14px; }
.variant small { color: var(--muted); font-size: 12px; }
.variant:has(input:checked) { background: var(--accent-soft); border-color: var(--accent); }
.variant:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.variant.out { opacity: .6; }
.stepper { display: inline-flex; align-items: center; gap: 4px; padding: 3px; background: var(--field); border-radius: 12px; }
.stepper button { width: 34px; height: 34px; color: var(--text); background: var(--surface); border: 0; border-radius: 9px; font-size: 18px; font-weight: 700; }
.stepper button:disabled { opacity: .4; }
.stepper span { min-width: 28px; text-align: center; font-weight: 800; }
.qty-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.cart { display: grid; gap: 12px; }
.cart-lines { display: grid; gap: 8px; }
.cart-line { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: 12px; padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.cart-thumb { width: 56px; height: 56px; overflow: hidden; border-radius: 12px; background: var(--accent-soft); }
.cart-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cart-thumb .product-placeholder svg { width: 26px; height: 26px; }
.cart-info { display: grid; gap: 6px; min-width: 0; }
.cart-info strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cart-info small { color: var(--muted); }
.cart-controls { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.cart-remove { padding: 4px; color: var(--muted); background: none; border: 0; font-size: 13px; text-decoration: underline; }
.cart-card { display: grid; gap: 12px; padding: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.cart-summary { display: grid; gap: 6px; font-size: 14px; }
.cart-summary div { display: flex; justify-content: space-between; gap: 10px; color: var(--muted); }
.cart-summary .total { color: var(--text); font-size: 18px; font-weight: 800; }
.cart-warning { padding: 10px 12px; color: var(--warn); background: var(--warn-soft); border-radius: 12px; font-size: 13px; }
.referral-banner { padding: 10px 12px; color: var(--good); background: var(--good-soft); border-radius: 12px; font-size: 13px; font-weight: 600; }
.order-items { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; color: var(--muted); font-size: 13px; }
.order-items li { display: flex; justify-content: space-between; gap: 10px; }
.referral-card { display: grid; gap: 10px; margin-bottom: 12px; padding: 14px; background: linear-gradient(135deg, var(--accent-soft), transparent); border: 1px solid var(--line); border-radius: var(--radius); }
.referral-card h3 { margin: 0; font-size: 16px; }
.referral-card p { margin: 0; color: var(--muted); font-size: 13px; }
.referral-actions { display: flex; gap: 8px; }
.referral-actions .button { flex: 1; }
.subscribed { color: var(--good); font-weight: 700; font-size: 13px; text-align: center; }

/* Мои курсы */
.courses-block { display: grid; gap: 10px; margin-bottom: 14px; }
.block-title { margin: 0; font-size: 16px; }
.course-card { display: grid; gap: 12px; padding: 14px; background: var(--surface); border: 1px solid var(--accent-soft); border-radius: var(--radius); box-shadow: inset 3px 0 0 var(--accent); }
.timeline { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; margin: 0; padding: 0; list-style: none; counter-reset: step; }
.timeline li { position: relative; padding-top: 22px; color: var(--muted); font-size: 10.5px; line-height: 1.2; text-align: center; counter-increment: step; }
.timeline li::before { content: counter(step); position: absolute; top: 0; left: 50%; transform: translateX(-50%); display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--field); font-size: 10px; font-weight: 700; }
.timeline li.done::before { content: "✓"; background: var(--good); color: #fff; }
.timeline li.now { color: var(--text); font-weight: 700; }
.timeline li.now::before { background: var(--accent); color: var(--accent-ink); }
.hint { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.4; }
.intake, .checkin, .review-form { display: grid; gap: 10px; }
.intake label, .checkin label { display: grid; gap: 4px; font-size: 13px; }
.intake textarea, .checkin textarea, .checkin input, .review-form textarea { width: 100%; box-sizing: border-box; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--field); color: var(--text); font: inherit; font-size: 15px; resize: vertical; }
.checkin-row { display: grid; grid-template-columns: 90px 1fr; gap: 10px; align-items: end; }
.stars { display: flex; gap: 4px; }
.stars label, .rating-input label { position: relative; flex: 1; }
.rating-input label { flex: 0 0 auto; }
.stars input, .rating-input input { position: absolute; opacity: 0; pointer-events: none; }
.stars b { display: grid; place-items: center; height: 40px; border-radius: 10px; background: var(--field); font-size: 14px; }
.stars input:checked + b { background: var(--accent); color: var(--accent-ink); }
.history summary { cursor: pointer; color: var(--muted); font-size: 13px; }
.history ul { display: grid; gap: 8px; margin: 8px 0 0; padding: 0; list-style: none; font-size: 13px; }
.rating-input { display: flex; justify-content: center; gap: 6px; }
.rating-input span { font-size: 34px; color: var(--line); cursor: pointer; }
.rating-input:has(label:nth-child(1) input:checked) label:nth-child(-n+1) span { color: #f2a516; }
.rating-input:has(label:nth-child(2) input:checked) label:nth-child(-n+2) span { color: #f2a516; }
.rating-input:has(label:nth-child(3) input:checked) label:nth-child(-n+3) span { color: #f2a516; }
.rating-input:has(label:nth-child(4) input:checked) label:nth-child(-n+4) span { color: #f2a516; }
.rating-input:has(label:nth-child(5) input:checked) label:nth-child(-n+5) span { color: #f2a516; }
.rating-line { margin: -4px 0 0; color: #c98a00; font-size: 13px; font-weight: 700; }
.sheet-reviews { display: grid; gap: 10px; }
.review { padding: 10px 12px; background: var(--field); border-radius: 12px; font-size: 13px; }
.review b { color: #f2a516; } .review b i { color: var(--line); font-style: normal; }
.review small { color: var(--muted); }
.review p { margin: 6px 0 0; } .review .reply { color: var(--muted); }
