/* ---- Bluejay brand type (self-hosted; licensed — see brand kit) ----
   Guidelines: short headlines = Terrane Serif Bold, tracking -10;
   longer headlines = Terrane Sans; body = Haffer Regular, tracking +20;
   small caps headers = Haffer, tracking +60. */
@font-face { font-family: "Terrane Serif"; src: url("assets/fonts/TerraneSerifWeb-Bold.woff2") format("woff2");  font-weight: 700; font-display: block; }
@font-face { font-family: "Terrane Serif"; src: url("assets/fonts/TerraneSerifWeb-Black.woff2") format("woff2"); font-weight: 900; font-display: block; }
@font-face { font-family: "Terrane Sans";  src: url("assets/fonts/TerraneSansWeb-Regular.woff2") format("woff2"); font-weight: 400; font-display: block; }
@font-face { font-family: "Terrane Sans";  src: url("assets/fonts/TerraneSansWeb-Bold.woff2") format("woff2");    font-weight: 700; font-display: block; }
@font-face { font-family: "Haffer"; src: url("assets/fonts/Haffer-Regular.woff2") format("woff2"); font-weight: 400; font-display: block; }
@font-face { font-family: "Haffer"; src: url("assets/fonts/Haffer-Medium.woff2") format("woff2");  font-weight: 500; font-display: block; }

:root {
  /* display (short headlines) / UI + body */
  --display: "Terrane Serif", Georgia, serif;
  --sans: "Terrane Sans", "Haffer", system-ui, sans-serif;
  --body: "Haffer", system-ui, -apple-system, sans-serif;

  /* Bluejay palette — primary from the brand guidelines, secondary used for glow/atmosphere.
     #3174FF is the brand blue but sits dark on near-black, so Cyan carries on-dark text + strokes. */
  --jay: #3174FF;
  --jay-lite: #6FD0FB;
  --jay-deep: #1B3FA8;
  --purple: #8A5EEB;
  --pink: #FFBEFF;
  --ink: #070911;
  --panel: #101426;
  --line: rgba(111, 208, 251, 0.32);
  --text: #FAFAFA;
  --dim: #8FA3BD;
  --danger: #ff4d5e;
  --gold: #ffd166;
  /* shared cut-corner shape language — cards/tabs/buttons chamfer top-right + bottom-left.
     borders are inset box-shadows (clip-path clips a real border away, inset shadows follow the cut). */
  --chamfer: polygon(0 0, calc(100% - 13px) 0, 100% 13px, 100% 100%, 13px 100%, 0 calc(100% - 13px));
  --chamfer-sm: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 7px 100%, 0 calc(100% - 7px));
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  height: 100%;
  background: var(--ink);
  font-family: var(--body);
  letter-spacing: 0.02em;
  color: var(--text);
  overflow: hidden;
}

body {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(1200px 600px at 50% -10%, rgba(111,208,251,0.10), transparent 60%),
    var(--ink);
}

#stage {
  position: relative;
  width: min(96vw, calc(96vh * 16 / 9));
  aspect-ratio: 16 / 9;
  box-shadow: 0 0 0 1px var(--line), 0 30px 80px rgba(0,0,0,0.7), 0 0 120px rgba(111,208,251,0.12);
  border-radius: 10px;
  overflow: hidden;
}

#game {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  /* custom aiming reticle — JAY ring + gold pip, hotspot dead-center */
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='34' height='34' viewBox='0 0 34 34'%3E%3Cg fill='none' stroke='%236FD0FB' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='17' cy='17' r='9'/%3E%3Cline x1='17' y1='2' x2='17' y2='8'/%3E%3Cline x1='17' y1='26' x2='17' y2='32'/%3E%3Cline x1='2' y1='17' x2='8' y2='17'/%3E%3Cline x1='26' y1='17' x2='32' y2='17'/%3E%3C/g%3E%3Ccircle cx='17' cy='17' r='2' fill='%23ffd166'/%3E%3C/svg%3E") 17 17, crosshair;
  background: var(--ink);
}

/* CRT atmosphere */
#crt {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 3px),
    radial-gradient(ellipse at center, transparent 55%, rgba(2,6,14,0.55) 100%);
  mix-blend-mode: overlay;
}

/* ---------- overlays ---------- */
.overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  background: rgba(4, 9, 18, 0.82);
  backdrop-filter: blur(6px);
  text-align: center;
  padding: 24px;
  z-index: 5;
}
.overlay.hidden { display: none; }

.lockup { width: 180px; opacity: 0.95; filter: drop-shadow(0 0 18px rgba(111,208,251,0.5)); }

/* the flock's world peeks through on the title screen, dimmed for the storm */
.menu-scene {
  background:
    linear-gradient(180deg, rgba(4,9,18,0.78) 0%, rgba(4,9,18,0.62) 45%, rgba(4,9,18,0.85) 100%),
    url("assets/scene_01.jpg") center / cover no-repeat;
}

#menuBird {
  height: 110px;
  filter: drop-shadow(0 12px 24px rgba(0,0,0,0.5));
  animation: hover 2.6s ease-in-out infinite;
}
@keyframes hover {
  0%, 100% { transform: translateY(0) rotate(-2deg); }
  50% { transform: translateY(-12px) rotate(2deg); }
}

#overBird {
  height: 96px;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.5)) saturate(0.8);
}

h1, h2 {
  font-family: var(--display);
  font-weight: 900;
  letter-spacing: -0.01em;
  color: var(--text);
  text-shadow: 0 0 28px rgba(111,208,251,0.45), 0 3px 0 var(--jay-deep);
}
h1 { font-size: clamp(34px, 6vw, 64px); line-height: 1; }
h1 span { color: var(--jay); }
h2 { font-size: clamp(26px, 4.5vw, 44px); }
.hub-panel h2, .codex-head h2 { text-shadow: 0 0 18px rgba(111,208,251,0.4); }
h2.dead { color: var(--danger); text-shadow: 0 0 24px rgba(255,77,94,0.55), 0 4px 0 rgba(90,10,20,0.8); }

.tag { font-family: var(--sans); color: var(--dim); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; }
.hint { color: var(--dim); font-size: 12px; }

kbd {
  font-family: inherit;
  font-size: 11px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 4px;
  padding: 2px 6px;
  background: var(--panel);
  color: var(--jay-lite);
}

.controls {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: center;
  font-size: 12px;
  color: var(--dim);
  margin: 6px 0 4px;
}

button {
  font-family: var(--display);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.01em;
  color: #04101e;
  background: linear-gradient(180deg, #6FD0FB, var(--jay) 58%, var(--jay-deep));
  border: none;
  border-radius: 8px;
  padding: 13px 34px;
  cursor: pointer;
  box-shadow: 0 0 28px rgba(111,208,251,0.5), inset 0 1px 0 rgba(255,255,255,0.5);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
button:hover { transform: translateY(-2px) scale(1.03); box-shadow: 0 0 44px rgba(111,208,251,0.8), inset 0 1px 0 rgba(255,255,255,0.5); }
button:active { transform: translateY(1px) scale(0.99); }

button.ghost {
  background: rgba(8,16,32,0.7);
  color: var(--jay-lite);
  border: 1px solid var(--line);
  box-shadow: none;
}
button.ghost:hover { box-shadow: 0 0 20px rgba(111,208,251,0.3); }
button.small { font-size: 12px; padding: 8px 18px; }

/* ---------- mode select ---------- */
.modes { display: flex; gap: 18px; flex-wrap: wrap; justify-content: center; margin-top: 10px; }
.mode-btn {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 250px;
  padding: 18px 20px;
  text-align: center;
}
.mode-btn .mode-title { font-size: 19px; }
.mode-btn .mode-sub {
  font-family: var(--body);
  font-size: 10px;
  letter-spacing: 0.08em;
  opacity: 0.75;
  text-transform: uppercase;
}
.mode-btn.alt {
  background: linear-gradient(180deg, #ffe39a, var(--gold) 55%, #d9a32e);
  box-shadow: 0 0 28px rgba(255,209,102,0.4), inset 0 1px 0 rgba(255,255,255,0.5);
}
.mode-btn.alt:hover { box-shadow: 0 0 44px rgba(255,209,102,0.7), inset 0 1px 0 rgba(255,255,255,0.5); }

/* ---------- multiplayer menus ---------- */
input {
  font-family: var(--body);
  font-size: 15px;
  color: var(--text);
  background: rgba(8,16,32,0.85);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 11px 14px;
  text-align: center;
  outline: none;
  width: 220px;
}
input:focus { border-color: var(--jay); box-shadow: 0 0 16px rgba(111,208,251,0.3); }
#codeInput { width: 110px; text-transform: uppercase; letter-spacing: 0.3em; }

.mp-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center; }
.or { color: var(--dim); font-size: 12px; }
.hint.warn { color: var(--danger); min-height: 16px; }

#roomCodeBig {
  font-family: var(--display); font-weight: 700;
  font-size: 64px;
  letter-spacing: 0.28em;
  color: var(--gold);
  text-shadow: 0 0 30px rgba(255,209,102,0.6), 0 4px 0 rgba(120,80,10,0.8);
  margin-right: -0.28em;
}

#lobbyPlayers { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; max-width: 560px; }
.pchip {
  font-size: 12px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(8,16,32,0.85);
  border: 1.5px solid var(--c, var(--jay));
  color: var(--c, var(--jay));
  animation: cardIn 0.3s cubic-bezier(0.2, 1.4, 0.4, 1) backwards;
}

/* ---------- chapter card ---------- */
#chapter {
  position: absolute;
  top: 18%;
  left: 0; right: 0;
  text-align: center;
  pointer-events: none;
  z-index: 4;
}
#chapter.hidden { display: none; }
#chapter h3 {
  font-family: var(--body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.5em;
  color: var(--gold);
  margin-right: -0.5em;
}
#chapter h2 { font-size: clamp(30px, 5vw, 52px); }
#chapter.animate h3 { animation: chapterKickerIn 2.6s cubic-bezier(0.16, 1, 0.3, 1) both; }
#chapter.animate h2 { animation: chapterIn 2.6s cubic-bezier(0.16, 1, 0.3, 1) both; }
#chapter.animate::after {
  content: "";
  display: block;
  margin: 10px auto 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--jay), var(--gold), transparent);
  animation: chapterSweep 2.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes chapterKickerIn {
  0% { opacity: 0; letter-spacing: 0.9em; filter: blur(6px); transform: translateY(10px) scale(0.94); }
  14%, 78% { opacity: 1; letter-spacing: 0.5em; filter: blur(0); transform: translateY(0) scale(1); }
  100% { opacity: 0; letter-spacing: 0.3em; filter: blur(3px); transform: translateY(-10px) scale(1.03); }
}
@keyframes chapterIn {
  0% { opacity: 0; transform: translateY(28px) scale(0.9); filter: blur(10px); }
  14%, 78% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
  100% { opacity: 0; transform: translateY(-16px) scale(1.06); filter: blur(6px); }
}
@keyframes chapterSweep {
  0% { width: 0; opacity: 0; }
  14% { width: 240px; opacity: 1; }
  78% { width: 240px; opacity: 1; }
  100% { width: 0; opacity: 0; }
}

@keyframes cardIn { from { opacity: 0; transform: translateY(26px) scale(0.92); } }

/* ---------- game over stats ---------- */
#stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(130px, 1fr));
  gap: 8px 28px;
  font-size: 13px;
  background: rgba(8,16,32,0.7);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 16px 24px;
}
#stats div { display: flex; justify-content: space-between; gap: 16px; }
#stats .k { color: var(--dim); }
#stats .v { color: var(--jay); font-weight: 700; }
#stats .v.gold { color: var(--gold); }

/* ---------- settings chips ---------- */
.settings { display: flex; gap: 10px; }
.chip {
  font-family: var(--body);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--dim);
  background: rgba(8, 16, 32, 0.8);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 7px 16px;
  cursor: pointer;
  box-shadow: none;
}
.chip:hover { transform: translateY(-1px); border-color: var(--jay); color: var(--text); box-shadow: none; }
.chip.on { color: var(--jay); border-color: var(--jay); background: rgba(111,208,251, 0.12); }

/* ---------- The Perch hub panel ---------- */
/* full-stage dark wash behind the panel — centers it and dims the world */
.hub-scrim {
  position: absolute;
  inset: 0;
  z-index: 19;
  display: grid;
  place-items: center;
  padding: 24px;
  background: radial-gradient(120% 120% at 50% 40%, rgba(4, 9, 20, 0.55), rgba(4, 9, 20, 0.86));
  backdrop-filter: blur(3px) saturate(0.9);
  -webkit-backdrop-filter: blur(3px) saturate(0.9);
}
.hub-scrim.hidden { display: none; }

#hubPanel.hub-panel {
  position: relative;
  width: min(680px, 92%);
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  padding: 30px 30px 24px;
  /* flat, modern surface — one dark fill, a hairline border, a single soft drop shadow */
  background: #0b1424;
  border: 1px solid rgba(120, 160, 210, 0.22);
  border-top: 2px solid var(--jay);
  border-radius: 16px;
  box-shadow: 0 30px 70px -20px rgba(0, 0, 0, 0.8);
}
#hubPanel.hidden { display: none; }

/* ---------- Perch enter/exit motion (JS toggles .is-in / .is-out) ---------- */
.hub-scrim {
  opacity: 0;
  transition: opacity 0.18s ease, backdrop-filter 0.18s ease;
}
.hub-scrim.is-in { opacity: 1; }
.hub-scrim.is-out { opacity: 0; transition-duration: 0.14s; }

#hubPanel.hub-panel {
  opacity: 0;
  transform: scale(0.94) translateY(12px);
  transition:
    opacity 0.22s cubic-bezier(0.2, 0.9, 0.25, 1),
    transform 0.22s cubic-bezier(0.2, 0.9, 0.25, 1);
}
#hubPanel.hub-panel.is-in { opacity: 1; transform: scale(1) translateY(0); }
#hubPanel.hub-panel.is-out { opacity: 0; transform: scale(0.96) translateY(0); transition-duration: 0.14s; }

/* card entrance stagger — nothing pops in */
@keyframes hubCardIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
#hubPanelBody .card-grid > *,
#hubPanelBody .icon-card-grid > *,
#hubPanelBody .swatch-grid > * {
  animation: hubCardIn 0.26s cubic-bezier(0.2, 0.9, 0.25, 1) both;
}
#hubPanelBody .card-grid > *:nth-child(1),
#hubPanelBody .icon-card-grid > *:nth-child(1),
#hubPanelBody .swatch-grid > *:nth-child(1) { animation-delay: 0.035s; }
#hubPanelBody .card-grid > *:nth-child(2),
#hubPanelBody .icon-card-grid > *:nth-child(2),
#hubPanelBody .swatch-grid > *:nth-child(2) { animation-delay: 0.07s; }
#hubPanelBody .card-grid > *:nth-child(3),
#hubPanelBody .icon-card-grid > *:nth-child(3),
#hubPanelBody .swatch-grid > *:nth-child(3) { animation-delay: 0.105s; }
#hubPanelBody .card-grid > *:nth-child(4),
#hubPanelBody .icon-card-grid > *:nth-child(4),
#hubPanelBody .swatch-grid > *:nth-child(4) { animation-delay: 0.14s; }
#hubPanelBody .card-grid > *:nth-child(5),
#hubPanelBody .icon-card-grid > *:nth-child(5),
#hubPanelBody .swatch-grid > *:nth-child(5) { animation-delay: 0.175s; }
#hubPanelBody .card-grid > *:nth-child(6),
#hubPanelBody .icon-card-grid > *:nth-child(6),
#hubPanelBody .swatch-grid > *:nth-child(6) { animation-delay: 0.21s; }
#hubPanelBody .card-grid > *:nth-child(7),
#hubPanelBody .icon-card-grid > *:nth-child(7),
#hubPanelBody .swatch-grid > *:nth-child(7) { animation-delay: 0.245s; }
#hubPanelBody .card-grid > *:nth-child(8),
#hubPanelBody .icon-card-grid > *:nth-child(8),
#hubPanelBody .swatch-grid > *:nth-child(8) { animation-delay: 0.28s; }

@media (prefers-reduced-motion: reduce) {
  .hub-scrim,
  .hub-scrim.is-in,
  .hub-scrim.is-out { transition: opacity 0.12s linear; backdrop-filter: blur(3px) saturate(0.9); }
  #hubPanel.hub-panel {
    transform: none;
    transition: opacity 0.12s linear;
  }
  #hubPanel.hub-panel.is-in,
  #hubPanel.hub-panel.is-out { transform: none; }
  #hubPanelBody .card-grid > *,
  #hubPanelBody .icon-card-grid > *,
  #hubPanelBody .icon-row > *,
  #hubPanelBody .swatch-grid > * {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
.hub-panel-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid rgba(120, 160, 210, 0.2); gap: 10px;
}
.hub-panel-head h2 { font-family: var(--display); font-weight: 700; font-size: 15px; color: var(--jay-lite); text-shadow: none; margin: 0; display: flex; align-items: center; gap: 11px; }
.hub-avatar {
  flex-shrink: 0; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-size: 17px; line-height: 1;
  background: color-mix(in srgb, var(--tint) 22%, transparent);
  border: 1.5px solid color-mix(in srgb, var(--tint) 70%, transparent);
  box-shadow: 0 0 14px color-mix(in srgb, var(--tint) 45%, transparent), inset 0 0 8px rgba(0,0,0,0.3);
}
.hub-id { display: flex; flex-direction: column; gap: 3px; }
.hub-name { font-family: var(--display); font-weight: 700; font-size: 15px; line-height: 1; }
.hub-panel-head .hub-role { font-family: var(--body); font-size: 9px; font-weight: 700; color: var(--dim); letter-spacing: 0.22em; }
.hub-panel-head .ghost.small { flex-shrink: 0; }
#hubPanelBody { overflow-y: auto; padding-right: 6px; }

/* ---------- shop tabs (segmented category row) ---------- */
.shop-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 4px 0 20px;
}
.shop-tab {
  font-family: var(--body);
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--dim);
  background: rgba(8, 16, 32, 0.6);
  border: 1px solid rgba(120, 160, 210, 0.22);
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  transition: color 0.12s, background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.12s;
}
.shop-tab:hover {
  color: var(--text);
  border-color: color-mix(in srgb, var(--c, var(--jay)) 55%, transparent);
  transform: translateY(-1px);
}
.shop-tab.active {
  color: #05131f;
  background: var(--c, var(--jay));
  border-color: color-mix(in srgb, var(--c, var(--jay)) 60%, #000);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 0 16px color-mix(in srgb, var(--c, var(--jay)) 40%, transparent);
}
.shop-tab:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--c, var(--jay)) 75%, transparent);
  outline-offset: 2px;
}

/* armory Weapons/Specials tabs — segmented control matching the shop's drill-in feel */
.armory-tabs { display: flex; gap: 8px; margin: 2px 0 18px; }
.armory-tab {
  flex: 1;
  display: flex; align-items: center; justify-content: center; gap: 7px;
  font-family: var(--body); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--dim);
  background: rgba(255, 255, 255, 0.03);
  clip-path: var(--chamfer);
  box-shadow: inset 0 0 0 1.5px rgba(120, 160, 210, 0.18);
  border: none; padding: 11px 14px; cursor: pointer;
  transition: color 0.12s, background 0.12s, box-shadow 0.12s;
}
.armory-tab:hover { color: var(--text); box-shadow: inset 0 0 0 1.5px rgba(120, 160, 210, 0.4); }
.armory-tab.active { color: #05131f; background: var(--jay); box-shadow: inset 0 0 0 1.5px var(--jay); }
.armory-tab.active .branch-ico { background: rgba(0, 0, 0, 0.12); }

/* compact close button — pinned to the panel's top-right corner */
.hub-close {
  position: absolute; top: 10px; right: 12px; z-index: 2;
  width: 29px; height: 29px; padding: 0; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  font-family: var(--body); font-size: 14px; line-height: 1;
  color: var(--dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(120, 160, 210, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: color 0.12s, background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.12s;
}
.hub-close:hover {
  color: var(--danger);
  background: color-mix(in srgb, var(--danger) 16%, transparent);
  border-color: color-mix(in srgb, var(--danger) 55%, transparent);
  box-shadow: 0 0 12px color-mix(in srgb, var(--danger) 45%, transparent), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.hub-close:active { transform: translateY(1px); box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.4); }
.hub-close:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--danger) 70%, transparent);
  outline-offset: 2px;
}

/* NPC dialogue — a little speech card so each stop reads as a character, not a menu */
.hub-npc {
  display: flex; align-items: center; gap: 10px; margin: 0 0 14px;
  padding: 9px 12px; border-radius: 10px;
  background: color-mix(in srgb, var(--tint) 8%, rgba(255,255,255,0.02));
  border: 1px solid color-mix(in srgb, var(--tint) 26%, transparent);
  border-left: 3px solid var(--tint);
}
.hub-npc-avatar { flex-shrink: 0; font-size: 20px; line-height: 1; filter: drop-shadow(0 0 6px var(--tint)); }
.hub-npc-line { font-style: italic; color: #dcecff; font-size: 12.5px; line-height: 1.35; }

/* branch section header (shop tree + weapons/specials groupings) */
.branch-head {
  display: flex; align-items: center; gap: 7px;
  grid-column: 1 / -1; font-weight: 700; font-size: 11px; letter-spacing: 1.4px;
  color: var(--c, var(--jay)); margin: 14px 0 7px;
}
.branch-head::after {
  content: ""; flex: 1; height: 1px; margin-left: 2px;
  background: linear-gradient(90deg, color-mix(in srgb, var(--c, var(--jay)) 45%, transparent), transparent);
}
.branch-head:first-of-type { margin-top: 2px; }
.branch-ico {
  font-size: 11px; width: 20px; height: 20px; border-radius: 6px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--c, var(--jay)) 16%, transparent);
}

/* shop-tree cards — flat surface, quiet hover lift */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(172px, 1fr)); gap: 14px; margin-bottom: 8px; }
.shop-node {
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.035);
  clip-path: var(--chamfer);
  box-shadow: inset 0 0 0 1.5px rgba(120, 160, 210, 0.18);
  transition: background 0.12s, transform 0.12s, box-shadow 0.12s;
}
.shop-node.ok { background: rgba(91, 224, 122, 0.06); box-shadow: inset 0 0 0 1.5px rgba(91, 224, 122, 0.5); }
.shop-node.owned { background: rgba(255, 209, 102, 0.06); box-shadow: inset 0 0 0 1.5px rgba(255, 209, 102, 0.42); }
.shop-node.branch-pick { box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--c, var(--jay)) 45%, transparent); }
.shop-node.locked { opacity: 0.5; }
.shop-node.ok:hover, .shop-node.owned:hover, .shop-node.branch-pick:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.07);
}
.sn-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 11.5px; }
.sn-top b { font-size: 11.5px; font-weight: 700; }
.sn-desc { font-size: 10px; color: #9db4d0; margin-top: 6px; line-height: 1.4; }

/* compact state badges: owned check, cost pill, lock, buy button */
.badge {
  font-size: 10px; font-weight: 700; white-space: nowrap; border-radius: 6px; padding: 3px 8px; letter-spacing: 0.03em;
}
.badge.owned {
  color: var(--gold);
  background: rgba(255, 209, 102, 0.12);
  border: 1px solid rgba(255, 209, 102, 0.3);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.badge.cost {
  color: #9fb6d0;
  background: rgba(120, 160, 210, 0.1);
  border: 1px solid rgba(120, 160, 210, 0.22);
}
.badge.lock {
  color: #7d8fa8;
  background: rgba(120, 160, 210, 0.06);
  border: 1px solid rgba(120, 160, 210, 0.14);
}

/* pill action buttons — tactile flat with subtle gradient + inner highlight */
.badge-buy {
  font-family: var(--body); font-size: 10px; font-weight: 700; white-space: nowrap;
  letter-spacing: 0.04em; border: none; border-radius: 0; padding: 5px 12px; cursor: pointer;
  clip-path: var(--chamfer-sm);
  transition: filter 0.12s, transform 0.12s;
}
.badge-buy.buy { color: #2a1c00; background: var(--gold); }
.badge-buy.equip { color: #05131f; background: var(--jay); }
.badge-buy:hover { filter: brightness(1.08); transform: translateY(-1px); }
.badge-buy:active { transform: translateY(1px); filter: brightness(0.96); }
.badge-buy.buy:focus-visible { outline: 2px solid color-mix(in srgb, var(--gold) 80%, transparent); outline-offset: 2px; }
.badge-buy.equip:focus-visible { outline: 2px solid color-mix(in srgb, var(--jay) 80%, transparent); outline-offset: 2px; }

/* weapons/specials — icon cards */
.icon-card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(154px, 1fr)); gap: 14px; margin-bottom: 8px; }
/* armory: horizontally scrollable progression rows */
.icon-row { display: flex; gap: 14px; overflow-x: auto; padding: 2px 2px 10px; margin-bottom: 12px; scrollbar-width: thin; scrollbar-color: rgba(120, 160, 210, 0.35) transparent; }
.icon-row > * { flex: 0 0 154px; }
#hubPanelBody .icon-row > * { animation: hubCardIn 0.26s cubic-bezier(0.2, 0.9, 0.25, 1) both; }
.icon-card {
  position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 7px;
  padding: 18px 13px 13px;
  background: rgba(255, 255, 255, 0.035);
  clip-path: var(--chamfer);
  box-shadow: inset 0 0 0 1.5px rgba(120, 160, 210, 0.18);
  transition: background 0.12s, transform 0.12s, box-shadow 0.12s;
}
.icon-card:hover { transform: translateY(-2px); background: rgba(255, 255, 255, 0.07); }
.icon-card.ok { box-shadow: inset 0 0 0 1.5px rgba(91, 224, 122, 0.4); }
.icon-card.locked { opacity: 0.5; }
.icon-card.eq { background: rgba(255, 209, 102, 0.08); box-shadow: inset 0 0 0 1.5px var(--gold); }
.ic-icon { width: 34px; height: 34px; }
.ic-icon svg { width: 100%; height: 100%; filter: drop-shadow(0 0 6px currentColor); }
.ic-icon .ico-fallback { font-size: 26px; line-height: 34px; }
.ic-name { font-size: 11.5px; font-weight: 700; color: var(--text); }
.ic-tag { font-size: 9.5px; color: #8fa6c2; line-height: 1.25; min-height: 22px; }
.ic-cd { display: block; color: #6a8099; margin-top: 1px; }
.ic-action { margin-top: 2px; }

/* skins — color swatch grid */
.swatch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 14px; }
.swatch-card {
  display: flex; flex-direction: column; align-items: center; gap: 9px; text-align: center;
  padding: 17px 12px;
  background: rgba(255, 255, 255, 0.035);
  clip-path: var(--chamfer);
  box-shadow: inset 0 0 0 1.5px rgba(120, 160, 210, 0.18);
  transition: background 0.12s, transform 0.12s, box-shadow 0.12s;
}
.swatch-card:hover { transform: translateY(-2px); background: rgba(255, 255, 255, 0.07); }
.swatch-card.ok { box-shadow: inset 0 0 0 1.5px rgba(91, 224, 122, 0.35); }
.swatch-card.locked { opacity: 0.55; }
.swatch-card.eq { background: rgba(255, 209, 102, 0.08); box-shadow: inset 0 0 0 1.5px var(--gold); }
.swatch-chip {
  width: 36px; height: 36px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, 0.25);
  box-shadow: inset 0 0 8px rgba(0, 0, 0, 0.35), 0 0 10px rgba(0, 0, 0, 0.3);
}

/* ---------- the roost (permanent meta upgrades) ---------- */
#roostList { display: flex; flex-direction: column; gap: 8px; max-width: 460px; margin: 16px 0; }

/* hub roost station — current-build loadout chips + owned-upgrade/perk tags */
.loadout-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.loadout-chip {
  display: flex; align-items: center; gap: 6px;
  border: 1px solid rgba(120, 160, 210, 0.25); border-radius: 999px;
  padding: 5px 10px 5px 6px; background: rgba(255, 255, 255, 0.03);
  font-size: 11px; font-weight: 700; color: var(--text);
}
.loadout-chip .ic-icon { width: 18px; height: 18px; }
.loadout-chip .swatch-chip { width: 18px; height: 18px; border-width: 1px; }
.loadout-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 14px; }
.tag-chip {
  font-size: 10px; font-weight: 700; color: #9fb6d0; background: rgba(120, 160, 210, 0.1);
  border: 1px solid rgba(120, 160, 210, 0.22); border-radius: 999px; padding: 3px 8px;
}
.tag-chip.perk { color: var(--gold); background: rgba(255, 209, 102, 0.1); border-color: rgba(255, 209, 102, 0.3); }
.tag-chip.dim { opacity: 0.5; }

/* ---------- quick level-up pick (1-of-3, between chapters) ---------- */
/* level-up: dim the still-living gameplay behind the cards, don't black it out */
#levelup { background: rgba(6, 12, 24, 0.44); backdrop-filter: blur(2px); }
/* level-up screen slides in — the scrim fades, the heading + cards stagger up (nothing pops in) */
@keyframes overlayIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes lvlCardIn { from { opacity: 0; transform: translateY(16px) scale(0.97); } to { opacity: 1; transform: none; } }
#levelup:not(.hidden) { animation: overlayIn 0.2s ease both; }
#levelup:not(.hidden) h2 { animation: lvlCardIn 0.3s cubic-bezier(0.2, 0.9, 0.25, 1) both; }
#levelCards { display: flex; flex-direction: row; gap: 16px; margin: 18px 0; flex-wrap: wrap; justify-content: center; }
.lvl-card {
  position: relative; width: 208px; cursor: pointer; text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 9px;
  padding: 22px 16px 16px;
  background: color-mix(in srgb, var(--c, var(--jay)) 9%, rgba(10, 18, 32, 0.85));
  clip-path: var(--chamfer);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--c, var(--jay)) 55%, transparent);
  transition: background 0.15s, transform 0.15s, box-shadow 0.15s;
  animation: lvlCardIn 0.34s cubic-bezier(0.2, 0.9, 0.25, 1) both;
}
.lvl-card:nth-child(1) { animation-delay: 0.07s; }
.lvl-card:nth-child(2) { animation-delay: 0.14s; }
.lvl-card:nth-child(3) { animation-delay: 0.21s; }
.lvl-card:hover {
  transform: translateY(-3px);
  background: color-mix(in srgb, var(--c, var(--jay)) 16%, rgba(10, 18, 32, 0.85));
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c, var(--jay)) 85%, #fff);
}
.lvl-ico { width: 42px; height: 42px; }
.lvl-ico svg { width: 100%; height: 100%; filter: drop-shadow(0 0 7px currentColor); }
.lvl-ico .ico-fallback { font-size: 32px; line-height: 42px; }
.lvl-name { font-size: 13px; font-weight: 700; color: var(--text); font-family: var(--display); font-weight: 700; letter-spacing: 0.02em; }
.lvl-desc { font-size: 10.5px; color: #9db4d0; line-height: 1.4; }
.lvl-key {
  position: absolute; top: 8px; left: 10px;
  font-family: var(--body); font-size: 10px; font-weight: 700; color: #06101c;
  width: 18px; height: 18px; display: grid; place-items: center;
  background: var(--c, var(--jay)); clip-path: var(--chamfer-sm);
}
@media (prefers-reduced-motion: reduce) {
  #levelup:not(.hidden), #levelup:not(.hidden) h2, .lvl-card { animation: none; }
}

/* ---------- codex / field guide (bestiary overlay) ---------- */
/* the codex is an .overlay; .codex adds a centered panel in the .hub-panel family */
#codex.overlay.codex {
  /* base .overlay already dims + flex-centers; nothing else needed on the overlay itself */
}
.codex .codex-panel {
  position: relative;
  width: min(760px, 92%);
  max-height: 86vh;
  display: flex;
  flex-direction: column;
  padding: 24px;
  background:
    linear-gradient(180deg, rgba(111,208,251, 0.06), transparent 42%),
    rgba(6, 12, 24, 0.97);
  border: 1.5px solid var(--jay);
  border-radius: 20px;
  text-align: left;
  overflow-y: auto;
  /* stacked depth: inner top rim-light + two drops + JAY hairline + soft bloom */
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.06) inset,
    0 24px 60px -12px rgba(0, 0, 0, 0.7),
    0 8px 20px -8px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(111,208,251, 0.25),
    0 0 50px rgba(111,208,251, 0.12);
}

.codex-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(120, 160, 210, 0.2);
}
.codex-head h2 {
  font-family: var(--display); font-weight: 700;
  font-size: 16px;
  color: var(--jay);
  margin: 0;
  line-height: 1;
}
/* round close button — mirrors .hub-close (muted, DANGER on hover) */
.codex-close {
  flex-shrink: 0;
  width: 29px; height: 29px; padding: 0; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  font-family: var(--body); font-size: 14px; line-height: 1;
  color: var(--dim);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(120, 160, 210, 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: color 0.12s, background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.12s;
}
.codex-close:hover {
  color: var(--danger);
  background: color-mix(in srgb, var(--danger) 16%, transparent);
  border-color: color-mix(in srgb, var(--danger) 55%, transparent);
  box-shadow: 0 0 12px color-mix(in srgb, var(--danger) 45%, transparent), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.codex-close:active { transform: translateY(1px); box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.4); }
.codex-close:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--danger) 70%, transparent);
  outline-offset: 2px;
}

/* segmented control — BOSSES / ENEMIES, in the .shop-tab spirit */
.codex-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 4px 0 18px;
}
.codex-tab {
  font-family: var(--body);
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--dim);
  background: rgba(8, 16, 32, 0.6);
  border: 1px solid rgba(120, 160, 210, 0.22);
  border-radius: 999px;
  padding: 8px 18px;
  cursor: pointer;
  transition: color 0.12s, background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.12s;
}
.codex-tab:hover {
  color: var(--text);
  border-color: color-mix(in srgb, var(--jay) 55%, transparent);
  transform: translateY(-1px);
}
.codex-tab.active {
  color: #05131f;
  background: var(--jay);
  border-color: color-mix(in srgb, var(--jay) 60%, #000);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 0 16px color-mix(in srgb, var(--jay) 40%, transparent);
}
.codex-tab:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--jay) 75%, transparent);
  outline-offset: 2px;
}

/* responsive grid of entry cards */
.codex-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
}

/* clickable entry card — resting depth + hover lift */
.codex-card {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 14px 14px 15px;
  border-radius: 14px;
  cursor: pointer;
  background:
    linear-gradient(180deg, rgba(111,208,251, 0.08), transparent 55%),
    rgba(8, 16, 32, 0.7);
  border: 1px solid rgba(120, 160, 210, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 8px 18px -10px rgba(0, 0, 0, 0.6);
  transition: transform 0.14s ease, border-color 0.14s ease, box-shadow 0.14s ease;
}
.codex-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--jay) 55%, transparent);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 14px 26px -10px rgba(0, 0, 0, 0.7),
    0 0 22px rgba(111,208,251, 0.18);
}
.codex-card:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--jay) 70%, transparent);
  outline-offset: 2px;
}
.cx-name {
  font-family: var(--display); font-weight: 700;
  font-size: 13px;
  color: var(--text);
  line-height: 1.15;
}
.cx-title {
  font-family: var(--body);
  font-size: 9px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--dim);
}
/* locked entry — muted, no lift, reads as "not yet discovered" */
.codex-card.locked {
  opacity: 0.5;
  filter: saturate(0.35);
  cursor: default;
  background: rgba(8, 16, 32, 0.5);
  border-color: rgba(120, 160, 210, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.codex-card.locked:hover {
  transform: none;
  border-color: rgba(120, 160, 210, 0.14);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.codex-card.locked .cx-name { color: var(--dim); }

/* single-entry reading view */
.codex-detail {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.cx-detail-name {
  font-family: var(--display); font-weight: 700;
  font-size: 22px;
  color: var(--jay);
  line-height: 1.1;
}
.cx-detail-title {
  font-family: var(--body);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--gold);
  margin-bottom: 8px;
}
.cx-lore {
  max-width: 62ch;
}
.cx-lore p {
  font-size: 13px;
  line-height: 1.6;
  color: #cfe6ff;
  margin: 0 0 12px;
}
.cx-lore p:last-child { margin-bottom: 0; }
/* ghost pill back button */
.codex-back {
  align-self: flex-start;
  margin-top: 18px;
  font-family: var(--body);
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--jay);
  background: rgba(8, 16, 32, 0.7);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 18px;
  cursor: pointer;
  transition: color 0.12s, background 0.12s, border-color 0.12s, box-shadow 0.12s, transform 0.12s;
}
.codex-back:hover {
  transform: translateY(-1px);
  color: var(--text);
  box-shadow: 0 0 18px rgba(111,208,251, 0.28);
}
.codex-back:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--jay) 70%, transparent);
  outline-offset: 2px;
}

/* entrance motion — inner container fades + scales in when #codex gets .is-in */
#codex.overlay .codex-panel {
  opacity: 0;
  transform: scale(0.94) translateY(12px);
  transition:
    opacity 0.2s cubic-bezier(0.2, 0.9, 0.25, 1),
    transform 0.2s cubic-bezier(0.2, 0.9, 0.25, 1);
}
#codex.overlay.is-in .codex-panel {
  opacity: 1;
  transform: scale(1) translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  #codex.overlay .codex-panel {
    transform: none;
    transition: opacity 0.12s linear;
  }
  #codex.overlay.is-in .codex-panel { transform: none; }
}

/* floating "book" button that opens the codex */
#codexBtn {
  position: absolute;
  z-index: 12;
  top: 50px;
  left: 16px;
  width: 40px; height: 40px; padding: 0;
  display: grid; place-items: center;
  font-family: var(--body);
  font-size: 19px; line-height: 1;
  border-radius: 12px;
  color: var(--text);
  background:
    linear-gradient(180deg, rgba(111,208,251, 0.14), transparent 60%),
    rgba(8, 16, 32, 0.82);
  border: 1.5px solid var(--jay);
  cursor: pointer;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 6px 16px -8px rgba(0, 0, 0, 0.6),
    0 0 18px rgba(111,208,251, 0.22);
  transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}
#codexBtn:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--jay) 80%, #fff);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 10px 22px -8px rgba(0, 0, 0, 0.7),
    0 0 28px rgba(111,208,251, 0.4);
}
#codexBtn:active { transform: translateY(1px) scale(0.98); }
#codexBtn:focus-visible {
  outline: 2px solid color-mix(in srgb, var(--jay) 75%, transparent);
  outline-offset: 2px;
}
#codexBtn.hidden { display: none; }

/* ---------- corner audio toggles ---------- */
#audioToggles {
  position: absolute;
  z-index: 12;
  left: 14px; bottom: 48px;   /* bottom-left, above the chapter label — clear of the top-right score */
  display: flex;
  gap: 8px;
}
/* matches the canvas HUD plate(): same fill, same JAY hairline, same 7px radius */
.audio-btn {
  position: relative;
  width: 30px; height: 30px; padding: 0;
  display: grid; place-items: center;
  border-radius: 7px;
  background: rgba(5, 11, 24, 0.78);
  border: 1px solid rgba(111,208,251, 0.45);
  cursor: pointer;
  transition: transform 0.12s ease, border-color 0.12s ease, color 0.12s ease;
  color: var(--jay);
}
.audio-btn svg {
  width: 16px; height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.audio-btn:hover { transform: translateY(-1px); border-color: var(--jay); color: #9fd6ff; }
.audio-btn:active { transform: translateY(1px) scale(0.97); }
.audio-btn.off { color: #43566b; border-color: rgba(255, 255, 255, 0.1); }
.audio-btn.off::after {
  content: ""; position: absolute;
  width: 20px; height: 1.8px; border-radius: 2px;
  background: var(--danger);
  transform: rotate(-45deg);
}

/* ---------- first-flight tutorial ---------- */
#tutorial { gap: 4px; }
.tut-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 18px 0 22px;
  max-width: 460px;
}
.tut-grid > div {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--text);
  line-height: 1.4;
}
.tut-grid span { color: var(--dim); }
.tut-ico { font-size: 18px; width: 34px; text-align: center; }


/* ---------- inline UI icons (window.UI_ICONS) ----------
   One rule per context instead of a width/height on every SVG string — the icon
   markup is shared between the DOM and the canvas rasteriser, so it carries no size. */
.badge svg, .badge-buy svg { width: 11px; height: 11px; vertical-align: -1px; margin-right: 3px; }
.badge.owned svg, .badge.lock svg { margin-right: 0; }
.badge.owned svg + *, .badge.lock svg + * { margin-left: 3px; }
.branch-ico svg { width: 13px; height: 13px; }
.hub-avatar svg { width: 19px; height: 19px; }
.hub-npc-avatar { width: 20px; height: 20px; display: grid; place-items: center; }
.hub-npc-avatar svg { width: 100%; height: 100%; }
.tut-ico { display: inline-grid; place-items: center; }
.tut-ico svg { width: 19px; height: 19px; color: var(--jay-lite); }
.codex-back svg { width: 13px; height: 13px; vertical-align: -2px; margin-right: 5px; }
.hub-close svg, .codex-close svg { width: 15px; height: 15px; }
#codexBtn svg { width: 21px; height: 21px; }
#pauseCodexBtn svg { width: 14px; height: 14px; vertical-align: -2px; margin-right: 5px; }
#mpBack svg, #roostBack svg { width: 13px; height: 13px; vertical-align: -2px; margin-right: 4px; }
#roostLifetime svg { width: 14px; height: 14px; vertical-align: -2px; color: var(--gold); }
.pchip svg { width: 12px; height: 12px; vertical-align: -2px; color: var(--gold); }

.tag-chip.perk svg { width: 10px; height: 10px; vertical-align: -1px; margin-right: 4px; }
