/* ========== Variables ========== */
:root {
    --bg-primary: #0a0e14;
    --bg-secondary: #12181f;
    --bg-tertiary: #1a222b;
    --bg-elevated: #1e2731;
    --accent: #ff4655;
    --accent-hover: #ff5a67;
    --accent-glow: rgba(255, 70, 85, 0.4);
    --text-primary: #ffffff;
    --text-secondary: #a0aab4;
    --text-muted: #6b7785;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.12);
    --success: #4ade80;
    --warning: #fbbf24;
    --error: #ef4444;
    --sidebar-width: 280px;

    /* Gradients */
    --gradient-accent: linear-gradient(135deg, #ff4655 0%, #ff6b7a 100%);
    --gradient-blue: linear-gradient(135deg, #3b82f6 0%, #60a5fa 100%);
    --gradient-purple: linear-gradient(135deg, #8b5cf6 0%, #a78bfa 100%);
    --gradient-emerald: linear-gradient(135deg, #10b981 0%, #34d399 100%);
    --gradient-amber: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
    --gradient-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);

    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);

    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 30px rgba(255, 70, 85, 0.2);
}

/* ========== Reset & Base ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Rajdhani', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    line-height: 1.6;
}

/* ========== Login Screen ========== */
.login-screen {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background:
        radial-gradient(ellipse at top left, rgba(255, 70, 85, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at bottom right, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
        linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
}

.login-container {
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 48px;
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow-lg);
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    width: 90px;
    height: 90px;
    margin-bottom: 24px;
    filter: drop-shadow(0 0 20px rgba(255, 70, 85, 0.3));
}

.login-header h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    color: var(--accent);
    margin-bottom: 10px;
    text-shadow: 0 0 30px rgba(255, 70, 85, 0.3);
}

.login-header p {
    color: var(--text-secondary);
    font-size: 1.05rem;
}

.login-form .form-group {
    margin-bottom: 24px;
}

.login-form label {
    display: block;
    margin-bottom: 10px;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.95rem;
}

.password-input-wrapper {
    position: relative;
}

.password-input-wrapper input {
    width: 100%;
    padding: 16px 50px 16px 18px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 14px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.password-input-wrapper input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(255, 70, 85, 0.15);
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    transition: color 0.2s;
}

.toggle-password:hover {
    color: var(--accent);
}

.login-footer {
    text-align: center;
    margin-top: 28px;
}

.login-footer a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s;
}

.login-footer a:hover {
    color: var(--accent);
}

.error-message {
    color: var(--error);
    font-size: 0.9rem;
    text-align: center;
    margin-top: 12px;
}

/* ========== Admin Panel Layout ========== */
.admin-panel {
    display: flex;
    min-height: 100vh;
}

/* ========== Sidebar ========== */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.sidebar-header {
    padding: 32px 28px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.sidebar-logo {
    width: 70px;
    height: 70px;
    margin-bottom: 14px;
    filter: drop-shadow(0 0 15px rgba(255, 70, 85, 0.2));
}

.sidebar-header h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.15rem;
    color: var(--accent);
    text-shadow: 0 0 20px rgba(255, 70, 85, 0.2);
}

.sidebar-nav {
    flex: 1;
    padding: 28px 20px;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 16px 20px;
    background: transparent;
    border: none;
    border-radius: 14px;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 10px;
}

.nav-item:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    transform: translateX(4px);
}

.nav-item.active {
    background: var(--gradient-accent);
    color: white;
    box-shadow: 0 4px 20px rgba(255, 70, 85, 0.3);
}

.nav-item i {
    font-size: 1.15rem;
    width: 24px;
}

.sidebar-footer {
    padding: 24px 20px;
    border-top: 1px solid var(--border);
}

/* ========== Main Content ========== */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    background:
        radial-gradient(ellipse at top right, rgba(255, 70, 85, 0.05) 0%, transparent 50%),
        var(--bg-primary);
}

.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 28px 40px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
}

.main-header h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.6rem;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.user-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    font-size: 0.95rem;
    color: var(--text-secondary);
    backdrop-filter: blur(10px);
}

.user-badge i {
    color: var(--accent);
}

/* ========== Tab Content ========== */
.tab-content {
    display: none;
    padding: 40px;
}

.tab-content.active {
    display: block;
}

/* ========== Cards ========== */
.card {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 28px;
    transition: all 0.3s ease;
}

.card:hover {
    border-color: var(--border-light);
    box-shadow: var(--shadow-md);
}

.card-header {
    padding: 22px 28px;
    border-bottom: 1px solid var(--border);
    background: var(--bg-tertiary);
}

.card-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.card-header h3 i {
    color: var(--accent);
    font-size: 1.1rem;
}

.card-body {
    padding: 28px;
}

/* ========== Dashboard Grid ========== */
.dashboard-grid {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

/* ========== Stats Row - Premium 2025 Design ========== */
.stats-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.stat-card {
    position: relative;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 28px;
    display: flex;
    align-items: center;
    gap: 22px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    border-radius: 20px 20px 0 0;
}

.stat-card:nth-child(1)::before {
    background: var(--gradient-accent);
}

.stat-card:nth-child(2)::before {
    background: var(--gradient-blue);
}

.stat-card:nth-child(3)::before {
    background: var(--gradient-purple);
}

.stat-card:nth-child(4)::before {
    background: var(--gradient-emerald);
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    opacity: 0.05;
    transition: all 0.4s ease;
}

.stat-card:nth-child(1)::after {
    background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
}

.stat-card:nth-child(2)::after {
    background: radial-gradient(circle, #3b82f6 0%, transparent 70%);
}

.stat-card:nth-child(3)::after {
    background: radial-gradient(circle, #8b5cf6 0%, transparent 70%);
}

.stat-card:nth-child(4)::after {
    background: radial-gradient(circle, #10b981 0%, transparent 70%);
}

.stat-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-light);
    box-shadow: var(--shadow-lg);
}

.stat-card:hover::after {
    opacity: 0.1;
    width: 200px;
    height: 200px;
}

.stat-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    color: white;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
}

.stat-card:nth-child(1) .stat-icon {
    background: var(--gradient-accent);
    box-shadow: 0 8px 24px rgba(255, 70, 85, 0.35);
}

.stat-card:nth-child(2) .stat-icon {
    background: var(--gradient-blue);
    box-shadow: 0 8px 24px rgba(59, 130, 246, 0.35);
}

.stat-card:nth-child(3) .stat-icon {
    background: var(--gradient-purple);
    box-shadow: 0 8px 24px rgba(139, 92, 246, 0.35);
}

.stat-card:nth-child(4) .stat-icon {
    background: var(--gradient-emerald);
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.35);
}

.stat-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
    z-index: 1;
}

.stat-value {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.4rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.1;
}

.stat-label {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ========== Countdown - Premium Glowing Design ========== */
.countdown-display {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 40px 30px;
    background:
        radial-gradient(ellipse at center, rgba(255, 70, 85, 0.08) 0%, transparent 60%),
        var(--bg-tertiary);
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.countdown-display::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-glass);
    pointer-events: none;
}

.countdown-item {
    text-align: center;
    padding: 24px 32px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 18px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    min-width: 130px;
}

.countdown-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 3px;
    background: var(--gradient-accent);
    border-radius: 0 0 4px 4px;
}

.countdown-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40%;
    height: 30px;
    background: radial-gradient(ellipse at top, rgba(255, 70, 85, 0.3) 0%, transparent 70%);
    pointer-events: none;
}

.countdown-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(255, 70, 85, 0.15);
    border-color: rgba(255, 70, 85, 0.3);
}

.countdown-value {
    display: block;
    font-family: 'Orbitron', sans-serif;
    font-size: 3.2rem;
    font-weight: 800;
    color: var(--accent);
    text-shadow: 0 0 40px rgba(255, 70, 85, 0.5);
    line-height: 1.1;
    margin-bottom: 8px;
    position: relative;
    z-index: 1;
}

.countdown-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    position: relative;
    z-index: 1;
}

.countdown-separator {
    font-family: 'Orbitron', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    color: var(--accent);
    text-shadow: 0 0 30px rgba(255, 70, 85, 0.4);
    animation: pulse-separator 1s ease-in-out infinite;
    align-self: flex-start;
    margin-top: 20px;
}

@keyframes pulse-separator {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

/* ========== Quick Actions - Modern Button Grid ========== */
.quick-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 10px;
}

.action-btn {
    position: relative;
    padding: 28px 24px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 18px;
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-accent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.action-btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 60%);
    opacity: 0;
    transform: scale(0);
    transition: all 0.6s ease;
}

.action-btn:hover {
    transform: translateY(-6px);
    border-color: var(--accent);
    box-shadow: 0 16px 40px rgba(255, 70, 85, 0.25);
}

.action-btn:hover::before {
    opacity: 1;
}

.action-btn:hover::after {
    opacity: 1;
    transform: scale(1);
}

.action-btn i {
    font-size: 1.8rem;
    position: relative;
    z-index: 1;
    transition: transform 0.4s ease;
}

.action-btn:hover i {
    transform: scale(1.15);
}

.action-btn span,
.action-btn {
    position: relative;
    z-index: 1;
}

/* ========== Settings Grid ========== */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
    gap: 28px;
}

/* ========== Teams Grid ========== */
.teams-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
}

.teams-grid .card.full-width {
    grid-column: 1 / -1;
}

/* ========== Matches Grid ========== */
.matches-grid {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: 28px;
}

.matches-grid .card.full-width {
    grid-column: 1 / -1;
}

/* ========== Standings Grid ========== */
.standings-grid {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* ========== Form Styles ========== */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(255, 70, 85, 0.12);
}

.form-group input::placeholder {
    color: var(--text-muted);
}

.player-inputs {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    accent-color: var(--accent);
}

/* ========== Buttons ========== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: var(--gradient-accent);
    color: white;
    box-shadow: 0 4px 15px rgba(255, 70, 85, 0.25);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 70, 85, 0.4);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(255, 70, 85, 0.05);
}

.btn-accent {
    background: var(--gradient-accent);
    color: white;
    box-shadow: 0 4px 20px rgba(255, 70, 85, 0.3);
}

.btn-accent:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(255, 70, 85, 0.45);
}

.btn-full {
    width: 100%;
}

.btn-large {
    padding: 18px 36px;
    font-size: 1.1rem;
}

/* ========== Teams List ========== */
.teams-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.team-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: all 0.3s ease;
}

.team-item:hover {
    background: var(--bg-elevated);
    border-color: var(--border-light);
    transform: translateX(4px);
}

.team-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

.team-name {
    font-weight: 600;
    font-size: 1.1rem;
}

.team-group {
    padding: 6px 14px;
    background: var(--gradient-accent);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
}

.team-actions {
    display: flex;
    gap: 10px;
}

.team-actions button {
    padding: 10px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.team-actions button:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(255, 70, 85, 0.08);
}

.team-actions button.delete:hover {
    border-color: var(--error);
    color: var(--error);
    background: rgba(239, 68, 68, 0.08);
}

/* ========== Matches List ========== */
.matches-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.match-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: all 0.3s ease;
}

.match-item:hover {
    border-color: var(--border-light);
}

.match-teams {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.match-team {
    font-weight: 500;
    min-width: 120px;
}

.match-vs {
    color: var(--accent);
    font-weight: 700;
}

.match-score {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    font-weight: 700;
    padding: 0 20px;
}

.match-group {
    padding: 6px 14px;
    background: var(--bg-secondary);
    border-radius: 20px;
    font-size: 0.85rem;
}

.match-actions {
    display: flex;
    gap: 10px;
}

.match-actions button {
    padding: 10px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.match-actions button:hover {
    border-color: var(--accent);
    color: var(--accent);
}

/* ========== Unassigned Teams ========== */
.unassigned-teams-list {
    margin: 18px 0;
    padding: 20px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 14px;
    min-height: 70px;
}

.unassigned-team {
    display: inline-block;
    padding: 8px 16px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 20px;
    margin: 5px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.unassigned-team:hover {
    border-color: var(--accent);
}

.no-teams, .no-data {
    color: var(--text-muted);
    text-align: center;
    padding: 24px;
}

.info-text {
    color: var(--text-secondary);
    margin-bottom: 12px;
    font-weight: 500;
}

/* ========== Modal ========== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 24px;
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 28px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-header h3 i {
    color: var(--accent);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.6rem;
    cursor: pointer;
    transition: all 0.2s;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    color: var(--accent);
    background: rgba(255, 70, 85, 0.1);
}

.modal-body {
    padding: 28px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 14px;
    padding: 24px 28px;
    border-top: 1px solid var(--border);
}

/* ========== Score Modal ========== */
.score-input-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 36px;
    padding: 24px;
}

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

.score-team .team-name {
    display: block;
    font-weight: 600;
    margin-bottom: 18px;
    font-size: 1.15rem;
}

.score-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}

.score-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--border);
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 1.6rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.score-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.score-btn.minus:hover {
    border-color: var(--error);
    color: var(--error);
}

.score-btn.plus:hover {
    border-color: var(--success);
    color: var(--success);
}

.score-input {
    width: 80px;
    height: 80px;
    text-align: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
    background: var(--bg-tertiary);
    border: 2px solid var(--border);
    border-radius: 16px;
    color: var(--text-primary);
}

.score-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px rgba(255, 70, 85, 0.15);
}

.score-vs {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    color: var(--accent);
    text-shadow: 0 0 20px rgba(255, 70, 85, 0.3);
}

.quick-scores {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 24px;
}

.quick-score-btn {
    padding: 12px 22px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.quick-score-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(255, 70, 85, 0.08);
}

/* ========== Lottery Modal ========== */
.lottery-modal {
    max-width: 720px;
}

.lottery-container {
    min-height: 320px;
}

.lottery-balls {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    justify-content: center;
    padding: 24px;
    background: var(--bg-tertiary);
    border-radius: 16px;
    min-height: 160px;
}

.lottery-ball {
    width: 85px;
    height: 85px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.8rem;
    text-align: center;
    padding: 6px;
    color: white;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
    animation: bounce 1s ease-in-out infinite;
}

.lottery-ball:nth-child(1) { background: linear-gradient(135deg, #ff4655, #ff6b7a); animation-delay: 0s; }
.lottery-ball:nth-child(2) { background: linear-gradient(135deg, #4f46e5, #6366f1); animation-delay: 0.1s; }
.lottery-ball:nth-child(3) { background: linear-gradient(135deg, #10b981, #34d399); animation-delay: 0.2s; }
.lottery-ball:nth-child(4) { background: linear-gradient(135deg, #f59e0b, #fbbf24); animation-delay: 0.3s; }
.lottery-ball:nth-child(5) { background: linear-gradient(135deg, #ec4899, #f472b6); animation-delay: 0.4s; }
.lottery-ball:nth-child(6) { background: linear-gradient(135deg, #06b6d4, #22d3ee); animation-delay: 0.5s; }
.lottery-ball:nth-child(7) { background: linear-gradient(135deg, #8b5cf6, #a78bfa); animation-delay: 0.6s; }
.lottery-ball:nth-child(8) { background: linear-gradient(135deg, #f97316, #fb923c); animation-delay: 0.7s; }

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-12px); }
}

.lottery-ball.drawn {
    animation: draw 0.5s ease-out forwards;
}

@keyframes draw {
    0% { transform: scale(1); }
    50% { transform: scale(1.35); }
    100% { transform: scale(0); opacity: 0; }
}

.lottery-results {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-top: 24px;
}

.lottery-group {
    background: var(--bg-tertiary);
    border-radius: 14px;
    padding: 18px;
    text-align: center;
}

.lottery-group h4 {
    color: var(--accent);
    margin-bottom: 12px;
    font-size: 1.05rem;
}

.lottery-group-teams {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lottery-group-team {
    padding: 10px;
    background: var(--bg-secondary);
    border-radius: 8px;
    font-size: 0.88rem;
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: translateY(0); }
}

.lottery-actions {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-top: 24px;
}

/* ========== Standings ========== */
.standings-display {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
}

.standings-group {
    background: var(--bg-tertiary);
    border-radius: 14px;
    overflow: hidden;
}

.standings-group-header {
    padding: 16px 20px;
    background: var(--gradient-accent);
    font-weight: 700;
    text-align: center;
}

.standings-table {
    width: 100%;
    border-collapse: collapse;
}

.standings-table th,
.standings-table td {
    padding: 14px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.standings-table th {
    background: var(--bg-secondary);
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.standings-table td:first-child {
    text-align: left;
    padding-left: 20px;
}

/* ========== Responsive ========== */
@media (max-width: 1200px) {
    .stats-row {
        grid-template-columns: repeat(2, 1fr);
    }

    .quick-actions {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 1024px) {
    .teams-grid {
        grid-template-columns: 1fr;
    }

    .matches-grid {
        grid-template-columns: 1fr;
    }

    .lottery-results {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        height: auto;
        position: relative;
    }

    .main-content {
        margin-left: 0;
    }

    .stats-row {
        grid-template-columns: 1fr;
    }

    .quick-actions {
        grid-template-columns: 1fr;
    }

    .countdown-display {
        flex-wrap: wrap;
        gap: 16px;
    }

    .countdown-item {
        min-width: 110px;
        padding: 18px 24px;
    }

    .countdown-value {
        font-size: 2.4rem;
    }

    .countdown-separator {
        display: none;
    }

    .score-input-container {
        flex-direction: column;
        gap: 24px;
    }

    .lottery-results {
        grid-template-columns: 1fr;
    }

    .tab-content {
        padding: 24px;
    }
}

/* ========== Toast Notifications ========== */
.toast {
    position: fixed;
    top: 24px;
    right: 24px;
    padding: 18px 28px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 14px;
    display: flex;
    align-items: center;
    gap: 14px;
    z-index: 2000;
    transform: translateX(420px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-lg);
}

.toast.show {
    transform: translateX(0);
    opacity: 1;
}

.toast.success {
    border-color: var(--success);
}

.toast.success i {
    color: var(--success);
}

.toast.error {
    border-color: var(--error);
}

.toast.error i {
    color: var(--error);
}

.toast.info {
    border-color: var(--warning);
}

.toast.info i {
    color: var(--warning);
}

.toast i {
    font-size: 1.3rem;
}

/* ========== Player Input Rows ========== */
.player-input-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.player-input-row .form-group {
    margin-bottom: 0;
    flex: 1;
}

.player-input-row .tag-input {
    max-width: 110px;
}

.player-number {
    width: 32px;
    height: 32px;
    background: var(--gradient-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(255, 70, 85, 0.3);
}

.hash-separator {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-secondary);
    flex-shrink: 0;
}

/* ========== Checkbox Grid ========== */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.checkbox-label:hover {
    background: var(--bg-elevated);
    border-color: var(--border-light);
}

.checkbox-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--accent);
    cursor: pointer;
}

/* ========== Card Header Actions ========== */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header-actions select {
    padding: 10px 14px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.card-header-actions select:focus {
    outline: none;
    border-color: var(--accent);
}

/* ========== Winner Indicator ========== */
.winner-indicator {
    text-align: center;
    padding: 18px;
    margin-top: 12px;
    font-size: 1.15rem;
    font-weight: 600;
}

.winner-indicator i {
    margin-right: 10px;
}

/* ========== Score Team States ========== */
.score-team.winner {
    background: rgba(74, 222, 128, 0.12);
    border-radius: 16px;
    padding: 18px;
}

.score-team.winner .team-name {
    color: var(--success);
}

.score-team.loser {
    opacity: 0.55;
}

/* ========== Empty State ========== */
.empty-state {
    text-align: center;
    padding: 48px;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 3.5rem;
    margin-bottom: 18px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1.05rem;
}

.empty-state.small {
    padding: 24px;
}

.empty-state.small i {
    font-size: 1.6rem;
    margin-bottom: 12px;
    color: var(--success);
    opacity: 1;
}

/* ========== Group Section ========== */
.group-section {
    margin-bottom: 24px;
    border: 1px solid var(--border);
    border-radius: 14px;
    overflow: hidden;
}

.group-section-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    background: var(--bg-tertiary);
    font-weight: 600;
}

.group-section-header .letter {
    width: 36px;
    height: 36px;
    background: var(--gradient-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
    box-shadow: 0 4px 12px rgba(255, 70, 85, 0.3);
}

/* ========== Team Players ========== */
.team-players {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.team-players span {
    padding: 6px 12px;
    background: var(--bg-secondary);
    border-radius: 18px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

/* ========== Button Sizes ========== */
.btn-sm {
    padding: 8px 14px;
    font-size: 0.88rem;
}

.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-secondary {
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-elevated);
    border-color: var(--accent);
    color: var(--accent);
}

.btn-danger {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.12);
    border-color: var(--error);
    color: var(--error);
}

/* ========== Match Items ========== */
.match-item {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 24px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 14px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
}

.match-item:hover {
    border-color: var(--border-light);
}

.match-item.completed {
    border-left: 4px solid var(--success);
}

.match-item.pending {
    border-left: 4px solid var(--warning);
}

.match-group-badge {
    width: 40px;
    height: 40px;
    background: var(--gradient-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.95rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(255, 70, 85, 0.3);
}

.match-info {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 14px;
}

.match-team {
    font-weight: 500;
    min-width: 110px;
}

.match-team.winner {
    color: var(--success);
    font-weight: 700;
}

.match-vs {
    color: var(--accent);
    font-weight: 700;
    font-size: 0.95rem;
}

.match-score {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    padding: 10px 18px;
    background: var(--bg-secondary);
    border-radius: 10px;
}

.match-status {
    padding: 8px 14px;
    border-radius: 18px;
    font-size: 0.88rem;
    font-weight: 500;
}

.match-status.pending {
    background: rgba(251, 191, 36, 0.15);
    color: var(--warning);
}

.match-actions {
    display: flex;
    gap: 10px;
}

/* ========== Unassigned Teams List ========== */
.unassigned-team-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: 12px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.unassigned-team-item:hover {
    border-color: var(--border-light);
}

.unassigned-team-item .team-icon {
    color: var(--accent);
}

.unassigned-team-item .team-name {
    flex: 1;
    font-weight: 500;
}

.unassigned-team-item .player-count {
    font-size: 0.88rem;
    color: var(--text-muted);
}

/* ========== Lottery Styles ========== */
.lottery-container {
    position: relative;
    min-height: 420px;
}

#lotteryBallContainer {
    position: relative;
    height: 220px;
    background: var(--bg-tertiary);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 24px;
}

.lottery-ball {
    position: absolute;
    width: 75px;
    height: 75px;
    background: var(--ball-color, var(--accent));
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 700;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
    transition: all 0.3s ease;
    cursor: default;
}

.lottery-ball .ball-text {
    font-size: 0.95rem;
}

.lottery-ball .ball-full-name {
    font-size: 0.65rem;
    opacity: 0.8;
    max-width: 65px;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.lottery-ball.bouncing {
    animation: lottery-bounce 0.5s ease-in-out infinite alternate;
}

@keyframes lottery-bounce {
    from { transform: translateY(0); }
    to { transform: translateY(-18px); }
}

.lottery-ball.drawn {
    animation: none;
}

.lottery-ball.flash {
    animation: ball-flash 0.5s ease-out;
}

@keyframes ball-flash {
    0% { transform: scale(1); box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.8); }
    50% { transform: scale(1.35); box-shadow: 0 0 35px 12px rgba(255, 255, 255, 0.6); }
    100% { transform: scale(0); opacity: 0; }
}

/* Lottery Groups */
.lottery-groups {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 18px;
}

.lottery-group {
    background: var(--bg-tertiary);
    border-radius: 14px;
    padding: 18px;
}

.lottery-group-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
    font-size: 1.05rem;
    color: var(--text-primary);
}

.lottery-group-title .group-letter {
    width: 32px;
    height: 32px;
    background: var(--gradient-accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(255, 70, 85, 0.3);
}

.lottery-group-teams {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lottery-team-result {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: var(--bg-secondary);
    border-radius: 10px;
}

.lottery-team-result .team-ball {
    width: 28px;
    height: 28px;
    background: var(--ball-color, var(--accent));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: white;
}

.lottery-team-result .team-name {
    font-size: 0.95rem;
    font-weight: 500;
}

.lottery-team-result.appear {
    animation: result-appear 0.5s ease-out;
}

@keyframes result-appear {
    from { opacity: 0; transform: translateY(-12px) scale(0.8); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.lottery-container.lottery-complete {
    animation: container-pulse 0.5s ease-out;
}

@keyframes container-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

/* Confetti Animation */
@keyframes confetti-fall {
    0% {
        transform: translate(0, 0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translate(var(--x-end), var(--y-end)) rotate(var(--rotation));
        opacity: 0;
    }
}

/* ========== Standings Improvements ========== */
.standings-group {
    margin-bottom: 24px;
}

.standings-group-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 24px;
    background: var(--gradient-accent);
    border-radius: 14px 14px 0 0;
    font-weight: 700;
}

.standings-group-header i {
    color: white;
}

.standings-table tr.qualified {
    background: rgba(74, 222, 128, 0.12);
}

.standings-table .rank {
    font-weight: 700;
    color: var(--accent);
}

.standings-table .points {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    color: var(--accent);
}

.standings-table .diff.positive {
    color: var(--success);
}

.standings-table .diff.negative {
    color: var(--error);
}

/* ========== Scrollbar Styling ========== */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border);
}

/* ========== Selection ========== */
::selection {
    background: rgba(255, 70, 85, 0.3);
    color: white;
}

/* ========== Focus States ========== */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

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

.stat-card {
    animation: fadeInUp 0.5s ease-out;
}

.stat-card:nth-child(1) { animation-delay: 0s; }
.stat-card:nth-child(2) { animation-delay: 0.1s; }
.stat-card:nth-child(3) { animation-delay: 0.2s; }
.stat-card:nth-child(4) { animation-delay: 0.3s; }

/* ========================================== */
/* PREMIUM LOTTERY WHEEL STYLES              */
/* ========================================== */

/* Modal Fullscreen Styling */
.lottery-wheel-modal {
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
}

.lottery-wheel-modal.active {
    display: flex;
    animation: modalFadeIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.lottery-wheel-content {
    max-width: 1600px;
    width: 95vw;
    max-height: 95vh;
    background: linear-gradient(180deg, #0d1117 0%, #0a0e14 50%, #0d1117 100%);
    border: 1px solid rgba(255, 70, 85, 0.3);
    border-radius: 24px;
    box-shadow:
        0 0 100px rgba(255, 70, 85, 0.15),
        0 0 200px rgba(255, 70, 85, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    overflow: hidden;
    animation: contentSlideIn 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes contentSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(40px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Header Styling */
.lottery-wheel-header {
    background: linear-gradient(180deg, rgba(255, 70, 85, 0.1) 0%, transparent 100%);
    border-bottom: 1px solid rgba(255, 70, 85, 0.2);
    padding: 24px 32px;
    position: relative;
    overflow: hidden;
}

.lottery-wheel-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.lottery-title-container {
    position: relative;
    text-align: center;
}

.lottery-title-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 100px;
    background: radial-gradient(ellipse, rgba(255, 70, 85, 0.3) 0%, transparent 70%);
    pointer-events: none;
    animation: titleGlowPulse 3s ease-in-out infinite;
}

@keyframes titleGlowPulse {
    0%, 100% { opacity: 0.5; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

.lottery-wheel-header h3 {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    font-weight: 900;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 8px;
    margin: 0;
    text-shadow:
        0 0 30px rgba(255, 70, 85, 0.5),
        0 0 60px rgba(255, 70, 85, 0.3);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.lottery-wheel-header h3 i {
    color: var(--accent);
    font-size: 1.6rem;
    animation: trophyPulse 2s ease-in-out infinite;
}

@keyframes trophyPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.lottery-subtitle {
    font-family: 'Rajdhani', sans-serif;
    font-size: 1rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-top: 8px;
}

/* Body Styling */
.lottery-wheel-body {
    padding: 24px 32px 32px;
    position: relative;
    overflow: hidden;
    min-height: 600px;
}

/* Particle Background */
.lottery-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.lottery-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--accent);
    border-radius: 50%;
    opacity: 0.3;
    animation: particleFloat 15s linear infinite;
}

@keyframes particleFloat {
    0% { transform: translateY(100%) translateX(0) scale(0); opacity: 0; }
    10% { opacity: 0.5; transform: scale(1); }
    90% { opacity: 0.3; }
    100% { transform: translateY(-100vh) translateX(100px) scale(0.5); opacity: 0; }
}

/* Main Layout */
.lottery-main-layout {
    display: grid;
    grid-template-columns: 280px 1fr 280px;
    gap: 32px;
    align-items: start;
    position: relative;
    z-index: 1;
}

/* Groups Panel Styling */
.lottery-groups-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.lottery-group-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.lottery-group-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-accent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.lottery-group-card.active {
    border-color: rgba(255, 70, 85, 0.5);
    box-shadow:
        0 0 30px rgba(255, 70, 85, 0.2),
        inset 0 0 30px rgba(255, 70, 85, 0.05);
}

.lottery-group-card.active::before {
    opacity: 1;
}

.lottery-group-card.filled {
    border-color: rgba(74, 222, 128, 0.4);
}

.lottery-group-card.filled::before {
    background: var(--gradient-emerald);
    opacity: 1;
}

.group-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.group-letter-badge {
    width: 36px;
    height: 36px;
    background: var(--gradient-accent);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    color: white;
    box-shadow: 0 4px 15px rgba(255, 70, 85, 0.4);
}

.group-name {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 2px;
    color: var(--text-primary);
    flex: 1;
}

.group-progress {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    color: var(--text-secondary);
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
}

.group-card-teams {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-height: 200px;
}

.group-empty-slot {
    height: 44px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    font-size: 0.8rem;
}

.group-team-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: linear-gradient(135deg, rgba(255, 70, 85, 0.15) 0%, rgba(255, 70, 85, 0.05) 100%);
    border: 1px solid rgba(255, 70, 85, 0.3);
    border-radius: 10px;
    animation: teamSlotFill 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes teamSlotFill {
    0% {
        opacity: 0;
        transform: scale(0.8) translateX(-20px);
        background: rgba(255, 70, 85, 0.4);
        box-shadow: 0 0 30px rgba(255, 70, 85, 0.6);
    }
    50% {
        background: rgba(255, 70, 85, 0.3);
        box-shadow: 0 0 20px rgba(255, 70, 85, 0.4);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateX(0);
    }
}

.group-team-item .team-number {
    width: 24px;
    height: 24px;
    background: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    color: white;
}

.group-team-item .team-name {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Wheel Container */
.lottery-wheel-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    position: relative;
}

/* Current Group Indicator */
.current-group-indicator {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 24px;
    background: linear-gradient(135deg, rgba(255, 70, 85, 0.2) 0%, rgba(255, 70, 85, 0.1) 100%);
    border: 1px solid rgba(255, 70, 85, 0.3);
    border-radius: 30px;
    animation: indicatorPulse 2s ease-in-out infinite;
}

@keyframes indicatorPulse {
    0%, 100% { box-shadow: 0 0 20px rgba(255, 70, 85, 0.2); }
    50% { box-shadow: 0 0 40px rgba(255, 70, 85, 0.4); }
}

.filling-text {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--text-secondary);
}

.filling-group {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.4rem;
    font-weight: 900;
    color: var(--accent);
    text-shadow: 0 0 20px rgba(255, 70, 85, 0.5);
}

/* Wheel Pointer */
.wheel-pointer {
    position: absolute;
    top: 95px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 20;
}

.pointer-arrow {
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 40px solid var(--accent);
    filter: drop-shadow(0 4px 15px rgba(255, 70, 85, 0.5));
    position: relative;
}

.pointer-arrow::before {
    content: '';
    position: absolute;
    top: -36px;
    left: -14px;
    width: 0;
    height: 0;
    border-left: 14px solid transparent;
    border-right: 14px solid transparent;
    border-top: 28px solid #ff6b7a;
}

.pointer-glow {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 60px;
    background: radial-gradient(ellipse, rgba(255, 70, 85, 0.4) 0%, transparent 70%);
    animation: pointerGlow 1.5s ease-in-out infinite;
}

@keyframes pointerGlow {
    0%, 100% { opacity: 0.5; transform: translateX(-50%) scale(1); }
    50% { opacity: 1; transform: translateX(-50%) scale(1.3); }
}

/* Wheel Rings */
.wheel-outer-ring {
    width: 440px;
    height: 440px;
    border-radius: 50%;
    padding: 8px;
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 50%, #2d3748 100%);
    box-shadow:
        0 0 0 4px rgba(255, 255, 255, 0.1),
        0 0 60px rgba(0, 0, 0, 0.5),
        inset 0 0 30px rgba(0, 0, 0, 0.3);
    position: relative;
}

.wheel-outer-ring::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 70, 85, 0.5), transparent, rgba(255, 70, 85, 0.3));
    z-index: -1;
    animation: ringRotate 8s linear infinite;
}

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

.wheel-inner-ring {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    padding: 6px;
    background: linear-gradient(180deg, #1e2631 0%, #0d1117 100%);
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.5);
}

.wheel-canvas-container {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
}

#lotteryWheelCanvas {
    width: 100%;
    height: 100%;
    transition: transform 0.05s linear;
}

/* Wheel Center */
.wheel-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(180deg, #1a202c 0%, #0d1117 100%);
    box-shadow:
        0 0 0 6px rgba(255, 70, 85, 0.3),
        0 0 30px rgba(0, 0, 0, 0.5),
        inset 0 2px 10px rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.wheel-center-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.wheel-logo {
    width: 50px;
    height: 50px;
    filter: drop-shadow(0 0 10px rgba(255, 70, 85, 0.3));
}

.wheel-spin-text {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.7rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 2px;
    text-shadow: 0 0 10px rgba(255, 70, 85, 0.5);
}

/* Selected Team Display */
.selected-team-display {
    padding: 16px 32px;
    background: linear-gradient(135deg, rgba(255, 70, 85, 0.15) 0%, rgba(255, 70, 85, 0.05) 100%);
    border: 1px solid rgba(255, 70, 85, 0.2);
    border-radius: 16px;
    min-width: 300px;
    text-align: center;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.selected-team-display.visible {
    opacity: 1;
    transform: translateY(0);
}

.selected-team-display.highlight {
    animation: selectedHighlight 0.6s ease-out;
}

@keyframes selectedHighlight {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 70, 85, 0.6);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 60px 10px rgba(255, 70, 85, 0.4);
        transform: scale(1.05);
    }
    100% {
        box-shadow: 0 0 30px 0 rgba(255, 70, 85, 0.2);
        transform: scale(1);
    }
}

.selected-team-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.selected-label {
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.9rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.selected-team-name {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-primary);
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
}

.selected-group-badge {
    width: 36px;
    height: 36px;
    background: var(--gradient-accent);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    color: white;
    box-shadow: 0 4px 15px rgba(255, 70, 85, 0.4);
}

/* Progress Container */
.lottery-progress-container {
    width: 100%;
    max-width: 400px;
}

.lottery-progress-bar {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.lottery-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--gradient-accent);
    border-radius: 10px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.lottery-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: progressShine 2s ease-in-out infinite;
}

@keyframes progressShine {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

.lottery-progress-text {
    text-align: center;
    margin-top: 12px;
    font-family: 'Rajdhani', sans-serif;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.lottery-progress-text span {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    color: var(--accent);
}

/* Action Buttons */
.lottery-wheel-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 24px;
    position: relative;
    z-index: 1;
}

.lottery-spin-btn {
    position: relative;
    padding: 20px 60px;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 4px;
    color: white;
    background: var(--gradient-accent);
    border: none;
    border-radius: 16px;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow:
        0 8px 30px rgba(255, 70, 85, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.1) inset;
}

.lottery-spin-btn:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow:
        0 12px 40px rgba(255, 70, 85, 0.5),
        0 0 60px rgba(255, 70, 85, 0.3);
}

.lottery-spin-btn:active {
    transform: translateY(-2px) scale(1);
}

.lottery-spin-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.lottery-spin-btn .btn-glow {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    animation: btnGlowMove 3s ease-in-out infinite;
}

@keyframes btnGlowMove {
    0% { left: -100%; }
    50%, 100% { left: 100%; }
}

.lottery-spin-btn i {
    margin-right: 12px;
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.lottery-spin-btn:hover i {
    transform: rotate(180deg);
}

.lottery-spin-btn.spinning i {
    animation: spinIcon 0.5s linear infinite;
}

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

.lottery-reset-btn,
.lottery-apply-btn {
    padding: 16px 32px;
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    letter-spacing: 2px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.lottery-reset-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-secondary);
}

.lottery-reset-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(255, 70, 85, 0.1);
}

.lottery-apply-btn {
    background: var(--gradient-emerald);
    border: none;
    color: white;
    box-shadow: 0 6px 25px rgba(16, 185, 129, 0.4);
}

.lottery-apply-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 35px rgba(16, 185, 129, 0.5);
}

/* Confetti Container */
.confetti-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
    z-index: 100;
}

.confetti-piece {
    position: absolute;
    width: 12px;
    height: 12px;
    opacity: 0;
    animation: confettiFall 3s ease-out forwards;
}

@keyframes confettiFall {
    0% {
        opacity: 1;
        transform: translateY(0) rotate(0deg) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(var(--fall-distance, 600px)) rotate(var(--rotation, 720deg)) scale(0.5);
    }
}

/* Wheel Spinning State */
.wheel-spinning .wheel-outer-ring::before {
    animation: ringRotate 0.5s linear infinite;
}

.wheel-spinning .pointer-glow {
    animation: pointerGlow 0.3s ease-in-out infinite;
}

/* Completion State */
.lottery-complete .lottery-group-card.filled {
    animation: groupCompleteGlow 1s ease-out;
}

@keyframes groupCompleteGlow {
    0% { box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.6); }
    50% { box-shadow: 0 0 40px 10px rgba(74, 222, 128, 0.3); }
    100% { box-shadow: 0 0 20px 0 rgba(74, 222, 128, 0.2); }
}

/* Responsive Design */
@media (max-width: 1400px) {
    .lottery-main-layout {
        grid-template-columns: 240px 1fr 240px;
        gap: 24px;
    }

    .wheel-outer-ring {
        width: 380px;
        height: 380px;
    }

    #lotteryWheelCanvas {
        width: 380px;
        height: 380px;
    }
}

@media (max-width: 1200px) {
    .lottery-main-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .lottery-groups-panel {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .lottery-groups-left {
        order: 2;
    }

    .lottery-wheel-container {
        order: 1;
    }

    .lottery-groups-right {
        order: 3;
    }

    .group-card-teams {
        min-height: 160px;
    }
}

@media (max-width: 768px) {
    .lottery-wheel-content {
        width: 98vw;
        max-height: 98vh;
        border-radius: 16px;
    }

    .lottery-wheel-header h3 {
        font-size: 1.4rem;
        letter-spacing: 4px;
    }

    .wheel-outer-ring {
        width: 320px;
        height: 320px;
    }

    #lotteryWheelCanvas {
        width: 320px;
        height: 320px;
    }

    .wheel-center {
        width: 90px;
        height: 90px;
    }

    .wheel-logo {
        width: 40px;
        height: 40px;
    }

    .lottery-groups-panel {
        grid-template-columns: 1fr;
    }

    .lottery-spin-btn {
        padding: 16px 40px;
        font-size: 1.1rem;
    }

    .lottery-wheel-actions {
        flex-direction: column;
        align-items: center;
    }
}

/* Neon Glow Effects */
.neon-glow {
    animation: neonPulse 2s ease-in-out infinite alternate;
}

@keyframes neonPulse {
    from {
        filter: drop-shadow(0 0 5px var(--accent)) drop-shadow(0 0 10px var(--accent));
    }
    to {
        filter: drop-shadow(0 0 10px var(--accent)) drop-shadow(0 0 20px var(--accent)) drop-shadow(0 0 30px var(--accent));
    }
}

/* Sound Simulation Pulse */
.sound-pulse {
    animation: soundWave 0.3s ease-out;
}

@keyframes soundWave {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}
