@font-face { font-family: 'Cinzel Decorative'; font-weight: 700; src: url('/vendor/fonts/cinzel-decorative/files/cinzel-decorative-latin-700-normal.woff2') format('woff2'); font-display: block; }
@font-face { font-family: 'Cinzel Decorative'; font-weight: 900; src: url('/vendor/fonts/cinzel-decorative/files/cinzel-decorative-latin-900-normal.woff2') format('woff2'); font-display: block; }
@font-face { font-family: 'Cinzel'; font-weight: 400; src: url('/vendor/fonts/cinzel/files/cinzel-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Cinzel'; font-weight: 600; src: url('/vendor/fonts/cinzel/files/cinzel-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Cinzel'; font-weight: 800; src: url('/vendor/fonts/cinzel/files/cinzel-latin-800-normal.woff2') format('woff2'); }
@font-face { font-family: 'IM Fell English'; font-style: normal; src: url('/vendor/fonts/im-fell-english/files/im-fell-english-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'IM Fell English'; font-style: italic; src: url('/vendor/fonts/im-fell-english/files/im-fell-english-latin-400-italic.woff2') format('woff2'); }

:root {
  --divider: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%27240%27%20height%3D%2712%27%20viewBox%3D%270%200%20240%2012%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27l%27%20x1%3D%270%27%20x2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3Cstop%20offset%3D%27.5%27%20stop-color%3D%27%23f3d38e%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect%20x%3D%270%27%20y%3D%275%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27url%28%23l%29%27/%3E%3Crect%20x%3D%270%27%20y%3D%276.2%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27%23000%27%20opacity%3D%27.5%27/%3E%3Cpath%20d%3D%27M120%201L125%206L120%2011L115%206Z%27%20fill%3D%27%23f6d890%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%27104%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3Ccircle%20cx%3D%27136%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3C/svg%3E");
  --corner-tl: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%2744%27%20height%3D%2744%27%20viewBox%3D%270%200%2044%2044%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27b%27%20x1%3D%270%27%20y1%3D%270%27%20x2%3D%271%27%20y2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23fff0c0%27/%3E%3Cstop%20offset%3D%27.35%27%20stop-color%3D%27%23d9a44c%27/%3E%3Cstop%20offset%3D%27.7%27%20stop-color%3D%27%237c5018%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23c89342%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg%20transform%3D%27%27%3E%3Cpath%20d%3D%27M1%201H34L29%206H9Q6%206%206%209V29L1%2034Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.8%27/%3E%3Cpath%20d%3D%27M11%2011H24Q20%2014%2017%2014Q14%2014%2014%2017Q14%2020%2011%2024Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%278.5%27%20cy%3D%278.5%27%20r%3D%272.6%27%20fill%3D%27%23fff2c8%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.7%27/%3E%3Ccircle%20cx%3D%278%27%20cy%3D%278%27%20r%3D%271%27%20fill%3D%27%238a5a1c%27/%3E%3C/g%3E%3C/svg%3E"); --corner-tr: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%2744%27%20height%3D%2744%27%20viewBox%3D%270%200%2044%2044%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27b%27%20x1%3D%270%27%20y1%3D%270%27%20x2%3D%271%27%20y2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23fff0c0%27/%3E%3Cstop%20offset%3D%27.35%27%20stop-color%3D%27%23d9a44c%27/%3E%3Cstop%20offset%3D%27.7%27%20stop-color%3D%27%237c5018%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23c89342%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg%20transform%3D%27translate%2844%200%29%20scale%28-1%201%29%27%3E%3Cpath%20d%3D%27M1%201H34L29%206H9Q6%206%206%209V29L1%2034Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.8%27/%3E%3Cpath%20d%3D%27M11%2011H24Q20%2014%2017%2014Q14%2014%2014%2017Q14%2020%2011%2024Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%278.5%27%20cy%3D%278.5%27%20r%3D%272.6%27%20fill%3D%27%23fff2c8%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.7%27/%3E%3Ccircle%20cx%3D%278%27%20cy%3D%278%27%20r%3D%271%27%20fill%3D%27%238a5a1c%27/%3E%3C/g%3E%3C/svg%3E"); --corner-bl: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%2744%27%20height%3D%2744%27%20viewBox%3D%270%200%2044%2044%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27b%27%20x1%3D%270%27%20y1%3D%270%27%20x2%3D%271%27%20y2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23fff0c0%27/%3E%3Cstop%20offset%3D%27.35%27%20stop-color%3D%27%23d9a44c%27/%3E%3Cstop%20offset%3D%27.7%27%20stop-color%3D%27%237c5018%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23c89342%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg%20transform%3D%27translate%280%2044%29%20scale%281%20-1%29%27%3E%3Cpath%20d%3D%27M1%201H34L29%206H9Q6%206%206%209V29L1%2034Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.8%27/%3E%3Cpath%20d%3D%27M11%2011H24Q20%2014%2017%2014Q14%2014%2014%2017Q14%2020%2011%2024Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%278.5%27%20cy%3D%278.5%27%20r%3D%272.6%27%20fill%3D%27%23fff2c8%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.7%27/%3E%3Ccircle%20cx%3D%278%27%20cy%3D%278%27%20r%3D%271%27%20fill%3D%27%238a5a1c%27/%3E%3C/g%3E%3C/svg%3E"); --corner-br: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%2744%27%20height%3D%2744%27%20viewBox%3D%270%200%2044%2044%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27b%27%20x1%3D%270%27%20y1%3D%270%27%20x2%3D%271%27%20y2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23fff0c0%27/%3E%3Cstop%20offset%3D%27.35%27%20stop-color%3D%27%23d9a44c%27/%3E%3Cstop%20offset%3D%27.7%27%20stop-color%3D%27%237c5018%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23c89342%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Cg%20transform%3D%27translate%2844%2044%29%20scale%28-1%20-1%29%27%3E%3Cpath%20d%3D%27M1%201H34L29%206H9Q6%206%206%209V29L1%2034Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.8%27/%3E%3Cpath%20d%3D%27M11%2011H24Q20%2014%2017%2014Q14%2014%2014%2017Q14%2020%2011%2024Z%27%20fill%3D%27url%28%23b%29%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%278.5%27%20cy%3D%278.5%27%20r%3D%272.6%27%20fill%3D%27%23fff2c8%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.7%27/%3E%3Ccircle%20cx%3D%278%27%20cy%3D%278%27%20r%3D%271%27%20fill%3D%27%238a5a1c%27/%3E%3C/g%3E%3C/svg%3E");
  --gold: #e3b45a;
  --gold-hi: #fff0c2;
  --gold-lo: #8a5d22;
  --ink: #f3e6c8;
  --ink-dim: #b9a888;
  --panel: rgba(18, 14, 10, 0.78);
  --panel-edge: rgba(227, 180, 90, 0.35);
  --blood: #b3261e;
  --display: 'Cinzel Decorative', 'Cinzel', Georgia, serif;
  --serif: 'Cinzel', Georgia, 'Times New Roman', serif;
  --body: 'IM Fell English', Georgia, 'Times New Roman', serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #07090b; color: var(--ink); font-family: var(--body); user-select: none; }
#game { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; }
.hidden { display: none !important; }
.screen { position: fixed; inset: 0; z-index: 10; }
.overlay { display: grid; place-items: center; background: radial-gradient(ellipse at center, rgba(10, 8, 6, 0.55), rgba(0, 0, 0, 0.85)); backdrop-filter: blur(6px); z-index: 30; }

/* ------------------------------------------------------------ titles */
.title {
  font-family: var(--display); font-weight: 900; margin: 0; letter-spacing: 0.02em; line-height: 1;
  font-size: clamp(48px, 8.4vw, 132px);
  background: linear-gradient(180deg, #fff6d8 0%, #f2cf7c 28%, #c98a2c 52%, #8a5a1a 62%, #e8bb62 78%, #fff1c9 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 0 #3b2208) drop-shadow(0 10px 22px rgba(0, 0, 0, 0.75)) drop-shadow(0 0 40px rgba(255, 170, 60, 0.18));
}
.title.small { font-size: 54px; }
.subtitle { font-family: var(--body); font-style: italic; font-size: clamp(16px, 1.6vw, 22px); color: var(--ink); opacity: 0.85; margin: 14px 0 0; text-shadow: 0 2px 8px #000; }
.title-ornament { width: 360px; max-width: 70vw; height: 18px; margin: 0 auto 14px; background:
  linear-gradient(90deg, transparent, var(--gold) 20%, var(--gold) 80%, transparent) center/100% 1px no-repeat,
  radial-gradient(circle, var(--gold-hi) 0 3px, var(--gold) 4px 5px, transparent 6px) center/18px 18px no-repeat; opacity: 0.9; }

/* ------------------------------------------------------------ loading */
#loading { display: grid; place-items: center; background: radial-gradient(ellipse at 50% 40%, #1d1710 0%, #070605 70%); z-index: 50; transition: opacity 0.8s; }
#loading.fade { opacity: 0; pointer-events: none; }
.loading-inner { text-align: center; }
.crest { width: 84px; height: 84px; margin: 0 auto 18px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Cpath fill='%23e3b45a' d='M6 58V22h8v8h8v-8h8v8h4v-8h8v8h8v-8h8v36H38V44a6 6 0 0 0-12 0v14z'/%3E%3C/svg%3E") center/contain no-repeat; filter: drop-shadow(0 0 18px rgba(227, 180, 90, 0.5)); animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.06); filter: drop-shadow(0 0 28px rgba(227, 180, 90, 0.8)); } }
.bar { width: 420px; max-width: 80vw; height: 6px; margin: 28px auto 12px; background: rgba(255, 255, 255, 0.08); border: 1px solid var(--panel-edge); border-radius: 4px; overflow: hidden; }
#load-fill { height: 100%; width: 0; background: linear-gradient(90deg, var(--gold-lo), var(--gold), var(--gold-hi)); box-shadow: 0 0 12px var(--gold); transition: width 0.25s; }
#load-text { font-family: var(--serif); letter-spacing: 0.12em; font-size: 13px; color: var(--ink-dim); text-transform: uppercase; }

/* ------------------------------------------------------------ menu */
#menu { display: flex; flex-direction: column; align-items: center; justify-content: center; }
#embers { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.menu-vignette { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(ellipse at 50% 45%, transparent 35%, rgba(0, 0, 0, 0.55) 80%, rgba(0, 0, 0, 0.9) 100%),
  linear-gradient(180deg, rgba(0, 0, 0, 0.35), transparent 30%, transparent 65%, rgba(0, 0, 0, 0.6)); }
.menu-wrap { position: relative; display: flex; flex-direction: column; align-items: center; gap: 34px; animation: rise 1.2s cubic-bezier(.2,.8,.2,1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }
.menu-title { text-align: center; }
.menu-footer { position: absolute; bottom: 14px; font-family: var(--serif); font-size: 11px; letter-spacing: 0.14em; color: rgba(243, 230, 200, 0.4); text-transform: uppercase; }

.panel {
  position: relative; min-width: 380px; max-width: 92vw; padding: 26px 30px; display: flex; flex-direction: column; gap: 12px;
  background: linear-gradient(180deg, rgba(34, 26, 18, 0.86), rgba(14, 11, 8, 0.9));
  border: 1px solid var(--panel-edge); border-radius: 6px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 230, 170, 0.12), inset 0 0 60px rgba(0, 0, 0, 0.5);
  animation: fadein 0.35s ease both;
}
.panel::before, .panel::after { content: ''; position: absolute; width: 18px; height: 18px; border: 2px solid var(--gold); opacity: 0.8; }
.panel::before { top: -3px; left: -3px; border-right: 0; border-bottom: 0; }
.panel::after { bottom: -3px; right: -3px; border-left: 0; border-top: 0; }
@keyframes fadein { from { opacity: 0; transform: translateY(8px); } }
.panel h2 { font-family: var(--serif); font-weight: 800; margin: 0 0 6px; text-align: center; letter-spacing: 0.1em; text-transform: uppercase; font-size: 22px; color: var(--gold); text-shadow: 0 2px 6px #000; }
.main-panel { width: 400px; }

.btn {
  position: relative; display: block; width: 100%; padding: 14px 20px; cursor: pointer; border-radius: 4px;
  font-family: var(--serif); font-weight: 600; font-size: 17px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink);
  background: linear-gradient(180deg, rgba(70, 54, 36, 0.9), rgba(36, 27, 18, 0.95));
  border: 1px solid rgba(227, 180, 90, 0.4);
  box-shadow: inset 0 1px 0 rgba(255, 235, 190, 0.18), inset 0 -2px 0 rgba(0, 0, 0, 0.35), 0 4px 12px rgba(0, 0, 0, 0.4);
  transition: transform 0.12s, border-color 0.2s, box-shadow 0.2s, color 0.2s, background 0.2s; overflow: hidden;
}
.btn::after { content: ''; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, rgba(255, 230, 170, 0.22) 50%, transparent 70%); transform: translateX(-120%); transition: transform 0.6s; }
.btn:hover { border-color: var(--gold); color: #fff; box-shadow: inset 0 1px 0 rgba(255, 235, 190, 0.25), 0 0 22px rgba(227, 180, 90, 0.28), 0 6px 16px rgba(0, 0, 0, 0.5); transform: translateY(-1px); }
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: linear-gradient(180deg, #b27a2c, #6d4312); border-color: var(--gold); color: #fff7e0; text-shadow: 0 1px 2px #2a1604; }
.btn.primary:hover { background: linear-gradient(180deg, #c98d38, #7d4f18); }
.btn.ghost { background: rgba(0, 0, 0, 0.25); }
.btn.small { font-size: 13px; padding: 11px 16px; }
.btn:disabled { opacity: 0.4; pointer-events: none; }
.btn-row { display: flex; gap: 12px; margin-top: 4px; }
.btn-row .btn { flex: 1; }

.name-field, .field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 6px; }
.name-field span, .field span, .settings-grid label { font-family: var(--serif); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-dim); }
input[type="text"], input:not([type]), select {
  font-family: var(--body); font-size: 19px; color: var(--ink); padding: 9px 12px; border-radius: 4px; outline: none; width: 100%;
  background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(227, 180, 90, 0.3); transition: border-color 0.2s, box-shadow 0.2s;
}
input:focus, select:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(227, 180, 90, 0.15); }
select { font-family: var(--serif); font-size: 14px; }
input[type="range"] { accent-color: var(--gold); width: 100%; }
input[type="checkbox"] { accent-color: var(--gold); width: 18px; height: 18px; justify-self: start; }
.hint { margin: 0; font-size: 16px; color: var(--ink-dim); line-height: 1.4; max-width: 420px; }
.settings-grid { display: grid; grid-template-columns: auto 220px; align-items: center; gap: 14px 22px; }

.scan { display: flex; align-items: center; gap: 10px; font-size: 16px; color: var(--ink-dim); }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 0 0 rgba(227, 180, 90, 0.7); animation: pulse 1.6s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 12px rgba(227, 180, 90, 0); } 100% { box-shadow: 0 0 0 0 rgba(227, 180, 90, 0); } }
.game-list, .lobby-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; min-height: 60px; max-height: 280px; overflow: auto; min-width: 440px; }
.game-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-radius: 4px; background: rgba(0, 0, 0, 0.35); border: 1px solid rgba(227, 180, 90, 0.18); cursor: pointer; transition: border-color 0.2s, background 0.2s; }
.game-list li:hover { border-color: var(--gold); background: rgba(227, 180, 90, 0.08); }
.game-list .g-name { font-family: var(--serif); font-weight: 600; font-size: 16px; letter-spacing: 0.06em; }
.game-list .g-meta { font-size: 14px; color: var(--ink-dim); }
.game-list .g-join { font-family: var(--serif); font-size: 12px; letter-spacing: 0.18em; color: var(--gold); }
.game-list .empty { cursor: default; justify-content: center; color: var(--ink-dim); font-style: italic; border-style: dashed; }
.game-list .empty:hover { background: rgba(0, 0, 0, 0.35); border-color: rgba(227, 180, 90, 0.18); }
.lobby-list li { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 4px; background: rgba(0, 0, 0, 0.35); border: 1px solid rgba(227, 180, 90, 0.18); font-family: var(--serif); letter-spacing: 0.06em; }
.lobby-list .swatch { width: 14px; height: 14px; border-radius: 50%; box-shadow: 0 0 10px currentColor; background: currentColor; }
.lobby-list .tag { margin-left: auto; font-size: 11px; letter-spacing: 0.18em; color: var(--gold); text-transform: uppercase; }
.manual summary { cursor: pointer; font-family: var(--serif); font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim); }
.manual-row { display: flex; gap: 10px; margin-top: 10px; }
.manual-row .btn { width: auto; }
.menu-error { margin: 0; padding: 10px 16px; border-radius: 4px; background: rgba(120, 20, 16, 0.6); border: 1px solid rgba(255, 120, 100, 0.4); font-size: 16px; }

.howto { max-width: 460px; font-size: 17px; line-height: 1.45; }
.howto p { margin: 0 0 12px; }
.keys { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 7px; }
kbd { display: inline-block; min-width: 26px; padding: 2px 7px; margin-right: 4px; text-align: center; font-family: var(--serif); font-size: 12px; font-weight: 600; color: var(--ink); background: linear-gradient(#4a3a26, #2a2016); border: 1px solid rgba(227, 180, 90, 0.4); border-bottom-width: 3px; border-radius: 4px; }

/* ------------------------------------------------------------ HUD */
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 20; font-family: var(--serif); }
#dmg-vignette { position: absolute; inset: 0; opacity: 0; background: radial-gradient(ellipse at center, transparent 45%, rgba(160, 10, 0, 0.55) 100%); transition: opacity 0.25s; }
#zoom-vignette { position: absolute; inset: 0; opacity: 0; background: radial-gradient(circle at center, transparent 38%, rgba(0, 0, 0, 0.75) 78%); }
#crosshair { position: absolute; left: 50%; top: 50%; width: 76px; height: 76px; transform: translate(-50%, -50%); }
#crosshair svg { width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 0 1.5px rgba(0, 0, 0, 1)) drop-shadow(0 0 3px rgba(0, 0, 0, 0.6)); }
#crosshair .ring-bg { fill: none; stroke: rgba(255, 255, 255, 0.12); stroke-width: 2; }
#crosshair .ring { fill: none; stroke: var(--gold-hi); stroke-width: 3; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; stroke-dasharray: 113.1; stroke-dashoffset: 0; opacity: 0.85; }
#crosshair .dot { fill: #fff; }
#crosshair .ticks { stroke: rgba(255, 255, 255, 0.92); stroke-width: 2.6; stroke-linecap: round; transition: transform 0.15s; transform-origin: 50% 50%; }
#crosshair.zoomed .ticks { transform: scale(0.72); }
#crosshair.zoomed .ring, #crosshair.zoomed .ring-bg { opacity: 0.35; }
#hitmarker { position: absolute; inset: 14px; opacity: 0; background:
  linear-gradient(45deg, transparent 46%, #fff 46% 54%, transparent 54%) top left/12px 12px no-repeat,
  linear-gradient(-45deg, transparent 46%, #fff 46% 54%, transparent 54%) top right/12px 12px no-repeat,
  linear-gradient(-45deg, transparent 46%, #fff 46% 54%, transparent 54%) bottom left/12px 12px no-repeat,
  linear-gradient(45deg, transparent 46%, #fff 46% 54%, transparent 54%) bottom right/12px 12px no-repeat; }
#hitmarker.show { animation: hit 0.28s ease-out; }
#hitmarker.head { filter: sepia(1) saturate(8) hue-rotate(-20deg) brightness(1.1); }
#hitmarker.kill { filter: sepia(1) saturate(10) hue-rotate(-50deg); }
@keyframes hit { 0% { opacity: 1; transform: scale(1.3); } 100% { opacity: 0; transform: scale(1); } }

.hud-top { position: absolute; top: 18px; left: 50%; transform: translateX(-50%); display: flex; align-items: center; gap: 22px; }
.castle-hp { display: flex; align-items: center; gap: 10px; }
.castle-icon { width: 30px; height: 30px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Cpath fill='%23e3b45a' d='M6 58V22h8v8h8v-8h8v8h4v-8h8v8h8v-8h8v36H38V44a6 6 0 0 0-12 0v14z'/%3E%3C/svg%3E") center/contain no-repeat; filter: drop-shadow(0 2px 3px #000); }
.hp-bar { position: relative; width: 380px; height: 20px; border-radius: 3px; background: rgba(0, 0, 0, 0.55); border: 1px solid rgba(227, 180, 90, 0.5); box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5), inset 0 0 8px #000; overflow: hidden; }
#hp-ghost, #hp-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; }
#hp-ghost { background: rgba(255, 220, 180, 0.6); transition: width 0.9s ease 0.25s; }
#hp-fill { background: linear-gradient(180deg, #e7503f, #9b1b12 60%, #6b0f0a); box-shadow: inset 0 1px 0 rgba(255, 200, 180, 0.5); transition: width 0.15s; z-index: 1; }
#hp-fill.healthy { background: linear-gradient(180deg, #d9b659, #a0761e 60%, #6b4b10); }
#hp-text { position: absolute; inset: 0; z-index: 2; display: grid; place-items: center; font-size: 12px; font-weight: 800; letter-spacing: 0.1em; text-shadow: 0 1px 2px #000; }
.wave-box { text-align: center; min-width: 140px; padding: 6px 16px; background: linear-gradient(180deg, rgba(40, 28, 16, 0.85), rgba(16, 11, 7, 0.85)); border: 1px solid rgba(227, 180, 90, 0.6); border-radius: 3px; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 230, 170, 0.15); }
#wave-label { font-family: var(--display); font-weight: 700; font-size: 20px; color: var(--gold); text-shadow: 0 2px 4px #000; }
#wave-sub { font-family: var(--body); font-size: 14px; color: var(--ink-dim); }

.announce { position: absolute; top: 12%; left: 0; right: 0; text-align: center; opacity: 0; }
.announce.show { animation: announce 2.4s ease both; }
.announce .a-title { font-family: var(--display); font-weight: 900; font-size: 48px; color: transparent; background: linear-gradient(180deg, #fff6d8, #e8b85a 50%, #9b6620); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 4px 0 #2b1805) drop-shadow(0 0 30px rgba(0, 0, 0, 0.8)); }
.announce .a-sub { font-family: var(--body); font-style: italic; font-size: 24px; color: var(--ink); text-shadow: 0 2px 8px #000; margin-top: 4px; }
.announce.danger .a-title { background: linear-gradient(180deg, #ffd9cf, #e0513b 50%, #7a140c); -webkit-background-clip: text; background-clip: text; }
@keyframes announce { 0% { opacity: 0; transform: scale(1.25); letter-spacing: 0.3em; } 12% { opacity: 1; transform: scale(1); letter-spacing: 0.02em; } 80% { opacity: 1; } 100% { opacity: 0; transform: translateY(-14px); } }

#killfeed { position: absolute; top: 20px; right: 22px; list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
#killfeed li { font-family: var(--body); font-size: 16px; padding: 4px 12px; background: rgba(0, 0, 0, 0.5); border-right: 2px solid var(--gold); animation: feed 5s ease both; }
#killfeed li b { font-family: var(--serif); font-weight: 600; font-size: 13px; letter-spacing: 0.06em; }
#killfeed li .hs { color: #ffb347; font-family: var(--serif); font-size: 11px; letter-spacing: 0.12em; margin-left: 6px; }
@keyframes feed { 0% { opacity: 0; transform: translateX(20px); } 8%, 85% { opacity: 1; transform: none; } 100% { opacity: 0; } }

.hud-stats { position: absolute; bottom: 24px; right: 26px; display: flex; gap: 18px; }
.hud-stats div { display: flex; flex-direction: column; align-items: flex-end; padding: 6px 12px; background: rgba(0, 0, 0, 0.4); border-bottom: 2px solid rgba(227, 180, 90, 0.5); }
.hud-stats .k { font-size: 10px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-dim); }
.hud-stats span:last-child { font-size: 22px; font-weight: 800; color: var(--ink); text-shadow: 0 2px 4px #000; }
#radar { position: absolute; left: 22px; bottom: 22px; width: 170px; height: 170px; border-radius: 50%; }
#fps { position: fixed; z-index: 70; pointer-events: none; top: 8px; left: 10px; font-family: ui-monospace, monospace; font-size: 12px; color: #9f9; text-shadow: 0 1px 2px #000; }
#toast { position: absolute; bottom: 22%; left: 0; right: 0; text-align: center; font-family: var(--body); font-style: italic; font-size: 22px; text-shadow: 0 2px 6px #000; opacity: 0; transition: opacity 0.4s; }
#toast.show { opacity: 1; }

#scoreboard, .over-table { font-family: var(--serif); }
#scoreboard { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); min-width: 560px; padding: 20px 26px; background: var(--panel); border: 1px solid var(--panel-edge); border-radius: 6px; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6); }
#scoreboard h3 { margin: 0 0 12px; text-align: center; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); }
table { width: 100%; border-collapse: collapse; }
th { font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-dim); text-align: right; padding: 6px 10px; border-bottom: 1px solid rgba(227, 180, 90, 0.3); }
th:first-child, td:first-child { text-align: left; }
td { padding: 8px 10px; text-align: right; font-size: 15px; border-bottom: 1px solid rgba(255, 255, 255, 0.05); }
td .swatch { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 8px; background: currentColor; box-shadow: 0 0 8px currentColor; }

.pause-panel { width: 360px; }
.over-panel { width: 620px; align-items: stretch; }
.over-title { font-family: var(--display) !important; font-size: 40px !important; text-transform: none !important; letter-spacing: 0.02em !important; color: transparent !important; background: linear-gradient(180deg, #ffd9cf, #d9503a 50%, #6a120a); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 3px 0 #2b0805); }
.over-sub { text-align: center; margin: 0 0 10px; font-size: 19px; font-style: italic; color: var(--ink); }
.over-table { margin-bottom: 8px; }

#click-resume { position: fixed; inset: 0; z-index: 25; display: grid; place-items: center; }

/* ============================================================ v2: HUD */
#visor { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(ellipse 120% 95% at 50% 50%, transparent 70%, rgba(180, 220, 255, 0.07) 86%, rgba(20, 30, 40, 0.5) 100%),
  linear-gradient(115deg, transparent 20%, rgba(255, 255, 255, 0.035) 24%, transparent 30%); }
#scope { position: absolute; inset: 0; background: radial-gradient(circle at center, transparent 0 31vh, #000 31.2vh); }
.scope-ring { position: absolute; left: 50%; top: 50%; width: 62vh; height: 62vh; transform: translate(-50%, -50%); border-radius: 50%; box-shadow: inset 0 0 60px rgba(0, 0, 0, 0.8), inset 0 0 0 3px rgba(0, 0, 0, 0.9); }
.scope-cross { position: absolute; left: 50%; top: 50%; width: 62vh; height: 62vh; transform: translate(-50%, -50%); background:
  linear-gradient(#000, #000) center/100% 1.5px no-repeat, linear-gradient(#000, #000) center/1.5px 100% no-repeat,
  radial-gradient(circle, #ff3a2a 0 2px, transparent 3px) center/100% 100% no-repeat; }
#crosshair.targeting .ring, #crosshair.targeting .ticks { stroke: #ff5a3a; }
#prompt { position: absolute; left: 50%; top: 62%; transform: translateX(-50%); font-family: var(--serif); font-weight: 800; font-size: 15px; letter-spacing: 0.12em; text-transform: uppercase; padding: 8px 16px; background: rgba(0, 0, 0, 0.55); border: 1px solid rgba(227, 180, 90, 0.5); opacity: 0; transition: opacity 0.2s; }
#prompt.show { opacity: 1; }
.loadout { position: absolute; right: 26px; bottom: 92px; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.lo-weapon { font-family: var(--serif); font-weight: 800; letter-spacing: 0.04em; font-weight: 700; font-size: 26px; color: var(--ink); text-shadow: 0 2px 6px #000; }
.lo-slots, .lo-abilities { display: flex; gap: 8px; }
.lo-slot, .lo-ab { position: relative; display: flex; align-items: center; gap: 8px; padding: 5px 10px; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 255, 255, 0.12); font-family: var(--serif); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-dim); overflow: hidden; }
.lo-slot.active { border-color: var(--gold); color: var(--ink); }
.lo-slot.alien.active { border-color: #6dff5a; box-shadow: 0 0 14px rgba(109, 255, 90, 0.35); }
.lo-ab i { position: absolute; left: 0; bottom: 0; height: 2px; width: var(--fill, 0%); background: var(--gold); }
.lo-ab.ready { color: var(--ink); border-color: rgba(227, 180, 90, 0.7); }
.lo-ab.strike.ready { border-color: #ff5a3a; color: #ffd0c0; box-shadow: 0 0 16px rgba(255, 90, 58, 0.4); animation: pulse2 1.2s infinite; }
.lo-ab.lion.ready { border-color: #ffb040; color: #ffe2b0; box-shadow: 0 0 16px rgba(255, 176, 64, 0.4); animation: pulse2 1.2s infinite; }
.lo-ab.nuke.ready { border-color: #ffe04a; color: #fff6c0; box-shadow: 0 0 22px rgba(255, 224, 74, 0.6); animation: pulse2 0.8s infinite; }
.lo-ab kbd, .lo-slot kbd { min-width: 20px; padding: 1px 5px; font-size: 11px; }
@keyframes pulse2 { 50% { box-shadow: 0 0 4px rgba(255, 90, 58, 0.1); } }

/* ============================================================ v3: orbital, boons */
#boons { position: absolute; left: 50%; top: 84px; transform: translateX(-50%); display: flex; gap: 10px; }
.boon { font-family: var(--serif); font-size: 12px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; padding: 5px 12px; border: 1px solid #5fd4ff; color: #cff3ff; background: rgba(10, 40, 60, 0.6); box-shadow: 0 0 14px rgba(95, 212, 255, 0.4); }
#boon-over { border-color: #b36bff; color: #ecd8ff; background: rgba(40, 10, 60, 0.6); box-shadow: 0 0 14px rgba(179, 107, 255, 0.4); }
.lo-ab.orbital.ready { border-color: #b36bff; color: #ecd8ff; box-shadow: 0 0 18px rgba(179, 107, 255, 0.5); animation: pulse2 1.2s infinite; }
#orbital { position: absolute; inset: 0; }
.orb-frame { position: absolute; inset: 0; background:
  radial-gradient(circle 44vh at 50% 50%, transparent 97%, rgba(0, 0, 0, 0.85) 99%, #07080c 100%),
  repeating-linear-gradient(0deg, rgba(120, 200, 255, 0.04) 0 2px, transparent 2px 4px); }
.orb-frame::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle 44vh at 50% 50%, transparent 97%, rgba(160, 110, 255, 0.6) 98.2%, transparent 99.5%); }
.orb-reticle { position: absolute; left: 50%; top: 50%; width: 120px; height: 120px; transform: translate(-50%, -50%); border: 2px solid rgba(200, 160, 255, 0.85); border-radius: 50%; box-shadow: 0 0 18px rgba(179, 107, 255, 0.6); animation: spin 8s linear infinite; }
.orb-reticle i { position: absolute; width: 14px; height: 2px; background: #e6d4ff; left: 50%; top: 50%; }
.orb-reticle i:nth-child(1) { transform: translate(-50%, -50%) translateX(-70px); }
.orb-reticle i:nth-child(2) { transform: translate(-50%, -50%) translateX(70px); }
.orb-reticle i:nth-child(3) { transform: translate(-50%, -50%) rotate(90deg) translateX(-70px); }
.orb-reticle i:nth-child(4) { transform: translate(-50%, -50%) rotate(90deg) translateX(70px); }
.orb-top, .orb-bottom { white-space: nowrap; position: absolute; left: 50%; transform: translateX(-50%); display: flex; gap: 24px; align-items: center; padding: 8px 22px; font-family: var(--serif); font-size: 13px; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink, #f3e6c8); text-shadow: 0 2px 8px rgba(0, 0, 0, 0.9); background: linear-gradient(90deg, transparent, rgba(12, 8, 20, 0.72) 18%, rgba(12, 8, 20, 0.72) 82%, transparent); border-top: 1px solid rgba(214, 178, 106, 0.55); border-bottom: 1px solid rgba(214, 178, 106, 0.55); }
.orb-top { top: 9%; }
.orb-bottom { bottom: 9%; }
.orb-title { font-family: var(--serif); font-weight: 800; color: var(--gold-hi, #f6d48a); }
#orb-coords { font-variant-numeric: tabular-nums; color: rgba(243, 230, 200, 0.8); }
.orb-bar { width: 260px; height: 6px; border: 1px solid rgba(214, 178, 106, 0.7); background: rgba(0, 0, 0, 0.4); }
#orb-fill { height: 100%; width: 100%; background: linear-gradient(90deg, #7a3cff, #e0c8ff); box-shadow: 0 0 12px #b36bff; }
.orb-hint { opacity: 0.7; }
#warp { position: absolute; inset: 0; background: radial-gradient(circle, #fff 0%, #cdb8ff 40%, rgba(120, 80, 255, 0) 75%); opacity: 0; pointer-events: none; }
#warp.go { animation: warp 0.9s ease-out; }
@keyframes warp { 0% { opacity: 0; transform: scale(0.3); } 25% { opacity: 1; transform: scale(1.2); } 100% { opacity: 0; transform: scale(2.4); } }

#photo-flash { position: fixed; inset: 0; background: #fff; opacity: 0; pointer-events: none; z-index: 60; }
#photo-flash.go { animation: shot 0.35s ease-out; }
@keyframes shot { 0% { opacity: 0.8; } 100% { opacity: 0; } }

#orb-marks { position: absolute; inset: 0; }
#orb-ring { display: none; position: absolute; left: 0; top: 0; border-radius: 50%; border: 2px dashed rgba(255, 230, 90, 0.85); box-shadow: 0 0 30px rgba(255, 220, 60, 0.35), inset 0 0 60px rgba(255, 200, 40, 0.25); }
#orbital.nuke #orb-ring { display: block; }
#orbital.nuke .orb-reticle i { border-color: #ffe04a; }
#orbital.nuke .orb-title { color: #ffe04a; }
#orb-marks i { position: absolute; left: 0; top: 0; background: linear-gradient(#fff,#fff) top left/30% 2px no-repeat, linear-gradient(#fff,#fff) top left/2px 30% no-repeat, linear-gradient(#fff,#fff) top right/30% 2px no-repeat, linear-gradient(#fff,#fff) top right/2px 30% no-repeat, linear-gradient(#fff,#fff) bottom left/30% 2px no-repeat, linear-gradient(#fff,#fff) bottom left/2px 30% no-repeat, linear-gradient(#fff,#fff) bottom right/30% 2px no-repeat, linear-gradient(#fff,#fff) bottom right/2px 30% no-repeat; filter: drop-shadow(0 0 3px rgba(255,255,255,0.9)); }
#orb-marks i.air { background: linear-gradient(#ff5a3a,#ff5a3a) top left/30% 2px no-repeat, linear-gradient(#ff5a3a,#ff5a3a) top left/2px 30% no-repeat, linear-gradient(#ff5a3a,#ff5a3a) top right/30% 2px no-repeat, linear-gradient(#ff5a3a,#ff5a3a) top right/2px 30% no-repeat, linear-gradient(#ff5a3a,#ff5a3a) bottom left/30% 2px no-repeat, linear-gradient(#ff5a3a,#ff5a3a) bottom left/2px 30% no-repeat, linear-gradient(#ff5a3a,#ff5a3a) bottom right/30% 2px no-repeat, linear-gradient(#ff5a3a,#ff5a3a) bottom right/2px 30% no-repeat; filter: drop-shadow(0 0 3px rgba(255,90,58,0.9)); }

#loc-marks { position: absolute; inset: 0; pointer-events: none; }
#loc-marks i { --c: #6bffd8; position: absolute; left: 0; top: 0; background: linear-gradient(var(--c),var(--c)) top left/28% 2px no-repeat, linear-gradient(var(--c),var(--c)) top left/2px 28% no-repeat, linear-gradient(var(--c),var(--c)) top right/28% 2px no-repeat, linear-gradient(var(--c),var(--c)) top right/2px 28% no-repeat, linear-gradient(var(--c),var(--c)) bottom left/28% 2px no-repeat, linear-gradient(var(--c),var(--c)) bottom left/2px 28% no-repeat, linear-gradient(var(--c),var(--c)) bottom right/28% 2px no-repeat, linear-gradient(var(--c),var(--c)) bottom right/2px 28% no-repeat; filter: drop-shadow(0 0 3px var(--c)); opacity: 0.85; }
#loc-marks i.air { --c: #ff6a4a; }
#loc-marks i.big { --c: #ffd24a; }
#loc-marks i b { position: absolute; left: 50%; top: 100%; transform: translate(-50%, 3px); font: 600 10px/1 var(--serif); letter-spacing: 0.08em; color: var(--c); white-space: nowrap; text-shadow: 0 1px 3px #000; }
#hud.orbital-mode #loc-marks { display: none; }

#ammo { display: flex; align-items: baseline; gap: 8px; font-family: var(--serif); text-shadow: 0 2px 6px #000; }
#ammo-n { font-size: 40px; font-weight: 800; color: var(--ink); line-height: 1; }
#ammo-max { font-size: 16px; color: var(--ink-dim); }
#ammo.low #ammo-n { color: #ff7a5a; }
#ammo { flex-wrap: wrap; justify-content: flex-end; }
#ammo .ammo-r { display: none; position: relative; flex-basis: 100%; text-align: right; font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold); padding-bottom: 4px; }
#ammo.reloading .ammo-r { display: inline-block; }
#ammo-bar { position: absolute; left: 0; bottom: 0; height: 2px; background: var(--gold); }

#hud.orbital-mode .hud-top, #hud.orbital-mode #killfeed, #hud.orbital-mode #announce, #hud.orbital-mode #boons { display: none; }

.lo-slot span { display: none; }
.lo-slot.alien span { display: inline; }

/* ============================================================ loading */
#loading { background: #05040a; overflow: hidden; }
#stars { position: absolute; inset: 0; width: 100%; height: 100%; }
.load-shade { position: absolute; inset: 0; pointer-events: none; background:
  radial-gradient(ellipse 70% 55% at 50% 30%, rgba(5, 4, 10, 0.55), transparent 70%),
  linear-gradient(180deg, transparent 72%, rgba(3, 2, 6, 0.85) 100%),
  radial-gradient(ellipse 120% 90% at 50% 50%, transparent 55%, rgba(0, 0, 0, 0.7) 100%); }
.loading-inner { position: absolute; left: 0; right: 0; top: 10vh; display: flex; flex-direction: column; align-items: center; text-align: center; z-index: 1; animation: rise 1.4s cubic-bezier(.2,.8,.2,1) both; }
.load-kicker, .kicker { font-family: var(--serif); font-weight: 600; font-size: clamp(12px, min(1.35vh, 0.8vw), 20px); letter-spacing: 0.55em; text-transform: uppercase; color: rgba(227, 180, 90, 0.85); margin: 0 0 18px; text-shadow: 0 1px 6px #000; }
.load-kicker { padding-left: 0.55em; }
.load-title { font-size: clamp(48px, 6.2vw, 132px); }
.rule { position: relative; width: min(440px, 60vw); height: 14px; margin: 22px auto 16px; background: linear-gradient(90deg, transparent, rgba(227, 180, 90, 0.75) 25%, rgba(255, 236, 190, 0.9) 50%, rgba(227, 180, 90, 0.75) 75%, transparent) center/100% 1px no-repeat; }
.rule i { position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; transform: translate(-50%, -50%) rotate(45deg); background: var(--gold-hi); box-shadow: 0 0 10px rgba(255, 210, 130, 0.9), 0 0 0 3px rgba(5, 4, 10, 0.9), 0 0 0 4px rgba(227, 180, 90, 0.6); }
.rule.left { margin: 20px 0 12px; width: min(380px, 80%); background: linear-gradient(90deg, rgba(227, 180, 90, 0.8), rgba(227, 180, 90, 0.35) 60%, transparent) center/100% 1px no-repeat; }
.rule.left i { left: 0; transform: translate(0, -50%) rotate(45deg); }
.load-tag { margin: 0; font-style: italic; font-size: clamp(17px, 1.35vw, 26px); color: var(--ink); opacity: 0.8; letter-spacing: 0.02em; text-shadow: 0 2px 10px #000; }
.load-foot { position: absolute; left: 0; right: 0; bottom: 7vh; display: flex; flex-direction: column; align-items: center; z-index: 1; }
.load-bar { width: min(640px, 80vw); }
.load-meta { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 12px; font-family: var(--serif); font-size: 12px; letter-spacing: 0.24em; text-transform: uppercase; color: rgba(243, 230, 200, 0.72); text-shadow: 0 1px 4px #000; }
#load-pct { color: var(--gold-hi); font-weight: 600; font-size: 13px; letter-spacing: 0.08em; font-variant-numeric: tabular-nums; }
.load-bar .bar { position: relative; width: 100%; height: 3px; margin: 0; border: 0; border-radius: 0; overflow: visible; background: linear-gradient(90deg, rgba(227, 180, 90, 0.05), rgba(227, 180, 90, 0.2) 50%, rgba(227, 180, 90, 0.05)); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5); }
.load-bar .bar::before, .load-bar .bar::after { content: ''; position: absolute; top: 50%; width: 7px; height: 7px; background: #120d08; border: 1px solid rgba(227, 180, 90, 0.8); transform: translateY(-50%) rotate(45deg); }
.load-bar .bar::before { left: -14px; }
.load-bar .bar::after { right: -14px; }
#load-fill { position: relative; height: 100%; width: 0; background: linear-gradient(90deg, rgba(138, 93, 34, 0.2), var(--gold) 70%, var(--gold-hi)); box-shadow: 0 0 10px rgba(227, 180, 90, 0.55); transition: width 0.5s cubic-bezier(.3,.7,.3,1); }
#load-fill::after { content: ''; position: absolute; right: -14px; top: 50%; width: 28px; height: 28px; transform: translateY(-50%); border-radius: 50%; background: radial-gradient(circle, #fff 0 2px, rgba(255, 230, 170, 0.9) 3px, rgba(255, 170, 70, 0.35) 7px, transparent 14px); animation: tipglow 1.4s ease-in-out infinite; }
@keyframes tipglow { 50% { transform: translateY(-50%) scale(1.35); opacity: 0.8; } }
.tip { margin: 30px 0 0; max-width: min(860px, 88vw); display: flex; gap: 14px; align-items: baseline; justify-content: center; text-align: left; font-size: clamp(16px, 1.1vw, 21px); color: var(--ink); opacity: 0; transform: translateY(4px); transition: opacity 0.7s, transform 0.7s; text-shadow: 0 1px 6px #000; }
.tip.in { opacity: 0.88; transform: none; }
.tip-k { flex: none; font-family: var(--serif); font-size: 10px; font-weight: 800; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold); padding: 3px 0 3px 12px; border-left: 2px solid var(--gold); }

/* ============================================================ menu */
#menu { display: block; }
.menu-scrim { position: absolute; inset: 0; pointer-events: none; background:
  linear-gradient(90deg, rgba(8, 6, 4, 0.82) 0%, rgba(8, 6, 4, 0.6) 26%, rgba(8, 6, 4, 0.12) 52%, transparent 62%, rgba(8, 6, 4, 0.2) 80%, rgba(8, 6, 4, 0.55) 100%); }
.menu-vignette { background:
  radial-gradient(ellipse 110% 90% at 50% 45%, transparent 50%, rgba(0, 0, 0, 0.55) 85%, rgba(0, 0, 0, 0.85) 100%),
  linear-gradient(180deg, rgba(0, 0, 0, 0.45), transparent 22%, transparent 70%, rgba(0, 0, 0, 0.7)); }
.menu-layout { position: absolute; inset: 0; display: flex; align-items: center; justify-content: space-between; padding: 6vh 6vw 8vh; gap: 3vw; }
.menu-left { position: relative; z-index: 1; display: flex; flex-direction: column; gap: clamp(20px, 4.5vh, 72px); max-width: min(900px, 44vw); animation: rise 1s cubic-bezier(.2,.8,.2,1) both; }
.menu-title { text-align: left; }
.menu-title .kicker { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.menu-title .kicker::before { content: ''; width: 40px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.menu-title .title { font-size: clamp(54px, min(6.2vw, 11.5vh), 200px); line-height: 0.92; }
.menu-title .title span { display: block; }
.menu-title .subtitle { margin: 0; font-size: clamp(17px, min(1.3vw, 2.3vh), 36px); }
.main-panel { width: auto; min-width: 0; padding: 0; background: none; border: 0; border-radius: 0; box-shadow: none; }
.main-panel::before, .main-panel::after { display: none; }
.menu-list { display: flex; flex-direction: column; gap: 2px; margin: 0; }
.mbtn { all: unset; position: relative; display: flex; flex-direction: column; cursor: pointer; padding: 11px 16px 11px 34px; margin-left: -34px; opacity: 0; animation: mbin 0.7s cubic-bezier(.2,.8,.2,1) forwards; }
.mbtn:nth-child(1) { animation-delay: 0.25s; } .mbtn:nth-child(2) { animation-delay: 0.33s; } .mbtn:nth-child(3) { animation-delay: 0.41s; }
.mbtn:nth-child(5) { animation-delay: 0.49s; } .mbtn:nth-child(6) { animation-delay: 0.57s; }
@keyframes mbin { from { opacity: 0; transform: translateX(-14px); } to { opacity: 1; transform: none; } }
.mbtn::before { content: ''; position: absolute; left: 12px; top: calc(11px + 0.62em); width: 8px; height: 8px; background: var(--gold-hi); transform: translateY(-50%) rotate(45deg) scale(0); box-shadow: 0 0 12px rgba(255, 200, 110, 0.9); transition: transform 0.25s cubic-bezier(.3,1.6,.5,1); }
.mbtn::after { content: ''; position: absolute; left: 34px; right: 30%; bottom: 6px; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); transform: scaleX(0); transform-origin: left; transition: transform 0.35s cubic-bezier(.2,.8,.2,1); }
.mbtn:hover::before, .mbtn:focus-visible::before { transform: translateY(-50%) rotate(45deg) scale(1); }
.mbtn:hover::after, .mbtn:focus-visible::after { transform: scaleX(1); }
.mb-t { font-family: var(--serif); font-weight: 600; font-size: clamp(20px, min(1.55vw, 2.75vh), 44px); letter-spacing: 0.14em; text-transform: uppercase; color: rgba(243, 230, 200, 0.86); text-shadow: 0 2px 10px rgba(0, 0, 0, 0.9); transition: color 0.2s, transform 0.3s cubic-bezier(.2,.8,.2,1), letter-spacing 0.3s; }
.mb-s { font-size: clamp(14px, min(0.95vw, 1.7vh), 26px); font-style: italic; color: var(--ink-dim); opacity: 0.75; margin-top: 2px; transition: opacity 0.2s, transform 0.3s cubic-bezier(.2,.8,.2,1); text-shadow: 0 1px 6px #000; }
.mbtn:hover .mb-t, .mbtn:focus-visible .mb-t { color: #fff6de; transform: translateX(6px); text-shadow: 0 0 18px rgba(255, 190, 90, 0.45), 0 2px 10px #000; }
.mbtn:hover .mb-s, .mbtn:focus-visible .mb-s { opacity: 1; transform: translateX(6px); }
.mbtn:active .mb-t { transform: translateX(6px) scale(0.98); }
.mbtn.primary .mb-t { font-weight: 800; font-size: clamp(26px, min(2.1vw, 3.7vh), 58px); color: transparent; background: linear-gradient(180deg, #fffaf0 10%, #f6d48a 55%, #d99e40); -webkit-background-clip: text; background-clip: text; text-shadow: none; filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.9)); }
.mbtn.primary:hover .mb-t { filter: drop-shadow(0 0 14px rgba(255, 190, 90, 0.5)) drop-shadow(0 2px 6px #000); }
.mbtn.primary { padding-bottom: 16px; }
.mbtn.primary::before { top: calc(11px + 0.8em); }
.mbtn.minor .mb-t { font-size: clamp(15px, min(1.05vw, 1.9vh), 30px); letter-spacing: 0.22em; color: rgba(243, 230, 200, 0.86); }
.mbtn.minor { padding-top: 7px; padding-bottom: 7px; }
.mbtn.minor::before { top: calc(7px + 0.62em); }
.mbtn.minor::after { bottom: 3px; }
.mb-sep { width: 220px; height: 1px; margin: 12px 0 10px; background: linear-gradient(90deg, rgba(227, 180, 90, 0.45), transparent); }

.menu-left > .panel:not(.main-panel) { width: min(520px, 90vw); align-self: flex-start; padding: 28px 32px; background: linear-gradient(180deg, rgba(30, 23, 16, 0.78), rgba(12, 9, 7, 0.86)); backdrop-filter: blur(10px) saturate(0.9); border-color: rgba(227, 180, 90, 0.28); }
.menu-left > .panel h2 { text-align: left; font-size: 20px; letter-spacing: 0.22em; padding-bottom: 12px; margin-bottom: 8px; border-bottom: 1px solid rgba(227, 180, 90, 0.2); }
.game-list, .lobby-list { min-width: 0; }

.menu-right { position: relative; z-index: 1; display: flex; align-items: center; animation: rise 1.3s 0.2s cubic-bezier(.2,.8,.2,1) both; }
.dog-card { --w: clamp(300px, min(28vw, 50vh), 820px); position: relative; width: var(--w); display: flex; flex-direction: column; align-items: center; }
.dog-stage { position: relative; width: 100%; height: min(calc(var(--w) * 1.36), 62vh); }
.stage-dof { position: absolute; inset: -10% -18% -6%; backdrop-filter: blur(9px) brightness(0.6) saturate(0.75); -webkit-mask: radial-gradient(ellipse 50% 50% at 50% 55%, #000 55%, transparent 100%); mask: radial-gradient(ellipse 50% 50% at 50% 55%, #000 55%, transparent 100%); }
.stage-light { position: absolute; inset: -6% -10% 0; pointer-events: none; background:
  radial-gradient(ellipse 34% 46% at 50% 44%, rgba(255, 190, 110, 0.2), transparent 70%),
  radial-gradient(ellipse 46% 12% at 50% 90%, rgba(255, 170, 80, 0.22), transparent 70%);
  animation: stagepulse 6s ease-in-out infinite alternate; }
@keyframes stagepulse { to { opacity: 0.8; } }
#dog-preview { position: relative; width: 100%; height: 100%; display: block; }
.dog-info { position: relative; width: calc(100% - 40px); margin-top: 4px; padding: 18px 26px 22px; display: flex; flex-direction: column; align-items: center; gap: 6px; background: linear-gradient(180deg, rgba(26, 20, 14, 0.9), rgba(10, 8, 6, 0.92)); border: 1px solid rgba(227, 180, 90, 0.32); box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 230, 170, 0.12); }
.dog-info::before, .dog-info::after { content: ''; position: absolute; top: -5px; width: 9px; height: 9px; background: #120d08; border: 1px solid var(--gold); transform: rotate(45deg); }
.dog-info::before { left: -5px; } .dog-info::after { right: -5px; }
.dog-label { font-family: var(--serif); font-size: clamp(10px, min(1.1vh, 0.65vw), 16px); font-weight: 600; letter-spacing: 0.4em; text-transform: uppercase; color: var(--ink-dim); padding-left: 0.4em; }
.dog-breed { font-family: var(--display); font-weight: 700; font-size: clamp(22px, min(1.7vw, 3vh), 46px); letter-spacing: 0.02em; color: transparent; background: linear-gradient(180deg, #fff3cf, #e6b55c 60%, #b07a2c); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 2px 3px #000); line-height: 1.1; }
.dog-suit { display: flex; align-items: center; gap: 8px; font-style: italic; font-size: clamp(15px, min(1.7vh, 0.95vw), 24px); color: var(--ink-dim); }
.suit-sw { display: inline-flex; }
.suit-sw i { width: 12px; height: 12px; border-radius: 50%; border: 1px solid rgba(255, 240, 200, 0.5); box-shadow: 0 1px 3px #000; }
.suit-sw i + i { margin-left: -4px; }
.dog-info .name-field { width: 100%; margin: 10px 0 4px; align-items: center; gap: 6px; }
.dog-info .name-field span { font-size: clamp(10px, min(1.1vh, 0.65vw), 16px); letter-spacing: 0.3em; }
.dog-info .name-field input { text-align: center; font-family: var(--serif); font-weight: 600; font-size: clamp(18px, min(2vh, 1.1vw), 28px); letter-spacing: 0.12em; padding: 0.45em 12px; background: rgba(0, 0, 0, 0.4); border-color: rgba(227, 180, 90, 0.25); }
.dog-info .btn.reroll { width: auto; min-width: 180px; font-size: clamp(13px, min(1.45vh, 0.8vw), 20px); }
.menu-footer { left: 6vw; right: 6vw; bottom: 3vh; display: flex; justify-content: space-between; }
.menu-footer kbd { font-size: 10px; }
.lobby-list .breed { margin-left: 10px; font-family: var(--body); font-style: italic; font-size: 14px; color: var(--ink-dim); text-transform: none; letter-spacing: 0; }
@media (max-aspect-ratio: 1/1) {
  .menu-layout { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; align-content: center; align-items: center; padding: 7vh 6vw 9vh; gap: 4vh 4vw; }
  .menu-left { display: contents; }
  .menu-title { grid-column: 1 / -1; text-align: center; animation: rise 1s cubic-bezier(.2,.8,.2,1) both; }
  .menu-title .kicker { justify-content: center; }
  .menu-title .kicker::after { content: ''; width: 40px; height: 1px; background: linear-gradient(90deg, var(--gold), transparent); }
  .menu-title .title span { display: inline; }
  .menu-title .title { font-size: clamp(54px, 9vw, 128px); }
  .menu-title .rule.left { margin: 20px auto 14px; background: linear-gradient(90deg, transparent, rgba(227, 180, 90, 0.8) 30%, rgba(227, 180, 90, 0.8) 70%, transparent) center/100% 1px no-repeat; }
  .menu-title .rule.left i { left: 50%; transform: translate(-50%, -50%) rotate(45deg); }
  .menu-left > .panel, .menu-error { grid-column: 1; grid-row: 2; align-self: center; }
  .menu-left > .panel:not(.main-panel) { width: 100%; padding: 24px 24px; }
  .settings-grid { grid-template-columns: auto minmax(0, 1fr); }
  .menu-right { grid-column: 2; grid-row: 2; }
  .dog-card { --w: min(44vw, 520px); }
  .menu-scrim { background: linear-gradient(180deg, rgba(8, 6, 4, 0.8), rgba(8, 6, 4, 0.3) 35%, rgba(8, 6, 4, 0.45) 65%, rgba(8, 6, 4, 0.7)); }
}
@media (max-width: 760px) { .menu-right { display: none; } }

/* ============================================================ sequel logo */
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; pointer-events: none; }
.logo { margin: 0; display: flex; align-items: center; gap: 0.12em; font-weight: 900; line-height: 1; }
.logo .logo-name { display: block; font-size: inherit; -webkit-text-stroke: 0.012em rgba(70, 38, 8, 0.55); }
.logo-name > span { position: relative; display: inline-block; }
.logo-name > span::after { content: attr(data-t); position: absolute; inset: 0; color: transparent; -webkit-text-stroke: 0; background: linear-gradient(105deg, transparent 44%, rgba(255, 252, 236, 0.85) 50%, transparent 56%) no-repeat; background-size: 400% 100%; background-position: 120% 0; -webkit-background-clip: text; background-clip: text; animation: sweep 6.5s 1.2s cubic-bezier(.45,0,.3,1) infinite; }
.logo-name > span + span::after { animation-delay: 1.45s; }
@keyframes sweep { 0%, 62% { background-position: 120% 0; } 100% { background-position: -20% 0; } }
.logo-ii { position: relative; flex: none; width: 1.9em; height: 1.9em; margin: -0.3em 0; }
.ii-svg { position: relative; width: 100%; height: 100%; display: block; overflow: visible; filter: drop-shadow(0 0.06em 0.12em rgba(0, 0, 0, 0.7)); }
.ii-burst, .ii-streak { position: absolute; left: 50%; top: 52%; pointer-events: none; opacity: 0; }
.ii-burst { width: 3.2em; height: 3.2em; margin: -1.6em 0 0 -1.6em; border-radius: 50%; background: radial-gradient(circle, rgba(255, 250, 230, 0.95) 0, rgba(255, 214, 140, 0.55) 18%, rgba(255, 160, 60, 0.18) 42%, transparent 70%); }
.ii-streak { width: 9em; height: 0.5em; margin: -0.25em 0 0 -4.5em; background: radial-gradient(ellipse 50% 50%, rgba(255, 244, 214, 0.9), rgba(255, 190, 100, 0.25) 45%, transparent 75%); }

/* loading: the name settles in, then the numeral lands with a flash */
.load-logo { justify-content: center; font-size: clamp(44px, min(6vw, 11vh), 150px); }
.load-logo .logo-name { animation: namein 1.3s cubic-bezier(.16,.8,.24,1) both; }
@keyframes namein { from { opacity: 0; transform: scale(1.08); letter-spacing: 0.16em; } to { opacity: 1; transform: none; letter-spacing: 0.02em; } }
.load-logo .ii-svg { animation: iiin 1s 0.55s cubic-bezier(.2,1.3,.35,1) both; }
@keyframes iiin { from { opacity: 0; transform: scale(1.7) rotate(-4deg); } 40% { opacity: 1; } to { opacity: 1; transform: none; } }
.load-logo .ii-burst { animation: burst 1.5s 0.72s ease-out both; }
.load-logo .ii-streak { animation: streak 1.6s 0.72s ease-out both; }
@keyframes burst { 0% { opacity: 0; transform: scale(0.2); } 14% { opacity: 1; } 100% { opacity: 0; transform: scale(2.2); } }
@keyframes streak { 0% { opacity: 0; transform: scaleX(0.1); } 12% { opacity: 1; } 100% { opacity: 0; transform: scaleX(1.4); } }
.loading-inner { top: 7vh; }
.load-kicker { animation: fadein 1s 0.1s both; }
.loading-inner .rule { margin: 14px auto 14px; animation: rulein 1.2s 0.9s cubic-bezier(.2,.8,.2,1) both; }
@keyframes rulein { from { opacity: 0; transform: scaleX(0.2); } }
.load-tag { animation: fadein 1s 1.1s both; }
.load-foot { animation: footin 1.1s 0.3s cubic-bezier(.2,.8,.2,1) both; }
@keyframes footin { from { opacity: 0; transform: translateY(10px); } }
.load-bar .bar { animation: barin 1.2s 0.4s cubic-bezier(.2,.8,.2,1) both; }
@keyframes barin { from { transform: scaleX(0); } }
#load-fill { transition: width 0.9s cubic-bezier(.25,.8,.25,1); }
#load-fill::before { content: ''; position: absolute; inset: -1px 0; background: linear-gradient(90deg, transparent, rgba(255, 250, 230, 0.8) 50%, transparent) no-repeat; background-size: 30% 100%; animation: barshine 2.2s linear infinite; }
@keyframes barshine { from { background-position: -40% 0; } to { background-position: 140% 0; } }

/* menu: stacked name with the numeral seal beside it */
.menu-title .menu-logo { font-size: clamp(50px, min(5.6vw, 10.4vh), 190px); gap: 0.1em; }
.menu-logo .logo-name { line-height: 0.92; }
.menu-logo .logo-name > span { display: block; }
.menu-logo .logo-ii { width: 2.3em; height: 2.3em; margin: -0.2em 0 -0.2em -0.05em; animation: iiin 1.1s 0.35s cubic-bezier(.2,1.3,.35,1) both; }

/* warm late-morning sun over the backdrop so the menu matches the sunny field */
.menu-sun { position: absolute; inset: 0; pointer-events: none; backdrop-filter: saturate(1.28) contrast(1.07) brightness(1.03); }
.menu-sun::after { content: ''; position: absolute; inset: 0; mix-blend-mode: soft-light; background:
  radial-gradient(ellipse 55% 50% at 68% 0%, rgba(255, 230, 170, 0.7), transparent 70%),
  linear-gradient(180deg, rgba(255, 190, 100, 0.22), rgba(255, 175, 80, 0.12)); }

.menu-minor { display: flex; gap: 12px; margin-top: 4px; opacity: 0; animation: mbin 0.7s 0.5s cubic-bezier(.2,.8,.2,1) forwards; }
.chip { all: unset; display: inline-flex; align-items: center; gap: 0.6em; cursor: pointer; padding: 0.62em 1.1em 0.62em 0.9em; font-family: var(--serif); font-weight: 600; font-size: clamp(14px, min(1vw, 1.8vh), 28px); letter-spacing: 0.2em; text-transform: uppercase; color: #f6ecd4; background: linear-gradient(180deg, rgba(34, 26, 16, 0.72), rgba(14, 10, 6, 0.78)); border: 1px solid rgba(227, 180, 90, 0.45); box-shadow: inset 0 1px 0 rgba(255, 230, 170, 0.12), 0 4px 14px rgba(0, 0, 0, 0.35); text-shadow: 0 1px 4px #000; transition: border-color 0.2s, background 0.2s, color 0.2s, transform 0.25s cubic-bezier(.2,.8,.2,1); }
.chip svg { width: 1.25em; height: 1.25em; fill: var(--gold); flex: none; filter: drop-shadow(0 0 4px rgba(255, 180, 80, 0.3)); transition: transform 0.4s cubic-bezier(.2,.8,.2,1); }
.chip:hover, .chip:focus-visible { color: #fff8e6; border-color: rgba(255, 214, 140, 0.9); background: linear-gradient(180deg, rgba(70, 50, 24, 0.82), rgba(26, 18, 10, 0.86)); transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255, 230, 170, 0.2), 0 0 18px rgba(255, 180, 80, 0.25), 0 4px 14px rgba(0, 0, 0, 0.35); }
.chip:hover svg { transform: rotate(40deg); }
.chip[data-action=howto]:hover svg { transform: scale(1.12); }
.mb-sep { margin: 10px 0 12px; }

@media (max-aspect-ratio: 1/1) {
  .menu-title .menu-logo { justify-content: center; font-size: clamp(40px, 6.4vw, 110px); }
  .menu-logo .logo-name > span { display: inline-block; }
  .menu-logo .logo-ii { width: 1.9em; height: 1.9em; }
}

/* the key art fades up on its first frame, and the title reveal waits for it */
#stars { opacity: 0; transition: opacity 0.9s ease-out; }
#loading.ready #stars { opacity: 1; }
#loading:not(.ready) .loading-inner, #loading:not(.ready) .loading-inner *, #loading:not(.ready) .load-foot, #loading:not(.ready) .load-foot * { animation-play-state: paused; }

/* loading: fixed spacing between name and seal; bar, percentage and tip scale with the viewport */
.load-logo { gap: 0.14em; }
.load-logo .logo-ii { margin: -0.36em 0; }
.load-bar { width: clamp(420px, 38vw, 1100px); }
.load-meta { font-size: clamp(12px, 0.72vw, 20px); margin-bottom: 0.9em; }
.bar-row { display: flex; align-items: center; gap: max(1.1em, 22px); }
.bar-row .bar { flex: 1; }
.load-bar .bar { height: clamp(3px, 0.18vw, 5px); }
.bar-row #load-pct { flex: none; min-width: 2.6em; text-align: left; font-size: clamp(13px, 0.9vw, 26px); }
.tip { font-size: clamp(16px, 1.05vw, 30px); max-width: min(42em, 86vw); text-wrap: balance; }
.tip-k { font-size: clamp(10px, 0.62vw, 17px); }


/* ============================================================ menu panels */
.menu-left > .panel:not(.main-panel), .dog-info {
  position: relative; width: min(clamp(460px, 32vw, 860px), 90vw); padding: clamp(28px, 2vw, 52px) clamp(30px, 2.3vw, 60px); border: 1px solid rgba(120, 82, 34, 0.9); border-radius: 3px;
  font-size: clamp(16px, 0.95vw, 26px);
  background:
    var(--corner-tl) left -3px top -3px / 2.8em no-repeat, var(--corner-tr) right -3px top -3px / 2.8em no-repeat,
    var(--corner-bl) left -3px bottom -3px / 2.8em no-repeat, var(--corner-br) right -3px bottom -3px / 2.8em no-repeat,
    radial-gradient(ellipse 80% 60% at 30% 0%, rgba(255, 200, 120, 0.1), transparent 70%),
    repeating-linear-gradient(33deg, rgba(255, 235, 200, 0.018) 0 2px, transparent 2px 5px),
    repeating-linear-gradient(-58deg, rgba(0, 0, 0, 0.06) 0 1px, transparent 1px 4px),
    radial-gradient(ellipse 120% 100% at 50% 40%, #2c2016 0%, #1b140e 60%, #100b08 100%);
  box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.14), inset 0 0 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(0, 0, 0, 0.6), 0 24px 60px rgba(0, 0, 0, 0.55), 0 0 60px rgba(255, 170, 80, 0.06);
  backdrop-filter: none; animation: panelin 0.5s cubic-bezier(.2,.8,.2,1) both; }
@keyframes panelin { from { opacity: 0; transform: translateY(12px) scale(0.985); } }
.menu-left > .panel:not(.main-panel)::before { content: ''; position: absolute; inset: 0.55em; width: auto; height: auto; border: 1px dashed rgba(227, 180, 90, 0.26); border-radius: 2px; opacity: 1; pointer-events: none; }
.menu-left > .panel:not(.main-panel)::after { display: none; }
.p-head { display: flex; align-items: center; gap: 0.7em; margin: -0.2em 0 0.4em; padding-bottom: 0.9em; background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%27240%27%20height%3D%2712%27%20viewBox%3D%270%200%20240%2012%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27l%27%20x1%3D%270%27%20x2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3Cstop%20offset%3D%27.5%27%20stop-color%3D%27%23f3d38e%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect%20x%3D%270%27%20y%3D%275%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27url%28%23l%29%27/%3E%3Crect%20x%3D%270%27%20y%3D%276.2%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27%23000%27%20opacity%3D%27.5%27/%3E%3Cpath%20d%3D%27M120%201L125%206L120%2011L115%206Z%27%20fill%3D%27%23f6d890%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%27104%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3Ccircle%20cx%3D%27136%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3C/svg%3E") left bottom / 100% 0.75em no-repeat; }
.h-ii { width: 2.4em; height: 2.4em; flex: none; margin: -0.3em 0; filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.6)); }
.menu-left > .panel .p-head h2 { margin: 0; padding: 0; border: 0; font-size: 1.3em; letter-spacing: 0.2em; color: transparent; background: linear-gradient(180deg, #fff3cf, #e6b55c 60%, #a8742a); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.8)); }
.menu-left > .panel .hint { font-size: 1em; max-width: none; color: #cdbb98; }
.menu-left > .panel .field span, .menu-left > .panel .settings-grid label { font-size: 0.72em; letter-spacing: 0.26em; color: #c9ad7a; }

/* inputs inset into the leather */
.menu-left > .panel input[type="text"], .menu-left > .panel input:not([type]) { font-family: var(--serif); font-weight: 600; font-size: 1.05em; letter-spacing: 0.06em; padding: 0.7em 0.9em; color: #f6ead0; background: linear-gradient(180deg, rgba(0, 0, 0, 0.55), rgba(20, 14, 8, 0.4)); border: 1px solid rgba(120, 82, 34, 0.9); border-bottom-color: rgba(227, 180, 90, 0.6); border-radius: 2px; box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6); transition: border-color 0.2s, box-shadow 0.2s; }
.menu-left > .panel input[type="text"]:focus, .menu-left > .panel input:not([type]):focus { outline: none; border-color: rgba(255, 210, 130, 0.9); box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6), 0 0 0 3px rgba(227, 180, 90, 0.15), 0 0 18px rgba(255, 180, 80, 0.2); }

/* brass plate buttons */
.menu-left > .panel .btn, .dog-info .btn { font-size: 0.82em; padding: 0.95em 1.2em; letter-spacing: 0.2em; border-radius: 2px; border: 1px solid rgba(140, 96, 40, 0.95); color: #f2e2c0; background: linear-gradient(180deg, rgba(52, 38, 24, 0.95), rgba(24, 17, 11, 0.95)); box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.16), inset 0 -2px 0 rgba(0, 0, 0, 0.4), 0 4px 12px rgba(0, 0, 0, 0.45); transition: transform 0.15s, box-shadow 0.2s, border-color 0.2s, filter 0.2s; }
.menu-left > .panel .btn.primary { color: #2a1604; text-shadow: 0 1px 0 rgba(255, 240, 200, 0.6); border-color: #5a3a10; background: linear-gradient(180deg, #fbe3a2 0%, #e2ae55 42%, #b07a2c 58%, #d9a24c 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 240, 0.7), inset 0 -2px 0 rgba(90, 52, 10, 0.5), 0 0 0 1px rgba(0, 0, 0, 0.5), 0 6px 16px rgba(0, 0, 0, 0.5); }
.menu-left > .panel .btn:hover, .dog-info .btn:hover { transform: translateY(-2px); border-color: rgba(255, 210, 130, 0.95); box-shadow: inset 0 1px 0 rgba(255, 230, 170, 0.25), 0 0 20px rgba(255, 180, 80, 0.25), 0 8px 18px rgba(0, 0, 0, 0.5); }
.menu-left > .panel .btn.primary:hover { filter: brightness(1.08) saturate(1.05); box-shadow: inset 0 1px 0 rgba(255, 255, 240, 0.8), 0 0 0 1px rgba(0, 0, 0, 0.5), 0 0 26px rgba(255, 190, 90, 0.45), 0 8px 18px rgba(0, 0, 0, 0.5); }
.menu-left > .panel .btn:active, .dog-info .btn:active { transform: translateY(1px) scale(0.985); box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.6); transition-duration: 0.05s; }
.menu-left > .panel .btn-row { margin-top: 1.1em; gap: 0.8em; }

/* scanning beacon */
.menu-left > .panel .scan { font-size: 0.95em; font-style: italic; color: #cdbb98; margin-bottom: 0.4em; }
.menu-left > .panel .pulse { width: 0.7em; height: 0.7em; background: radial-gradient(circle at 35% 30%, #fff3c8, #e3b45a 45%, #8a5a1c); }

/* join list: each castle hangs its banner */
.menu-left > .panel .game-list { gap: 0.7em; max-height: 20em; padding: 0.3em 0.2em 0.3em 0; }
.menu-left > .panel .game-list li { position: relative; padding: 0.9em 1.1em 0.9em 4.2em; border-radius: 2px; border: 1px solid rgba(120, 82, 34, 0.8); background: linear-gradient(90deg, rgba(60, 20, 16, 0.35), rgba(0, 0, 0, 0.3) 40%), linear-gradient(180deg, rgba(40, 30, 20, 0.8), rgba(18, 13, 9, 0.85)); box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.08), 0 3px 10px rgba(0, 0, 0, 0.4); transition: transform 0.25s cubic-bezier(.2,.8,.2,1), border-color 0.2s, box-shadow 0.2s; }
.menu-left > .panel .game-list li::before { content: ''; position: absolute; left: 0.9em; top: -0.35em; width: 2.2em; bottom: -0.1em; clip-path: polygon(0 0, 100% 0, 100% 100%, 50% 80%, 0 100%); background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20fill%3D%27%23f2cf84%27%20d%3D%27M3%2021V9h3v2h2V9h2v2h4V9h2v2h2V9h3v12h-7v-4a2%202%200%200%200-4%200v4Z%27/%3E%3Cpath%20fill%3D%27%23f2cf84%27%20d%3D%27M11%203h3l-3%202v3h-1V3Z%27/%3E%3C/svg%3E") center 38% / 1.3em no-repeat, linear-gradient(90deg, #5c1612, #8e2a1e 60%, #6a1a15); box-shadow: inset 0 0 0 2px rgba(214, 160, 80, 0.5); transition: transform 0.3s cubic-bezier(.3,1.6,.5,1); transform-origin: top; }
.menu-left > .panel .game-list li::after { content: ''; position: absolute; left: 0.7em; top: -0.45em; width: 2.6em; height: 0.25em; border-radius: 2px; background: linear-gradient(180deg, #f2cf84, #8a5a1c); }
.menu-left > .panel .game-list li:not(.empty):hover { transform: translateX(4px); border-color: rgba(255, 210, 130, 0.85); box-shadow: 0 0 20px rgba(255, 180, 80, 0.18), 0 4px 12px rgba(0, 0, 0, 0.45); background: linear-gradient(90deg, rgba(90, 28, 20, 0.4), rgba(40, 26, 12, 0.3) 45%), linear-gradient(180deg, rgba(52, 38, 24, 0.85), rgba(22, 16, 10, 0.9)); }
.menu-left > .panel .game-list li:not(.empty):hover::before { transform: rotate(-4deg); }
.menu-left > .panel .game-list .g-name { font-size: 1.05em; color: #f6ead0; }
.menu-left > .panel .game-list .g-meta { font-size: 0.82em; font-style: italic; margin-top: 0.15em; }
.menu-left > .panel .game-list .g-join { font-size: 0.72em; font-weight: 800; padding: 0.5em 0.8em; border: 1px solid rgba(227, 180, 90, 0.5); border-radius: 2px; white-space: nowrap; }
.menu-left > .panel .game-list .empty { padding: 1.2em 1.4em 1.2em 4.2em; justify-content: flex-start; border: 1px dashed rgba(227, 180, 90, 0.3); background: rgba(0, 0, 0, 0.25); box-shadow: none; font-size: 0.95em; }
.menu-left > .panel .game-list .empty::before { opacity: 0.45; filter: grayscale(0.6); }
.menu-left > .panel .game-list .empty::after { opacity: 0.45; }
.menu-left > .panel .manual { margin-top: 0.9em; }
.menu-left > .panel .manual summary { font-size: 0.75em; letter-spacing: 0.2em; color: #c9ad7a; list-style: none; }
.menu-left > .panel .manual summary::before { content: '\25B8'; display: inline-block; margin-right: 0.6em; color: var(--gold); transition: transform 0.2s; }
.menu-left > .panel .manual[open] summary::before { transform: rotate(90deg); }

/* lobby roster: numbered name plates */
.menu-left > .panel .lobby-list { counter-reset: roster; gap: 0.55em; margin-top: 0.6em; max-height: 22em; }
.menu-left > .panel .lobby-list li { position: relative; gap: 0.8em; padding: 0.8em 1.1em 0.8em 3.4em; font-size: 1.02em; border-radius: 2px; border: 1px solid rgba(120, 82, 34, 0.8); background: linear-gradient(180deg, rgba(44, 33, 22, 0.85), rgba(18, 13, 9, 0.9)); box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.08); animation: panelin 0.4s both; counter-increment: roster; }
.menu-left > .panel .lobby-list li::before { content: counter(roster, upper-roman); position: absolute; left: 0; top: 0; bottom: 0; width: 2.4em; display: grid; place-items: center; font-family: var(--display); font-weight: 900; font-size: 0.9em; color: #2a1604; background: linear-gradient(180deg, #f6d890, #c48c38 55%, #9a6624); border-right: 1px solid #5a3a10; }
.menu-left > .panel .lobby-list .swatch { width: 0.75em; height: 0.75em; flex: none; }
.menu-left > .panel .lobby-list .breed { font-size: 0.85em; margin-left: 0.2em; }
.menu-left > .panel .lobby-list .suit-sw i { width: 0.8em; height: 0.8em; }
.menu-left > .panel .lobby-list .tag:not(:empty) { padding: 0.35em 0.7em; color: #fbe6d0; background: radial-gradient(circle at 40% 35%, #b43a2a, #6e1510 70%); border-radius: 999px; box-shadow: 0 1px 3px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 200, 180, 0.3); font-size: 0.62em; }

/* settings: brass levers and wax seals */
.menu-left > .panel .settings-grid { grid-template-columns: auto minmax(8em, 1fr) 3.6em; gap: 1.1em 1.4em; margin: 0.6em 0 0.2em; }
.menu-left > .panel .settings-grid output { font-family: var(--serif); font-weight: 600; font-size: 0.9em; color: #f6d48a; text-align: right; font-variant-numeric: tabular-nums; }
.set-rule { grid-column: 1 / -1; height: 0.75em; background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%27240%27%20height%3D%2712%27%20viewBox%3D%270%200%20240%2012%27%3E%3Cdefs%3E%3ClinearGradient%20id%3D%27l%27%20x1%3D%270%27%20x2%3D%271%27%3E%3Cstop%20offset%3D%270%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3Cstop%20offset%3D%27.5%27%20stop-color%3D%27%23f3d38e%27/%3E%3Cstop%20offset%3D%271%27%20stop-color%3D%27%23e3b45a%27%20stop-opacity%3D%270%27/%3E%3C/linearGradient%3E%3C/defs%3E%3Crect%20x%3D%270%27%20y%3D%275%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27url%28%23l%29%27/%3E%3Crect%20x%3D%270%27%20y%3D%276.2%27%20width%3D%27240%27%20height%3D%271%27%20fill%3D%27%23000%27%20opacity%3D%27.5%27/%3E%3Cpath%20d%3D%27M120%201L125%206L120%2011L115%206Z%27%20fill%3D%27%23f6d890%27%20stroke%3D%27%233a2208%27%20stroke-width%3D%27.6%27/%3E%3Ccircle%20cx%3D%27104%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3Ccircle%20cx%3D%27136%27%20cy%3D%276%27%20r%3D%271.5%27%20fill%3D%27%23e3b45a%27/%3E%3C/svg%3E") center / 100% 100% no-repeat; opacity: 0.8; }
.menu-left > .panel input[type="range"] { -webkit-appearance: none; appearance: none; height: 2em; background: transparent; cursor: pointer; --v: 50%; }
.menu-left > .panel input[type="range"]::-webkit-slider-runnable-track { height: 0.4em; border-radius: 1em; background: linear-gradient(90deg, #8a5a1c, #f2c46a var(--v), rgba(0, 0, 0, 0.6) var(--v)); box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.8), 0 1px 0 rgba(255, 220, 160, 0.12); }
.menu-left > .panel input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 1em; height: 1.9em; margin-top: -0.75em; border-radius: 0.3em 0.3em 0.45em 0.45em; border: 1px solid #3a2208; background: linear-gradient(90deg, #7a5020, #fbe3a2 40%, #d9a24c 60%, #8a5a1c); box-shadow: 0 3px 6px rgba(0, 0, 0, 0.6), inset 0 1px 0 rgba(255, 255, 240, 0.7); transition: transform 0.15s; }
.menu-left > .panel input[type="range"]:hover::-webkit-slider-thumb { transform: scaleY(1.08); box-shadow: 0 3px 6px rgba(0, 0, 0, 0.6), 0 0 12px rgba(255, 190, 90, 0.5), inset 0 1px 0 rgba(255, 255, 240, 0.7); }
.menu-left > .panel input[type="range"]:active::-webkit-slider-thumb { transform: scale(0.94, 1.02); }
.menu-left > .panel input[type="range"]::-moz-range-track { height: 0.4em; border-radius: 1em; background: rgba(0, 0, 0, 0.6); }
.menu-left > .panel input[type="range"]::-moz-range-progress { height: 0.4em; border-radius: 1em; background: linear-gradient(90deg, #8a5a1c, #f2c46a); }
.menu-left > .panel input[type="range"]::-moz-range-thumb { width: 1em; height: 1.9em; border-radius: 0.3em; border: 1px solid #3a2208; background: linear-gradient(90deg, #7a5020, #fbe3a2 40%, #d9a24c 60%, #8a5a1c); }
.menu-left > .panel input[type="checkbox"] { -webkit-appearance: none; appearance: none; width: 2.1em; height: 2.1em; margin: 0; cursor: pointer; border-radius: 50%; border: 1px dashed rgba(227, 180, 90, 0.5); background: radial-gradient(circle, rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.2)); box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.7); transition: transform 0.2s, border-color 0.2s; }
.menu-left > .panel input[type="checkbox"]:hover { border-color: rgba(255, 210, 130, 0.9); transform: rotate(-8deg); }
.menu-left > .panel input[type="checkbox"]:checked { border: 0; background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M7%2012.5l3.2%203.2L17%208.8%27%20fill%3D%27none%27%20stroke%3D%27%23f7c9a8%27%20stroke-opacity%3D%27.85%27%20stroke-width%3D%272.4%27%20stroke-linecap%3D%27round%27%20stroke-linejoin%3D%27round%27/%3E%3C/svg%3E") center / 62% no-repeat, radial-gradient(circle at 38% 32%, #d0533c, #8e1f16 55%, #5a0f0b 100%); box-shadow: 0 0 0 0.12em #7a1812, 0.08em 0.1em 0 0.12em #6a140f, -0.1em 0.06em 0 0.1em #801a13, 0.05em -0.1em 0 0.09em #8a1d15, 0 3px 8px rgba(0, 0, 0, 0.6), inset 0 0.15em 0.2em rgba(255, 170, 140, 0.35), inset 0 -0.2em 0.3em rgba(0, 0, 0, 0.45); animation: stamp 0.35s cubic-bezier(.3,1.6,.5,1); }
@keyframes stamp { from { transform: scale(1.35) rotate(-14deg); opacity: 0.4; } }
.menu-left > .panel input[type="checkbox"]:focus-visible, .menu-left > .panel input[type="range"]:focus-visible { outline: 2px solid rgba(255, 210, 130, 0.6); outline-offset: 3px; }

/* field manual */
.menu-left > .panel .howto { max-width: none; font-size: 1em; line-height: 1.5; }
.menu-left > .panel .howto > p:first-child { font-style: italic; color: #e8d9b8; }
.menu-left > .panel .howto .keys { margin: 0.4em 0 1em; padding: 0; list-style: none; }
.menu-left > .panel .howto .keys li { padding: 0.5em 0 0.5em 1.4em; position: relative; border-bottom: 1px solid rgba(227, 180, 90, 0.12); }
.menu-left > .panel .howto .keys li::before { content: ''; position: absolute; left: 0.2em; top: 1.05em; width: 0.4em; height: 0.4em; background: var(--gold); transform: rotate(45deg); }
.menu-left > .panel kbd { font-size: 0.72em; min-width: 2em; padding: 0.2em 0.5em; border-radius: 3px; color: #2a1604; background: linear-gradient(180deg, #fbe3a2, #d9a24c 60%, #a8742c); border: 1px solid #5a3a10; box-shadow: 0 2px 0 #4a2c08, inset 0 1px 0 rgba(255, 255, 240, 0.7); text-shadow: none; }

/* defender plinth grounded in the scene: a soft contact shadow and sun haze that match the backdrop */
.dog-stage::after { content: ''; position: absolute; left: 6%; right: 6%; bottom: -2%; height: 12%; pointer-events: none; background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(10, 8, 4, 0.55), transparent 70%); z-index: -1; }
.stage-light { background: radial-gradient(ellipse 40% 50% at 60% 30%, rgba(255, 214, 150, 0.16), transparent 70%), radial-gradient(ellipse 46% 12% at 50% 90%, rgba(255, 190, 110, 0.2), transparent 70%); }
.menu-left > .panel .howto .keys li { padding: 0.32em 0 0.32em 1.4em; }
.menu-left > .panel .howto .keys li::before { top: 0.8em; }
.menu-left > .panel .howto p { margin-bottom: 0.6em; }
.menu-left > .panel .lobby-list li::before { font-family: var(--serif); font-weight: 800; font-size: 0.85em; letter-spacing: 0.04em; }

/* ------------------------------------------------ menu review pass */
/* the title block holds one position on every panel; tall panels scroll inside */
.menu-layout { align-items: stretch; }
.menu-left { justify-content: flex-start; padding-top: clamp(0px, 3vh, 60px); gap: clamp(18px, 3.6vh, 64px); }
.menu-right { align-self: center; }
.menu-left > .panel:not(.main-panel) { max-height: min(60vh, calc(100vh - var(--title-h, 44vh) - 21vh)); overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(227, 180, 90, 0.5) transparent; }
.menu-left > .panel:not(.main-panel)::-webkit-scrollbar { width: 8px; }
.menu-left > .panel:not(.main-panel)::-webkit-scrollbar-thumb { background: linear-gradient(180deg, #e3b45a, #8a5a1c); border-radius: 4px; border: 2px solid transparent; background-clip: padding-box; }
.p-head { margin-top: 0; }

/* soft dark bed behind the left column so the menu reads over foliage */
.menu-scrim { background:
  linear-gradient(90deg, rgba(8, 6, 4, 0.88) 0%, rgba(8, 6, 4, 0.7) 24%, rgba(8, 6, 4, 0.35) 42%, rgba(8, 6, 4, 0.08) 56%, transparent 64%, rgba(8, 6, 4, 0.2) 80%, rgba(8, 6, 4, 0.55) 100%); }

/* main list: a gold bar marks the focused item */
.mbtn { border-left: 0; }
.mbtn::before { left: 10px; top: 12%; bottom: 12%; width: 3px; height: auto; background: linear-gradient(180deg, transparent, #f6d48a 20%, #e3b45a 80%, transparent); transform: scaleY(0); box-shadow: 0 0 12px rgba(255, 200, 110, 0.8); transition: transform 0.25s cubic-bezier(.2,.8,.2,1); }
.mbtn:hover::before, .mbtn:focus-visible::before { transform: scaleY(1); }
.mbtn:hover, .mbtn:focus-visible { background: linear-gradient(90deg, rgba(255, 190, 90, 0.12), transparent 70%); }
.mbtn:hover .mb-t, .mbtn:focus-visible .mb-t { color: #ffe3a2; }
.mb-s { font-size: clamp(15px, min(1.08vw, 1.95vh), 30px); opacity: 0.88; color: #d6c4a0; }

/* defender card: same gilded leather frame as the panels, dropped clear of the plinth */
.dog-info { margin-top: 40px; border: 1px solid rgba(120, 82, 34, 0.9); border-radius: 3px;
  background:
    var(--corner-tl) left -3px top -3px / 2.4em no-repeat, var(--corner-tr) right -3px top -3px / 2.4em no-repeat,
    var(--corner-bl) left -3px bottom -3px / 2.4em no-repeat, var(--corner-br) right -3px bottom -3px / 2.4em no-repeat,
    repeating-linear-gradient(33deg, rgba(255, 235, 200, 0.018) 0 2px, transparent 2px 5px),
    radial-gradient(ellipse 120% 100% at 50% 40%, #2c2016 0%, #1b140e 60%, #100b08 100%);
  box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.14), inset 0 0 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(0, 0, 0, 0.6), 0 24px 60px rgba(0, 0, 0, 0.5); }
.dog-info::before { content: ''; position: absolute; inset: 0.5em; top: 0.5em; left: 0.5em; width: auto; height: auto; border: 1px dashed rgba(227, 180, 90, 0.26); background: none; transform: none; pointer-events: none; }
.dog-info::after { display: none; }

/* settings toggles: gold pill switches in the readout column */
.menu-left > .panel .settings-grid { grid-auto-flow: row dense; }
.menu-left > .panel .settings-grid input[type="checkbox"] { grid-column: 3; justify-self: end; width: 3.4em; height: 1.7em; border-radius: 1em; border: 1px solid rgba(140, 96, 40, 0.95);
  background: radial-gradient(circle at 50% 40%, #6b665e, #3a352e 70%) left 0.18em center / 1.3em 1.3em no-repeat, linear-gradient(180deg, rgba(0, 0, 0, 0.6), rgba(30, 22, 14, 0.7));
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.7); transition: background-position 0.25s cubic-bezier(.3,1.4,.5,1), border-color 0.2s, box-shadow 0.2s; animation: none; }
.menu-left > .panel .settings-grid input[type="checkbox"]:hover { transform: none; border-color: rgba(255, 210, 130, 0.9); }
.menu-left > .panel .settings-grid input[type="checkbox"]:checked { border: 1px solid #5a3a10;
  background: radial-gradient(circle at 45% 35%, #fff6d8, #e6b55c 55%, #9a6624) right 0.18em center / 1.3em 1.3em no-repeat, linear-gradient(180deg, #8a5a1c, #c48c38 60%, #7a4e18);
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.45), 0 0 14px rgba(255, 190, 90, 0.35); animation: none; }
.menu-left > .panel .settings-grid input[type="checkbox"]:active { background-size: 1.5em 1.2em, auto; }
.menu-left > .panel .settings-grid input[type="checkbox"] + span { grid-column: 2; justify-self: end; font-family: var(--serif); font-weight: 600; font-size: 0.72em; letter-spacing: 0.24em; color: #8f7c5c; }
.menu-left > .panel .settings-grid input[type="checkbox"] + span::after { content: 'Off'; }
.menu-left > .panel .settings-grid input[type="checkbox"]:checked + span { color: #f6d48a; }
.menu-left > .panel .settings-grid input[type="checkbox"]:checked + span::after { content: 'On'; }

/* field manual: keycap column and action column */
.menu-left > .panel .howto .keys { display: grid; grid-template-columns: 7.2em 1fr; margin: 0.6em 0 0.8em; }
.menu-left > .panel .howto .keys li { display: contents; }
.menu-left > .panel .howto .keys li::before { display: none; }
.menu-left > .panel .howto .keys .k, .menu-left > .panel .howto .keys .v { padding: 0.24em 0; border-bottom: 1px solid rgba(227, 180, 90, 0.1); }
.menu-left > .panel .howto .keys .k { display: flex; gap: 0.25em; align-items: center; }
.menu-left > .panel .howto .keys .k kbd { margin: 0; }
.menu-left > .panel .howto .keys .v { font-family: var(--serif); font-size: 0.86em; letter-spacing: 0.03em; color: #eadcbc; display: flex; align-items: center; font-variant-numeric: lining-nums tabular-nums; }
.howto-intro { font-style: italic; color: #e8d9b8; }
.howto-lore { margin: 0 !important; padding-top: 0.9em; font-style: italic; font-size: 0.92em; color: #c9b58f; background: linear-gradient(90deg, transparent, rgba(227, 180, 90, 0.5), transparent) top / 100% 1px no-repeat; }

/* lobby: the numbered plate carries the player's colour; Host is a gold outline tag */
.menu-left > .panel .lobby-list li::before { color: #1a1206; background: linear-gradient(180deg, color-mix(in srgb, var(--pc, #e3b45a) 70%, #fff), var(--pc, #e3b45a) 55%, color-mix(in srgb, var(--pc, #e3b45a) 70%, #000)); border-right: 1px solid rgba(0, 0, 0, 0.5); }
.menu-left > .panel .lobby-list .p-name { font-family: var(--serif); font-weight: 600; letter-spacing: 0.08em; color: #f6ead0; }
.menu-left > .panel .lobby-list .swatch, .menu-left > .panel .lobby-list .suit-sw { display: none; }
.menu-left > .panel .lobby-list .tag:not(:empty) { color: #f6d48a; background: none; border: 1px solid rgba(227, 180, 90, 0.75); border-radius: 2px; box-shadow: none; padding: 0.35em 0.8em; }


/* ============================================================ HUD: brass and leather family */
#hud { --plate: linear-gradient(180deg, rgba(38, 28, 18, 0.82), rgba(14, 10, 7, 0.86)); --edge: rgba(150, 104, 44, 0.9); --hair: inset 0 1px 0 rgba(255, 220, 160, 0.14), 0 0 0 1px rgba(0, 0, 0, 0.55), 0 6px 18px rgba(0, 0, 0, 0.4);
  font-size: clamp(12px, min(0.78vw, 1.4vh), 22px); }

/* castle health and the wave plaque */
.hud-top { top: 1.4em; gap: 1.2em; align-items: flex-start; }
.castle-hp { gap: 0; align-items: center; margin-top: 0.5em; }
.castle-icon { position: relative; z-index: 2; width: 3.1em; height: 3.1em; margin-right: -0.9em; border-radius: 50%; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Cpath fill='%23fff0c2' d='M6 58V22h8v8h8v-8h8v8h4v-8h8v8h8v-8h8v36H38V44a6 6 0 0 0-12 0v14z'/%3E%3C/svg%3E") center / 52% no-repeat, radial-gradient(circle at 40% 30%, #8e2a1e, #4a0d0a 75%); border: 2px solid #d9a24c; box-shadow: 0 0 0 1px #3a2208, 0 3px 10px rgba(0, 0, 0, 0.6), inset 0 1px 2px rgba(255, 200, 160, 0.4); filter: none; }
.hp-bar { width: clamp(300px, 24vw, 720px); height: 1.55em; padding: 0; border-radius: 0 0.8em 0.8em 0; border: 1px solid var(--edge); background: linear-gradient(180deg, rgba(0, 0, 0, 0.7), rgba(24, 16, 10, 0.75)); box-shadow: var(--hair), inset 0 2px 6px rgba(0, 0, 0, 0.8); }
.hp-bar::after { content: ''; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: repeating-linear-gradient(90deg, transparent 0 calc(25% - 1px), rgba(0, 0, 0, 0.55) calc(25% - 1px) 25%); }
#hp-fill.healthy, #hp-fill { background: linear-gradient(180deg, #ffe7a8 0%, #e2ae55 35%, #a8742a 70%, #7a4e18 100%); box-shadow: inset 0 1px 0 rgba(255, 250, 230, 0.7), 0 0 12px rgba(255, 190, 90, 0.35); transition: width 0.25s cubic-bezier(.3,.7,.3,1); }
#hp-fill:not(.healthy) { background: linear-gradient(180deg, #ffc9a8 0%, #e2683f 35%, #a8321c 70%, #6a150c 100%); box-shadow: inset 0 1px 0 rgba(255, 220, 200, 0.6), 0 0 12px rgba(255, 90, 50, 0.4); }
#hud.hp-low #hp-fill { animation: hplow 1.1s ease-in-out infinite; }
@keyframes hplow { 50% { filter: brightness(1.35); } }
#hp-ghost { background: linear-gradient(180deg, rgba(255, 240, 220, 0.75), rgba(255, 200, 160, 0.5)); }
#hp-text { font-size: 0.78em; font-weight: 800; letter-spacing: 0.14em; color: #fff6e0; text-shadow: 0 1px 2px #000, 0 0 6px rgba(0, 0, 0, 0.8); font-variant-numeric: tabular-nums lining-nums; z-index: 3; }
.wave-box { position: relative; min-width: 9.5em; padding: 0.55em 1.3em 1.2em; border: 1px solid var(--edge); border-top: 0; border-radius: 0; background: var(--corner-bl) left -2px bottom -2px / 1.6em no-repeat, var(--corner-br) right -2px bottom -2px / 1.6em no-repeat, var(--plate); box-shadow: var(--hair); clip-path: polygon(0 0, 100% 0, 100% 100%, 50% calc(100% - 0.6em), 0 100%); }
.wave-box::before { content: ''; position: absolute; left: -0.4em; right: -0.4em; top: 0; height: 0.3em; background: linear-gradient(180deg, #f2cf84, #8a5a1c); }
#wave-label { font-size: 1.55em; line-height: 1.1; color: transparent; background: linear-gradient(180deg, #fff3cf, #e6b55c 60%, #a8742a); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.9)); }
#wave-sub { font-size: 1em; font-style: italic; color: #e2d2b0; margin-top: 0.1em; font-variant-numeric: lining-nums tabular-nums; }

/* boons: gems with a draining brass line */
#boons { top: 5.4em; gap: 0.6em; }
.boon { --gem: #5fd4ff; position: relative; display: flex; align-items: center; gap: 0.55em; padding: 0.4em 0.9em 0.5em 0.7em; font-size: 0.8em; letter-spacing: 0.16em; color: #f2e2c0; border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); text-shadow: 0 1px 2px #000; overflow: hidden; }
.boon::before { content: ''; width: 0.7em; height: 0.7em; flex: none; transform: rotate(45deg); background: radial-gradient(circle at 35% 30%, #fff, var(--gem) 55%, color-mix(in srgb, var(--gem) 60%, #000)); box-shadow: 0 0 8px var(--gem); }
.boon::after { content: ''; position: absolute; left: 0; bottom: 0; height: 2px; width: calc(var(--t, 1) * 100%); background: linear-gradient(90deg, color-mix(in srgb, var(--gem) 50%, #000), var(--gem)); transition: width 1s linear; }
.boon b { color: #fff6de; font-variant-numeric: tabular-nums lining-nums; }
.boon.ending { animation: boonend 0.9s ease-in-out infinite; }
@keyframes boonend { 50% { opacity: 0.55; } }
#boon-over { --gem: #c08bff; border-color: var(--edge); color: #f2e2c0; background: var(--plate); box-shadow: var(--hair); }
#boon-sentry { --gem: #ff7a5a; }
#boon-locate { --gem: #6bffd8; }

/* kill feed */
#killfeed { top: 1.6em; right: 1.8em; gap: 0.35em; }
#killfeed li { --pc: #e3b45a; display: flex; align-items: baseline; gap: 0.45em; padding: 0.35em 0.9em 0.4em; font-size: 1em; color: #e8d9b8; border: 0; border-right: 3px solid var(--pc); background: linear-gradient(90deg, transparent, rgba(14, 10, 7, 0.78) 18%, rgba(24, 17, 11, 0.85)); text-shadow: 0 1px 2px #000; animation: feed2 5s cubic-bezier(.2,.8,.2,1) both; }
#killfeed li b { font-size: 0.92em; letter-spacing: 0.1em; color: var(--pc); }
#killfeed li .kf-v { font-style: italic; opacity: 0.8; }
#killfeed li .kf-w { font-family: var(--serif); font-weight: 600; font-size: 0.92em; letter-spacing: 0.06em; color: #f6ead0; }
#killfeed li .hs { margin-left: 0.2em; padding: 0.1em 0.45em; font-size: 0.68em; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: #f6d48a; border: 1px solid rgba(227, 180, 90, 0.7); }
@keyframes feed2 { 0% { opacity: 0; transform: translateX(1.6em); } 6%, 86% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translateX(0.6em); } }

/* announce banners with an engraved rule; toasts on a soft plate */
.announce { top: 15%; }
.announce .a-title { font-size: clamp(40px, 3.3vw, 96px); }
.announce .a-sub { font-size: clamp(18px, 1.3vw, 36px); }
.announce .a-sub::before { content: ''; display: block; width: min(26em, 60vw); height: 0.5em; margin: 0.2em auto 0.35em; background: radial-gradient(circle, #f6d890 0 0.14em, transparent 0.16em) center / 0.5em 0.5em no-repeat, linear-gradient(90deg, transparent, rgba(227, 180, 90, 0.8) 30%, rgba(227, 180, 90, 0.8) 70%, transparent) center / 100% 1px no-repeat; }
.announce.danger .a-sub::before { background: radial-gradient(circle, #ff9a7a 0 0.14em, transparent 0.16em) center / 0.5em 0.5em no-repeat, linear-gradient(90deg, transparent, rgba(224, 81, 59, 0.8) 30%, rgba(224, 81, 59, 0.8) 70%, transparent) center / 100% 1px no-repeat; }
#toast { left: 50%; right: auto; transform: translate(-50%, 6px); width: max-content; max-width: 70vw; padding: 0.45em 1.6em; font-size: clamp(16px, 1.15vw, 32px); color: #f6ead0; background: radial-gradient(ellipse 60% 100% at 50% 50%, rgba(12, 9, 6, 0.72), rgba(12, 9, 6, 0.35) 70%, transparent); transition: opacity 0.4s, transform 0.4s; }
#toast.show { transform: translate(-50%, 0); }
#prompt { font-size: 1.05em; padding: 0.6em 1.3em; border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); color: #f6ead0; }

/* crosshair: a thin dark outline keeps it readable on a bright sky */
#crosshair { width: clamp(64px, 4.4vw, 128px); height: clamp(64px, 4.4vw, 128px); }
#crosshair .ring { stroke: #f6d48a; }
#hitmarker { filter: drop-shadow(0 0 1px #000) drop-shadow(0 0 2px rgba(0, 0, 0, 0.7)); }
#hitmarker.head { filter: drop-shadow(0 0 1px #000) sepia(1) saturate(8) hue-rotate(-20deg) brightness(1.1); }
#hitmarker.kill { filter: drop-shadow(0 0 1px #000) sepia(1) saturate(10) hue-rotate(-50deg); }

/* loadout tray: weapon, ammo, then ability tiles that fill and pulse when ready */
.loadout { right: 1.8em; bottom: 5.2em; gap: 0.5em; }
.lo-weapon { font-family: var(--display); font-size: 1.7em; line-height: 1; color: transparent; background: linear-gradient(180deg, #fff3cf, #e6b55c 60%, #a8742a); -webkit-background-clip: text; background-clip: text; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, 0.9)); text-shadow: none; }
#ammo-n { font-size: 3.3em; color: #fff6e0; font-variant-numeric: tabular-nums lining-nums; text-shadow: 0 2px 4px #000, 0 0 16px rgba(0, 0, 0, 0.5); }
#ammo-max { font-size: 1.2em; color: #d9c6a0; font-variant-numeric: lining-nums; }
#ammo.low #ammo-n { color: #ff8a64; animation: hplow 0.8s ease-in-out infinite; }
#ammo .ammo-r { font-size: 0.8em; color: #f6d48a; }
#ammo-bar { height: 2px; background: linear-gradient(90deg, #8a5a1c, #f6d48a); box-shadow: 0 0 6px rgba(255, 190, 90, 0.6); }
.lo-slots { gap: 0.3em; }
.lo-slot { padding: 0.25em 0.45em; border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); }
.lo-slot.active { border-color: #f2c46a; box-shadow: var(--hair), 0 0 10px rgba(255, 190, 90, 0.35); }
.lo-abilities { gap: 0; padding: 0.3em; border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); }
.lo-ab { --glow: 227, 180, 90; flex-direction: column; justify-content: center; gap: 0.3em; min-width: 5.4em; padding: 0.45em 0.6em 0.5em; border: 0; border-left: 1px solid rgba(227, 180, 90, 0.16); background: none; font-size: 0.72em; letter-spacing: 0.14em; color: #9d8a68; text-shadow: 0 1px 2px #000; transition: color 0.3s; }
.lo-ab:first-child { border-left: 0; }
.lo-ab span { white-space: nowrap; }
.lo-ab b { color: #fff6de; }
.lo-ab i { left: 0; right: 0; bottom: 0; top: auto; width: auto; height: var(--fill, 0%); background: linear-gradient(0deg, rgba(227, 180, 90, 0.28), rgba(227, 180, 90, 0.04)); border-top: 1px solid rgba(246, 212, 138, 0.7); transition: height 0.2s linear; pointer-events: none; }
.lo-ab kbd { font-size: 1.05em; }
.lo-ab.ready { color: #f6ead0; border-color: rgba(227, 180, 90, 0.16); background: radial-gradient(ellipse 80% 70% at 50% 100%, rgba(var(--glow), 0.28), transparent 70%); box-shadow: none; animation: readyglow 1.8s ease-in-out infinite; }
.lo-ab.ready i { display: none; }
.lo-ab.strike { --glow: 255, 110, 70; } .lo-ab.lion { --glow: 255, 176, 64; } .lo-ab.orbital { --glow: 180, 120, 255; } .lo-ab.nuke { --glow: 255, 224, 74; }
.lo-ab.strike.ready, .lo-ab.lion.ready, .lo-ab.orbital.ready, .lo-ab.nuke.ready { border-color: rgba(227, 180, 90, 0.16); color: #fff2dc; box-shadow: inset 0 -2px 0 rgba(var(--glow), 0.9); animation: readyglow 1.8s ease-in-out infinite; }
.lo-ab.ready kbd { border-color: rgba(var(--glow), 0.9); box-shadow: 0 0 8px rgba(var(--glow), 0.6), 0 2px 0 #4a2c08; }
@keyframes readyglow { 50% { background-color: rgba(var(--glow), 0.12); } }
.hud-stats { right: 1.8em; bottom: 1.6em; gap: 0.5em; }
.hud-stats div { min-width: 5.5em; padding: 0.35em 0.8em; border: 1px solid var(--edge); border-bottom: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); }
.hud-stats .k { font-size: 0.7em; color: #c9ad7a; }
.hud-stats span:last-child { font-size: 1.5em; color: #fff6e0; font-variant-numeric: tabular-nums lining-nums; }
#radar { left: 1.6em; bottom: 1.6em; width: clamp(150px, 10.5vw, 300px); height: clamp(150px, 10.5vw, 300px); filter: drop-shadow(0 6px 14px rgba(0, 0, 0, 0.5)); }

/* locator brackets: thinner, softer, with a dark hairline for bright skies */
#loc-marks i { filter: drop-shadow(0 0 1px rgba(0, 0, 0, 0.9)); opacity: 0.85; }
#loc-marks i b { font-size: 0.72em; }

/* scoreboard, pause and game over share the gilded leather panel */
#scoreboard, .pause-panel, .over-panel { border: 1px solid rgba(120, 82, 34, 0.9); border-radius: 3px;
  background: var(--corner-tl) left -3px top -3px / 2.6em no-repeat, var(--corner-tr) right -3px top -3px / 2.6em no-repeat, var(--corner-bl) left -3px bottom -3px / 2.6em no-repeat, var(--corner-br) right -3px bottom -3px / 2.6em no-repeat,
    repeating-linear-gradient(33deg, rgba(255, 235, 200, 0.018) 0 2px, transparent 2px 5px), radial-gradient(ellipse 120% 100% at 50% 40%, rgba(44, 32, 22, 0.96) 0%, rgba(27, 20, 14, 0.96) 60%, rgba(16, 11, 8, 0.97) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.14), inset 0 0 40px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(0, 0, 0, 0.6), 0 24px 60px rgba(0, 0, 0, 0.55); }
#scoreboard::before, .pause-panel::before, .over-panel::before { content: ''; position: absolute; inset: 0.55em; width: auto; height: auto; border: 1px dashed rgba(227, 180, 90, 0.26); border-radius: 2px; opacity: 1; pointer-events: none; }
#scoreboard::after, .pause-panel::after, .over-panel::after { display: none; }
#scoreboard { min-width: min(46em, 90vw); padding: 1.8em 2.2em; font-size: clamp(14px, 0.85vw, 24px); animation: panelin 0.25s cubic-bezier(.2,.8,.2,1) both; }
#scoreboard h3, .pause-panel h2, .over-panel h2:not(.over-title) { margin: 0 0 0.9em; padding-bottom: 0.9em; font-size: 1.3em; letter-spacing: 0.24em; color: transparent; background: var(--divider) center bottom / 100% 0.75em no-repeat, linear-gradient(180deg, #fff3cf, #e6b55c 60%, #a8742a); -webkit-background-clip: border-box, text; background-clip: border-box, text; }
#scoreboard th, .over-table th { font-size: 0.7em; letter-spacing: 0.22em; color: #c9ad7a; border-bottom: 1px solid rgba(227, 180, 90, 0.35); }
#scoreboard td, .over-table td { font-size: 1em; color: #f2e2c0; font-variant-numeric: tabular-nums lining-nums; border-bottom: 1px solid rgba(227, 180, 90, 0.1); }
#scoreboard tbody tr:first-child td, .over-table tbody tr:first-child td { color: #fff3cf; }
td .swatch { width: 0.75em; height: 0.75em; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.6), 0 0 6px currentColor; }
.overlay { background: radial-gradient(ellipse at center, rgba(8, 6, 4, 0.45), rgba(8, 6, 4, 0.82)); backdrop-filter: blur(3px) saturate(0.8); }
.pause-panel { width: min(24em, 90vw); padding: 2.2em 2.4em; gap: 0.7em; font-size: clamp(15px, 0.9vw, 24px); animation: panelin 0.35s cubic-bezier(.2,.8,.2,1) both; }
.pause-panel .hint { text-align: center; margin: -0.4em 0 0.4em; font-style: italic; }
.over-panel { width: min(40em, 92vw); padding: 2.4em 2.6em; font-size: clamp(15px, 0.9vw, 24px); animation: panelin 0.5s cubic-bezier(.2,.8,.2,1) both; }
.over-title { font-size: 2.6em !important; }
.pause-panel .btn, .over-panel .btn { font-size: 0.82em; padding: 0.95em 1.2em; letter-spacing: 0.2em; border-radius: 2px; border: 1px solid rgba(140, 96, 40, 0.95); color: #f2e2c0; background: linear-gradient(180deg, rgba(52, 38, 24, 0.95), rgba(24, 17, 11, 0.95)); box-shadow: inset 0 1px 0 rgba(255, 220, 160, 0.16), inset 0 -2px 0 rgba(0, 0, 0, 0.4), 0 4px 12px rgba(0, 0, 0, 0.45); transition: transform 0.15s, box-shadow 0.2s, border-color 0.2s, filter 0.2s; }
.pause-panel .btn.primary, .over-panel .btn.primary { color: #2a1604; text-shadow: 0 1px 0 rgba(255, 240, 200, 0.6); border-color: #5a3a10; background: linear-gradient(180deg, #fbe3a2 0%, #e2ae55 42%, #b07a2c 58%, #d9a24c 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 240, 0.7), inset 0 -2px 0 rgba(90, 52, 10, 0.5), 0 0 0 1px rgba(0, 0, 0, 0.5), 0 6px 16px rgba(0, 0, 0, 0.5); }
.pause-panel .btn:hover, .over-panel .btn:hover { transform: translateY(-2px); border-color: rgba(255, 210, 130, 0.95); }
.pause-panel .btn:active, .over-panel .btn:active { transform: translateY(1px) scale(0.985); }

/* orbital and warhead overlays: brass type on the violet scope */
.orb-top, .orb-bottom { font-size: clamp(12px, 0.8vw, 22px); border-top: 1px solid rgba(227, 180, 90, 0.35); border-bottom: 1px solid rgba(227, 180, 90, 0.35); }
.orb-title { color: transparent; background: linear-gradient(180deg, #fff3cf, #e6b55c 60%, #a8742a); -webkit-background-clip: text; background-clip: text; }
#orbital.nuke .orb-title { background: linear-gradient(180deg, #fffbe0, #ffe04a 60%, #b08a10); -webkit-background-clip: text; background-clip: text; }
.orb-bar { width: clamp(220px, 16vw, 460px); height: 0.5em; border-color: rgba(227, 180, 90, 0.7); }
.over-title { font-size: 2.1em !important; white-space: nowrap; font-family: var(--serif) !important; font-weight: 800; letter-spacing: 0.08em !important; text-transform: uppercase !important; }
#orbital.nuke #orb-fill { background: linear-gradient(90deg, #b08a10, #ffe04a 70%, #fffbe0); box-shadow: 0 0 12px rgba(255, 224, 74, 0.7); }
.lo-ab i { border-top: 0; background: linear-gradient(0deg, rgba(227, 180, 90, 0.32), rgba(227, 180, 90, 0.06)); }
.lo-ab kbd, .lo-ab span { position: relative; z-index: 1; }


/* ------------------------------------------------ HUD review pass */
#hud { --i-grenade: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Ccircle%20cx%3D%2711%27%20cy%3D%2714.5%27%20r%3D%277%27/%3E%3Crect%20x%3D%279%27%20y%3D%275%27%20width%3D%275%27%20height%3D%273.5%27%20rx%3D%271%27/%3E%3Cpath%20d%3D%27M13.5%205.5c1-2.5%203.5-3%205.5-1.5%27%20fill%3D%27none%27%20stroke%3D%27black%27%20stroke-width%3D%271.6%27%20stroke-linecap%3D%27round%27/%3E%3Ccircle%20cx%3D%2720%27%20cy%3D%273.6%27%20r%3D%271.4%27/%3E%3C/svg%3E"); --i-strike: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M12%201.5l1.6%206.2%208.4%205v2l-8.2-2.6-.4%205.4%202.6%202v1.7L12%2020.4l-4%20.8v-1.7l2.6-2-.4-5.4L2%2014.7v-2l8.4-5z%27/%3E%3C/svg%3E"); --i-lion: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cellipse%20cx%3D%2712%27%20cy%3D%2716%27%20rx%3D%275.2%27%20ry%3D%274.4%27/%3E%3Cellipse%20cx%3D%275.6%27%20cy%3D%2710.6%27%20rx%3D%272.2%27%20ry%3D%272.8%27/%3E%3Cellipse%20cx%3D%2718.4%27%20cy%3D%2710.6%27%20rx%3D%272.2%27%20ry%3D%272.8%27/%3E%3Cellipse%20cx%3D%279%27%20cy%3D%276.2%27%20rx%3D%272.2%27%20ry%3D%272.9%27/%3E%3Cellipse%20cx%3D%2715%27%20cy%3D%276.2%27%20rx%3D%272.2%27%20ry%3D%272.9%27/%3E%3C/svg%3E"); --i-tank: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Crect%20x%3D%272%27%20y%3D%2714%27%20width%3D%2720%27%20height%3D%276%27%20rx%3D%273%27/%3E%3Cpath%20d%3D%27M5%2014l1.5-4h10l1.5%204z%27/%3E%3Crect%20x%3D%2712%27%20y%3D%278.6%27%20width%3D%2710%27%20height%3D%272%27%20rx%3D%27.8%27/%3E%3Crect%20x%3D%278%27%20y%3D%277%27%20width%3D%276%27%20height%3D%274%27%20rx%3D%271%27/%3E%3C/svg%3E"); --i-orbital: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Crect%20x%3D%279%27%20y%3D%273%27%20width%3D%276%27%20height%3D%275%27%20rx%3D%271%27/%3E%3Crect%20x%3D%271.5%27%20y%3D%273.5%27%20width%3D%276%27%20height%3D%274%27%20rx%3D%27.6%27/%3E%3Crect%20x%3D%2716.5%27%20y%3D%273.5%27%20width%3D%276%27%20height%3D%274%27%20rx%3D%27.6%27/%3E%3Cpath%20d%3D%27M10.5%209h3l2%2013h-7z%27%20opacity%3D%27.85%27/%3E%3C/svg%3E"); --i-nuke: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Ccircle%20cx%3D%2712%27%20cy%3D%2712%27%20r%3D%272.2%27/%3E%3Cpath%20d%3D%27M12%209.2L8.3%202.8A10.5%2010.5%200%200%200%203.2%2011.6h7.4A1.6%201.6%200%200%201%2012%209.2zM12%209.2l3.7-6.4a10.5%2010.5%200%200%201%205.1%208.8h-7.4A1.6%201.6%200%200%200%2012%209.2zM10.6%2013.4l-3.7%206.4a10.5%2010.5%200%200%200%2010.2%200l-3.7-6.4a1.6%201.6%200%200%201-2.8%200z%27/%3E%3C/svg%3E");
  --i-wire: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M13.5%201.5L4%2013.5h6.5L9%2022.5l10-12.5h-6.6z%27/%3E%3C/svg%3E"); --i-over: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M12%202l7%208h-4.5v5h-5v-5H5zM7%2017h10v2.2H7zM7%2020.6h10v1.9H7z%27/%3E%3C/svg%3E"); --i-sentry: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Ccircle%20cx%3D%2712%27%20cy%3D%2712%27%20r%3D%273%27/%3E%3Cpath%20d%3D%27M12%202v5M12%2017v5M2%2012h5M17%2012h5%27%20stroke%3D%27black%27%20stroke-width%3D%272%27%20stroke-linecap%3D%27round%27/%3E%3Ccircle%20cx%3D%2712%27%20cy%3D%2712%27%20r%3D%277.5%27%20fill%3D%27none%27%20stroke%3D%27black%27%20stroke-width%3D%271.6%27/%3E%3C/svg%3E"); --i-locate: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M1.5%2012S5.5%205%2012%205s10.5%207%2010.5%207-4%207-10.5%207S1.5%2012%201.5%2012z%27%20fill%3D%27none%27%20stroke%3D%27black%27%20stroke-width%3D%271.8%27/%3E%3Ccircle%20cx%3D%2712%27%20cy%3D%2712%27%20r%3D%273.4%27/%3E%3C/svg%3E"); }

/* centre banners: smaller, gone after about 1.5 s */
.announce { top: 17%; }
.announce .a-title { font-size: clamp(26px, 2vw, 58px); }
.announce .a-sub { font-size: clamp(14px, 0.9vw, 24px); }
.announce .a-sub::before { width: min(16em, 50vw); }
.announce.show { animation: announce2 1.9s cubic-bezier(.2,.8,.2,1) both; }
@keyframes announce2 { 0% { opacity: 0; transform: scale(1.12); } 10% { opacity: 1; transform: none; } 78% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translateY(-8px); } }

/* streak rewards: a keycap notice above the ability tray */
#ready-toast { position: absolute; right: 1.8em; bottom: 12.4em; display: flex; align-items: center; gap: 0.6em; padding: 0.45em 0.9em 0.45em 0.5em; font-family: var(--serif); font-weight: 700; font-size: 1.05em; letter-spacing: 0.14em; text-transform: uppercase; color: #fff3cf; border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair), 0 0 18px rgba(255, 190, 90, 0.25); opacity: 0; transform: translateY(8px); pointer-events: none; }
#ready-toast.show { animation: readyin 2.6s cubic-bezier(.2,.8,.2,1) both; }
#ready-toast kbd { font-size: 1em; min-width: 1.8em; color: #2a1604; background: linear-gradient(180deg, #fbe3a2, #d9a24c 60%, #a8742c); border: 1px solid #5a3a10; box-shadow: 0 2px 0 #4a2c08, 0 0 10px rgba(255, 200, 110, 0.6); }
@keyframes readyin { 0% { opacity: 0; transform: translateY(10px); } 10%, 80% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translateY(-4px); } }

/* top centre: the health bar is the hero, the wave plate docks to its end */
.hud-top { top: 1.3em; gap: 0; align-items: center; }
.castle-icon { width: 3.6em; height: 3.6em; margin-right: -1em; }
.hp-bar { width: clamp(380px, 30vw, 900px); height: 2.3em; border-radius: 0; border-right: 0; }
#hp-text { font-size: 1.05em; letter-spacing: 0.12em; }
.wave-box { min-width: 0; height: 2.3em; padding: 0 1em; display: flex; align-items: baseline; gap: 0.7em; justify-content: center; border: 1px solid var(--edge); border-left: 1px solid rgba(0, 0, 0, 0.6); border-radius: 0 1.15em 1.15em 0; clip-path: none; background: var(--plate); line-height: 2.3em; white-space: nowrap; }
.wave-box::before { display: none; }
#wave-label { font-size: 1.2em; line-height: inherit; }
#wave-sub { font-size: 0.92em; margin: 0; }

/* boons: icon badges with a radial timer, labelled only when new */
#boons { top: 4.9em; gap: 0.5em; }
.boon { padding: 0; gap: 0; width: 2.4em; height: 2.4em; justify-content: center; border-radius: 50%; border: 0; background: conic-gradient(var(--gem) calc(var(--t, 1) * 360deg), rgba(0, 0, 0, 0.55) 0); box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.7), 0 3px 8px rgba(0, 0, 0, 0.5); overflow: visible; transition: width 0.4s cubic-bezier(.2,.8,.2,1), border-radius 0.4s; }
.boon::before { content: ''; position: absolute; inset: 0.2em; transform: none; width: auto; height: auto; border-radius: 50%; background: radial-gradient(circle at 40% 30%, #3a2c1e, #120d08 75%); box-shadow: inset 0 0 0 1px rgba(227, 180, 90, 0.5); }
.boon::after { display: none; }
.boon i { position: relative; z-index: 1; width: 1.2em; height: 1.2em; background: var(--gem); -webkit-mask: var(--icon) center / contain no-repeat; mask: var(--icon) center / contain no-repeat; filter: drop-shadow(0 0 3px var(--gem)); }
.boon span, .boon b { position: absolute; top: calc(100% + 0.35em); left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 0.78em; letter-spacing: 0.14em; color: #f6ead0; text-shadow: 0 1px 2px #000, 0 0 6px #000; opacity: 0; transition: opacity 0.3s; }
.boon b { top: calc(100% + 1.8em); font-size: 0.72em; color: #d9c6a0; }
.boon.fresh span, .boon.fresh b, .boon.ending b { opacity: 1; }
.boon.ending b { top: calc(100% + 0.35em); color: #ffb08a; }
.boon.ending.fresh b { top: calc(100% + 1.8em); }
#boon-wire { --icon: var(--i-wire); } #boon-over { --icon: var(--i-over); background: conic-gradient(var(--gem) calc(var(--t, 1) * 360deg), rgba(0, 0, 0, 0.55) 0); border: 0; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.7), 0 3px 8px rgba(0, 0, 0, 0.5); } #boon-sentry { --icon: var(--i-sentry); } #boon-locate { --icon: var(--i-locate); }

/* bottom right: ammo stays big; kills and accuracy live on the scoreboard */
.hud-stats { display: none; }
.loadout { bottom: 1.6em; }
.lo-ab { min-width: 0; width: 3.6em; height: 3.6em; padding: 0; font-size: 1em; justify-content: center; align-items: center; overflow: hidden; }
.lo-ab::before { content: ''; width: 1.7em; height: 1.7em; background: #8c7a5c; -webkit-mask: var(--icon) center / contain no-repeat; mask: var(--icon) center / contain no-repeat; transition: background 0.3s, transform 0.3s; position: relative; z-index: 1; }
.lo-ab span { position: absolute; right: 0.25em; top: 0.2em; font-size: 0; }
.lo-ab span b { font-size: 0.7rem; font-size: clamp(10px, 0.62vw, 17px); font-weight: 800; color: #fff6de; text-shadow: 0 1px 2px #000; }
.lo-ab kbd { position: absolute; left: 0.2em; top: 0.2em; font-size: 0.62em; min-width: 1.5em; padding: 0.05em 0.3em; }
.lo-ab i { inset: 0; height: auto; width: auto; background: conic-gradient(transparent var(--fill, 0%), rgba(0, 0, 0, 0.62) 0); z-index: 2; }
.lo-ab.ready::before { background: linear-gradient(180deg, #fff3cf, rgb(var(--glow))); filter: drop-shadow(0 0 5px rgba(var(--glow), 0.8)); }
#lo-grenade { --icon: var(--i-grenade); } #lo-strike { --icon: var(--i-strike); } #lo-lion { --icon: var(--i-lion); } #lo-tank { --icon: var(--i-tank); } #lo-orbital { --icon: var(--i-orbital); } #lo-nuke { --icon: var(--i-nuke); }
#lo-grenade.ready { --glow: 246, 212, 138; }

/* locator brackets hold up over foliage */
#loc-marks i { opacity: 1; filter: drop-shadow(0 0 1px #000) drop-shadow(0 0 1px #000) drop-shadow(0 0 3px rgba(0, 0, 0, 0.6)); }
#loc-marks i.near { --c: #9dffe6; }
#loc-marks i b { font-size: max(11px, 0.72em); font-weight: 700; text-shadow: 0 0 2px #000, 0 0 4px #000, 0 1px 2px #000; }

/* kill feed: one plate, fixed-width right-aligned rows */
#killfeed { width: 22em; gap: 0; padding: 0.3em 0; background: linear-gradient(90deg, transparent, rgba(12, 9, 6, 0.62) 22%); border-right: 2px solid rgba(227, 180, 90, 0.7); }
#killfeed:empty { display: none; }
#killfeed li { justify-content: flex-end; padding: 0.3em 0.9em; background: none; border-right: 0; }
#killfeed li .kf-v { font-style: normal; text-transform: lowercase; opacity: 0.75; font-family: var(--body); }
#killfeed li .kf-w { color: #ffffff; }
#killfeed li .hs { margin: 0 0.3em 0 0; }
@keyframes feed2 { 0% { opacity: 0; transform: translateX(1.2em); } 6%, 86% { opacity: 1; transform: none; } 100% { opacity: 0; } }

/* toasts below the aim zone on a crisp plate */
#toast { top: 70%; bottom: auto; padding: 0.5em 1.4em; font-style: normal; font-size: clamp(15px, 0.95vw, 26px); border: 1px solid var(--edge); background: var(--plate); box-shadow: var(--hair); }

/* orbital and warhead: a brass rim around the scope, bright instructions */
.orb-frame::before { content: ''; position: absolute; inset: 0; background: radial-gradient(circle 44vh at 50% 50%, transparent 97.3%, #7a4e18 97.6%, #f2cf84 98%, #d9a24c 98.4%, #5a3a10 98.9%, transparent 99.2%); }
.orb-top, .orb-bottom { color: #fff6e0; background: linear-gradient(90deg, transparent, rgba(12, 9, 6, 0.88) 12%, rgba(12, 9, 6, 0.88) 88%, transparent); border-color: rgba(227, 180, 90, 0.6); }
.orb-hint { opacity: 1; color: #fff3cf; }
#orb-coords { color: #f2e2c0; }
.boon.fresh { width: auto; padding: 0 0.9em 0 0.4em; gap: 0.5em; border-radius: 1.2em; background: var(--plate); box-shadow: 0 0 0 1px var(--edge), 0 3px 8px rgba(0, 0, 0, 0.5); }
.boon.fresh::before { display: none; }
.boon.fresh i { width: 1.3em; height: 1.3em; }
.boon.fresh span, .boon.fresh b, .boon.ending.fresh b { position: static; transform: none; opacity: 1; font-size: 0.8em; }
.lo-ab { width: 4.3em; height: 4.3em; }
.lo-ab::before { width: 2.1em; height: 2.1em; margin-top: 0.5em; }
.lo-ab kbd { font-size: 0.6em; }
.lo-slots:not(:has(#lo-slot2:not(.hidden))) { display: none; }
#ready-toast { bottom: 12.8em; }
#boon-over.fresh { background: var(--plate); box-shadow: 0 0 0 1px var(--edge), 0 3px 8px rgba(0, 0, 0, 0.5); }
.orb-frame::before { background: radial-gradient(circle 45.2vh at 50% 50%, transparent 96.6%, #4a2c08 96.9%, #d9a24c 97.5%, #fbe3a2 98.1%, #b07a2c 98.8%, #3a2208 99.4%, transparent 99.7%); }


/* ------------------------------------------------ wave tally: the run's score, bottom left */
#wave-tally { --c: #ece2cc; position: absolute; left: calc(1.6em + clamp(150px, 10.5vw, 300px) + 1.2em); bottom: 1.2em; height: clamp(70px, 11vh, 190px); display: flex; align-items: flex-end; pointer-events: none; color: var(--c); transition: color 1.6s ease, filter 1.6s ease; filter: drop-shadow(0 3px 0 rgba(20, 8, 4, 0.85)) drop-shadow(0 0 12px rgba(0, 0, 0, 0.55)); }
#wave-tally.active { --c: #b3170e; filter: drop-shadow(0 3px 0 rgba(30, 4, 2, 0.9)) drop-shadow(0 0 16px rgba(160, 20, 10, 0.45)) drop-shadow(0 0 2px rgba(0, 0, 0, 0.9)); }
#wave-tally .wt-marks { height: 100%; width: auto; overflow: visible; }
#wave-tally .wt-marks path { fill: none; stroke: currentColor; stroke-width: 12; stroke-linecap: round; stroke-linejoin: round; }
#wave-tally .wt-marks path.new { stroke-dasharray: 160; stroke-dashoffset: 160; animation: scratch 0.45s cubic-bezier(.6,.05,.4,1) forwards; }
@keyframes scratch { to { stroke-dashoffset: 0; } }
#wave-tally .wt-num { display: none; font-family: var(--display); font-weight: 900; font-size: clamp(64px, 10.5vh, 180px); line-height: 0.8; letter-spacing: 0.02em; color: currentColor; filter: url(#f-scratch); -webkit-text-stroke: 0.02em rgba(20, 6, 3, 0.6); }
#wave-tally.numeral .wt-marks { display: none; }
#wave-tally.numeral .wt-num { display: block; }
#wave-tally.flare { animation: waveflare 1.1s cubic-bezier(.2,.8,.2,1); }
@keyframes waveflare { 0% { transform: scale(1.35); filter: drop-shadow(0 0 30px rgba(255, 60, 30, 0.95)) brightness(1.6); } 100% { transform: none; } }
#wave-tally { transform-origin: left bottom; }
#hud.orbital-mode #wave-tally { display: none; }

/* co-op connection status */
.no-lan .lan-only, .no-online .online-only, .no-lan.no-online .net-any { display: none !important; }
.room-row input { flex: 1; text-transform: uppercase; letter-spacing: 0.3em; font-size: 20px; }
.room-code { margin: 6px 0 12px; font-size: 15px; letter-spacing: 0.08em; opacity: 0.85; }
.room-code b { margin-left: 10px; padding: 4px 12px; border-radius: 4px; font-size: 26px; letter-spacing: 0.32em; color: var(--gold); background: rgba(20, 14, 8, 0.55); border: 1px solid rgba(227, 180, 90, 0.4); user-select: all; }
.lobby-list .away { font-size: 0.8em; opacity: 0.7; }
#menu-solo { width: auto; justify-self: start; margin-top: 10px; }
.net-wait { z-index: 35; align-items: start; background: linear-gradient(rgba(8, 6, 4, 0.55), rgba(8, 6, 4, 0) 40%); backdrop-filter: none; pointer-events: none; }
.net-wait-box { display: flex; align-items: center; gap: 12px; margin-top: 14vh; padding: 12px 22px; border-radius: 6px; font-size: 20px; letter-spacing: 0.06em; color: #f2d9a0; background: rgba(20, 14, 8, 0.75); border: 1px solid rgba(227, 180, 90, 0.35); }
#netend { z-index: 40; }
.public-toggle { display: flex; align-items: center; gap: 10px; margin: 4px 0 14px; font-size: 15px; cursor: pointer; }
.public-toggle input { width: 18px; height: 18px; accent-color: var(--gold); }
.list-head { margin: 14px 0 6px; font-size: 14px; letter-spacing: 0.18em; text-transform: uppercase; opacity: 0.8; }
