:root {
    --ink: #13213c;
    --muted: #68758d;
    --line: #e3e9f2;
    --surface: #ffffff;
    --soft: #f3f6fb;
    --navy: #172554;
    --blue: #3157bd;
    --violet: #7654df;
    --orange: #f59e0b;
    --green: #10b981;
    --danger: #e04f5f;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: #eef2f8; }
body {
    min-height: 100%; margin: 0; color: var(--ink); font-family: Inter, system-ui, -apple-system, sans-serif;
    background: radial-gradient(circle at 8% 2%, rgba(49,87,189,.12), transparent 32rem), #eef2f8;
    -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { touch-action: manipulation; }
[hidden] { display: none !important; }

.games-shell { min-height: 100vh; }
.games-header {
    position: sticky; top: 0; z-index: 50; height: 68px; padding: 0 max(18px, env(safe-area-inset-left));
    display: flex; align-items: center; justify-content: space-between; gap: 18px;
    background: rgba(255,255,255,.92); border-bottom: 1px solid rgba(210,220,234,.8); backdrop-filter: blur(18px);
}
.games-back { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 14px; }
.games-back i { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; background: var(--soft); color: var(--blue); }
.games-restaurant { display: flex; align-items: center; gap: 10px; min-width: 0; font-size: 14px; }
.games-restaurant strong { max-width: 260px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.games-restaurant-logo { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; overflow: hidden; border-radius: 12px; color: #fff; background: linear-gradient(145deg,var(--blue),var(--violet)); font-weight: 800; }
.games-restaurant-logo img { width: 100%; height: 100%; object-fit: cover; }

.games-main { width: min(1080px, calc(100% - 32px)); margin: 0 auto; padding: 34px 0 60px; }
.games-hero { position: relative; overflow: hidden; padding: 34px 36px; border-radius: 28px; color: #fff; background: linear-gradient(125deg,#12234d 0%,#284fae 58%,#7555dc 100%); box-shadow: 0 22px 55px rgba(23,37,84,.18); }
.games-hero:after { content: "8"; position: absolute; right: 28px; top: -54px; font-size: 220px; line-height: 1; font-weight: 800; color: rgba(255,255,255,.07); }
.games-eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 800; letter-spacing: .14em; color: #fcd34d; }
.games-hero h1 { position: relative; z-index: 1; margin: 12px 0 8px; font-size: clamp(27px, 5vw, 44px); line-height: 1.08; letter-spacing: -.04em; }
.games-hero p { position: relative; z-index: 1; max-width: 620px; margin: 0; color: rgba(255,255,255,.8); font-size: 16px; line-height: 1.65; }
.games-hero small { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 7px; margin-top: 17px; padding: 8px 11px; border-radius: 999px; background: rgba(255,255,255,.12); color: rgba(255,255,255,.88); }

.game-tabs { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin: 22px 0; }
.game-tab { display: flex; align-items: center; gap: 13px; min-width: 0; padding: 15px; text-align: left; cursor: pointer; border: 1px solid var(--line); border-radius: 18px; background: rgba(255,255,255,.82); color: var(--ink); transition: .2s ease; }
.game-tab:hover { transform: translateY(-2px); border-color: #b9c7e2; }
.game-tab.is-active { background: #fff; border-color: var(--blue); box-shadow: 0 12px 30px rgba(49,87,189,.12); }
.game-tab-icon { flex: 0 0 48px; height: 48px; display: grid; place-items: center; border-radius: 14px; color: #fff; background: linear-gradient(145deg,var(--blue),var(--violet)); font-size: 23px; font-weight: 800; }
.game-tab span:last-child { min-width: 0; }
.game-tab strong, .game-tab small { display: block; }
.game-tab strong { margin-bottom: 4px; font-size: 15px; }
.game-tab small { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; color: var(--muted); }

.game-panel { display: none; padding: 26px; border: 1px solid var(--line); border-radius: 26px; background: rgba(255,255,255,.96); box-shadow: 0 18px 48px rgba(26,45,82,.09); }
.game-panel.is-active { display: block; animation: panel-in .25s ease; }
@keyframes panel-in { from { opacity: 0; transform: translateY(7px); } }

.game-intro-copy { display: flex; align-items: center; gap: 17px; margin-bottom: 23px; }
.game-intro-copy h2, .food-game-head h2 { margin: 0 0 6px; font-size: 25px; letter-spacing: -.035em; }
.game-intro-copy p, .food-game-head p { margin: 0; color: var(--muted); line-height: 1.55; }
.game-number-mark { width: 65px; height: 65px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 20px; color: #fff; background: linear-gradient(145deg,#23469d,var(--violet)); font-size: 34px; font-weight: 800; box-shadow: 0 12px 25px rgba(49,87,189,.22); }
.game-field { display: block; max-width: 480px; margin: 0 auto 17px; }
.game-field span { display: block; margin: 0 0 7px; color: #41506a; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.game-field input, .word-form input { width: 100%; height: 49px; border: 1px solid #cfd8e6; border-radius: 13px; outline: 0; padding: 0 15px; color: var(--ink); background: #fff; transition: .2s; }
.game-field input:focus, .word-form input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(49,87,189,.1); }
.sekizli-modes { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 680px; margin: auto; }
.mode-card { min-height: 82px; display: flex; align-items: center; gap: 13px; padding: 16px; border: 1px solid var(--line); border-radius: 17px; cursor: pointer; text-align: left; background: var(--soft); color: var(--ink); }
.mode-card:hover { border-color: #aebfe0; }
.mode-card i { width: 42px; height: 42px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 13px; background: #fff; color: var(--blue); font-size: 18px; }
.mode-card strong, .mode-card small { display: block; }
.mode-card strong { margin-bottom: 4px; }
.mode-card small { color: var(--muted); line-height: 1.35; }
.mode-card-primary { color: #fff; border-color: transparent; background: linear-gradient(135deg,var(--blue),var(--violet)); }
.mode-card-primary i { color: var(--violet); }
.mode-card-primary small { color: rgba(255,255,255,.72); }
.game-message { min-height: 21px; margin: 13px 0 0; text-align: center; color: var(--danger); font-size: 13px; font-weight: 700; }
.game-message.success { color: var(--green); }

.game-stats { display: grid; grid-template-columns: repeat(3,1fr); overflow: hidden; max-width: 560px; margin: 0 auto 9px; border: 1px solid var(--line); border-radius: 16px; background: var(--soft); }
.game-stats > div { padding: 11px 15px; text-align: center; border-right: 1px solid var(--line); }
.game-stats > div:last-child { border: 0; }
.game-stats small, .game-stats strong { display: block; }
.game-stats small { color: var(--muted); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.game-stats strong { margin-top: 2px; font-size: 22px; }
.sekizli-mode-label { min-height: 20px; margin-bottom: 9px; text-align: center; color: var(--muted); font-size: 12px; font-weight: 700; }
.letter-wheel { display: grid; grid-template-columns: repeat(8, minmax(38px,55px)); justify-content: center; gap: 8px; margin: 17px auto; }
.letter-tile { aspect-ratio: 1; display: grid; place-items: center; padding: 0; border: 0; border-radius: 15px; cursor: pointer; color: #fff; background: linear-gradient(150deg,#173473,#365fc6); box-shadow: 0 7px 0 #10285e,0 10px 18px rgba(22,48,107,.2); font-size: 21px; font-weight: 800; text-transform: uppercase; }
.letter-tile:active { transform: translateY(4px); box-shadow: 0 3px 0 #10285e; }
.word-form { display: flex; gap: 9px; max-width: 520px; margin: 20px auto 10px; }
.word-form input { text-align: center; text-transform: uppercase; font-size: 17px; font-weight: 700; letter-spacing: .08em; }
.word-form button, .result-card button, #foodStart { min-width: 105px; border: 0; border-radius: 13px; padding: 0 18px; cursor: pointer; color: #fff; background: linear-gradient(135deg,var(--blue),var(--violet)); font-weight: 800; box-shadow: 0 8px 20px rgba(49,87,189,.2); }
.word-tools { display: flex; justify-content: center; gap: 8px; }
.word-tools button { padding: 7px 11px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; color: #506078; background: #fff; font-size: 12px; font-weight: 700; }
.sekizli-columns { display: grid; grid-template-columns: 1fr; gap: 14px; margin-top: 18px; }
.found-panel, .leader-panel, .recipe-progress-card { padding: 17px; border: 1px solid var(--line); border-radius: 17px; background: var(--soft); }
.panel-title { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 13px; }
.panel-title h3 { margin: 0; font-size: 14px; }
.panel-title span, .panel-title i { color: var(--blue); font-size: 12px; font-weight: 800; }
.found-words { min-height: 55px; display: flex; flex-wrap: wrap; align-content: flex-start; gap: 7px; }
.found-word { padding: 5px 8px; border-radius: 8px; background: #fff; color: #23395f; font-size: 12px; font-weight: 800; box-shadow: 0 2px 6px rgba(20,37,71,.06); }
.leader-list { list-style: none; margin: 0; padding: 0; }
.leader-list li { display: grid; grid-template-columns: 28px 1fr auto; gap: 7px; align-items: center; padding: 8px 0; border-bottom: 1px solid #dfe5ef; font-size: 12px; }
.leader-list li:last-child { border: 0; }
.leader-list .is-you { color: var(--blue); font-weight: 800; }
.leader-rank { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: #fff; font-weight: 800; }

.game-result { position: absolute; inset: 0; z-index: 20; display: grid; place-items: center; padding: 18px; background: rgba(13,27,54,.72); backdrop-filter: blur(7px); }
.sekizli-board { position: relative; min-height: 500px; }
.result-card { width: min(340px,100%); padding: 28px; border-radius: 23px; text-align: center; background: #fff; box-shadow: 0 24px 70px rgba(0,0,0,.2); }
.result-icon { font-size: 42px; }
.result-card h2 { margin: 9px 0 4px; }
.result-card p { color: var(--muted); }
.result-card p strong { color: var(--ink); font-size: 28px; }
.result-card button { min-height: 46px; margin-top: 6px; }

.sekizli-report { animation: panel-in .28s ease; }
.report-hero { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 23px; border-radius: 20px; color: #fff; background: linear-gradient(130deg,#142657,#3157bd 62%,#7654df); }
.report-hero h2 { margin: 8px 0 4px; font-size: 28px; letter-spacing: -.04em; }
.report-hero p { margin: 0; color: rgba(255,255,255,.72); }
.report-hero p strong { color: #fff; }
.next-round-box { flex: 0 0 170px; padding: 14px; border-radius: 15px; text-align: center; background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.18); }
.next-round-box small, .next-round-box strong, .next-round-box span { display: block; }
.next-round-box small { color: #fde68a; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.next-round-box strong { margin: 3px 0; font-size: 25px; }
.next-round-box span { color: rgba(255,255,255,.72); font-size: 10px; line-height: 1.4; }
.report-stats { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; margin: 13px 0; }
.report-stats > div { position: relative; padding: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: var(--soft); }
.report-stats i { position: absolute; right: 11px; top: 11px; color: #c5d1e7; font-size: 17px; }
.report-stats small, .report-stats strong { display: block; }
.report-stats small { color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.report-stats strong { margin-top: 4px; font-size: 23px; }
.report-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 13px; }
.report-actions button { min-height: 42px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; color: #526079; background: #fff; font-size: 12px; font-weight: 800; }
.report-actions .report-primary { color: #fff; border-color: transparent; background: linear-gradient(135deg,var(--blue),var(--violet)); }
.report-leaderboard, .word-analysis { margin-top: 13px; padding: 17px; border: 1px solid var(--line); border-radius: 17px; background: var(--soft); }
.report-leaderboard .panel-title > div small, .word-analysis-head small { display: block; margin-bottom: 3px; color: var(--blue); font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.report-leaderboard .panel-title > strong { color: var(--blue); font-size: 11px; }
.result-leader-list { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.result-leader-list li { grid-template-columns: 30px 1fr auto; padding: 9px 10px; border: 1px solid #dfe5ef; border-radius: 11px; background: #fff; }
.result-leader-list li:nth-child(1) .leader-rank { color: #805e00; background: #fff3bd; }
.result-leader-list li:nth-child(2) .leader-rank { color: #526079; background: #e8edf5; }
.result-leader-list li:nth-child(3) .leader-rank { color: #874c25; background: #ffe2ce; }
.word-analysis-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.word-analysis-head h3 { margin: 0; font-size: 15px; }
.word-analysis-tabs { display: flex; padding: 3px; border-radius: 10px; background: #e5eaf3; }
.word-analysis-tabs button { padding: 7px 10px; border: 0; border-radius: 8px; cursor: pointer; color: #647189; background: transparent; font-size: 10px; font-weight: 800; }
.word-analysis-tabs button.is-active { color: var(--blue); background: #fff; box-shadow: 0 2px 7px rgba(25,43,78,.09); }
.report-word-groups { display: grid; grid-template-columns: repeat(3,1fr); gap: 9px; margin-top: 14px; }
.report-word-group { padding: 11px; border: 1px solid #dfe5ef; border-radius: 12px; background: #fff; }
.report-word-group > strong { display: flex; justify-content: space-between; margin-bottom: 8px; color: #526079; font-size: 9px; text-transform: uppercase; letter-spacing: .06em; }
.report-word-group > strong span { color: var(--blue); }
.report-word-list { display: flex; flex-wrap: wrap; gap: 5px; max-height: 150px; overflow-y: auto; }
.report-word-list span { padding: 4px 6px; border-radius: 7px; color: #30415f; background: var(--soft); font-size: 9px; font-weight: 800; }
.report-word-list em { color: #929caf; font-size: 10px; }

.food-game-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.recipe-picker { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.recipe-picker button { padding: 9px 11px; border: 1px solid var(--line); border-radius: 11px; cursor: pointer; background: var(--soft); color: #526079; font-size: 12px; font-weight: 700; }
.recipe-picker button.is-active { color: #fff; border-color: var(--blue); background: var(--blue); }
.food-game-wrap { display: grid; grid-template-columns: minmax(0,1fr) 260px; gap: 15px; align-items: start; }
.food-stage { position: relative; overflow: hidden; min-height: 610px; border-radius: 21px; background: linear-gradient(#eaf6ff 0 70%,#ddc49c 70%); box-shadow: inset 0 0 0 1px rgba(33,62,110,.1); touch-action: none; user-select: none; }
#foodCanvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.food-hud { position: absolute; z-index: 5; top: 10px; left: 10px; right: 10px; display: grid; grid-template-columns: repeat(4,1fr); overflow: hidden; border: 1px solid rgba(255,255,255,.7); border-radius: 14px; background: rgba(255,255,255,.87); backdrop-filter: blur(9px); box-shadow: 0 8px 20px rgba(20,48,80,.09); pointer-events: none; }
.food-hud > div { padding: 8px 5px; text-align: center; border-right: 1px solid var(--line); }
.food-hud > div:last-child { border: 0; }
.food-hud small, .food-hud strong { display: block; }
.food-hud small { color: var(--muted); font-size: 9px; font-weight: 800; text-transform: uppercase; }
.food-hud strong { margin-top: 2px; font-size: 16px; }
.food-feedback { position: absolute; z-index: 7; top: 73px; left: 50%; opacity: 0; transform: translate(-50%,-8px); padding: 7px 12px; border-radius: 999px; color: #fff; background: var(--green); font-size: 12px; font-weight: 800; pointer-events: none; transition: .2s; }
.food-feedback.show { opacity: 1; transform: translate(-50%,0); }
.food-feedback.wrong { background: var(--danger); }
.food-ready { position: absolute; z-index: 10; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 28px; text-align: center; color: #fff; background: linear-gradient(145deg,rgba(19,33,60,.88),rgba(49,87,189,.82)); }
.food-ready-icon { font-size: 58px; filter: drop-shadow(0 8px 12px rgba(0,0,0,.18)); }
.food-ready h3 { margin: 13px 0 5px; font-size: 27px; }
.food-ready p { max-width: 330px; margin: 0; color: rgba(255,255,255,.8); line-height: 1.55; }
#foodStart { min-height: 48px; margin-top: 20px; padding: 0 24px; background: #fff; color: var(--blue); }
.recipe-progress-card { position: sticky; top: 84px; background: #fff; }
.recipe-sequence { display: flex; flex-direction: column; gap: 7px; }
.recipe-step { display: flex; align-items: center; gap: 9px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 11px; color: #65738b; background: var(--soft); font-size: 12px; font-weight: 700; }
.recipe-step .step-emoji { width: 27px; text-align: center; font-size: 19px; }
.recipe-step.is-current { color: var(--blue); border-color: #9db3e5; background: #edf3ff; box-shadow: 0 0 0 3px rgba(49,87,189,.07); }
.recipe-step.is-done { color: #087c60; border-color: #9ce0ce; background: #ecfbf6; }
.recipe-progress-card > p { margin: 14px 0 0; padding-top: 13px; border-top: 1px solid var(--line); color: var(--muted); font-size: 11px; line-height: 1.55; }

.snake-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.snake-head h2 { margin: 0 0 5px; font-size: 25px; letter-spacing: -.035em; }
.snake-head p { margin: 0; color: var(--muted); }
.solo-pill { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 8px 11px; border-radius: 999px; color: var(--blue); background: #edf3ff; font-size: 10px; font-weight: 800; }
.snake-layout { width: min(560px,100%); margin: auto; }
.snake-stage { position: relative; width: 100%; aspect-ratio: 1; overflow: hidden; border: 1px solid #cad6e9; border-radius: 21px; background: #102147; box-shadow: 0 18px 42px rgba(18,36,78,.2); touch-action: none; user-select: none; }
#snakeCanvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.snake-hud { display: grid; grid-template-columns: repeat(4,1fr); overflow: hidden; margin-bottom: 10px; border: 1px solid #20386a; border-radius: 13px; background: #102147; box-shadow: 0 8px 22px rgba(18,36,78,.13); }
.snake-hud > div { padding: 8px; text-align: center; border-right: 1px solid rgba(255,255,255,.1); }
.snake-hud > div:last-child { border: 0; }
.snake-hud small, .snake-hud strong { display: block; }
.snake-hud small { color: #9fb0d0; font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.snake-hud strong { color: #fff; font-size: 17px; }
.snake-hud > div:last-child strong { color: #ff8e9d; }
.snake-notice { position: absolute; z-index: 7; top: 14px; left: 50%; max-width: calc(100% - 30px); padding: 8px 13px; opacity: 0; transform: translate(-50%,-7px); border-radius: 999px; color: #fff; background: rgba(42,197,126,.94); box-shadow: 0 8px 22px rgba(10,25,55,.24); font-size: 11px; font-weight: 800; text-align: center; pointer-events: none; transition: opacity .2s ease,transform .2s ease; }
.snake-notice.show { opacity: 1; transform: translate(-50%,0); }
.snake-notice.danger { background: rgba(229,72,92,.95); }
.snake-ready { position: absolute; z-index: 9; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 28px; text-align: center; color: #fff; background: linear-gradient(145deg,rgba(10,25,57,.92),rgba(49,87,189,.86)); }
.snake-ready > span { font-size: 58px; }
.snake-ready h3 { margin: 10px 0 4px; font-size: 27px; }
.snake-ready p { max-width: 330px; margin: 0; color: rgba(255,255,255,.76); line-height: 1.55; }
.snake-ready button { min-height: 47px; margin-top: 18px; padding: 0 22px; border: 0; border-radius: 13px; cursor: pointer; color: var(--blue); background: #fff; font-weight: 800; }
.snake-controls { display: grid; grid-template-columns: repeat(3,72px); grid-template-areas: '. up .' 'left down right'; justify-content: center; gap: 9px; margin-top: 14px; touch-action: manipulation; user-select: none; }
.snake-controls button { display: grid; width: 72px; height: 62px; place-items: center; border: 1px solid #b9c9e2; border-radius: 18px; cursor: pointer; color: #fff; background: linear-gradient(145deg,#5378db,#244cae); box-shadow: 0 9px 20px rgba(49,87,189,.25),inset 0 1px 0 rgba(255,255,255,.28); font-size: 24px; transition: transform .12s ease,box-shadow .12s ease; -webkit-tap-highlight-color: transparent; }
.snake-controls button:active { transform: translateY(2px) scale(.97); box-shadow: 0 4px 10px rgba(49,87,189,.24),inset 0 1px 0 rgba(255,255,255,.25); }
.snake-controls [data-snake-direction="up"] { grid-area: up; }
.snake-controls [data-snake-direction="left"] { grid-area: left; }
.snake-controls [data-snake-direction="down"] { grid-area: down; }
.snake-controls [data-snake-direction="right"] { grid-area: right; }

@media (max-width: 760px) {
    .games-header { height: 60px; padding-right: max(12px,env(safe-area-inset-right)); padding-left: max(12px,env(safe-area-inset-left)); }
    .games-back span { display: none; }
    .games-back i { width: 36px; height: 36px; }
    .games-restaurant strong { max-width: 62vw; }
    .games-main { width: min(100% - 20px,680px); padding: 12px 0 calc(30px + env(safe-area-inset-bottom)); }
    .games-hero { padding: 24px 21px; border-radius: 21px; }
    .games-hero:after { right: -12px; font-size: 170px; }
    .games-hero h1 { max-width: 270px; }
    .games-hero p { font-size: 14px; }
    .games-hero small { align-items: flex-start; border-radius: 12px; line-height: 1.4; }
    .game-tabs { gap: 8px; margin: 12px 0; }
    .game-tab { gap: 8px; padding: 10px; border-radius: 15px; }
    .game-tab-icon { flex-basis: 39px; height: 39px; border-radius: 12px; font-size: 19px; }
    .game-tab strong { margin: 0; font-size: 12px; }
    .game-tab small { display: none; }
    .game-panel { padding: 17px 13px; border-radius: 21px; }
    .game-intro-copy { align-items: flex-start; gap: 11px; margin-bottom: 18px; }
    .game-number-mark { width: 52px; height: 52px; border-radius: 16px; font-size: 27px; }
    .game-intro-copy h2, .food-game-head h2 { font-size: 21px; }
    .game-intro-copy p, .food-game-head p { font-size: 13px; }
    .sekizli-modes { grid-template-columns: 1fr; }
    .mode-card { min-height: 70px; padding: 12px; }
    .letter-wheel { grid-template-columns: repeat(4,52px); gap: 9px; }
    .letter-tile { border-radius: 14px; font-size: 20px; }
    .word-form { gap: 7px; }
    .word-form input { min-width: 0; padding: 0 10px; }
    .word-form button { min-width: 78px; padding: 0 12px; }
    .sekizli-columns { grid-template-columns: 1fr; }
    .report-hero { display: block; padding: 18px; }
    .report-hero h2 { font-size: 23px; }
    .next-round-box { margin-top: 13px; }
    .report-stats { grid-template-columns: 1fr 1fr; }
    .result-leader-list { grid-template-columns: 1fr; }
    .word-analysis-head { align-items: flex-start; }
    .word-analysis-tabs { flex: 0 0 auto; }
    .word-analysis-tabs button { max-width: 105px; }
    .report-word-groups { grid-template-columns: 1fr 1fr; }
    .game-stats strong { font-size: 19px; }
    .food-game-head { display: block; }
    .recipe-picker { display: grid; grid-template-columns: repeat(2,1fr); margin-top: 13px; }
    .recipe-picker button { padding: 8px 4px; }
    .recipe-picker button span { display: block; margin-top: 3px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
    .food-game-wrap { display: flex; flex-direction: column; }
    .food-stage { width: 100%; min-height: 0; height: min(67vh,590px); }
    .recipe-progress-card { position: static; width: 100%; order: -1; padding: 12px; }
    .recipe-progress-card .panel-title { margin-bottom: 8px; }
    .recipe-sequence { display: grid; grid-template-columns: repeat(var(--recipe-steps,6),minmax(0,1fr)); gap: 5px; overflow: visible; padding: 3px 1px 5px; }
    .recipe-step { min-width: 0; justify-content: center; padding: 7px 2px; opacity: .3; filter: grayscale(.3); }
    .recipe-step .step-emoji { width: auto; font-size: clamp(18px,5.7vw,23px); }
    .recipe-step .step-label { display: none; }
    .recipe-step.is-current { opacity: 1; filter: none; transform: scale(1.08); box-shadow: 0 0 0 3px rgba(49,87,189,.1); }
    .recipe-step.is-done { opacity: .25; filter: grayscale(.45); }
    .recipe-progress-card > p { display: none; }
    .snake-head { display: block; }
    .solo-pill { margin-top: 10px; }
    .snake-stage { border-radius: 17px; }
    .snake-hud > div { padding: 7px 4px; }
    .snake-hud strong { font-size: 15px; }
    .snake-controls { grid-template-columns: repeat(3,76px); gap: 10px; }
    .snake-controls button { width: 76px; height: 64px; font-size: 25px; }
}

@media (max-width: 380px) {
    .games-main { width: calc(100% - 12px); }
    .game-panel { padding: 14px 9px; }
    .letter-wheel { grid-template-columns: repeat(4,47px); }
    .food-stage { height: 63vh; }
    .game-tab { padding: 8px 5px; }
    .game-tab-icon { flex-basis: 34px; height: 34px; }
    .report-word-groups { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    *, *:before, *:after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

[dir="rtl"] .game-tab,
[dir="rtl"] .mode-card { text-align: right; }
[dir="rtl"] .games-back i { transform: rotate(180deg); }
