@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;600;700;800&display=swap');

:root {
    --bg-main: #0b0f19;
    --bg-gradient: radial-gradient(circle at top, #1e1b4b 0%, #0b0f19 70%);
    --card-bg: rgba(255, 255, 255, 0.98);
    --primary: #6366f1;
    --primary-hover: #4f46e5;
    --gold: #f59e0b;
    --gold-hover: #d97706;
    --emerald: #10b981;
    --emerald-hover: #059669;
    --danger: #ef4444;
    --text-dark: #0f172a;
    --text-muted: #64748b;
    --radius-xl: 28px;
    --radius-lg: 20px;
    --radius-md: 14px;
}

* {
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    background: var(--bg-main);
    background-image: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-dark);
    margin: 0;
    padding: 12px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

body.center-page {
    justify-content: center;
    align-items: center;
}

.container {
    max-width: 580px;
    width: 100%;
    margin: 0 auto;
    flex: 1;
}

/* Felső Navigáció */
.top-nav {
    display: flex;
    justify-content: flex-start;
    max-width: 580px;
    width: 100%;
    margin: 0 auto 12px auto;
}

.btn-secondary-sm {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.9rem;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

/* Lebegő Admin Gomb */
.btn-admin-sm {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 99;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
    border: none;
    padding: 14px 22px;
    border-radius: 50px;
    font-weight: 800;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.4);
}

/* Index / Kezdőlap Kártya */
.index-card {
    background: var(--card-bg);
    border-radius: var(--radius-xl);
    padding: 35px 25px;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    text-align: center;
}

.badge-pill {
    display: inline-block;
    background: #e0e7ff;
    color: #3730a3;
    padding: 6px 16px;
    border-radius: 20px;
    font-weight: 800;
    font-size: 0.85rem;
    margin-bottom: 15px;
}

.index-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--text-dark);
    margin: 0 0 10px 0;
    line-height: 1.2;
}

.index-subtitle {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 30px;
    line-height: 1.5;
}

.index-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Kártyák Alap-stílusa */
.card {
    background: var(--card-bg);
    border-radius: var(--radius-xl);
    padding: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    margin-bottom: 20px;
}

.card-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 20px;
}

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

/* Gombok */
.btn {
    width: 100%;
    min-height: 56px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    font-size: 1.05rem;
    font-weight: 700;
    border: none;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-hero {
    min-height: 72px;
    justify-content: flex-start;
    padding: 0 20px;
    gap: 15px;
    text-align: left;
}

.btn-icon { font-size: 1.8rem; }
.btn-text-group { display: flex; flex-direction: column; }
.btn-main-text { font-size: 1.1rem; font-weight: 800; }
.btn-sub-text { font-size: 0.8rem; opacity: 0.85; font-weight: 500; }

.btn-large { font-size: 1.15rem; min-height: 60px; }
.btn-primary { background: linear-gradient(135deg, #6366f1, #4f46e5); color: white; }
.btn-gold { background: linear-gradient(135deg, #f59e0b, #d97706); color: white; }
.btn-emerald { background: linear-gradient(135deg, #10b981, #059669); color: white; }
.btn-danger { background: linear-gradient(135deg, #ef4444, #dc2626); color: white; }

/* Mezők */
.form-group { margin-bottom: 15px; }

.input-field, .textarea-field {
    width: 100%;
    padding: 16px;
    font-size: 1.05rem;
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-md);
    background: #f8fafc;
    color: #0f172a;
    outline: none;
    font-family: inherit;
}

.input-field:focus, .textarea-field:focus {
    border-color: var(--primary);
    background: #ffffff;
}

.uppercase { text-transform: uppercase; }

/* Játékkód Doboz */
.code-box {
    background: #f1f5f9;
    padding: 16px;
    border-radius: var(--radius-md);
    margin: 15px 0;
}

.code-box strong {
    display: block;
    color: var(--primary);
    font-size: 2.4rem;
    letter-spacing: 5px;
}

/* Csapat Tabletta */
.team-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    justify-content: center;
}

.team-pill {
    background: #e0e7ff;
    color: #3730a3;
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 700;
}

/* Kvíz Fejléc */
.quiz-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.q-badge {
    background: #e0e7ff;
    color: #3730a3;
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 800;
}

.timer-badge {
    background: #fee2e2;
    color: #991b1b;
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 800;
}

.question-title {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin: 0 0 20px 0;
    line-height: 1.4;
    font-weight: 800;
}

/* Válaszok Kijelölése (Kattintható Kártyák) */
.answers-header-flex {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 12px;
}

.hint-pill {
    font-size: 0.85rem;
    color: #059669;
    font-weight: 700;
}

.answers-grid { display: grid; gap: 10px; }

.answer-card {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    padding: 16px;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.answer-card.selected {
    background: #ecfdf5;
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.15);
}

.answer-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.answer-card-header h4 {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.85rem;
}

.select-indicator {
    font-size: 0.8rem;
    font-weight: 800;
    color: var(--text-muted);
}

.answer-card.selected .select-indicator {
    color: #059669;
}

.answer-text {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
}

.host-action-footer {
    margin-top: 20px;
}

/* Szünet Banner */
.paused-banner {
    background: #fef2f2;
    border: 2px solid #fca5a5;
    color: #991b1b;
    padding: 16px;
    border-radius: var(--radius-md);
    text-align: center;
    margin-bottom: 15px;
}

.paused-banner h2 { margin: 0 0 5px 0; font-size: 1.1rem; }
.paused-banner p { margin: 0; font-size: 0.85rem; }

/* Eredményjelző */
.scoreboard { display: grid; gap: 8px; margin-top: 15px; }

.score-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    padding: 12px 18px;
    border-radius: var(--radius-md);
    font-size: 1rem;
    border: 1px solid #e2e8f0;
}

.score-badge {
    background: var(--gold);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-weight: 800;
}

/* Admin Modal */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(11, 15, 25, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: flex-end;
    z-index: 1000;
}

.modal-card {
    background: white;
    width: 100%;
    max-width: 580px;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    padding: 24px;
    max-height: 85vh;
    overflow-y: auto;
}

.modal-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; }
.close-btn { background: #f1f5f9; border: none; font-size: 1.4rem; width: 36px; height: 36px; border-radius: 50%; cursor: pointer; }

.admin-section { margin-top: 15px; border-top: 1px solid #e2e8f0; padding-top: 12px; }
.admin-q-text { font-weight: 700; color: #334155; }
.admin-ans-box { display: grid; gap: 6px; }
.admin-ans-item { background: #f1f5f9; padding: 8px 12px; border-radius: 8px; font-size: 0.85rem; }

button:disabled, textarea:disabled { opacity: 0.5; cursor: not-allowed; }