/* VORTEX GAME CSS V5.0 - DUEL & CHAT UPDATE */

:root {
    --vortex-bg: #0f0c29;
    --vortex-primary: #a29bfe;
    --vortex-secondary: #6c5ce7;
    --vortex-gold: #ffd700;
    --vortex-danger: #ff4d4d;
}

#vortex-game-container {
    font-family: 'Segoe UI', sans-serif;
    display: flex; justify-content: center; align-items: center;
    min-height: 600px;
}

#vortex-card {
    width: 100%; max-width: 400px; height: 750px;
    background: radial-gradient(circle at top, #302b63, #0f0c29);
    border-radius: 20px;
    box-shadow: 0 0 30px rgba(108, 92, 231, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative; overflow: hidden; color: white;
    /* FLEXBOX - EZ TARTJA EGYBEN A LAYOUTOT */
    display: flex; flex-direction: column;
    transition: all 0.3s ease; /* Háttérkép cseréhez finom átmenet */
    background-size: cover;
    background-position: center;
}

/* --- 1. ÚJ DUEL HEADER (VS MÓD) --- */
/* Ez váltja ki a régi sima headert a párbajban */
.duel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: rgba(0, 0, 0, 0.7); /* Sötétebb alap, hogy olvasható legyen */
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    height: 85px;
    flex-shrink: 0; /* Ne nyomódjon össze */
    z-index: 50;
}

.duel-player {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    width: 80px;
}

.duel-avatar-frame {
    width: 50px;
    height: 50px;
    position: relative;
    border-radius: 50%;
    margin-bottom: 5px;
    background: rgba(0,0,0,0.5);
}

.duel-avatar-frame img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

.duel-name {
    font-size: 10px;
    font-weight: bold;
    color: #fff;
    text-transform: uppercase;
    text-shadow: 0 1px 2px #000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.duel-stats-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.duel-vs {
    font-size: 20px;
    font-weight: 900;
    font-style: italic;
    color: var(--vortex-gold);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.5);
    line-height: 1;
}

.duel-streak-badge {
    background: #ff4d4d;
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: bold;
    box-shadow: 0 0 5px red;
}

.duel-coin-badge {
    color: var(--vortex-gold);
    font-size: 12px;
    font-weight: bold;
    text-shadow: 0 1px 2px #000;
}

/* --- 2. CHAT ALAPÚ JÁTÉK --- */
/* Ez helyettesíti a régi question-boxot és chat-areát párbajban */
#duel-chat-area {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    /* Átlátszó háttér, hogy a Shopban vett téma látszódjon */
    background: rgba(0,0,0,0.2); 
    scroll-behavior: smooth;
}

.chat-bubble {
    padding: 12px 15px;
    border-radius: 15px;
    max-width: 85%;
    font-size: 14px;
    line-height: 1.4;
    position: relative;
    animation: fadeIn 0.3s ease;
    word-wrap: break-word;
}

/* Rendszerüzenet (pl. "Válaszoltál...") */
.chat-bubble.system {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid #444;
    align-self: center;
    color: #ccc;
    font-size: 12px;
    font-style: italic;
    text-align: center;
}

/* Kérdés buborék (Kiemelt!) */
.chat-bubble.question {
    background: rgba(139, 92, 246, 0.95); /* Primary color erősebben */
    align-self: flex-start; /* Bal oldalon */
    color: white;
    border-bottom-left-radius: 2px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.3);
    font-weight: 500;
}

/* Spam buborék (Sabotage effekt) */
.chat-bubble.spam {
    background: rgba(255, 0, 0, 0.2);
    align-self: center;
    color: #ffcccc;
    font-family: monospace;
    font-size: 11px;
    border: 1px dashed red;
    width: 100%;
    text-align: center;
}

/* --- 3. DINAMIKUS IDŐZÍTŐ --- */
#duel-timer-bar { 
    height: 8px; 
    width: 100%; 
    background: #333; 
    transition: width 0.1s linear, background-color 0.3s ease;
    margin-bottom: 0; 
}

/* Szín kódok a logikához */
.timer-gold { background: #ffd700 !important; box-shadow: 0 0 15px #ffd700; }
.timer-blue { background: #00d4ff !important; box-shadow: 0 0 10px #00d4ff; }
.timer-red  { background: #ff4d4d !important; box-shadow: 0 0 15px #ff4d4d; }


/* --- 4. INPUT (Válasz gombok) --- */
#vortex-input-area {
    flex: 0 0 auto;
    padding: 15px;
    background: rgba(15, 12, 41, 0.95);
    display: flex; 
    gap: 10px;
    border-top: 1px solid rgba(255,255,255,0.1);
    z-index: 60;
}

/* --- 5. GAME OVER (GOLD DESIGN) --- */
.gold-overlay {
    background: radial-gradient(circle, #ffd700 0%, #b8860b 100%);
    color: #000;
}

.gold-title {
    font-size: 32px;
    font-weight: 900;
    text-transform: uppercase;
    text-shadow: 0 2px 0 rgba(255,255,255,0.4);
    margin-bottom: 20px;
    letter-spacing: 2px;
}

/* Animációk */
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }