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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    background: linear-gradient(to bottom right, #0f172a, #1e3a8a, #0f172a);
}

.container {
    max-width: 950px; /* RÉDUIT à 950px */
    margin: 0; /* Collé à gauche */
    padding: 0.5rem;
}

/* Panneau latéral */
.side-panel {
    position: fixed;
    right: 0;
    top: 0;
    width: 300px;
    height: 100vh;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(10px);
    border-left: 2px solid rgba(59, 130, 246, 0.3);
    padding: 1.5rem;
    overflow-y: auto;
    transition: transform 0.3s ease;
    z-index: 1000;
}

.side-panel.closed {
    transform: translateX(100%);
}

.close-btn {
    position: absolute;
    right: 1rem;
    top: 1rem;
    font-size: 2rem;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    transition: color 0.2s;
}

.close-btn:hover {
    color: #ef4444;
}

.open-panel-btn {
    position: fixed;
    right: 1rem;
    top: 1rem;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(59, 130, 246, 0.8);
    border: 2px solid rgba(59, 130, 246, 1);
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s;
    z-index: 999;
    display: none;
}

.open-panel-btn.visible {
    display: block;
}

.open-panel-btn:hover {
    background: rgba(59, 130, 246, 1);
    transform: scale(1.1);
}

.main-content {
    transition: margin-right 0.3s ease;
    margin-right: 0;
}

.main-content.panel-open {
    margin-right: 300px;
}

/* Cards */
.header-card {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.2rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.qso-card {
    background: linear-gradient(to right, rgba(34, 197, 94, 0.2), rgba(59, 130, 246, 0.2));
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.2rem;
    margin-bottom: 1rem;
    border: 2px solid rgba(34, 197, 94, 0.5);
}

.qso-card.inactive {
    background: linear-gradient(to right, rgba(71, 85, 105, 0.2), rgba(51, 65, 85, 0.2));
    border-color: rgba(71, 85, 105, 0.5);
}

.card {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.2rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

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

.card-header h2 {
    font-size: 1.1rem;
    font-weight: bold;
}

.badge {
    background: #3b82f6;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: bold;
}

/* User cards */
.user-card {
    padding: 0.8rem;
    border-radius: 0.5rem;
    border-left: 4px solid rgba(59, 130, 246, 0.5);
    background: rgba(51, 65, 85, 0.5);
    transition: all 0.3s;
}

.user-card.talking {
    background: rgba(34, 197, 94, 0.2);
    border-color: #22c55e;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Grid */
.grid-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* FORCÉ: 2 colonnes fixes */
    gap: 0.8rem;
    margin-bottom: 1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.8rem;
}

.stat-card {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 0.5rem;
    padding: 0.8rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
    text-align: center;
}

/* Links */
.link-category {
    margin-bottom: 1.2rem;
}

.link-category h3 {
    font-size: 0.95rem;
    color: #3b82f6;
    margin-bottom: 0.5rem;
    font-weight: bold;
}

.link-item {
    background: rgba(51, 65, 85, 0.5);
    padding: 0.6rem;
    border-radius: 0.5rem;
    margin-bottom: 0.4rem;
    border: 1px solid rgba(59, 130, 246, 0.2);
    transition: all 0.2s;
}

.link-item:hover {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
    transform: translateX(-5px);
}

.link-item a {
    color: white;
    text-decoration: none;
    display: block;
}

.link-item .link-title {
    font-weight: bold;
    margin-bottom: 0.2rem;
    font-size: 0.9rem;
}

.link-item .link-desc {
    font-size: 0.8rem;
    color: #9ca3af;
}

/* Utility classes */
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.mb-1 { margin-bottom: 0.25rem; }
.mb-4 { margin-bottom: 1rem; }
.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.text-sm { font-size: 0.875rem; }
.text-xs { font-size: 0.75rem; }
.text-lg { font-size: 1.125rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-4xl { font-size: 2.25rem; }
.font-bold { font-weight: bold; }
.font-mono { font-family: monospace; }
.text-white { color: white; }
.text-blue-300 { color: #93c5fd; }
.text-blue-400 { color: #60a5fa; }
.text-green-400 { color: #4ade80; }
.text-purple-400 { color: #c084fc; }
.text-gray-400 { color: #9ca3af; }
.text-gray-500 { color: #6b7280; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.flex-1 { flex: 1; }

/* Icons */
.radio-icon, .activity-icon {
    font-size: 2.2rem;
}

/* Responsive */
@media (max-width: 768px) {
    .grid-container {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .side-panel {
        width: 100%;
    }
    
    .main-content.panel-open {
        margin-right: 0;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.5);
}

::-webkit-scrollbar-thumb {
    background: rgba(59, 130, 246, 0.5);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(59, 130, 246, 0.8);
}

/* Audio Player */
.audio-player-card {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border: 1px solid rgba(59, 130, 246, 0.3);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.audio-player-card .flex {
    flex-wrap: wrap;
}

.audio-icon {
    font-size: 2rem;
    background: rgba(59, 130, 246, 0.2);
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid rgba(59, 130, 246, 0.4);
}

.audio-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem;
    background: rgba(51, 65, 85, 0.3);
    border-radius: 0.75rem;
    border: 1px solid rgba(71, 85, 105, 0.5);
}

.audio-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    border: 2px solid rgba(59, 130, 246, 0.5);
    background: rgba(59, 130, 246, 0.2);
    color: white;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-btn:hover:not(:disabled) {
    background: rgba(59, 130, 246, 0.4);
    transform: scale(1.1);
    border-color: rgba(59, 130, 246, 0.8);
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}

.audio-btn:active:not(:disabled) {
    transform: scale(0.95);
}

.audio-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.play-btn.playing {
    background: rgba(34, 197, 94, 0.3);
    border-color: rgba(34, 197, 94, 0.6);
    animation: pulse-audio 2s infinite;
}

@keyframes pulse-audio {
    0%, 100% { 
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    50% { 
        box-shadow: 0 0 0 10px rgba(34, 197, 94, 0);
    }
}

.volume-control {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: rgba(30, 41, 59, 0.5);
    padding: 0.5rem 1.25rem;
    border-radius: 9999px;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.volume-icon {
    font-size: 1.2rem;
}

.volume-slider {
    width: 120px;
    height: 6px;
    border-radius: 3px;
    background: rgba(71, 85, 105, 0.5);
    outline: none;
    -webkit-appearance: none;
    cursor: pointer;
}

.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.volume-slider::-webkit-slider-thumb:hover {
    background: linear-gradient(135deg, #60a5fa, #93c5fd);
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
}

.volume-slider::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.volume-slider::-moz-range-thumb:hover {
    background: linear-gradient(135deg, #60a5fa, #93c5fd);
    transform: scale(1.2);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.6);
}

.volume-text {
    font-size: 0.875rem;
    font-weight: bold;
    color: #60a5fa;
    min-width: 45px;
    text-align: right;
}

#audioStatus {
    color: #9ca3af;
    transition: color 0.3s;
}

@media (max-width: 768px) {
    .audio-player-card .flex {
        flex-direction: column;
        gap: 1rem;
    }
    
    .audio-controls {
        width: 100%;
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .volume-control {
        width: 100%;
    }
    
    .volume-slider {
        flex: 1;
    }
}

/* Petite animation au survol de la carte audio */
.audio-player-card:hover {
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s;
}
