/* Ravana Mailer Pro - Cosmic Divine Theme
   Palette: Gold (#d4af37), Fiery Red/Orange (#ff6b35, #e63946),
            Deep Blue (#1a237e, #0d1b3e), Neon Blue (#00d4ff, #4fc3f7)
            Dark cosmic background (#0a0a1a, #0d0d1f)
*/

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

:root {
    /* Core brand colors from logo */
    --gold: #d4af37;
    --gold-bright: #ffd700;
    --gold-deep: #b8860b;
    --fire: #ff6b35;
    --fire-deep: #e63946;
    --ember: #ff4500;
    --deep-blue: #1a237e;
    --neon-blue: #00d4ff;
    --neon-glow: #4fc3f7;
    --cosmic-dark: #0a0a1a;
    --cosmic-darker: #050510;
    --cosmid-mid: #0d0d1f;
    --panel-bg: rgba(15, 15, 35, 0.85);
    --panel-border: rgba(212, 175, 55, 0.25);

    /* Semantic */
    --primary-color: var(--gold);
    --secondary-color: var(--neon-blue);
    --success-color: #00e676;
    --danger-color: #ff3d56;
    --warning-color: var(--fire);
    --info-color: var(--neon-glow);

    /* Text */
    --dark-text: #f0f0f8;
    --light-text: #9ca3c4;
    --text-secondary: #9ca3c4;

    /* Surfaces */
    --light-bg: var(--cosmic-dark);
    --bg-white: rgba(15, 15, 35, 0.7);
    --border-color: rgba(212, 175, 55, 0.15);

    /* Shadows with cosmic glow */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.7);
    --glow-gold: 0 0 20px rgba(212, 175, 55, 0.3), 0 0 40px rgba(255, 107, 53, 0.15);
    --glow-neon: 0 0 15px rgba(0, 212, 255, 0.4), 0 0 30px rgba(0, 212, 255, 0.2);
    --glow-fire: 0 0 20px rgba(255, 107, 53, 0.4), 0 0 40px rgba(230, 57, 70, 0.2);

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--cosmic-darker);
    color: var(--dark-text);
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
}

/* =========================================================================
   ANIMATED COSMIC BACKGROUND — matches logo's dark space + fiery aura
   ========================================================================= */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 30%, rgba(255, 107, 53, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(212, 175, 55, 0.06) 0%, transparent 45%),
        radial-gradient(ellipse at 50% 80%, rgba(26, 35, 126, 0.12) 0%, transparent 55%),
        radial-gradient(ellipse at 90% 60%, rgba(0, 212, 255, 0.05) 0%, transparent 40%),
        var(--cosmic-darker);
    z-index: -3;
    animation: cosmicShift 20s ease-in-out infinite alternate;
}

@keyframes cosmicShift {
    0% { filter: hue-rotate(0deg); }
    100% { filter: hue-rotate(15deg); }
}

/* Floating star/particle layer */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        radial-gradient(1px 1px at 15% 25%, rgba(212, 175, 55, 0.6), transparent),
        radial-gradient(1px 1px at 45% 60%, rgba(255, 255, 255, 0.4), transparent),
        radial-gradient(2px 2px at 70% 35%, rgba(0, 212, 255, 0.5), transparent),
        radial-gradient(1px 1px at 85% 75%, rgba(212, 175, 55, 0.5), transparent),
        radial-gradient(1px 1px at 30% 80%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(1.5px 1.5px at 60% 15%, rgba(255, 107, 53, 0.4), transparent),
        radial-gradient(1px 1px at 90% 45%, rgba(255, 255, 255, 0.3), transparent),
        radial-gradient(1px 1px at 10% 55%, rgba(0, 212, 255, 0.4), transparent),
        radial-gradient(1px 1px at 55% 90%, rgba(212, 175, 55, 0.3), transparent),
        radial-gradient(1px 1px at 75% 10%, rgba(255, 255, 255, 0.4), transparent);
    background-size: 100% 100%;
    z-index: -2;
    animation: twinkle 4s ease-in-out infinite alternate;
}

@keyframes twinkle {
    0% { opacity: 0.4; }
    100% { opacity: 0.9; }
}

/* =========================================================================
   HEADER — golden aura, glowing logo, 3D depth
   ========================================================================= */
.header {
    background: linear-gradient(135deg, rgba(10, 10, 26, 0.95) 0%, rgba(26, 35, 126, 0.4) 100%);
    border-bottom: 1px solid var(--panel-border);
    padding: 1rem 0;
    box-shadow: var(--glow-gold), var(--shadow-md);
    position: relative;
    z-index: 100;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Animated energy line under header */
.header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--gold) 20%,
        var(--fire) 40%,
        var(--neon-blue) 60%,
        var(--gold) 80%,
        transparent 100%);
    background-size: 200% 100%;
    animation: energyFlow 3s linear infinite;
}

@keyframes energyFlow {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

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

.header-logo {
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    position: relative;
}

.header-logo-img {
    width: 52px;
    height: 52px;
    object-fit: contain;
    border-radius: 8px;
    flex-shrink: 0;
    box-shadow: var(--glow-gold);
    animation: logoPulse 3s ease-in-out infinite;
    transition: transform 0.3s ease;
}

.header-logo-img:hover {
    transform: scale(1.1) rotate(-3deg);
}

@keyframes logoPulse {
    0%, 100% {
        box-shadow: 0 0 15px rgba(212, 175, 55, 0.4), 0 0 30px rgba(255, 107, 53, 0.2);
    }
    50% {
        box-shadow: 0 0 25px rgba(212, 175, 55, 0.6), 0 0 50px rgba(255, 107, 53, 0.35);
    }
}

.header-logo span {
    background: linear-gradient(135deg, #ffd700 0%, #ff6b35 50%, #00d4ff 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientFlow 5s ease infinite;
    text-shadow: 0 0 30px rgba(212, 175, 55, 0.3);
    letter-spacing: 0.5px;
}

@keyframes gradientFlow {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.header-logo::before {
    content: none;
}

.header-nav {
    display: flex;
    gap: 1rem;
    align-items: center;
    color: var(--light-text);
}

#user-info {
    padding: 0.4rem 1rem;
    border-radius: 20px;
    background: rgba(212, 175, 55, 0.1);
    border: 1px solid var(--panel-border);
    color: var(--gold-bright);
    font-size: 0.9rem;
}

/* =========================================================================
   MAIN LAYOUT
   ========================================================================= */
.container {
    display: flex;
    min-height: calc(100vh - 70px);
    position: relative;
}

/* =========================================================================
   SIDEBAR — dark cosmic panel with gold active states
   ========================================================================= */
.sidebar {
    width: 250px;
    background: linear-gradient(180deg, rgba(10, 10, 26, 0.95) 0%, rgba(13, 13, 31, 0.95) 100%);
    border-right: 1px solid var(--panel-border);
    color: white;
    padding: 1.5rem 0;
    overflow-y: auto;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: inset -10px 0 30px rgba(0, 0, 0, 0.3);
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}
.sidebar::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
}
.sidebar::-webkit-scrollbar-thumb {
    background: var(--gold-deep);
    border-radius: 3px;
}

.sidebar-title {
    padding: 1rem 1.5rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--gold);
    opacity: 0.8;
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

.sidebar-nav {
    list-style: none;
}

.sidebar-nav li {
    border-left: 3px solid transparent;
    transition: var(--transition);
    position: relative;
}

.sidebar-nav a {
    display: block;
    padding: 0.75rem 1.5rem;
    color: #c5c5e0;
    text-decoration: none;
    font-size: 0.92rem;
    transition: var(--transition);
}

.sidebar-nav li:hover a {
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.12) 0%, transparent 100%);
    padding-left: 1.75rem;
    color: var(--gold-bright);
}

.sidebar-nav li.active {
    border-left-color: var(--gold);
    background: linear-gradient(90deg, rgba(212, 175, 55, 0.15) 0%, transparent 70%);
}

.sidebar-nav li.active a {
    background: rgba(212, 175, 55, 0.08);
    color: var(--gold-bright);
    text-shadow: 0 0 12px rgba(212, 175, 55, 0.5);
}

/* =========================================================================
   MAIN CONTENT
   ========================================================================= */
.main-content {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
    position: relative;
}

.page-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, var(--gold-bright) 0%, var(--fire) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 40px rgba(212, 175, 55, 0.2);
    letter-spacing: 0.3px;
}

.page-subtitle {
    font-size: 1.1rem;
    color: var(--light-text);
    margin-bottom: 1rem;
}

/* =========================================================================
   CARDS — glassmorphism with gold border + cosmic glow
   ========================================================================= */
.card {
    background: var(--panel-bg);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--panel-border);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

/* Subtle glow line at top of cards */
.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0.4;
}

.card:hover {
    border-color: rgba(212, 175, 55, 0.45);
    box-shadow: var(--glow-gold), var(--shadow-lg);
    transform: translateY(-2px);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--gold-bright);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
}

.card-subtitle {
    font-size: 0.9rem;
    color: var(--light-text);
    margin-bottom: 0.5rem;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

/* =========================================================================
   STAT CARDS — glowing left borders in brand colors
   ========================================================================= */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--panel-bg);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
    border-left: 4px solid var(--gold);
    border: 1px solid var(--panel-border);
    border-left-width: 4px;
    border-left-color: var(--gold);
    transition: var(--transition);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: var(--glow-gold), var(--shadow-lg);
}

.stat-card.success {
    border-left-color: var(--success-color);
}

.stat-card.success:hover {
    box-shadow: 0 0 20px rgba(0, 230, 118, 0.3), 0 0 40px rgba(0, 230, 118, 0.15);
}

.stat-card.danger {
    border-left-color: var(--danger-color);
}

.stat-card.danger:hover {
    box-shadow: 0 0 20px rgba(255, 61, 86, 0.3), 0 0 40px rgba(255, 61, 86, 0.15);
}

.stat-card.warning {
    border-left-color: var(--warning-color);
}

.stat-card.warning:hover {
    box-shadow: var(--glow-fire);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold-bright);
    text-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--light-text);
    margin-top: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* =========================================================================
   FORMS
   ========================================================================= */
.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--gold-bright);
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--panel-border);
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
    background: rgba(5, 5, 16, 0.6);
    color: var(--dark-text);
}

.form-control:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15), var(--glow-gold);
    background: rgba(10, 10, 26, 0.8);
}

.form-control::placeholder {
    color: #6b7290;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23d4af37' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
    padding-right: 2.5rem;
}

select.form-control option {
    background: var(--cosmic-dark);
    color: var(--dark-text);
}

textarea.form-control {
    resize: vertical;
    min-height: 120px;
}

/* =========================================================================
   BUTTONS — fiery gradients + neon glow
   ========================================================================= */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold-deep) 0%, var(--gold) 50%, var(--fire) 100%);
    color: #0a0a1a;
    box-shadow: 0 2px 10px rgba(212, 175, 55, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--gold) 0%, var(--gold-bright) 50%, var(--fire) 100%);
    transform: translateY(-2px);
    box-shadow: var(--glow-gold), var(--glow-fire);
}

.btn-success {
    background: linear-gradient(135deg, #00b870 0%, var(--success-color) 100%);
    color: #0a0a1a;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(0, 230, 118, 0.4), 0 0 40px rgba(0, 230, 118, 0.2);
}

.btn-danger {
    background: linear-gradient(135deg, #c1121f 0%, var(--danger-color) 100%);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(255, 61, 86, 0.4), 0 0 40px rgba(255, 61, 86, 0.2);
}

.btn-warning {
    background: linear-gradient(135deg, var(--fire-deep) 0%, var(--fire) 100%);
    color: white;
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: var(--glow-fire);
}

.btn-info {
    background: linear-gradient(135deg, #0288d1 0%, var(--neon-blue) 100%);
    color: #0a0a1a;
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: var(--glow-neon);
}

.btn-secondary {
    background: rgba(107, 114, 160, 0.3);
    color: var(--dark-text);
    border: 1px solid var(--panel-border);
}

.btn-secondary:hover {
    background: rgba(107, 114, 160, 0.5);
    border-color: var(--gold);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.btn-block {
    display: block;
    width: 100%;
    text-align: center;
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Shimmer effect on primary buttons */
.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover::after {
    left: 100%;
}

/* =========================================================================
   TABLES
   ========================================================================= */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead th {
    background: rgba(212, 175, 55, 0.1);
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    border-bottom: 2px solid var(--gold);
    color: var(--gold-bright);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
}

.table tbody td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--dark-text);
}

.table tbody tr:hover {
    background: rgba(212, 175, 55, 0.06);
}

.table tbody tr {
    transition: var(--transition);
}

/* =========================================================================
   STATUS BADGES
   ========================================================================= */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
}

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

.badge-success {
    background-color: rgba(0, 230, 118, 0.15);
    color: var(--success-color);
    border: 1px solid rgba(0, 230, 118, 0.3);
}

.badge-danger {
    background-color: rgba(255, 61, 86, 0.15);
    color: var(--danger-color);
    border: 1px solid rgba(255, 61, 86, 0.3);
}

.badge-warning {
    background-color: rgba(255, 107, 53, 0.15);
    color: var(--fire);
    border: 1px solid rgba(255, 107, 53, 0.3);
}

.badge-info {
    background-color: rgba(0, 212, 255, 0.12);
    color: var(--neon-blue);
    border: 1px solid rgba(0, 212, 255, 0.3);
}

.badge-secondary {
    background-color: rgba(107, 114, 160, 0.15);
    color: #a5a5c4;
    border: 1px solid rgba(107, 114, 160, 0.3);
}

/* =========================================================================
   MODALS
   ========================================================================= */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(5, 5, 16, 0.85);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.modal.show {
    display: block;
}

.modal-content {
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.98) 0%, rgba(13, 13, 31, 0.98) 100%);
    border: 1px solid var(--panel-border);
    margin: 8% auto;
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: var(--glow-gold), var(--shadow-lg);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateY(-50px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--panel-border);
    padding-bottom: 1rem;
}

.modal-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gold-bright);
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--light-text);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--danger-color);
    transform: scale(1.2);
}

.modal-body {
    margin-bottom: 1.5rem;
    color: var(--dark-text);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

/* =========================================================================
   ALERTS
   ========================================================================= */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    border-left: 4px solid;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.alert-success {
    background-color: rgba(0, 230, 118, 0.1);
    border-color: var(--success-color);
    color: #6ee7a0;
}

.alert-danger {
    background-color: rgba(255, 61, 86, 0.1);
    border-color: var(--danger-color);
    color: #ff8095;
}

.alert-warning {
    background-color: rgba(255, 107, 53, 0.1);
    border-color: var(--warning-color);
    color: #ffa775;
}

.alert-info {
    background-color: rgba(0, 212, 255, 0.1);
    border-color: var(--info-color);
    color: var(--neon-glow);
}

/* =========================================================================
   PROGRESS BAR
   ========================================================================= */
.progress {
    background-color: rgba(0, 0, 0, 0.3);
    border-radius: 9999px;
    height: 8px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.progress-bar {
    background: linear-gradient(90deg, var(--gold) 0%, var(--fire) 100%);
    height: 100%;
    transition: width 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 10px rgba(255, 107, 53, 0.5);
}

.progress-bar.success {
    background-color: var(--success-color);
    background: linear-gradient(90deg, #00b870 0%, var(--success-color) 100%);
}

.progress-bar.danger {
    background-color: var(--danger-color);
    background: linear-gradient(90deg, #c1121f 0%, var(--danger-color) 100%);
}

/* =========================================================================
   LOADING SPINNER
   ========================================================================= */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(212, 175, 55, 0.15);
    border-radius: 50%;
    border-top-color: var(--gold);
    animation: spin 0.6s linear infinite;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3);
}

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

/* =========================================================================
   UTILITY CLASSES
   ========================================================================= */
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--light-text); }

.flex { display: flex; }
.gap-1 { gap: 0.5rem; }
.gap-2 { gap: 1rem; }
.gap-3 { gap: 1.5rem; }

.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.items-center { align-items: center; }

/* =========================================================================
   RESPONSIVE
   ========================================================================= */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        padding: 1rem 0;
    }

    .container {
        flex-direction: column;
    }

    .main-content {
        padding: 1rem;
    }

    .stat-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        width: 95%;
        margin: 50% auto;
    }
}

/* =========================================================================
   DASHBOARD CONTROLS
   ========================================================================= */
.dashboard-controls {
    background: var(--panel-bg);
    padding: 1.5rem;
    margin-bottom: 1rem;
    border-radius: 12px;
    border: 1px solid var(--panel-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.control-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.control-group .form-label {
    margin-bottom: 0;
    white-space: nowrap;
}

.control-group .form-control {
    padding: 0.5rem;
    font-size: 0.875rem;
}

/* =========================================================================
   ADMIN TABS
   ========================================================================= */
.admin-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid var(--panel-border);
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    background-color: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--gold-bright);
}

.tab-btn.active {
    color: var(--gold-bright);
    border-bottom-color: var(--gold);
    text-shadow: 0 0 15px rgba(212, 175, 55, 0.4);
}

.admin-tab {
    display: none;
}

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

.admin-tab > .card {
    margin-bottom: 1.5rem;
}

/* =========================================================================
   ANALYTICS GRID
   ========================================================================= */
.analytics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 1024px) {
    .analytics-grid {
        grid-template-columns: 1fr;
    }
}

/* Charts Container */
canvas {
    max-height: 300px;
}

.chart-container {
    position: relative;
    height: 300px;
    margin-bottom: 1rem;
}

/* =========================================================================
   STATISTICS TABLE
   ========================================================================= */
.stat-table {
    width: 100%;
    margin-top: 1rem;
}

.stat-table td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    color: var(--dark-text);
}

.stat-table tr:last-child td {
    border-bottom: none;
}

.stat-table td:first-child {
    font-weight: 500;
    width: 60%;
    color: var(--light-text);
}

.stat-table td:last-child {
    text-align: right;
    font-weight: 600;
    color: var(--gold-bright);
}

/* Health Status Indicators */
.health-ok {
    color: var(--success-color);
    text-shadow: 0 0 10px rgba(0, 230, 118, 0.4);
}

.health-warning {
    color: var(--warning-color);
    text-shadow: 0 0 10px rgba(255, 107, 53, 0.4);
}

.health-error {
    color: var(--danger-color);
    text-shadow: 0 0 10px rgba(255, 61, 86, 0.4);
}

/* =========================================================================
   PROGRESS BAR (alternate)
   ========================================================================= */
.progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--gold) 0%, var(--fire) 50%, var(--neon-blue) 100%);
    transition: width 0.3s ease;
    box-shadow: 0 0 10px rgba(255, 107, 53, 0.4);
}

/* =========================================================================
   ACTIVITY TIMELINE
   ========================================================================= */
.timeline {
    position: relative;
    padding: 1rem 0;
}

.timeline-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.timeline-item:before {
    content: '';
    position: absolute;
    left: 12px;
    top: 35px;
    bottom: -1.5rem;
    width: 2px;
    background: linear-gradient(180deg, var(--gold), var(--panel-border));
}

.timeline-item:last-child:before {
    display: none;
}

.timeline-marker {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, var(--gold) 0%, var(--fire) 100%);
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #0a0a1a;
    font-size: 0.75rem;
    position: relative;
    z-index: 1;
    box-shadow: var(--glow-gold);
}

.timeline-content {
    flex-grow: 1;
}

.timeline-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: var(--dark-text);
}

.timeline-time {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* =========================================================================
   METRIC CARD
   ========================================================================= */
.metric-card {
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.metric-card:hover {
    border-color: var(--gold);
    box-shadow: var(--glow-gold);
    transform: translateY(-2px);
}

.metric-card .metric-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--gold-bright) 0%, var(--fire) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}

.metric-card .metric-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.metric-card .metric-change {
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.metric-change.positive {
    color: var(--success-color);
}

.metric-change.negative {
    color: var(--danger-color);
}

/* =========================================================================
   FILTER PANEL
   ========================================================================= */
.filter-panel {
    background: var(--panel-bg);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.filter-row:last-child {
    margin-bottom: 0;
}

.filter-group {
    display: flex;
    flex-direction: column;
}

.filter-group label {
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    color: var(--gold-bright);
}

/* Data Export */
.export-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.export-button:before {
    content: '📥';
}

/* =========================================================================
   RESPONSIVE (dashboard)
   ========================================================================= */
@media (max-width: 768px) {
    .dashboard-controls {
        padding: 1rem;
    }

    .control-row {
        flex-direction: column;
        align-items: stretch;
    }

    .control-group {
        width: 100%;
    }

    .control-group .form-control {
        width: 100%;
    }

    .admin-tabs {
        flex-direction: column;
        border-bottom: none;
        gap: 0;
    }

    .tab-btn {
        border-bottom: none;
        border-left: 3px solid transparent;
        border-radius: 0;
        width: 100%;
        text-align: left;
    }

    .tab-btn.active {
        border-bottom: none;
        border-left-color: var(--gold);
    }

    .analytics-grid {
        grid-template-columns: 1fr;
    }

    .filter-row {
        grid-template-columns: 1fr;
    }
}

/* =========================================================================
   ACTIVITY FEED
   ========================================================================= */
.activity-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.activity-item:hover {
    background: rgba(212, 175, 55, 0.05);
    padding-left: 8px;
}

.activity-item:last-child { border-bottom: none; }
.activity-text { color: #c5c5e0; font-size: 14px; }
.activity-time { font-size: 12px; white-space: nowrap; color: var(--text-secondary); }

/* =========================================================================
   MULTISELECT (Campaign Builder)
   ========================================================================= */
.multiselect-toolbar {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
}

.multiselect-list {
    max-height: 240px;
    overflow-y: auto;
    border: 1px solid var(--panel-border);
    border-radius: 8px;
    padding: 4px;
    background: rgba(5, 5, 16, 0.5);
}

.multiselect-list::-webkit-scrollbar {
    width: 6px;
}
.multiselect-list::-webkit-scrollbar-thumb {
    background: var(--gold-deep);
    border-radius: 3px;
}

.multiselect-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 8px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    color: #c5c5e0;
    transition: background .12s;
}

.multiselect-item:hover { background: rgba(212, 175, 55, 0.1); }
.multiselect-item input[type="checkbox"] {
    margin: 0;
    cursor: pointer;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    accent-color: var(--gold);
}
.multiselect-item .ms-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.multiselect-item .ms-badge {
    font-size: 11px;
    padding: 1px 6px;
    border-radius: 10px;
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-bright);
    white-space: nowrap;
}
.multiselect-empty { padding: 12px; text-align: center; color: #6b7290; font-size: 14px; }

/* =========================================================================
   TEMPLATE PREVIEW MODAL
   ========================================================================= */
.preview-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-modal-backdrop {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(5, 5, 16, 0.85);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.preview-modal-dialog {
    position: relative;
    background: linear-gradient(135deg, rgba(15, 15, 35, 0.98) 0%, rgba(13, 13, 31, 0.98) 100%);
    border: 1px solid var(--panel-border);
    border-radius: 12px;
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--glow-gold), 0 20px 60px rgba(0,0,0,0.5);
    overflow: hidden;
}

.preview-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--panel-border);
    flex-shrink: 0;
}

.preview-modal-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gold-bright);
}

.preview-modal-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.preview-modal-info {
    padding: 0.5rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    flex-shrink: 0;
    color: var(--light-text);
}

.preview-modal-body {
    flex: 1;
    overflow: hidden;
    min-height: 400px;
    background: #fff;
}

.preview-modal-source {
    padding: 0.5rem 1.25rem 1rem;
    border-top: 1px solid var(--panel-border);
    flex-shrink: 0;
}

/* =========================================================================
   VARIABLE CHIPS
   ========================================================================= */
.var-chip {
    display: inline-block;
    background: rgba(0, 212, 255, 0.12);
    color: var(--neon-blue);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 4px;
    padding: 1px 6px;
    margin: 2px 1px;
    font-size: 0.8rem;
    font-family: monospace;
    cursor: pointer;
    transition: all 0.12s;
    user-select: none;
}

.var-chip:hover {
    background: rgba(0, 212, 255, 0.25);
    border-color: var(--neon-blue);
    color: var(--neon-glow);
    box-shadow: var(--glow-neon);
}

.var-chip:active {
    background: rgba(0, 212, 255, 0.35);
}

/* =========================================================================
   FORMS (generic)
   ========================================================================= */
.form {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.5rem 1rem;
    margin-bottom: 1rem;
}

.form-grid .form-group {
    margin-bottom: 0;
}

/* =========================================================================
   TOR IP MANAGER / MAIL ROUTER
   ========================================================================= */
.stat-card .stat-value {
    word-break: break-all;
}

#tor-current-ip,
#mr-tor-status,
#tor-running-status,
#tor-auto-status {
    font-size: 1rem;
}

/* =========================================================================
   GLOBAL SCROLLBAR STYLING
   ========================================================================= */
.main-content::-webkit-scrollbar {
    width: 8px;
}
.main-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
}
.main-content::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--gold-deep), var(--fire));
    border-radius: 4px;
}
.main-content::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--gold), var(--fire));
}

/* =========================================================================
   3D ANIMATED DECORATIVE ELEMENTS
   ========================================================================= */

/* Floating energy ring — large rotating halo like in the logo */
.cosmic-ring {
    position: fixed;
    width: 600px;
    height: 600px;
    border: 2px solid transparent;
    border-radius: 50%;
    border-top-color: rgba(212, 175, 55, 0.08);
    border-right-color: rgba(255, 107, 53, 0.06);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: -1;
    animation: ringRotate 30s linear infinite;
    pointer-events: none;
}

.cosmic-ring.ring2 {
    width: 900px;
    height: 900px;
    border-top-color: rgba(0, 212, 255, 0.05);
    border-left-color: rgba(26, 35, 126, 0.1);
    animation: ringRotate 45s linear infinite reverse;
}

.cosmic-ring.ring3 {
    width: 350px;
    height: 350px;
    border-top-color: rgba(255, 107, 53, 0.1);
    border-bottom-color: rgba(212, 175, 55, 0.08);
    animation: ringRotate 20s linear infinite;
}

@keyframes ringRotate {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Orbiting envelope icon — floats around like in the logo */
.orbit-envelope {
    position: fixed;
    font-size: 24px;
    z-index: -1;
    pointer-events: none;
    opacity: 0.5;
    filter: drop-shadow(0 0 8px rgba(0, 212, 255, 0.4));
}

.orbit-envelope.e1 {
    top: 15%;
    left: 8%;
    animation: floatUp 6s ease-in-out infinite;
}
.orbit-envelope.e2 {
    top: 70%;
    right: 5%;
    animation: floatUp 7s ease-in-out infinite 1s;
}
.orbit-envelope.e3 {
    bottom: 10%;
    left: 12%;
    animation: floatUp 5s ease-in-out infinite 2s;
}
.orbit-envelope.e4 {
    top: 25%;
    right: 10%;
    animation: floatUp 8s ease-in-out infinite 0.5s;
}

@keyframes floatUp {
    0%, 100% { transform: translateY(0) rotate(-5deg); opacity: 0.3; }
    50% { transform: translateY(-25px) rotate(5deg); opacity: 0.6; }
}

/* Floating planets/spheres like in the logo background */
.cosmic-planet {
    position: fixed;
    border-radius: 50%;
    z-index: -1;
    pointer-events: none;
}

.cosmic-planet.p1 {
    width: 60px;
    height: 60px;
    top: 20%;
    right: 15%;
    background: radial-gradient(circle at 30% 30%, #d4af37, #8b6914 70%, #4a3800);
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.2);
    animation: drift 15s ease-in-out infinite;
}

.cosmic-planet.p2 {
    width: 40px;
    height: 40px;
    bottom: 25%;
    left: 6%;
    background: radial-gradient(circle at 30% 30%, #ff6b35, #c1121f 70%, #5a0a0f);
    box-shadow: 0 0 25px rgba(255, 107, 53, 0.2);
    animation: drift 18s ease-in-out infinite reverse;
}

.cosmic-planet.p3 {
    width: 25px;
    height: 25px;
    top: 60%;
    right: 8%;
    background: radial-gradient(circle at 30% 30%, #4fc3f7, #0288d1 70%, #01437a);
    box-shadow: 0 0 20px rgba(0, 212, 255, 0.2);
    animation: drift 12s ease-in-out infinite 3s;
}

@keyframes drift {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(20px, -30px); }
    66% { transform: translate(-15px, 20px); }
}

/* Glowing aura pulse behind logo area */
.cosmic-aura {
    position: fixed;
    width: 400px;
    height: 400px;
    top: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(255, 107, 53, 0.06) 0%, transparent 60%);
    z-index: -1;
    pointer-events: none;
    animation: auraPulse 5s ease-in-out infinite;
}

@keyframes auraPulse {
    0%, 100% { opacity: 0.5; transform: translateX(-50%) scale(1); }
    50% { opacity: 0.9; transform: translateX(-50%) scale(1.15); }
}

/* Links */
a {
    color: var(--neon-glow);
    transition: var(--transition);
}

a:hover {
    color: var(--gold-bright);
    text-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

/* Selection color */
::selection {
    background: rgba(212, 175, 55, 0.3);
    color: var(--gold-bright);
}

/* Text colors override for dark theme */
.text-muted {
    color: var(--light-text) !important;
}

.text-center {
    text-align: center;
}

/* =========================================================================
   LICENSE ACTIVATION GATE — cosmic themed overlay
   ========================================================================= */
.license-gate-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(ellipse at 50% 40%, rgba(255, 107, 53, 0.10) 0%, transparent 55%),
        radial-gradient(ellipse at 50% 50%, rgba(212, 175, 55, 0.06) 0%, transparent 60%),
        rgba(5, 5, 16, 0.97);
    backdrop-filter: blur(8px);
    animation: gateFadeIn 0.5s ease;
}
@keyframes gateFadeIn { from { opacity: 0; } to { opacity: 1; } }

.license-gate-card {
    width: min(460px, 92vw);
    padding: 2.5rem 2.2rem 1.8rem;
    background:
        linear-gradient(160deg, rgba(20, 20, 45, 0.95), rgba(10, 10, 25, 0.98));
    border: 1px solid rgba(212, 175, 55, 0.30);
    border-radius: 20px;
    box-shadow:
        0 0 30px rgba(212, 175, 55, 0.15),
        0 0 60px rgba(255, 107, 53, 0.08),
        0 20px 60px rgba(0, 0, 0, 0.6);
    text-align: center;
    animation: gateCardPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    position: relative;
    overflow: hidden;
}
@keyframes gateCardPop {
    from { transform: scale(0.85) translateY(20px); opacity: 0; }
    to   { transform: scale(1) translateY(0); opacity: 1; }
}
.license-gate-card::before {
    content: '';
    position: absolute;
    top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(212,175,55,0.06), transparent 30%);
    animation: gateShimmer 6s linear infinite;
    pointer-events: none;
}
@keyframes gateShimmer { to { transform: rotate(360deg); } }

.license-gate-logo {
    display: flex; justify-content: center; margin-bottom: 0.5rem;
    position: relative; z-index: 1;
}
.license-gate-logo-img {
    width: 90px; height: 90px; border-radius: 50%;
    box-shadow: 0 0 25px rgba(255, 107, 53, 0.4), 0 0 50px rgba(212, 175, 55, 0.2);
    animation: logoFloat 3s ease-in-out infinite;
}
@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.license-gate-title {
    font-size: 1.6rem; font-weight: 800; letter-spacing: 2px;
    background: linear-gradient(90deg, var(--gold-bright), var(--fire), var(--gold));
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0.3rem 0 0; position: relative; z-index: 1;
}
.license-gate-subtitle {
    font-size: 0.85rem; color: var(--neon-blue); letter-spacing: 1px;
    text-transform: uppercase; margin: 0.2rem 0 1rem; position: relative; z-index: 1;
}
.license-gate-desc {
    font-size: 0.9rem; color: var(--light-text); line-height: 1.5;
    margin-bottom: 1.5rem; position: relative; z-index: 1;
}
.license-gate-desc small { color: rgba(156, 163, 196, 0.7); font-size: 0.78rem; }

.license-gate-form { position: relative; z-index: 1; }

.license-input-wrap { margin-bottom: 1rem; }
.license-input {
    width: 100%; padding: 14px 18px;
    background: rgba(5, 5, 20, 0.8);
    border: 1.5px solid rgba(212, 175, 55, 0.25);
    border-radius: 12px;
    color: var(--gold-bright);
    font-size: 1.05rem; font-family: 'Courier New', monospace; letter-spacing: 1px;
    text-align: center; text-transform: uppercase;
    transition: var(--transition);
}
.license-input:focus {
    outline: none;
    border-color: var(--gold);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.15), 0 0 20px rgba(212, 175, 55, 0.2);
    background: rgba(10, 10, 30, 0.9);
}
.license-input::placeholder { color: rgba(156, 163, 196, 0.35); text-transform: none; letter-spacing: 0; }

.license-support-wrap {
    display: flex; flex-direction: column; align-items: center; gap: 0.4rem;
    margin-bottom: 1.2rem;
}
.whatsapp-support-btn {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 10px 20px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    border: none; border-radius: 12px;
    color: #fff; font-size: 0.88rem; font-weight: 600;
    text-decoration: none; cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.35);
    position: relative; overflow: hidden;
}
.whatsapp-support-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(37, 211, 102, 0.5), 0 0 15px rgba(37, 211, 102, 0.3);
    background: linear-gradient(135deg, #2ee672, #14a08a);
}
.whatsapp-support-btn:active { transform: translateY(0); }
.whatsapp-icon {
    flex-shrink: 0; filter: drop-shadow(0 0 2px rgba(0,0,0,0.15));
}
.whatsapp-support-btn::after {
    content: ''; position: absolute; top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.25), transparent);
    transition: left 0.5s;
}
.whatsapp-support-btn:hover::after { left: 100%; }
.whatsapp-support-number {
    font-size: 0.75rem; color: rgba(156, 163, 196, 0.6);
    font-family: monospace; margin: 0;
}

.license-activate-btn {
    width: 100%; padding: 14px;
    background: linear-gradient(135deg, var(--fire), var(--ember), var(--gold-deep));
    border: none; border-radius: 12px;
    color: #fff; font-size: 1.05rem; font-weight: 700; letter-spacing: 0.5px;
    cursor: pointer; position: relative; overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.35);
}
.license-activate-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(255, 107, 53, 0.5), 0 0 20px rgba(212, 175, 55, 0.3);
}
.license-activate-btn:active { transform: translateY(0); }
.license-activate-btn:disabled { opacity: 0.6; cursor: wait; }
.license-activate-btn::after {
    content: ''; position: absolute; top: 0; left: -100%;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}
.license-activate-btn:hover::after { left: 100%; }
.license-btn-text { position: relative; z-index: 1; }

.license-gate-message {
    margin-top: 1rem; min-height: 1.5em;
    font-size: 0.85rem; padding: 0.5rem;
    border-radius: 8px;
    transition: var(--transition);
}
.license-gate-message.success {
    color: var(--success-color);
    background: rgba(0, 230, 118, 0.08);
    border: 1px solid rgba(0, 230, 118, 0.2);
}
.license-gate-message.error {
    color: var(--danger-color);
    background: rgba(255, 61, 86, 0.08);
    border: 1px solid rgba(255, 61, 86, 0.2);
}
.license-gate-message.loading {
    color: var(--neon-blue);
}

.license-gate-footer {
    margin-top: 1.5rem; padding-top: 1.2rem;
    border-top: 1px solid rgba(212, 175, 55, 0.12);
    display: flex; justify-content: space-between; align-items: center;
    font-size: 0.78rem; position: relative; z-index: 1; flex-wrap: wrap; gap: 0.5rem;
}
.license-device-info {
    color: rgba(156, 163, 196, 0.6); font-family: monospace; font-size: 0.72rem;
}
.license-manager-link {
    color: var(--gold); text-decoration: none; font-size: 0.78rem;
    transition: var(--transition);
}
.license-manager-link:hover { color: var(--gold-bright); text-shadow: 0 0 10px rgba(212,175,55,0.4); }

/* Gate hidden state */
.license-gate-overlay.hidden {
    display: none !important;
}

/* License badge in header (shown after activation) */
.license-badge-active {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 4px 12px; margin-left: 10px;
    background: rgba(0, 230, 118, 0.10);
    border: 1px solid rgba(0, 230, 118, 0.30);
    border-radius: 20px;
    font-size: 0.75rem; color: var(--success-color);
    font-family: monospace;
}
.license-badge-active .dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: var(--success-color);
    box-shadow: 0 0 8px var(--success-color);
    animation: pulseDot 2s ease-in-out infinite;
}
@keyframes pulseDot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}
