/* CSS Variables for Dark Mode */
:root {
    --bg-primary: #f8f9fa;
    --bg-secondary: #ffffff;
    --bg-tertiary: #f8f9ff;
    --text-primary: #333333;
    --text-secondary: #6c757d;
    --text-muted: #666666;
    --border-color: #dee2e6;
    --shadow-color: rgba(0,0,0,0.08);
    --highlight-bg: #f8f9fa;
    --blue-primary: #4285f4;
    --blue-secondary: #3367d6;
    --overlay-bg: rgba(255, 255, 255, 0.95);
}

.dark {
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --bg-tertiary: #374151;
    --text-primary: #f9fafb;
    --text-secondary: #d1d5db;
    --text-muted: #9ca3af;
    --border-color: #374151;
    --shadow-color: rgba(0,0,0,0.3);
    --highlight-bg: #374151;
    --blue-primary: #60a5fa;
    --blue-secondary: #3b82f6;
    --overlay-bg: rgba(31, 41, 55, 0.95);
}

/* Reset và Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-primary);
    padding: 0;
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Logo Styles */
.logo {
    font-size: 24px;
    font-weight: bold;
    color: var(--text-primary);
}

/* Tab Button Styles for both header and mobile */
.tab-btn {
    text-decoration: none;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
}

.tab-btn:hover {
    color: var(--text-secondary);
}

.tab-btn.active {
    color: var(--blue-primary) !important;
}

/* Mobile menu styles */
.mode-tabs {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Container Styles */
.main-grid {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 24px;
    align-items: start;
}

.game-container {
    width: 100%;
    max-width: 750px;
}

.game-wrapper {
    width: 100%;
    height: 480px;
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 20px var(--shadow-color);
    display: flex;
    flex-direction: column;
    position: relative;
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

.sidebar-container {
    width: 280px;
    flex-shrink: 0;
}

/* Pause Overlay */
.pause-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--overlay-bg);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 100;
    transition: all 0.3s ease;
}

.pause-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.pause-content {
    text-align: center;
    padding: 40px;
}

.pause-icon {
    font-size: 64px;
    color: var(--blue-primary);
    margin-bottom: 20px;
}

.pause-title {
    font-size: 28px;
    font-weight: bold;
    color: var(--text-primary);
    margin-bottom: 10px;
}

.pause-subtitle {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 30px;
}

.resume-btn {
    background: var(--blue-primary);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.resume-btn:hover {
    background: var(--blue-secondary);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(66, 133, 244, 0.4);
}

/* Difficulty Section */
.difficulty-section-container {
    margin-bottom: 16px;
}

.difficulty-section {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.difficulty-label {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 14px;
}

.difficulty-buttons {
    display: flex;
    gap: 6px;
    flex: 1;
}

.difficulty-btn {
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    background: var(--bg-secondary);
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s;
}

.difficulty-btn:hover {
    border-color: var(--blue-primary);
    background: var(--bg-tertiary);
}

.difficulty-btn.active {
    background: var(--blue-primary);
    color: white;
    border-color: var(--blue-primary);
}

.score-display {
    font-size: 32px;
    font-weight: bold;
    color: var(--text-primary);
    text-align: center;
    padding: 8px 16px;
    background: var(--highlight-bg);
    border-radius: 8px;
    min-width: 80px;
    transition: all 0.3s ease;
}

/* Game Area */
.game-area {
    display: flex;
    gap: 40px;
    height: 100%;
    align-items: flex-start;
}

/* Game Board */
.game-board {
    display: grid;
    grid-template-columns: repeat(9, 40px);
    grid-template-rows: repeat(9, 40px);
    gap: 1px;
    background: var(--text-primary);
    border: 3px solid var(--text-primary);
    border-radius: 4px;
    transition: all 0.3s ease;
}

.game-cell {
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
    position: relative;
    color: var(--text-primary);
}

.game-cell:hover {
    background: var(--bg-tertiary) !important;
    transform: scale(1.05);
    z-index: 5;
}

.game-cell.selected:not(.conflict) {
    background: #4285f4 !important;
    color: white !important;
    font-weight: bold !important;
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.3) !important;
    z-index: 10;
    position: relative;
}

.game-cell.highlighted {
    background: #e3f2fd !important; /* Light blue for light mode */
    color: #333 !important;
}

/* Dark mode highlighted cells */
.dark .game-cell.highlighted {
    background: #4a5568 !important; /* Darker gray-blue for dark mode */
    color: #f7fafc !important;
}

.game-cell.same-number {
    background: #c8e6c9 !important;
    color: #2e7d32 !important;
    font-weight: bold !important;
}

/* Dark mode same number highlighting */
.dark .game-cell.same-number {
    background: #4ade80 !important;
    color: #1a202c !important;
    font-weight: bold !important;
}

/* Row/Column highlighting */
.game-cell.row-highlighted {
    background: #bbdefb !important;
    color: #333 !important;
}

.game-cell.col-highlighted {
    background: #bbdefb !important;
    color: #333 !important;
}

.game-cell.block-highlighted {
    background: #bbdefb !important;
    color: #333 !important;
}

/* Dark mode row/column highlighting */
.dark .game-cell.row-highlighted {
    background: #4a5568 !important;
    color: #e2e8f0 !important;
}

.dark .game-cell.col-highlighted {
    background: #4a5568 !important;
    color: #e2e8f0 !important;
}

.dark .game-cell.block-highlighted {
    background: #4a5568 !important;
    color: #e2e8f0 !important;
}

/* Combined highlighting states */
.game-cell.highlighted.same-number {
    background: #a5d6a7 !important;
    color: #1b5e20 !important;
}

.game-cell.row-highlighted.same-number,
.game-cell.col-highlighted.same-number,
.game-cell.block-highlighted.same-number {
    background: #a5d6a7 !important;
    color: #1b5e20 !important;
}

/* Dark mode combined highlighting states */
.dark .game-cell.highlighted.same-number {
    background: #68d391 !important;
    color: #1a202c !important;
}

.dark .game-cell.row-highlighted.same-number,
.dark .game-cell.col-highlighted.same-number,
.dark .game-cell.block-highlighted.same-number {
    background: #68d391 !important;
    color: #1a202c !important;
}

/* ===========================================
   PRIORITY SYSTEM FOR CELL HIGHLIGHTING
   =========================================== 
   1. 🔴 CONFLICT/ERROR (RED) - HIGHEST PRIORITY
   2. 🔵 SELECTED CELL (BLUE) - Second priority  
   3. 🟢 SAME NUMBERS (GREEN) - Third priority
   4. 🔵 ROW/COLUMN HIGHLIGHT (LIGHT BLUE) - Fourth priority
   5. 💙 HOVER (VERY LIGHT) - Lowest priority
   =========================================== */

/* 1. Conflict/Error (RED) - HIGHEST PRIORITY - Moved to bottom for higher specificity */

/* 2. Selected cell (BLUE) - Second priority */
.game-cell.selected:not(.conflict) {
    background: #4285f4 !important;
    color: white !important;
    z-index: 10 !important;
}

/* Ensure conflict always wins over selected */
.game-cell.conflict.given,
.game-cell.selected.conflict.given,
.game-cell.highlighted.conflict.given,
.game-cell.same-number.conflict,
.game-cell.row-highlighted.conflict,
.game-cell.col-highlighted.conflict,
.game-cell.block-highlighted.conflict {
    background: #ffcdd2 !important;
    color: #000000 !important;
    animation: shake 0.5s ease-in-out !important;
    z-index: 15 !important;
}

/* FINAL OVERRIDE: Conflict always wins - placed last for maximum specificity */
.game-cell.conflict:not(.given) {
    background: #ffcdd2 !important;
    color: #d32f2f !important;
    animation: shake 0.5s ease-in-out !important;
    z-index: 15 !important;
}

/* Auto Check disabled - remove conflict animations and styling */
.auto-check-disabled .game-cell.conflict.given,
.auto-check-disabled .game-cell.selected.conflict.given,
.auto-check-disabled .game-cell.highlighted.conflict.given,
.auto-check-disabled .game-cell.same-number.conflict,
.auto-check-disabled .game-cell.row-highlighted.conflict,
.auto-check-disabled .game-cell.col-highlighted.conflict,
.auto-check-disabled .game-cell.block-highlighted.conflict,
.auto-check-disabled .game-cell.conflict:not(.given) {
    background: white !important;
    color: #333 !important;
    animation: none !important;
    z-index: auto !important;
}

.game-cell.given {
    background: var(--highlight-bg);
    color: var(--text-primary);
    font-weight: 500;
    transition: all 0.3s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-2px); }
    75% { transform: translateX(2px); }
}

/* Grid lines - thicker borders for 3x3 sections */
.game-cell:nth-child(3n):not(:nth-child(9n)) {
    border-right: 2px solid #333 !important;
}

.game-cell:nth-child(n+19):nth-child(-n+27),
.game-cell:nth-child(n+46):nth-child(-n+54) {
    border-bottom: 2px solid #333 !important;
}

/* Right Panel */
.right-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 290px;
    flex-shrink: 0;
}

/* Stats Section */
.stats-section {
    display: flex;
    flex-direction: row;
    gap: 8px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 0px 10px;
    background: var(--highlight-bg);
    transition: all 0.3s ease;
    border-radius: 8px;
    min-height: 50px;
}

.trophy-icon {
    font-size: 20px;
    width: 24px;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 2px;
}

.stat-value {
    font-size: 16px;
    font-weight: bold;
    color: var(--text-primary);
}

.pause-btn {
    background: var(--highlight-bg);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s;
    color: var(--text-secondary);
}

.pause-btn:hover {
    background: var(--bg-tertiary);
    border-color: var(--text-secondary);
}

.pause-btn.paused {
    background: #4285f4;
    color: white;
}

.pause-btn.paused:hover {
    background: #3367d6;
}

/* Controls */
.controls {
    display: flex;
    gap: 10px;
}

.control-btn {
    width: 50px;
    height: 50px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 1px 3px var(--shadow-color);
    position: relative;
    color: var(--text-primary);
}

.control-btn:hover {
    border-color: var(--blue-primary);
    background: var(--bg-tertiary);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--shadow-color);
}

.control-btn.active {
    background: var(--blue-primary);
    color: white;
    border-color: var(--blue-primary);
}

.control-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: var(--highlight-bg);
    border-color: var(--border-color);
}

.control-btn.disabled:hover {
    background: var(--highlight-bg);
    border-color: var(--border-color);
    transform: none;
    box-shadow: none;
}

.control-icon {
    font-size: 18px;
}

/* Number Pad */
.numpad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.num-btn {
    height: 50px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 3px var(--shadow-color);
}

.num-btn:hover {
    border-color: var(--blue-primary);
    background: var(--bg-tertiary);
    transform: translateY(-1px);
    box-shadow: 0 2px 6px var(--shadow-color);
}

.num-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px var(--shadow-color);
}

/* New Game Button */
.new-game-btn {
    width: 100%;
    height: 44px;
    background: var(--blue-primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(66, 133, 244, 0.3);
}

.new-game-btn:hover {
    background: var(--blue-secondary);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.4);
}

/* Killer Mode Styles */
.killer-mode .game-cell {
    position: relative;
}

.killer-mode .game-cell.given {
    background: #fff3e0;
    color: #e65100;
    font-weight: bold;
}

.killer-mode .game-cell.given.selected {
    background: #4285f4 !important;
    color: white !important;
}

.killer-mode .game-cell.given.highlighted {
    background: #ffe0b2;
}

.killer-mode .game-cell.given.same-number {
    background: #ffcc02;
    color: #333;
}

.killer-mode .game-cell.cage-border-top {
    border-top: 2px dashed #ff9800;
}

.killer-mode .game-cell.cage-border-right {
    border-right: 2px dashed #ff9800;
}

.killer-mode .game-cell.cage-border-bottom {
    border-bottom: 2px dashed #ff9800;
}

.killer-mode .game-cell.cage-border-left {
    border-left: 2px dashed #ff9800;
}

.cage-sum {
    position: absolute;
    top: 1px;
    left: 2px;
    font-size: 8px;
    font-weight: bold;
    color: #ff9800;
    background: white;
    padding: 1px 2px;
    border-radius: 2px;
    line-height: 1;
}

.killer-mode .game-cell.cage-error {
    background: #ffebee !important;
    color: #d32f2f !important;
}

.killer-mode .game-cell.cage-complete {
    background: #e8f5e8 !important;
}

/* Smart Hint Carousel Styles */
.smart-hint_carousel_name {
    font-size: 18px;
    font-weight: bold;
    color: #325aaf;
    margin-bottom: 15px;
}

.smart-hint_carousel_visual {
    margin: 15px 0;
    display: flex;
    justify-content: center;
}

.mini-board {
    display: grid;
    grid-template-columns: repeat(9, 25px);
    grid-template-rows: repeat(9, 25px);
    gap: 1px;
    background: #333;
    border: 2px solid #333;
    margin: 0 auto;
    padding: 2px;
}

.mini-cell {
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: bold;
    border: none;
    position: relative;
}

/* Mini board borders (same pattern as game board) */
.mini-cell:nth-child(3n):not(:nth-child(9n)) {
    border-right: 2px solid #333 !important;
}

.mini-cell:nth-child(n+19):nth-child(-n+27),
.mini-cell:nth-child(n+46):nth-child(-n+54) {
    border-bottom: 2px solid #333 !important;
}

.mini-cell.hint-target {
    background: #ff6b6b;
    color: white;
    animation: pulse 1s infinite;
}

.mini-cell.related {
    background: #ffe066;
}

.mini-cell.given {
    background: #f0f0f0;
    color: #333;
}

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

.smart-hint_carousel_desc {
    font-size: 14px;
    color: #666;
    line-height: 1.4;
    margin: 15px 0;
    text-align: left;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
}

.hint-cell-info {
    background: #e3f2fd;
    padding: 12px;
    border-radius: 8px;
    margin: 15px 0;
    font-size: 13px;
    text-align: left;
}

.sh-nav-submit, .sh-nav-cancel {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    transition: all 0.2s;
}

.sh-nav-submit {
    background: #325aaf;
    color: white;
}

.sh-nav-submit:hover {
    background: #2a4d98;
}

.sh-nav-cancel {
    background: #f0f0f0;
    color: #666;
}

.sh-nav-cancel:hover {
    background: #e0e0e0;
}

/* Mobile elements - hidden by default */
.mobile-stats-container,
.mobile-score-display,
.mobile-new-game-btn {
    display: none;
}

/* ===== MOBILE RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    body {
        background-color: #ffffff;
        font-size: 14px;
    }

    .main-grid {
        grid-template-columns: 1fr;
        gap: 0;
        padding: 0;
    }

    .game-container {
        max-width: 100%;
        padding: 0;
    }
    
    .game-wrapper {
        width: 100%;
        height: 60vh;
        margin: 0;
        padding: 16px;
        border-radius: 0;
        box-shadow: none;
        background: #ffffff;
        overflow-y: auto;
    }


    /* Mobile Header - Add New Game Button */
    .flex.justify-between.items-center.h-16 {
        padding: 0 16px;
    }

    .flex.items-center.space-x-4 {
        gap: 12px;
    }

    /* Mobile new game button in header */
    .mobile-new-game-btn {
        display: block !important;
        background: #4285f4;
        color: white;
        border: none;
        padding: 6px 12px;
        border-radius: 6px;
        font-size: 12px;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s;
    }

    .mobile-new-game-btn:hover {
        background: #3367d6;
    }

    /* Mobile Stats + Difficulty Section - Horizontal layout */
    .mobile-stats-container {
        display: flex !important;
        align-items: center;
        gap: 12px;
        background: #f8f9fa;
        padding: 12px;
        border-radius: 8px;
    }

    /* Difficulty Dropdown */
    .mobile-difficulty-select {
        background: white;
        border: 1px solid #dee2e6;
        border-radius: 6px;
        padding: 6px 8px;
        font-size: 12px;
        font-weight: 500;
        color: #333;
        cursor: pointer;
        min-width: 80px;
    }

    .mobile-difficulty-select:hover,
    .mobile-difficulty-select:focus {
        border-color: #4285f4;
        outline: none;
    }

    /* Mobile Stats - Horizontal compact */
    .mobile-stats {
        display: flex;
        gap: 12px;
        flex: 1;
    }

    .mobile-stat-item {
        text-align: center;
        flex: 1;
    }

    .mobile-stat-label {
        font-size: 10px;
        color: #666;
        margin-bottom: 2px;
        font-weight: 500;
    }

    .mobile-stat-value {
        font-size: 14px;
        font-weight: bold;
        color: #333;
    }

    /* Hide original difficulty section */
    .difficulty-section-container {
        display: none;
    }

    /* Hide original stats section */
    .stats-section {
        display: none;
    }

    /* Mobile Score Display - Large and prominent */
    .mobile-score-display {
        display: block !important;
        font-size: 30px;
        font-weight: bold;
        color: #333;
        text-align: center;
    }
    
    /* Mobile Game Area - Vertical layout */
    .game-area {
        flex-direction: column;
        align-items: center;
        gap: 20px;
        height: auto;
    }
    
    /* Mobile Game Board - Smaller cells */
    .game-board {
        grid-template-columns: repeat(9, 34px);
        grid-template-rows: repeat(9, 34px);
        gap: 1px;
        border: 2px solid #333;
    }
    
    .game-cell {
        width: 34px;
        height: 34px;
        font-size: 16px;
        font-weight: bold;
    }

    /* Mobile highlighting effects */
    .game-cell:hover {
        transform: none !important;
    }

    .game-cell.selected:not(.conflict) {
        background: #4285f4 !important;
        color: white !important;
        font-weight: bold !important;
        box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.3) !important;
        z-index: 10;
    }

    /* Mobile conflict priority */
    .game-cell.conflict {
        background: #ffcdd2 !important;
        color: #d32f2f !important;
        z-index: 15 !important;
    }
    
    /* Mobile Right Panel - Full width */
    .right-panel {
        width: 100%;
        max-width: 320px;
        gap: 16px;
    }
    
    /* Mobile Controls - Centered horizontal layout */
    .controls {
        justify-content: center;
        gap: 16px;
        margin-bottom: 8px;
    }
    
    .control-btn {
        width: 50px;
        height: 50px;
        border-radius: 12px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    }
    
    .control-icon {
        font-size: 20px;
    }
    
    /* Mobile Number Pad - Single row */
    .numpad {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 4px;
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
    }
    
    .num-btn {
        width: calc((100% - 64px) / 9); /* 9 buttons with 8px gaps */
        min-width: 32px;
        height: 50px;
        font-size: 18px;
        font-weight: bold;
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0,0,0,0.1);
        color: #4285f4;
        border: 1px solid #e0e0e0;
    }

    .num-btn:hover {
        background: #f0f8ff;
        border-color: #4285f4;
        transform: none;
        box-shadow: 0 2px 8px rgba(66, 133, 244, 0.2);
    }

    .num-btn:active {
        background: #e3f2fd;
        transform: scale(0.95);
    }

    /* Desktop New Game Button - Hidden on mobile */
    .new-game-btn {
        display: none;
    }

    /* Mobile Pause Overlay adjustments */
    .pause-content {
        padding: 20px;
    }

    .pause-icon {
        font-size: 48px;
        margin-bottom: 16px;
    }

    .pause-title {
        font-size: 24px;
        margin-bottom: 8px;
    }

    .pause-subtitle {
        font-size: 14px;
        margin-bottom: 20px;
    }

    .resume-btn {
        padding: 10px 24px;
        font-size: 14px;
    }
}

/* Desktop specific classes */
@media (min-width: 769px) {
    .mobile-only {
        display: none;
    }

    .desktop-only {
        display: block;
    }
    
    /* Desktop - show sidebar */
    .sidebar-container {
        display: block !important;
    }
    
    .mobile-stats-container,
    .mobile-score-display,
    .mobile-new-game-btn {
        display: none;
    }

    /* Ensure desktop layout stays unchanged */
    .stats-section {
        flex-direction: row !important;
        gap: 8px !important;
    }

    .numpad {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 8px !important;
    }

    .new-game-btn {
        display: block !important;
    }

    /* Hide mobile elements on desktop */
    .mobile-new-game-btn {
        display: none !important;
    }

    .mobile-stats-container {
        display: none !important;
    }

    .mobile-score-display {
        display: none !important;
    }
}

/* Notes Grid 3x3 Styles */
.game-cell.notes-grid {
    font-family: 'Courier New', monospace;
    font-size: 8px !important;
    line-height: 1.1 !important;
    white-space: pre-line !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center;
    padding: 2px !important;
    letter-spacing: 0.5px;
}

/* Responsive notes for mobile */
@media (max-width: 768px) {
    .game-cell.notes-grid {
        font-size: 6px !important;
        line-height: 1.0 !important;
        letter-spacing: 0.3px;
        padding: 1px !important;
    }
}

/* Notes placeholders (dots) */
.game-cell .notes-placeholder {
    opacity: 0.3;
    color: #ccc;
}