/* =====================================================================
 * themes.css — variables des thèmes d'affichage (voir theme_lib.php)
 * ---------------------------------------------------------------------
 * Chaque thème a un mode nuit (sombre) et un mode jour (clair). L'élément
 * <html> porte data-theme="neutre|luxe|…" et data-scheme="light|dark" ; sans
 * data-theme, c'est Neutre. index-inline.css, incarstyle.css, meteolocale.css
 * et les pages des onglets internes n'emploient que ces variables : pour
 * ajouter un thème, on n'écrit qu'ici (et une entrée dans IW_THEMES).
 *
 * Choisi dans « Mon compte », réservé aux comptes Plus. Chargée par
 * iw_theme_head() avant les autres feuilles.
 * ===================================================================== */

/* ===================================================================
 * Neutre — l'habillage historique du site, thème par défaut
 * ------------------------------------------------------------------- */

/* Nuit (défaut). Les panneaux et fenêtres restent sombres dans les deux modes :
   c'est le rendu qu'ont toujours connu les utilisateurs. */
:root {
    color-scheme: dark;
    --font-body: "Universal Sans Text", sans-serif;
    --font-title: "Universal Sans Text", sans-serif;
    --title-weight: bold;
    --title-tracking: 0;
    --menu-weight: normal;
    --menu-tracking: 0;

    /* page */
    --bg: #161616;
    --text: grey;
    --text-strong: white;
    --link: grey;
    --surface: #333333;          /* volet actif du menu */
    --surface-text: white;
    --field-bg: #333333;         /* zone de note */
    --field-text: lightgrey;
    --rule: grey;                /* trait sous le titre de la fiche d'icône */
    --menu-active-shadow: none;
    --icon-ring: transparent;
    --page-gradient: none;
    --menu-bg: var(--bg);
    --accent-bg: var(--accent);
    --panel-blur: none;
    --title-color: inherit;
    --modal-border: transparent;
    --banner-bg: #237afc;
    --banner-text: #ffffff;

    /* barre d'onglets */
    --tabbar-bg: #333;
    --tabbar-text: white;
    --tabbar-border: transparent;
    --tab-bg: #555;
    --tab-active-bg: #222;
    --tab-active-shadow: none;
    --tab-text: white;

    /* boutons et étiquettes */
    --btn-bg: dimgrey;
    --btn-text: white;
    --btn-border: transparent;
    --chip-bg: #555;             /* étiquette des icônes ouvertes en onglet */
    --chip-text: white;
    --dash: #666;                /* vignette « + » en pointillés */

    /* accent (bleu iOS) et couleurs sémantiques */
    --accent: #007AFF;
    --accent-text: white;
    --accent-soft: rgba(0,122,255,0.12);
    --accent-border: rgba(0,122,255,0.45);
    --accent-deep: #0a2a4a;      /* fond du mode d'ouverture sélectionné */
    --toggle-off: #48484a;
    --toggle-on: #1552F0;
    --toggle-knob: #fff;
    --success: #28a745;
    --success-text: white;
    --success-fg: #28a745;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #dc3545;
    --danger-text: #ff453a;      /* texte rouge lisible sur fond sombre */
    --warning: #D9730D;
    --ok-badge: #1DA34A;
    --badge-text: white;
    --submit-bg: yellow;
    --submit-text: black;

    /* panneaux et fenêtres (ajout de lien, Mon compte, avertissements) */
    --panel-bg: #1c1c1e;
    --panel-text: white;
    --panel-muted: #aaa;
    --panel-soft: #ccc;
    --panel-list: #ddd;
    --panel-border: #444;
    --panel-border-w: 2px;
    --panel-divider: #3a3a3c;
    --panel-input-bg: #3a3a3c;
    --panel-input-bg-2: #2b2b2d;
    --panel-input-border: #555;
    --panel-input-border-2: #666;
    --panel-hint: #888;
    --panel-hint-2: #9ca3af;
    --overlay: rgba(0,0,0,0.6);
    --shadow-panel: 0 4px 20px rgba(0,0,0,0.6);
    --shadow-modal: 0 8px 32px rgba(0,0,0,0.6);
    --shadow-bubble: 0 4px 16px rgba(0,0,0,0.4);
    --shadow-ghost: 0 8px 28px rgba(0,0,0,0.35);

    /* menus flottants (menu contextuel, langues, altitude) et infobulles */
    --popup-bg: white;
    --popup-text: black;
    --popup-border: #ccc;
    --popup-muted: #666666;
    --popup-hover: #333333;
    --popup-shadow: 0 2px 10px rgba(0,0,0,0.2);
    --tooltip-bg: #333;
    --tooltip-text: white;

    /* encadré d'état des notes, annonce « comptes Plus » (fond blanc, texte bleu) */
    --status-bg: #f8f9fa;
    --status-border: #dee2e6;
    --notice-bg: #fff;
    --notice-text: #0057d9;
    --notice-soft: #e8f0ff;

    /* tableaux (boutique) */
    --table-bg: white;
    --table-head-bg: #2c3e50;
    --table-head-text: white;
    --table-border: #ddd;
    --table-hover: #f9f9f9;
    --table-shadow: 0 2px 4px rgba(0,0,0,0.1);

    /* widget météo */
    --mt-bg: rgba(255,255,255,0.95);
    --mt-text: #2c3e50;
    --mt-muted: #7f8c8d;
    --mt-faint: #95a5a6;
    --mt-item-bg: #f8f9fa;
    --mt-divider: #ecf0f1;
    --mt-accent: #667eea;
    --mt-accent-2: #764ba2;
    --mt-accent-hover: #5568d3;
    --mt-accent-text: white;
    --mt-error: #e74c3c;
    --mt-spinner: #f3f3f3;
    --mt-shadow: 0 20px 60px rgba(0,0,0,0.3);

    /* rayons */
    --radius-s: 4px;
    --radius: 8px;
    --radius-m: 10px;
    --radius-l: 12px;
    --radius-xl: 16px;
    --radius-icon: 20px;
}

/* Jour : seuls le fond de page, le volet actif et la zone de note s'éclaircissent. */
html[data-scheme="light"] {
    color-scheme: light;
    --bg: #EEEEEE;
    --text-strong: black;
    --surface: #ffffff;
    --surface-text: black;
    --field-bg: white;
    --field-text: black;
}

/* ===================================================================
 * Luxe — épuré façon montre suisse : surfaces unies, traits fins,
 * accents dorés discrets, titres en romain. Les panneaux suivent le mode.
 * ------------------------------------------------------------------- */

/* Nuit */
html[data-theme="luxe"] {
    color-scheme: dark;
    --font-title: Georgia, "Times New Roman", "Songti SC", "Noto Serif CJK SC", serif;
    --title-weight: 400;
    --title-tracking: 0.02em;
    --menu-weight: 300;
    --menu-tracking: 0.03em;

    --bg: #0E0E10;
    --text: #C9C4B8;
    --text-strong: #F3EFE6;
    --link: #C9C4B8;
    --surface: transparent;
    --surface-text: #C9A96A;
    --field-bg: #17171A;
    --field-text: #F3EFE6;
    --rule: rgba(201,169,106,0.45);
    --menu-active-shadow: inset 0 -2px 0 #C9A96A;
    --icon-ring: rgba(201,169,106,0.35);
    --page-gradient: none;
    --menu-bg: var(--bg);
    --accent-bg: var(--accent);
    --panel-blur: none;
    --title-color: #C9A96A;
    --modal-border: rgba(201,169,106,0.35);
    --banner-bg: #131316;
    --banner-text: #C9A96A;

    --tabbar-bg: #0E0E10;
    --tabbar-text: #C9C4B8;
    --tabbar-border: rgba(201,169,106,0.35);
    --tab-bg: #17171A;
    --tab-active-bg: #1F1F24;
    --tab-active-shadow: inset 0 -2px 0 #C9A96A;
    --tab-text: #F3EFE6;

    --btn-bg: #17171A;
    --btn-text: #E6E1D6;
    --btn-border: rgba(201,169,106,0.5);
    --chip-bg: #C9A96A;         /* même or que le texte .info (--accent) */
    --chip-text: var(--bg);     /* couleur du fond de page */
    --dash: #3A3A40;

    --accent: #C9A96A;
    --accent-text: #0E0E10;
    --accent-soft: rgba(201,169,106,0.10);
    --accent-border: rgba(201,169,106,0.45);
    --accent-deep: #2A2418;
    --toggle-off: #2A2A2F;
    --toggle-on: #C9A96A;
    --toggle-knob: #F3EFE6;
    --success: #5E9E6E;
    --success-text: #0E0E10;
    --success-fg: #5E9E6E;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #B5493B;
    --danger-text: #D9776A;
    --warning: #C67A2E;
    --ok-badge: #4F8C5F;
    --badge-text: #F3EFE6;
    --submit-bg: #C9A96A;
    --submit-text: #0E0E10;

    --panel-bg: #131316;
    --panel-text: #F3EFE6;
    --panel-muted: #B8B3A8;
    --panel-soft: #C9C4B8;
    --panel-list: #D8D3C8;
    --panel-border: rgba(201,169,106,0.35);
    --panel-border-w: 1px;
    --panel-divider: #26262B;
    --panel-input-bg: #1E1E22;
    --panel-input-bg-2: #191A1E;
    --panel-input-border: #2A2A2F;
    --panel-input-border-2: #3A3A40;
    --panel-hint: #8B877F;
    --panel-hint-2: #8B877F;
    --overlay: rgba(0,0,0,0.65);
    --shadow-panel: 0 2px 24px rgba(0,0,0,0.55);
    --shadow-modal: 0 8px 40px rgba(0,0,0,0.6);
    --shadow-bubble: 0 4px 20px rgba(0,0,0,0.5);
    --shadow-ghost: 0 8px 28px rgba(0,0,0,0.5);

    --popup-bg: #17171A;
    --popup-text: #F3EFE6;
    --popup-border: rgba(201,169,106,0.35);
    --popup-muted: #B8B3A8;
    --popup-hover: #F3EFE6;
    --popup-shadow: 0 2px 16px rgba(0,0,0,0.5);
    --tooltip-bg: #1F1F24;
    --tooltip-text: #F3EFE6;

    --status-bg: #17171A;
    --status-border: #2A2A2F;
    --notice-bg: #131316;
    --notice-text: #C9A96A;
    --notice-soft: rgba(201,169,106,0.12);

    --table-bg: #17171A;
    --table-head-bg: #131316;
    --table-head-text: #C9A96A;
    --table-border: #2A2A2F;
    --table-hover: #1F1F24;
    --table-shadow: none;

    --mt-bg: rgba(23,23,26,0.96);
    --mt-text: #F3EFE6;
    --mt-muted: #B8B3A8;
    --mt-faint: #8B877F;
    --mt-item-bg: #1F1F24;
    --mt-divider: #2A2A2F;
    --mt-accent: #C9A96A;
    --mt-accent-2: #8C7442;
    --mt-accent-hover: #D8B97C;
    --mt-accent-text: #0E0E10;
    --mt-error: #D9776A;
    --mt-spinner: #2A2A2F;
    --mt-shadow: 0 12px 40px rgba(0,0,0,0.5);

    --radius-s: 2px;
    --radius: 4px;
    --radius-m: 6px;
    --radius-l: 6px;
    --radius-xl: 8px;
    --radius-icon: 18px;
}

/* Jour : ivoire, blanc, or ancien plus soutenu pour rester lisible. */
html[data-theme="luxe"][data-scheme="light"] {
    color-scheme: light;

    --bg: #F5F3ED;
    --text: #514D45;
    --text-strong: #17150F;
    --link: #514D45;
    --surface: transparent;
    --surface-text: #9C7B3A;
    --field-bg: #FFFFFF;
    --field-text: #17150F;
    --rule: rgba(156,123,58,0.45);
    --menu-active-shadow: inset 0 -2px 0 #9C7B3A;
    --icon-ring: rgba(156,123,58,0.35);
    --page-gradient: none;
    --menu-bg: var(--bg);
    --accent-bg: var(--accent);
    --panel-blur: none;
    --title-color: #9C7B3A;
    --modal-border: rgba(156,123,58,0.45);
    --banner-bg: #FFFFFF;
    --banner-text: #9C7B3A;

    --tabbar-bg: #FFFFFF;
    --tabbar-text: #514D45;
    --tabbar-border: rgba(156,123,58,0.4);
    --tab-bg: #F0EDE5;
    --tab-active-bg: #FFFFFF;
    --tab-active-shadow: inset 0 -2px 0 #9C7B3A;
    --tab-text: #17150F;

    --btn-bg: #FFFFFF;
    --btn-text: #3A362E;
    --btn-border: rgba(156,123,58,0.55);
    --chip-bg: #9C7B3A;         /* même or que le texte .info (--accent) */
    --chip-text: var(--bg);     /* couleur du fond de page */
    --dash: #C9C4B8;

    --accent: #9C7B3A;
    --accent-text: #FFFFFF;
    --accent-soft: rgba(156,123,58,0.10);
    --accent-border: rgba(156,123,58,0.45);
    --accent-deep: #F1EADB;
    --toggle-off: #D8D4CA;
    --toggle-on: #9C7B3A;
    --toggle-knob: #FFFFFF;
    --success: #3F8A52;
    --success-text: #FFFFFF;
    --success-fg: #3F8A52;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #B23B2E;
    --danger-text: #B23B2E;
    --warning: #B96D22;
    --ok-badge: #3F8A52;
    --badge-text: #FFFFFF;
    --submit-bg: #9C7B3A;
    --submit-text: #FFFFFF;

    --panel-bg: #FFFFFF;
    --panel-text: #17150F;
    --panel-muted: #7E796F;
    --panel-soft: #514D45;
    --panel-list: #3A362E;
    --panel-border: rgba(156,123,58,0.45);
    --panel-border-w: 1px;
    --panel-divider: #E7E3D9;
    --panel-input-bg: #F5F3ED;
    --panel-input-bg-2: #FAF9F5;
    --panel-input-border: #E2DED4;
    --panel-input-border-2: #D3CEC3;
    --panel-hint: #9A958B;
    --panel-hint-2: #9A958B;
    --overlay: rgba(23,21,15,0.45);
    --shadow-panel: 0 8px 28px rgba(23,21,15,0.12);
    --shadow-modal: 0 12px 40px rgba(23,21,15,0.16);
    --shadow-bubble: 0 4px 20px rgba(23,21,15,0.14);
    --shadow-ghost: 0 8px 28px rgba(23,21,15,0.18);

    --popup-bg: #FFFFFF;
    --popup-text: #17150F;
    --popup-border: #E2DED4;
    --popup-muted: #7E796F;
    --popup-hover: #17150F;
    --popup-shadow: 0 2px 16px rgba(23,21,15,0.12);
    --tooltip-bg: #17150F;
    --tooltip-text: #F5F3ED;

    --status-bg: #FFFFFF;
    --status-border: #E2DED4;
    --notice-bg: #FFFFFF;
    --notice-text: #9C7B3A;
    --notice-soft: rgba(156,123,58,0.12);

    --table-bg: #FFFFFF;
    --table-head-bg: #F5F3ED;
    --table-head-text: #9C7B3A;
    --table-border: #E2DED4;
    --table-hover: #FAF9F5;
    --table-shadow: none;

    --mt-bg: rgba(255,255,255,0.96);
    --mt-text: #17150F;
    --mt-muted: #7E796F;
    --mt-faint: #9A958B;
    --mt-item-bg: #F5F3ED;
    --mt-divider: #E7E3D9;
    --mt-accent: #9C7B3A;
    --mt-accent-2: #C9A96A;
    --mt-accent-hover: #7F6430;
    --mt-accent-text: #FFFFFF;
    --mt-error: #B23B2E;
    --mt-spinner: #E7E3D9;
    --mt-shadow: 0 12px 40px rgba(23,21,15,0.12);
}

/* ===================================================================
 * Aurore — tons pastels et dégradés doux. Le jour : rose, lavande et
 * ciel sur fond clair. La nuit : indigo profond traversé de lueurs
 * lavande et menthe, comme une aurore boréale. Le texte sombre sur les
 * aplats pastel garde le contraste ; les dégradés vont aux fonds (page,
 * barre d'onglets, panneaux, boutons d'accent, volet actif du menu).
 * ------------------------------------------------------------------- */

/* Nuit */
html[data-theme="aurore"] {
    color-scheme: dark;
    --font-title: "Universal Sans Text", sans-serif;
    --title-weight: 600;
    --title-tracking: 0;
    --menu-weight: normal;
    --menu-tracking: 0;

    --bg: #1B1A2E;
    --page-gradient: linear-gradient(160deg, #1B1A2E 0%, #212A45 50%, #1C3238 100%);
    --menu-bg: transparent;
    --text: #C9C5E3;
    --text-strong: #F4F2FF;
    --link: #C9C5E3;
    --surface: linear-gradient(135deg, rgba(196,181,253,0.28), rgba(167,243,208,0.22));
    --surface-text: #F4F2FF;
    --field-bg: #262541;
    --field-text: #F4F2FF;
    --rule: #3D3B63;
    --menu-active-shadow: none;
    --icon-ring: rgba(196,181,253,0.25);
    --title-color: #C4B5FD;
    --modal-border: rgba(196,181,253,0.3);
    --banner-bg: #2A2850;
    --banner-text: #C4B5FD;

    --tabbar-bg: linear-gradient(90deg, #2A2650, #253A55 55%, #1F3F44);
    --tabbar-text: #E4E1F5;
    --tabbar-border: transparent;
    --tab-bg: rgba(255,255,255,0.10);
    --tab-active-bg: rgba(255,255,255,0.20);
    --tab-active-shadow: 0 0 0 1px rgba(196,181,253,0.35);
    --tab-text: #F4F2FF;

    --btn-bg: #2F2D4E;
    --btn-text: #E4E1F5;
    --btn-border: rgba(196,181,253,0.25);
    --chip-bg: #33315A;
    --chip-text: #E4E1F5;
    --dash: #5E5A8C;

    --accent: #C4B5FD;
    --accent-text: #1B1A2E;
    --accent-bg: linear-gradient(135deg, #C4B5FD, #A7F3D0);
    --panel-blur: none;
    --accent-soft: rgba(196,181,253,0.14);
    --accent-border: rgba(196,181,253,0.5);
    --accent-deep: #33315A;
    --toggle-off: #3D3B63;
    --toggle-on: #A7F3D0;
    --toggle-knob: #F4F2FF;
    --success: #86EFAC;
    --success-text: #14532D;
    --success-fg: #86EFAC;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #E0607E;
    --danger-text: #F9A8D4;
    --warning: #FDBA74;
    --ok-badge: #5EC9A0;
    --badge-text: #1B1A2E;
    --submit-bg: #C4B5FD;
    --submit-text: #1B1A2E;

    --panel-bg: linear-gradient(160deg, #24233F, #1F2C40);
    --panel-text: #F4F2FF;
    --panel-muted: #B4B0D0;
    --panel-soft: #C9C5E3;
    --panel-list: #DAD7EE;
    --panel-border: rgba(196,181,253,0.3);
    --panel-border-w: 1px;
    --panel-divider: #3A3860;
    --panel-input-bg: #2F2D4E;
    --panel-input-bg-2: #2A2848;
    --panel-input-border: #47447A;
    --panel-input-border-2: #5E5A8C;
    --panel-hint: #8F8BAF;
    --panel-hint-2: #8F8BAF;
    --overlay: rgba(10,10,25,0.6);
    --shadow-panel: 0 6px 28px rgba(5,5,20,0.5);
    --shadow-modal: 0 10px 40px rgba(5,5,20,0.55);
    --shadow-bubble: 0 4px 20px rgba(5,5,20,0.45);
    --shadow-ghost: 0 8px 28px rgba(5,5,20,0.45);

    --popup-bg: #262541;
    --popup-text: #F4F2FF;
    --popup-border: rgba(196,181,253,0.3);
    --popup-muted: #B4B0D0;
    --popup-hover: #F4F2FF;
    --popup-shadow: 0 4px 18px rgba(5,5,20,0.45);
    --tooltip-bg: #33315A;
    --tooltip-text: #F4F2FF;

    --status-bg: #262541;
    --status-border: #3D3B63;
    --notice-bg: #24233F;
    --notice-text: #C4B5FD;
    --notice-soft: rgba(196,181,253,0.15);

    --table-bg: #262541;
    --table-head-bg: #33315A;
    --table-head-text: #C4B5FD;
    --table-border: #3D3B63;
    --table-hover: #2F2D4E;
    --table-shadow: none;

    --mt-bg: linear-gradient(160deg, rgba(38,37,65,0.96), rgba(31,44,64,0.96));
    --mt-text: #F4F2FF;
    --mt-muted: #B4B0D0;
    --mt-faint: #8F8BAF;
    --mt-item-bg: #2F2D4E;
    --mt-divider: #3D3B63;
    --mt-accent: #C4B5FD;
    --mt-accent-2: #A7F3D0;
    --mt-accent-hover: #DDD6FE;
    --mt-accent-text: #1B1A2E;
    --mt-error: #F9A8D4;
    --mt-spinner: #3D3B63;
    --mt-shadow: 0 12px 40px rgba(5,5,20,0.45);

    --radius-s: 6px;
    --radius: 10px;
    --radius-m: 14px;
    --radius-l: 16px;
    --radius-xl: 20px;
    --radius-icon: 22px;
}

/* Jour : rose, lavande et ciel ; texte indigo sombre sur les pastels. */
html[data-theme="aurore"][data-scheme="light"] {
    color-scheme: light;

    --bg: #F5F3FF;
    --page-gradient: linear-gradient(160deg, #FDF2F8 0%, #EEF2FF 50%, #ECFEFF 100%);
    --menu-bg: transparent;
    --text: #4B4A5E;
    --text-strong: #2E2C45;
    --link: #6B5FA8;
    --surface: linear-gradient(135deg, #FBCFE8, #DDD6FE);
    --surface-text: #2E2C45;
    --field-bg: #FFFFFF;
    --field-text: #2E2C45;
    --rule: #D9D4EE;
    --menu-active-shadow: none;
    --icon-ring: rgba(167,139,250,0.25);
    --title-color: #7C6BC4;
    --modal-border: rgba(167,139,250,0.35);
    --banner-bg: #DDD6FE;
    --banner-text: #2E2C45;

    --tabbar-bg: linear-gradient(90deg, #FBCFE8, #DDD6FE 50%, #BAE6FD);
    --tabbar-text: #2E2C45;
    --tabbar-border: transparent;
    --tab-bg: rgba(255,255,255,0.55);
    --tab-active-bg: #FFFFFF;
    --tab-active-shadow: 0 2px 8px rgba(124,107,196,0.25);
    --tab-text: #2E2C45;

    --btn-bg: #FFFFFF;
    --btn-text: #4B4A5E;
    --btn-border: #E4DEF7;
    --chip-bg: #EDE9FE;
    --chip-text: #4B4A5E;
    --dash: #C4B5FD;

    --accent: #7C6BC4;
    --accent-text: #2E2C45;
    --accent-bg: linear-gradient(135deg, #C4B5FD, #A5D8F3);
    --panel-blur: none;
    --accent-soft: rgba(167,139,250,0.15);
    --accent-border: rgba(167,139,250,0.5);
    --accent-deep: #EDE9FE;
    --toggle-off: #D9D4EE;
    --toggle-on: #A78BFA;
    --toggle-knob: #FFFFFF;
    --success: #A7F3D0;
    --success-text: #14532D;
    --success-fg: #1E8A5A;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #E0607E;
    --danger-text: #C0395B;
    --warning: #F0A868;
    --ok-badge: #7DCBA6;
    --badge-text: #FFFFFF;
    --submit-bg: #FBCFE8;
    --submit-text: #2E2C45;

    --panel-bg: linear-gradient(160deg, #FFFFFF, #F5F3FF);
    --panel-text: #2E2C45;
    --panel-muted: #6E6B85;
    --panel-soft: #4B4A5E;
    --panel-list: #3E3C57;
    --panel-border: rgba(167,139,250,0.35);
    --panel-border-w: 1px;
    --panel-divider: #E9E5F7;
    --panel-input-bg: #F3F0FA;
    --panel-input-bg-2: #F8F6FD;
    --panel-input-border: #DDD6FE;
    --panel-input-border-2: #C4B5FD;
    --panel-hint: #8A87A3;
    --panel-hint-2: #8A87A3;
    --overlay: rgba(46,44,69,0.35);
    --shadow-panel: 0 8px 28px rgba(124,107,196,0.18);
    --shadow-modal: 0 12px 40px rgba(124,107,196,0.22);
    --shadow-bubble: 0 4px 20px rgba(124,107,196,0.18);
    --shadow-ghost: 0 8px 28px rgba(124,107,196,0.22);

    --popup-bg: #FFFFFF;
    --popup-text: #2E2C45;
    --popup-border: #E4DEF7;
    --popup-muted: #6E6B85;
    --popup-hover: #2E2C45;
    --popup-shadow: 0 4px 18px rgba(124,107,196,0.18);
    --tooltip-bg: #2E2C45;
    --tooltip-text: #F5F3FF;

    --status-bg: #F5F3FF;
    --status-border: #DDD6FE;
    --notice-bg: #FFFFFF;
    --notice-text: #7C6BC4;
    --notice-soft: #EDE9FE;

    --table-bg: #FFFFFF;
    --table-head-bg: #DDD6FE;
    --table-head-text: #2E2C45;
    --table-border: #E9E5F7;
    --table-hover: #F8F6FD;
    --table-shadow: 0 2px 12px rgba(124,107,196,0.12);

    --mt-bg: linear-gradient(160deg, rgba(255,255,255,0.92), rgba(238,242,255,0.92));
    --mt-text: #2E2C45;
    --mt-muted: #6E6B85;
    --mt-faint: #8A87A3;
    --mt-item-bg: #F3F0FA;
    --mt-divider: #E9E5F7;
    --mt-accent: #A78BFA;
    --mt-accent-2: #7DD3FC;
    --mt-accent-hover: #8B7CD8;
    --mt-accent-text: #2E2C45;
    --mt-error: #C0395B;
    --mt-spinner: #E9E5F7;
    --mt-shadow: 0 12px 40px rgba(124,107,196,0.18);
}

/* ===================================================================
 * Alpha — anthracite profond, tuiles en verre dépoli aux angles très arrondis,
 * accent bleu-cyan froid. Le jour : gris argent, cartes blanches, bleu
 * plus soutenu. Le flou de verre passe par --panel-blur (backdrop-filter).
 * ------------------------------------------------------------------- */

/* Nuit */
html[data-theme="alpha"] {
    color-scheme: dark;
    --font-title: "Universal Sans Text", sans-serif;
    --title-weight: 500;
    --title-tracking: 0;
    --menu-weight: normal;
    --menu-tracking: 0;

    --bg: #0B0D11;
    --page-gradient: radial-gradient(120% 70% at 50% -10%, #1A2433 0%, #0B0D11 60%);
    --menu-bg: transparent;
    --text: #C3CAD3;
    --text-strong: #FFFFFF;
    --link: #C3CAD3;
    --surface: linear-gradient(135deg, rgba(62,166,255,0.22), rgba(111,227,255,0.10));
    --surface-text: #FFFFFF;
    --field-bg: #161A21;
    --field-text: #FFFFFF;
    --rule: #2A313B;
    --menu-active-shadow: inset 0 0 0 1px rgba(62,166,255,0.35);
    --icon-ring: rgba(255,255,255,0.08);
    --title-color: #FFFFFF;
    --modal-border: rgba(255,255,255,0.10);
    --banner-bg: #161A21;
    --banner-text: #6FE3FF;

    --tabbar-bg: linear-gradient(180deg, rgba(22,26,33,0.92), rgba(11,13,17,0.92));
    --tabbar-text: #E6EAEF;
    --tabbar-border: rgba(255,255,255,0.08);
    --tab-bg: rgba(255,255,255,0.08);
    --tab-active-bg: rgba(62,166,255,0.22);
    --tab-active-shadow: inset 0 0 0 1px rgba(62,166,255,0.5);
    --tab-text: #FFFFFF;

    --btn-bg: #1C2129;
    --btn-text: #E6EAEF;
    --btn-border: rgba(255,255,255,0.10);
    --chip-bg: #232A34;
    --chip-text: #C3CAD3;
    --dash: #3A424D;

    --accent: #3EA6FF;
    --accent-text: #06131F;
    --accent-bg: linear-gradient(135deg, #3EA6FF, #6FE3FF);
    --panel-blur: blur(18px);
    --accent-soft: rgba(62,166,255,0.14);
    --accent-border: rgba(62,166,255,0.5);
    --accent-deep: #12283D;
    --toggle-off: #2A313B;
    --toggle-on: #3EA6FF;
    --toggle-knob: #FFFFFF;
    --success: #2ED47A;
    --success-text: #06131F;
    --success-fg: #2ED47A;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #E5484D;
    --danger-text: #FF7B7F;
    --warning: #F5A524;
    --ok-badge: #2ED47A;
    --badge-text: #06131F;
    --submit-bg: #3EA6FF;
    --submit-text: #06131F;

    --panel-bg: linear-gradient(160deg, rgba(28,33,41,0.92), rgba(16,19,24,0.92));
    --panel-text: #FFFFFF;
    --panel-muted: #9AA3AE;
    --panel-soft: #C3CAD3;
    --panel-list: #D5DAE1;
    --panel-border: rgba(255,255,255,0.10);
    --panel-border-w: 1px;
    --panel-divider: #2A313B;
    --panel-input-bg: #232A34;
    --panel-input-bg-2: #1C2129;
    --panel-input-border: #333B47;
    --panel-input-border-2: #3A424D;
    --panel-hint: #7C8591;
    --panel-hint-2: #7C8591;
    --overlay: rgba(0,0,0,0.6);
    --shadow-panel: 0 12px 40px rgba(0,0,0,0.6);
    --shadow-modal: 0 16px 56px rgba(0,0,0,0.65);
    --shadow-bubble: 0 6px 24px rgba(0,0,0,0.5);
    --shadow-ghost: 0 8px 28px rgba(0,0,0,0.5);

    --popup-bg: #1C2129;
    --popup-text: #FFFFFF;
    --popup-border: rgba(255,255,255,0.10);
    --popup-muted: #9AA3AE;
    --popup-hover: #FFFFFF;
    --popup-shadow: 0 6px 24px rgba(0,0,0,0.5);
    --tooltip-bg: #232A34;
    --tooltip-text: #FFFFFF;

    --status-bg: #161A21;
    --status-border: #2A313B;
    --notice-bg: #161A21;
    --notice-text: #6FE3FF;
    --notice-soft: rgba(62,166,255,0.14);

    --table-bg: #161A21;
    --table-head-bg: #1C2129;
    --table-head-text: #6FE3FF;
    --table-border: #2A313B;
    --table-hover: #232A34;
    --table-shadow: none;

    --mt-bg: linear-gradient(160deg, rgba(28,33,41,0.94), rgba(16,19,24,0.94));
    --mt-text: #FFFFFF;
    --mt-muted: #9AA3AE;
    --mt-faint: #7C8591;
    --mt-item-bg: #232A34;
    --mt-divider: #2A313B;
    --mt-accent: #3EA6FF;
    --mt-accent-2: #6FE3FF;
    --mt-accent-hover: #6FE3FF;
    --mt-accent-text: #06131F;
    --mt-error: #FF7B7F;
    --mt-spinner: #2A313B;
    --mt-shadow: 0 16px 48px rgba(0,0,0,0.55);

    --radius-s: 8px;
    --radius: 12px;
    --radius-m: 16px;
    --radius-l: 18px;
    --radius-xl: 22px;
    --radius-icon: 22px;
}

/* Jour : gris argent, cartes blanches en verre, bleu plus soutenu. */
html[data-theme="alpha"][data-scheme="light"] {
    color-scheme: light;

    --bg: #E9ECF0;
    --page-gradient: linear-gradient(180deg, #F4F6F8 0%, #E3E7EC 100%);
    --menu-bg: transparent;
    --text: #3A424D;
    --text-strong: #0F1419;
    --link: #0B6BD6;
    --surface: linear-gradient(135deg, rgba(11,107,214,0.14), rgba(11,107,214,0.06));
    --surface-text: #0F1419;
    --field-bg: #FFFFFF;
    --field-text: #0F1419;
    --rule: #CDD3DA;
    --menu-active-shadow: inset 0 0 0 1px rgba(11,107,214,0.35);
    --icon-ring: rgba(15,20,25,0.08);
    --title-color: #0F1419;
    --modal-border: rgba(15,20,25,0.10);
    --banner-bg: #FFFFFF;
    --banner-text: #0B6BD6;

    --tabbar-bg: linear-gradient(180deg, rgba(255,255,255,0.92), rgba(233,236,240,0.92));
    --tabbar-text: #0F1419;
    --tabbar-border: rgba(15,20,25,0.08);
    --tab-bg: rgba(15,20,25,0.06);
    --tab-active-bg: rgba(11,107,214,0.14);
    --tab-active-shadow: inset 0 0 0 1px rgba(11,107,214,0.45);
    --tab-text: #0F1419;

    --btn-bg: #FFFFFF;
    --btn-text: #1F252C;
    --btn-border: rgba(15,20,25,0.12);
    --chip-bg: #DDE2E8;
    --chip-text: #3A424D;
    --dash: #B7BEC7;

    --accent: #0B6BD6;
    --accent-text: #FFFFFF;
    --accent-bg: linear-gradient(135deg, #0B6BD6, #1F9BE8);
    --panel-blur: blur(18px);
    --accent-soft: rgba(11,107,214,0.12);
    --accent-border: rgba(11,107,214,0.45);
    --accent-deep: #DCEBFB;
    --toggle-off: #C8CFD7;
    --toggle-on: #0B6BD6;
    --toggle-knob: #FFFFFF;
    --success: #1E9E5A;
    --success-text: #FFFFFF;
    --success-fg: #1E9E5A;      /* texte vert sur le fond de page (remise, article en vente) */
    --danger: #D6363C;
    --danger-text: #B3262C;
    --warning: #D98A12;
    --ok-badge: #1E9E5A;
    --badge-text: #FFFFFF;
    --submit-bg: #0B6BD6;
    --submit-text: #FFFFFF;

    --panel-bg: linear-gradient(160deg, rgba(255,255,255,0.94), rgba(244,246,248,0.94));
    --panel-text: #0F1419;
    --panel-muted: #5E6873;
    --panel-soft: #3A424D;
    --panel-list: #2A313B;
    --panel-border: rgba(15,20,25,0.10);
    --panel-border-w: 1px;
    --panel-divider: #E1E5EA;
    --panel-input-bg: #EEF1F4;
    --panel-input-bg-2: #F4F6F8;
    --panel-input-border: #D3D9E0;
    --panel-input-border-2: #C0C7D0;
    --panel-hint: #7C8591;
    --panel-hint-2: #7C8591;
    --overlay: rgba(15,20,25,0.35);
    --shadow-panel: 0 12px 36px rgba(15,20,25,0.14);
    --shadow-modal: 0 16px 48px rgba(15,20,25,0.18);
    --shadow-bubble: 0 6px 24px rgba(15,20,25,0.14);
    --shadow-ghost: 0 8px 28px rgba(15,20,25,0.18);

    --popup-bg: #FFFFFF;
    --popup-text: #0F1419;
    --popup-border: #D3D9E0;
    --popup-muted: #5E6873;
    --popup-hover: #0F1419;
    --popup-shadow: 0 6px 24px rgba(15,20,25,0.14);
    --tooltip-bg: #0F1419;
    --tooltip-text: #F4F6F8;

    --status-bg: #F4F6F8;
    --status-border: #D3D9E0;
    --notice-bg: #FFFFFF;
    --notice-text: #0B6BD6;
    --notice-soft: #DCEBFB;

    --table-bg: #FFFFFF;
    --table-head-bg: #EEF1F4;
    --table-head-text: #0B6BD6;
    --table-border: #E1E5EA;
    --table-hover: #F4F6F8;
    --table-shadow: 0 2px 10px rgba(15,20,25,0.08);

    --mt-bg: linear-gradient(160deg, rgba(255,255,255,0.94), rgba(244,246,248,0.94));
    --mt-text: #0F1419;
    --mt-muted: #5E6873;
    --mt-faint: #7C8591;
    --mt-item-bg: #EEF1F4;
    --mt-divider: #E1E5EA;
    --mt-accent: #0B6BD6;
    --mt-accent-2: #1F9BE8;
    --mt-accent-hover: #0A5CB8;
    --mt-accent-text: #FFFFFF;
    --mt-error: #B3262C;
    --mt-spinner: #E1E5EA;
    --mt-shadow: 0 16px 48px rgba(15,20,25,0.14);
}
