/* Font Face Declaration */
@font-face {
    font-family: 'Ninja Naruto';
    src: url('../font/njnaruto.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Reset et base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', 'Arial', sans-serif;
    background: linear-gradient(135deg, rgba(10, 10, 10, 0.8) 0%, rgba(26, 26, 46, 0.8) 50%, rgba(22, 33, 62, 0.8) 100%), 
                url('../image/background.jpg') center/cover no-repeat fixed;
    color: #ffffff;
    min-height: 100vh;
    overflow-x: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo h1 {
    font-family: 'Ninja Naruto', 'Orbitron', monospace;
    font-size: 2.8rem;
    font-weight: normal;
    background: linear-gradient(45deg, #ff6b35, #f7931e, #ffd700);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(255, 107, 53, 0.5);
    letter-spacing: 2px;
}

.subtitle {
    font-size: 0.9rem;
    color: #cccccc;
    display: block;
    margin-top: -5px;
}

.nav {
    display: flex;
    align-items: center;
    gap: 30px;
}

.nav-link {
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 25px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-link:hover,
.nav-link.active {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.btn-connect {
    background: linear-gradient(45deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 25px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-connect:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* Main Content */
.main-content {
    padding: 40px 0;
}

/* Server Status */
.server-status {
    text-align: center;
    margin-bottom: 50px;
}

.server-status h2 {
    font-family: 'Ninja Naruto', 'Orbitron', monospace;
    font-size: 3.2rem;
    font-weight: normal;
    margin-bottom: 20px;
    background: linear-gradient(45deg, #ffffff, #cccccc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 3px;
}

.status-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 1.2rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

.status-dot.online {
    background: #00ff88;
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.6);
}

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

/* Server Grid */
.server-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.server-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    position: relative;
}

.server-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.3);
}

.server-image {
    height: 200px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4));
    overflow: hidden;
}

/* Thèmes spécifiques par serveur */
.server-card.fire .server-image {
    background: linear-gradient(135deg, rgba(255, 69, 0, 0.3), rgba(255, 140, 0, 0.1));
}

.server-card.wind .server-image {
    background: linear-gradient(135deg, rgba(135, 206, 235, 0.3), rgba(70, 130, 180, 0.1));
}

.server-card.iron .server-image {
    background: linear-gradient(135deg, rgba(169, 169, 169, 0.3), rgba(105, 105, 105, 0.1));
}

.server-card.sakura .server-image {
    background: linear-gradient(135deg, rgba(255, 182, 193, 0.3), rgba(255, 105, 180, 0.1));
}

.server-card.neutral .server-image {
    background: linear-gradient(135deg, rgba(128, 128, 128, 0.3), rgba(64, 64, 64, 0.1));
}

.server-icon {
    font-size: 4rem;
    font-weight: bold;
    opacity: 0.8;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
}

.server-status-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 5px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.server-status-badge.online {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
    border: 1px solid #00ff88;
}

.server-status-badge.offline {
    background: rgba(220, 53, 69, 0.2);
    color: #dc3545;
    border: 1px solid #dc3545;
}

.server-info {
    padding: 25px;
}

.server-info h3 {
    font-family: 'Ninja Naruto', 'Roboto', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 15px;
    font-weight: normal;
    letter-spacing: 1px;
}

.server-details {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 0.9rem;
    color: #cccccc;
}

.player-count {
    font-weight: 600;
    color: #00ff88;
}

.btn-join {
    width: 100%;
    padding: 12px;
    background: linear-gradient(45deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-join:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.btn-join:disabled {
    background: linear-gradient(45deg, #666666 0%, #444444 100%);
    cursor: not-allowed !important;
    opacity: 0.5;
    transform: none !important;
}

.btn-join:disabled:hover {
    transform: none !important;
    box-shadow: none !important;
}

/* Events Section */
.events-section {
    margin-bottom: 60px;
}

.events-section h2 {
    font-family: 'Ninja Naruto', 'Orbitron', monospace;
    font-size: 2.8rem;
    font-weight: normal;
    text-align: center;
    margin-bottom: 40px;
    background: linear-gradient(45deg, #ffffff, #cccccc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 2px;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}

.event-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    overflow: hidden;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.3);
}

.event-image {
    height: 150px;
    background: linear-gradient(135deg, rgba(139, 69, 19, 0.4), rgba(160, 82, 45, 0.2));
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.event-label {
    font-family: 'Ninja Naruto', 'Orbitron', monospace;
    font-size: 2.2rem;
    font-weight: normal;
    color: rgba(255, 255, 255, 0.8);
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    letter-spacing: 1px;
}

.event-status {
    position: absolute;
    top: 15px;
    left: 15px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.status-badge {
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.password {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
    border: 1px solid #ffc107;
}

.status-badge.closed {
    background: rgba(220, 53, 69, 0.2);
    color: #dc3545;
    border: 1px solid #dc3545;
}

.status-badge.online {
    background: rgba(0, 255, 136, 0.2);
    color: #00ff88;
    border: 1px solid #00ff88;
}

.event-info {
    padding: 20px;
}

.event-info h3 {
    font-family: 'Ninja Naruto', 'Roboto', sans-serif;
    font-size: 1.4rem;
    margin-bottom: 10px;
    font-weight: normal;
    letter-spacing: 1px;
}

.event-players {
    color: #cccccc;
    font-size: 0.9rem;
}

.whitelist-info {
    margin-top: 10px;
    font-size: 0.8rem;
}

.whitelist-label {
    color: #cccccc;
}

.whitelist-status.invalid {
    color: #dc3545;
    font-weight: 600;
}

/* Footer */
.footer {
    padding: 30px 0;
    margin-top: 50px;
}

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

/* Animations et effets */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design - Simplifié */
@media (max-width: 768px) {
    .server-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
    
    .events-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

/* Effets de particules en arrière-plan */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 107, 53, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(102, 126, 234, 0.2) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
}

/* Effets de brillance sur les cartes */
.server-card::before,
.event-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.server-card:hover::before,
.event-card:hover::before {
    left: 100%;
}

/* Amélioration des boutons */
.btn-join:active {
    transform: translateY(0);
}

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

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #764ba2, #667eea);
}

/* Indicateurs de performance */
.player-count {
    position: relative;
}

.player-count::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #00ff88, #00cc6a);
    border-radius: 1px;
}

/* Effets de lueur pour les éléments importants */
.server-card.fire:hover {
    box-shadow: 0 20px 40px rgba(255, 69, 0, 0.3);
}

.server-card.wind:hover {
    box-shadow: 0 20px 40px rgba(135, 206, 235, 0.3);
}

.server-card.iron:hover {
    box-shadow: 0 20px 40px rgba(169, 169, 169, 0.3);
}

.server-card.sakura:hover {
    box-shadow: 0 20px 40px rgba(255, 182, 193, 0.3);
}

.server-card.neutral:hover {
    box-shadow: 0 20px 40px rgba(128, 128, 128, 0.3);
}

/* ===== STYLES POUR LA FILE D'ATTENTE ===== */

/* Modal de file d'attente */
.queue-modal .modal-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    padding: 0;
    border-radius: 20px;
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
}

.queue-header {
    background: linear-gradient(45deg, #667eea, #764ba2);
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.queue-icon {
    font-size: 2rem;
    margin-right: 15px;
}

.queue-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

.queue-info {
    padding: 25px;
    max-height: 60vh;
    overflow-y: auto;
}

.queue-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.stat-item {
    text-align: center;
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: #cccccc;
    margin-bottom: 8px;
}

.stat-value {
    display: block;
    font-size: 1.4rem;
    font-weight: 700;
    color: #00ff88;
}

.position-value {
    color: #ffc107;
}

.time-value {
    color: #ff6b35;
}

.queue-progress {
    margin-bottom: 25px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(45deg, #00ff88, #00cc6a);
    border-radius: 4px;
    transition: width 0.5s ease;
}

.progress-text {
    text-align: center;
    font-size: 0.9rem;
    color: #cccccc;
    margin: 0;
}

.queue-list h4 {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: #ffffff;
}

.queue-users {
    max-height: 200px;
    overflow-y: auto;
}

.queue-user {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.queue-user:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
}

.queue-user.current-user {
    background: rgba(255, 193, 7, 0.2);
    border-color: #ffc107;
    box-shadow: 0 0 15px rgba(255, 193, 7, 0.3);
}

.user-position {
    font-weight: 700;
    color: #ffc107;
    min-width: 30px;
}

.user-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    margin: 0 10px 0 5px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.queue-user.current-user .user-avatar {
    border-color: #ffc107;
    box-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
}

.user-name {
    flex: 1;
    margin: 0 15px 0 0;
    font-weight: 500;
}

.user-wait {
    font-size: 0.9rem;
    color: #cccccc;
}

.queue-more {
    text-align: center;
    padding: 10px;
    color: #cccccc;
    font-style: italic;
}

.queue-actions {
    padding: 20px 25px;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    gap: 15px;
    justify-content: space-between;
}

.btn-leave-queue,
.btn-minimize {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.btn-leave-queue {
    background: linear-gradient(45deg, #dc3545, #c82333);
    color: white;
}

.btn-leave-queue:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(220, 53, 69, 0.4);
}

.btn-minimize {
    background: linear-gradient(45deg, #6c757d, #5a6268);
    color: white;
}

.btn-minimize:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 117, 125, 0.4);
}

/* Notification de file d'attente minimisée */
.queue-notification {
    animation: slideInRight 0.3s ease;
}

.queue-mini-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.queue-mini-icon {
    font-size: 1.2rem;
}

.queue-mini-text {
    font-weight: 600;
    flex: 1;
}

.queue-mini-expand,
.queue-mini-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background 0.3s ease;
}

.queue-mini-expand:hover,
.queue-mini-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.queue-mini-close {
    padding: 5px 8px;
    margin-left: 5px;
}

/* Animation pour la notification */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Scrollbar personnalisée pour les listes de file d'attente */
.queue-users::-webkit-scrollbar,
.queue-info::-webkit-scrollbar {
    width: 6px;
}

.queue-users::-webkit-scrollbar-track,
.queue-info::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.queue-users::-webkit-scrollbar-thumb,
.queue-info::-webkit-scrollbar-thumb {
    background: linear-gradient(45deg, #667eea, #764ba2);
    border-radius: 3px;
}

.queue-users::-webkit-scrollbar-thumb:hover,
.queue-info::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(45deg, #764ba2, #667eea);
}

/* Responsive pour la modal de file d'attente */
@media (max-width: 768px) {
    .queue-modal .modal-content {
        width: 95%;
        max-height: 90vh;
    }
    
    .queue-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .queue-actions {
        flex-direction: column;
    }
    
    .queue-notification {
        bottom: 10px;
        right: 10px;
        left: 10px;
        width: auto;
    }
    
    .queue-mini-info {
        flex-wrap: wrap;
        gap: 8px;
    }
}
