:root {
  --bone: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 52 32'%3E%3Ccircle cx='9' cy='9' r='8'/%3E%3Ccircle cx='9' cy='23' r='8'/%3E%3Ccircle cx='43' cy='9' r='8'/%3E%3Ccircle cx='43' cy='23' r='8'/%3E%3Crect x='8' y='9' width='36' height='14' rx='6'/%3E%3C/svg%3E");
  --ink: #07131d;
  --cream: #f7e6c2;
  --cyan: #2fd6ee;
  --gold: #ffc62e;
  --pink: #ff5c7a;
  --panel: rgba(255, 255, 255, 0.94);
  --shadow: 0 10px 30px rgba(7, 19, 29, 0.25);
  --safe-t: env(safe-area-inset-top, 0px);
  --safe-b: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #6cc6ff; color: var(--ink); font-family: 'Fredoka', 'Jua', system-ui, sans-serif; user-select: none; -webkit-user-select: none; touch-action: none; }
html:lang(ko) body, html:lang(ja) body { font-family: 'Fredoka', 'Jua', system-ui, sans-serif; }
#c { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
button { font: inherit; color: inherit; border: 0; cursor: pointer; background: none; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }

/* 아이콘 */
i { display: inline-block; flex: none; }
.i-play { width: 0; height: 0; border-left: 22px solid currentColor; border-top: 14px solid transparent; border-bottom: 14px solid transparent; margin-left: 4px; }
.i-pause { width: 16px; height: 18px; border-left: 5px solid currentColor; border-right: 5px solid currentColor; }
.i-sound { width: 24px; height: 22px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 9v6h4l5 5V4L7 9H3zm13.5 3A4.5 4.5 0 0 0 14 8v8a4.5 4.5 0 0 0 2.5-4zM14 3.2v2.1a7 7 0 0 1 0 13.4v2.1a9 9 0 0 0 0-17.6z'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M3 9v6h4l5 5V4L7 9H3zm13.5 3A4.5 4.5 0 0 0 14 8v8a4.5 4.5 0 0 0 2.5-4zM14 3.2v2.1a7 7 0 0 1 0 13.4v2.1a9 9 0 0 0 0-17.6z'/%3E%3C/svg%3E") center/contain no-repeat; }
.btn-sound.off .i-sound { opacity: .35; }
.i-out { width: 12px; height: 12px; border-top: 2.5px solid currentColor; border-right: 2.5px solid currentColor; transform: rotate(0deg); margin-left: 4px; }
.i-again { width: 22px; height: 22px; border: 4px solid currentColor; border-top-color: transparent; border-radius: 50%; }
.i-share { width: 20px; height: 20px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M18 16a3 3 0 0 0-2.4 1.2l-6.7-3.4a3 3 0 0 0 0-1.6l6.7-3.4A3 3 0 1 0 15 7l-6.7 3.4a3 3 0 1 0 0 3.2L15 17a3 3 0 1 0 3-1z'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M18 16a3 3 0 0 0-2.4 1.2l-6.7-3.4a3 3 0 0 0 0-1.6l6.7-3.4A3 3 0 1 0 15 7l-6.7 3.4a3 3 0 1 0 0 3.2L15 17a3 3 0 1 0 3-1z'/%3E%3C/svg%3E") center/contain no-repeat; }
.i-home { width: 22px; height: 20px; background: currentColor; clip-path: polygon(50% 0, 100% 45%, 86% 45%, 86% 100%, 14% 100%, 14% 45%, 0 45%); }
.i-x { width: 18px; height: 18px; background: linear-gradient(45deg, transparent 42%, currentColor 42% 58%, transparent 58%), linear-gradient(-45deg, transparent 42%, currentColor 42% 58%, transparent 58%); }
.i-crown { width: 20px; height: 16px; background: var(--gold); clip-path: polygon(0 100%, 0 20%, 25% 55%, 50% 0, 75% 55%, 100% 20%, 100% 100%); }

/* 버튼 */
.big-btn { display: flex; align-items: center; justify-content: center; gap: 12px; min-width: 220px; height: 70px; padding: 0 34px; border-radius: 999px; font-size: 30px; font-weight: 700; color: #fff; background: linear-gradient(180deg, #ffb13b, #ff7a1a); box-shadow: 0 7px 0 #c4520a, 0 14px 28px rgba(196, 82, 10, .35); text-shadow: 0 2px 0 rgba(0,0,0,.18); transition: transform .08s; animation: pulse 1.6s ease-in-out infinite; }
.big-btn:active { transform: translateY(5px); box-shadow: 0 2px 0 #c4520a; }
.mid-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 52px; min-width: 52px; padding: 0 18px; border-radius: 18px; font-size: 19px; font-weight: 700; background: #fff; box-shadow: 0 5px 0 rgba(7,19,29,.18), 0 8px 18px rgba(7,19,29,.12); }
.mid-btn:active { transform: translateY(3px); box-shadow: 0 2px 0 rgba(7,19,29,.18); }
.ic-btn { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: rgba(255,255,255,.9); box-shadow: 0 4px 0 rgba(7,19,29,.15); }
@keyframes pulse { 50% { transform: scale(1.04); } }
/* 화면 */
.screen { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; z-index: 10; }
.screen.dim { background: rgba(7, 19, 29, .45); justify-content: center; backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.row { display: flex; gap: 12px; justify-content: center; align-items: center; flex-wrap: wrap; }
.row.col { flex-direction: column; gap: 18px; }

#menu { justify-content: space-between; padding: calc(28px + var(--safe-t)) 16px calc(26px + var(--safe-b)); pointer-events: none; }
#menu > * { pointer-events: auto; }
.logo-wrap { display: flex; flex-direction: column; align-items: center; animation: drop .7s cubic-bezier(.2,1.6,.4,1) both; }
.logo-img { width: min(78vw, 460px); height: auto; filter: drop-shadow(0 10px 20px rgba(7,19,29,.3)); }
.logo-img + .logo { display: none; }
.logo { margin: 0; display: flex; flex-direction: column; align-items: center; line-height: .82; font-weight: 700; font-style: italic; letter-spacing: -1px; }
.logo span { font-size: clamp(64px, 18vw, 120px); color: var(--cream); -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 5px 6px 0 var(--cyan), 7px 9px 0 var(--ink); transform: skew(-8deg); }
.logo span + span { color: #fff; }
@keyframes drop { from { transform: translateY(-60px) scale(.8); opacity: 0; } }
.best-m { margin-top: 10px; padding: 6px 16px; border-radius: 999px; background: rgba(7,19,29,.55); color: #fff; font-size: 17px; display: flex; gap: 8px; align-items: center; }
.best-m b { color: var(--gold); font-size: 20px; }
.menu-bottom { display: flex; flex-direction: column; align-items: center; gap: 18px; width: 100%; }
.studio { display: inline-flex; align-items: center; padding: 8px 16px; border-radius: 999px; background: var(--ink); color: var(--cream); font-weight: 700; font-size: 14px; letter-spacing: 1px; box-shadow: 0 4px 12px rgba(7,19,29,.3); }
/* HUD */
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 5; }
#hud > * { position: absolute; }
#btnPause { left: 14px; top: calc(14px + var(--safe-t)); pointer-events: auto; }
#score { left: 50%; top: calc(10px + var(--safe-t)); transform: translateX(-50%); font-size: 40px; font-weight: 700; color: #fff; -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; text-shadow: 0 4px 0 rgba(7,19,29,.35); font-variant-numeric: tabular-nums; }
/* 결과 */
#over { justify-content: flex-end; padding: calc(12px + var(--safe-t)) 16px calc(12px + var(--safe-b)); overflow-y: auto; }
.panel { width: min(100%, 400px); background: var(--panel); border-radius: 28px; padding: 22px 20px 18px; display: flex; flex-direction: column; align-items: center; gap: 12px; box-shadow: var(--shadow); animation: pop .45s cubic-bezier(.2,1.5,.4,1) both; }
@keyframes pop { from { transform: scale(.7); opacity: 0; } }
.lbl { font-size: 16px; font-weight: 600; opacity: .55; letter-spacing: 2px; }
.big-num { font-size: 60px; font-weight: 700; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; }
.badge { padding: 4px 14px; border-radius: 999px; background: linear-gradient(90deg, #ff5c7a, #ffb13b); color: #fff; font-weight: 700; letter-spacing: 2px; animation: pulse 1s infinite; }
.mini { display: flex; gap: 22px; font-size: 20px; }
.mini span { display: flex; align-items: center; gap: 6px; }
#count { position: fixed; inset: 0; display: grid; place-items: center; font-size: 120px; font-weight: 700; color: #fff; -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; z-index: 30; pointer-events: none; }
#nogl { display: none; }

@media (min-height: 900px) { .big-btn { height: 78px; } }
@media (max-height: 640px) { .logo span { font-size: 60px; } .big-btn { height: 60px; font-size: 26px; } .menu-bottom { gap: 12px; } .big-num { font-size: 48px; } .feature { aspect-ratio: 21/9; } }
@keyframes pulse { 50% { transform: scale(1.04); } }
@keyframes drop { from { transform: translateY(-60px) scale(.8); opacity: 0; } }
@keyframes pop { from { transform: scale(.7); opacity: 0; } }
@keyframes fade { 0%, 80% { opacity: 1; } 100% { opacity: 0; } }
@keyframes popUp { 0% { transform: translate(-50%, 10px) scale(.6); opacity: 0; } 20% { transform: translate(-50%, -10px) scale(1.15); opacity: 1; } 100% { transform: translate(-50%, -70px) scale(1); opacity: 0; } }
@keyframes blink { to { opacity: .35; } }
@keyframes ring { to { stroke-dashoffset: 289; } }
@keyframes banner { 0% { opacity: 0; transform: translate(-50%, -50%) scale(2); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 80% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -60%) scale(.9); } }
@keyframes fbump { 40% { transform: translateX(-50%) scale(1.22); } }
@keyframes tapPulse { 0% { box-shadow: 0 0 0 0 rgba(255,255,255,.7); transform: translateX(-50%) scale(1); } 70% { box-shadow: 0 0 0 26px rgba(255,255,255,0); transform: translateX(-50%) scale(.92); } 100% { transform: translateX(-50%) scale(1); } }
#toast { position: fixed; left: 50%; top: calc(84px + var(--safe-t)); transform: translate(-50%, -30px) scale(.8); opacity: 0; display: flex; align-items: center; gap: 12px; padding: 10px 18px 10px 10px; border-radius: 22px; background: rgba(255,255,255,.96); box-shadow: 0 0 0 3px #ffc62e, var(--shadow); z-index: 20; pointer-events: none; transition: .35s cubic-bezier(.2,1.6,.4,1); max-width: calc(100% - 32px); }
#toast.show { opacity: 1; transform: translate(-50%, 0) scale(1); }
#toast img { width: 56px; height: 56px; border-radius: 14px; }
#toast b { display: block; font-size: 17px; }
#toast em { font-style: normal; font-weight: 700; font-size: 13px; color: #fff; background: var(--pink); padding: 2px 8px; border-radius: 8px; }
#toast em.dup { background: #ffb13b; }
.pop { position: absolute; left: 0; top: 0; transform: translate(-50%, 0); font-size: 30px; font-weight: 700; color: #fff; -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; white-space: nowrap; animation: popUp .9s ease-out forwards; }
.pop small { font-size: 20px; color: #ffe14d; margin-left: 6px; }
.pop .coin-ic { width: 26px; height: 16px; margin-left: 6px; vertical-align: middle; }
.hub-link { position: absolute; left: 14px; top: calc(14px + var(--safe-t)); }
.i-grid { width: 20px; height: 20px; background: radial-gradient(circle, currentColor 0 3.5px, transparent 4px) 0 0 / 10px 10px; }
.i-flag { width: 18px; height: 20px; background: linear-gradient(90deg, #07131d 0 3px, transparent 3px), conic-gradient(from 90deg at 50% 50%, #fff 0 25%, #07131d 0 50%, #fff 0 75%, #07131d 0) 3px 0 / 8px 8px no-repeat; background-size: auto, 15px 12px; }
.chal-m { margin-top: 8px; display: flex; gap: 8px; align-items: center; padding: 6px 14px; border-radius: 999px; background: #fff; font-size: 18px; box-shadow: 0 4px 0 rgba(7,19,29,.15); animation: pulse 1.4s infinite; }
.rank { padding: 6px 18px; border-radius: 999px; color: #fff; font-family: 'Jua', 'Fredoka', sans-serif; font-size: 20px; box-shadow: 0 3px 0 rgba(0,0,0,.15); }
.chal-o { display: flex; align-items: center; gap: 8px; font-size: 18px; }
.chal-o em { font-style: normal; font-weight: 700; padding: 2px 10px; border-radius: 8px; color: #fff; }
.chal-o em.win { background: #2bc46a; } .chal-o em.lose { background: #8d99a6; }
.over-card { width: 100%; max-width: 230px; border-radius: 16px; box-shadow: 0 6px 18px rgba(7,19,29,.25); cursor: pointer; }
.share-big { background: linear-gradient(180deg, #4fd2ff, #1f8cf0); box-shadow: 0 7px 0 #135ea8, 0 14px 28px rgba(19,94,168,.35); }
.share-big:active { box-shadow: 0 2px 0 #135ea8; }
#toast { position: fixed; left: 50%; bottom: calc(30px + var(--safe-b)); top: auto; transform: translate(-50%, 20px); opacity: 0; padding: 10px 18px; border-radius: 16px; background: #fff; font-weight: 700; z-index: 40; pointer-events: none; transition: .3s; box-shadow: 0 6px 20px rgba(7,19,29,.25); }
#toast.show { opacity: 1; transform: translate(-50%, 0); }
body.loading #btnPlay { opacity: .6; animation: none; }
.best-m .sep { width: 1px; height: 16px; background: rgba(255,255,255,.4); }
.i-star { width: 22px; height: 22px; background: linear-gradient(180deg, #fff1b0, #ffc62e); clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); vertical-align: -3px; margin-right: 2px; }
#over .row { gap: 8px; flex-wrap: nowrap; }
#over .row .mid-btn { height: 48px; min-width: 48px; padding: 0 13px; font-size: 17px; }
@media (max-height: 760px) { #over .panel { gap: 8px; padding: 16px 16px 14px; } #over .big-num { font-size: 48px; } #over .over-card { max-width: 170px; } }
#hud #touchzone { z-index: 1; }
#hud button, #hud .ic-btn, #hud .tbtn, #hud a { z-index: 6; }
#over .row .mid-btn { white-space: nowrap; }
@media (max-width: 400px) { #over .row { gap: 6px; } #over .row .mid-btn { padding: 0 10px; font-size: 16px; } }
.hub-link, #btnPause { width: 54px !important; height: 54px !important; border-radius: 16px !important; top: calc(16px + env(safe-area-inset-top, 0px)) !important; left: calc(14px + env(safe-area-inset-left, 0px)) !important; z-index: 20 !important; touch-action: manipulation; }
.hub-link::before, #btnPause::before { content: ''; position: absolute; inset: -14px; }
.hub-link .i-grid { transform: scale(1.15); }

/* ---------- KEKE GOLF ---------- */
html, body { background: #8fd0ff; overscroll-behavior: none; }
#touchzone { position: absolute; inset: 0; pointer-events: auto; z-index: 1; touch-action: none; }
#btnPause, #btnMenuHud { position: absolute; pointer-events: auto; z-index: 20; width: 54px; height: 54px; border-radius: 16px; top: calc(16px + var(--safe-t)); }
#btnPause { left: calc(14px + env(safe-area-inset-left, 0px)); }
#btnMenuHud { left: calc(78px + env(safe-area-inset-left, 0px)); }
#btnPause::before, #btnMenuHud::before { content: ''; position: absolute; inset: -10px; }
#holeInfo { left: 50%; top: calc(10px + var(--safe-t)); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 4px; pointer-events: none; }
#holeN { font-size: 44px; font-weight: 700; line-height: 1; color: #fff; -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; text-shadow: 0 4px 0 rgba(7,19,29,.3); font-variant-numeric: tabular-nums; }
#holeN small { font-size: 22px; opacity: .9; margin-left: 2px; }
#par { padding: 3px 12px; border-radius: 999px; background: rgba(7,19,29,.55); color: #fff; font-size: 15px; font-weight: 700; letter-spacing: 1px; }
#strokes { display: flex; gap: 5px; }
#strokes i { width: 13px; height: 13px; border-radius: 50%; background: rgba(255,255,255,.35); box-shadow: inset 0 0 0 2px rgba(255,255,255,.8); transition: .2s; }
#strokes i.over { box-shadow: inset 0 0 0 2px rgba(255,140,140,.9); }
#strokes i.on { background: #fff; box-shadow: 0 0 0 2px var(--ink); transform: scale(1.1); }
#strokes i.on.over { background: #ff7a7a; }
#tot { right: calc(14px + env(safe-area-inset-right, 0px)); top: calc(18px + var(--safe-t)); min-width: 64px; height: 48px; padding: 0 14px; border-radius: 16px; display: grid; place-items: center; font-size: 28px; font-weight: 700; color: #fff; background: #1fa8f0; box-shadow: 0 4px 0 rgba(7,19,29,.25); font-variant-numeric: tabular-nums; }
#tot.under { background: #2bc46a; } #tot.overp { background: #ff5c5c; }
#banner { position: fixed; left: 50%; top: 34%; transform: translate(-50%, -50%); z-index: 7; pointer-events: none; opacity: 0; display: flex; flex-direction: column; align-items: center; gap: 6px; white-space: nowrap; }
#banner b { display: flex; align-items: baseline; gap: 10px; font-size: clamp(40px, 12vw, 76px); font-weight: 700; color: #fff; -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 0 6px 0 rgba(7,19,29,.3); line-height: 1; }
#banner b small { font-size: .45em; color: #ffe14d; }
#banner em { font-style: normal; font-weight: 700; font-size: 26px; padding: 4px 16px; border-radius: 999px; background: rgba(7,19,29,.6); color: #fff; }
#banner.good b { color: #9be15d; }
#banner.ace b { color: #ffe14d; font-size: clamp(36px, 10.5vw, 80px); animation: rainbow .6s linear infinite; }
#banner.show { animation: banner 2s ease-out forwards; }
@keyframes rainbow { 50% { color: #ff8fb1; } }
#pull { position: fixed; left: 0; top: 0; height: 8px; margin-top: -4px; transform-origin: 0 50%; border-radius: 4px; background: repeating-linear-gradient(90deg, var(--c, #fff) 0 10px, transparent 10px 18px); opacity: 0; pointer-events: none; z-index: 6; filter: drop-shadow(0 2px 2px rgba(7,19,29,.4)); }
#aimDot { position: fixed; left: -22px; top: -22px; width: 44px; height: 44px; border-radius: 50%; border: 4px solid rgba(255,255,255,.9); box-shadow: 0 0 0 3px rgba(7,19,29,.25); pointer-events: none; z-index: 6; }
#aimHint { left: 50%; bottom: calc(22% + var(--safe-b)); width: 64px; height: 64px; margin-left: -32px; pointer-events: none; animation: hintDrag 1.8s ease-in-out infinite; }
#aimHint::before { content: ''; position: absolute; inset: 8px; border-radius: 50%; background: rgba(255,255,255,.9); box-shadow: 0 4px 10px rgba(7,19,29,.3); }
#aimHint::after { content: ''; position: absolute; left: 50%; top: -70px; width: 6px; height: 70px; margin-left: -3px; border-radius: 3px; background: repeating-linear-gradient(0deg, #fff 0 8px, transparent 8px 14px); animation: hintLine 1.8s ease-in-out infinite; transform-origin: 50% 100%; }
@keyframes hintDrag { 0%, 15% { transform: translateY(0); opacity: 0; } 25% { opacity: 1; } 65% { transform: translateY(70px); opacity: 1; } 80%, 100% { transform: translateY(70px); opacity: 0; } }
@keyframes hintLine { 0%, 25% { transform: scaleY(0); } 65%, 100% { transform: scaleY(1); } }
.pop.bad { color: #ff7a7a; font-size: 44px; }

/* 결과 */
.score-row { display: flex; align-items: center; gap: 12px; }
.rel-badge { padding: 6px 16px; border-radius: 16px; font-size: 32px; font-weight: 700; color: #fff; background: #1fa8f0; }
.rel-badge.under { background: #2bc46a; } .rel-badge.overp { background: #ff5c5c; }
#cardO { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; width: 100%; max-width: 250px; }
#cardO i { aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 700; font-size: 14px; background: #eef1f6; color: var(--ink); }
#cardO i.under { background: #2bc46a; color: #fff; } #cardO i.overp { background: #ffd6d6; color: #c43c3c; }
#cardO i.ace { background: linear-gradient(135deg, #ffe14d, #ff9a3c); color: #fff; box-shadow: 0 0 0 2px #fff, 0 0 8px #ffc62e; }
.i-ace { width: 22px; height: 22px; position: relative; }
.i-ace::before { content: ''; position: absolute; left: 4px; top: 1px; width: 3px; height: 20px; background: var(--ink); border-radius: 2px; }
.i-ace::after { content: ''; position: absolute; left: 7px; top: 1px; width: 0; height: 0; border-left: 14px solid #ff3b4e; border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.best-m .rel { color: #9be15d; }
@media (max-height: 760px) { #cardO i { font-size: 12px; } }
@media (max-height: 640px) { #holeN { font-size: 34px; } #holeN small { font-size: 18px; } #tot { height: 42px; font-size: 24px; } #banner b { font-size: 46px; } .score-row .big-num { font-size: 44px; } .rel-badge { font-size: 26px; } }
/* 낮은 가로 화면: 결과 패널을 두 줄로 */
@media (max-height: 500px) and (orientation: landscape) {
  #over { justify-content: center; }
  #over .panel { width: min(100%, 720px); display: grid; grid-template-columns: 1fr 1fr; align-items: center; justify-items: center; gap: 8px 16px; padding: 14px; max-height: calc(100vh - 20px); overflow-y: auto; }
  #over .panel > * { grid-column: auto; }
  #over .panel #moreGames, #over .panel #hofForm { grid-column: 1 / -1; }
  #over .over-card { max-width: 110px; }
}
/* 낮은 가로 화면: 메뉴를 왼쪽(로고·최고점)·오른쪽(순위·버튼) 두 칸으로 */
@media (max-height: 520px) and (orientation: landscape) {
  #menu { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr auto auto; column-gap: 16px; row-gap: 8px; align-items: center; justify-items: center; padding: calc(10px + var(--safe-t)) 24px calc(10px + var(--safe-b)); }
  #menu .logo-wrap { grid-column: 1; grid-row: 1; }
  #menu .logo-img { width: min(30vw, 230px); }
  #menu .best-m { grid-column: 1; grid-row: 2; margin: 0; }
  #menu #chalM { grid-column: 2; grid-row: 1; align-self: start; margin: 0; }
  #menu .course-pick { grid-column: 1; grid-row: 3; }
  #menu #hofMenu { grid-column: 2; grid-row: 1; align-self: end; margin: 0; }
  #menu .menu-bottom { grid-column: 2; grid-row: 2 / span 2; gap: 8px; }
  #menu .big-btn { height: 56px; font-size: 24px; min-width: 200px; }
  #menu .mid-btn { height: 44px; min-width: 44px; }
  #menu .studio { padding: 5px 12px; font-size: 12px; }
}

/* 코스 고르기 */
.course-pick { display: flex; flex-direction: column; align-items: center; gap: 6px; }
#courseName { padding: 4px 14px; border-radius: 999px; background: rgba(7,19,29,.6); color: #fff; font-family: 'Jua', 'Fredoka', sans-serif; font-size: 18px; }
#courses { display: flex; gap: 6px; }
.cc { position: relative; width: 54px; height: 62px; border-radius: 16px; background: rgba(255,255,255,.9); box-shadow: 0 4px 0 rgba(7,19,29,.18); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; transition: transform .15s; }
.cc .ci { font-size: 26px; line-height: 1; }
.cc small { font-size: 12px; font-weight: 700; opacity: .7; }
.cc.on { background: #fff; box-shadow: 0 0 0 3px #ff9a3c, 0 4px 0 rgba(7,19,29,.18); transform: translateY(-3px) scale(1.06); }
.cc.lock { background: rgba(7,19,29,.45); box-shadow: none; }
.cc.lock .ci::before { content: ''; display: block; width: 18px; height: 14px; margin-top: 8px; border-radius: 4px; background: rgba(255,255,255,.75); box-shadow: 0 -9px 0 -4px transparent; }
.cc.lock .ci::after { content: ''; position: absolute; left: 50%; top: 13px; width: 12px; height: 12px; margin-left: -6px; border: 3px solid rgba(255,255,255,.75); border-bottom: 0; border-radius: 8px 8px 0 0; }
.cc.shake { animation: shake .35s; }
@keyframes shake { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
#holeN em { font-style: normal; font-size: 26px; margin-right: 6px; vertical-align: 6px; -webkit-text-stroke: 0; }
.course-o { font-family: 'Jua', 'Fredoka', sans-serif; font-size: 18px; opacity: .75; }
.next-btn { background: linear-gradient(180deg, #ffb13b, #ff7a1a) !important; color: #fff; box-shadow: 0 5px 0 #c4520a !important; gap: 4px !important; }
.next-btn .ci { font-size: 22px; }
.next-btn .i-play { border-left-width: 14px; border-top-width: 9px; border-bottom-width: 9px; }
.next-btn.new { animation: pulse 1s infinite; }
@media (max-height: 640px) { .cc { width: 48px; height: 54px; } .cc .ci { font-size: 22px; } #courseName { font-size: 15px; } }

#menu .course-pick { pointer-events: auto; }
