@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,600;0,9..40,700&family=Silkscreen:wght@400;700&display=swap');

/* Account / Minecraft profile */
.account-body {
  background: radial-gradient(ellipse 120% 80% at 50% -20%, rgba(34, 197, 94, 0.12), transparent 50%),
    var(--bg-dark);
}

.account-main {
  max-width: 720px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

.account-card.mc-panel,
.profile-hero.mc-panel,
.stats-panel.mc-panel,
.inv-panel.mc-panel {
  background: linear-gradient(145deg, #1a1a2e 0%, #12121c 100%);
  border: 3px solid #3d3d52;
  border-radius: 4px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 8px 24px rgba(0, 0, 0, 0.45);
  padding: 1.75rem 1.5rem;
  image-rendering: pixelated;
}

.account-title {
  font-size: 1.35rem;
  color: #ffd54f;
  text-shadow: 2px 2px 0 #3e2723;
  margin-bottom: 1rem;
  letter-spacing: 0.02em;
}

.account-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.account-form label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

.account-form input {
  background: #0d0d14;
  border: 2px solid #4a4a62;
  border-radius: 4px;
  color: var(--text);
  padding: 0.65rem 0.75rem;
  font-size: 1rem;
}

.account-form input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.25);
}

/* Password field + show/hide (eye) toggle */
.account-password-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 600;
}

.account-password-label {
  display: block;
}

.account-password-row {
  position: relative;
  width: 100%;
}

.account-password-row input {
  width: 100%;
  box-sizing: border-box;
  padding: 0.65rem 2.75rem 0.65rem 0.75rem;
  background: #0d0d14;
  border: 2px solid #4a4a62;
  border-radius: 4px;
  color: var(--text);
  font-size: 1rem;
}

.account-password-row input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(34, 197, 94, 0.25);
}

.account-password-toggle {
  position: absolute;
  right: 0.3rem;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border: none;
  border-radius: 4px;
  background: transparent;
  color: #94a3b8;
  cursor: pointer;
  line-height: 0;
}

.account-password-toggle:hover {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.06);
}

.account-password-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.account-password-toggle svg {
  display: block;
}

.hypercode-input {
  font-family: ui-monospace, monospace;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 700;
}

.btn-mc {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.25rem;
  background: linear-gradient(180deg, #5c9e4b 0%, #3d7a34 100%);
  border: 2px solid #2d5a27;
  border-radius: 4px;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.btn-mc:hover {
  filter: brightness(1.08);
}

.btn-mc-inline {
  text-decoration: none;
  margin-top: 0.5rem;
}

.account-error {
  background: rgba(185, 28, 28, 0.2);
  border: 1px solid #b91c1c;
  color: #fecaca;
  padding: 0.65rem 0.85rem;
  border-radius: 4px;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.account-form-hint {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.4;
  margin: 0 0 1rem 0;
}

.account-success {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid var(--accent-dim);
  color: #bbf7d0;
  padding: 0.65rem 0.85rem;
  border-radius: 4px;
  margin-top: 1rem;
}

.account-foot,
.link-help {
  margin-top: 1.25rem;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.link-help strong {
  color: #ffd54f;
}

.account-foot a {
  color: var(--accent);
}

/* Profile */
.profile-wrap {
  max-width: 1200px;
}

.profile-hero {
  margin-bottom: 1.5rem;
}

.profile-head {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  align-items: center;
}

.profile-avatar-wrap {
  flex-shrink: 0;
  padding: 6px;
  background: #2a2a3d;
  border: 3px solid #5c5c78;
  border-radius: 4px;
  box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.05);
}

.profile-avatar {
  display: block;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
}

.profile-kicker {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #94a3b8;
  margin-bottom: 0.35rem;
}

.profile-name {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  color: #fff;
  text-shadow: 2px 2px 0 #1e293b;
  margin-bottom: 0.35rem;
}

.profile-sub {
  color: var(--text-muted);
  font-size: 0.95rem;
  max-width: 36rem;
}

.profile-rank-line strong {
  color: #ffd54f;
  font-weight: 700;
}

.mc-stat-chip-rank .mc-stat-chip-val {
  font-weight: 700;
}

/* LiteBans — banned from Minecraft (profile alert; website login still works) */
.profile-mc-ban-banner {
  margin-bottom: 1.25rem;
  padding: 1.35rem 1.5rem;
  border-radius: 8px;
  border: 2px solid #f87171;
  background: linear-gradient(180deg, #991b1b 0%, #450a0a 100%);
  box-shadow:
    0 0 0 2px rgba(0, 0, 0, 0.45),
    0 8px 28px rgba(0, 0, 0, 0.55);
}

.profile-mc-ban-inner {
  max-width: 42rem;
}

.profile-mc-ban-title {
  font-family: 'Silkscreen', ui-monospace, monospace;
  font-size: 1.2rem;
  font-weight: 700;
  color: #fecaca;
  text-shadow: 2px 2px 0 #7f1d1d;
  margin: 0 0 0.5rem 0;
}

.profile-mc-ban-lead {
  color: #fecdd3;
  font-size: 0.92rem;
  line-height: 1.45;
  margin: 0 0 0.75rem 0;
}

.profile-mc-ban-reason,
.profile-mc-ban-duration,
.profile-mc-ban-countdown-wrap,
.profile-mc-ban-meta {
  color: #fee2e2;
  font-size: 0.92rem;
  line-height: 1.45;
  margin: 0.35rem 0 0 0;
}

.profile-mc-ban-label {
  color: #fca5a5;
  font-weight: 600;
  margin-right: 0.35em;
}

.profile-mc-ban-countdown {
  font-family: 'Silkscreen', ui-monospace, monospace;
  font-weight: 700;
  color: #fff;
}

.admin-ban-status {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0 0 0.5rem 0;
}

.stats-panel {
  margin-bottom: 1rem;
}

.stats-panel .inv-hint {
  margin-bottom: 0.5rem;
  font-size: 0.8rem;
  line-height: 1.35;
}

.inv-panel {
  margin-top: 0.5rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.inv-ender-perm-banner {
  margin: 0.75rem 0 1rem 0;
  padding: 0.85rem 1rem;
  border-radius: 8px;
  border: 1px solid rgba(196, 165, 95, 0.65);
  background: rgba(90, 70, 40, 0.35);
  font-size: 0.92rem;
  line-height: 1.45;
}

.inv-ender-perm-banner p {
  margin: 0;
}

.inv-ender-perm-banner a {
  font-weight: 600;
}

/* Profile stats — compact chips (readable UI font, not pixel font) */
.mc-stats-compact {
  font-family: 'DM Sans', ui-sans-serif, system-ui, -apple-system, sans-serif;
  font-feature-settings: 'tnum' 1;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.mc-stats-compact-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.45rem;
}

.mc-stats-claim-row {
  margin-top: 0.15rem;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(61, 68, 88, 0.65);
}

.mc-stat-chip-labeled {
  flex-direction: column;
  align-items: stretch;
  align-self: flex-start;
  gap: 0.2rem;
  min-height: auto;
  padding: 0.32rem 0.45rem 0.35rem 0.42rem;
}

.mc-stat-kicker {
  display: block;
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #64748b;
  font-weight: 700;
  line-height: 1.2;
}

.mc-stat-chip-body {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
}

.profile-claim-line {
  font-size: 0.88rem;
  color: #94a3b8;
  line-height: 1.45;
  margin-top: 0.25rem;
}

.profile-claim-line strong {
  color: #e2e8f0;
  font-weight: 700;
}

.mc-stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.28rem 0.5rem 0.28rem 0.4rem;
  background: linear-gradient(165deg, rgba(30, 41, 59, 0.75) 0%, rgba(15, 23, 42, 0.92) 100%);
  border: 1px solid #3d4458;
  border-radius: 4px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  min-height: 1.85rem;
}

.mc-stat-icon {
  flex-shrink: 0;
  font-size: 0.95rem;
  line-height: 1;
  width: 1.15rem;
  text-align: center;
  filter: drop-shadow(1px 1px 0 rgba(0, 0, 0, 0.45));
}

.mc-stat-icon-lv {
  font-family: inherit;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fde047;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.5);
  width: auto;
  min-width: 1.15rem;
  padding: 0.05rem 0;
}

.mc-stat-icon-empty {
  visibility: hidden;
  width: 1.15rem;
}

/* Gems chip: original invisible icon slot, but tighter bubble (less edge + icon gap) */
.mc-stat-chip-gems {
  flex: 0 0 auto;
  padding: 0.28rem 0.42rem 0.28rem 0.28rem;
  gap: 0.15rem;
}

.mc-stat-chip-gems .mc-stat-icon-empty {
  width: 0.45rem;
  min-width: 0.45rem;
  flex-shrink: 0;
}

.mc-stat-chip-gems .mc-stat-gems {
  color: #f59e0b;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.3);
}

.mc-stat-chip-val {
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  color: #e2e8f0;
  text-shadow: 0 1px 2px rgba(15, 23, 42, 0.85);
  white-space: nowrap;
  line-height: 1.25;
}

.mc-stat-coins {
  color: #4ade80;
}

.mc-stat-sep {
  color: #64748b;
  font-weight: 400;
  margin: 0 0.06em;
}

.mc-stat-suffix {
  font-weight: 700;
  color: #38bdf8;
  margin-left: 0.06em;
}

.stats-empty {
  color: var(--text-muted);
  font-style: italic;
  margin: 0;
}

.inv-title {
  font-size: 1.15rem;
  color: #ffd54f;
  text-shadow: 1px 1px 0 #3e2723;
  margin-bottom: 0.5rem;
}

.inv-hint {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 1rem;
}

/* Below the inventory grids so the bar grows downward and doesn’t shift the chests */
.inv-transfer-msg {
  font-size: 0.88rem;
  margin: 0.85rem 0 0 0;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
  max-width: 42rem;
  margin-inline: auto;
  text-align: center;
}

.inv-transfer-msg[hidden] {
  display: none !important;
}

.inv-transfer-msg--err {
  color: #fca5a5;
  border-color: rgba(248, 113, 113, 0.35);
}

.mc-inv-pick-active .mc-slot-interactive.mc-slot-empty {
  outline: 0.12rem dashed rgba(255, 255, 255, 0.35);
  outline-offset: -2px;
}

.mc-slot-interactive {
  cursor: pointer;
  -webkit-user-select: none;
  user-select: none;
}

.mc-slot-interactive:hover {
  filter: brightness(1.08);
}

/* Minecraft-style inventories: fixed square slots (like 18×18 px scaled), vanilla panel chrome */
:root {
  --mc-slot: 36px;
  --mc-gap: 4px;
  /* Armor column + gap + 9 main slots (matches each inventory row inner width) */
  --mc-inv-row-width: calc(10 * var(--mc-slot) + 9 * var(--mc-gap));
}

.mc-inv-twin {
  display: grid;
  grid-template-columns: repeat(2, max-content);
  gap: 1.25rem;
  align-items: stretch;
  justify-content: center;
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
}

@media (max-width: 960px) {
  .mc-inv-twin {
    grid-template-columns: 1fr;
    justify-items: center;
    width: 100%;
  }

  .mc-inv-shell-ender {
    flex: 0 1 auto;
    align-self: center;
    width: auto;
  }
}

.mc-inv-column {
  min-width: 0;
  width: max-content;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  height: 100%;
}

.mc-inv-heading {
  font-family: 'Silkscreen', ui-monospace, monospace;
  font-size: 0.95rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
  letter-spacing: 0.04em;
}

.mc-inv-heading-player {
  color: #e0e0e0;
  text-shadow: 2px 2px 0 #2a2a2a;
}

.mc-inv-heading-ender {
  color: #d8b4ff;
  text-shadow: 2px 2px 0 #3d2060;
}

/* Container panels — vanilla generic_54 / player-like gray */
.mc-inv-shell {
  --slot-bg: #8b8b8b;
  --slot-empty: #6b6b6b;
  --panel-bg-top: #c6c6c6;
  --panel-bg-bot: #6f6f6f;
  --panel-border-out: #373737;
  --panel-border-hi: #ffffff;
  --panel-border-lo: #2a2a2a;
  width: fit-content;
  max-width: 100%;
  box-sizing: border-box;
  /* Match inventory panel width (armor + 9-slot row); keeps Ender column aligned when side-by-side */
  min-width: calc(24px + var(--mc-inv-row-width));
  background: linear-gradient(180deg, var(--panel-bg-top) 0%, var(--panel-bg-bot) 100%);
  border: 4px solid var(--panel-border-out);
  border-top-color: var(--panel-border-hi);
  border-left-color: var(--panel-border-hi);
  border-right-color: var(--panel-border-lo);
  border-bottom-color: var(--panel-border-lo);
  padding: 10px 12px;
  border-radius: 0;
  overflow-x: auto;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    0 4px 12px rgba(0, 0, 0, 0.45);
}

/* Ender chest: darker purple-black panel (approx. ender UI) */
.mc-inv-shell-ender {
  --slot-bg: #2f2f2f;
  --slot-empty: #2a2a2a;
  --panel-bg-top: #4a2f5c;
  --panel-bg-bot: #1a0f22;
  --panel-border-hi: #8b6aa8;
  --panel-border-lo: #1a0b24;
  border-color: #2d1538;
  flex: 1 1 auto;
  align-self: stretch;
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.mc-inv-shell-ender--no-transfer {
  opacity: 0.72;
  filter: saturate(0.88);
}

.mc-inv-shell-ender--no-transfer .mc-slot-interactive {
  cursor: not-allowed;
}

.mc-inv-body {
  display: flex;
  flex-direction: column;
  gap: var(--mc-gap);
  width: fit-content;
  max-width: 100%;
}

.mc-inv-row {
  display: flex;
  flex-direction: row;
  gap: var(--mc-gap);
  align-items: center;
}

.mc-inv-armor {
  flex: 0 0 var(--mc-slot);
  width: var(--mc-slot);
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Empty column same width as armor (align hotbar with storage grid) */
.mc-inv-armor.mc-inv-armor-spacer {
  visibility: hidden;
  pointer-events: none;
}

/* Off-hand (left) + main hand (right), centered under the 3×9 storage block */
.mc-inv-row-hands {
  align-items: center;
}

.mc-inv-hands-track {
  width: calc(9 * var(--mc-slot) + 8 * var(--mc-gap));
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: var(--mc-slot);
}

.mc-inv-hands-pair {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: calc(var(--mc-gap) * 3);
}

.mc-inv-nine {
  display: grid;
  grid-template-columns: repeat(9, var(--mc-slot));
  gap: var(--mc-gap);
  width: fit-content;
}

/* Boots row: armor slot only — no fake storage slots (matches vanilla layout). */
.mc-inv-row-boots {
  align-items: center;
}

.mc-inv-boots-gap {
  flex: 0 0 auto;
  width: calc(9 * var(--mc-slot) + 8 * var(--mc-gap));
  min-height: var(--mc-slot);
  pointer-events: none;
}

/* Single Main hand row (upper): same bevel as other slots; sword silhouette when empty. Clicks forward to held hotbar slot in JS.
   Do not force outline:none when picked — that would override .mc-slot-picked (lower specificity) and hide the selection ring. */
.mc-slot.mc-slot-main-hand.mc-slot-main-hand-display:not(.mc-slot-picked) {
  outline: none;
  cursor: pointer;
}

.mc-slot.mc-slot-main-hand.mc-slot-main-hand-display:not(.mc-slot-empty):hover {
  filter: brightness(1.08);
}

/* Clicks forward to selected hotbar slot in JS; pointer shows it’s usable. */
.mc-slot-main-hand-display[data-mc-viz-only="1"] {
  cursor: pointer;
}

/* Vanilla-style empty-slot silhouettes (armor, off-hand, main hand) — /images/inventory-slots/*.svg */
.mc-slot[data-mc-slot-role]::before {
  content: '';
  position: absolute;
  inset: 5px;
  background: center / contain no-repeat;
  opacity: 0.48;
  pointer-events: none;
  z-index: 0;
}

.mc-slot[data-mc-slot-role="helmet"]::before {
  background-image: url('/images/inventory-slots/helmet.svg');
}

.mc-slot[data-mc-slot-role="chestplate"]::before {
  background-image: url('/images/inventory-slots/chestplate.svg');
}

.mc-slot[data-mc-slot-role="leggings"]::before {
  background-image: url('/images/inventory-slots/leggings.svg');
}

.mc-slot[data-mc-slot-role="boots"]::before {
  background-image: url('/images/inventory-slots/boots.svg');
}

.mc-slot[data-mc-slot-role="offhand"]::before {
  background-image: url('/images/inventory-slots/shield.svg');
}

.mc-slot[data-mc-slot-role="mainhand"]::before {
  background-image: url('/images/inventory-slots/sword.svg');
}

.mc-slot[data-mc-slot-role] .mc-item-img {
  position: relative;
  z-index: 1;
}

/* After generic role ::before (sword) — hide silhouette when the main-hand cell holds an item. */
.mc-slot.mc-slot-main-hand-display:not(.mc-slot-empty)[data-mc-slot-role]::before {
  opacity: 0;
  visibility: hidden;
}

.mc-inv-tline-slotrole {
  color: #a3e635;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.mc-inv-row-hotbar {
  margin-top: 6px;
  padding-top: 8px;
  border-top: 3px solid rgba(0, 0, 0, 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Ender chest: 3×9 only — centered within panel (same width as inventory shell) */
.mc-inv-ec-body {
  display: flex;
  flex-direction: column;
  gap: var(--mc-gap);
  width: fit-content;
  max-width: 100%;
  margin-inline: auto;
}

.mc-inv-ec-row {
  display: grid;
  grid-template-columns: repeat(9, var(--mc-slot));
  gap: var(--mc-gap);
}

/* Square slot — Minecraft uses ~18px outer with 16px inner; we lock 36×36 */
.mc-slot {
  position: relative;
  box-sizing: border-box;
  width: var(--mc-slot);
  height: var(--mc-slot);
  min-width: var(--mc-slot);
  min-height: var(--mc-slot);
  flex-shrink: 0;
  background: var(--slot-bg);
  border: 2px solid var(--panel-border-out);
  border-top-color: var(--panel-border-hi);
  border-left-color: var(--panel-border-hi);
  border-right-color: var(--panel-border-lo);
  border-bottom-color: var(--panel-border-lo);
  box-shadow:
    inset 2px 2px 0 rgba(255, 255, 255, 0.22),
    inset -2px -2px 0 rgba(0, 0, 0, 0.28);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Must follow .mc-slot so these box-shadow layers are not overwritten. Inset ring stays visible with overflow:hidden. */
.mc-slot.mc-slot-picked {
  outline: none;
  box-shadow:
    inset 0 0 0 2px #7dd3fc,
    inset 2px 2px 0 rgba(255, 255, 255, 0.22),
    inset -2px -2px 0 rgba(0, 0, 0, 0.28);
}

.mc-inv-shell-ender .mc-slot {
  border-color: #1f1f1f;
  border-top-color: #5c4a66;
  border-left-color: #5c4a66;
  border-right-color: #0d0d0d;
  border-bottom-color: #0d0d0d;
}

.mc-slot-empty {
  background: var(--slot-empty);
  opacity: 0.95;
}

.mc-item-img {
  width: 24px;
  height: 24px;
  max-width: 24px;
  max-height: 24px;
  object-fit: contain;
  image-rendering: pixelated;
  image-rendering: crisp-edges;
  filter: drop-shadow(1px 1px 0 rgba(0, 0, 0, 0.45));
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

/* In-game–style item tooltip (§ colors from HyperCode tooltip_legacy JSON) */
.mc-inv-floating-tooltip {
  position: fixed;
  z-index: 10050;
  max-width: min(280px, calc(100vw - 16px));
  padding: 6px 8px;
  font-family: 'Silkscreen', ui-monospace, monospace;
  font-size: 0.72rem;
  line-height: 1.35;
  color: #fff;
  background: linear-gradient(180deg, #100010 0%, #0a000a 100%);
  border: 2px solid #500050;
  border-top-color: #a060a0;
  border-left-color: #a060a0;
  border-right-color: #280028;
  border-bottom-color: #280028;
  box-shadow:
    inset 1px 1px 0 rgba(255, 255, 255, 0.12),
    0 4px 14px rgba(0, 0, 0, 0.55);
  pointer-events: none;
}

.mc-inv-floating-tooltip .mc-inv-tline {
  min-height: 0.95em;
}

.mc-inv-floating-tooltip .mc-inv-tline + .mc-inv-tline {
  margin-top: 1px;
}

.mc-slot-count {
  position: absolute;
  bottom: 2px;
  right: 3px;
  font-family: 'Silkscreen', ui-monospace, monospace;
  font-size: 0.65rem;
  font-weight: 700;
  color: #fff;
  text-shadow:
    1px 1px 0 #000,
    -1px -1px 0 #3f3f3f;
  line-height: 1;
  pointer-events: none;
}

/* Clicks must hit the slot div, not the child image (fixes missed clicks) */
.mc-slot .mc-item-img {
  pointer-events: none;
}

.mc-slot-offhand {
  box-shadow:
    inset 2px 2px 0 rgba(255, 255, 255, 0.28),
    inset -2px -2px 0 rgba(0, 0, 0, 0.3),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}

.inv-empty {
  color: var(--text-muted);
  font-style: italic;
}

.profile-foot {
  margin-top: 1.5rem;
}

.profile-foot a {
  color: var(--accent);
}

@media (max-width: 540px) {
  .profile-head {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* ——— Management / admin ——— */
.admin-body .account-main.admin-main {
  max-width: 1200px;
}

.admin-hero {
  margin-bottom: 1rem;
}

.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.admin-tile {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: filter 0.15s ease;
}

.admin-tile:hover {
  filter: brightness(1.06);
}

.admin-tile-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
}

.admin-tile-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: #ffd54f;
  font-family: 'Silkscreen', ui-monospace, monospace;
}

.admin-tile-static {
  cursor: default;
}

.admin-panel-hint {
  margin-top: 0.5rem;
}

.admin-table-wrap {
  overflow: hidden;
}

.admin-table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.admin-table th,
.admin-table td {
  padding: 0.5rem 0.65rem;
  text-align: left;
  border-bottom: 1px solid #3d3d52;
}

.admin-table th {
  color: #94a3b8;
  font-weight: 600;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.admin-table-row {
  cursor: pointer;
}

.admin-table-row:hover {
  background: rgba(34, 197, 94, 0.08);
}

.admin-td-face {
  width: 48px;
}

.admin-face {
  border-radius: 4px;
  border: 2px solid #5c5c78;
  image-rendering: pixelated;
}

.admin-badge {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
}

.admin-badge-on {
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
}

.admin-badge-off {
  background: rgba(185, 28, 28, 0.25);
  color: #fecaca;
}

.admin-back {
  margin-bottom: 0.75rem;
}

.admin-back a {
  color: var(--accent);
}

.admin-user-hero {
  margin-bottom: 1rem;
}

.admin-actions {
  margin-bottom: 1.25rem;
}

.admin-action-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: flex-end;
  margin-bottom: 0.75rem;
}

.admin-inline-form {
  display: inline;
}

.admin-ban-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: flex-end;
  width: 100%;
}

.admin-ban-label {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.admin-ban-input {
  background: #0d0d14;
  border: 2px solid #4a4a62;
  border-radius: 4px;
  color: var(--text);
  padding: 0.45rem 0.6rem;
  min-width: 12rem;
}

.admin-role-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: flex-end;
}

.admin-select {
  background: #0d0d14;
  border: 2px solid #4a4a62;
  border-radius: 4px;
  color: var(--text);
  padding: 0.45rem 0.6rem;
}

.admin-presence {
  margin-bottom: 1.25rem;
}

.admin-location-line {
  font-size: 1rem;
  color: var(--text);
  margin: 0.5rem 0 0 0;
}

.admin-reset-link a {
  word-break: break-all;
  color: #86efac;
}

.btn-mc-danger {
  background: linear-gradient(180deg, #b91c1c 0%, #7f1d1d 100%);
  border-color: #450a0a;
}

.btn-mc-secondary {
  background: linear-gradient(180deg, #52525b 0%, #3f3f46 100%);
  border-color: #27272a;
}

.admin-log-filter {
  margin-bottom: 1rem;
}

.admin-log-filter select {
  background: #0d0d14;
  border: 2px solid #4a4a62;
  color: var(--text);
  padding: 0.4rem 0.6rem;
  border-radius: 4px;
}

.admin-table-compact td {
  font-size: 0.82rem;
}

.admin-meta code {
  font-size: 0.7rem;
  word-break: break-all;
  color: #cbd5e1;
}

.admin-role-create {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 28rem;
}

.admin-role-create input[type='text'] {
  background: #0d0d14;
  border: 2px solid #4a4a62;
  border-radius: 4px;
  color: var(--text);
  padding: 0.5rem 0.65rem;
}

.admin-checks {
  border: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.admin-checks label {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Admin layout: sidebar + content */
.admin-layout {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1rem 3rem;
  gap: 0;
  box-sizing: border-box;
}

.admin-sidebar {
  flex: 0 0 14.5rem;
  position: sticky;
  top: 0.75rem;
  align-self: flex-start;
  padding: 1rem 0 2rem;
}

.admin-sidebar-inner {
  background: linear-gradient(145deg, #16162a 0%, #0f0f18 100%);
  border: 2px solid #3d3d52;
  border-radius: 4px;
  padding: 1rem 0.85rem 1.1rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.admin-sidebar-kicker {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #64748b;
  margin: 0 0 0.75rem 0;
  padding: 0 0.35rem;
}

.admin-sidebar-group {
  margin-bottom: 1.1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(61, 61, 82, 0.6);
}

.admin-sidebar-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.admin-sidebar-group-foot {
  padding-top: 0.25rem;
}

.admin-sidebar-heading {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #94a3b8;
  margin: 0 0 0.4rem 0;
  padding: 0 0.35rem;
}

.admin-sidebar-link {
  display: block;
  padding: 0.4rem 0.5rem;
  margin: 0.1rem 0;
  border-radius: 4px;
  color: #e2e8f0;
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  border-left: 3px solid transparent;
}

.admin-sidebar-link:hover {
  background: rgba(34, 197, 94, 0.1);
  color: #fff;
}

.admin-sidebar-link.is-active {
  background: rgba(34, 197, 94, 0.15);
  border-left-color: var(--accent);
  color: #bbf7d0;
}

.admin-sidebar-subnav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  margin: 0.35rem 0 0.5rem 0;
  padding-left: 0.35rem;
  border-left: 2px solid rgba(61, 61, 82, 0.8);
}

.admin-sidebar-sublink {
  font-size: 0.8rem;
  color: #94a3b8;
  text-decoration: none;
  padding: 0.2rem 0.35rem;
  border-radius: 3px;
}

.admin-sidebar-sublink:hover {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.04);
}

.admin-sidebar-note {
  font-size: 0.75rem;
  line-height: 1.45;
  color: #64748b;
  margin: 0.35rem 0 0 0;
  padding: 0 0.35rem;
}

/* Exclusive accordion: <details name="survival-plugins"> — one open at a time in supporting browsers */
.admin-sidebar-disclosure {
  border: 1px solid rgba(61, 61, 82, 0.55);
  border-radius: 4px;
  margin: 0.4rem 0;
  background: rgba(0, 0, 0, 0.15);
}

.admin-sidebar-disclosure-summary {
  list-style: none;
  cursor: pointer;
  padding: 0.45rem 0.5rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: #e2e8f0;
  user-select: none;
}

.admin-sidebar-disclosure-summary::-webkit-details-marker {
  display: none;
}

.admin-sidebar-disclosure-summary::before {
  content: '';
  display: inline-block;
  width: 0.35em;
  margin-right: 0.45em;
  border: solid #94a3b8;
  border-width: 0 2px 2px 0;
  padding: 0.2em;
  transform: rotate(-45deg);
  vertical-align: middle;
  transition: transform 0.15s ease;
}

.admin-sidebar-disclosure[open] .admin-sidebar-disclosure-summary::before {
  transform: rotate(45deg);
  margin-top: -0.1em;
}

.admin-sidebar-disclosure-body {
  padding: 0 0.35rem 0.65rem 0.35rem;
}

.admin-sidebar-disclosure-body .admin-sidebar-link {
  margin-left: 0;
}

.admin-cp-opt {
  font-weight: 400;
  color: #64748b;
  font-size: 0.85em;
}

.admin-bank-ref-table-wrap {
  overflow-x: auto;
  margin-top: 0.5rem;
}

.admin-bank-ref-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  color: #cbd5e1;
}

.admin-bank-ref-table th,
.admin-bank-ref-table td {
  border: 1px solid rgba(61, 61, 82, 0.7);
  padding: 0.4rem 0.5rem;
  text-align: left;
  vertical-align: top;
}

.admin-bank-ref-table th {
  background: rgba(34, 197, 94, 0.08);
  color: #e2e8f0;
  font-weight: 600;
}

.admin-bank-ref-table code {
  font-size: 0.88em;
  color: #86efac;
}

/* BankPlus admin: collapsible command reference (collapsed by default) */
.admin-bank-ref-details {
  border: 1px solid rgba(61, 61, 82, 0.55);
  border-radius: 4px;
  padding: 0.5rem 0.65rem 0.75rem;
  background: rgba(0, 0, 0, 0.12);
}

.admin-bank-ref-summary {
  list-style: none;
  cursor: pointer;
  padding: 0.35rem 0.25rem;
  user-select: none;
}

.admin-bank-ref-summary::-webkit-details-marker {
  display: none;
}

.admin-bank-ref-summary::before {
  content: '';
  display: inline-block;
  width: 0.35em;
  margin-right: 0.5em;
  border: solid #94a3b8;
  border-width: 0 2px 2px 0;
  padding: 0.2em;
  transform: rotate(-45deg);
  vertical-align: middle;
  transition: transform 0.15s ease;
}

.admin-bank-ref-details[open] .admin-bank-ref-summary::before {
  transform: rotate(45deg);
  margin-top: -0.08em;
}

.admin-bank-ref-summary-title {
  display: block;
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffd54f;
  text-shadow: 1px 1px 0 #3e2723;
  letter-spacing: 0.02em;
}

.admin-bank-ref-summary-hint {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: #64748b;
  margin-top: 0.2rem;
  padding-left: 1.15rem;
}

.admin-bank-ref-lead {
  margin: 0.75rem 0 0.5rem 0;
}

.admin-bank-ref-foot {
  margin-top: 0.75rem;
  margin-bottom: 0;
}

.admin-lp-group-form {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
}

.admin-role-lp-cell {
  vertical-align: middle;
  min-width: 12rem;
}

.admin-lp-group-input {
  max-width: 11rem;
  flex: 1 1 7rem;
}

.admin-content {
  flex: 1;
  min-width: 0;
}

.admin-body .admin-content .account-main.admin-main {
  max-width: none;
  margin: 0;
  padding: 1.5rem 0 3rem 1.25rem;
}

.admin-user-cp-link a {
  color: var(--accent);
  font-weight: 600;
}

.admin-cp-status {
  margin-bottom: 1rem;
}

.admin-cp-line {
  margin: 0.35rem 0 0 0;
  color: var(--text);
}

.admin-cp-sample {
  margin: 0.65rem 0 0 0;
  font-size: 0.9rem;
  color: #cbd5e1;
}

.admin-cp-block {
  margin-bottom: 1.25rem;
}

.admin-cp-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: flex-end;
  margin-top: 0.75rem;
}

.admin-cp-label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  color: var(--text-muted);
  font-size: 0.88rem;
  font-weight: 600;
}

@media (max-width: 900px) {
  .admin-layout {
    flex-direction: column;
    padding: 0 0.75rem 2rem;
  }

  .admin-sidebar {
    flex: none;
    width: 100%;
    position: static;
    padding: 0.5rem 0 0;
  }

  .admin-body .admin-content .account-main.admin-main {
    padding: 1rem 0 2rem 0;
  }
}

/* Player account area: sidebar + main (matches management layout) */
.player-body .admin-content .account-main.player-area-main {
  max-width: none;
  margin: 0;
  padding: 1.5rem 0 3rem 1.25rem;
}

.player-page-hero {
  margin-bottom: 1.25rem;
}

.player-page-hero .account-title {
  margin-bottom: 0.35rem;
}

.player-link-card {
  max-width: 42rem;
}

@media (max-width: 900px) {
  .player-body .admin-content .account-main.player-area-main {
    padding: 1rem 0 2rem 0;
  }
}

/* Staff-only hold grid (admin user profile) */
.admin-confiscate-bulk-wrap {
  margin-top: 0.75rem;
}

.admin-confiscate-bulk-wrap .btn-mc {
  width: 100%;
  max-width: 16rem;
}

.staff-confiscation-panel {
  margin-top: 1.5rem;
}

.staff-confiscation-grid {
  display: grid;
  grid-template-columns: repeat(5, var(--mc-slot, 36px));
  gap: var(--mc-gap, 4px);
  justify-content: flex-start;
  margin-top: 0.75rem;
}

.staff-confiscation-grid .mc-slot {
  width: var(--mc-slot, 36px);
  height: var(--mc-slot, 36px);
}

.mc-slot-picked-confiscate {
  outline: 2px solid var(--accent, #6cf);
  outline-offset: 1px;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.35);
}

.staff-confiscation-msg--err {
  color: #f88;
}

/* UltimateRewards claim list */
.rewards-claim-panel .rewards-claim-list {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.rewards-claim-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 1rem 1.1rem;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid #3d3d52;
  border-radius: 4px;
}

.rewards-claim-meta {
  flex: 1;
  min-width: 12rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.rewards-claim-title {
  font-weight: 700;
  color: #e2e8f0;
  font-size: 1.05rem;
}

.rewards-claim-sub {
  font-size: 0.82rem;
  color: #94a3b8;
  line-height: 1.4;
}

.rewards-claim-form {
  margin: 0;
}

/* UltimateRewards — compact grouped table */
.rewards-compact-panel {
  max-width: 100%;
}

.rewards-compact-title {
  margin: 0 0 0.35rem;
  font-size: 1.15rem;
}

.rewards-compact-lead {
  margin: 0 0 0.75rem;
  font-size: 0.78rem;
  line-height: 1.35;
  color: #94a3b8;
}

.rewards-compact-meta {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  color: #94a3b8;
}

.rewards-compact-cat {
  margin: 0.85rem 0 0.2rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent, #6cf);
}

.rewards-compact-cat:first-of-type {
  margin-top: 0.25rem;
}

.rewards-compact-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
  line-height: 1.25;
}

.rewards-compact-table th,
.rewards-compact-table td {
  padding: 0.28rem 0.4rem;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid #3d3d52;
}

.rewards-compact-table thead th {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
  border-bottom-color: #4a4a62;
}

.rewards-compact-col-action {
  width: 4.5rem;
  text-align: right;
}

.rewards-compact-td-id code {
  font-size: 0.72rem;
  color: #cbd5e1;
}

.rewards-compact-td-status {
  color: #cbd5e1;
}

.rewards-compact-perm {
  font-size: 0.68rem;
  color: #64748b;
}

.rewards-compact-tr--ready .rewards-compact-td-status {
  color: #86efac;
}

.rewards-compact-tr--claimed .rewards-compact-td-status,
.rewards-compact-tr--cooldown .rewards-compact-td-status {
  color: #94a3b8;
}

.rewards-compact-tr--progress .rewards-compact-td-status {
  color: #fcd34d;
}

.rewards-compact-form {
  margin: 0;
  display: inline;
}

.rewards-compact-noaction {
  color: #475569;
  font-size: 0.75rem;
}

.btn-mc-compact {
  padding: 0.22rem 0.5rem;
  font-size: 0.72rem;
  line-height: 1.2;
}
