:root,
[data-theme="dark"] {
    /* ===============================
       Discord Dark — 1:1 приближенно
       =============================== */

    /* --- Фоны --- */
    --background-primary: #313338;
    --background-primary-hover: #3a3c43;
    --background-lighting: #393a41;
    --background-secondary: #2b2d31;
    --background-tertiary: #1e1f22;
    --background-accent: #404249;
    --background-floating: #111214;
    --light-card: #3f4048;
    --light-panel: #36373e;
    /* --- Алиасы --- */
    --bg-dark: #313338;
    --bg-sidebar: #2b2d31;
    --bg-panel: #2b2d31;
    --bg-hover: #3a3c43;
    --background-search-input: #28292e;

    /* --- Текст --- */
    --header-primary: #f2f3f5;
    --text-primary: #dbdee1;
    --text-normal: #dbdee1;
    --text-secondary: #b5bac1;
    --text-muted: #949ba4;
    --text-mutedv2: #949ba4;
    --text-mutedv3: #a9adb2;
    --img-muted: #b5bac1;

    /* --- Бренд / интерактив --- */
    --accent: #0e6ee2;
    --brand: #0e6ee2;
    --brand-hover: #0b5ac0;
    --brand-experiment: #0e6ee2;
    --brand-experiment-560: #0b5ac0;
    --brand-transperent: #3e459154;

    --highlight-color: rgba(88, 101, 242, 0.3);
    --selected: rgba(79, 84, 92, 0.32);

    /* --- Hover / active модификаторы --- */
    --background-modifier-hover: rgba(79, 84, 92, 0.16);
    --background-modifier-hover-muted: rgba(79, 84, 92, 0.08);
    --background-modifier-accent: rgba(79, 84, 92, 0.48);
    --outline: #3f4147;
    --light-outline: #46474c;

    /* --- Статусы --- */
    --success: #3ba55d;
    --sucess-muted: rgba(59, 165, 93, 0.15);

    --status-danger: #ed4245;
    --status-danger-muted: rgba(237, 66, 69, 0.15);
    --status-warning: #faa81a;

    --danger: #ed4245;
    --danger-hover: #c03537;
    --danger-active: #a1282a;

    --online: #3ba55d;
    --idle: #faa81a;
    --dnd: #ed4245;
    --offline: #80848e;

    /* --- Шрифты --- */
    --font-main: "Segoe UI", Arial, sans-serif;
    --font-code: "gg mono", "Source Code Pro", Consolas,
        "Andale Mono WT", "Andale Mono", "Lucida Console",
        "Lucida Sans Typewriter", "DejaVu Sans Mono",
        "Bitstream Vera Sans Mono", "Liberation Mono",
        "Nimbus Mono L", Monaco, "Courier New", Courier, monospace;

    /* --- Тени --- */
    --shadow-low:
        0 1px 0 rgba(4, 4, 5, 0.2),
        0 1.5px 0 rgba(6, 6, 7, 0.05),
        0 2px 0 rgba(4, 4, 5, 0.05);

    --shadow-context-menu: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-tooltip: 0px 4px 12px rgba(0, 0, 0, 0.2);

    --text-positive: #7dca93;
}

[data-theme="light"] {
    --bg-dark: #ffffff;
    --bg-sidebar: #f2f3f5;
    --bg-panel: #ffffff;
    --bg-hover: #e3e5e8;
    --text-primary: #303038;
    --text-secondary: #4e5058;
    --accent: #0e6ee2;
    --background-primary: #ffffff;
    --background-primary-hover: #f8f9f9;
    --background-secondary: #f2f3f5;
    --background-tertiary: #e3e5e8;
    --background-accent: #e6e8ea;
    --background-lighting: #f2f3f5;
    /* Изменено с #393a41 на светлый аналог */
    --background-modifier-hover: rgba(138, 142, 148, 0.16);
    --background-modifier-hover-muted: rgba(138, 142, 148, 0.5);
    --background-modifier-accent: rgba(138, 142, 148, 0.48);
    --background-floating: #ffffff;
    --brand-experiment: #0e6ee2;
    --brand-experiment-560: #0b5ac0;
    --status-danger: #d93f42;
    --danger-hover: #c03537;
    --danger-active: #a1282a;
    --status-danger-muted: rgba(217, 63, 66, 0.1);
    --status-warning: #e69600;
    --text-normal: #2e3338;
    --text-muted: #747f8d;
    --text-mutedv2: #5c626b;
    --text-mutedv3: #4c5158;
    --img-muted: #5c626b;
    --background-search-input: #e3e5e8;
    --brand: #0e6ee2;
    --brand-hover: #0b5ac0;
    --brand-transperent: rgba(14, 110, 226, 0.15);
    /* Добавлено */
    --selected: #e3e5e8;
    --success: #248046;
    --sucess-muted: rgba(36, 128, 70, 0.1);
    /* Исправлено с #24804613 на rgba */
    --outline: #cdd3de;
    --light-outline: #b5bac1;
    /* Добавлено */
    --danger: #d93f42;
    --online: #23a55a;
    --idle: #f0b232;
    --dnd: #f23f43;
    --offline: #80848e;
    --highlight-color: rgba(88, 101, 242, 0.2);
    --shadow-low: 0 1px 0 rgba(0, 0, 0, 0.05);
    --shadow-context-menu: 0px 4px 8px rgba(0, 0, 0, 0.15);
    --shadow-tooltip: 0px 4px 12px rgba(0, 0, 0, 0.1);
    /* Добавлено */
    --header-primary: #383841;
    --font-main: "Segoe UI", Arial, sans-serif;
    /* Добавлено */
    --font-code: "gg mono", "Source Code Pro", Consolas,
        /* Добавлено */
        "Andale Mono WT", "Andale Mono", "Lucida Console",
        "Lucida Sans Typewriter", "DejaVu Sans Mono",
        "Bitstream Vera Sans Mono", "Liberation Mono",
        "Nimbus Mono L", Monaco, "Courier New", Courier, monospace;
    --light-card: #f2f3f5;
    /* Добавлено (аналог #3f4048 из темной) */
    --light-panel: #ffffff;
    /* Добавлено (аналог #36373e из темной) */
    --text-positive: #5ba87a;
}

/* ===============================
   1. Midnight (Deep Obsidian — Классический баланс)
   =============================== */
[data-theme="midnight"] {
    /* --- Фоны (Чат — светлее, Сайдбар — темнее) --- */
    --background-primary: #161719;
    /* Основной фон чата (чуть светлее) */
    --background-primary-hover: #1f2023;
    --background-lighting: #1a1b1f;
    --background-secondary: #111214;
    /* Боковая панель / сайдбар (темнее) */
    --background-tertiary: #0b0c0d;
    /* Список серверов (самый глубокий и темный) */
    --background-accent: #222428;
    --background-floating: #0f1011;
    /* Модалки и контекстные меню */
    --light-card: #202225;
    --light-panel: #141517;

    /* --- Алиасы --- */
    --bg-dark: #161719;
    /* Изменено обратно на #161719 */
    --bg-sidebar: #111214;
    /* Изменено обратно на #111214 */
    --bg-panel: #111214;
    --bg-hover: #1f2023;
    --background-search-input: #0b0c0d;

    /* --- Текст --- */
    --header-primary: #f2f3f5;
    --text-primary: #dbdee1;
    --text-normal: #c9cdd1;
    /* Мягкий серебристый, чтобы не резал глаза */
    --text-secondary: #949ba4;
    --text-muted: #6d737d;
    --text-mutedv2: #6d737d;
    --text-mutedv3: #828994;
    --img-muted: #949ba4;

    /* --- Бренд / интерактив --- */
    --accent: #0e6ee2;
    --brand: #0e6ee2;
    --brand-hover: #0b5ac0;
    --brand-experiment: #0e6ee2;
    --brand-experiment-560: #0b5ac0;
    --brand-transperent: rgba(14, 110, 226, 0.15);

    --highlight-color: rgba(14, 110, 226, 0.2);
    --selected: rgba(255, 255, 255, 0.06);

    /* --- Hover / active модификаторы --- */
    --background-modifier-hover: rgba(255, 255, 255, 0.04);
    --background-modifier-hover-muted: rgba(255, 255, 255, 0.02);
    --background-modifier-accent: rgba(255, 255, 255, 0.08);
    --outline: #1f2124;
    --light-outline: #2b2e33;

    /* --- Статусы --- */
    --success: #23a55a;
    --sucess-muted: rgba(35, 165, 90, 0.1);
    --status-danger: #f23f43;
    --status-danger-muted: rgba(242, 63, 67, 0.1);
    --status-warning: #f0b232;

    --danger: #f23f43;
    --danger-hover: #da373c;
    --danger-active: #bc3035;

    --online: #23a55a;
    --idle: #f0b232;
    --dnd: #f23f43;
    --offline: #80848e;
    --text-positive: #5ba87a;

    /* --- Шрифты и Тени --- */
    --font-main: "Segoe UI", Arial, sans-serif;
    --shadow-low: 0 1px 2px rgba(0, 0, 0, 0.5);
    --shadow-context-menu: 0 4px 12px rgba(0, 0, 0, 0.4);
    --shadow-tooltip: 0px 4px 10px rgba(0, 0, 0, 0.3);
}

/* ===============================
   2. Synthwave (Cyberpunk Neon)
   =============================== */
[data-theme="synthwave"] {
    /* --- Фоны --- */
    --background-primary: #1a0826;
    /* Глубокий фиолетовый */
    --background-primary-hover: #260f35;
    --background-lighting: #2d123f;
    --background-secondary: #13051c;
    --background-tertiary: #0a0210;
    --background-accent: #37174c;
    --background-floating: #07010b;
    --light-card: #2c113d;
    --light-panel: #180721;
    /* --- Алиасы --- */
    --bg-dark: #1a0826;
    --bg-sidebar: #13051c;
    --bg-panel: #13051c;
    --bg-hover: #260f35;
    --background-search-input: #0a0210;

    /* --- Текст (ИСПРАВЛЕНО) --- */
    --header-primary: #f0e6ff;
    /* Был #00ffff — Светло-фиолетовый для заголовков */
    --text-primary: #e8d5f5;
    /* Был #ff79c6 — Мягкий сиреневый для основного текста */
    --text-normal: #e0d0ec;
    /* Был #f6e1ff — Комфортный светлый для чтения */
    --text-secondary: #c0a8d6;
    /* Был #b19fc2 — Более контрастный вторичный */
    --text-muted: #8b7a9e;
    /* Был #79628c — Более светлый muted */
    --text-mutedv2: #8b7a9e;
    --text-mutedv3: #a08db5;
    --img-muted: #b19fc2;

    /* --- Бренд / интерактив --- */
    --accent: #ff007f;
    /* Ядовито-розовый бренд */
    --brand: #ff007f;
    --brand-hover: #e60072;
    --brand-experiment: #ff007f;
    --brand-experiment-560: #e60072;
    --brand-transperent: rgba(255, 0, 127, 0.2);
    --highlight-color: rgba(0, 255, 255, 0.2);
    --selected: rgba(255, 0, 127, 0.25);

    /* --- Модификаторы --- */
    --background-modifier-hover: rgba(255, 0, 127, 0.12);
    --background-modifier-hover-muted: rgba(0, 255, 255, 0.05);
    --background-modifier-accent: rgba(0, 255, 255, 0.2);
    --outline: #ff007f55;
    --light-outline: #00ffff55;

    /* --- Статусы --- */
    --success: #00ff66;
    --sucess-muted: rgba(0, 255, 102, 0.15);
    --status-danger: #ff3333;
    --status-danger-muted: rgba(255, 51, 51, 0.1);
    --status-warning: #ffcc00;
    --danger: #ff3333;
    --danger-hover: #cc2929;
    --danger-active: #992020;
    --online: #00ff66;
    --idle: #ffcc00;
    --dnd: #ff3333;
    --offline: #79628c;
    --text-positive: #00ff66;

    --font-main: "Segoe UI", Arial, sans-serif;
    --shadow-low: 0 2px 4px rgba(255, 0, 127, 0.2);
    --shadow-context-menu: 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-tooltip: 0px 4px 12px rgba(255, 0, 127, 0.3);
}

/* ===============================
   3. Evergreen (Уютный Лес / Шалфей)
   =============================== */
[data-theme="evergreen"] {
    /* --- Фоны --- */
    --background-primary: #232d27;
    /* Матовый темно-зеленый */
    --background-primary-hover: #2b3730;
    --background-lighting: #324138;
    --background-secondary: #1c2420;
    --background-tertiary: #141a17;
    --background-accent: #38473f;
    --background-floating: #0f1311;
    --light-card: #2d3a32;
    --light-panel: #324138;
    /* --- Алиасы --- */
    --bg-dark: #232d27;
    --bg-sidebar: #1c2420;
    --bg-panel: #1c2420;
    --bg-hover: #2b3730;
    --background-search-input: #141a17;

    /* --- Текст --- */
    --header-primary: #fbf1c7;
    /* Ламповый кремовый / слоновая кость */
    --text-primary: #ebdbb2;
    /* Мягкий светлый ретро-текст */
    --text-normal: #ebdbb2;
    --text-secondary: #b8bb26;
    /* Оливковый подтекст */
    --text-muted: #a89984;
    /* Серо-бежевый мутед */
    --text-mutedv2: #a89984;
    --text-mutedv3: #928374;
    --img-muted: #a89984;

    /* --- Бренд / интерактив --- */
    --accent: #8ec07c;
    /* Пастельный зеленый акцент */
    --brand: #8ec07c;
    --brand-hover: #79a369;
    --brand-experiment: #8ec07c;
    --brand-experiment-560: #79a369;
    --brand-transperent: rgba(142, 192, 124, 0.2);
    --highlight-color: rgba(215, 153, 33, 0.2);
    /* Теплый янтарный хайлайт */
    --selected: rgba(142, 192, 124, 0.15);

    /* --- Модификаторы --- */
    --background-modifier-hover: rgba(235, 219, 178, 0.05);
    --background-modifier-hover-muted: rgba(235, 219, 178, 0.02);
    --background-modifier-accent: rgba(142, 192, 124, 0.25);
    --outline: #2d3a32;
    --light-outline: #38473f;

    /* --- Статусы --- */
    --success: #b8bb26;
    --sucess-muted: rgba(184, 187, 38, 0.15);
    --status-danger: #fb4934;
    --status-danger-muted: rgba(251, 73, 52, 0.1);
    --status-warning: #fabd2f;
    --danger: #fb4934;
    --danger-hover: #cc3e2b;
    --danger-active: #993022;
    --online: #b8bb26;
    --idle: #fabd2f;
    --dnd: #fb4934;
    --offline: #928374;
    --text-positive: #b8bb26;

    --font-main: "Segoe UI", Arial, sans-serif;
    --shadow-low: 0 1px 3px rgba(0, 0, 0, 0.4);
    --shadow-context-menu: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-tooltip: 0px 4px 10px rgba(0, 0, 0, 0.2);
}