/* =====================================================
   THEMES - Single source of truth for ALL colors & fonts
   Theme: "Dark Medieval Fantasy" (Default)
   =====================================================
   RULE: No hex/rgb values allowed in any other CSS file.
   All other files MUST reference these variables.
   ===================================================== */

:root,
[data-theme="dark-medieval"] {
    /* === Fonts === */
    --font-primary: 'Cinzel', 'Georgia', 'Times New Roman', serif;
    --font-body: 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    --font-mono: 'Courier New', Courier, monospace;

    /* === Core Palette === */
    --clr-bg: #1A1E2E;
    --clr-surface: #242838;
    --clr-surface-light: #2E3348;
    --clr-surface-dark: #0f1219;

    /* === Accent Colors === */
    --clr-accent: #C9A669;            /* Antique gold */
    --clr-accent-dim: #A8864D;        /* Dimmer gold */
    --clr-accent-bright: #D6B676;     /* Brighter gold */
    --rgb-accent: 201, 166, 105;      /* Raw RGB for rgba() usage */

    /* === Text === */
    --clr-text: #D4CFC4;             /* Warm stone */
    --clr-text-dim: #8A8578;          /* Muted stone */
    --clr-text-bright: #EFECE6;       /* White-ish stone */

    /* === Borders === */
    --clr-border: #3A3F52;
    --clr-border-light: #4A5068;
    --clr-border-dim: #2A2E3E;

    /* === System Colors === */
    --clr-gold: #C9A669;              /* Gold currency */
    --clr-essence: #8b5cf6;           /* Purple essence */
    --clr-danger: #9B1B30;            /* Blood red */
    --clr-danger-bright: #C62040;     /* Lighter danger */
    --clr-success: #4ecca3;           /* Teal green */
    --clr-warning: #D6A24D;           /* Amber warning */
    --clr-info: #60a5fa;              /* Info blue */

    /* === Combat Colors === */
    --clr-player: #C9A669;            /* Player border/highlight */
    --clr-enemy: #9B1B30;             /* Enemy border/highlight */
    --clr-combat-bg: #1A1E2E;         /* Combat area bg */
    --clr-combat-surface: #242838;    /* Combat card bg */
    --clr-combat-active: #9B1B30;     /* Active turn glow */
    --clr-combat-target: #D6A24D;     /* Target highlight */
    --clr-exploring: #C9A669;         /* Exploring status */
    --clr-combat-text: #9B1B30;       /* Combat status text */
    --clr-victory: #C9A669;           /* Victory status */
    --clr-vs: #9B1B30;               /* VS indicator */

    /* === HP/MP Bars === */
    --clr-hp-player: #4ecca3;         /* Player HP fill */
    --clr-hp-enemy: #9B1B30;          /* Enemy HP fill */
    --clr-hp-bar-bg: #2A2E3E;        /* HP bar background */
    --clr-mp: #3b82f6;                /* MP bar fill */
    --clr-mp-text: #60a5fa;           /* MP text color */

    /* === Status Effects === */
    --clr-buff: #50C878;              /* Buff glow */
    --clr-debuff: #C83232;            /* Debuff glow */

    /* === Rarity Colors === */
    --clr-rarity-common: #b0b0b0;
    --clr-rarity-uncommon: #4CAF50;
    --clr-rarity-rare: #2196F3;
    --clr-rarity-epic: #9C27B0;
    --clr-rarity-legendary: #FF9800;

    /* === Rarity Border Colors (armory) === */
    --clr-rarity-border-common: #666;
    --clr-rarity-border-uncommon: #2a2;
    --clr-rarity-border-rare: #22a;
    --clr-rarity-border-epic: #a2a;
    --clr-rarity-border-legendary: #fa2;

    /* === Rarity Text Colors (armory) === */
    --clr-rarity-text-common: #ccc;
    --clr-rarity-text-uncommon: #afa;
    --clr-rarity-text-rare: #aaf;
    --clr-rarity-text-epic: #faf;
    --clr-rarity-text-legendary: #fb0;

    /* === UI Element Colors === */
    --clr-btn-bg: #2E3348;
    --clr-btn-border: #4A5068;
    --clr-btn-text: #D4CFC4;
    --clr-btn-hover-bg: #3A3F52;
    --clr-btn-text-on-accent: #1A1E2E;

    /* === Action Button Colors === */
    --clr-equip-border: #2a2;
    --clr-equip-text: #afa;
    --clr-sell-border: #aa2;
    --clr-sell-text: #ffa;
    --clr-dismantle-border: #a22;
    --clr-dismantle-text: #faa;
    --clr-unequip: #f44;
    --clr-unequip-hover: #f00;
    --clr-dismiss: #9B1B30;
    --clr-dismiss-hover: #7A1526;

    /* === Badge Colors === */
    --clr-badge-gold-start: #C9A669;
    --clr-badge-gold-end: #A8864D;
    --clr-badge-text: #1A1E2E;

    /* === Misc === */
    --clr-selected-border: #D6A24D;
    --clr-selected-bg: rgba(214, 162, 77, 0.1);
    --clr-overlay: rgba(0, 0, 0, 0.7);
    --clr-shadow: rgba(0, 0, 0, 0.3);
    --clr-shadow-strong: rgba(0, 0, 0, 0.5);
    --clr-white-faint: rgba(255, 255, 255, 0.05);
    --clr-white-dim: rgba(255, 255, 255, 0.1);
    --clr-white-muted: rgba(255, 255, 255, 0.7);
    --clr-hint: #555;
    --clr-hero-portrait-bg: #3A3F52;
    --clr-hero-portrait-border: #4A5068;
    --clr-slot-dashed: #3A3F52;
    --clr-current-room-border: #EFECE6;
    --clr-current-room-glow: #9B1B30;
    --clr-room-visited-bg: #C9A669;
    --clr-room-visited-text: #1A1E2E;

    /* === Currency Tier Colors === */
    --clr-copper: #B87333;
    --clr-silver: #C0C0C0;
    --clr-gold-coin: #FFD700;
    --clr-platinum: #E5E4E2;
}
