* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%); min-height: 100vh; }
.page-wrapper { display: grid; grid-template-columns: 160px 1fr 160px; gap: 20px; min-height: 100vh; max-width: 1400px; margin: 0 auto; padding: 20px; }
.sidebar { min-height: 100vh; }
.sidebar-left, .sidebar-right { display: flex; align-items: flex-start; padding-top: 80px; }
.sticky-ad { position: sticky; top: 20px; width: 160px; min-height: 600px; }
.main-content { display: flex; justify-content: center; align-items: flex-start; padding: 20px 0; }
@media (max-width: 1024px) { .page-wrapper { grid-template-columns: 1fr; } .sidebar { display: none; } }
.container { max-width: 560px; width: 100%; }
.header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.back-button { text-decoration: none; color: #fff; background: rgba(255,255,255,0.15); padding: 6px 14px; border-radius: 20px; font-size: 1em; }
.back-button:hover { background: rgba(255,255,255,0.25); }
.title { color: #fff; font-size: 1.6em; font-weight: 800; }
.stats-bar { display: flex; justify-content: space-between; background: rgba(255,255,255,0.08); border-radius: 14px; padding: 10px 16px; color: #a29bfe; font-size: 0.95em; margin-bottom: 12px; }
.stats-bar strong { color: #fff; }
.game-area {
    background: rgba(0,0,0,0.4); border-radius: 16px; height: 340px; position: relative;
    overflow: hidden; margin-bottom: 0; border: 2px solid rgba(162,155,254,0.3);
}
.start-overlay { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff; text-align: center; padding: 20px; }
.start-emoji { font-size: 3em; margin-bottom: 12px; }
.start-overlay h2 { font-size: 1.8em; margin-bottom: 8px; }
.start-overlay p { color: #a29bfe; margin-bottom: 20px; }
.start-btn { background: linear-gradient(135deg, #6c5ce7, #a29bfe); color: #fff; border: none; border-radius: 12px; padding: 14px 36px; font-size: 1.1em; font-weight: 700; cursor: pointer; }
.start-btn:hover { opacity: 0.85; }
.falling-word {
    position: absolute; color: #a29bfe; font-size: 1.1em; font-weight: 700;
    padding: 6px 14px; background: rgba(108,92,231,0.2); border-radius: 20px;
    border: 1px solid rgba(162,155,254,0.4); white-space: nowrap;
    transition: top 0.1s linear; user-select: none;
}
.falling-word.matched { color: #00b894; border-color: #00b894; background: rgba(0,184,148,0.15); }
.input-row { margin-top: 0; }
.word-input { width: 100%; padding: 14px 20px; font-size: 1.2em; font-weight: 600; border-radius: 0 0 14px 14px; border: 2px solid rgba(162,155,254,0.4); background: rgba(255,255,255,0.07); color: #fff; outline: none; caret-color: #a29bfe; }
.word-input::placeholder { color: rgba(255,255,255,0.3); }
.word-input:focus { border-color: #a29bfe; background: rgba(255,255,255,0.1); }
.word-input:disabled { opacity: 0.4; }
.ground-line { height: 3px; background: linear-gradient(90deg, transparent, #d63031, transparent); margin-bottom: 16px; }
.game-over { background: rgba(255,255,255,0.05); border: 2px solid rgba(162,155,254,0.3); border-radius: 20px; padding: 36px 24px; text-align: center; }
.game-over h2 { font-size: 2em; color: #fff; margin-bottom: 10px; }
.game-over p { color: #a29bfe; font-size: 1.05em; margin-bottom: 8px; }
.share-btn, .play-again-btn { border: none; border-radius: 12px; padding: 12px 24px; font-size: 1em; font-weight: 700; cursor: pointer; margin: 6px; }
.share-btn { background: linear-gradient(135deg, #6c5ce7, #a29bfe); color: #fff; }
.play-again-btn { background: rgba(255,255,255,0.1); color: #fff; border: 1px solid rgba(255,255,255,0.2); }
.hidden { display: none; }
