/* Image-led entry screens; all selectors stay outside the game HUD. */
body:not(.in-game){font-family:'Noto Sans',system-ui,sans-serif;background:#142019;color:#fff8e8}
body:not(.in-game) #backdrop{background:#17251d;overflow:hidden}
body:not(.in-game) #backdrop:before{content:'';position:absolute;inset:-1.5%;background:url('/art/home-temple.jpg') center 45%/cover no-repeat;animation:entry-breathe 28s ease-in-out infinite alternate}
body:not(.in-game) #backdrop:after{display:block;background:linear-gradient(90deg,#10231cdb 0%,#15251b9c 31%,#14231b26 60%,transparent 80%),linear-gradient(0deg,#10201688,transparent 45%)}
body:not(.in-game) .topbar{position:absolute;top:0;left:0;width:100%;padding:26px 6vw;border:0;max-width:none;background:none}
body:not(.in-game) .brand{color:#fff6de;gap:13px;font-size:16px;letter-spacing:3px;align-items:center}
body:not(.in-game) .brand-mark{display:grid;place-items:center;width:43px;height:43px;border:1px solid #ead5a28c;border-radius:50%;font:italic 23px 'Noto Serif',Georgia,serif;letter-spacing:-2px;color:#f0d398}
body:not(.in-game) .brand small{color:#e8e5d5;font-size:7px;letter-spacing:1.7px;margin-top:5px}
body:not(.in-game) .build-badge,body:not(.in-game) #connection{display:none}
#onboarding.entry-shell,#onboarding.entry-shell:has(#profile-panel:not([hidden])){display:block;max-width:none;width:100%;margin:0;padding:120px 6vw 50px;min-height:100svh}
.entry-shell .intro:not([hidden]){display:flex;min-height:calc(100svh - 170px);flex-direction:column;align-items:flex-start;justify-content:center;max-width:640px}
.hero-eyebrow{font-size:10px;letter-spacing:3px;color:#f0d5a4}
.entry-shell .intro .hero-wordmark{display:flex;gap:8px;align-items:center;margin:12px 0 20px;font-family:'Noto Serif',Georgia,'Times New Roman',serif;font-weight:400;font-size:clamp(95px,12.5vw,176px);line-height:1.1;letter-spacing:-.055em;color:#fff6df;text-shadow:0 5px 35px #0b24184d}
.hero-three{font-size:1.3em;line-height:.9;font-style:italic;color:#f5d998}
.hero-kiep{position:relative;padding-bottom:12px;font-style:italic}
.hero-seal{display:block;font:8px system-ui,sans-serif;letter-spacing:3px;color:#eddbb6;margin:0 0 0 12px;position:absolute;bottom:-1px;white-space:nowrap}
.entry-shell .intro h2{font-family:'Noto Serif',Georgia,'Times New Roman',serif;font-size:clamp(27px,3.2vw,42px);font-weight:400;line-height:1.15;letter-spacing:-.9px;margin:6px 0 12px;color:#fff9eb}
.entry-shell .intro p{font-size:14px;line-height:1.85;color:#e4e9db;margin:0 0 26px}
.journey-button{display:flex;align-items:center;gap:38px;padding:16px 21px;border:1px solid #f8e3b9;border-radius:11px;background:#edd3a0;color:#243b2c;box-shadow:0 8px 35px #0719102b;font-size:14px;font-weight:650;transition:background .2s,transform .2s}
.journey-button span{font-size:24px;font-weight:400;line-height:1}
.journey-button:hover{background:#ffe8ba;transform:translateY(-2px)}
.hero-footnote{display:block;font-size:10px;letter-spacing:.3px;color:#d3dfce;margin-top:21px}
.entry-shell .welcome-card{width:min(420px,100%);margin:0;padding:24px 27px 21px;border-radius:20px;background:#fffdf5ed;border:1px solid #f3e5c4;box-shadow:0 20px 80px #071b1940;color:#304a39;backdrop-filter:blur(16px)}
.entry-back{border:0;background:none;color:#758371;font-size:11px;padding:0;margin:0 0 18px}
.entry-shell .welcome-card .card-step{color:#8b997b;font-size:9px;letter-spacing:2px}
.entry-shell .welcome-card h2{font-family:'Noto Serif',Georgia,'Times New Roman',serif;font-weight:400;font-size:32px;letter-spacing:-.8px;color:#2e4a38;margin:9px 0 18px}
.entry-shell #profile-form label{font-size:11px;color:#6a7d69;margin-bottom:6px}
.entry-shell #profile-form input,.entry-shell #profile-form select{background:#fffef9;color:#3d5542;border:1px solid #d6dfcc;border-radius:9px;padding:10px 12px;min-height:43px;font-size:13px}
.entry-shell .avatar-preview{height:145px;margin-top:17px;border-radius:12px;background:radial-gradient(ellipse at 50% 70%,#dce8d2,#f1f5e7);border-color:#dfe7d6}
.entry-shell #profile-form>.primary{margin-top:16px;background:#315c43;border:1px solid #315c43;color:#fff8e8;border-radius:10px;padding:13px 17px;font-size:14px}
.entry-shell #profile-error:empty{display:none}
.entry-shell #profile-error{font-size:12px;color:#954a3d;margin:10px 0 0}
.creating-profile #onboarding.entry-shell{padding-top:105px}
.choosing-map #backdrop:before{filter:blur(3px)}
.choosing-map #backdrop:after{background:linear-gradient(110deg,#10241be8,#132419b8)}
.entry-shell #map-panel{width:min(1280px,100%);max-width:none;margin:14px auto 0;grid-column:auto}
.entry-shell .map-heading{display:flex;justify-content:space-between;align-items:flex-end;margin-bottom:26px;gap:24px}
.entry-shell .map-heading .eyebrow{font-size:9px;letter-spacing:2.5px;color:#e4cf9d}
.entry-shell .map-heading h2{font-family:'Noto Serif',Georgia,'Times New Roman',serif;font-weight:400;font-size:clamp(27px,3.3vw,43px);letter-spacing:-1.2px;line-height:1.2;color:#fff7e3;margin:10px 0}
.entry-shell .map-heading p{font-size:13px;color:#ccd8c8;margin:0;line-height:1.6}
.entry-shell #edit-profile{padding:10px 15px;color:#f1e8d0;background:#ffffff0b;border:1px solid #d7dfc842;border-radius:30px;white-space:nowrap;font-size:11px}
.entry-shell .map-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px}
.entry-shell .map-card{display:flex;flex-direction:column;overflow:hidden;min-width:0;padding:0;text-align:left;border:1px solid #e7dfb82b;border-radius:17px;background:#1b3025;color:#f9f1dc;box-shadow:0 15px 40px #00160c30;transition:transform .35s,border-color .35s,box-shadow .35s}
.entry-shell .map-card .map-art{position:relative;height:clamp(220px,32vh,320px);min-height:0;aspect-ratio:auto;width:100%;overflow:hidden;background:#24392c}
.entry-shell .map-cover{width:100%;height:100%;object-fit:cover;transition:transform 1s ease;animation:card-breathe 18s ease-in-out infinite alternate}
.entry-shell .map-art.temple .map-cover{object-position:68% 50%}
.entry-shell .map-art.street .map-cover{object-position:45% 50%;animation-delay:-6s}
.entry-shell .map-art.karaoke .map-cover{object-position:52% 45%;animation-delay:-12s}
.entry-shell .map-art:after{content:'';position:absolute;inset:0;background:linear-gradient(0deg,#10251c45,transparent 50%);pointer-events:none}
.entry-shell .map-art>span{position:absolute;z-index:1;left:16px;top:16px;bottom:auto;color:#fff6dc;background:#10271e8c;border:1px solid #f8e5bd59;border-radius:30px;padding:7px 10px;font-size:8px;letter-spacing:1px;backdrop-filter:blur(6px)}
.entry-shell .map-card-body{width:100%;padding:20px 22px 18px;background:#1b3025;flex:1}
.entry-shell .map-card h3{font-family:'Noto Serif',Georgia,'Times New Roman',serif;font-size:29px;font-weight:400;color:#faf1da;letter-spacing:-.65px;margin:0 0 10px;line-height:1.2}
.entry-shell .map-card p{display:none}
.entry-shell .map-card small{display:flex;justify-content:space-between;color:#d5dfca;font-size:12px;font-weight:400;line-height:1.5;border-top:1px solid #e4e9d71c;padding-top:12px;margin:0}
.entry-shell .map-card:hover{transform:translateY(-5px);border-color:#ebd5a380;box-shadow:0 22px 45px #00160c50}
.entry-shell .map-card:hover .map-cover{animation:none;transform:scale(1.06)}
.entry-shell .map-card:disabled{opacity:.5}
.entry-shell .entry-status{display:none}
.entry-shell #entry-error:not(:empty){padding:14px;color:#fff6df;background:#68463a;border-radius:10px;font-size:13px}
@keyframes entry-breathe{from{transform:scale(1)}to{transform:scale(1.035)}}
@keyframes card-breathe{from{transform:scale(1.01)}to{transform:scale(1.055)}}
@media(max-width:760px){
 body:not(.in-game) .topbar{padding:21px 24px}
 body:not(.in-game) #backdrop:before{background-position:62% 50%}
 body:not(.in-game) #backdrop:after{background:linear-gradient(90deg,#10231ccb,#14231b35),linear-gradient(0deg,#102016bd,transparent 70%)}
 #onboarding.entry-shell,#onboarding.entry-shell:has(#profile-panel:not([hidden])){padding:112px 24px 36px}
 .entry-shell .intro:not([hidden]){min-height:calc(100svh - 148px);justify-content:flex-end;padding-bottom:20px}
 .hero-eyebrow{font-size:8px;letter-spacing:2px}
 .entry-shell .intro .hero-wordmark{font-size:104px;letter-spacing:-.045em;margin:10px 0 20px}
 .hero-seal{font-size:6px;letter-spacing:1.9px;margin-left:8px}
 .entry-shell .intro h2{font-size:32px}
 .entry-shell .intro p{font-size:12px;margin-bottom:21px}
 .hero-footnote{font-size:9px;max-width:270px;line-height:1.6}
 .entry-shell .welcome-card{margin:0 auto;padding:22px}
 .creating-profile #onboarding.entry-shell{padding-top:100px}
 .entry-shell .map-heading{align-items:flex-start;gap:10px;margin-bottom:22px}
 .entry-shell .map-heading h2{font-size:30px;max-width:280px}
 .entry-shell .map-heading p{font-size:12px;max-width:260px}
 .entry-shell #edit-profile{padding:8px 10px;font-size:10px;margin-top:26px}
 .entry-shell .map-cards{grid-template-columns:1fr;gap:20px}
 .entry-shell .map-card .map-art{height:240px}
 .entry-shell .map-card-body{padding:19px 20px}
 .entry-shell .map-card h3{font-size:28px}
}
@media(max-height:650px) and (min-width:761px){.entry-shell .intro .hero-wordmark{font-size:115px;margin:4px 0 12px}.entry-shell .intro h2{font-size:29px}.entry-shell .intro p{margin-bottom:18px}.hero-footnote{margin-top:12px}#onboarding.entry-shell{padding-top:105px}.entry-shell .map-card .map-art{height:210px}}
@media(prefers-reduced-motion:reduce){body:not(.in-game) #backdrop:before,.entry-shell .map-cover{animation:none}.journey-button,.entry-shell .map-card,.entry-shell .map-cover{transition:none}.entry-shell .map-card:hover,.journey-button:hover{transform:none}}

body:not(.in-game) .brand{background:#12261f70;border:1px solid #ffffff26;border-radius:13px;padding:9px 13px;backdrop-filter:blur(6px)}
.hero-eyebrow{display:inline-block;padding:8px 12px;border:1px solid #f3deaa3d;border-radius:30px;background:#12271fb0;color:#f4e6c3;font-size:10px;letter-spacing:1.7px;backdrop-filter:blur(6px)}
.hero-kiep{white-space:nowrap}
.hero-seal{bottom:-8px;font-size:8px;letter-spacing:1.6px;background:#142b219e;border:1px solid #ffffff24;padding:5px 8px;border-radius:5px;color:#f2dfbd}
.entry-shell .intro .hero-wordmark{margin-bottom:30px}
.entry-shell .intro p{display:inline-block;background:#142b218f;border:1px solid #ffffff24;border-radius:10px;padding:10px 14px;color:#f1f3e5;font-size:13px;backdrop-filter:blur(6px)}
.hero-footnote{display:inline-block;width:fit-content;background:#142b21a3;border:1px solid #ffffff22;border-radius:7px;padding:8px 11px;font-size:11px;color:#f1efdf;backdrop-filter:blur(6px)}
.entry-shell .map-heading .eyebrow{display:inline-block;background:#10271f80;border:1px solid #e5d8ae40;border-radius:20px;padding:7px 10px;font-size:10px;letter-spacing:1.5px}
.entry-shell .map-heading p{display:inline-block;padding:8px 11px;background:#10251f8c;border-radius:8px;color:#eef1e3}
.entry-shell .map-art>span{font-size:9px;color:#fff7e4;background:#10251dbd}
body.in-game{overflow:hidden;overscroll-behavior:none;min-height:100dvh}
@media(max-width:760px){body:not(.in-game) #backdrop:before{background-position:78% 50%}.hero-eyebrow{font-size:9px;letter-spacing:1px}.entry-shell .intro .hero-wordmark{font-size:96px}.entry-shell .intro h2{font-size:30px}.hero-seal{font-size:6px;letter-spacing:1px}.entry-shell .intro p{font-size:12px}.hero-footnote{font-size:10px}.entry-shell .map-heading p{font-size:11px}.entry-shell .map-heading{flex-wrap:wrap}.entry-shell #edit-profile{margin-top:0}}

body:not(.in-game) .brand small{font-size:8px;letter-spacing:1.2px}.hero-seal{font-size:9px;letter-spacing:1px}#world{touch-action:none;user-select:none;-webkit-user-select:none}button{touch-action:manipulation}
@media(max-width:700px){.hero-seal{font-size:8px}.hud-toolbar{top:calc(12px + env(safe-area-inset-top));right:calc(12px + env(safe-area-inset-right))}.hud-toolbar button{width:42px;height:42px}.movement-pad{left:calc(10px + env(safe-area-inset-left));bottom:calc(12px + env(safe-area-inset-bottom))}.movement-pad button{width:42px;height:42px}.action-dock{bottom:calc(12px + env(safe-area-inset-bottom));max-width:calc(100vw - 156px)}#actions button.action-icon{width:42px;height:42px;min-width:42px;font-size:22px}.open-settings .map-info,.open-music #temple-music:not([hidden]),.open-music #street-music:not([hidden]){top:calc(66px + env(safe-area-inset-top))}}

.dialogue-body{max-height:min(calc(100dvh - 220px),var(--dialogue-body-max,550px))}
@media(max-width:700px){.entry-shell #profile-form input,.entry-shell #profile-form select,.chat-panel input{font-size:16px}.action-dock{max-height:172px}.entry-shell .map-card small{font-size:13px}}

#npc-targets{position:fixed;inset:0;pointer-events:none;z-index:2}.npc-hit-target{position:fixed;pointer-events:auto;background:transparent;border:0;border-radius:35%;padding:0;cursor:pointer;touch-action:none}.npc-hit-target:focus-visible{outline:2px solid #e5ca85;outline-offset:3px}.in-game .hud-toolbar,.in-game .action-dock,.in-game .map-info,.in-game .temple-music,.in-game .street-music{z-index:8}

@media(max-width:700px){.map-tools button{min-height:42px}.temple-music input[type=range],.street-music input[type=range]{min-height:38px}.temple-music label,.street-music label{font-size:12px}}
