:root {
  --dojo-base: #091322;
  --dojo-surface: #111f33;
  --dojo-raised: #172a45;
  --dojo-line: #3b5376;
  --dojo-copy: #bed0ea;
  --dojo-blue: #88c8ff;
  --dojo-gold: #ffda63;
  --dojo-display: "Noto Sans HK", "Microsoft JhengHei", sans-serif;
}

body { background-color: var(--dojo-base); font-family: var(--dojo-display); }
::selection { background: var(--dojo-gold); color: var(--dojo-base); }
:is(a, button, input, select, textarea, summary):focus-visible {
  outline: 2px solid var(--dojo-blue);
  outline-offset: 4px;
}

.page {
  width: min(100%, 1180px);
  padding: clamp(24px, 5vw, 56px) clamp(16px, 4vw, 44px) 72px;
}
.page h1 {
  font-size: clamp(1.9rem, 5vw, 3.55rem);
  line-height: 1.14;
  letter-spacing: -.025em;
  overflow-wrap: anywhere;
}
.page h2 { font-size: clamp(1.25rem, 3vw, 1.9rem); line-height: 1.3; }
.page :is(h2, h3) { text-wrap: balance; }
.page .muted { color: var(--dojo-copy); }
.page :is(.card, .admin-settings, .registration-countdown) {
  background: var(--dojo-surface);
  border: 1px solid var(--dojo-line);
  border-radius: 6px;
  box-shadow: none;
}
.page .card { padding: clamp(14px, 2.6vw, 24px); }
.page .card .card { background: var(--dojo-base); }
.page a { text-underline-offset: .24em; }
.page :is(button, .button, summary),
.admin-shortcuts button { min-height: 44px; }
.page summary { align-content: center; }
.page :is(input:not([type=checkbox],[type=radio]), select, textarea) {
  color: #f3f7ff;
  background: var(--dojo-base);
  border-color: var(--dojo-line);
  caret-color: var(--dojo-gold);
}
.page :is(.gold, .score-save, .score-panel form[data-comp="score"] > button) {
  background: var(--dojo-gold);
  border-color: var(--dojo-gold);
  color: var(--dojo-base);
  font-weight: 800;
}
.page :is(.gold, .score-save):hover { background: #ffe896; }
.page button:disabled { opacity: .55; cursor: not-allowed; }
.page .event-apply { width: min(100%, 31rem); }
.page .event-apply :is(a, button) { min-height: 52px; }
.page .event-back { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.page .event-back a { padding-block: 10px; }
.page .player-card { align-items: center; overflow-wrap: anywhere; }
.page .album-card { min-width: 0; overflow-wrap: anywhere; }
.page .album-card img { max-width: 100%; height: auto; }
.page .admin-settings { padding: 0 clamp(10px, 2vw, 18px); margin-block: 10px; }
.admin-shortcuts button { text-wrap: balance; }
.score-match .match-versus strong { min-width: 0; overflow-wrap: anywhere; }
.score-match .match-score { font-variant-numeric: tabular-nums; }
.score-match .points button { min-height: 44px; }
.score-match .editor > summary { background: var(--dojo-raised); }
.tournament-home .race-opens {
  margin: 0 0 10px;
  color: var(--dojo-blue);
  font-weight: 700;
}
.tournament-home .race-result h3 { overflow-wrap: anywhere; }

@media (max-width: 560px) {
  .page .admin-shortcuts { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .page .admin-shortcuts button { padding-inline: 8px; }
  .page .form :is(input:not([type=checkbox],[type=radio]),select,textarea) { font-size: 1rem; }
  .score-match .points { gap: 4px; }
  .score-match .score-panel { padding-top: 10px; }
}
.forest-home {
  --forest: #0b1628;
  --paper: #eef5ff;
  --gold: #ffda63;
  background: var(--paper);
  color: var(--paper);
}
body:has(.forest-home) > :is(.dojo-header, footer, .mobile-nav) {
  background: #0b1628;
  border-color: #355980;
}
.forest-wrap { width: min(100% - 36px, 1100px); margin-inline: auto; }
.forest-hero {
  padding-block: clamp(54px, 10vw, 142px) clamp(46px, 8vw, 100px);
  border-bottom: 1px solid #304565;
}
.forest-hero h1 {
  margin: 0 0 clamp(24px, 4vw, 44px);
  font-size: clamp(3rem, 9vw, 6rem);
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1.12;
}
.forest-hero h1 span { display: block; }
.forest-hero h1 span + span { color: #99caff; }
.forest-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.forest-actions a {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  padding: 9px 14px;
  border: 1px solid #5676a3;
  color: var(--paper);
  font-weight: 800;
  text-decoration: none;
}
.forest-actions .forest-primary { background: var(--gold); border-color: var(--gold); color: var(--forest); }
.forest-actions a:hover { background: #233e65; color: var(--paper); }
.forest-actions .forest-primary:hover { background: #ffe896; color: var(--forest); }
.forest-home :focus-visible { outline-color: #88c8ff; }
.forest-content { padding-bottom: clamp(40px, 8vw, 90px); }
.forest-content section { padding-block: clamp(26px, 5vw, 58px); scroll-margin-top: 100px; }
.forest-content section + section { border-top: 1px solid #304565; }
.forest-content h2 { margin: 0 0 10px; font-size: clamp(1.45rem, 4vw, 2.35rem); color: var(--paper); }
.forest-content p { color: #bed0ea; max-width: 50ch; line-height: 1.75; }
.forest-content a { color: var(--paper); font-weight: 800; display: inline-flex; align-items: center; min-height: 44px; }
.forest-recent article { background: #172a45; padding: clamp(16px, 3vw, 28px); margin-bottom: 10px; }
.forest-recent h3 { margin: .3em 0; color: var(--paper); overflow-wrap: anywhere; }
.forest-recent ol { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.forest-recent li { border-top: 1px solid #3b5376; padding-top: 6px; overflow-wrap: anywhere; }
.forest-recent li small { display: block; color: #99caff; }
@media (min-width: 720px) {
  .forest-content { display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; }
  .forest-content section:nth-child(2) { border-top: 0; }
  .forest-recent { grid-column: 1 / -1; }
  .forest-recent ol { grid-template-columns: repeat(4,minmax(0,1fr)); }
}
.arena-home.tournament-home {
  background-color:#060b1a;
  background-image:radial-gradient(ellipse at 20% 5%,#13395470,transparent 45%),linear-gradient(#38bdf80a 1px,transparent 1px),linear-gradient(90deg,#38bdf80a 1px,transparent 1px);
  background-size:auto,44px 44px,44px 44px;
  padding:clamp(24px,5vw,72px) max(18px,calc((100vw - 1160px)/2));
}
.arena-hero {display:grid;align-items:center;gap:28px;margin-bottom:clamp(28px,5vw,60px)}
.arena-hero h1 {font-size:clamp(2.8rem,6vw,5.4rem);line-height:1.12;margin:0;color:#fff;font-weight:900;font-style:italic}
.arena-hero h1 em {color:#facc15}
.arena-hero p {color:#cbd8e9;max-width:37ch;line-height:1.7}
.arena-actions {display:flex;flex-wrap:wrap;gap:9px}
.arena-actions a {display:inline-flex;align-items:center;padding:10px 16px;min-height:44px;background:#facc15;color:#071123;font-weight:800;clip-path:polygon(8px 0,100% 0,100% calc(100% - 8px),calc(100% - 8px) 100%,0 100%,0 8px)}
.arena-actions a+a {background:#103b36;color:#a2f4d7}
.arena-hero .stage-art {width:100%;min-width:0;margin:0}
.arena-hero .stage-slides {position:relative;aspect-ratio:2048/683;background:#081224}
.arena-hero .stage-slides > :not([hidden]) {position:absolute;inset:0;display:block}
.arena-hero .stage-slides img {display:block;width:100%;height:100%;object-fit:contain}
.arena-home .tournament-section {background:#0d1630;border:1px solid #284564;padding:clamp(14px,2.5vw,30px);margin-bottom:18px;min-width:0}
.arena-home .tournament-wrap {width:100%;max-width:none;padding:0}
.arena-home .tournament-heading h2 {font-size:clamp(1.5rem,3vw,2.4rem)}
.arena-home .tournament-heading h2:after {display:none}
.arena-home .tournament-heading p {display:none}
.arena-home .race-ranking li:first-child {background:#322d22}
@media(min-width:900px){
  .arena-hero {grid-template-columns:5fr 7fr}
  .arena-pair {display:grid;grid-template-columns:minmax(0,7fr) minmax(0,5fr);gap:18px}
  .arena-pair .race-events,.arena-pair .race-ranking {grid-template-columns:1fr}
}
.dojo-header {background:#080e1c;border-bottom:1px solid #20425a}
.core-links {display:none}
@media(min-width:768px){.core-links{display:flex;align-items:center;gap:clamp(10px,2vw,30px);margin-inline:auto}.core-links a{font-weight:700;color:#dae3ef;text-decoration:none;padding-block:12px}.core-links a:hover{color:#facc15}}
.dojo-header .nav-toggle:not([hidden]),.dojo-header #login {border-radius:0;clip-path:polygon(7px 0,100% 0,100% calc(100% - 7px),calc(100% - 7px) 100%,0 100%,0 7px)}
.dojo-header .nav-toggle:not([hidden]){background:#101c2d;color:#bde7ff;border:1px solid #335978}
.dojo-header svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linejoin:round;stroke-linecap:round}
.dojo-header .chevron{width:12px}.nav-toggle[aria-expanded=true] .chevron{transform:rotate(180deg)}
.dojo-header #login{display:inline-flex;align-items:center;gap:7px;background:#facc15;color:#091121;border-color:#facc15;font-weight:800}
.dojo-header #login:before{content:"";width:16px;height:16px;background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Ccircle cx='12' cy='7' r='4'/%3E%3Cpath d='M4 21v-2a8 6 0 0 1 16 0v2'/%3E%3C/svg%3E") center/contain}
.dojo-header #dojo-nav{grid-template-columns:repeat(3,minmax(0,1fr));width:min(360px,calc(100vw - 24px));background:#0d162a;border-color:#254760;max-height:75vh;overflow:auto}
.dojo-header #dojo-nav a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:5px;text-align:center;background:#111f34;border:1px solid #293e57;font-size:.85rem;color:#e8f0fa}
.dojo-header #dojo-nav a[hidden]{display:none}
@media(min-width:768px){.dojo-header #dojo-nav a.core-link-mobile{display:none}}
.dojo-header #dojo-nav a:hover{background:#19334d}
#dojo-nav a svg{color:#67cfff}#dojo-nav a:nth-of-type(odd) svg{color:#facc15}
.menu-caption{grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;color:#83cfff;font-size:.8rem;font-weight:700}
.menu-caption button{color:#d1dfef;background:transparent;border:0;font-size:1.3rem}
.arena-home h2[id]{scroll-margin-top:100px}


/* === Direction A Full-Site UI Polish & Structural Fixes === */
.dojo-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(8, 14, 28, 0.92);
  backdrop-filter: blur(12px);
}
.core-links a[aria-current="page"] {
  color: #facc15;
  position: relative;
}
.core-links a[aria-current="page"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 2px;
  background: #facc15;
}

/* Opening animation Skip button */
.opening-skip {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 105;
  min-height: 44px;
  padding: 8px 16px;
  background: rgba(13, 22, 48, 0.92);
  color: #f8fafc;
  border: 1px solid #38bdf8;
  font-weight: 800;
  font-size: 0.9rem;
  clip-path: polygon(7px 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%, 0 7px);
}
.opening-skip:hover {
  background: #facc15;
  color: #060b1a;
  border-color: #facc15;
}
.opening-hint {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 105;
  margin: 0;
  font-size: 0.85rem;
  color: #cbd5e1;
  background: rgba(6, 11, 26, 0.78);
  padding: 6px 14px;
  border-radius: 999px;
}

/* Hero Eyebrow & Carousel Controls */
.arena-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.12);
  border: 1px solid rgba(56, 189, 248, 0.35);
  color: #7dd3fc;
  font-size: 0.8rem;
  font-weight: 700;
}
.arena-hero .stage-art {
  border: 1px solid #284564;
  background: #0d1630;
  overflow: hidden;
}
.arena-hero .stage-slides img {
  object-fit: contain;
}
.stage-carousel-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 14px;
  background: #0a1228;
  border-top: 1px solid #23415f;
}
.stage-dots {
  display: flex;
  align-items: center;
  gap: 8px;
}
.stage-dot {
  width: 9px;
  height: 9px;
  min-height: 0;
  padding: 0;
  border-radius: 999px;
  border: 0;
  background: #3d567a;
  transition: width 0.2s, background 0.2s;
}
.stage-dot.is-active {
  width: 24px;
  background: #facc15;
}
.stage-arrows {
  display: flex;
  align-items: center;
  gap: 8px;
}
.stage-counter {
  font-family: "Barlow Condensed", monospace;
  font-size: 0.9rem;
  color: #8bc7ff;
  letter-spacing: 0.06em;
}
.stage-arrows button {
  min-height: 34px;
  width: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #132342;
  border: 1px solid #355780;
  color: #f8fafc;
  font-size: 1.2rem;
  line-height: 1;
}
.stage-arrows button:hover {
  background: #facc15;
  color: #060b1a;
  border-color: #facc15;
}

/* Home Empty State Actions */
.race-empty-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-top: 10px;
}
.race-empty-cta {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 14px;
  background: #facc15;
  color: #060b1a !important;
  text-decoration: none !important;
  font-weight: 800;
  clip-path: polygon(7px 0, 100% 0, 100% calc(100% - 7px), calc(100% - 7px) 100%, 0 100%, 0 7px);
}
.race-empty-cta:hover {
  background: #fde047;
}
.empty-hero-box {
  padding: 28px;
  background: #0d1630;
  border: 1px solid #2b4a70;
  border-left: 4px solid #facc15;
  border-radius: 6px;
}
.empty-hero-box strong {
  display: block;
  font-size: 1.25rem;
  margin-bottom: 6px;
  color: #fff;
}

/* Uniform Album Covers & Event Card Posters */
.album-card img,
.tournament-gallery .album-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  height: auto;
  object-fit: contain;
  object-position: center;
  background: #071124;
}
.album-placeholder {
  aspect-ratio: 16 / 10;
  min-height: 0;
}
.event-grid-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.event-grid-card h2 {
  word-break: keep-all;
  overflow-wrap: break-word;
  text-wrap: balance;
}
.event-card-cta {
  margin-top: auto;
  align-self: flex-start;
}
.event-card-poster-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  background: #071124;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.event-card-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 2;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 0.74rem;
  font-weight: 800;
  color: #f8fafc;
  background: rgba(7, 17, 36, 0.88);
  border: 1px solid #35547a;
}
.event-card-poster-compact {
  aspect-ratio: 16 / 5;
}
.event-card-poster-wrap .event-card-poster {
  width: 100%;
  height: 100%;
  max-height: none;
  margin: 0;
  object-fit: contain;
  object-position: center;
  border-radius: 0;
}
.event-card-poster-fallback {
  flex-direction: column;
  gap: 8px;
  background: radial-gradient(circle at 50% 30%, #17305c, #081326);
  border: 1px dashed #2e4c73;
}
.event-card-poster-fallback img {
  width: min(140px, 55%);
  height: auto;
  opacity: 0.78;
}

/* Dark-Integrated Beyblade Part Slots */
.deck-part-picture,
.race-deck-list .deck-part-picture {
  background: #091326;
  border: 1px solid #2b4a70;
  border-radius: 8px;
  padding: 6px;
}

/* Players Directory Search Toolbar & Single-Line Name Truncation */
.players-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px 16px;
  margin: 0 0 20px;
  padding: 16px;
  background: #0e1b35;
  border: 1px solid #2b4a70;
  border-radius: 6px;
}
.players-search-label {
  flex: 1 1 240px;
}
.players-count {
  margin: 0;
  align-self: center;
  font-size: 0.88rem;
  white-space: nowrap;
}
.player-rank-num {
  font: 700 1.45rem/1 "Barlow Condensed", "Noto Sans HK", sans-serif;
  color: #ffd05e;
  min-width: 1.8em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  flex: none;
}
.player-card-body {
  min-width: 0;
  flex: 1;
}
.player-card-body h2 {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  margin: 0 0 4px;
}
.player-card-body h2 a {
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  font-size: clamp(0.96rem, 2.5vw, 1.12rem);
  line-height: 1.25;
}
.player-card-meta {
  margin: 0;
  color: #b8cae4;
  font-size: 0.85rem;
}
.player-wins-big {
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1;
  padding-left: 8px;
  flex: none;
}
.player-wins-big b {
  font: 800 1.75rem/1 "Barlow Condensed", sans-serif;
  color: #ffd05e;
  font-variant-numeric: tabular-nums;
}
.player-wins-big small {
  font-size: 0.72rem;
  color: #cbd5e1;
  margin-top: 2px;
}
.avatar-preview span,
.rank-avatar span {
  font-weight: 900;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.45);
}
.player-id-tag {
  font-size: 0.72rem;
  font-weight: 700;
  color: #8bc7ff;
  background: #172e54;
  padding: 1px 6px;
  border-radius: 4px;
  flex: none;
}

/* Tiers Page Color Badges & 2-Column Grid */
.tier-jump-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 16px 0 24px;
}
.tier-pill {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 6px 14px;
  border-radius: 999px;
  font-weight: 800;
  font-size: 0.85rem;
  background: #122341;
  border: 1px solid #355680;
  color: #f8fafc;
}
.tier-pill[data-tier="S"] { border-color: #facc15; color: #fde047; }
.tier-pill[data-tier="A"] { border-color: #c084fc; color: #e9d5ff; }
.tier-pill[data-tier="B"] { border-color: #38bdf8; color: #7dd3fc; }
.tier-pill[data-tier="C"] { border-color: #94a3b8; color: #cbd5e1; }
.tier-section {
  scroll-margin-top: 90px;
  margin-bottom: 28px;
}
.tier-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
}
.tier-heading span {
  padding: 3px 12px;
  border-radius: 4px;
  font-weight: 900;
}
.tier-heading[data-tier="S"] span { background: #facc15; color: #060b1a; }
.tier-heading[data-tier="A"] span { background: #a855f7; color: #ffffff; }
.tier-heading[data-tier="B"] span { background: #0ea5e9; color: #060b1a; }
.tier-heading[data-tier="C"] span { background: #475569; color: #f8fafc; }
.tier-heading small {
  font-size: 0.85rem;
  color: #9bb2ce;
  font-weight: 600;
}
.tiers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: 14px;
  align-items: start;
}
.tiers-grid .blade-rank {
  margin-bottom: 0;
}
.blade-rank summary {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
}
.blade-rank summary::after {
  content: "▾";
  margin-inline-start: auto;
  color: #7dd3fc;
  font-size: 1rem;
  transition: transform 0.18s;
}
.blade-rank[open] summary::after {
  transform: rotate(180deg);
}
.blade-rank-info {
  min-width: 0;
}
.tier-rank-badge {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 800;
  background: #1a3258;
  color: #e2e8f0;
}
.tier-rank-badge[data-rank="1"] { background: #facc15; color: #091326; }
.tier-rank-badge[data-rank="2"] { background: #cbd5e1; color: #091326; }
.tier-rank-badge[data-rank="3"] { background: #d97706; color: #fff; }

/* Giveaways Grid, Info Banner & Uniform Photo Frame */
.giveaway-info-banner {
  margin-bottom: 22px;
  border-left: 4px solid #ffd05e;
  background: linear-gradient(135deg, #10203e, #0a1428);
}
.giveaway-info-head h2 { margin: 8px 0 6px; }
.giveaway-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr));
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 14px 0 0;
}
.giveaway-steps li {
  background: #081224;
  border: 1px solid #284564;
  border-radius: 6px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.giveaway-steps li strong { color: #ffd05e; font-size: 0.95rem; }
.giveaway-steps li span { color: #cbd5e1; font-size: 0.86rem; }
.giveaway-winners-summary {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid #284564;
}
.giveaway-winners-summary ul {
  margin: 6px 0 0;
  padding-left: 18px;
  color: #e2e8f0;
}
.giveaways-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 18px;
}
.giveaway-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.giveaway-card-actions {
  margin-top: auto;
  padding-top: 10px;
}
.giveaway-cta-btn {
  width: 100%;
  justify-content: center;
}
.giveaway-photo-frame {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: radial-gradient(circle at 50% 45%, #162b4f 0%, #071124 72%);
  border: 1px solid #284564;
  border-radius: 6px;
  overflow: hidden;
  padding: 10px;
  margin: 12px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.giveaway-photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 6px;
}
.giveaway-card {
  display: flex;
  flex-direction: column;
}
.giveaway-meta-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.giveaway-pill {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  background: #1b2f52;
  color: #cbd5e1;
  border: 1px solid #355680;
}
.giveaway-pill[data-open="yes"] {
  background: rgba(250, 204, 21, 0.16);
  border-color: #facc15;
  color: #fde047;
}
.giveaway-winner-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: flex-start;
  margin: 4px 0 0;
  padding: 6px 12px;
  border-radius: 6px;
  background: rgba(250, 204, 21, 0.14);
  border: 1px solid rgba(250, 204, 21, 0.45);
  color: #fde047;
  font-weight: 800;
}

/* Account 2-Column Profile */
.account-profile-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 18px;
  align-items: start;
}

/* Admin 4-Stat Summary Bar & High-Density Players Table */
.admin-stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  gap: 12px;
  margin: 0 0 20px;
}
.admin-stat {
  padding: 14px 18px;
  background: #0e1b35;
  border: 1px solid #2b4a70;
  border-top: 3px solid #38bdf8;
  border-radius: 6px;
}
.admin-stat small {
  display: block;
  font-size: 0.78rem;
  color: #9bb2ce;
  font-weight: 700;
}
.admin-stat strong {
  display: block;
  margin-top: 4px;
  font-size: 1.5rem;
  font-weight: 900;
  color: #f8fafc;
}
.admin-stat strong.stat-ok { color: #4ade80; }
.admin-stat strong.stat-warn { color: #facc15; }

.admin-table-wrap {
  width: 100%;
  overflow-x: auto;
  background: #0e1b35;
  border: 1px solid #2b4a70;
  border-radius: 6px;
}
.admin-players-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.admin-players-table th {
  padding: 12px 14px;
  background: #132445;
  color: #7dd3fc;
  font-weight: 800;
  white-space: nowrap;
  border-bottom: 2px solid #facc15;
}
.admin-players-table td {
  padding: 11px 14px;
  border-bottom: 1px solid #243b5c;
  vertical-align: middle;
}
.admin-players-table tr:hover td {
  background: rgba(56, 189, 248, 0.06);
}
.role-badge {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 7px;
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 4px;
  background: #1e3a5f;
  color: #bde0ff;
}
.nowrap { white-space: nowrap; }
.table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.page .btn-sm,
.page .btn-danger-sm {
  min-height: 34px;
  padding: 4px 10px;
  font-size: 0.8rem;
}
.page .btn-danger-sm {
  background: rgba(239, 68, 68, 0.14);
  border-color: #ef4444;
  color: #fca5a5;
}
.page .btn-danger-sm:hover {
  background: rgba(239, 68, 68, 0.28);
  color: #fff;
}

/* About Hero 2-Column Visual & Unified Dark Grid */
.dojo-intro {
  background-color: #060b1a;
  background-image:
    radial-gradient(ellipse at 20% 0%, rgba(56, 189, 248, 0.12), transparent 44%),
    linear-gradient(rgba(56, 189, 248, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 189, 248, 0.03) 1px, transparent 1px);
  background-size: auto, 44px 44px, 44px 44px;
}
.dojo-intro .intro-hero {
  background: radial-gradient(ellipse at 80% 30%, rgba(250, 204, 21, 0.14), transparent 50%), linear-gradient(125deg, #0d1f3c 0%, #071124 70%);
  border-bottom: 3px solid #facc15;
}
.dojo-intro .intro-steps {
  background: #091326;
  border-block: 1px solid #233c61;
}
.dojo-intro .intro-steps li {
  background: #0d1933;
  border: 1px solid #284564;
  border-top: 3px solid #facc15;
  border-radius: 6px;
}
.intro-hero-grid {
  display: grid;
  gap: 28px;
  align-items: center;
}
.intro-hero-art img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
  border: 1px solid #2e5282;
  border-radius: 8px;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
}
@media (min-width: 860px) {
  .intro-hero-grid {
    grid-template-columns: 1fr 1.05fr;
  }
}

/* Evenly Aligned Album Cards */
.page .album-card,
.tournament-gallery .album-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.album-card .album-card-media {
  display: block;
  padding: 0;
  width: 100%;
  background: #071124;
  border-bottom: 1px solid #243e63;
  overflow: hidden;
}
.album-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 14px 16px;
  gap: 6px;
}
.album-card-body strong {
  display: block;
  color: #f8fafc;
}
.album-card-body span {
  margin-top: auto;
  font-size: 0.84rem;
  color: #b7c9e2;
}

/* Dark-Mode Friendly Single Footer Badge */
.footer-org-badge {
  display: inline-flex;
  align-items: center;
  padding: 6px 10px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 6px;
  border: 1px solid #355980;
}
footer .footer-org-badge img {
  background: transparent;
  padding: 0;
  width: min(160px, 38vw);
}

/* Full-Width Forms for Deck Editor & Event Creation */
.page .deck-editor.form,
#admin-create .form[data-form="create"] {
  max-width: 100%;
}
@media (min-width: 760px) {
  #admin-create .form[data-form="create"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
  #admin-create .form[data-form="create"] > :is(fieldset, button, .actions),
  #admin-create .form[data-form="create"] > label:has(textarea, input[type="file"]) {
    grid-column: 1 / -1;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Dark Scrollbars, Fixed Part Image Dimensions (No CLS), Event Back Pills & Album Lightbox */
:root { color-scheme: dark; }
.favorite-deck .deck-part-picture {
  width: 64px;
  height: 64px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.favorite-deck .deck-part-picture img {
  width: 50px;
  height: 50px;
  object-fit: contain;
}
.player-summary-card {
  display: flex;
  align-items: center;
  gap: 16px;
}
.player-summary-card .avatar-preview { margin-bottom: 0; }
.event-back {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}
.event-back a {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 6px 14px;
  border-radius: 6px;
  border: 1px solid #355680;
  background: #10203b;
  color: #e2e8f0;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.9rem;
}
.event-back a:hover { border-color: #67cfff; color: #fff; }
.album-thumb {
  display: block;
  padding: 0;
  border: 1px solid #2b4a70;
  border-radius: 6px;
  overflow: hidden;
  background: #071124;
  aspect-ratio: 16 / 10;
}
.album-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
dialog.album-lightbox {
  width: min(96vw, 1080px);
  max-height: 92vh;
  padding: 14px;
  border: 1px solid #38bdf8;
  border-radius: 10px;
  background: #060b1a;
  color: #f8fafc;
}
dialog.album-lightbox::backdrop { background: rgba(2, 6, 18, 0.88); }
.lightbox-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.lightbox-stage {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}
.lightbox-stage img {
  display: block;
  width: 100%;
  max-height: 76vh;
  object-fit: contain;
}
.lightbox-nav, .dialog-x {
  min-width: 44px;
  min-height: 44px;
  font-size: 1.35rem;
  line-height: 1;
}
.deck-picker header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}
.deck-picker header h2 { margin: 0; font-size: 1.15rem; }
::placeholder { color: #94a3b8; opacity: 1; }

/* Mobile & Desktop Overflow Guards */
*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; max-width: 100%; }
header.dojo-header, main, footer, .mobile-nav { max-width: 100vw; }
.page, .card, .players-toolbar > * { min-width: 0; max-width: 100%; }
@media (max-width: 560px) {
  .dojo-header { flex-wrap: nowrap; padding: 8px 10px; gap: 6px; }
  .dojo-header .brand-logo { width: min(120px, 33vw); }
  .dojo-header .nav-toggle:not([hidden]) { padding: 5px 8px; font-size: 0.84rem; }
  .dojo-header #login { padding: 5px 10px; font-size: 0.84rem; }
  .players-toolbar { flex-direction: column; align-items: stretch; }
  .players-search-label { flex: none; width: 100%; }
  .players-count { align-self: flex-start; }
}

/* === 6-Part Beyblade Motion & Tactile Feedback === */
@keyframes bladeLaunch {
  0% { transform: rotate(0deg) scale(1); }
  22% { transform: rotate(220deg) scale(1.12); }
  100% { transform: rotate(540deg) scale(1); }
}
@keyframes slideKenBurns {
  from { transform: scale(1); }
  to { transform: scale(1.045); }
}
@keyframes dotProgress {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}
@keyframes pageEnter {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes navPop {
  0% { transform: scale(1); }
  45% { transform: scale(1.24) translateY(-2px); }
  100% { transform: scale(1); }
}
@keyframes statusPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(250, 204, 21, 0.55); }
  60% { box-shadow: 0 0 0 8px rgba(250, 204, 21, 0); }
}
@keyframes goldSheen {
  0%, 72% { transform: translateX(-140%) skewX(-24deg); }
  100% { transform: translateX(260%) skewX(-24deg); }
}

/* 1. Blade Launch Spin */
.deck-part-picture img.is-spinning,
.blade-rank:hover .deck-part-picture img,
.race-deck-list .deck-part-picture:hover img,
.favorite-deck .deck-part-picture:hover img {
  animation: bladeLaunch 0.68s cubic-bezier(0.16, 1, 0.3, 1);
}
.blade-rank[open][data-tier="S"] .deck-part-picture { box-shadow: 0 0 14px rgba(250, 204, 21, 0.42); border-color: #facc15; }
.blade-rank[open][data-tier="A"] .deck-part-picture { box-shadow: 0 0 14px rgba(192, 132, 252, 0.42); border-color: #c084fc; }
.blade-rank[open][data-tier="B"] .deck-part-picture { box-shadow: 0 0 14px rgba(56, 189, 248, 0.42); border-color: #38bdf8; }

/* 2. Hero Carousel Crossfade + 8s Dot Progress */
.stage-rotating .stage-slides > * {
  opacity: 0;
  pointer-events: none;
  z-index: 1;
  transition: opacity 0.55s ease;
}
.stage-rotating .stage-slides > .is-active {
  opacity: 1;
  pointer-events: auto;
  z-index: 2;
}
.stage-rotating .stage-slides > .is-active img {
  animation: slideKenBurns 8s ease-out forwards;
}
.stage-dot.is-active {
  position: relative;
  overflow: hidden;
  width: 28px;
  background: #3d567a;
}
.stage-dot.is-active::after {
  content: "";
  position: absolute;
  inset: 0;
  background: #facc15;
  transform-origin: left center;
  animation: dotProgress 8s linear forwards;
}

/* 3. View Transitions & Mobile Nav Pop */
#app > .page,
#app > .arena-home {
  animation: pageEnter 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.mobile-nav a[aria-current="page"] span {
  animation: navPop 0.34s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 5. Live Status Pulse */
.race-status[data-status="報名中"],
.status[data-status="報名中"] {
  animation: statusPulse 2.2s ease-out infinite;
}

/* 6. Tactile Press & Gold CTA Sheen */
.button, button, .stage-primary, .stage-secondary, .race-empty-cta, .arena-actions a {
  transition: transform 0.14s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.16s, border-color 0.16s;
}
.button:active, button:active, .stage-primary:active, .stage-secondary:active, .race-empty-cta:active, .arena-actions a:active {
  transform: scale(0.96);
}
.arena-actions a:first-child,
.race-empty-cta,
.event-apply-button {
  position: relative;
  overflow: hidden;
}
.arena-actions a:first-child::after,
.race-empty-cta::after,
.event-apply-button::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 45%;
  pointer-events: none;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.42), transparent);
  animation: goldSheen 6s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* === Bracket Tree, Player Stats Strip, Admin Checklist, Roster Filter, Skeleton & Footer Replay === */
@keyframes shimmerBg {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.event-cards-grid {
  align-items: start;
}
.event-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}
.event-card-badge-inline {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 0.74rem;
  font-weight: 800;
  color: #f8fafc;
  background: #172e54;
  border: 1px solid #35547a;
}
.race-status-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.countdown-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 0.76rem;
  font-weight: 800;
  background: #172e54;
  color: #ffd05e;
  border: 1px solid #ffd05e66;
}
.countdown-pill.is-today {
  background: #ffd05e;
  color: #081224;
}
.players-explain {
  margin: 0 0 14px;
  font-size: 0.88rem;
}
.giveaway-eligibility {
  margin: 8px 0 0;
  color: #e2e8f0;
  font-size: 0.9rem;
}
.past-giveaways {
  margin-top: 24px;
  border-top: 1px solid #284564;
  padding-top: 16px;
}
.past-giveaways > summary {
  cursor: pointer;
  font-weight: 800;
  color: #cbd5e1;
  min-height: 44px;
  display: flex;
  align-items: center;
  margin-bottom: 14px;
}
.dojo-sk-hero {
  height: 220px;
  border-radius: 8px;
  margin-bottom: 18px;
  background: linear-gradient(110deg, #071124 30%, #13284a 45%, #071124 60%);
  background-size: 200% 100%;
  animation: shimmerBg 1.5s linear infinite;
}
.dojo-sk-card {
  min-height: 160px;
}
.hk-sk-line {
  height: 14px;
  border-radius: 4px;
  margin-bottom: 12px;
  background: linear-gradient(110deg, #0c1d3a 30%, #1a3560 45%, #0c1d3a 60%);
  background-size: 200% 100%;
  animation: shimmerBg 1.5s linear infinite;
}
.hk-sk-line.w40 { width: 40%; height: 18px; }
.hk-sk-line.w60 { width: 60%; }
.hk-sk-line.w85 { width: 85%; height: 20px; }
.event-utility-actions {
  margin: 10px 0 14px;
}
.my-schedule-box {
  margin-bottom: 18px;
  border-left: 4px solid #38bdf8;
}
.my-schedule-box ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: grid;
  gap: 10px;
}
.my-schedule-box li {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding-top: 8px;
  border-top: 1px solid #284564;
}
.my-schedule-box li p { margin: 2px 0 0; }
.player-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.player-badges span {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 800;
  background: #13284a;
  color: #ffd05e;
  border: 1px solid #38bdf866;
}
.player-share-bar {
  margin: 0 0 18px;
}
.h2h-section {
  margin: 22px 0;
  border-left: 4px solid #38bdf8;
}
.h2h-controls {
  display: grid;
  gap: 10px;
  margin-bottom: 16px;
}
.h2h-picks {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.h2h-versus-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 14px;
  align-items: center;
  padding: 14px;
  background: #081224;
  border: 1px solid #2b4a70;
  border-radius: 6px;
}
.h2h-fighter {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.h2h-fighter:last-child { text-align: right; }
.h2h-fighter strong { font-size: 1.08rem; overflow-wrap: anywhere; }
.h2h-fighter small { color: #8bc7ff; font-size: 0.8rem; }
.h2h-fighter span { color: #cbd5e1; font-size: 0.84rem; }
.h2h-score-center {
  text-align: center;
  min-width: 96px;
}
.h2h-score-center small { display: block; color: #94a3b8; font-size: 0.74rem; }
.h2h-score-center strong {
  font: 900 2rem/1.1 "Barlow Condensed", sans-serif;
  color: #ffd05e;
  font-variant-numeric: tabular-nums;
}
.h2h-bar {
  height: 6px;
  border-radius: 999px;
  background: #334155;
  overflow: hidden;
  margin-top: 6px;
}
.h2h-bar i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #ffd05e, #38bdf8);
}
.h2h-match-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: grid;
  gap: 8px;
}
.h2h-match-list li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px;
  background: #091326;
  border: 1px solid #1e3a5f;
  border-radius: 4px;
  font-size: 0.88rem;
}
@media (max-width: 580px) {
  .h2h-versus-grid { grid-template-columns: 1fr; text-align: center; }
  .h2h-fighter:last-child { text-align: center; }
}
.combo-top-section {
  margin: 20px 0 26px;
}
.combo-top-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  display: grid;
  gap: 10px;
}
.combo-top-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
}
.combo-top-rank {
  font: 900 1.5rem/1 "Barlow Condensed", sans-serif;
  color: #ffd05e;
  min-width: 1.8em;
}
.combo-top-parts {
  display: flex;
  align-items: center;
  gap: 6px;
}
.combo-top-parts .deck-part-picture {
  width: 48px;
  height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
}
.combo-top-parts img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.combo-top-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1 1 200px;
}
.event-cards-grid .event-grid-card.is-compact {
  height: auto;
}
.event-card-actions {
  margin-top: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.home-greeting {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  padding: 12px 16px;
  background: linear-gradient(135deg, #102447, #0a162d);
  border: 1px solid #38bdf866;
  border-left: 4px solid #ffd05e;
  border-radius: 6px;
  margin-bottom: 4px;
}
.home-greeting strong { color: #ffd05e; margin-right: 8px; }
.home-greeting span { color: #e2e8f0; font-size: 0.92rem; }
.stage-slide { overflow: hidden; }
.slide-backdrop {
  position: absolute;
  inset: -14px;
  background-size: cover;
  background-position: center;
  filter: blur(18px) brightness(0.42);
  transform: scale(1.08);
  z-index: 0;
}
.stage-slide img {
  position: relative;
  z-index: 1;
}
.live-countdown-box {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 6px 0 8px;
  padding: 6px 12px;
  background: #081224;
  border: 1px solid #2b4a70;
  border-radius: 4px;
  font-size: 0.85rem;
}
.live-countdown-box span { color: #93c5fd; font-weight: 700; }
.live-countdown-box strong {
  color: #ffd05e;
  font: 800 1.05rem/1.1 "Barlow Condensed", "Noto Sans HK", sans-serif;
  font-variant-numeric: tabular-nums;
}
.newbie-home-card {
  margin-top: 14px;
  border-left: 4px solid #38bdf8;
}
.newbie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 16px;
  margin-bottom: 20px;
}
.newbie-parent-card { border-left: 4px solid #ffd05e; }
.newbie-quiz { display: grid; gap: 16px; }
.quiz-q {
  border: 1px solid #29456b;
  border-radius: 6px;
  padding: 14px;
  margin: 0;
  display: grid;
  gap: 8px;
}
.quiz-q legend { font-weight: 800; color: #fff; padding: 0 6px; }
.quiz-opt {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 10px;
  margin: 0;
  cursor: pointer;
  padding: 6px 8px;
  border-radius: 4px;
}
.quiz-opt:hover { background: #132648; }
.quiz-opt input { width: auto; min-height: 20px; }
.quiz-fb { margin: 4px 0 0; font-size: 0.88rem; font-weight: 700; }
.quiz-fb.is-ok { color: #86efac; }
.quiz-fb.is-wrong { color: #fca5a5; }
.cabinet-box { margin-top: 18px; border-left: 4px solid #38bdf8; }
.cabinet-list { list-style: none; padding: 0; margin: 12px 0; display: grid; gap: 8px; }
.cabinet-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: #081224;
  border: 1px solid #284564;
  border-radius: 6px;
}
.cabinet-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.cabinet-form button { grid-column: 1 / -1; justify-self: start; }
.verified-email {
  padding: 8px 12px;
  background: #081224;
  border: 1px solid #284564;
  border-radius: 4px;
  margin: 0 0 10px;
  font-size: 0.9rem;
}
.admin-dup-merge {
  margin: 14px 0;
  border-left: 4px solid #ffd05e;
  background: #13223e;
}
.poster-backdrop {
  position: absolute;
  inset: -14px;
  background-size: cover;
  background-position: center;
  filter: blur(18px) brightness(0.4);
  transform: scale(1.08);
  z-index: 0;
  pointer-events: none;
}
.event-card-poster-wrap .event-card-poster,
.album-card-media img,
.race-poster img {
  position: relative;
  z-index: 1;
}
.album-card-media,
.race-poster {
  position: relative;
  overflow: hidden;
}
.combo-top-list {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
}
.poster-skeleton.is-img-ready {
  animation: none;
  background: #071124;
}
.poster-skeleton {
  background:
    radial-gradient(circle at 50% 45%, rgba(56, 189, 248, 0.14), transparent 62%),
    linear-gradient(110deg, #071124 30%, #16315b 45%, #071124 60%);
  background-size: auto, 200% 100%;
  animation: shimmerBg 1.5s linear infinite;
}
.muted { color: #b8cae4; }
.footer-replay {
  background: transparent;
  border: 0;
  padding: 0;
  min-height: 0;
  color: #8bc7ff;
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.footer-replay:hover { color: #facc15; background: transparent; translate: none; }
.player-stats-strip {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
  margin: 0 0 22px;
}
.player-stats-strip > div {
  background: #0d1630;
  border: 1px solid #2b4a70;
  border-radius: 8px;
  padding: 12px 14px;
}
.player-stats-strip small { display: block; color: #9bb2ce; font-size: 0.78rem; margin-bottom: 4px; }
.player-stats-strip strong { font-size: 1.35rem; color: #facc15; font-weight: 900; }
.admin-checklist {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 8px 0 14px;
}
.admin-checklist span {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 4px;
  background: #132544;
  border: 1px solid #2e4c73;
  color: #cbd5e1;
}
.admin-checklist span.ok { background: #12362b; border-color: #2f7a5c; color: #a7f3d0; }
.admin-checklist span.warn { background: #3b2a14; border-color: #926626; color: #fde68a; }
.roster-filter-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px 18px;
  margin: 12px 0;
}
.roster-filter-bar > label:first-child { flex: 1 1 220px; }
.roster-unchecked-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-weight: 700;
  cursor: pointer;
}
.roster-unchecked-toggle input { width: auto; }
.load-more-wrap { display: flex; justify-content: center; margin-top: 20px; }
.bracket-wrap {
  margin: 20px 0 24px;
  padding: 16px;
  background: #091326;
  border: 1px solid #2b4a70;
  border-radius: 8px;
}
.bracket-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 14px;
}
.bracket-head h3 { margin: 0; color: #facc15; }
.bracket-tree {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding-bottom: 8px;
  align-items: stretch;
}
.bracket-round {
  flex: 0 0 220px;
  display: flex;
  flex-direction: column;
}
.bracket-round h4 {
  margin: 0 0 10px;
  font-size: 0.86rem;
  color: #7dd3fc;
  letter-spacing: 0.04em;
}
.bracket-matches {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  gap: 12px;
}
.bracket-match {
  background: #0f1e3a;
  border: 1px solid #304c74;
  border-radius: 6px;
  overflow: hidden;
}
.bracket-slot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  font-size: 0.86rem;
}
.bracket-slot + .bracket-slot { border-top: 1px solid #243b5c; }
.bracket-slot.is-winner { background: rgba(250, 204, 21, 0.14); color: #fde047; font-weight: 800; }
.bracket-slot.is-empty { color: #7e94b4; }
.bracket-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bracket-score { font-family: "Barlow Condensed", sans-serif; font-size: 1.05rem; flex: none; }
