:root {
  --ink: #103f4b;
  --ink-soft: #56777b;
  --cream: #fffaf0;
  --cream-depth: #dfd4bc;
  --play: #e98b6e;
  --play-depth: #cf735b;
  --teal: #299f9c;
  --teal-depth: #267f7d;
  --blue: #338f96;
  --blue-depth: #28787e;
  --gold: #eac36b;
  --font: 'Nunito', 'Trebuchet MS', system-ui, sans-serif;
}
html, body { background: #e4f1ec; }
#bg { pointer-events: none; }
#app { z-index: 3; }
.river-foreground { position: fixed; inset: 0; z-index: 2; overflow: hidden; pointer-events: none; contain: layout paint; }
.reeds { position: absolute; bottom: -10px; width: clamp(140px, 23vw, 390px); aspect-ratio: 1; pointer-events: none; }
.reeds img { width: 100%; height: 100%; object-fit: contain; transform-origin: 16% 100%; animation: river-breeze 8.5s ease-in-out infinite; will-change: transform; }
.reeds-left { left: -22px; }
.reeds-right { right: -22px; transform: scaleX(-1); }
.reeds-right img { animation-duration: 10.8s; animation-delay: -4s; }
@keyframes river-breeze {
  0%, 100% { transform: rotate(-1.2deg) skewX(-.6deg); }
  48% { transform: rotate(1.6deg) skewX(.8deg); }
  74% { transform: rotate(.3deg) skewX(-.2deg); }
}
body[data-time="night"] .river-foreground { filter: brightness(.5) saturate(.65); }
body[data-time="sunset"] .river-foreground { filter: sepia(.14) saturate(.8); }
.reduce-motion .reeds img { animation: none; will-change: auto; }
.bar { position: relative; z-index: 3; }
.icon-btn, .card-x { color: var(--ink); background: #fffaf0; box-shadow: 0 2px 0 #dbdfd4, 0 4px 12px #254e4810; }
.icon-btn svg { fill: var(--ink); }
.coins, .level-pill { background: #fffdf4ed; box-shadow: 0 2px 0 #d8e1d9, 0 5px 16px #254e4810; }
.coins::after { background: var(--teal); }
.logo-img { width: min(320px, 78vw); filter: none; animation: none; }
.logo { animation: none; }
.btn { text-shadow: none; box-shadow: 0 3px 0 var(--play-depth), 0 5px 12px #254e4812; }
.btn-play { background: var(--play); box-shadow: 0 4px 0 var(--play-depth), 0 7px 14px #254e4814; }
.btn-play.pulse { animation: none; }
.btn-play .tri { filter: none; }
.btn-free, .btn-blue, .btn-teal { background: var(--teal); box-shadow: 0 3px 0 var(--teal-depth); }
.btn-wheel { background: #f3d58d; color: #69552c; box-shadow: 0 3px 0 #d6b574; }
.btn-wheel.ready { animation: none; }
.next-card { background: #fffdf4ed; border: 1px solid #e3dfce; box-shadow: 0 3px 0 #dce2d5, 0 7px 18px #254e4810; }
.next-card .nc-count { background: #d4eae3; color: #28635f; }
.next-card .chest-img, .chest-img { filter: none; }
.tabbar, #home .tabbar { background: #fffdf1eb; border: 1px solid #d9e5dd; box-shadow: 0 3px 14px #254e4810; border-radius: 20px 20px 0 0; }
.tabbar button { color: #6e8985; background: none; box-shadow: none; }
.tabbar button + button::before { display: none; }
.tabbar button.on, #home .tabbar button.on { margin-top: 0; padding-top: 0; border-radius: 16px; background: #d9eee7; color: #216d6a; box-shadow: none; }
.tabbar .tab-ico svg, .tabbar button.on .tab-ico svg { filter: none; animation: none; }
.tabbar .tab-lbl { text-shadow: none; }
.game-logo { display: none; width: 145px; height: 70px; object-fit: contain; }
#clues { height: 108px; }
.clue { background: #fffdf5f2; box-shadow: 0 3px 0 #dbe4db, 0 6px 12px #254e4810; }
.clue.current { background: #e5f3ec; }
.clue:not(.current) { opacity: 1; }
.clue:not(.current) .clue-text { color: var(--ink); }
.clue-heading { display: none; }
.clue-text { font-weight: 700; }
.clue-ans span { background: #e0ebe3; color: var(--ink-soft); }
.hints { position: relative; z-index: 3; gap: 20px; }
.hint-ico.svg { background: #f5faf0e8; border: 1px solid #d7e5d9; box-shadow: 0 2px 0 #d6e2d6, 0 4px 9px #254e4810; }
.hint-ico.svg img { inset: 15%; width: 70%; height: 70%; filter: none; }
.hint:hover .hint-ico.svg { box-shadow: 0 2px 0 #d6e2d6, 0 5px 12px #254e4818; }
.hint:hover .hint-ico.svg img { animation: none; }
.hint.locked .hint-ico img { filter: saturate(.35); opacity: .75; }
.hint.locked .hint-ico::after { background-color: #315d5a44 !important; background-size: 26% !important; }
.price, .hint.locked .price { color: var(--ink); background: #fffaf0; box-shadow: 0 2px 0 #dce3d6; }
.hint.locked { filter: none; opacity: 1; }
.otter { display: none; }
.card-title { background: #e7f0e7; box-shadow: 0 2px 0 #d4e0d3; }
#modal { background: #183f4866; }
#modal .card { background: #fffdf5; box-shadow: 0 4px 0 #d5dfd4, 0 14px 42px #183f4820; }
.shop-item, .day, .langs button { background: #e8f0e7; box-shadow: 0 2px 0 #d4e0d3; }
.langs button.on { background: var(--teal); box-shadow: 0 2px 0 var(--teal-depth); }
#board { cursor: pointer; }
#preview span { background: #fffaf0; box-shadow: 0 2px 0 #d8dece; animation: chipIn .18s ease-out; }
#tip .tip-text { color: #237f80; box-shadow: 0 3px 0 #d6e5da; }
#curtain { background: #9ad9d9; }
#curtain::before { display: none; }
button:focus-visible { outline: 3px solid #176f78; outline-offset: 4px; }
@media (max-width: 899px), (max-aspect-ratio: 4/3) {
  .reeds { width: min(24vw, 145px); bottom: -8px; }
  .reeds-left { left: -12px; }
  .reeds-right { right: -12px; }
  #home .logo { margin-top: clamp(16px, 4vh, 45px); }
  .home-actions { gap: 16px; margin-top: 20px; }
  .hint { width: 84px; height: 95px; }
  .hint-ico { width: 72px; height: 72px; }
  .clue { height: 90px; }
  .clue-text { font-size: 20px; }
  #game .bar { gap: 8px; }
}
@media (max-height: 710px) and (max-width: 899px) {
  .logo-img { width: min(240px, 62vw); }
  #home .logo { margin-top: 6px; }
  .next-card { padding: 9px 13px; }
  .home-actions { margin-top: 12px; gap: 10px; margin-bottom: 14px; }
  .btn-play { font-size: 26px; padding: 9px 24px; }
  #clues { height: 86px; }
  .clue { height: 76px; }
  .hint { height: 80px; }
  .hint-ico { width: 62px; height: 62px; }
}
@media (min-width: 900px) and (min-aspect-ratio: 4/3) {
  #home.screen { max-width: 1060px; margin: auto; padding: 20px 40px 0; }
  #home .logo { align-self: center; }
  #home .logo-img { width: 355px; max-height: 38vh; object-fit: contain; }
  #home .next-card { min-height: 160px; width: auto; }
  #home .home-actions { width: 360px; }
  #home .btn-play { min-width: 0; width: 100%; font-size: 32px; }
  #home .tabbar { width: 440px; margin-top: 22px; height: 72px; }
  #game.screen { max-width: 1190px; margin: auto; padding: 26px 30px 22px; column-gap: 36px; grid-template-columns: minmax(0, 600px) minmax(280px, 350px); justify-content: center; grid-template-rows: 76px 18px minmax(0, 1fr) 115px; }
  .game-logo { display: block; margin-left: 14px; }
  #game .level-pill { position: absolute; left: 50%; transform: translateX(-50%); font-size: 22px; }
  #game .bar { height: 76px; }
  #game .coins { font-size: 23px; min-width: 124px; }
  #preview { height: 18px; align-self: center; position: relative; z-index: 3; }
  #preview:not(:empty) { transform: translateY(12px); }
  #clues { height: auto; align-self: center; padding: 18px; margin: 0; background: #fffdf4ed; border: 1px solid #e4dfca; border-radius: 28px; box-shadow: 0 5px 16px #254e480c; max-height: calc(100% - 20px); }
  #clue-track { gap: 8px; }
  .clue-heading { display: block; text-align: center; font-size: 20px; font-weight: 800; letter-spacing: 1.5px; margin: 4px 0 18px; }
  .clue { min-height: 76px; padding: 15px 10px; border-radius: 15px; box-shadow: none; background: transparent; border: 1px solid transparent; }
  .clue.current { background: #dff1e9; border-left: 4px solid #2e9e9d; box-shadow: none; transform: none; }
  .clue:not(.current) { opacity: 1; background: transparent; border-bottom-color: #e6e8dc; }
  .clue:hover:not(.done) { transform: none; background: #edf5eb; }
  .clue-text { font-size: 20px; line-height: 1.3; }
  .hints { gap: 24px; align-self: center; }
  .hint { width: 94px; height: 103px; }
  .hint-ico { width: 80px; height: 80px; }
  #combo { right: 160px; }
}
@media (prefers-reduced-motion: reduce) {
  .reeds img { animation: none; will-change: auto; }
}
@media (min-width: 900px) and (min-aspect-ratio: 4/3) and (max-height: 700px) {
  #game.screen { padding: 12px 24px; grid-template-rows: 52px 0 minmax(0, 1fr) 84px; column-gap: 28px; grid-template-columns: minmax(0, 540px) minmax(270px, 320px); }
  #game .bar { height: 52px; }
  .game-logo { height: 52px; width: 120px; }
  #clues { padding: 12px; background: #fffdf4; }
  .clue-heading { font-size: 17px; margin: 2px 0 8px; }
  .clue { min-height: 62px; padding: 10px 8px; }
  .clue-text { font-size: 17px; }
  .hint { width: 76px; height: 82px; }
  .hint-ico { width: 62px; height: 62px; }
}
