:root {
  color-scheme: dark;
  --bg: #0b0c10;
  --panel: #15171d;
  --panel-2: #1d2029;
  --line: #2c303b;
  --text: #ecebe4;
  --muted: #a3a6b3;
  --accent: #ffb54a;
  --accent-2: #ff7a3a;
  --good: #6ad66a;
  --bad: #e0503a;
  --blue: #56aaff;
  --purple: #bb72ff;
  --r-scrap: #9a9a92;
  --r-common: #ecebe4;
  --r-uncommon: #6ad66a;
  --r-rare: #56aaff;
  --r-epic: #bb72ff;
  --r-legendary: #ff9d2e;
  font-family: "Nunito", ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-weight: 700;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; background: var(--bg); color: var(--text); overscroll-behavior: none; }
body { touch-action: none; -webkit-user-select: none; user-select: none; }
button { font: inherit; color: inherit; -webkit-tap-highlight-color: transparent; cursor: pointer; }
:focus-visible { outline: 3px solid #ffd84a; outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
kbd { display: inline-block; min-width: 1.6em; padding: 0 5px; border: 1px solid #555a66; border-bottom-width: 2px; border-radius: 5px; background: #23262f; font: 800 0.8em/1.5 ui-monospace, monospace; text-align: center; color: #fff; }

.ll { position: fixed; inset: 0; overflow: hidden; }
#view { position: absolute; inset: 0; width: 100%; height: 100%; display: block; cursor: crosshair; outline: none; }
#view:focus-visible { outline: none; }

/* ---------- HUD ---------- */
.hud { position: absolute; inset: 0; pointer-events: none; }
.hud button, .hud .quickbar, .hud .buildbar { pointer-events: auto; }
.hud-tl { position: absolute; left: 10px; top: 10px; display: flex; gap: 8px; align-items: flex-start; }
.me { position: relative; width: 58px; height: 58px; padding: 0; border: 2px solid #3a3f4c; border-radius: 14px; background: #1a1c23; overflow: visible; }
.me .portrait { width: 100%; height: 100%; border-radius: 12px; }
.me-lvl { position: absolute; right: -7px; bottom: -7px; min-width: 24px; height: 24px; padding: 0 5px; border-radius: 12px; background: var(--accent); color: #1a1208; font-weight: 900; font-size: 13px; line-height: 24px; box-shadow: 0 2px 0 #0008; }
.me-info { width: min(210px, 38vw); display: grid; gap: 4px; text-shadow: 0 1px 2px #000; }
.me-name { font-size: 13px; font-weight: 900; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.title-tag { color: var(--accent); font-weight: 800; font-size: 11px; }
.bar { position: relative; height: 12px; border-radius: 6px; background: #0009; border: 1px solid #0008; overflow: hidden; }
.bar i { position: absolute; inset: 0 auto 0 0; width: 100%; border-radius: 6px; transition: width 0.15s; }
.bar.hp { height: 16px; }
.bar.hp i { background: linear-gradient(#ff6b5a, #b8352a); }
.bar.hp span { position: absolute; inset: 0; font-size: 11px; line-height: 15px; text-align: center; font-weight: 900; }
.bar.sta i { background: linear-gradient(#ffe066, #c99a1c); }
.bar.sta { height: 7px; }
.minibars { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.minibars .bar { height: 11px; }
.minibars b { position: absolute; inset: 0; font-size: 8.5px; line-height: 10px; text-align: center; font-weight: 900; letter-spacing: 0.04em; text-transform: uppercase; opacity: 0.85; }
.bar.hun i { background: linear-gradient(#e8b050, #9a6a1c); }
.bar.inf i { background: linear-gradient(#8fe05a, #3f7a2a); }
.bar.xp { height: 5px; }
.bar.xp i { background: linear-gradient(90deg, #56aaff, #bb72ff); }
.skillpip { font-size: 11px; color: #ffd84a; font-weight: 900; animation: pulse 1.2s infinite; }
@keyframes pulse { 50% { opacity: 0.5; } }

.hud-tr { position: absolute; right: 10px; top: 10px; display: grid; justify-items: end; gap: 6px; }
.clock { display: grid; justify-items: end; text-shadow: 0 1px 2px #000; font-size: 12px; color: var(--muted); }
.clock strong { color: var(--text); font-size: 15px; }
#minimap { width: 130px; height: 130px; border-radius: 14px; border: 2px solid #3a3f4c; background: #0b0c10; box-shadow: 0 4px 16px #0008; }
.hud-buttons { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; max-width: 240px; }
.hb { height: 30px; padding: 0 9px; border: 1px solid #3a3f4c; border-radius: 9px; background: #1a1c23e6; font-size: 12px; font-weight: 900; }
.hb:hover { background: #262a35; }

.tracker { position: absolute; left: 10px; top: 150px; width: min(250px, 44vw); display: grid; gap: 6px; text-shadow: 0 1px 2px #000; }
.tq { padding: 6px 9px; border-radius: 10px; background: #0b0c10b3; border-left: 3px solid var(--accent); font-size: 12px; }
.tq.side { border-left-color: var(--blue); }
.tq.daily { border-left-color: #9fd0a8; }
.tq h4 { margin: 0 0 2px; font-size: 12px; font-weight: 900; }
.tq p { margin: 0; color: var(--muted); font-size: 11.5px; }
.tq p.done { color: var(--good); text-decoration: line-through; }
.tq p.ready { color: var(--good); }

.bossbar { position: absolute; left: 50%; top: 12px; width: min(460px, 60vw); transform: translateX(-50%); text-align: center; text-shadow: 0 1px 3px #000; font-weight: 900; color: #ffc8d0; }
.bossbar .bar { height: 12px; margin-top: 3px; border-color: #ff5f7a88; }
.bossbar .bar i { background: linear-gradient(#ff5f7a, #8a1d2e); }
.nightbar { position: absolute; left: 50%; top: 12px; width: min(360px, 56vw); transform: translateX(-50%); text-align: center; text-shadow: 0 1px 3px #000; font-weight: 900; font-size: 13px; }
.nightbar .bar { height: 9px; margin-top: 3px; }
.nightbar .bar i { background: linear-gradient(#e8c46a, #8a6a1c); }
.bossbar:not([hidden]) ~ .nightbar { top: 50px; }

.prompt { position: absolute; left: 50%; bottom: 128px; transform: translateX(-50%); padding: 7px 12px; border-radius: 12px; background: #0b0c10d0; border: 1px solid #3a3f4c; font-size: 13px; white-space: nowrap; }
.prompt .prog { height: 5px; margin-top: 5px; border-radius: 3px; background: #333; overflow: hidden; }
.prompt .prog i { display: block; height: 100%; width: 0; background: var(--accent); }
.hint { position: absolute; left: 50%; bottom: 170px; transform: translateX(-50%); max-width: min(560px, 90vw); padding: 8px 14px; border-radius: 12px; background: #2a1d0ae0; border: 1px solid #ffb54a88; color: #ffe2b0; font-size: 13px; text-align: center; box-shadow: 0 6px 20px #0008; }
.objarrow { position: absolute; left: 0; top: 0; width: 34px; height: 34px; margin: -17px 0 0 -17px; }
.objarrow i { position: absolute; inset: 0; background: #ffd84a; clip-path: polygon(100% 50%, 20% 10%, 38% 50%, 20% 90%); filter: drop-shadow(0 0 4px #000); }
.objarrow span { position: absolute; top: 32px; left: 50%; transform: translateX(-50%); font-size: 10px; font-weight: 900; color: #ffd84a; text-shadow: 0 1px 2px #000; white-space: nowrap; }

.hud-bottom { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); display: flex; gap: 10px; align-items: flex-end; }
.weapon { min-width: 170px; padding: 7px 11px; border-radius: 12px; border: 1px solid #3a3f4c; background: #0b0c10d8; text-align: left; font-size: 12px; }
.weapon .wn { display: block; font-weight: 900; font-size: 13px; white-space: nowrap; max-width: 210px; overflow: hidden; text-overflow: ellipsis; }
.weapon .wa { font-size: 18px; font-weight: 900; }
.weapon .wa small { font-size: 12px; color: var(--muted); }
.weapon .dur { height: 3px; margin-top: 4px; border-radius: 2px; background: #333; }
.weapon .dur i { display: block; height: 100%; border-radius: 2px; background: var(--good); }
.quickbar { display: flex; gap: 6px; }
.qs { position: relative; width: 50px; height: 50px; padding: 0; border-radius: 12px; border: 1px solid #3a3f4c; background: #0b0c10d8; }
.qs img { width: 34px; height: 34px; margin-top: 3px; }
.qs .k { position: absolute; left: 4px; top: 2px; font-size: 10px; color: var(--muted); }
.qs .n { position: absolute; right: 4px; bottom: 2px; font-size: 12px; font-weight: 900; text-shadow: 0 1px 2px #000; }
.qs.empty { opacity: 0.45; }

.toasts { position: absolute; right: 10px; bottom: 80px; display: grid; gap: 6px; justify-items: end; max-width: min(360px, 70vw); }
.toast { padding: 7px 11px; border-radius: 10px; background: #0b0c10e0; border: 1px solid #3a3f4c; font-size: 12.5px; animation: toastIn 0.25s ease-out; box-shadow: 0 4px 14px #0007; }
.toast.ach { border-color: #ffd84a; background: #2a2208e8; }
.toast.quest { border-color: var(--good); background: #0f2410e8; }
.toast.loot { border-color: var(--blue); }
.toast.bad { border-color: var(--bad); background: #2a0e0ae8; }
@keyframes toastIn { from { transform: translateX(20px); opacity: 0; } }

.buildbar { position: absolute; left: 50%; bottom: 76px; transform: translateX(-50%); display: flex; gap: 4px; max-width: 96vw; overflow-x: auto; padding: 5px; border-radius: 12px; background: #0b0c10e8; border: 1px solid #ffb54a66; scrollbar-width: thin; }
.bt { flex: none; min-width: 56px; padding: 4px 6px; border-radius: 9px; border: 1px solid #3a3f4c; background: #1d2029; font-size: 10.5px; line-height: 1.15; white-space: nowrap; }
.bt[aria-pressed="true"] { border-color: var(--accent); background: #3a2a10; }
.bt small { display: block; color: var(--muted); font-size: 10px; font-weight: 700; }
.bt.ok small { color: var(--good); }

/* ---------- touch ---------- */
.touch { position: absolute; inset: 0; pointer-events: none; }
.stick { position: absolute; bottom: 18px; width: 116px; height: 116px; border-radius: 50%; border: 2px solid #ffffff30; background: #ffffff0c; pointer-events: none; }
#stick-l { left: 14px; }
#stick-r { right: 14px; }
.stick i { position: absolute; left: 50%; top: 50%; width: 48px; height: 48px; margin: -24px 0 0 -24px; border-radius: 50%; background: #ffffff38; border: 2px solid #ffffff60; }
.tbtns { position: absolute; right: 8px; bottom: 146px; display: grid; grid-template-columns: repeat(3, 52px); gap: 5px; pointer-events: auto; }
.tb { height: 42px; border-radius: 12px; border: 1px solid #ffffff40; background: #0b0c10b0; font-size: 10px; font-weight: 900; letter-spacing: 0.02em; touch-action: none; }
.tb.on, .tb:active { background: #3a2a10; border-color: var(--accent); }
.is-touch .hud-bottom { left: 8px; bottom: 146px; transform: none; flex-direction: column; align-items: flex-start; gap: 5px; }
.is-touch .weapon { min-width: 0; width: 192px; padding: 5px 8px; }
.is-touch .weapon .wn { max-width: 176px; font-size: 11.5px; }
.is-touch .quickbar .qs { width: 44px; height: 44px; }
.is-touch .quickbar .qs img { width: 28px; height: 28px; }
.is-touch .prompt { bottom: 262px; }
.is-touch .hint { bottom: 306px; font-size: 12px; }
.is-touch .toasts { bottom: 262px; }
.is-touch .buildbar { bottom: 262px; }
@media (min-width: 700px) { .is-touch .tbtns { right: 150px; bottom: 16px; } .is-touch .hud-bottom { left: 150px; bottom: 12px; } .is-touch .prompt, .is-touch .toasts, .is-touch .buildbar { bottom: 140px; } .is-touch .hint { bottom: 184px; } }
@media (max-height: 480px) { .is-touch .tbtns { bottom: 12px; right: 140px; } .is-touch .hud-bottom { bottom: 12px; left: 140px; flex-direction: row; } .is-touch .weapon { width: 150px; } .is-touch .prompt, .is-touch .toasts, .is-touch .buildbar { bottom: 120px; } .is-touch .hint { display: none; } }

/* ---------- panels ---------- */
.panel { position: absolute; inset: 0; display: grid; place-items: center; padding: 10px; background: #000a; z-index: 20; }
.panel-card { width: min(980px, 100%); height: min(700px, 100%); display: flex; flex-direction: column; border-radius: 18px; background: var(--panel); border: 1px solid var(--line); box-shadow: 0 20px 60px #000c; overflow: hidden; }
.panel-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--panel-2); flex-wrap: wrap; }
.panel-head h2 { margin: 0; font-size: 17px; font-weight: 900; }
.tabs { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.tab { padding: 6px 10px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--muted); font-size: 13px; font-weight: 800; }
.tab[aria-selected="true"] { background: #2a2e3a; border-color: var(--line); color: var(--text); }
.x { width: 34px; height: 34px; border-radius: 10px; border: 1px solid var(--line); background: #252834; font-size: 15px; }
.panel-body { flex: 1; overflow: auto; padding: 12px; -webkit-user-select: text; user-select: text; touch-action: pan-y; }
.cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
.cols3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 720px) { .cols, .cols3 { grid-template-columns: minmax(0, 1fr); } }
.box { padding: 10px; border-radius: 12px; background: #1b1e26; border: 1px solid var(--line); }
.box h3 { margin: 0 0 8px; font-size: 14px; font-weight: 900; color: var(--accent); }
.box h4 { margin: 8px 0 4px; font-size: 13px; }
.muted { color: var(--muted); font-weight: 600; }
.small { font-size: 12px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spacer { flex: 1; }
.btn { padding: 7px 12px; border-radius: 10px; border: 1px solid #4a4f5c; background: #2a2e3a; font-size: 13px; font-weight: 800; }
.btn:hover:not(:disabled) { background: #343948; }
.btn.primary { background: linear-gradient(#ffb54a, #e0842a); color: #1a1208; border-color: #ffcf7a; }
.btn.good { background: #1f4a22; border-color: #6ad66a; }
.btn.danger { background: #4a1f1a; border-color: #e0503a; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn.primary:hover:not(:disabled) { background: linear-gradient(#ffc466, #eb9238); }
.btn.good:hover:not(:disabled) { background: #28602c; }
.btn.danger:hover:not(:disabled) { background: #5e2720; }
.btn.sm { padding: 4px 8px; font-size: 12px; }

.grid-items { display: grid; grid-template-columns: repeat(auto-fill, minmax(56px, 1fr)); gap: 6px; }
.slot { position: relative; aspect-ratio: 1; min-width: 0; padding: 0; border-radius: 10px; border: 2px solid #333844; background: #111318; display: grid; place-items: center; }
.slot img { width: 78%; height: 78%; }
.slot .en { position: absolute; left: 3px; top: 1px; font-size: 10.5px; font-weight: 900; color: #ffd84a; text-shadow: 0 1px 2px #000; }
.slot .lab { position: absolute; left: 0; right: 0; bottom: 1px; font-size: 9px; color: var(--muted); text-align: center; }
.slot .br { position: absolute; right: 3px; top: 1px; font-size: 10px; color: var(--bad); font-weight: 900; }
.slot.sel { box-shadow: 0 0 0 2px #fff; }
.slot.empty { opacity: 0.5; }
.r-scrap { border-color: var(--r-scrap); }
.r-common { border-color: #6a6d76; }
.r-uncommon { border-color: var(--r-uncommon); }
.r-rare { border-color: var(--r-rare); }
.r-epic { border-color: var(--r-epic); box-shadow: inset 0 0 12px #bb72ff44; }
.r-legendary { border-color: var(--r-legendary); box-shadow: inset 0 0 14px #ff9d2e55; }
.t-scrap { color: var(--r-scrap); } .t-common { color: var(--r-common); } .t-uncommon { color: var(--r-uncommon); } .t-rare { color: var(--r-rare); } .t-epic { color: var(--r-epic); } .t-legendary { color: var(--r-legendary); }
.equip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.itemcard { padding: 10px; border-radius: 12px; background: #111318; border: 1px solid var(--line); font-size: 12.5px; }
.itemcard h4 { margin: 0; font-size: 15px; }
.itemcard .kind { color: var(--muted); font-size: 11.5px; margin-bottom: 6px; }
.itemcard ul { margin: 6px 0; padding-left: 16px; }
.itemcard li { margin: 2px 0; }
.itemcard .pw { color: var(--r-legendary); font-style: italic; }
.up { color: var(--good); } .down { color: var(--bad); }
.compare { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 4px 12px; font-size: 12.5px; }
.stats div { display: flex; justify-content: space-between; border-bottom: 1px dashed #2c303b; padding: 2px 0; }
.res-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 4px 8px; font-size: 12px; }
.res-list div { display: flex; align-items: center; gap: 5px; }
.res-list img { width: 20px; height: 20px; }
.list { display: grid; gap: 6px; }
.li { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 10px; background: #1b1e26; border: 1px solid var(--line); font-size: 13px; }
.li.locked { opacity: 0.55; }
.li img.ic { width: 34px; height: 34px; flex: none; }
.li .grow { flex: 1; min-width: 0; }
.li .cost { font-size: 11.5px; color: var(--muted); }
.cost .miss { color: var(--bad); }
.skill { position: relative; }
.skill .pips { color: var(--accent); letter-spacing: 1px; }
.prog-bar { height: 6px; border-radius: 3px; background: #2a2e3a; overflow: hidden; margin-top: 4px; }
.prog-bar i { display: block; height: 100%; background: var(--good); }
.ach.done { border-color: #ffd84a88; background: #262008; }
.tuner { display: grid; gap: 8px; }
.tune-meter { height: 16px; border-radius: 8px; background: #2a2e3a; overflow: hidden; position: relative; }
.tune-meter i { display: block; height: 100%; background: linear-gradient(90deg, #6ad66a, #ffd84a); }
.tune-meter span { position: absolute; inset: 0; text-align: center; font-size: 11px; line-height: 16px; font-weight: 900; }
.tune-result { min-height: 26px; font-weight: 900; font-size: 15px; }
.tune-result.ok { color: var(--good); animation: pop 0.4s; }
.tune-result.bad { color: var(--bad); animation: shake 0.4s; }
@keyframes pop { 30% { transform: scale(1.2); } }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.mapcanvas { width: 100%; max-width: 560px; aspect-ratio: 1; border-radius: 12px; border: 1px solid var(--line); display: block; margin: 0 auto; }
.district { display: grid; gap: 4px; }
.district.locked { opacity: 0.5; }
.pill { display: inline-block; padding: 2px 8px; border-radius: 999px; background: #2a2e3a; font-size: 11px; }
.pill.q { background: #3a2a10; color: #ffd84a; }
.table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.table th, .table td { padding: 5px 6px; border-bottom: 1px solid var(--line); text-align: left; }
textarea { width: 100%; min-height: 110px; border-radius: 10px; border: 1px solid var(--line); background: #0b0c10; color: var(--text); font: 12px ui-monospace, monospace; padding: 8px; }
input[type="text"] { padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: #0b0c10; color: var(--text); font: inherit; }
input[type="range"] { accent-color: var(--accent); }

/* ---------- portraits ---------- */
.portrait { position: relative; display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 14px; overflow: hidden; background: radial-gradient(circle at 50% 35%, var(--c, #555), #111 80%); flex: none; }
.portrait::before { content: attr(data-i); font-size: 1.6em; font-weight: 900; color: #fff; text-shadow: 0 2px 4px #000; }
.portrait img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.portrait.sm { width: 40px; height: 40px; }
.portrait.lg { width: 120px; height: 120px; border-radius: 18px; font-size: 1.6em; }

/* ---------- dialogue ---------- */
.dialog { position: absolute; left: 0; right: 0; bottom: 0; display: flex; justify-content: center; padding: 10px; z-index: 25; background: linear-gradient(transparent, #000c 40%); }
.dlg-card { width: min(860px, 100%); display: flex; gap: 14px; padding: 14px; border-radius: 18px; background: #14161cf2; border: 1px solid var(--line); box-shadow: 0 10px 40px #000c; }
.dlg-portrait .portrait { width: 132px; height: 132px; border-radius: 16px; font-size: 1.8em; }
.dlg-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.dlg-main h3 { margin: 0 0 4px; font-size: 16px; font-weight: 900; }
.dlg-main p { margin: 0 0 10px; font-size: 15px; line-height: 1.45; font-weight: 600; min-height: 3em; }
.dlg-choices { display: flex; flex-direction: column; gap: 5px; }
.dlg-choices .btn { text-align: left; }
.dlg-choices .btn .tag { float: right; font-size: 11px; color: var(--accent); }
@media (max-width: 560px) { .dlg-portrait .portrait { width: 72px; height: 72px; } .dlg-main p { font-size: 13.5px; } }

.bosscard { position: absolute; left: 50%; top: 22%; transform: translateX(-50%); display: flex; gap: 14px; align-items: center; padding: 14px 20px; border-radius: 18px; background: #1a0a10ee; border: 2px solid #ff5f7a; box-shadow: 0 0 40px #ff5f7a55; z-index: 15; animation: bossIn 0.4s ease-out; }
.bosscard h3 { margin: 0; font-size: 22px; font-weight: 900; color: #ffc8d0; }
.bosscard p { margin: 2px 0 0; color: var(--muted); font-size: 13px; }
@keyframes bossIn { from { transform: translate(-50%, -20px) scale(0.9); opacity: 0; } }
.tooltip { position: absolute; z-index: 30; max-width: 300px; pointer-events: none; }

/* ---------- title ---------- */
.title { position: absolute; inset: 0; display: grid; place-items: center; padding: 16px; overflow: auto; z-index: 30; background: radial-gradient(120% 90% at 50% 0%, #3a2410 0%, #120d0a 55%, #07070a 100%); }
.title-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.55; }
.title::after { content: ""; position: absolute; inset: 0; background: radial-gradient(80% 70% at 50% 45%, transparent, #000c); pointer-events: none; }
.title-inner { position: relative; z-index: 1; width: min(560px, 100%); text-align: center; }
.kicker { margin: 0; color: var(--muted); letter-spacing: 0.12em; text-transform: uppercase; font-size: 11px; }
.logo { margin: 4px 0 0; font-size: clamp(44px, 11vw, 84px); font-weight: 900; letter-spacing: -0.02em; line-height: 0.95; text-shadow: 0 4px 24px #000; }
.logo span { color: var(--accent); text-shadow: 0 0 30px #ff9d2e88; }
.sub { margin: 4px 0 10px; font-size: 16px; letter-spacing: 0.3em; text-transform: uppercase; color: #d9c8a6; }
.blurb { margin: 0 auto 16px; max-width: 460px; color: #d8d4c8; font-weight: 600; font-size: 14px; text-shadow: 0 1px 3px #000; }
.title-actions { display: grid; gap: 8px; justify-items: center; }
.title-actions .btn { min-width: 220px; padding: 11px 16px; font-size: 15px; }
.title-note { min-height: 1.2em; color: var(--muted); font-size: 12px; }
.howto { margin-top: 10px; text-align: left; font-size: 12.5px; color: #cfcab8; background: #0008; border-radius: 12px; padding: 8px 12px; }
.howto summary { cursor: pointer; font-weight: 900; }
.newgame { display: grid; gap: 8px; justify-items: center; }

@media (max-width: 640px) {
  .me { width: 46px; height: 46px; }
  .me-info { width: 150px; }
  #minimap { width: 92px; height: 92px; }
  .tracker { top: 128px; width: 190px; }
  .tq p { font-size: 10.5px; }
  .hb { height: 26px; padding: 0 6px; font-size: 10.5px; }
  .hud-buttons { max-width: 130px; }
  .weapon { min-width: 128px; padding: 5px 8px; }
  .weapon .wn { max-width: 140px; font-size: 11.5px; }
  .qs { width: 42px; height: 42px; }
  .qs img { width: 28px; height: 28px; }
}
@media (max-height: 560px) { .tracker { display: none; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
