/* =========================================================
   The_Hood2.0 — dark urban theme, glass panels
   ========================================================= */
:root {
  --bg: #0e0e10;
  --bg-deep: #070708;
  --glass: rgba(24, 24, 28, .55);
  --glass-strong: rgba(14, 14, 17, .7);
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --text: #eeece8;
  --muted: #9d9ca3;
  --orange: #ff7a18;
  --gold: #ffc53d;
  --lamp: #ffb02e;                       /* single accent color for links, focus rings, numbers */
  --grad: linear-gradient(135deg, var(--orange) 0%, var(--gold) 100%);
  --hp: #e0483e;
  --xp: #2fb5a3;
  --cash: #5fd38a;
  --stamina: #6cc24a;
  --energy: #4aa3ff;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .45), 0 2px 6px rgba(0, 0, 0, .35);
  --shadow-soft: 0 4px 14px rgba(0, 0, 0, .35);
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--bg-deep); }
body {
  margin: 0; min-height: 100vh;
  font: 18px/1.5 "Barlow", system-ui, sans-serif;
  color: var(--text);
  /* night city: warm street-light glow, cold neon, and a dark asphalt gradient */
  background:
    radial-gradient(ellipse 55% 35% at 15% 0%, rgba(255, 122, 24, .22), transparent 70%),
    radial-gradient(ellipse 45% 35% at 95% 15%, rgba(74, 110, 255, .14), transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 110%, rgba(255, 176, 46, .10), transparent 70%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .018) 0 1px, transparent 1px 120px),
    linear-gradient(180deg, #16161a 0%, #0c0c0e 55%, #060607 100%);
  background-attachment: fixed;
}
h1, h2, .brand { font-family: "Bowlby One", Impact, sans-serif; font-weight: 400; margin: 0 0 .4em; letter-spacing: .01em; }
h1 { font-size: 2rem; }
h1 small { font: 500 1rem "Barlow", sans-serif; color: var(--muted); margin-left: .5rem; }
h2 { font-size: 1.3rem; }
a { color: var(--lamp); }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--lamp); outline-offset: 2px; }
.muted { color: var(--muted); }

/* ---------- Glass surfaces ---------- */
.top, .panel {
  background: var(--glass);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .top, .panel { background: rgba(22, 22, 26, .94); }
}

/* ---------- Header ---------- */
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; align-items: center;
  padding: .9rem 1.5rem;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 6px 24px rgba(0, 0, 0, .4);
}
.brand {
  font-size: 1.7rem; text-decoration: none; margin: 0;
  color: var(--gold);                                   /* fallback if gradient text isn't supported */
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 10px rgba(255, 122, 24, .35));
}
.top nav { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.top nav a { text-decoration: none; color: var(--text); padding: .35rem .8rem; border-radius: 999px; transition: background .15s, color .15s; }
.top nav a:hover { color: var(--gold); background: rgba(255, 255, 255, .06); }

/* ---------- Panels ---------- */
.panel {
  border: 1px solid var(--line);
  border-top-color: var(--line-strong);                 /* light catching the top edge of the glass */
  border-radius: var(--radius);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255, 255, 255, .05);
  padding: 2rem; max-width: 420px; margin: 3rem auto;
}
.panel.wide { max-width: 680px; margin: 1.5rem auto; }
.game { padding: 0 1rem 2rem; }

/* ---------- Forms ---------- */
label { display: block; margin-bottom: 1rem; color: var(--muted); }
input:not([type=radio]):not([type=hidden]) {
  display: block; width: 100%; margin-top: .25rem; padding: .65rem .85rem;
  font: inherit; color: var(--text);
  background: rgba(0, 0, 0, .45); border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, .4);
  transition: border-color .15s;
}
input:not([type=radio]):not([type=hidden]):focus { border-color: rgba(255, 176, 46, .6); }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius-sm); margin: 0 0 1.25rem; padding: .75rem 1rem .25rem; background: rgba(0, 0, 0, .2); }
legend { color: var(--muted); padding: 0 .4rem; }
.choice { display: flex; gap: .75rem; align-items: flex-start; cursor: pointer; }
.choice input { margin-top: .45rem; accent-color: var(--orange); }
.choice strong { display: block; color: var(--text); }

/* ---------- Buttons ---------- */
button {
  width: 100%; padding: .75rem 1rem; font: 700 1rem "Barlow", sans-serif;
  color: #1c0f00; background: var(--grad); border: 0; border-radius: var(--radius-sm); cursor: pointer;
  box-shadow: 0 6px 18px rgba(255, 122, 24, .28), inset 0 1px 0 rgba(255, 255, 255, .35);
  transition: transform .12s, box-shadow .12s, filter .12s;
}
button:hover { filter: brightness(1.08); box-shadow: 0 8px 22px rgba(255, 122, 24, .38), inset 0 1px 0 rgba(255, 255, 255, .35); }
button:active { transform: translateY(1px); }
.alt-btn { background: rgba(255, 255, 255, .05); color: var(--text); border: 1px solid var(--line-strong); box-shadow: var(--shadow-soft); }
.alt-btn:hover { background: rgba(255, 255, 255, .1); box-shadow: var(--shadow-soft); filter: none; }
.alt { text-align: center; color: var(--muted); margin: 1.25rem 0 0; }
.error { background: rgba(224, 72, 62, .14); border: 1px solid rgba(224, 72, 62, .35); border-radius: var(--radius-sm); padding: .55rem .85rem; margin: 0 0 1rem; }
.notice { background: rgba(47, 181, 163, .12); border: 1px solid rgba(47, 181, 163, .35); border-radius: var(--radius-sm); padding: .55rem .85rem; margin: 1rem 0 0; }

/* ---------- XP bar on The Block ---------- */
.bar { position: relative; height: 1.8rem; background: rgba(0, 0, 0, .5); border: 1px solid var(--line); border-radius: 999px; margin: .6rem 0; overflow: hidden; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .5); }
.bar span { position: absolute; inset: 0 auto 0 0; border-radius: 999px; }
.bar .hp { background: var(--hp); }
.bar .xp { background: linear-gradient(90deg, #1f8a7b, var(--xp)); }
.bar em { position: relative; font-style: normal; font-size: .9rem; line-height: 1.7rem; padding-left: .8rem; text-shadow: 0 1px 2px #000; }
.wallet-line { margin: .75rem 0 0; color: var(--muted); }
.wallet-line b { font-variant-numeric: tabular-nums; }
.wallet-line .sep { margin: 0 .35rem; opacity: .6; }
.cash { color: var(--cash); }
.coin { color: var(--gold); }

.actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-top: 1.25rem; }

/* ---------- Stats ---------- */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin: 1.5rem 0 0; }
.stats div { padding: .6rem .8rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-soft); position: relative; overflow: hidden; }
.stats div::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--grad); }
.stats dt { color: var(--muted); font-size: .9rem; }
.stats dd { margin: 0; font: 400 1.8rem "Bowlby One", sans-serif; }
.stat-hint { display: block; margin-top: .1rem; color: var(--muted); font-size: .8rem; }

/* ---------- Chat ---------- */
.chat { height: 240px; overflow-y: auto; background: rgba(0, 0, 0, .4); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: .6rem .85rem; margin-bottom: .75rem; box-shadow: inset 0 2px 10px rgba(0, 0, 0, .5); }
.chat p { margin: .2rem 0; overflow-wrap: anywhere; }
.chat b { color: var(--gold); margin-right: .4rem; }
.say { display: flex; gap: .5rem; }
.say input { margin: 0; flex: 1; }
.say button { width: auto; }

/* ---------- Tables ---------- */
.scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(0, 0, 0, .25); }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .6rem .8rem; border-bottom: 1px solid var(--line); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: rgba(255, 255, 255, .04); }
th { color: var(--muted); font-weight: 500; background: rgba(255, 255, 255, .03); }

@media (max-width: 520px) {
  .row, .actions { grid-template-columns: 1fr; }
  .panel { margin: 1rem 0; padding: 1.25rem; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; } }

/* ---------- Vitals: health, stamina, energy ---------- */
.vitals { display: grid; gap: .9rem; margin: 1.25rem 0 .9rem; }
.vital-head, .vital-foot { display: flex; justify-content: space-between; align-items: baseline; }
.vital-name { font-weight: 700; }
.vital-num { color: var(--muted); font-variant-numeric: tabular-nums; }
.vital-num b { color: var(--text); font-weight: 700; }
.track { height: 1.1rem; background: rgba(0, 0, 0, .5); border: 1px solid var(--line); border-radius: 999px; overflow: hidden; margin: .25rem 0; box-shadow: inset 0 2px 6px rgba(0, 0, 0, .5); }
.fill { display: block; height: 100%; border-radius: 999px; transition: width 1s linear; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25); }
/* Gold vitals: health, stamina, energy. Same gold family, a slightly different tone for each */
.fill-hp      { --g1: #8a5a00; --g2: #e0a020; --g3: #ffd45e; }
.fill-stamina { --g1: #9a6d00; --g2: #f2b91f; --g3: #ffe08a; }
.fill-energy  { --g1: #a87b0a; --g2: #ffc53d; --g3: #fff1b8; }
.fill-hp, .fill-stamina, .fill-energy {
  position: relative; overflow: hidden;
  background: linear-gradient(90deg, var(--g1) 0%, var(--g2) 55%, var(--g3) 100%);
  box-shadow: 0 0 10px rgba(255, 197, 61, .45), 0 0 2px rgba(255, 220, 120, .8), inset 0 -2px 3px rgba(120, 70, 0, .45);
}
/* glossy top highlight */
.fill-hp::before, .fill-stamina::before, .fill-energy::before {
  content: ""; position: absolute; inset: 1px 4px auto 4px; height: 42%;
  border-radius: 999px; background: linear-gradient(180deg, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0));
}
/* light sweep across the bar */
.fill-hp::after, .fill-stamina::after, .fill-energy::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -40%; width: 40%;
  background: linear-gradient(100deg, transparent 0%, rgba(255, 255, 255, .55) 50%, transparent 100%);
  animation: goldsweep 3.2s ease-in-out infinite;
}
.fill-stamina::after { animation-delay: .5s; }
.fill-energy::after { animation-delay: 1s; }
@keyframes goldsweep { 0% { left: -40%; } 55%, 100% { left: 110%; } }
/* the numbers next to the bars pick up the gold too */
.vital-num b { color: var(--gold); text-shadow: 0 0 8px rgba(255, 197, 61, .35); }
@media (prefers-reduced-motion: reduce) { .fill-hp::after, .fill-stamina::after, .fill-energy::after { animation: none; display: none; } }
.fill-xp { background: linear-gradient(90deg, #1f8a7b, var(--xp)); }
.vital-foot { font-size: .85rem; color: var(--muted); }
.vital-foot .eta { font-variant-numeric: tabular-nums; }
.xp-row { margin: 1rem 0 0; }
.xp-row .track { height: .7rem; }
@media (prefers-reduced-motion: reduce) { .fill { transition: none; } }

/* ---------- Avatar card (profile) ---------- */
.avatar-card { display: flex; gap: 1.25rem; align-items: center; margin: 1rem 0 .5rem; padding: 1rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.avatar { position: relative; flex: none; width: 160px; height: 160px; padding: 0; border: 2px solid var(--gold); border-radius: 14px; overflow: hidden; background: var(--bg); cursor: pointer; box-shadow: 0 8px 24px rgba(0, 0, 0, .5), 0 0 0 4px rgba(255, 176, 46, .12); }
.avatar:hover { background: var(--bg); filter: none; }
.avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.avatar-hint { position: absolute; inset: auto 0 0 0; padding: .35rem; font-size: .85rem; font-weight: 500; text-align: center; color: var(--text); background: rgba(10, 10, 12, .8); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); opacity: 0; transition: opacity .15s; }
.avatar:hover .avatar-hint, .avatar:focus-visible .avatar-hint { opacity: 1; }
.avatar.busy { opacity: .55; cursor: progress; }
.avatar-side p { margin: 0 0 .75rem; }
.avatar-actions { display: flex; gap: .6rem; flex-wrap: wrap; }
.avatar-actions button { width: auto; padding: .45rem .9rem; font-size: .95rem; }
.avatar-msg { min-height: 1.5em; margin: .6rem 0 0; color: var(--xp); }
.avatar-msg.bad { color: #ff8a80; }
@media (max-width: 520px) { .avatar-card { flex-direction: column; text-align: center; } .avatar-actions { justify-content: center; } }

/* ---------- Small avatars: header, chat, leaderboard ---------- */
.pic { flex: none; object-fit: cover; border-radius: 50%; background: var(--bg-deep); vertical-align: middle; box-shadow: 0 0 0 1px var(--line-strong), 0 2px 6px rgba(0, 0, 0, .5); }
.top nav a.me { display: inline-flex; align-items: center; gap: .5rem; padding: .2rem .8rem .2rem .2rem; margin-left: .4rem; background: rgba(255, 255, 255, .05); border: 1px solid var(--line-strong); border-radius: 999px; }
.top nav a.me:hover { border-color: rgba(255, 176, 46, .6); }
.top nav a.me .pic { width: 32px; height: 32px; }
.chat p { display: flex; align-items: flex-start; gap: .5rem; }
.chat .pic { width: 24px; height: 24px; margin-top: .1rem; }
.chat b { margin-right: 0; }
.who { display: inline-flex; align-items: center; gap: .6rem; }
.who .pic { width: 32px; height: 32px; }

/* ---------- Wallet: money and gold (profile) ---------- */
.wallet { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin: .75rem 0 1rem; }
.purse { position: relative; overflow: hidden; display: flex; flex-direction: column; padding: .8rem 1.1rem; border-radius: var(--radius); border: 1px solid var(--line); background: rgba(0, 0, 0, .35); box-shadow: var(--shadow-soft), inset 0 1px 0 rgba(255, 255, 255, .05); }
.purse::after { content: ""; position: absolute; inset: auto -30% -60% auto; width: 70%; aspect-ratio: 1; border-radius: 50%; opacity: .18; filter: blur(18px); pointer-events: none; }
.purse.cash { border-color: rgba(95, 211, 138, .3); }
.purse.cash::after { background: var(--cash); }
.purse.coin { border-color: rgba(255, 197, 61, .3); }
.purse.coin::after { background: var(--gold); }
.purse-label { color: var(--muted); font-size: .9rem; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; }
.purse-amt { font: 400 2.1rem/1.1 "Bowlby One", Impact, sans-serif; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.purse.cash .purse-amt { color: var(--cash); text-shadow: 0 0 18px rgba(95, 211, 138, .25); }
.purse.coin .purse-amt { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold); }
.start-note { margin: 0 0 1.25rem; }

/* ---------- Live fight replay (The Block) ---------- */
.fight { margin: 1.25rem 0 0; padding: 1rem; background: rgba(0, 0, 0, .35); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.fighters { display: grid; grid-template-columns: 1fr auto 1fr; gap: .75rem; align-items: center; }
.fighter { display: flex; gap: .75rem; align-items: center; min-width: 0; padding: .6rem; border-radius: var(--radius-sm); background: rgba(255, 255, 255, .03); border: 1px solid var(--line); transition: opacity .4s, filter .4s; }
.fighter.foe { flex-direction: row-reverse; text-align: right; }
.fpic { flex: none; width: 64px; height: 64px; object-fit: cover; border-radius: 12px; border: 2px solid var(--gold); background: var(--bg-deep); }
.foe-pic { display: block; overflow: hidden; border-color: var(--hp); }
.foe-pic img { display: block; width: 100%; height: 100%; object-fit: cover; filter: hue-rotate(140deg) saturate(1.6); }
.fbody { flex: 1; min-width: 0; }
.fname { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fhp { font-size: .85rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.fhp b { color: var(--text); }
.fighter .fill { transition: width .25s ease-out; }
.foe .track { direction: rtl; }
.fill-foe { background: linear-gradient(270deg, #a8322a, var(--orange)); }
.vs { font: 400 1.3rem "Bowlby One", Impact, sans-serif; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold); }
.fighter.hit { animation: fhit .35s ease-out; }
@keyframes fhit {
  0% { transform: translateX(0); box-shadow: 0 0 0 0 rgba(224, 72, 62, 0); }
  20% { transform: translateX(-6px); box-shadow: 0 0 0 3px rgba(224, 72, 62, .55); }
  45% { transform: translateX(5px); }
  70% { transform: translateX(-3px); }
  100% { transform: translateX(0); box-shadow: 0 0 0 0 rgba(224, 72, 62, 0); }
}
.fighter.down { opacity: .45; filter: grayscale(.8); }
.flog { list-style: none; margin: .9rem 0 0; padding: .4rem .6rem; height: 220px; overflow-y: auto; background: rgba(0, 0, 0, .4); border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: .95rem; }
.flog:empty::before { content: "The fight is starting..."; color: var(--muted); }
.flog li { display: grid; grid-template-columns: 3.2rem 1fr auto; gap: .6rem; align-items: baseline; padding: .25rem .35rem; border-left: 3px solid transparent; border-radius: 4px; animation: fin .25s ease-out; }
.flog .ft, .flog .fl { color: var(--muted); font-size: .8rem; font-variant-numeric: tabular-nums; }
.flog .fd { font-weight: 700; font-variant-numeric: tabular-nums; }
.flog .by-you { border-left-color: var(--gold); }
.flog .by-you .fd { color: var(--gold); }
.flog .by-foe { border-left-color: var(--hp); background: rgba(224, 72, 62, .06); }
.flog .by-foe .fd { color: #ff7a70; }
.flog .by-end { display: block; margin-top: .3rem; font-weight: 700; text-align: center; padding: .45rem; }
.flog .by-end.won { color: var(--cash); background: rgba(95, 211, 138, .08); }
.flog .by-end.lost { color: #ff7a70; background: rgba(224, 72, 62, .08); }
@keyframes fin { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
/* Result message and "Skip to result" share one slot at the bottom of the fight box */
.fight-foot { display: grid; margin-top: .6rem; }
.fight-foot > * { grid-area: 1 / 1; }
.fight-foot #fSkip { justify-self: end; align-self: start; }
.fight-foot .notice { margin: 0; }
.fight-foot button { width: auto; padding: .4rem .9rem; font-size: .9rem; }
@media (max-width: 520px) {
  .fighters { grid-template-columns: 1fr; }
  .vs { text-align: center; }
  .fighter.foe { flex-direction: row; text-align: left; }
  .foe .track { direction: ltr; }
  .fpic { width: 48px; height: 48px; }
}
@media (prefers-reduced-motion: reduce) { .fighter.hit, .flog li { animation: none; } }

/* ---------- Gym ---------- */
.gym-intro { margin: 0 0 .5rem; }
.gym-intro b { color: var(--text); }
.gym { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-top: 1.25rem; }
.gym-card { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: .35rem; padding: .9rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow-soft); }
.gym-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 3px; background: var(--grad); }
.gym-top { display: flex; flex-direction: column; align-items: flex-start; gap: .25rem; }   /* name above the number, so big numbers never collide */
.gym-name { font-weight: 700; }
.gym-val { font: 400 1.8rem/1 "Bowlby One", Impact, sans-serif; white-space: nowrap; font-variant-numeric: tabular-nums; }
.gym-val small { font: 500 .9rem "Barlow", sans-serif; color: var(--muted); }
.gym-track { height: .5rem; margin: .1rem 0; }
.gym-does { color: var(--muted); font-size: .85rem; flex: 1; }
.gym-gear { color: var(--cash); font-size: .8rem; font-weight: 700; }
.gym-card button { margin-top: .35rem; }
button:disabled, button:disabled:hover { cursor: not-allowed; filter: grayscale(1) brightness(.6); box-shadow: none; transform: none; }
.gym-left { margin: .9rem 0 0; font-size: .9rem; }
@media (max-width: 520px) { .gym { grid-template-columns: 1fr; } }

/* ---------- DNC store ---------- */
.shop { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem; margin-top: 1.25rem; }
.shop-item { display: flex; flex-wrap: wrap; gap: .9rem; min-width: 0; padding: .9rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.shop-img { flex: none; width: 96px; height: 96px; border-radius: 14px; box-shadow: 0 6px 18px rgba(0, 0, 0, .5); }
.shop-info { display: flex; flex-direction: column; gap: .3rem; min-width: 0; flex: 1; }
.shop-top { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
.shop-name { overflow-wrap: anywhere; font: 400 1.15rem "Bowlby One", Impact, sans-serif; }
.shop-price { font: 400 1.2rem "Bowlby One", Impact, sans-serif; color: var(--cash); }
.shop-does { font-weight: 700; font-size: .95rem; }
.shop-does.energy { color: var(--energy); }
.shop-does.stamina { color: var(--stamina); }
.shop-desc { font-size: .85rem; flex: 1; }
.shop-item button { margin-top: .3rem; font-variant-numeric: tabular-nums; }
.shop-note { margin: .9rem 0 0; font-size: .85rem; }
@media (max-width: 620px) { .shop { grid-template-columns: 1fr; } }

/* XP bar sits above the vitals */
.bar + .vitals, .xp-row + .vitals { margin-top: 1rem; }

/* Thin line-style vitals (health, stamina, energy) */
.vitals .track { height: 6px; border: 0; background: rgba(255, 255, 255, .07); box-shadow: inset 0 1px 2px rgba(0, 0, 0, .6); margin: .35rem 0 .2rem; overflow: visible; }
.vitals .fill { border-radius: 999px; }
.vitals .fill-hp::before, .vitals .fill-stamina::before, .vitals .fill-energy::before { inset: 0 3px auto 3px; height: 45%; }
.vitals .fill-hp, .vitals .fill-stamina, .vitals .fill-energy { box-shadow: 0 0 8px rgba(255, 197, 61, .55), 0 0 2px rgba(255, 220, 120, .9); }
.vitals { gap: .75rem; }

/* ---------- Fight choices (The Block) ---------- */
.fights { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-top: 1.25rem; }
.fight-btn { display: flex; flex-direction: column; align-items: flex-start; gap: .1rem; text-align: left; padding: .75rem .9rem; }
.fb-name { font: 400 1.1rem "Bowlby One", Impact, sans-serif; }
.fb-tier { font-size: .85rem; font-weight: 700; opacity: .85; }
.fb-loot { font-size: .8rem; font-weight: 500; opacity: .8; }
.fight-btn.tier-1 { background: linear-gradient(135deg, #ff5a1f, #ff9b2e); }
.fight-btn.tier-2 { background: linear-gradient(135deg, #c2261f, #ff5a3a); color: #fff3ee; box-shadow: 0 6px 18px rgba(224, 72, 62, .3), inset 0 1px 0 rgba(255, 255, 255, .3); }
.fight-btn.tier-3 { background: linear-gradient(135deg, #7a1fa2, #c13ad8); color: #fbeeff; box-shadow: 0 6px 18px rgba(193, 58, 216, .3), inset 0 1px 0 rgba(255, 255, 255, .25); }
.fight-btn.tier-4 { background: linear-gradient(135deg, #3b0a0a, #8e1414); color: #ffe3de; border: 1px solid rgba(255, 90, 60, .45); box-shadow: 0 6px 18px rgba(142, 20, 20, .45), inset 0 1px 0 rgba(255, 255, 255, .15); }
.fight-btn.tier-5 { background: linear-gradient(135deg, #0b0b0d, #26200f); color: var(--gold); border: 1px solid rgba(255, 197, 61, .7); box-shadow: 0 0 18px rgba(255, 197, 61, .35), inset 0 1px 0 rgba(255, 255, 255, .1); }
.fight-btn.tier-5 .fb-name { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.foe-pic.tier-3 img { filter: hue-rotate(60deg) saturate(2.2); }
.foe-pic.tier-4 img { filter: hue-rotate(140deg) saturate(3) brightness(.75) contrast(1.2); }
.foe-pic.tier-5 img { filter: sepia(1) saturate(3) hue-rotate(5deg) brightness(.95); }
.foe-pic.tier-5 { border-color: var(--gold); box-shadow: 0 0 12px rgba(255, 197, 61, .5); }
.clinic { margin-top: .75rem; }
.foe-pic.tier-0 img { filter: grayscale(.6) brightness(1.1); }
.foe-pic.tier-1 img { filter: hue-rotate(170deg) saturate(1.8); }
.foe-pic.tier-2 img { filter: hue-rotate(140deg) saturate(2.4) brightness(.9); }
@media (max-width: 620px) { .fights { grid-template-columns: 1fr; } }

/* ---------- Stash (DNC) ---------- */
.owned { display: inline-block; white-space: nowrap; font: 700 .75rem "Barlow", sans-serif; color: var(--gold); background: rgba(255, 197, 61, .12); border: 1px solid rgba(255, 197, 61, .35); border-radius: 999px; padding: .05rem .45rem; vertical-align: middle; }
.stash-btn { margin-top: .4rem; font-size: .9rem; }

/* ---------- Inventory ---------- */
.inv-panel { max-width: 960px; }
.inv { display: grid; grid-template-columns: 340px 1fr; gap: 1.25rem; margin-top: 1rem; align-items: start; }
.equip-card, .bag-card { padding: 1rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.equip-card h2, .bag-card h2 { font-size: 1.05rem; margin-bottom: .75rem; }
.bag-card h2 small { font: 500 .85rem "Barlow", sans-serif; margin-left: .4rem; }
/* rarity colors */
.rar-common { --rar: #8c8f9c; }
.rar-uncommon { --rar: #5fd38a; }
.rar-rare { --rar: #4aa3ff; }
.rar-epic { --rar: #c13ad8; }
.rar-legendary { --rar: #ffc53d; }

/* body + slots */
.body { position: relative; width: 300px; height: 420px; margin: 0 auto; }
.silhouette { position: absolute; left: 50%; top: 8px; width: 205px; height: 410px; transform: translateX(-50%); filter: drop-shadow(0 0 18px rgba(109, 116, 184, .18)); }
.slot { position: absolute; width: 64px; height: 64px; display: grid; place-items: center; border-radius: 12px;
  background: rgba(10, 10, 14, .78); border: 2px dashed rgba(255, 255, 255, .16); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); transition: border-color .15s, box-shadow .15s, transform .15s; }
.slot.filled { border: 2px solid var(--rar); box-shadow: 0 0 12px color-mix(in srgb, var(--rar) 35%, transparent); cursor: grab; }
.slot img, .cell img { width: 48px; height: 48px; pointer-events: none; }
.slot-label { font-size: .68rem; font-weight: 700; color: var(--muted); text-align: center; line-height: 1.1; padding: 0 .2rem; }
.slot-head  { left: 118px; top: 0; }
.slot-chest { left: 118px; top: 100px; }
.slot-legs  { left: 118px; top: 230px; }
.slot-feet  { left: 118px; top: 350px; }
.slot-left  { left: 0;     top: 175px; }
.slot-right { right: 0;    top: 175px; }
.slot.can-drop { border-color: var(--gold); border-style: solid; box-shadow: 0 0 14px rgba(255, 197, 61, .5); }
.slot.over { transform: scale(1.08); background: rgba(255, 197, 61, .15); }
.gear-total { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; margin-top: 1rem; }
.gear-total div { display: flex; flex-direction: column; padding: .45rem .6rem; background: rgba(255, 255, 255, .03); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.gear-total .muted { font-size: .78rem; }
.gear-total b { font: 400 1.35rem "Bowlby One", Impact, sans-serif; }
.gear-total .plus { color: var(--cash); font-size: .75rem; font-weight: 700; }

/* bag grid */
.bag { display: grid; grid-template-columns: repeat(6, 1fr); gap: .5rem; padding: .5rem; border-radius: var(--radius-sm); border: 1px solid transparent; transition: border-color .15s, background .15s; }
.bag.can-drop { border-color: rgba(255, 197, 61, .5); }
.bag.over { background: rgba(255, 197, 61, .08); }
.cell { position: relative; aspect-ratio: 1; display: grid; place-items: center; border-radius: 10px; background: rgba(255, 255, 255, .03); border: 1px solid rgba(255, 255, 255, .07); box-shadow: inset 0 2px 6px rgba(0, 0, 0, .45); }
.cell.filled { border: 2px solid var(--rar); background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--rar) 18%, transparent), rgba(0, 0, 0, .3) 70%); cursor: grab; transition: transform .12s; }
.cell.filled:hover, .slot.filled:hover { transform: translateY(-2px); }
.cell.sel, .slot.sel { outline: 2px solid var(--gold); outline-offset: 2px; }
.qty { position: absolute; right: 4px; bottom: 2px; font: 700 .8rem "Barlow", sans-serif; color: #fff; text-shadow: 0 1px 2px #000, 0 0 4px #000; }

/* details panel */
.details { display: flex; gap: .9rem; margin-top: .9rem; padding: .8rem; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(255, 255, 255, .03); }
.details img { flex: none; border-radius: 10px; background: rgba(0, 0, 0, .35); padding: 4px; }
.d-body { flex: 1; min-width: 0; }
.d-name { font: 400 1.1rem "Bowlby One", Impact, sans-serif; color: var(--rar, var(--text)); }
.d-info { font-weight: 700; font-size: .9rem; color: var(--cash); }
.d-desc { font-size: .85rem; margin: .15rem 0 .5rem; }
.d-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.d-actions button { width: auto; padding: .45rem .9rem; font-size: .9rem; }
.inv-help { font-size: .82rem; margin: .8rem 0 0; }

/* tooltip */
.tip { position: fixed; z-index: 50; max-width: 240px; padding: .55rem .7rem; border-radius: 10px; pointer-events: none;
  background: rgba(12, 12, 16, .95); border: 1px solid var(--rar, var(--line)); box-shadow: 0 10px 30px rgba(0, 0, 0, .6); font-size: .85rem; }
.tip b { display: block; color: var(--rar, var(--text)); font-size: .95rem; }
.tip .t-info { display: block; color: var(--cash); font-weight: 700; }
.tip .t-desc { display: block; color: var(--muted); }

@media (max-width: 820px) {
  .inv { grid-template-columns: 1fr; }
  .bag { grid-template-columns: repeat(6, 1fr); }
}
@media (max-width: 420px) {
  .body { transform: scale(.9); transform-origin: top center; height: 380px; }
  .bag { grid-template-columns: repeat(4, 1fr); }
}

/* DNC buy row */
.buy-row { display: flex; gap: .5rem; }
.shop-actions { flex: 1 1 100%; display: flex; flex-direction: column; gap: .45rem; min-width: 0; }
.buy-row .buy-btn { flex: 1; min-width: 0; margin: 0; padding: .6rem .5rem; font-size: .95rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.shop-actions .stash-btn { margin: 0; }
.qty-box input { width: 3.2rem !important; margin: 0 !important; text-align: center; padding: .6rem .2rem !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* =========================================================
   Black & gold everywhere
   Every accent is a shade of gold on black/charcoal. Red is kept only
   where it warns you: errors, damage you take, and the enemy's health.
   ========================================================= */
:root {
  --orange: #d99a1c;                                    /* was orange: now deep gold */
  --gold: #ffc53d;
  --lamp: #ffc53d;
  --grad: linear-gradient(135deg, #b8860b 0%, #ffc53d 55%, #ffe08a 100%);
  --cash: #ffd45e;                                      /* money: bright gold (was green) */
  --xp: #c9962b;                                        /* experience: dark gold (was teal) */
  --stamina: #ffd45e;
  --energy: #ffe08a;
}
/* background: warm gold glow only (the blue glow is gone) */
body {
  background:
    radial-gradient(ellipse 55% 35% at 15% 0%, rgba(255, 176, 46, .16), transparent 70%),
    radial-gradient(ellipse 45% 35% at 95% 15%, rgba(255, 197, 61, .07), transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 110%, rgba(255, 176, 46, .08), transparent 70%),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, .018) 0 1px, transparent 1px 120px),
    linear-gradient(180deg, #141414 0%, #0b0b0b 55%, #050505 100%);
  background-attachment: fixed;
}
.brand { filter: drop-shadow(0 2px 10px rgba(255, 176, 46, .35)); }
.top nav a:hover { color: var(--gold); background: rgba(255, 197, 61, .08); }
.choice input { accent-color: var(--gold); }

/* buttons: gold */
button { color: #1a1204; box-shadow: 0 6px 18px rgba(255, 176, 46, .25), inset 0 1px 0 rgba(255, 255, 255, .4); }
button:hover { box-shadow: 0 8px 22px rgba(255, 176, 46, .35), inset 0 1px 0 rgba(255, 255, 255, .4); }
.alt-btn { color: var(--text); border-color: rgba(255, 197, 61, .3); box-shadow: var(--shadow-soft); }
.alt-btn:hover { border-color: rgba(255, 197, 61, .6); background: rgba(255, 197, 61, .08); }

/* messages */
.notice { background: rgba(255, 197, 61, .08); border-color: rgba(255, 197, 61, .35); }
.avatar-msg { color: var(--gold); }

/* experience bars: dark gold, no shimmer, so they still stand apart from the vitals */
.bar .xp, .fill-xp { background: linear-gradient(90deg, #6b4e10, #c9962b); }
.bar em { color: #fff7e0; }

/* money & gold on the profile */
.purse.cash { border-color: rgba(255, 212, 94, .3); }
.purse.cash::after { background: #ffd45e; }
.purse.cash .purse-amt { color: #ffd45e; text-shadow: 0 0 18px rgba(255, 212, 94, .25); }

/* fight buttons: one gold ladder, from bright gold (easy) to black and gold (boss) */
.fight-btn.tier-0 { background: linear-gradient(135deg, #ffd45e, #ffe9a6); color: #1a1204; }
.fight-btn.tier-1 { background: linear-gradient(135deg, #e0a020, #ffc53d); color: #1a1204; }
.fight-btn.tier-2 { background: linear-gradient(135deg, #9a6d00, #d99a1c); color: #fff4d6; box-shadow: 0 6px 18px rgba(217, 154, 28, .3), inset 0 1px 0 rgba(255, 255, 255, .25); }
.fight-btn.tier-3 { background: linear-gradient(135deg, #3d2c08, #6b4e10); color: #ffd45e; border: 1px solid rgba(255, 197, 61, .35); box-shadow: 0 6px 18px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255, 255, 255, .12); }
.fight-btn.tier-4 { background: linear-gradient(135deg, #1c1608, #33270b); color: #ffc53d; border: 1px solid rgba(255, 197, 61, .5); box-shadow: 0 6px 18px rgba(0, 0, 0, .5), 0 0 10px rgba(255, 197, 61, .15); }
.fight-btn.tier-5 { background: linear-gradient(135deg, #050505, #1a1508); color: var(--gold); border: 1px solid rgba(255, 197, 61, .8); box-shadow: 0 0 18px rgba(255, 197, 61, .35), inset 0 1px 0 rgba(255, 255, 255, .1); }
/* enemy pictures: gold/bronze tints that get richer with difficulty */
.foe-pic img, .foe-pic.tier-0 img { filter: grayscale(1) brightness(1.1); }
.foe-pic.tier-1 img { filter: sepia(.6) saturate(1.2) brightness(1.05); }
.foe-pic.tier-2 img { filter: sepia(.9) saturate(1.6); }
.foe-pic.tier-3 img { filter: sepia(1) saturate(2.2) brightness(.9); }
.foe-pic.tier-4 img { filter: sepia(1) saturate(2.8) brightness(.75) contrast(1.2); }
.foe-pic.tier-5 img { filter: sepia(1) saturate(3) hue-rotate(5deg) brightness(.95); }
.flog .by-end.won { color: var(--gold); background: rgba(255, 197, 61, .08); }

/* store, gym, inventory: gold instead of blue/green */
.shop-does.energy, .shop-does.stamina { color: var(--gold); }
.gym-gear, .gear-total .plus, .d-info, .tip .t-info { color: var(--gold); }
.gym-track .fill { background: linear-gradient(90deg, #6b4e10, #c9962b); }
.rar-common { --rar: #8c8a84; }
.rar-uncommon { --rar: #ffc53d; }
.rar-rare { --rar: #ffe08a; }
.silhouette { filter: drop-shadow(0 0 18px rgba(255, 197, 61, .12)); }
.slot.filled { box-shadow: 0 0 12px color-mix(in srgb, var(--rar) 30%, transparent); }
.fill-foe { background: linear-gradient(270deg, #7a1f1a, #e0483e); }   /* enemy health stays red */

/* ---------- Gym supplies box ---------- */
.supplies { margin-top: 1.25rem; padding: 1rem; background: rgba(0, 0, 0, .3); border: 1px solid rgba(255, 197, 61, .2); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.supplies-head { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; margin-bottom: .6rem; }
.supplies-head h2 { font-size: 1.05rem; margin: 0; }
.supplies-head .muted { font-size: .9rem; }
.supply { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: .8rem; align-items: center; padding: .6rem 0; border-top: 1px solid var(--line); }
.supply:first-of-type { border-top: 0; }
.supply img { border-radius: 10px; }
.supply-info { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.supply-info .muted { font-size: .85rem; }
.supply-have { font-size: .8rem; font-weight: 700; color: var(--gold); }
.supply-actions { display: flex; gap: .5rem; align-items: center; }
.supply-actions > button { width: auto; margin: 0; padding: .55rem .8rem; font-size: .9rem; white-space: nowrap; }
.supply .buy-row .buy-btn { min-width: 7.5rem; }
@media (max-width: 620px) {
  .supply { grid-template-columns: 44px minmax(0, 1fr); }
  .supply img { width: 44px; height: 44px; }
  .supply-actions { grid-column: 1 / -1; flex-wrap: wrap; }
  .supply-actions .buy-row { flex: 1 1 12rem; min-width: 0; }
  .supply .buy-row .buy-btn { min-width: 0; }
}

/* ---------- The Block: locations and enemies ---------- */
.loc-tabs { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .75rem; }
.loc-tab { padding: .45rem .9rem; border-radius: 999px; text-decoration: none; font-weight: 700; font-size: .92rem;
  color: var(--text); background: rgba(255, 255, 255, .04); border: 1px solid rgba(255, 197, 61, .25); transition: background .15s, border-color .15s; }
.loc-tab:hover { border-color: rgba(255, 197, 61, .6); background: rgba(255, 197, 61, .08); }
.loc-tab.on { color: #1a1204; background: var(--grad); border-color: transparent; box-shadow: 0 4px 14px rgba(255, 176, 46, .3); }
.loc-tab.locked { color: var(--muted); border-style: dashed; border-color: rgba(255, 255, 255, .12); cursor: not-allowed; }
.loc-tab.locked small { font-weight: 500; margin-left: .25rem; }
.loc-tab.locked::before { content: "🔒 "; filter: grayscale(1); font-size: .8em; }
.loc-head { display: flex; flex-direction: column; gap: .1rem; margin: .9rem 0 .6rem; }
.loc-head b { font: 400 1.2rem "Bowlby One", Impact, sans-serif; color: var(--gold); }
.loc-head .muted { font-size: .88rem; }

.enemies { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.enemy-card { display: flex; flex-direction: column; align-items: stretch; gap: .15rem; text-align: left; padding: .7rem .85rem;
  color: var(--text); background: linear-gradient(135deg, rgba(255, 197, 61, .07), rgba(0, 0, 0, .35)); border: 1px solid rgba(255, 197, 61, .22);
  box-shadow: var(--shadow-soft); min-width: 0; }
.enemy-card:hover { filter: none; border-color: rgba(255, 197, 61, .6); background: linear-gradient(135deg, rgba(255, 197, 61, .14), rgba(0, 0, 0, .35)); box-shadow: 0 6px 18px rgba(255, 176, 46, .18); }
.enemy-card.boss { border: 1px solid rgba(255, 197, 61, .8); background: linear-gradient(135deg, #1d1608, #050505); box-shadow: 0 0 16px rgba(255, 197, 61, .25); grid-column: 1 / -1; }
.ec-top { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.ec-name { font: 400 1.05rem "Bowlby One", Impact, sans-serif; overflow-wrap: anywhere; }
.enemy-card.boss .ec-name { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; font-size: 1.2rem; }
.ec-boss { flex: none; font: 700 .7rem "Barlow", sans-serif; text-transform: uppercase; letter-spacing: .08em; color: #1a1204; background: var(--grad); border-radius: 999px; padding: .1rem .5rem; }
.ec-meta { font-size: .82rem; font-weight: 700; color: var(--gold); }
.ec-loot { font-size: .8rem; color: var(--muted); }
.ec-danger { margin-top: .25rem; font-size: .82rem; font-weight: 700; }
.ec-danger small { font-weight: 500; opacity: .8; margin-left: .25rem; }
.d-easy { color: #b9b29a; }
.d-fair { color: var(--gold); }
.d-risky { color: #ff9b3d; }
.d-deadly { color: #ff6b5e; }
.foe-pic.boss { border-color: var(--gold); box-shadow: 0 0 12px rgba(255, 197, 61, .55); }
@media (max-width: 620px) { .enemies { grid-template-columns: 1fr; } }

.ec-gold { font-size: .8rem; font-weight: 700; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold); }

/* ---------- Profile: avatar + gym (property) box ---------- */
.avatar-card { position: relative; justify-content: space-between; }
.prop-box { flex: none; width: 160px; height: 160px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .3rem; text-align: center;
  border-radius: 14px; border: 2px dashed rgba(255, 197, 61, .45); background: radial-gradient(circle at 50% 40%, rgba(255, 197, 61, .10), rgba(0, 0, 0, .35) 70%);
  box-shadow: inset 0 0 18px rgba(0, 0, 0, .5); color: rgba(255, 197, 61, .55); }
.prop-icon { width: 54px; height: 54px; filter: drop-shadow(0 0 8px rgba(255, 197, 61, .35)); }
.prop-label { font: 400 1rem "Bowlby One", Impact, sans-serif; color: var(--gold); }
.prop-soon { font-size: .75rem; color: var(--muted); padding: 0 .5rem; }
.avatar-toast { position: absolute; left: 50%; bottom: .6rem; transform: translateX(-50%); margin: 0; min-height: 0; font-size: .85rem; text-align: center; pointer-events: none; }
@media (max-width: 520px) {
  .avatar-card { flex-direction: row; text-align: left; }
  .avatar-card .avatar, .prop-box { width: 128px; height: 128px; }
  .prop-icon { width: 42px; height: 42px; }
}

/* ---------- Inventory: profile picture card ---------- */
.inv-right { display: grid; gap: 1.25rem; min-width: 0; }
.pic-card { padding: 1rem; background: rgba(0, 0, 0, .3); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-soft); }
.pic-card h2 { font-size: 1.05rem; margin-bottom: .75rem; }
.pic-row { display: flex; gap: 1rem; align-items: center; }
.pic-preview { width: 120px; height: 120px; }
.pic-side { min-width: 0; }
.pic-side p { margin: 0 0 .6rem; font-size: .95rem; }
@media (max-width: 520px) { .pic-row { flex-direction: column; text-align: center; } .pic-row .avatar-actions { justify-content: center; } }

/* critical hits in the fight log (3rd hit in a row) */
.flog li.crit { background: linear-gradient(90deg, rgba(255, 197, 61, .16), transparent 70%); }
.flog li.crit .fd { font-size: 1.1em; text-shadow: 0 0 10px rgba(255, 197, 61, .6); }
.flog li.by-foe.crit { background: linear-gradient(90deg, rgba(224, 72, 62, .2), transparent 70%); }
.crit-tag { display: inline-block; margin-right: .4rem; padding: 0 .35rem; border-radius: 4px; font-size: .7rem; letter-spacing: .06em; color: #1a1204; background: var(--grad); vertical-align: middle; }
.by-foe .crit-tag { color: #fff; background: linear-gradient(135deg, #7a1f1a, #e0483e); }

.gym-now { margin: .4rem 0 0; font-size: .95rem; }
.gym-now b { color: var(--gold); }

.xp-cut s { opacity: .55; margin-left: .15rem; }

/* enemy cool-off */
.enemy-card.cooling, .enemy-card.cooling:hover { cursor: not-allowed; filter: grayscale(.7) brightness(.7); transform: none; box-shadow: var(--shadow-soft); }
.ec-wait { font-size: .82rem; font-weight: 700; color: var(--muted); }
.ec-wait b { color: var(--gold); font-variant-numeric: tabular-nums; }

/* ---------- The Block: two rows of five enemies, boss underneath ---------- */
.panel.wide.block-panel { max-width: 1080px; }
.enemies { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .5rem; }
.enemy-card { padding: .55rem .6rem; gap: .1rem; }
.enemy-card .ec-name { font-size: .92rem; line-height: 1.15; }
.enemy-card .ec-meta, .enemy-card .ec-loot, .enemy-card .ec-wait, .enemy-card .ec-danger { font-size: .74rem; line-height: 1.3; }
.enemy-card .ec-danger { margin-top: auto; padding-top: .2rem; }
.enemy-card .ec-danger small { margin-left: .15rem; }
.enemy-card .xp-cut s { margin-left: .1rem; }
/* the boss keeps a roomy card across the full width */
.enemy-card.boss { grid-column: 1 / -1; padding: .75rem .9rem; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr); column-gap: 1rem; align-items: center; }
.enemy-card.boss .ec-top { grid-column: 1; grid-row: 1 / span 3; flex-direction: column; align-items: flex-start; gap: .3rem; }
.enemy-card.boss .ec-name { font-size: 1.25rem; }
.enemy-card.boss .ec-meta, .enemy-card.boss .ec-loot, .enemy-card.boss .ec-gold, .enemy-card.boss .ec-wait { grid-column: 2; font-size: .82rem; }
.enemy-card.boss .ec-danger { grid-column: 3; grid-row: 1 / span 3; margin: 0; padding: 0; font-size: .95rem; text-align: right; }
.enemy-card.boss .ec-danger small { display: block; margin: .15rem 0 0; }
@media (max-width: 900px) { .enemies { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 620px) {
  .enemies { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .enemy-card.boss { display: flex; }
  .enemy-card.boss .ec-top { flex-direction: row; justify-content: space-between; width: 100%; }
  .enemy-card.boss .ec-danger { text-align: left; }
}
.nowrap { white-space: nowrap; }
.notice.waiting { visibility: hidden; }   /* fight result: space reserved while the fight replays */

/* The Block: fight box and message slot are always on the page so nothing jumps */
.fight.idle .fighter.foe { opacity: .5; }
.fight.idle .flog:empty::before { content: "No fight yet. Click an enemy below and the hits will show up here."; }
.notice.empty { visibility: hidden; }
/* Reserve room for a long result message (fight + drop + gold + level up) so short and long ones take the same space */
.block-panel #flash { min-height: calc(3 * 1.5em + 1.1rem + 2px); }
@media (max-width: 900px) { .block-panel #flash { min-height: calc(4 * 1.5em + 1.1rem + 2px); } }
@media (max-width: 620px) { .block-panel #flash { min-height: calc(7 * 1.5em + 1.1rem + 2px); } }
/* "Back in m:ss" sits on top of a cooling card instead of adding a line, so the cards below don't move */
.enemy-card { position: relative; }
.enemy-card .ec-wait, .enemy-card.boss .ec-wait { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 1;
  white-space: nowrap; padding: .3rem .7rem; font-size: .85rem; line-height: 1.3; color: #f3e6c4;
  background: rgba(0, 0, 0, .85); border: 1px solid rgba(255, 197, 61, .45); border-radius: 999px; box-shadow: 0 2px 10px rgba(0, 0, 0, .6); }

/* =========================================================
   STREETS THEME: slums at night. Brick, concrete, sodium lamps,
   hazard tape and stencil lettering. Still black and gold.
   ========================================================= */
:root {
  --radius: 8px;
  --radius-sm: 5px;
  --text: #e9e4d8;
  --muted: #9a9285;
  --line: rgba(201, 150, 43, .14);
  --line-strong: rgba(201, 150, 43, .26);
  --gold: #f0b429;
  --lamp: #f0b429;
  --grad: linear-gradient(180deg, #ffd46b 0%, #e0a020 48%, #a66f0e 100%);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .7 -.12'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  --brick: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='60'%3E%3Cg fill='%23ffffff' fill-opacity='.018'%3E%3Crect x='2' y='2' width='56' height='26'/%3E%3Crect x='62' y='2' width='56' height='26'/%3E%3Crect x='-28' y='32' width='56' height='26'/%3E%3Crect x='32' y='32' width='56' height='26'/%3E%3Crect x='92' y='32' width='56' height='26'/%3E%3C/g%3E%3C/svg%3E");
  --hazard: repeating-linear-gradient(-45deg, #d9a224 0 11px, #0b0a08 11px 22px);
  --stencil: "Black Ops One", "Bowlby One", Impact, sans-serif;
}

/* the wall behind everything: wet brick under a sodium lamp, dirty air, dark corners */
body {
  background:
    radial-gradient(ellipse 120% 90% at 50% 40%, transparent 55%, rgba(0, 0, 0, .75) 100%),
    radial-gradient(ellipse 50% 38% at 12% 0%, rgba(255, 150, 30, .24), transparent 70%),
    radial-gradient(ellipse 38% 30% at 92% 8%, rgba(170, 30, 20, .12), transparent 70%),
    radial-gradient(ellipse 70% 40% at 50% 115%, rgba(240, 180, 41, .08), transparent 70%),
    var(--grain),
    var(--brick),
    linear-gradient(180deg, #17140f 0%, #0c0a08 55%, #050404 100%);
  background-attachment: fixed;
}

/* stencil lettering for headings and the logo */
h1, h2, .brand { font-family: var(--stencil); text-transform: uppercase; letter-spacing: .04em; }
h1 { color: #efe3c4; text-shadow: 0 2px 0 #000, 0 0 18px rgba(240, 180, 41, .12); }
h2 { color: #e0c07a; }
h1 small { font-family: "Barlow", sans-serif; text-transform: none; letter-spacing: 0; }
.brand { font-size: 1.6rem; letter-spacing: .02em; filter: drop-shadow(0 2px 0 #000) drop-shadow(0 0 12px rgba(240, 160, 30, .35)); }
.gear-total b, .stats dd { font-family: var(--stencil); }

/* header: dark steel, hazard tape along the bottom */
.top { background: linear-gradient(180deg, rgba(18, 16, 12, .92), rgba(8, 7, 6, .94)); border-bottom: 0; }
.top::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 4px; background: var(--hazard); opacity: .85; }
.top nav a { border-radius: 4px; text-transform: uppercase; letter-spacing: .06em; font-size: .92rem; font-weight: 700; }
.top nav a:hover { color: var(--gold); background: rgba(240, 180, 41, .08); }
.top nav a.me { border-radius: 4px; text-transform: none; letter-spacing: 0; font-size: 1rem; }

/* panels: grimy concrete slabs instead of glass */
.panel {
  position: relative;
  background: var(--grain), linear-gradient(180deg, rgba(24, 21, 16, .9) 0%, rgba(11, 10, 8, .93) 100%);
  border: 1px solid rgba(201, 150, 43, .18); border-top-color: rgba(201, 150, 43, .32);
  box-shadow: 0 14px 34px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 220, 140, .05), inset 0 0 40px rgba(0, 0, 0, .45);
}
.panel::before { content: ""; position: absolute; left: 18px; right: 18px; top: -1px; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(240, 180, 41, .7) 20%, rgba(240, 180, 41, .7) 80%, transparent); }

/* buttons: brass plates with stamped letters */
button:not(.enemy-card):not(.alt-btn):not(.avatar) {
  font-family: var(--stencil); font-weight: 400; text-transform: uppercase; letter-spacing: .07em;
  color: #140d02; background: var(--grad); border: 1px solid #6b4a0c; border-radius: 4px;
  box-shadow: 0 4px 0 #3d2905, 0 8px 18px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 240, 190, .55);
  text-shadow: 0 1px 0 rgba(255, 230, 160, .35);
}
button:not(.enemy-card):not(.alt-btn):not(.avatar):hover { filter: brightness(1.1); box-shadow: 0 4px 0 #3d2905, 0 10px 22px rgba(240, 160, 30, .25), inset 0 1px 0 rgba(255, 240, 190, .55); }
button:not(.enemy-card):not(.alt-btn):not(.avatar):active { transform: translateY(3px); box-shadow: 0 1px 0 #3d2905, inset 0 1px 0 rgba(255, 240, 190, .4); }
button:disabled:not(.enemy-card) { filter: grayscale(.8) brightness(.6); cursor: not-allowed; }
.alt-btn { background: linear-gradient(180deg, #24201a, #12100c); color: #e0c07a; border: 1px solid rgba(201, 150, 43, .35); border-radius: 4px;
  text-transform: uppercase; letter-spacing: .06em; font-size: .92rem; }
.alt-btn:hover { background: linear-gradient(180deg, #2e2920, #17140f); color: var(--gold); }

/* inputs: cut into the concrete */
input:not([type=radio]):not([type=hidden]), select, textarea { border-radius: 4px; background: rgba(0, 0, 0, .55); border-color: rgba(201, 150, 43, .2); }

/* messages: a scrap of paper taped up, not a soft teal box */
.notice { background: linear-gradient(180deg, rgba(240, 180, 41, .1), rgba(240, 180, 41, .04)); border: 1px solid rgba(240, 180, 41, .3); border-left: 4px solid var(--gold); border-radius: 3px; }
.error { border-radius: 3px; border-left: 4px solid #e0483e; }

/* cards and boxes all get the hard-edged look */
.stats div::before { background: var(--hazard); height: 4px; opacity: .8; }
.scroll, .chat, .flog, .fight, .supplies, .details, .gear-total div, .cell, .slot { border-radius: var(--radius-sm); }
th { font-family: var(--stencil); font-weight: 400; text-transform: uppercase; letter-spacing: .06em; font-size: .85rem; color: #c9a45a; }
.chat { background: var(--grain), rgba(0, 0, 0, .55); }
.loc-tab { text-transform: uppercase; letter-spacing: .05em; }

/* enemy cards: wanted-poster feel */
.enemy-card { border-radius: 5px; background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .07), rgba(0, 0, 0, .5)); }
.enemy-card .ec-name { font-family: var(--stencil); text-transform: uppercase; letter-spacing: .03em; font-size: .86rem; }
.enemy-card.boss { border-color: rgba(224, 72, 62, .55); background: var(--grain), linear-gradient(160deg, rgba(160, 30, 20, .18), rgba(0, 0, 0, .55)); }
.enemy-card.boss .ec-name { font-size: 1.3rem; color: #f2d58a; }
.ec-boss { border-radius: 3px; background: #a3261c; color: #fff1d0; letter-spacing: .12em; }

/* inventory: the thug stands in the dark; empty slots are just chalk outlines over him */
.silhouette { filter: drop-shadow(0 0 22px rgba(0, 0, 0, .9)); }
.slot:not(.filled) { background: rgba(0, 0, 0, .18); border: 2px dashed rgba(240, 180, 41, .28); -webkit-backdrop-filter: none; backdrop-filter: none; }
.slot:not(.filled) .slot-label { color: rgba(233, 228, 216, .7); text-shadow: 0 1px 2px #000, 0 0 6px #000; text-transform: uppercase; letter-spacing: .05em; }
.slot.filled { background: rgba(8, 7, 6, .82); }
.cell img, .slot img { border-radius: 4px; }
.equip-card, .bag-card { background-image: var(--grain); }

/* ---------- City Stores ---------- */
.store-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .6rem; margin: 1rem 0 1.25rem; }
.store-tab { display: flex; flex-direction: column; gap: .1rem; padding: .7rem .9rem; text-decoration: none; color: var(--text);
  background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .06), rgba(0, 0, 0, .5)); border: 1px solid rgba(201, 150, 43, .25); border-radius: 5px;
  border-left: 4px solid rgba(201, 150, 43, .35); transition: border-color .15s, background .15s; }
.store-tab b { font: 400 1.1rem var(--stencil); text-transform: uppercase; letter-spacing: .05em; }
.store-tab small { color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; }
.store-tab:hover { border-color: rgba(240, 180, 41, .6); }
.store-tab.on { border-color: var(--gold); border-left-color: var(--gold); background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .2), rgba(0, 0, 0, .45)); box-shadow: 0 0 18px rgba(240, 180, 41, .15); }
.store-tab.on b { color: var(--gold); }
.store-guns.on { border-left-color: #e0483e; }
.store-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .8rem; }
.store-head h2 { margin: 0; }
.shop-name, .shop-price { font-family: var(--stencil); }
.shop-price { color: var(--gold); }
.shop.guns .shop-img { width: 150px; height: 150px; }
.shop.guns .shop-does { color: var(--gold); }
.equip-link { display: block; text-align: center; text-decoration: none; padding: .6rem 1rem; }
@media (max-width: 620px) { .store-tabs { gap: .35rem; } .store-tab { padding: .5rem .45rem; border-left-width: 3px; } .store-tab b { font-size: .82rem; letter-spacing: .02em; } .store-tab small { font-size: .68rem; } }
.shop.guns { grid-template-columns: 1fr; }
.shop.guns .shop-item { flex-wrap: nowrap; align-items: center; }
.shop.guns .shop-img { width: 190px; height: 190px; }
.shop.guns .shop-actions { flex: 0 0 210px; }
@media (max-width: 620px) {
  .shop.guns .shop-item { flex-wrap: wrap; }
  .shop.guns .shop-img { width: 120px; height: 120px; }
  .shop.guns .shop-actions { flex: 1 1 100%; }
}
.owned-line.none { visibility: hidden; }
.store-msg { min-height: calc(2 * 1.5em + 1.1rem + 2px); }
@media (max-width: 620px) { .store-msg { min-height: calc(4 * 1.5em + 1.1rem + 2px); } }

/* ---------- Perks: diamond column next to the profile picture ---------- */
.perk-col { list-style: none; margin: 0 auto 0 -.5rem; padding: 0; height: 160px; display: flex; flex-direction: column; justify-content: space-between; flex: none; width: 92px; }
.perk-slot { display: flex; align-items: center; gap: .4rem; height: 29px; }
.perk-slot img, .perk-empty { flex: none; width: 29px; height: 29px; border-radius: 5px; }
.perk-slot img { box-shadow: 0 0 10px rgba(240, 180, 41, .35); outline: 1px solid rgba(240, 180, 41, .55); }
.perk-empty { border: 1px dashed rgba(240, 180, 41, .3); background: rgba(0, 0, 0, .35); position: relative; }
.perk-empty::after { content: ""; position: absolute; inset: 9px; border: 1px solid rgba(240, 180, 41, .25); transform: rotate(45deg); }
.perk-time { font: 700 .78rem "Barlow", sans-serif; color: var(--gold); font-variant-numeric: tabular-nums; }
.perk-count { margin: .4rem 0 0; }
.shop.jewels .shop-img { border-radius: 8px; }
@media (max-width: 520px) {
  .perk-col { height: 128px; width: 74px; margin-left: -.6rem; }
  .perk-slot { height: 22px; gap: .3rem; }
  .perk-slot img, .perk-empty { width: 22px; height: 22px; }
  .perk-empty::after { inset: 6px; }
  .perk-time { font-size: .7rem; }
}
.store-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 620px) { .store-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) {
  .avatar-card { flex-wrap: wrap; justify-content: flex-start; gap: .9rem; }
  .avatar-card .prop-box { width: 100%; height: auto; flex-direction: row; gap: .7rem; padding: .6rem .8rem; }
  .avatar-card .prop-box .prop-icon { width: 32px; height: 32px; }
}
/* perk timers only show when you hover (or tab to) a diamond */
.perk-col { width: auto; margin-right: auto; }
.perk-slot { position: relative; }
.perk-slot.on { cursor: help; outline: none; }
.perk-tip { position: absolute; left: calc(100% + 10px); top: 50%; transform: translateY(-50%); z-index: 20; display: none;
  white-space: nowrap; padding: .4rem .6rem; border-radius: 4px; background: rgba(8, 7, 6, .96); border: 1px solid rgba(240, 180, 41, .5);
  box-shadow: 0 8px 22px rgba(0, 0, 0, .65); font-size: .8rem; line-height: 1.35; color: var(--text); pointer-events: none; }
.perk-tip::before { content: ""; position: absolute; left: -6px; top: 50%; width: 10px; height: 10px; transform: translateY(-50%) rotate(45deg);
  background: inherit; border-left: 1px solid rgba(240, 180, 41, .5); border-bottom: 1px solid rgba(240, 180, 41, .5); }
.perk-tip b { display: block; color: var(--gold); font-weight: 700; }
.perk-tip small { display: block; color: var(--muted); font-size: .72rem; }
.perk-tip .perk-time { font-size: .8rem; margin-right: .2rem; }
.perk-slot.on:hover .perk-tip, .perk-slot.on:focus-visible .perk-tip { display: block; }
.perk-slot.on:focus-visible img { outline: 2px solid var(--gold); outline-offset: 2px; }
@media (max-width: 520px) { .perk-col { width: auto; } }

/* ---------- Properties ---------- */
.store-tabs { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.store-tab b { font-size: .98rem; }
@media (max-width: 760px) { .store-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.props { display: grid; gap: 1rem; margin-top: 1rem; }
.prop-card { display: flex; gap: 1.1rem; align-items: stretch; padding: .9rem; border: 1px solid rgba(201, 150, 43, .25); border-radius: 6px;
  background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .05), rgba(0, 0, 0, .5)); box-shadow: var(--shadow-soft); }
.prop-card.home { border-color: var(--gold); box-shadow: 0 0 22px rgba(240, 180, 41, .18); }
.prop-card.past { opacity: .6; }
.prop-img { flex: none; width: 210px; height: 210px; border-radius: 10px; box-shadow: 0 8px 22px rgba(0, 0, 0, .6); }
.prop-info { display: flex; flex-direction: column; gap: .35rem; min-width: 0; flex: 1; }
.prop-lvl { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.prop-info .shop-does { color: var(--gold); }
.prop-info button { margin-top: auto; }
.prop-tag { margin-top: auto; align-self: flex-start; padding: .35rem .8rem; border-radius: 3px; font: 400 .9rem var(--stencil); text-transform: uppercase; letter-spacing: .06em;
  color: #140d02; background: var(--grad); }
.prop-tag.dim { background: rgba(255, 255, 255, .08); color: var(--muted); }
.prop-card.soon { justify-content: center; border-style: dashed; background: rgba(0, 0, 0, .25); }
.prop-soon-box { color: var(--muted); font-size: .9rem; padding: .6rem; text-align: center; }
@media (max-width: 620px) {
  .prop-card { flex-direction: column; }
  .prop-img { width: 100%; height: auto; aspect-ratio: 1; }
}

/* the home box on the profile */
a.prop-box { text-decoration: none; color: inherit; }
.prop-box.has-home { position: relative; padding: 0; overflow: hidden; border-style: solid; border-color: rgba(240, 180, 41, .55); }
.prop-pic { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.prop-caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 1.4rem .5rem .45rem; display: flex; flex-direction: column; line-height: 1.2;
  background: linear-gradient(transparent, rgba(0, 0, 0, .9) 45%); }
.prop-caption b { font: 400 .78rem var(--stencil); text-transform: uppercase; letter-spacing: .04em; color: var(--gold); }
.prop-caption small { font-size: .7rem; color: var(--text); }
.home-add { color: var(--gold); font-weight: 700; }
.gym-home { margin: .2rem 0 0; font-size: .92rem; }
@media (max-width: 520px) {
  .avatar-card .prop-box.has-home { height: 140px; padding: 0; }
}
.store-tab { padding: .6rem .6rem .6rem .7rem; min-width: 0; }
.store-tab b { font-size: .84rem; letter-spacing: .02em; overflow-wrap: anywhere; }
.store-tab small { font-size: .7rem; letter-spacing: .06em; }
.store-tab b { overflow-wrap: normal; }
@media (max-width: 760px) { .store-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 520px) { .store-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .store-tab b { font-size: .8rem; } }

/* ---------- Travel ---------- */
.travel-here { font-size: 1.1rem; margin: 0; }
.travel-here b { color: var(--gold); }
.travel-intro { margin: .3rem 0 0; }
.cities { list-style: none; margin: 1rem 0 0; padding: 0; display: grid; gap: .5rem; }
.city form { display: grid; grid-template-columns: 2.6rem minmax(0, 1.3fr) minmax(0, 1fr) auto; gap: .9rem; align-items: center; padding: .65rem .85rem;
  border: 1px solid rgba(201, 150, 43, .2); border-radius: 5px; background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .04), rgba(0, 0, 0, .5)); }
.city.here form { border-color: var(--gold); box-shadow: 0 0 18px rgba(240, 180, 41, .15); background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .14), rgba(0, 0, 0, .45)); }
.city-rank { font: 400 1.15rem var(--stencil); color: #a3261c; text-align: center; }
.city-main { display: flex; flex-direction: column; min-width: 0; }
.city-name { font: 400 1.02rem var(--stencil); text-transform: uppercase; letter-spacing: .03em; }
.city.here .city-name { color: var(--gold); }
.city-nick { font-size: .8rem; color: var(--muted); }
.city-crime { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.city-crime small { font-size: .75rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.crime-bar { display: block; height: 6px; border-radius: 3px; background: rgba(0, 0, 0, .5); overflow: hidden; }
.crime-bar span { display: block; height: 100%; background: linear-gradient(90deg, #7a1f1a, #e0483e); }
.city-go { display: flex; align-items: center; gap: .6rem; justify-content: flex-end; }
.city-go small { white-space: nowrap; font-variant-numeric: tabular-nums; }
.city-go button { width: auto; padding: .5rem .9rem; font-size: .85rem; white-space: nowrap; }
.city-tag { padding: .4rem .8rem; border-radius: 3px; font: 400 .85rem var(--stencil); text-transform: uppercase; letter-spacing: .05em; color: #140d02; background: var(--grad); white-space: nowrap; }
@media (max-width: 620px) {
  .city form { grid-template-columns: 2rem minmax(0, 1fr) auto; gap: .5rem .7rem; }
  .city-crime { grid-column: 2 / 4; grid-row: 2; }
  .city-go button { padding: .45rem .7rem; }
  .city-go small { display: none; }
}

/* profile: where you are, right above the XP bar */
.location { display: flex; align-items: center; gap: .4rem; margin: 1rem 0 .2rem; font-size: 1rem; }
.location svg { width: 18px; height: 18px; color: #e0483e; flex: none; }
.location .loc-label { color: var(--muted); }
.location a { color: var(--gold); font-weight: 700; text-decoration: none; }
.location a:hover { text-decoration: underline; }
.city form { grid-template-columns: 2.6rem minmax(0, 1.3fr) minmax(0, 1fr) 14.5rem; }
@media (max-width: 620px) {
  .city form { grid-template-columns: 2rem minmax(0, 1fr) auto; }
  .travel-panel .store-msg { min-height: calc(3 * 1.5em + 1.1rem + 2px); }
}

/* travel: level gates and the bus ride */
.bus { margin: .2rem 0 0; padding: .8rem .9rem; border: 1px solid var(--gold); border-radius: 5px; background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .14), rgba(0, 0, 0, .45)); }
.bus-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .3rem 1rem; }
.bus-top b { color: var(--gold); }
.bus-eta b { font-variant-numeric: tabular-nums; }
.bus-track { height: 8px; margin: .55rem 0 .4rem; border-radius: 4px; background: rgba(0, 0, 0, .55); overflow: hidden; }
.bus-track span { display: block; height: 100%; background: var(--grad); transition: width 1s linear; }
.city-tag.dim { background: rgba(240, 180, 41, .15); color: var(--gold); border: 1px solid rgba(240, 180, 41, .5); }
.next-city { margin: .8rem 0 0; padding: .6rem .8rem; border: 1px dashed rgba(240, 180, 41, .35); border-radius: 5px; color: var(--muted); text-align: center; }
.next-city b { color: var(--gold); }
.loc-eta { font-size: .85rem; }

/* six City Stores: two rows of three */
.store-tabs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 520px) { .store-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.store-dispensary.on { border-left-color: #5fd38a; }

/* travel: sleep on the bus with Za */
.sleep { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin-top: .7rem; padding-top: .7rem; border-top: 1px solid rgba(240, 180, 41, .25); }
.sleep-info { flex: 1 1 260px; display: flex; flex-direction: column; gap: .1rem; font-size: .9rem; }
.sleep-info > b { font: 400 1rem var(--stencil); text-transform: uppercase; letter-spacing: .04em; color: var(--gold); }
.za-have { color: var(--gold); }
.sleep .qty-box input { width: 4.2rem; margin: 0; }
.sleep-btn { width: auto; }
.sleep-buy { width: auto; padding: .55rem .9rem; text-decoration: none; }

/* ---------- Online ---------- */
.online-count { display: inline-block; min-width: 1.3rem; padding: 0 .35rem; margin-left: .2rem; border-radius: 999px; font-size: .75rem; line-height: 1.3rem; text-align: center;
  color: #0b1a0e; background: #5fd38a; letter-spacing: 0; }
.online .status { display: inline-flex; align-items: center; gap: .45rem; white-space: nowrap; }
.online .dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.st-on .dot { background: #5fd38a; box-shadow: 0 0 8px #5fd38a; }
.st-on .status { color: #8ee8ad; font-weight: 700; }
.st-idle .dot { background: var(--gold); }
.st-idle .status { color: var(--gold); }
.st-off .dot { background: #6b665c; }
.st-off { opacity: .7; }
.st-off .status { color: var(--muted); }
.online .acts { white-space: nowrap; text-align: right; }
.act-btn { display: inline-block; width: auto; padding: .35rem .7rem; font-size: .8rem; margin-left: .35rem; text-decoration: none; }
.attack-btn { background: linear-gradient(180deg, #c0392b, #7a1a12) !important; color: #fff1d0 !important; border-color: #4a0d08 !important; box-shadow: 0 3px 0 #3a0805 !important; text-shadow: none !important; }
.attack-btn:disabled { filter: grayscale(.6) brightness(.7); }
/* someone else's profile */
.view-card { align-items: stretch; }
.view-avatar { flex: none; width: 160px; height: 160px; padding: 0; overflow: hidden; border-radius: var(--radius); border: 2px solid var(--gold); }
.view-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.view-facts { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .5rem; }
.view-facts .status, .view-facts .location { margin: 0; display: flex; align-items: center; gap: .45rem; }
.view-facts .dot { width: 9px; height: 9px; border-radius: 50%; }
.view-facts .st-on .dot, .view-facts .status.st-on .dot { background: #5fd38a; box-shadow: 0 0 8px #5fd38a; }
.status.st-on { color: #8ee8ad; font-weight: 700; }
.status.st-idle { color: var(--gold); } .status.st-idle .dot { background: var(--gold); }
.status.st-off { color: var(--muted); } .status.st-off .dot { background: #6b665c; }
.view-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; margin: .2rem 0 0; }
.view-stats div { padding: .4rem .6rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, .3); }
.view-stats dt { font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.view-stats dd { margin: 0; font: 400 1.2rem var(--stencil); }
.view-stats dd.small { font: 700 .85rem "Barlow", sans-serif; }
.view-acts { display: flex; gap: .5rem; flex-wrap: wrap; }
.view-acts > * { width: auto; }
.view-acts .alt-btn { padding: .6rem 1rem; text-decoration: none; }
.attack-soon { margin: 0; font-size: .82rem; }
@media (max-width: 620px) { .view-card { flex-wrap: wrap; } .view-card .prop-box { display: none; } }
.scroll { position: relative; }
.view-facts .location { flex-wrap: wrap; }
.panel.wide.online-panel { max-width: 960px; }
.panel.wide.player-panel { max-width: 900px; }
.online td { vertical-align: middle; }
.online td:nth-child(3) { white-space: nowrap; }
@media (max-width: 760px) { .online td:nth-child(3) { white-space: normal; } }
.inline-form { display: inline; margin: 0; }
.clinic-me { margin: .4rem 0 .6rem; padding: .7rem .9rem; border: 1px solid rgba(224, 72, 62, .6); border-left: 4px solid #e0483e; border-radius: 4px; background: rgba(160, 30, 20, .14); }
.clinic-me b { color: #ff8a7a; font-variant-numeric: tabular-nums; }
.clinic-list .out-in { color: #ff8a7a; font-variant-numeric: tabular-nums; }
.clinic-list tr.is-me td { background: rgba(224, 72, 62, .08); }
.clinic-list a.who { color: inherit; text-decoration: none; }
.after-attack { margin-top: 1rem; }
/* menu fits on one line with all its links */
.top { gap: .5rem 1rem; }
.top nav { gap: .1rem; }
.top nav a { padding: .35rem .55rem; font-size: .85rem; letter-spacing: .04em; }
.top nav a.me { margin-left: .3rem; }

/* ---------- Bank ---------- */
.panel.wide.bank-panel { max-width: 860px; }
.bank-intro { margin: 0; }
.gold-txt { color: var(--gold); }
.vaults { display: grid; gap: 1rem; margin-top: .6rem; }
.vault { padding: 1rem; border: 1px solid rgba(201, 150, 43, .28); border-radius: 6px; background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .05), rgba(0, 0, 0, .5)); box-shadow: var(--shadow-soft); }
.vault h2 { margin: 0 0 .6rem; }
.vault-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; }
.vault-box { display: flex; flex-direction: column; gap: .1rem; padding: .7rem .9rem; border-radius: 5px; border: 1px solid var(--line); background: rgba(0, 0, 0, .35); }
.vault-box.safe { border-color: rgba(240, 180, 41, .55); background: linear-gradient(160deg, rgba(240, 180, 41, .12), rgba(0, 0, 0, .4)); }
.vault-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.vault-amt { font: 400 1.7rem var(--stencil); color: var(--gold); font-variant-numeric: tabular-nums; }
.vault-box.safe small { color: var(--gold); }
.interest-line { margin: .7rem 0 0; font-size: .92rem; }
.interest-line b { color: var(--gold); font-variant-numeric: tabular-nums; }
.vault-forms { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; margin-top: .8rem; }
.vault-form { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: .4rem; }
.vault-form input { margin: 0 !important; }
.vault-form button { width: auto; padding: .55rem .8rem; font-size: .85rem; }
@media (max-width: 620px) { .vault-forms { grid-template-columns: 1fr; } }
.clinic-me { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1rem; }
.buyout { display: flex; flex-direction: column; align-items: flex-end; gap: .2rem; margin: 0; }
.buyout button { width: auto; }
.buyout small { font-size: .75rem; }
@media (max-width: 620px) { .buyout { align-items: stretch; width: 100%; } }
.clinic-me > span { flex: 1 1 280px; }
/* empty perk slots stay invisible (but keep their spot, so nothing shifts); only slots with a diamond show */
.perk-slot:not(.on) { visibility: hidden; }

/* ---------- Players ---------- */
.players-tools { display: flex; flex-wrap: wrap; gap: .5rem; margin: .4rem 0 .9rem; }
.players-tools input { flex: 1 1 200px; margin: 0; }
.players-tools select { flex: 0 0 auto; width: auto; margin: 0; }
.players-tools button, .players-tools .clear-q { width: auto; padding: .55rem 1rem; text-decoration: none; }
.players a.who { color: inherit; text-decoration: none; }
.players a.who:hover { color: var(--gold); }
.players tr.is-me td { background: rgba(240, 180, 41, .06); }
.spy-btn { background: linear-gradient(180deg, #2b3a4a, #141c26) !important; color: #b9d3ec !important; border-color: #0c141c !important; box-shadow: 0 3px 0 #070b10 !important; text-shadow: none !important; }
.spy-btn:disabled { filter: grayscale(.4) brightness(.75); }
.pager { display: flex; justify-content: center; align-items: center; gap: .8rem; margin-top: .9rem; }
.pager .alt-btn { padding: .45rem .9rem; text-decoration: none; }
.players-tools select { color: var(--text); background: rgba(0, 0, 0, .55); border: 1px solid rgba(201, 150, 43, .25); border-radius: 4px; padding: .55rem .7rem; font: 600 .9rem "Barlow", sans-serif; }
.players-tools select option { background: #14110d; color: var(--text); }
.players td { vertical-align: middle; }

/* ---------- Messages inbox ---------- */
.top nav a.inbox { position: relative; display: inline-flex; align-items: center; padding: .35rem .5rem; color: var(--muted); }
.top nav a.inbox svg { width: 20px; height: 20px; }
.top nav a.inbox.has-new { color: var(--gold); }
.inbox-count { position: absolute; top: -2px; right: -4px; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 9px; background: #d0342a; color: #fff;
  font: 700 .68rem/17px "Barlow", sans-serif; text-align: center; letter-spacing: 0; box-shadow: 0 0 0 2px #0b0a08; }
.inbox-list { list-style: none; margin: .6rem 0 0; padding: 0; display: grid; gap: .45rem; }
.msg { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: .7rem; align-items: center; padding: .65rem .8rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, .3); }
.msg.new { border-color: rgba(240, 180, 41, .55); background: rgba(240, 180, 41, .07); }
.msg-tag { padding: .2rem .5rem; border-radius: 3px; font: 400 .72rem var(--stencil); text-transform: uppercase; letter-spacing: .06em; background: #2b3a4a; color: #b9d3ec; }
.msg-attack .msg-tag { background: #7a1a12; color: #ffd8cc; }
.msg-body a { color: var(--gold); margin-left: .3rem; }
.msg-when { font-size: .8rem; white-space: nowrap; }
@media (max-width: 620px) { .msg { grid-template-columns: 1fr; gap: .3rem; } }

/* ---------- Spy report ---------- */
.spy-card { margin-top: .6rem; padding: 1rem; border: 1px solid rgba(110, 160, 210, .45); border-radius: 6px; background: var(--grain), linear-gradient(160deg, rgba(60, 100, 140, .12), rgba(0, 0, 0, .5)); }
.spy-card.tier-full { border-color: var(--gold); }
.spy-head { display: flex; gap: .8rem; align-items: center; }
.spy-head img { border-radius: 6px; border: 1px solid var(--line); }
.spy-head b { font: 400 1.25rem var(--stencil); text-transform: uppercase; }
.spy-tier { display: inline-block; margin-left: .4rem; padding: .15rem .5rem; border-radius: 3px; font-size: .75rem; background: #2b3a4a; color: #b9d3ec; }
.tier-full .spy-tier { background: var(--grad); color: #140d02; }
.spy-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; margin: .9rem 0 0; }
.spy-grid div { padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, .35); }
.spy-grid dt { font-size: .72rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.spy-grid dd { margin: 0; font: 400 1.25rem var(--stencil); }
.spy-grid dd small { font: 600 .72rem "Barlow", sans-serif; }
.spy-extra { margin-top: .9rem; }
.spy-extra h2 { margin: 0 0 .3rem; font-size: 1rem; }
.spy-extra ul { margin: 0; padding-left: 1.1rem; }
.spy-extra p { margin: 0; }
.spy-extra .locked { font-style: italic; }
.spy-once { margin: .9rem 0 0; font-size: .8rem; }
.view-acts .spy-btn { padding: .6rem 1rem; }
@media (max-width: 620px) { .spy-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Jewelry Store: sell gold */
.sell-gold { display: flex; flex-wrap: wrap; align-items: center; gap: .9rem 1.1rem; margin: .2rem 0 1rem; padding: .9rem 1rem; border: 1px solid var(--gold); border-radius: 6px;
  background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .14), rgba(0, 0, 0, .45)); box-shadow: 0 0 20px rgba(240, 180, 41, .12); }
.gold-bars { flex: none; width: 96px; height: 72px; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .6)); }
.sell-info { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; gap: .2rem; }
.sell-info .shop-top { display: flex; justify-content: space-between; gap: .6rem; }
.sell-info .shop-name { font-size: 1.15rem; }
.sell-info b { color: var(--gold); }
.sell-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; }
.sell-actions .qty-box input { width: 4.6rem; margin: 0; }
.sell-actions button { width: auto; padding: .55rem .9rem; }
/* NPC marker */
.npc-tag { display: inline-block; margin-left: .4rem; padding: .05rem .4rem; border-radius: 3px; font: 700 .65rem "Barlow", sans-serif; letter-spacing: .08em;
  color: #140d02; background: linear-gradient(180deg, #9fd3ff, #4a8ed0); vertical-align: middle; }
h1 .npc-tag { font-size: .75rem; }
.npc-note { margin: .2rem 0 .8rem; padding: .55rem .8rem; border-left: 4px solid #4a8ed0; border-radius: 3px; background: rgba(74, 142, 208, .1); }
.npc-note b { color: var(--gold); }

/* ---- Pharmacy labs ---- */
.lab-head { margin-top: 2rem; padding-top: 1.2rem; border-top: 1px dashed rgba(201, 150, 43, .3); }
.labs { display: grid; gap: .8rem; margin-top: 1rem; }
.lab-card { display: flex; gap: 1rem; align-items: stretch; padding: .8rem; border: 1px solid rgba(201, 150, 43, .25); border-radius: 6px;
  background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .05), rgba(0, 0, 0, .5)); box-shadow: var(--shadow-soft); }
.lab-card.home { border-color: var(--gold); box-shadow: 0 0 22px rgba(240, 180, 41, .18); }
.lab-card.past { opacity: .6; }
.lab-img { flex: none; width: 120px; height: 120px; border-radius: 12px; box-shadow: 0 6px 18px rgba(0, 0, 0, .55); }
.lab-bench { margin-top: 1.2rem; padding: 1rem; border: 1px solid var(--gold); border-radius: 6px; box-shadow: 0 0 22px rgba(240, 180, 41, .12);
  background: var(--grain), radial-gradient(120% 90% at 50% 0%, rgba(160, 220, 70, .08), rgba(0, 0, 0, .55)); }
.bench-title { margin-bottom: .8rem; }
.bench-title b { font-family: var(--stencil); font-weight: 400; text-transform: uppercase; letter-spacing: .05em; color: var(--gold); }
.bench-row { display: flex; align-items: center; gap: .8rem; flex-wrap: wrap; }
.lab-slots { display: flex; gap: .6rem; flex-wrap: wrap; }
.lab-slot { display: flex; flex-direction: column; align-items: center; gap: .35rem; width: 104px; margin: 0; cursor: pointer; }
.slot-pic { display: grid; place-items: center; width: 84px; height: 84px; border-radius: 10px; border: 2px dashed rgba(201, 150, 43, .35); background: rgba(0, 0, 0, .45); overflow: hidden; }
.lab-slot.full .slot-pic, .lab-result.ok .slot-pic { border-style: solid; border-color: rgba(201, 150, 43, .7); }
.slot-pic img { width: 100%; height: 100%; display: block; }
.slot-plus { font: 400 1.8rem var(--stencil); color: rgba(201, 150, 43, .45); }
.lab-slot select { width: 100%; margin: 0; padding: .35rem .3rem; color: var(--text); border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px;
  background: rgba(0, 0, 0, .55); font: 600 .8rem "Barlow", sans-serif; }
.lab-slot select option { background: #14110d; color: var(--text); }
.bench-arrow { font: 400 2rem var(--stencil); color: var(--gold); }
.lab-result { display: flex; align-items: center; gap: .7rem; min-width: 0; flex: 1 1 200px; }
.lab-result .slot-pic { width: 96px; height: 96px; flex: none; }
.lab-result.ok .slot-pic { box-shadow: 0 0 18px rgba(160, 220, 70, .3); }
.result-name { display: flex; flex-direction: column; gap: .15rem; min-height: 2.8em; }
.result-name b { font-family: var(--stencil); font-weight: 400; text-transform: uppercase; color: var(--gold); letter-spacing: .04em; }
.result-name small { color: var(--muted); }
.bench-actions { display: flex; align-items: center; gap: .6rem; margin-top: .9rem; flex-wrap: wrap; }
.bench-actions .qty-box { margin: 0; flex: none; }
.bench-actions button { width: auto; min-width: 9rem; flex: none; }
.recipes { margin-top: 1.4rem; }
.recipes h3 { font-family: var(--stencil); font-weight: 400; text-transform: uppercase; letter-spacing: .05em; color: #c9a45a; margin: 0; }
.recipes > summary { display: flex; align-items: center; gap: .8rem; padding: .6rem .9rem; cursor: pointer; list-style: none; user-select: none;
  border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px; background: linear-gradient(180deg, #1c1914, #0e0c09); }
.recipes > summary::-webkit-details-marker { display: none; }
.recipes > summary:hover { border-color: rgba(201, 150, 43, .6); }
.recipes > summary:hover h3 { color: var(--gold); }
.recipes > summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.recipe-count { font-size: .8rem; color: var(--muted); }
.chev { margin-left: auto; width: 10px; height: 10px; border-right: 2px solid var(--gold); border-bottom: 2px solid var(--gold); transform: rotate(45deg); transition: transform .15s; margin-top: -4px; }
.recipes[open] > summary .chev { transform: rotate(-135deg); margin-top: 4px; }
.recipe-list { padding-top: .7rem; }
.recipe { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: .7rem .9rem; margin-bottom: .6rem;
  border: 1px solid var(--line); border-left: 4px solid #8fc23a; border-radius: 4px; background: rgba(0, 0, 0, .3); }
.recipe.locked { border-left-color: rgba(255, 255, 255, .15); }
.recipe-mix { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.r-ing { display: flex; flex-direction: column; align-items: center; gap: .2rem; text-align: center; }
.r-ing img { border-radius: 8px; }
.r-ing small { font-size: .72rem; color: var(--muted); max-width: 7rem; }
.r-ing.out small { color: var(--gold); }
.recipe-mix .plus { font: 400 1.3rem var(--stencil); color: var(--gold); }
.recipe-info { display: flex; flex-direction: column; align-items: flex-end; gap: .3rem; text-align: right; }
.recipe-info .shop-does { color: var(--gold); }
@media (max-width: 620px) {
  .lab-card { flex-direction: row; }
  .lab-img { width: 88px; height: 88px; }
  .lab-slot { width: 84px; } .slot-pic { width: 72px; height: 72px; }
  .bench-arrow { transform: rotate(90deg); width: 100%; text-align: center; }
  .recipe-info { align-items: flex-start; text-align: left; }
}
/* lab: batch cooking */
.lab-cooking { display: flex; align-items: center; gap: 1rem; }
.cooking-pic { width: 96px; height: 96px; flex: none; border-style: solid; border-color: rgba(160, 220, 70, .6); animation: brew 1.6s ease-in-out infinite; }
@keyframes brew { 50% { box-shadow: 0 0 22px rgba(160, 220, 70, .45); } }
.cook-info { display: flex; flex-direction: column; gap: .4rem; flex: 1; min-width: 0; }
.cook-info b { font-family: var(--stencil); font-weight: 400; text-transform: uppercase; letter-spacing: .04em; color: var(--gold); }
.cook-info small { color: var(--muted); }
.cook-info small span { color: var(--gold); font-weight: 700; font-variant-numeric: tabular-nums; }
.cook-bar { height: 12px; border-radius: 3px; background: rgba(0, 0, 0, .6); border: 1px solid rgba(201, 150, 43, .3); overflow: hidden; }
.cook-bar span { display: block; height: 100%; background: linear-gradient(90deg, #5a8a1c, #b8e04a); transition: width .25s linear; }
.result-name .cook-time { color: #b8d87a; }
@media (prefers-reduced-motion: reduce) { .cooking-pic { animation: none; } }
.recipe-info .muted { font-size: .85rem; }
/* Lab page + nav link */
.lab-hero { display: flex; gap: 1.2rem; align-items: center; margin-bottom: .6rem; }
.lab-hero-img { flex: none; width: 150px; height: 150px; border-radius: 14px; box-shadow: 0 8px 24px rgba(0, 0, 0, .6), 0 0 0 1px rgba(201, 150, 43, .35); }
.lab-hero h1 { margin: 0 0 .3rem; }
.lab-hero p { margin: .2rem 0; }
.lab-stats { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; font-size: .9rem; color: var(--muted); }
.lab-stats b { color: var(--gold); }
.lab-page .lab-bench { margin-top: .6rem; }
.lab-go { margin-top: 1rem; display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; }
.lab-go .alt-btn { display: inline-block; padding: .55rem 1rem; text-decoration: none; }
.nav-lab { position: relative; }
.lab-dot { display: inline-block; width: 7px; height: 7px; margin-left: .35rem; vertical-align: middle; border-radius: 50%; background: #b8e04a; box-shadow: 0 0 8px #b8e04a; animation: brew 1.6s ease-in-out infinite; }
.lab-dot.ready { background: var(--gold); box-shadow: 0 0 8px var(--gold); animation: none; }
@media (max-width: 620px) { .lab-hero { align-items: flex-start; } .lab-hero-img { width: 96px; height: 96px; } }
/* recipe rows: ingredients left, info right, one line on wide screens */
.recipe { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.recipe-info { min-width: 13rem; }
@media (max-width: 620px) { .recipe { grid-template-columns: 1fr; } }
.recipe-mix { flex-wrap: nowrap; gap: .35rem; }
.r-ing { width: 5.2rem; flex: none; }
.r-ing small { max-width: none; line-height: 1.15; }
@media (max-width: 620px) { .r-ing { width: 4.6rem; } .r-ing img { width: 40px; height: 40px; } .r-ing.out img { width: 46px; height: 46px; } }
@media (max-width: 620px) { .recipe-mix { flex-wrap: wrap; } }

/* ---- Black Market ---- */
.msg-market .msg-tag { background: #3a2a06; color: #ffd27a; }
.market-hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; padding-bottom: .8rem; border-bottom: 1px dashed rgba(201, 150, 43, .3); }
.market-hero h1 { margin: 0 0 .3rem; }
.market-hero p { margin: 0; max-width: 38rem; }
.market-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 1.2rem; align-items: start; }
.market-page h2 { font-size: 1.05rem; margin: 0 0 .7rem; color: #c9a45a; }
.market-bar { display: flex; justify-content: space-between; align-items: center; gap: .8rem; flex-wrap: wrap; margin-bottom: .6rem; }
.market-bar h2 { margin: 0; }
.market-filter label { margin: 0; }
.market-filter select { margin: 0; padding: .45rem .6rem; color: var(--text); background: rgba(0, 0, 0, .55); border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px; font: 600 .85rem "Barlow", sans-serif; }
.market-filter select option, .mk-sell select option { background: #14110d; color: var(--text); }
.market-empty { padding: 1.4rem; text-align: center; border: 1px dashed rgba(201, 150, 43, .3); border-radius: 6px; }
.mk-list { display: grid; gap: .6rem; }
.mk-card { display: grid; grid-template-columns: 72px minmax(0, 1fr) auto; gap: .9rem; align-items: center; padding: .7rem .8rem; border: 1px solid rgba(201, 150, 43, .22); border-radius: 6px;
  background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .04), rgba(0, 0, 0, .5)); }
.mk-card.own { border-style: dashed; }
.mk-img { border-radius: 10px; box-shadow: 0 4px 12px rgba(0, 0, 0, .5); }
.mk-info { display: flex; flex-direction: column; gap: .2rem; min-width: 0; }
.mk-info .shop-price small { font-size: .7rem; color: var(--muted); }
.mk-info .shop-does { color: var(--gold); font-size: .85rem; }
.mk-seller { font-size: .82rem; display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.mk-seller .who { display: inline-flex; align-items: center; gap: .35rem; color: var(--text); text-decoration: none; }
.mk-seller .who:hover { color: var(--gold); }
.mk-seller .pic { border-radius: 50%; object-fit: cover; }
.mk-seller b { color: var(--text); }
.mk-yours { margin: 0; padding: .1rem .5rem; font-size: .7rem; }
.mk-actions { display: flex; flex-direction: column; align-items: stretch; min-width: 11rem; }
.mk-actions .buy-row { display: flex; gap: .4rem; align-items: center; }
.mk-actions .qty-box { margin: 0; flex: none; }
.mk-actions button { width: auto; flex: 1; white-space: nowrap; padding: .6rem .8rem; }
.market-side { display: grid; gap: 1rem; position: sticky; top: 7.5rem; }
.mk-sell, .mk-mine { padding: .9rem; border: 1px solid rgba(201, 150, 43, .35); border-radius: 6px; background: var(--grain), linear-gradient(180deg, #1a1711, #0c0a08); }
.mk-sell label, .mk-nums label { display: flex; flex-direction: column; gap: .25rem; margin: 0; font-size: .8rem; }
.mk-sell select, .mk-sell input { margin: 0; }
.mk-sell select { padding: .5rem; color: var(--text); background: rgba(0, 0, 0, .55); border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px; font: 600 .9rem "Barlow", sans-serif; }
.mk-pick { display: flex; gap: .7rem; align-items: center; margin-bottom: .6rem; }
.mk-pick img { border-radius: 10px; flex: none; }
.mk-pick label { flex: 1; min-width: 0; }
.mk-nums { display: grid; grid-template-columns: 1fr 1.3fr; gap: .5rem; }
.mk-hint { font-size: .8rem; min-height: 2.4em; margin: .5rem 0; }
.mk-small { font-size: .75rem; margin: .6rem 0 0; }
.mk-row { display: flex; align-items: center; gap: .6rem; padding: .45rem 0; border-top: 1px solid var(--line); }
.mk-row img { border-radius: 6px; flex: none; }
.mk-row-txt { display: flex; flex-direction: column; flex: 1; min-width: 0; font-size: .85rem; }
.mk-row-txt small { color: var(--muted); }
.mk-x { width: auto; padding: .35rem .6rem; font-size: .75rem; }
@media (max-width: 860px) {
  .market-grid { grid-template-columns: 1fr; }
  .market-side { position: static; order: -1; }
}
@media (max-width: 560px) {
  .mk-card { grid-template-columns: 56px minmax(0, 1fr); }
  .mk-img { width: 56px; height: 56px; }
  .mk-actions { grid-column: 1 / -1; min-width: 0; }
}
/* room for the Lab + Black Market links: tighter menu so it stays on one line on a laptop screen */
.top nav a { padding: .35rem .42rem; font-size: .8rem; letter-spacing: .03em; }
.top nav a.inbox { padding: .35rem .4rem; }
.panel.wide.market-page { max-width: 1060px; }
/* recipe book: one collapsible section per slot count */
.recipe-group { margin-bottom: .55rem; border: 1px solid rgba(201, 150, 43, .2); border-radius: 4px; background: rgba(0, 0, 0, .25); }
.recipe-group > summary { display: flex; align-items: center; gap: .6rem; padding: .5rem .8rem; cursor: pointer; list-style: none; user-select: none; }
.recipe-group > summary::-webkit-details-marker { display: none; }
.recipe-group > summary:hover .rg-title { color: var(--gold); }
.recipe-group > summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.rg-title { font: 400 .95rem var(--stencil); text-transform: uppercase; letter-spacing: .05em; color: #e0c07a; }
.rg-count { min-width: 1.4rem; padding: .05rem .4rem; border-radius: 999px; text-align: center; font: 700 .75rem "Barlow", sans-serif; color: #140d02; background: var(--grad); }
.recipe-group.locked .rg-count { background: rgba(255, 255, 255, .12); color: var(--muted); }
.recipe-group.locked .rg-title { color: var(--muted); }
.rg-need { font-size: .78rem; }
.recipe-group .chev { width: 8px; height: 8px; }
.recipe-group[open] > summary .chev { transform: rotate(-135deg); margin-top: 4px; }
.rg-body { padding: 0 .6rem .2rem; }
.rg-body .recipe:last-child { margin-bottom: .6rem; }
.rg-empty { margin: .2rem .3rem .7rem; font-size: .85rem; }
.recipe.locked { opacity: .7; }
@media (max-width: 560px) { .rg-need { display: none; } }

/* ---- Profile notepad ---- */
.notepad { margin-top: 1.4rem; border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px; background: var(--grain), linear-gradient(180deg, #1a1711, #0c0a08); }
.notepad > summary { display: flex; align-items: center; gap: .8rem; padding: .65rem .9rem; cursor: pointer; list-style: none; user-select: none; }
.notepad > summary::-webkit-details-marker { display: none; }
.notepad > summary:hover .np-title { color: var(--gold); }
.notepad > summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.notepad[open] > summary { border-bottom: 1px dashed rgba(201, 150, 43, .25); }
.notepad[open] > summary .chev { transform: rotate(-135deg); margin-top: 4px; }
.np-title { font: 400 1.05rem var(--stencil); text-transform: uppercase; letter-spacing: .05em; color: #c9a45a; }
.np-status { font-size: .8rem; }
.np-status.saved { color: var(--cash); }
.np-status.err { color: var(--hp); }
.np-body { padding: .8rem .9rem .9rem; }
.np-body textarea { display: block; width: 100%; box-sizing: border-box; min-height: 11rem; margin: 0; padding: .8rem .9rem; resize: vertical;
  font: 500 .95rem/1.55 "Barlow", sans-serif; color: #efe6cf; background: rgba(0, 0, 0, .55);
  background-image: repeating-linear-gradient(180deg, transparent 0 1.47rem, rgba(201, 150, 43, .1) 1.47rem 1.48rem); background-attachment: local;
  border: 1px solid rgba(201, 150, 43, .25); border-radius: 4px; }
.np-body textarea:focus { outline: none; border-color: rgba(255, 197, 61, .6); }
.np-foot { display: flex; align-items: center; gap: .8rem; margin-top: .6rem; flex-wrap: wrap; font-size: .8rem; }
.np-hint { flex: 1; }
.np-foot button { width: auto; padding: .5rem 1.4rem; }
.lab-cooking .stop-cook { width: auto; flex: none; align-self: center; padding: .55rem 1rem; color: #ffb4a8; border-color: rgba(224, 72, 62, .45); }
.lab-cooking .stop-cook:hover { color: #ffd8cc; border-color: rgba(224, 72, 62, .8); background: rgba(224, 72, 62, .12); }
@media (max-width: 560px) { .lab-cooking { flex-wrap: wrap; } .lab-cooking .stop-cook { width: 100%; } }

/* ---- Stock Market ---- */
.panel.wide.stocks-page { max-width: 1060px; }
.up { color: var(--cash); } .down { color: var(--hp); } .flat { color: var(--muted); }
.tape { overflow: hidden; margin: -.4rem 0 1rem; padding: .45rem 0; border-top: 1px solid rgba(201, 150, 43, .35); border-bottom: 1px solid rgba(201, 150, 43, .35);
  background: #050504; white-space: nowrap; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.tape-run { display: inline-block; animation: tape 40s linear infinite; }
.tape-item { display: inline-block; margin-right: 2.2rem; font: 600 .85rem/1 "Barlow", sans-serif; color: #e8dcc0; font-variant-numeric: tabular-nums; }
.tape-item b { font-family: var(--stencil); font-weight: 400; color: var(--gold); letter-spacing: .05em; margin-right: .3rem; }
.tape-item i { font-style: normal; margin-left: .3rem; }
@keyframes tape { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .tape-run { animation: none; } }
.portfolio { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin-bottom: 1rem; }
.portfolio > div { padding: .7rem .9rem; border: 1px solid rgba(201, 150, 43, .3); border-radius: 4px; background: linear-gradient(180deg, #1a1711, #0c0a08); }
.pf-label { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.portfolio b { font: 400 1.35rem var(--stencil); color: var(--gold); font-variant-numeric: tabular-nums; }
.portfolio b.up { color: var(--cash); } .portfolio b.down { color: var(--hp); }
.portfolio small { font: 600 .8rem "Barlow", sans-serif; }
.stock-list { display: grid; gap: .5rem; }
.stock { display: grid; grid-template-columns: minmax(10rem, 1.3fr) 7rem 9rem minmax(8rem, 1fr) auto; gap: .9rem; align-items: center; padding: .6rem .8rem;
  border: 1px solid rgba(201, 150, 43, .22); border-radius: 6px; background: var(--grain), linear-gradient(160deg, rgba(240, 180, 41, .04), rgba(0, 0, 0, .5)); }
.st-id { display: flex; align-items: center; gap: .6rem; min-width: 0; }
.st-id img { border-radius: 8px; flex: none; }
.st-id > div { display: flex; flex-direction: column; min-width: 0; }
.st-tick { font: 400 1.1rem var(--stencil); letter-spacing: .06em; color: var(--gold); }
.st-name { font-size: .8rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.st-price { display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.st-price b { font-size: 1.15rem; color: var(--text); }
.st-price span { font-size: .8rem; font-weight: 700; }
.st-price small { font-weight: 400; color: var(--muted); }
.st-chart { display: flex; flex-direction: column; gap: .15rem; }
.st-chart small { font-size: .7rem; }
.spark { display: block; }
.st-mine { display: flex; flex-direction: column; font-size: .85rem; font-variant-numeric: tabular-nums; }
.st-mine small { color: var(--muted); }
.st-trade { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; justify-content: flex-end; }
.st-trade .qty-box { margin: 0; }
.st-trade .qty-box input { width: 4.2rem !important; }
.st-trade button { width: auto; padding: .5rem .8rem; font-size: .85rem; }
.st-trade .st-all { padding: .5rem .55rem; }
.st-total { flex-basis: 100%; text-align: right; font-size: .75rem; font-variant-numeric: tabular-nums; }
@media (max-width: 900px) {
  .stock { grid-template-columns: 1fr auto; }
  .st-chart, .st-mine { grid-column: span 1; }
  .st-trade { grid-column: 1 / -1; justify-content: flex-start; }
  .st-total { text-align: left; }
}
@media (max-width: 560px) { .portfolio { grid-template-columns: 1fr; } .portfolio b { font-size: 1.1rem; } }
/* Stock Market link: tighten the menu a little more so it still fits one line at 1280px */
.top nav a { padding: .35rem .32rem; letter-spacing: .01em; font-size: .76rem; }
.top nav a.me { margin-left: .2rem; }

/* ---- Admin: Watchtower ---- */
.msg-admin .msg-tag { background: #5a0e0e; color: #ffd0c8; }
.admin-shield.has-new { color: #ff8a7a; }
.admin-shield .inbox-count { background: #e0483e; }
.panel.wide.admin-page { max-width: 1180px; }
.admin-page h1 small { font: 600 .8rem "Barlow", sans-serif; color: #ff8a7a; letter-spacing: .1em; vertical-align: middle; }
.adm-h { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin: 1.2rem 0 .6rem; font-size: 1rem; color: #c9a45a; }
.adm-h small { font: 500 .75rem "Barlow", sans-serif; text-transform: none; letter-spacing: 0; }
.adm-badge { padding: .1rem .5rem; border-radius: 999px; font: 700 .75rem "Barlow", sans-serif; letter-spacing: 0; background: rgba(255, 255, 255, .1); color: var(--muted); }
.adm-badge.hot { background: #e0483e; color: #fff; }
.adm-tools { margin-left: auto; display: flex; align-items: center; gap: .8rem; font: 600 .8rem "Barlow", sans-serif; text-transform: none; letter-spacing: 0; }
.adm-btn { width: auto; padding: .3rem .7rem; font-size: .75rem; }
.adm-empty { padding: 1rem; border: 1px dashed rgba(201, 150, 43, .3); border-radius: 6px; text-align: center; }
.adm-alerts { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.adm-alert { display: grid; grid-template-columns: 8.5rem 1fr auto auto; gap: .8rem; align-items: center; padding: .55rem .8rem; border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, .08); border-left: 4px solid #c9962b; background: rgba(0, 0, 0, .35); font-size: .88rem; }
.adm-alert.lvl-high { border-left-color: #e0483e; background: rgba(224, 72, 62, .08); }
.adm-alert.lvl-low { border-left-color: #6a6a6a; }
.adm-alert.seen { opacity: .55; }
.adm-kind { font: 400 .78rem var(--stencil); text-transform: uppercase; letter-spacing: .05em; color: var(--gold); }
.adm-alert.lvl-high .adm-kind { color: #ff8a7a; }
.adm-links { display: block; font-size: .78rem; margin-top: .15rem; }
.adm-time { font-size: .75rem; white-space: nowrap; }
.adm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: .4rem; }
.adm-card { min-width: 0; padding: .2rem .9rem .9rem; border: 1px solid rgba(201, 150, 43, .25); border-radius: 6px; background: linear-gradient(180deg, #16130f, #0b0a08); }
.adm-card.wide { grid-column: 1 / -1; }
.adm-card .adm-h { margin-top: .8rem; }
.adm-table { width: 100%; border-collapse: collapse; font-size: .84rem; font-variant-numeric: tabular-nums; }
.adm-table th { text-align: left; padding: .35rem .4rem; font-size: .72rem; border-bottom: 1px solid rgba(201, 150, 43, .3); }
.adm-table td { padding: .4rem; border-bottom: 1px solid rgba(255, 255, 255, .05); }
.adm-table tr.flag td { background: rgba(224, 72, 62, .1); }
.adm-table a { color: var(--text); }
.adm-table a:hover { color: var(--gold); }
.warn { color: #f0b429; }
.adm-note { font-size: .75rem; margin: .6rem 0 0; }
@media (max-width: 860px) {
  .adm-grid { grid-template-columns: 1fr; }
  .adm-alert { grid-template-columns: 1fr auto; }
  .adm-kind { grid-column: 1 / -1; }
}
/* the admin's menu has one more icon (shield): keep the icons tight so it still fits one line */
.top nav a.inbox { padding: .35rem .3rem; }
.top nav { gap: .05rem; }

/* ---- Top bar: brand + (money, gold, profile chip) on the first row, the menu on the second ---- */
.top { display: grid; grid-template-columns: auto 1fr; grid-template-areas: "brand me" "nav nav"; align-items: center; gap: .4rem 1rem; }
.top .brand { grid-area: brand; }
.top nav { grid-area: nav; }
.top-me { grid-area: me; justify-self: end; display: flex; align-items: center; gap: .7rem; min-width: 0; }
.top-wallet { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; font: 700 .72rem/1.2 "Barlow", sans-serif;
  color: var(--gold); font-variant-numeric: tabular-nums; letter-spacing: .02em; white-space: nowrap; min-width: 7.5em; text-align: right; }
.top-wallet .w-cash { color: #ffd27a; }
.top-wallet .w-gold { display: inline-flex; align-items: center; gap: .25rem; color: var(--gold); }
.top-wallet .w-gold svg { width: 9px; height: 9px; color: #f0b429; }
.top-me a.me { display: inline-flex; align-items: center; gap: .5rem; padding: .2rem .8rem .2rem .2rem; margin: 0; text-decoration: none; color: var(--text);
  background: rgba(255, 255, 255, .05); border: 1px solid var(--line-strong); border-radius: 4px; font-weight: 700; font-size: 1rem; transition: border-color .15s; }
.top-me a.me:hover { border-color: rgba(255, 176, 46, .6); color: var(--gold); }
.top-me a.me .pic { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
@media (max-width: 520px) {
  .top-me { gap: .45rem; }
  .top-wallet { font-size: .66rem; min-width: 0; }
  .top-me a.me { padding: .15rem .5rem .15rem .15rem; font-size: .85rem; }
  .top-me a.me .pic { width: 26px; height: 26px; }
}
@media (min-width: 1700px) {
  .top { grid-template-columns: auto 1fr auto; grid-template-areas: "brand nav me"; }
  .top nav { justify-self: end; }
}
.top-me { height: 42px; align-self: center; }
@media (max-width: 520px) { .top .brand { font-size: 1.2rem; } .top { gap: .4rem .6rem; } }
/* stat totals: gym + enemy cards */
.gym-total { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; margin: .2rem 0 .8rem; font-size: .95rem; }
.gym-total b { font: 400 1.3rem var(--stencil); color: var(--gold); letter-spacing: .03em; font-variant-numeric: tabular-nums; }
.gym-total-hint { flex-basis: 100%; font-size: .78rem; }
.ec-stats { display: block; font-size: .78rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.ec-stats b { color: var(--gold); font-weight: 700; }
.ec-stats small { font-size: .72rem; opacity: .85; }
/* stock ticker in the header, under the menu */
.top { grid-template-areas: "brand me" "nav nav" "tape tape"; }
.top-tape { grid-area: tape; display: block; margin: 0 -1.5rem -.9rem; padding: .32rem 0; text-decoration: none; border-bottom: 0;
  border-top: 1px solid rgba(201, 150, 43, .25); background: rgba(0, 0, 0, .55); }
.top-tape .tape-run { animation-duration: 45s; }
.top-tape:hover .tape-run { animation-play-state: paused; }
.top-tape .tape-item { font-size: .76rem; }
.top-tape .up { color: var(--cash); } .top-tape .down { color: var(--hp); } .top-tape .flat { color: var(--muted); }
@media (min-width: 1700px) { .top { grid-template-areas: "brand nav me" "tape tape tape"; } }
@media (max-width: 520px) { .top-tape { margin: 0 -1rem -.9rem; } }
/* gym: the "each session now gives" line grows when you're below full energy; keep its space so Train buttons never move */
.gym-now { min-height: calc(2 * 1.5em); }
@media (max-width: 620px) { .gym-now { min-height: calc(3 * 1.5em); } }
/* ---- In the clinic: red name + profile banner ---- */
.in-clinic, .who.in-clinic, a.who.in-clinic, .chat b.in-clinic { color: #ff5a4a !important; }
h1.in-clinic { color: #ff5a4a; -webkit-text-fill-color: #ff5a4a; }
h1.in-clinic small { color: var(--muted); -webkit-text-fill-color: currentColor; }
.top-me a.me.in-clinic { border-color: rgba(224, 72, 62, .6); }
.top-me a.me.in-clinic span { color: #ff5a4a; }
.clinic-banner { display: flex; align-items: center; gap: .7rem; margin: -.2rem 0 .9rem; padding: .55rem .8rem; border-radius: 4px;
  border: 1px solid rgba(224, 72, 62, .55); border-left: 4px solid #e0483e; background: rgba(224, 72, 62, .1); color: #ffd0c8; font-weight: 600; }
.clinic-banner b { color: #ff8a7a; font-variant-numeric: tabular-nums; }
.cb-cross { display: grid; place-items: center; width: 22px; height: 22px; flex: none; border-radius: 4px; background: #e0483e; color: #fff; font: 900 1.05rem/1 "Barlow", sans-serif; }
.clinic-banner a { margin-left: auto; color: #ffb4a8; font-size: .85rem; }
/* Block: one location per city */
.loc-tab small { margin-left: .35rem; font-size: .7rem; opacity: .75; letter-spacing: .04em; }
.loc-none { padding: 1rem 1.1rem; margin: .75rem 0 1rem; border: 1px dashed rgba(201, 150, 43, .4); border-radius: 6px; background: rgba(0, 0, 0, .3); display: grid; gap: .4rem; }
.loc-none b { color: var(--gold); }
.loc-where { margin: .2rem 0 0; padding-left: 1.1rem; display: grid; gap: .15rem; }

/* Leaderboard: rank in each fighting stat (no numbers shown) */
.rk { color: var(--muted); font-variant-numeric: tabular-nums; }
.rk.rk-top { color: var(--gold); font-weight: 700; }
.panel.wide.lb-panel { max-width: 1060px; }
.lb-panel th, .lb-panel td { white-space: nowrap; }
.lb-panel td:has(.rk), .lb-panel th.rk-col { text-align: center; }
@media (max-width: 760px) { .lb-panel th, .lb-panel td { padding: .5rem .45rem; } }

/* Clinic: buy another player out */
.row-buyout { margin: 0; }
.row-buyout button { width: auto; padding: .3rem .7rem; font-size: .85rem; white-space: nowrap; }
.rk-n { color: var(--muted); font-size: .8rem; margin-left: .2rem; }

/* Player profile: send money, gold or an item */
.send-box { margin-top: 1rem; border: 1px solid rgba(201, 150, 43, .3); border-radius: 6px; background: rgba(0, 0, 0, .3); }
.send-box > summary { cursor: pointer; padding: .7rem 1rem; font: 400 .9rem var(--stencil); text-transform: uppercase; letter-spacing: .06em; color: var(--gold); list-style: none; }
.send-box > summary::-webkit-details-marker { display: none; }
.send-box > summary::before { content: "+"; display: inline-block; width: 1.1rem; }
.send-box[open] > summary::before { content: "−"; }
.send-form { display: grid; grid-template-columns: 1fr 1fr 2fr auto; gap: .8rem; align-items: end; padding: 0 1rem .4rem; }
.send-form label { display: grid; gap: .3rem; font-size: .85rem; margin: 0; }
.send-form input, .send-form select { width: 100%; background: #14110d; color: var(--text); border: 1px solid var(--line); border-radius: 4px; padding: .45rem .55rem; font: inherit; }
.send-form select option { background: #14110d; color: var(--text); }
.send-item-row { display: grid; grid-template-columns: 1fr 4.5rem; gap: .4rem; }
.send-form .send-btn { width: auto; padding: .5rem 1.2rem; }
.send-note { padding: 0 1rem .8rem; margin: 0; font-size: .8rem; }
.send-form input:disabled { opacity: .45; color: var(--muted); }
@media (max-width: 760px) { .send-form { grid-template-columns: 1fr 1fr; } .send-item { grid-column: 1 / -1; } .send-form .send-btn { grid-column: 1 / -1; width: 100%; } }
.msg-gift .msg-tag { background: #1f3a22; color: #b8f0c2; }
/* Foe pictures for the later cities (tier = location number) */
.foe-pic.tier-6 img { filter: sepia(1) saturate(4) hue-rotate(-25deg) brightness(.8) contrast(1.25); }
.foe-pic.tier-7 img { filter: grayscale(1) brightness(.55) contrast(1.6); }
.foe-pic.tier-7 { border-color: rgba(255, 197, 61, .6); }
.foe-pic.tier-8 img { filter: sepia(1) saturate(5) hue-rotate(-40deg) brightness(.7) contrast(1.4); }
.foe-pic.tier-8, .foe-pic.tier-9 { border-color: var(--gold); box-shadow: 0 0 14px rgba(255, 197, 61, .55); }
.foe-pic.tier-9 img { filter: sepia(1) saturate(3.5) brightness(1.1) contrast(1.3); }
.foe-pic.tier-9 { box-shadow: 0 0 20px rgba(255, 197, 61, .8), 0 0 4px rgba(224, 72, 62, .6) inset; }
/* Profile: home gym bar, to the left of the home picture (only when equipment is set up) */
.home-wrap { display: flex; gap: .55rem; align-items: stretch; flex: none; }
.gym-col { width: 41px; height: 160px; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 5px 0 8px;
  border-radius: 10px; border: 1px solid rgba(240, 180, 41, .45); background: linear-gradient(180deg, rgba(240, 180, 41, .14), rgba(0, 0, 0, .55)); box-shadow: inset 0 0 12px rgba(0, 0, 0, .6); }
.gym-col .perk-slot { height: 29px; }
.gym-col .perk-tip { left: auto; right: calc(100% + 10px); white-space: normal; width: 220px; }
.gym-col .perk-tip::before { left: auto; right: -6px; transform: translateY(-50%) rotate(225deg); }
.gym-col-label { writing-mode: vertical-rl; transform: rotate(180deg); font: 400 .72rem var(--stencil); letter-spacing: .3em; color: var(--gold); opacity: .8; }
@media (max-width: 520px) {
  .gym-col { height: 128px; width: 34px; }
  .avatar-card .home-wrap { width: 100%; }
  .avatar-card .home-wrap .prop-box { flex: 1; width: auto; }
  .gym-col .perk-slot img { width: 22px; height: 22px; }
}
/* City Stores: wider page, more per row, so it's shorter */
.panel.wide.stores-page { max-width: 1180px; }
@media (min-width: 1000px) {
  .stores-page .store-tabs { grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .stores-page .shop { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .stores-page .props { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9rem; }
  .stores-page .props .prop-card { margin: 0; }
}
.prop-info .sell-home { margin-top: .5rem; }
/* Gun Shop: compact cards, 4 to a row on wide screens (image on top-left, text beside, buttons under) */
.stores-page .shop.guns { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stores-page .shop.guns .shop-item { flex-wrap: wrap; align-items: flex-start; }
.stores-page .shop.guns .shop-img { width: 96px; height: 96px; }
.stores-page .shop.guns .shop-actions { flex: 1 1 100%; }
@media (min-width: 1000px) { .stores-page .shop.guns { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 620px) { .stores-page .shop.guns { grid-template-columns: 1fr; } }
.stores-page .shop.guns .shop-top { flex-direction: column; align-items: flex-start; gap: .1rem; } .stores-page .shop.guns .shop-name { overflow-wrap: normal; word-break: keep-all; }
/* Header ticker: close button (not on the Stock Market) */
.top-tape-wrap { grid-area: tape; position: relative; margin: 0 -1.5rem -.9rem; }
.top-tape-wrap .top-tape { margin: 0; padding-right: 2rem; }
.tape-x { position: absolute; right: .35rem; top: 50%; transform: translateY(-50%); width: 1.4rem; height: 1.4rem; padding: 0; margin: 0; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid rgba(201, 150, 43, .45); background: rgba(10, 8, 6, .95); color: var(--gold); font: 700 1rem/1 Arial, sans-serif; cursor: pointer; box-shadow: none; }
.tape-x:hover { background: var(--gold); color: #1a1204; }
@media (max-width: 520px) { .top-tape-wrap { margin: 0 -1rem -.9rem; } }
.tape-back { margin: .2rem 0 0; font-size: .85rem; }
.link-btn { background: none; border: 0; padding: 0; margin: 0 0 0 .3rem; width: auto; color: var(--gold); text-decoration: underline; font: inherit; cursor: pointer; box-shadow: none; text-transform: none; letter-spacing: 0; }
/* Ticker closed: a small button where it was, to bring it back */
.top-tape-wrap.tape-closed { display: flex; justify-content: flex-end; padding: .2rem .5rem; border-top: 1px solid rgba(201, 150, 43, .2); background: rgba(0, 0, 0, .35); }
.tape-open { width: auto; margin: 0; padding: .15rem .6rem; font: 700 .68rem "Barlow", sans-serif; letter-spacing: .06em; text-transform: uppercase;
  color: var(--gold); background: transparent; border: 1px solid rgba(201, 150, 43, .45); border-radius: 999px; box-shadow: none; cursor: pointer; }
.tape-open:hover { background: var(--gold); color: #1a1204; }
/* Cards in a row stretch to the tallest one: keep their content packed at the top so buttons never move when a neighbour grows */
.shop-item { align-content: flex-start; }
/* Ticker open/closed toggle: both states are on the page, a class switches them */
.top-tape-wrap .tape-open { display: none; }
.top-tape-wrap.closed .top-tape, .top-tape-wrap.closed .tape-x { display: none; }
.top-tape-wrap.closed { display: flex; justify-content: flex-end; padding: .2rem .5rem; border-top: 1px solid rgba(201, 150, 43, .2); background: rgba(0, 0, 0, .35); }
.top-tape-wrap.closed .tape-open { display: inline-block; }
.stores-page .shop.guns .shop-desc { display: none; }   /* gun cards: no flavor text, so they all match */
.gym-lore { display: block; margin-top: .2rem; font-style: italic; opacity: .75; }
/* Phone turned sideways (short, wide screen): one compact header row, menu scrolls sideways, slim ticker,
   and the header scrolls away with the page instead of staying pinned, so the game gets the screen. */
@media (orientation: landscape) and (max-height: 500px) {
  .top { position: static; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "brand nav me" "tape tape tape"; gap: .25rem .6rem; padding: .35rem .8rem; }
  .brand { font-size: 1.05rem; }
  .top nav { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
    mask-image: linear-gradient(90deg, #000 92%, transparent); -webkit-mask-image: linear-gradient(90deg, #000 92%, transparent); }
  .top nav::-webkit-scrollbar { display: none; }
  .top nav a { flex: 0 0 auto; padding: .3rem .4rem; font-size: .72rem; white-space: nowrap; }
  .top nav a.inbox svg { width: 17px; height: 17px; }
  .top-me { gap: .4rem; }
  .top-wallet { font-size: .62rem; }
  .top-me a.me { padding: .1rem .45rem .1rem .1rem; font-size: .78rem; }
  .top-me a.me .pic { width: 22px; height: 22px; }
  .top-tape-wrap { margin: 0 -.8rem -.35rem; }
  .top-tape { padding: .18rem 0; }
  .top-tape .tape-item { font-size: .66rem; margin-right: 1.6rem; }
  .tape-x { width: 1.15rem; height: 1.15rem; font-size: .85rem; }
  .panel, .panel.wide { max-width: none; margin: .6rem .5rem 1rem; padding: 1rem 1.2rem; }
  h1 { font-size: 1.5rem; }
}
/* Jail (jail.php): steel bars over a cold panel */
.panel.wide.jail-page { max-width: 620px; text-align: center; overflow: hidden; }
.jail-bars { position: absolute; inset: 0; pointer-events: none; opacity: .16;
  background: repeating-linear-gradient(90deg, transparent 0 46px, #9aa3ad 46px 52px, #3c4249 52px 56px, transparent 56px 102px); }
.jail-page > *:not(.jail-bars) { position: relative; }
.jail-page h1 { color: #d8dde2; letter-spacing: .08em; }
.jail-lead { color: var(--muted); }
.jail-reason { margin: 1rem auto; max-width: 30rem; padding: .7rem 1rem; border: 1px solid rgba(224, 72, 62, .45); border-radius: 6px; background: rgba(224, 72, 62, .08); }
.jail-reason span { display: block; font: 700 .7rem "Barlow", sans-serif; letter-spacing: .12em; text-transform: uppercase; color: #ff8a7a; margin-bottom: .2rem; }
.jail-time { display: grid; gap: .3rem; margin: 1.2rem 0; }
.jail-time b { font: 400 2rem var(--stencil); color: var(--gold); font-variant-numeric: tabular-nums; }
.jail-links { display: flex; gap: .6rem; justify-content: center; }
.jail-links .alt-btn { width: auto; }
.fine-print { font-size: .78rem; margin-top: .8rem; }
/* Admin: player lookup (admin_player.php) */
.adm-search { display: flex; gap: .5rem; margin: .4rem 0 1rem; }
.adm-search input { flex: 1; margin: 0; }
.adm-search .adm-btn { padding: .5rem 1rem; }
.adm-who { display: flex; gap: 1rem; align-items: center; margin: .5rem 0 1rem; }
.adm-who .pic { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-strong); }
.adm-who h2 { margin: 0; display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; font-size: 1.4rem; }
.adm-who p { margin: .2rem 0 0; font-size: .85rem; }
.adm-tag { display: inline-block; padding: .1rem .45rem; border-radius: 4px; font: 700 .68rem "Barlow", sans-serif; letter-spacing: .06em; text-transform: uppercase;
  background: rgba(255, 255, 255, .1); color: var(--text); vertical-align: middle; }
.adm-tag.jail { background: rgba(240, 180, 41, .2); color: var(--gold); }
.adm-tag.ban { background: rgba(224, 72, 62, .25); color: #ff8a7a; }
.adm-kv th { text-align: left; font-weight: 600; color: var(--muted); white-space: nowrap; width: 1%; padding-right: 1rem; }
.adm-act { display: grid; gap: .5rem; margin: 0 0 .9rem; }
.adm-act label { margin: 0; font-size: .82rem; }
.adm-act textarea { width: 100%; resize: vertical; }
.adm-row { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-bottom: .9rem; }
.adm-row select { width: auto; min-width: 9rem; margin: 0; padding: .35rem .5rem; color: var(--text); background: #0d0b08; border: 1px solid var(--line-strong); }
.adm-btn.danger { background: #b8382f; border-color: #e0483e; color: #fff; }
.adm-btn.alt { background: transparent; border: 1px solid var(--line-strong); color: var(--text); box-shadow: none; }
.adm-small { font-size: .85rem; margin: .3rem 0; }
.adm-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; font-size: .85rem; }
.adm-list li.lvl-high { color: #ff8a7a; }
.adm-scroll { max-height: 320px; overflow: auto; }
.adm-table tr.in td { background: rgba(80, 200, 120, .05); }
.adm-lookup { display: inline-block; width: auto; margin: .2rem 0 .4rem; }
/* Dealers + street news (dealers.php) */
.mk-dealer { background: rgba(240, 180, 41, .16); color: var(--gold); border-color: rgba(240, 180, 41, .4); }
.dealer-who { display: inline-flex; align-items: center; gap: .35rem; color: var(--text); }
.street-news { margin: 0 0 1rem; padding: .7rem .9rem; border: 1px solid rgba(201, 150, 43, .22); border-radius: 6px; background: rgba(0, 0, 0, .3); }
.street-news h2 { margin: 0 0 .45rem; font-size: .95rem; color: #c9a45a; }
.street-news ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; font-size: .85rem; }
.street-news li { opacity: .65; }
.street-news li.live { opacity: 1; }
.sn-tag { display: inline-block; margin-right: .45rem; padding: .05rem .4rem; border-radius: 3px; font: 700 .66rem "Barlow", sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.sn-raid .sn-tag { background: rgba(95, 211, 138, .18); color: #5fd38a; }
.sn-flood .sn-tag { background: rgba(224, 72, 62, .2); color: #ff8a7a; }
.acct-links { margin: 1.2rem 0 0; font-size: .82rem; text-align: right; }
.pw-req { padding: .45rem .6rem; border-left: 3px solid var(--gold); background: rgba(240, 180, 41, .07); border-radius: 3px; }
.pw-req.done { opacity: .55; border-left-color: #6a6a6a; }
.mail-setup { max-width: 620px; }
.mail-setup form { display: grid; gap: .6rem; margin-top: .8rem; }
.mail-help, .mail-adv { margin: .6rem 0; font-size: .88rem; }
.mail-help summary, .mail-adv summary { cursor: pointer; color: var(--gold); }
.mail-help ol { margin: .5rem 0 0 1.1rem; display: grid; gap: .3rem; }
.mail-what { border: 1px solid var(--line-strong); border-radius: 6px; padding: .5rem .8rem; display: grid; gap: .3rem; }
.mail-what legend { padding: 0 .3rem; font-size: .8rem; color: var(--muted); }
.chk { display: flex; align-items: center; gap: .5rem; margin: 0; font-size: .9rem; }
.chk input { width: auto; margin: 0; }
.store-msg.bad { border-color: rgba(224, 72, 62, .5); }
/* Rules page + footer link */
.rules-page { max-width: 760px; }
.rules-list { display: grid; gap: .7rem; padding-left: 1.3rem; margin: 1rem 0 1.4rem; }
.rules-list li { line-height: 1.5; }
.rules-list b { color: var(--gold); }
.rules-page h2 { font-size: 1.05rem; margin: 1.2rem 0 .4rem; color: #c9a45a; }
.site-foot { text-align: center; font-size: .78rem; margin: 1.5rem 0 1rem; opacity: .6; }
.site-foot a { color: var(--muted); }

/* ---- Player mail (messages.php) ---- */
.dm-tabs { display: flex; gap: .4rem; margin: .4rem 0 0; border-bottom: 1px solid var(--line); }
.dm-tabs a { padding: .45rem .9rem; color: var(--muted); text-decoration: none; border: 1px solid transparent; border-bottom: none; border-radius: 5px 5px 0 0; font: 400 .85rem var(--stencil); text-transform: uppercase; letter-spacing: .06em; }
.dm-tabs a.on { color: var(--gold); border-color: var(--line); background: rgba(0, 0, 0, .35); }
.dm-tabs b { display: inline-block; min-width: 1.3rem; padding: 0 .3rem; margin-left: .25rem; border-radius: 9px; background: var(--gold); color: #1a1204; font: 700 .72rem/1.3rem sans-serif; text-align: center; }
.dm-panel .store-msg { min-height: calc(1.5em + 1.1rem + 2px); }
.dm-compose { display: grid; gap: .5rem; margin: .6rem 0 1rem; }
.dm-compose label { margin: 0; display: grid; gap: .3rem; }
.dm-compose textarea { width: 100%; resize: vertical; min-height: 4.5rem; font: inherit; color: var(--text); padding: .55rem .7rem; box-sizing: border-box; }
.dm-compose button { justify-self: end; width: auto; min-width: 8rem; }
.dm-head .alt-btn { text-decoration: none; }
.msg-dm { grid-template-columns: auto minmax(0, 1fr) auto; }
.msg .pic { border-radius: 50%; object-fit: cover; }
.dm-row { color: var(--text); text-decoration: none; overflow-wrap: anywhere; }
.dm-row:hover b { color: var(--gold); }
.dm-new { font-size: .72rem; color: #1a1204; background: var(--gold); border-radius: 9px; padding: .05rem .4rem; margin-left: .3rem; }
.dm-head { display: flex; align-items: center; gap: .6rem; margin: .3rem 0 .6rem; flex-wrap: wrap; }
.dm-head .pic { border-radius: 50%; object-fit: cover; }
.dm-who { color: var(--gold); font-weight: 700; text-decoration: none; }
.dm-admin { font: 400 .7rem var(--stencil); text-transform: uppercase; letter-spacing: .06em; background: #5a0e0e; color: #ffd0c8; padding: .15rem .45rem; border-radius: 3px; }
.dm-block { margin-left: auto; }
.dm-thread { height: 22rem; overflow-y: auto; display: flex; flex-direction: column; gap: .45rem; padding: .7rem; border: 1px solid var(--line); border-radius: 5px; background: rgba(0, 0, 0, .3); }
.dm-bubble { max-width: 80%; padding: .5rem .7rem; border-radius: 8px; overflow-wrap: anywhere; }
.dm-bubble p { margin: 0 0 .2rem; }
.dm-bubble span { font-size: .72rem; }
.dm-bubble.theirs { align-self: flex-start; background: rgba(255, 255, 255, .06); border: 1px solid var(--line); }
.dm-bubble.mine { align-self: flex-end; background: rgba(240, 180, 41, .12); border: 1px solid rgba(240, 180, 41, .35); }
@media (max-width: 620px) { .msg-dm { grid-template-columns: auto minmax(0, 1fr); } .msg-dm .msg-when { grid-column: 2; } .dm-thread { height: 60vh; } }

/* ---- Street jail (lockup.php) ---- */
.in-jail, .who.in-jail, a.who.in-jail { color: #7fb2ff !important; }
h1.in-jail { color: #7fb2ff; -webkit-text-fill-color: #7fb2ff; }
h1.in-jail small { color: var(--muted); -webkit-text-fill-color: currentColor; }
.jail-banner { border-color: rgba(127, 178, 255, .45); background: rgba(40, 70, 120, .25); }
.jail-banner b { color: #a9cbff; }
.jail-banner .cb-cross { background: #2f5ea8; }
.jail-banner a { color: #a9cbff; }
.jail-me { border-color: rgba(127, 178, 255, .45); background: rgba(40, 70, 120, .18); }
.jail-ways { display: flex; flex-wrap: wrap; gap: .8rem 1.4rem; margin-top: .6rem; }
.jail-ways .buyout { display: grid; gap: .25rem; justify-items: start; }
.bondsman.gone small { color: #ff8a80; }
.jail-panel .store-msg { min-height: calc(2 * 1.5em + 1.1rem + 2px); }
.break-btn { white-space: nowrap; padding: .35rem .7rem; font-size: .8rem; }
.jail-list td.small { font-size: .85rem; }
/* ---- Report a bug (report.php) ---- */
.report-panel .store-msg { min-height: calc(2 * 1.5em + 1.1rem + 2px); }
.report-form select { width: 100%; padding: .5rem .6rem; color: var(--text); font: inherit; }
.adm-alert .adm-body { white-space: pre-line; }

/* ---- Hood time clock (header) + night on the block ---- */
.hood-clock { position: relative; display: inline-flex; align-items: center; gap: .35rem; min-width: 7.2rem; justify-content: center;
  padding: .3rem .55rem; margin: 0; border: 1px solid rgba(255, 197, 61, .22); border-radius: 4px; background: rgba(0, 0, 0, .35);
  box-shadow: none; color: var(--text); font: 600 .82rem/1 "Barlow", sans-serif; letter-spacing: .02em; text-transform: none; cursor: pointer; }
.hood-clock:hover { filter: none; box-shadow: none; border-color: rgba(255, 197, 61, .5); }
.hood-clock:active { transform: none; }
.hood-clock b { font-variant-numeric: tabular-nums; font-weight: 700; color: #ffd27a; }
.hood-clock small { color: var(--muted); font-size: .68rem; }
.hood-clock svg { width: 14px; height: 14px; flex: none; }
.hood-clock .hc-sun { color: #f0b429; }
.hood-clock .hc-moon { display: none; color: #a9cbff; }
.hood-clock.night .hc-sun { display: none; }
.hood-clock.night .hc-moon { display: block; }
.hood-clock.night b { color: #cfe0ff; }
.hc-tip { display: none; position: absolute; top: calc(100% + 8px); right: 0; z-index: 60; width: 17rem; padding: .7rem .8rem; text-align: left;
  border: 1px solid rgba(255, 197, 61, .35); border-radius: 5px; background: #120e08; box-shadow: 0 10px 30px rgba(0, 0, 0, .6);
  color: var(--text); font: 400 .82rem/1.45 "Barlow", sans-serif; white-space: normal; cursor: default; }
.hc-tip b { color: var(--gold); }
.hc-tip .hc-night, .hc-tip .hc-now { display: block; margin-top: .4rem; color: #a9cbff; }
.hc-tip .hc-now { color: var(--muted); margin-top: .2rem; }
.hood-clock.open .hc-tip { display: block; }
@media (hover: hover) { .hood-clock:hover .hc-tip { display: block; } }
@media (max-width: 620px) { .hood-clock { min-width: 5.4rem; padding: .25rem .4rem; } .hood-clock small { display: none; } .hc-tip { right: auto; left: 0; width: 15rem; } }
.night-note { margin: .6rem 0 0; padding: .4rem .7rem; border: 1px solid rgba(127, 178, 255, .35); border-radius: 4px; background: rgba(40, 70, 120, .2); color: #a9cbff; font-size: .9rem; }
/* clock: beat the global gold button look; keep the tip above the ticker tape */
.top-me { position: relative; z-index: 30; }
.top-me button.hood-clock, .top-me button.hood-clock:hover { width: auto; background: rgba(0, 0, 0, .35); background-image: none; color: var(--text);
  text-transform: none; letter-spacing: .02em; box-shadow: none; filter: none; transform: none; }
.top-me button.hood-clock:hover { border-color: rgba(255, 197, 61, .5); }
.hood-clock .hc-tip, .hood-clock .hc-tip * { text-transform: none; letter-spacing: normal; font-family: "Barlow", sans-serif; }
.hood-clock .hc-tip { z-index: 200; font-weight: 400; }
.hood-clock .hc-tip b { font-weight: 700; }
@media (max-width: 620px) {
  .top-me { flex-wrap: wrap; justify-content: flex-end; row-gap: .3rem; }
  .top-me button.hood-clock { order: 3; min-width: 0; padding: .15rem .45rem; font-size: .75rem; }
  .hc-tip { left: auto; right: 0; }
}
/* clock: darker, quieter (overrides any theme button colours) */
.top-me button.hood-clock, .top-me button.hood-clock:hover, .top-me button.hood-clock:focus, .top-me button.hood-clock.open {
  background: #0c0a07 !important; background-image: none !important; box-shadow: none !important; filter: none !important;
  border: 1px solid rgba(201, 150, 43, .18) !important; color: #9a8f7c !important; }
.top-me button.hood-clock:hover, .top-me button.hood-clock.open { border-color: rgba(201, 150, 43, .38) !important; }
.top-me button.hood-clock b { color: #b8975a !important; font-weight: 600; }
.top-me button.hood-clock.night b { color: #9fb2cc !important; }
.top-me button.hood-clock .hc-sun { color: #a7802e; }
.top-me button.hood-clock .hc-moon { color: #7f97b8; }
.top-me button.hood-clock small { color: #6f6656; }
.top-me button.hood-clock, .top-me button.hood-clock * { text-shadow: none !important; -webkit-text-stroke: 0 !important; }
.top-me button.hood-clock, .top-me button.hood-clock:hover, .top-me button.hood-clock:focus, .top-me button.hood-clock.open, .top-me button.hood-clock > b, .top-me button.hood-clock > small { letter-spacing: .07em !important; }

/* ---- Picture overlays: jail bars / clinic cross (footer script wraps the img in .av-st) ---- */
.av-st { position: relative; display: inline-block; flex: none; line-height: 0; overflow: hidden; isolation: isolate; vertical-align: middle; }
.av-st > img { display: block; width: 100% !important; height: 100% !important; object-fit: cover; border-radius: inherit; }
.av-st::before, .av-st::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1; border-radius: inherit; }
.av-jail > img { filter: grayscale(.55) brightness(.62) contrast(1.1); }
.av-jail::before { background: linear-gradient(180deg, rgba(30, 45, 80, .35), rgba(5, 8, 15, .55)); }
.av-jail::after { --gap: 20%; --bar: 6.5%;
  background:
    linear-gradient(180deg, transparent 9%, #1a1c20 9%, #8f96a0 10.5%, #3a3e45 12%, #121316 13.5%, transparent 13.5%,
                            transparent 86%, #1a1c20 86%, #8f96a0 87.5%, #3a3e45 89%, #121316 90.5%, transparent 90.5%),
    repeating-linear-gradient(90deg, transparent 0 calc(var(--gap) - var(--bar)),
      #0e0f12 calc(var(--gap) - var(--bar)), #5d636c calc(var(--gap) - var(--bar) * .72), #c9ced6 calc(var(--gap) - var(--bar) * .55),
      #6b717a calc(var(--gap) - var(--bar) * .35), #0e0f12 var(--gap));
  box-shadow: inset 0 0 18px rgba(0, 0, 0, .85); }
.av-jail.sm::after { --gap: 33.4%; --bar: 11%; box-shadow: inset 0 0 6px rgba(0, 0, 0, .85); }
.av-tag { position: absolute; left: 50%; bottom: 7%; transform: translateX(-50%); z-index: 2; padding: 3px 8px; border-radius: 3px; background: #0d1522;
  border: 1px solid #5d82b8; color: #cfe0ff; font: 700 11px/1 "Barlow", sans-serif; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap; }
.av-clinic { box-shadow: 0 0 0 2px #b8261c, 0 0 16px rgba(224, 72, 62, .55); animation: avClinicPulse 1.8s ease-in-out infinite; overflow: visible; }
.av-clinic > img { filter: saturate(.6) brightness(.8); }
.av-clinic::before { background: radial-gradient(circle at 50% 45%, transparent 35%, rgba(150, 10, 10, .55) 100%), rgba(180, 20, 20, .18); }
.av-clinic::after { display: none; }
.av-cross { position: absolute; right: 7%; top: 7%; z-index: 2; width: 30%; aspect-ratio: 1; border-radius: 22%; background: #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .6), 0 0 0 2px #b8261c; line-height: 0; }
.av-cross::before, .av-cross::after { content: ""; position: absolute; background: #d7261b; border-radius: 2px; }
.av-cross::before { left: 40%; top: 16%; width: 20%; height: 68%; }
.av-cross::after { top: 40%; left: 16%; height: 20%; width: 68%; }
.av-clinic.sm .av-cross { width: 46%; right: -8%; top: -8%; border-radius: 30%; }
@keyframes avClinicPulse { 0%, 100% { box-shadow: 0 0 0 2px #b8261c, 0 0 10px rgba(224, 72, 62, .4); } 50% { box-shadow: 0 0 0 2px #e0483e, 0 0 22px rgba(224, 72, 62, .8); } }
@media (prefers-reduced-motion: reduce) { .av-clinic { animation: none; } }

/* ---- Hot block ---- */
@keyframes hotPulse { 0%, 100% { color: #ff6b5e; text-shadow: 0 0 4px rgba(255, 60, 40, .35); } 50% { color: #ff2a1a; text-shadow: 0 0 12px rgba(255, 40, 20, .85); } }
header nav a.nav-hot { color: #ff5040; animation: hotPulse 1.6s ease-in-out infinite; }
header nav a.nav-hot::after { content: " 🔥"; font-size: .8em; }
.hot-banner { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .8rem; margin: .7rem 0 0; padding: .6rem .85rem; border-radius: 5px;
  border: 1px solid rgba(255, 70, 50, .55); background: linear-gradient(90deg, rgba(160, 20, 10, .35), rgba(60, 8, 4, .35)); color: #ffd6cf; }
.hot-banner b { font: 400 1rem "Black Ops One", var(--stencil), sans-serif; letter-spacing: .08em; color: #ff4a36; animation: hotPulse 1.6s ease-in-out infinite; }
.hot-banner span { font-size: .9rem; }
.hot-banner a { color: #ffb4a8; }
.hot-banner .hot-left { margin-left: auto; font: 700 1.05rem "Barlow", sans-serif; font-variant-numeric: tabular-nums; color: #fff; }
.hot-banner.here { box-shadow: 0 0 18px rgba(255, 50, 30, .25); }
.city-hot { display: inline-block; margin-left: .35rem; padding: .05rem .4rem; border-radius: 3px; background: #b3170a; color: #fff;
  font: 700 .68rem/1.3 "Barlow", sans-serif; letter-spacing: .08em; vertical-align: middle; animation: hotPulseBg 1.6s ease-in-out infinite; }
@keyframes hotPulseBg { 0%, 100% { background: #8e1408; } 50% { background: #e0261a; } }
.street-news .sn-heat .sn-tag { background: #8e1408; color: #fff; }
.adm-hot { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; margin: .6rem 0 0; }
.adm-hot select { width: auto; padding: .35rem .5rem; color: var(--text); }
.adm-hot button { width: auto; }
@media (prefers-reduced-motion: reduce) { header nav a.nav-hot, .hot-banner b, .city-hot { animation: none; } }
