  :root {
            --bg-primary: #0f172a;
            --bg-surface: #1e293b;
            --bg-surface-elevated: #334155;
            --border-default: #334155;
            --border-highlight: #475569;
            --text-primary: #f8fafc;
            --text-secondary: #94a3b8;
            --text-muted: #64748b;
            --color-gold: #f59e0b;
            --color-orange: #ea580c;
            --color-green: #10b981;
            --color-blue: #3b82f6;
            --color-red: #ef4444;
            --color-purple: #8b5cf6;
            --color-cyan: #06b6d4;
            --radius-md: 10px;
            --radius-lg: 18px;
            --radius-xl: 26px;
            --shadow-card: 0 10px 25px -5px rgba(0, 0, 0, 0.45), 0 8px 10px -6px rgba(0, 0, 0, 0.4);
            --shadow-glow: 0 0 24px rgba(245, 158, 11, 0.35);
            --cell-size: clamp(42px, min(9vw, 7.5vh), 76px);
            --grid-gap: 5px;
        }

        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
            -webkit-tap-highlight-color: transparent;
            user-select: none;
            -webkit-user-select: none;
        }

        html, body {
            width: 100%;
            height: 100%;
            overflow: hidden;
            background: var(--bg-primary);
            color: var(--text-primary);
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
            touch-action: none;
        }

        /* App Container & Sky Background */
        .game-app {
            position: relative;
            width: 100%;
            height: 100dvh;
            display: flex;
            flex-direction: column;
            overflow: hidden;
            background: var(--bg-primary);
        }

        .scene-background {
            position: absolute;
            inset: 0;
            z-index: 0;
            pointer-events: none;
            overflow: hidden;
            background: linear-gradient(180deg, #090e17 0%, #0f172a 45%, #162442 75%, #0f172a 100%);
        }

        .scene-stars {
            position: absolute;
            inset: 0;
        }

        .star-item {
            position: absolute;
            background: #ffffff;
            border-radius: 50%;
            animation: twinkleAnimation 3.5s infinite ease-in-out;
        }

        @keyframes twinkleAnimation {
            0%, 100% { opacity: 0.15; transform: scale(0.6); }
            50% { opacity: 0.95; transform: scale(1); }
        }

        .scene-mountain-layer {
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            height: 38%;
            opacity: 0.65;
        }

        .scene-ground {
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            height: 10%;
            background: linear-gradient(180deg, #132a1e 0%, #09140e 100%);
            border-top: 2px solid rgba(16, 185, 129, 0.2);
        }

        .scene-rail-tracks {
            position: absolute;
            bottom: 7.5%;
            left: 0;
            right: 0;
            height: 4px;
            background: repeating-linear-gradient(90deg, #64748b 0px, #64748b 24px, transparent 24px, transparent 38px);
            opacity: 0.55;
        }

        .scene-cloud {
            position: absolute;
            background: rgba(255, 255, 255, 0.07);
            border-radius: 999px;
            animation: cloudDrift linear infinite;
        }

        @keyframes cloudDrift {
            from { transform: translateX(110vw); }
            to { transform: translateX(-40vw); }
        }

        .scene-tree {
            position: absolute;
            bottom: 8.5%;
            animation: treeDrift linear infinite;
        }

        @keyframes treeDrift {
            from { transform: translateX(110vw); }
            to { transform: translateX(-30vw); }
        }

        .tree-canopy {
            width: 28px;
            height: 22px;
            background: #1e4d2b;
            border-radius: 50% 50% 40% 40%;
            margin: 0 auto -4px;
        }

        .tree-stem {
            width: 7px;
            height: 20px;
            background: #271c14;
            border-radius: 2px 2px 0 0;
            margin: 0 auto;
        }

        /* Screens & Overlays */
        .screen-view {
            position: absolute;
            inset: 0;
            z-index: 10;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
        }

        .is-hidden {
            display: none !important;
        }

        /* Start Screen Layout */
        .start-container {
            padding: 24px;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 28px;
        }

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

        .brand-mascot {
            font-size: clamp(54px, 12vw, 82px);
            display: block;
            line-height: 1.15;
            filter: drop-shadow(0 8px 20px rgba(245, 158, 11, 0.55));
            animation: gentleBob 3.2s infinite ease-in-out;
        }

        @keyframes gentleBob {
            0%, 100% { transform: translateY(0) rotate(-2deg); }
            50% { transform: translateY(-8px) rotate(2deg); }
        }

        .brand-header h1 {
            font-size: clamp(30px, 7vw, 54px);
            font-weight: 900;
            letter-spacing: 0.5px;
            background: linear-gradient(135deg, #f59e0b 0%, #ea580c 50%, #f59e0b 100%);
            background-size: 200% auto;
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            animation: textShimmer 4s infinite linear;
            margin-top: 6px;
        }

        @keyframes textShimmer {
            to { background-position: 200% center; }
        }

        .brand-subtitle {
            font-size: clamp(11px, 2.5vw, 14px);
            color: var(--text-secondary);
            letter-spacing: 3px;
            text-transform: uppercase;
            margin-top: 6px;
        }

        .menu-card {
            background: linear-gradient(145deg, var(--bg-surface) 0%, var(--bg-surface-elevated) 100%);
            border: 1px solid var(--border-highlight);
            border-radius: var(--radius-xl);
            padding: clamp(24px, 5vw, 36px) clamp(28px, 6vw, 48px);
            box-shadow: var(--shadow-card);
            width: min(380px, 90vw);
            display: flex;
            flex-direction: column;
            gap: 14px;
            align-items: center;
        }

        /* Buttons & Controls */
        .btn {
            border: none;
            cursor: pointer;
            border-radius: var(--radius-md);
            font-family: inherit;
            font-weight: 700;
            transition: transform 0.12s ease, filter 0.15s ease, box-shadow 0.15s ease;
            position: relative;
            overflow: hidden;
            letter-spacing: 0.3px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 8px;
        }

        .btn:active {
            transform: scale(0.96);
        }

        .btn-primary {
            background: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
            color: #ffffff;
            font-size: clamp(15px, 3.5vw, 17px);
            padding: 15px 32px;
            width: 100%;
            box-shadow: 0 4px 20px rgba(245, 158, 11, 0.4);
        }

        .btn-primary:hover {
            filter: brightness(1.08);
            box-shadow: 0 6px 28px rgba(245, 158, 11, 0.55);
        }

        .btn-secondary {
            background: var(--bg-surface-elevated);
            color: var(--text-primary);
            font-size: clamp(13px, 3vw, 15px);
            padding: 12px 24px;
            width: 100%;
            border: 1px solid var(--border-highlight);
        }

        .btn-secondary:hover {
            background: #475569;
        }

        .btn-icon {
            background: var(--bg-surface-elevated);
            border: 1px solid var(--border-default);
            border-radius: var(--radius-md);
            color: var(--text-secondary);
            width: 42px;
            height: 42px;
            font-size: 18px;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.15s;
            flex-shrink: 0;
        }

        .btn-icon:hover {
            background: var(--border-highlight);
            color: var(--text-primary);
        }

        .btn-icon.is-active {
            color: var(--color-gold);
            border-color: var(--color-gold);
            background: rgba(245, 158, 11, 0.12);
        }

        .sfx-toolbar {
            display: flex;
            gap: 12px;
            justify-content: center;
            margin-top: 4px;
        }

        /* Gameplay Screen */
        .game-screen {
            position: absolute;
            inset: 0;
            z-index: 10;
            display: flex;
            flex-direction: column;
            align-items: stretch;
            justify-content: flex-start;
            height: 100dvh;
            padding: env(safe-area-inset-top, 0px) env(safe-area-inset-right, 0px) env(safe-area-inset-bottom, 0px) env(safe-area-inset-left, 0px);
        }

        /* Header Bar */
        .game-header {
            background: linear-gradient(90deg, var(--bg-surface) 0%, var(--bg-surface-elevated) 100%);
            border-bottom: 1px solid var(--border-default);
            padding: clamp(8px, 1.5vh, 12px) clamp(10px, 2vw, 20px);
            display: flex;
            align-items: center;
            gap: clamp(8px, 1.5vw, 16px);
            flex-shrink: 0;
            z-index: 20;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.45);
        }

        .header-brand {
            font-size: clamp(13px, 2.3vw, 16px);
            font-weight: 900;
            background: linear-gradient(135deg, #f59e0b, #ea580c);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            white-space: nowrap;
            letter-spacing: 0.5px;
            display: flex;
            align-items: center;
            gap: 5px;
        }

        .header-scores {
            display: flex;
            gap: clamp(6px, 1.2vw, 10px);
            flex-shrink: 0;
        }

        .stat-card {
            background: var(--bg-primary);
            border: 1px solid var(--border-default);
            border-radius: 8px;
            padding: clamp(4px, 0.8vw, 6px) clamp(8px, 1.5vw, 14px);
            text-align: center;
            min-width: clamp(52px, 10vw, 86px);
        }

        .stat-card .stat-label {
            font-size: clamp(8px, 1.2vw, 10px);
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.8px;
        }

        .stat-card .stat-value {
            font-size: clamp(13px, 2.5vw, 18px);
            font-weight: 900;
            color: var(--color-gold);
        }

        .fuel-meter-container {
            flex: 1;
            min-width: 0;
            display: flex;
            flex-direction: column;
            gap: 3px;
        }

        .fuel-meter-info {
            display: flex;
            justify-content: space-between;
            font-size: clamp(8px, 1.3vw, 11px);
            color: var(--text-secondary);
        }

        .fuel-meter-track {
            height: clamp(8px, 1.5vw, 11px);
            background: var(--bg-primary);
            border: 1px solid var(--border-default);
            border-radius: 999px;
            overflow: hidden;
        }

        .fuel-meter-bar {
            height: 100%;
            border-radius: 999px;
            background: linear-gradient(90deg, #ea580c, #f59e0b, #10b981);
            background-size: 200% 100%;
            transition: width 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
            animation: fuelFlow 2s linear infinite;
        }

        @keyframes fuelFlow {
            to { background-position: -200% 0; }
        }

        .destination-info {
            min-width: 0;
            display: flex;
            flex-direction: column;
            gap: 1px;
        }

        .destination-label {
            font-size: clamp(8px, 1.3vw, 10px);
            color: var(--text-muted);
            text-transform: uppercase;
        }

        .destination-name {
            font-size: clamp(10px, 1.8vw, 14px);
            font-weight: 700;
            color: var(--color-green);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .header-controls {
            display: flex;
            gap: 8px;
            flex-shrink: 0;
        }

        /* Game Board Area */
        .board-workspace {
            flex: 1;
            display: flex;
            align-items: flex-start;
            justify-content: center;
            gap: clamp(8px, 1.8vw, 18px);
            padding: clamp(8px, 1.5vw, 14px);
            overflow: hidden;
            min-height: 0;
        }

        /* Side Navigation & Tool Panels */
        .side-column {
            display: flex;
            flex-direction: column;
            gap: clamp(8px, 1.3vw, 12px);
            flex-shrink: 0;
            width: clamp(82px, 15vw, 132px);
            overflow-y: auto;
            overflow-x: hidden;
            scrollbar-width: none;
        }

        .side-column::-webkit-scrollbar {
            display: none;
        }

        .panel-widget {
            background: linear-gradient(135deg, var(--bg-surface) 0%, var(--bg-surface-elevated) 100%);
            border: 1px solid var(--border-default);
            border-radius: var(--radius-md);
            padding: clamp(10px, 1.5vw, 14px);
            box-shadow: var(--shadow-card);
            flex-shrink: 0;
        }

        .panel-heading {
            font-size: clamp(8px, 1.3vw, 10px);
            text-transform: uppercase;
            letter-spacing: 1px;
            color: var(--text-muted);
            text-align: center;
            margin-bottom: 8px;
        }

        .next-preview-box {
            display: flex;
            align-items: center;
            justify-content: center;
            width: clamp(48px, 9vw, 70px);
            height: clamp(48px, 9vw, 70px);
            border-radius: var(--radius-md);
            font-weight: 900;
            font-size: clamp(16px, 3vw, 24px);
            margin: 0 auto;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
            transition: background 0.25s ease, color 0.25s ease;
        }

        .powerup-button {
            width: 100%;
            background: var(--bg-surface-elevated);
            border: 1.5px solid var(--border-default);
            border-radius: var(--radius-md);
            color: var(--text-primary);
            cursor: pointer;
            font-family: inherit;
            font-size: clamp(9px, 1.4vw, 11px);
            font-weight: 700;
            padding: clamp(8px, 1.3vw, 11px) 6px;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 4px;
            transition: all 0.15s ease;
            position: relative;
            overflow: hidden;
        }

        .powerup-button .icon-glyph {
            font-size: clamp(18px, 3.5vw, 24px);
            line-height: 1;
        }

        .powerup-button .count-badge {
            font-size: clamp(8px, 1.2vw, 10px);
            color: var(--text-secondary);
            font-weight: 700;
        }

        .powerup-button:hover:not(:disabled) {
            background: var(--border-highlight);
            border-color: var(--color-gold);
        }

        .powerup-button:active:not(:disabled) {
            transform: scale(0.95);
        }

        .powerup-button:disabled {
            opacity: 0.35;
            cursor: not-allowed;
        }

        .powerup-button.is-selected {
            border-color: var(--color-green);
            background: rgba(16, 185, 129, 0.16);
            box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.25);
        }

        /* Journey Track List */
        .journey-list {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }

        .journey-station {
            display: flex;
            align-items: center;
            gap: 6px;
            font-size: clamp(8px, 1.3vw, 11px);
            color: var(--text-muted);
        }

        .journey-station.is-current {
            color: var(--color-green);
            font-weight: 700;
        }

        .journey-station.is-completed {
            color: var(--text-secondary);
        }

        .station-indicator {
            width: 8px;
            height: 8px;
            border-radius: 50%;
            background: var(--text-muted);
            flex-shrink: 0;
        }

        .journey-station.is-current .station-indicator {
            background: var(--color-green);
            box-shadow: 0 0 8px rgba(16, 185, 129, 0.85);
        }

        .journey-station.is-completed .station-indicator {
            background: var(--color-gold);
        }

        .journey-connector {
            width: 2px;
            height: 10px;
            background: var(--border-default);
            margin-left: 3px;
        }

        .journey-connector.is-completed {
            background: var(--color-gold);
        }

        /* Stats Row */
        .metric-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            font-size: clamp(9px, 1.4vw, 11px);
        }

        .metric-label {
            color: var(--text-muted);
        }

        .metric-value {
            color: var(--text-primary);
            font-weight: 700;
        }

        /* Grid Board */
        .board-canvas-frame {
            position: relative;
            flex-shrink: 0;
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        .board-surface {
            position: relative;
            background: linear-gradient(135deg, #162036 0%, #0f172a 100%);
            border: 2px solid var(--border-highlight);
            border-radius: var(--radius-md);
            box-shadow: var(--shadow-card), inset 0 1px 0 rgba(255, 255, 255, 0.05);
            overflow: hidden;
            cursor: pointer;
        }

        .board-grid-layer {
            display: grid;
            gap: var(--grid-gap, 5px);
            padding: var(--grid-gap, 5px);
        }

        .cell-slot {
            background: rgba(255, 255, 255, 0.035);
            border: 1px solid rgba(255, 255, 255, 0.05);
            border-radius: 8px;
        }

        .danger-line-indicator {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: calc((var(--cell-size, 54px) + var(--grid-gap, 5px)) * 2 + var(--grid-gap, 5px));
            background: linear-gradient(180deg, rgba(239, 68, 68, 0.22) 0%, transparent 100%);
            border-top: 2px solid var(--color-red);
            border-radius: var(--radius-md) var(--radius-md) 0 0;
            pointer-events: none;
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        .danger-line-indicator.is-alert {
            opacity: 1;
            animation: dangerPulse 1.1s infinite ease-in-out;
        }

        @keyframes dangerPulse {
            0%, 100% { border-color: rgba(239, 68, 68, 0.5); }
            50% { border-color: rgba(239, 68, 68, 1); box-shadow: 0 0 16px rgba(239, 68, 68, 0.5); }
        }

        .landing-ghost-tile {
            position: absolute;
            border-radius: 8px;
            border: 2px dashed rgba(255, 255, 255, 0.25);
            background: rgba(255, 255, 255, 0.05);
            pointer-events: none;
            z-index: 4;
            transition: left 0.1s ease, top 0.06s ease;
        }

        /* Tile Elements */
        .puzzle-tile {
            position: absolute;
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 900;
            z-index: 5;
            pointer-events: none;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.45);
            transition: left 0.12s ease;
            user-select: none;
        }

        .puzzle-tile.is-falling {
            z-index: 8;
        }

        .puzzle-tile.is-landing {
            animation: tileLandSquish 0.22s cubic-bezier(0.34, 1.56, 0.64, 1);
        }

        @keyframes tileLandSquish {
            0% { transform: scaleY(1.15) scaleX(0.88); }
            60% { transform: scaleY(0.9) scaleX(1.08); }
            100% { transform: scale(1); }
        }

        .puzzle-tile.is-merging {
            animation: tileMergeBounce 0.28s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
            z-index: 9;
        }

        @keyframes tileMergeBounce {
            0% { transform: scale(1); filter: brightness(1); }
            45% { transform: scale(1.35); filter: brightness(1.65); }
            100% { transform: scale(1); filter: brightness(1); }
        }

        .puzzle-tile.is-spawning {
            animation: tileSpawnIn 0.24s cubic-bezier(0.34, 1.56, 0.64, 1);
        }

        @keyframes tileSpawnIn {
            from { transform: scale(0.35); opacity: 0; }
            to { transform: scale(1); opacity: 1; }
        }

        /* Particle Canvas */
        .fx-canvas {
            position: absolute;
            inset: 0;
            pointer-events: none;
            z-index: 40;
        }

        /* Combo Badge Overlay */
        .combo-badge-overlay {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            pointer-events: none;
            z-index: 50;
            text-align: center;
            opacity: 0;
        }

        .combo-badge-overlay.is-visible {
            animation: comboPopIn 1.3s ease forwards;
        }

        @keyframes comboPopIn {
            0% { opacity: 0; transform: translate(-50%, -50%) scale(0.35); }
            20% { opacity: 1; transform: translate(-50%, -50%) scale(1.22); }
            70% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
            100% { opacity: 0; transform: translate(-50%, -50%) scale(0.85); }
        }

        .combo-badge-title {
            font-size: clamp(22px, 5.5vw, 38px);
            font-weight: 900;
            color: #ffffff;
            text-shadow: 0 3px 18px rgba(245, 158, 11, 0.95), 0 0 45px rgba(245, 158, 11, 0.6);
            letter-spacing: 2px;
        }

        .combo-badge-subtitle {
            font-size: clamp(11px, 2vw, 14px);
            color: var(--color-gold);
            font-weight: 800;
            letter-spacing: 3px;
            text-transform: uppercase;
        }

        .float-score-label {
            position: absolute;
            font-weight: 900;
            color: var(--color-gold);
            pointer-events: none;
            z-index: 50;
            text-shadow: 0 2px 8px rgba(0, 0, 0, 0.75);
            animation: floatScoreUp 1s ease forwards;
            font-size: clamp(13px, 2.6vw, 18px);
            white-space: nowrap;
        }

        @keyframes floatScoreUp {
            0% { opacity: 1; transform: translateY(0) scale(1); }
            100% { opacity: 0; transform: translateY(-56px) scale(0.72); }
        }

        /* Mobile Action Toolbar */
        .mobile-action-bar {
            display: none;
            background: linear-gradient(90deg, var(--bg-surface) 0%, var(--bg-surface-elevated) 100%);
            border-top: 1px solid var(--border-default);
            padding: clamp(6px, 1.4vh, 12px) clamp(10px, 2.5vw, 20px);
            gap: 10px;
            align-items: center;
            justify-content: center;
            flex-shrink: 0;
        }

        .action-button {
            background: var(--bg-surface-elevated);
            border: 1.5px solid var(--border-highlight);
            border-radius: var(--radius-md);
            color: var(--text-primary);
            font-size: clamp(18px, 4.5vw, 26px);
            width: clamp(52px, 14vw, 70px);
            height: clamp(46px, 12vw, 60px);
            cursor: pointer;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            transition: transform 0.1s ease, background 0.15s ease;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
        }

        .action-button:active {
            background: var(--border-default);
            transform: scale(0.92);
        }

        .action-button.is-drop {
            background: linear-gradient(135deg, #ea580c, #f59e0b);
            border-color: rgba(245, 158, 11, 0.6);
            flex: 1;
            max-width: 130px;
            font-size: clamp(13px, 3.2vw, 16px);
            font-weight: 800;
            color: #ffffff;
            letter-spacing: 0.5px;
            flex-direction: column;
            gap: 2px;
        }

        .action-button.is-drop .btn-glyph {
            font-size: clamp(18px, 4.5vw, 24px);
            line-height: 1;
        }

        /* Modal Dialog & Overlays */
        .modal-overlay {
            position: absolute;
            inset: 0;
            z-index: 100;
            background: rgba(5, 10, 20, 0.88);
            display: flex;
            align-items: center;
            justify-content: center;
            backdrop-filter: blur(8px);
            animation: modalFadeIn 0.25s ease;
            padding: 16px;
        }

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

        .modal-card {
            background: linear-gradient(145deg, var(--bg-surface) 0%, var(--bg-surface-elevated) 100%);
            border: 1px solid var(--border-highlight);
            border-radius: var(--radius-xl);
            padding: clamp(22px, 4vw, 38px);
            box-shadow: var(--shadow-card);
            width: min(400px, 94vw);
            max-height: 90dvh;
            overflow-y: auto;
            display: flex;
            flex-direction: column;
            align-items: center;
            gap: 16px;
            animation: modalPopIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
            scrollbar-width: none;
        }

        .modal-card::-webkit-scrollbar {
            display: none;
        }

        @keyframes modalPopIn {
            from { transform: scale(0.75) translateY(24px); opacity: 0; }
            to { transform: scale(1) translateY(0); opacity: 1; }
        }

        .modal-title {
            font-size: clamp(22px, 5vw, 32px);
            font-weight: 900;
            text-align: center;
        }

        .text-gold {
            background: linear-gradient(135deg, #f59e0b, #ea580c);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
        }

        .text-red { color: var(--color-red); }
        .text-green { color: var(--color-green); }

        .stat-grid-summary {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            width: 100%;
        }

        .stat-cell-box {
            background: var(--bg-primary);
            border-radius: var(--radius-md);
            padding: 12px;
            text-align: center;
            border: 1px solid var(--border-default);
        }

        .stat-cell-box .cell-label {
            font-size: clamp(9px, 1.5vw, 11px);
            color: var(--text-muted);
            text-transform: uppercase;
            letter-spacing: 0.8px;
        }

        .stat-cell-box .cell-value {
            font-size: clamp(15px, 3.2vw, 21px);
            font-weight: 900;
            color: var(--color-gold);
        }

        .modal-actions {
            display: flex;
            flex-direction: column;
            gap: 10px;
            width: 100%;
        }

        .modal-description {
            color: var(--text-secondary);
            font-size: clamp(12px, 2.4vw, 15px);
            text-align: center;
            line-height: 1.5;
        }

        /* Tutorial List */
        .tutorial-steps-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
            width: 100%;
        }

        .tutorial-step-row {
            display: flex;
            align-items: flex-start;
            gap: 12px;
            padding: 10px 12px;
            background: rgba(255, 255, 255, 0.04);
            border-radius: 8px;
            border: 1px solid var(--border-default);
        }

        .tutorial-badge {
            width: 26px;
            height: 26px;
            border-radius: 50%;
            background: linear-gradient(135deg, #f59e0b, #ea580c);
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 12px;
            font-weight: 800;
            flex-shrink: 0;
            color: #ffffff;
        }

        .tutorial-step-row p {
            font-size: clamp(11px, 2.1vw, 13px);
            color: var(--text-secondary);
            line-height: 1.45;
        }

        .tutorial-step-row p strong {
            color: var(--color-gold);
        }

        /* Train Travel Animation */
        .train-transition-overlay {
            position: absolute;
            inset: 0;
            z-index: 200;
            pointer-events: none;
            overflow: hidden;
            display: flex;
            align-items: center;
        }

        .train-sprite {
            font-size: clamp(44px, 10vw, 72px);
            position: absolute;
            white-space: nowrap;
            filter: drop-shadow(0 6px 20px rgba(245, 158, 11, 0.75));
        }

        /* Media Queries */
        @media (max-width: 768px) {
            .side-column {
                width: clamp(70px, 14vw, 104px);
            }
            .mobile-action-bar {
                display: flex;
            }
        }

        @media (max-width: 580px) {
            .side-column {
                display: none;
            }
            .mobile-action-bar {
                display: flex;
            }
        }

        @media (max-width: 420px) {
            .header-brand {
                display: none;
            }
            .stat-card {
                min-width: 46px;
                padding: 4px 6px;
            }
            .game-header {
                gap: 6px;
            }
        }

        @media (max-height: 520px) and (orientation: landscape) {
            .game-header {
                padding: 4px 10px;
            }
            .board-workspace {
                padding: 4px;
                gap: 6px;
            }
            .mobile-action-bar {
                padding: 4px 10px;
            }
            .header-brand {
                display: none;
            }
        }