* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #0b1520; font-family: "Segoe UI", system-ui, -apple-system, sans-serif; color: #fff; }
#game { display: block; width: 100vw; height: 100vh; }
#hud { position: fixed; top: 14px; left: 14px; pointer-events: none; text-shadow: 0 1px 3px rgba(0,0,0,.8); }
#loc-name { font-size: 26px; font-weight: 700; letter-spacing: .3px; }
#loc-ml { font-size: 20px; opacity: .95; font-family: "Noto Sans Malayalam", "Nirmala UI", "Kartika", sans-serif; }
#loc-sub { font-size: 13px; opacity: .85; margin-top: 4px; line-height: 1.5; white-space: pre-line; }
#stats { position: fixed; bottom: 14px; left: 14px; font-size: 12px; opacity: .8; font-variant-numeric: tabular-nums; white-space: pre-line; }
#crosshair { position: fixed; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: rgba(255,255,255,.85); box-shadow: 0 0 3px #000; pointer-events: none; }
#minimap { position: fixed; top: 14px; right: 14px; border-radius: 50%; box-shadow: 0 2px 12px rgba(0,0,0,.5); background: #cfe3b8; }
#help { position: fixed; bottom: 14px; right: 14px; font-size: 12px; background: rgba(0,0,0,.45); padding: 6px 10px; border-radius: 8px; max-width: 520px; text-align: right; line-height: 1.6; }
#help b { color: #ffd166; }
#chat { position: fixed; left: 14px; bottom: 70px; width: 360px; pointer-events: none; }
#chat-log { max-height: 160px; overflow: hidden; font-size: 13px; text-shadow: 0 1px 2px #000; display: flex; flex-direction: column; justify-content: flex-end; }
#chat-log div { background: rgba(0,0,0,.35); padding: 3px 8px; border-radius: 6px; margin-top: 3px; width: fit-content; max-width: 100%; }
#chat-log .sys { opacity: .7; font-style: italic; }
#chat-input { display: none; width: 100%; margin-top: 6px; padding: 8px 10px; border-radius: 8px; border: 1px solid #5a7; background: rgba(0,0,0,.7); color: #fff; font-size: 14px; pointer-events: auto; outline: none; }
#overlay { position: fixed; inset: 0; background: radial-gradient(ellipse at center, rgba(20,45,60,.85), rgba(5,12,20,.96)); display: flex; align-items: center; justify-content: center; z-index: 10; }
.panel { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15); backdrop-filter: blur(8px); padding: 28px 36px; border-radius: 16px; text-align: center; min-width: 360px; max-width: 520px; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.panel h1 { margin: 0; font-size: 34px; letter-spacing: 1px; }
.panel h2 { margin: 6px 0 18px; font-size: 18px; font-weight: 500; opacity: .9; font-family: "Noto Sans Malayalam", "Nirmala UI", "Kartika", sans-serif; }
.panel p { margin: 10px 0; opacity: .9; }
.panel .small { font-size: 12px; opacity: .65; }
.panel label { display: block; margin: 12px 0; font-size: 14px; }
.panel input { margin-left: 8px; padding: 8px 10px; border-radius: 8px; border: 1px solid #789; background: rgba(0,0,0,.4); color: #fff; font-size: 15px; width: 200px; }
.panel button { padding: 12px 28px; font-size: 18px; border: 0; border-radius: 10px; background: #ffb703; color: #222; font-weight: 700; cursor: pointer; margin-top: 8px; }
.panel button:disabled { opacity: .5; cursor: default; }
#progress { font-variant-numeric: tabular-nums; }
#mapview { display: none; position: fixed; inset: 0; background: rgba(10,20,30,.92); z-index: 8; }
#bigmap { display: block; cursor: crosshair; }
#map-hint { height: 40px; line-height: 40px; text-align: center; font-size: 13px; opacity: .85; }
#teleport { display: none; position: fixed; inset: 0; background: rgba(5,12,20,.8); z-index: 9; align-items: center; justify-content: center; }
#teleport .panel { max-height: 80vh; overflow: auto; text-align: left; min-width: 420px; }
#tp-search { width: 100%; padding: 10px 12px; margin: 4px 0 10px; border-radius: 8px; border: 1px solid #789; background: rgba(0,0,0,.4); color: #fff; font-size: 15px; outline: none; }
#tp-search:focus { border-color: #ffb703; }
#tp-list { columns: 2; column-gap: 24px; }
#tp-list.search { columns: 1; }
#tp-list h4 { margin: 10px 0 4px; font-size: 12px; text-transform: uppercase; letter-spacing: 1px; opacity: .6; column-span: all; }
#tp-list button { display: block; width: 100%; text-align: left; margin: 2px 0; padding: 6px 10px; font-size: 14px; background: rgba(255,255,255,.08); color: #fff; border: 0; border-radius: 6px; cursor: pointer; break-inside: avoid; }
#tp-list button:hover { background: rgba(255,183,3,.35); }
#tp-list small { opacity: .6; margin-left: 6px; }
#compass { position: fixed; top: 244px; right: 14px; width: 220px; text-align: center; font-size: 12px; opacity: .8; text-shadow: 0 1px 2px #000; }
