*{box-sizing:border-box}body{margin:0;background:#f7f4ee;color:#102b53;font:16px Manrope,"Segoe UI",sans-serif}main{width:min(1100px,calc(100% - 32px));margin:36px auto 80px}.back{color:#425b7b;text-decoration:none}.back:hover{text-decoration:underline}.eyebrow,.label{font-size:11px;letter-spacing:.13em;font-weight:800;color:#697c94;margin-top:40px}h1{font-size:clamp(36px,6vw,64px);margin:8px 0}.intro{color:#62718a}.layout{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:24px;margin-top:32px}.game,.panel,details{background:#fff;border:1px solid #e2e7ed;border-radius:20px;box-shadow:0 10px 35px #102b530d}.game{padding:clamp(14px,3vw,36px)}.board{position:relative;aspect-ratio:1;background:#edf2f7;border-radius:16px}.board svg{position:absolute;inset:0;width:100%;height:100%}.cell{position:absolute;width:10%;height:10%;transform:translate(-50%,-50%);border:1px solid #d4e0ec;border-radius:50%;background:#fff;color:#102b53;cursor:pointer;font-size:clamp(16px,3.5vw,30px);display:grid;place-items:center;padding:0}.cell:hover{border-color:#8ba6c2;background:#e3edf8}.cell:focus-visible,.action:focus-visible,summary:focus-visible,.back:focus-visible{outline:3px solid #477fb7;outline-offset:3px}.cell.selected{background:#d6e8fa;border-color:#386da1}.cell.target{box-shadow:0 0 0 5px #8db9df}.cell:disabled{cursor:default}.panel{padding:24px}.panel .label{margin:0}h2{margin:14px 0;font-size:25px}aside p{line-height:1.6;color:#536680}.count{border-top:1px solid #edf0f4;padding-top:16px}.action{border:0;border-radius:999px;padding:13px 20px;background:#173b65;color:white;font:inherit;font-weight:700;cursor:pointer}.action:hover{background:#285580}details{margin-top:16px;padding:20px}summary{cursor:pointer;font-weight:700}.note{font-size:12px}@media(max-width:700px){.layout{grid-template-columns:1fr}main{margin-top:24px}.cell{font-size:clamp(16px,6vw,28px)}}

label{display:block;font-weight:700;margin:18px 0 8px}select{width:100%;padding:10px;border:1px solid #cbd7e3;border-radius:9px;color:#102b53;background:#fff;font:inherit}select:focus-visible,input:focus-visible{outline:3px solid #477fb7;outline-offset:3px}.sound{font-weight:400;font-size:14px}

.cell img{display:block;width:100%;height:100%;pointer-events:none}.cell:has(img){background:transparent;border-color:transparent}.cell.selected:has(img){border-color:#386da1;background:#d6e8fa}.cell:disabled{opacity:1}summary{list-style:none;display:flex;align-items:center;justify-content:space-between;gap:12px}summary::-webkit-details-marker{display:none}summary:after{content:"";width:30px;height:30px;flex:none;border:1px solid #d7e1eb;border-radius:50%;background:#f5f8fb url("data:image/svg+xml,%3Csvg xmlns=%27http://www.w3.org/2000/svg%27 viewBox=%270 0 24 24%27%3E%3Cpath d=%27m7 10 5 5 5-5%27 fill=%27none%27 stroke=%27%23102b53%27 stroke-width=%271.5%27/%3E%3C/svg%3E") center/18px no-repeat}details[open] summary:after{transform:rotate(180deg)}summary:hover:after{background-color:#e6eef6}

.board{background:#482419 url("foxgeese-original-board.png") center/100% 100% no-repeat}.board svg{display:none}.cell{width:8.4%;height:9.4%;background:transparent;border-color:transparent}.cell:hover{background:#dbeaf055;border-color:#d6e5f0}.cell.target{background:#bdd8ed80;box-shadow:0 0 0 2px #eff7ff}.cell.selected:has(img){background:#d6e8fa77;border-color:#e6f2ff}

.board{touch-action:none}.drag-ghost{position:fixed;width:45px;height:52px;object-fit:contain;transform:translate(-50%,-50%);pointer-events:none;z-index:1000;filter:drop-shadow(0 4px 5px #0008)}

/* Original 640×385 scene and its 376×376 board crop. */
.game{padding:0;overflow:hidden;background:#17110e}.original-scene{position:relative;width:100%;aspect-ratio:640/385;background:#17110e url("foxgeese-original-scene.png") center/100% 100% no-repeat}.original-scene .board{position:absolute;left:20.78125%;top:.51948%;width:58.75%;height:97.66234%;aspect-ratio:auto;border-radius:0;background:transparent}.original-scene .cell{width:8.4%;height:9.4%}

/* Размещаем управление под игровым экраном. */
.game-page-main .layout{grid-template-columns:minmax(0,1fr);gap:18px}.game-page-main .original-scene{width:100%}.game-page-main aside{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;align-items:start}.game-page-main aside details{margin-top:0}.game-page-main aside .note{grid-column:1/-1;margin:0}@media(max-width:700px){.game-page-main aside{grid-template-columns:1fr}.game-page-main aside .note{grid-column:auto}}
.game-controls{display:flex;align-items:center;gap:12px;flex-wrap:wrap;padding:4px 2px}.game-controls label{margin:0;font-size:14px}.game-controls select{width:auto;min-width:205px}.game-controls button{padding:10px 15px;border:1px solid #d6e1ea;border-radius:10px;background:#fff;color:#102b53;font:700 14px Manrope,"Segoe UI",sans-serif;cursor:pointer}.game-controls button:hover{background:#edf3f8}.game-controls button:focus-visible,.source-game a:focus-visible,dialog button:focus-visible{outline:3px solid #477fb7;outline-offset:3px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.ending{padding:16px 20px;background:white;border-radius:14px}.ending[hidden]{display:none}.source-game{display:flex;gap:24px;align-items:center;margin-top:32px;padding:24px;background:#fff;border:1px solid #e4e9ee;border-radius:22px;box-shadow:0 14px 38px #1823381c}.source-game img{width:100px;aspect-ratio:3/4;object-fit:cover;border-radius:10px}.source-game h2{margin:5px 0 8px;font-size:24px}.source-game p{color:#536680;line-height:1.5}.source-game .source-game__eyebrow{font-size:11px;font-weight:800;letter-spacing:.08em;color:#687d96}.source-game a{color:#183d67;font-weight:700;text-decoration:none}.source-game a:hover{text-decoration:underline}dialog{width:min(520px,calc(100% - 32px));border:0;border-radius:20px;padding:24px;color:#102b53;box-shadow:0 20px 70px #102b5355}dialog::backdrop{background:#0b1a2aaa}.dialog-head{display:flex;justify-content:space-between;align-items:center;gap:20px}.dialog-head h2{margin:0}.dialog-head button{border:1px solid #dce5eb;border-radius:50%;background:#f5f8fb;color:#102b53;font-size:24px;width:36px;height:36px;cursor:pointer}dialog p{line-height:1.6;color:#536680}.game:fullscreen{display:grid;place-items:center;background:#15110f}.game:fullscreen .original-scene{width:min(100vw,166.23vh);max-height:100vh}@media(max-width:600px){.game-controls{gap:8px}.game-controls select{flex:1;min-width:0}.source-game{padding:18px;gap:15px}.source-game img{width:76px}.source-game h2{font-size:19px}}

.game-intro__actions .game-controls{display:contents}.game-intro__actions .game-controls label{align-self:center;color:#fff;font-size:13px}.game-intro__actions .game-controls select{width:auto;min-width:180px;min-height:42px;background:#fff;color:#102b53}.game-intro__actions .game-controls button{min-height:42px;background:rgba(9,28,51,.35);color:#fff;border-color:rgba(255,255,255,.72)}.game-intro__actions .game-controls button:hover{background:#284c6e}.game-intro__actions .game-controls button:focus-visible,.game-intro__actions .game-controls select:focus-visible{outline:3px solid #a9d2f5;outline-offset:3px}@media(max-width:600px){.game-intro__actions .game-controls select{min-height:44px;min-width:0;max-width:100%}}

.game-page-main .game-intro{min-height:230px;background:linear-gradient(90deg,rgba(8,23,42,.9),rgba(8,23,42,.72) 45%,rgba(8,23,42,.25)),url("https://library.magicalnancy.ru/assets/nancy-game-16-hero.webp") center/cover no-repeat}.game-card{padding:clamp(10px,2.5vw,24px);background:#fff;border-radius:22px;box-shadow:0 14px 38px #1823361c}.game-card .layout{max-width:980px;margin:auto}.steam-promo{margin-top:22px;padding:30px 20px;text-align:center;border-radius:20px;color:#fff;background:linear-gradient(90deg,rgba(7,29,54,.86),rgba(7,29,54,.7)),url("https://library.magicalnancy.ru/assets/nancy-game-16-hero.webp") center/cover no-repeat;box-shadow:0 14px 38px #1823361c}.steam-promo h2{margin:0;color:#fff;font-size:clamp(22px,3vw,30px)}.steam-promo p{margin:10px auto 16px;max-width:650px;font-size:14px;line-height:1.5;font-weight:600}.steam-promo__actions{display:flex;justify-content:center;flex-wrap:wrap;gap:10px}.steam-promo a{display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:10px 20px;border-radius:12px;background:#287d55;color:#fff;font-size:13px;font-weight:800;text-decoration:none}.steam-promo a:hover{background:#216846}.steam-promo a:focus-visible{outline:3px solid #a9d2f5;outline-offset:3px}@media(max-width:600px){.steam-promo{margin-top:16px;padding:26px 18px}}
.ending-overlay{position:absolute;inset:0;z-index:10;display:grid;place-items:center;padding:12px;background:rgba(8,23,42,.78)}.ending-overlay[hidden]{display:none}.ending-card{width:min(380px,90%);padding:clamp(18px,3vw,30px);border-radius:20px;background:#fff;color:#102b53;text-align:center;box-shadow:0 18px 54px #0006}.ending-card h2{margin:0;font-size:clamp(20px,3vw,32px)}.ending-card p{margin:12px 0 20px;color:#536680}.ending-buttons{display:flex;justify-content:center;align-items:center;gap:12px;flex-wrap:wrap}.ending-buttons a{color:#23486e;font-weight:700;text-decoration:none;padding:10px}.ending-buttons a:hover{text-decoration:underline}.ending-buttons a:focus-visible{outline:3px solid #477fb7;outline-offset:3px;border-radius:8px}
.game-page-main .game-intro{background:linear-gradient(90deg,rgba(20,4,5,.52),rgba(20,4,5,.18) 55%,transparent 82%),url("foxgeese-fox-geese-header.png") center/cover no-repeat}@media(max-width:600px){.game-page-main .game-intro{background-position:center,right center}}
.game-controls{position:relative}.game-controls #difficulty-label{font-size:14px;font-weight:700}.difficulty-menu{position:relative}.difficulty-trigger{display:flex;align-items:center;justify-content:space-between;gap:18px;min-width:230px;padding:5px 6px 5px 14px!important;border:1px solid #d7e1eb!important;border-radius:12px!important;background:#fff!important;color:#102b53!important;text-align:left}.difficulty-arrow{width:32px;height:32px;display:grid;place-items:center;flex:none;border:1px solid #dce5eb;border-radius:50%;background:#f6f9fb}.difficulty-arrow:before{content:"";width:7px;height:7px;border-right:1.5px solid #183652;border-bottom:1.5px solid #183652;transform:translateY(-2px) rotate(45deg)}.difficulty-trigger[aria-expanded=true] .difficulty-arrow:before{transform:translateY(2px) rotate(225deg)}.difficulty-trigger:hover .difficulty-arrow{background:#e9f1f7}.difficulty-trigger:focus-visible,.difficulty-options button:focus-visible{outline:3px solid #477fb7;outline-offset:2px}.difficulty-options{position:absolute;z-index:20;top:calc(100% + 6px);left:0;min-width:100%;padding:5px;border:1px solid #dce5eb;border-radius:12px;background:#fff;box-shadow:0 10px 28px #102b5324}.difficulty-options[hidden]{display:none}.difficulty-options button{display:block;width:100%;border:0;border-radius:8px;background:transparent;padding:10px!important;text-align:left;white-space:nowrap;font-weight:500}.difficulty-options button:hover,.difficulty-options button[aria-selected=true]{background:#edf3f8;color:#102b53}
.difficulty-trigger #difficulty-current,.difficulty-options button{font-weight:400}
