/**
 * Discord Voice Theme CSS - Games.php Design System
 * Overrides discord_voice.php styling to match games.php purple theme
 */

/* ─────────────────────────────────────────────────────────
   HERO SECTION
   ───────────────────────────────────────────────────────── */

.discord-hero {
    background: linear-gradient(135deg, var(--purple-dark) 0%, #251647 50%, var(--purple-dark) 100%);
    padding: 3rem 0 2.5rem;
    position: relative;
    overflow: hidden;
    text-align: center;
}

.discord-hero::before {
    content: '';
    position: absolute;
    top: -150px;
    right: -150px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, var(--purple-primary) 0%, transparent 70%);
    opacity: 0.3;
    border-radius: 50%;
}

.discord-hero::after {
    content: '';
    position: absolute;
    bottom: -100px;
    left: -100px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, var(--pink-500) 0%, transparent 70%);
    opacity: 0.2;
    border-radius: 50%;
}

.discord-hero-content {
    position: relative;
    z-index: 1;
}

.discord-hero h1 {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(139, 92, 246, 0.5);
}

.discord-hero p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 700px;
    margin: 0 auto;
}

.discord-status {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-full);
    margin-top: 1rem;
    font-weight: 600;
}

/* ─────────────────────────────────────────────────────────
   VOICE CHANNELS LIST
   ───────────────────────────────────────────────────────── */

.voice-channels {
    background: var(--card-bg);
    border: 1px solid var(--purple-primary);
    border-radius: var(--radius-2xl);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

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

.voice-channels-header h2 {
    margin: 0;
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.voice-channels-header h2 i {
    color: var(--purple-primary);
}

.refresh-btn {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-dark));
    color: #ffffff;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-lg);
    border: none;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all var(--transition-smooth);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.refresh-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
}

.voice-channel-card {
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1rem 1.5rem;
    margin-bottom: 1rem;
    transition: all var(--transition-smooth);
}

.voice-channel-card:hover {
    border-color: var(--purple-primary);
    box-shadow: 0 4px 15px rgba(139, 92, 246, 0.15);
}

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

.channel-name {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #ffffff;
    font-weight: 600;
    font-size: 1.1rem;
}

.channel-icon {
    color: var(--purple-primary);
    font-size: 1.25rem;
}

.channel-status {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.875rem;
    font-weight: 600;
}

.channel-status.online {
    color: #22c55e;
}

.channel-status.idle {
    color: #f59e0b;
}

.users-in-channel {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-color);
}

.voice-user {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--card-bg);
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius-lg);
    font-size: 0.875rem;
}

.voice-user img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.voice-user-name {
    color: #ffffff;
    font-weight: 500;
}

.voice-user.deafened .voice-user-name {
    color: var(--text-muted);
    text-decoration: line-through;
}

/* ─────────────────────────────────────────────────────────
   CONNECT BUTTON SECTION
   ───────────────────────────────────────────────────────── */

.connect-section {
    background: linear-gradient(135deg, var(--purple-dark), #251647);
    border: 2px solid var(--purple-primary);
    border-radius: var(--radius-2xl);
    padding: 2rem;
    text-align: center;
    margin-bottom: 2rem;
}

.connect-section h3 {
    color: #ffffff;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.connect-section p {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.discord-btn {
    background: #5865F2;
    color: #ffffff;
    padding: 1rem 2rem;
    border-radius: var(--radius-full);
    border: none;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-smooth);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.discord-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(88, 101, 242, 0.4);
    background: #4752c4;
}

/* ─────────────────────────────────────────────────────────
   STATS CARDS
   ───────────────────────────────────────────────────────── */

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

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-xl);
    padding: 1.5rem;
    text-align: center;
    transition: all var(--transition-smooth);
}

.stat-card:hover {
    transform: translateY(-3px);
    border-color: var(--purple-primary);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.2);
}

.stat-card .icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-dark));
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.stat-card .icon i {
    color: #ffffff;
    font-size: 1.5rem;
}

.stat-card .value {
    color: #ffffff;
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
}

.stat-card .label {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
}

/* ─────────────────────────────────────────────────────────
   SETTINGS PANEL
   ───────────────────────────────────────────────────────── */

.settings-panel {
    background: var(--card-bg);
    border: 1px solid var(--purple-primary);
    border-radius: var(--radius-2xl);
    padding: 1.5rem;
}

.settings-panel h3 {
    color: #ffffff;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.settings-panel h3 i {
    color: var(--purple-primary);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    color: #ffffff;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.form-group input[type="text"],
.form-group input[type="url"] {
    width: 100%;
    background: var(--input-bg);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 0.75rem 1rem;
    color: #ffffff;
    font-size: 1rem;
    transition: all var(--transition-smooth);
}

.form-group input:focus {
    outline: none;
    border-color: var(--purple-primary);
    box-shadow: 0 0 15px rgba(139, 92, 246, 0.2);
}

.form-group .help-text {
    color: var(--text-muted);
    font-size: 0.875rem;
    margin-top: 0.5rem;
}

.save-btn {
    background: linear-gradient(135deg, var(--purple-primary), var(--purple-dark));
    color: #ffffff;
    padding: 0.75rem 2rem;
    border-radius: var(--radius-full);
    border: none;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-smooth);
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.3);
}

/* ─────────────────────────────────────────────────────────
   ERROR & LOADING STATES
   ───────────────────────────────────────────────────────── */

.alert-warning {
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.3);
    color: #f59e0b;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-xl);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-xl);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.loading-spinner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    color: var(--purple-primary);
    font-size: 1.1rem;
}

.loading-spinner i {
    animation: spin 1s linear infinite;
    margin-right: 0.5rem;
}

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

/* ─────────────────────────────────────────────────────────
   RESPONSIVE DESIGN
   ───────────────────────────────────────────────────────── */

@media (max-width: 1100px) {
    .discord-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .discord-hero h1 {
        font-size: 2rem;
    }
    
    .voice-channels-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
}

@media (max-width: 768px) {
    .discord-hero {
        padding: 2rem 0 1.5rem;
    }
    
    .discord-hero h1 {
        font-size: 1.75rem;
    }
    
    .discord-stats {
        grid-template-columns: 1fr;
    }
    
    .connect-section {
        padding: 1.5rem;
    }
    
    .voice-channels {
        padding: 1rem;
    }
    
    .voice-channel-card {
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .discord-hero h1 {
        font-size: 1.5rem;
    }
    
    .discord-hero p {
        font-size: 1rem;
    }
    
    .users-in-channel {
        gap: 0.5rem;
    }
    
    .voice-user {
        padding: 0.4rem 0.6rem;
        font-size: 0.8rem;
    }
    
    .discord-btn {
        padding: 0.875rem 1.5rem;
        font-size: 0.9rem;
    }
}