/* ============================================================
   SMASH ANALYZER — styles.css
   ============================================================ */

/* ─── Custom Properties ─────────────────────────────────── */
:root {
  --bg-deep: #080a14;
  --bg-card: #0f1220;
  --bg-surface: #161929;
  --gold: #d4a017;
  --gold-light: #f0c040;
  --gold-dark: #9e7612;
  --red: #e63946;
  --blue: #4361ee;
  --green: #2ec44b;
  --purple: #9b5de5;
  --amber: #f4a261;
  --text-primary: #f0f0f5;
  --text-muted: #aaaacc;
  --border: rgba(212, 160, 23, 0.2);
  --border-subtle: rgba(212, 160, 23, 0.15);
  --nav-height: 64px;
}

/* ─── Reset & Base ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  line-height: 1.1;
}

a { color: var(--gold); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--gold-light); }

img { display: block; max-width: 100%; }

/* ─── Utility Classes ────────────────────────────────────── */
.text-gold { color: var(--gold); }
.text-red { color: var(--red); }
.text-muted { color: var(--text-muted); }
.font-barlow { font-family: 'Barlow Condensed', sans-serif; }
.uppercase { text-transform: uppercase; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }

/* ─── Scrollbar ──────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg-deep); }
::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 3px; }

/* ============================================================
   NAVIGATION
   ============================================================ */
.site-nav {
  transition: transform 0.3s ease;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: rgba(8, 10, 20, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
}

.site-nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.nav-logo {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.5rem;
  text-transform: uppercase;
  color: var(--gold);
  letter-spacing: 0.04em;
  text-decoration: none;
}
.nav-logo:hover { color: var(--gold-light); }

.nav-logo span {
  color: var(--text-primary);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active { color: var(--gold); }

.nav-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text-primary);
}

.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  transition: all 0.3s;
  margin: 5px 0;
}

.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  right: 0;
  background: rgba(8, 10, 20, 0.98);
  border-bottom: 1px solid var(--border);
  padding: 20px 24px;
  z-index: 999;
  flex-direction: column;
  gap: 16px;
}

.nav-mobile.open { display: flex; }

.nav-mobile a {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1.3rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.nav-mobile a:hover { color: var(--gold); }

/* ─── Page Content Offset ───────────────────────────────── */
.page-content { padding-top: var(--nav-height); }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: 4px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all 0.2s;
  border: 2px solid transparent;
  text-decoration: none;
}

.btn-gold {
  background: var(--gold);
  color: var(--bg-deep);
  border-color: var(--gold);
}
.btn-gold:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--bg-deep);
  transform: translateY(-2px);
  box-shadow: 0 6px 24px rgba(212, 160, 23, 0.4);
}

.btn-outline {
  background: rgba(212, 160, 23, 0.05);
  color: rgba(240, 240, 245, 0.9);
  border-color: rgba(212, 160, 23, 0.45);
}
.btn-outline:hover {
  background: rgba(212, 160, 23, 0.1);
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(212, 160, 23, 0.15);
}

.btn-lg {
  padding: 11px 28px;
  font-size: 1rem;
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ============================================================
   HERO SECTION
   ============================================================ */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  background: var(--bg-deep);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-image: url('./images/hero-banner.png');
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(8,10,20,0.78) 0%, rgba(8,10,20,0.86) 45%, rgba(8,10,20,0.97) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 900px;
  padding: 80px 24px;
}

.hero-eyebrow {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 16px;
}

.hero-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: clamp(2.8rem, 8vw, 6rem);
  text-transform: uppercase;
  line-height: 1;
  color: var(--text-primary);
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
  margin-bottom: 20px;
}

.hero-title .accent { color: var(--gold); }

.hero-subtitle {
  font-size: 1.2rem;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto 40px;
  line-height: 1.7;
}

.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ============================================================
   SECTION STYLES
   ============================================================ */
section { padding: 80px 0; }

/* Scroll reveal */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.reveal-on-scroll.revealed {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .reveal-on-scroll { opacity: 1; transform: none; }
}

.section-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold);
  margin-bottom: 12px;
}

.section-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: clamp(2rem, 4vw, 3rem);
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.section-sub {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 560px;
}

/* ============================================================
   HOW IT WORKS — SVG FLOW DIAGRAM
   ============================================================ */
.how-it-works {
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.how-flow-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px 0;
  overflow-x: auto;
}

.flow-svg {
  width: 100%;
  max-width: 800px;
  height: auto;
}

/* ─── SVG text / circle styles via class ─── */
.flow-circle {
  fill: var(--bg-surface);
  stroke: var(--gold);
  stroke-width: 2;
}

.flow-icon-text {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 20px;
  fill: var(--gold);
  text-anchor: middle;
  dominant-baseline: central;
}

.flow-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 13px;
  fill: var(--text-primary);
  text-anchor: middle;
  text-transform: uppercase;
  letter-spacing: 1.5px;
}

.flow-sublabel {
  font-size: 11px;
  fill: var(--text-muted);
  text-anchor: middle;
  letter-spacing: 0.5px;
}

@keyframes dashFlow {
  to { stroke-dashoffset: -24; }
}

.flow-connector {
  fill: none;
  stroke: var(--gold);
  stroke-width: 2;
  stroke-dasharray: 8 4;
  opacity: 0.6;
  animation: dashFlow 1.5s linear infinite;
}

.flow-arrow {
  fill: var(--gold);
  opacity: 0.6;
}

/* ============================================================
   FIGHTER PREVIEW STRIP
   ============================================================ */
.fighter-strip-section { background: var(--bg-deep); }

.fighter-strip {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 8px 0 20px;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-dark) transparent;
  scroll-snap-type: x mandatory;
}

.fighter-strip::-webkit-scrollbar { height: 4px; }
.fighter-strip::-webkit-scrollbar-track { background: transparent; }
.fighter-strip::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 2px; }

.fighter-tile {
  flex: 0 0 160px;
  height: 220px;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  scroll-snap-align: start;
  border: 1px solid var(--border-subtle);
  transition: transform 0.25s, box-shadow 0.25s;
}

.fighter-tile:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(212, 160, 23, 0.25), inset 0 0 0 1px rgba(212, 160, 23, 0.3);
}

.fighter-tile img,
.fighter-tile .char-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fighter-tile img {
  transition: transform 0.3s ease, filter 0.3s ease;
  filter: saturate(0.85);
}
.fighter-tile:hover img {
  filter: saturate(1.1) drop-shadow(0 0 18px rgba(212, 160, 23, 0.38));
}

.fighter-tile .tile-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8,10,20,0.92) 0%, rgba(8,10,20,0.1) 55%);
  display: flex;
  align-items: flex-end;
  padding: 12px;
}

.fighter-tile .tile-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  color: var(--text-primary);
  letter-spacing: 0.04em;
  line-height: 1;
}

.fighter-tile .tile-accent {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gold);
}

/* ============================================================
   STATS BAR
   ============================================================ */
.stats-bar {
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 48px 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.stat-item {
  text-align: center;
  padding: 20px;
  border-right: 1px solid var(--border-subtle);
}
.stat-item:last-child { border-right: none; }

.stat-number {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: clamp(3rem, 6vw, 5rem);
  color: var(--gold);
  line-height: 1;
  display: block;
}

.stat-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-top: 6px;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.cta-section {
  background: radial-gradient(ellipse at center, rgba(212, 160, 23, 0.12) 0%, var(--bg-deep) 70%);
  text-align: center;
  padding: 100px 24px;
}

.cta-section .section-title { margin-bottom: 32px; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  padding: 40px 0 24px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.footer-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-brand { display: flex; flex-direction: column; gap: 8px; }

.footer-about {
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 320px;
  line-height: 1.5;
}

.footer-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
}

.footer-nav {
  display: flex;
  gap: 24px;
  list-style: none;
}

.footer-nav a {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.footer-nav a:hover { color: var(--gold); }

.footer-socials {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer-social-link {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-decoration: none;
  border: 1px solid rgba(212,160,23,0.25);
  padding: 4px 12px;
  border-radius: 3px;
  transition: color 0.2s, border-color 0.2s;
}
.footer-social-link:hover { color: var(--gold); border-color: var(--gold); }

.footer-copy {
  color: var(--text-muted);
  font-size: 0.85rem;
  text-align: center;
  border-top: 1px solid var(--border-subtle);
  padding-top: 20px;
}

/* ============================================================
   PAGE HEADER
   ============================================================ */
.page-header {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-subtle);
  padding: 48px 0 40px;
}

.page-header-eyebrow {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.page-header-eyebrow span {
  color: var(--gold);
  text-shadow: 0 0 18px rgba(212, 160, 23, 0.35);
}

.page-header h1 {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: clamp(2.5rem, 5vw, 4rem);
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 8px;
}

.page-header p {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 560px;
}

.badge-count {
  display: inline-block;
  background: var(--gold);
  color: var(--bg-deep);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  padding: 3px 12px;
  border-radius: 100px;
  vertical-align: middle;
  margin-left: 12px;
  letter-spacing: 0.05em;
}

/* ============================================================
   CHARACTER PLACEHOLDER
   ============================================================ */
.char-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  background: linear-gradient(135deg, var(--bg-surface) 0%, #1a1e35 100%);
  flex-shrink: 0;
}

/* Silhouette SVG inside placeholder — sized relative to container */
.char-silhouette svg {
  width: 55%;
  height: 55%;
  opacity: 0.6;
}

/* ============================================================
   ROSTER PAGE
   ============================================================ */
.roster-section { padding: 40px 0 80px; }

.filter-bar {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: flex-end;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1 1 180px;
}

.filter-group label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}

.filter-input,
.filter-select {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  padding: 10px 14px;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
}

.filter-input:focus,
.filter-select:focus { border-color: var(--gold); }

.filter-select-wrapper {
  position: relative;
}
.filter-select-wrapper::after {
  content: '▾';
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  font-size: 0.85rem;
}

.btn-clear {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
  align-self: flex-end;
}
.btn-clear:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Roster Grid */
.roster-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.fighter-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.fighter-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 32px rgba(212, 160, 23, 0.2);
  border-color: var(--border);
}

.fighter-card-img {
  height: 180px;
  overflow: hidden;
  background: var(--bg-surface);
  position: relative;
}

.fighter-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: drop-shadow(0 0 20px rgba(212, 160, 23, 0.3));
  transition: transform 0.3s;
}

.fighter-card:hover .fighter-card-img img { transform: scale(1.05); }

.fighter-card-body {
  padding: 12px 14px 14px;
}

.fighter-card-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1.15rem;
  text-transform: uppercase;
  color: var(--text-primary);
  letter-spacing: 0.03em;
  margin-bottom: 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 8px;
}

.badge {
  display: inline-block;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 9px;
  border-radius: 100px;
  line-height: 1.4;
}

.badge-series {
  border: 1px solid var(--gold);
  color: var(--gold);
  background: transparent;
}

.badge-archetype {
  background: rgba(212, 160, 23, 0.12);
  color: var(--text-muted);
  border: 1px solid var(--border-subtle);
}

.badge-weight {
  background: rgba(67, 97, 238, 0.15);
  color: var(--blue);
  border: 1px solid rgba(67, 97, 238, 0.3);
}

.no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
}

.no-results p {
  font-size: 1.1rem;
}

/* ============================================================
   MODAL
   ============================================================ */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(8, 10, 20, 0.85);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 24px;
  backdrop-filter: blur(4px);
}

.modal-overlay.open { display: flex; }

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  max-width: 680px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  animation: modalSlideIn 0.2s ease-out;
}

@keyframes modalSlideIn {
  from { opacity: 0; transform: translateY(-20px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: rgba(240, 240, 245, 0.1);
  border: none;
  color: var(--text-primary);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  z-index: 1;
}
.modal-close:hover { background: rgba(240, 240, 245, 0.2); }

.modal-portrait {
  height: 280px;
  background: var(--bg-surface);
  overflow: hidden;
  border-radius: 12px 12px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: drop-shadow(0 0 30px rgba(212, 160, 23, 0.4));
}

.modal-body {
  padding: 24px 28px 28px;
}

.modal-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 2.2rem;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.modal-section {
  margin-bottom: 18px;
}

.modal-section-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--gold);
  margin-bottom: 6px;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-section p,
.modal-section li {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.6;
}

.modal-section ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.modal-section ul li {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  padding: 4px 10px;
  font-size: 0.82rem;
  color: var(--text-primary);
}

.modal-footer {
  padding: 0 28px 24px;
}

/* ============================================================
   ANALYZER PAGE
   ============================================================ */
.analyzer-section { padding: 40px 0 80px; }

/* Dual Picker Layout */
.dual-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}

.picker-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
}

.picker-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.picker-header h2 {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.3rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.picker-header.left h2 { color: var(--gold); }
.picker-header.right h2 { color: var(--red); }

/* Selected Character Display */
.picker-selected {
  height: 280px;
  background: var(--bg-surface);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--border-subtle);
}

.picker-selected img,
.picker-selected .char-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.picker-selected .char-placeholder { font-size: 6rem; }

.picker-selected-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8,10,20,0.85) 0%, transparent 50%);
  display: flex;
  align-items: flex-end;
  padding: 14px 16px;
  pointer-events: none;
}

.picker-selected-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.4rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Picker placeholder state with radial burst */
.picker-selected::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at center, rgba(212,160,23,0.07) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.picker-silhouette {
  position: absolute;
  top: 40%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.92;
  z-index: 0;
  pointer-events: none;
  filter: drop-shadow(0 0 26px rgba(212,160,23,0.45)) drop-shadow(0 0 6px rgba(255,233,168,0.35));
  animation: silhouettePulse 2.8s ease-in-out infinite;
}
.picker-silhouette.right-sil {
  filter: drop-shadow(0 0 26px rgba(230,57,70,0.42)) drop-shadow(0 0 6px rgba(255,180,173,0.32));
}

@keyframes silhouettePulse {
  0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.88; }
  50% { transform: translate(-50%, -50%) scale(1.035); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .picker-silhouette { animation: none; }
}

.picker-placeholder-text {
  position: relative;
  z-index: 1;
  margin-top: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--gold-light);
  text-shadow: 0 1px 10px rgba(0,0,0,0.6);
}

.picker-placeholder-hint {
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: none;
  color: var(--text-muted);
}

.picker-controls {
  padding: 14px 16px 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.picker-controls .filter-input { font-size: 0.85rem; padding: 9px 12px; }
.picker-controls .filter-select-wrapper { width: 100%; }
.picker-controls .filter-select { font-size: 0.85rem; padding: 9px 12px; }

/* Character Thumbnail Grid */
.char-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  padding: 12px 16px 16px;
  max-height: 380px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-dark) transparent;
}

.char-thumb {
  /* Fixed height instead of aspect-ratio: prevents collapse on mobile browsers */
  height: 120px;
  border-radius: 5px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  border: 2px solid transparent;
  transition: all 0.15s;
  background: var(--bg-surface);
  display: flex;
  flex-direction: column;
}

.char-thumb img,
.char-thumb .char-placeholder {
  width: 100%;
  /* Grow to fill all space above the name label */
  flex: 1 1 auto;
  /* Explicit min-height prevents flex from collapsing the image area */
  min-height: 0;
  object-fit: cover;
  object-position: top center;
  display: block;
}

.char-thumb .char-placeholder {
  font-size: 1rem;
  min-height: unset;
}

/* Visible name label at bottom of each thumb */
.char-thumb-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 600;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  text-align: center;
  /* Roomier vertical rhythm so the label is not crammed against the edge */
  padding: 5px 6px 6px;
  min-height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Soft gradient instead of a hard pill so it never reads as a clipped bar */
  background: linear-gradient(to top, rgba(6, 8, 16, 0.96) 60%, rgba(6, 8, 16, 0) 100%);
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 100%;
  flex-shrink: 0;
}

.char-thumb:hover {
  border-color: rgba(240, 240, 245, 0.4);
  transform: scale(1.06);
  z-index: 2;
}

.char-thumb.selected-left {
  box-shadow: 0 0 15px rgba(212, 160, 23, 0.6), inset 0 0 0 2px var(--gold);
  border-color: var(--gold);
}

.char-thumb.selected-right {
  box-shadow: 0 0 15px rgba(230, 57, 70, 0.6), inset 0 0 0 2px var(--red);
  border-color: var(--red);
}

/* Tooltip */
.char-thumb-tooltip {
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--bg-deep);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 5px 10px;
  white-space: nowrap;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
  z-index: 10;
}
.char-thumb:hover .char-thumb-tooltip { opacity: 1; }

/* Analyze Button */
.analyze-btn-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-bottom: 36px;
}

/* ============================================================
   LOADING STATE
   ============================================================ */
.loading-panel {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 24px;
  text-align: center;
  gap: 24px;
}

.loading-panel.active { display: flex; }

.loading-pulse {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 3px solid var(--border);
  border-top-color: var(--gold);
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.loading-text {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--gold);
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}
.loading-text { animation: pulse 1.4s ease-in-out infinite; }

/* ============================================================
   RESULTS PANEL
   ============================================================ */
.results-panel {
  display: none;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.results-panel.visible {
  display: block;
  opacity: 1;
  transform: none;
}

/* VS Header */
.results-vs-header {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.vs-fighter {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  min-width: 120px;
}

.vs-portrait {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid transparent;
  background: var(--bg-surface);
  flex-shrink: 0;
}

.vs-fighter.my-fighter .vs-portrait { border-color: var(--gold); box-shadow: 0 0 20px rgba(212,160,23,0.4); }
.vs-fighter.opponent .vs-portrait { border-color: var(--red); box-shadow: 0 0 20px rgba(230,57,70,0.4); }

.vs-portrait img, .vs-portrait .char-placeholder {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}
.vs-portrait .char-placeholder { font-size: 2.5rem; }

.vs-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.3rem;
  text-transform: uppercase;
  text-align: center;
}

.vs-separator {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 2.5rem;
  color: var(--text-muted);
}

/* Summary Text — highlighted quote treatment */
.matchup-summary {
  position: relative;
  background: linear-gradient(135deg, rgba(212,160,23,0.10) 0%, var(--bg-surface) 55%);
  border: 1px solid var(--border);
  border-left: 4px solid var(--gold);
  border-radius: 0 10px 10px 0;
  padding: 26px 30px 26px 56px;
  margin-bottom: 24px;
  font-size: 1.02rem;
  color: var(--text-primary);
  line-height: 1.75;
  font-style: italic;
  box-shadow: 0 6px 24px rgba(0,0,0,0.25);
}

.matchup-summary::before {
  content: '\201C';
  position: absolute;
  left: 14px;
  top: 2px;
  font-family: 'Barlow Condensed', Georgia, serif;
  font-weight: 900;
  font-size: 4.2rem;
  line-height: 1;
  color: var(--gold);
  opacity: 0.55;
}

.matchup-summary p { margin: 0; }
.matchup-summary p + p { margin-top: 10px; }
.matchup-summary strong { color: var(--gold-light); font-style: normal; }

/* Gauge */
.gauge-section {
  position: relative;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(212,160,23,0.10) 0%, transparent 60%),
    var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 30px 32px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  margin-bottom: 24px;
  overflow: hidden;
}

.gauge-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-muted);
}

.gauge-display {
  display: flex;
  justify-content: center;
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.35));
}

#gaugeScoreText { transition: fill 0.6s ease; }

/* Difficulty badge — prominent, color-coded chip */
.gauge-badge {
  display: inline-block;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold);
  border: 2px solid var(--gold);
  border-radius: 6px;
  padding: 5px 18px;
  margin-top: 2px;
  background: rgba(212,160,23,0.10);
}

.gauge-caption {
  max-width: 420px;
  text-align: center;
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin-top: 4px;
}

.gauge-score-text {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Attribute Bars */
.attributes-section {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  padding: 24px 28px;
  margin-bottom: 24px;
}

.attributes-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.attr-row {
  display: grid;
  grid-template-columns: 1fr 100px 1fr;
  gap: 10px;
  align-items: center;
  margin-bottom: 14px;
}

.attr-bar-left {
  display: flex;
  justify-content: flex-end;
}

.attr-bar-right {
  display: flex;
  justify-content: flex-start;
}

.attr-bar-track {
  flex: 1;
  height: 10px;
  background: rgba(255,255,255,0.07);
  border-radius: 100px;
  overflow: hidden;
}

.attr-bar-fill {
  height: 100%;
  border-radius: 100px;
  width: 0;
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.attr-bar-fill.gold { background: var(--gold); }
.attr-bar-fill.red { background: var(--red); }

.attr-bar-left .attr-bar-track { direction: rtl; }
.attr-bar-left .attr-bar-fill { direction: ltr; transform-origin: right; }

.attr-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  text-align: center;
}

/* Analysis Sections — styled cards with accent + icon header.
   Every card is full-width and uniformly spaced for a cohesive, consistent layout. */
.analysis-sections {
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.analysis-block {
  --accent: var(--gold);
  position: relative;
  width: 100%;
  padding: 22px 24px 22px 26px;
  background:
    linear-gradient(120deg, color-mix(in srgb, var(--accent) 7%, transparent) 0%, transparent 40%),
    var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  margin-bottom: 0;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.analysis-block::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  border-radius: 10px 0 0 10px;
  background: var(--accent);
}

.analysis-block:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.32);
  border-color: color-mix(in srgb, var(--accent) 45%, transparent);
}

.analysis-block.neutral-game   { --accent: var(--blue); }
.analysis-block.advantages     { --accent: var(--gold); }
.analysis-block.disadvantages  { --accent: var(--red); }
.analysis-block.moves          { --accent: var(--amber); }
.analysis-block.combos         { --accent: var(--gold-light); }
.analysis-block.punish         { --accent: var(--green); }
.analysis-block.key-percents   { --accent: var(--purple); }
.analysis-block.edgeguard      { --accent: var(--blue); }
.analysis-block.mental-stack   { --accent: var(--amber); }

.analysis-block-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.05rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
  color: var(--accent);
}

/* Icon chip in each block header */
.block-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  border-radius: 7px;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 40%, transparent);
}

.block-icon svg { width: 17px; height: 17px; display: block; }

.analysis-block ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.analysis-block ul li {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.55;
  padding-left: 20px;
  position: relative;
}

.analysis-block ul li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 0.5em;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(45deg);
}

.analysis-block p {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.7;
}

.moves-list { display: flex; flex-direction: column; gap: 10px; }

.move-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  padding: 10px 14px;
}

.move-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 4px;
}

.move-threat {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Stage Tiles */
.stages-section { margin-bottom: 24px; }

.stages-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-primary);
  margin-bottom: 14px;
}

.stage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.stage-tile {
  border-radius: 8px;
  border: 1px solid var(--border-subtle);
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #1a1e35 0%, #221c2e 100%);
  display: flex;
  flex-direction: column;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.stage-tile:hover {
  transform: translateY(-3px);
  border-color: rgba(212,175,55,0.45);
  box-shadow: 0 10px 26px rgba(0,0,0,0.45);
}

/* Stage artwork thumbnail */
.stage-thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #11131f;
}

.stage-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stage-thumb::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,12,20,0) 45%, rgba(10,12,20,0.85) 100%);
  pointer-events: none;
}

.stage-tile-body {
  padding: 12px 16px 16px;
  position: relative;
}

.stage-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--gold);
  margin-bottom: 6px;
  position: relative;
}

.stage-pick-label {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  font-size: 0.66rem;
  font-weight: 800;
  font-family: 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #0c1a0e;
  background: var(--green);
  padding: 3px 9px;
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.stage-rationale {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
  position: relative;
}

/* Stage ban thumbnail */
.stage-ban-thumb {
  flex-shrink: 0;
  width: 96px;
  aspect-ratio: 16 / 10;
  border-radius: 6px;
  overflow: hidden;
  background: #11131f;
  border: 1px solid rgba(230,57,70,0.25);
}

.stage-ban-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: saturate(0.85) brightness(0.82);
}

.stage-ban-body {
  flex: 1 1 auto;
  min-width: 0;
}

/* Share Button */
.share-row {
  display: flex;
  justify-content: center;
  margin-top: 12px;
}

.btn-share {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 12px 28px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-share:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.btn-share.copied {
  border-color: var(--green);
  color: var(--green);
}

/* ============================================================
   AI FOLLOW-UP CHAT PANEL
   ============================================================ */
.chat-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  margin-top: 32px;
  overflow: hidden;
  display: none;
}

.chat-panel-header {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  padding: 16px 24px;
  display: flex;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
}

.chat-panel-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--gold);
}

.chat-panel-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0;
}

.chat-messages {
  min-height: 100px;
  max-height: 420px;
  overflow-y: auto;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  scrollbar-width: thin;
  scrollbar-color: var(--gold-dark) transparent;
}

.chat-messages::-webkit-scrollbar { width: 4px; }
.chat-messages::-webkit-scrollbar-track { background: transparent; }
.chat-messages::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 2px; }

.chat-welcome {
  background: rgba(212,160,23,0.05);
  border: 1px solid rgba(212,160,23,0.12);
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.chat-message {
  display: flex;
  flex-direction: column;
  gap: 4px;
  animation: chatFadeIn 0.2s ease;
}

@keyframes chatFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .chat-message { animation: none; }
}

.chat-message.user { align-items: flex-end; }
.chat-message.assistant { align-items: flex-start; }

.chat-bubble {
  max-width: 90%;
  border-radius: 8px;
  padding: 11px 15px;
  line-height: 1.65;
  font-size: 0.9rem;
}

.chat-message.user .chat-bubble {
  background: rgba(212,160,23,0.1);
  border: 1px solid rgba(212,160,23,0.22);
  color: var(--text-primary);
  border-radius: 8px 8px 3px 8px;
}

.chat-message.assistant .chat-bubble {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  color: var(--text-primary);
  border-radius: 8px 8px 8px 3px;
}

/* Markdown inside assistant bubbles */
.chat-bubble p { margin: 0 0 8px; }
.chat-bubble p:last-child { margin-bottom: 0; }
.chat-bubble ul, .chat-bubble ol { padding-left: 18px; margin: 6px 0; }
.chat-bubble li { margin-bottom: 4px; }
.chat-bubble strong { color: var(--gold-light); }

.chat-message-role {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.chat-message.user .chat-message-role { color: rgba(212,160,23,0.7); }
.chat-message.assistant .chat-message-role { color: var(--text-muted); }

.chat-input-row {
  display: flex;
  gap: 10px;
  padding: 12px 16px;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-subtle);
}

.chat-input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  padding: 10px 14px;
  outline: none;
  transition: border-color 0.2s;
}

.chat-input:focus { border-color: var(--gold); }
.chat-input::placeholder { color: var(--text-muted); opacity: 0.7; }
.chat-input:disabled { opacity: 0.5; }

.btn-chat-send {
  background: var(--gold);
  color: var(--bg-deep);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 10px 22px;
  border: 2px solid var(--gold);
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.btn-chat-send:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(212,160,23,0.3);
}

.btn-chat-send:active { transform: translateY(0); }

.btn-chat-send:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* Typing indicator */
.chat-typing-wrapper { align-items: flex-start; }

.chat-typing {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 12px 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px 8px 8px 3px;
}

.chat-typing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  animation: chatDotPulse 1.2s ease-in-out infinite;
}

.chat-typing-dot:nth-child(2) { animation-delay: 0.2s; }
.chat-typing-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes chatDotPulse {
  0%, 80%, 100% { transform: scale(0.65); opacity: 0.35; }
  40% { transform: scale(1); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .chat-typing-dot { animation: none; opacity: 0.7; }
}

/* Error display */
.error-panel {
  background: rgba(230, 57, 70, 0.1);
  border: 1px solid rgba(230, 57, 70, 0.3);
  border-radius: 8px;
  padding: 20px 24px;
  text-align: center;
  color: var(--red);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: none;
}

.error-panel.visible {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
}

/* Validation (info) tone — used when the user must still pick fighters */
.error-panel.validation {
  background: rgba(212, 160, 23, 0.1);
  border-color: rgba(212, 160, 23, 0.4);
  color: var(--gold-light);
}

/* Analyze button when the matchup is not yet ready: dimmed but still
   clickable so the click surfaces a clear "select your fighters" prompt. */
.btn-gold.not-ready {
  opacity: 0.55;
  box-shadow: none;
}
.btn-gold.not-ready:hover {
  transform: none;
  box-shadow: none;
  background: var(--gold);
  border-color: var(--gold);
}

/* Pulse cue drawing the eye to an empty picker panel that still needs a pick */
@keyframes pickerNeedsPick {
  0%, 100% { box-shadow: 0 0 0 0 rgba(212, 160, 23, 0); }
  50%      { box-shadow: 0 0 0 3px rgba(212, 160, 23, 0.55); }
}
.picker-panel.needs-pick {
  animation: pickerNeedsPick 0.9s ease-in-out 2;
  border-radius: 12px;
}
@media (prefers-reduced-motion: reduce) {
  .picker-panel.needs-pick { animation: none; box-shadow: 0 0 0 3px rgba(212, 160, 23, 0.55); }
}

.error-panel-text {
  display: block;
  line-height: 1.4;
}

.btn-retry {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #0e0a06;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  border: none;
  border-radius: 4px;
  padding: 9px 22px;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.2s ease, filter 0.2s ease;
}

.btn-retry:hover {
  filter: brightness(1.08);
  box-shadow: 0 4px 16px rgba(212, 160, 23, 0.4);
}

.btn-retry:active { transform: scale(0.96); }
.btn-retry:focus-visible { outline: 2px solid var(--gold-light); outline-offset: 2px; }

/* ============================================================
   RESPONSIVE BREAKPOINTS
   ============================================================ */

/* Tablet — 768px */
@media (max-width: 768px) {
  section { padding: 56px 0; }

  .nav-links { display: none; }
  .nav-hamburger { display: flex; flex-direction: column; }

  .hero-title { font-size: clamp(2.2rem, 7vw, 3.5rem); }

  .stats-grid { grid-template-columns: 1fr; }
  .stat-item { border-right: none; border-bottom: 1px solid var(--border-subtle); }
  .stat-item:last-child { border-bottom: none; }

  .roster-grid { grid-template-columns: repeat(3, 1fr); }

  .dual-picker { grid-template-columns: 1fr; }

  /* Stacked panels are now full-width — 4 cols, fixed-height cards */
  .char-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    /* 4 rows × 90px + gaps + padding ≈ 420px */
    max-height: 420px;
  }

  /* Fixed card height at tablet: ~76px wide col → 90px tall is comfortably portrait */
  .char-thumb {
    height: 90px;
  }

  .stage-grid { grid-template-columns: 1fr 1fr; }

  .results-vs-header { gap: 16px; }

  .attr-row { grid-template-columns: 1fr 80px 1fr; }

  .analysis-block { padding: 18px 18px 18px 20px; }
  .matchup-summary { padding: 22px 22px 22px 48px; font-size: 0.96rem; }
}

/* Mobile — 375px */
@media (max-width: 480px) {
  .hero-cta { flex-direction: column; align-items: center; }

  .roster-grid { grid-template-columns: repeat(2, 1fr); }

  /* 3 columns on small phones — ~109px wide col → 100px tall for good portrait crop */
  .char-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
    /* 5 rows × 100px + gaps + padding ≈ 580px — enough to show ~15 fighters */
    max-height: 560px;
  }

  /* Fixed card height at small phone: slightly taller because columns are wider */
  .char-thumb {
    height: 100px;
  }

  /* Larger name labels at this size */
  .char-thumb-name { font-size: 0.65rem; }

  /* Trim the selected-fighter display so the grid gets more breathing room */
  .picker-selected { height: 200px; }

  .stage-grid { grid-template-columns: 1fr; }

  .filter-bar { flex-direction: column; }
  .filter-group { flex: 1 1 100%; }

  .vs-separator { font-size: 1.8rem; }

  .gauge-section { padding: 20px; }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .flow-connector { animation: none; }
  .attr-bar-fill { transition: none; }
  .results-panel { transition: none; }
}

/* ============================================================
   ANALYSIS HISTORY BAR
   ============================================================ */
.analysis-history-bar {
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-subtle);
  padding: 16px 0;
}

.history-bar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.history-bar-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}

.history-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.history-item {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 10px 14px;
  transition: border-color 0.2s;
}
.history-item:hover { border-color: var(--border); }

.history-portraits {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.history-portrait-img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-subtle);
}

.history-portrait-placeholder {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-deep);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold);
  flex-shrink: 0;
  border: 2px solid var(--border-subtle);
}

.history-portrait-placeholder svg {
  width: 60%;
  height: 60%;
  opacity: 0.7;
}

.history-vs {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  flex-shrink: 0;
}

.history-info {
  flex: 1;
  min-width: 0;
}

.history-matchup {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.history-meta {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 3px;
  flex-wrap: wrap;
}

.history-diff {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 8px;
  border-radius: 100px;
}
.history-diff.diff-favorable { background: rgba(46,196,75,0.15); color: var(--green); border: 1px solid rgba(46,196,75,0.3); }
.history-diff.diff-even { background: rgba(212,160,23,0.12); color: var(--gold); border: 1px solid rgba(212,160,23,0.25); }
.history-diff.diff-challenging { background: rgba(244,162,97,0.12); color: var(--amber); border: 1px solid rgba(244,162,97,0.3); }
.history-diff.diff-very-challenging { background: rgba(230,57,70,0.12); color: var(--red); border: 1px solid rgba(230,57,70,0.3); }

.history-time { font-size: 0.75rem; color: var(--text-muted); }

.history-rerun {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 5px 12px;
  border-radius: 4px;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s;
  white-space: nowrap;
}
.history-rerun:hover { border-color: var(--gold); color: var(--gold); }

/* ============================================================
   SWAP BUTTON
   ============================================================ */
.btn-swap {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-swap:hover { border-color: var(--gold); color: var(--gold); }

/* ============================================================
   ANALYSIS BLOCK ACCENTS
   Single source of truth: each block's --accent drives the
   left rail, icon chip, and title color together.
   ============================================================ */
.analysis-block.neutral-game  { --accent: #4361ee; }
.analysis-block.combos        { --accent: var(--purple); }
.analysis-block.key-percents  { --accent: var(--amber); }
.analysis-block.mental-stack  { --accent: #06d6a0; }

/* Move counter field */
.move-counter {
  font-size: 0.82rem;
  color: var(--green);
  margin-top: 6px;
  line-height: 1.5;
}
.move-counter-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--green);
  margin-right: 4px;
}

/* ============================================================
   COMBO ROUTES
   ============================================================ */
.combo-route-item {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 12px 16px;
  margin-bottom: 10px;
}
.combo-route-item:last-child { margin-bottom: 0; }

.combo-starter {
  display: inline-block;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  color: var(--blue);
  background: rgba(67,97,238,0.12);
  border: 1px solid rgba(67,97,238,0.3);
  border-radius: 4px;
  padding: 3px 8px;
  margin-bottom: 6px;
}

.combo-route-text {
  font-size: 0.9rem;
  color: var(--text-primary);
  line-height: 1.5;
  margin-bottom: 8px;
}

.combo-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 6px;
}

.combo-badge {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 4px;
  letter-spacing: 0.04em;
}
.combo-badge-percent { background: rgba(244,162,97,0.12); color: var(--amber); border: 1px solid rgba(244,162,97,0.3); }
.combo-badge-damage { background: rgba(46,196,75,0.12); color: var(--green); border: 1px solid rgba(46,196,75,0.3); }

/* ============================================================
   KEY PERCENT CARDS
   ============================================================ */
.key-percents-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 8px;
}

.key-percent-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 14px 16px;
}

.key-percent-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
  display: block;
}

.key-percent-value {
  font-size: 0.85rem;
  color: var(--text-primary);
  line-height: 1.5;
}

/* ============================================================
   STAGE BANS
   ============================================================ */
.stages-subsection { margin-bottom: 20px; }
.stages-subsection:last-child { margin-bottom: 0; }

.stages-sublabel {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  margin-bottom: 10px;
}
.picks-label { color: var(--green); }
.bans-label { color: var(--red); }

.stage-bans-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stage-ban-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: rgba(230,57,70,0.05);
  border: 1px solid rgba(230,57,70,0.2);
  border-radius: 8px;
  padding: 12px 16px;
}

.stage-ban-header { flex-shrink: 0; }

.stage-ban-label {
  font-size: 0.7rem;
  font-weight: 700;
  font-family: 'Barlow Condensed', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--red);
  margin-bottom: 2px;
}

.stage-ban-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.95rem;
  text-transform: uppercase;
  color: var(--red);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.stage-ban-rationale {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
  padding-top: 4px;
}

/* ============================================================
   SHARE ROW UPDATE
   ============================================================ */
.share-row {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 12px;
}

/* ============================================================
   RESPONSIVE FOR NEW SECTIONS
   ============================================================ */
@media (max-width: 768px) {
  .key-percents-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 480px) {
  .key-percents-grid { grid-template-columns: 1fr; }
  .stage-ban-item { flex-direction: column; gap: 8px; }
  .stage-ban-thumb { width: 100%; aspect-ratio: 16 / 7; }
  .history-item { flex-wrap: wrap; }
  .analyze-btn-row { flex-direction: column; align-items: center; }
}

/* ============================================================
   HOW IT WORKS — EDITORIAL FLOW (tournament-ready design)
   ============================================================ */
.how-editorial-flow {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  padding: 12px 0 28px;
}

.how-stage {
  flex: 0 0 200px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 0 12px;
}

/* ── Stage 1: fighter select duel ── */
.how-select-duel {
  display: flex;
  align-items: center;
  gap: 8px;
}

.how-select-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 12px 10px;
  border-radius: 4px;
  border: 1.5px solid;
  min-width: 64px;
  background: var(--bg-surface);
  transition: box-shadow 0.2s;
}

.how-slot-gold {
  border-color: rgba(212,160,23,0.55);
  box-shadow: 0 0 12px rgba(212,160,23,0.08);
}
.how-slot-red {
  border-color: rgba(230,57,70,0.45);
  box-shadow: 0 0 12px rgba(230,57,70,0.08);
}

.how-slot-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  text-align: center;
  line-height: 1.25;
}
.how-slot-gold .how-slot-name { color: var(--gold); }
.how-slot-red .how-slot-name { color: var(--red); }

.how-duel-vs {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 1.1rem;
  color: var(--text-muted);
  text-align: center;
  flex-shrink: 0;
}

/* ── Stage 2: AI diamond node ── */
.how-ai-diamond {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 88px;
  height: 88px;
  filter: drop-shadow(0 0 8px rgba(212,160,23,0.25));
  animation: aiDiamondPulse 2.6s ease-in-out infinite;
}

@keyframes aiDiamondPulse {
  0%, 100% { filter: drop-shadow(0 0 8px rgba(212,160,23,0.25)); }
  50% { filter: drop-shadow(0 0 18px rgba(212,160,23,0.5)); }
}
@media (prefers-reduced-motion: reduce) {
  .how-ai-diamond { animation: none; filter: drop-shadow(0 0 8px rgba(212,160,23,0.3)); }
}

/* ── Stage 3: breakdown panel ── */
.how-breakdown-panel {
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 100%;
  max-width: 175px;
}

.how-breakdown-row {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.67rem;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  padding: 5px 10px 5px 12px;
  border-radius: 3px;
  border-left: 3px solid;
  background: rgba(255,255,255,0.04);
  color: var(--text-primary);
}
.hbr-gold { border-left-color: var(--gold); }
.hbr-amber { border-left-color: var(--amber); }
.hbr-purple { border-left-color: var(--purple); }
.hbr-blue { border-left-color: var(--blue); }

/* ── Stage labels ── */
.how-stage-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-primary);
  text-align: center;
  margin-top: 2px;
}

.how-stage-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.5;
  max-width: 190px;
}

/* ── Connector arrows ── */
.how-arrow-connector {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 56px;
  padding-top: 44px;
}

.how-conn-line {
  fill: none;
  stroke: var(--gold);
  stroke-width: 1.5;
  stroke-dasharray: 6 3;
  opacity: 0.6;
  animation: dashFlow 1.8s linear infinite;
}

@media (max-width: 768px) {
  .how-editorial-flow {
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 8px 16px 24px;
  }
  .how-stage { flex: none; width: 100%; max-width: 300px; }
  .how-arrow-connector {
    width: auto;
    height: 36px;
    padding-top: 0;
    transform: rotate(90deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .how-conn-line { animation: none; }
}

/* ============================================================
   MATCHUP ANATOMY TIMELINE
   ============================================================ */
.matchup-anatomy {
  background: var(--bg-deep);
  border-top: 1px solid var(--border-subtle);
  padding: 80px 0;
}

.matchup-anatomy .section-sub {
  margin: 0 auto;
  margin-bottom: 56px;
  text-align: center;
}

/* Desktop: horizontal timeline */
.anatomy-timeline {
  position: relative;
  padding: 0 16px;
}

.anatomy-rail-track {
  position: absolute;
  top: 20px;
  left: 48px;
  right: 48px;
  height: 2px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
}

.anatomy-rail-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(to right, var(--gold), var(--gold-dark));
  border-radius: 2px;
  transition: width 1.4s cubic-bezier(0.4,0,0.2,1);
}

.anatomy-milestones {
  display: flex;
  justify-content: space-between;
  position: relative;
  z-index: 1;
}

.anatomy-milestone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  flex: 0 0 calc(20% - 8px);
  max-width: 160px;
}

.anatomy-dot {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid rgba(212,160,23,0.25);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: border-color 0.4s, background 0.4s;
}

.anatomy-dot-inner {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(212,160,23,0.3);
  transition: background 0.4s;
}

.anatomy-milestone.active .anatomy-dot {
  border-color: var(--gold);
  box-shadow: 0 0 12px rgba(212,160,23,0.4);
}

.anatomy-milestone.active .anatomy-dot-inner {
  background: var(--gold);
}

.anatomy-num {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  color: var(--gold);
  opacity: 0.6;
}

.anatomy-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  text-align: center;
}

.anatomy-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.45;
}

/* Mobile: vertical timeline */
@media (max-width: 768px) {
  .anatomy-rail-track {
    top: 20px;
    left: 32px;
    right: auto;
    bottom: 20px;
    width: 2px;
    height: auto;
  }
  .anatomy-rail-fill {
    width: 100%;
    height: 0%;
    transition: height 1.4s cubic-bezier(0.4,0,0.2,1);
  }
  .anatomy-milestones {
    flex-direction: column;
    gap: 32px;
    padding-left: 60px;
  }
  .anatomy-milestone {
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
    flex: none;
    max-width: 100%;
  }
  .anatomy-milestone .anatomy-dot {
    flex-shrink: 0;
    margin-left: -60px;
  }
  .anatomy-milestone .anatomy-label,
  .anatomy-milestone .anatomy-desc,
  .anatomy-milestone .anatomy-num {
    text-align: left;
  }
}

@media (prefers-reduced-motion: reduce) {
  .anatomy-rail-fill { transition: none; width: 100%; height: 100%; }
  .anatomy-milestone.active .anatomy-dot { box-shadow: none; }
}

/* ============================================================
   SERIES BREAKDOWN — Proof/Metric Composition
   ============================================================ */
.series-breakdown {
  max-width: 680px;
  margin: 48px auto 0;
  padding: 0 24px;
}

.series-breakdown-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--text-muted);
  margin-bottom: 20px;
  text-align: center;
}

.series-bar-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.series-bar-row {
  display: grid;
  grid-template-columns: 120px 1fr 32px;
  align-items: center;
  gap: 12px;
}

.series-bar-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  text-align: right;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.series-bar-track {
  height: 8px;
  background: rgba(255,255,255,0.06);
  border-radius: 100px;
  overflow: hidden;
}

.series-bar-fill {
  height: 100%;
  border-radius: 100px;
  width: 0%;
  background: linear-gradient(to right, var(--gold-dark), var(--gold));
  transition: width 1s cubic-bezier(0.4,0,0.2,1);
}

.series-bar-count {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.9rem;
  color: var(--gold);
  text-align: left;
}

.series-caption {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  margin-top: 20px;
  line-height: 1.5;
}

@media (prefers-reduced-motion: reduce) {
  .series-bar-fill { transition: none; width: var(--target-width, 0%); }
}

/* ============================================================
   ARCHETYPE TAXONOMY — Collection Visual System
   ============================================================ */
.archetype-taxonomy {
  margin-bottom: 20px;
}

.archetype-filter-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.archetype-tab {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 6px 16px;
  border-radius: 3px;
  border: 1.5px solid var(--border-subtle);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.18s;
}

.archetype-tab:hover {
  border-color: var(--gold);
  color: var(--gold);
}

.archetype-tab.active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}

.fighter-tile.hidden-by-filter {
  display: none;
}

.archetype-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 3px 7px;
  border-radius: 2px;
  background: rgba(8,10,20,0.75);
  backdrop-filter: blur(4px);
}

/* Fighter tiles: hide floating badge, use accent bar for archetype color instead */
.fighter-tile .archetype-badge {
  display: none;
}

/* Color-code tile accent bar by archetype */
.fighter-tile[data-archetype="rushdown"] .tile-accent { background: var(--gold); }
.fighter-tile[data-archetype="zoner"] .tile-accent { background: var(--blue); }
.fighter-tile[data-archetype="brawler"] .tile-accent { background: var(--amber); }
.fighter-tile[data-archetype="heavyweight"] .tile-accent { background: var(--red); }
.fighter-tile[data-archetype="other"] .tile-accent { background: rgba(136,136,170,0.6); }

.archetype-badge.rushdown { color: var(--gold); border: 1px solid rgba(212,160,23,0.4); }
.archetype-badge.zoner { color: var(--blue); border: 1px solid rgba(67,97,238,0.4); }
.archetype-badge.brawler { color: var(--amber); border: 1px solid rgba(244,162,97,0.4); }
.archetype-badge.heavyweight { color: var(--red); border: 1px solid rgba(230,57,70,0.4); }
.archetype-badge.other { color: var(--text-muted); border: 1px solid rgba(136,136,170,0.3); }

/* ============================================================
   ATTRIBUTE COMPARISON — AI Estimate disclaimer
   ============================================================ */
.attributes-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.attributes-header .attributes-title {
  margin-bottom: 0;
}

.ai-estimate-badge {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 3px 10px;
  border-radius: 2px;
  background: rgba(244,162,97,0.1);
  color: var(--amber);
  border: 1px solid rgba(244,162,97,0.3);
}

.attr-disclaimer {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  margin-top: 16px;
  margin-bottom: 0;
  line-height: 1.4;
}

/* ============================================================
   RADAR CHART
   ============================================================ */
.radar-chart-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
  align-items: stretch;
}

.radar-chart-wrapper {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 20px 16px 16px;
  margin-bottom: 24px;
  text-align: center;
}

.radar-chart-row .radar-chart-wrapper {
  margin-bottom: 0;
}

/* Subtle reveal: polygons draw in once when a chart renders */
.radar-poly {
  transform-box: fill-box;
  transform-origin: center;
  animation: radarPolyReveal 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.radar-poly-opp { animation-delay: 0.05s; }
.radar-poly-my { animation-delay: 0.15s; }

@keyframes radarPolyReveal {
  from { opacity: 0; transform: scale(0.55); }
  to { opacity: 1; transform: scale(1); }
}

@media (max-width: 768px) {
  .radar-chart-row {
    grid-template-columns: 1fr;
    gap: 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .radar-poly { animation: none; }
}

.radar-chart-title {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.radar-legend {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.radar-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.radar-dot.gold-dot { background: var(--gold); }
.radar-dot.red-dot { background: var(--red); }

.radar-legend-name {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* ============================================================
   ROSTER CARD WEIGHT-CLASS INDICATOR
   ============================================================ */
.fighter-card-weight-bar {
  height: 3px;
  width: 100%;
  border-radius: 0 0 2px 2px;
}
.fighter-card-weight-bar.lightweight { background: var(--gold); }
.fighter-card-weight-bar.middleweight { background: var(--amber); }
.fighter-card-weight-bar.heavyweight { background: #e87040; }
.fighter-card-weight-bar.super-heavyweight { background: var(--red); }

.fighter-card-tier-chip {
  position: absolute;
  top: 8px;
  left: 8px;
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 2px 7px;
  border-radius: 3px;
  z-index: 2;
  line-height: 1.4;
  pointer-events: none;
}
.tier-chip-s { background: rgba(46,196,75,0.85); color: #fff; }
.tier-chip-a { background: rgba(212,160,23,0.85); color: #000; }
.tier-chip-b { background: rgba(67,97,238,0.85); color: #fff; }
.tier-chip-c { background: rgba(155,93,229,0.7); color: #fff; }
.tier-chip-d { background: rgba(244,162,97,0.75); color: #000; }
.tier-chip-e { background: rgba(230,57,70,0.8); color: #fff; }

/* Roster group band headers */
.roster-group-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 20px 0 10px;
  margin-top: 12px;
}
.roster-group-header:first-child { margin-top: 0; padding-top: 8px; }
.roster-group-label {
  font-family: 'Barlow Condensed', sans-serif;
  font-weight: 900;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
}
.roster-group-line {
  flex: 1;
  height: 1px;
  background: var(--border-subtle);
}
.roster-group-line.lightweight-line { background: var(--gold); opacity: 0.3; }
.roster-group-line.middleweight-line { background: var(--amber); opacity: 0.3; }
.roster-group-line.heavyweight-line { background: #e87040; opacity: 0.3; }
.roster-group-line.super-heavyweight-line { background: var(--red); opacity: 0.3; }

/* Nav scroll-hide */
.site-nav.nav-hidden { transform: translateY(-100%); }

/* Picker silhouette color */
.picker-silhouette { color: var(--gold); }

/* Fighter card img position for tier chip */
.fighter-card-img { position: relative; }

/* Weight bar at bottom of card image */
.fighter-card-weight-bar { position: absolute; bottom: 0; left: 0; right: 0; height: 3px; }

/* Reveal classes for sections */
.how-it-works .container,
.fighter-strip-section .container,
.matchup-anatomy .container,
.cta-section .container,
.roster-section .container,
.analyzer-section .container {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.how-it-works .container.revealed,
.fighter-strip-section .container.revealed,
.matchup-anatomy .container.revealed,
.cta-section .container.revealed,
.roster-section .container.revealed,
.analyzer-section .container.revealed {
  opacity: 1;
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .how-it-works .container,
  .fighter-strip-section .container,
  .matchup-anatomy .container,
  .cta-section .container,
  .roster-section .container,
  .analyzer-section .container { opacity: 1; transform: none; }
}
