/* GPX presence layer — the emblem, the touch, the out-gate. */
/* ===== GPX EMBLEM: fixed beside time and battery, never in the way ===== */
.gpx-emblem { position: fixed; top: calc(env(safe-area-inset-top, 0px) + 8px); right: 10px; width: 46px; height: 46px; z-index: 800; cursor: pointer; -webkit-tap-highlight-color: transparent; filter: drop-shadow(0 2px 10px rgba(0,0,0,.55)); }
.gpx-emblem svg { width: 100%; height: 100%; display: block; }
.gpx-emblem .em-flare { position: absolute; inset: -14px; border-radius: 50%; pointer-events: none; opacity: 0; background: radial-gradient(circle, rgba(241,217,138,.55) 0%, rgba(216,181,106,.18) 45%, transparent 70%); }
.gpx-emblem.flaring .em-flare { animation: emFlare .9s ease-out; }
.gpx-emblem.flaring.big .em-flare { animation: emFlareBig 1.6s ease-out; }
.gpx-emblem.flaring svg { animation: emPulse .9s ease; }
@keyframes emFlare { 0% { opacity: 0; transform: scale(.6); } 25% { opacity: 1; } 100% { opacity: 0; transform: scale(1.5); } }
@keyframes emFlareBig { 0% { opacity: 0; transform: scale(.5); } 20% { opacity: 1; } 100% { opacity: 0; transform: scale(2.3); } }
@keyframes emPulse { 0% { transform: scale(1); } 30% { transform: scale(1.14); } 100% { transform: scale(1); } }
.gpx-emblem .em-spin { transform-origin: 32px 32px; animation: emSpin 14s linear infinite; }
@keyframes emSpin { to { transform: rotate(360deg); } }
.gpx-emblem.st0 { opacity: .62; }
.gpx-emblem.st5, .gpx-emblem.st6 { filter: drop-shadow(0 0 12px rgba(216,181,106,.45)); }
/* THE PHANTOM FINAL FORM — the lord's emblem, beyond every stage */
.gpx-emblem.st7 { width: 56px; height: 56px; filter: drop-shadow(0 0 14px rgba(199,125,255,.4)) drop-shadow(0 0 6px rgba(216,181,106,.5)); }
.gpx-emblem .em-spin-rev { transform-origin: 32px 32px; animation: emSpinRev 22s linear infinite; }
@keyframes emSpinRev { to { transform: rotate(-360deg); } }
/* the lord's crest inside the murmur monuments */
.mono-crest.lord-crest { background: none !important; border: 0 !important; width: 44px; height: 44px; }
.mono-crest.lord-crest svg { width: 44px; height: 44px; display: block; filter: drop-shadow(0 0 8px rgba(199,125,255,.35)); }

/* ===== the touch: every button answers the finger ===== */
.gpx-pressed { transform: scale(.965) !important; filter: brightness(1.18); transition: transform .07s ease, filter .07s ease !important; }

/* ===== OUT-GATE: before flying to Instagram ===== */
.outgate { position: fixed; inset: 0; z-index: 1200; background: rgba(3,3,5,.9); backdrop-filter: blur(6px); display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .35s ease; }
.outgate.on { opacity: 1; }
.outgate-core { text-align: center; padding: 24px; max-width: 520px; }
.outgate-crest { width: 92px; height: 92px; margin: 0 auto 20px; border-radius: 50%; border: 1px solid #d8b56a; outline: 1px solid rgba(216,181,106,.3); outline-offset: 6px; display: flex; align-items: center; justify-content: center; font-family: "Cinzel", serif; font-weight: 800; font-size: 42px; color: #f1d98a; position: relative; }
.outgate-count { position: absolute; inset: -14px; border-radius: 50%; border: 2px solid transparent; border-top-color: #d8b56a; animation: emSpin 1s linear infinite; }
.outgate-line { font-family: "Shippori Mincho B1", serif; font-size: clamp(19px, 4.6vw, 26px); line-height: 1.9; color: #e8e4d8; }
.outgate-line .en { display: block; font-family: "Berkshire Swash", cursive; font-size: .78em; color: #d8b56a; margin-top: 10px; }
.outgate-num { font-family: "Cinzel", serif; font-size: 44px; color: #f1d98a; margin: 14px 0 4px; }
.outgate-go { margin-top: 16px; display: inline-block; background: linear-gradient(180deg, #e9cf7a, #b8912c); color: #171204; font-weight: 800; letter-spacing: .12em; border-radius: 999px; padding: 14px 34px; text-decoration: none; font-size: 15px; }
.outgate-stay { display: block; margin: 16px auto 0; background: none; border: 0; color: #9a958a; font: inherit; font-size: 13px; cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }

/* ============ GPX URANAI — 幻神占い (index shrine) ============ */
.uranai-panel { grid-column: 1 / -1; text-align: center; }
.uranai-stage { position: relative; width: 190px; height: 190px; margin: 18px auto 6px; }
.uranai-stars { position: absolute; inset: 0; }
.uranai-stars i { position: absolute; width: 4px; height: 4px; margin: -2px 0 0 -2px; border-radius: 50%; background: #ffe9a8; box-shadow: 0 0 6px 2px rgba(255,215,130,.55); animation: urTw 2.6s ease-in-out infinite alternate; }
.uranai-stars.flare i { animation: urFlare 1.1s ease-out; }
@keyframes urTw { from { opacity: .35; transform: scale(.8); } to { opacity: 1; transform: scale(1.25); } }
@keyframes urFlare { 0% { transform: scale(1); opacity: 1; } 40% { transform: scale(2.6); opacity: 1; } 100% { transform: scale(1); opacity: .9; } }
.uranai-crystal { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 96px; height: 96px; background: none; border: 0; cursor: pointer; padding: 0; filter: drop-shadow(0 0 14px rgba(109,179,242,.45)); animation: urFloat 5s ease-in-out infinite; }
.uranai-crystal svg { width: 100%; height: 100%; }
@keyframes urFloat { 0%, 100% { transform: translate(-50%, -52%); } 50% { transform: translate(-50%, -46%); } }
.uranai-out { max-width: 640px; margin: 16px auto 4px; text-align: left; }
.uranai-out.show .uranai-line { animation: riseIn 1.2s ease both; }
.uranai-out.show .uranai-line:nth-child(2) { animation-delay: .35s; }
.uranai-out.show .uranai-line:nth-child(3) { animation-delay: .7s; }
.uranai-line { display: flex; gap: 12px; align-items: baseline; padding: 10px 4px; border-bottom: 1px solid rgba(216,181,106,.14); font-size: 14.5px; line-height: 2; color: var(--text); }
.uranai-tag { flex: none; font-family: 'Yuji Syuku', serif; color: var(--gold); font-size: 15px; letter-spacing: .2em; border: 1px solid rgba(216,181,106,.4); border-radius: 999px; padding: 1px 12px; }
.uranai-oracle { font-size: 16px; }

/* ============ THE OFFERING CEREMONY (shrine → PayPal) ============ */
.offer-ceremony { position: fixed; inset: 0; z-index: 950; display: flex; flex-direction: column; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 42%, rgba(60,44,10,.97), rgba(3,3,5,.99) 72%); opacity: 0; transition: opacity .45s ease; text-align: center; padding: 20px; }
.offer-ceremony.on { opacity: 1; }
.offer-ceremony .oc-torii { position: relative; width: 130px; height: 130px; border-radius: 50%; border: 2px solid var(--gold); outline: 1px solid rgba(216,181,106,.35); outline-offset: 8px; display: flex; align-items: center; justify-content: center; background: rgba(5,5,7,.9); box-shadow: 0 0 60px 18px rgba(216,181,106,.35); }
.offer-ceremony .oc-torii b { font-family: 'Cinzel', serif; font-weight: 800; font-size: 56px; color: var(--gold); }
.offer-ceremony .oc-torii i { position: absolute; inset: -26px; border-radius: 50%; border: 1px dashed rgba(216,181,106,.5); animation: emSpin 14s linear infinite; }
.offer-ceremony .oc-word { font-family: 'Yuji Syuku', serif; font-size: 30px; color: #ffe9a8; letter-spacing: .3em; margin-top: 42px; text-shadow: 0 0 24px rgba(255,215,130,.6); }
.offer-ceremony .oc-sub { color: var(--muted); font-size: 13.5px; line-height: 2; margin-top: 10px; }
.offer-ceremony .oc-light { position: absolute; left: 50%; top: 42%; width: 12px; height: 12px; margin: -6px; border-radius: 50%; background: #fff3c4; box-shadow: 0 0 120px 90px rgba(255,220,140,.5); animation: ocPulse 1.7s ease-in-out infinite; pointer-events: none; }
@keyframes ocPulse { 0%, 100% { transform: scale(.7); opacity: .6; } 50% { transform: scale(1.25); opacity: 1; } }

/* ============ GPX PLAY — the floating game door (index) ============ */
.gpx-play-float { position: fixed; left: max(12px, env(safe-area-inset-left)); bottom: calc(86px + env(safe-area-inset-bottom)); z-index: 790; display: flex; align-items: center; gap: 8px; text-decoration: none; color: #ffe9a8; background: rgba(8,8,12,.88); border: 1px solid rgba(216,181,106,.65); border-radius: 999px; padding: 10px 16px 10px 11px; font-family: 'Cinzel', serif; font-size: 12px; letter-spacing: .18em; box-shadow: 0 6px 24px rgba(0,0,0,.55), 0 0 18px rgba(216,181,106,.25); transform: translateY(24px) scale(.85); opacity: 0; pointer-events: none; transition: transform .5s cubic-bezier(.2,1.6,.4,1), opacity .4s; backdrop-filter: blur(4px); }
.gpx-play-float.on { transform: none; opacity: 1; pointer-events: auto; }
.gpx-play-float .pf-mark { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--gold); display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; color: var(--gold); animation: urFloat2 3.4s ease-in-out infinite; }
@keyframes urFloat2 { 0%, 100% { transform: translateY(-1px); } 50% { transform: translateY(2px); } }
.gpx-play-float small { display: block; font-family: 'Shippori Mincho B1', serif; letter-spacing: .14em; font-size: 10px; color: var(--muted); }

/* ============ GPX CHARA — 御案内： the living wall ============ */
.chara-wall { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; max-width: 680px; margin: 26px auto 6px; }
@media (max-width: 640px) { .chara-wall { grid-template-columns: repeat(5, 1fr); } }
.chara-tile { aspect-ratio: 1; border: 1px solid rgba(216,181,106,.22); border-radius: 14px; background: radial-gradient(circle at 50% 38%, rgba(216,181,106,.07), rgba(5,5,7,.5) 72%); display: flex; align-items: center; justify-content: center; padding: 7px; animation: riseIn .8s ease both; }
.chara-tile svg { width: 100%; height: 100%; }
.chara-wall-note { max-width: 640px; margin: 16px auto 0; color: var(--muted); font-size: 13px; line-height: 2; text-align: center; }
.chara-wall-note span { display: block; }
.chara-guide-btns { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 22px; }

/* ============ 離脱の光 — the light at the threshold ============ */
.gpx-exit-panel { position: fixed; left: 50%; bottom: 18px; transform: translate(-50%, 130%); width: min(520px, calc(100vw - 24px)); z-index: 960; background: linear-gradient(170deg, #12100c, #070708 70%); border: 1px solid rgba(216,181,106,.5); border-radius: 20px; padding: 30px 26px 24px; text-align: center; box-shadow: 0 30px 80px rgba(0,0,0,.75), 0 0 44px rgba(216,181,106,.14); transition: transform .55s cubic-bezier(.22,1.2,.36,1); overflow: hidden; }
.gpx-exit-panel.show { transform: translate(-50%, 0); }
.gpx-exit-streak { position: absolute; top: 0; left: -70%; width: 55%; height: 3px; background: linear-gradient(90deg, transparent, #ffe9a8, #fff, transparent); animation: exitStreak 1.6s ease .25s both; }
@keyframes exitStreak { to { left: 115%; } }
.gpx-exit-x { position: absolute; top: 8px; right: 12px; background: none; border: none; color: var(--muted); font-size: 22px; cursor: pointer; }
.gpx-exit-crest { font-family: 'Berkshire Swash', cursive; font-size: 40px; line-height: 1; background: linear-gradient(100deg, #8a6a1f, #f8e08a 40%, #fff3c4 55%, #d8b56a 75%, #8a6a1f); -webkit-background-clip: text; background-clip: text; color: transparent; }
.gpx-exit-kicker { margin-top: 8px; color: var(--gold); font-family: Cinzel, serif; letter-spacing: .3em; font-size: 10px; }
.gpx-exit-oracle { margin-top: 12px; font-family: 'Yuji Syuku', serif; font-size: 19px; line-height: 2; color: #fdf6dd; }
.gpx-exit-note { margin-top: 12px; color: var(--muted); font-size: 11.5px; line-height: 1.9; }
.gpx-exit-note span { display: block; }
.gpx-exit-btns { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 18px; }

/* ============ the master's being — a living halo ============ */
#gpxMasterChara { filter: drop-shadow(0 0 14px rgba(248,224,138,.35)); animation: masterBreath 5s ease-in-out infinite; }
@keyframes masterBreath { 0%, 100% { filter: drop-shadow(0 0 10px rgba(248,224,138,.28)); } 50% { filter: drop-shadow(0 0 22px rgba(248,224,138,.55)); } }

/* ============ 月の裏側 — THE FAR SIDE ============ */
.farside-section { overflow: hidden; }
.farside-rail { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 26px max(20px, calc((100vw - 1080px) / 2)) 10px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.farside-rail::-webkit-scrollbar { display: none; }
.farside-card { scroll-snap-align: start; flex: 0 0 238px; min-height: 196px; border: 1px solid rgba(216,181,106,.3); border-radius: 18px; background: linear-gradient(165deg, rgba(216,181,106,.07), rgba(5,5,7,.55) 65%); padding: 22px 20px; display: flex; flex-direction: column; gap: 8px; text-decoration: none; transition: border-color .3s, transform .3s; }
a.farside-card:hover { border-color: rgba(216,181,106,.75); transform: translateY(-3px); }
.fs-glyph { font-family: 'Yuji Syuku', serif; font-size: 30px; color: var(--gold); line-height: 1; }
.fs-name { font-family: Cinzel, serif; font-weight: 700; letter-spacing: .12em; font-size: 14px; color: var(--ink); }
.fs-sub { color: var(--muted); font-size: 12px; line-height: 1.8; }
.farside-end { border-color: rgba(216,181,106,.65); background: radial-gradient(circle at 50% 0%, rgba(216,181,106,.16), rgba(5,5,7,.6) 70%); }
.farside-end .fs-glyph { font-family: 'Berkshire Swash', cursive; background: linear-gradient(100deg, #8a6a1f, #f8e08a 45%, #fff3c4 55%, #d8b56a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.fs-end-btns { display: flex; flex-direction: column; gap: 8px; margin-top: auto; }
.fs-end-btns .ritual-btn { text-align: center; font-size: 12px; padding: 10px 12px; }
.farside-track { height: 2px; background: rgba(216,181,106,.15); margin: 14px max(20px, calc((100vw - 1080px) / 2)) 0; border-radius: 2px; overflow: hidden; }
.farside-fill { height: 100%; width: 8%; background: linear-gradient(90deg, #8a6a1f, #ffe9a8, #fff); transition: width .2s ease; box-shadow: 0 0 10px rgba(255,233,168,.8); }
.farside-hint { text-align: center; color: var(--muted); font-size: 11px; letter-spacing: .24em; margin-top: 12px; }

/* v22 — the corner must never collide; Japanese must carry its weight */
.head-cta{margin-right:60px !important}
.jp{color:#f2dda6 !important;opacity:1 !important;font-weight:500}
@media (prefers-reduced-motion: reduce){
  *,*::before,*::after{animation-duration:.01s !important;animation-iteration-count:1 !important;transition-duration:.01s !important}
}

/* audit 2026-11-02: hidden attribute guard (see style.css) */
[hidden]{display:none!important}
