/* Prevent iOS context menu and improve touch handling */
* {
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
}

canvas {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
    touch-action: none;
    /* Prevent iOS Safari zoom on double-tap */
    touch-action: manipulation;
}

.game-canvas {
    -webkit-touch-callout: none !important;
    -webkit-user-select: none !important;
    user-select: none !important;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease-out;
}

.loading-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

.loading-content {
    text-align: center;
    color: white;
}

.loading-content h1 {
    font-size: 3rem;
    margin-bottom: 2rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.loading-bar {
    width: 300px;
    height: 8px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    overflow: hidden;
    margin: 0 auto 1rem;
}

.loading-fill {
    height: 100%;
    background: white;
    width: 0%;
    transition: width 0.3s ease-out;
    border-radius: 4px;
}

.loading-text {
    font-size: 1.1rem;
    opacity: 0.9;
}

:root {
    --primary-color: #6366f1;
    --secondary-color: #f97316;
    --success-color: #10b981;
    --error-color: #ef4444;
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --border-color: #334155;
    --cell-size: 50px;
    --glow-color: #60a5fa;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: #000000;
    color: var(--text-primary);
    overflow: hidden;
    user-select: none;
}

#gameContainer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000000;
    overflow: hidden;
}

#vfxCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

#gameLayer {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    height: 100vh;
    height: 100%;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    gap: 20px;
    box-sizing: border-box;
}

/* Game Header */
#gameHeader {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    padding: 14px 22px;
    border-radius: 12px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    position: relative;
    min-height: 70px;
    width: 100%;
    max-width: 750px;
    gap: 20px;
    position: relative;
}

.menu-btn {
    background: transparent;
    border: none;
    color: var(--text-primary);
    padding: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: background 0.2s;
}

.menu-btn:hover {
    background: rgba(99, 102, 241, 0.2);
}

.score-group {
    display: flex;
    gap: 16px;
    align-items: center;
    flex: 1;
    justify-content: center;
    padding: 0 8px;
}

.difficulty-badge {
    background: rgba(99, 102, 241, 0.3);
    color: var(--primary-color);
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    text-transform: uppercase;
    border: 1px solid rgba(99, 102, 241, 0.4);
    white-space: nowrap;
    flex-shrink: 0;
}

.score-container, .combo-container, .streak-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    min-width: 0;
}

.score-label, .combo-label, .streak-label {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 600;
    letter-spacing: 0.5px;
    line-height: 1;
    white-space: nowrap;
}

.score-value {
    font-size: 26px;
    font-weight: bold;
    color: var(--primary-color);
    text-shadow: 0 0 10px rgba(99, 102, 241, 0.5);
    font-variant-numeric: tabular-nums;
    line-height: 1.2;
}

.streak-value {
    font-size: 22px;
    font-weight: bold;
    color: var(--secondary-color);
    text-shadow: 0 0 10px rgba(249, 115, 22, 0.5);
    line-height: 1.2;
}

.combo-meter {
    width: 80px;
    height: 6px;
    background: rgba(15, 23, 42, 0.4);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 3px;
    border: 1px solid rgba(99, 102, 241, 0.15);
}

.combo-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--secondary-color), var(--error-color));
    transition: width 0.3s ease;
}

.combo-multiplier {
    font-size: 20px;
    font-weight: bold;
    color: var(--secondary-color);
    line-height: 1.2;
    white-space: nowrap;
}

/* Sudoku Grid */
#sudokuContainer {
    position: relative;
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: 12px;
    padding: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(51, 65, 85, 0.7);
    width: min(680px, calc(100vw - 40px), calc(100vh - 280px));
    height: min(680px, calc(100vw - 40px), calc(100vh - 280px));
    flex-shrink: 0;
    aspect-ratio: 1/1;
}

#gridCanvas {
    display: block;
    cursor: pointer;
    width: 100% !important;
    height: 100% !important;
    max-width: 680px;
    max-height: 680px;
    image-rendering: crisp-edges;
    image-rendering: -webkit-crisp-edges;
    image-rendering: pixelated;
}

#gridOverlay {
    position: absolute;
    top: 10px;
    left: 10px;
    pointer-events: none;
}

/* Menu Popup */
.menu-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    animation: fadeIn 0.2s ease-out;
}

.menu-popup.hidden {
    display: none;
}

.menu-popup-content {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4),
                0 0 120px rgba(99, 102, 241, 0.1),
                inset 0 1px 0 rgba(255, 255, 255, 0.1),
                inset 0 -1px 0 rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
    min-width: 320px;
    max-width: 90%;
}

.menu-popup-option {
    display: flex;
    align-items: center;
    gap: 20px;
    width: 100%;
    padding: 24px;
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 15px;
    color: var(--text-primary);
    font-size: 20px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 15px 0;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.menu-popup-option::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
    transition: left 0.5s ease;
}

.menu-popup-option:hover {
    background: rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(15px) saturate(200%);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(99, 102, 241, 0.5);
}

.menu-popup-option:hover::before {
    left: 100%;
}

.menu-popup-option:active {
    transform: translateY(-1px) scale(1.01);
}

.menu-popup-option svg {
    width: 28px;
    height: 28px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.menu-popup-option span {
    flex: 1;
    text-align: left;
}

/* New Game button - green accent */
.menu-popup-option:first-child {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.4), rgba(16, 185, 129, 0.1));
}

.menu-popup-option:first-child:hover {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.3), rgba(16, 185, 129, 0.2));
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Pause button - yellow accent */
.menu-popup-option:nth-child(2) {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.4), rgba(245, 158, 11, 0.1));
}

.menu-popup-option:nth-child(2):hover {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.3), rgba(245, 158, 11, 0.2));
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Settings button - purple accent */
.menu-popup-option:nth-child(3) {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.4), rgba(139, 92, 246, 0.1));
}

.menu-popup-option:nth-child(3):hover {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.3), rgba(139, 92, 246, 0.2));
    box-shadow: 0 8px 30px rgba(139, 92, 246, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.menu-popup-option.cancel {
    background: rgba(30, 41, 59, 0.2);
    color: var(--text-secondary);
    justify-content: center;
    border: 1px solid rgba(99, 102, 241, 0.1);
    margin-top: 20px;
    padding: 18px;
    font-size: 16px;
    font-weight: 500;
}

.menu-popup-option.cancel:hover {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.3);
    transform: scale(1.02);
    box-shadow: 0 4px 20px rgba(239, 68, 68, 0.2);
}

/* Control Panel */
#controlPanel {
    display: flex;
    flex-direction: row;
    gap: 15px;
    justify-content: center;
    align-items: center;
    max-width: 500px;
    flex-shrink: 0;
}

.side-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
}

.icon-btn {
    width: 60px;
    height: 60px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 10px;
    color: var(--text-primary);
    cursor: pointer;
    transition: all 0.2s;
}

.icon-btn:hover {
    background: rgba(99, 102, 241, 0.3);
    transform: scale(1.05);
}

.icon-btn.active {
    background: rgba(99, 102, 241, 0.5);
    border-color: var(--primary-color);
}

/* Number Pad */
#numberPad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    width: 100%;
}

.num-btn {
    width: 95px;
    height: 95px;
    font-size: 32px;
    font-weight: bold;
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: var(--text-primary);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.08);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.num-btn:hover:not(:disabled) {
    background: rgba(99, 102, 241, 0.3);
    transform: scale(1.05);
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3);
}

.num-btn:active:not(:disabled) {
    transform: scale(0.95);
}

.num-btn.focused {
    background: rgba(99, 102, 241, 0.4);
    border-color: var(--primary-color);
    animation: pulse 1.5s infinite;
}

.num-btn.completed {
    opacity: 0.3;
    background: rgba(16, 185, 129, 0.2);
}

.num-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.complete-indicator {
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 12px;
    color: var(--success-color);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.num-btn:hover:not(:disabled) {
    background: rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(10px) saturate(200%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(99, 102, 241, 0.5);
}

.action-btn:hover:not(:disabled) {
    background: rgba(99, 102, 241, 0.4);
    backdrop-filter: blur(10px) saturate(200%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(99, 102, 241, 0.6);
}

.num-btn.focused {
    background: var(--success-color) !important;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.5);
    transform: translateY(-2px);
}

.num-btn:active:not(:disabled), .action-btn:active:not(:disabled) {
    transform: translateY(0);
}

.num-btn:disabled, .action-btn:disabled, .num-btn.disabled, .action-btn.disabled {
    opacity: 0.3;
    cursor: not-allowed;
    background: var(--bg-secondary);
    transform: none !important;
    box-shadow: none !important;
}

/* Completed number styles */
.num-btn.completed {
    position: relative;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(16, 185, 129, 0.2)) !important;
    border-color: rgba(16, 185, 129, 0.3) !important;
    color: rgba(16, 185, 129, 0.6) !important;
    opacity: 0.7;
    cursor: not-allowed;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
}

.num-btn.completed .complete-indicator {
    position: absolute;
    top: 2px;
    right: 2px;
    font-size: 14px;
    color: var(--success-color);
    font-weight: bold;
    text-shadow: 0 0 10px rgba(16, 185, 129, 0.8);
    animation: pulse 2s infinite;
}

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


/* Game Controls */
#gameControls {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin: 20px auto;
}

.control-btn {
    padding: 10px 20px;
    font-size: 16px;
    font-weight: 600;
    background: rgba(30, 41, 59, 0.3);
    backdrop-filter: blur(8px) saturate(150%);
    -webkit-backdrop-filter: blur(8px) saturate(150%);
    color: var(--text-primary);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.08);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.control-btn:hover {
    background: rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(10px) saturate(200%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border-color: rgba(99, 102, 241, 0.5);
}

/* Overlays */
.overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.overlay.hidden {
    display: none;
}

.overlay-content, .modal-content, .finish-content {
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    padding: 40px;
    border-radius: 20px;
    border: 1px solid rgba(99, 102, 241, 0.3);
    max-width: 500px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4),
                0 0 120px rgba(99, 102, 241, 0.1),
                inset 0 1px 0 rgba(255, 255, 255, 0.1),
                inset 0 -1px 0 rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-30px) scale(0.95);
        opacity: 0;
    }
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* Modal Specific */
.modal {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.modal.hidden {
    display: none;
}

.modal-content h2, .finish-content h1 {
    background: linear-gradient(135deg, #60a5fa, #c084fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 30px;
    text-align: center;
}

/* Difficulty Modal */
.difficulty-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin: 30px 0;
}

.difficulty-btn {
    padding: 24px;
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.difficulty-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
    transition: left 0.5s ease;
}

.difficulty-btn:hover {
    background: rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(15px) saturate(200%);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(99, 102, 241, 0.5);
}

.difficulty-btn:hover::before {
    left: 100%;
}

.difficulty-name {
    display: block;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.difficulty-desc {
    display: block;
    font-size: 14px;
    color: var(--text-secondary);
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.difficulty-btn:hover .difficulty-desc {
    opacity: 1;
    color: rgba(255, 255, 255, 0.9);
}

/* Pause Menu Styles - Vertical like difficulty picker */
.pause-menu-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 25px 0;
}

.pause-menu-btn {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 24px;
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: left;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
    width: 100%;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
}

.pause-menu-btn svg {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    stroke: var(--primary-color);
    opacity: 0.9;
    transition: all 0.3s ease;
}

.pause-menu-text {
    flex-grow: 1;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.pause-menu-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), transparent);
    transition: left 0.5s ease;
}

.pause-menu-btn:hover {
    background: rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(15px) saturate(200%);
    transform: translateX(5px) scale(1.02);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
    border-color: rgba(99, 102, 241, 0.5);
}

.pause-menu-btn:hover::before {
    left: 100%;
}

.pause-menu-btn:hover svg {
    stroke: #ffffff;
    opacity: 1;
    transform: scale(1.1);
}

.pause-menu-btn:active {
    transform: translateX(3px) scale(0.98);
}

/* Highlight the resume button */
#resumeBtn {
    background: rgba(34, 197, 94, 0.2);
    border-color: rgba(34, 197, 94, 0.3);
}

#resumeBtn svg {
    stroke: #22c55e;
}

#resumeBtn:hover {
    background: rgba(34, 197, 94, 0.3);
    border-color: rgba(34, 197, 94, 0.5);
    box-shadow: 0 8px 30px rgba(34, 197, 94, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Difficulty indicator icons */
.difficulty-btn[data-difficulty="beginner"] .difficulty-name::before {
    content: '⭐';
    margin-right: 10px;
}

.difficulty-btn[data-difficulty="easy"] .difficulty-name::before {
    content: '⭐⭐';
    margin-right: 10px;
}

.difficulty-btn[data-difficulty="medium"] .difficulty-name::before {
    content: '⭐⭐⭐';
    margin-right: 10px;
}

.difficulty-btn[data-difficulty="hard"] .difficulty-name::before {
    content: '⭐⭐⭐⭐';
    margin-right: 10px;
}

.difficulty-btn[data-difficulty="expert"] .difficulty-name::before {
    content: '⭐⭐⭐⭐⭐';
    margin-right: 10px;
}

/* Premium Settings Modal Styles */
.settings-modal-content {
    background: rgba(30, 41, 59, 0.5) !important;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4),
                0 0 120px rgba(99, 102, 241, 0.1),
                inset 0 1px 0 rgba(255, 255, 255, 0.1),
                inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}

.settings-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
    background: linear-gradient(135deg, #ffffff, #a78bfa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.settings-section {
    margin: 25px 0;
    padding: 20px;
    background: rgba(30, 41, 59, 0.3);
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.settings-section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
    position: relative;
}

.settings-section.collapsible .settings-section-header {
    cursor: pointer;
    user-select: none;
    transition: opacity 0.2s;
}

.settings-section.collapsible .settings-section-header:hover {
    opacity: 0.8;
}

.collapse-icon {
    margin-left: auto;
    transition: transform 0.3s ease;
    stroke: var(--primary-color);
    filter: drop-shadow(0 2px 4px rgba(99, 102, 241, 0.3));
}

.settings-section.collapsible .settings-items.collapsed {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    margin-top: 0;
    transition: max-height 0.3s ease, opacity 0.3s ease, margin-top 0.3s ease;
}

.settings-section.collapsible .settings-items:not(.collapsed) {
    max-height: 500px;
    opacity: 1;
    transition: max-height 0.3s ease, opacity 0.3s ease;
}

.settings-section.collapsible .settings-section-header[aria-expanded="true"] .collapse-icon {
    transform: rotate(180deg);
}

.settings-section-header svg {
    width: 24px;
    height: 24px;
    stroke: var(--primary-color);
    filter: drop-shadow(0 2px 4px rgba(99, 102, 241, 0.3));
}

.settings-section-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.settings-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* Toggle Switch Items */
.settings-toggle-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: rgba(30, 41, 59, 0.2);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.settings-toggle-item:hover {
    background: rgba(99, 102, 241, 0.1);
    transform: translateX(3px);
}

.settings-toggle-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.settings-toggle-label {
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
}

.settings-toggle-desc {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

/* Custom Toggle Switch */
.settings-toggle {
    position: relative;
    width: 56px;
    height: 28px;
    cursor: pointer;
}

.settings-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.settings-toggle-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(71, 85, 105, 0.5);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 20px;
    transition: all 0.3s ease;
}

.settings-toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 4px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.settings-toggle input:checked + .settings-toggle-slider {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border-color: rgba(139, 92, 246, 0.5);
}

.settings-toggle input:checked + .settings-toggle-slider:before {
    transform: translateX(28px);
    box-shadow: 0 2px 12px rgba(99, 102, 241, 0.5);
}

/* Disabled toggle state */
.settings-toggle input:disabled + .settings-toggle-slider {
    background: rgba(71, 85, 105, 0.2);
    border-color: rgba(99, 102, 241, 0.1);
    cursor: not-allowed;
}

.settings-toggle input:disabled + .settings-toggle-slider:before {
    background: rgba(255, 255, 255, 0.3);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.settings-toggle-item.disabled {
    opacity: 0.5;
}

.settings-toggle-item.disabled .settings-toggle {
    cursor: not-allowed;
}

/* Slider Items */
.settings-slider-item {
    padding: 15px;
    background: rgba(30, 41, 59, 0.2);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.settings-slider-item:hover {
    background: rgba(99, 102, 241, 0.1);
}

.settings-slider-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.settings-slider-label {
    font-size: 16px;
    font-weight: 500;
    color: var(--text-primary);
}

.settings-slider-value {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary-color);
    padding: 4px 10px;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 8px;
    min-width: 50px;
    text-align: center;
}

/* Custom Range Slider */
.settings-slider {
    width: 100%;
    height: 6px;
    border-radius: 10px;
    background: rgba(71, 85, 105, 0.3);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
}

.settings-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.5);
    transition: all 0.3s ease;
}

.settings-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.7);
}

.settings-slider::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.5);
    transition: all 0.3s ease;
}

.settings-slider::-moz-range-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.7);
}

/* Account Section Styles */
.settings-account-card {
    padding: 20px;
    background: rgba(30, 41, 59, 0.2);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.settings-account-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.settings-account-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.settings-account-email {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    word-break: break-all;
}

.settings-btn-signout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 10px;
    color: #ff6b6b;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.settings-btn-signout:hover {
    background: rgba(239, 68, 68, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.settings-btn-signout svg {
    width: 18px;
    height: 18px;
}

/* Login Card Styles */
.settings-login-card {
    padding: 20px;
    background: rgba(30, 41, 59, 0.2);
    border-radius: 12px;
}

.settings-login-text {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 15px;
    text-align: center;
    line-height: 1.5;
}

.settings-login-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.settings-auth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 14px 20px;
    border-radius: 10px;
    text-decoration: none;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.settings-auth-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.settings-auth-btn:hover::before {
    left: 100%;
}

.settings-auth-btn svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.settings-auth-btn span {
    white-space: nowrap;
}

.google-settings {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
}

.google-settings:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(66, 133, 244, 0.3);
    border-color: rgba(66, 133, 244, 0.5);
}

.twitter-settings {
    background: rgba(29, 161, 242, 0.1);
    border: 1px solid rgba(29, 161, 242, 0.2);
    color: white;
}

.twitter-settings:hover {
    background: rgba(29, 161, 242, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(29, 161, 242, 0.3);
    border-color: rgba(29, 161, 242, 0.5);
}

/* Settings Close Button */
.settings-close-btn {
    width: 100%;
    padding: 16px;
    margin-top: 20px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.settings-close-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.settings-close-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
}

.settings-close-btn:hover::before {
    left: 100%;
}

.settings-close-btn:active {
    transform: translateY(0);
}

/* Buttons */
.btn-primary, .btn-secondary {
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 5px;
    position: relative;
    overflow: hidden;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.btn-primary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(99, 102, 241, 0.4),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.btn-primary:hover::before {
    width: 300px;
    height: 300px;
}

.btn-secondary {
    background: rgba(30, 41, 59, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: var(--text-primary);
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.btn-secondary:hover {
    background: rgba(99, 102, 241, 0.2);
    backdrop-filter: blur(15px);
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.4);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.2),
                inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

/* Cancel button styling */
#cancelDifficulty {
    margin-top: 10px;
    width: 100%;
}

/* Game Messages */
.game-message {
    position: fixed;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 30px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.9), rgba(255, 183, 0, 0.9));
    backdrop-filter: blur(10px);
    color: #000;
    font-size: 20px;
    font-weight: bold;
    border-radius: 50px;
    box-shadow: 0 10px 40px rgba(255, 215, 0, 0.5),
                0 0 60px rgba(255, 215, 0, 0.3);
    z-index: 1000;
    animation: slideDown 0.5s ease-out, fadeOut 0.5s ease-out 1.5s forwards;
}

@keyframes slideDown {
    from {
        transform: translate(-50%, -100px);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
}

/* Finish Screen */
.finish-content h1 {
    text-align: center;
    font-size: 42px;
    margin-bottom: 35px;
    font-weight: 700;
    animation: celebrateText 0.6s ease-out;
}

@keyframes celebrateText {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.score-breakdown {
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05),
                inset 0 -1px 0 rgba(0, 0, 0, 0.2);
}

.score-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 18px;
    transition: all 0.3s ease;
}

.score-row span:first-child {
    color: var(--text-secondary);
    font-weight: 500;
}

.score-row span:last-child {
    color: var(--text-primary);
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.score-row.total {
    border-top: 2px solid rgba(99, 102, 241, 0.3);
    margin-top: 15px;
    padding-top: 20px;
    font-size: 28px;
    font-weight: bold;
}

.score-row.total span:last-child {
    background: linear-gradient(135deg, #60a5fa, #c084fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    animation: pulseGlow 2s ease-in-out infinite;
}

@keyframes pulseGlow {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.2);
    }
}

.finish-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
}

.primary-actions {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.btn-large {
    padding: 16px 40px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.btn-small {
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
}

.btn-submit-score {
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2));
    color: #a78bfa;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-submit-score:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(139, 92, 246, 0.3));
    border-color: rgba(167, 139, 250, 0.5);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

/* Leaderboard Section */
.leaderboard-section {
    margin-top: 25px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: 16px;
    backdrop-filter: blur(10px);
}

.leaderboard-section.compact {
    padding: 18px;
    margin-top: 20px;
}

.leaderboard-title {
    text-align: center;
    font-size: 16px;
    font-weight: 700;
    color: #e2e8f0;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: linear-gradient(135deg, #60a5fa, #c084fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.leaderboard-item {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    background: rgba(30, 41, 59, 0.4);
    border-radius: 10px;
    border: 1px solid rgba(99, 102, 241, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.leaderboard-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s ease;
}

.leaderboard-item:hover::before {
    transform: translateX(100%);
}

.leaderboard-item:hover {
    background: rgba(30, 41, 59, 0.6);
    transform: translateX(5px);
}

.rank-badge {
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(99, 102, 241, 0.2);
    border-radius: 50%;
    font-weight: 700;
    font-size: 13px;
    color: #a78bfa;
    margin-right: 12px;
    flex-shrink: 0;
}

.leaderboard-item.rank-1 .rank-badge {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #1e293b;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.4);
}

.leaderboard-item.rank-2 .rank-badge {
    background: linear-gradient(135deg, #cbd5e1, #94a3b8);
    color: #1e293b;
    box-shadow: 0 0 15px rgba(203, 213, 225, 0.3);
}

.leaderboard-item.rank-3 .rank-badge {
    background: linear-gradient(135deg, #f97316, #ea580c);
    color: #fff;
    box-shadow: 0 0 15px rgba(249, 115, 22, 0.3);
}

.player-name {
    flex: 1;
    font-weight: 600;
    font-size: 14px;
    color: #e2e8f0;
}

.player-score {
    font-weight: 700;
    font-size: 15px;
    color: #60a5fa;
    margin-left: auto;
    font-variant-numeric: tabular-nums;
}

.leaderboard-item.rank-1 .player-score {
    color: #fbbf24;
    font-size: 16px;
}

.leaderboard-item.rank-2 .player-score {
    color: #cbd5e1;
}

.leaderboard-item.rank-3 .player-score {
    color: #f97316;
}

/* Sign Up Section (placeholder) */
.signup-section {
    background: rgba(99, 102, 241, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 15px;
    padding: 20px;
    margin: 20px 0;
    text-align: center;
}

.signup-section h3 {
    color: var(--primary-color);
    margin-bottom: 10px;
    font-size: 18px;
}

.signup-section p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 15px;
    line-height: 1.5;
}

.signup-btn {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.signup-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(99, 102, 241, 0.4);
}

/* Tactics Overlay */
.tactics-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
}

#techniqueName {
    color: var(--primary-color);
    margin-bottom: 15px;
    font-size: 24px;
}

#techniqueDescription {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Animations */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes glow {
    0% { box-shadow: 0 0 5px var(--glow-color); }
    50% { box-shadow: 0 0 20px var(--glow-color), 0 0 30px var(--glow-color); }
    100% { box-shadow: 0 0 5px var(--glow-color); }
}

.cell-highlight {
    animation: glow 1s ease-in-out infinite;
}

.score-pop {
    position: absolute;
    font-size: 24px;
    font-weight: bold;
    color: var(--success-color);
    pointer-events: none;
    animation: scoreFloat 1s ease-out forwards;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5), 0 0 4px rgba(16, 185, 129, 0.4);
}

@keyframes scoreFloat {
    0% {
        transform: translateY(0) scale(0.5);
        opacity: 1;
    }
    100% {
        transform: translateY(-50px) scale(1);
        opacity: 0;
    }
}

/* Keep desktop at default sizes - no media query needed since base styles are for desktop */

/* Tablet/Mid-size screens */
@media (min-width: 769px) and (max-width: 1024px) {
    #gameLayer {
        max-width: 800px;
        padding: 30px 20px;
        gap: 25px;
    }
    
    #sudokuContainer {
        width: min(550px, calc(100vw - 40px));
        height: min(550px, calc(100vh - 250px));
    }
    
    #gridCanvas {
        max-width: 520px;
        max-height: 520px;
    }
    
    .num-btn {
        width: 80px;
        height: 80px;
    }
    
    #controlPanel {
        max-width: 420px;
    }
}

/* Mobile Specific Styles */
@media (max-width: 768px) {
    /* Fix for iOS Safari viewport - use available height */
    #gameContainer {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100vw;
        height: 100vh;
        height: calc(var(--vh, 1vh) * 100); /* Use JS-calculated viewport height */
        padding: 0;
        overflow: hidden;
    }
    
    #gameLayer {
        width: 100%;
        height: 100%;
        padding: 5px 0 0 0;
        gap: 5px;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        overflow: hidden;
        padding-top: max(5px, env(safe-area-inset-top, 5px));
        padding-bottom: env(safe-area-inset-bottom, 0);
    }
    
    #gameHeader {
        padding: 6px 10px;
        min-height: 40px;
        max-height: 40px;
        width: 100%;
        gap: 6px;
        flex-shrink: 0;
        z-index: 10;
    }
    
    .score-group {
        gap: 6px;
        padding: 0;
    }
    
    .score-label, .combo-label, .streak-label {
        font-size: 8px;
    }
    
    .score-value {
        font-size: 14px;
    }
    
    .streak-value {
        font-size: 12px;
    }
    
    .combo-multiplier {
        font-size: 11px;
    }
    
    .combo-meter {
        width: 45px;
        height: 3px;
    }
    
    .difficulty-badge {
        font-size: 9px;
        padding: 2px 5px;
    }
    
    #sudokuContainer {
        padding: 0;
        width: 100%;
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        min-height: 0; /* Important for flexbox */
        background: transparent;
        border: none;
        box-shadow: none;
        border-radius: 0;
    }
    
    #gridCanvas {
        width: min(95vw, calc(100vh - 180px)) !important;
        height: min(95vw, calc(100vh - 180px)) !important;
        max-width: 600px !important;
        max-height: 600px !important;
    }
    
    #controlPanel {
        width: 100%;
        padding: 10px 10px;
        padding-bottom: max(25px, calc(15px + env(safe-area-inset-bottom, 10px)));
        gap: 10px;
        flex-shrink: 0;
        background: transparent;
        border-top: none;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        max-height: 130px; /* Limit control panel height */
    }
    
    .side-actions {
        display: flex;
        flex-direction: column;
        gap: 5px;
        margin: 0 5px;
        flex-shrink: 0;
    }
    
    .icon-btn {
        width: 40px;
        height: 40px;
        padding: 8px;
        display: flex;
        align-items: center;
        justify-content: center;
        flex-shrink: 0;
    }
    
    #numberPad {
        gap: 5px;
        grid-template-columns: repeat(3, 1fr);
        display: grid;
        flex: 0 0 auto;
        width: 240px;
        max-width: 240px;
    }
    
    .num-btn {
        width: 100%;
        height: 42px;
        padding: 0;
        font-size: 18px;
        min-width: 0;
    }
    
    /* Fix modal centering on mobile */
    .modal, .overlay {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 20px;
    }
    
    .modal-content, .finish-content {
        width: 100%;
        max-width: 400px;
        max-height: 90vh;
        overflow-y: auto;
        margin: 0 auto;
        padding: 30px 20px;
    }
    
    .difficulty-options {
        gap: 10px;
    }
    
    .difficulty-btn {
        padding: 18px;
        font-size: 14px;
    }
    
    .difficulty-name {
        font-size: 18px;
    }
    
    .difficulty-desc {
        font-size: 12px;
    }
    
    .finish-content h1 {
        font-size: 32px;
    }
    
    .signup-section {
        padding: 15px;
        margin: 15px 0;
    }
    
    .signup-section h3 {
        font-size: 16px;
    }
    
    .signup-section p {
        font-size: 13px;
    }
    
    .finish-buttons {
        width: 100%;
    }
    
    .primary-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn-primary, .btn-secondary {
        width: 100%;
        margin: 5px 0;
    }
    
    .btn-large {
        width: 100%;
    }
    
    .btn-small {
        width: 100%;
    }
    
    .leaderboard-section {
        padding: 20px 15px;
    }
    
    .leaderboard-item {
        padding: 10px 12px;
    }
    
    .player-name {
        font-size: 14px;
    }
    
    .player-score {
        font-size: 15px;
    }
    
    #gameContainer {
        height: 100vh;
        height: 100dvh; /* Dynamic viewport height for mobile */
        overflow: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
}

/* Safari specific fixes (desktop and mobile) */
@supports (-webkit-appearance: none) and (stroke-color: transparent) {
    #gameLayer {
        display: -webkit-flex;
        display: flex;
        -webkit-flex-direction: column;
        flex-direction: column;
        -webkit-justify-content: space-between;
        justify-content: space-between;
        -webkit-align-items: center;
        align-items: center;
        height: 100vh;
        padding: 20px;
        box-sizing: border-box;
    }
    
    #gameHeader {
        -webkit-flex-shrink: 0;
        flex-shrink: 0;
    }
    
    #sudokuContainer {
        -webkit-flex-shrink: 0;
        flex-shrink: 0;
        width: min(520px, calc(100vw - 40px), calc(100vh - 240px));
        height: min(520px, calc(100vw - 40px), calc(100vh - 240px));
    }
    
    #controlPanel {
        -webkit-flex-shrink: 0;
        flex-shrink: 0;
    }
}

/* iOS Safari specific fixes */
@supports (-webkit-touch-callout: none) {
    #gameLayer {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
    }
    
    #gameHeader {
        position: sticky;
        top: 0;
        z-index: 100;
    }
    
    #sudokuContainer {
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
    }
    
    #gridCanvas {
        -webkit-backface-visibility: hidden;
        -webkit-transform: translateZ(0);
        backface-visibility: hidden;
        transform: translateZ(0);
    }
}

/* Even smaller screens */
@media (max-width: 400px) {
    #gameHeader {
        padding: 5px 8px;
    }
    
    .score-value {
        font-size: 16px;
    }
    
    .streak-value {
        font-size: 14px;
    }
    
    #numberPad {
        width: 220px;
        max-width: 220px;
    }
    
    .num-btn {
        height: 38px;
        font-size: 16px;
    }
    
    .icon-btn {
        width: 36px;
        height: 36px;
    }
    
    .control-btn {
        font-size: 12px;
        padding: 6px 10px;
    }
}

/* Contextual Erase Button */
.contextual-erase {
    position: absolute;
    width: 32px;
    height: 32px;
    background: rgba(239, 68, 68, 0.9);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 2000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3),
                0 0 20px rgba(239, 68, 68, 0.3);
    animation: popIn 0.2s ease-out;
}

.contextual-erase:hover {
    transform: scale(1.1);
    background: rgba(239, 68, 68, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4),
                0 0 30px rgba(239, 68, 68, 0.5);
}

.contextual-erase:active {
    transform: scale(0.95);
}

.contextual-erase.hidden {
    display: none;
}

.contextual-erase svg {
    width: 16px;
    height: 16px;
    stroke-width: 3;
}

/* Erase Popup */
.erase-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3000;
    animation: fadeIn 0.2s ease-out;
}

.erase-popup.hidden {
    display: none;
}

.erase-popup-content {
    background: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    animation: popIn 0.3s ease-out;
    min-width: 200px;
}

/* Mobile improvements for erase popup */
@media (max-width: 768px) {
    .erase-popup-content {
        padding: 15px;
        min-width: 250px;
    }
    
    .erase-option {
        min-height: 50px;
        padding: 12px 20px;
        font-size: 16px;
    }
}

.erase-option {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px 20px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.2s ease;
    margin: 5px 0;
}

.erase-option:hover {
    background: rgba(99, 102, 241, 0.2);
    transform: translateX(5px);
}

.erase-option svg {
    width: 20px;
    height: 20px;
}

.erase-option.cancel {
    color: var(--text-secondary);
    justify-content: center;
    border-top: 1px solid rgba(99, 102, 241, 0.2);
    margin-top: 10px;
    padding-top: 20px;
}

.erase-option.cancel:hover {
    background: rgba(239, 68, 68, 0.1);
    transform: none;
}

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

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

/* Combo meter penalty animations */
@keyframes comboPulseError {
    0%, 100% {
        box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
    }
    50% {
        box-shadow: 0 0 20px rgba(239, 68, 68, 0.8),
                    inset 0 0 10px rgba(239, 68, 68, 0.4);
        transform: scale(1.05);
    }
}

@keyframes comboPulseWarning {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(0.95);
        opacity: 0.7;
    }
}

.combo-pulse-error {
    animation: comboPulseError 0.5s ease-out;
}

.combo-pulse-warning {
    animation: comboPulseWarning 0.5s ease-out;
}

.combo-multiplier.combo-pulse-error {
    animation: comboPulseError 0.5s ease-out;
    color: var(--error-color) !important;
}

.combo-multiplier.combo-pulse-warning {
    animation: comboPulseWarning 0.5s ease-out;
    color: var(--secondary-color) !important;
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* High Contrast Theme */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #ffffff;
        --text-primary: #ffffff;
        --bg-primary: #000000;
        --bg-secondary: #1a1a1a;
        --border-color: #ffffff;
    }
}

/* Note Limit Message Animation */
@keyframes fadeInOut {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.9);
    }
    20% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    80% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.95);
    }
}

/* Login and Authentication Styles */
.login-prompt {
    margin-top: 20px;
    padding: 15px;
    background: linear-gradient(135deg, #667eea10 0%, #764ba210 100%);
    border: 1px solid #667eea30;
    border-radius: 10px;
}

.login-prompt-text {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    color: #666;
    font-size: 0.9rem;
}

.login-prompt-text svg {
    flex-shrink: 0;
    color: #667eea;
}

.login-link {
    display: inline-block;
    padding: 8px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.login-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Auth Buttons in Victory Screen */
.auth-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
}

.signup-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.google-btn {
    background: white;
    color: #333;
    border: 2px solid #e0e0e0;
}

.google-btn:hover {
    background: #f8f8f8;
    border-color: #4285F4;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(66, 133, 244, 0.3);
}

.twitter-btn {
    background: #000;
    color: white;
}

.twitter-btn:hover {
    background: #111;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.auth-icon {
    width: 20px;
    height: 20px;
}

/* User welcome message */
.signup-section h3 {
    color: #333;
    margin-bottom: 10px;
}

.signup-section p {
    color: #666;
    font-size: 0.95rem;
}


/* Quick Login Buttons in Difficulty Selector */
.quick-login-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 10px;
}

.quick-login-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.quick-login-btn svg {
    width: 18px;
    height: 18px;
}

.google-mini {
    background: white;
    color: #333;
    border: 1px solid #dadce0;
}

.google-mini:hover {
    background: #f8f9fa;
    border-color: #4285f4;
    box-shadow: 0 1px 3px rgba(66, 133, 244, 0.3);
}

.twitter-mini {
    background: #000;
    color: white;
    border: 1px solid #000;
}

.twitter-mini:hover {
    background: #1a1a1a;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}


/* Logged In User Display in Difficulty Selector */
.login-prompt.logged-in {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.15) 0%, rgba(5, 150, 105, 0.15) 100%);
    border-color: #10b981;
    background-color: rgba(255, 255, 255, 0.05); /* Add slight white background for better contrast */
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}

.user-icon {
    color: #10b981;
    flex-shrink: 0;
}

.user-details {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.user-label {
    font-size: 0.75rem;
    color: #9ca3af;  /* Lighter gray for better visibility on dark backgrounds */
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.user-email {
    font-size: 0.95rem;
    color: #10b981;  /* Changed to green for better visibility */
    font-weight: 600;  /* Made bolder */
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.check-icon {
    color: #10b981;
    flex-shrink: 0;
}


/* Victory Screen Logged In Display */
.signup-section.logged-in-victory {
    background: linear-gradient(135deg, #10b98115 0%, #05966915 100%);
    border: 1px solid #10b98130;
    border-radius: 12px;
    padding: 20px;
}

/* Compact logged-in victory section */
.signup-section.logged-in-victory.compact {
    padding: 12px 16px;
    margin-top: 18px;
}

.user-status-victory {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.user-info-compact {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.btn-submit-score-inline {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2));
    color: #a78bfa;
    border: 1px solid rgba(167, 139, 250, 0.3);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-submit-score-inline:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(139, 92, 246, 0.3));
    border-color: rgba(167, 139, 250, 0.5);
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.2);
}

.user-status-victory {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.user-icon-victory {
    color: #10b981;
    flex-shrink: 0;
}

.user-details-victory {
    display: flex;
    flex-direction: column;
}

.user-label-victory {
    font-size: 0.85rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.user-email-victory {
    font-size: 1.1rem;
    color: #e5e7eb;
    font-weight: 600;
}

.check-icon-victory {
    color: #10b981;
    flex-shrink: 0;
}

/* Menu Popup User Status */
.menu-user-status {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    background: linear-gradient(135deg, #667eea10 0%, #764ba210 100%);
    border-radius: 8px;
    margin-bottom: 12px;
    border: 1px solid #667eea20;
}

.menu-user-icon {
    color: #667eea;
    flex-shrink: 0;
}

.menu-user-email {
    font-size: 0.9rem;
    color: #374151;
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Menu Login Prompt */
.menu-login-prompt {
    padding: 12px 16px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.05), rgba(139, 92, 246, 0.05));
    border-radius: 10px;
    margin-bottom: 12px;
    border: 1px solid rgba(99, 102, 241, 0.2);
}

.menu-login-text {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.menu-login-text svg {
    width: 16px;
    height: 16px;
    color: var(--primary-color);
}

.menu-quick-login {
    display: flex;
    gap: 8px;
}

.menu-login-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    background: rgba(30, 41, 59, 0.3);
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.menu-login-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.menu-login-btn svg {
    width: 16px;
    height: 16px;
}

.menu-login-btn.google-mini:hover {
    background: rgba(66, 133, 244, 0.2);
    border-color: rgba(66, 133, 244, 0.4);
}

.menu-login-btn.twitter-mini:hover {
    background: rgba(0, 0, 0, 0.3);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Offline Indicator */
.offline-indicator {
    position: fixed;
    top: 70px;
    right: 20px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.9), rgba(220, 38, 38, 0.9));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 10px;
    padding: 8px 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2),
                0 0 20px rgba(239, 68, 68, 0.2);
    z-index: 1000;
    transition: all 0.3s ease;
    animation: slideInRight 0.3s ease-out;
}

.offline-indicator.hidden {
    display: none;
}

.offline-indicator.online {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.9), rgba(22, 163, 74, 0.9));
    border-color: rgba(34, 197, 94, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2),
                0 0 20px rgba(34, 197, 94, 0.2);
}

.offline-content {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 500;
    color: white;
}

.offline-icon {
    font-size: 1rem;
}

.sync-status {
    font-size: 0.75rem;
    opacity: 0.9;
    padding-left: 8px;
    border-left: 1px solid rgba(255, 255, 255, 0.3);
    margin-left: 4px;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Settings Account Section */
.account-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 15px;
    padding: 10px;
    background: #f9fafb;
    border-radius: 6px;
}

.account-label {
    font-size: 0.8rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.account-email {
    font-size: 1rem;
    color: #111827;
    font-weight: 500;
}

.btn-signout {
    width: 100%;
    padding: 10px 20px;
    background: white;
    color: #dc2626;
    border: 1px solid #dc2626;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-signout:hover {
    background: #dc2626;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}


/* Settings Login Section */
.settings-login-prompt {
    padding: 15px;
    background: #f9fafb;
    border-radius: 8px;
}

.settings-login-text {
    font-size: 0.9rem;
    color: #6b7280;
    margin-bottom: 15px;
    text-align: center;
}

.settings-login-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.settings-login-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 16px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.settings-login-btn svg {
    width: 20px;
    height: 20px;
}

.google-settings {
    background: white;
    color: #333;
    border: 2px solid #e0e0e0;
}

.google-settings:hover {
    background: #f8f8f8;
    border-color: #4285F4;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 133, 244, 0.3);
}

.twitter-settings {
    background: #000;
    color: white;
    border: 2px solid #000;
}

.twitter-settings:hover {
    background: #111;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}
