/* Sexy Chess — Pinup Cartoon Theme */

@import url('https://fonts.googleapis.com/css2?family=Pacifico&family=Nunito:wght@400;600;700;800&display=swap');

:root {
    --bg: #fff0f3;
    --bg-warm: #ffe4ec;
    --pink-hot: #ff3b7a;
    --pink-light: #ff85a8;
    --pink-pastel: #ffc2d4;
    --coral: #ff6b6b;
    --peach: #ffb5a7;
    --gold: #ffd700;
    --gold-warm: #f0a500;
    --cream: #fff8f0;
    --red-lip: #d32f2f;
    --skin-light: #fdd9b5;
    --board-light: #ffe0e6;
    --board-dark: #d4607a;
    --text-dark: #3d1a2e;
    --text-mid: #7a4060;
    --text-light: rgba(61, 26, 46, 0.5);
    --shadow-pink: rgba(255, 59, 122, 0.25);
    --shadow-warm: rgba(255, 107, 107, 0.2);
    --board-radius: 12px;
    --sq-size: min(11.25vw, 70px);
}

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

html, body {
    height: 100%;
    overflow: hidden;
    font-family: 'Nunito', 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text-dark);
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

/* Fun Background */
.bg-decor {
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}
.bg-heart {
    position: absolute;
    font-size: 2rem;
    opacity: 0.18;
    animation: floatUp 10s ease-in-out infinite;
}
.bg-heart:nth-child(1) { left: 5%; animation-delay: 0s; font-size: 1.8rem; }
.bg-heart:nth-child(2) { left: 15%; animation-delay: -2s; font-size: 2.5rem; }
.bg-heart:nth-child(3) { left: 30%; animation-delay: -4s; font-size: 1.8rem; }
.bg-heart:nth-child(4) { left: 45%; animation-delay: -6s; font-size: 2.2rem; }
.bg-heart:nth-child(5) { left: 60%; animation-delay: -1.5s; font-size: 1.5rem; }
.bg-heart:nth-child(6) { left: 72%; animation-delay: -8s; font-size: 2.4rem; }
.bg-heart:nth-child(7) { left: 85%; animation-delay: -5s; font-size: 1.6rem; }
.bg-heart:nth-child(8) { left: 95%; animation-delay: -3s; font-size: 1.4rem; }

@keyframes floatUp {
    0% { transform: translateY(110vh) rotate(0deg) scale(0.8); opacity: 0; }
    10% { opacity: 0.2; }
    50% { opacity: 0.25; transform: translateY(50vh) rotate(20deg) scale(1.1); }
    90% { opacity: 0.15; }
    100% { transform: translateY(-10vh) rotate(45deg) scale(0.9); opacity: 0; }
}

/* Gradient background blob */
.bg-blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.35;
}
.bg-blob--1 {
    width: 400px; height: 400px;
    background: var(--pink-pastel);
    top: -10%; right: -10%;
    animation: blobDrift1 12s ease-in-out infinite alternate;
}
.bg-blob--2 {
    width: 300px; height: 300px;
    background: var(--peach);
    bottom: -5%; left: -5%;
    animation: blobDrift2 14s ease-in-out infinite alternate;
}
.bg-blob--3 {
    width: 250px; height: 250px;
    background: var(--gold);
    top: 40%; left: 50%;
    opacity: 0.18;
    animation: blobDrift3 10s ease-in-out infinite alternate;
}

@keyframes blobDrift1 {
    0% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(-40px, 30px) scale(1.1); }
    66% { transform: translate(30px, -20px) scale(0.95); }
    100% { transform: translate(-20px, 50px) scale(1.05); }
}
@keyframes blobDrift2 {
    0% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(50px, -30px) scale(1.08); }
    66% { transform: translate(-30px, 40px) scale(0.92); }
    100% { transform: translate(40px, -10px) scale(1.03); }
}
@keyframes blobDrift3 {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(-60px, 30px) scale(1.15) rotate(10deg); }
    100% { transform: translate(30px, -40px) scale(0.9) rotate(-5deg); }
}

/* Screens */
#app {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.screen {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 20px;
    animation: screenIn 0.5s ease;
}
.screen.active { display: flex; }

@keyframes screenIn {
    from { opacity: 0; transform: scale(0.97); }
    to { opacity: 1; transform: scale(1); }
}

/* Welcome Screen */
.welcome-deco {
    font-size: clamp(3rem, 10vw, 5rem);
    margin-bottom: 8px;
    animation: pieceWiggle 3s ease-in-out infinite;
    filter: drop-shadow(0 4px 8px var(--shadow-pink));
}
@keyframes pieceWiggle {
    0%, 100% { transform: rotate(-5deg); }
    25% { transform: rotate(5deg); }
    50% { transform: rotate(-3deg) scale(1.05); }
    75% { transform: rotate(4deg); }
}

.game-title {
    font-family: 'Pacifico', cursive;
    font-size: clamp(2.5rem, 9vw, 4.5rem);
    font-weight: 400;
    color: var(--pink-hot);
    text-shadow: 2px 2px 0 var(--pink-pastel), 4px 4px 0 rgba(255,59,122,0.1);
    margin-bottom: 4px;
    cursor: default;
    line-height: 1.2;
}
.subtitle {
    font-size: clamp(1rem, 3.5vw, 1.3rem);
    color: var(--text-mid);
    font-weight: 600;
    margin-bottom: 8px;
    letter-spacing: 0.02em;
}
.age-gate {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-bottom: 24px;
    text-align: center;
    line-height: 1.5;
    background: rgba(255,59,122,0.06);
    padding: 6px 16px;
    border-radius: 20px;
}
.welcome-tagline {
    font-size: 0.9rem;
    color: var(--text-mid);
    font-style: italic;
    margin-bottom: 24px;
    text-align: center;
    max-width: 300px;
    line-height: 1.5;
}

.player-setup {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    justify-content: center;
}
.player-setup input {
    background: white;
    border: 2px solid var(--pink-pastel);
    border-radius: 25px;
    padding: 10px 16px;
    color: var(--text-dark);
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    width: 130px;
    text-align: center;
    outline: none;
    transition: all 0.3s;
}
.player-setup input:focus {
    border-color: var(--pink-hot);
    box-shadow: 0 0 0 3px var(--shadow-pink);
}
.player-setup input::placeholder {
    color: var(--pink-light);
    font-weight: 400;
}
.vs {
    color: var(--coral);
    font-weight: 800;
    font-size: 1rem;
}

/* Buttons */
.btn {
    font-family: inherit;
    font-size: 1rem;
    font-weight: 700;
    padding: 14px 36px;
    border-radius: 30px;
    border: none;
    cursor: pointer;
    transition: all 0.25s;
    letter-spacing: 0.03em;
    min-width: 200px;
    text-transform: uppercase;
}
.btn-primary {
    background: linear-gradient(135deg, var(--pink-hot), var(--coral));
    color: white;
    box-shadow: 0 4px 15px var(--shadow-pink), 0 2px 4px rgba(0,0,0,0.1);
}
.btn-primary:hover, .btn-primary:active {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 25px var(--shadow-pink);
}
.btn-ghost {
    background: white;
    color: var(--pink-hot);
    border: 2px solid var(--pink-pastel);
    margin-top: 10px;
}
.btn-ghost:hover { border-color: var(--pink-hot); }

.btn-glow {
    animation: btnBounce 2s ease-in-out infinite;
}
@keyframes btnBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* Game Screen */
#screenGame {
    padding: 8px;
    justify-content: flex-start;
    gap: 0;
    background: transparent;
}

.game-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 580px;
    gap: 4px;
}

/* Player Bars */
.player-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: calc(var(--sq-size) * 8 + 4px);
    max-width: calc(var(--sq-size) * 8 + 4px);
    padding: 6px 12px;
    border-radius: 25px;
    background: white;
    border: 2px solid transparent;
    transition: all 0.3s;
    min-height: 38px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.player-bar.active {
    border-color: var(--pink-hot);
    box-shadow: 0 2px 15px var(--shadow-pink), 0 0 20px var(--shadow-pink);
    background: linear-gradient(135deg, white, #fff5f7);
    animation: activeBarPulse 1.5s ease-in-out infinite;
    transform: scale(1.03);
}
/* Black player bar — dark theme */
#playerBarBlack {
    background: #1a1a2e;
    border-color: #2a2a4e;
}
#playerBarBlack .player-name {
    color: #e0e0e0;
}
#playerBarBlack .captured-pieces {
    filter: brightness(1.2);
}
#playerBarBlack .score-diff {
    color: #aaa;
}
#playerBarBlack.active {
    background: linear-gradient(135deg, #1a1a2e, #2d1525);
    border-color: var(--coral);
    box-shadow: 0 2px 15px rgba(255,107,107,0.3), 0 0 20px rgba(255,107,107,0.2);
}
#playerBarBlack.active .player-name {
    color: var(--coral);
}
.player-bar.active .player-name::before {
    content: '▸ ';
    color: var(--pink-hot);
    animation: arrowBlink 1s ease-in-out infinite;
}
#playerBarBlack.active .player-name::before {
    color: var(--coral);
}
@keyframes arrowBlink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}
@keyframes activeBarPulse {
    0%, 100% { box-shadow: 0 2px 15px var(--shadow-pink), 0 0 10px var(--shadow-pink); }
    50% { box-shadow: 0 4px 25px var(--shadow-pink), 0 0 35px var(--shadow-pink); }
}
.player-name {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
    color: var(--text-dark);
}
.player-bar.active .player-name {
    color: var(--pink-hot);
}
.captured-pieces {
    display: flex;
    gap: 1px;
    font-size: 0.85rem;
    opacity: 0.8;
    flex-wrap: wrap;
    justify-content: flex-end;
    max-width: 60%;
}
.score-diff {
    font-size: 0.75rem;
    color: var(--text-mid);
    font-weight: 700;
    margin-left: 4px;
}

/* Turn Indicator */
.turn-indicator {
    font-size: clamp(0.85rem, 3vw, 1rem);
    color: var(--pink-hot);
    font-weight: 800;
    text-align: center;
    padding: 6px 14px;
    min-height: 30px;
    background: rgba(255,59,122,0.08);
    border-radius: 20px;
    letter-spacing: 0.01em;
}

/* Chess Board */
.board-container {
    position: relative;
    margin: 4px 0;
}

/* Giant decorative whip */
.board-whip {
    position: absolute;
    left: -48px;
    top: 50%;
    transform: translateY(-50%) rotate(-15deg);
    font-size: 2.8rem;
    z-index: 10;
    pointer-events: none;
    opacity: 0.7;
    transition: all 0.15s;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}
.board-whip.crack {
    animation: whipCrack 0.4s ease-out;
}
@keyframes whipCrack {
    0% { transform: translateY(-50%) rotate(-15deg) scale(1); }
    20% { transform: translateY(-50%) rotate(25deg) scale(1.3); opacity: 1; }
    40% { transform: translateY(-50%) rotate(-5deg) scale(1.1); }
    100% { transform: translateY(-50%) rotate(-15deg) scale(1); opacity: 0.7; }
}
@media (max-width: 420px) {
    .board-whip { left: -36px; font-size: 2rem; }
}
.board {
    display: grid;
    grid-template-columns: repeat(8, var(--sq-size));
    grid-template-rows: repeat(8, var(--sq-size));
    border-radius: var(--board-radius);
    overflow: hidden;
    box-shadow: 0 8px 30px rgba(0,0,0,0.12), 0 2px 8px rgba(0,0,0,0.08);
    border: 3px solid var(--pink-pastel);
    touch-action: manipulation;
}

.square {
    width: var(--sq-size);
    height: var(--sq-size);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    cursor: pointer;
    transition: background-color 0.15s;
    line-height: 1;
}
.square--light { background: var(--board-light); }
.square--dark { background: var(--board-dark); }

.square:active {
    filter: brightness(1.1);
}

/* Square States */
.square.selected {
    background: rgba(255, 215, 0, 0.5) !important;
    box-shadow: inset 0 0 15px rgba(255, 215, 0, 0.4);
}
.square.legal-move::after {
    content: '';
    position: absolute;
    width: 30%;
    height: 30%;
    border-radius: 50%;
    background: rgba(255, 59, 122, 0.4);
    pointer-events: none;
    animation: dotPop 0.2s ease-out;
}
@keyframes dotPop {
    from { transform: scale(0); }
    to { transform: scale(1); }
}
.square.legal-capture::after {
    content: '';
    position: absolute;
    width: 85%;
    height: 85%;
    border-radius: 50%;
    border: 3px solid rgba(255, 59, 122, 0.5);
    background: transparent;
    pointer-events: none;
}
.square.last-move {
    background: rgba(255, 215, 0, 0.2) !important;
}
.square.in-check {
    animation: checkPulse 0.8s ease-in-out infinite;
}
@keyframes checkPulse {
    0%, 100% { background: rgba(211, 47, 47, 0.25); box-shadow: inset 0 0 15px rgba(211,47,47,0.3); }
    50% { background: rgba(211, 47, 47, 0.4); box-shadow: inset 0 0 25px rgba(211,47,47,0.4); }
}

/* Pieces — Naughty Emoji Characters */
.piece {
    position: relative;
    z-index: 2;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}
.piece-char {
    font-size: calc(var(--sq-size) * 0.7);
    line-height: 1;
    position: relative;
    z-index: 2;
}

/* Angel wings (white pieces) — feathery white wings */
.piece--white::before,
.piece--white::after {
    content: '🪽';
    position: absolute;
    font-size: calc(var(--sq-size) * 0.3);
    z-index: 1;
    top: 2px;
    opacity: 0.85;
    pointer-events: none;
}
.piece--white::before {
    left: 0;
    transform: scaleX(-1);
}
.piece--white::after {
    right: 0;
    transform: scaleX(1);
}

/* Demon wings (black pieces) — dark tinted wing emoji */
.piece--black::before,
.piece--black::after {
    content: '🪽';
    position: absolute;
    font-size: calc(var(--sq-size) * 0.3);
    z-index: 1;
    top: 2px;
    opacity: 0.9;
    pointer-events: none;
    filter: brightness(0.1) saturate(2);
}
.piece--black::before {
    left: 0;
    transform: scaleX(-1);
}
.piece--black::after {
    right: 0;
    transform: scaleX(1);
}


/* Flirty shimmy when piece lands */
.piece-landed .piece {
    animation: flirtyShimmy 0.5s ease-out;
}
@keyframes flirtyShimmy {
    0% { transform: scale(0.6) rotate(-10deg); }
    40% { transform: scale(1.15) rotate(5deg); }
    70% { transform: scale(0.95) rotate(-3deg); }
    100% { transform: scale(1) rotate(0deg); }
}

/* Strip tease — garment tossed on capture */
.strip-tease {
    position: absolute;
    z-index: 30;
    font-size: calc(var(--sq-size) * 0.5);
    pointer-events: none;
    animation: stripToss 1s ease-out forwards;
}
@keyframes stripToss {
    0% { transform: translate(0, 0) rotate(0deg) scale(1); opacity: 1; }
    30% { transform: translate(10px, -30px) rotate(60deg) scale(1.2); opacity: 1; }
    100% { transform: translate(25px, -60px) rotate(180deg) scale(0.4); opacity: 0; }
}

/* Selected piece sexy bounce */
.square.selected .piece {
    animation: sexyBounce 0.6s ease-in-out infinite;
}
@keyframes sexyBounce {
    0%, 100% { transform: scale(1) rotate(0deg); }
    25% { transform: scale(1.1) rotate(-5deg); }
    75% { transform: scale(1.08) rotate(5deg); }
}

/* Coordinates */
.coord {
    position: absolute;
    font-size: 0.5rem;
    color: rgba(61, 26, 46, 0.35);
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    pointer-events: none;
    z-index: 1;
}
.coord--file { bottom: 1px; right: 3px; }
.coord--rank { top: 1px; left: 3px; }
.square--dark .coord { color: rgba(255,255,255,0.35); }

/* Promotion Modal */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(255,240,243,0.9);
    backdrop-filter: blur(8px);
    z-index: 100;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}
.modal-overlay.active { display: flex; }
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.promotion-modal {
    background: white;
    border: 3px solid var(--pink-hot);
    border-radius: 24px;
    padding: 28px;
    text-align: center;
    box-shadow: 0 10px 40px var(--shadow-pink);
}
.promotion-modal h3 {
    font-family: 'Pacifico', cursive;
    font-size: 1.3rem;
    font-weight: 400;
    color: var(--pink-hot);
    margin-bottom: 4px;
}
.promotion-modal .promo-subtitle {
    font-size: 0.85rem;
    color: var(--text-mid);
    margin-bottom: 16px;
}
.promotion-choices {
    display: flex;
    gap: 12px;
    justify-content: center;
}
.promo-choice {
    width: 64px;
    height: 64px;
    font-size: 2.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    background: var(--bg-warm);
    border: 2px solid var(--pink-pastel);
    cursor: pointer;
    transition: all 0.2s;
    touch-action: manipulation;
}
.promo-choice:hover, .promo-choice:active {
    border-color: var(--pink-hot);
    background: var(--pink-pastel);
    transform: scale(1.12) rotate(-3deg);
}

/* Menu Button */
.menu-btn {
    position: fixed;
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: white;
    border: 2px solid var(--pink-pastel);
    color: var(--pink-hot);
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.menu-btn:hover { background: var(--bg-warm); transform: rotate(90deg); }

/* Game Over Screen */
#screenGameOver {
    background: transparent;
}
.result-deco {
    font-size: 4rem;
    margin-bottom: 12px;
    animation: pieceWiggle 2s ease-in-out infinite;
}
.result-title {
    font-family: 'Pacifico', cursive;
    font-size: clamp(1.8rem, 7vw, 3rem);
    font-weight: 400;
    color: var(--pink-hot);
    margin-bottom: 8px;
    text-align: center;
    text-shadow: 2px 2px 0 var(--pink-pastel);
}
.result-subtitle {
    font-size: clamp(0.9rem, 3vw, 1.1rem);
    color: var(--text-mid);
    margin-bottom: 24px;
    text-align: center;
    max-width: 320px;
    line-height: 1.6;
    font-weight: 600;
}
.game-stats {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 24px;
    font-size: 0.85rem;
    color: var(--text-mid);
    text-align: center;
    background: white;
    padding: 16px 24px;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.game-stats span {
    color: var(--pink-hot);
    font-weight: 700;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: white;
    border: 2px solid var(--pink-hot);
    border-radius: 25px;
    padding: 10px 22px;
    color: var(--text-dark);
    font-family: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 200;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    text-align: center;
    max-width: 90vw;
    box-shadow: 0 4px 20px var(--shadow-pink);
    pointer-events: none;
}
.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Confetti container */
.confetti-container {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 300;
    overflow: hidden;
}
.confetti {
    position: absolute;
    top: -10px;
    animation: confettiFall 3s ease-in forwards;
}
@keyframes confettiFall {
    0% { transform: translateY(0) rotate(0deg) scale(1); opacity: 1; }
    50% { opacity: 1; }
    100% { transform: translateY(100vh) rotate(720deg) scale(0.5); opacity: 0; }
}

/* Heart burst on capture */
.heart-burst {
    position: absolute;
    pointer-events: none;
    z-index: 20;
    font-size: 1rem;
    animation: heartPop 0.8s ease-out forwards;
}
@keyframes heartPop {
    0% { transform: scale(0) translateY(0); opacity: 1; }
    50% { transform: scale(1.2) translateY(-20px); opacity: 0.8; }
    100% { transform: scale(0.5) translateY(-40px); opacity: 0; }
}

/* Board shake on capture */
.board-shake {
    animation: boardShake 0.4s ease-in-out;
}
@keyframes boardShake {
    0%, 100% { transform: translateX(0); }
    15% { transform: translateX(-4px) rotate(-0.5deg); }
    30% { transform: translateX(4px) rotate(0.5deg); }
    45% { transform: translateX(-3px); }
    60% { transform: translateX(3px); }
    75% { transform: translateX(-1px); }
}

/* Move sparkle trail */
.move-sparkle {
    position: absolute;
    pointer-events: none;
    z-index: 25;
    font-size: 0.9rem;
    animation: sparkleTrail 0.7s ease-out forwards;
}
@keyframes sparkleTrail {
    0% { transform: scale(0) rotate(0deg); opacity: 1; }
    40% { transform: scale(1.3) rotate(180deg); opacity: 0.8; }
    100% { transform: scale(0) rotate(360deg) translateY(-15px); opacity: 0; }
}

/* Idle wiggle on waiting pieces */
.idle-wiggle .piece {
    animation: idleWiggle 0.6s ease-in-out;
}
@keyframes idleWiggle {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-4deg); }
    75% { transform: rotate(4deg); }
}

/* Ambient floating emojis during game */
.game-float-emoji {
    position: fixed;
    pointer-events: none;
    z-index: 2;
    opacity: 0.4;
    animation: gameFloat 10s linear forwards;
}
@keyframes gameFloat {
    0% { transform: translateY(105vh) rotate(0deg) scale(0.8); opacity: 0; }
    10% { opacity: 0.4; }
    50% { transform: translateY(50vh) rotate(15deg) scale(1.1); opacity: 0.45; }
    90% { opacity: 0.3; }
    100% { transform: translateY(-10vh) rotate(30deg) scale(0.9); opacity: 0; }
}

/* Red Light secret theme */
.red-light {
    --bg: #1a0a10;
    --bg-warm: #2a0f18;
    --board-light: #3d1520;
    --board-dark: #8b1a30;
    --text-dark: #ffb5b5;
    --text-mid: #ff8a8a;
    --text-light: rgba(255,181,181,0.4);
}
.red-light .board { border-color: #8b1a30; }
.red-light .player-bar { background: #2a0f18; }
.red-light .player-bar.active { background: #3a1520; }
.red-light .btn-primary { background: linear-gradient(135deg, #d32f2f, #8b1a30); }

/* Neon secret theme (Konami) */
.neon-mode {
    --bg: #0a0a2e;
    --bg-warm: #0f0f3a;
    --board-light: #1a1a4e;
    --board-dark: #0d0d30;
    --text-dark: #00ffff;
    --text-mid: #ff00ff;
    --pink-hot: #ff00ff;
    --pink-pastel: rgba(255,0,255,0.2);
}
.neon-mode .board { border-color: rgba(0,255,255,0.4); box-shadow: 0 0 30px rgba(0,255,255,0.15); }
.neon-mode .piece--white { filter: drop-shadow(0 0 8px rgba(0,255,255,0.6)); }
.neon-mode .piece--black { filter: drop-shadow(0 0 8px rgba(255,0,255,0.6)); }
.neon-mode .player-bar { background: #151545; }

/* Heartbeat animation for King-Queen proximity */
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    15% { transform: scale(1.15); }
    30% { transform: scale(1); }
    45% { transform: scale(1.1); }
    60% { transform: scale(1); }
}
.square.heartbeat .piece {
    animation: heartbeat 1.2s ease-in-out;
}

/* Mobile responsive */
@media (max-width: 420px) {
    :root { --sq-size: 11.25vw; }
    .player-bar { padding: 4px 8px; min-height: 34px; }
    .player-name { font-size: 0.78rem; max-width: 80px; }
    .captured-pieces { font-size: 0.75rem; }
    .turn-indicator { font-size: 0.75rem; padding: 2px 0; }
    #screenGame { padding: 4px; }
}

@media (min-width: 421px) and (max-width: 599px) {
    :root { --sq-size: 11vw; }
}

@media (min-width: 600px) {
    :root { --sq-size: 64px; }
    .board { box-shadow: 0 12px 40px rgba(0,0,0,0.12); }
}

@media (min-height: 800px) {
    #screenGame { justify-content: center; }
}

@media (max-height: 400px) and (orientation: landscape) {
    :root { --sq-size: min(9vh, 44px); }
    .player-bar { min-height: 28px; padding: 2px 6px; }
    .turn-indicator { min-height: 20px; font-size: 0.7rem; }
}

html { overscroll-behavior: none; }
body { overscroll-behavior: none; }
