/* ========================================================
   HATOM KINGDOM — DESIGN SYSTEM MÉDIÉVAL FÉODAL & GLASSMORPHISM
   ======================================================== */

:root {
    --bg-main: #0c0d12;
    --bg-surface: #141721;
    --bg-card: rgba(20, 23, 33, 0.88);
    --bg-card-hover: rgba(28, 32, 46, 0.96);
    --border-color: rgba(201, 168, 78, 0.22);
    --border-hover: rgba(232, 202, 116, 0.55);
    
    --gold-primary: #c9a84e;
    --gold-bright: #e8ca74;
    --gold-dark: #8c6f24;
    --gold-gradient: linear-gradient(135deg, #e8ca74 0%, #c9a84e 50%, #8c6f24 100%);
    
    --crimson: #8b1523;
    --crimson-dark: #560a12;
    --blurple: #5865f2;
    --green-emerald: #2ec4b6;
    --green-light: #57cc99;
    --purple-arcane: #7b2cbf;

    --text-primary: #f4ecd8;
    --text-secondary: #beb399;
    --text-muted: #827966;

    --font-heading: 'Cinzel', serif;
    --font-medieval: 'MedievalSharp', cursive;
    --font-body: 'Crimson Text', 'Inter', serif;
    --font-mono: 'JetBrains Mono', monospace;

    --shadow-soft: 0 8px 32px 0 rgba(0, 0, 0, 0.6);
    --shadow-gold: 0 0 24px rgba(201, 168, 78, 0.25);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-main);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    line-height: 1.5;
}

/* Background Atmosphere */
.app-background {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 15% 20%, rgba(131, 56, 236, 0.12) 0%, transparent 40%),
        radial-gradient(circle at 85% 15%, rgba(212, 175, 55, 0.10) 0%, transparent 45%),
        radial-gradient(circle at 50% 80%, rgba(230, 57, 70, 0.08) 0%, transparent 50%),
        #0a0b10;
    pointer-events: none;
    z-index: -1;
}

/* ==================== HEADER ==================== */
.royal-header {
    background: rgba(14, 16, 24, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 18px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
}

.royal-crest {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid var(--border-hover);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-gold);
    animation: crestGlow 4s ease-in-out infinite alternate;
    overflow: hidden;
    position: relative;
    flex-shrink: 0;
}

.brand-logo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    border-radius: inherit;
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.royal-crest:hover .brand-logo-img {
    transform: scale(1.1) rotate(1deg);
}

@keyframes crestGlow {
    0% { box-shadow: 0 0 12px rgba(212, 175, 55, 0.15); }
    100% { box-shadow: 0 0 28px rgba(246, 226, 122, 0.35); }
}

.main-title {
    font-family: var(--font-heading);
    font-size: 1.55rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 2px 10px rgba(212, 175, 55, 0.2);
}

.sub-title {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 400;
}

.header-right-side {
    display: flex;
    align-items: center;
    gap: 14px;
}

.btn-discord-login {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #5865F2;
    color: #ffffff !important;
    font-weight: 700;
    font-size: 0.82rem;
    padding: 7px 14px;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 12px rgba(88, 101, 242, 0.35);
    white-space: nowrap;
}

.btn-discord-login:hover {
    background: #4752c4;
    box-shadow: 0 4px 18px rgba(88, 101, 242, 0.6);
    transform: translateY(-1px);
}

.user-auth-pill {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 6px 14px;
    border-radius: 24px;
    transition: all 0.2s ease;
}

.user-auth-pill:hover {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.07);
}

.user-avatar-wrap {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.user-avatar-placeholder {
    font-size: 1.1rem;
}

.user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-details {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.user-name {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-primary);
    max-width: 130px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.user-role-badge {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.user-role-badge.admin {
    color: var(--gold-bright);
    font-weight: 600;
}

.user-role-badge.mod {
    color: var(--blue-light);
    font-weight: 600;
}

.user-role-badge.guest {
    color: var(--text-secondary);
}

.user-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 6px;
}

.btn-auth-toggle {
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid rgba(212, 175, 55, 0.35);
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.btn-auth-toggle:hover {
    background: rgba(212, 175, 55, 0.25);
    border-color: var(--gold-bright);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.25);
}

.btn-logout-header {
    background: rgba(220, 20, 60, 0.12);
    border: 1px solid rgba(220, 20, 60, 0.35);
    color: #ff708d;
    font-family: var(--font-heading);
    font-size: 0.78rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.btn-logout-header:hover {
    background: rgba(220, 20, 60, 0.25);
    border-color: #ff5577;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(220, 20, 60, 0.25);
}

.header-status {
    display: flex;
    align-items: center;
    gap: 14px;
}

.status-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 600;
    border: 1px solid rgba(46, 196, 182, 0.3);
    background: rgba(46, 196, 182, 0.1);
    color: var(--green-light);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--green-light);
    box-shadow: 0 0 8px var(--green-light);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.85); }
}

.latency-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-family: var(--font-mono);
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid var(--border-color);
}

/* ==================== NAVIGATION ROYALE : 4 GRANDS HUBS ==================== */
.royal-hubs-nav {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* SÉLECTEUR DE DOMAINE MOBILE COMPACT */
.mobile-realm-selector-bar {
    display: none;
    width: 100%;
}

.mobile-realm-select-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    background: rgba(14, 16, 23, 0.95);
    border: 1px solid rgba(212, 175, 55, 0.45);
    border-radius: 10px;
    padding: 6px 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
    box-sizing: border-box;
}

.mobile-realm-ico {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.mobile-realm-select {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 4px 0;
    width: 100%;
}

.mobile-realm-select option {
    background: #12141d;
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.9rem;
    padding: 8px;
}

.realm-tabs-bar {
    display: flex;
    gap: 8px;
    background: rgba(14, 16, 23, 0.92);
    padding: 6px;
    border-radius: 12px;
    border: 1px solid rgba(212, 175, 55, 0.25);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    overflow-x: auto;
}

.realm-tab {
    flex: 1;
    min-width: 140px;
    padding: 10px 18px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 8px;
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    transition: all 0.25s ease;
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.realm-tab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(212, 175, 55, 0.25);
}

.realm-tab.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25) 0%, rgba(184, 134, 11, 0.1) 100%);
    color: var(--gold-bright);
    border-color: rgba(212, 175, 55, 0.55);
    box-shadow: 0 2px 12px rgba(212, 175, 55, 0.2);
}

.sub-tabs-container {
    position: relative;
    width: 100%;
}

.sub-tabs-realm {
    display: none;
    gap: 8px;
    overflow-x: auto;
    padding: 2px 4px 6px;
    scrollbar-width: thin;
    animation: fadeInRealm 0.25s ease forwards;
}

.sub-tabs-realm.active {
    display: flex;
}

@keyframes fadeInRealm {
    from { opacity: 0; transform: translateY(-4px); }
    to { opacity: 1; transform: translateY(0); }
}

.sub-tabs-realm .nav-tab {
    background: rgba(18, 22, 32, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 9px 18px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.sub-tabs-realm .nav-tab:hover {
    background: rgba(28, 34, 50, 0.95);
    color: var(--text-primary);
    border-color: rgba(212, 175, 55, 0.35);
}

.sub-tabs-realm .nav-tab.active {
    background: rgba(212, 175, 55, 0.18);
    color: var(--gold-bright);
    border-color: var(--gold-primary);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.25);
}

/* ==================== TABS ==================== */
.nav-tabs-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 16px;
    position: relative;
}

.nav-tabs-wrapper {
    display: flex;
    align-items: center;
    position: relative;
    gap: 8px;
}

.nav-scroll-btn {
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(18, 21, 30, 0.95);
    border: 1px solid var(--border-color);
    color: var(--gold-bright);
    font-size: 1.3rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
    z-index: 5;
    user-select: none;
}

.nav-scroll-btn:hover:not(:disabled) {
    background: var(--gold-primary);
    color: #111;
    border-color: var(--gold-bright);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.4);
    transform: scale(1.08);
}

.nav-scroll-btn:disabled {
    opacity: 0.2;
    cursor: not-allowed;
}

.nav-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: rgba(212, 175, 55, 0.4) rgba(0, 0, 0, 0.25);
    padding: 4px 0 8px;
    width: 100%;
    -webkit-overflow-scrolling: touch;
}

.nav-tabs::-webkit-scrollbar {
    height: 4px;
}

.nav-tabs::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 4px;
}

.nav-tabs::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #d4af37, #f6e27a);
    border-radius: 4px;
}

.nav-tab {
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-secondary);
    font-family: var(--font-body);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 12px 20px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.25s ease;
    white-space: nowrap;
}

.nav-tab:hover {
    color: var(--text-primary);
    border-bottom-color: rgba(218, 165, 32, 0.4);
}

.nav-tab.active {
    color: var(--gold-bright);
    border-bottom-color: var(--gold-primary);
    background: linear-gradient(180deg, transparent 0%, rgba(212, 175, 55, 0.08) 100%);
}

.badge {
    padding: 2px 7px;
    border-radius: 12px;
    font-size: 0.72rem;
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

.nav-tab.active .badge {
    background: var(--gold-primary);
    color: #111;
    font-weight: 700;
}

.new-badge {
    background: var(--crimson) !important;
    color: #fff !important;
    font-weight: 700;
}

/* ==================== GUEST BANNER & ACTIONS ==================== */
.guest-banner {
    max-width: 1400px;
    margin: 16px auto 0;
    padding: 12px 20px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.12) 0%, rgba(18, 21, 30, 0.95) 100%);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
}

.guest-banner .banner-icon {
    font-size: 1.6rem;
    flex-shrink: 0;
}

.guest-banner .banner-content {
    flex: 1;
    font-size: 0.92rem;
    color: var(--text-primary);
    line-height: 1.4;
}

.guest-banner .banner-content code {
    background: rgba(0, 0, 0, 0.4);
    color: var(--gold-bright);
    padding: 2px 7px;
    border-radius: 4px;
    font-weight: bold;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.guest-banner .banner-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

/* ==================== DISCORD BUTTONS & AUTH MODAL ==================== */
.btn-discord {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #5865F2;
    color: #ffffff !important;
    font-weight: 600;
    font-size: 0.88rem;
    padding: 8px 16px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 10px rgba(88, 101, 242, 0.3);
    white-space: nowrap;
}

.btn-discord:hover {
    background: #4752c4;
    box-shadow: 0 4px 18px rgba(88, 101, 242, 0.55);
    transform: translateY(-1px);
}

.btn-discord.btn-lg {
    padding: 12px 20px;
    font-size: 1rem;
    border-radius: 10px;
}

.modal-oauth-action {
    margin: 16px 0;
}

.auth-modal-divider {
    display: flex;
    align-items: center;
    margin: 18px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.72rem;
    letter-spacing: 1px;
}

.auth-modal-divider::before,
.auth-modal-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.auth-modal-divider span {
    padding: 0 10px;
}

.auth-royal-modal {
    max-width: 520px;
}

/* ==================== MAIN LAYOUT ==================== */
.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 28px 24px 60px;
    flex: 1;
    width: 100%;
}

.tab-content {
    display: none;
    animation: fadeIn 0.35s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================== TAB 1 : GRIMOIRE ==================== */
.grimoire-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.search-box-wrapper {
    position: relative;
    flex: 1;
    min-width: 320px;
}

.search-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    opacity: 0.6;
}

.search-input {
    width: 100%;
    padding: 14px 44px 14px 48px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.95rem;
    outline: none;
    transition: all 0.25s ease;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.search-input:focus {
    border-color: var(--gold-primary);
    box-shadow: 0 0 16px rgba(212, 175, 55, 0.25);
    background: rgba(25, 28, 42, 0.95);
}

.clear-search-btn {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.1rem;
    cursor: pointer;
    display: none;
}

.clear-search-btn:hover {
    color: var(--text-primary);
}

.stats-summary {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.stats-summary span {
    color: var(--gold-bright);
    font-weight: 700;
}

/* Category Filters Container */
.category-filters-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    position: relative;
}

.chip-scroll-btn {
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(18, 21, 30, 0.95);
    border: 1px solid var(--border-color);
    color: var(--gold-bright);
    font-size: 1.2rem;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 4;
    user-select: none;
}

.chip-scroll-btn:hover:not(:disabled) {
    background: var(--gold-primary);
    color: #111;
    border-color: var(--gold-bright);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.35);
    transform: scale(1.08);
}

.chip-scroll-btn:disabled {
    opacity: 0.2;
    cursor: not-allowed;
}

.category-filters-scroll {
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: rgba(212, 175, 55, 0.4) rgba(0, 0, 0, 0.25);
    width: 100%;
    -webkit-overflow-scrolling: touch;
}

.category-filters-scroll::-webkit-scrollbar {
    height: 4px;
}

.category-filters-scroll::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.25);
    border-radius: 4px;
}

.category-filters-scroll::-webkit-scrollbar-thumb {
    background: linear-gradient(90deg, #d4af37, #f6e27a);
    border-radius: 4px;
}

.category-filters {
    display: flex;
    gap: 10px;
    white-space: nowrap;
}

.filter-chip {
    padding: 9px 16px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-chip:hover {
    border-color: var(--border-hover);
    color: var(--text-primary);
}

.filter-chip.active {
    background: rgba(212, 175, 55, 0.15);
    border-color: var(--gold-primary);
    color: var(--gold-bright);
    font-weight: 700;
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

/* Commands Grid */
.commands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 20px;
}

.command-card {
    background: var(--bg-card);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.command-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gold-primary);
    opacity: 0.3;
    transition: opacity 0.25s ease;
}

.command-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-hover);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), var(--shadow-gold);
}

.command-card:hover::before {
    opacity: 1;
}

.card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.command-name {
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gold-bright);
}

.perm-badge {
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.perm-admin {
    background: rgba(230, 57, 70, 0.2);
    border: 1px solid rgba(230, 57, 70, 0.4);
    color: #ff6b6b;
}

.perm-mod {
    background: rgba(88, 101, 242, 0.2);
    border: 1px solid rgba(88, 101, 242, 0.4);
    color: #8da2fb;
}

.perm-user {
    background: rgba(46, 196, 182, 0.15);
    border: 1px solid rgba(46, 196, 182, 0.3);
    color: var(--green-light);
}

.command-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.5;
}

.command-options {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.option-pill {
    padding: 3px 8px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    font-family: var(--font-mono);
    font-size: 0.78rem;
    color: #cad5e2;
}

.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.category-tag {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.copy-btn {
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid var(--border-color);
    color: var(--gold-bright);
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.copy-btn:hover {
    background: var(--gold-primary);
    color: #111;
    border-color: var(--gold-primary);
}

/* ==================== TAB 2 : AUTOMOD GRANULAIRE ==================== */
.admin-auth-bar {
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.auth-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.auth-actions {
    display: flex;
    gap: 10px;
}

.admin-key-input {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 8px 14px;
    color: var(--text-primary);
    font-size: 0.88rem;
    width: 220px;
}

.automod-header-banner {
    background: linear-gradient(135deg, rgba(22, 25, 37, 0.9) 0%, rgba(35, 25, 60, 0.7) 100%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px 28px;
    margin-bottom: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.banner-text h2 {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 1.35rem;
    margin-bottom: 6px;
}

.banner-text p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    max-width: 800px;
}

.hierarchy-legend {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.badge-source {
    padding: 2px 7px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 700;
}

.badge-source.server { background: rgba(88, 101, 242, 0.25); color: #8da2fb; }
.badge-source.category { background: rgba(131, 56, 236, 0.25); color: #d0a4ff; }
.badge-source.channel { background: rgba(212, 175, 55, 0.25); color: var(--gold-bright); }

/* Guild Tree Component */
.automod-guild-tree {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.category-block {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.category-header {
    background: rgba(18, 20, 30, 0.9);
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    flex-wrap: wrap;
    gap: 12px;
}

.category-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.category-name {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
}

.feature-toggles-row {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.toggle-label-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.3);
    padding: 5px 10px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.toggle-name {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

/* Switch styling */
.switch {
    position: relative;
    display: inline-block;
    width: 38px;
    height: 20px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #33394a;
    transition: .3s cubic-bezier(0.2, 0.8, 0.2, 1);
    border-radius: 20px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s cubic-bezier(0.2, 0.8, 0.2, 1);
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--green-light);
}

input:checked + .slider:before {
    transform: translateX(18px);
}

.channels-sublist {
    padding: 8px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.channel-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: rgba(14, 16, 25, 0.4);
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.03);
    transition: background 0.2s ease;
    flex-wrap: wrap;
    gap: 10px;
}

.channel-row:hover {
    background: rgba(22, 25, 38, 0.7);
}

.channel-tag {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-mono);
    font-size: 0.88rem;
    color: var(--gold-bright);
}

/* ==================== TAB 3 : BROADCAST ==================== */
.broadcast-container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 28px;
}

.broadcast-form-card, .broadcast-preview-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
}

.card-header h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--gold-bright);
    margin-bottom: 6px;
}

.card-header p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: var(--text-secondary);
}

.form-input, .form-textarea, .form-select {
    width: 100%;
    padding: 12px 14px;
    background: var(--bg-surface);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.9rem;
    outline: none;
    transition: all 0.25s ease;
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
    border-color: var(--gold-primary);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

.form-row {
    display: flex;
    gap: 16px;
}

.form-group.half {
    flex: 1;
}

/* Discord Preview */
.discord-embed-preview {
    background: #2b2d31;
    border-radius: 8px;
    display: flex;
    overflow: hidden;
    margin-top: 18px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.embed-border {
    width: 4px;
    background: var(--gold-primary);
}

.embed-border.gold { background: #d4af37; }
.embed-border.crimson { background: #e63946; }
.embed-border.blue { background: #5865f2; }
.embed-border.purple { background: #8338ec; }
.embed-border.green { background: #2ec4b6; }

.embed-content {
    padding: 16px 20px;
    flex: 1;
}

.embed-author {
    font-size: 0.8rem;
    color: #dbdee1;
    font-weight: 600;
}

.embed-title {
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    margin: 6px 0 8px;
}

.embed-description {
    font-size: 0.88rem;
    color: #dbdee1;
    line-height: 1.45;
    margin-bottom: 12px;
    white-space: pre-wrap;
}

.embed-footer {
    font-size: 0.72rem;
    color: #949ba4;
    display: flex;
    gap: 6px;
}

/* ==================== TAB 4 : TELEMETRY ==================== */
.telemetry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.telemetry-card.metric {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 22px;
    display: flex;
    align-items: center;
    gap: 18px;
}

.metric-icon {
    font-size: 2.2rem;
    width: 58px;
    height: 58px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.04);
    border-radius: var(--radius-md);
}

.metric-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.metric-value {
    font-family: var(--font-heading);
    font-size: 1.45rem;
    color: var(--gold-bright);
    margin: 4px 0;
}

.metric-sub {
    font-size: 0.78rem;
    color: var(--green-light);
}

.telemetry-actions-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 28px;
}

.telemetry-actions-card h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--gold-bright);
    margin-bottom: 6px;
}

.telemetry-actions-card p {
    font-size: 0.88rem;
    color: var(--text-secondary);
    margin-bottom: 24px;
}

.actions-buttons-row {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}

.action-feedback {
    margin-top: 16px;
    font-size: 0.9rem;
    font-weight: 600;
}

/* ==================== BUTTONS ==================== */
.btn {
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-gold {
    background: var(--gold-gradient);
    color: #111;
    box-shadow: 0 4px 14px rgba(212, 175, 55, 0.3);
}

.btn-gold:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(246, 226, 122, 0.45);
}

.btn-outline {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover {
    background: rgba(212, 175, 55, 0.12);
    border-color: var(--gold-primary);
    color: var(--gold-bright);
    transform: translateY(-2px);
}

.btn-crimson {
    background: linear-gradient(135deg, #dc2626 0%, #991b1b 100%);
    color: #ffffff !important;
    border: 1px solid rgba(248, 113, 113, 0.5);
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    font-weight: 700;
    cursor: pointer;
}

.btn-crimson:hover {
    background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%);
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    color: #ffffff !important;
}

.btn-crimson:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(220, 38, 38, 0.4);
}

.btn-outline-crimson {
    background: rgba(220, 38, 38, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.45);
    color: #fca5a5;
    font-weight: 700;
    cursor: pointer;
}

.btn-outline-crimson:hover {
    background: rgba(220, 38, 38, 0.25);
    border-color: #ef4444;
    color: #ffffff;
    transform: translateY(-2px);
}

.btn-outline-gold {
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid rgba(212, 175, 55, 0.45);
    color: var(--gold-bright);
    font-weight: 700;
    cursor: pointer;
}

.btn-outline-gold:hover {
    background: rgba(212, 175, 55, 0.25);
    border-color: var(--gold-primary);
    color: #ffffff;
    transform: translateY(-2px);
}

.btn-block {
    width: 100%;
}

/* ==================== FOOTER ==================== */
.royal-footer {
    border-top: 1px solid var(--border-color);
    background: rgba(10, 11, 16, 0.9);
    padding: 24px 20px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: auto;
}

.royal-footer .copyright {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 6px;
}

/* ==================== TOASTS ==================== */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1000;
}

.toast {
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    background: var(--bg-surface);
    color: var(--text-primary);
    border: 1px solid var(--border-hover);
    box-shadow: var(--shadow-soft);
    font-size: 0.88rem;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: toastSlideIn 0.3s ease;
}

@keyframes toastSlideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* Loading Spinner */
.loading-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.spinner {
    width: 44px;
    height: 44px;
    border: 3px solid rgba(212, 175, 55, 0.2);
    border-top-color: var(--gold-primary);
    border-radius: 50%;
    margin: 0 auto 16px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 900px) {
    .broadcast-container {
        grid-template-columns: 1fr;
    }
    .commands-grid {
        grid-template-columns: 1fr;
    }
    .header-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
}

/* ==================== AUTH & USER PROFILE ==================== */
.header-right-side {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}

.user-auth-pill {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(22, 25, 37, 0.85);
    border: 1px solid var(--border-color);
    padding: 6px 14px;
    border-radius: var(--radius-pill);
    transition: var(--transition-fast);
}

.user-auth-pill:hover {
    border-color: var(--gold-primary);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

.user-avatar-wrap {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(212, 175, 55, 0.4);
}

.user-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-details {
    display: flex;
    flex-direction: column;
}

.user-name {
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.1;
}

.user-role-badge {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 2px;
}

.user-role-badge.guest { color: var(--text-muted); }
.user-role-badge.mod { color: #57f287; font-weight: 700; }
.user-role-badge.admin { color: var(--gold-bright); font-weight: 800; }

.nav-tab .badge.locked-badge {
    background: rgba(235, 69, 158, 0.2);
    color: #ff708d;
    border: 1px solid rgba(235, 69, 158, 0.3);
}

.nav-tab .badge.upcoming-badge {
    background: rgba(88, 101, 242, 0.2);
    color: #8da2fb;
    border: 1px solid rgba(88, 101, 242, 0.3);
}

/* ==================== TAVERNE & MINI-JEUX ==================== */
.tavern-container {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.tavern-header-card {
    background: linear-gradient(135deg, rgba(30, 20, 10, 0.85) 0%, rgba(50, 30, 15, 0.7) 100%);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: var(--radius-lg);
    padding: 32px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
}

.tavern-crest {
    font-size: 2.8rem;
    display: inline-block;
    margin-bottom: 8px;
}

.tavern-header-card h2 {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    color: var(--gold-bright);
    margin-bottom: 8px;
}

.tavern-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
    max-width: 680px;
    margin: 0 auto;
}

.tavern-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.tavern-game-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    transition: var(--transition-medium);
}

.tavern-game-card:hover {
    transform: translateY(-4px);
    border-color: var(--gold-primary);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}

.tavern-game-card .game-icon {
    font-size: 2.4rem;
    margin-bottom: 12px;
}

.tavern-game-card h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--gold-bright);
    margin-bottom: 8px;
}

.tavern-game-card p {
    color: var(--text-secondary);
    font-size: 0.88rem;
    line-height: 1.45;
    flex-grow: 1;
    margin-bottom: 16px;
}

.tavern-game-card .game-tag {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--gold-primary);
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid rgba(212, 175, 55, 0.25);
    padding: 4px 10px;
    border-radius: var(--radius-pill);
}

/* ==================== MODAL AUTHENTIFICATION ==================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.modal-card {
    background: var(--bg-surface);
    border: 1px solid var(--gold-primary);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 520px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
    overflow: hidden;
}

.modal-header {
    padding: 18px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.3);
}

.modal-header h3 {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 1.1rem;
}

.btn-close-modal {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
    transition: var(--transition-fast);
}

.btn-close-modal:hover {
    color: #ff5555;
}

.modal-body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.modal-intro {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.modal-method-card {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    position: relative;
}

.modal-method-card .method-badge {
    position: absolute;
    top: -10px;
    right: 14px;
    background: var(--gold-primary);
    color: #0b0d14;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    text-transform: uppercase;
}

.modal-method-card h4 {
    font-size: 0.95rem;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.modal-method-card p {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.modal-method-card code {
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}

.modal-key-row {
    display: flex;
    gap: 10px;
    margin-top: 12px;
}

.modal-key-row .form-input {
    flex-grow: 1;
}

.hidden {
    display: none !important;
}

/* ========================================================
   SECTION 2 : ESPACE CITOYEN / PROFIL & DECK BUILDER
   ======================================================== */

.profile-layout {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 28px;
    align-items: start;
}

@media (max-width: 980px) {
    .profile-layout {
        grid-template-columns: 1fr;
    }
}

/* Carte d'Identité Féodale */
.noble-id-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
}

.noble-id-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gold-gradient);
}

.noble-crest-wrapper {
    position: relative;
    width: 100px;
    height: 100px;
    margin-bottom: 14px;
}

.noble-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--gold-primary);
    box-shadow: 0 0 20px rgba(229, 184, 66, 0.35);
    background: #141724;
}

.faction-emblem-badge {
    position: absolute;
    bottom: -4px;
    right: -4px;
    width: 32px;
    height: 32px;
    background: #0e1018;
    border: 2px solid var(--gold-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.noble-name {
    font-family: var(--font-heading);
    font-size: 1.35rem;
    color: var(--text-primary);
    margin-bottom: 4px;
    letter-spacing: 0.5px;
}

.noble-rank {
    font-size: 0.85rem;
    color: var(--gold-bright);
    font-weight: 600;
    margin-bottom: 2px;
}

.noble-faction {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.profile-faction-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
    padding: 6px 12px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: var(--radius-sm);
    margin: 8px 0 16px 0;
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.profile-faction-box .noble-faction {
    margin: 0;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--faction-color, var(--gold-bright, #f5d77f));
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--font-heading);
    letter-spacing: 0.3px;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.profile-faction-box .noble-faction-emoji {
    font-size: 1.05rem;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 0 5px rgba(0, 0, 0, 0.6));
    flex-shrink: 0;
}

.profile-faction-box .noble-faction-text {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-faction-box #btnOpenFactionModal {
    padding: 4px 10px;
    font-size: 0.72rem;
    white-space: nowrap;
    flex-shrink: 0;
    margin: 0;
    line-height: 1.2;
}

/* Bourse & Banque */
.profile-wealth-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
    margin-bottom: 18px;
}

.wealth-item {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(229, 184, 66, 0.2);
    border-radius: var(--radius-sm);
    padding: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
    text-align: left;
}

.wealth-icon {
    font-size: 1.5rem;
}

.wealth-body {
    display: flex;
    flex-direction: column;
}

.wealth-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.wealth-val {
    font-size: 0.95rem;
    color: var(--gold-bright);
    font-family: var(--font-mono);
}

/* XP Bar */
.profile-xp-card {
    width: 100%;
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 12px;
    margin-bottom: 18px;
}

.xp-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.8rem;
    margin-bottom: 6px;
    font-weight: 600;
}

.xp-lvl {
    color: var(--gold-primary);
}

.xp-pct {
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

.xp-bar-track {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 6px;
}

.xp-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #d4af37, #f6e27a);
    box-shadow: 0 0 10px rgba(246, 226, 122, 0.5);
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.xp-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
    display: block;
}

/* Quêtes Fiche */
.profile-quests-box {
    width: 100%;
    text-align: left;
}

.profile-quests-box h3 {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    color: var(--gold-primary);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.quests-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.quest-item {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: var(--radius-sm);
    padding: 8px 10px;
    font-size: 0.8rem;
}

.quest-item.completed {
    border-color: rgba(46, 196, 182, 0.4);
    background: rgba(46, 196, 182, 0.08);
}

.quest-title-row {
    display: flex;
    justify-content: space-between;
    font-weight: 600;
    margin-bottom: 4px;
}

.quest-reward-tag {
    color: var(--gold-bright);
    font-size: 0.75rem;
    font-family: var(--font-mono);
}

.quest-desc {
    color: var(--text-secondary);
    font-size: 0.75rem;
    margin-bottom: 6px;
}

.quest-progress-track {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}

.quest-progress-fill {
    height: 100%;
    background: var(--gold-primary);
}

/* Deck Builder */
.deck-builder-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow-soft);
}

.deck-builder-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 18px;
    flex-wrap: wrap;
    gap: 12px;
}

.deck-builder-header h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--gold-bright);
}

.deck-builder-header p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Barre d'Optimisation Automatique Royale */
.deck-auto-optimize-card {
    background: linear-gradient(135deg, rgba(26, 32, 50, 0.85) 0%, rgba(14, 18, 28, 0.95) 100%);
    border: 1px solid rgba(229, 184, 66, 0.35);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), inset 0 0 14px rgba(229, 184, 66, 0.08);
}

.auto-opt-intro {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-width: 580px;
}

.auto-opt-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-heading);
    font-size: 1rem;
    color: var(--gold-bright);
    letter-spacing: 0.5px;
}

.auto-opt-icon {
    font-size: 1.15rem;
    animation: lightningPulse 1.5s infinite alternate;
}

@keyframes lightningPulse {
    from { transform: scale(1); filter: drop-shadow(0 0 4px #ffd166); }
    to { transform: scale(1.2); filter: drop-shadow(0 0 10px #ffb703); }
}

.auto-opt-desc {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

.auto-opt-btn-group {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}

.auto-opt-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    font-size: 0.82rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.2s ease;
    white-space: nowrap;
}

.auto-opt-btn:hover {
    transform: translateY(-2px);
}

#btnAutoOptimizeAll {
    box-shadow: 0 4px 15px rgba(229, 184, 66, 0.35);
}

#btnAutoOptimizeAll:hover {
    box-shadow: 0 4px 22px rgba(229, 184, 66, 0.6);
}

.profile-trio-actions, .arena-team-header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.deck-slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
    margin-bottom: 20px;
}

@media (max-width: 900px) {
    .deck-slots-grid {
        grid-template-columns: 1fr;
    }
}

.deck-slot-card {
    background: rgba(14, 16, 26, 0.85);
    border: 2px dashed rgba(229, 184, 66, 0.4);
    border-radius: 12px;
    padding: 16px 12px 14px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 380px;
    position: relative;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.deck-slot-card:hover {
    border-color: var(--gold-primary);
    background: rgba(22, 26, 42, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

.deck-slot-card.active-target {
    border-color: var(--gold-bright);
    box-shadow: 0 0 20px rgba(229, 184, 66, 0.4), inset 0 0 15px rgba(229, 184, 66, 0.15);
}

.deck-slot-card.drag-over {
    border: 2px solid var(--gold-bright) !important;
    background: rgba(229, 184, 66, 0.18) !important;
    box-shadow: 0 0 30px rgba(229, 184, 66, 0.6), inset 0 0 25px rgba(229, 184, 66, 0.3) !important;
    transform: scale(1.025);
}

.slot-role-badge {
    position: absolute;
    top: -12px;
    background: var(--gold-gradient);
    color: #0b0d14;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 3px 14px;
    border-radius: var(--radius-pill);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.6);
    border: 1px solid #ffe885;
    z-index: 5;
}

.slot-card-preview {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.empty-slot-placeholder {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-style: italic;
    padding: 60px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    border-radius: 8px;
    transition: all 0.2s;
}

.empty-slot-placeholder::before {
    content: '⚔️';
    font-size: 2.2rem;
    opacity: 0.4;
    filter: grayscale(0.5);
}

.deck-slot-card.drag-over .empty-slot-placeholder {
    color: var(--gold-bright);
    font-weight: 700;
}

/* ========================================================
   CARTE MÉDIÉVALE PARCHEMIN (FIDÈLE DISCORD BOT)
   ======================================================== */
.feudal-card {
    position: relative;
    width: 100%;
    max-width: 320px;
    background: linear-gradient(180deg, #ede0c4 0%, #e2d1b0 45%, #c8a77b 100%);
    border: 3px solid #d4af37;
    border-radius: 10px;
    padding: 10px 10px 8px 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7), inset 0 0 20px rgba(90, 60, 20, 0.45);
    color: #231911;
    font-family: var(--font-body);
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-sizing: border-box;
    user-select: none;
}

.feudal-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.85), inset 0 0 20px rgba(90, 60, 20, 0.4);
}

.feudal-card[draggable="true"] {
    cursor: grab;
}

.feudal-card[draggable="true"]:active {
    cursor: grabbing;
}

.feudal-card.dragging {
    opacity: 0.45;
    transform: scale(0.96) rotate(2deg);
    border-color: var(--gold-bright);
    box-shadow: 0 15px 35px rgba(212, 175, 55, 0.5);
}

/* 4 Coins orfèvrerie féodale */
.feudal-corner {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #f5d75f;
    border: 1.5px solid #78550f;
    transform: rotate(45deg);
    z-index: 2;
    box-shadow: 0 0 4px rgba(0,0,0,0.4);
}
.feudal-corner.corner-tl { top: -5px; left: -5px; }
.feudal-corner.corner-tr { top: -5px; right: -5px; }
.feudal-corner.corner-bl { bottom: -5px; left: -5px; }
.feudal-corner.corner-br { bottom: -5px; right: -5px; }

/* Bannière supérieure de rareté + étoiles */
.feudal-top-banner {
    background: rgba(35, 28, 20, 0.95);
    border: 1.5px solid #d4af37;
    border-radius: 6px;
    padding: 4px 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
}

.feudal-rarity-badge {
    font-family: var(--font-heading);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 1px;
    color: #f5d75f;
    text-transform: uppercase;
}

.feudal-stars {
    color: #f5c32d;
    font-size: 0.85rem;
    letter-spacing: 2px;
    filter: drop-shadow(0 0 4px rgba(245, 195, 45, 0.6));
}

/* Titre de la carte */
.feudal-card-name {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 800;
    color: #1c140e;
    text-align: center;
    margin: 2px 0 0 0;
    padding: 0 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
}

/* Cadre d'illustration */
.feudal-art-frame {
    position: relative;
    width: 100%;
    height: 140px;
    background: #100e12;
    border: 2px solid #8c641e;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.8), 0 2px 6px rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: center;
    align-items: center;
}

.feudal-art-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.feudal-card:hover .feudal-art-img {
    transform: scale(1.04);
}

.feudal-inspect-trigger {
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(20, 16, 12, 0.85);
    border: 1px solid #d4af37;
    color: #f5d75f;
    font-size: 0.75rem;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    z-index: 3;
}

.feudal-inspect-trigger:hover {
    background: #d4af37;
    color: #100e12;
    transform: scale(1.15);
}

.feudal-deck-tag {
    position: absolute;
    bottom: 6px;
    left: 6px;
    background: var(--green-light);
    color: #0b0d14;
    font-size: 0.6rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
    letter-spacing: 0.5px;
}

/* Barre de stats ATK / DEF / PV */
.feudal-stats-bar {
    background: rgba(35, 28, 20, 0.95);
    border: 1.5px solid #d4af37;
    border-radius: 6px;
    padding: 4px 8px;
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 4px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.feudal-stat-cell {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.1;
}

.feudal-stat-cell .stat-lbl {
    font-size: 0.58rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.feudal-stat-cell .stat-val {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 800;
}

.feudal-stat-cell.stat-atk .stat-lbl { color: #f5a0a0; }
.feudal-stat-cell.stat-atk .stat-val { color: #f58c8c; }
.feudal-stat-cell.stat-def .stat-lbl { color: #a0d4f5; }
.feudal-stat-cell.stat-def .stat-val { color: #8cc8f5; }
.feudal-stat-cell.stat-hp .stat-lbl { color: #a8f5c0; }
.feudal-stat-cell.stat-hp .stat-val { color: #57cc99; }

/* Deux badges héraldiques : Team / Ordre + Caractère */
.feudal-badges-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px;
}

.feudal-badge {
    background: rgba(28, 22, 18, 0.95);
    border: 1.5px solid #d4af37;
    border-radius: 5px;
    padding: 3px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    line-height: 1.1;
}

.feudal-badge .badge-tag {
    font-size: 0.55rem;
    font-weight: 700;
    color: #c8aa6e;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.feudal-badge .badge-title {
    font-size: 0.72rem;
    font-weight: 800;
    color: #fff5e6;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.feudal-badge.badge-trait {
    border-color: #c3872d;
}

.feudal-badge.badge-trait .badge-title {
    color: #f5d778;
}

/* Pilules de Talents / Caractère */
.feudal-trait-pills {
    display: flex;
    gap: 4px;
    font-size: 0.65rem;
    font-family: var(--font-mono);
}

.trait-pill {
    flex: 1;
    padding: 2px 4px;
    border-radius: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
    font-weight: 700;
}

.trait-pill.perk-bonus {
    background: rgba(46, 117, 89, 0.25);
    border: 1px solid rgba(46, 117, 89, 0.5);
    color: #1b533b;
}

.trait-pill.perk-malus {
    background: rgba(186, 45, 59, 0.2);
    border: 1px solid rgba(186, 45, 59, 0.4);
    color: #7d1c25;
}

/* Ligne Équipements */
.feudal-gear-bar {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    font-size: 0.68rem;
    font-family: var(--font-mono);
    color: #5d421d;
    font-weight: 700;
    padding: 1px 0;
}

.feudal-gear-bar .gear-entry.equipped {
    color: #2b1e10;
}

.feudal-gear-bar .gear-entry.empty {
    opacity: 0.6;
    font-style: italic;
}

/* Citation / Lore */
.feudal-lore-box {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
    padding: 3px 6px;
    text-align: center;
    min-height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feudal-quote {
    font-size: 0.68rem;
    font-style: italic;
    color: #3b2a1c;
    line-height: 1.25;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Séparateur antique */
.feudal-sep-line {
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(150, 115, 65, 0.8), transparent);
    margin: 1px 0;
}

/* Footer de carte */
.feudal-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.68rem;
    font-family: var(--font-mono);
    color: #2b1f15;
    font-weight: 800;
    padding: 0 2px;
}

.footer-forge {
    color: #9c6c0e;
}

.footer-code {
    background: rgba(35, 28, 20, 0.12);
    padding: 1px 5px;
    border-radius: 3px;
    border: 1px solid rgba(150, 115, 65, 0.3);
}

/* Boutons d'actions */
.feudal-card-actions {
    display: flex;
    gap: 4px;
    width: 100%;
    margin-top: 3px;
}

.feudal-card-actions button {
    flex: 1;
    font-size: 0.68rem;
    padding: 4px 2px;
    font-weight: 700;
}

/* Grille de collection */
.player-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    gap: 16px;
    max-height: 700px;
    overflow-y: auto;
    padding-right: 6px;
}

/* ========================================================
   NOUVEAU COMPOSANT CARTE FÉODALE UNIFIÉE (FULL STATS & GEAR)
   ======================================================== */
.feudal-card-chassis,
.feudal-card.feudal-card-chassis {
    position: relative;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
    background: linear-gradient(165deg, #171c2b 0%, #101420 50%, #090b12 100%) !important;
    border: 2px solid var(--gold-primary) !important;
    border-radius: 12px !important;
    padding: 10px !important;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.8), inset 0 0 20px rgba(229, 184, 66, 0.05) !important;
    color: #e2e8f0;
    font-family: var(--font-body);
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 7px !important;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.25s ease, border-color 0.25s ease;
    box-sizing: border-box !important;
    user-select: none;
    overflow: hidden !important;
}

.feudal-card-chassis:hover,
.feudal-card.feudal-card-chassis:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.9), 0 0 20px rgba(229, 184, 66, 0.25) !important;
    border-color: var(--gold-bright) !important;
}

.feudal-card-chassis[draggable="true"] { cursor: grab; }
.feudal-card-chassis[draggable="true"]:active { cursor: grabbing; }

/* Bordures & halos thématiques selon la Rareté */
.feudal-card-chassis.rarity-common { border-color: #64748b !important; box-shadow: 0 8px 24px rgba(0,0,0,0.6) !important; }
.feudal-card-chassis.rarity-uncommon { border-color: #10b981 !important; box-shadow: 0 8px 24px rgba(16, 185, 129, 0.25) !important; }
.feudal-card-chassis.rarity-rare { border-color: #3b82f6 !important; box-shadow: 0 8px 24px rgba(59, 130, 246, 0.3) !important; }
.feudal-card-chassis.rarity-epic { border-color: #a855f7 !important; box-shadow: 0 8px 26px rgba(168, 85, 247, 0.35) !important; }
.feudal-card-chassis.rarity-legendary { border-color: #f59e0b !important; box-shadow: 0 8px 30px rgba(245, 158, 11, 0.45) !important; }
.feudal-card-chassis.rarity-mythic { border-color: #ef4444 !important; box-shadow: 0 8px 35px rgba(239, 68, 68, 0.55) !important; }

/* Masquer les anciens coins dépassants */
.feudal-corner { display: none !important; }

/* En-tête Rareté & Élément */
.card-chassis-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    width: 100%;
    box-sizing: border-box;
    z-index: 2;
}

.card-chassis-rarity {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.68rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: var(--radius-pill);
    text-transform: uppercase;
    letter-spacing: 0.8px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.card-chassis-rarity .rarity-stars {
    color: #ffd166;
    letter-spacing: 1px;
    font-size: 0.72rem;
}

.card-chassis-element {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: var(--radius-pill);
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
}

/* Identité : Titre & Faction */
.card-chassis-identity {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

.card-chassis-name {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 800;
    color: #fff;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: 0.3px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
    line-height: 1.25;
}

.card-chassis-meta-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.72rem;
    color: var(--text-muted);
    min-width: 0;
    width: 100%;
}

.card-faction-badge {
    color: var(--gold-bright);
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 170px;
}

.card-code-badge {
    font-family: var(--font-mono);
    background: rgba(0, 0, 0, 0.45);
    padding: 1px 6px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 0.65rem;
    flex-shrink: 0;
}

/* Cadre illustration Artwork */
.card-chassis-art-frame {
    position: relative;
    width: 100%;
    height: 145px;
    background: #080a10;
    border: 1.5px solid rgba(229, 184, 66, 0.35);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: inset 0 0 16px rgba(0, 0, 0, 0.85);
    box-sizing: border-box;
}

.card-chassis-art-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 25%;
    display: block;
    transition: transform 0.35s ease;
}

.feudal-card-chassis:hover .card-chassis-art-img {
    transform: scale(1.06);
}

.card-chassis-print-tag {
    position: absolute;
    bottom: 6px;
    left: 6px;
    background: rgba(11, 13, 20, 0.88);
    border: 1px solid rgba(229, 184, 66, 0.35);
    color: var(--gold-bright);
    font-family: var(--font-mono);
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    z-index: 2;
}

.feudal-card-zoom-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 28px;
    height: 28px;
    background: rgba(10, 12, 20, 0.88);
    border: 1px solid var(--gold-primary);
    border-radius: 50%;
    color: var(--gold-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 4;
    font-size: 0.75rem;
    line-height: 1;
    padding: 0;
    opacity: 0.85;
    transition: transform 0.2s, background 0.2s, opacity 0.2s;
}

.feudal-card-chassis:hover .feudal-card-zoom-btn {
    opacity: 1;
    transform: scale(1.08);
}

.feudal-card-zoom-btn:hover {
    transform: scale(1.15) !important;
    background: var(--gold-primary);
    color: #000;
}

/* Grille des 5 Statistiques (PV, ATK, DEF, VIT, CRIT) */
.card-chassis-stats-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 3px;
    background: rgba(9, 12, 20, 0.9);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: 7px;
    padding: 5px 3px;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.6);
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

.stat-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 2px;
    padding: 2px 1px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.02);
    min-width: 0;
}

.stat-pill .stat-lbl {
    font-size: 0.58rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1;
    white-space: nowrap;
}

.stat-pill .stat-num {
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.stat-pill.stat-hp .stat-lbl { color: #86efac; }
.stat-pill.stat-hp .stat-num { color: #4ade80; }

.stat-pill.stat-atk .stat-lbl { color: #fca5a5; }
.stat-pill.stat-atk .stat-num { color: #f87171; }

.stat-pill.stat-def .stat-lbl { color: #93c5fd; }
.stat-pill.stat-def .stat-num { color: #60a5fa; }

.stat-pill.stat-spd .stat-lbl { color: #fde68a; }
.stat-pill.stat-spd .stat-num { color: #fbbf24; }

.stat-pill.stat-crit .stat-lbl { color: #f0abfc; }
.stat-pill.stat-crit .stat-num { color: #e879f9; }

/* Arsenal : Équipements rattachés au personnage */
.card-chassis-gear-shelf {
    display: flex;
    flex-direction: column;
    gap: 3px;
    background: rgba(8, 10, 18, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    padding: 4px 6px;
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
}

.gear-slot-chip {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.7rem;
    padding: 2px 4px;
    border-radius: 4px;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.gear-slot-chip.equipped {
    background: rgba(229, 184, 66, 0.12);
    border: 1px solid rgba(229, 184, 66, 0.35);
    color: #f7e7b4;
    font-weight: 600;
}

.gear-slot-chip.empty {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    color: var(--text-muted);
    font-style: italic;
}

.gear-slot-chip .gear-icon { font-size: 0.8rem; flex-shrink: 0; line-height: 1; }
.gear-slot-chip .gear-label { flex: 1 1 0%; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Passif / Tempérament (SÉCURITÉ STRICTE ANTI-DÉBORDEMENT) */
.card-chassis-trait-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.7rem;
    background: rgba(147, 51, 234, 0.12);
    border: 1px solid rgba(147, 51, 234, 0.32);
    color: #e9d5ff;
    padding: 4px 7px;
    border-radius: 6px;
    width: 100%;
    box-sizing: border-box;
    min-width: 0;
    overflow: hidden;
}

.card-chassis-trait-pill .trait-emoji {
    font-size: 0.82rem;
    flex-shrink: 0;
    line-height: 1;
}

.card-chassis-trait-pill .trait-name {
    font-weight: 700;
    color: #f3e8ff;
    flex-shrink: 0;
    white-space: nowrap;
}

.card-chassis-trait-pill .trait-desc-inline {
    flex: 1 1 0%;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #cbd5e1;
    font-size: 0.68rem;
}

/* Actions au pied de la carte */
.feudal-card-actions {
    display: flex;
    gap: 5px;
    width: 100%;
    margin-top: 2px;
    box-sizing: border-box;
}

.feudal-card-actions .btn-card-assign {
    flex: 1 1 0%;
    min-width: 0;
    padding: 6px 2px;
    font-size: 0.73rem;
    font-weight: 700;
    border-radius: 6px;
    white-space: nowrap;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.feudal-card-actions .btn-assign-tank {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
    color: #93c5fd;
}
.feudal-card-actions .btn-assign-tank:hover {
    background: #2563eb;
    color: #fff;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4);
}

.feudal-card-actions .btn-assign-dps {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    color: #fca5a5;
}
.feudal-card-actions .btn-assign-dps:hover {
    background: #dc2626;
    color: #fff;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.4);
}

.feudal-card-actions .btn-assign-tact {
    background: rgba(245, 158, 11, 0.2);
    border-color: rgba(245, 158, 11, 0.5);
    color: #fde68a;
}
.feudal-card-actions .btn-assign-tact:hover {
    background: #d97706;
    color: #fff;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.4);
}

.feudal-card-actions .btn-card-remove {
    width: 100%;
    padding: 6px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 6px;
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.6);
    color: #fca5a5;
    cursor: pointer;
    transition: all 0.2s ease;
}
.feudal-card-actions .btn-card-remove:hover {
    background: #dc2626;
    color: #fff;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.45);
}

/* ========================================================
   BANNIÈRE SYNERGIES DU TRIO FÉODAL
   ======================================================== */
.trio-synergies-panel {
    background: rgba(18, 21, 35, 0.85);
    border: 2px solid var(--gold-primary);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin-bottom: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

.trio-synergies-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    flex-wrap: wrap;
    gap: 8px;
}

.trio-synergies-header h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: var(--gold-bright);
    margin: 0;
}

.trio-synergies-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.synergy-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(35, 28, 20, 0.8);
    border: 1.5px solid #d4af37;
    border-radius: var(--radius-pill);
    padding: 6px 14px;
    font-size: 0.8rem;
    color: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    transition: all 0.25s ease;
}

.synergy-chip.active {
    border-color: var(--green-light);
    background: rgba(46, 117, 89, 0.25);
    box-shadow: 0 0 12px rgba(87, 204, 153, 0.4);
    animation: pulseGlowGreen 2s infinite alternate;
}

.synergy-chip.inactive {
    opacity: 0.55;
    border-color: rgba(255, 255, 255, 0.15);
    background: rgba(0,0,0,0.3);
}

@keyframes pulseGlowGreen {
    from { box-shadow: 0 0 8px rgba(87, 204, 153, 0.3); }
    to { box-shadow: 0 0 16px rgba(87, 204, 153, 0.7); }
}

/* Couleurs de Raretés des Cartes */
.rarity-mythic {
    border-color: #ff007f !important;
    box-shadow: 0 0 14px rgba(255, 0, 127, 0.4);
    animation: mythicGlow 3s infinite alternate;
}
.rarity-legendary {
    border-color: #e5b842 !important;
    box-shadow: 0 0 12px rgba(229, 184, 66, 0.35);
}
.rarity-epic {
    border-color: #8338ec !important;
    box-shadow: 0 0 10px rgba(131, 56, 236, 0.3);
}
.rarity-rare {
    border-color: #3a86ff !important;
    box-shadow: 0 0 8px rgba(58, 134, 255, 0.25);
}
.rarity-uncommon {
    border-color: #2ec4b6 !important;
}
.rarity-common {
    border-color: #647087 !important;
}

@keyframes mythicGlow {
    0% { box-shadow: 0 0 10px #ff007f, 0 0 20px #8338ec; }
    50% { box-shadow: 0 0 14px #3a86ff, 0 0 24px #e5b842; }
    100% { box-shadow: 0 0 10px #ff007f, 0 0 20px #8338ec; }
}

/* ========================================================
   SECTION 3 : ARÈNE DE COMBAT (DONJON PVE)
   ======================================================== */

.arena-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.arena-banner {
    background: linear-gradient(135deg, rgba(230, 57, 70, 0.15) 0%, rgba(22, 25, 37, 0.9) 100%);
    border: 1px solid rgba(230, 57, 70, 0.3);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 24px;
}

.arena-banner-crest {
    font-size: 3rem;
}

.arena-banner h2 {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.arena-banner p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

/* Grille des Étages */
/* Grille des Étages */
.floors-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 16px;
    align-items: stretch;
}

.floor-card {
    background: linear-gradient(165deg, #12141c 0%, #0c0d12 100%);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(212, 175, 55, 0.28);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 240px;
    gap: 12px;
    position: relative;
    transition: all 0.25s ease;
    box-shadow: inset 0 0 0 1px rgba(255, 215, 0, 0.05), 0 8px 24px rgba(0, 0, 0, 0.5);
}

.floor-card:hover:not(.locked) {
    border-color: var(--gold-primary);
    transform: translateY(-4px);
    box-shadow: inset 0 0 0 1px rgba(255, 215, 0, 0.15), 0 12px 30px rgba(0, 0, 0, 0.7), 0 0 18px rgba(212, 175, 55, 0.25);
}

.floor-card.locked {
    opacity: 0.5;
    filter: grayscale(0.85);
    cursor: not-allowed;
    border-color: rgba(255, 255, 255, 0.08);
}

.floor-card.cleared {
    border-color: rgba(46, 196, 182, 0.45);
    background: linear-gradient(165deg, rgba(46, 196, 182, 0.08) 0%, #0c0d12 100%);
}

.floor-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.floor-title-group {
    display: flex;
    align-items: center;
    gap: 5px;
    min-width: 0;
    overflow: hidden;
}

.floor-number-badge {
    font-size: 0.72rem;
    font-weight: 800;
    font-family: var(--font-heading);
    color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.3);
    padding: 2px 7px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.floor-biome-tag {
    font-size: 0.68rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.floor-status-badge {
    font-size: 0.68rem;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
    white-space: nowrap;
    flex-shrink: 0;
}

.floor-status-badge.status-cleared {
    background: rgba(46, 196, 182, 0.15);
    color: #2ec4b6;
    border: 1px solid rgba(46, 196, 182, 0.35);
}

.floor-status-badge.status-ready {
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.floor-status-badge.status-locked {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.floor-boss-info {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 54px;
    height: 54px;
}

.floor-boss-avatar {
    width: 52px;
    height: 52px;
    min-width: 52px;
    border-radius: 6px;
    border: 1.5px solid var(--gold-primary);
    object-fit: cover;
    background: #000;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.25);
}

.floor-boss-text-wrapper {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.floor-boss-name {
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 0.88rem;
    color: #f5edd8;
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.floor-boss-lvl {
    font-size: 0.72rem;
    color: #e63946;
    font-family: var(--font-mono);
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.floor-rewards-row {
    font-size: 0.72rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    border-top: 1px solid rgba(212, 175, 55, 0.12);
    padding-top: 8px;
    margin-top: 2px;
    flex-wrap: wrap;
}

.floor-rewards-row .reward-badge {
    font-size: 0.70rem;
    padding: 2px 6px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.btn-challenge-floor {
    margin-top: auto;
    width: 100%;
}

/* CHAMP DE BATAILLE EN DIRECT */
.arena-battle-stage {
    background: radial-gradient(circle at center, #1a1e2d 0%, #0d0f17 100%);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.battle-stage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 14px;
}

.battle-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.battle-round-badge {
    background: var(--gold-gradient);
    color: #0b0d14;
    font-weight: 800;
    font-size: 0.8rem;
    padding: 4px 12px;
    border-radius: var(--radius-pill);
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.battle-stage-header h2 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--text-primary);
}
.battle-stage-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
    background: rgba(14, 18, 28, 0.7);
    padding: 12px 18px;
    border-radius: var(--radius-md);
    border: 1px solid rgba(229, 184, 66, 0.2);
}

.battle-header-actions {
    display: flex;
    align-items: center;
    gap: 14px;
}

.battle-stage-tip {
    font-size: 0.8rem;
    color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.1);
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(229, 184, 66, 0.25);
}

.battle-field {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 18px;
}

.battle-team-row {
    background: radial-gradient(circle at 50% 0%, rgba(26, 32, 50, 0.8) 0%, rgba(10, 13, 22, 0.95) 100%);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
    position: relative;
}

.battle-team-row.enemy-row {
    border-top: 3px solid var(--crimson);
}

.battle-team-row.ally-row {
    border-top: 3px solid var(--gold-primary);
}

/* ==================== PANNEAU D'INITIATIVE ROYALE (CHACUN SON TOUR) ==================== */
.battle-initiative-panel {
    background: linear-gradient(135deg, rgba(16, 22, 38, 0.95) 0%, rgba(9, 13, 24, 0.98) 100%);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    margin-bottom: 16px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
    position: relative;
    overflow: hidden;
}

.initiative-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    padding-bottom: 8px;
}

.initiative-header-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    color: var(--text-primary);
}

.initiative-icon {
    font-size: 1.1rem;
}

.initiative-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: normal;
}

.initiative-turn-indicator {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 12px;
    background: rgba(229, 184, 66, 0.12);
    border: 1px solid rgba(229, 184, 66, 0.4);
    border-radius: var(--radius-pill);
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--gold-bright);
}

.turn-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--gold-bright);
    box-shadow: 0 0 8px var(--gold-bright);
}

.turn-dot.pulse {
    animation: turnDotPulse 1.2s infinite ease-in-out;
}

@keyframes turnDotPulse {
    0%, 100% { transform: scale(0.9); opacity: 0.7; }
    50% { transform: scale(1.3); opacity: 1; }
}

.initiative-timeline-track {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    padding: 6px 2px 4px 2px;
    scrollbar-width: thin;
}

.initiative-timeline-track::-webkit-scrollbar {
    height: 4px;
}

.initiative-timeline-track::-webkit-scrollbar-thumb {
    background: rgba(229, 184, 66, 0.3);
    border-radius: 2px;
}

.initiative-node {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(18, 24, 38, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 6px 10px;
    min-width: 145px;
    flex-shrink: 0;
    position: relative;
    transition: all 0.25s ease;
}

.initiative-node.node-player {
    border-left: 3px solid #3a86ff;
}

.initiative-node.node-enemy {
    border-left: 3px solid #e63946;
}

.initiative-node.is-current {
    border-color: var(--gold-bright) !important;
    background: rgba(229, 184, 66, 0.12) !important;
    box-shadow: 0 0 16px rgba(229, 184, 66, 0.4), inset 0 0 10px rgba(229, 184, 66, 0.1);
    transform: translateY(-2px) scale(1.03);
}

.initiative-node.has-acted {
    opacity: 0.45;
    filter: grayscale(0.6);
}

.initiative-node.is-dead {
    opacity: 0.25;
    filter: grayscale(1);
    text-decoration: line-through;
}

.node-order-pill {
    position: absolute;
    top: -5px;
    left: -5px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #0f1523;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.62rem;
    font-weight: 800;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.node-avatar-wrap {
    position: relative;
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.node-avatar {
    width: 100%;
    height: 100%;
    border-radius: 6px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.node-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex-grow: 1;
}

.node-name-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
}

.node-name {
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 80px;
}

.node-spd-badge {
    font-size: 0.68rem;
    font-weight: 800;
    color: #64dfdf;
    background: rgba(100, 223, 223, 0.12);
    padding: 1px 5px;
    border-radius: 4px;
    white-space: nowrap;
}

.node-status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.65rem;
    margin-top: 2px;
}

.node-role-label {
    color: var(--text-muted);
}

.node-turn-tag {
    font-weight: 800;
    font-size: 0.62rem;
    letter-spacing: 0.3px;
}

.node-turn-tag.current {
    color: var(--gold-bright);
    animation: turnTagPulse 1.2s infinite alternate;
}

@keyframes turnTagPulse {
    from { opacity: 0.8; }
    to { opacity: 1; text-shadow: 0 0 6px var(--gold-bright); }
}

.node-turn-tag.acted {
    color: #52b788;
}

.timeline-arrow-sep {
    color: rgba(255, 255, 255, 0.2);
    font-size: 0.75rem;
    flex-shrink: 0;
}

.combat-unit-card.active-turn-card {
    border-color: var(--gold-bright) !important;
    box-shadow: 0 0 28px rgba(229, 184, 66, 0.7), inset 0 0 16px rgba(229, 184, 66, 0.25) !important;
    animation: activeTurnCardGlow 1.8s infinite alternate !important;
}

@keyframes activeTurnCardGlow {
    from { transform: translateY(-3px) scale(1.01); box-shadow: 0 0 18px rgba(229, 184, 66, 0.5); }
    to { transform: translateY(-5px) scale(1.03); box-shadow: 0 0 30px rgba(229, 184, 66, 0.85); }
}

.combat-unit-card.waiting-turn {
    opacity: 0.85;
}

.combat-unit-card.already-acted-turn {
    opacity: 0.55;
    filter: grayscale(0.35);
}

.team-header-tag {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.targeting-instruction, .actor-instruction {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--gold-bright);
    background: rgba(0, 0, 0, 0.4);
    padding: 2px 10px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.combat-units-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

@media (max-width: 900px) {
    .combat-units-row {
        grid-template-columns: 1fr;
    }
}

/* CARTE D'UNITÉ COMBATTIQUE MODÉLISÉE (ALLIÉ & ENNEMI) */
.combat-unit-card {
    background: linear-gradient(180deg, rgba(22, 28, 44, 0.95) 0%, rgba(12, 16, 26, 0.98) 100%);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
    cursor: pointer;
    user-select: none;
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.25s ease, border-color 0.25s ease;
    overflow: hidden;
}

.combat-unit-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.5);
}

/* Ennemi survolable avec réticule */
.combat-unit-card.enemy-unit:hover {
    border-color: rgba(230, 57, 70, 0.6);
    box-shadow: 0 0 16px rgba(230, 57, 70, 0.35);
}

/* CIBLE ENNEMIE SÉLECTIONNÉE */
.combat-unit-card.selected-target {
    border-color: #ff3344 !important;
    box-shadow: 0 0 24px rgba(255, 51, 68, 0.6), inset 0 0 16px rgba(255, 51, 68, 0.2) !important;
    transform: translateY(-4px) scale(1.02);
}

.combat-unit-card.selected-target::before {
    content: '🎯 CIBLE VERROUILLÉE';
    position: absolute;
    top: 6px;
    right: 8px;
    background: linear-gradient(90deg, #d90429, #ef233c);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
    z-index: 10;
    animation: targetBadgePulse 1.2s infinite alternate;
}

@keyframes targetBadgePulse {
    from { opacity: 0.85; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1.04); }
}

/* CHAMPION ALLIÉ ACTIF (CELUI QUI ATTAQUE) */
.combat-unit-card.selected-actor {
    border-color: var(--gold-bright) !important;
    box-shadow: 0 0 24px rgba(229, 184, 66, 0.65), inset 0 0 16px rgba(229, 184, 66, 0.2) !important;
    transform: translateY(-4px) scale(1.02);
}

.combat-unit-card.selected-actor::before {
    content: '⚔️ ATTAQUANT ACTIF';
    position: absolute;
    top: 6px;
    right: 8px;
    background: linear-gradient(90deg, #b8860b, #e5b842);
    color: #0b0d14;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.5px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
    z-index: 10;
    animation: actorBadgePulse 1.2s infinite alternate;
}

@keyframes actorBadgePulse {
    from { opacity: 0.85; transform: scale(0.98); }
    to { opacity: 1; transform: scale(1.04); }
}

.combat-unit-card.dead {
    opacity: 0.3;
    filter: grayscale(1);
    pointer-events: none;
    transform: none !important;
}

.combat-unit-card.shake {
    animation: unitShake 0.45s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}

@keyframes unitShake {
    10%, 90% { transform: translate3d(-3px, 0, 0); }
    20%, 80% { transform: translate3d(5px, 0, 0); }
    30%, 50%, 70% { transform: translate3d(-6px, 0, 0); }
    40%, 60% { transform: translate3d(6px, 0, 0); }
}

/* En-tête de carte unitaire */
.unit-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.unit-role-pill {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.06);
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.unit-element-pill {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.unit-element-pill.elem-fire { border-color: #ff5400; color: #ff9e00; }
.unit-element-pill.elem-steel { border-color: #a0aab8; color: #e2e8f0; }
.unit-element-pill.elem-shadow { border-color: #7b2cbf; color: #c77dff; }
.unit-element-pill.elem-holy { border-color: #ffd166; color: #ffe49e; }
.unit-element-pill.elem-blood { border-color: #e63946; color: #ff758f; }
.unit-element-pill.elem-poison { border-color: #2ec4b6; color: #57cc99; }

/* Contenu Unité : Portrait + Données */
.unit-card-body {
    display: flex;
    gap: 12px;
    align-items: center;
}

.unit-card-avatar-wrap {
    position: relative;
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 2px solid rgba(255, 255, 255, 0.15);
    background: #000;
    box-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

.unit-card-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.combat-unit-card:hover .unit-card-avatar {
    transform: scale(1.08);
}

.unit-card-meta {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.unit-card-name {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.unit-card-stats-row {
    display: flex;
    gap: 10px;
    font-size: 0.72rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 3px;
}

/* Badges d'état (Poison, Brûlure, Stun, etc.) */
.unit-status-badges {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
    min-height: 18px;
    margin-top: 2px;
}

.status-badge-chip {
    font-size: 0.65rem;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: var(--radius-pill);
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.status-badge-chip.burn { border-color: #ff5400; color: #ff9e00; }
.status-badge-chip.poison { border-color: #2ec4b6; color: #57cc99; }
.status-badge-chip.stun { border-color: #ffd166; color: #ffe49e; }
.status-badge-chip.curse { border-color: #9d4edd; color: #c77dff; }
.status-badge-chip.shield { border-color: #3a86ff; color: #90e0ef; }

/* Barres de PV et Bouclier */
.unit-meter-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: rgba(0, 0, 0, 0.35);
    padding: 6px 8px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.meter-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.72rem;
    font-family: var(--font-mono);
    font-weight: 600;
}

.hp-track {
    width: 100%;
    height: 9px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.hp-fill {
    height: 100%;
    background: linear-gradient(90deg, #2ec4b6, #57cc99);
    transition: width 0.4s ease, background 0.4s ease;
}

.hp-fill.danger {
    background: linear-gradient(90deg, #d90429, #ef233c);
}

.shield-track {
    width: 100%;
    height: 5px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 2px;
}

.shield-fill {
    height: 100%;
    background: linear-gradient(90deg, #3a86ff, #90e0ef);
    transition: width 0.4s ease;
}

/* Jauge d'Énergie en Orbes (3 Cristaux Pokémon-Style) */
.energy-orbs-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
    padding-top: 4px;
    border-top: 1px dashed rgba(255, 255, 255, 0.08);
}

.energy-orbs-label {
    font-size: 0.68rem;
    font-weight: 700;
    color: var(--text-muted);
}

.energy-orbs-list {
    display: flex;
    gap: 6px;
}

.energy-pip {
    width: 13px;
    height: 13px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.energy-pip.filled {
    background: linear-gradient(135deg, #00f0ff, #3a86ff);
    border-color: #00f0ff;
    box-shadow: 0 0 8px #00f0ff;
}

.energy-pip.filled.max {
    background: linear-gradient(135deg, #ffd166, #ff9e00);
    border-color: #ffd166;
    box-shadow: 0 0 10px #ffd166;
    animation: maxPipGlow 1s infinite alternate;
}

@keyframes maxPipGlow {
    from { transform: scale(1); filter: brightness(1); }
    to { transform: scale(1.18); filter: brightness(1.35); }
}

/* SÉPARATEUR DE CHOC ET MATCHUP TACTIQUE */
.battle-clash-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 6px 0;
}

.battle-clash-divider::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(229, 184, 66, 0.3), transparent);
}

.matchup-preview-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(10, 13, 22, 0.9);
    border: 1px solid rgba(229, 184, 66, 0.35);
    padding: 6px 18px;
    border-radius: var(--radius-pill);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
    z-index: 2;
    flex-wrap: wrap;
    justify-content: center;
}

.matchup-actor-badge, .matchup-target-badge {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-primary);
}

.clash-icon {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--gold-bright);
}

.advantage-badge {
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 10px;
    border-radius: var(--radius-pill);
    letter-spacing: 0.5px;
}

.advantage-badge.effective {
    background: rgba(87, 204, 153, 0.2);
    border: 1px solid #57cc99;
    color: #57cc99;
    box-shadow: 0 0 8px rgba(87, 204, 153, 0.3);
}

.advantage-badge.resisted {
    background: rgba(230, 57, 70, 0.2);
    border: 1px solid #e63946;
    color: #ff758f;
}

.advantage-badge.neutral {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-secondary);
}

/* ==================== CONSOLE DE COMBAT STYLE POKÉMON (3v3) ==================== */
.pokemon-battle-console {
    background: linear-gradient(180deg, #131724 0%, #0c0f18 100%);
    border: 2px solid rgba(229, 184, 66, 0.35);
    border-radius: var(--radius-md);
    padding: 16px;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 18px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
    margin-bottom: 16px;
    position: relative;
}

@media (max-width: 960px) {
    .pokemon-battle-console {
        grid-template-columns: 1fr;
    }
}

/* Boîte de Dialogue Pokémon (Gauche) */
.pk-console-dialog {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
}

.pk-dialog-avatar-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pk-dialog-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--gold-primary);
    box-shadow: 0 0 10px rgba(229, 184, 66, 0.4);
}

.pk-dialog-elem-badge {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: var(--radius-pill);
    background: rgba(229, 184, 66, 0.15);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
}

.pk-dialog-content {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.pk-dialog-speaker {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--gold-bright);
}

.pk-dialog-message {
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    border-left: 3px solid var(--gold-primary);
}

.pk-dialog-subtext {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-family: var(--font-mono);
}

/* Grille des 4 Attaques Pokémon (Droite) */
.pk-console-moves {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.pk-moves-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

@media (max-width: 600px) {
    .pk-moves-grid {
        grid-template-columns: 1fr;
    }
}

.pk-move-btn {
    background: rgba(20, 26, 40, 0.9);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.2, 0.8, 0.2, 1);
    position: relative;
    user-select: none;
}

.pk-move-btn:hover:not(:disabled) {
    background: rgba(30, 40, 62, 0.95);
    border-color: rgba(229, 184, 66, 0.5);
    transform: translateY(-2px);
}

.pk-move-btn.active {
    background: linear-gradient(135deg, rgba(35, 45, 70, 0.95) 0%, rgba(20, 28, 45, 0.98) 100%);
    border-color: var(--gold-bright) !important;
    box-shadow: 0 0 16px rgba(229, 184, 66, 0.4), inset 0 0 8px rgba(229, 184, 66, 0.15);
    transform: translateY(-2px);
}

.pk-move-btn.active::after {
    content: '✓';
    position: absolute;
    top: 6px;
    right: 8px;
    font-weight: 900;
    color: var(--gold-bright);
    font-size: 0.8rem;
}

.pk-move-btn:disabled, .pk-move-btn.disabled {
    opacity: 0.4;
    cursor: not-allowed;
    filter: grayscale(0.6);
    transform: none !important;
    box-shadow: none !important;
}

.pk-move-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
}

.pk-move-name {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.pk-move-type {
    font-size: 0.65rem;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: var(--radius-pill);
    text-transform: uppercase;
}

.pk-move-type.type-physique { background: rgba(160, 170, 184, 0.2); color: #e2e8f0; border: 1px solid #a0aab8; }
.pk-move-type.type-element { background: rgba(0, 240, 255, 0.15); color: #00f0ff; border: 1px solid #00f0ff; }
.pk-move-type.type-defense { background: rgba(58, 134, 255, 0.2); color: #90e0ef; border: 1px solid #3a86ff; }
.pk-move-type.type-ultime { background: rgba(229, 184, 66, 0.2); color: var(--gold-bright); border: 1px solid var(--gold-primary); }

.pk-move-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.72rem;
    font-family: var(--font-mono);
}

.pk-move-power {
    font-weight: 700;
    color: var(--text-secondary);
}

.pk-move-cost {
    font-weight: 700;
}

.pk-move-cost.cost-free { color: #57cc99; }
.pk-move-cost.cost-energy { color: #00f0ff; }
.pk-move-cost.cost-ult { color: var(--gold-bright); }

.pk-move-desc {
    font-size: 0.7rem;
    color: var(--text-muted);
    line-height: 1.25;
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Actions de validation d'assaut */
.pk-console-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn-execute-attack {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 20px;
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 15px rgba(229, 184, 66, 0.35);
    animation: executeBtnGlow 2s infinite alternate;
}

@keyframes executeBtnGlow {
    from { box-shadow: 0 4px 15px rgba(229, 184, 66, 0.3); }
    to { box-shadow: 0 4px 22px rgba(229, 184, 66, 0.6); }
}

.btn-instant-finish {
    padding: 14px 16px;
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    white-space: nowrap;
}

/* POPUPS DE DÉGÂTS VOLANTS */
.floating-damage-popup {
    position: absolute;
    top: 30%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 900;
    color: #ff3344;
    text-shadow: 0 0 8px rgba(0,0,0,0.9), 0 0 16px rgba(255, 51, 68, 0.7);
    pointer-events: none;
    z-index: 100;
    animation: floatDamage 1s cubic-bezier(0.18, 0.89, 0.32, 1.28) forwards;
}

.floating-damage-popup.crit {
    font-size: 1.8rem;
    color: #ffb703;
    text-shadow: 0 0 10px rgba(0,0,0,0.9), 0 0 20px rgba(255, 183, 3, 0.9);
}

.floating-damage-popup.effective {
    color: #57cc99;
}

@keyframes floatDamage {
    0% { opacity: 0; transform: translate(-50%, 0) scale(0.5); }
    20% { opacity: 1; transform: translate(-50%, -20px) scale(1.2); }
    70% { opacity: 1; transform: translate(-50%, -35px) scale(1); }
    100% { opacity: 0; transform: translate(-50%, -50px) scale(0.9); }
}

/* Journal des Coups */
.battle-log-card {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
    max-height: 180px;
}

.log-header {
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 14px;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--gold-primary);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.log-hint {
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--text-muted);
}

.battle-log-scroll {
    overflow-y: auto;
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.75rem;
    font-family: var(--font-mono);
}

.log-entry {
    color: var(--text-secondary);
    line-height: 1.35;
}

.log-entry.crit {
    color: #ff9e00;
    font-weight: 700;
}

.log-entry.ultimate {
    color: #00f0ff;
    font-weight: 700;
}

.log-entry.defeat {
    color: #ff4d4d;
}

.log-entry.victory {
    color: #57cc99;
    font-weight: 700;
}

/* ========================================================
   SECTION 4 : TAVERNE ROYALE / BLACKJACK 21
   ======================================================== */

.blackjack-container {
    max-width: 960px;
    margin: 0 auto;
}

.tavern-table-felt {
    background: radial-gradient(ellipse at center, #1b6338 0%, #0d381e 65%, #071f11 100%);
    border: 12px solid #38220f;
    border-radius: 40px;
    box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.8), 0 16px 40px rgba(0, 0, 0, 0.7);
    padding: 32px 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    position: relative;
}

.felt-header {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px dashed rgba(229, 184, 66, 0.3);
    padding-bottom: 12px;
    flex-wrap: wrap;
}

.felt-header-titles {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    gap: 3px;
    flex: 1;
    min-width: 240px;
}

.felt-logo {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--gold-bright);
    letter-spacing: 2px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}

.felt-rules {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.75);
    letter-spacing: 1px;
}

.btn-felt-rules {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.18) 0%, rgba(26, 20, 10, 0.7) 100%);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 700;
    padding: 7px 15px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-felt-rules:hover {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.38) 0%, rgba(212, 175, 55, 0.15) 100%);
    box-shadow: 0 0 14px rgba(212, 175, 55, 0.45);
    transform: translateY(-1px);
    color: #fff;
}

.bj-hand-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.hand-meta {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hand-owner {
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.hand-score-pill {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 0.85rem;
    padding: 2px 10px;
    border-radius: var(--radius-pill);
}

.bj-cards-row {
    display: flex;
    gap: 10px;
    min-height: 120px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

/* Carte de Jeu Réelle */
.bj-card {
    width: 80px;
    height: 116px;
    background: #ffffff;
    color: #111111;
    border-radius: 8px;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 8px;
    font-weight: 800;
    position: relative;
    user-select: none;
    transition: transform 0.25s ease;
}

.bj-card:hover {
    transform: translateY(-6px);
}

.bj-card.red {
    color: #c91818;
}

.bj-card .card-corner {
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1;
    font-size: 0.9rem;
}

.bj-card .card-center-suit {
    align-self: center;
    font-size: 1.8rem;
    opacity: 0.9;
}

.bj-card .card-corner.bottom {
    transform: rotate(180deg);
}

.bj-card.back-card {
    background: #7a1d25;
    background-image: repeating-linear-gradient(45deg, rgba(229, 184, 66, 0.2) 0, rgba(229, 184, 66, 0.2) 10px, transparent 10px, transparent 20px);
    border: 2px solid var(--gold-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--gold-bright);
}

.bj-card.empty-card {
    background: rgba(0, 0, 0, 0.25);
    border: 2px dashed rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.3);
}

.felt-center-strip {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.current-bet-display {
    font-family: var(--font-heading);
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    background: rgba(0, 0, 0, 0.4);
    padding: 6px 18px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(229, 184, 66, 0.3);
}

.current-bet-display strong {
    color: var(--gold-bright);
}

.bj-outcome-banner {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 800;
    padding: 8px 24px;
    border-radius: var(--radius-md);
    animation: popIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-align: center;
}

.bj-outcome-banner.win {
    background: linear-gradient(135deg, #10b981, #059669);
    color: #ffffff;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.5);
}

.bj-outcome-banner.blackjack {
    background: var(--gold-gradient);
    color: #0b0d14;
    box-shadow: 0 0 30px rgba(229, 184, 66, 0.7);
}

.bj-outcome-banner.loss {
    background: linear-gradient(135deg, #ef4444, #b91c1c);
    color: #ffffff;
}

.bj-outcome-banner.push {
    background: #475569;
    color: #ffffff;
}

/* Contrôles & Jetons */
.felt-controls {
    background: rgba(0, 0, 0, 0.5);
    border-radius: var(--radius-md);
    padding: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.betting-console {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.wallet-balance-indicator {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.85);
}

.wallet-balance-indicator strong {
    color: var(--gold-bright);
    font-size: 1.05rem;
}

.chips-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}

.chip-btn {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 4px dashed rgba(255, 255, 255, 0.8);
    font-weight: 800;
    font-size: 0.75rem;
    color: #ffffff;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5);
    transition: transform 0.15s, box-shadow 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #000;
}

.chip-btn:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
}

.chip-btn[data-val="50"] { background: #1e3a8a; border-color: #60a5fa; }
.chip-btn[data-val="100"] { background: #991b1b; border-color: #f87171; }
.chip-btn[data-val="250"] { background: #065f46; border-color: #34d399; }
.chip-btn[data-val="500"] { background: #5b21b6; border-color: #a78bfa; }
.chip-btn[data-val="1000"] { background: #854d0e; border-color: #fde047; }

.custom-bet-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.bj-bet-input {
    width: 140px;
    text-align: center;
    font-family: var(--font-mono);
    font-size: 1.1rem;
    font-weight: 700;
}

.play-console {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* ========================================================
   SECTION 5 : CRYPTE AUX TRÉSORS / BOOSTERS
   ======================================================== */

.packs-container {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.packs-header-banner {
    background: linear-gradient(135deg, rgba(131, 56, 236, 0.15) 0%, rgba(22, 25, 37, 0.9) 100%);
    border: 1px solid rgba(131, 56, 236, 0.3);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.pack-banner-icon {
    font-size: 3rem;
}

.packs-showcase-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

@media (max-width: 860px) {
    .packs-showcase-grid {
        grid-template-columns: 1fr;
    }
}

.pack-showcase-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
    transition: transform 0.3s ease, border-color 0.3s ease;
}

.pack-showcase-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6);
}

.pack-serf:hover { border-color: #647087; }
.pack-garde:hover { border-color: #3a86ff; box-shadow: 0 16px 40px rgba(58, 134, 255, 0.25); }
.pack-trone:hover { border-color: #e5b842; box-shadow: 0 16px 40px rgba(229, 184, 66, 0.35); }

.pack-foil-wrapper {
    perspective: 800px;
    margin-bottom: 20px;
}

.pack-3d-foil {
    width: 170px;
    height: 250px;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 16px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
    background: #111;
    overflow: hidden;
    transition: transform 0.4s ease;
}

.pack-showcase-card:hover .pack-3d-foil {
    transform: rotateY(10deg) scale(1.03);
}

.pack-3d-foil::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    right: -50%;
    bottom: -50%;
    background: linear-gradient(45deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.2) 50%, rgba(255,255,255,0) 100%);
    transform: rotate(25deg);
    animation: foilShimmer 4s infinite linear;
}

@keyframes foilShimmer {
    0% { transform: translateY(-100%) rotate(25deg); }
    100% { transform: translateY(100%) rotate(25deg); }
}

.pack-serf .pack-3d-foil {
    background: linear-gradient(135deg, #2b3040, #141724);
    border: 2px solid #5a647a;
}

.pack-garde .pack-3d-foil {
    background: linear-gradient(135deg, #1e3a8a, #0f172a);
    border: 2px solid #3b82f6;
}

.pack-trone .pack-3d-foil {
    background: linear-gradient(135deg, #78350f, #1c1917);
    border: 2px solid #f59e0b;
}

.pack-foil-badge {
    font-size: 3rem;
    margin-bottom: 8px;
    z-index: 2;
}

.pack-3d-foil h3 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: #ffffff;
    margin-bottom: 8px;
    z-index: 2;
}

.pack-odds {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.4;
    z-index: 2;
}

.pack-card-footer {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

.pack-price-tag {
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--gold-bright);
}

/* Scène d'Ouverture de Pack */
.unboxing-stage {
    background: rgba(14, 16, 26, 0.95);
    border: 2px solid var(--gold-primary);
    border-radius: var(--radius-lg);
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9);
    animation: popIn 0.3s ease-out;
}

.unboxing-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.unboxing-header h3 {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 1.3rem;
}

.unboxing-subtitle {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-top: 4px;
}

.unboxing-actions-bar {
    display: flex;
    gap: 10px;
    align-items: center;
}

.unboxed-cards-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    perspective: 1200px;
}

@media (max-width: 900px) {
    .unboxed-cards-row {
        grid-template-columns: 1fr;
    }
}

.unboxed-card-reveal {
    background: transparent;
    border: none;
    padding: 0;
    width: 280px;
    max-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
    animation: cardReveal3D 0.75s cubic-bezier(0.2, 0.8, 0.35, 1) forwards;
    transition: transform 0.3s ease, filter 0.3s ease;
}

.unboxed-card-reveal .feudal-card-chassis {
    width: 100%;
}

.unboxed-card-reveal:hover {
    transform: translateY(-8px) scale(1.02);
    filter: brightness(1.06);
}

@keyframes cardReveal3D {
    0% {
        opacity: 0;
        transform: translateY(40px) rotateY(90deg) scale(0.7);
    }
    60% {
        opacity: 1;
        transform: translateY(-10px) rotateY(-8deg) scale(1.04);
    }
    100% {
        opacity: 1;
        transform: translateY(0) rotateY(0deg) scale(1);
    }
}

.feudal-card-display {
    position: relative;
    width: 100%;
    max-width: 360px;
    border-radius: 12px;
    overflow: hidden;
    background: #141724;
    transition: all 0.3s ease;
}

.feudal-card-display.rarity-common {
    border: 2px solid #8a909d;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 15px rgba(138, 144, 157, 0.25);
}

.feudal-card-display.rarity-uncommon {
    border: 2px solid #3cb45f;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 20px rgba(60, 180, 95, 0.35);
}

.feudal-card-display.rarity-rare {
    border: 2px solid #288cf0;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 25px rgba(40, 140, 240, 0.45);
}

.feudal-card-display.rarity-epic {
    border: 2px solid #af41eb;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 30px rgba(175, 65, 235, 0.55);
}

.feudal-card-display.rarity-legendary {
    border: 2px solid #e5b842;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.85), 0 0 35px rgba(229, 184, 66, 0.65);
    animation: goldFoilPulse 2.4s infinite alternate ease-in-out;
}

.feudal-card-display.rarity-mythic {
    border: 2px solid #eb2d41;
    box-shadow: 0 10px 35px rgba(0, 0, 0, 0.9), 0 0 45px rgba(235, 45, 65, 0.75);
    animation: crimsonFoilPulse 2s infinite alternate ease-in-out;
}

@keyframes goldFoilPulse {
    from { box-shadow: 0 10px 30px rgba(0, 0, 0, 0.85), 0 0 20px rgba(229, 184, 66, 0.4); }
    to { box-shadow: 0 12px 35px rgba(0, 0, 0, 0.9), 0 0 40px rgba(229, 184, 66, 0.8); }
}

@keyframes crimsonFoilPulse {
    from { box-shadow: 0 10px 35px rgba(0, 0, 0, 0.9), 0 0 25px rgba(235, 45, 65, 0.5); }
    to { box-shadow: 0 14px 45px rgba(0, 0, 0, 0.95), 0 0 55px rgba(235, 45, 65, 0.9); }
}

.feudal-card-render-img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    background: #141724;
}

.card-foil-sheen {
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(115deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.18) 50%, rgba(255,255,255,0) 100%);
    pointer-events: none;
    transition: left 0.6s ease;
}

.feudal-card-display:hover .card-foil-sheen {
    left: 150%;
}

.unboxed-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 360px;
    margin-top: 10px;
    padding: 4px 6px;
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--gold-bright);
}

.card-footer-code {
    background: rgba(0, 0, 0, 0.5);
    padding: 3px 8px;
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    letter-spacing: 0.5px;
}

.card-footer-print {
    color: var(--text-secondary);
    font-size: 0.75rem;
}

/* Plateau Discord de Déballage */
.unboxed-plate-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 15px;
    animation: fadeIn 0.4s ease-out;
}

.plate-frame {
    border: 3px solid var(--gold-primary);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.95);
    background: #0c0d10;
}

.plate-img {
    width: 100%;
    max-width: 900px;
    height: auto;
    display: block;
}

/* Modale Zoom Carte HD & Dossier Royal & Generic Modal Backdrop */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2200;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.modal-dialog {
    background: rgba(14, 16, 26, 0.98);
    border: 2px solid var(--gold-primary);
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.95);
    position: relative;
    max-height: 90vh;
    overflow-y: auto;
    padding: 20px 24px;
}

.card-zoom-dialog {
    max-width: 860px;
    background: rgba(14, 16, 26, 0.98);
    border: 2px solid var(--gold-primary);
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.95);
    text-align: left;
}

.card-zoom-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(229, 184, 66, 0.3);
    padding-bottom: 12px;
    margin-bottom: 14px;
}

.card-zoom-header h3 {
    margin: 0;
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 1.25rem;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.6rem;
    cursor: pointer;
    line-height: 1;
    padding: 2px 8px;
    border-radius: 4px;
    transition: var(--transition-fast);
}

.modal-close:hover {
    color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.1);
}

.card-zoom-layout {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 20px;
    padding: 12px 0;
}

@media (max-width: 768px) {
    .card-zoom-layout {
        grid-template-columns: 1fr;
    }
}

.card-zoom-img-pane {
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.card-zoom-large-img {
    width: 100%;
    max-width: 360px;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.9);
    border: 2px solid var(--gold-primary);
}

.card-zoom-details-pane {
    display: flex;
    flex-direction: column;
    gap: 12px;
    color: var(--text-primary);
    max-height: 520px;
    overflow-y: auto;
    padding-right: 8px;
}

.zoom-section-card {
    background: rgba(24, 28, 44, 0.7);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: 8px;
    padding: 12px 14px;
}

.zoom-section-title {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    color: var(--gold-bright);
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.zoom-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    text-align: center;
}

.zoom-stat-item {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 6px;
    padding: 6px;
}

.zoom-stat-lbl {
    font-size: 0.65rem;
    color: var(--text-secondary);
    display: block;
}

.zoom-stat-val {
    font-family: var(--font-mono);
    font-size: 1.05rem;
    font-weight: 800;
}

.zoom-lore-text {
    font-style: italic;
    color: #e0d0b8;
    font-size: 0.85rem;
    line-height: 1.4;
    margin: 0;
}

.card-zoom-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 14px;
    flex-wrap: wrap;
}

.equipment-loot-alert {
    background: rgba(229, 184, 66, 0.15);
    border: 1px solid var(--gold-primary);
    border-radius: var(--radius-sm);
    padding: 12px;
    font-size: 0.9rem;
    color: var(--gold-bright);
    text-align: center;
    animation: pulseGlow 1.5s infinite alternate;
}

@keyframes pulseGlow {
    from { box-shadow: 0 0 5px rgba(229, 184, 66, 0.2); }
    to { box-shadow: 0 0 16px rgba(229, 184, 66, 0.5); }
}

/* ========================================================
   SECTION 5.5 : ATELIER DU TRIO DE GUERRE & CARTES FÉODALES
   ======================================================== */

.deck-builder-card {
    background: linear-gradient(180deg, rgba(22, 25, 40, 0.85) 0%, rgba(13, 15, 25, 0.95) 100%);
    border: 1px solid rgba(229, 184, 66, 0.35);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    position: relative;
    overflow: hidden;
}

.deck-builder-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
}

.deck-builder-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 16px;
}

.deck-builder-header h2 {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    margin: 0 0 6px 0;
    font-size: 1.4rem;
}

.deck-builder-header p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0;
}

/* Panneau des Synergies & Talents Actifs */
.trio-synergies-panel {
    background: rgba(10, 12, 20, 0.75);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin-bottom: 22px;
    backdrop-filter: blur(10px);
}

.trio-synergies-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.trio-synergies-header h3 {
    font-family: var(--font-heading);
    color: #f7e7b4;
    font-size: 1rem;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.trio-synergies-header .badge {
    font-size: 0.75rem;
    padding: 3px 10px;
    border-radius: 20px;
    background: rgba(229, 184, 66, 0.15);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
}

.trio-synergies-list {
    width: 100%;
}

.trio-synergies-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
}

.synergies-sub-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.synergies-section-title {
    font-family: var(--font-heading);
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--gold-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

.synergies-order-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 12px;
}

.synergy-order-card {
    background: rgba(18, 22, 34, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    position: relative;
    transition: all 0.25s ease;
}

.synergy-order-card.active {
    background: linear-gradient(135deg, rgba(229, 184, 66, 0.16) 0%, rgba(18, 22, 34, 0.96) 100%);
    border: 1px solid var(--gold-bright);
    box-shadow: 0 0 16px rgba(229, 184, 66, 0.28);
}

.synergy-order-card.active.tier-3 {
    background: linear-gradient(135deg, rgba(235, 45, 65, 0.2) 0%, rgba(229, 184, 66, 0.22) 100%);
    border: 1px solid #ff7b72;
    box-shadow: 0 0 20px rgba(255, 123, 114, 0.38);
}

.synergy-order-card.inactive-hint {
    background: rgba(12, 14, 22, 0.65);
    border: 1px dashed rgba(255, 255, 255, 0.14);
    opacity: 0.8;
}

.synergy-order-icon {
    font-size: 1.8rem;
    line-height: 1;
    min-width: 36px;
    text-align: center;
    padding-top: 2px;
}

.synergy-order-content {
    flex: 1;
}

.synergy-order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
    flex-wrap: wrap;
    gap: 4px;
}

.synergy-order-name {
    font-weight: 700;
    font-size: 0.92rem;
    color: #fff;
}

.synergy-order-badge {
    font-size: 0.7rem;
    padding: 2px 8px;
    border-radius: 12px;
    background: rgba(229, 184, 66, 0.2);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
    font-weight: 700;
}

.synergy-order-badge.tier-3 {
    background: rgba(235, 45, 65, 0.25);
    border-color: #ff7b72;
    color: #ffa198;
}

.synergy-order-badge.hint {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.18);
    color: var(--text-muted);
}

.synergy-order-desc {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.35;
}

.synergies-traits-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 900px) {
    .synergies-traits-grid {
        grid-template-columns: 1fr;
    }
}

.synergy-trait-card {
    background: rgba(14, 18, 28, 0.88);
    border: 1px solid rgba(229, 184, 66, 0.24);
    border-radius: 8px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.synergy-trait-card.empty {
    border-style: dashed;
    border-color: rgba(255, 255, 255, 0.12);
    background: rgba(10, 12, 18, 0.5);
}

.synergy-trait-slot-tag {
    font-size: 0.68rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.synergy-trait-title-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.synergy-trait-name {
    font-size: 0.88rem;
    font-weight: 700;
    color: #fff;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.trait-cat-badge {
    font-size: 0.65rem;
    padding: 1px 6px;
    border-radius: 8px;
    background: rgba(229, 184, 66, 0.15);
    color: var(--gold-bright);
    border: 1px solid rgba(229, 184, 66, 0.3);
}

.synergy-trait-badge-name {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gold-bright);
}

.synergy-trait-desc {
    font-size: 0.77rem;
    color: var(--text-secondary);
    line-height: 1.3;
}

.synergies-empty-banner, .synergies-hetero-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(16, 20, 32, 0.7);
    border: 1px dashed rgba(229, 184, 66, 0.25);
    border-radius: 8px;
    padding: 12px 16px;
}

/* Grille des 3 emplacements de combat */
.deck-slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

@media (max-width: 900px) {
    .deck-slots-grid {
        grid-template-columns: 1fr;
    }
}

.deck-slot-card {
    background: rgba(15, 18, 30, 0.7);
    border: 2px dashed rgba(229, 184, 66, 0.3);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    transition: all 0.25s ease;
    min-height: 480px;
    cursor: pointer;
}

.deck-slot-card:hover {
    border-color: rgba(229, 184, 66, 0.6);
    background: rgba(20, 24, 40, 0.8);
}

.deck-slot-card.active-target {
    border-style: solid;
    border-color: var(--gold-bright);
    box-shadow: 0 0 25px rgba(229, 184, 66, 0.4), inset 0 0 20px rgba(229, 184, 66, 0.1);
}

.deck-slot-card.drag-over {
    border-color: #38ef7d;
    background: rgba(56, 239, 125, 0.15);
    box-shadow: 0 0 30px rgba(56, 239, 125, 0.5);
    transform: scale(1.02);
}

.slot-role-badge {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--gold-bright);
    background: rgba(10, 12, 20, 0.85);
    border: 1px solid rgba(229, 184, 66, 0.4);
    padding: 4px 14px;
    border-radius: 20px;
    margin-bottom: 14px;
    letter-spacing: 0.5px;
}

.slot-card-preview {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-grow: 1;
}

.empty-slot-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
    font-size: 0.9rem;
    gap: 12px;
}

.empty-slot-placeholder::before {
    content: '🛡️';
    font-size: 2.8rem;
    opacity: 0.4;
    filter: drop-shadow(0 0 10px rgba(229, 184, 66, 0.2));
}

/* ========================================================
   CARTE FÉODALE (COMPOSANT UNIFIÉ .feudal-card)
   ======================================================== */

.feudal-card:not(.feudal-card-chassis) {
    position: relative;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
    background: transparent;
    border: none;
    box-shadow: none;
    overflow: visible;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.35, 1);
    user-select: none;
    cursor: grab;
}

.feudal-card:hover {
    transform: translateY(-6px);
}

.feudal-card.dragging {
    opacity: 0.45;
    transform: scale(0.95) rotate(2deg);
    cursor: grabbing;
}

.feudal-card.assigned-to-slot .feudal-card-display {
    border-color: #10b981 !important;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.6) !important;
}

.card-equipped-slot-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(16, 185, 129, 0.95);
    color: #ffffff;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 6px;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
    z-index: 4;
}

.feudal-card-display .feudal-card-zoom-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    background: rgba(10, 12, 20, 0.85);
    border: 1px solid var(--gold-primary);
    border-radius: 50%;
    color: var(--gold-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease, background 0.2s ease;
}

.feudal-card:hover .feudal-card-zoom-btn,
.arena-deployed-unit-card:hover .feudal-card-zoom-btn,
.feudal-card-display:hover .feudal-card-zoom-btn {
    opacity: 1;
}

.feudal-card-display .feudal-card-zoom-btn:hover {
    transform: scale(1.15);
    background: var(--gold-primary);
    color: #000;
}

/* Raretés féodales */
.feudal-card.rarity-common {
    border-color: #8a909d;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 12px rgba(138, 144, 157, 0.2);
}

.feudal-card.rarity-uncommon {
    border-color: #2ecc71;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 18px rgba(46, 204, 113, 0.35);
}

.feudal-card.rarity-rare {
    border-color: #3498db;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.8), 0 0 22px rgba(52, 152, 219, 0.45);
}

.feudal-card.rarity-epic {
    border-color: #9b59b6;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.85), 0 0 28px rgba(155, 89, 182, 0.55);
}

.feudal-card.rarity-legendary {
    border-color: #f1c40f;
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.9), 0 0 35px rgba(241, 196, 15, 0.65);
    animation: goldPulse 2.8s infinite alternate ease-in-out;
}

.feudal-card.rarity-mythic {
    border-color: #e74c3c;
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.95), 0 0 45px rgba(231, 76, 60, 0.75);
    animation: crimsonPulse 2.2s infinite alternate ease-in-out;
}

/* En-tête de carte féodale */
.feudal-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.55);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.feudal-card-name {
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    color: #f7e7b4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 170px;
}

.feudal-card-stars {
    color: #f1c40f;
    font-size: 0.85rem;
    letter-spacing: 1px;
    filter: drop-shadow(0 0 4px rgba(241, 196, 15, 0.5));
}

/* Portrait & Illustration */
.feudal-card-portrait-wrap {
    position: relative;
    width: 100%;
    height: 190px;
    background: #090a0f;
    overflow: hidden;
}

.feudal-card-portrait-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
    transition: transform 0.4s ease;
}

.feudal-card:hover .feudal-card-portrait-img {
    transform: scale(1.05);
}

.feudal-card-faction-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: rgba(10, 12, 20, 0.85);
    border: 1px solid rgba(229, 184, 66, 0.5);
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 700;
    color: #f7e7b4;
    display: flex;
    align-items: center;
    gap: 4px;
    backdrop-filter: blur(4px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
}

.feudal-card-zoom-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(10, 12, 20, 0.85);
    border: 1px solid rgba(229, 184, 66, 0.5);
    color: #f7e7b4;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.feudal-card-zoom-btn:hover {
    background: var(--gold-primary);
    color: #000;
    transform: scale(1.1);
}

/* Ruban de tempérament / talent */
.feudal-card-trait-bar {
    background: rgba(22, 25, 38, 0.95);
    padding: 4px 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.75rem;
    color: #d1d5db;
}

.feudal-card-trait-title {
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 600;
}

.feudal-card-trait-effect {
    font-size: 0.7rem;
    color: #f7e7b4;
}

/* Grille des caractéristiques */
.feudal-card-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 4px;
    padding: 8px 10px;
    background: rgba(14, 16, 24, 0.9);
}

.feudal-stat-cell {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    padding: 3px 2px;
    text-align: center;
}

.feudal-stat-label {
    display: block;
    font-size: 0.62rem;
    color: var(--text-muted);
    line-height: 1;
    margin-bottom: 2px;
}

.feudal-stat-val {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 800;
    color: #fff;
    line-height: 1;
}

/* Barrette d'équipements attachés */
.feudal-card-gear-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 10px;
    background: rgba(10, 12, 18, 0.85);
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.72rem;
}

.feudal-gear-slot {
    display: flex;
    align-items: center;
    gap: 4px;
    color: var(--text-secondary);
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.feudal-gear-slot.equipped {
    color: #f7e7b4;
    font-weight: 600;
}

/* Actions au pied de la carte */
.feudal-card-actions {
    display: flex;
    gap: 6px;
    width: 100%;
    margin-top: 8px;
    background: transparent;
    border: none;
    padding: 0;
}

.feudal-card-actions .btn {
    flex: 1;
    padding: 6px 4px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 6px;
    white-space: nowrap;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
    transition: all 0.2s ease;
}

.feudal-card-actions .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.6);
}

.feudal-card-actions .btn-remove {
    background: rgba(239, 68, 68, 0.25);
    border: 1px solid #ef4444;
    color: #fca5a5;
    width: 100%;
}

.feudal-card-actions .btn-remove:hover {
    background: rgba(239, 68, 68, 0.55);
    color: #fff;
}

/* ========================================================
   SECTION 6 : CLASSEMENTS PUBLICS (LEADERBOARD)
   ======================================================== */

.leaderboard-container {
    max-width: 1050px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.lb-tabs-bar {
    display: flex;
    gap: 12px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 12px;
}

.lb-subtab {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-secondary);
    padding: 8px 18px;
    border-radius: var(--radius-pill);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
}

.lb-subtab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.lb-subtab.active {
    background: var(--gold-primary);
    color: #0b0d14;
    font-weight: 700;
}

/* Podium Féodal */
.podium-row {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    gap: 16px;
    margin: 20px 0 32px 0;
}

.podium-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 170px;
}

.podium-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 8px;
    border: 3px solid #ccc;
    background: #141724;
}

.podium-name {
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.podium-val {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--gold-bright);
    margin-bottom: 8px;
}

.podium-pedestal {
    width: 100%;
    border-radius: 8px 8px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.5rem;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

.podium-rank-1 .podium-pedestal {
    height: 120px;
    background: linear-gradient(180deg, #d4af37, #854d0e);
    color: #ffffff;
}
.podium-rank-1 .podium-avatar {
    border-color: #ffd700;
    box-shadow: 0 0 16px rgba(255, 215, 0, 0.5);
    width: 76px;
    height: 76px;
}

.podium-rank-2 .podium-pedestal {
    height: 90px;
    background: linear-gradient(180deg, #94a3b8, #475569);
    color: #ffffff;
}
.podium-rank-2 .podium-avatar { border-color: #cbd5e1; }

.podium-rank-3 .podium-pedestal {
    height: 70px;
    background: linear-gradient(180deg, #b45309, #78350f);
    color: #ffffff;
}
.podium-rank-3 .podium-avatar { border-color: #d97706; }

/* Tableaux */
.lb-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.lb-table th {
    background: rgba(0, 0, 0, 0.4);
    padding: 12px 16px;
    text-align: left;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.lb-table td {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    font-size: 0.85rem;
}

.lb-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.rank-pill {
    font-family: var(--font-mono);
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.06);
}

.rank-pill.gold { background: #d4af37; color: #0b0d14; }
.rank-pill.silver { background: #94a3b8; color: #0b0d14; }
.rank-pill.bronze { background: #b45309; color: #ffffff; }

/* Guerre des Ordres */
.factions-war-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.faction-war-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faction-war-card h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    color: var(--text-primary);
}

/* Modale de Résultat de Combat */
.battle-result-card {
    max-width: 480px;
    text-align: center;
}

.result-header {
    padding: 24px 20px 10px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.result-emoji {
    font-size: 3.5rem;
    animation: popIn 0.4s ease-out;
}

.result-header h2 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    color: var(--gold-bright);
}

.result-body {
    padding: 16px 24px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.result-footer {
    padding: 16px 24px 24px 24px;
}

/* Toast de Diffusion Discord d'Exploit */
.toast.exploit-toast {
    background: linear-gradient(135deg, #1e1b4b, #0f172a);
    border: 1px solid var(--gold-primary);
    box-shadow: 0 8px 30px rgba(229, 184, 66, 0.4);
    color: #ffffff;
}

/* ==================== STYLES DU DASHBOARD PROFESSIONNEL ==================== */

/* --- TRIBUNAL & ANNUAIRE DES MEMBRES --- */
.stats-overview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow-soft);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    border-color: var(--gold-primary);
}

.stat-icon {
    font-size: 2rem;
    background: rgba(255, 255, 255, 0.05);
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
}

.stat-info .stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 2px;
}

.stat-info .stat-val {
    font-size: 1.6rem;
    font-weight: 800;
    font-family: var(--font-heading);
    margin: 0;
}

.text-crimson { color: #f87171 !important; }
.text-gold { color: var(--gold-bright) !important; }
.text-green { color: #34d399 !important; }

.members-toolbar-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.toolbar-search-box {
    position: relative;
    width: 100%;
}

.toolbar-search-box .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    opacity: 0.6;
}

.toolbar-search-box .form-input {
    padding-left: 42px;
    width: 100%;
}

.toolbar-filters-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.filter-group .form-select {
    padding: 6px 12px;
    font-size: 0.85rem;
    min-width: 150px;
    height: 38px;
    box-sizing: border-box;
}

.filter-group.filter-btn-group label.filter-btn-label {
    display: none;
}

.filter-group.filter-btn-group #btnRefreshMembers {
    height: 38px;
    padding: 0 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    box-sizing: border-box;
    white-space: nowrap;
}

/* ==================== TRIBUNAL & MEMBRES (STRICTEMENT UNIFORMES) ==================== */
.members-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
    gap: 16px;
    grid-auto-rows: 1fr;
}

.member-card {
    background: rgba(18, 20, 28, 0.92);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    position: relative;
    transition: all 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

.member-card:hover {
    border-color: var(--gold-primary);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(201, 168, 78, 0.2);
}

.member-card.is-jailed {
    border-color: rgba(239, 68, 68, 0.6);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.12), rgba(18, 20, 28, 0.95));
}

.member-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    max-height: 52px;
}

.member-avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--gold-primary);
    flex-shrink: 0;
}

.member-avatar-fallback {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(201, 168, 78, 0.2);
    border: 2px solid var(--gold-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--gold-bright);
    flex-shrink: 0;
}

.member-meta {
    flex: 1;
    min-width: 0;
}

.member-display-name {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    gap: 6px;
}

.member-username {
    font-size: 0.75rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.member-username code {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    opacity: 0.8;
}

.member-status-badges {
    min-height: 22px;
    max-height: 22px;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 4px;
    overflow: hidden;
}

.status-badge {
    font-size: 0.68rem;
    padding: 1px 6px;
    border-radius: 4px;
    font-weight: 600;
    white-space: nowrap;
}

.status-badge.jailed {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.status-badge.timeout {
    background: rgba(249, 115, 22, 0.2);
    color: #fb923c;
    border: 1px solid rgba(249, 115, 22, 0.4);
}

.status-badge.warned {
    background: rgba(234, 179, 8, 0.2);
    color: #fde047;
    border: 1px solid rgba(234, 179, 8, 0.4);
}

.trust-score-wrapper {
    min-height: 38px;
    margin: 8px 0;
}

.trust-score-header {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-secondary);
    margin-bottom: 4px;
}

.trust-score-bar-bg {
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    overflow: hidden;
}

.trust-score-bar-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.3s ease;
}

.member-roles-row {
    height: 28px;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    margin-bottom: 6px;
}

.member-role-pill {
    font-size: 0.7rem;
    padding: 2px 7px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 140px;
}

.member-finances-snippet {
    font-size: 0.82rem;
    color: var(--text-secondary);
    min-height: 22px;
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.member-finances-snippet strong {
    color: var(--gold-bright);
    margin-left: 4px;
}

.member-card-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    margin-top: auto;
}

.member-card-actions .btn {
    padding: 6px 2px;
    font-size: 0.72rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    height: 32px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    box-shadow: none;
    transition: all 0.15s ease;
}

.member-card-actions .btn:hover {
    transform: translateY(-1px);
}

/* ==================== MOTEUR DE GIFS (NON ROGNÉS & ALIGNÉS) ==================== */
.gifs-search-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.gif-search-bar {
    display: flex;
    gap: 10px;
    position: relative;
}

.gif-search-bar .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    opacity: 0.6;
}

.gif-search-bar .form-input {
    padding-left: 42px;
    flex: 1;
}

.gif-categories-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.82rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pill:hover {
    background: rgba(201, 168, 78, 0.15);
    color: var(--gold-bright);
    border-color: var(--gold-primary);
}

.pill.active {
    background: var(--gold-primary);
    color: #0b0c10;
    font-weight: 700;
    border-color: var(--gold-bright);
}

.pill-special.pill-welcome {
    border-color: rgba(34, 197, 94, 0.4);
    color: #4ade80;
}
.pill-special.pill-welcome.active {
    background: linear-gradient(135deg, #15803d, #22c55e);
    color: #fff;
    border-color: #86efac;
    box-shadow: 0 0 15px rgba(34, 197, 94, 0.35);
}

.pill-special.pill-levelup {
    border-color: rgba(168, 85, 247, 0.4);
    color: #c084fc;
}
.pill-special.pill-levelup.active {
    background: linear-gradient(135deg, #7e22ce, #a855f7);
    color: #fff;
    border-color: #e9d5ff;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.35);
}

.gifs-rotation-info {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 18px;
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, rgba(30, 27, 75, 0.7), rgba(15, 23, 42, 0.85));
    border: 1px solid rgba(168, 85, 247, 0.3);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: fadeIn 0.3s ease;
}

.rotation-info-badge {
    padding: 4px 10px;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    border-radius: 6px;
    background: rgba(168, 85, 247, 0.2);
    border: 1px solid rgba(168, 85, 247, 0.5);
    color: #e9d5ff;
    white-space: nowrap;
}

.rotation-info-content h4 {
    margin: 0 0 3px 0;
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 0.95rem;
}

.rotation-info-content p {
    margin: 0;
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.custom-gif-importer {
    background: rgba(0, 0, 0, 0.25);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 10px 14px;
}

.importer-details summary {
    cursor: pointer;
    color: var(--gold-bright);
    font-size: 0.85rem;
    font-weight: 600;
}

.importer-body {
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.importer-row {
    display: flex;
    gap: 10px;
}

.importer-preview-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    background: rgba(0, 0, 0, 0.4);
    padding: 12px;
    border-radius: 8px;
}

.direct-gif-preview-img {
    max-height: 220px;
    border-radius: 8px;
    border: 1px solid var(--gold-primary);
}

.importer-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.gifs-masonry-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 18px;
}

.gif-card {
    background: #11131a;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.25s ease;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.gif-card:hover {
    border-color: var(--gold-primary);
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(201, 168, 78, 0.22);
}

.gif-media-wrapper {
    position: relative;
    width: 100%;
    height: 190px;
    background: #08090d;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-bottom: 1px solid rgba(201, 168, 78, 0.15);
}

.gif-media-img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    transition: transform 0.2s ease;
}

.gif-card:hover .gif-media-img {
    transform: scale(1.03);
}

.gif-overlay-actions {
    position: absolute;
    inset: 0;
    background: rgba(10, 11, 16, 0.88);
    backdrop-filter: blur(4px);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
    padding: 14px;
    align-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.gif-card:hover .gif-overlay-actions {
    opacity: 1;
    pointer-events: auto;
}

.gif-action-btn {
    background: rgba(25, 28, 38, 0.95);
    border: 1px solid var(--gold-primary);
    color: var(--text-primary);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 8px 6px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    transition: all 0.15s ease;
}

.gif-action-btn:hover {
    background: var(--gold-primary);
    color: #0c0d12;
    transform: translateY(-1px);
}

.gif-meta-footer {
    padding: 10px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #141722;
}

.gif-title {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 170px;
}

.gif-tag-badge {
    font-size: 0.7rem;
    color: var(--gold-bright);
    background: rgba(201, 168, 78, 0.12);
    padding: 2px 8px;
    border-radius: 12px;
    border: 1px solid rgba(201, 168, 78, 0.25);
    text-transform: capitalize;
}

.gif-action-btn-danger {
    background: rgba(220, 38, 38, 0.25);
    border: 1px solid rgba(239, 68, 68, 0.5);
    color: #fca5a5;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-xs);
    cursor: pointer;
    transition: all 0.2s ease;
}

.gif-action-btn-danger:hover {
    background: rgba(220, 38, 38, 0.85);
    border-color: #ef4444;
    color: #fff;
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

.btn-delete-gif-footer {
    padding: 3px 8px;
    font-size: 0.72rem;
    color: #f87171;
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.35);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-delete-gif-footer:hover {
    background: #dc2626;
    color: #fff;
    border-color: #ef4444;
}

body.is-admin #btnAuthToggle,
body.is-admin .btn-auth-toggle {
    display: none !important;
}

.gif-category-tag {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-transform: capitalize;
}

/* --- VISUAL EMBED STUDIO --- */
.embed-presets-card {
    background: linear-gradient(135deg, rgba(20, 24, 38, 0.95) 0%, rgba(13, 16, 26, 0.95) 100%);
    border: 1px solid rgba(229, 184, 66, 0.35);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    margin-bottom: 20px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.presets-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.presets-icon {
    font-size: 1.6rem;
    line-height: 1;
}

.presets-header strong {
    color: var(--gold-bright);
    font-size: 1rem;
    font-family: var(--font-heading);
}

.presets-header p {
    margin: 2px 0 0 0;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.presets-buttons-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.btn-embed-preset {
    transition: all 0.2s ease;
    border-color: rgba(229, 184, 66, 0.25);
    color: #e2e8f0;
}

.btn-embed-preset:hover {
    border-color: var(--gold-primary);
    background: rgba(229, 184, 66, 0.15);
    color: #fff;
    transform: translateY(-1px);
}

.embed-studio-layout {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 24px;
    align-items: start;
}

@media (max-width: 1100px) {
    .embed-studio-layout {
        grid-template-columns: 1fr;
    }
}

.embed-builder-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.md-helpers-row {
    display: flex;
    align-items: center;
    gap: 4px;
}

.btn-md-helper {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 4px;
    color: #cbd5e1;
    font-size: 0.78rem;
    padding: 2px 7px;
    cursor: pointer;
    line-height: 1.2;
    transition: all 0.15s ease;
}

.btn-md-helper:hover {
    background: var(--gold-primary);
    color: #000;
    border-color: var(--gold-primary);
}

.btn-xs {
    padding: 3px 8px;
    font-size: 0.72rem;
    border-radius: 4px;
}

.color-palette-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.color-swatch {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.2);
    cursor: pointer;
    transition: transform 0.15s ease, border-color 0.15s ease;
}

.color-swatch:hover {
    transform: scale(1.15);
}

.color-swatch.active {
    border-color: #ffffff;
    box-shadow: 0 0 10px var(--gold-bright);
    transform: scale(1.15);
}

.color-picker-input {
    width: 34px;
    height: 34px;
    padding: 0;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    cursor: pointer;
    background: transparent;
}

.embed-fields-section {
    background: rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 14px;
}

.fields-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.embed-field-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 8px;
}

.embed-field-row .form-input {
    font-size: 0.85rem;
    padding: 6px 10px;
}

.field-inline-label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.78rem;
    color: var(--text-muted);
    cursor: pointer;
    white-space: nowrap;
}

.btn-remove-field,
.btn-del-field {
    background: rgba(239, 68, 68, 0.2) !important;
    color: #f87171 !important;
    border: 1px solid rgba(239, 68, 68, 0.4) !important;
    border-radius: 4px;
    padding: 5px 9px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-remove-field:hover,
.btn-del-field:hover {
    background: #ef4444 !important;
    color: #fff !important;
}

.builder-actions-row {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 6px;
}

.builder-secondary-actions {
    display: flex;
    gap: 8px;
}

.builder-secondary-actions .btn {
    flex: 1;
    font-size: 0.8rem;
}

/* --- REPRODUCTION FIDÈLE DISCORD DARK MODE --- */
.embed-preview-wrapper {
    position: sticky;
    top: 20px;
    background: #1e1f22;
    border: 1px solid #35363c;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.6);
}

.preview-header {
    background: #111214;
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #2b2d31;
    font-size: 0.8rem;
    color: #949ba4;
}

.channel-indicator {
    font-family: var(--font-mono);
    color: var(--gold-bright);
}

.discord-message-mock {
    background: #313338;
    padding: 16px;
    display: flex;
    gap: 14px;
}

.discord-avatar-img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.discord-content {
    flex: 1;
    min-width: 0;
}

.discord-header-line {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
}

.discord-bot-name {
    font-weight: 600;
    color: #f2f3f5;
    font-size: 0.95rem;
}

.discord-bot-badge {
    background: #5865f2;
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 1px 4px;
    border-radius: 3px;
    letter-spacing: 0.5px;
}

.discord-timestamp {
    color: #949ba4;
    font-size: 0.72rem;
}

.discord-message-text {
    color: #dbdee1;
    font-size: 0.92rem;
    margin-bottom: 8px;
    word-break: break-word;
}

.discord-embed-card {
    background: #2b2d31;
    border-left: 4px solid #d4af37;
    border-radius: 4px;
    padding: 12px 16px;
    max-width: 520px;
    display: flex;
    gap: 16px;
}

.embed-main-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.embed-author-line {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #ffffff;
}

.embed-author-icon {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
}

.embed-title {
    font-size: 1rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
}

.embed-desc {
    font-size: 0.88rem;
    color: #dbdee1;
    line-height: 1.45;
    word-break: break-word;
}

.discord-quote {
    border-left: 4px solid #4e5058;
    padding-left: 8px;
    margin: 4px 0;
    color: #b5bac1;
}

.discord-inline-code {
    background: #1e1f22;
    padding: 1px 5px;
    border-radius: 3px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: #e0e1e5;
}

.discord-code-block {
    background: #1e1f22;
    padding: 8px 10px;
    border-radius: 4px;
    margin: 6px 0;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    color: #e0e1e5;
    overflow-x: auto;
}

.discord-link {
    color: #00a8fc;
    text-decoration: none;
}
.discord-link:hover {
    text-decoration: underline;
}

.embed-fields-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin-top: 6px;
}

.discord-field-item,
.preview-field {
    min-width: 0;
    overflow-wrap: break-word;
    font-size: 0.85rem;
}

.discord-field-item.full-width,
.preview-field.block {
    grid-column: 1 / -1;
}

.discord-field-name,
.preview-field .field-title {
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 2px;
    font-size: 0.84rem;
}

.discord-field-val,
.preview-field .field-value {
    color: #dbdee1;
    font-size: 0.84rem;
    line-height: 1.35;
    word-break: break-word;
}

.embed-image-box {
    margin-top: 8px;
    border-radius: 4px;
    overflow: hidden;
    max-width: 100%;
}

.embed-main-image {
    max-width: 100%;
    max-height: 280px;
    border-radius: 4px;
    display: block;
}

.embed-thumb-box {
    flex-shrink: 0;
}

.embed-thumb-img {
    width: 80px;
    height: 80px;
    border-radius: 4px;
    object-fit: cover;
}

.embed-footer-line {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-top: 6px;
    font-size: 0.72rem;
    color: #949ba4;
}

.embed-footer-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    object-fit: cover;
}

/* --- BANQUE ROYALE & TRÉSORERIE --- */
.treasury-kpi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
    margin-bottom: 24px;
}

.kpi-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    box-shadow: var(--shadow-soft);
}

.kpi-card.gold-glow {
    border-color: rgba(229, 184, 66, 0.4);
    box-shadow: 0 0 25px rgba(229, 184, 66, 0.15);
}

.kpi-icon {
    font-size: 1.8rem;
    margin-bottom: 4px;
}

.kpi-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.kpi-val {
    font-size: 1.8rem;
    font-weight: 800;
    font-family: var(--font-heading);
    color: var(--text-primary);
    margin: 2px 0;
}

.kpi-sub {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.treasury-dual-layout {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 24px;
}

@media (max-width: 992px) {
    .treasury-dual-layout {
        grid-template-columns: 1fr;
    }
}

.treasury-adjust-card, .treasury-richest-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
}

.royal-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 12px;
}

.royal-table th {
    background: rgba(0, 0, 0, 0.4);
    color: var(--gold-bright);
    font-size: 0.8rem;
    text-transform: uppercase;
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.royal-table td {
    padding: 10px 12px;
    font-size: 0.88rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.royal-table tr:hover td {
    background: rgba(255, 255, 255, 0.03);
}

/* --- CONFIGURATION DU ROYAUME --- */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 20px;
}

.settings-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.settings-save-card {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, rgba(229, 184, 66, 0.1), rgba(0, 0, 0, 0.5));
    border-color: var(--gold-primary);
}

/* --- HUB D'OUTILS & LIENS EXTERNES --- */
.tools-hub-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.tool-hub-card {
    background: var(--bg-card);
    backdrop-filter: blur(14px);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    gap: 18px;
    text-decoration: none;
    color: inherit;
    transition: all 0.25s ease;
}

.tool-hub-card:hover {
    transform: translateY(-4px);
    border-color: var(--gold-primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 20px rgba(229, 184, 66, 0.2);
}

.tool-card-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.tool-card-body {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tool-card-badge {
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 12px;
    display: inline-block;
    width: fit-content;
}

.tool-card-badge.official { background: rgba(88, 101, 242, 0.2); color: #818cf8; }
.tool-card-badge.oci { background: rgba(234, 88, 12, 0.2); color: #fb923c; }
.tool-card-badge.status { background: rgba(34, 197, 94, 0.2); color: #4ade80; }
.tool-card-badge.media { background: rgba(236, 72, 153, 0.2); color: #f472b6; }
.tool-card-badge.secure { background: rgba(229, 184, 66, 0.2); color: var(--gold-bright); }

.tool-card-body h3 {
    font-size: 1.1rem;
    font-family: var(--font-heading);
    margin: 2px 0;
    color: var(--text-primary);
}

.tool-card-body p {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.tool-card-link {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--gold-bright);
    margin-top: 4px;
}

/* Modales d'administration */
.member-detail-card {
    max-width: 650px;
}

.sanction-card {
    max-width: 480px;
}

.sanction-target-desc {
    background: rgba(0, 0, 0, 0.3);
    padding: 10px 14px;
    border-radius: 6px;
    border-left: 3px solid var(--gold-primary);
    font-size: 0.88rem;
    margin-bottom: 14px;
}

.toolbar-filters-row {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.toolbar-filters-row .filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.toolbar-filters-row .filter-group label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 600;
}

/* ==================== NOTIFICATIONS TOAST ROYALES ==================== */
.royal-toast {
    position: fixed;
    bottom: 24px;
    right: 24px;
    background: #151824;
    border: 1px solid var(--gold-primary);
    color: #fff;
    padding: 12px 22px;
    border-radius: 10px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7), 0 0 15px rgba(212, 175, 55, 0.3);
    font-size: 0.92rem;
    font-weight: 600;
    font-family: var(--font-body);
    z-index: 10000;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    pointer-events: none;
}

.royal-toast.show {
    opacity: 1;
    transform: translateY(0);
}

.royal-toast.success {
    border-color: var(--green-light);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7), 0 0 15px rgba(46, 196, 182, 0.3);
}

.royal-toast.error {
    border-color: var(--crimson);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7), 0 0 15px rgba(230, 57, 70, 0.3);
}

/* ========================================================
/* ========================================================
   SECTION FIEF & TRAVAIL : ÉCONOMIE FÉODALE (LABEUR, MINES, BANQUE, ATELIERS, CHAPELLE)
   ======================================================== */

.fief-hero .hero-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.fief-rank-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(201, 168, 78, 0.12);
    border: 1px solid rgba(201, 168, 78, 0.4);
    border-radius: 20px;
    padding: 6px 14px;
    box-shadow: 0 0 15px rgba(201, 168, 78, 0.15);
}

.fief-rank-chip .fief-rank-icon {
    font-size: 1.15rem;
}

.fief-rank-chip .fief-rank-text {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    color: var(--gold-bright);
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* --- BANDEAU D'ACTION RAPIDE (CYCLE DU FIEF) --- */
.fief-quick-hub {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    background: linear-gradient(135deg, rgba(20, 24, 38, 0.95), rgba(12, 14, 22, 0.98));
    border: 1px solid rgba(201, 168, 78, 0.35);
    border-radius: var(--radius-lg);
    padding: 16px 22px;
    margin-bottom: 20px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.55), 0 0 20px rgba(201, 168, 78, 0.08);
}

.fief-hub-status-col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.fief-hub-label {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--gold-bright);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.fief-status-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.fief-status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 0.85rem;
}

.fief-ind-title {
    color: var(--text-secondary);
}

.fief-ind-val {
    font-weight: 700;
}

.fief-ind-val.text-green {
    color: var(--green-light);
    text-shadow: 0 0 8px rgba(87, 204, 153, 0.4);
}

.fief-ind-val.text-cooldown {
    color: #fca5a5;
}

.fief-hub-actions-col {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.btn-fief-claim-all {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 22px;
    font-size: 0.95rem;
    font-family: var(--font-heading);
    font-weight: 700;
    background: var(--gold-gradient);
    color: #0c0d12;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(201, 168, 78, 0.4);
    transition: all 0.25s ease;
}

.btn-fief-claim-all:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(232, 202, 116, 0.6);
}

.btn-fief-claim-all:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    filter: grayscale(0.5);
}

/* --- BARRE DE FILTRES / NAVIGATION DU FIEF --- */
.fief-subnav-bar {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 6px;
    margin-bottom: 22px;
    scrollbar-width: thin;
}

.fief-subnav-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: rgba(18, 20, 30, 0.85);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.fief-subnav-btn:hover {
    border-color: var(--gold-primary);
    color: var(--text-primary);
    background: rgba(28, 32, 46, 0.95);
}

.fief-subnav-btn.active {
    background: var(--gold-primary);
    color: #0c0d12;
    font-weight: 700;
    border-color: var(--gold-bright);
    box-shadow: 0 0 14px rgba(201, 168, 78, 0.35);
}

/* --- BANDEAU DE FORTUNE JOUEUR --- */
.feudal-wallet-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
    width: 100%;
    box-sizing: border-box;
}

.feudal-wallet-pill {
    background: rgba(18, 20, 29, 0.92);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
    position: relative;
    transition: all 0.2s ease;
    min-width: 0;
    box-sizing: border-box;
    overflow: hidden;
}

.feudal-wallet-pill:hover {
    border-color: var(--gold-primary);
    transform: translateY(-2px);
}

.feudal-wallet-pill.highlight-gold {
    background: linear-gradient(135deg, rgba(201, 168, 78, 0.16), rgba(18, 20, 29, 0.95));
    border-color: var(--gold-primary);
    box-shadow: 0 4px 20px rgba(201, 168, 78, 0.15);
}

.feudal-wallet-pill .wallet-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.feudal-wallet-pill .wallet-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.wallet-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-bottom: 2px;
    flex-wrap: wrap;
    min-width: 0;
}

.feudal-wallet-pill .wallet-label {
    font-size: 0.72rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
}

.wallet-risk-tag {
    font-size: 0.65rem;
    color: #f59e0b;
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.35);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
    white-space: nowrap;
    flex-shrink: 0;
}

.wallet-safe-tag {
    font-size: 0.65rem;
    color: var(--green-light);
    background: rgba(87, 204, 153, 0.12);
    border: 1px solid rgba(87, 204, 153, 0.25);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.wallet-couple-tag {
    font-size: 0.65rem;
    color: #e879f9;
    background: rgba(232, 121, 249, 0.12);
    border: 1px solid rgba(232, 121, 249, 0.25);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn-quick-dep {
    background: rgba(201, 168, 78, 0.18);
    border: 1px solid rgba(201, 168, 78, 0.45);
    color: var(--gold-bright);
    font-size: 0.72rem;
    font-weight: 700;
    padding: 5px 10px;
    border-radius: 6px;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.btn-quick-dep:hover {
    background: var(--gold-primary);
    color: #0c0d12;
    border-color: var(--gold-bright);
    box-shadow: 0 0 10px rgba(201, 168, 78, 0.4);
}

.feudal-wallet-pill .wallet-val {
    font-size: 1.25rem;
    font-weight: 700;
    font-family: var(--font-heading);
    color: var(--text-primary);
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- GRILLE DES STATIONS FÉODALES --- */
.feudal-stations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 22px;
}

.feudal-station-card {
    background: rgba(18, 20, 29, 0.94);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
    transition: all 0.25s ease;
}

.feudal-station-card:hover {
    border-color: var(--gold-primary);
    box-shadow: 0 10px 32px rgba(201, 168, 78, 0.2);
}

.station-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    border-bottom: 1px solid rgba(201, 168, 78, 0.15);
    padding-bottom: 14px;
    position: relative;
}

.station-icon-wrap {
    font-size: 2rem;
    width: 52px;
    height: 52px;
    background: rgba(201, 168, 78, 0.12);
    border: 1px solid rgba(201, 168, 78, 0.3);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.station-title-box {
    flex: 1;
}

.station-title-box h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--gold-bright);
    margin: 0;
}

.station-title-box .station-sub {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.station-status-badge {
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 6px;
    background: rgba(87, 204, 153, 0.15);
    border: 1px solid rgba(87, 204, 153, 0.35);
    color: var(--green-light);
    white-space: nowrap;
}

.station-status-badge.cooldown {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.35);
    color: #fca5a5;
}

.station-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 18px;
}

/* --- FLAVOR JOB & TRADES --- */
.station-flavor-box {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-left: 3px solid var(--gold-primary);
    border-radius: 8px;
    padding: 12px 14px;
}

.flavor-job-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.flavor-job-badge {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--gold-bright);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.flavor-mult-badge {
    font-size: 0.68rem;
    background: rgba(201, 168, 78, 0.15);
    color: var(--gold-bright);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}

.flavor-job-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin: 0;
}

.fief-trades-strip {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.strip-label {
    font-size: 0.72rem;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.trade-pills-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.trade-pill {
    font-size: 0.72rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 3px 8px;
    border-radius: 12px;
    color: var(--text-secondary);
    cursor: default;
    transition: all 0.2s ease;
}

.trade-pill:hover {
    background: rgba(201, 168, 78, 0.15);
    color: var(--gold-bright);
    border-color: var(--gold-primary);
}

.station-specs {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 8px;
    padding: 10px 12px;
}

.spec-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* --- JAUGES DE RECHARGE VISUELLES --- */
.cooldown-gauge-wrap {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.cooldown-progress-track {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    overflow: hidden;
}

.cooldown-progress-fill {
    height: 100%;
    background: var(--gold-gradient);
    border-radius: 4px;
    transition: width 0.4s ease;
    box-shadow: 0 0 10px rgba(201, 168, 78, 0.5);
}

.cooldown-meta-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.cooldown-val {
    font-weight: 700;
    color: var(--gold-bright);
}

.station-footer {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-station-action {
    padding: 12px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: var(--font-heading);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* --- FILONS MINIERS & PIOCHE DE DIAMANT --- */
.fief-ores-showcase {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.fief-ores-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
}

.ore-mini-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 6px 4px;
    transition: all 0.2s ease;
}

.ore-mini-card .ore-icon {
    font-size: 1.25rem;
}

.ore-mini-card .ore-name {
    font-size: 0.68rem;
    font-weight: 700;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.ore-mini-card .ore-tier {
    font-size: 0.6rem;
    text-transform: uppercase;
    font-weight: 600;
}

.ore-mini-card.ore-common {
    border-color: rgba(160, 160, 160, 0.3);
}
.ore-mini-card.ore-common .ore-tier {
    color: #9ca3af;
}

.ore-mini-card.ore-rare {
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.08);
}
.ore-mini-card.ore-rare .ore-tier {
    color: #60a5fa;
}

.ore-mini-card.ore-epic {
    border-color: rgba(168, 85, 247, 0.45);
    background: rgba(168, 85, 247, 0.08);
}
.ore-mini-card.ore-epic .ore-tier {
    color: #c084fc;
}

.ore-mini-card.ore-legendary {
    border-color: rgba(245, 158, 11, 0.5);
    background: rgba(245, 158, 11, 0.1);
}
.ore-mini-card.ore-legendary .ore-tier {
    color: #fbbf24;
}

.ore-mini-card.ore-mythic {
    border-color: rgba(239, 68, 68, 0.6);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(201, 168, 78, 0.15));
    box-shadow: 0 0 10px rgba(239, 68, 68, 0.2);
}
.ore-mini-card.ore-mythic .ore-tier {
    color: #f87171;
    font-weight: 800;
}

.diamond-pick-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: linear-gradient(135deg, rgba(14, 165, 233, 0.12), rgba(18, 20, 30, 0.9));
    border: 1px solid rgba(14, 165, 233, 0.35);
    border-radius: 8px;
    padding: 10px 14px;
}

.diamond-pick-banner.equipped {
    border-color: var(--gold-primary);
    background: linear-gradient(135deg, rgba(201, 168, 78, 0.2), rgba(14, 165, 233, 0.15));
}

.pick-banner-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.pick-banner-info .pick-icon {
    font-size: 1.5rem;
}

.pick-banner-info strong {
    font-size: 0.85rem;
    color: var(--text-primary);
    display: block;
}

.pick-banner-info p {
    font-size: 0.72rem;
    color: var(--text-secondary);
    margin: 0;
}

/* --- BANQUE ROYALE DANS LE FIEF --- */
.bank-safe-badge {
    font-size: 0.72rem;
    color: var(--green-light);
    background: rgba(87, 204, 153, 0.12);
    border: 1px solid rgba(87, 204, 153, 0.3);
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
}

.bank-account-tabs {
    display: flex;
    gap: 8px;
    background: rgba(0, 0, 0, 0.3);
    padding: 4px;
    border-radius: 8px;
}

.bank-acc-tab {
    flex: 1;
    padding: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bank-acc-tab.active {
    background: rgba(201, 168, 78, 0.2);
    color: var(--gold-bright);
    font-weight: 700;
}

.bank-balance-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(201, 168, 78, 0.25);
    border-radius: 8px;
    padding: 12px 16px;
}

.bank-balance-card .bank-balance-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 2px;
}

.bank-balance-card .bank-balance-val {
    font-size: 1.35rem;
    font-family: var(--font-heading);
}

.bank-seal-icon {
    font-size: 1.5rem;
    opacity: 0.6;
}

.bank-tabs {
    display: flex;
    gap: 8px;
    background: rgba(0, 0, 0, 0.3);
    padding: 4px;
    border-radius: 8px;
}

.bank-tab-btn {
    flex: 1;
    padding: 8px;
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bank-tab-btn.active {
    background: var(--gold-primary);
    color: #0c0d12;
    font-weight: 700;
}

.bank-form-body {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bank-input-group {
    display: flex;
    gap: 8px;
}

.bank-input-group .form-input {
    flex: 1;
}

.quick-percentages-row {
    display: flex;
    gap: 6px;
}

.quick-bank-pct {
    flex: 1;
    padding: 6px 4px;
    font-size: 0.75rem;
    background: rgba(201, 168, 78, 0.1);
    border: 1px solid rgba(201, 168, 78, 0.25);
    border-radius: 6px;
    color: var(--gold-bright);
    cursor: pointer;
    text-align: center;
    font-weight: 700;
    transition: all 0.15s ease;
}

.quick-bank-pct:hover {
    background: var(--gold-primary);
    color: #0c0d12;
}

.quick-amounts-row {
    display: flex;
    gap: 6px;
}

.quick-bank-chip {
    flex: 1;
    padding: 6px 4px;
    font-size: 0.72rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-secondary);
    cursor: pointer;
    text-align: center;
    transition: all 0.15s ease;
}

.quick-bank-chip:hover {
    background: rgba(201, 168, 78, 0.2);
    color: var(--gold-bright);
    border-color: var(--gold-primary);
}

.bank-preview-box {
    display: flex;
    align-items: center;
    justify-content: space-around;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 8px;
    padding: 8px 12px;
}

.preview-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.prev-label {
    font-size: 0.68rem;
    color: var(--text-secondary);
}

.prev-val {
    font-size: 0.88rem;
    font-weight: 700;
}

.preview-arrow {
    font-size: 1rem;
    opacity: 0.5;
}

/* --- ATELIERS & DOMAINE FÉODAL --- */
.domain-overview-box {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 10px 12px;
}

.domain-desc {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
}

.domain-workshops-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.workshop-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
    transition: all 0.2s ease;
}

.workshop-card:hover {
    border-color: var(--gold-primary);
    transform: translateY(-2px);
}

.workshop-icon {
    font-size: 1.6rem;
    width: 36px;
    height: 36px;
    background: rgba(201, 168, 78, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.workshop-info {
    flex: 1;
}

.workshop-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2px;
}

.workshop-title-row strong {
    font-size: 0.8rem;
    color: var(--text-primary);
}

.workshop-desc {
    font-size: 0.72rem;
    color: var(--text-secondary);
    line-height: 1.3;
    margin: 0 0 6px 0;
}

.workshop-perk {
    display: inline-block;
    font-size: 0.68rem;
    color: var(--green-light);
    background: rgba(87, 204, 153, 0.12);
    border: 1px solid rgba(87, 204, 153, 0.25);
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 700;
}

.domain-footer-note {
    font-size: 0.78rem;
    color: var(--gold-bright);
    text-align: center;
    padding: 6px;
}

/* --- CHAPELLE & FOYER CONJUGAL --- */
.chapel-married-box {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.married-partner-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(201, 168, 78, 0.3);
    border-radius: 10px;
    padding: 12px;
}

.partner-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--gold-primary);
}

.partner-info {
    flex: 1;
}

.partner-badge {
    font-size: 0.7rem;
    color: var(--gold-bright);
    font-weight: 700;
    text-transform: uppercase;
    display: block;
}

.partner-info h4 {
    margin: 2px 0;
    font-size: 1rem;
    color: var(--text-primary);
}

.partner-sub {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.couple-vault-card {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(201, 168, 78, 0.2);
    border-radius: 10px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.couple-vault-card .vault-header {
    display: flex;
    align-items: center;
    gap: 10px;
}

.couple-vault-card .vault-icon {
    font-size: 1.5rem;
}

.couple-vault-card .vault-label {
    font-size: 0.72rem;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.couple-vault-card .vault-val {
    margin: 0;
    font-size: 1.2rem;
    font-family: var(--font-heading);
}

.couple-bank-actions {
    display: flex;
    gap: 6px;
}

.couple-bank-actions .form-input-sm {
    flex: 1;
    padding: 6px 8px;
    font-size: 0.8rem;
}

.chapel-single-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
}

.single-crest {
    font-size: 2.2rem;
}

.chapel-single-box h4 {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    color: var(--gold-bright);
    margin: 0;
}

.chapel-intro {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin: 0;
}

.chapel-form-group {
    width: 100%;
    text-align: left;
    margin-top: 6px;
}

.chapel-form-group label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: block;
    margin-bottom: 4px;
}

.chapel-ring-note {
    font-size: 0.8rem;
    font-weight: 600;
    margin: 4px 0 8px 0;
}

/* --- REGISTRE D'ACTIVITÉ DU FIEF --- */
.fief-activity-log-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 220px;
    overflow-y: auto;
    padding-right: 4px;
}

.fief-log-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 6px;
    padding: 8px 12px;
    font-size: 0.82rem;
    animation: fadeIn 0.3s ease;
}

.fief-log-item-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.fief-log-time {
    font-size: 0.72rem;
    color: var(--text-muted);
}

.fief-log-gain {
    font-weight: 700;
    color: var(--gold-bright);
}

.fief-log-empty {
    text-align: center;
    font-size: 0.82rem;
    color: var(--text-secondary);
    padding: 20px;
}

.fief-log-summary {
    text-align: right;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* ========================================================
   SECTION BOUTIQUE ROYALE COMPLETE & CRYPTE DES RELIQUES
   ======================================================== */

.shop-wallet-banner {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    background: rgba(18, 20, 28, 0.9);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 18px;
    margin-bottom: 20px;
    align-items: center;
}

.shop-balance-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    padding: 4px 10px;
    background: rgba(0, 0, 0, 0.25);
    border-radius: 6px;
}

.shop-balance-pill strong {
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-size: 1.05rem;
}

.shop-balance-pill.highlight-gold {
    border: 1px solid rgba(201, 168, 78, 0.35);
    background: rgba(201, 168, 78, 0.1);
}

.unopened-shelf-box {
    background: linear-gradient(135deg, rgba(30, 24, 16, 0.9), rgba(18, 20, 28, 0.95));
    border: 1px solid var(--gold-primary);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    margin-bottom: 24px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.shelf-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.shelf-header h3 {
    font-family: var(--font-heading);
    font-size: 1.05rem;
    color: var(--gold-bright);
    margin: 0;
}

.shelf-hint {
    font-size: 0.78rem;
    color: var(--text-secondary);
}

.unopened-shelf-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 12px;
}

.unopened-pack-card {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(201, 168, 78, 0.3);
    border-radius: 8px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.unopened-pack-card:hover {
    border-color: var(--gold-bright);
    transform: translateY(-2px);
}

.unopened-pack-badge {
    font-size: 1.4rem;
    font-weight: 700;
}

.unopened-pack-card h4 {
    font-size: 0.9rem;
    margin: 0;
    color: var(--text-primary);
}

.unopened-pack-sub {
    font-size: 0.72rem;
    color: var(--gold-bright);
    margin-bottom: 4px;
}

.shop-category-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 22px;
}

.shop-catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
    gap: 18px;
    margin-bottom: 30px;
}

.shop-item-card {
    background: rgba(18, 20, 28, 0.95);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: all 0.3s cubic-bezier(0.2, 0.8, 0.35, 1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5);
    position: relative;
}

.shop-item-card:hover {
    border-color: var(--gold-primary);
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(229, 184, 66, 0.25);
}

.shop-item-media {
    position: relative;
    width: 100%;
    height: 180px;
    background: #0b0d14;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.shop-item-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.45s ease;
    display: block;
}

.shop-item-card:hover .shop-item-banner-img {
    transform: scale(1.08);
}

.shop-cat-pill {
    position: absolute;
    top: 10px;
    left: 10px;
    font-size: 0.72rem;
    font-weight: 700;
    background: rgba(11, 13, 20, 0.85);
    border: 1px solid rgba(229, 184, 66, 0.4);
    color: var(--gold-bright);
    padding: 3px 10px;
    border-radius: 12px;
    backdrop-filter: blur(6px);
}

.shop-badge-status {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 0.72rem;
    font-weight: 700;
    background: rgba(46, 117, 89, 0.92);
    border: 1px solid #57cc99;
    color: #fff;
    padding: 3px 10px;
    border-radius: 12px;
    box-shadow: 0 0 12px rgba(87, 204, 153, 0.6);
    backdrop-filter: blur(4px);
}

.shop-item-body {
    padding: 14px 16px 8px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.shop-item-title-row {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
}

.shop-item-inline-emoji {
    font-size: 1.25rem;
    line-height: 1;
}

.shop-item-title-row h4 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    color: #fff;
}

.shop-item-desc {
    font-size: 0.82rem;
    color: var(--text-secondary);
    line-height: 1.4;
    margin: 0 0 8px 0;
    flex: 1;
}

.shop-item-footer {
    padding: 10px 16px 16px 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.shop-item-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shop-item-price .price-label {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.shop-item-price .price-val {
    font-size: 1.05rem;
    color: var(--gold-bright);
    font-family: var(--font-heading);
}

.shop-item-price {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.shop-item-price strong {
    font-size: 1.1rem;
    color: var(--gold-bright);
    font-family: var(--font-heading);
}

/* --- MODAL POPUP : DÉBALLAGE IMMÉDIAT DU PACK ACHETÉ --- */
.instant-unbox-dialog {
    max-width: 460px;
    text-align: center;
    padding: 30px 24px;
    border: 2px solid var(--gold-primary);
    background: linear-gradient(135deg, rgba(28, 22, 16, 0.98), rgba(16, 18, 26, 0.98));
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.8), 0 0 25px rgba(201, 168, 78, 0.3);
}

.instant-crest {
    font-size: 3rem;
    margin-bottom: 10px;
    animation: bounce 1.5s infinite;
}

.instant-unbox-dialog h2 {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 1.4rem;
    margin-bottom: 10px;
}

.instant-unbox-dialog p {
    font-size: 0.92rem;
    color: var(--text-secondary);
    line-height: 1.5;
    margin-bottom: 22px;
}

.instant-unbox-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-glow {
    box-shadow: 0 0 18px rgba(201, 168, 78, 0.5);
    font-weight: 700;
    font-family: var(--font-heading);
}

.btn-glow:hover {
    box-shadow: 0 0 26px rgba(201, 168, 78, 0.8);
    transform: scale(1.02);
}

/* ==================== GUICHET BANQUE ROYALE & COFFRE DE COUPLE ==================== */
.bank-account-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 14px;
}

.bank-acc-tab {
    flex: 1;
    background: rgba(22, 25, 37, 0.7);
    border: 1px solid rgba(212, 175, 55, 0.25);
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 8px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
}

.bank-acc-tab:hover {
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    border-color: rgba(212, 175, 55, 0.4);
}

.bank-acc-tab.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(154, 114, 24, 0.35));
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

.bank-balance-card {
    background: rgba(10, 12, 18, 0.75);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 8px;
    padding: 10px 14px;
    margin-bottom: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bank-balance-label {
    font-family: var(--font-heading);
    font-size: 0.82rem;
    color: var(--text-muted);
}

.bank-balance-val {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--gold-bright);
    text-shadow: 0 0 8px rgba(212, 175, 55, 0.4);
}

.couple-bank-notice {
    background: rgba(235, 69, 158, 0.08);
    border: 1px solid rgba(235, 69, 158, 0.25);
    color: #ff9ec0;
    font-size: 0.82rem;
    padding: 8px 12px;
    border-radius: 6px;
    margin-bottom: 14px;
    line-height: 1.4;
}

.couple-bank-notice.married-info {
    background: rgba(212, 175, 55, 0.1);
    border-color: rgba(212, 175, 55, 0.35);
    color: var(--gold-bright);
}

/* ==================== TAVERNE JEUX ROYAUX (NAVIGATION) ==================== */
.tavern-games-nav {
    display: flex;
    gap: 12px;
    background: rgba(14, 16, 24, 0.85);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 12px;
    padding: 8px 12px;
    margin-bottom: 20px;
}

.tavern-game-btn {
    flex: 1;
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-family: var(--font-heading);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 10px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
    letter-spacing: 0.5px;
}

.tavern-game-btn:hover {
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.1);
}

.tavern-game-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(138, 98, 14, 0.35));
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 16px rgba(212, 175, 55, 0.25);
}

.tavern-rules-nav-btn {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.16) 0%, rgba(14, 16, 24, 0.9) 100%);
    border: 1px solid var(--gold-primary);
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

.tavern-rules-nav-btn:hover {
    background: var(--gold-primary);
    color: #121008;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.6);
    transform: translateY(-1px);
}

.tavern-game-panel {
    display: none;
    width: 100%;
}

.tavern-game-panel.active {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

/* ==================== PILE OU FACE FÉODAL (COINFLIP) ==================== */
.coinflip-felt {
    background: radial-gradient(circle at center, #1b263b 0%, #0d131f 70%, #06090e 100%);
    border: 2px solid rgba(212, 175, 55, 0.35);
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.8), 0 8px 32px rgba(0, 0, 0, 0.6);
}

.coinflip-arena {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 20px 30px 20px;
    gap: 16px;
}

.coin-3d-stage {
    position: relative;
    width: 200px;
    height: 250px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding-bottom: 20px;
    overflow: visible;
}

.coin-3d-wrapper {
    perspective: 1200px;
    width: 130px;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.medieval-coin {
    width: 124px;
    height: 124px;
    position: relative;
    transform-style: preserve-3d;
    border-radius: 50%;
    cursor: pointer;
    transform: translateY(0px) rotateY(0deg) rotateX(12deg);
    transition: transform 0.4s ease;
    filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.5));
}

.medieval-coin.spinning {
    animation: coinTossPhysics 1.6s cubic-bezier(0.2, 0.8, 0.35, 1) forwards;
}

@keyframes coinTossPhysics {
    0% {
        transform: translateY(0px) rotateY(0deg) rotateX(12deg) scale(1);
    }
    18% {
        transform: translateY(-130px) rotateY(720deg) rotateX(6deg) scale(1.22);
    }
    40% {
        transform: translateY(-175px) rotateY(1440deg) rotateX(0deg) scale(1.35);
    }
    68% {
        transform: translateY(-60px) rotateY(2160deg) rotateX(-5deg) scale(1.15);
    }
    85% {
        transform: translateY(0px) rotateY(var(--target-spin, 2520deg)) rotateX(0deg) scale(1);
    }
    90% {
        transform: translateY(-18px) rotateY(var(--target-spin, 2520deg)) rotateX(-6deg) scale(1.04);
    }
    95% {
        transform: translateY(0px) rotateY(var(--target-spin, 2520deg)) rotateX(3deg) scale(1);
    }
    100% {
        transform: translateY(0px) rotateY(var(--target-spin, 2520deg)) rotateX(0deg) scale(1);
    }
}

.coin-floor-shadow {
    width: 100px;
    height: 16px;
    border-radius: 50%;
    background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 75%);
    margin-top: 10px;
    z-index: 1;
    transition: all 0.3s ease;
}

.coin-floor-shadow.spinning {
    animation: coinShadowToss 1.6s cubic-bezier(0.2, 0.8, 0.35, 1) forwards;
}

@keyframes coinShadowToss {
    0% {
        transform: scale(1);
        opacity: 0.85;
        filter: blur(2px);
    }
    40% {
        transform: scale(0.32);
        opacity: 0.12;
        filter: blur(12px);
    }
    85% {
        transform: scale(1);
        opacity: 0.85;
        filter: blur(2px);
    }
    90% {
        transform: scale(0.78);
        opacity: 0.5;
        filter: blur(5px);
    }
    95% {
        transform: scale(1);
        opacity: 0.85;
        filter: blur(2px);
    }
    100% {
        transform: scale(1);
        opacity: 0.85;
        filter: blur(2px);
    }
}

.coin-face {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 5px double #ffe066;
    box-shadow: 0 0 24px rgba(255, 215, 0, 0.45), inset 0 0 16px rgba(0, 0, 0, 0.7);
    user-select: none;
}

.coin-front {
    background: radial-gradient(circle at 35% 35%, #fff2a3 0%, #f9d71c 30%, #d4af37 65%, #805300 100%);
    color: #2b1800;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.4);
}

.coin-back {
    background: radial-gradient(circle at 35% 35%, #ffb48a 0%, #e65c00 35%, #992200 70%, #520000 100%);
    color: #fff;
    transform: rotateY(180deg);
    border-color: #ffaa66;
    box-shadow: 0 0 24px rgba(255, 120, 50, 0.4), inset 0 0 16px rgba(0, 0, 0, 0.7);
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7);
}

.coin-crest {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 900;
    letter-spacing: 1px;
}

.coin-legend {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 2px;
    opacity: 0.85;
}

.coinflip-choice-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.selector-label {
    font-family: var(--font-heading);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.coin-choice-buttons {
    display: flex;
    gap: 16px;
}

.coin-side-btn {
    background: rgba(20, 24, 36, 0.9);
    border: 2px solid rgba(212, 175, 55, 0.3);
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 700;
    padding: 10px 22px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.coin-side-btn:hover {
    border-color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
}

.coin-side-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.35), rgba(138, 98, 14, 0.45));
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 16px rgba(212, 175, 55, 0.3);
    transform: scale(1.04);
}

.coinflip-outcome-banner {
    padding: 12px 24px;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    text-align: center;
    animation: fadeIn 0.3s ease-out;
}

.coinflip-outcome-banner.win {
    background: rgba(46, 204, 113, 0.15);
    border: 1px solid rgba(46, 204, 113, 0.5);
    color: #2ecc71;
    box-shadow: 0 0 20px rgba(46, 204, 113, 0.2);
}

.coinflip-outcome-banner.loss {
    background: rgba(231, 76, 60, 0.15);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #e74c3c;
    box-shadow: 0 0 20px rgba(231, 76, 60, 0.2);
}

/* ==================== CHIFOUMI ROYAL (RPS) ==================== */
.rps-felt {
    background: radial-gradient(circle at center, #24141e 0%, #160c13 70%, #0b050a 100%);
    border: 2px solid rgba(235, 69, 158, 0.35);
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.8), 0 8px 32px rgba(0, 0, 0, 0.6);
}

.rps-arena {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 24px 20px;
    gap: 22px;
}

.rps-duel-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    width: 100%;
    max-width: 650px;
}

.rps-fighter-card {
    flex: 1;
    background: rgba(18, 20, 30, 0.85);
    border: 2px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.rps-fighter-card.guard-fighter {
    border-color: rgba(231, 76, 60, 0.4);
}

.fighter-title {
    font-family: var(--font-heading);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.rps-symbol-box {
    min-width: 140px;
    min-height: 140px;
    border-radius: 12px;
    background: rgba(10, 12, 18, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px;
    text-align: center;
    position: relative;
}

.rps-symbol-name {
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--gold-bright);
}

.rps-vs-divider {
    display: flex;
    align-items: center;
    justify-content: center;
}

.vs-text {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 900;
    color: #ff5577;
    background: rgba(220, 20, 60, 0.15);
    border: 1px solid rgba(220, 20, 60, 0.4);
    padding: 6px 14px;
    border-radius: 20px;
    letter-spacing: 1.5px;
    box-shadow: 0 0 12px rgba(220, 20, 60, 0.3);
}

.rps-choice-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.rps-choice-cards {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    justify-content: center;
}

.rps-card-btn {
    background: rgba(20, 24, 36, 0.9);
    border: 2px solid rgba(212, 175, 55, 0.3);
    color: var(--text-primary);
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.rps-card-btn:hover {
    border-color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    transform: translateY(-2px);
}

.rps-card-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.35), rgba(138, 98, 14, 0.45));
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 16px rgba(212, 175, 55, 0.35);
    transform: scale(1.03);
}

.rps-outcome-banner {
    padding: 12px 24px;
    border-radius: 8px;
    font-family: var(--font-heading);
    font-size: 1.05rem;
    font-weight: 700;
    text-align: center;
    animation: fadeIn 0.3s ease-out;
}

.rps-outcome-banner.win {
    background: rgba(46, 204, 113, 0.15);
    border: 1px solid rgba(46, 204, 113, 0.5);
    color: #2ecc71;
    box-shadow: 0 0 20px rgba(46, 204, 113, 0.2);
}

.rps-outcome-banner.loss {
    background: rgba(231, 76, 60, 0.15);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #e74c3c;
    box-shadow: 0 0 20px rgba(231, 76, 60, 0.2);
}

.rps-outcome-banner.tie {
    background: rgba(52, 152, 219, 0.15);
    border: 1px solid rgba(52, 152, 219, 0.5);
    color: #3498db;
    box-shadow: 0 0 20px rgba(52, 152, 219, 0.2);
}

.falling-coin-particle {
    position: fixed;
    z-index: 9999;
    font-size: 1.6rem;
    pointer-events: none;
    animation: coinFall 1.8s linear forwards;
    filter: drop-shadow(0 0 6px rgba(255, 215, 0, 0.6));
}

@keyframes coinFall {
    0% { transform: translateY(0) rotate(0deg); opacity: 1; }
    80% { opacity: 0.9; }
    100% { transform: translateY(105vh) rotate(720deg); opacity: 0; }
}

/* ==================== QG & CASERNE MILITAIRE ==================== */
.caserne-atelier-nav {
    display: flex;
    gap: 10px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    background: rgba(11, 13, 20, 0.6);
    padding: 8px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}
.caserne-nav-btn {
    background: transparent;
    border: 1px solid transparent;
    color: var(--text-secondary);
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-family: var(--font-heading);
    font-size: 0.92rem;
    font-weight: 600;
    transition: all 0.2s ease;
}
.caserne-nav-btn:hover {
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.08);
}
.caserne-nav-btn.active {
    background: var(--gold-gradient);
    color: #0b0d14;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.25);
}

.atelier-panel.hidden { display: none; }
.atelier-panel.active { display: block; animation: fadeIn 0.3s ease; }

/* Profil Showcase (Lecture Seule) */
.profile-showcase-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
}
.showcase-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 16px;
}
.profile-trio-showcase {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
    width: 100%;
    box-sizing: border-box;
}

@media (max-width: 900px) {
    .profile-trio-showcase {
        grid-template-columns: 1fr;
    }
}

.profile-showcase-unit {
    background: rgba(14, 16, 26, 0.9);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    max-width: 100%;
    box-sizing: border-box;
}

.profile-showcase-unit:hover {
    border-color: var(--gold-primary);
    transform: translateY(-3px);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.7);
}

.profile-showcase-unit.empty-unit {
    border: 2px dashed rgba(229, 184, 66, 0.35);
    background: rgba(11, 13, 20, 0.6);
    min-height: 360px;
    justify-content: center;
    text-align: center;
}

.showcase-unit-role-tag {
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.12);
    border: 1px solid rgba(229, 184, 66, 0.35);
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 12px;
    width: fit-content;
}

.profile-showcase-unit .feudal-card-display {
    max-width: 100%;
    width: 100%;
    margin-bottom: 4px;
}

.profile-showcase-unit .feudal-card-display .feudal-card-render-img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
}

.showcase-unit-details {
    width: 100%;
    margin-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 8px;
}

.showcase-unit-gear {
    display: flex;
    justify-content: space-around;
    font-size: 0.78rem;
    color: var(--text-secondary);
    gap: 8px;
}

.showcase-unit-gear span {
    background: rgba(255, 255, 255, 0.04);
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Faction Synergies Banner */
.faction-synergy-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.08), rgba(11, 13, 20, 0.85));
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 16px 20px;
    transition: all 0.3s ease;
}

.faction-synergy-banner.has-active-synergy {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.18) 0%, rgba(18, 22, 34, 0.95) 100%);
    border: 1px solid var(--gold-bright);
    box-shadow: 0 0 20px rgba(229, 184, 66, 0.25);
}
.synergy-badge-icon {
    font-size: 2rem;
}

/* ==================== CASIER MILITAIRE & EXPLOITS DE GUERRE ==================== */
.profile-military-record {
    background: linear-gradient(145deg, rgba(16, 20, 32, 0.92), rgba(9, 11, 18, 0.98));
    border: 1px solid rgba(212, 175, 55, 0.28);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    margin-top: 24px;
    position: relative;
    overflow: hidden;
}
.profile-military-record::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold-bright), #e67e22, transparent);
}
.military-record-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.mil-section-badge {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: var(--gold-bright);
    margin-bottom: 4px;
}
.military-record-header h3 {
    font-family: var(--font-cinzel);
    font-size: 1.35rem;
    color: #fff;
    margin: 0;
    letter-spacing: 0.5px;
}
.mil-record-motto {
    font-style: italic;
    font-size: 0.88rem;
    color: var(--text-muted);
}
.military-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}
@media (max-width: 1024px) {
    .military-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 600px) {
    .military-stats-grid {
        grid-template-columns: 1fr;
    }
}
.mil-stat-card {
    background: rgba(13, 16, 26, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: var(--radius-md);
    padding: 18px 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    backdrop-filter: blur(8px);
}
.mil-stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.4);
}
.mil-card-dungeon {
    border-top: 3px solid #8e44ad;
}
.mil-card-dungeon:hover {
    border-color: #9b59b6;
    box-shadow: 0 12px 30px rgba(142, 68, 173, 0.25);
}
.mil-card-boss {
    border-top: 3px solid #c0392b;
}
.mil-card-boss:hover {
    border-color: #e74c3c;
    box-shadow: 0 12px 30px rgba(192, 57, 43, 0.25);
}
.mil-card-cards {
    border-top: 3px solid #27ae60;
}
.mil-card-cards:hover {
    border-color: #2ecc71;
    box-shadow: 0 12px 30px rgba(39, 174, 96, 0.25);
}
.mil-card-gear {
    border-top: 3px solid #d4af37;
}
.mil-card-gear:hover {
    border-color: #f1c40f;
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.25);
}
.mil-stat-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.mil-icon-box {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.mil-card-dungeon .mil-icon-box {
    background: rgba(142, 68, 173, 0.15);
    border-color: rgba(142, 68, 173, 0.35);
}
.mil-card-boss .mil-icon-box {
    background: rgba(192, 57, 43, 0.15);
    border-color: rgba(192, 57, 43, 0.35);
}
.mil-card-cards .mil-icon-box {
    background: rgba(39, 174, 96, 0.15);
    border-color: rgba(39, 174, 96, 0.35);
}
.mil-card-gear .mil-icon-box {
    background: rgba(212, 175, 55, 0.15);
    border-color: rgba(212, 175, 55, 0.35);
}
.mil-badge-pill {
    font-size: 0.72rem;
    padding: 3px 8px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-muted);
    font-weight: 600;
}
.mil-stat-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.mil-stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}
.mil-stat-val {
    font-family: var(--font-cinzel);
    font-size: 1.85rem;
    font-weight: 800;
    color: #fff;
    line-height: 1.1;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}
.mil-stat-footer {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.mil-mini-track {
    width: 100%;
    height: 6px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 3px;
    overflow: hidden;
    position: relative;
}
.mil-mini-fill {
    height: 100%;
    border-radius: 3px;
    transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.mil-mini-fill.dungeon-fill {
    background: linear-gradient(90deg, #8e44ad, #bb86fc);
}
.mil-mini-fill.boss-fill {
    background: linear-gradient(90deg, #c0392b, #ff7675);
}
.mil-mini-fill.cards-fill {
    background: linear-gradient(90deg, #27ae60, #55efc4);
}
.mil-mini-fill.gear-fill {
    background: linear-gradient(90deg, #d4af37, #ffeaa7);
}
.mil-sub-txt {
    font-size: 0.76rem;
    color: var(--text-muted);
    font-family: var(--font-mono, monospace);
}

/* Arène Deployed Trio Banner */
.arena-team-deployed-banner {
    background: linear-gradient(180deg, rgba(20, 24, 38, 0.9), rgba(11, 13, 20, 0.95));
    border: 1px solid var(--gold-border);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 24px;
}
.arena-team-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 16px;
}
.arena-team-badge {
    color: var(--gold-bright);
    font-size: 0.75rem;
    letter-spacing: 1px;
    font-weight: 700;
}
.arena-deployed-cards-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 18px;
    align-items: start;
}

@media (max-width: 900px) {
    .arena-deployed-cards-row {
        grid-template-columns: 1fr;
    }
}

.arena-deployed-unit-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    width: 100%;
    max-width: 320px;
    margin: 0 auto;
}

.arena-deployed-unit-card .unit-role-pill {
    padding: 6px 16px;
    background: rgba(20, 24, 38, 0.95);
    border: 1.5px solid var(--gold-primary);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #f7e7b4;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    text-align: center;
    width: 100%;
}

.arena-deployed-unit-card .feudal-card-display {
    width: 100%;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.arena-deployed-unit-card .feudal-card-display:hover {
    transform: translateY(-6px) scale(1.02);
}

.arena-deployed-unit-card.empty .empty-unit-placeholder {
    width: 100%;
    min-height: 380px;
    border: 2px dashed rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(14, 16, 24, 0.4);
    color: var(--text-muted);
    padding: 24px;
    text-align: center;
}

/* Arène PvP Challenge Card */
.arena-pvp-card {
    background: linear-gradient(135deg, rgba(192, 57, 43, 0.1), rgba(11, 13, 20, 0.85));
    border: 1px solid rgba(192, 57, 43, 0.4);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
}
.arena-pvp-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 18px;
}
.arena-pvp-header .pvp-crest {
    font-size: 2.2rem;
}
.arena-pvp-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}
.pvp-input-col.full-width {
    grid-column: 1 / -1;
}
.pvp-submit-wrap {
    grid-column: 1 / -1;
    margin-top: 6px;
}

/* ==================== FORGE ROYALE D'ÉQUIPEMENTS ==================== */
.feudal-blacksmith-chamber, .feudal-athanor-chamber, .feudal-packs-chamber {
    background: linear-gradient(135deg, rgba(16, 20, 30, 0.96) 0%, rgba(10, 12, 18, 0.98) 100%);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.feudal-blacksmith-chamber::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(230, 81, 0, 0.12) 0%, transparent 70%);
    pointer-events: none;
    border-radius: 50%;
}

.feudal-athanor-chamber::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(147, 51, 234, 0.14) 0%, transparent 70%);
    pointer-events: none;
    border-radius: 50%;
}

.feudal-packs-chamber::before {
    content: '';
    position: absolute;
    top: -80px;
    right: -80px;
    width: 260px;
    height: 260px;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
    pointer-events: none;
    border-radius: 50%;
}

/* En-têtes thématiques */
.forge-header-banner, .fusion-header-banner, .caserne-packs-banner {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.18);
    position: relative;
    flex-wrap: wrap;
}

.forge-banner-icon-box, .fusion-banner-icon-box, .packs-banner-icon-box {
    width: 64px;
    height: 64px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.forge-banner-icon-box {
    background: radial-gradient(circle, rgba(249, 115, 22, 0.25) 0%, rgba(20, 24, 33, 0.9) 100%);
    border: 1px solid rgba(249, 115, 22, 0.4);
    color: #fb923c;
}

.fusion-banner-icon-box {
    background: radial-gradient(circle, rgba(168, 85, 247, 0.25) 0%, rgba(20, 24, 33, 0.9) 100%);
    border: 1px solid rgba(168, 85, 247, 0.4);
    color: #c084fc;
}

.packs-banner-icon-box {
    background: radial-gradient(circle, rgba(212, 175, 55, 0.25) 0%, rgba(20, 24, 33, 0.9) 100%);
    border: 1px solid rgba(212, 175, 55, 0.4);
    color: var(--gold-bright);
}

.forge-banner-text, .fusion-banner-text, .packs-banner-text {
    flex: 1;
    min-width: 280px;
}

.forge-pill-tag, .fusion-pill-tag, .packs-pill-tag {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 6px;
}

.forge-pill-tag {
    background: rgba(234, 88, 12, 0.18);
    color: #fb923c;
    border: 1px solid rgba(234, 88, 12, 0.35);
}

.fusion-pill-tag {
    background: rgba(147, 51, 234, 0.18);
    color: #c084fc;
    border: 1px solid rgba(147, 51, 234, 0.35);
}

.packs-pill-tag {
    background: rgba(212, 175, 55, 0.18);
    color: var(--gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.forge-banner-text h2, .fusion-banner-text h2, .packs-banner-text h2 {
    margin: 0 0 6px 0;
    font-size: 1.45rem;
    color: #f8fafc;
    letter-spacing: 0.5px;
}

.forge-banner-text p, .fusion-banner-text p, .packs-banner-text p {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.5;
    color: #94a3b8;
}

/* Portefeuilles de la Caserne */
.packs-wallet-pills {
    display: flex;
    gap: 12px;
    align-items: center;
}

.pack-wallet-pill {
    background: rgba(11, 14, 22, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pack-wallet-pill.highlight-gold {
    border-color: rgba(212, 175, 55, 0.35);
    background: rgba(212, 175, 55, 0.08);
}

.pack-wallet-pill .pill-ico {
    font-size: 1.4rem;
}

.pack-wallet-pill .pill-lbl {
    display: block;
    font-size: 0.72rem;
    color: #94a3b8;
    text-transform: uppercase;
}

.pack-wallet-pill .pill-val {
    font-size: 1.05rem;
    color: var(--gold-bright);
    font-weight: 700;
}

/* Layout Forge Royale */
.forge-content-layout {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 24px;
    margin-top: 22px;
}

@media (max-width: 1024px) {
    .forge-content-layout {
        grid-template-columns: 1fr;
    }
}

.forge-gear-list-pane {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.forge-gear-list-header {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.forge-list-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.forge-list-title-row h3 {
    margin: 0;
    font-size: 1.15rem;
    color: #f1f5f9;
}

.forge-inventory-counter {
    font-size: 0.78rem;
    font-weight: 600;
    color: #94a3b8;
    background: rgba(0, 0, 0, 0.4);
    padding: 2px 8px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.forge-filter-group {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.forge-filter-btn {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.forge-filter-btn:hover {
    border-color: rgba(212, 175, 55, 0.6);
    color: #f8fafc;
    transform: translateY(-1px);
}

.forge-filter-btn.active {
    background: rgba(212, 175, 55, 0.2);
    border-color: var(--gold-primary);
    color: var(--gold-bright);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.25);
}

.forge-gear-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    gap: 14px;
    max-height: 560px;
    overflow-y: auto;
    padding-right: 6px;
}

/* Carte Équipement Féodale */
.forge-gear-card {
    background: linear-gradient(135deg, rgba(18, 22, 32, 0.95), rgba(12, 14, 22, 0.95));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    gap: 12px;
    align-items: center;
    cursor: pointer;
    position: relative;
    transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

.forge-gear-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 4px;
    border-radius: 12px 0 0 12px;
}

.forge-gear-card.rarity-common::after { background: #94a3b8; }
.forge-gear-card.rarity-uncommon::after { background: #22c55e; }
.forge-gear-card.rarity-rare::after { background: #38bdf8; }
.forge-gear-card.rarity-epic::after { background: #c084fc; }
.forge-gear-card.rarity-legendary::after { background: #fbbf24; }
.forge-gear-card.rarity-mythic::after { background: #ef4444; }

.forge-gear-card:hover {
    transform: translateY(-2px);
    border-color: rgba(212, 175, 55, 0.5);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.5), 0 0 14px rgba(212, 175, 55, 0.15);
}

.forge-gear-card.active {
    border-color: var(--gold-bright);
    background: linear-gradient(135deg, rgba(35, 30, 18, 0.96), rgba(20, 18, 12, 0.96));
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.35);
}

.forge-gear-card .gear-icon {
    font-size: 1.9rem;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    flex-shrink: 0;
}

.forge-gear-card .gear-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.forge-gear-card .gear-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
}

.forge-gear-card .gear-title {
    font-size: 0.9rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #f1f5f9;
}

.forge-gear-card .gear-lvl-badge {
    font-size: 0.72rem;
    font-weight: 800;
    padding: 1px 7px;
    border-radius: 6px;
    background: rgba(212, 175, 55, 0.2);
    color: var(--gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.4);
    flex-shrink: 0;
}

.forge-gear-card .gear-stats-sm {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    font-size: 0.76rem;
    color: #cbd5e1;
    margin-top: 2px;
}

.forge-gear-card .gear-stat-pill {
    background: rgba(0, 0, 0, 0.35);
    padding: 1px 6px;
    border-radius: 4px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.forge-gear-card .gear-equipped-tag {
    font-size: 0.72rem;
    color: #94a3b8;
    margin-top: 2px;
}

.forge-gear-card .gear-equipped-tag.equipped {
    color: #38bdf8;
    font-weight: 600;
}

/* Panneau d'action & Enclume Royale */
.forge-action-pane {
    background: rgba(11, 14, 22, 0.92);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: var(--radius-md);
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-shadow: inset 0 0 24px rgba(0, 0, 0, 0.6);
}

.forge-selected-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-anvil-pulse {
    font-size: 3.2rem;
    margin-bottom: 14px;
    animation: anvil-pulse 2.2s infinite ease-in-out;
}

@keyframes anvil-pulse {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0 rgba(249, 115, 22, 0)); }
    50% { transform: scale(1.08); filter: drop-shadow(0 0 16px rgba(249, 115, 22, 0.5)); }
}

.forge-selected-empty h4 {
    color: #e2e8f0;
    margin: 8px 0 6px 0;
    font-size: 1.15rem;
}

.forge-selected-empty p {
    font-size: 0.85rem;
    line-height: 1.5;
    max-width: 320px;
    margin: 0 auto;
}

/* Fiche Héros de l'Équipement Sélectionné */
.forge-selected-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.forge-item-hero-card {
    background: linear-gradient(135deg, rgba(24, 28, 40, 0.95), rgba(16, 18, 26, 0.95));
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.forge-item-hero-top {
    display: flex;
    align-items: center;
    gap: 14px;
}

.forge-item-icon-frame {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.15) 0%, rgba(0, 0, 0, 0.6) 100%);
    border: 2px solid rgba(212, 175, 55, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    flex-shrink: 0;
}

.forge-item-hero-info {
    flex: 1;
    min-width: 0;
}

.forge-item-hero-info h3 {
    margin: 0 0 6px 0;
    font-size: 1.25rem;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.forge-item-meta {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
    align-items: center;
}

.badge-slot {
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.badge-lvl {
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
    font-weight: 700;
}

/* Jauge de Forge à 4 paliers */
.forge-level-track-wrapper {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.forge-track-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.78rem;
    color: #94a3b8;
    margin-bottom: 8px;
}

.forge-track-label strong {
    color: var(--gold-bright);
}

.forge-level-track {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.forge-track-step {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 6px 0;
    text-align: center;
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    transition: all 0.25s ease;
}

.forge-track-step.reached {
    background: rgba(212, 175, 55, 0.18);
    border-color: var(--gold-primary);
    color: var(--gold-bright);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.2);
}

.forge-track-step.current {
    background: linear-gradient(135deg, rgba(234, 88, 12, 0.3), rgba(212, 175, 55, 0.3));
    border-color: #fb923c;
    color: #f8fafc;
    box-shadow: 0 0 12px rgba(249, 115, 22, 0.4);
}

/* Boîte de Porteur */
.forge-item-assignment-box {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 12px 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.forge-assign-header {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.forge-assign-label {
    font-size: 0.75rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.forge-bearer-name {
    font-weight: 600;
    color: #38bdf8;
    font-size: 0.92rem;
}

/* Boîte de comparaison de stats */
.forge-stats-comparison-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.55);
    padding: 14px 18px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.stat-compare-box {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: center;
    flex: 1;
}

.comp-label {
    font-size: 0.74rem;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.comp-val {
    font-size: 0.98rem;
    font-weight: 700;
    color: #f1f5f9;
}

.stat-compare-box.highlight .comp-val {
    color: #22c55e;
}

.stat-compare-arrow-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 0 12px;
}

.stat-compare-arrow {
    font-size: 1.3rem;
    color: var(--gold-bright);
    animation: pulse-arrow 1.8s infinite;
}

.stat-boost-pill {
    font-size: 0.7rem;
    font-weight: 800;
    background: rgba(34, 197, 94, 0.15);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.35);
    padding: 1px 6px;
    border-radius: 10px;
}

/* Coût et Actions */
.forge-cost-box {
    background: rgba(212, 175, 55, 0.08);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 10px;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cost-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cost-label {
    font-size: 0.75rem;
    color: #94a3b8;
    text-transform: uppercase;
}

.cost-info strong {
    font-size: 1.15rem;
    color: var(--gold-bright);
}

.wallet-balance-indicator {
    font-size: 0.85rem;
    color: #cbd5e1;
}

.wallet-balance-indicator strong {
    color: var(--gold-bright);
}

.forge-action-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.btn-forge-action {
    padding: 14px;
    font-size: 1.02rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.btn-scrap-action {
    padding: 10px;
    font-size: 0.88rem;
}

/* ==================== FUSION ALCHIMIQUE ==================== */
.fusion-header-action {
    margin-left: auto;
}

.btn-auto-fuse {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    font-size: 0.92rem;
    font-weight: 700;
}

.badge-count {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.75rem;
}

/* Schéma rituel alchimique */
.fusion-ritual-diagram {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin: 22px 0;
    padding: 20px;
    background: radial-gradient(circle at center, rgba(147, 51, 234, 0.12) 0%, rgba(10, 12, 18, 0.8) 100%);
    border: 1px dashed rgba(168, 85, 247, 0.35);
    border-radius: 14px;
    flex-wrap: wrap;
}

.ritual-step-slot {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
    min-width: 140px;
}

.slot-circle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    border: 2px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    color: #e2e8f0;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
    transition: all 0.3s ease;
}

.slot-circle.gold-glow {
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    background: radial-gradient(circle, rgba(212, 175, 55, 0.2) 0%, rgba(0, 0, 0, 0.7) 100%);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.35);
    animation: gold-pulse 2s infinite ease-in-out;
}

@keyframes gold-pulse {
    0%, 100% { box-shadow: 0 0 14px rgba(212, 175, 55, 0.3); }
    50% { box-shadow: 0 0 26px rgba(212, 175, 55, 0.6); }
}

.slot-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: #f1f5f9;
}

.slot-sub {
    font-size: 0.72rem;
    color: #94a3b8;
}

.ritual-operator {
    font-size: 1.6rem;
    font-weight: 800;
    color: #c084fc;
}

.ritual-operator-arrow {
    font-size: 1.8rem;
    color: var(--gold-bright);
    animation: pulse-arrow 1.8s infinite;
}

/* Grille des candidats à la fusion */
.fusion-candidates-box {
    margin-top: 14px;
}

.fusion-candidates-header h3 {
    margin: 0;
    font-size: 1.15rem;
    color: #f1f5f9;
}

.fusion-candidates-subtitle {
    margin: 4px 0 14px 0;
    font-size: 0.82rem;
    color: #94a3b8;
}

.fusion-candidates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 18px;
}

.fusion-candidate-card {
    background: linear-gradient(135deg, rgba(20, 24, 36, 0.96), rgba(14, 16, 24, 0.96));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.fusion-candidate-card:hover {
    transform: translateY(-3px);
    border-color: rgba(168, 85, 247, 0.5);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), 0 0 16px rgba(168, 85, 247, 0.2);
}

.fusion-candidate-card.rarity-legendary:hover {
    border-color: rgba(245, 158, 11, 0.6);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6), 0 0 20px rgba(245, 158, 11, 0.25);
}

.fusion-card-head {
    display: flex;
    gap: 14px;
    align-items: center;
}

.fusion-card-avatar {
    width: 64px;
    height: 86px;
    object-fit: cover;
    border-radius: 8px;
    border: 2px solid var(--border-color);
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.fusion-card-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.fusion-card-info h4 {
    margin: 0;
    font-size: 1.05rem;
    color: #f8fafc;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fusion-stars-step {
    font-size: 0.95rem;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 6px;
}

.fusion-copies-count {
    font-size: 0.78rem;
    color: #94a3b8;
}

.fusion-copies-count strong {
    color: #38bdf8;
}

.fusion-stats-boost-row {
    display: flex;
    justify-content: space-between;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 0.78rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.fusion-stats-boost-row span {
    color: #94a3b8;
}

.fusion-stats-boost-row strong {
    color: #4ade80;
}

.btn-fuse-candidate {
    padding: 8px 14px;
    font-size: 0.85rem;
    font-weight: 700;
}

/* Badges d'exigence des Pierres d'Éveil dans la Fusion */
.fusion-stone-req-badge {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 0.78rem;
    font-weight: 600;
    transition: all 0.25s ease;
}

.fusion-stone-req-badge.stone-req-ok {
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.fusion-stone-req-badge.stone-req-missing {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.35);
    color: #fca5a5;
}

.fusion-stone-req-badge .stone-stock-pill {
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.1);
    white-space: nowrap;
}

.fusion-stone-req-badge .stone-stock-pill.missing {
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.3);
}

.btn-fuse-single.btn-locked {
    opacity: 0.65;
    cursor: not-allowed;
    background: #334155 !important;
    border-color: #475569 !important;
    color: #94a3b8 !important;
}

.fusion-awakening-stones-bar {
    margin-bottom: 24px;
}

/* ==================== BOUTIQUE DE BOOSTERS ROYALE ==================== */
.caserne-packs-showcase {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 24px;
}

@media (max-width: 1024px) {
    .caserne-packs-showcase {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* Carte Foil de Booster */
.booster-foil-card {
    background: linear-gradient(135deg, rgba(20, 24, 34, 0.96) 0%, rgba(12, 14, 20, 0.98) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.booster-foil-card:hover {
    transform: translateY(-6px) scale(1.015);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7);
}

/* Reflets de brillance holographique Foil */
.booster-foil-sheen {
    position: absolute;
    top: -100%;
    left: -100%;
    width: 300%;
    height: 300%;
    background: linear-gradient(115deg, transparent 40%, rgba(255, 255, 255, 0.08) 45%, rgba(212, 175, 55, 0.18) 50%, rgba(255, 255, 255, 0.08) 55%, transparent 60%);
    pointer-events: none;
    transition: transform 0.6s ease;
    transform: rotate(25deg);
}

.booster-foil-card:hover .booster-foil-sheen {
    transform: translateY(30%) rotate(25deg);
}

.booster-foil-card.pack-serf {
    border-color: rgba(180, 140, 90, 0.35);
}

.booster-foil-card.pack-serf:hover {
    border-color: rgba(210, 160, 100, 0.7);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 24px rgba(180, 140, 90, 0.25);
}

.booster-foil-card.pack-garde {
    border-color: rgba(56, 189, 248, 0.35);
}

.booster-foil-card.pack-garde:hover {
    border-color: rgba(56, 189, 248, 0.75);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 24px rgba(56, 189, 248, 0.3);
}

.booster-foil-card.pack-trone {
    border-color: rgba(168, 85, 247, 0.4);
}

.booster-foil-card.pack-trone:hover {
    border-color: rgba(212, 175, 55, 0.85);
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 28px rgba(212, 175, 55, 0.35), 0 0 35px rgba(168, 85, 247, 0.2);
}

/* Conteneur d'illustration Booster */
.booster-pack-art-container {
    width: 100%;
    height: 310px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    background: #000;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
    border: 2px solid rgba(255, 255, 255, 0.08);
}

.booster-pack-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.4s ease;
}

.booster-foil-card:hover .booster-pack-img {
    transform: scale(1.05);
}

.booster-wax-seal-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: radial-gradient(circle, #78350f 0%, #451a03 100%);
    border: 2px solid #b45309;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.6);
}

.booster-wax-seal-badge.seal-blue {
    background: radial-gradient(circle, #1e3a8a 0%, #0f172a 100%);
    border-color: #3b82f6;
}

.booster-wax-seal-badge.seal-purple {
    background: radial-gradient(circle, #831843 0%, #500724 100%);
    border-color: #f59e0b;
    box-shadow: 0 0 14px rgba(245, 158, 11, 0.5);
}

/* Détails du Booster */
.booster-pack-details {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    margin-top: 14px;
    flex: 1;
}

.booster-type-tag {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    padding: 2px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
}

.tag-serf {
    background: rgba(180, 140, 90, 0.18);
    color: #d4a373;
    border: 1px solid rgba(180, 140, 90, 0.35);
}

.tag-garde {
    background: rgba(56, 189, 248, 0.18);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.35);
}

.tag-trone {
    background: rgba(212, 175, 55, 0.18);
    color: var(--gold-bright);
    border: 1px solid rgba(212, 175, 55, 0.35);
}

.booster-title {
    margin: 0 0 6px 0;
    font-size: 1.25rem;
    color: #f8fafc;
    font-weight: 700;
}

.booster-desc {
    margin: 0 0 12px 0;
    font-size: 0.82rem;
    color: #94a3b8;
    line-height: 1.45;
    min-height: 48px;
}

/* Badges de taux de drop */
.booster-drop-rates-box {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    margin-bottom: 12px;
    width: 100%;
}

.drop-rate-chip {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 7px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #94a3b8;
}

.drop-rate-chip.rate-rare { color: #38bdf8; }
.drop-rate-chip.rate-epic { color: #c084fc; }
.drop-rate-chip.rate-legendary { color: #fbbf24; }
.drop-rate-chip.rate-mythic { color: #f87171; }
.drop-rate-chip.highlight {
    background: rgba(212, 175, 55, 0.12);
    border-color: rgba(212, 175, 55, 0.3);
    font-weight: 700;
}

.booster-stock-indicator {
    font-size: 0.78rem;
    color: #94a3b8;
    background: rgba(0, 0, 0, 0.35);
    padding: 4px 12px;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.booster-stock-indicator strong {
    color: #38bdf8;
}

.booster-price-row {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 14px;
}

.price-label {
    font-size: 0.78rem;
    color: #94a3b8;
    text-transform: uppercase;
}

.price-val {
    font-size: 1.35rem;
    font-weight: 800;
    color: #f1f5f9;
}

.price-val.gold-val {
    color: var(--gold-bright);
}

.price-val.mythic-val {
    color: #fbbf24;
    text-shadow: 0 0 12px rgba(251, 191, 36, 0.4);
}

.booster-action-group {
    width: 100%;
}

.booster-action-group .btn {
    padding: 12px;
    font-size: 0.95rem;
    font-weight: 700;
}

/* ==================== ARÈNE DE DÉBALLAGE EN DIRECT (CASERNE) ==================== */
.caserne-unboxing-arena {
    margin-top: 30px;
    padding: 24px;
    background: radial-gradient(circle at center, rgba(30, 24, 40, 0.98) 0%, rgba(10, 12, 18, 0.98) 100%);
    border: 2px solid var(--gold-primary);
    border-radius: 16px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7), 0 0 30px rgba(212, 175, 55, 0.2);
    position: relative;
    overflow: hidden;
    animation: arena-appear 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes arena-appear {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.arena-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    margin-bottom: 22px;
    flex-wrap: wrap;
    gap: 12px;
}

.arena-pill {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 1px;
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.35);
    padding: 2px 10px;
    border-radius: 12px;
    margin-bottom: 4px;
}

.arena-header h3 {
    margin: 0;
    font-size: 1.35rem;
    color: #f8fafc;
}

.arena-actions {
    display: flex;
    gap: 10px;
}

/* 3 Cartes Révélées */
.caserne-unboxed-cards-row {
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
    margin: 10px 0;
}

.caserne-unboxed-cards-row .unboxed-card-reveal {
    width: 280px;
    max-width: 100%;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    animation: card-reveal-flip 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) backwards;
}

.caserne-unboxed-cards-row .unboxed-card-reveal:hover {
    transform: translateY(-8px) scale(1.03);
}

@keyframes card-reveal-flip {
    0% { opacity: 0; transform: scale(0.6) rotateY(90deg); }
    100% { opacity: 1; transform: scale(1) rotateY(0deg); }
}

.caserne-unboxed-plate-wrapper {
    display: flex;
    justify-content: center;
    margin: 14px 0;
}

.caserne-unboxed-plate-wrapper .plate-img {
    max-width: 100%;
    border-radius: 12px;
    border: 2px solid var(--gold-primary);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

/* Taverne : Poker de Dés (The Witcher) */
.dice-poker-felt, .passe-dix-felt {
    background: radial-gradient(circle at center, #1b3a24 0%, #0c1c11 100%);
    border: 2px solid #2d5a38;
}
.dice-section {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-md);
    padding: 16px;
    margin-bottom: 16px;
}
.dice-section-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 0.9rem;
}
.dice-tray {
    display: flex;
    justify-content: center;
    gap: 14px;
}
.dice-box {
    width: 52px;
    height: 52px;
    background: #fdf6e2;
    color: #111;
    font-size: 1.8rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5), inset 0 0 4px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    user-select: none;
    transition: all 0.2s ease;
}
.dice-box.reroll-selected {
    outline: 3px solid #e74c3c;
    transform: translateY(-4px);
    box-shadow: 0 6px 14px rgba(231, 76, 60, 0.6);
}
.dice-reroll-hint {
    display: block;
    text-align: center;
    margin-top: 10px;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

/* Taverne : Passe-Dix (GoT) */
.passe-dix-arena {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 24px 0;
}
.passedix-dice-row {
    display: flex;
    gap: 20px;
}
.dice-box-lg {
    width: 70px;
    height: 70px;
    background: #fdf6e2;
    color: #111;
    font-size: 2.4rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.6);
}
.passedix-choices-row {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
}
.passedix-choice-btn {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    padding: 10px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    transition: all 0.2s ease;
}
.passedix-choice-btn.active {
    background: var(--gold-gradient);
    color: #0b0d14;
    font-weight: 700;
    border-color: var(--gold-bright);
}
.passedix-choice-btn.highlight { border-color: #9b59b6; }
.passedix-choice-btn.highlight.active { background: #9b59b6; color: #fff; }

/* Taverne : Coinflip Mode Switch */
.coinflip-mode-selector {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 20px;
}
.cf-mode-btn {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-secondary);
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.88rem;
    transition: all 0.2s ease;
}
.cf-mode-btn.active {
    background: var(--gold-primary);
    color: #0b0d14;
    font-weight: 700;
}

/* Modal Factions */
.modal-subtitle-sm {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin-bottom: 12px;
    line-height: 1.4;
}
.faction-modal-card {
    max-width: 780px;
    width: 95%;
}
.factions-modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 16px;
    margin-top: 14px;
}
.faction-opt-card {
    background: rgba(11, 13, 20, 0.85);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    position: relative;
}
.faction-opt-card.active-faction {
    border-color: var(--gold-primary);
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.15), rgba(11, 13, 20, 0.9));
}
.faction-opt-header {
    display: flex;
    align-items: center;
    gap: 12px;
}
.faction-opt-header h4 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 1.15rem;
}
.faction-opt-motto {
    font-style: italic;
    font-size: 0.82rem;
    color: var(--text-secondary);
}
.faction-opt-synergies {
    background: rgba(0, 0, 0, 0.4);
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.8rem;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/* ==================== ROUE DU DESTIN DU GARDE (CHIFOUMI) ==================== */
.rps-wheel-container {
    position: relative;
    width: 170px;
    height: 170px;
    margin: 6px auto 10px auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rps-wheel-needle {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1.4rem;
    color: var(--gold-bright);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.9), 0 2px 4px #000;
    z-index: 10;
    pointer-events: none;
    transition: transform 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.rps-wheel-needle.needle-tick {
    transform: translateX(-50%) rotate(-18deg);
}

.rps-wheel-canvas {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(0, 0, 0, 0.8), 0 0 10px rgba(212, 175, 55, 0.4);
    border: 3px solid #d4af37;
    background: #111;
    transform: rotate(0deg);
    transition: transform 0.05s linear;
}

.rps-wheel-hub {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: radial-gradient(circle, #f3d069 0%, #b8860b 70%, #5a4103 100%);
    border: 2px solid #fff;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: #fff;
    z-index: 5;
    pointer-events: none;
}

/* ==================== ROULETTE ROYALE DU GRAND CASINO ==================== */
.roulette-table-felt {
    background: radial-gradient(circle at center, #0f3d23 0%, #061c10 85%, #020b06 100%);
    border: 2px solid rgba(212, 175, 55, 0.4);
    box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.8), 0 10px 30px rgba(0, 0, 0, 0.6);
    border-radius: var(--radius-lg);
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.roulette-main-layout {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 28px;
    align-items: start;
    margin: 20px 0;
}

@media (max-width: 1100px) {
    .roulette-main-layout {
        grid-template-columns: 1fr;
        justify-items: center;
    }
}

.roulette-wheel-column {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.roulette-wheel-stage {
    position: relative;
    width: 340px;
    height: 340px;
    border-radius: 50%;
    background: radial-gradient(circle, #2b1d0c 0%, #150e05 60%, #0a0602 100%);
    box-shadow: 0 0 35px rgba(0, 0, 0, 0.9), inset 0 0 25px rgba(0, 0, 0, 0.95), 0 0 0 6px #5a3d16, 0 0 0 10px #2a1c09, 0 0 20px rgba(212, 175, 55, 0.3);
    padding: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.roulette-wheel-bezel {
    position: relative;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

#rouletteCanvas {
    width: 320px;
    height: 320px;
    border-radius: 50%;
    transform-origin: center center;
}

.roulette-center-turret {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: radial-gradient(circle, #ffe082 0%, #d4af37 50%, #8c6b12 85%, #423206 100%);
    border: 3px solid #fff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.8), inset 0 2px 5px rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.1rem;
    font-weight: bold;
    pointer-events: none;
    z-index: 10;
}

.roulette-stats-card {
    background: rgba(0, 0, 0, 0.55);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: var(--radius-md);
    padding: 12px 18px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.roulette-recent-title {
    font-family: var(--font-heading);
    font-size: 0.82rem;
    letter-spacing: 1px;
    color: var(--text-secondary);
    text-transform: uppercase;
}

.roulette-history-row {
    display: flex;
    gap: 8px;
    align-items: center;
}

.roulette-num-badge {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.roulette-num-badge.badge-red {
    background: linear-gradient(135deg, #e53935 0%, #b71c1c 100%);
    color: #fff;
}

.roulette-num-badge.badge-black {
    background: linear-gradient(135deg, #374151 0%, #111827 100%);
    color: #fff;
}

.roulette-num-badge.badge-green {
    background: linear-gradient(135deg, #10b981 0%, #047857 100%);
    color: #fff;
}

/* --- TAPIS DE MISES VERT ÉMERAUDE --- */
.roulette-board-column {
    display: flex;
    flex-direction: column;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
}

.roulette-felt-board {
    background: #08331a;
    border: 2px solid #d4af37;
    border-radius: 8px;
    padding: 10px;
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.7);
    user-select: none;
    min-width: 680px;
}

.roulette-grid-wrapper {
    display: flex;
    gap: 4px;
    margin-bottom: 4px;
}

.roulette-bet-cell {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: bold;
    color: #fff;
    transition: all 0.15s ease;
    border: 1px solid rgba(212, 175, 55, 0.4);
    box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.3);
}

.roulette-bet-cell:hover {
    filter: brightness(1.25);
    border-color: #ffd700;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.6);
    transform: translateY(-1px);
}

.roulette-bet-cell:active {
    transform: scale(0.97);
}

.cell-zero {
    width: 48px;
    background: linear-gradient(135deg, #10b981, #065f46);
    border-radius: 6px 0 0 6px;
    font-size: 1.4rem;
    font-family: var(--font-heading);
}

.roulette-numbers-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    grid-template-rows: repeat(3, 46px);
    gap: 3px;
    flex: 1;
}

.roulette-num-cell {
    font-size: 1.05rem;
    font-family: var(--font-heading);
}

.roulette-num-cell.cell-red {
    background: linear-gradient(135deg, #b71c1c 0%, #7f0000 100%);
    border-color: #ef5350;
}

.roulette-num-cell.cell-black {
    background: linear-gradient(135deg, #263238 0%, #10171a 100%);
    border-color: #78909c;
}

.roulette-cols-wrapper {
    display: flex;
    flex-direction: column;
    gap: 3px;
    width: 52px;
}

.cell-col {
    flex: 1;
    background: rgba(0, 0, 0, 0.4);
    font-size: 0.85rem;
}

.roulette-dozens-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    margin-left: 52px;
    margin-right: 56px;
    margin-bottom: 4px;
}

.cell-dozen {
    height: 38px;
    background: rgba(0, 0, 0, 0.45);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.roulette-outside-row {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 4px;
    margin-left: 52px;
    margin-right: 56px;
}

.cell-outside {
    height: 40px;
    background: rgba(0, 0, 0, 0.4);
    font-size: 0.85rem;
    text-transform: uppercase;
}

.cell-outside.cell-red {
    background: linear-gradient(135deg, #b71c1c, #7f0000);
}

.cell-outside.cell-black {
    background: linear-gradient(135deg, #263238, #10171a);
}

/* Jeton posé sur la feutrine */
.chip-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 24px;
    height: 24px;
    padding: 0 4px;
    border-radius: 12px;
    background: radial-gradient(circle, #ffe082 0%, #d4af37 60%, #8c6b12 100%);
    border: 2px dashed #ffffff;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.9), 0 0 8px rgba(255, 215, 0, 0.7);
    color: #000;
    font-size: 0.75rem;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    z-index: 5;
    animation: chipPop 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes chipPop {
    0% { transform: translate(-50%, -50%) scale(0.3); opacity: 0; }
    100% { transform: translate(-50%, -50%) scale(1); opacity: 1; }
}

.chip-badge.hidden {
    display: none !important;
}

.roulette-action-buttons {
    display: flex;
    gap: 10px;
    align-items: center;
    justify-content: flex-end;
    margin-top: 10px;
}

.roulette-outcome-banner {
    margin: 16px 0;
    padding: 14px 20px;
    border-radius: var(--radius-md);
    font-family: var(--font-heading);
    text-align: center;
    font-size: 1.15rem;
    animation: bannerFadeIn 0.3s ease-out;
}

.roulette-outcome-banner.win {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.25), rgba(6, 78, 59, 0.6));
    border: 1px solid #10b981;
    color: #6ee7b7;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
}

.roulette-outcome-banner.loss {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.25), rgba(153, 27, 27, 0.6));
    border: 1px solid #ef4444;
    color: #fca5a5;
}

.roulette-outcome-banner.tie {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.25), rgba(180, 83, 9, 0.6));
    border: 1px solid #f59e0b;
    color: #fde68a;
}

/* ==================== PROCHAIN RANG FÉODAL & PROFIL ==================== */
.profile-next-rank-card {
    width: 100%;
    background: linear-gradient(145deg, rgba(25, 20, 10, 0.75) 0%, rgba(10, 10, 15, 0.85) 100%);
    border: 1px solid rgba(212, 175, 55, 0.28);
    border-radius: var(--radius-sm);
    padding: 14px;
    margin-bottom: 18px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4), inset 0 0 15px rgba(212, 175, 55, 0.04);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.profile-next-rank-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold-bright, #ffd700), transparent);
}

.profile-next-rank-card:hover {
    border-color: rgba(212, 175, 55, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 6px 22px rgba(212, 175, 55, 0.15);
}

.next-rank-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    flex-wrap: wrap;
    gap: 6px;
}

.next-rank-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gold-bright, #f6e27a);
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 4px;
    padding: 2px 8px;
}

.next-rank-target {
    font-size: 0.72rem;
    color: var(--gold-primary, #d4af37);
    font-weight: 600;
    font-family: var(--font-mono);
}

.next-rank-title {
    font-family: var(--font-heading);
    font-size: 0.98rem;
    color: #fff;
    margin: 4px 0 6px 0;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0,0,0,0.6);
}

.next-rank-desc {
    font-size: 0.76rem;
    color: #c4c8d4;
    font-style: italic;
    line-height: 1.4;
    margin-bottom: 10px;
}

.next-rank-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.74rem;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.next-rank-levels {
    color: #6ee7b7;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.btn-roadmap {
    width: 100%;
    justify-content: center;
    font-size: 0.78rem;
    padding: 7px 12px;
    border-color: rgba(212, 175, 55, 0.35);
    background: rgba(212, 175, 55, 0.06);
    color: var(--gold-bright, #ffd700);
    transition: all 0.25s ease;
}

.btn-roadmap:hover {
    background: rgba(212, 175, 55, 0.18);
    border-color: var(--gold-bright, #ffd700);
    color: #fff;
}

/* ==================== MODAL FEUILLE DE ROUTE DES 35 RANGS ==================== */
.roadmap-modal-dialog {
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    background: linear-gradient(180deg, #13121b 0%, #0d0c13 100%);
    border: 1px solid rgba(212, 175, 55, 0.35);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.8), 0 0 30px rgba(212, 175, 55, 0.1);
    border-radius: var(--radius-md);
    overflow: hidden;
}

.roadmap-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(20, 18, 28, 0.6);
}

.roadmap-header-badge {
    font-size: 0.72rem;
    color: var(--gold-bright);
    letter-spacing: 0.1em;
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    margin-bottom: 4px;
}

.roadmap-modal-header h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: #fff;
    margin: 0 0 6px 0;
}

.roadmap-header-sub {
    font-size: 0.82rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.4;
}

.roadmap-filter-bar {
    display: flex;
    gap: 8px;
    padding: 12px 24px;
    background: rgba(10, 9, 15, 0.7);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    flex-wrap: wrap;
}

.roadmap-filter-btn {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.roadmap-filter-btn:hover {
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold-bright);
    border-color: rgba(212, 175, 55, 0.3);
}

.roadmap-filter-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25), rgba(246, 226, 122, 0.15));
    border-color: var(--gold-bright);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.25);
}

.roadmap-scroll-body {
    flex: 1;
    overflow-y: auto;
    padding: 18px 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.roadmap-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    background: rgba(18, 16, 26, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.25s ease;
    position: relative;
}

.roadmap-item:hover {
    background: rgba(24, 22, 34, 0.9);
}

/* Statuts de palier */
.roadmap-item.status-passed {
    border-left: 4px solid #10b981;
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.06) 0%, rgba(18, 16, 26, 0.6) 100%);
}

.roadmap-item.status-current {
    border-left: 4px solid var(--gold-bright);
    border-color: rgba(212, 175, 55, 0.5);
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.15) 0%, rgba(26, 22, 14, 0.8) 100%);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.15);
}

.roadmap-item.status-future {
    border-left: 4px solid #4b5563;
    opacity: 0.85;
}

.roadmap-lvl-pill {
    min-width: 72px;
    text-align: center;
    padding: 6px 10px;
    border-radius: 6px;
    font-family: var(--font-mono);
    font-size: 0.82rem;
    font-weight: 700;
}

.roadmap-item.status-passed .roadmap-lvl-pill {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

.roadmap-item.status-current .roadmap-lvl-pill {
    background: rgba(212, 175, 55, 0.25);
    border: 1px solid var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 10px rgba(246, 226, 122, 0.3);
}

.roadmap-item.status-future .roadmap-lvl-pill {
    background: rgba(75, 85, 99, 0.2);
    border: 1px solid rgba(75, 85, 99, 0.4);
    color: #9ca3af;
}

.roadmap-item-info {
    flex: 1;
}

.roadmap-title-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 4px;
    flex-wrap: wrap;
}

.roadmap-item-title {
    font-family: var(--font-heading);
    font-size: 1.02rem;
    color: #fff;
    margin: 0;
}

.roadmap-item.status-current .roadmap-item-title {
    color: var(--gold-bright);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.35);
}

.roadmap-state-badge {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-passed .roadmap-state-badge {
    background: rgba(16, 185, 129, 0.2);
    color: #6ee7b7;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-current .roadmap-state-badge {
    background: rgba(212, 175, 55, 0.25);
    color: var(--gold-bright);
    border: 1px solid var(--gold-bright);
    animation: pulseBadge 2s infinite ease-in-out;
}

.status-future .roadmap-state-badge {
    background: rgba(75, 85, 99, 0.25);
    color: #9ca3af;
    border: 1px solid rgba(75, 85, 99, 0.35);
}

@keyframes pulseBadge {
    0%, 100% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.4); }
    50% { box-shadow: 0 0 0 6px rgba(212, 175, 55, 0); }
}

.roadmap-item-desc {
    font-size: 0.8rem;
    color: #c4c8d4;
    font-style: italic;
    line-height: 1.4;
    margin: 0;
}

.roadmap-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(15, 13, 22, 0.8);
}

.roadmap-footer-hint {
    font-size: 0.78rem;
    color: var(--text-muted);
}

.roadmap-footer-hint code {
    background: rgba(255, 255, 255, 0.08);
    padding: 2px 6px;
    border-radius: 4px;
    color: var(--gold-primary);
}

/* ==================== TRIBUNAL LEVEL CHIPS ==================== */
.member-level-badge-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 6px 0;
    flex-wrap: wrap;
}

.member-level-chip {
    font-size: 0.74rem;
    font-family: var(--font-mono);
    font-weight: 700;
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.3);
    padding: 2px 8px;
    border-radius: 4px;
}

.member-rank-chip {
    font-size: 0.74rem;
    color: #e2e8f0;
    font-style: italic;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
}

/* ==================== CLASSEMENT NIVEAUX ==================== */
.levels-actions-bar {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

/* ==================== CODEX DES RÈGLES DE LA TAVERNE ROYALE ==================== */
.tavern-rules-dialog {
    max-width: 940px;
    width: 95%;
    background: radial-gradient(circle at top, rgba(28, 22, 14, 0.98) 0%, rgba(11, 13, 20, 0.99) 100%);
    border: 2px solid var(--gold-primary);
    box-shadow: 0 20px 80px rgba(0, 0, 0, 0.95), 0 0 30px rgba(212, 175, 55, 0.25);
    border-radius: 16px;
    padding: 24px 28px;
    color: #e2e8f0;
}

.tavern-rules-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    padding-bottom: 16px;
    margin-bottom: 18px;
}

.tavern-rules-badge {
    display: inline-block;
    font-size: 0.72rem;
    font-family: var(--font-heading);
    letter-spacing: 1.5px;
    font-weight: 700;
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.35);
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 6px;
}

.tavern-rules-header-title h3 {
    margin: 4px 0;
    font-family: var(--font-heading);
    font-size: 1.45rem;
    color: var(--gold-bright);
    text-shadow: 0 2px 10px rgba(212, 175, 55, 0.3);
}

.tavern-rules-subtitle {
    margin: 0;
    font-size: 0.88rem;
    color: rgba(226, 232, 240, 0.75);
}

/* Tabs de navigation du codex */
.tavern-rules-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.rules-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(212, 175, 55, 0.2);
    color: rgba(226, 232, 240, 0.8);
    font-family: var(--font-heading);
    font-size: 0.88rem;
    font-weight: 600;
    padding: 9px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.rules-tab-btn:hover {
    background: rgba(212, 175, 55, 0.12);
    color: var(--gold-bright);
    border-color: rgba(212, 175, 55, 0.4);
}

.rules-tab-btn.active {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.25) 0%, rgba(138, 98, 14, 0.35) 100%);
    border-color: var(--gold-bright);
    color: var(--gold-bright);
    box-shadow: 0 0 14px rgba(212, 175, 55, 0.3);
}

.rules-tab-icon {
    font-size: 1.1rem;
}

/* Corps des règles */
.tavern-rules-body {
    max-height: 58vh;
    overflow-y: auto;
    padding-right: 8px;
}

.rules-section {
    display: none;
    animation: fadeIn 0.25s ease-out;
}

.rules-section.active {
    display: block;
}

/* Bannière d'en-tête de jeu */
.rules-hero {
    display: flex;
    align-items: center;
    gap: 16px;
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.12) 0%, rgba(255, 255, 255, 0.02) 100%);
    border-left: 4px solid var(--gold-primary);
    border-radius: 8px;
    padding: 14px 18px;
    margin-bottom: 18px;
}

.rules-hero-icon {
    font-size: 2.2rem;
    flex-shrink: 0;
}

.rules-hero-text h4 {
    margin: 0 0 4px 0;
    font-family: var(--font-heading);
    font-size: 1.15rem;
    color: var(--gold-bright);
}

.rules-hero-text p {
    margin: 0;
    font-size: 0.88rem;
    color: rgba(226, 232, 240, 0.85);
    line-height: 1.45;
}

/* Grilles & Cartes */
.rules-grid-2col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.rules-grid-3col {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.rules-card {
    background: rgba(18, 20, 32, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.rules-card-title {
    margin: 0 0 10px 0;
    font-family: var(--font-heading);
    font-size: 0.96rem;
    color: var(--gold-bright);
    display: flex;
    align-items: center;
    gap: 6px;
}

.rules-list, .rules-ordered-list {
    margin: 0;
    padding-left: 20px;
    font-size: 0.86rem;
    color: rgba(226, 232, 240, 0.85);
    line-height: 1.6;
}

.rules-list li, .rules-ordered-list li {
    margin-bottom: 6px;
}

.rules-text {
    margin: 0;
    font-size: 0.86rem;
    line-height: 1.55;
    color: rgba(226, 232, 240, 0.85);
}

.rules-payout-box {
    margin-top: 12px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 8px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.88rem;
}

.rules-payout-box.highlight {
    background: rgba(212, 175, 55, 0.15);
    border-color: rgba(212, 175, 55, 0.4);
    box-shadow: 0 0 12px rgba(212, 175, 55, 0.2);
}

/* Tableaux de règles et gains */
.rules-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    text-align: left;
    margin-top: 6px;
}

.rules-table th {
    background: rgba(212, 175, 55, 0.12);
    color: var(--gold-bright);
    font-family: var(--font-heading);
    font-weight: 700;
    padding: 10px 12px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.25);
    letter-spacing: 0.5px;
}

.rules-table td {
    padding: 9px 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: rgba(226, 232, 240, 0.9);
}

.rules-table tr:hover td {
    background: rgba(255, 255, 255, 0.03);
}

/* Badges de résultats */
.badge-gold {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(212, 175, 55, 0.2);
    border: 1px solid rgba(212, 175, 55, 0.45);
    color: var(--gold-bright);
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-mythic {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.5);
    color: #fca5a5;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-purple {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(168, 85, 247, 0.2);
    border: 1px solid rgba(168, 85, 247, 0.45);
    color: #d8b4fe;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-green {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(34, 197, 94, 0.2);
    border: 1px solid rgba(34, 197, 94, 0.45);
    color: #86efac;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-blue {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(59, 130, 246, 0.2);
    border: 1px solid rgba(59, 130, 246, 0.45);
    color: #93c5fd;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-red {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(225, 29, 72, 0.2);
    border: 1px solid rgba(225, 29, 72, 0.45);
    color: #fda4af;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-black {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(148, 163, 184, 0.35);
    color: #cbd5e1;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

.badge-silver {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: rgba(148, 163, 184, 0.2);
    border: 1px solid rgba(148, 163, 184, 0.4);
    color: #e2e8f0;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.78rem;
}

/* Schéma Chifoumi Royal */
.rps-trinity-display {
    display: flex;
    align-items: center;
    justify-content: space-around;
    gap: 12px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px dashed rgba(212, 175, 55, 0.3);
    border-radius: 10px;
    padding: 16px;
    margin-top: 6px;
}

.rps-trinity-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 4px;
}

.rps-trinity-icon {
    font-size: 2rem;
}

.rps-trinity-item strong {
    font-family: var(--font-heading);
    color: var(--gold-bright);
    font-size: 0.95rem;
}

.rps-trinity-item span {
    font-size: 0.76rem;
    color: rgba(226, 232, 240, 0.7);
}

.rps-trinity-arrow {
    font-size: 1.4rem;
    color: var(--gold-primary);
    opacity: 0.7;
}

/* Pied du modal */
.tavern-rules-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(212, 175, 55, 0.25);
    padding-top: 14px;
    margin-top: 18px;
    flex-wrap: wrap;
    gap: 12px;
}

.tavern-rules-seal {
    font-size: 0.78rem;
    color: rgba(226, 232, 240, 0.65);
    font-style: italic;
}

.mt-12 {
    margin-top: 12px;
}

/* Adaptation Mobile */
@media (max-width: 768px) {
    .rules-grid-2col, .rules-grid-3col {
        grid-template-columns: 1fr;
    }
    .tavern-rules-dialog {
        padding: 16px;
    }
    .tavern-rules-tabs {
        gap: 6px;
    }
    .rules-tab-btn {
        padding: 7px 12px;
        font-size: 0.8rem;
    }
    .felt-header {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .felt-header-titles {
        align-items: center;
        text-align: center;
    }
    .btn-felt-rules {
        align-self: center;
    }
}

/* ========================================================
   DONJON DES OUBLIETTES — 50 ÉTAGES & 10 AILES THÉMATIQUES
   ======================================================== */
.dungeon-biomes-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 8px 4px 14px;
    margin-bottom: 12px;
    scrollbar-width: thin;
    scrollbar-color: var(--gold-primary) rgba(15, 23, 42, 0.6);
}

.dungeon-biomes-nav::-webkit-scrollbar {
    height: 6px;
}
.dungeon-biomes-nav::-webkit-scrollbar-thumb {
    background: var(--gold-primary);
    border-radius: 4px;
}

.biome-tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: 20px;
    color: #cbd5e1;
    padding: 8px 16px;
    font-family: var(--font-cinzel);
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.biome-tab-btn:hover {
    border-color: var(--gold-bright);
    color: #fff;
    background: rgba(30, 41, 59, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 4px 14px rgba(229, 184, 66, 0.15);
}

.biome-tab-btn.active {
    border-color: var(--gold-primary);
    background: linear-gradient(135deg, rgba(229, 184, 66, 0.25) 0%, rgba(15, 23, 42, 0.95) 100%);
    color: var(--gold-bright);
    box-shadow: 0 0 16px rgba(229, 184, 66, 0.35);
}

.biome-tab-btn.locked-biome {
    opacity: 0.6;
    border-color: rgba(148, 163, 184, 0.2);
}

.biome-tab-btn small {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-left: 4px;
}

.biome-info-banner {
    margin: 8px 0 18px;
    animation: fadeIn 0.3s ease;
}

.biome-banner-card {
    background: linear-gradient(135deg, rgba(26, 22, 40, 0.9) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1px solid rgba(168, 85, 247, 0.35);
    border-radius: 12px;
    padding: 14px 18px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}

.biome-banner-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

.biome-banner-title {
    font-family: var(--font-cinzel);
    font-weight: 800;
    color: var(--gold-bright);
    font-size: 1.05rem;
}

.biome-affix-badge {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.45);
    color: #fca5a5;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.78rem;
    font-weight: 700;
}

.biome-banner-desc {
    font-size: 0.85rem;
    color: #cbd5e1;
    margin-bottom: 10px;
    line-height: 1.4;
}

.biome-banner-rules {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.rule-chip {
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.78rem;
    line-height: 1.3;
}

.rule-chip.hostile {
    background: rgba(220, 38, 38, 0.15);
    border: 1px solid rgba(220, 38, 38, 0.35);
    color: #fca5a5;
}

.rule-chip.weakness {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.35);
    color: #6ee7b7;
}

/* CARTE D'ÉTAGE DU DONJON ENRICHIE */
.floor-card {
    position: relative;
    background: linear-gradient(165deg, rgba(23, 28, 43, 0.95) 0%, rgba(16, 20, 32, 0.98) 100%);
    border: 1px solid rgba(229, 184, 66, 0.2);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.6);
}

.floor-card:hover {
    transform: translateY(-4px);
    border-color: var(--gold-primary);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.8), 0 0 16px rgba(229, 184, 66, 0.2);
}

.floor-card.is-biome-boss {
    border: 2px solid #f59e0b !important;
    background: linear-gradient(165deg, rgba(38, 28, 14, 0.95) 0%, rgba(20, 16, 10, 0.98) 100%) !important;
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.35) !important;
}

.floor-boss-crest-badge {
    position: absolute;
    top: -10px;
    right: 14px;
    background: linear-gradient(135deg, #f59e0b 0%, #b45309 100%);
    color: #000;
    font-weight: 900;
    font-size: 0.65rem;
    padding: 3px 9px;
    border-radius: 6px;
    letter-spacing: 0.6px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
    z-index: 2;
}

.floor-biome-tag {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--gold-primary);
    background: rgba(229, 184, 66, 0.1);
    padding: 2px 7px;
    border-radius: 4px;
    margin-left: 6px;
}

.floor-affix-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px dashed rgba(229, 184, 66, 0.35);
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 0.74rem;
    color: #cbd5e1;
}

.floor-affix-pill .affix-ico {
    font-size: 0.85rem;
}

.floor-affix-pill .affix-name {
    font-weight: 700;
    color: var(--gold-bright);
}

.floor-tactical-banner {
    padding: 6px 9px;
    border-radius: 6px;
    font-size: 0.72rem;
    line-height: 1.3;
}

.floor-tactical-banner.tactical-advantaged {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.4);
    color: #6ee7b7;
}

.floor-tactical-banner.tactical-neutral {
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.25);
    color: #fde68a;
}

.tactical-status-line {
    font-weight: 700;
    margin-bottom: 2px;
}

.tactical-faille-line {
    font-size: 0.68rem;
    opacity: 0.9;
}

/* BANNIÈRE DE CLIMAT DANS L'ARÈNE */
.battle-climate-banner {
    margin: 8px 0 12px;
}

.climate-banner-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 0.82rem;
    flex-wrap: wrap;
}

.climate-banner-inner.climate-advantaged {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1px solid rgba(16, 185, 129, 0.45);
    color: #6ee7b7;
}

.climate-banner-inner.climate-hostile {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.2) 0%, rgba(15, 23, 42, 0.95) 100%);
    border: 1px solid rgba(239, 68, 68, 0.45);
    color: #fca5a5;
}

.climate-status-tag {
    font-weight: 800;
    font-size: 0.78rem;
}

/* ==========================================================================
   SACOCHE DES PIERRES D'AMÉLIORATION DU DONJON & NOUVELLE FORGE (+25)
   ========================================================================== */
.forge-stones-bar {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(30, 27, 46, 0.9) 100%);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 22px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.forge-stones-header,
.stones-bar-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 10px;
}

.stones-title-group,
.stones-head-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.stones-header-icon {
    font-size: 1.8rem;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
}

.stones-title-group h4,
.stones-head-title h4 {
    margin: 0;
    font-family: var(--font-heading, inherit);
    font-size: 1.05rem;
    color: #f1f5f9;
    letter-spacing: 0.5px;
}

.stones-title-group p,
.stones-head-title p {
    margin: 2px 0 0;
    font-size: 0.78rem;
    color: #94a3b8;
}

.stones-exclusive-badge {
    background: linear-gradient(135deg, #7c3aed 0%, #4f46e5 100%);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(124, 58, 237, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.forge-stones-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
}

.stone-pill-card {
    background: rgba(11, 15, 25, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.stone-pill-card:hover {
    transform: translateY(-2px);
    border-color: rgba(212, 175, 55, 0.4);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.stone-pill-card .stone-icon {
    font-size: 1.4rem;
    flex-shrink: 0;
}

.stone-pill-card .stone-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.stone-pill-card .stone-name {
    font-size: 0.78rem;
    font-weight: 700;
    color: #e2e8f0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.stone-tier-badge {
    font-size: 0.65rem;
    color: #38bdf8;
    font-weight: 600;
    margin-top: 2px;
}

.stone-tier-badge.tier-2 {
    color: #ec4899;
}

.stone-pill-card .stone-qty {
    font-size: 1.15rem;
    font-weight: 800;
    color: #facc15;
    background: rgba(250, 204, 21, 0.1);
    padding: 2px 8px;
    border-radius: 6px;
    border: 1px solid rgba(250, 204, 21, 0.25);
    min-width: 32px;
    text-align: center;
}

/* Badge de doublons sur les cartes de râtelier */
.gear-card-footer-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    margin-top: 4px;
}

.gear-dup-badge {
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.25) 0%, rgba(202, 138, 4, 0.4) 100%);
    color: #fef08a;
    border: 1px solid rgba(234, 179, 8, 0.5);
    padding: 2px 7px;
    border-radius: 12px;
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.btn-gold-shimmer {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #b45309 100%);
    color: #0b0d14 !important;
    font-weight: 800 !important;
    border: 1px solid #fde68a !important;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.35);
    transition: all 0.2s ease;
}

.btn-gold-shimmer:hover {
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #d97706 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(245, 158, 11, 0.5);
}

/* Jauge de progression continue jusqu'à +25 */
.forge-progression-bar-container {
    position: relative;
    height: 12px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    margin: 18px 0 14px;
    overflow: visible;
}

.forge-progression-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6 0%, #8b5cf6 50%, #f59e0b 100%);
    border-radius: 10px;
    transition: width 0.4s ease;
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.5);
}

.forge-milestone-marker {
    position: absolute;
    top: -5px;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.forge-milestone-marker.marker-10 { left: 40%; }
.forge-milestone-marker.marker-20 { left: 80%; }
.forge-milestone-marker.marker-25 { left: 100%; }

.forge-milestone-marker .milestone-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #1e293b;
    border: 2px solid #64748b;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.forge-milestone-marker.reached .milestone-dot {
    background: #f59e0b;
    border-color: #fef08a;
    box-shadow: 0 0 10px rgba(245, 158, 11, 0.8);
}

.forge-milestone-marker .milestone-label {
    font-size: 0.65rem;
    font-weight: 800;
    color: #94a3b8;
    margin-top: 6px;
    white-space: nowrap;
}

.forge-milestone-marker.reached .milestone-label {
    color: #fde68a;
}

/* Conditions de fusion : Carte d'état */
.forge-requirements-card {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 12px 16px;
    margin: 14px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.forge-req-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.forge-req-row .req-icon-box {
    font-size: 1.3rem;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    flex-shrink: 0;
}

.forge-req-row .req-text-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.forge-req-row .req-label {
    font-size: 0.72rem;
    color: #94a3b8;
}

.forge-req-row strong {
    font-size: 0.82rem;
    color: #f1f5f9;
}

.forge-req-row .req-badge {
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.72rem;
    font-weight: 700;
    white-space: nowrap;
}

.req-badge.badge-success {
    background: rgba(16, 185, 129, 0.2);
    color: #6ee7b7;
    border: 1px solid rgba(16, 185, 129, 0.4);
}

.req-badge.badge-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.req-badge.badge-neutral {
    background: rgba(148, 163, 184, 0.15);
    color: #cbd5e1;
    border: 1px solid rgba(148, 163, 184, 0.3);
}

/* ==========================================================================
   ARÈNE : TOURNOI FÉODAL & CARTELS DE DÉFI (FACE-À-FACE)
   ========================================================================== */
.feudal-jousting-arena {
    background: linear-gradient(135deg, #131722 0%, #1c1527 100%);
    border: 2px solid rgba(212, 175, 55, 0.45);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 28px;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.arena-pvp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.25);
    flex-wrap: wrap;
}

.pvp-banner-crest {
    font-size: 2.2rem;
    filter: drop-shadow(0 2px 8px rgba(220, 38, 38, 0.5));
}

.pvp-banner-info {
    flex: 1;
    min-width: 240px;
}

.arena-pill-badge {
    display: inline-block;
    background: rgba(220, 38, 38, 0.2);
    border: 1px solid rgba(220, 38, 38, 0.4);
    color: #fca5a5;
    font-size: 0.72rem;
    font-weight: 800;
    padding: 2px 10px;
    border-radius: 12px;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.pvp-banner-info h3 {
    margin: 0;
    font-family: var(--font-heading, inherit);
    font-size: 1.35rem;
    color: #f8fafc;
}

.pvp-banner-info p {
    margin: 4px 0 0;
    font-size: 0.84rem;
    color: #94a3b8;
    line-height: 1.4;
}

.arena-tabs-switcher {
    display: flex;
    gap: 6px;
    background: rgba(15, 23, 42, 0.8);
    padding: 4px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.arena-subtab-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
}

.arena-subtab-btn:hover {
    color: #f1f5f9;
    background: rgba(255, 255, 255, 0.05);
}

.arena-subtab-btn.active {
    background: var(--gold-primary, #d4af37);
    color: #0b0d14;
    font-weight: 800;
    box-shadow: 0 2px 8px rgba(212, 175, 55, 0.4);
}

.badge-crimson-pulse {
    background: #ef4444;
    color: #fff;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 800;
    animation: crimson-pulse 1.8s infinite;
}

@keyframes crimson-pulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.15); opacity: 0.8; }
    100% { transform: scale(1); opacity: 1; }
}

/* Plateau Face-à-Face des Seigneurs */
.pvp-faceoff-stage {
    display: grid;
    grid-template-columns: 1fr 180px 1fr;
    gap: 20px;
    margin-top: 22px;
    align-items: stretch;
}

@media (max-width: 900px) {
    .pvp-faceoff-stage {
        grid-template-columns: 1fr;
    }
}

.pvp-fighter-box {
    background: rgba(15, 23, 42, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.player-fighter-box {
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: inset 0 0 16px rgba(59, 130, 246, 0.1);
}

.opponent-fighter-box {
    border-color: rgba(239, 68, 68, 0.4);
    box-shadow: inset 0 0 16px rgba(239, 68, 68, 0.1);
}

.fighter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-bottom: 8px;
}

.fighter-role-tag {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #94a3b8;
}

.fighter-name {
    font-size: 0.95rem;
    color: #f1f5f9;
}

.fighter-trio-preview {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 140px;
    justify-content: center;
}

.faceoff-card-chip {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(11, 15, 25, 0.8);
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.faceoff-card-chip .chip-avatar {
    font-size: 1.4rem;
}

.faceoff-card-chip .chip-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.faceoff-card-chip .chip-name {
    font-size: 0.82rem;
    color: #e2e8f0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.faceoff-card-chip .chip-stats {
    font-size: 0.72rem;
    color: #94a3b8;
}

.fighter-power-badge {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #93c5fd;
    padding: 6px 12px;
    border-radius: 8px;
    text-align: center;
    font-size: 0.82rem;
    margin-top: auto;
}

/* Centre : VS Divider & Enjeu */
.pvp-versus-divider {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 0;
}

.vs-emblem {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: radial-gradient(circle, #dc2626 0%, #7f1d1d 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 900;
    letter-spacing: 1px;
    border: 2px solid #fecaca;
    box-shadow: 0 0 20px rgba(220, 38, 38, 0.6);
}

.vs-stake-selector {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.vs-stake-label {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #facc15;
}

.stake-amount-input {
    text-align: center;
    font-size: 1.15rem;
    font-weight: 800;
    color: #facc15;
    background: rgba(11, 15, 25, 0.9);
    border: 1px solid rgba(250, 204, 21, 0.4);
    border-radius: 8px;
    padding: 8px 12px;
    width: 100%;
}

.quick-wager-chips {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    width: 100%;
}

.wager-chip {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #cbd5e1;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.wager-chip:hover {
    background: rgba(250, 204, 21, 0.15);
    border-color: #facc15;
    color: #fef08a;
}

.wager-chip.active {
    background: #facc15;
    color: #0b0d14;
    font-weight: 800;
    border-color: #fef08a;
}

/* Carte de prévisualisation adversaire */
.target-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
    padding: 30px 14px;
    color: #64748b;
    font-size: 0.82rem;
}

.placeholder-icon {
    font-size: 2.2rem;
    opacity: 0.6;
}

.opponent-hero-profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 10px;
    padding: 16px 10px;
    background: rgba(11, 15, 25, 0.6);
    border-radius: 10px;
}

.opponent-avatar-wrap {
    position: relative;
    width: 64px;
    height: 64px;
}

.opponent-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #ef4444;
    object-fit: cover;
}

.opponent-avatar-placeholder {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #334155;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    border: 2px solid #ef4444;
}

.opponent-status-dot.online {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 12px;
    height: 12px;
    background: #22c55e;
    border: 2px solid #0f172a;
    border-radius: 50%;
}

.opponent-hero-info h4 {
    margin: 0;
    font-size: 1.05rem;
    color: #f1f5f9;
}

.opponent-role-tag {
    font-size: 0.72rem;
    color: #94a3b8;
}

.opponent-ready-banner {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
}

/* Cri de guerre & lancement */
.pvp-warcry-section {
    background: rgba(15, 23, 42, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 18px;
    margin-top: 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.warcry-input-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.warcry-label-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.warcry-quick-presets {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.preset-cry-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #94a3b8;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.preset-cry-btn:hover {
    background: rgba(220, 38, 38, 0.2);
    border-color: #ef4444;
    color: #fca5a5;
}

.warcry-input {
    background: rgba(11, 15, 25, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    padding: 10px 14px;
    color: #f1f5f9;
    font-size: 0.88rem;
    width: 100%;
}

.pvp-launch-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.corbeau-notice {
    flex: 1;
    min-width: 240px;
    color: #94a3b8;
    font-size: 0.78rem;
}

.btn-joust-launch {
    padding: 12px 28px !important;
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 16px rgba(220, 38, 38, 0.45);
}

/* Liste des Cartels Reçus */
.pending-challenges-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 14px;
}

.no-challenges-card {
    background: rgba(15, 23, 42, 0.5);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 36px 20px;
    text-align: center;
}

.no-challenges-card .empty-icon {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 8px;
}

.no-challenges-card h4 {
    margin: 0 0 6px;
    color: #f1f5f9;
}

.no-challenges-card p {
    margin: 0;
    color: #94a3b8;
    font-size: 0.84rem;
}

.pending-challenge-card {
    background: linear-gradient(135deg, rgba(19, 23, 34, 0.95) 0%, rgba(30, 20, 35, 0.95) 100%);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    padding: 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.challenge-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.challenger-identity {
    display: flex;
    align-items: center;
    gap: 12px;
}

.challenger-avatar-img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid #d4af37;
}

.challenger-avatar-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #1e293b;
    border: 2px solid #d4af37;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
}

.challenge-label {
    font-size: 0.68rem;
    font-weight: 800;
    color: #d4af37;
    letter-spacing: 0.5px;
}

.challenger-name {
    margin: 2px 0;
    font-size: 1.1rem;
    color: #f8fafc;
}

.challenge-date {
    font-size: 0.72rem;
    color: #94a3b8;
}

.challenge-stake-pill {
    background: rgba(250, 204, 21, 0.12);
    border: 1px solid rgba(250, 204, 21, 0.35);
    padding: 6px 14px;
    border-radius: 8px;
    text-align: right;
}

.challenge-stake-pill .stake-title {
    font-size: 0.68rem;
    color: #94a3b8;
    display: block;
}

.challenge-stake-pill .stake-val {
    font-size: 1.1rem;
    color: #facc15;
}

.challenge-warcry-quote {
    background: rgba(11, 13, 20, 0.75);
    border-left: 3px solid #d4af37;
    border-radius: 6px;
    padding: 10px 14px;
    display: flex;
    gap: 8px;
    align-items: flex-start;
}

.challenge-warcry-quote .quote-mark {
    font-size: 1.3rem;
    color: #d4af37;
    line-height: 1;
}

.challenge-warcry-quote .quote-text {
    margin: 0;
    font-style: italic;
    font-size: 0.88rem;
    color: #e2e8f0;
}

.challenge-card-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 10px;
}

/* Historique des Défis */
.history-challenge-row {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 8px;
}

.history-challenge-row .hist-icon {
    font-size: 1.4rem;
}

.history-challenge-row .hist-details {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.history-challenge-row .hist-title {
    font-size: 0.88rem;
    color: #f1f5f9;
}

.history-challenge-row .hist-meta {
    font-size: 0.74rem;
    color: #94a3b8;
}

/* Modal Résultat de Duel PvP */
.duel-result-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e1b2e 100%);
    border: 2px solid var(--gold-primary, #d4af37);
    border-radius: 16px;
    max-width: 620px;
    width: 95%;
    padding: 24px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.7);
}

.duel-result-header {
    text-align: center;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.25);
}

.duel-result-emblem {
    font-size: 3.5rem;
    display: block;
    margin-bottom: 8px;
    filter: drop-shadow(0 4px 12px rgba(212, 175, 55, 0.5));
}

.duel-result-header h2 {
    margin: 0;
    font-family: var(--font-heading, inherit);
    font-size: 1.5rem;
    color: #f8fafc;
}

.duel-result-header p {
    margin: 6px 0 0;
    font-size: 0.88rem;
    color: #94a3b8;
}

.duel-stakes-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin: 18px 0;
}

.stake-pill-box {
    background: rgba(11, 15, 25, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 10px;
    text-align: center;
}

.stake-pill-box .label {
    display: block;
    font-size: 0.7rem;
    color: #94a3b8;
    margin-bottom: 2px;
}

.stake-pill-box strong {
    font-size: 1.15rem;
    font-weight: 800;
}

.stake-pill-box.gold-gain strong { color: #facc15; }
.stake-pill-box.gold-loss strong { color: #ef4444; }
.stake-pill-box.elo-gain strong { color: #22c55e; }
.stake-pill-box.elo-loss strong { color: #ef4444; }

.duel-combat-log-pane {
    background: rgba(11, 13, 20, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    padding: 14px;
    margin-bottom: 18px;
}

.duel-combat-log-pane h5 {
    margin: 0 0 10px;
    color: #e2e8f0;
    font-size: 0.84rem;
}

.duel-combat-log-list {
    max-height: 180px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 0.78rem;
    line-height: 1.4;
    color: #cbd5e1;
}

.duel-log-entry {
    padding: 4px 8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 4px;
}

.duel-log-entry.crit {
    color: #facc15;
    background: rgba(250, 204, 21, 0.1);
    font-weight: 700;
}

.duel-log-entry.faint {
    color: #f87171;
    background: rgba(239, 68, 68, 0.1);
    font-weight: 700;
}

/* ==========================================================================
   MODULES MODERNISÉS : ÉQUIPEMENT FORGE, PUISSANCE DONJON, DÉBALLAGE X10 & MOBILE
   ========================================================================== */

/* 1. Équipement et transfert de cartes à la Forge Royale */
.forge-assign-controls {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed rgba(255, 255, 255, 0.12);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.forge-assign-sublabel {
    font-size: 0.78rem;
    color: #94a3b8;
    font-weight: 600;
}

.forge-assign-row {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.forge-card-select {
    flex: 1;
    min-width: 180px;
    background: rgba(11, 15, 25, 0.95);
    border: 1px solid rgba(212, 175, 55, 0.4);
    color: #f1f5f9;
    padding: 7px 10px;
    border-radius: 8px;
    font-size: 0.82rem;
}

.btn-equip-item {
    font-weight: 700 !important;
    white-space: nowrap;
    padding: 7px 14px !important;
}

.btn-unequip-item {
    white-space: nowrap;
    padding: 7px 12px !important;
}

/* 2. Badge de Puissance Recommandée des Étages de Donjon */
.floor-power-recommendation-bar {
    background: rgba(11, 15, 25, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    padding: 7px 10px;
    margin: 8px 0;
    display: flex;
    flex-direction: column;
    gap: 5px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    overflow: hidden;
}

.floor-power-recommendation-bar.diff-favorable {
    border-color: rgba(34, 197, 94, 0.45);
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.12) 0%, rgba(11, 15, 25, 0.92) 100%);
}

.floor-power-recommendation-bar.diff-balanced {
    border-color: rgba(234, 179, 8, 0.45);
    background: linear-gradient(135deg, rgba(234, 179, 8, 0.12) 0%, rgba(11, 15, 25, 0.92) 100%);
}

.floor-power-recommendation-bar.diff-perilous {
    border-color: rgba(239, 68, 68, 0.45);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.14) 0%, rgba(11, 15, 25, 0.92) 100%);
}

.rec-power-main-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.rec-power-label {
    font-size: 0.74rem;
    color: #cbd5e1;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

.rec-power-num {
    font-size: 0.88rem;
    font-weight: 800;
    color: #facc15;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.rec-power-sub-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    width: 100%;
}

.rec-diff-badge {
    font-size: 0.65rem;
    font-weight: 800;
    padding: 2px 7px;
    border-radius: 10px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.rec-diff-badge.diff-favorable {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
    border: 1px solid rgba(34, 197, 94, 0.4);
}

.rec-diff-badge.diff-balanced {
    background: rgba(234, 179, 8, 0.2);
    color: #fde047;
    border: 1px solid rgba(234, 179, 8, 0.4);
}

.rec-diff-badge.diff-perilous {
    background: rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    border: 1px solid rgba(239, 68, 68, 0.4);
}

.rec-player-compare-txt {
    font-size: 0.68rem;
    color: #94a3b8;
    white-space: nowrap;
}

.rec-player-compare-txt strong {
    color: #f1f5f9;
}

/* Bannière Trio de Guerre Déployé dans le Donjon */
.dungeon-trio-summary-banner {
    background: linear-gradient(135deg, rgba(22, 27, 46, 0.95) 0%, rgba(13, 16, 28, 0.98) 100%);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    margin-bottom: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 14px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.dungeon-trio-summary-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
    min-width: 280px;
}

.dungeon-trio-title-wrap {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.dungeon-trio-badge {
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: var(--gold-bright);
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.35);
    padding: 3px 9px;
    border-radius: var(--radius-pill);
}

.dungeon-trio-power-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(250, 204, 21, 0.35);
    padding: 3px 10px;
    border-radius: var(--radius-pill);
}

.dungeon-trio-power-indicator .power-label {
    font-size: 0.76rem;
    color: #cbd5e1;
    font-weight: 600;
}

.dungeon-trio-power-indicator .power-value {
    font-size: 0.95rem;
    color: #facc15;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.dungeon-trio-chips-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.dungeon-trio-card-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 5px 10px;
    min-width: 140px;
}

.dungeon-trio-card-chip .chip-thumb {
    width: 32px;
    height: 32px;
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    object-fit: cover;
}

.dungeon-trio-card-chip .chip-details {
    display: flex;
    flex-direction: column;
}

.dungeon-trio-card-chip .chip-name {
    font-size: 0.76rem;
    font-weight: 700;
    color: #f8fafc;
    white-space: nowrap;
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.dungeon-trio-card-chip .chip-stats {
    font-size: 0.68rem;
    color: #94a3b8;
}

.dungeon-trio-summary-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

/* Actions rapides dans la boîte Défi Arène */
.fighter-quick-trio-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    width: 100%;
}

.fighter-quick-trio-actions .btn {
    flex: 1;
    font-size: 0.76rem;
    padding: 6px 10px;
    justify-content: center;
}

/* Modal de Sélection Rapide du Trio */
.quick-deck-dialog {
    background: #0f121d !important;
    border: 1.5px solid rgba(212, 175, 55, 0.45) !important;
    border-radius: var(--radius-lg);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.8), 0 0 24px rgba(212, 175, 55, 0.2);
}

.quick-deck-header {
    border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    padding: 16px 20px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.quick-deck-badge {
    font-size: 0.7rem;
    font-weight: 800;
    color: var(--gold-bright);
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

.quick-deck-header h3 {
    margin: 4px 0 2px 0;
    font-family: var(--font-heading);
    color: #f8fafc;
    font-size: 1.25rem;
}

.quick-deck-subtitle {
    margin: 0;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.quick-deck-body {
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-height: 75vh;
    overflow-y: auto;
}

.quick-deck-slots-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.quick-deck-slot-card {
    background: rgba(17, 24, 39, 0.7);
    border: 1.5px dashed rgba(212, 175, 55, 0.35);
    border-radius: var(--radius-md);
    padding: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 140px;
    justify-content: center;
}

.quick-deck-slot-card:hover {
    border-color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.05);
}

.quick-deck-slot-card.active-slot {
    border-style: solid;
    border-color: var(--gold-bright);
    background: rgba(229, 184, 66, 0.1);
    box-shadow: 0 0 14px rgba(212, 175, 55, 0.3);
}

.quick-deck-slot-card.has-card {
    border-style: solid;
    border-color: rgba(212, 175, 55, 0.5);
    background: rgba(17, 24, 39, 0.9);
}

.quick-deck-slot-header {
    font-size: 0.68rem;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--gold-bright);
    margin-bottom: 6px;
}

.quick-deck-slot-card .slot-thumb {
    width: 48px;
    height: 48px;
    border-radius: 6px;
    border: 1.5px solid var(--gold-primary);
    object-fit: cover;
    margin-bottom: 6px;
}

.quick-deck-slot-card .slot-card-name {
    font-size: 0.8rem;
    font-weight: 700;
    color: #f8fafc;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.quick-deck-slot-card .slot-card-power {
    font-size: 0.72rem;
    color: #facc15;
    font-weight: 800;
}

.quick-deck-slot-card .btn-slot-remove {
    position: absolute;
    top: 6px;
    right: 6px;
    background: rgba(239, 68, 68, 0.25);
    border: 1px solid rgba(239, 68, 68, 0.5);
    color: #fca5a5;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    cursor: pointer;
}

.quick-deck-slot-empty-icon {
    font-size: 1.8rem;
    opacity: 0.4;
    margin-bottom: 6px;
}

.quick-deck-power-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 10px 14px;
    border-radius: var(--radius-md);
    font-size: 0.88rem;
}

.quick-deck-collection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 4px;
}

.quick-deck-collection-header h4 {
    margin: 0;
    font-size: 0.92rem;
    color: #cbd5e1;
}

.quick-deck-cards-picker {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(135px, 1fr));
    gap: 10px;
    max-height: 260px;
    overflow-y: auto;
    padding-right: 4px;
}

.picker-card-item {
    background: rgba(17, 24, 39, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
    transition: all 0.18s ease;
    position: relative;
}

.picker-card-item:hover {
    border-color: var(--gold-bright);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

.picker-card-item.is-selected {
    border-color: #22c55e;
    background: rgba(34, 197, 94, 0.1);
}

.picker-card-item .card-badge-in-deck {
    position: absolute;
    top: 4px;
    left: 4px;
    background: #22c55e;
    color: #000;
    font-size: 0.6rem;
    font-weight: 800;
    padding: 1px 4px;
    border-radius: 4px;
}

.picker-card-item .picker-card-thumb {
    width: 44px;
    height: 44px;
    border-radius: 4px;
    object-fit: cover;
    margin-bottom: 5px;
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.picker-card-item .picker-card-name {
    font-size: 0.74rem;
    font-weight: 700;
    color: #f1f5f9;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    margin-bottom: 2px;
}

.picker-card-item .picker-card-pwr {
    font-size: 0.68rem;
    color: #facc15;
    font-weight: 800;
}

.quick-deck-footer {
    border-top: 1px solid rgba(212, 175, 55, 0.2);
    padding: 14px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.quick-deck-tip {
    font-size: 0.74rem;
    color: var(--text-muted);
}

.quick-deck-footer-actions {
    display: flex;
    gap: 10px;
}

/* 3. Déballage de Boosters en Lot x10 */
.unboxed-batch-container {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
}

.unboxed-batch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: 10px;
    padding: 12px 18px;
}

.unboxed-batch-stats {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.batch-stat-chip {
    font-size: 0.76rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.batch-stat-chip.mythic {
    background: rgba(220, 38, 38, 0.25);
    border-color: #ef4444;
    color: #fca5a5;
}

.batch-stat-chip.legendary {
    background: rgba(234, 179, 8, 0.25);
    border-color: #facc15;
    color: #fef08a;
}

.batch-stat-chip.epic {
    background: rgba(168, 85, 247, 0.25);
    border-color: #a855f7;
    color: #e9d5ff;
}

.unboxed-batch-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 14px;
    max-height: 68vh;
    overflow-y: auto;
    padding: 4px;
}

/* 4. Optimisation Mobile Complète (Élimination des chevauchements) */
@media (max-width: 900px) {
    .realm-tabs-bar {
        display: flex;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 6px;
        padding-bottom: 4px;
    }
    .realm-tabs-bar::-webkit-scrollbar {
        display: none;
    }
    .realm-tab {
        flex-shrink: 0;
        white-space: nowrap;
        padding: 8px 14px;
        font-size: 0.85rem;
    }

    .sub-tabs-realm {
        display: none !important;
    }
    .sub-tabs-realm.active {
        display: flex !important;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 6px;
        padding: 4px 0;
    }
    .sub-tabs-realm.active::-webkit-scrollbar {
        display: none;
    }
    .sub-tabs-realm .nav-tab {
        flex-shrink: 0;
        white-space: nowrap;
        padding: 6px 12px;
        font-size: 0.8rem;
    }
}

@media (max-width: 768px) {
    /* Élimination des deux menus sur mobile : Masquage du gros menu PC et affichage du sélecteur compact */
    .realm-tabs-bar {
        display: none !important;
    }
    .mobile-realm-selector-bar {
        display: flex !important;
    }
    .sub-tabs-realm {
        display: none !important;
    }
    .sub-tabs-realm.active {
        display: flex !important;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        gap: 6px;
        padding: 4px 0;
    }
    .sub-tabs-realm .nav-tab {
        flex-shrink: 0;
        white-space: nowrap;
        padding: 7px 14px;
        font-size: 0.82rem;
    }

    /* Bourse en liquide & modules féodaux : aucun débordement */
    .feudal-wallet-bar {
        grid-template-columns: 1fr !important;
        gap: 10px;
    }
    .feudal-wallet-pill {
        flex-wrap: wrap;
        padding: 12px 14px;
        gap: 10px;
        min-width: 0;
        overflow: hidden;
    }
    .feudal-wallet-pill .wallet-icon {
        font-size: 1.6rem;
    }
    .feudal-wallet-pill .wallet-info {
        flex: 1 1 calc(100% - 46px);
        min-width: 0;
    }
    .wallet-label-row {
        flex-wrap: wrap;
        gap: 4px;
        margin-bottom: 4px;
        min-width: 0;
    }
    .wallet-label-row .wallet-label {
        font-size: 0.75rem;
    }
    .wallet-risk-tag {
        font-size: 0.65rem;
    }
    .feudal-wallet-pill .btn-quick-dep {
        width: 100%;
        flex-basis: 100%;
        text-align: center;
        padding: 8px 12px;
        margin-top: 4px;
        font-size: 0.8rem;
        box-sizing: border-box;
    }

    .feudal-stations-grid {
        grid-template-columns: 1fr !important;
        gap: 16px;
    }
    .feudal-station-card {
        padding: 16px 14px;
    }
    .bank-tabs {
        flex-direction: column;
        gap: 6px;
    }
    .bank-tab-btn {
        width: 100%;
        text-align: center;
        padding: 8px 10px;
        font-size: 0.8rem;
    }
    .bank-account-tabs {
        flex-direction: column;
        gap: 6px;
    }
    .bank-acc-tab {
        width: 100%;
        text-align: center;
    }

    .pvp-faceoff-stage {
        display: flex;
        flex-direction: column;
        gap: 16px;
    }

    .pvp-versus-divider {
        order: 2;
        width: 100%;
        margin: 10px 0;
    }

    .player-fighter-box {
        order: 1;
        width: 100%;
    }

    .opponent-fighter-box {
        order: 3;
        width: 100%;
    }

    .quick-wager-chips {
        grid-template-columns: repeat(3, 1fr);
        gap: 6px;
    }

    .wager-chip {
        padding: 8px 4px;
        font-size: 0.8rem;
        min-height: 38px;
    }

    .pvp-launch-row {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-joust-launch {
        width: 100%;
        justify-content: center;
    }

    .forge-content-layout {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }

    .forge-gear-grid {
        max-height: 400px;
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .forge-stones-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

@media (max-width: 600px) {
    .royal-header {
        padding: 10px 12px;
    }

    .header-container {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }

    .brand-wrapper {
        justify-content: center;
        text-align: center;
    }

    .brand-titles .main-title {
        font-size: 1.3rem;
        letter-spacing: 1px;
    }

    .brand-titles .sub-title {
        font-size: 0.7rem;
    }

    .header-right-side {
        justify-content: center;
        gap: 8px;
        width: 100%;
    }

    .user-auth-pill {
        flex: 1;
        justify-content: space-between;
        padding: 5px 10px;
    }

    .caserne-packs-showcase {
        grid-template-columns: 1fr;
    }

    .arena-floors-grid {
        grid-template-columns: 1fr;
    }

    .floor-power-recommendation-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .rec-power-value-box {
        width: 100%;
        justify-content: space-between;
    }

    .unboxed-batch-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 8px;
    }

    .modal-content,
    .modal-dialog {
        width: 95vw !important;
        max-width: 95vw !important;
        margin: 10px auto;
        padding: 14px;
    }

    .warcry-label-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .warcry-quick-presets {
        display: flex;
        flex-wrap: wrap;
        gap: 4px;
        width: 100%;
    }

    .preset-cry-btn {
        flex: 1;
        min-width: 90px;
        text-align: center;
        padding: 6px 4px;
    }
}

/* ========================================================
   FEUDAL ENDGAME, FIEF, CRAFT & CASTLES ENHANCEMENTS
   ======================================================== */

/* 1. Header Season & Weather Pill */
.season-weather-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.85), rgba(15, 23, 42, 0.95));
    border: 1px solid rgba(147, 197, 253, 0.35);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    color: #e2e8f0;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: default;
}
.season-weather-pill:hover {
    border-color: rgba(229, 184, 66, 0.6);
    box-shadow: 0 6px 20px rgba(229, 184, 66, 0.2);
    transform: translateY(-1px);
}
.season-weather-pill .season-sep {
    color: rgba(255, 255, 255, 0.3);
    margin: 0 2px;
}
.season-weather-pill .season-name {
    color: #93c5fd;
}
.season-weather-pill .weather-name {
    color: #fcd34d;
}

/* 2. Fief Moulin & Grain Silo */
.fief-moulin-box {
    background: linear-gradient(135deg, rgba(20, 24, 38, 0.9), rgba(13, 16, 28, 0.95));
    border: 1px solid rgba(229, 184, 66, 0.3);
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 20px;
    box-shadow: inset 0 0 15px rgba(229, 184, 66, 0.05);
}
.fief-moulin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}
.moulin-title-info {
    display: flex;
    align-items: center;
    gap: 12px;
}
.moulin-ico {
    font-size: 2rem;
    filter: drop-shadow(0 2px 6px rgba(229, 184, 66, 0.4));
}
.moulin-title-info strong {
    font-size: 1.05rem;
    color: #f7e7b4;
    display: block;
}
.moulin-title-info p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    margin: 2px 0 0;
}
.moulin-stock-track {
    width: 100%;
    height: 12px;
    background: rgba(10, 12, 20, 0.8);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 8px;
}
.moulin-stock-fill {
    height: 100%;
    background: linear-gradient(90deg, #d97706, #fbbf24, #f59e0b);
    border-radius: 8px;
    transition: width 0.5s ease;
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}
.moulin-stock-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.8);
}

/* 3. 4 Bâtiments du Fief */
.fief-buildings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}
.fief-bldg-card {
    background: rgba(18, 22, 34, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 12px;
    transition: all 0.3s ease;
}
.fief-bldg-card:hover {
    border-color: rgba(229, 184, 66, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transform: translateY(-2px);
}
.bldg-top {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
.bldg-ico {
    font-size: 1.8rem;
    line-height: 1;
}
.bldg-meta {
    flex: 1;
}
.bldg-name-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}
.bldg-name-row strong {
    font-size: 0.95rem;
    color: #e2e8f0;
}
.bldg-perk {
    display: block;
    font-size: 0.78rem;
    color: #94a3b8;
    line-height: 1.3;
}

/* 4. Expéditions AFK */
.fief-expeditions-section {
    background: rgba(15, 18, 28, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 18px;
}
.fief-exp-header h4 {
    margin: 0 0 4px;
    font-size: 1.05rem;
    color: #f7e7b4;
}
.exp-sub {
    font-size: 0.8rem;
    color: #94a3b8;
    display: block;
    margin-bottom: 14px;
}
.fief-active-exp-box {
    margin-bottom: 16px;
}
.fief-exp-empty {
    padding: 16px;
    text-align: center;
    font-size: 0.85rem;
    color: #64748b;
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}
.fief-active-exp-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.fief-active-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(24, 30, 48, 0.9);
    border: 1px solid rgba(229, 184, 66, 0.25);
    border-radius: 10px;
    padding: 10px 14px;
}
.fief-dispatch-box {
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    padding-top: 14px;
}
.fief-dispatch-box h5 {
    margin: 0 0 10px;
    font-size: 0.9rem;
    color: #cbd5e1;
}
.fief-dispatch-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* 5. Crafting & Alchemy Station */
.craft-bag-box {
    background: rgba(18, 22, 34, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}
.craft-bag-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}
.craft-materials-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.mat-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(30, 41, 59, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 0.82rem;
    color: #e2e8f0;
}
.mat-chip.has-qty {
    border-color: rgba(52, 211, 153, 0.4);
    background: rgba(16, 185, 129, 0.1);
}
.craft-recipes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}
.craft-recipe-card {
    background: rgba(18, 22, 34, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 12px;
    transition: all 0.3s ease;
}
.craft-recipe-card:hover {
    border-color: rgba(244, 63, 94, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
}
.craft-recipe-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.craft-recipe-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #f7e7b4;
}
.craft-recipe-desc {
    font-size: 0.8rem;
    color: #94a3b8;
    line-height: 1.3;
}
.craft-ingredients-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 0.78rem;
}
.craft-ing-row {
    display: flex;
    justify-content: space-between;
    color: #cbd5e1;
}
.craft-ing-row.missing {
    color: #f87171;
}
.craft-ing-row.ok {
    color: #4ade80;
}
.craft-dismantle-box {
    background: rgba(18, 22, 34, 0.85);
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: 12px;
    padding: 16px;
}
.dismantle-header {
    display: flex;
    gap: 12px;
    align-items: center;
    margin-bottom: 12px;
}
.dismantle-ico {
    font-size: 2rem;
}
.dismantle-form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}
.dismantle-preview-badge {
    font-size: 0.82rem;
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.1);
    padding: 8px 12px;
    border-radius: 8px;
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* 6. Castles & Territory War */
.ruling-suzerain-card {
    background: linear-gradient(135deg, rgba(229, 184, 66, 0.15), rgba(15, 23, 42, 0.9));
    border: 1px solid rgba(229, 184, 66, 0.4);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}
.suzerain-crest {
    font-size: 2.4rem;
}
.suzerain-details h4 {
    margin: 0 0 4px;
    font-size: 1.1rem;
    color: #fbbf24;
}
.suzerain-details p {
    margin: 0;
    font-size: 0.85rem;
    color: #cbd5e1;
}
.castles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
}
.castle-card {
    background: rgba(18, 22, 34, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 14px;
    transition: all 0.3s ease;
}
.castle-card:hover {
    border-color: rgba(229, 184, 66, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transform: translateY(-2px);
}
.castle-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.castle-name-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}
.castle-ico {
    font-size: 1.8rem;
}
.castle-name {
    font-size: 1rem;
    font-weight: 700;
    color: #f7e7b4;
}
.castle-lore {
    font-size: 0.8rem;
    color: #94a3b8;
    line-height: 1.35;
}
.castle-perk {
    font-size: 0.8rem;
    color: #fbbf24;
    font-weight: 600;
}
.castle-def-track {
    width: 100%;
    height: 10px;
    background: rgba(10, 12, 20, 0.8);
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin: 6px 0 4px;
}
.castle-def-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 6px;
    transition: width 0.4s ease;
}
.castle-actions-row {
    display: flex;
    gap: 8px;
}

/* 7. World Boss Raid Banner */
.world-boss-raid-banner {
    background: linear-gradient(135deg, rgba(35, 14, 20, 0.95), rgba(15, 18, 30, 0.95));
    border: 2px solid rgba(225, 29, 72, 0.5);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 24px;
    box-shadow: 0 10px 30px rgba(225, 29, 72, 0.2);
    position: relative;
    overflow: hidden;
}
.boss-raid-top {
    display: flex;
    gap: 20px;
    align-items: center;
}
.boss-portrait-wrap {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 14px;
    overflow: hidden;
    border: 2px solid rgba(244, 63, 94, 0.6);
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.6);
}
.boss-raid-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.boss-element-tag {
    position: absolute;
    bottom: 4px;
    left: 4px;
    background: rgba(0, 0, 0, 0.75);
    border: 1px solid rgba(244, 63, 94, 0.6);
    padding: 2px 6px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    color: #fca5a5;
}
.boss-raid-details {
    flex: 1;
}
.boss-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}
.boss-sub {
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #f43f5e;
}
.boss-name {
    font-size: 1.4rem;
    margin: 0 0 6px;
    color: #ffe4e6;
    text-shadow: 0 2px 8px rgba(244, 63, 94, 0.5);
}
.boss-lore {
    font-size: 0.82rem;
    color: #cbd5e1;
    margin: 0 0 12px;
    line-height: 1.35;
}
.boss-hp-section {
    margin-bottom: 12px;
}
.boss-hp-meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.82rem;
    margin-bottom: 4px;
    color: #f1f5f9;
}
.boss-hp-track {
    width: 100%;
    height: 14px;
    background: rgba(10, 12, 20, 0.9);
    border: 1px solid rgba(244, 63, 94, 0.4);
    border-radius: 8px;
    overflow: hidden;
}
.boss-hp-fill {
    height: 100%;
    background: linear-gradient(90deg, #be123c, #f43f5e, #fb7185);
    border-radius: 8px;
    transition: width 0.5s ease;
    box-shadow: 0 0 12px rgba(244, 63, 94, 0.7);
}
.boss-actions-row {
    display: flex;
    align-items: center;
    gap: 12px;
}
.btn-boss-attack {
    background: linear-gradient(135deg, #e11d48, #be123c);
    color: #fff;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(225, 29, 72, 0.4);
    cursor: pointer;
    transition: all 0.2s ease;
}
.btn-boss-attack:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(225, 29, 72, 0.6);
}
.boss-attack-note {
    font-size: 0.78rem;
    color: #94a3b8;
}
.boss-podium-box {
    margin-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 10px;
}
.boss-podium-header {
    font-size: 0.8rem;
    color: #fcd34d;
    font-weight: 700;
    margin-bottom: 6px;
}
.boss-top-dps-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.dps-pill {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid rgba(229, 184, 66, 0.3);
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 0.78rem;
    color: #e2e8f0;
}

/* ==================== 5b. FORGE D'ARMES SUR-MESURE & JOYAUX ==================== */
.custom-weapon-station {
    border: 1px solid rgba(229, 184, 66, 0.35) !important;
    background: linear-gradient(180deg, rgba(20, 24, 38, 0.85) 0%, rgba(13, 16, 27, 0.95) 100%) !important;
}

.custom-forge-builder-box,
.custom-weapons-arsenal-box,
.gear-smelting-box {
    background: rgba(15, 20, 32, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px 20px;
    margin-bottom: 20px;
}

.builder-header,
.smelting-header,
.arsenal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.builder-ico,
.smelting-ico {
    font-size: 1.8rem;
    background: rgba(229, 184, 66, 0.12);
    border-radius: 12px;
    padding: 8px 12px;
    border: 1px solid rgba(229, 184, 66, 0.25);
}

.section-sublabel {
    display: block;
    font-size: 0.85rem;
    color: #cbd5e1;
    font-weight: 700;
    margin-bottom: 8px;
}

.archetypes-selector-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.archetype-choice-card {
    background: rgba(20, 28, 48, 0.7);
    border: 1.5px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px 12px;
    cursor: pointer;
    transition: all 0.25s ease;
    text-align: center;
}

.archetype-choice-card:hover {
    border-color: rgba(229, 184, 66, 0.5);
    transform: translateY(-2px);
    background: rgba(30, 42, 70, 0.8);
}

.archetype-choice-card.selected {
    border-color: #f59e0b;
    box-shadow: 0 0 16px rgba(245, 158, 11, 0.35);
    background: rgba(36, 45, 75, 0.95);
}

.arch-icon {
    font-size: 1.8rem;
    margin-bottom: 4px;
    display: block;
}

.arch-name {
    font-size: 0.82rem;
    font-weight: 700;
    color: #f1f5f9;
    display: block;
    margin-bottom: 2px;
}

.arch-stats {
    font-size: 0.72rem;
    color: #94a3b8;
    line-height: 1.25;
}

.forge-custom-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

@media (max-width: 768px) {
    .forge-custom-form-grid {
        grid-template-columns: 1fr;
    }
}

.forge-cost-and-action-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    flex-wrap: wrap;
}

.forge-cost-preview {
    font-size: 0.85rem;
    color: #cbd5e1;
}

.custom-weapons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 14px;
}

.custom-weapon-card {
    background: rgba(18, 24, 38, 0.8);
    border: 1.5px solid rgba(229, 184, 66, 0.3);
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.3);
    transition: all 0.25s ease;
}

.custom-weapon-card:hover {
    border-color: rgba(229, 184, 66, 0.6);
    box-shadow: 0 8px 24px rgba(229, 184, 66, 0.2);
}

.custom-weapon-card.rarity-mythic {
    border-color: #ef4444;
    box-shadow: 0 0 16px rgba(239, 68, 68, 0.3);
}

.custom-weapon-card.rarity-legendary {
    border-color: #f59e0b;
    box-shadow: 0 0 16px rgba(245, 158, 11, 0.25);
}

.custom-weapon-card.rarity-epic {
    border-color: #a855f7;
    box-shadow: 0 0 16px rgba(168, 85, 247, 0.25);
}

.cw-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.cw-title {
    font-size: 0.95rem;
    font-weight: 800;
    color: #f1f5f9;
}

.cw-stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
    font-size: 0.78rem;
    color: #cbd5e1;
}

.cw-stat-chip {
    background: rgba(255, 255, 255, 0.06);
    padding: 3px 8px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.socket-slots-row {
    display: flex;
    gap: 8px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.socket-slot-pill {
    flex: 1;
    background: rgba(255, 255, 255, 0.04);
    border: 1px dashed rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.socket-slot-pill.filled {
    border-style: solid;
    border-color: rgba(229, 184, 66, 0.4);
    background: rgba(229, 184, 66, 0.08);
}

.smelting-form-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.smelting-preview-badge {
    font-size: 0.78rem;
    color: #94a3b8;
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 12px;
    border-radius: 8px;
}

/* ==================== MOBILE PWA DOCK BAR ==================== */
.mobile-dock-bar {
    display: none;
}

@media (max-width: 768px) {
    body {
        padding-bottom: 74px !important;
    }

    .mobile-dock-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 64px;
        background: rgba(11, 12, 16, 0.94);
        backdrop-filter: blur(14px);
        -webkit-backdrop-filter: blur(14px);
        border-top: 1px solid rgba(212, 175, 55, 0.35);
        box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.7);
        z-index: 9999;
        justify-content: space-around;
        align-items: center;
        padding: 0 8px;
    }

    .mobile-dock-item {
        background: transparent;
        border: none;
        color: #94a3b8;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 3px;
        padding: 6px 12px;
        cursor: pointer;
        border-radius: 10px;
        transition: all 0.2s ease;
        flex: 1;
        max-width: 72px;
    }

    .mobile-dock-item .dock-icon {
        font-size: 1.35rem;
        transition: transform 0.2s ease;
    }

    .mobile-dock-item .dock-label {
        font-size: 0.7rem;
        font-weight: 600;
        letter-spacing: 0.3px;
    }

    .mobile-dock-item:hover,
    .mobile-dock-item.active {
        color: #f6e27a;
    }

    .mobile-dock-item.active {
        background: rgba(212, 175, 55, 0.12);
        box-shadow: inset 0 0 12px rgba(212, 175, 55, 0.15);
    }

    .mobile-dock-item.active .dock-icon {
        transform: scale(1.18);
    }
}

/* ==================== LIVE KINGDOM TICKER ==================== */
.kingdom-live-ticker {
    max-width: 1400px;
    margin: 12px auto 6px;
    padding: 8px 16px;
    background: rgba(14, 16, 24, 0.88);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.5), inset 0 0 16px rgba(212, 175, 55, 0.05);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    overflow: hidden;
    position: relative;
}

.ticker-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(212, 175, 55, 0.15);
    border: 1px solid rgba(212, 175, 55, 0.45);
    color: #f6e27a;
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    padding: 4px 10px;
    border-radius: 20px;
    white-space: nowrap;
    text-transform: uppercase;
}

.ticker-pulse-dot {
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    box-shadow: 0 0 8px #ef4444;
    animation: tickerPulse 1.6s infinite ease-in-out;
}

@keyframes tickerPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.75); }
}

.ticker-content-track {
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    height: 24px;
    display: flex;
    align-items: center;
}

.ticker-item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.88rem;
    color: #e2e8f0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.ticker-item-icon {
    font-size: 1.05rem;
}

.ticker-item-badge {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #f6e27a;
    font-size: 0.7rem;
    padding: 1px 6px;
    border-radius: 4px;
    font-weight: 600;
}

.ticker-item-text {
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 900px;
}

.ticker-refresh-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #94a3b8;
    padding: 4px 8px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 0.85rem;
}

.ticker-refresh-btn:hover {
    color: #f6e27a;
    border-color: rgba(212, 175, 55, 0.4);
    transform: rotate(90deg);
}





