/**
 * Zarnia Staff Dashboard - Custom Theme, Glow FX & Mobile-First Adaptation
 * Dark modern design with neon cyan / electric blue accents
 */

:root {
    --color-bg-dark: #0b1120;
    --color-card-dark: #131c31;
    --color-border-dark: #1e293b;
    --neon-cyan: #2563eb;
    --neon-cyan-glow: transparent;
    --neon-blue: #1d4ed8;
    --neon-blue-glow: transparent;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #0b1120;
}

::-webkit-scrollbar-thumb {
    background: #273549;
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
    background: #334155;
}

/* Flat Design Utilities (zero glow / zero blur) */
.glow-cyan,
.glow-cyan-sm,
.glow-blue,
.glow-red {
    box-shadow: none;
}

.glow-text-cyan {
    text-shadow: none;
}

/* Flat Solid Cards */
.glass-panel {
    background: #131c31;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 1px solid #1e293b;
}

.glass-card {
    background: #131c31;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 1px solid #1e293b;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.glass-card:hover {
    border-color: #2563eb;
    background: #18223a;
    transform: none;
    box-shadow: none;
}

/* Flat Background (no radial mesh) */
.bg-radial-mesh {
    background-color: #0b1120;
    background-image: none;
}

/* Status Pulse Animation */
@keyframes pulseGlow {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        filter: drop-shadow(0 0 4px #00f0ff);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.95);
        filter: drop-shadow(0 0 1px #00f0ff);
    }
}

.animate-pulse-glow {
    animation: pulseGlow 2.5s infinite ease-in-out;
}

/* Skeleton Loading Animation */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.skeleton {
    background: linear-gradient(90deg, #111827 25%, #1f2937 50%, #111827 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* Micro-transitions */
.transition-smooth {
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Sanction Type Badges */
.badge-ban {
    background: rgba(239, 68, 68, 0.12);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.badge-kick {
    background: rgba(249, 115, 22, 0.12);
    color: #fb923c;
    border: 1px solid rgba(249, 115, 22, 0.25);
}

.badge-mute {
    background: rgba(234, 179, 8, 0.12);
    color: #facc15;
    border: 1px solid rgba(234, 179, 8, 0.25);
}

.badge-warn {
    background: rgba(59, 130, 246, 0.12);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.25);
}

.badge-unban, .badge-unmute {
    background: rgba(16, 185, 129, 0.12);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.25);
}

/* Modal Backdrop Blur */
.modal-backdrop {
    background-color: rgba(3, 7, 18, 0.78);
    backdrop-filter: blur(8px);
}

/* Discord Live Embed Preview Box */
.discord-embed-preview {
    background-color: #2b2d31;
    border-left: 4px solid #ef4444;
    border-radius: 6px;
    padding: 14px 16px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

/* ========================================================
   CUSTOM STYLED SELECT DROPDOWNS & INTERACTIVE SELECTORS
   ======================================================== */
select, .custom-select {
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    background-color: #0c1222 !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2300f0ff' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 14px center !important;
    background-size: 14px !important;
    padding-right: 40px !important;
    border: 1px solid rgba(51, 65, 85, 0.7) !important;
    border-radius: 14px !important;
    color: #f1f5f9 !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

select:hover, .custom-select:hover {
    border-color: rgba(0, 240, 255, 0.45) !important;
    background-color: #0f172a !important;
    box-shadow: 0 0 16px -2px rgba(0, 240, 255, 0.2) !important;
}

select:focus, .custom-select:focus {
    border-color: #00f0ff !important;
    outline: none !important;
    background-color: #0f172a !important;
    box-shadow: 0 0 0 3px rgba(0, 240, 255, 0.2), 0 0 20px -2px rgba(0, 240, 255, 0.35) !important;
}

select option {
    background-color: #070a13 !important;
    color: #f1f5f9 !important;
    padding: 12px 14px !important;
    font-size: 13px !important;
    font-weight: 500 !important;
}

select option:checked {
    background-color: #0e1e38 !important;
    color: #00f0ff !important;
    font-weight: 700 !important;
}

/* Custom interactive sanction type card buttons */
.sanction-type-pill {
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
}

.sanction-type-pill:hover {
    transform: translateY(-1.5px);
}

.sanction-type-pill.active {
    box-shadow: 0 0 16px -1px var(--active-glow, rgba(0, 240, 255, 0.4));
    border-color: var(--active-border, #00f0ff) !important;
}

/* Mobile responsive drawer animations */
#main-sidebar {
    will-change: transform;
}

/* ========================================================
   OPTIMISATION MOBILE COMPLÈTE (TÉLÉPHONES & TABLETTES)
   ======================================================== */
@media (max-width: 767px) {
    /* Espacement en bas pour la barre de navigation mobile fixe */
    #main-content-area {
        padding-bottom: 5.5rem !important;
    }

    #toast-container {
        bottom: 4.75rem !important;
        right: 0.75rem !important;
        left: 0.75rem !important;
        max-width: none !important;
        width: auto !important;
    }

    /* Transformation automatique des tableaux en cartes tactiles sur téléphone */
    table.responsive-table,
    table.responsive-table tbody,
    table.responsive-table tr,
    table.responsive-table td {
        display: block;
        width: 100%;
    }

    table.responsive-table thead {
        display: none;
    }

    table.responsive-table tbody tr {
        margin-bottom: 0.75rem;
        border: 1px solid rgba(51, 65, 85, 0.55) !important;
        border-radius: 1rem;
        background: rgba(15, 23, 42, 0.75);
        padding: 0.75rem 0.9rem;
        box-shadow: 0 6px 16px -4px rgba(0, 0, 0, 0.35);
    }

    table.responsive-table tbody td {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.75rem;
        padding: 0.45rem 0 !important;
        border-bottom: 1px solid rgba(51, 65, 85, 0.25);
        text-align: right;
    }

    table.responsive-table tbody td:last-child {
        border-bottom: none;
        padding-top: 0.65rem !important;
    }

    table.responsive-table tbody td::before {
        content: attr(data-label);
        font-size: 10px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        color: #94a3b8;
        text-align: left;
        flex-shrink: 0;
    }

    /* Boutons et contrôles plus faciles à toucher sur mobile */
    .mobile-touch-btn {
        min-height: 42px;
        padding-top: 0.6rem !important;
        padding-bottom: 0.6rem !important;
    }

    input[type="text"],
    input[type="date"],
    input[type="password"],
    textarea,
    select {
        font-size: 14px !important;
        min-height: 42px;
    }
}
