/* =================================================================
   Vixi Aurora — собственный стиль панели.
   Идея: «ночное небо с северным сиянием» — сиреневый, розовый и голубой
   на мягком жемчужном (светлая) или чернильном (тёмная) фоне. Парящее меню,
   секции-карточки, крупные скругления, заголовки шрифтом Unbounded.
   Подключается последним: переопределяет panel.css и modern.css.
   ================================================================= */
:root {
  --brand: #4955D4;
  --brand-600: #6a59f5;
  --brand-700: #5646dc;
  --brand-50: #f1eeff;
  --brand-100: #e5e0ff;
  --brand-200: #cdc5ff;
  --brand-text: #5a49e0;
  --violet: #6f7bf0;
  --rose: #4cc3f5;
  --sky: #5ad1ff;

  --aurora: linear-gradient(120deg, #4955D4 0%, #6f7bf0 48%, #4cc3f5 100%);
  --brand-grad: linear-gradient(135deg, #5663e0 0%, #4955D4 40%, #6f7bf0 100%);
  --brand-glow: 0 10px 28px -8px rgba(73, 85, 212, 0.6);
  --focus: 0 0 0 3px rgba(73, 85, 212, 0.35);

  --bg: #f7f4fd;
  --surface: #ffffff;
  --surface-2: #f6f3fd;
  --surface-3: #ece7f8;
  --border: #ebe6f6;
  --border-strong: #d8d1ec;
  --text: #1f1b38;
  --text-2: #5b5679;
  --text-3: #918cad;
  --glass: color-mix(in srgb, var(--surface) 78%, transparent);

  --r-sm: 12px;
  --r-md: 14px;
  --r-lg: 22px;
  --font-display: "Unbounded", "Manrope", "Golos Text", system-ui, sans-serif;
  --shadow-card: 0 1px 2px rgba(60, 40, 120, 0.04), 0 14px 34px -18px rgba(70, 50, 160, 0.22);
  --shadow-hover: 0 2px 4px rgba(60, 40, 120, 0.05), 0 22px 44px -18px rgba(73, 85, 212, 0.4);
  --shadow-pop: 0 30px 70px -16px rgba(40, 24, 110, 0.35);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand-50: #272250;
    --brand-100: #322b68;
    --brand-200: #463d8e;
    --brand-text: #aab3ff;
    --bg: #0f0d1c;
    --surface: #181530;
    --surface-2: #1f1b3b;
    --surface-3: #2a2548;
    --border: #2b2650;
    --border-strong: #3d3770;
    --text: #efecff;
    --text-2: #bab5de;
    --text-3: #8780b0;
    --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.35), 0 16px 36px -18px rgba(0, 0, 0, 0.7);
    --shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.4), 0 22px 44px -16px rgba(73, 85, 212, 0.5);
    --shadow-pop: 0 30px 80px -14px rgba(0, 0, 0, 0.8);
  }
}
:root[data-theme="dark"] {
  --brand-50: #272250;
  --brand-100: #322b68;
  --brand-200: #463d8e;
  --brand-text: #aab3ff;
  --bg: #0f0d1c;
  --surface: #181530;
  --surface-2: #1f1b3b;
  --surface-3: #2a2548;
  --border: #2b2650;
  --border-strong: #3d3770;
  --text: #efecff;
  --text-2: #bab5de;
  --text-3: #8780b0;
  --shadow-card: 0 1px 2px rgba(0, 0, 0, 0.35), 0 16px 36px -18px rgba(0, 0, 0, 0.7);
  --shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.4), 0 22px 44px -16px rgba(73, 85, 212, 0.5);
  --shadow-pop: 0 30px 80px -14px rgba(0, 0, 0, 0.8);
}

/* ---------- фон: сияние и точечная сетка ---------- */
body {
  background:
    radial-gradient(1000px 520px at 6% -10%, color-mix(in srgb, var(--brand) 20%, transparent), transparent 70%),
    radial-gradient(800px 460px at 100% 0%, color-mix(in srgb, var(--rose) 14%, transparent), transparent 70%),
    radial-gradient(900px 500px at 50% 115%, color-mix(in srgb, var(--sky) 11%, transparent), transparent 70%),
    var(--bg);
  background-attachment: fixed;
}
body::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: .5;
  background-image: radial-gradient(color-mix(in srgb, var(--text) 12%, transparent) 1px, transparent 1.2px); background-size: 26px 26px;
  mask-image: linear-gradient(180deg, #000, transparent 70%); -webkit-mask-image: linear-gradient(180deg, #000, transparent 70%); }

/* ---------- типографика ---------- */
h1, .page-top h1, .servers-head h1, .wizard-head h1 { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.035em; }
.hero h1, .block-title { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.04em; }
.hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); line-height: 1.12; }
.block-title { font-size: clamp(1.5rem, 3vw, 2.1rem); }
.page-head h1 { font-size: 1.55rem; }
.tile-value, .stat-item dd { font-family: var(--font-display); font-weight: 600; }
.logo { font-family: var(--font-display); font-weight: 600; letter-spacing: -0.03em; }
.grad-text { background: var(--aurora); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- кнопки: «таблетки» ---------- */
.btn { border-radius: var(--r-pill); min-height: 42px; padding: 0 20px; border-color: var(--border-strong); }
.btn.small { min-height: 34px; padding: 0 15px; }
.btn.lg { min-height: 50px; padding: 0 28px; }
.btn.primary { background: var(--brand-grad); box-shadow: var(--brand-glow), inset 0 1px 0 rgba(255, 255, 255, 0.25); }
.btn.primary:hover:not(:disabled) { box-shadow: 0 14px 34px -8px rgba(73, 85, 212, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.3); }
.btn.soft { background: var(--brand-50); color: var(--brand-text); }
.btn.soft:hover { background: var(--brand-100); }
.btn.ghost { border-color: transparent; }
.badge, .chip { border-radius: var(--r-pill); }
input[type="text"], input[type="number"], input[type="password"], input[type="search"], input[type="url"],
input[type="datetime-local"], input[type="time"], input[type="date"], select, textarea { border-radius: var(--r-md); background: var(--surface-2); border-color: transparent; box-shadow: inset 0 0 0 1px var(--border); }
input:hover, select:hover, textarea:hover { box-shadow: inset 0 0 0 1px var(--border-strong); border-color: transparent; }
input:focus-visible, select:focus-visible, textarea:focus-visible { background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--brand), var(--focus); border-color: transparent; }
.switch input:checked + span { background: var(--aurora); }

/* ---------- шапка ---------- */
.header { background: color-mix(in srgb, var(--bg) 62%, transparent); border-bottom: 0; backdrop-filter: blur(22px) saturate(1.6); -webkit-backdrop-filter: blur(22px) saturate(1.6); }
.header::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--brand) 40%, transparent), color-mix(in srgb, var(--rose) 30%, transparent), transparent); }
.logo img, .logo .mark { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px color-mix(in srgb, var(--brand) 60%, transparent), 0 6px 18px -2px rgba(73, 85, 212, 0.55); }
.mark { background: var(--aurora); }
.nav a[aria-current="page"] { background: var(--brand-50); color: var(--brand-text); }

/* ---------- каркас панели: парящее меню ---------- */
.shell { background: transparent; }
.side { background: var(--glass); border: 1px solid var(--border); border-radius: 26px; box-shadow: var(--shadow-card); backdrop-filter: blur(18px) saturate(1.4); -webkit-backdrop-filter: blur(18px) saturate(1.4); padding: 14px 12px 14px; }
@media (min-width: 961px) {
  .shell { padding: 10px 22px 28px; gap: 22px; grid-template-columns: 272px minmax(0, 1fr); }
  .side { top: calc(var(--header-h) + 10px); height: calc(100vh - var(--header-h) - 38px); }
  .content { max-width: 1020px; padding: 12px 4px 80px; }
  .subbar { padding: 8px 4px 0; }
}
@media (max-width: 960px) { .side { border-radius: 0 26px 26px 0; } }
.side::-webkit-scrollbar { width: 6px; }
.nav-item { min-height: 42px; border-radius: 14px; padding: 0 12px; gap: 12px; font-weight: 500; }
.nav-item .emoji { width: 30px; height: 30px; border-radius: 10px; background: var(--surface-2); color: var(--text-2); transition: background-color .2s ease, color .2s ease, transform .2s var(--ease); }
.nav-item:hover { transform: none; background: var(--surface-2); }
.nav-item:hover .emoji { color: var(--brand-text); }
.nav-item > .icon { width: 20px; height: 20px; }
.nav-item[aria-current="page"] { background: color-mix(in srgb, var(--brand) 13%, transparent); color: var(--text); font-weight: 600; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 25%, transparent); }
.nav-item[aria-current="page"]::before { display: none; }
.nav-item[aria-current="page"] .emoji { background: var(--brand-grad); color: #fff; box-shadow: var(--brand-glow); transform: scale(1.04); }
.nav-item[aria-current="page"] > .icon { color: var(--brand-text); }
.nav-label { margin-top: 6px; padding-left: 14px; letter-spacing: .12em; }
.nav-item .dot-warn { box-shadow: 0 0 0 4px color-mix(in srgb, var(--warn) 25%, transparent); }
.switcher-btn { border-radius: 18px; padding: 10px; background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 14%, var(--surface)), color-mix(in srgb, var(--rose) 8%, var(--surface))); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 22%, var(--border)); border: 0; }
.switcher-list { border-radius: 18px; }
.side-foot { border-top-color: var(--border); }
.crumbs { padding: 0 4px; }

/* ---------- заголовок страницы ---------- */
.page-head { padding: 6px 4px 4px; margin-bottom: 18px; }
.page-head .title-icon { width: 54px; height: 54px; border-radius: 18px; background: var(--brand-grad); box-shadow: var(--brand-glow), inset 0 1px 0 rgba(255, 255, 255, 0.3); }
.page-head .title-icon, .page-head .title-icon .icon { color: #fff; }
.page-head p { font-size: 0.95rem; }

/* ---------- секции — карточки ---------- */
.content .section:not(.section .section) { background: var(--surface); border: 1px solid var(--border); border-radius: 24px; padding: 24px 26px; box-shadow: var(--shadow-card); position: relative; }
.content .section:not(.section .section) + .section:not(.section .section) { margin-top: 16px; border-top: 1px solid var(--border); }
.content .section:last-child { padding-bottom: 24px; }
.page-head + .section, .notice + .section, .module-tabs + .tab-pane > .section:first-child { padding-top: 24px; }
.tab-pane > .section:first-child { padding-top: 24px; }
.tab-pane { display: grid; gap: 16px; }
.tab-pane[hidden] { display: none !important; }
.tab-pane > .section + .section { margin-top: 0; }
.content .section h2 { font-size: 1.08rem; display: flex; align-items: center; gap: 10px; }
.content .section > h2:first-child::before, .content .section > .section-head > h2:first-child::before { content: ""; width: 4px; height: 18px; border-radius: 4px; background: var(--aurora); flex: none; }
.section .table-wrap { border: 0; background: transparent; }
.section .table th { background: transparent; }
.content .section.compact:not(.section .section) { padding: 16px 22px; }
.card { border-radius: 22px; }
.editor { border-radius: 20px; border-color: transparent; box-shadow: inset 0 0 0 1px var(--border); }
.notice { border-radius: 18px; padding: 14px 16px; }
.module-tabs { margin: 0 0 16px; background: var(--glass); border-radius: var(--r-pill); padding: 5px; }
.module-tabs .seg { border-radius: var(--r-pill); padding: 8px 18px; }
.seg[aria-selected="true"] { background: var(--brand-grad); color: #fff; box-shadow: var(--brand-glow); }
.seg[aria-selected="true"] .seg-count { color: rgba(255, 255, 255, 0.85); }
.segmented { border-radius: var(--r-pill); }
.segmented .seg { border-radius: var(--r-pill); }
.toggle-row, .cmd-row, .notif-row, .todo { border-top-color: color-mix(in srgb, var(--border) 80%, transparent); }

/* ---------- обзор: герой сервера ---------- */
.server-head { position: relative; overflow: hidden; padding: 28px 30px; margin-bottom: 18px; border-radius: 28px; border: 1px solid color-mix(in srgb, var(--brand) 28%, var(--border));
  background:
    radial-gradient(420px 220px at 0% 0%, color-mix(in srgb, var(--brand) 30%, transparent), transparent 70%),
    radial-gradient(380px 220px at 100% 100%, color-mix(in srgb, var(--rose) 22%, transparent), transparent 70%),
    var(--surface);
  box-shadow: var(--shadow-card); }
.server-head::after { content: "✦"; position: absolute; right: 26px; top: 16px; font-size: 1.4rem; color: color-mix(in srgb, var(--rose) 70%, transparent); text-shadow: 0 0 18px var(--rose); opacity: .8; pointer-events: none; }
.server-head h1 { font-size: 1.6rem; }
.server-head .server-icon.lg { width: 72px; height: 72px; box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px color-mix(in srgb, var(--brand) 55%, transparent), 0 10px 26px -6px rgba(73, 85, 212, 0.6); }
.server-meta .live { padding: 3px 11px 3px 9px; border-radius: var(--r-pill); background: color-mix(in srgb, var(--ok) 14%, transparent); }
.server-meta .live .dot { box-shadow: 0 0 0 3px color-mix(in srgb, var(--ok) 28%, transparent); }
.readiness { width: 240px; }
.quick-row .btn { background: var(--surface-2); }
.feature-mini a { padding: 8px 12px; margin: 0 -12px; border-radius: 12px; transition: background-color .15s ease; }
.feature-mini a:hover { background: var(--surface-2); }
.activity li { border-left-color: color-mix(in srgb, var(--brand) 35%, transparent); }
.tile { border-radius: 20px; }
.tile-value { background: var(--aurora); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- каталог функций ---------- */
.catalog-group > h2 { font-family: var(--font-display); font-size: 0.78rem; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--text-3); margin: 0 0 8px 6px; }
.feature-list { background: var(--surface); border: 1px solid var(--border); border-radius: 24px; padding: 6px 14px; box-shadow: var(--shadow-card); }
.feature-row { margin: 0 -8px; padding: 12px 8px; border-bottom-color: color-mix(in srgb, var(--border) 70%, transparent); }
.feature-row:last-child { border-bottom: 0; }
.fr-icon, .todo-icon { width: 40px; height: 40px; border-radius: 14px; background: var(--brand-50); }
.fr-icon .icon, .todo-icon .icon { color: var(--brand-text); }
.filter-row .btn, .cat-tabs .seg { border-radius: var(--r-pill); }

/* ---------- мастер, выбор, команды, серверы ---------- */
.wizard-steps .n { width: 30px; height: 30px; }
.wizard-steps li.current .n { background: var(--aurora); }
.choice { border-radius: 22px; border-width: 1px; background: var(--surface); box-shadow: var(--shadow-card); }
.choice:has(input:checked) { border-color: var(--brand); background: linear-gradient(135deg, color-mix(in srgb, var(--brand) 10%, var(--surface)), var(--surface)); }
.choice:has(input:checked) .choice-mark { background: var(--aurora); border-color: transparent; }
.cmd-item, .cat-list { border-radius: 20px; }
.cat-list button { border-radius: 14px; }
.cat-list button[aria-pressed="true"] { background: var(--brand-50); color: var(--brand-text); }
.server-card { border-radius: 24px; padding: 18px; }
.server-card .server-icon { width: 56px; height: 56px; }
.center-card { border-radius: 30px; }
.plan { border-radius: 26px; }
.plan.featured { background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--aurora) border-box; }
.modal { border-radius: 28px; }
.toast { border-radius: 16px; }

/* ---------- главная ---------- */
.hero::before { background: color-mix(in srgb, var(--brand) 38%, transparent); }
.hero::after { background: color-mix(in srgb, var(--rose) 30%, transparent); }
.eyebrow { background: var(--glass); }
.feature-item { border-radius: 26px; padding: 26px; }
.feature-item::after { background: radial-gradient(closest-side at 20% 0, color-mix(in srgb, var(--rose) 20%, transparent), transparent); }
.fi-icon, .stat-icon { background: var(--brand-grad); border: 0; color: #fff; box-shadow: var(--brand-glow), inset 0 1px 0 rgba(255, 255, 255, 0.3); }
.fi-icon .icon, .stat-icon .icon { color: #fff; }
.why-item, .step { border-radius: 26px; padding: 26px; }
.why-item .icon { background: var(--brand-grad); }
.step h3::before { background: var(--aurora); border-radius: 12px; }
.panel-preview { border-radius: 28px; }
.panel-preview::before { background: var(--aurora); }
.block.final .wrap { background: var(--aurora); border-radius: 34px; }
.block.final .btn.primary { color: var(--brand-700); }
.footer { border-top: 0; }
.footer::before { content: ""; display: block; height: 1px; max-width: 1200px; margin: 0 auto; background: linear-gradient(90deg, transparent, var(--border-strong), transparent); }

/* ---------- купленная подписка: те же цвета сияния ---------- */
@media (prefers-reduced-motion: reduce) { .hero::before, .hero::after { animation: none; } }

/* =================================================================
   Доводка: умеренные скругления, единые иконки меню, отступы вложенных элементов
   ================================================================= */
:root { --r-lg: 18px; }
.page-head h1 { font-size: 1.4rem; }
.hero h1 { font-size: clamp(2rem, 4vw, 3rem); }
.content .section:not(.section .section) { border-radius: 20px; padding: 22px 24px; }
.feature-list { border-radius: 20px; }
.server-head { border-radius: 24px; }
.server-card { border-radius: 20px; }
.choice { border-radius: 18px; }
.plan { border-radius: 20px; }
.card { border-radius: 18px; }
.editor { border-radius: 16px; }
.notice { border-radius: 14px; }
.cmd-item, .cat-list { border-radius: 16px; }
.feature-item, .why-item, .step { border-radius: 22px; }
.panel-preview { border-radius: 22px; }
.block.final .wrap { border-radius: 28px; }
.center-card { border-radius: 24px; }
.modal { border-radius: 22px; }
.side { border-radius: 22px; }
@media (max-width: 960px) { .side { border-radius: 0 22px 22px 0; } }
.nav-item, .switcher-btn, .switcher-list { border-radius: 14px; }
.tile { border-radius: 16px; }

/* Все пункты меню — иконка в одинаковой плитке (и пункты без .emoji, где иконка — прямой потомок) */
.nav-item > .icon:first-child { box-sizing: content-box; width: 18px; height: 18px; padding: 6px; border-radius: 10px; background: var(--surface-2); color: var(--text-2); transition: background-color .2s ease, color .2s ease; }
.nav-item:hover > .icon:first-child { color: var(--brand-text); }
.nav-item[aria-current="page"] > .icon:first-child { background: var(--brand-grad); color: #fff; box-shadow: var(--brand-glow); }
.nav-item.add > .icon:first-child { background: transparent; border: 1px dashed var(--border-strong); }
.nav-item .emoji { flex: none; }
.nav-item .dot-warn { flex: none; }

/* вложенные переключатели и заголовки внутри карточки-секции */
.content .section h2 + .segmented, .content .section h2 + .cat-tabs { margin-top: 14px; }
.content .section .segmented { margin-bottom: 16px; }
.section-head { margin-bottom: 14px; }
.content .section .plans { margin-top: 16px; }

/* ничего не вылезает за скруглённые края */
.content .section:not(.section .section), .feature-list, .plan, .cmd-item, .server-card, .choice, .editor, .tile, .card, .notice { overflow: clip; }
.content .section:not(.section .section) { overflow: visible; }
.table-wrap { max-width: 100%; }
.msg-editor .editor-actions { border-radius: 0 0 22px 22px; }

/* Страницы сайта: основная колонка во всю ширину, чтобы совпадала с шапкой и подвалом */
.site-main.wrap { width: 100%; }
@media (max-width: 640px) {
  .todo-text { flex: 1 1 calc(100% - 56px); }
  .todo .btn { margin-left: 52px; }
}
