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

        body {
            font-family: 'Microsoft YaHei', 'SF Pro Display', -apple-system, sans-serif;
            background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
            min-height: 100vh;
            color: #2c3e50;
            padding: 20px;
            overflow-x: hidden;
        }

        .game-container {
            max-width: 1200px;
            margin: 0 auto;
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(20px);
            border-radius: 24px;
            padding: 30px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
        }

        h1 {
            text-align: center;
            font-size: 2.8rem;
            color: #2c3e50;
            margin-bottom: 30px;
            font-weight: 700;
            text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
        }

        .game-phase {
            text-align: center;
            margin-bottom: 30px;
            padding: 20px;
            background: linear-gradient(135deg, #3498DB, #2980B9);
            color: white;
            border-radius: 16px;
            box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
        }

        .phase-title {
            font-size: 1.5rem;
            font-weight: 700;
            margin-bottom: 10px;
        }

        .phase-description {
            font-size: 1rem;
            opacity: 0.9;
        }

        .game-controls {
            display: flex;
            gap: 15px;
            margin-bottom: 30px;
            justify-content: center;
            flex-wrap: wrap;
        }

        .btn {
            padding: 12px 24px;
            border: none;
            border-radius: 50px;
            background: linear-gradient(135deg, #667eea, #764ba2);
            color: white;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            font-size: 0.9rem;
            box-shadow: 0 6px 20px rgba(102, 126, 234, 0.3);
        }

        .btn:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
        }

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

        .btn:disabled {
            background: #94a3b8;
            cursor: not-allowed;
            transform: none;
            box-shadow: none;
        }

        .btn.secondary {
            background: linear-gradient(135deg, #4ECDC4, #44A08D);
            box-shadow: 0 6px 20px rgba(78, 205, 196, 0.3);
        }

        .btn.secondary:hover {
            box-shadow: 0 8px 25px rgba(78, 205, 196, 0.4);
        }

        .btn.danger {
            background: linear-gradient(135deg, #E74C3C, #C0392B);
            box-shadow: 0 6px 20px rgba(231, 76, 60, 0.3);
        }

        .btn.danger:hover {
            box-shadow: 0 8px 25px rgba(231, 76, 60, 0.4);
        }

        .boards-container {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 30px;
            margin-bottom: 30px;
        }

        .board-section {
            background: rgba(255, 255, 255, 0.8);
            padding: 20px;
            border-radius: 16px;
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
        }

        .board-title {
            text-align: center;
            font-size: 1.3rem;
            font-weight: 700;
            color: #2c3e50;
            margin-bottom: 20px;
        }

        .board {
            display: grid;
            grid-template-columns: repeat(10, 35px);
            grid-template-rows: repeat(10, 35px);
            gap: 2px;
            margin: 0 auto;
            background: #34495e;
            padding: 10px;
            border-radius: 12px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
        }

        .cell {
            background: #3498DB;
            border-radius: 4px;
            cursor: pointer;
            transition: all 0.2s ease;
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: 700;
            font-size: 0.8rem;
        }

        .cell:hover {
            transform: scale(1.1);
        }

        .cell.ship {
            background: #2c3e50;
            color: white;
        }

        .cell.hit {
            background: #E74C3C;
            color: white;
        }

        .cell.miss {
            background: #7f8c8d;
            color: white;
        }

        .cell.sunk {
            background: #8e44ad;
            color: white;
        }

        .cell.highlight {
            background: #f39c12;
            box-shadow: 0 0 0 2px #e67e22;
        }

        .ships-panel {
            background: rgba(255, 255, 255, 0.8);
            padding: 20px;
            border-radius: 16px;
            margin-bottom: 30px;
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
        }

        .ships-panel h3 {
            color: #2c3e50;
            margin-bottom: 15px;
            font-size: 1.2rem;
            text-align: center;
        }

        .ship-list {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 10px;
        }

        .ship-item {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 10px 15px;
            background: white;
            border-radius: 10px;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .ship-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
        }

        .ship-item.selected {
            background: linear-gradient(135deg, #3498DB, #2980B9);
            color: white;
        }

        .ship-item.placed {
            background: #95a5a6;
            color: white;
            cursor: not-allowed;
        }

        .ship-name {
            font-weight: 600;
        }

        .ship-size {
            background: rgba(0, 0, 0, 0.1);
            padding: 4px 8px;
            border-radius: 8px;
            font-size: 0.8rem;
        }

        .ship-item.selected .ship-size {
            background: rgba(255, 255, 255, 0.2);
        }

        .game-stats {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
            gap: 15px;
            margin-bottom: 30px;
        }

        .stat-item {
            background: linear-gradient(135deg, #3498DB, #2980B9);
            color: white;
            padding: 15px;
            border-radius: 16px;
            text-align: center;
            box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
        }

        .stat-label {
            font-size: 0.85rem;
            font-weight: 600;
            opacity: 0.9;
            margin-bottom: 5px;
        }

        .stat-value {
            font-size: 1.4rem;
            font-weight: 700;
        }

        .game-over-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.8);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 1000;
        }

        .game-over-content {
            background: white;
            padding: 40px;
            border-radius: 20px;
            text-align: center;
            max-width: 400px;
            margin: 20px;
            box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
        }

        .game-over-content h2 {
            color: #27ae60;
            margin-bottom: 20px;
            font-size: 2rem;
        }

        .winner-text {
            font-size: 1.5rem;
            color: #2c3e50;
            margin-bottom: 25px;
        }

        .celebration {
            font-size: 3rem;
            margin-bottom: 20px;
            animation: bounce 2s infinite;
        }

        @keyframes bounce {
            0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
            40% { transform: translateY(-10px); }
            60% { transform: translateY(-5px); }
        }

        .instructions {
            background: rgba(255, 255, 255, 0.8);
            padding: 25px;
            border-radius: 16px;
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
        }

        .instructions h3 {
            color: #2c3e50;
            margin-bottom: 20px;
            font-size: 1.3rem;
            text-align: center;
        }

        .instruction-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 15px;
        }

        .instruction-item {
            background: white;
            padding: 15px;
            border-radius: 12px;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
        }

        .instruction-item h4 {
            color: #3498DB;
            margin-bottom: 8px;
            font-size: 1rem;
        }

        .instruction-item p {
            color: #7f8c8d;
            font-size: 0.85rem;
            line-height: 1.4;
        }

        @media (max-width: 768px) {
            .game-container {
                padding: 20px;
                margin: 10px;
            }

            h1 {
                font-size: 2.2rem;
            }

            .boards-container {
                grid-template-columns: 1fr;
                gap: 20px;
            }

            .board {
                grid-template-columns: repeat(10, 30px);
                grid-template-rows: repeat(10, 30px);
            }

            .game-controls {
                flex-direction: column;
                align-items: center;
            }

            .btn {
                width: 100%;
                max-width: 200px;
            }

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

        @media (max-width: 480px) {
            .board {
                grid-template-columns: repeat(10, 25px);
                grid-template-rows: repeat(10, 25px);
            }

            .cell {
                font-size: 0.7rem;
            }
        }