
:root {
  --ink: #1f2a24;
  --ink-soft: #55625a;
  --paper: #fbfaf5;
  --paper-2: #f2efe4;
  --line: #e2ddcc;
  --accent: #7fae3c;      
  --accent-ink: #ffffff;
  --gold: #c9a24a;
  --gold-soft: #fff4d2;
  --night: #0f1a35;
  --danger: #c0392b;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(20, 30, 20, .14);
  --font: "Malgun Gothic", "Apple SD Gothic Neo", "Noto Sans KR", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--font); color: var(--ink);
  background: linear-gradient(180deg, #eef4e6 0%, var(--paper) 40%, var(--paper) 100%);
  word-break: keep-all; overflow-wrap: anywhere; -webkit-tap-highlight-color: transparent;
}
button { font: inherit; cursor: pointer; }
.hidden { display: none !important; }


#topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 40; height: 48px;
  display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 12px;
  background: rgba(251, 250, 245, .92); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line);
}
.me { display: flex; align-items: center; gap: 6px; font-weight: 700; min-width: 0; }
.me .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); flex: none; }
#meName { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 32vw; }
.tier { font-size: 11px; font-weight: 600; color: var(--ink-soft); border: 1px solid var(--line); border-radius: 99px; padding: 1px 7px; }
.top-actions { display: flex; gap: 6px; }
.chip {
  border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 99px;
  padding: 6px 11px; font-size: 13px; white-space: nowrap;
}
.chip:disabled { opacity: .5; cursor: default; }
.chip.ghost { background: rgba(0, 0, 0, .35); color: #fff; border-color: rgba(255, 255, 255, .35); padding: 4px 12px; font-size: 16px; }

#steps {
  position: fixed; top: 48px; left: 0; right: 0; z-index: 39; margin: 0; padding: 6px 10px;
  display: flex; gap: 4px; list-style: none; overflow-x: auto; scrollbar-width: none;
  background: rgba(251, 250, 245, .78); border-bottom: 1px solid rgba(0, 0, 0, .04);
}
#steps li { flex: 1 0 auto; text-align: center; font-size: 11.5px; color: #9aa39c; padding: 3px 6px; border-radius: 99px; }
#steps li.done { color: var(--accent); }
#steps li.now { background: var(--accent); color: #fff; font-weight: 700; }


.screen { display: none; }
.screen.active { display: block; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 12px;
  padding: 11px 14px; font-size: 15px; font-weight: 600; text-decoration: none; min-height: 44px;
}
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.primary:disabled { background: #b9cf98; border-color: #b9cf98; cursor: default; }
.btn.big { width: 100%; font-size: 17px; min-height: 52px; }
.sheet {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 16px; margin: 12px 16px;
}
.sheet-title { font-size: 18px; font-weight: 800; margin-bottom: 12px; }
.field { display: block; }
.field span { display: block; font-size: 13px; color: var(--ink-soft); margin-bottom: 6px; }
.field input, textarea {
  width: 100%; font: inherit; font-size: 16px; padding: 11px 12px; border: 1px solid var(--line);
  border-radius: 10px; background: var(--paper);
}
.field input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.err { color: var(--danger); font-size: 13px; min-height: 18px; margin: 4px 0; }
.hint { color: var(--ink-soft); font-size: 12px; margin-top: 4px; }
.fine { color: var(--ink-soft); font-size: 12.5px; line-height: 1.5; margin: 10px 0 0; }
#entrySheet .btn.primary { width: 100%; }
.divider { display: flex; align-items: center; gap: 8px; margin: 16px 0 10px; color: var(--ink-soft); font-size: 12.5px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.sns { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.sns-btn { font-size: 13px; padding: 9px 4px; }

.sns-btn.google { background: #fff; border-color: #747775; color: #1f1f1f; }
.sns-btn.naver { background: #03a94d; border-color: #03a94d; color: #fff; }
.sns-btn.kakao { background: #fee500; border-color: #fee500; color: rgba(0, 0, 0, .85); }
.sns-btn.email { background: var(--paper-2); }
.guide { background: var(--gold-soft); border: 1px solid #f0dfa6; border-radius: 12px; padding: 12px 14px; margin-bottom: 12px; }
.guide-h { font-weight: 800; font-size: 13.5px; color: #8a6a14; margin: 2px 0 6px; }
.guide ul, .guide ol { margin: 0 0 8px; padding-left: 20px; line-height: 1.6; font-size: 14px; }
.guide p { margin: 0 0 4px; font-size: 14px; line-height: 1.55; }


#scrMap { padding-top: 0; }
#scrMap.active ~ * {}
body:has(#topbar:not(.hidden)) #scrMap { padding-top: 84px; }
.brand { padding: 18px 16px 6px; }
.brand-title { font-size: 26px; font-weight: 900; letter-spacing: -.5px; }
.brand-sub { font-size: 13px; color: var(--ink-soft); margin-top: 2px; }
body:has(#topbar:not(.hidden)) .brand { display: none; }
.map-wrap { margin: 8px 16px 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: #cfe3b5; }
.map-inner { position: relative; }
.map-inner img { display: block; width: 100%; height: auto; user-select: none; }
.marker {
  position: absolute; transform: translate(-50%, -50%); border: 0; background: none; padding: 0;
  width: 44px; height: 44px; display: grid; place-items: center;
}
.marker .pin { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 4px solid var(--gold); box-shadow: 0 0 0 3px rgba(255, 255, 255, .6), 0 0 18px rgba(255, 215, 90, .95); position: relative; z-index: 2; }
.marker .pulse { position: absolute; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 215, 90, .55); animation: pulse 1.8s ease-out infinite; }
.marker-label {
  position: absolute; left: 50%; top: 100%; transform: translateX(-30%); white-space: nowrap;
  background: var(--night); color: #ffe9a8; font-weight: 800; font-size: 12px; padding: 4px 9px; border-radius: 99px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
}
.marker.ready .pulse { background: rgba(127, 174, 60, .6); }
@keyframes pulse { 0% { transform: scale(.4); opacity: 1; } 100% { transform: scale(1.6); opacity: 0; } }


#scrFront.active { position: fixed; inset: 0; padding-top: 84px; overflow-y: auto; }
.front-bg {
  position: fixed; inset: 0; z-index: -1; background-size: cover; background-position: center 45%;
  filter: blur(2px) brightness(.85); transform: scale(1.04);
}
.front-sheet { max-width: 560px; margin: 8px auto 24px; margin-left: max(16px, calc(50% - 280px)); margin-right: max(16px, calc(50% - 280px)); }
.place-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.place-name { font-size: 20px; font-weight: 900; flex: 1; min-width: 0; }
.guide-voice {
  display: inline-flex; align-items: center; gap: 4px; border: 1px solid var(--line); background: #fff; color: var(--ink);
  border-radius: 99px; padding: 6px 10px; font-size: 12.5px; font-weight: 700; white-space: nowrap;
}
.guide-voice svg { width: 18px; height: 18px; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.guide-voice.playing { background: var(--accent); border-color: var(--accent); color: #fff; }
.guide-voice.playing svg { stroke: #fff; }
.guide-voice.playing .wave { animation: breathe 1s ease-in-out infinite; }
.guide-voice.nudge { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(201, 162, 74, .35); animation: hop .5s ease-in-out 3; }
.close-x { border: 0; background: var(--paper-2); color: var(--ink-soft); width: 32px; height: 32px; border-radius: 50%; font-size: 20px; line-height: 1; }
.notice {
  background: linear-gradient(180deg, #fffaf0, #fff3d6); border: 1px solid #f0d58f; border-radius: 12px;
  padding: 14px; font-size: 16px; line-height: 1.65; margin-bottom: 12px;
}
.notice b { color: #8a5a00; }
.notice.small { font-size: 14px; }
#btnEnter { width: 100%; }


#scrInside.active { position: fixed; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; background: var(--night); overflow: hidden; }
#pano, #panoFallback { position: absolute; inset: 0; z-index: 0; }
#panoFallback { background-size: auto 100%; background-repeat: repeat-x; animation: panPan 120s linear infinite; }
@keyframes panPan { from { background-position: 0 50%; } to { background-position: -200vh 50%; } }
.pnlm-container { background: var(--night) !important; }
.scene-hud {
  position: absolute; z-index: 5; top: 92px; right: 12px; display: flex; align-items: center; gap: 6px;
  color: #fff; font-size: 12.5px; text-shadow: 0 1px 3px rgba(0, 0, 0, .6);
}

#sky { position: absolute; left: 0; right: 0; top: 0; bottom: 40%; z-index: 6; pointer-events: none; overflow: hidden; }
#crowd {
  position: relative; z-index: 7; display: flex; justify-content: center; align-items: flex-end; gap: 6px;
  padding: 0 8px 6px; pointer-events: none;
}
.person { position: relative; display: flex; flex-direction: column; align-items: center; pointer-events: auto; width: 86px; }
.person .fig { width: 58px; height: 106px; }
.person.far .fig { width: 46px; height: 84px; opacity: .92; }
.person.me .fig { width: 66px; height: 120px; }
.pfig { width: 100%; height: 100%; overflow: visible; }
.pfig .upper { transform-origin: 30px 66px; transition: transform .3s; }
.pfig .armL { transform-origin: 15.5px 40px; }
.pfig .armR { transform-origin: 44.5px 40px; }

.tag {
  margin-top: -2px; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 2px 3px;
  max-width: 86px; background: rgba(15, 26, 53, .72); color: #fff; border-radius: 10px; padding: 2px 6px 3px; font-size: 11px;
}
.tag .nm { max-width: 64px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tag .add-friend { flex-basis: 100%; }
.tag.mine { background: var(--accent); padding: 2px 9px; font-weight: 700; }
.npc-mark { font-size: 8px; line-height: 1; padding: 1px 3px; border-radius: 4px; background: rgba(255, 255, 255, .25); color: #e8eef9; }
.add-friend { border: 0; background: rgba(255, 255, 255, .92); color: var(--night); border-radius: 99px; font-size: 10px; padding: 2px 6px; font-weight: 700; }
.bubble {
  position: absolute; bottom: 100%; left: 50%; transform: translate(-50%, 6px); opacity: 0; white-space: nowrap;
  background: #fff; color: var(--ink); font-weight: 700; font-size: 12px; padding: 4px 9px; border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .25); transition: all .25s; pointer-events: none;
}
.bubble.show { opacity: 1; transform: translate(-50%, -2px); }



.pfig .legs { transform-origin: 30px 104px; }
.a-bow .legs { animation: bowKnee 1.25s ease-in-out; }
.a-bow .upper { animation: bowUpper 1.25s ease-in-out; }
.a-bow .armL { animation: bowArmL 1.25s ease-in-out; }
.a-bow .armR { animation: bowArmR 1.25s ease-in-out; }
@keyframes bowKnee { 0%, 100% { transform: scaleY(1); } 35%, 65% { transform: scaleY(.45); } }
@keyframes bowUpper { 0%, 100% { transform: translateY(0) scaleY(1); } 35% { transform: translateY(21px) scaleY(.9); } 48%, 62% { transform: translateY(32px) scaleY(.5); } }
@keyframes bowArmL { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(150deg); } 48%, 62% { transform: rotate(20deg); } }
@keyframes bowArmR { 0%, 100% { transform: rotate(0); } 20% { transform: rotate(-150deg); } 48%, 62% { transform: rotate(-20deg); } }
.a-cheer .pfig { animation: hop .5s ease-in-out 3; }
.a-cheer .armL { animation: armUpL 1.5s ease-in-out; }
.a-cheer .armR { animation: armUpR 1.5s ease-in-out; }
@keyframes armUpL { 0%, 100% { transform: rotate(0); } 15%, 85% { transform: rotate(160deg); } }
@keyframes armUpR { 0%, 100% { transform: rotate(0); } 15%, 85% { transform: rotate(-160deg); } }
.a-clap .armL { animation: clapL .22s ease-in-out 6 alternate; }
.a-clap .armR { animation: clapR .22s ease-in-out 6 alternate; }
@keyframes clapL { from { transform: rotate(-30deg); } to { transform: rotate(-62deg); } }
@keyframes clapR { from { transform: rotate(30deg); } to { transform: rotate(62deg); } }
.a-like .pfig { animation: hop .45s ease-in-out 2; }
.a-like .armR { animation: armWave 1.2s ease-in-out; }
@keyframes armWave { 0%, 100% { transform: rotate(0); } 20%, 80% { transform: rotate(-130deg); } 50% { transform: rotate(-100deg); } }
@keyframes hop { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.float-icon {
  position: fixed; z-index: 60; transform: translate(-50%, 0); pointer-events: none; font-weight: 900;
  font-size: 22px; color: #ff5f7a; text-shadow: 0 2px 6px rgba(0, 0, 0, .35); animation: floatUp 1.5s ease-out forwards;
}
.float-icon.f-clap, .float-icon.f-cheer { color: #ffe27a; font-size: 18px; }
@keyframes floatUp { from { opacity: 1; transform: translate(-50%, 0) scale(.8); } to { opacity: 0; transform: translate(-50%, -90px) scale(1.25); } }


.panel {
  position: relative; z-index: 8; margin: 0 10px max(10px, env(safe-area-inset-bottom)); padding: 12px;
  background: rgba(255, 255, 255, .95); border-radius: 16px; box-shadow: 0 -4px 24px rgba(0, 0, 0, .25);
  max-width: 560px; align-self: center; width: calc(100% - 20px);
}
.panel-msg { font-size: 14.5px; font-weight: 700; margin-bottom: 8px; line-height: 1.5; }
.bow-dots { display: flex; gap: 8px; justify-content: center; margin: 4px 0 10px; }
.bow-dots i { width: 14px; height: 14px; border-radius: 50%; background: #e4e8de; border: 1px solid #cfd8c3; transition: background .3s; }
.bow-dots i.on { background: var(--gold); border-color: var(--gold); box-shadow: 0 0 10px rgba(201, 162, 74, .8); }
#bowCount { font-weight: 900; margin-left: 4px; }
.panel textarea { resize: none; font-size: 16px; }
.row { display: flex; gap: 14px; margin: 4px 0 8px; font-size: 14px; flex-wrap: wrap; }
.radio { display: inline-flex; align-items: center; gap: 4px; }
.radio input { accent-color: var(--accent); width: 18px; height: 18px; }
.offer { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--ink-soft); margin-bottom: 10px; flex-wrap: wrap; }
.soon-tag { background: var(--paper-2); border: 1px dashed #cfc7ad; color: #8a7a4a; border-radius: 8px; padding: 2px 8px; font-size: 12px; }
.acts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 8px; }
.act { flex-direction: column; gap: 2px; font-size: 13px; padding: 8px 4px; }
.act svg { width: 22px; height: 22px; fill: none; stroke: var(--ink); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.act[data-act="like"] svg { fill: #ff7a90; stroke: #ff7a90; }
.row2 { display: grid; grid-template-columns: 1fr auto; gap: 8px; }


#ceremony {
  position: absolute; inset: 0; z-index: 20; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(ellipse at 50% 45%, rgba(255, 244, 200, .55) 0%, rgba(30, 30, 70, .55) 55%, rgba(5, 8, 25, .85) 100%);
  opacity: 0; transition: opacity .8s;
}
#ceremony.on { opacity: 1; }
#ceremony.leave { opacity: 0; }
#ceremony .glow { position: absolute; left: 50%; top: 44%; width: 120vmin; height: 120vmin; transform: translate(-50%, -50%); background: radial-gradient(circle, rgba(255, 250, 220, .95) 0%, rgba(255, 220, 120, .35) 30%, rgba(255, 200, 80, 0) 60%); animation: breathe 3s ease-in-out infinite; }
#ceremony .rays {
  position: absolute; left: 50%; top: 44%; width: 160vmax; height: 160vmax; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, rgba(255, 235, 160, .22) 0deg 6deg, rgba(255, 235, 160, 0) 6deg 18deg);
  animation: spin 40s linear infinite; mask-image: radial-gradient(circle, #000 10%, transparent 55%); -webkit-mask-image: radial-gradient(circle, #000 10%, transparent 55%);
}
@keyframes spin { to { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes breathe { 0%, 100% { opacity: .85; } 50% { opacity: 1; } }
.sinin-wrap { position: relative; width: min(64vw, 300px); aspect-ratio: 220 / 260; margin-top: -6vh; }
#ceremony.on .sinin-wrap { animation: rise 1.6s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes rise { from { transform: translateY(60px) scale(.6); opacity: 0; filter: brightness(3); } to { transform: none; opacity: 1; filter: none; } }
.halo { position: absolute; left: 50%; top: 2%; width: 42%; aspect-ratio: 1; transform: translateX(-50%); border-radius: 50%; border: 5px solid rgba(255, 226, 122, .95); box-shadow: 0 0 30px 8px rgba(255, 226, 122, .8), inset 0 0 20px rgba(255, 226, 122, .7); animation: breathe 2s ease-in-out infinite; }
#sinin { position: absolute; inset: 0; }
#sinin svg, #sinin img, #sinin video { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 0 22px rgba(255, 240, 180, .95)); }
#ceremony.on .s-armL { transform-origin: 88px 100px; animation: openL 1.8s .6s ease-out both; }
#ceremony.on .s-armR { transform-origin: 132px 100px; animation: openR 1.8s .6s ease-out both; }
@keyframes openL { from { transform: rotate(-55deg); } to { transform: rotate(0); } }
@keyframes openR { from { transform: rotate(55deg); } to { transform: rotate(0); } }
.call {
  position: relative; z-index: 3; margin-top: 18px; padding: 10px 18px; border-radius: 14px; text-align: center;
  color: #fff8dc; font-size: clamp(20px, 5.6vw, 34px); font-weight: 900; line-height: 1.35; max-width: 92vw;
  text-shadow: 0 0 12px rgba(255, 200, 80, .95), 0 2px 4px rgba(0, 0, 0, .5);
}
#ceremony.on .call { animation: fadeIn 1s 1.3s both; }
.call b { color: #ffe27a; }
.voice-note { position: relative; z-index: 3; color: rgba(255, 255, 255, .8); font-size: 12px; margin-top: 4px; text-align: center; padding: 0 16px; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.angels { position: absolute; inset: 0; pointer-events: none; z-index: 2; }
.angel { position: absolute; top: var(--y); width: 64px; height: 56px; animation: var(--d) linear var(--delay) infinite; }
.angel svg, .angel img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 0 10px rgba(255, 255, 255, .9)); }
.angel .wing { transform-box: fill-box; animation: flap .35s ease-in-out infinite alternate; }
.angel .wl { transform-origin: right center; }
.angel .wr { transform-origin: left center; }
@keyframes flap { from { transform: scaleY(1); } to { transform: scaleY(.55); } }
.angel.fly0 { animation-name: fly0; } .angel.fly1 { animation-name: fly1; }
.angel.fly2 { animation-name: fly2; } .angel.fly3 { animation-name: fly3; }
@keyframes fly0 { 0% { left: -12%; transform: translateY(0); } 50% { transform: translateY(-30px); } 100% { left: 108%; transform: translateY(0); } }
@keyframes fly1 { 0% { left: 108%; transform: translateY(0) scaleX(-1); } 50% { transform: translateY(26px) scaleX(-1); } 100% { left: -12%; transform: translateY(0) scaleX(-1); } }
@keyframes fly2 { 0% { left: 10%; transform: translate(0, 0); } 25% { transform: translate(25vw, -40px); } 50% { transform: translate(55vw, 10px); } 75% { transform: translate(25vw, 40px); } 100% { left: 10%; transform: translate(0, 0); } }
@keyframes fly3 { 0% { left: 80%; transform: translate(0, 0) scaleX(-1); } 33% { transform: translate(-30vw, 50px) scaleX(-1); } 66% { transform: translate(-55vw, -30px) scaleX(-1); } 100% { left: 80%; transform: translate(0, 0) scaleX(-1); } }


.sky-lantern {
  position: absolute; bottom: 2%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center;
  animation: liftOff var(--d) ease-in forwards;
}
.sky-lantern svg, .sky-lantern img { width: 30px; height: 42px; filter: drop-shadow(0 0 10px rgba(255, 190, 90, .9)); }
.sky-lantern.mine svg, .sky-lantern.mine img { width: 56px; height: 78px; }
.sky-lantern .lt { margin-top: 2px; font-size: 11px; color: #fff; background: rgba(15, 26, 53, .55); padding: 2px 7px; border-radius: 8px; max-width: 150px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sky-lantern.mine .lt { font-size: 13px; font-weight: 700; max-width: 240px; background: rgba(127, 174, 60, .85); }
@keyframes liftOff {
  0% { transform: translate(-50%, 0) scale(1); opacity: 0; }
  6% { opacity: 1; }
  50% { transform: translate(calc(-50% + var(--sway)), -40vh) scale(.85); }
  100% { transform: translate(-50%, -85vh) scale(.55); opacity: 0; }
}

.sky-lantern.readable { pointer-events: auto; cursor: pointer; }
.sky-lantern svg, .sky-lantern img { transition: transform .4s, filter .4s; transform-origin: center bottom; }
.sky-lantern.glow1 svg, .sky-lantern.glow1 img { transform: scale(1.2); filter: drop-shadow(0 0 14px rgba(255, 200, 100, 1)); }
.sky-lantern.glow2 svg, .sky-lantern.glow2 img { transform: scale(1.45); filter: drop-shadow(0 0 20px rgba(255, 210, 110, 1)); }
.sky-lantern.glow3 svg, .sky-lantern.glow3 img { transform: scale(1.75); filter: drop-shadow(0 0 28px rgba(255, 225, 130, 1)) brightness(1.15); }
.sky-lantern.cheered .lt { background: rgba(201, 162, 74, .9); }


.hear-badge {
  position: relative; z-index: 3; margin-top: 14px; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(15, 26, 53, .7); color: #fff; border: 1px solid rgba(255, 226, 122, .6); border-radius: 99px; padding: 4px 12px; font-size: 13px; font-weight: 700;
}
.hear-badge svg { width: 16px; height: 16px; fill: none; stroke: #ffe27a; stroke-width: 2; stroke-linecap: round; }
.hear-badge + .call { margin-top: 6px; }
.voice-wait { position: relative; z-index: 3; color: #fff8dc; font-size: 14px; margin-top: 6px; display: flex; align-items: center; gap: 4px; }
.voice-wait span { width: 7px; height: 7px; border-radius: 50%; background: #ffe27a; animation: dotb 1s infinite ease-in-out; }
.voice-wait span:nth-child(2) { animation-delay: .15s; } .voice-wait span:nth-child(3) { animation-delay: .3s; margin-right: 4px; }
@keyframes dotb { 0%, 100% { opacity: .3; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-4px); } }
.scene-hud { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.wish-box-btn #wishStats { font-size: .86em; opacity: .85; margin-left: 2px; }
.wish-box { width: min(560px, 100%); }
.box-counts { font-size: 13.5px; color: var(--ink-soft); margin: 0 0 8px; line-height: 1.5; }
.box-counts b { color: var(--ink); }
.box-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; max-height: calc(100dvh - 220px); overflow-y: auto; }
.box-list li { border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; background: var(--paper); }
.box-list li.mine { border-color: var(--accent); background: #f6fbef; }
.box-list li.empty { text-align: center; color: var(--ink-soft); }
.bw-head { display: flex; align-items: baseline; gap: 6px; font-size: 13.5px; }
.bw-head small { margin-left: auto; color: var(--ink-soft); font-size: 11.5px; }
.bw-me { font-size: 11px; color: #4c7a1c; }
.bw-text { margin: 4px 0 0; font-size: 14.5px; line-height: 1.5; }
.bw-text.locked { color: var(--ink-soft); font-size: 13px; }
.bw-lock { display: inline-flex; align-items: center; gap: 3px; font-size: 11.5px; font-weight: 700; color: #8a6a14; background: var(--gold-soft); border-radius: 6px; padding: 1px 6px; }
.bw-lock svg { width: 12px; height: 12px; fill: none; stroke: #8a6a14; stroke-width: 2.2; }
.bw-acts { display: flex; align-items: center; gap: 6px; margin-top: 6px; font-size: 12.5px; color: var(--ink-soft); }
.bw-acts span { margin-right: auto; }
.wish-meta { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--ink-soft); margin-top: 3px; }
.call .bless { display: block; margin-top: 2px; color: #ffe27a; font-size: 1.12em; }
.call.bless-big .bless { font-size: 1.3em; }
.others-hear { position: relative; z-index: 3; color: rgba(255, 255, 255, .88); font-size: 12.5px; margin-top: 4px; text-align: center; padding: 0 16px; }
#ceremony.scold .call { color: #fff; text-shadow: 0 0 10px rgba(255, 140, 90, .9), 0 2px 4px rgba(0, 0, 0, .5); }
#ceremony.scold .rays { opacity: .4; }
.call .lv { display: inline-block; font-size: 12px; font-weight: 700; vertical-align: middle; color: #fff; background: rgba(192, 57, 43, .8); border-radius: 6px; padding: 1px 6px; text-shadow: none; }
.rec-tag { font-size: 10.5px; font-weight: 700; color: #7a5d10; background: var(--gold-soft); border: 1px solid #ecd48c; border-radius: 6px; padding: 0 5px; vertical-align: middle; }
.vis-help { font-size: 12.5px; color: var(--ink-soft); line-height: 1.5; margin: -2px 0 8px; }
.lt-wish { font-size: 17px; line-height: 1.6; background: var(--paper); border-radius: 10px; padding: 12px; margin: 0 0 8px; }
.lt-count { font-size: 13px; color: var(--ink-soft); margin-bottom: 10px; }
.row3 { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; }


.modal { position: fixed; inset: 0; z-index: 80; background: rgba(10, 14, 28, .6); display: grid; place-items: center; padding: 16px; }
.modal-box { background: #fff; border-radius: 16px; padding: 16px; width: min(420px, 100%); max-height: calc(100dvh - 32px); overflow: auto; box-shadow: var(--shadow); }
.modal-title { font-weight: 900; font-size: 18px; margin-bottom: 10px; }
#cardImg { width: 100%; max-height: calc(100dvh - 230px); object-fit: contain; border-radius: 10px; display: block; background: var(--night); aspect-ratio: 1080 / 1350; }
.card-tabs { display: flex; gap: 6px; margin-bottom: 8px; }
.card-tabs .chip.on { background: var(--accent); border-color: var(--accent); color: #fff; }
.charge-grid { display: grid; gap: 8px; margin-bottom: 10px; }
.charge-item { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; display: flex; justify-content: space-between; gap: 8px; background: var(--paper); opacity: .8; }
.charge-item span { color: var(--ink-soft); font-size: 13px; }
.toast {
  position: fixed; left: 50%; top: 96px; transform: translate(-50%, -10px); z-index: 90; opacity: 0; pointer-events: none;
  background: var(--night); color: #fff; padding: 10px 16px; border-radius: 12px; font-size: 14px; max-width: calc(100vw - 32px);
  text-align: center; transition: all .25s; box-shadow: 0 6px 18px rgba(0, 0, 0, .3);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }


@media (min-width: 900px) {
  #scrMap.active { display: grid; grid-template-columns: 1fr 380px; grid-template-rows: auto 1fr; align-items: start; max-width: 1400px; margin: 0 auto; }
  .brand { grid-column: 1 / -1; }
  .map-wrap { grid-column: 1; grid-row: 2; margin: 8px 8px 16px 24px; }
  #entrySheet, #mapGuide { grid-column: 2; grid-row: 2; margin: 8px 24px 16px 8px; }
  .person .fig { width: 72px; height: 132px; }
  .person.me .fig { width: 82px; height: 150px; }
  .person.far .fig { width: 58px; height: 106px; }
  #crowd { gap: 18px; }
  .person { width: 104px; }
  .tag { max-width: 104px; }
  .marker-label { font-size: 14px; }
  .sky-lantern svg, .sky-lantern img { width: 38px; height: 54px; }
  .sky-lantern.mine svg, .sky-lantern.mine img { width: 72px; height: 100px; }
}


#scrInside.active { position: fixed; inset: 0; display: block; background: #bfe0fb; overflow: hidden; }
#world { position: absolute; inset: 0; z-index: 0; touch-action: none; }
.world-canvas { width: 100%; height: 100%; display: block; }
#labels { position: absolute; inset: 0; z-index: 3; pointer-events: none; overflow: hidden; }
.w-label { position: absolute; left: 0; top: 0; will-change: transform; white-space: nowrap; }
.w-tag {
  display: flex; align-items: center; gap: 3px; background: rgba(15, 26, 53, .72); color: #fff; border-radius: 10px;
  padding: 2px 6px; font-size: 11px; pointer-events: auto;
}
.w-tag.mine { background: var(--accent); font-weight: 700; padding: 2px 9px; }
.w-tag .add-friend { margin-left: 2px; }
.w-bubble {
  background: #fff; color: var(--ink); font-weight: 700; font-size: 12px; padding: 4px 9px; border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .25); animation: fadeIn .2s both;
}
.w-float { font-weight: 900; font-size: 20px; color: #ff5f7a; text-shadow: 0 2px 6px rgba(0, 0, 0, .35); animation: floatUp3 1.5s ease-out forwards; }
.w-float.f-clap, .w-float.f-cheer { color: #ffe27a; font-size: 17px; }
@keyframes floatUp3 { from { opacity: 1; margin-top: 0; } to { opacity: 0; margin-top: -70px; } }
.w-note { background: rgba(15, 26, 53, .75); color: #ffe9a8; font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; }
.scene-hud { top: 92px; right: 10px; left: auto; z-index: 6; }
.walk-hint {
  position: absolute; z-index: 6; left: 50%; transform: translateX(-50%); bottom: calc(150px + env(safe-area-inset-bottom));
  background: rgba(15, 26, 53, .72); color: #fff; font-size: 13px; padding: 6px 12px; border-radius: 99px; width: max-content; max-width: calc(100vw - 32px); text-align: center;
}
#joy {
  position: absolute; z-index: 7; left: 22px; bottom: calc(22px + env(safe-area-inset-bottom)); width: 116px; height: 116px; border-radius: 50%;
  background: rgba(255, 255, 255, .28); border: 2px solid rgba(255, 255, 255, .7); box-shadow: 0 4px 16px rgba(0, 0, 0, .18); touch-action: none;
  display: grid; place-items: center;
}
#joyKnob { width: 52px; height: 52px; border-radius: 50%; background: rgba(255, 255, 255, .92); box-shadow: 0 2px 8px rgba(0, 0, 0, .25); pointer-events: none; }
#frontSheet {
  position: absolute; z-index: 8; left: 0; right: 0; bottom: 0; margin: 0 10px max(10px, env(safe-area-inset-bottom));
  max-height: calc(100% - 110px); overflow-y: auto; max-width: 560px; margin-left: auto; margin-right: auto;
}
@media (max-width: 580px) { #frontSheet { left: 10px; right: 10px; margin: 0 0 max(10px, env(safe-area-inset-bottom)); } }
.panel { position: absolute; z-index: 8; left: 0; right: 0; bottom: 0; margin: 0 auto max(10px, env(safe-area-inset-bottom)); }
.tap-hint { margin: 0 0 8px; text-align: center; }
.row3b { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; }

#ceremony {
  position: absolute; inset: 0; z-index: 9; pointer-events: none; display: flex; flex-direction: column; justify-content: flex-end; align-items: center;
  background: radial-gradient(ellipse at 50% 30%, rgba(255, 246, 200, .35) 0%, rgba(255, 240, 190, 0) 60%);
  padding-bottom: calc(26px + env(safe-area-inset-bottom));
}
.cer-box {
  display: flex; flex-direction: column; align-items: center; gap: 4px; max-width: min(720px, calc(100vw - 24px));
  background: rgba(15, 20, 45, .62); border: 1px solid rgba(255, 226, 122, .45); border-radius: 16px; padding: 12px 16px 14px;
}
#ceremony .call { margin-top: 2px; font-size: clamp(18px, 4.8vw, 30px); }
#ceremony .hear-badge { margin-top: 0; }
#panoView { position: absolute; inset: 0; z-index: 30; background: var(--night); }
#panoView #pano, #panoView #panoFallback { position: absolute; inset: 0; }

.music-fab { position: absolute; z-index: 10; top: 92px; left: 10px; display: inline-flex; align-items: center; gap: 5px; font-size: 13px; padding: 5px 11px; }
.music-fab svg { width: 16px; height: 16px; fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.music-fab.on { background: rgba(127, 174, 60, .85); border-color: rgba(255, 255, 255, .7); }
.music-panel {
  position: absolute; z-index: 11; top: 130px; left: 10px; width: min(330px, calc(100vw - 20px)); max-height: calc(100% - 290px); overflow-y: auto;
  background: rgba(255, 255, 255, .96); border-radius: 14px; box-shadow: var(--shadow); padding: 10px 12px; font-size: 13.5px;
}
.mp-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.mp-modes { display: grid; gap: 4px; }
.mm { display: flex; align-items: center; gap: 6px; padding: 5px 4px; border-radius: 8px; }
.mm input { accent-color: var(--accent); width: 17px; height: 17px; }
.mm.off { color: #9aa39c; }
.mm.sel { background: #f1f8e6; }
.music-fab svg { color: #fff; }
.music-fab.blocked { background: #c9a24a; border-color: #fff; animation: hop .6s ease-in-out infinite; }
.mp-now b { color: var(--ink); } .mp-now b.warn { color: #b26a00; }
.eq { display: inline-flex; align-items: flex-end; gap: 2px; height: 12px; margin-right: 5px; vertical-align: -1px; }
.eq i { width: 3px; background: var(--accent); animation: eqb .8s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: .2s; } .eq i:nth-child(3) { animation-delay: .4s; }
@keyframes eqb { 0%, 100% { height: 3px; } 50% { height: 12px; } }
#music-on-tip { display: none; }

.pano-intro { display: none; }
#panoView.intro .pano-intro {
  display: flex; flex-direction: column; align-items: center; gap: 6px; position: absolute; z-index: 6; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom));
  transform: translateX(-50%); width: min(520px, calc(100% - 24px)); background: rgba(15, 20, 45, .66); border: 1px solid rgba(255, 226, 122, .5);
  border-radius: 16px; padding: 12px 16px 14px; color: #fff; text-align: center;
}
#panoView.intro #btnPanoClose { display: none; }
.pi-title { font-weight: 900; font-size: 18px; color: #ffe9a8; }
.pi-sub { font-size: 13px; opacity: .9; }
.pi-pray { width: 100%; min-height: 54px; font-size: 20px; letter-spacing: 2px; margin-top: 4px; box-shadow: 0 0 0 3px rgba(255, 226, 122, .35), 0 6px 18px rgba(0, 0, 0, .3); }
@media (orientation: landscape) and (max-height: 520px) { .pi-sub { display: none; } .pi-pray { min-height: 44px; font-size: 17px; } }

.music-fab, .music-panel, .yt-box { z-index: 36; }
.yt-box.big { z-index: 45; }
.mp-nowrow { display: flex; align-items: center; gap: 8px; margin: 8px 0 6px; }
.mp-now { flex: 1; min-width: 0; color: var(--ink-soft); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mp-big { min-height: 42px; padding: 8px 12px; font-size: 14px; }
.mp-ctrl { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 6px; margin-bottom: 8px; }
.mp-rep[data-rep="off"] { color: var(--ink-soft); }
.mp-rep[data-rep="one"], .mp-rep[data-rep="all"] { border-color: var(--accent); color: #4c7a1c; }
.mp-list .no { display: inline-block; width: 20px; color: var(--ink-soft); font-size: 12px; }
.mp-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
.mp-list li { display: flex; align-items: center; gap: 6px; background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 2px 6px; }
.mp-list li.now { border-color: var(--accent); background: #f1f8e6; }
.mp-list li.dragging { opacity: .6; box-shadow: var(--shadow); }
.mp-list .grip { cursor: grab; touch-action: none; padding: 4px 6px; color: var(--ink-soft); font-size: 16px; user-select: none; }
.mp-list .tt { flex: 1; text-align: left; border: 0; background: none; padding: 9px 0; font-size: 14px; min-height: 40px; }

.mp-list li { flex-wrap: wrap; }
.mp-list .yt-blk { flex-basis: 100%; padding: 0 0 6px 30px; font-size: 12px; color: #9a5b00; }
.mp-list .yt-blk a, .mp-note a { color: #2a6db0; font-weight: 700; }
.mp-note { margin: 4px 0 8px; padding: 6px 9px; border-radius: 8px; background: #fff6e0; color: #6b4a00; font-size: 12.5px; line-height: 1.45; }

.mini-map {
  position: absolute; z-index: 6; top: 130px; right: 10px; width: 118px; aspect-ratio: 16 / 9; padding: 0; border: 2px solid #fff;
  border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); background: #cfe3b5;
}
.mini-map img, .map-big-inner img { display: block; width: 100%; height: 100%; object-fit: cover; user-select: none; }
.mini-map .mm-place, .map-big-inner .mm-place { position: absolute; transform: translate(-50%, -50%); border: 0; background: none; padding: 0; display: flex; align-items: center; gap: 3px; }
.mm-place .dot { width: 8px; height: 8px; border-radius: 50%; background: #3fbf3f; box-shadow: 0 0 0 2px #fff; display: block; }
.mm-place .lock { width: 10px; height: 10px; display: grid; place-items: center; background: rgba(15, 26, 53, .7); border-radius: 3px; }
.mm-place .lock svg { width: 8px; height: 8px; fill: none; stroke: #fff; stroke-width: 2.4; }
.mini-map .mm-place { pointer-events: none; }
.mm-me { position: absolute; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: #e8423a; box-shadow: 0 0 0 2px #fff; animation: pulseMe 1.4s infinite; }
@keyframes pulseMe { 0%, 100% { box-shadow: 0 0 0 2px #fff, 0 0 0 2px rgba(232, 66, 58, .5); } 50% { box-shadow: 0 0 0 2px #fff, 0 0 0 7px rgba(232, 66, 58, 0); } }
.mm-pt { position: absolute; width: 7px; height: 7px; margin: -3.5px 0 0 -3.5px; border-radius: 50%; }
.mm-angels { background: #fff; box-shadow: 0 0 6px #fff; } .mm-sinin_walk { background: #ffd34d; } .mm-friends { background: #4aa3ff; }
.map-big-box { width: min(980px, 100%); }
.map-big-inner { position: relative; width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; }

.mini-map .mm-place.soon { display: none; }
.map-big-inner .mm-place.soon span { display: none; }
.map-big-inner .mm-place.soon:hover span, .map-big-inner .mm-place.soon:focus-visible span { display: inline; position: relative; z-index: 3; }
.map-big-inner .mm-place.soon:hover { z-index: 3; }
.map-big-inner .mm-place .dot { width: 14px; height: 14px; }
.map-big-inner .mm-place .lock { width: 16px; height: 16px; } .map-big-inner .mm-place .lock svg { width: 12px; height: 12px; }
.map-big-inner .mm-place span { background: rgba(15, 26, 53, .78); color: #fff; font-size: 11px; padding: 1px 6px; border-radius: 6px; white-space: nowrap; }
.map-big-inner .mm-place.open span { background: #3a9a3a; font-weight: 700; }
.map-big-inner .mm-me { width: 16px; height: 16px; margin: -8px 0 0 -8px; }
.map-big-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 4px; }
.map-big-list button { width: 100%; text-align: left; border: 1px solid var(--line); background: var(--paper); border-radius: 8px; padding: 7px 8px; font-size: 13px; }
.map-big-list li.open button { border-color: var(--accent); background: #f1f8e6; }
.map-big-list .no { display: inline-block; min-width: 20px; color: var(--ink-soft); font-size: 11px; }
.map-big-list small { color: var(--ink-soft); }
.open-tag { color: #3a8a1a; font-size: 12px; }
@media (min-width: 900px) { .mini-map { width: 210px; } }


.yt-box { position: absolute; z-index: 10; top: 130px; left: 10px; width: 176px; background: #000; border-radius: 10px; overflow: hidden; box-shadow: var(--shadow); }
.yt-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.yt-frame iframe, #ytPlayer { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.yt-bar { display: flex; align-items: center; gap: 4px; padding: 4px; background: rgba(15, 26, 53, .92); }
.yt-title { flex: 1; min-width: 0; color: #fff; font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.yt-bar .chip { padding: 3px 7px; font-size: 11px; }
.yt-box.big { z-index: 40; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(92vw, 860px); }
body.yt-on .music-panel { top: 268px; max-height: calc(100% - 430px); }
@media (min-width: 900px) { .yt-box { width: 256px; } body.yt-on .music-panel { top: 318px; } }
.pano-hud { position: absolute; z-index: 5; top: 92px; right: 10px; display: flex; align-items: center; gap: 6px; color: #fff; font-size: 12.5px; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); flex-wrap: wrap; justify-content: flex-end; }


:root { --top: 92px; --yth: 138px; --sl: env(safe-area-inset-left, 0px); --sr: env(safe-area-inset-right, 0px); }
body.in-game { background: #0b1226; overflow: hidden; }
.scene-hud { top: var(--top); right: calc(10px + var(--sr)); }
.music-fab { top: var(--top); left: calc(10px + var(--sl)); }
.pano-hud { top: var(--top); }
.mini-map { top: calc(var(--top) + 38px); right: calc(10px + var(--sr)); }
.yt-box { top: calc(var(--top) + 38px); left: calc(10px + var(--sl)); }
.music-panel { top: calc(var(--top) + 38px); left: calc(10px + var(--sl)); max-height: calc(100% - var(--top) - 50px); }
body.yt-on .music-panel { top: calc(var(--top) + 46px + var(--yth)); max-height: calc(100% - var(--top) - var(--yth) - 58px); }
#joy { left: calc(22px + var(--sl)); }

.dongja-face {
  position: fixed; z-index: 40; left: calc(14px + var(--sl)); bottom: calc(150px + env(safe-area-inset-bottom));
  width: clamp(110px, 17vmin, 180px); aspect-ratio: 1; border-radius: 50%; overflow: hidden;
  background: radial-gradient(circle at 50% 40%, rgba(255, 246, 214, .95), rgba(232, 222, 190, .9)); border: 3px solid #fff; box-shadow: 0 6px 20px rgba(0, 0, 0, .28);
  animation: fadeIn .25s both;
}
.dongja-face video { width: 100%; height: 100%; object-fit: cover; display: block; }
.dongja-face .close-x { position: absolute; top: 4px; right: 4px; width: 26px; height: 26px; border-radius: 50%; background: rgba(15, 26, 53, .6); color: #fff; border: 0; font-size: 16px; line-height: 1; }
@media (orientation: landscape) and (max-height: 520px) { .dongja-face { bottom: 118px; width: 104px; } }
.rotate-tip {
  position: absolute; z-index: 12; left: 10px; right: 10px; top: calc(var(--top) + 38px); display: flex; align-items: center; gap: 8px;
  background: rgba(15, 26, 53, .9); color: #fff; border-radius: 12px; padding: 8px 10px; font-size: 13px; line-height: 1.4;
}
.rotate-tip svg { width: 26px; height: 26px; flex: none; fill: none; stroke: #ffe27a; stroke-width: 1.8; stroke-linecap: round; animation: tilt 2s ease-in-out infinite; }
.rotate-tip .chip { flex: none; }
@keyframes tilt { 0%, 30% { transform: rotate(0); } 60%, 100% { transform: rotate(-90deg); } }
@media (min-width: 900px) { :root { --yth: 182px; } }
@media (orientation: portrait) { .mini-map, .rotate-tip { top: calc(var(--top) + 76px); } }

@media (orientation: landscape) {
  #scrInside.active { inset: 0; width: auto; height: auto; transform: none; }
  #scrInside .panel, #scrInside #frontSheet {
    left: auto; right: calc(8px + var(--sr)); top: calc(var(--top) + 40px); bottom: 8px; width: min(380px, 46%);
    margin: 0; max-width: none; max-height: none; overflow-y: auto; align-self: auto;
  }
  body.panel-open .mini-map { display: none; }
  .walk-hint { bottom: 16px; left: auto; right: 16px; transform: none; max-width: 46%; }
  #ceremony { padding-bottom: 14px; }
  .cer-box { max-width: min(720px, 80%); }
}

@media (orientation: landscape) and (max-height: 520px) {
  :root { --top: 46px; --yth: 112px; }
  #topbar { height: 40px; }
  #steps { display: none !important; }
  body:has(#topbar:not(.hidden)) #scrMap { padding-top: 48px; }
  .chip { padding: 4px 9px; font-size: 12px; }
  .chip.ghost { font-size: 12px; padding: 4px 10px; }
  .mini-map { width: 104px; }
  .yt-box { width: 150px; }
  #joy { width: 96px; height: 96px; bottom: 12px; }
  #joyKnob { width: 44px; height: 44px; }
  #scrInside .panel, #scrInside #frontSheet { padding: 10px; font-size: 13px; }
  .panel-msg { font-size: 13px; margin-bottom: 6px; }
  .btn.big { min-height: 44px; font-size: 15px; }
  .btn { min-height: 38px; padding: 8px 10px; font-size: 13.5px; }
  .notice { font-size: 14px; padding: 10px; }
  .guide ul, .guide p { font-size: 13px; }
  .acts .act { padding: 5px 4px; }
  .cer-box { padding: 8px 12px 10px; }
  #ceremony .call { font-size: clamp(16px, 3.6vw, 24px); }
  .walk-hint { font-size: 12px; padding: 5px 10px; }
  .toast { top: 54px; }
}


#scrMap.active { display: block !important; position: fixed; inset: 0; padding: 0 !important; overflow: hidden; background: #8cc06a; max-width: none; margin: 0; } 
.map-stage { position: absolute; inset: 0; overflow: hidden; touch-action: none; cursor: grab; }
.map-stage.dragging { cursor: grabbing; }
.map-pan { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.map-pan img { display: block; width: 100%; height: 100%; user-select: none; -webkit-user-drag: none; pointer-events: none; }

.map-spots { position: absolute; inset: 0; pointer-events: none; }
.map-stage.over { cursor: pointer; }
.spot { position: absolute; transform: translate(-50%, -50%); border: 0; background: none; padding: 0; border-radius: 50%; pointer-events: none; outline: none; }
.spot .hring { position: absolute; inset: 0; border-radius: 50%; border: 3px solid rgba(240, 212, 130, 0); background: rgba(240, 212, 130, 0); transition: border-color .25s, background .25s, box-shadow .25s; }
.spot.hov .hring, .spot:focus-visible .hring { border-color: rgba(246, 222, 150, .95); background: rgba(246, 222, 150, .12); box-shadow: 0 0 22px rgba(246, 222, 150, .5); }

.spot .plate { position: absolute; inset: -60%; border-radius: 50%; border: 0;
  background: radial-gradient(closest-side, rgba(255, 244, 190, .12) 35%, rgba(255, 240, 170, .62) 68%, rgba(255, 236, 160, .26) 88%, rgba(255, 236, 160, 0) 100%);
  box-shadow: 0 0 26px 4px rgba(255, 238, 160, .55), 0 0 6px rgba(255, 190, 60, .6); opacity: .8; animation: plateGlow 4.6s ease-in-out infinite; }
@keyframes plateGlow { 0%, 100% { opacity: .42; } 50% { opacity: .95; } }
.cmark { position: absolute; width: 58px; height: 58px; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none; }
.cmark .ring { position: absolute; inset: 6px; border-radius: 50%; border: 2px solid rgba(255, 211, 77, .78); background: rgba(255, 211, 77, .08); box-shadow: 0 0 10px rgba(255, 211, 77, .45); }
.cmark .pulse { display: none; }
.cmark::after { content: ''; position: absolute; left: 80%; top: -14%; width: 30px; height: 30px; background: linear-gradient(135deg, #fff3bd, #e6b94a);
  clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%); filter: drop-shadow(0 0 3px rgba(255, 214, 110, .9)); }
.map-labels { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 3; }
.nm { position: absolute; left: 0; top: 0; white-space: nowrap; pointer-events: none; will-change: transform, opacity; line-height: 1; letter-spacing: .01em;
  font-size: 11.5px; font-weight: 600; color: #f8f1d6; padding: 3px 9px 4px; border-radius: 99px;
  background: linear-gradient(180deg, rgba(26, 44, 32, .64), rgba(12, 24, 18, .64)); border: 1px solid rgba(226, 196, 120, .55);
  box-shadow: 0 1px 6px rgba(0, 0, 0, .28); text-shadow: 0 1px 2px rgba(0, 0, 0, .55);
  opacity: 0; animation: nmFade 4.4s ease-in-out infinite; animation-delay: var(--d, 0s); }
.nm small { display: none; font-weight: 500; opacity: .86; margin-left: 2px; font-size: .92em; }
@keyframes nmFade { 0%, 100% { opacity: 0; } 30%, 70% { opacity: .78; } }

.nm.open { font-size: 13px; color: #fff6d0; border-color: rgba(255, 217, 120, .92); background: linear-gradient(180deg, rgba(40, 62, 28, .78), rgba(22, 40, 18, .78));
  overflow: hidden; opacity: 0; animation: nmOpen 4.4s ease-in-out infinite; animation-delay: var(--d, 0s); }
@keyframes nmOpen { 0%, 100% { opacity: 0; box-shadow: 0 0 0 rgba(255, 214, 110, 0); } 9% { opacity: .96; box-shadow: 0 0 14px rgba(255, 214, 110, .7); } 30%, 70% { opacity: .86; box-shadow: 0 0 5px rgba(255, 214, 110, .25); } }
.nm.open::after { content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(100deg, transparent 36%, rgba(255, 242, 190, .72) 50%, transparent 64%) 130% 0 / 260% 100% no-repeat; animation: nmSheen 4.4s ease-out infinite; animation-delay: var(--d, 0s); }
@keyframes nmSheen { 0% { background-position: 130% 0; } 24% { background-position: -30% 0; } 100% { background-position: -30% 0; } }
.nm.hot { animation: none; opacity: 1; font-size: 13px; z-index: 2; background: rgba(14, 26, 20, .9); border-color: rgba(246, 218, 140, .97); box-shadow: 0 2px 12px rgba(0, 0, 0, .4), 0 0 12px rgba(246, 218, 140, .35); }
.nm.hot small { display: inline; }
.map-stage.tiny .nm:not(.open):not(.hot) { font-size: 9.5px; padding: 2px 6px 3px; }
.map-stage.zoomed .nm:not(.hot) { animation: none; opacity: .92; } 
.map-stage.zoomed .nm.open::after, .nm.hot::after { display: none; }
@media (prefers-reduced-motion: reduce) { 
  .nm, .nm.open { animation: none !important; }
  .nm.open::after { display: none; }
  .nm { opacity: .62; font-size: 10.5px; }
  .nm.open { opacity: .9; font-size: 12px; box-shadow: 0 0 6px rgba(255, 214, 110, .3); }
  .nm.hot { opacity: 1; font-size: 12.5px; }
  .spot .plate, .cmark .pulse { animation: none !important; }
  .spot .plate { opacity: .75; }
}
.map-brand { position: absolute; z-index: 5; left: calc(12px + var(--sl)); bottom: 14px; background: rgba(255, 255, 255, .88); border-radius: 99px; padding: 5px 12px; font-size: 13px; box-shadow: var(--shadow); }
.map-brand span { color: var(--ink-soft); font-size: 12px; }
.map-zoom { position: absolute; z-index: 5; left: calc(12px + var(--sl)); bottom: 52px; display: flex; flex-direction: column; gap: 6px; }
.map-zoom .chip { width: 40px; height: 40px; padding: 0; font-size: 20px; font-weight: 700; box-shadow: var(--shadow); }
.entry-float {
  position: absolute; z-index: 20; right: calc(14px + var(--sr)); top: 60px; width: min(360px, 44%); max-height: calc(100% - 76px); overflow-y: auto;
  margin: 0 !important; background: rgba(255, 255, 255, .95);
}
body:not(:has(#topbar:not(.hidden))) .entry-float { top: 14px; }
.entry-float.small { width: min(320px, 44%); }
@media (orientation: portrait) {
  .entry-float, .entry-float.small { left: 10px; right: 10px; top: auto; bottom: 10px; width: auto; max-height: 52%; }
  .map-zoom { bottom: auto; top: 96px; }
  .map-brand { bottom: auto; top: 60px; }
}
@media (orientation: landscape) and (max-height: 520px) {
  .entry-float { top: 50px; max-height: calc(100% - 60px); padding: 10px; }
  .entry-float .sheet-title { font-size: 15px; margin-bottom: 6px; }
  .entry-float .fine { display: none; }
  .entry-float .divider { margin: 8px 0 6px; }
}


.spot.prev .hring { border-style: dashed; } 
.pv-modal { z-index: 95; padding: 12px; }
.pv-box { position: relative; background: var(--paper); border-radius: 16px; width: min(560px, 100%); max-height: calc(100dvh - 24px); overflow: auto; box-shadow: var(--shadow); }
.pv-pic { position: relative; background: #e9e5d6; }
.pv-pic img { display: block; width: 100%; aspect-ratio: 16 / 9; max-height: 40dvh; object-fit: cover; border-radius: 16px 16px 0 0; }
.pv-badge { position: absolute; left: 8px; top: 8px; max-width: calc(100% - 64px); background: rgba(15, 26, 53, .82); color: #fff; font-size: 12.5px; font-weight: 700; line-height: 1.35; padding: 5px 10px; border-radius: 10px; }
.pv-credit { position: absolute; right: 8px; bottom: 8px; max-width: calc(100% - 16px); background: rgba(0, 0, 0, .6); color: #fff; font-size: 11.5px; padding: 3px 8px; border-radius: 8px; }
.pv-close { position: absolute; right: 8px; top: 8px; width: 38px; height: 38px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); color: var(--ink); font-size: 17px; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .25); }
.pv-body { padding: 14px 16px 16px; }
.pv-place { font-size: 12.5px; color: var(--ink-soft); margin-bottom: 2px; }
.pv-title { margin: 0 0 8px; font-size: 21px; font-weight: 900; word-break: keep-all; }
.pv-lines { margin: 0; padding-left: 18px; font-size: 15.5px; line-height: 1.6; word-break: keep-all; }
.pv-lines li { margin-bottom: 6px; }
.pv-note { margin: 10px 0 12px; padding: 8px 10px; background: var(--gold-soft); border: 1px dashed #d8c27a; border-radius: 10px; font-size: 13px; color: #6a5a24; word-break: keep-all; }
.pv-more-t { font-size: 12.5px; color: var(--ink-soft); margin-bottom: 6px; }
.pv-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.pv-chip { border: 1px solid var(--line); background: #fff; border-radius: 99px; padding: 6px 11px; font-size: 13px; cursor: pointer; color: var(--ink); }
.pv-chip.on { background: var(--accent); border-color: var(--accent); color: #fff; font-weight: 700; }
.pv-ok { width: 100%; }
.pv-go { width: 100%; margin: 6px 0 4px; min-height: 48px; } 
.pv-go.hidden { display: none; }
@media (max-width: 580px) {
  .pv-modal { align-items: end; padding: 8px; }
  .pv-box { max-height: calc(100dvh - 16px); }
}
@media (orientation: landscape) and (max-height: 520px) {
  .pv-box { width: min(820px, 100%); display: grid; grid-template-columns: 44% 1fr; max-height: calc(100dvh - 16px); overflow: hidden; }
  .pv-pic img { height: 100%; aspect-ratio: auto; border-radius: 16px 0 0 16px; }
  .pv-body { overflow-y: auto; max-height: calc(100dvh - 16px); padding: 10px 12px; }
  .pv-lines { font-size: 14px; line-height: 1.5; }
}

.ar-box .pv-pic img { max-height: 28dvh; }
.ar-sub { margin: 0 0 10px; font-size: 14px; color: var(--ink-soft); word-break: keep-all; }
.ar-list { list-style: none; margin: 0 0 10px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ar-game { display: flex; flex-direction: column; gap: 2px; min-height: 58px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 12px; background: linear-gradient(180deg, #fff, var(--paper-2)); color: var(--ink); text-decoration: none; word-break: keep-all; }
.ar-game b { font-size: 15.5px; }
.ar-game small { font-size: 12.5px; color: var(--ink-soft); line-height: 1.35; }
.ar-game.here { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.ar-game:hover, .ar-game:focus-visible { border-color: var(--accent); }
.ar-note { margin: 0 0 12px; font-size: 12.5px; color: var(--ink-soft); word-break: keep-all; }

.ar-soon { display: flex; flex-direction: column; gap: 2px; min-height: 58px; padding: 9px 11px; border: 1px dashed var(--line); border-radius: 12px; background: var(--paper-2); color: var(--ink-soft); word-break: keep-all; cursor: default; opacity: .8; }
.ar-soon b { font-size: 15.5px; }
.ar-soon small { font-size: 12.5px; line-height: 1.35; }
@media (max-width: 360px) { .ar-list { grid-template-columns: 1fr; } }
@media (orientation: landscape) and (max-height: 520px) {
  .ar-box .pv-pic img { max-height: none; }
  .ar-game { min-height: 0; padding: 7px 9px; }
}



.hn-back { position: absolute; left: 8px; top: 8px; z-index: 3; }
.pv-pic .pv-badge { top: 56px; }
.pv-close { background: var(--hn-glass); border: 1px solid var(--hn-gold); color: var(--hn-ink); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
@media (pointer: coarse) { .pv-close { width: 44px; height: 44px; } }

#topbar .chip { position: relative; border-color: var(--hn-gold); background: linear-gradient(180deg, #fffdf6, #f5eed9); color: #4a3b12; font-weight: 600; letter-spacing: .02em; box-shadow: 0 1px 4px rgba(120, 90, 20, .12); }
#topbar .chip::after { content: ''; position: absolute; inset: -6px -3px; }
#topbar .chip { min-height: 36px; padding: 6px 14px; font-size: 13.5px; }
@media (orientation: landscape) and (max-height: 520px) { #topbar .chip { min-height: 32px; padding: 4px 12px; font-size: 13px; } }
@media (max-width: 420px) { #topbar .chip { padding: 6px 11px; font-size: 13px; } #topbar .tier { display: none; } #meName { max-width: 40vw; } }
#btnMap { display: none; }
body.in-game #btnMap { display: inline-block; }

.ar-hall { width: 100%; margin: 0 0 4px; background: linear-gradient(180deg, #27324f, #121a2e); }
.ar-join .hgt-join { margin: 8px 0 12px; }
.entry-float .hgt-join, #mapGuide .hgt-join { margin-top: 8px; padding: 6px 10px; }
.entry-float .hgt-join .a, #mapGuide .hgt-join .a { color: #7a5a14; }
.entry-float .hgt-join .b, #mapGuide .hgt-join .b { color: #6a6354; }
.entry-float .hgt-join { background: linear-gradient(100deg, rgba(201, 162, 74, .08) 0%, rgba(255, 226, 140, .38) 45%, rgba(201, 162, 74, .08) 90%) 0 0 / 220% 100%; }
@media (orientation: landscape) and (max-height: 520px) { .entry-float .hgt-join .b { display: none; } }


html.gf-open, html.gf-open body { overflow: hidden; }
.gf { position: fixed; inset: 0; z-index: 120; display: flex; flex-direction: column; background: #0b1120; }
.gf-bar {
  flex: none; display: flex; align-items: center; gap: 8px; height: 56px; padding: 6px max(10px, env(safe-area-inset-right)) 6px max(10px, env(safe-area-inset-left));
  background: linear-gradient(180deg, #1b2540, #0f1729); border-bottom: 1px solid var(--hn-gold);
}
.gf-bar .hn-btn { min-height: 40px; padding: 0 14px; background: linear-gradient(180deg, rgba(60, 74, 104, .6), rgba(26, 36, 58, .6)); }
.gf-title { flex: 1; min-width: 0; text-align: center; color: #f1e4bb; font-size: 14px; font-weight: 700; letter-spacing: .06em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gf-stage { position: relative; flex: 1; min-height: 0; background: #000; }
.gf-stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; background: #fff; }
.gf-wait { position: absolute; inset: 0; display: grid; place-items: center; padding: 20px; text-align: center; color: #e9dcb4; background: #0b1120; font-size: 14px; line-height: 1.6; pointer-events: none; word-break: keep-all; }
@media (max-width: 560px) {
  .gf-bar { gap: 6px; padding-left: max(8px, env(safe-area-inset-left)); padding-right: max(8px, env(safe-area-inset-right)); justify-content: space-between; }
  .gf-bar .hn-btn { padding: 0 11px; font-size: 13px; }
  .gf-title { display: none; }
}
@media (pointer: coarse) { .gf-bar .hn-btn { min-height: 44px; } }
@media (orientation: landscape) and (max-height: 520px) {
  .gf-bar { height: 48px; padding-top: 3px; padding-bottom: 3px; }
  .gf-bar .hn-btn, .hn-btn { min-height: 40px; }
}


.gd, .gd-sheet, #scrInside .panel, #scrInside #frontSheet {
  background: var(--hn-glass); border: 1px solid var(--hn-gold); border-radius: 16px; color: var(--hn-ink);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  box-shadow: 0 6px 22px rgba(0, 0, 0, .30), inset 0 0 0 1px rgba(255, 255, 255, .07);
}
.gd { padding: 8px 10px; }
.gd .gd-say { display: none; padding: 2px 4px 8px; font: 500 13.5px/1.5 var(--hn-sans); word-break: keep-all; }
.gd .gd-say b { color: #f0d890; }
.gd.say-on .gd-say, .gd.open .gd-say { display: block; }
.gd .gd-more { display: none; padding: 0 4px 8px; }
.gd.open .gd-more { display: block; }
.gd-row { display: flex; align-items: center; gap: 8px; }
.gd .btn.primary, #scrInside .panel .btn.primary {
  border: 1px solid #f0d890; background: linear-gradient(180deg, #e2c27a, #b88f36); color: #2b2008; font-weight: 700; border-radius: 999px;
}
.gd .btn.primary:hover, #scrInside .panel .btn.primary:hover { background: linear-gradient(180deg, #ecd08e, #c79d40); }
.gd .btn.primary:disabled, #scrInside .panel .btn.primary:disabled { background: linear-gradient(180deg, #8c8466, #6b6448); border-color: #8c8466; color: #d8d2bb; }
.gd-go { flex: 1; min-width: 0; min-height: 44px; }

.go-chips { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.go-chip {
  min-height: 36px; padding: 0 10px; border-radius: 999px; border: 1px solid rgba(201, 162, 74, .75);
  background: rgba(20, 28, 44, .55); color: var(--hn-ink); font: 600 13px/1 var(--hn-sans); white-space: nowrap; cursor: pointer;
}

#mapGuide.open .gd-x { position: absolute; top: 8px; right: 8px; }
#mapGuide.open .gd-say { padding-right: 40px; }
.go-chip:hover, .go-chip:focus-visible { border-color: #f0d890; background: rgba(40, 52, 78, .8); outline: none; }
.go-chip.open::before { content: ''; display: inline-block; width: 6px; height: 6px; margin: 0 6px 1px 0; border-radius: 50%; background: #f0d890; vertical-align: middle; } 
#mapGuide .gd-row { align-items: flex-start; }
.gd-i, .gd-x, .gd-fold {
  position: relative; flex: none; width: 36px; height: 36px; padding: 0; border-radius: 50%; border: 1px solid var(--hn-gold);
  background: rgba(20, 28, 44, .55); color: var(--hn-ink); font: italic 700 16px/1 var(--hn-serif); cursor: pointer;
}
.gd-x { font: 400 20px/1 var(--hn-sans); }
.gd-i:hover, .gd-x:hover, .gd-fold:hover, .gd-i:focus-visible, .gd-x:focus-visible, .gd-fold:focus-visible { border-color: #f0d890; background: rgba(40, 52, 78, .8); outline: none; }
.gd-i[aria-expanded="true"] { background: linear-gradient(180deg, #e2c27a, #b88f36); color: #2b2008; border-color: #f0d890; }
.gd-fold::before { content: ''; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -6px 0 0 -4px; border-right: 2px solid var(--hn-ink); border-bottom: 2px solid var(--hn-ink); transform: rotate(45deg); }
.panel.folded .gd-fold::before { margin-top: -2px; transform: rotate(-135deg); }
.gd-head { display: flex; align-items: flex-start; gap: 8px; }
.gd-head .panel-msg { flex: 1; min-width: 0; margin-bottom: 6px; }
.panel.folded > :not(.gd-head) { display: none !important; }
.panel.folded .gd-head .panel-msg { margin-bottom: 0; align-self: center; }
.gd .guide { background: rgba(255, 255, 255, .06); border: 1px solid rgba(201, 162, 74, .4); margin-bottom: 8px; }
.gd .guide-h { color: #f0d890; }
.gd .guide ol, .gd .guide p, .gd .fine { color: var(--hn-ink); }
.gd .place-name { margin: 0 0 6px; font: 700 16px/1.3 var(--hn-serif); color: var(--hn-ink); }
.gd .guide-voice { flex: none; min-height: 40px; padding: 0 10px; border-radius: 999px; border: 1px solid var(--hn-gold); background: rgba(20, 28, 44, .55); color: var(--hn-ink); font: 600 12.5px/1 var(--hn-sans); }
.gd .guide-voice svg { stroke: var(--hn-ink); }
.gd .guide-voice.playing { background: linear-gradient(180deg, #e2c27a, #b88f36); border-color: #f0d890; color: #2b2008; }
.gd .guide-voice.playing svg { stroke: #2b2008; }
.gd .guide-voice.nudge { border-color: #f0d890; }
@media (max-width: 360px) { .gd .guide-voice span { display: none; } }


.gd-bar, .map-join { position: absolute; z-index: 20; left: 10px; right: 10px; bottom: calc(12px + env(safe-area-inset-bottom)); max-width: 460px; margin: 0 auto; }
.map-join { z-index: 19; display: flex; align-items: center; gap: 8px; }
.map-join .hgt-join { flex: 1; width: auto; margin: 0; padding: 6px 10px; }
.map-join .hgt-join .a { font-size: 12px; }
.map-join .hgt-join .b { display: none; }
#entrySheet, #mapGuide { background: var(--hn-glass); }
#entrySheet { max-height: 62%; padding: 12px; }
#mapGuide { top: auto; bottom: calc(60px + env(safe-area-inset-bottom)); }
#mapGuide:not(.open) .gd-row { display: none; }
#entrySheet .sheet-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; font: 700 16px/1.3 var(--hn-serif); color: var(--hn-ink); }
#entrySheet .field span, #entrySheet .hint, #entrySheet .fine, #entrySheet .divider { color: var(--hn-ink-soft); }
#entrySheet .field input { background: rgba(255, 255, 255, .95); color: #1b1b1b; border-color: rgba(201, 162, 74, .6); }
#entrySheet .divider::before, #entrySheet .divider::after { background: rgba(201, 162, 74, .4); }
#entrySheet .err { color: #ff9c8f; }
#entrySheet .hgt-join .a { color: #f6dd8f; }
#entrySheet .hgt-join .b { color: var(--hn-ink-soft); }

#entrySheet.kb { display: flex; flex-direction: column; padding: 8px 10px 0; overscroll-behavior: contain; }
#entrySheet.kb > * { flex: none; }
#entrySheet.kb .sheet-title { order: 0; margin-bottom: 4px; font-size: 14px; }
#entrySheet.kb .sheet-title .gd-x { width: 30px; height: 30px; font-size: 17px; }
#entrySheet.kb .field { order: 1; }
#entrySheet.kb .field span { margin-bottom: 3px; font-size: 12px; }
#entrySheet.kb .field input { padding: 8px 10px; }
#entrySheet.kb .err { order: 2; min-height: 0; margin: 2px 0 0; }
#entrySheet.kb .hgt-join { order: 3; margin-top: 4px; padding: 5px 10px; }
#entrySheet.kb .divider, #entrySheet.kb .fine { display: none; }
#entrySheet.kb .sns { order: 4; margin-top: 6px; }
#entrySheet.kb .sns-btn { min-height: 36px; padding: 6px 4px; }
#entrySheet.kb #btnGuest { order: 5; position: sticky; bottom: 8px; z-index: 1; margin: 8px 0; min-height: 42px; box-shadow: 0 -4px 12px rgba(10, 16, 28, .35); }
#entrySheet.kb .hint { order: 6; margin: 0 0 8px; }
.entry-gate { position: absolute; inset: 0; z-index: 15; background: transparent; touch-action: none; } 
#entryBar.say-on .legal-line { display: none; } 
.legal-line { margin: 6px 2px 0; text-align: center; font: 500 11px/1.3 var(--hn-sans); color: var(--hn-ink-soft); }
.legal-line a { color: var(--hn-ink-soft); text-decoration: underline; text-underline-offset: 2px; }
body #entrySheet.entry-float.gd-sheet.kb-port { left: 10px; right: 10px; width: auto; } 
@media (orientation: landscape) {
  .gd-bar, .map-join { left: auto; right: calc(14px + var(--sr)); width: min(340px, 44%); margin: 0; bottom: 14px; }
  .map-join { width: min(440px, 54%); }
  body #entrySheet.entry-float.gd-sheet, body #mapGuide.entry-float { top: auto; right: calc(14px + var(--sr)); bottom: 14px; max-height: calc(100% - 28px); }
  body #mapGuide.entry-float { bottom: 62px; }
  
  body:has(#topbar:not(.hidden)) #mapGuide.entry-float { max-height: calc(100% - 62px - 92px); }
  body:has(#topbar:not(.hidden)) #entrySheet.entry-float.gd-sheet { max-height: calc(100% - 14px - 92px); }
}
#entrySheet .fine { display: none; } 
#entrySheet .err { min-height: 0; margin: 2px 0; }
.gd-sheet .btn.primary { border: 1px solid #f0d890; background: linear-gradient(180deg, #e2c27a, #b88f36); color: #2b2008; font-weight: 700; border-radius: 999px; }
@media (orientation: portrait) {
  body #entrySheet.entry-float.gd-sheet { top: auto; bottom: 10px; max-height: 62%; }
  body #mapGuide.entry-float { bottom: calc(64px + env(safe-area-inset-bottom)); max-height: 46%; }
}
@media (max-height: 700px) { #entrySheet .fine { display: none; } }
@media (orientation: portrait) { body.ui-open .map-brand { top: 96px; } body.ui-open .map-zoom { top: 132px; } } 


#scrInside .panel { padding: 10px 12px; }
#scrInside #frontSheet { padding: 8px 10px; max-height: min(62%, calc(100% - 110px)); }
.panel .panel-msg { color: var(--hn-ink); }
.panel .radio { color: var(--hn-ink); }
.panel .wish-meta, .panel .vis-help, .panel .offer, .panel .fine { color: var(--hn-ink-soft); }
.panel .wish-meta:has(#wishCost:empty) { display: none; }
.panel textarea { background: rgba(255, 255, 255, .95); color: #1b1b1b; border-color: rgba(201, 162, 74, .6); }
.panel .err { color: #ff9c8f; }
.panel .btn:not(.primary) { background: rgba(255, 255, 255, .10); color: var(--hn-ink); border: 1px solid rgba(201, 162, 74, .6); }
.panel .act svg { stroke: var(--hn-ink); }
.panel .act[data-act="like"] svg { stroke: #ff7a90; }
.panel .chip { background: rgba(255, 255, 255, .10); color: var(--hn-ink); border-color: rgba(201, 162, 74, .4); }
.panel .soon-tag { background: transparent; border-color: rgba(201, 162, 74, .5); color: #e6c778; }
.panel .bow-dots i { background: rgba(255, 255, 255, .16); border-color: rgba(201, 162, 74, .5); }
.panel .bow-dots i.on { background: #e2c27a; border-color: #f0d890; }
@media (orientation: landscape) {
  #scrInside .panel, #scrInside #frontSheet { top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); width: min(360px, 42%); max-height: calc(100% - var(--top) - 52px); }
}
@media (orientation: landscape) and (max-height: 520px) {
  #scrInside .panel { padding: 8px 10px; }
  .panel .wish-meta, .panel .vis-help { font-size: 11.5px; }
  .panel .offer { display: none; }
}


#panoView.intro .pano-intro { background: var(--hn-glass); border: 1px solid var(--hn-gold); border-radius: 16px; padding: 8px 10px; gap: 6px; width: min(460px, calc(100% - 24px)); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
.pano-intro .gd-say { text-align: center; padding-bottom: 4px; }
.pano-intro .gd-row { width: 100%; }
.pano-intro .gd-go.pi-pray { margin-top: 0; min-height: 48px; font-size: 17px; letter-spacing: 1px; box-shadow: none; }
.pano-intro .pi-sub { color: var(--hn-ink); }


.menu-btn svg { width: 16px; height: 16px; margin-right: 5px; vertical-align: -3px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
#topbar .menu-btn.on { background: linear-gradient(180deg, #e2c27a, #b88f36); color: #2b2008; border-color: #f0d890; }
body:not(.ui-open) #steps, body:not(.ui-open) #btnFriendTop, body:not(.ui-open) #btnCharge,
body:not(.ui-open) .scene-hud > .chip:not(#btnViewReset), body:not(.ui-open) .mini-map,
body:not(.ui-open) .music-fab:not(.blocked), body:not(.ui-open) .music-panel { display: none !important; }

body:has(#musicFab.blocked:not(.hidden)) #btnGuideVoice { top: calc(var(--top, 92px) + 42px); }
@keyframes gdUp { from { transform: translateY(18px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes gdFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes gdDown { from { transform: translateY(-8px); opacity: 0; } to { transform: none; opacity: 1; } }
.gd-bar, .map-join, #entrySheet:not(.hidden), #mapGuide:not(.hidden), #scrInside #frontSheet:not(.hidden), #scrInside .panel:not(.hidden) { animation: gdUp .24s ease-out; }
#panoView.intro .pano-intro { animation: gdFade .3s ease-out; }
.gd.say-on .gd-say { animation: gdFade .25s ease-out; }
body.ui-open #steps, body.ui-open #btnFriendTop, body.ui-open #btnCharge, body.ui-open .scene-hud > .chip, body.ui-open .mini-map, body.ui-open .music-fab { animation: gdDown .22s ease-out; }
@media (prefers-reduced-motion: reduce) {
  .gd-bar, .map-join, #entrySheet, #mapGuide, #scrInside #frontSheet, #scrInside .panel, #panoView.intro .pano-intro, .gd.say-on .gd-say,
  body.ui-open #steps, body.ui-open #btnFriendTop, body.ui-open #btnCharge, body.ui-open .scene-hud > .chip, body.ui-open .mini-map, body.ui-open .music-fab { animation: none !important; }
  .gd-i, .gd-x, .gd-fold { transition: none !important; }
}


.nb { position: absolute; width: var(--nb, 16px); height: var(--nb, 16px); transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none; z-index: 2;
  display: grid; place-items: center; font: 800 calc(var(--nb, 16px) * .6)/1 var(--hn-sans, system-ui, sans-serif); font-style: normal; letter-spacing: -.03em;
  color: #fff; background: rgba(184, 28, 28, .86); border: calc(var(--nb, 16px) * .07) solid rgba(255, 255, 255, .88);
  box-shadow: 0 0 calc(var(--nb, 16px) * .22) rgba(0, 0, 0, .35); transition: transform .2s, background .2s; }

#topbar .snd-btn { min-width: 40px; padding: 4px 9px; display: inline-flex; align-items: center; justify-content: center; }
#topbar .snd-btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
#topbar .snd-btn svg path:first-child { fill: currentColor; fill-opacity: .18; }
#topbar .snd-btn.on { color: #2f5d17; border-color: rgba(127, 174, 60, .9); background: linear-gradient(180deg, #f4fbe9, #dfeecb); }
#topbar .snd-btn.blocked { color: #7a5a14; animation: hop .6s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { #topbar .snd-btn.blocked { animation: none; } }
#mapLabels .nm { transform-origin: 0 0; } 
.nb.hot { transform: translate(-50%, -50%) scale(1.3); background: rgba(160, 18, 18, .97); z-index: 4; }
.nb.open { color: #3a2a06; background: linear-gradient(180deg, #ffe9a6, #e1b44c); border-color: rgba(255, 250, 230, .95); box-shadow: 0 0 calc(var(--nb, 16px) * .5) rgba(255, 214, 110, .75); }


.cmark { width: calc(var(--nb, 16px) * 1.9); height: calc(var(--nb, 16px) * 1.9); }
.cmark .ring { inset: 0; border-width: calc(var(--nb, 16px) * .09); }
.cmark::after { left: 74%; top: -22%; width: calc(var(--nb, 16px) * .8); height: calc(var(--nb, 16px) * .8); }
@media (prefers-reduced-motion: reduce) { .nb { transition: none; } }


.ai-head { position: relative; padding: 58px 18px 16px; background: var(--hn-panel, #13203a); color: var(--hn-ink, #fbf1d6); border-radius: 16px 16px 0 0; border-bottom: 1px solid var(--hn-gold, #c9a24a); }
.ai-no { display: inline-grid; place-items: center; min-width: 26px; height: 26px; padding: 0 6px; border-radius: 99px; background: rgba(28, 64, 120, .95); border: 2px solid rgba(255, 255, 255, .85); font: 800 13px/1 var(--hn-sans, sans-serif); color: #fff; margin-bottom: 8px; }
.ai-place { font: 600 12.5px/1.3 var(--hn-sans, sans-serif); letter-spacing: .12em; color: var(--hn-ink-soft, #c9bf9c); }
.ai-title { margin: 4px 0 0; font: 700 23px/1.25 var(--hn-serif, serif); letter-spacing: .04em; color: #f6e7b8; word-break: keep-all; }
.ai-contact { display: grid; grid-template-columns: auto 1fr; gap: 8px 14px; margin: 2px 0 14px; font-size: 15px; }
.ai-contact dt { color: var(--ink-soft); font-size: 13px; padding-top: 2px; }
.ai-contact dd { margin: 0; word-break: break-all; }
.ai-contact a { color: #1c4078; font-weight: 700; text-decoration: none; border-bottom: 1px solid rgba(28, 64, 120, .3); }
.ai-wait { color: var(--ink-soft); }

.ai-greet { margin: 0 0 12px; padding: 9px 12px; border-radius: 12px; background: rgba(28, 64, 120, .07); border-left: 3px solid rgba(28, 64, 120, .55); font-size: 14.5px; line-height: 1.5; color: #24324a; word-break: keep-all; }
.ai-links { display: grid; gap: 8px; margin-bottom: 8px; }
.ai-links:empty { display: none; }
.ai-link { display: grid; gap: 2px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--hn-gold, #c9a24a); background: #fffdf6; color: #3a2f12; text-decoration: none; }
.ai-link b { font-size: 16px; }
.ai-link span { font-size: 13.5px; color: #4a4636; word-break: keep-all; }
.ai-link i { font-style: normal; font-size: 12px; color: #1c4078; word-break: break-all; }
.ai-link:hover, .ai-link:focus-visible { background: #fbf3dc; outline: none; }
.ai-btns { display: grid; gap: 8px; margin-bottom: 8px; }
.ai-btns:empty { display: none; }
.ai-btn { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 46px; padding: 8px 14px; border-radius: 12px; cursor: pointer;
  border: 1px solid var(--hn-gold, #c9a24a); background: linear-gradient(180deg, #fffdf6, #f3ead2); color: #3a2f12; font: 700 15px/1.3 var(--hn-sans, sans-serif); text-align: left; }
.ai-btn small { flex: none; font: 600 11.5px/1 var(--hn-sans, sans-serif); color: #7a6630; padding: 4px 8px; border-radius: 99px; background: rgba(201, 162, 74, .18); }
.ai-soon { min-height: 1.4em; margin: 0 0 12px; font-size: 13.5px; color: #6a5a24; word-break: keep-all; }
.ai-soon.flash { animation: gdFade .3s ease-out; }
@media (orientation: landscape) and (max-height: 520px) {
  .ai-box { grid-template-columns: 40% 1fr; }
  .ai-head { border-radius: 16px 0 0 16px; border-bottom: 0; border-right: 1px solid var(--hn-gold, #c9a24a); padding-top: 56px; }
  .ai-title { font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) { .ai-soon.flash { animation: none; } }


html.a3-open, html.a3-open body { overflow: hidden; }
.a3 { position: fixed; inset: 0; z-index: 86; background: #f7e9ee; overflow: hidden; touch-action: none; -webkit-user-select: none; user-select: none; }
.a3-cv { position: absolute; inset: 0; width: 100%; height: 100%; display: block; outline: none; cursor: grab; }
.a3-cv:active { cursor: grabbing; }
.a3-bar {
  position: absolute; left: 0; right: 0; top: 0; z-index: 4; display: flex; align-items: center; gap: 8px;
  padding: max(8px, env(safe-area-inset-top)) max(10px, env(safe-area-inset-right)) 8px max(10px, env(safe-area-inset-left));
  background: linear-gradient(180deg, rgba(16, 22, 36, .55), rgba(16, 22, 36, 0)); pointer-events: none;
}
.a3-bar .hn-btn { pointer-events: auto; }
.a3-title { flex: 1; min-width: 0; text-align: center; color: #fff8e6; font: 700 15px/1.2 var(--hn-serif); letter-spacing: .08em; text-shadow: 0 1px 6px rgba(0, 0, 0, .45); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.a3-lite.on { background: linear-gradient(180deg, #8fd4a0, #4f9c66); color: #10301b; border-color: #c9f0d3; }
.a3-labels { position: absolute; inset: 0; z-index: 2; pointer-events: none; transition: opacity .25s; }
.a3-labels.off { opacity: 0; visibility: hidden; }

.a3-labels.off .a3-label { visibility: hidden !important; pointer-events: none; }
.a3-label {
  position: absolute; left: 0; top: 0; pointer-events: auto; cursor: pointer; white-space: nowrap;
  padding: 5px 11px; border-radius: 999px; border: 1px solid var(--hn-gold); background: var(--hn-glass); color: var(--hn-ink);
  font: 700 12.5px/1.2 var(--hn-sans); box-shadow: 0 3px 10px rgba(0, 0, 0, .25); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.a3-label small { font: 600 10.5px/1 var(--hn-sans); color: #f0d890; margin-left: 3px; }
.a3-label.soon { opacity: .85; }
.a3-label:hover, .a3-label:focus-visible { border-color: #f0d890; outline: none; background: linear-gradient(180deg, rgba(74, 58, 26, .85), rgba(40, 30, 12, .88)); }
.a3-label::after { content: ''; position: absolute; inset: -8px -4px; } 
.a3-hint {
  position: absolute; z-index: 3; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  max-width: calc(100% - 32px); padding: 8px 16px; border-radius: 999px; border: 1px solid var(--hn-gold); background: var(--hn-glass); color: var(--hn-ink);
  font: 600 13px/1.4 var(--hn-sans); text-align: center; word-break: keep-all; pointer-events: none; transition: opacity .6s;
}
.a3-hint.gone { opacity: 0; }
.a3-near { position: absolute; z-index: 3; left: 50%; bottom: calc(64px + env(safe-area-inset-bottom)); transform: translateX(-50%); min-height: 46px; padding: 0 22px; font-size: 15px; }
.a3-joy {
  display: none; position: absolute; z-index: 3; left: calc(20px + env(safe-area-inset-left)); bottom: calc(20px + env(safe-area-inset-bottom));
  width: 112px; height: 112px; border-radius: 50%; border: 1px solid var(--hn-gold); background: radial-gradient(circle, rgba(255, 255, 255, .28), rgba(20, 28, 44, .35)); touch-action: none;
}
.a3-knob { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: linear-gradient(180deg, #f3dc9c, #c9a24a); box-shadow: 0 2px 8px rgba(0, 0, 0, .35); }
@media (pointer: coarse) { .a3-joy { display: block; } }
.a3.seated .a3-joy, .a3.seated .a3-hint, .a3.seated .a3-near { display: none; }
.a3.seated .a3-title { visibility: hidden; } 

.a3-seat { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.a3-seat > * { pointer-events: auto; }
.a3-seat.busy > * { opacity: 0; pointer-events: none; }
.a3-seat > * { transition: opacity .3s; }
.a3-stand { position: absolute; left: max(10px, env(safe-area-inset-left)); bottom: calc(16px + env(safe-area-inset-bottom)); }
.a3-side {
  position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 64px; border-radius: 14px; cursor: pointer;
  border: 1px solid var(--hn-gold); background: var(--hn-glass); color: var(--hn-ink); font: 700 26px/1 var(--hn-sans);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.a3-side.l { left: max(10px, env(safe-area-inset-left)); }
.a3-side.r { right: max(10px, env(safe-area-inset-right)); }
.a3-seatname {
  position: absolute; right: max(10px, env(safe-area-inset-right)); bottom: calc(16px + env(safe-area-inset-bottom)); max-width: 42%;
  display: grid; gap: 2px; padding: 8px 14px; border-radius: 14px; border: 1px solid var(--hn-gold); background: var(--hn-glass); color: var(--hn-ink); text-align: right; word-break: keep-all;
}
.a3-seatname b { font: 700 15px/1.25 var(--hn-serif); color: #f6e7b8; }
.a3-seatname small { font: 500 12px/1.35 var(--hn-sans); color: var(--hn-ink-soft); }
.a3-play {
  position: absolute; left: 50%; top: 60%; transform: translate(-50%, -50%); min-height: 54px; padding: 0 34px; font-size: 18px; letter-spacing: .08em;
  box-shadow: 0 0 0 3px rgba(255, 240, 200, .35), 0 8px 26px rgba(0, 0, 0, .35); animation: a3Pulse 2.2s ease-in-out infinite;
}
@keyframes a3Pulse { 0%, 100% { box-shadow: 0 0 0 3px rgba(255, 240, 200, .35), 0 8px 26px rgba(0, 0, 0, .35); } 50% { box-shadow: 0 0 0 9px rgba(255, 225, 140, .18), 0 8px 26px rgba(0, 0, 0, .35); } }

.a3-pick { position: absolute; inset: 0; z-index: 5; display: grid; place-items: center; padding: max(10px, env(safe-area-inset-top)) 12px max(10px, env(safe-area-inset-bottom)); background: rgba(10, 12, 24, .28); }
.a3-pickbox {
  position: relative; width: min(760px, 100%); max-height: 100%; display: flex; flex-direction: column; overflow: hidden;
  border-radius: 18px; border: 1px solid var(--hn-gold); color: var(--hn-ink);
  background: repeating-linear-gradient(0deg, rgba(255, 255, 255, .025) 0 1px, transparent 1px 3px), linear-gradient(180deg, rgba(26, 32, 56, .93), rgba(12, 16, 30, .95));
  box-shadow: 0 0 0 4px rgba(20, 22, 28, .9), 0 0 40px rgba(255, 190, 220, .25), 0 18px 50px rgba(0, 0, 0, .5); animation: a3In .28s ease-out;
}
@keyframes a3In { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
.a3-pickhead { flex: none; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid rgba(201, 162, 74, .45); }
.a3-pickhead b { text-align: center; font: 700 17px/1.2 var(--hn-serif); letter-spacing: .12em; color: #f6e7b8; }
.a3-pickhead span { width: 72px; }
.a3-games { list-style: none; margin: 0; padding: 12px; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.a3-game, .a3-soon {
  position: relative; display: grid; grid-template-rows: auto 1fr; height: 100%; border-radius: 12px; overflow: hidden; text-decoration: none; color: var(--hn-ink);
  border: 1px solid rgba(201, 162, 74, .55); background: rgba(255, 255, 255, .05); word-break: keep-all;
}
.a3-game img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; background: #1b2238; }
.a3-game span, .a3-soon span { display: grid; gap: 2px; padding: 7px 9px 9px; }
.a3-game b, .a3-soon b { font: 700 14.5px/1.25 var(--hn-sans); color: #fff6dc; }
.a3-game small, .a3-soon small { font: 500 11.5px/1.35 var(--hn-sans); color: var(--hn-ink-soft); }
.a3-game i, .a3-soon i { position: absolute; left: 7px; top: 7px; font: 700 11px/1 var(--hn-sans); font-style: normal; padding: 4px 8px; border-radius: 99px; background: linear-gradient(180deg, #f3dc9c, #c9a24a); color: #2b2008; }
.a3-game.cur { border-color: #f0d890; box-shadow: 0 0 0 2px rgba(240, 216, 144, .55); }
.a3-game:hover, .a3-game:focus-visible { border-color: #f0d890; background: rgba(255, 230, 160, .12); outline: none; }
.a3-soon { cursor: default; opacity: .75; border-style: dashed; grid-template-rows: 1fr; align-content: center; min-height: 90px; }
.a3-soon i { position: static; justify-self: start; margin-top: 4px; }
.a3-pickfoot { flex: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 8px 12px 12px; border-top: 1px solid rgba(201, 162, 74, .3); }
.a3-pickfoot small { flex: 1; min-width: 180px; font: 500 11.5px/1.4 var(--hn-sans); color: var(--hn-ink-soft); word-break: keep-all; }
.a3.picking .a3-seat { opacity: 0; pointer-events: none; }
.a3.picking .a3-seat > * { pointer-events: none; }

@media (orientation: landscape) and (max-height: 520px) {
  .a3-bar { padding-top: max(6px, env(safe-area-inset-top)); padding-bottom: 4px; }
  .a3-games { grid-template-columns: repeat(5, 1fr); gap: 7px; padding: 8px 10px; }
  .a3-game img { aspect-ratio: 2 / 1; }
  .a3-game span, .a3-soon span { padding: 5px 7px 6px; }
  .a3-game b, .a3-soon b { font-size: 13px; }
  .a3-game small { display: none; }
  .a3-soon { min-height: 0; }
  .a3-label { padding: 4px 9px; font-size: 11.5px; }
  .a3-pickhead { padding: 6px 10px; }
  .a3-pickfoot { padding: 6px 10px 8px; }
  .a3-pickfoot small { display: none; }
  .a3-play { min-height: 48px; font-size: 16px; }
  .a3-joy { width: 96px; height: 96px; }
  .a3-near { bottom: calc(14px + env(safe-area-inset-bottom)); }
  .a3-seatname { max-width: 34%; padding: 6px 12px; }
}
@media (max-width: 560px) {
  .a3-bar .hn-btn { padding: 0 11px; font-size: 12.5px; }
  .a3-title { display: none; }
  .a3-games { grid-template-columns: 1fr 1fr; }
}

@media (pointer: coarse) and (max-width: 600px) {
  .a3-hint { bottom: calc(146px + env(safe-area-inset-bottom)); }
  .a3-near { bottom: calc(146px + env(safe-area-inset-bottom)); }
}

@media (min-width: 1700px) and (min-height: 900px) {
  .a3-bar { gap: 12px; padding: 14px 18px; }
  .a3-bar .hn-btn { min-height: 48px; padding: 0 22px; font-size: clamp(15px, .78vw, 20px); }
  .a3-title { font-size: clamp(18px, .95vw, 24px); }
  .a3-label { padding: 6px 14px; font-size: clamp(14px, .72vw, 18px); }
  .a3-hint { padding: 10px 22px; font-size: clamp(15px, .78vw, 19px); }
  .a3-near { min-height: 54px; font-size: clamp(17px, .85vw, 21px); }
  .a3-side { width: 60px; height: 80px; font-size: 32px; }
  .a3-stand { min-height: 48px; font-size: 16px; }
  .a3-seatname b { font-size: clamp(17px, .9vw, 22px); }
  .a3-seatname small { font-size: clamp(13px, .7vw, 16px); }
  .a3-play { min-height: 64px; padding: 0 44px; font-size: clamp(20px, 1vw, 26px); }
  .a3-pickbox { width: min(clamp(760px, 56vw, 1400px), 100%); }
  .a3-pickhead { padding: 14px 18px; }
  .a3-pickhead b { font-size: clamp(19px, 1vw, 26px); }
  .a3-games { grid-template-columns: repeat(auto-fill, minmax(clamp(150px, 10.5vw, 290px), 1fr)); gap: 14px; padding: 16px; }
  .a3-game b, .a3-soon b { font-size: clamp(15px, .82vw, 21px); }
  .a3-game small, .a3-soon small { font-size: clamp(12px, .62vw, 16px); }
  .a3-game i, .a3-soon i { font-size: 13px; padding: 5px 10px; }
  .a3-pickfoot { padding: 12px 18px 16px; }
  .a3-pickfoot small { font-size: clamp(12px, .62vw, 15px); }
}
@media (prefers-reduced-motion: reduce) { .a3-play, .a3-pickbox { animation: none; } .a3-hint, .a3-labels, .a3-seat > * { transition: none; } }


.nm.open { opacity: 1; font-size: 14px; font-weight: 800; color: #fffbe6; border: 1.5px solid #ffd76a;
  background: linear-gradient(180deg, rgba(120, 84, 10, .92), rgba(70, 46, 6, .92)); z-index: 2; }
.spot .plate { inset: -75%; }
.cmark .ring { border: 3px solid #ffd54a; background: rgba(255, 213, 74, .22); box-shadow: 0 0 18px 4px rgba(255, 213, 74, .85); }
@media (prefers-reduced-motion: no-preference) {
  .nm.open { animation: nmOpenFlash 1.6s ease-in-out infinite; }
  @keyframes nmOpenFlash { 0%, 100% { box-shadow: 0 0 6px rgba(255, 214, 110, .5); filter: brightness(1); }
    50% { box-shadow: 0 0 22px 6px rgba(255, 220, 120, .95), 0 0 46px 10px rgba(255, 200, 80, .55); filter: brightness(1.35); } }
  .spot .plate { animation: plateFlash 1.6s ease-in-out infinite; }
  @keyframes plateFlash { 0%, 100% { opacity: .55; transform: scale(.94); } 50% { opacity: 1; transform: scale(1.06); } }
  .cmark .pulse { display: block; position: absolute; inset: 6px; border-radius: 50%; border: 3px solid rgba(255, 220, 110, .95);
    animation: cmarkPulse 1.6s ease-out infinite; }
  @keyframes cmarkPulse { 0% { transform: scale(1); opacity: .95; } 100% { transform: scale(2.6); opacity: 0; } }
  .cmark::after { animation: starTwinkle 1.6s ease-in-out infinite; }
  @keyframes starTwinkle { 0%, 100% { transform: scale(.8) rotate(0deg); opacity: .7; } 50% { transform: scale(1.35) rotate(45deg); opacity: 1; } }
}


.a3-play:active { transform: translate(-50%, -50%) scale(.97); }
.a3-near:active { transform: translateX(-50%) scale(.97); }


html, body { overscroll-behavior: none; }
#entryBar .gd-say {
  display: block; position: absolute; left: 0; right: 0; bottom: calc(100% + 8px); padding: 8px 12px; border-radius: 14px;
  background: var(--hn-glass); border: 1px solid var(--hn-gold); box-shadow: 0 6px 22px rgba(0, 0, 0, .30);
  opacity: 0; visibility: hidden; pointer-events: none; animation: none; transition: opacity .35s ease, visibility 0s linear .35s;
}
#entryBar.say-on .gd-say, #entryBar.open .gd-say { opacity: 1; visibility: visible; transition: opacity .35s ease; }
#entryBar.say-on .legal-line { display: block; } 
.map-join .hgt-join { animation: none; background-position: 50% 0; } 
@media (prefers-reduced-motion: no-preference) {
  .nm.open { animation: none; overflow: visible; box-shadow: 0 0 8px rgba(255, 214, 110, .6); }
  .nm.open::before { content: ''; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none; will-change: opacity;
    box-shadow: 0 0 16px 4px rgba(255, 220, 120, .85), 0 0 34px 8px rgba(255, 200, 80, .40); opacity: .7; animation: nmOpenGlow 4s ease-in-out infinite; }
  .nm.open::after { display: none; animation: none; }
  
  @keyframes nmOpenGlow { 0%, 100% { opacity: .7; } 50% { opacity: 1; } }
  
  .spot .plate { animation: plateFlash 4s ease-in-out infinite; }
  @keyframes plateFlash { 0%, 100% { opacity: .75; transform: scale(.98); } 50% { opacity: 1; transform: scale(1.02); } }
  .cmark .pulse { animation: cmarkPulse 4s ease-out infinite; }
  @keyframes cmarkPulse { 0% { transform: scale(1); opacity: .55; } 100% { transform: scale(1.9); opacity: 0; } }
  .cmark::after { animation: starTwinkle 4s ease-in-out infinite; }
  @keyframes starTwinkle { 0%, 100% { transform: scale(.95); opacity: .85; } 50% { transform: scale(1.1); opacity: 1; } }
}
@media (pointer: coarse) {
  #scrMap .gd, #scrMap .gd-sheet { -webkit-backdrop-filter: none; backdrop-filter: none; background: linear-gradient(180deg, rgba(36, 46, 68, .94), rgba(16, 22, 36, .95)); }
  #entryBar .gd-say { background: linear-gradient(180deg, rgba(36, 46, 68, .94), rgba(16, 22, 36, .95)); }
}
html.gf-open #scrMap { visibility: hidden; }
html.gf-open #scrMap *, html.gf-open #scrMap *::before, html.gf-open #scrMap *::after { animation-play-state: paused !important; }


.spot .plate, .cmark .pulse, .cmark::after, .nm.open::before { animation: none !important; }
.cmark .pulse { display: none !important; }
.cmark .ring { border-width: calc(var(--nb, 16px) * .08); border-color: rgba(255, 213, 74, calc(.62 * var(--calm, 1))); background: rgba(255, 213, 74, calc(.10 * var(--calm, 1)));
  box-shadow: 0 0 calc(var(--nb, 16px) * .5) rgba(255, 213, 74, calc(.35 * var(--calm, 1))); }
.cmark::after { transform: none; opacity: calc(.45 + .4 * var(--calm, 1)); }
.spot .plate { inset: -55%; opacity: calc(.34 * var(--calm, 1)); transform: none; box-shadow: 0 0 14px 2px rgba(255, 238, 160, calc(.3 * var(--calm, 1))); }
.spot.hov .plate, .spot:focus-visible .plate { opacity: calc(.34 + .5 * var(--calm, 1)); transition: opacity .25s; }
.nm.open::before { opacity: calc(.15 + .45 * var(--calm, 1)); box-shadow: 0 0 10px 2px rgba(255, 220, 120, .6); }
@media (prefers-reduced-motion: no-preference) {
  .spot .plate, .cmark .ring { animation: calmIn 1.4s ease-out 1 both !important; } 
  @keyframes calmIn { from { opacity: 0; } }
}
