.content-page:has(> .sn-page) { padding: 0 24px; }
.sn-page { --sn-mint: #a7ffc7; --sn-cyan: #53e7db; --sn-pink: #ff81bd; max-width: 1060px; margin: auto; padding: 18px 16px 24px; color: #e8f3ee; }
.sn-page [hidden] { display: none !important; }
.sn-page button { font: inherit; -webkit-tap-highlight-color: transparent; }
.sn-title-line { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 8px 0 16px; }
.sn-title-line h1 { display: flex; align-items: center; gap: 12px; margin: 0; font-size: clamp(27px, 3.5vw, 38px); font-weight: 850; line-height: 1; letter-spacing: -1.6px; }
.sn-title-line h1 > span { color: var(--sn-mint); }
.sn-title-line h1 > i { font-size: 35px; margin-left: 3px; color: var(--sn-pink); font-style: normal; font-weight: 400; }
.sn-edition { color: #91a5a7; font-size: 9px; letter-spacing: 1.6px; text-align: right; }
.sn-layout { display: grid; grid-template-columns: minmax(0, 1fr) 236px; gap: 40px; align-items: start; }
.sn-game { min-width: 0; }
.sn-hud { height: 62px; display: flex; gap: 34px; align-items: center; padding: 0 3px 16px; }
.sn-score, .sn-best { position: relative; display: flex; gap: 4px; flex-direction: column; }
.sn-score > span:first-child, .sn-best > span { color: #9aadae; font-size: 9px; font-weight: 600; letter-spacing: 1.7px; display: flex; align-items: center; gap: 6px; }
.sn-score strong, .sn-best strong { font-size: 28px; font-variant-numeric: tabular-nums; font-weight: 650; letter-spacing: -1px; line-height: 1.1; }
.sn-score strong { color: var(--sn-mint); }
.sn-best strong { color: #d1ded9; }
.sn-best svg { height: 12px; width: 12px; fill: none; stroke: #aebbad; stroke-width: 1.3; }
.sn-score-pop { position: absolute; top: 20px; left: calc(100% + 10px); color: var(--sn-pink); font-size: 13px; opacity: 0; pointer-events: none; }
.sn-score-pop.is-active { animation: sn-score-pop .55s ease-out; }
.sn-pause { display: grid; place-items: center; margin-left: auto; width: 42px; height: 42px; border: 1px solid #304342; border-radius: 11px; background: #162624; color: #c2d6cd; font-size: 20px !important; }
.sn-pause:hover:enabled { color: var(--sn-mint); border-color: #83be9e; }
.sn-pause:disabled { opacity: .35; }
.sn-board { position: relative; width: 100%; aspect-ratio: 1; overflow: hidden; border: 1px solid #304d48; border-radius: 16px; background: #0b171b; box-shadow: 0 0 0 5px #101c20, 0 20px 55px #0003; isolation: isolate; }
.sn-board:focus-within { border-color: #6a9c87; }
#sn-canvas { display: block; width: 100%; height: 100%; outline: none; touch-action: none; user-select: none; -webkit-user-select: none; }
#sn-canvas:focus-visible { outline: 2px solid var(--sn-mint); outline-offset: -5px; border-radius: 15px; }
.sn-overlay { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; background: #09151bc9; }
.sn-overlay-content { width: 100%; padding: 24px; }
.sn-overlay-mark { display: block; margin: 0 auto 26px; width: 80px; height: 52px; }
.sn-overlay-mark svg { overflow: visible; width: 100%; height: 100%; }
.sn-overlay-mark path { fill: none; stroke: var(--sn-cyan); stroke-width: 12; stroke-linecap: round; stroke-linejoin: round; }
.sn-overlay-mark circle:first-of-type { fill: var(--sn-mint); }
.sn-overlay-mark circle:last-of-type { fill: #122a23; }
.sn-kicker { font-size: 9px; color: var(--sn-cyan); letter-spacing: 1.8px; margin: 0 0 15px; }
.sn-overlay h2 { font-size: clamp(24px, 3vw, 35px); font-weight: 700; letter-spacing: -1.2px; margin: 0 0 12px; }
#sn-overlay-detail { font-size: 13px; color: #a5bcb9; margin-bottom: 25px; }
.sn-play { display: inline-flex; gap: 36px; align-items: center; justify-content: space-between; min-height: 48px; padding: 13px 22px; background: var(--sn-mint); color: #13281f; border: 1px solid var(--sn-mint); border-radius: 9px; font-size: 14px !important; font-weight: 700 !important; box-shadow: 0 0 26px #a7ffc710; transition: background .15s, transform .15s; }
.sn-play:hover { background: #c8ffdc; transform: translateY(-1px); }
.sn-play:active { transform: translateY(1px); }
.sn-play > span { font-size: 19px; line-height: 1; }
.sn-start-hint { display: block; color: #8da49f; font-size: 10px; margin-top: 14px; }
.sn-board-caption { display: flex; justify-content: space-between; gap: 14px; margin: 17px 2px 0; color: #8ba3a1; font-size: 9px; letter-spacing: 1.3px; }
.sn-board-caption > span:first-child { display: flex; align-items: center; gap: 7px; }
.sn-board-caption i { height: 5px; width: 5px; border-radius: 50%; background: var(--sn-cyan); }
.sn-sidebar { padding-top: 67px; }
.sn-small-label { font-size: 9px; color: #9cb4af; letter-spacing: 1.4px; line-height: 1.7; }
.sn-small-label > span { color: #64827b; margin-right: 6px; }
.sn-about h2 { font-size: 29px; font-weight: 650; letter-spacing: -1.1px; line-height: 1.2; margin: 18px 0 15px; }
.sn-about h2 > span { color: var(--sn-mint); }
.sn-about > p { color: #9bb0ad; font-size: 12px; line-height: 1.9; max-width: 225px; margin: 0; }
.sn-rules { display: grid; gap: 20px; margin: 30px 0; }
.sn-rules > div { display: flex; align-items: center; gap: 16px; }
.sn-rules p { font-size: 11px; color: #cfdfd7; line-height: 1.6; margin: 0; }
.sn-rules small { display: block; font-size: 10px; color: #8fa6a1; }
.sn-food-icon { width: 11px; height: 11px; border-radius: 3px; transform: rotate(45deg); background: var(--sn-pink); box-shadow: 0 0 17px #ff81bd35; flex: 0 0 11px; margin-left: 3px; }
.sn-rule-turn { color: var(--sn-cyan); font-size: 24px; line-height: 1; flex: 0 0 14px; }
.sn-controls { border-top: 1px solid #2a3b3c; padding-top: 20px; }
.sn-desktop-help, .sn-touch-help { font-size: 11px; color: #c1d2ca; line-height: 1.9; margin: 10px 0 0; }
.sn-desktop-help > span { font-size: 10px; color: #8fa6a1; }
.sn-touch-help { display: none; }
.sn-dpad { display: grid; grid-template-columns: repeat(3, 43px); grid-template-rows: repeat(3, 39px); gap: 5px; width: max-content; margin: 20px auto 0; }
.sn-dpad > button { border: 1px solid #304640; border-radius: 9px; background: #172723; color: #c8e9d8; font-size: 20px; touch-action: none; user-select: none; -webkit-user-select: none; }
.sn-dpad > button:hover { background: #233e31; border-color: #6e9b81; }
.sn-dpad > button:active { background: #8eddb1; color: #11271e; }
.sn-dpad > button[data-sn-direction="up"] { grid-column: 2; }
.sn-dpad > button[data-sn-direction="left"] { grid-column: 1; grid-row: 2; }
.sn-dpad > button[data-sn-direction="right"] { grid-column: 3; grid-row: 2; }
.sn-dpad > button[data-sn-direction="down"] { grid-column: 2; grid-row: 3; }
.sn-dpad > span { grid-column: 2; grid-row: 2; display: grid; place-items: center; color: #517467; font-size: 14px; }
.sn-save-note { color: #88a09a; font-size: 9px; line-height: 1.7; text-align: center; margin: 24px 0 0; }
@keyframes sn-score-pop { 0% { opacity: 1; transform: translateY(5px); } 100% { opacity: 0; transform: translateY(-15px); } }
@media (min-width: 761px) {
    .sn-layout { grid-template-columns: minmax(0, clamp(300px, calc(100dvh - 300px), 650px)) 236px; justify-content: center; }
    .sn-heading { max-width: calc(clamp(300px, calc(100dvh - 300px), 650px) + 276px); margin: auto; }
}
@media (min-width: 761px) and (pointer: fine) { .sn-dpad { display: none; } }
@media (max-width: 1000px) and (min-width: 761px) { .sn-layout { gap: 28px; } .sn-about h2 { font-size: 26px; } }
@media (pointer: coarse) { .sn-touch-help { display: block; } .sn-desktop-help, .sn-start-hint { display: none; } .sn-dpad { grid-template-columns: repeat(3, 50px); grid-template-rows: repeat(3, 45px); } }
@media (max-width: 760px) {
    .sn-page { padding: 16px 0 24px; max-width: 500px; }
    .sn-title-line { margin: 6px 0 18px; }
    .sn-title-line h1 { font-size: 29px; gap: 8px; }
    .sn-title-line h1 > i { font-size: 29px; }
    .sn-edition { font-size: 7px; max-width: 110px; line-height: 1.8; letter-spacing: 1px; }
    .sn-layout { display: flex; flex-direction: column; gap: 18px; }
    .sn-game { width: 100%; }
    .sn-hud { height: 62px; padding-bottom: 13px; }
    .sn-score strong, .sn-best strong { font-size: 24px; }
    .sn-board { border-radius: 12px; }
    .sn-sidebar { display: grid; grid-template-columns: 1fr; width: 100%; padding: 0; }
    .sn-about, .sn-rules, .sn-controls > .sn-small-label, .sn-desktop-help { display: none; }
    .sn-controls { display: flex; align-items: center; justify-content: space-between; gap: 18px; border: 0; padding: 0; }
    .sn-touch-help { display: block; margin: 0; max-width: 155px; font-size: 11px; }
    .sn-dpad { grid-template-columns: repeat(3, 48px); grid-template-rows: repeat(3, 44px); margin: 0; gap: 4px; flex-shrink: 0; }
    .sn-save-note { text-align: left; margin: 12px 0 0; }
    .sn-board-caption { font-size: 8px; letter-spacing: 1px; }
    .sn-overlay-mark { margin-bottom: 16px; width: 64px; height: 42px; }
    .sn-kicker { font-size: 8px; letter-spacing: 1.1px; }
    .sn-overlay h2 { font-size: 27px; }
    .sn-overlay-content { padding: 18px 12px; }
    #sn-overlay-detail { font-size: 12px; margin-bottom: 20px; }
}
@media (max-width: 380px) {
    .sn-edition, .sn-overlay-mark, .sn-start-hint { display: none; }
    .sn-overlay h2 { font-size: 24px; }
    .sn-kicker { font-size: 7px; }
}
@media (prefers-reduced-motion: reduce) { .sn-score-pop.is-active { animation: none; } .sn-play { transition: none; } }
