/* ============================================
   OSTALBZOCKER - Stadium Nights Theme
   ============================================ */

/* --- Font Faces --- */
@font-face {
  font-family: 'Bebas Neue';
  src: url('../fonts/BebasNeue-Regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'DM Sans';
  src: url('../fonts/DMSans-Regular.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* --- CSS Custom Properties --- */
:root {
  /* Gold Palette (preserved) */
  --gold: #cba03f;
  --gold-light: #e4c56a;
  --gold-dark: #a07d2e;
  --gold-glow: rgba(203, 160, 63, 0.4);
  
  /* Podium Colors */
  --silver: #c0c0c0;
  --bronze: #cd7f32;
  
  /* Dark Theme (Default) */
  --bg-primary: #0a0a0a;
  --bg-secondary: #111111;
  --bg-card: rgba(17, 17, 17, 0.85);
  --bg-elevated: #1a1a1a;
  --text-primary: #ffffff;
  --text-secondary: #b0b0b0;
  --text-muted: #707070;
  --border-color: rgba(255, 255, 255, 0.08);
  --border-accent: rgba(203, 160, 63, 0.3);
  
  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --shadow-gold: 0 0 30px rgba(203, 160, 63, 0.15);
  
  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  
  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow: 400ms ease;
  
  /* Typography */
  --font-display: 'Bebas Neue', Impact, sans-serif;
  --font-body: 'DM Sans', system-ui, -apple-system, sans-serif;
}


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

html {
  scroll-behavior: smooth;
  scrollbar-color: var(--gold) var(--bg-secondary);
  scrollbar-width: thin;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Background Pattern (Stadium Lines) with Parallax --- */
body::before {
  content: '';
  position: fixed;
  /* Extend beyond viewport for parallax room */
  top: -20%;
  left: 0;
  right: 0;
  bottom: -20%;
  pointer-events: none;
  background:
    /* Diagonal golden lines - subtler, wider spacing */
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 200px,
      rgba(203, 160, 63, 0.14) 200px,
      transparent 201px
    ),
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 200px,
      rgba(203, 160, 63, 0.10) 200px,
      transparent 201px
    ),
    /* Corner glows - wider, softer */
    radial-gradient(ellipse 1100px 750px at 0% 0%, rgba(203, 160, 63, 0.10), transparent 60%),
    radial-gradient(ellipse 1100px 750px at 100% 100%, rgba(203, 160, 63, 0.08), transparent 60%);
  opacity: 0.55;
  z-index: -1;
  /* Parallax effect via JS - uses background-position instead of transform */
  background-position-y: var(--parallax-offset, 0);
  transition: background-position-y 0.05s linear;
}


/* --- Scrollbar (WebKit) --- */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--gold-light), var(--gold));
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--gold-light), var(--gold-dark));
}

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.1;
}

h1 { font-size: clamp(3rem, 8vw, 5.5rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 3vw, 1.5rem); }

a {
  color: var(--gold);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover {
  color: var(--gold-light);
}

/* --- Layout --- */
.wrap {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}


/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold) 100%);
  color: #0a0a0a;
  box-shadow: var(--shadow-md), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.5s ease;
}

@media (hover: hover) {
  .btn-primary:hover::before {
    left: 100%;
  }

  .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg), 0 0 20px var(--gold-glow);
  }
}

.btn-ghost {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-ghost:hover {
  border-color: var(--gold);
  background: var(--bg-card);
}

.btn-sm {
  padding: var(--space-sm) var(--space-md);
  font-size: 0.85rem;
}

.btn.is-loading {
  opacity: 0.7;
  pointer-events: none;
}

.btn.is-loading::before {
  content: '';
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-right: 8px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  vertical-align: -2px;
}

/* --- Hero Section --- */
.hero {
  padding: var(--space-3xl) 0;
  position: relative;
  overflow: hidden;
}

.hero > .wrap {
  position: relative;
  z-index: 1;
}

/* Wandernder Gold-Blob im Hero — atmosphärische Hintergrund-Schicht */
.hero-blob {
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(203, 160, 63, 0.22) 0%, transparent 70%);
  filter: blur(120px);
  pointer-events: none;
  z-index: 0;
  top: 50%;
  left: 50%;
  margin-left: -300px;
  margin-top: -300px;
  animation: blobDrift 45s ease-in-out infinite;
  will-change: transform;
}

@keyframes blobDrift {
  0%   { transform: translate(-30%, -25%); }
  18%  { transform: translate(35%, -20%); }
  36%  { transform: translate(45%, 25%); }
  54%  { transform: translate(10%, 35%); }
  72%  { transform: translate(-35%, 18%); }
  88%  { transform: translate(-40%, -20%); }
  100% { transform: translate(-30%, -25%); }
}

@media (max-width: 768px) {
  .hero-blob {
    width: 400px;
    height: 400px;
    margin-left: -200px;
    margin-top: -200px;
  }
}

/* Vignette: dunkelt die Hero-Ränder ab, fokussiert auf Wappen + Headline */
.hero-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(ellipse 90% 80% at center, transparent 40%, rgba(0, 0, 0, 0.45) 100%);
}

/* Cursor-Spotlight (Desktop) — radialer Goldschimmer, der dem Cursor folgt */
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(
    circle 380px at var(--mx, 50%) var(--my, 35%),
    rgba(203, 160, 63, 0.16),
    rgba(203, 160, 63, 0.06) 35%,
    transparent 70%
  );
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 0;
}

.hero.spotlight-active::after {
  opacity: 1;
}

/* Hero-Partikel-Schicht */
.hero-particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

.hero-particle {
  position: absolute;
  bottom: -8px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--gold-light);
  box-shadow: 0 0 8px 1px rgba(203, 160, 63, 0.55);
  opacity: 0;
  animation: particleDrift infinite;
  will-change: transform, opacity;
}

/* Organische Bewegung: mehrere Sway-Stops mit Sinus-artig versetzten X-Werten,
   pro Partikel über CSS-Custom-Properties individualisiert. */
@keyframes particleDrift {
  0%   { transform: translate(0, 0); opacity: 0; }
  8%   { opacity: var(--peak-opacity, 0.8); }
  20%  { transform: translate(var(--sway-1, 0px), -16vh); opacity: var(--peak-opacity, 0.8); }
  40%  { transform: translate(var(--sway-2, 0px), -36vh); }
  55%  { opacity: var(--peak-opacity, 0.8); }
  60%  { transform: translate(var(--sway-3, 0px), -54vh); }
  80%  { transform: translate(var(--sway-4, 0px), -70vh); opacity: calc(var(--peak-opacity, 0.8) * 0.55); }
  100% { transform: translate(var(--drift-x, 0px), calc(var(--drift-distance, 75vh) * -1)); opacity: 0; }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-2xl);
  align-items: center;
}

.hero-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-full);
  width: fit-content;
  backdrop-filter: blur(10px);
}

.kicker svg {
  color: var(--gold);
  flex-shrink: 0;
}

.kicker small {
  font-size: 0.85rem;
  color: var(--text-secondary);
  white-space: nowrap;
}

.hero h1 {
  color: var(--text-primary);
  text-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.hero h1 span {
  background: linear-gradient(
    90deg,
    var(--gold) 0%,
    var(--gold-light) 35%,
    #f4dca5 50%,
    var(--gold-light) 65%,
    var(--gold) 100%
  );
  background-size: 200% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: titleShimmer 9s ease-in-out infinite;
}

/* Shimmer effect on "ZOCKER" - moving gradient */
@keyframes titleShimmer {
  0%, 100% { background-position: 100% 0; }
  50% { background-position: 0% 0; }
}

/* --- Hero: Stats-Strip --- */
.hero-stats {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.55rem;
  margin-top: 0.45rem;
  padding: 0.5rem 0.85rem;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-full);
  width: fit-content;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.hero-stat {
  display: inline-flex;
  align-items: baseline;
  gap: 0.35rem;
}

.hero-stat-value {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  color: var(--gold);
  line-height: 1;
}

.hero-stat-label {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.hero-stat-sep {
  color: rgba(255, 255, 255, 0.18);
  font-size: 0.95rem;
  user-select: none;
}

@media (max-width: 600px) {
  .hero-stats {
    padding: 0.4rem 0.7rem;
    gap: 0.35rem;
  }
  .hero-stat-value { font-size: 1.05rem; }
  .hero-stat-label { font-size: 0.62rem; letter-spacing: 0.12em; }
}

/* --- Shield / Logo --- */
/* Layer trennung: .shield = perspective host, .shield-inner = float (translateY),
   .logo = glow (filter) + tilt/easter-spin (rotate). Verhindert transform-Konflikte. */
.shield {
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1200px;
}

.shield-inner {
  display: flex;
  justify-content: center;
  width: 100%;
  animation: float 6s ease-in-out infinite;
}

.shield .logo {
  width: 100%;
  max-width: 380px;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5));
  animation: logoGlow 12s ease-in-out infinite;
  transform: rotateX(var(--tilt-x, 0deg)) rotateY(var(--tilt-y, 0deg));
  transition: transform 200ms ease-out;
  transform-style: preserve-3d;
  will-change: transform;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

/* Easter-Egg: 360°-Drehung + Gold-Pulse beim 10. Klick */
@keyframes shieldEasterSpin {
  0% {
    transform: rotateY(0);
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5));
  }
  50% {
    transform: rotateY(180deg);
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5))
            drop-shadow(0 0 60px rgba(203, 160, 63, 0.95));
  }
  100% {
    transform: rotateY(360deg);
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5));
  }
}

.shield .logo.easter-spin {
  /* Überschreibt während der Animation float-Tilt und logoGlow */
  animation: shieldEasterSpin 1.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Logo Glow Pulse */
@keyframes logoGlow {
  0%, 100% { 
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5)) 
            drop-shadow(0 0 20px rgba(203, 160, 63, 0));
  }
  50% { 
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5)) 
            drop-shadow(0 0 40px rgba(203, 160, 63, 0.3));
  }
}

/* --- Champion-Pin (Saisonende-Modus) --- */
.champion-pin {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.25), rgba(203, 160, 63, 0.05));
  border: 1px solid var(--gold);
  border-radius: var(--radius-md);
  width: fit-content;
  box-shadow: 0 0 24px rgba(203, 160, 63, 0.3);
  animation: championPinPulse 3s ease-in-out infinite;
}

@keyframes championPinPulse {
  0%, 100% { box-shadow: 0 0 24px rgba(203, 160, 63, 0.3); }
  50%      { box-shadow: 0 0 40px rgba(203, 160, 63, 0.6); }
}

.champion-trophy {
  width: 32px;
  height: 32px;
  color: var(--gold);
  flex-shrink: 0;
}

.champion-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}

.champion-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-secondary);
}

.champion-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--gold);
  letter-spacing: 0.03em;
  line-height: 1.1;
}

.champion-season {
  font-size: 0.8rem;
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .champion-pin {
    align-self: center;
    text-align: center;
  }
  .champion-text {
    align-items: center;
  }
}

.season-ended-note {
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: 0.12em;
  color: var(--text-secondary);
  margin-top: var(--space-md);
}

/* --- Countdown Section --- */
.countdown-wrapper {
  margin-top: var(--space-lg);
}

.countdown-label {
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  margin-bottom: var(--space-xs);
}

.countdown-meta {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: var(--space-md);
}

.countdown {
  display: flex;
  align-items: baseline;
  gap: var(--space-xl);
  flex-wrap: wrap;
}

.counter {
  flex: 0 0 auto;
  min-width: 60px;
  text-align: center;
  position: relative;
  background: none;
  border: none;
  padding: 0;
}

/* Dezente Trennlinien zwischen den Countern - konstante Höhe trotz unterschiedlicher Counter-Größen */
.counter:not(:last-child)::after {
  content: '';
  position: absolute;
  right: calc(var(--space-xl) * -0.5);
  top: 50%;
  transform: translateY(-50%);
  height: 2.4rem;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--border-accent) 30%, var(--border-accent) 70%, transparent);
  pointer-events: none;
}

.counter b {
  display: block;
  font-family: var(--font-display);
  font-size: 2rem;
  color: var(--gold);
  letter-spacing: 0.05em;
  line-height: 1;
  transform-style: preserve-3d;
}

/* Visuelle Hierarchie: Tage XL und hell, Sekunden klein und gedimmt */
.counter:nth-child(1) b {
  font-size: 3.4rem;
  color: var(--gold-light);
  text-shadow: 0 2px 16px rgba(203, 160, 63, 0.25);
}

.counter:nth-child(2) b {
  font-size: 2.6rem;
}

.counter:nth-child(3) b {
  font-size: 2rem;
}

.counter:nth-child(4) b {
  font-size: 1.4rem;
  color: var(--gold-dark);
  opacity: 0.75;
}

.counter:nth-child(4) span {
  opacity: 0.75;
}

/* Flip animation only for seconds (last counter) */
.counter:last-child b {
  animation: flipNumber 0.3s ease-out;
}

@keyframes flipNumber {
  0% {
    transform: translateY(-8px) scale(1.15);
    opacity: 0.5;
  }
  100% {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.counter span {
  display: block;
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin-top: var(--space-xs);
}

/* Urgent: Glow auf den Zahlen statt Box-Pulse (es gibt keine Box mehr) */
.countdown.urgent .counter b {
  animation: counterPulse 1.5s ease-in-out infinite;
  color: var(--gold-light);
}

@keyframes counterPulse {
  0%, 100% { text-shadow: 0 0 0 rgba(203, 160, 63, 0); }
  50% { text-shadow: 0 0 24px rgba(203, 160, 63, 0.7); }
}

/* Imminent: letzte 60 s — intensiverer Pulse + Sekunden-Bounce + Hero-Flash */
.countdown.imminent .counter b {
  animation: counterPulseStrong 1s ease-in-out infinite;
}

@keyframes counterPulseStrong {
  0%, 100% { text-shadow: 0 0 4px rgba(203, 160, 63, 0.4); }
  50%      { text-shadow: 0 0 32px rgba(203, 160, 63, 1); }
}

@keyframes tickBounce {
  0%   { transform: translateY(0) scale(1); }
  30%  { transform: translateY(-3px) scale(1.18); color: var(--gold-light); }
  100% { transform: translateY(0) scale(1); }
}

.counter:last-child b.tick-bounce {
  animation: tickBounce 0.55s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes imminentFlash {
  0%, 100% { box-shadow: inset 0 0 0 rgba(203, 160, 63, 0); }
  25%      { box-shadow: inset 0 0 120px rgba(203, 160, 63, 0.10); }
}

.hero.imminent-flash {
  animation: imminentFlash 0.6s ease-out;
}

/* --- Sections --- */
section {
  padding: var(--space-3xl) 0;
  position: relative;
}

section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 800px);
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  animation: sectionLinePulse 3s ease-in-out infinite;
}

/* Section Line Pulse */
@keyframes sectionLinePulse {
  0%, 100% { 
    opacity: 0.4;
    box-shadow: 0 0 10px rgba(203, 160, 63, 0);
  }
  50% { 
    opacity: 0.9;
    box-shadow: 0 0 20px rgba(203, 160, 63, 0.5);
  }
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-2xl);
}

.section-header h2 {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  color: var(--text-primary);
}

.section-header h2 svg {
  width: 1.2em;
  height: 1.2em;
  color: var(--gold);
}

.section-header .sub {
  color: var(--text-secondary);
  margin-top: var(--space-sm);
}

/* --- Top-3-Podest --- */
.podium {
  display: grid;
  grid-template-columns: 1fr 1.15fr 1fr;
  gap: var(--space-md);
  align-items: end;
  max-width: 720px;
  margin: 0 auto var(--space-xl);
}

.podium-card {
  position: relative;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(0, 0, 0, 0.2));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-sm) var(--space-lg);
  text-align: center;
  cursor: pointer;
  transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

@media (hover: hover) {
  .podium-card:hover {
    transform: translateY(-3px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-md), 0 0 24px rgba(203, 160, 63, 0.18);
  }
}

.podium-card:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.podium-rank-1 {
  border-color: rgba(203, 160, 63, 0.45);
  background: linear-gradient(180deg, rgba(203, 160, 63, 0.18), rgba(203, 160, 63, 0.02) 60%, transparent);
  box-shadow: 0 0 30px rgba(203, 160, 63, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  min-height: 240px;
  padding-bottom: var(--space-xl);
}

.podium-rank-2 {
  border-color: rgba(192, 192, 192, 0.3);
  background: linear-gradient(180deg, rgba(192, 192, 192, 0.10), transparent 60%);
  min-height: 200px;
}

.podium-rank-3 {
  border-color: rgba(205, 127, 50, 0.3);
  background: linear-gradient(180deg, rgba(205, 127, 50, 0.10), transparent 60%);
  min-height: 180px;
}

.podium-trophy {
  width: 28px;
  height: 28px;
}

.podium-trophy svg {
  width: 100%;
  height: 100%;
}

.podium-rank-1 .podium-trophy { color: var(--gold); }
.podium-rank-2 .podium-trophy { color: var(--silver); }
.podium-rank-3 .podium-trophy { color: var(--bronze); }

.podium-rank-numeral {
  font-family: var(--font-display);
  font-size: 2.2rem;
  line-height: 1;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

.podium-rank-1 .podium-rank-numeral { color: var(--gold); font-size: 2.8rem; }
.podium-rank-2 .podium-rank-numeral { color: var(--silver); }
.podium-rank-3 .podium-rank-numeral { color: var(--bronze); }

.podium-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-primary);
  letter-spacing: 0.02em;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 0 4px;
}

.podium-rank-1 .podium-name { font-size: 1.05rem; }

.podium-points {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}

.podium-points b {
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--gold);
  line-height: 1;
  letter-spacing: 0.03em;
  font-variant-numeric: tabular-nums;
}

.podium-rank-1 .podium-points b { font-size: 1.9rem; }

.podium-points span {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Tie-Indikator unten in der Podium-Card (z.B. "& Hauspu" oder "+2 geteilt") */
.podium-tie {
  margin-top: 4px;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.85;
}
.podium-rank-1 .podium-tie { color: var(--gold-light); }
.podium-rank-2 .podium-tie { color: var(--silver); }
.podium-rank-3 .podium-tie { color: var(--bronze); }

/* Olympic-Luecke: Slot leer, weil hoeherer Rang doppelt belegt */
.podium-card.podium-empty {
  opacity: 0.42;
  filter: grayscale(0.55);
  cursor: default;
}
.podium-card.podium-empty .podium-trophy { opacity: 0.35; }
.podium-card.podium-empty:hover { transform: none; }

/* Highlight-Pulse für angesprungene Tabellenzeile */
.stand-row.podium-highlight {
  animation: rowHighlight 1.2s ease-out;
}

@keyframes rowHighlight {
  0% { background: rgba(203, 160, 63, 0.4); }
  100% { background: transparent; }
}

@media (max-width: 560px) {
  .podium {
    grid-template-columns: 1fr;
    max-width: 320px;
    gap: var(--space-sm);
  }
  .podium-rank-1,
  .podium-rank-2,
  .podium-rank-3 {
    min-height: 0;
    padding: var(--space-md);
  }
  /* Reihenfolge: 1, 2, 3 */
  .podium-rank-1 { order: 1; }
  .podium-rank-2 { order: 2; }
  .podium-rank-3 { order: 3; }
  .podium-card {
    flex-direction: row;
    text-align: left;
    gap: var(--space-md);
    align-items: center;
  }
  .podium-points {
    margin-top: 0;
    margin-left: auto;
    align-items: flex-end;
  }
  .podium-name {
    flex: 1;
    min-width: 0;
  }
}

/* --- Titelverteidiger-Banner --- */
.defender-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  max-width: 600px;
  margin: 0 auto var(--space-lg);
  padding: var(--space-sm) var(--space-lg);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.18), rgba(203, 160, 63, 0.04));
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  text-align: center;
  flex-wrap: wrap;
}

.defender-banner .defender-head {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
}

.defender-banner svg {
  width: 20px;
  height: 20px;
  color: var(--gold);
  flex-shrink: 0;
}

.defender-banner .defender-label {
  color: var(--text-muted);
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  font-weight: 600;
}

.defender-banner .defender-name {
  font-weight: 700;
  color: var(--gold);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.defender-banner .defender-season {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.defender-banner .defender-season::before {
  content: '· ';
  margin-right: 2px;
}

@media (max-width: 480px) {
  .defender-banner {
    flex-direction: column;
    gap: 4px;
    border-radius: var(--radius-md);
    padding: var(--space-md) var(--space-md);
  }
  .defender-banner .defender-name {
    font-size: 1.15rem;
  }
  .defender-banner .defender-season::before {
    content: '';
    margin-right: 0;
  }
}

/* --- Saison-Fortschrittsbalken --- */
.season-progress {
  margin: 0 0 var(--space-lg);
}

.season-progress-meta {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-sm);
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.season-progress-phase {
  flex: 1;
  text-align: center;
  font-size: 0.7rem;
  color: var(--text-secondary);
  letter-spacing: 0.12em;
  font-style: italic;
}

.season-progress-label strong {
  color: var(--gold);
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  margin: 0 2px;
}

.season-progress-pct {
  font-family: var(--font-display);
  font-size: 0.9rem;
  color: var(--text-secondary);
  letter-spacing: 0.05em;
}

.season-progress-track {
  position: relative;
  height: 6px;
  background: var(--bg-elevated);
  border-radius: var(--radius-full);
  overflow: hidden;
  /* Tick-Marks alle 1/34 = ~2.94% */
  background-image:
    repeating-linear-gradient(
      90deg,
      transparent 0,
      transparent calc(100% / 34 - 1px),
      rgba(255, 255, 255, 0.05) calc(100% / 34 - 1px),
      rgba(255, 255, 255, 0.05) calc(100% / 34)
    );
}

.season-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light));
  border-radius: var(--radius-full);
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 8px rgba(203, 160, 63, 0.4);
}

.season-progress-marker {
  position: absolute;
  top: 50%;
  width: 12px;
  height: 12px;
  background: var(--gold-light);
  border: 2px solid var(--bg-primary);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  box-shadow: 0 0 12px rgba(203, 160, 63, 0.7);
  transition: left 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Saisonkalender --- */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(72px, 1fr));
  gap: var(--space-sm);
}

.match-day-pill {
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: var(--space-sm) var(--space-xs);
  text-align: center;
  position: relative;
  transition: border-color var(--transition-fast), transform var(--transition-fast);
}

@media (hover: hover) {
  .match-day-pill:hover {
    border-color: var(--border-accent);
    transform: translateY(-1px);
  }
}

.match-day-pill .md-weekday {
  display: block;
  font-family: var(--font-display);
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 3px;
}

.match-day-pill .md-number {
  display: block;
  font-family: var(--font-display);
  font-size: 1.4rem;
  color: var(--gold);
  letter-spacing: 0.05em;
  line-height: 1;
}

.match-day-pill .md-date {
  display: block;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}

.match-day-pill .md-time {
  display: block;
  font-size: 0.66rem;
  color: var(--text-muted);
  margin-top: 1px;
  font-variant-numeric: tabular-nums;
  opacity: 0.85;
}

.match-day-pill.past {
  opacity: 0.62;
}

.match-day-pill.past .md-number {
  color: var(--text-secondary);
}

.match-day-pill.current {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.22), rgba(203, 160, 63, 0.05));
  box-shadow: 0 0 16px rgba(203, 160, 63, 0.28);
  animation: matchDayPulse 2.8s ease-in-out infinite;
}

@keyframes matchDayPulse {
  0%, 100% { box-shadow: 0 0 16px rgba(203, 160, 63, 0.28); }
  50% { box-shadow: 0 0 26px rgba(203, 160, 63, 0.5); }
}

.match-day-pill.current .md-number {
  color: var(--gold-light);
}

/* Final-MD nach Saisonende: Story-Anker statt Live-Pulse */
.match-day-pill.final {
  border-color: rgba(203, 160, 63, 0.55);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.16), rgba(203, 160, 63, 0.03));
  box-shadow: 0 0 14px rgba(203, 160, 63, 0.18);
}
.match-day-pill.final .md-number {
  color: var(--gold-light);
}
.match-day-pill.final::after {
  /* Mini-Crown oben am MD-Pill statt der pulsierenden Glühschicht */
  content: "";
  position: absolute;
  top: 3px;
  right: 6px;
  width: 12px;
  height: 8px;
  background: linear-gradient(transparent 60%, rgba(203, 160, 63, 0.7) 60%);
  clip-path: polygon(0 80%, 0 30%, 25% 60%, 50% 0%, 75% 60%, 100% 30%, 100% 80%);
  opacity: 0.85;
}

.match-day-pill .md-note-icon {
  position: absolute;
  top: 4px;
  right: 6px;
  font-size: 0.65rem;
  color: var(--gold);
  opacity: 0.75;
  line-height: 1;
}

.calendar-break {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-sm) 0;
  color: var(--text-secondary);
  margin: var(--space-xs) 0;
}

.calendar-break-line {
  flex: 1 1 auto;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(203, 160, 63, 0.35), transparent);
  display: block;
}

.calendar-break-body {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
  padding: 0 var(--space-sm);
}

.calendar-break svg {
  width: 14px;
  height: 14px;
  color: var(--gold);
  flex-shrink: 0;
  opacity: 0.85;
}

.calendar-break-label {
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  opacity: 0.85;
}

.calendar-break-range {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.calendar-legend {
  display: flex;
  justify-content: center;
  gap: var(--space-lg);
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-color);
  font-size: 0.75rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}

.legend-item::before {
  content: '';
  width: 14px;
  height: 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-elevated);
  display: inline-block;
}

.legend-item.past::before {
  opacity: 0.42;
}

.legend-item.current::before {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.22), rgba(203, 160, 63, 0.05));
}

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
  max-width: 800px;
  margin: 0 auto;
}

@media (hover: hover) {
  .card:hover {
    border-color: var(--border-accent);
    box-shadow: var(--shadow-lg), var(--shadow-gold);
  }
}

/* --- Table Styles --- */
.table {
  width: 100%;
  border-collapse: collapse;
}

.table thead {
  position: relative;
}

.table thead::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 5%, var(--gold) 50%, transparent 95%);
  animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% { opacity: 0.5; }
  50% { opacity: 1; }
}

.table thead th {
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-align: left;
  padding: var(--space-md);
  background: var(--bg-elevated);
}

.table thead th.rank,
.table thead th.points {
  text-align: center;
}

/* Sortable Table Headers */
.table thead th.sortable {
  cursor: pointer;
  user-select: none;
  position: relative;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.table thead th.sortable:hover {
  color: var(--gold);
}

.table thead th.sortable::after {
  content: '↕';
  display: inline-block;
  margin-left: 6px;
  vertical-align: middle;
  font-size: 0.85em;
  font-weight: 700;
  line-height: 1;
  opacity: 0.45;
  transition: opacity var(--transition-fast), color var(--transition-fast);
}

.table thead th.sortable:hover::after {
  opacity: 0.75;
}

.table thead th.sortable.sort-asc::after {
  content: '↑';
  opacity: 1;
  color: var(--gold);
}

.table thead th.sortable.sort-desc::after {
  content: '↓';
  opacity: 1;
  color: var(--gold);
}

.table tbody tr {
  transition: all var(--transition-fast);
  border-bottom: 1px solid var(--border-color);
}

/* Lazy Staggered Table Row Animation - only when table is visible */
.table.animate-rows tbody tr {
  opacity: 0;
  transform: translateX(-20px);
  animation: tableRowSlideIn 0.4s ease forwards;
}

@keyframes tableRowSlideIn {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Stagger delays via CSS custom property set by JS */
.table.animate-rows tbody tr { animation-delay: calc(var(--row-index, 0) * 0.04s); }

.table tbody tr:last-child {
  border-bottom: none;
}

.table tbody tr:hover {
  background: rgba(203, 160, 63, 0.05);
}

.table td {
  padding: var(--space-md);
  vertical-align: middle;
}

.table td.rank,
.table td.points {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.table td.rank {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text-muted);
  width: 60px;
}

.table td.points b {
  font-weight: 700;
  color: var(--gold);
}

/* Fehler-/Leerzustand-Zeile in Tabellen */
.table td.meta {
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
  padding: var(--space-lg);
}

/* --- Tipper-Cell mit Avatar + Form-Indicator (Stand-Polish) --- */
.tipper-cell {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.form-slot {
  margin-left: auto;
  flex-shrink: 0;
}

.form-indicator {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 3px 5px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.form-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
}

.form-dot-gold    { background: var(--gold);   box-shadow: 0 0 4px rgba(203, 160, 63, 0.55); }
.form-dot-silver  { background: #c0c0c0; }
.form-dot-neutral { background: #6a6a6a; }
.form-dot-muted   { background: #2e2e2e; }
.form-dot-empty   {
  background: transparent;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  width: 4px;
  height: 4px;
}

@media (max-width: 600px) {
  .form-slot { display: none; }
  .tipper-cell { gap: 0.45rem; }
}

/* --- Top 3 Highlighting (an Platz gekoppelt, robust gegen Sortierung) --- */
.stand-row.rank-1 td.rank { color: var(--gold); }
.stand-row.rank-2 td.rank { color: var(--silver); }
.stand-row.rank-3 td.rank { color: var(--bronze); }

.stand-row.rank-1 {
  background: linear-gradient(90deg, rgba(203, 160, 63, 0.1), transparent);
}

.stand-row.rank-2 {
  background: linear-gradient(90deg, rgba(192, 192, 192, 0.08), transparent);
}

.stand-row.rank-3 {
  background: linear-gradient(90deg, rgba(205, 127, 50, 0.08), transparent);
}

/* --- Δ-Pille in .rank-Cell: Tendenz zum vorigen Spieltag --- */
.table td.rank {
  white-space: nowrap;
  width: 80px;
}
.rank-num {
  display: inline-block;
}
.delta {
  display: inline-block;
  margin-left: 4px;
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 1px 4px;
  border-radius: 4px;
  vertical-align: 0.15em;
  line-height: 1.2;
}
.delta-up   { color: #6bc77e; background: rgba(107, 199, 126, 0.12); }
.delta-down { color: #e07a7a; background: rgba(224, 122, 122, 0.12); }
.delta-same { color: var(--text-muted); background: transparent; opacity: 0.5; padding: 1px 2px; }

@media (max-width: 480px) {
  .table td.rank { width: 66px; }
  .delta { font-size: 0.58rem; margin-left: 3px; padding: 0 3px; }
}

/* --- Badge --- */
.badge {
  display: inline-block;
  padding: var(--space-xs) var(--space-md);
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #0a0a0a;
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  cursor: default;
}

/* Badge Hover Glow */
@media (hover: hover) {
  .badge:hover {
    transform: scale(1.05);
    box-shadow:
      var(--shadow-sm),
      0 0 20px rgba(203, 160, 63, 0.5),
      0 0 40px rgba(203, 160, 63, 0.3);
  }
}

/* --- Stars (Hall of Fame) --- */
.stars {
  display: inline-flex;
  gap: 4px;
  justify-content: center;
}

.stars .star {
  width: 20px;
  height: 20px;
  color: var(--gold);
  animation: twinkle 2s ease-in-out infinite alternate;
}

@keyframes twinkle {
  0% { opacity: 0.55; }
  100% { opacity: 1; }
}

/* --- Skeleton Loader --- */
.skeleton-row {
  display: flex;
  align-items: center;
  padding: var(--space-md);
  gap: var(--space-md);
  border-bottom: 1px solid var(--border-color);
}

.skeleton-row:last-child {
  border-bottom: none;
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--bg-elevated) 0%,
    var(--bg-secondary) 50%,
    var(--bg-elevated) 100%
  );
  background-size: 200% 100%;
  animation: skeletonShimmer 1.5s ease-in-out infinite;
  border-radius: var(--radius-sm);
}

.skeleton-rank {
  width: 40px;
  height: 28px;
}

.skeleton-name {
  flex: 1;
  height: 28px;
  max-width: 120px;
  border-radius: var(--radius-full);
}

.skeleton-points {
  width: 50px;
  height: 28px;
}

@keyframes skeletonShimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* --- Pull to Refresh Indicator --- */
.pull-indicator {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%) translateY(-100%);
  background: var(--bg-card);
  border: 1px solid var(--border-accent);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  padding: var(--space-sm) var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.85rem;
  color: var(--gold);
  backdrop-filter: blur(10px);
  z-index: 1000;
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  pointer-events: none;
}

.pull-indicator.pulling {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.pull-indicator.refreshing {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.pull-indicator svg {
  width: 18px;
  height: 18px;
  transition: transform 0.2s ease;
}

.pull-indicator.pulling svg {
  transform: rotate(180deg);
}

.pull-indicator.refreshing svg {
  animation: spin 1s linear infinite;
}

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

/* --- Table Actions --- */
.table-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-color);
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.table-actions .stamp {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.table-actions .right {
  display: flex;
  gap: var(--space-sm);
}

/* ============================================
   Legal Pages (Impressum / Datenschutz)
   ============================================ */

/* Hero-Section */
.legal-hero {
  position: relative;
  padding: clamp(var(--space-xl), 6vw, var(--space-2xl)) 0 var(--space-xl);
  overflow: hidden;
}

.legal-hero-glow {
  position: absolute;
  top: -40%;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 200%;
  background: radial-gradient(45% 50% at 50% 50%, rgba(203, 160, 63, 0.16), rgba(203, 160, 63, 0) 70%);
  pointer-events: none;
  filter: blur(6px);
  z-index: 0;
}

.legal-hero .wrap { position: relative; z-index: 1; }

.legal-eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  padding: 4px 12px;
  background: rgba(203, 160, 63, 0.10);
  border: 1px solid rgba(203, 160, 63, 0.32);
  border-radius: 999px;
  margin-bottom: var(--space-md);
}

.legal-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 3.5rem);
  letter-spacing: 0.03em;
  color: var(--gold);
  margin: 0 0 var(--space-sm);
  line-height: 1;
  text-shadow: 0 0 32px rgba(203, 160, 63, 0.22);
}

.legal-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 56ch;
  margin: 0 0 var(--space-md);
  line-height: 1.5;
}

.legal-lastupdated {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0;
}

.legal-lastupdated-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 6px rgba(203, 160, 63, 0.7);
}

/* Sticky-Tabs-Bar UNTER dem Header (Header ist sticky top:0 z-50, also Tabs
   eine Header-Höhe tiefer + niedrigeren z-index damit sie nicht überschlagen). */
.legal-tabs-bar {
  position: sticky;
  top: var(--header-height, 64px);
  z-index: 40;
  padding: 10px 0;
  background: rgba(10, 10, 10, 0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(203, 160, 63, 0.18);
  border-bottom: 1px solid var(--border-color);
}

.legal-tabs {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  background: rgba(0, 0, 0, 0.45);
  border: 1px solid var(--border-color);
  border-radius: 999px;
}

.legal-tab {
  font-family: var(--font-display);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  color: var(--text-muted);
  transition: background var(--transition-fast), color var(--transition-fast);
}
.legal-tab:hover { color: var(--text-primary); }
.legal-tab.is-active {
  background: rgba(203, 160, 63, 0.18);
  color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(203, 160, 63, 0.35);
}

/* Layout: Sidebar + Content */
.legal {
  padding: var(--space-xl) 0 var(--space-2xl);
}

.legal-wrap {
  max-width: 1100px;
}

.legal-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-lg);
}

@media (min-width: 1024px) {
  .legal-layout {
    grid-template-columns: 220px 1fr;
    gap: var(--space-2xl);
  }
}

/* TOC-Sidebar — unter Header (64 px) + Tabs-Bar (≈ 58 px) + Luft */
.legal-toc {
  position: sticky;
  top: calc(var(--header-height, 64px) + 70px);
  align-self: start;
  padding: var(--space-md);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.18));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  max-height: calc(100vh - var(--header-height, 64px) - 100px);
  overflow-y: auto;
}

@media (max-width: 1023px) {
  .legal-toc { display: none; }
}

.legal-toc-title {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 var(--space-sm);
}

.legal-toc-list {
  list-style: none;
  counter-reset: toc;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.legal-toc-list li {
  counter-increment: toc;
}

.legal-toc-list a {
  display: block;
  padding: 8px 10px 8px 36px;
  position: relative;
  color: var(--text-secondary);
  font-size: 0.88rem;
  line-height: 1.35;
  border-radius: 6px;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.legal-toc-list a::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute;
  left: 10px;
  top: 8px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  transition: color var(--transition-fast);
}
.legal-toc-list a:hover {
  color: var(--text-primary);
  background: rgba(255, 255, 255, 0.03);
}
.legal-toc-list a.is-active {
  color: var(--gold);
  background: rgba(203, 160, 63, 0.10);
}
.legal-toc-list a.is-active::before {
  color: var(--gold);
}

/* Content */
.legal-content {
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.65;
  min-width: 0;
}

/* Nummerierter H2-Section-Header mit Icon */
.legal-h2 {
  display: grid;
  grid-template-columns: auto auto 1fr;
  align-items: center;
  gap: 12px;
  margin: var(--space-2xl) 0 var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-color);
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 3vw, 1.7rem);
  letter-spacing: 0.04em;
  color: var(--gold);
  /* Scroll-Target unter Header + Sticky-Tabs-Bar */
  scroll-margin-top: calc(var(--header-height, 64px) + 70px);
}

.legal-h2:first-child,
.legal-content > .legal-h2:first-of-type {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
}

.legal-h2-num {
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.06em;
  color: var(--gold);
  padding: 4px 10px;
  background: rgba(203, 160, 63, 0.14);
  border: 1px solid rgba(203, 160, 63, 0.35);
  border-radius: 6px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.legal-h2-icon {
  display: inline-flex;
  width: 22px;
  height: 22px;
  color: var(--gold);
  opacity: 0.85;
  flex-shrink: 0;
}
.legal-h2-icon svg { width: 100%; height: 100%; }

.legal-h2-text {
  line-height: 1.15;
  min-width: 0;
}

.legal-content h3 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #e0e0e0;
  margin: var(--space-lg) 0 0.5rem;
}

.legal-content p {
  margin: 0 0 var(--space-sm);
}

.legal-content ul {
  margin: 0 0 var(--space-sm);
  padding-left: 1.4rem;
}

.legal-content ul li {
  margin-bottom: 0.35rem;
}

.legal-content a {
  color: var(--gold);
}
.legal-content a:hover {
  text-decoration: underline;
}

.legal-content code {
  font-family: ui-monospace, "SF Mono", "Cascadia Code", monospace;
  font-size: 0.85em;
  padding: 1px 5px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  color: #e0e0e0;
}

.legal-content strong {
  color: #e8e8e8;
  font-weight: 600;
}

.legal-card {
  margin: 0 0 var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.10), rgba(203, 160, 63, 0.02));
  border: 1px solid rgba(203, 160, 63, 0.35);
  border-radius: var(--radius-md);
}

.legal-card-eyebrow {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 0.4rem;
}

.legal-card-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.04em;
  color: var(--text-primary);
  margin: 0 0 0.4rem;
}

.legal-card-address {
  font-style: normal;
  color: var(--text-secondary);
  line-height: 1.5;
  font-size: 0.92rem;
}

.legal-card-contact {
  margin: 0.6rem 0 0;
  font-size: 0.9rem;
}

/* Kontakt-CTA am Ende der Datenschutz */
.legal-contact-cta {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: var(--space-md);
  margin: var(--space-2xl) 0 0;
  padding: var(--space-md) var(--space-lg);
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.14), rgba(203, 160, 63, 0.03));
  border: 1px solid rgba(203, 160, 63, 0.4);
  border-radius: var(--radius-md);
  box-shadow: 0 0 24px rgba(203, 160, 63, 0.10);
}

.legal-contact-cta-icon {
  display: inline-flex;
  width: 36px;
  height: 36px;
  color: var(--gold);
  flex-shrink: 0;
}
.legal-contact-cta-icon svg { width: 100%; height: 100%; }

.legal-contact-cta-body { min-width: 0; }

.legal-contact-cta-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: 0.03em;
  color: var(--gold);
  margin: 0 0 2px;
}

.legal-contact-cta-text {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.legal-contact-cta-btn {
  display: inline-block;
  padding: 0.55rem 1rem;
  background: linear-gradient(135deg, var(--gold), var(--gold-dark));
  color: var(--bg-primary);
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  border-radius: 6px;
  font-weight: 700;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}
.legal-contact-cta-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(203, 160, 63, 0.35);
  text-decoration: none;
}

@media (max-width: 600px) {
  .legal-title { letter-spacing: 0.02em; }
  .legal-h2 { font-size: 1.15rem; gap: 8px; }
  .legal-h2-num { font-size: 0.85rem; padding: 3px 7px; }
  .legal-h2-icon { width: 18px; height: 18px; }
  .legal-content h3 { font-size: 0.95rem; }
  .legal-content { font-size: 0.9rem; }
  .legal-card { padding: var(--space-md); }
  .legal-tab { font-size: 0.7rem; padding: 5px 10px; letter-spacing: 0.1em; }
  .legal-contact-cta {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
    gap: var(--space-sm);
  }
  .legal-contact-cta-btn { width: 100%; text-align: center; }
}

/* Legal-Pages: Footer 2-spaltig statt 3-spaltig (kein Stats-Slot) */
.legal-page .footer-grid {
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 768px) {
  .legal-page .footer-grid {
    grid-template-columns: 1fr;
  }
}

/* --- Footer --- */
footer {
  position: relative;
  padding: calc(var(--space-2xl) + var(--space-sm)) 0 var(--space-xl);
  color: var(--text-muted);
  background:
    radial-gradient(60% 100% at 50% 0%, rgba(203, 160, 63, 0.04), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.01), rgba(0, 0, 0, 0.25));
}

footer::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent 4%, rgba(203, 160, 63, 0.55) 50%, transparent 96%);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: var(--space-lg);
  align-items: center;
}

/* Brand-Block links */
.footer-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.footer-logo {
  width: 44px;
  height: 44px;
  flex-shrink: 0;
  filter: drop-shadow(0 0 8px rgba(203, 160, 63, 0.18));
}

.footer-brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.footer-brand-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 0.05em;
  color: var(--gold);
  line-height: 1;
}

.footer-brand-sub {
  font-family: var(--font-display);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Stats-Strip mitte */
.footer-stats {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.45rem 0.85rem;
  background: rgba(0, 0, 0, 0.25);
  border: 1px solid rgba(203, 160, 63, 0.18);
  border-radius: 999px;
}

.footer-stat {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 1px;
}

.footer-stat-value {
  font-family: var(--font-display);
  font-size: 1.15rem;
  letter-spacing: 0.04em;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.footer-stat-label {
  font-family: var(--font-display);
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.footer-stat-sep {
  width: 1px;
  height: 22px;
  background: rgba(255, 255, 255, 0.08);
}

/* Meta rechts */
.footer-meta {
  display: flex;
  flex-direction: column;
  gap: 5px;
  text-align: right;
  align-items: flex-end;
  font-size: 0.75rem;
}

.footer-updated {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-display);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.footer-updated::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(203, 160, 63, 0.4);
}

.footer-updated[data-fresh="true"]::before {
  background: var(--gold);
  box-shadow: 0 0 6px rgba(203, 160, 63, 0.7);
  animation: footerLivePulse 2s ease-in-out infinite;
}

@keyframes footerLivePulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.45; }
}

.footer-link {
  color: var(--gold);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}
.footer-link:hover { text-decoration: underline; }

.footer-links {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: inherit;
}

.footer-link-sep {
  color: var(--text-muted);
  opacity: 0.5;
}

.footer-copy {
  color: var(--text-muted);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
}

.footer-note {
  margin: var(--space-lg) 0 0;
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-style: italic;
}

@media (max-width: 768px) {
  footer {
    padding: var(--space-xl) 0 var(--space-lg);
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: var(--space-md);
    text-align: center;
  }
  .footer-brand,
  .footer-stats,
  .footer-meta {
    justify-content: center;
  }
  .footer-meta {
    text-align: center;
    align-items: center;
  }
  .footer-stats {
    align-self: center;
    margin: 0 auto;
  }
}

/* --- Reveal Animation --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Screen Reader Only --- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --- Skip Link (Keyboard-User) --- */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-md);
  background: var(--gold);
  color: var(--bg-primary);
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  font-weight: 700;
  text-decoration: none;
  z-index: 9999;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: var(--space-md);
  color: var(--bg-primary);
  outline: 2px solid var(--text-primary);
  outline-offset: 2px;
}

/* Sticky-Header-Versatz für Skip-Link-Sprünge */
section[id] {
  scroll-margin-top: 90px;
}
@media (max-width: 768px) {
  section[id] {
    scroll-margin-top: 12px;
  }
}

/* Sortable Header Focus für Keyboard-User */
.table thead th.sortable:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: -2px;
}

/* Auto-Refresh-Hinweis unter dem Stand-Stempel */
.auto-refresh-hint {
  display: block;
  margin-top: 2px;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-style: italic;
  letter-spacing: 0.02em;
}

/* --- HOF Specific --- */
#hof .table th:nth-child(2),
#hof .table td:nth-child(2) {
  text-align: center;
  width: 100px;
}

#hof .table th:nth-child(3),
#hof .table td:nth-child(3) {
  text-align: right;
}

#hof .table td:nth-child(3) {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.season-item {
  line-height: 1.4;
}

/* HOF: Saison-Pills mit Punkten */
.hof-seasons {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 6px;
}

.hof-season-pill {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  padding: 3px 10px;
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.14), rgba(203, 160, 63, 0.04));
  border: 1px solid rgba(203, 160, 63, 0.32);
  border-radius: 999px;
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  color: var(--gold);
  white-space: nowrap;
  line-height: 1.3;
}

.hof-season-year {
  font-variant-numeric: tabular-nums;
}

.hof-y-short { display: none; }

.hof-season-sep {
  color: var(--text-muted);
  opacity: 0.5;
}

.hof-season-pts {
  color: var(--text-secondary);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

/* HOF: Crown-Akzent vor den Titel-Sternen */
.hof-crown-lead {
  width: 18px;
  height: 18px;
  color: var(--gold);
  margin-right: 4px;
  filter: drop-shadow(0 0 6px rgba(203, 160, 63, 0.45));
  vertical-align: -3px;
}

/* HOF: Subtitel unter dem Section-Header */
.hof-subtitle {
  margin: 6px 0 0;
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.hof-subtitle [data-hof-stat] {
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

@media (max-width: 500px) {
  /* Layout: feste Spaltenbreiten damit Tabelle nicht über den Viewport hinauswächst */
  #hof .table { table-layout: fixed; width: 100%; }
  #hof .table > colgroup > col:nth-child(2) { width: 64px !important; }
  #hof .table > colgroup > col:nth-child(4) { width: 56px !important; }

  /* Pills auf Mobile kompakter, Year nur als Kurzform */
  .hof-seasons { gap: 3px 4px; }
  .hof-y-full { display: none; }
  .hof-y-short { display: inline; }
  .hof-season-pill {
    font-size: 0.72rem;
    padding: 2px 7px;
    gap: 4px;
  }
  .hof-season-pts { font-size: 0.62rem; }
  .hof-season-sep { margin: 0 1px; }

  /* HOF-Sparkline-Spalte kleiner */
  .sparkline-cell svg { max-width: 48px; height: 20px; }

  /* Titel-Spalte: Crown raus, Sterne kleiner — sonst dranht es in die Saison-Spalte */
  .hof-crown-lead { display: none; }
  .stars { gap: 2px; }
  .stars .star { width: 12px; height: 12px; }

  .hof-subtitle { font-size: 0.72rem; letter-spacing: 0.12em; }
}

/* --- Mobile Responsive --- */
@media (max-width: 768px) {
  .hero {
    padding: var(--space-2xl) 0;
  }
  
  .hero-grid {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
    text-align: center;
  }
  
  .shield {
    order: -1;
  }
  
  .shield .logo {
    max-width: 280px;
  }
  
  .kicker {
    margin: 0 auto;
  }
  
  .hero h1::after {
    content: '';
    display: block;
    width: 60%;
    height: 2px;
    margin: var(--space-md) auto 0;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
  }
  
  .countdown {
    justify-content: center;
  }
  
  .counter {
    min-width: 65px;
  }
  
  section {
    padding: var(--space-2xl) 0;
  }
  
  .card {
    padding: var(--space-md);
    border-radius: var(--radius-md);
  }
  
  .table thead th,
  .table td {
    padding: var(--space-sm) var(--space-sm);
    font-size: 0.85rem;
  }
  
  .table td.rank {
    width: 45px;
    font-size: 1rem;
  }
  
  .badge {
    padding: var(--space-xs) var(--space-sm);
    font-size: 0.8rem;
  }
  
  #hof .table th:nth-child(3),
  #hof .table td:nth-child(3) {
    text-align: left;
    font-size: 0.8rem;
  }
  
  .stars .star {
    width: 16px;
    height: 16px;
  }
  
  .table-actions {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  
  .table-actions .right {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  :root {
    --space-lg: 1rem;
    --space-xl: 1.5rem;
    --space-2xl: 2rem;
    --space-3xl: 2.5rem;
  }
  
  .wrap {
    padding: 0 var(--space-md);
  }
  
  h1 {
    font-size: 2.5rem;
  }
  
  .kicker small {
    font-size: 0.75rem;
  }
  
  .counter {
    min-width: 50px;
  }

  .calendar-grid {
    grid-template-columns: repeat(auto-fill, minmax(58px, 1fr));
    gap: var(--space-xs);
  }
  .match-day-pill .md-weekday {
    font-size: 0.55rem;
    margin-bottom: 2px;
    letter-spacing: 0.12em;
  }
  .match-day-pill .md-number {
    font-size: 1.15rem;
  }
  .match-day-pill .md-date {
    font-size: 0.65rem;
  }
  .match-day-pill .md-time {
    font-size: 0.6rem;
  }

  .countdown {
    gap: var(--space-md);
  }
  .counter:not(:last-child)::after {
    right: calc(var(--space-md) * -0.5);
  }
  .counter:nth-child(1) b { font-size: 2rem; }
  .counter:nth-child(2) b { font-size: 1.6rem; }
  .counter:nth-child(3) b { font-size: 1.3rem; }
  .counter:nth-child(4) b { font-size: 1rem; }

  .counter span {
    font-size: 0.6rem;
  }
}

/* --- Landscape Mobile --- */
@media (max-height: 500px) and (orientation: landscape) {
  .hero {
    padding: var(--space-xl) 0;
  }
  
  .shield .logo {
    max-width: 200px;
  }
}

/* --- Back to Top Button --- */
.back-to-top {
  position: fixed;
  bottom: var(--space-xl);
  right: var(--space-xl);
  width: 50px;
  height: 50px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg), 0 0 20px rgba(203, 160, 63, 0.3);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-normal);
  z-index: 99;
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

@media (hover: hover) {
  .back-to-top:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: var(--shadow-lg), 0 0 30px rgba(203, 160, 63, 0.5);
  }

  .back-to-top:hover svg {
    transform: translateY(-2px);
  }
}

.back-to-top:active {
  transform: translateY(-2px) scale(1);
}

.back-to-top svg {
  width: 24px;
  height: 24px;
  color: #0a0a0a;
  transition: transform var(--transition-fast);
}

@media (max-width: 768px) {
  .back-to-top {
    bottom: var(--space-lg);
    right: var(--space-lg);
    width: 44px;
    height: 44px;
  }
  
  .back-to-top svg {
    width: 20px;
    height: 20px;
  }
}

/* --- Site Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 10, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
}

.header-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md) var(--space-lg);
  gap: var(--space-md);
}

.header-brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  color: var(--text-primary);
  transition: color var(--transition-fast);
}

.header-brand:hover .brand-name {
  color: var(--gold);
}

.brand-text {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  line-height: 1.05;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.4s ease, background 0.4s ease;
}

.brand-sub {
  font-family: var(--font-body);
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  opacity: 0.78;
}

/* Hero out-of-view: Brand-Name bekommt Gold-Gradient, Header subtilen Goldglow */
.site-header.hero-out {
  border-bottom-color: var(--border-accent);
  box-shadow: 0 2px 24px rgba(203, 160, 63, 0.12);
}

.site-header.hero-out .brand-name {
  background: linear-gradient(90deg, var(--gold), var(--gold-light), var(--gold));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.site-header.hero-out .brand-sub {
  color: var(--gold);
  opacity: 0.85;
}

.header-brand img {
  width: 56px;
  height: 56px;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.4));
}

/* --- Header-Navigation (Desktop) --- */
.header-nav {
  display: none;
  gap: var(--space-md);
  margin-left: auto;
  margin-right: var(--space-md);
}

@media (min-width: 900px) {
  .header-nav {
    display: inline-flex;
    align-items: center;
  }
}

.header-nav a {
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  padding: 6px 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-full);
  transition: color var(--transition-fast), background-color var(--transition-fast), border-color var(--transition-fast);
}

.header-nav a:hover {
  color: var(--gold);
  background: rgba(203, 160, 63, 0.06);
}

.header-nav a[aria-current="true"] {
  color: var(--gold);
  background: rgba(203, 160, 63, 0.14);
  border-color: rgba(203, 160, 63, 0.35);
}

/* --- Burger-Button (Mobile) --- */
.burger-btn {
  display: none;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
  background: transparent;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  cursor: pointer;
  padding: 0;
  transition: border-color var(--transition-fast), background-color var(--transition-fast);
}

.burger-btn:hover,
.burger-btn:focus-visible {
  border-color: var(--gold);
  background: rgba(203, 160, 63, 0.08);
  outline: none;
}

.burger-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--gold);
  border-radius: 2px;
  transition: transform 200ms ease, opacity 150ms ease;
  transform-origin: center;
}

.burger-btn[aria-expanded="true"] .burger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.burger-btn[aria-expanded="true"] .burger-bar:nth-child(2) {
  opacity: 0;
}
.burger-btn[aria-expanded="true"] .burger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Mobile / Tablet: Burger sichtbar, Header-Nav als sliding Drawer */
@media (max-width: 899px) {
  .burger-btn { display: inline-flex; }

  .header-nav {
    display: flex !important;
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 9000;
    width: 280px;
    max-width: 85vw;
    flex-direction: column;
    gap: 0;
    margin: 0;
    padding: calc(var(--space-lg) * 1.5) var(--space-lg) var(--space-lg);
    background: var(--bg-elevated);
    border-left: 1px solid var(--border-accent);
    box-shadow: -8px 0 32px rgba(0, 0, 0, 0.6);
    transform: translateX(100%);
    transition: transform 220ms cubic-bezier(0.2, 0.8, 0.2, 1);
    overscroll-behavior: contain;
  }

  .header-nav.is-open {
    transform: translateX(0);
  }

  .header-nav a {
    padding: var(--space-md) var(--space-md);
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 0;
    font-size: 1.05rem;
    background: transparent;
  }

  .header-nav a:last-child {
    border-bottom: none;
  }

  .header-nav a[aria-current="true"] {
    background: rgba(203, 160, 63, 0.1);
    border-left: 3px solid var(--gold);
    border-color: rgba(255, 255, 255, 0.05);
    padding-left: calc(var(--space-md) - 3px);
  }

  /* Drawer-Overlay/Backdrop wenn offen */
  .header-nav.is-open::before {
    content: '';
    position: fixed;
    inset: 0;
    z-index: -1;
    background: rgba(5, 5, 5, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    /* Click-to-close handled in JS */
  }
}

@media (max-width: 768px) {
  /* Header: nicht sticky auf Mobile, Brand-Text aus */
  .site-header {
    position: static;
    background: var(--bg-secondary);
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .header-wrap {
    padding: var(--space-sm) var(--space-md);
  }
  .header-brand span {
    display: none;
  }
  .header-brand img {
    width: 44px;
    height: 44px;
  }

  /* Glassmorphism abschalten — Performance auf Low-End-Phones */
  .card,
  .kicker,
  .pull-indicator {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
  .card {
    background: var(--bg-secondary);
  }
  .kicker,
  .pull-indicator {
    background: var(--bg-elevated);
  }

  /* Countdown: enger und kleiner für Mobile */
  .countdown {
    gap: var(--space-lg);
  }
  .counter:not(:last-child)::after {
    right: calc(var(--space-lg) * -0.5);
  }
  .counter:nth-child(1) b { font-size: 2.6rem; }
  .counter:nth-child(2) b { font-size: 2rem; }
  .counter:nth-child(3) b { font-size: 1.6rem; }
  .counter:nth-child(4) b { font-size: 1.15rem; }
}

/* --- Reduced Motion (Accessibility) --- */
@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;
  }
  html {
    scroll-behavior: auto;
  }
  /* Parallax-Pattern und Float-Logo abschalten */
  body::before {
    background-position-y: 0 !important;
  }
  .shield-inner,
  .shield .logo,
  .hero-blob {
    animation: none !important;
    transform: none !important;
  }
}

/* --- Print Styles --- */
/* ============================================
   Awards / Saison-Höhepunkte
   ============================================ */
#awards .section-header { margin-bottom: var(--space-md); }

.awards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
  margin-top: var(--space-md);
}

@media (min-width: 560px) {
  .awards-grid { grid-template-columns: repeat(2, 1fr); }
  .award-champion { grid-column: 1 / -1; }
}

@media (min-width: 900px) {
  .awards-grid { grid-template-columns: repeat(4, 1fr); }
  .award-champion {
    grid-column: 1 / -1;
    max-width: 480px;
    justify-self: center;
  }
  .award-champion .award-name { font-size: 2.6rem; }
  .award-champion .award-icon { width: 64px; height: 64px; }
}

.award-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: var(--space-md) var(--space-sm);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(0, 0, 0, 0.18));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
}

@media (hover: hover) {
  .award-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-md), 0 0 20px rgba(203, 160, 63, 0.14);
  }
}

.award-icon {
  width: 38px;
  height: 38px;
  color: var(--gold);
  opacity: 0.92;
  margin-bottom: 8px;
}
.award-icon svg { width: 100%; height: 100%; }

.award-title {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.award-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.04em;
  color: var(--gold);
  line-height: 1.1;
  margin-bottom: 6px;
  word-break: break-word;
  hyphens: auto;
}

.award-sub {
  font-size: 0.8rem;
  color: var(--text-muted);
  line-height: 1.35;
  max-width: 22ch;
}

/* Champion — Hero-Treatment: groesserer Trophy, groesserer Name, Pulse-Glow */
.award-champion {
  border-color: rgba(203, 160, 63, 0.6);
  background:
    radial-gradient(circle at 50% 0%, rgba(228, 197, 106, 0.18), transparent 60%),
    linear-gradient(180deg, rgba(203, 160, 63, 0.22), rgba(203, 160, 63, 0.04) 65%, transparent);
  box-shadow: 0 0 36px rgba(203, 160, 63, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  padding: var(--space-lg) var(--space-md);
  animation: championPinPulse 4s ease-in-out infinite;
}
.award-champion .award-icon {
  color: var(--gold-light);
  opacity: 1;
  width: 56px;
  height: 56px;
  margin-bottom: 10px;
  filter: drop-shadow(0 0 12px rgba(228, 197, 106, 0.45));
}
.award-champion .award-title {
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  color: var(--gold-light);
  margin-bottom: 6px;
}
.award-champion .award-name {
  font-size: 2.2rem;
  letter-spacing: 0.05em;
  color: var(--gold-light);
  text-shadow: 0 0 24px rgba(228, 197, 106, 0.35);
}
.award-champion .award-sub {
  font-size: 0.95rem;
  color: var(--text-secondary, var(--text-muted));
  max-width: 28ch;
}

/* Subtle palette pro Award-Typ */
.award-comeback   .award-icon { color: #6bc77e; }
.award-fall       .award-icon { color: #e07a7a; }
.award-king       .award-icon { color: var(--gold-light); }
.award-constancy  .award-icon { color: #7dbef0; }

@media (max-width: 480px) {
  .award-name { font-size: 1.35rem; }
  .award-champion .award-name { font-size: 1.9rem; }
  .award-champion .award-icon { width: 48px; height: 48px; }
}

/* Reduced-Motion: Pulse aus */
@media (prefers-reduced-motion: reduce) {
  .award-champion { animation: none; }
}

/* ============================================
   Profile Modal (Career-Stats Welle 5a)
   ============================================ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5, 5, 5, 0.78);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  transition: opacity 180ms ease;
  padding: 1rem;
}

.modal-overlay[hidden] {
  display: none;
}

.modal-overlay.is-open {
  opacity: 1;
}

.modal-dialog {
  position: relative;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  background: var(--bg-elevated);
  border: 1px solid rgba(203, 160, 63, 0.25);
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(255, 255, 255, 0.03) inset;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(8px) scale(0.985);
  transition: transform 200ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.modal-overlay.is-open .modal-dialog {
  transform: translateY(0) scale(1);
}

.modal-dialog:focus {
  outline: none;
}

.modal-close {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  color: var(--gold);
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 6px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 120ms ease, color 120ms ease;
}

.modal-close:hover,
.modal-close:focus-visible {
  background: rgba(203, 160, 63, 0.12);
  color: var(--gold-light);
  outline: none;
}

.modal-close:focus-visible {
  box-shadow: 0 0 0 2px rgba(203, 160, 63, 0.5);
}

.modal-body {
  padding: 1.75rem 1.5rem 1.5rem;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 1 1 auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 500px) {
  .modal-overlay {
    padding: 0;
    align-items: flex-end;
    padding: 0; /* Bottom-Sheet bündig zum Viewport-Boden */
  }
  .modal-dialog {
    /* dvh > vh, damit iOS-Safari die URL-Bar korrekt berücksichtigt — 95vh
       konnte das Modal-Top über den sichtbaren Viewport-Rand schieben. */
    max-height: 90vh;
    max-height: 90dvh;
    max-width: 100%;
    border-radius: 12px 12px 0 0;
  }
}

/* Tipper-Link styling (badge as clickable element) */
.badge.tipper-link,
.tipper-link {
  cursor: pointer;
  outline-offset: 2px;
  transition: filter 120ms ease, transform 120ms ease;
}

.badge.tipper-link:hover,
.tipper-link:hover {
  filter: brightness(1.15);
}

.badge.tipper-link:focus-visible,
.tipper-link:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

/* Award-Card-Name: clickable name styling */
.award-card .award-name .tipper-link {
  display: inline-block;
  color: inherit;
  border-radius: 4px;
  padding: 0 2px;
}

/* ============================================
   Profile-Modal: Streaks + YoY + H2H (Welle 5e)
   ============================================ */
.yoy-arrow {
  display: inline-block;
  margin-left: 0.4rem;
  padding: 0.05rem 0.4rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  vertical-align: baseline;
}
.yoy-arrow.yoy-up   { background: rgba(120, 180, 120, 0.18); color: #aed0a8; }
.yoy-arrow.yoy-down { background: rgba(220, 100, 100, 0.18); color: #e89a9a; }
.yoy-arrow.yoy-flat { background: rgba(255, 255, 255, 0.06); color: var(--text-muted); }

.profile-streaks-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.streak-row {
  display: grid;
  grid-template-columns: max-content 1fr;
  align-items: baseline;
  gap: 0.7rem;
  padding: 0.45rem 0.7rem;
  background: rgba(255, 255, 255, 0.025);
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.streak-val {
  font-family: 'Bebas Neue', sans-serif;
  color: var(--gold);
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  line-height: 1;
  min-width: 2rem;
}

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

/* H2H-Form */
.profile-h2h-form {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.h2h-label {
  color: var(--text-muted);
  font-size: 0.82rem;
}

.h2h-select {
  background: var(--bg-elevated);
  color: #e8e8e8;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  padding: 0.45rem 0.6rem;
  font-family: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.h2h-select:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
}

/* H2H-View */
.h2h-header-bar {
  margin-bottom: 0.5rem;
}

.h2h-back {
  background: transparent;
  border: 1px solid rgba(203, 160, 63, 0.4);
  color: var(--gold-light);
  padding: 0.3rem 0.65rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  transition: background-color 120ms ease;
}

.h2h-back:hover,
.h2h-back:focus-visible {
  background: rgba(203, 160, 63, 0.12);
  outline: none;
}

.h2h-title {
  margin: 0 0 0.6rem;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.6rem;
  letter-spacing: 0.03em;
  color: var(--gold);
  line-height: 1.1;
}
.h2h-title .tipper-link { color: var(--gold-light); padding: 0 2px; border-radius: 3px; }
.h2h-vs {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 0 0.35rem;
  vertical-align: middle;
}

.h2h-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.82rem;
  margin: 0 0 0.8rem;
  padding: 0.5rem 0.7rem;
  background: rgba(255, 255, 255, 0.025);
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.h2h-summary b {
  color: var(--gold);
  font-weight: 700;
}

.h2h-sep {
  color: rgba(255, 255, 255, 0.2);
}

.h2h-table {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  max-height: 45vh;
  overflow-y: auto;
  margin-bottom: 0.7rem;
  padding-right: 0.2rem;
}

.h2h-row {
  display: grid;
  grid-template-columns: max-content 1fr 1fr max-content;
  gap: 0.5rem;
  align-items: center;
  padding: 0.35rem 0.6rem;
  border-radius: 5px;
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.02);
}

.h2h-row.h2h-head {
  background: transparent;
  color: var(--text-muted);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  padding-bottom: 0.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.h2h-row .h2h-season {
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.h2h-row .h2h-rank {
  color: #d0d0d0;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.h2h-row .h2h-winner {
  color: var(--gold);
  font-weight: 600;
  text-align: right;
}

.h2h-row.h2h-win-a .h2h-a,
.h2h-row.h2h-win-b .h2h-b {
  color: var(--gold-light);
  font-weight: 700;
}

.h2h-row.h2h-tie .h2h-winner {
  color: var(--text-muted);
}

.h2h-row.is-live {
  background: rgba(203, 160, 63, 0.07);
  border: 1px solid rgba(203, 160, 63, 0.18);
}

.h2h-tightest {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-style: italic;
}

/* ============================================
   Era-Heatmap (Welle 5d — refactored)
   ============================================ */
.heatmap-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 0.65rem;
  margin-top: var(--space-sm);
  padding: 0.55rem 0.85rem;
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.08), rgba(203, 160, 63, 0.01));
  border: 1px solid rgba(203, 160, 63, 0.22);
  border-radius: var(--radius-md);
}

.heatmap-stat {
  display: inline-flex;
  align-items: baseline;
  gap: 0.32rem;
}

.heatmap-stat-value {
  font-family: var(--font-display);
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

.heatmap-stat-label {
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.heatmap-stat-sep {
  color: var(--text-muted);
  opacity: 0.4;
}

@media (max-width: 480px) {
  .heatmap-stats {
    gap: 0.35rem 0.55rem;
    padding: 0.45rem 0.7rem;
  }
  .heatmap-stat-value { font-size: 0.95rem; }
  .heatmap-stat-label { font-size: 0.58rem; }
}

.heatmap-controls {
  margin-top: var(--space-sm);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
}

.heatmap-sort {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  background: rgba(0, 0, 0, 0.32);
  border: 1px solid var(--border-color);
  border-radius: 999px;
}

.hm-sort-pill {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
  transition: background var(--transition-fast), color var(--transition-fast);
}
.hm-sort-pill:hover { color: var(--text-primary); }
.hm-sort-pill.is-active {
  background: rgba(203, 160, 63, 0.18);
  color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(203, 160, 63, 0.35);
}
.hm-sort-pill:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 2px;
}

.heatmap-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  color: var(--text-muted);
  font-size: 0.85rem;
  user-select: none;
}

.heatmap-toggle input {
  width: 16px;
  height: 16px;
  accent-color: var(--gold);
  cursor: pointer;
}

/* Toggle nur auf Mobile sinnvoll; Desktop blendet ihn aus */
@media (min-width: 768px) {
  .heatmap-toggle { display: none; }
}

.heatmap-container {
  margin-top: var(--space-sm);
  overflow-x: auto;
  overflow-y: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(0, 0, 0, 0.12)),
    var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: var(--space-sm);
  -webkit-overflow-scrolling: touch;
}

.era-heatmap {
  display: block;
  width: 100%;
  height: auto;
  min-width: 540px; /* Mindestbreite für Lesbarkeit, sonst h-scrolling */
}

.hm-header {
  fill: var(--text-muted);
  font-family: 'Bebas Neue', 'BebasNeue', sans-serif;
  font-size: 10px;
  letter-spacing: 0.06em;
  transition: fill 140ms ease;
}
.hm-header-current { fill: var(--gold); }

.hm-live-dot {
  fill: var(--gold);
  animation: hmLivePulse 1.8s ease-in-out infinite;
}
.hm-live-label {
  fill: var(--gold);
  font-family: 'Bebas Neue', 'BebasNeue', sans-serif;
  font-size: 8px;
  letter-spacing: 0.14em;
}
.hm-live-column {
  fill: rgba(203, 160, 63, 0.05);
  stroke: rgba(203, 160, 63, 0.18);
  stroke-width: 0.5;
}
@keyframes hmLivePulse {
  0%, 100% { opacity: 1; transform-origin: center; }
  50% { opacity: 0.35; }
}

/* Tipper-Label (Text, klickbar) */
.hm-tipper-label {
  fill: #d8d8d8;
  font-family: 'DM Sans', sans-serif;
  font-size: 10px;
  cursor: pointer;
  transition: fill 120ms ease, opacity 140ms ease;
}
.hm-tipper-label:hover,
.hm-tipper-label:focus-visible { fill: var(--gold); outline: none; }

/* Cross-Hair: gefadete Cells + Axis-Highlights */
.hm-cell {
  cursor: pointer;
  stroke: rgba(0, 0, 0, 0.30);
  stroke-width: 0.5;
  transition: opacity 140ms ease, stroke 120ms ease, filter 140ms ease;
}
.hm-cell:hover,
.hm-cell:focus { outline: none; }
.hm-cell.hm-faded { opacity: 0.22; }
.hm-cell.hm-axis-row,
.hm-cell.hm-axis-col { opacity: 0.95; }
.hm-cell.hm-axis-focus {
  stroke: var(--gold);
  stroke-width: 2;
  filter: drop-shadow(0 0 6px rgba(203, 160, 63, 0.55));
}

.hm-tipper-label.hm-tipper-faded { opacity: 0.35; }
.hm-tipper-label.hm-tipper-axis { fill: var(--gold); }

/* Farbskala: warm-Top-3, kühl ab Pl 4 */
.hm-1     { fill: var(--gold); }
.hm-2     { fill: #d0d0d0; }
.hm-3     { fill: #c98748; }
.hm-mid   { fill: #3d5a7a; }   /* Slate-Blue, Pl 4–6 */
.hm-back  { fill: #2a3a4d; }   /* Slate-Dark, Pl 7–10 */
.hm-rest  { fill: #1f2128; }   /* Charcoal, Pl 11+ */
.hm-empty {
  fill: transparent;
  stroke: none;
}
.hm-empty-dot {
  fill: rgba(255, 255, 255, 0.16);
}

/* Champion-Krone in Pl-1-Cells */
.hm-crown {
  fill: rgba(0, 0, 0, 0.16);
  stroke: rgba(0, 0, 0, 0.7);
  stroke-linejoin: round;
  stroke-linecap: round;
}

/* Titel-Sterne im Tipper-Label */
.hm-stars {
  fill: var(--gold);
  letter-spacing: 0.04em;
}
.hm-tipper-label.hm-tipper-faded .hm-stars { fill: rgba(203, 160, 63, 0.4); }

.heatmap-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.75rem;
  font-size: 0.7rem;
}

.hm-chip {
  display: inline-block;
  padding: 0.18rem 0.55rem;
  border-radius: 4px;
  letter-spacing: 0.04em;
  font-weight: 600;
}
.hm-chip.hm-1     { background: var(--gold);     color: #1a1a1a; }
.hm-chip.hm-2     { background: #d0d0d0;          color: #1a1a1a; }
.hm-chip.hm-3     { background: #c98748;          color: #1a1a1a; }
.hm-chip.hm-mid   { background: #3d5a7a;          color: #f0f0f0; }
.hm-chip.hm-back  { background: #2a3a4d;          color: #d0d0d0; }
.hm-chip.hm-rest  { background: #1f2128;          color: var(--text-muted); }
.hm-chip.hm-empty {
  position: relative;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text-muted);
  padding: 0.12rem 0.5rem 0.12rem 1.05rem;
}
.hm-chip.hm-empty::before {
  content: "";
  position: absolute;
  left: 0.42rem;
  top: 50%;
  width: 4px;
  height: 4px;
  margin-top: -2px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.32);
}

/* ============================================
   Profile-Modal: Rivalry-Section (Welle 5d)
   ============================================ */
.profile-rivals-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.rival-row {
  padding: 0.55rem 0.7rem;
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.85rem;
}

.rival-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 0.2rem;
}

.rival-name { color: #e8e8e8; font-weight: 600; }
.rival-name .tipper-link { color: var(--gold-light); padding: 0 2px; border-radius: 3px; }
.rival-meta { color: var(--text-muted); font-size: 0.78rem; }

.rival-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.78rem;
  margin-bottom: 0.15rem;
}
.rival-stats .rival-avg { color: #c0c0c0; }

.rival-tight {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: italic;
}

/* ============================================
   All-Time-Records (Welle 5c — refactored)
   ============================================ */
.records-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  margin-top: var(--space-md);
}

/* Hero-Card (full-width, dominant) */
.record-hero {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: clamp(var(--space-md), 3vw, var(--space-lg));
  padding: clamp(var(--space-md), 3vw, var(--space-lg)) clamp(var(--space-md), 4vw, var(--space-xl));
  padding-right: clamp(var(--space-lg), 6vw, var(--space-xl));
  background:
    linear-gradient(135deg, rgba(203, 160, 63, 0.10) 0%, rgba(203, 160, 63, 0.02) 55%, rgba(0, 0, 0, 0.25) 100%),
    var(--bg-card);
  border: 1px solid rgba(203, 160, 63, 0.45);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 0 32px rgba(203, 160, 63, 0.12), var(--shadow-md);
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.record-hero-glow {
  position: absolute;
  inset: -40% -10% auto auto;
  width: 70%;
  height: 220%;
  background: radial-gradient(closest-side, rgba(203, 160, 63, 0.28), rgba(203, 160, 63, 0) 70%);
  pointer-events: none;
  filter: blur(8px);
}

@media (hover: hover) {
  .record-hero:hover {
    transform: translateY(-2px);
    border-color: var(--gold);
    box-shadow: 0 0 42px rgba(203, 160, 63, 0.22), var(--shadow-lg);
  }
}

.record-hero-icon {
  width: clamp(44px, 6vw, 56px);
  height: clamp(44px, 6vw, 56px);
  color: var(--gold);
  flex-shrink: 0;
  filter: drop-shadow(0 0 14px rgba(203, 160, 63, 0.45));
}
.record-hero-icon svg { width: 100%; height: 100%; }

.record-hero-body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.record-hero-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
  /* Reservierter Platz rechts, damit Titel nicht unter der Saison-Pill rutscht */
  padding-right: 70px;
}

.record-hero-eyebrow {
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
}

.record-hero-title {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3.2vw, 1.9rem);
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin: 0;
  line-height: 1.05;
}

.record-hero-value {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 0.45rem;
  font-family: var(--font-display);
  color: var(--gold);
  line-height: 0.9;
  margin-top: 4px;
  flex-wrap: wrap;
}

.record-hero-number {
  font-size: clamp(2.6rem, 7vw, 4rem);
  letter-spacing: 0.02em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 26px rgba(203, 160, 63, 0.35);
}

.record-hero-unit {
  font-size: clamp(0.9rem, 1.6vw, 1.1rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.record-hero-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin-top: 2px;
}

.record-hero-foot .record-tippers {
  font-weight: 600;
  color: #e8e8e8;
}

@media (max-width: 560px) {
  .record-hero {
    grid-template-columns: 1fr;
  }
  .record-hero-icon {
    width: 40px;
    height: 40px;
  }
  .record-hero-head {
    padding-right: 60px;
  }
}

/* Standard-Cards */
.records-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

@media (min-width: 560px) {
  .records-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 900px) {
  .records-grid { grid-template-columns: repeat(3, 1fr); }
}

.record-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: var(--space-md) var(--space-sm) calc(var(--space-md) + 2px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(0, 0, 0, 0.20));
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
}

.record-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.06), transparent 60%);
  opacity: 0;
  transition: opacity var(--transition-normal);
}

@media (hover: hover) {
  .record-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-accent);
    box-shadow: var(--shadow-md), 0 0 22px rgba(203, 160, 63, 0.18);
  }
  .record-card:hover::before { opacity: 1; }
}

.record-card-icon {
  width: 30px;
  height: 30px;
  color: var(--gold);
  opacity: 0.85;
  margin-bottom: 2px;
}
.record-card-icon svg { width: 100%; height: 100%; }

.record-card-title {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 600;
  margin: 0;
}

.record-card-value {
  display: flex;
  align-items: baseline;
  gap: 0.32rem;
  font-family: var(--font-display);
  color: var(--gold);
  line-height: 0.95;
  margin-top: 2px;
  flex-wrap: wrap;
}

.record-card-number {
  font-size: clamp(1.75rem, 4.5vw, 2.2rem);
  letter-spacing: 0.03em;
  font-variant-numeric: tabular-nums;
}

.record-card-unit {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.record-card-foot {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 0.82rem;
  line-height: 1.35;
  margin-top: 4px;
  color: var(--text-muted);
}

.record-card-foot .record-tippers {
  color: #e8e8e8;
  font-weight: 600;
}

.record-card-detail {
  color: var(--text-muted);
  font-size: 0.78rem;
}

/* Tipper-Badge-Reset für Records (Light-Weight, inline) */
.record-card .tipper-link,
.record-hero .tipper-link {
  color: inherit;
  font-weight: inherit;
  border-radius: 3px;
  padding: 0 2px;
  margin: 0 -2px;
}

/* Saison-Pill für Hero-Card */
.record-season-pill {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(203, 160, 63, 0.14);
  border: 1px solid rgba(203, 160, 63, 0.35);
  color: var(--gold);
  white-space: nowrap;
}

/* ============================================
   Profile Modal Content (Welle 5b — Player-Card-Refactor)
   ============================================ */
.profile-header {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 1rem;
  margin: 0 0 1rem;
  padding-right: 2.5rem;  /* Space für close-button */
}

.profile-avatar-wrap {
  position: relative;
  flex: 0 0 auto;
}

.profile-avatar-wrap::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  background: radial-gradient(closest-side, rgba(203, 160, 63, 0.35), rgba(203, 160, 63, 0) 70%);
  pointer-events: none;
  z-index: 0;
}

.profile-header.is-champion .profile-avatar-wrap::before {
  background: radial-gradient(closest-side, rgba(203, 160, 63, 0.55), rgba(203, 160, 63, 0) 75%);
}

.profile-avatar {
  position: relative;
  z-index: 1;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: var(--bg-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.7rem;
  letter-spacing: 0.04em;
  font-weight: 700;
  box-shadow: 0 6px 18px rgba(203, 160, 63, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* Crown-Badge bei Champions oben rechts am Avatar — bewusst NICHT zu weit nach
   rechts, sonst ragt sie auf engen Mobile-Modal-Breiten in die Meta-Spalte. */
.profile-crown-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 1px;
  padding: 2px 6px 2px 4px;
  background: linear-gradient(135deg, #f6c971, var(--gold));
  border: 1.5px solid #1a1a1a;
  border-radius: 999px;
  color: #1a1a1a;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
  font-family: 'Bebas Neue', sans-serif;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  line-height: 1;
}
.profile-crown-badge svg {
  width: 14px;
  height: 14px;
}
.profile-crown-num {
  font-weight: 700;
}

.profile-header-meta {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.profile-eyebrow {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.profile-name {
  margin: 0;
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(1.7rem, 4.5vw, 2.1rem);
  letter-spacing: 0.02em;
  color: var(--gold);
  line-height: 1.0;
}

.profile-empty {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: 1rem 0 0;
}

.profile-classification {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 4px 0 0;
}

/* Top-3-Key-Stats-Strip */
.profile-key-stats {
  display: flex;
  align-items: stretch;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 0 1.1rem;
  padding: 0.7rem 0.4rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(0, 0, 0, 0.18));
  border: 1px solid rgba(203, 160, 63, 0.22);
  border-radius: 10px;
}

.profile-key-stat {
  flex: 1 1 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.profile-key-stat-value {
  font-family: 'Bebas Neue', sans-serif;
  font-size: clamp(1.5rem, 5vw, 1.9rem);
  letter-spacing: 0.04em;
  color: #e0e0e0;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.profile-key-stat.is-champion .profile-key-stat-value { color: var(--gold); text-shadow: 0 0 12px rgba(203, 160, 63, 0.4); }
.profile-key-stat.is-podium  .profile-key-stat-value { color: var(--gold); }
.profile-key-stat.is-mid     .profile-key-stat-value { color: #c0c0c0; }

.profile-key-stat-label {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.profile-key-stat-sep {
  width: 1px;
  background: rgba(255, 255, 255, 0.08);
  align-self: stretch;
  margin: 4px 0;
}

/* Trophy-Cabinet */
.profile-trophy-cabinet {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.profile-trophy-card {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.7rem;
  background: linear-gradient(135deg, rgba(203, 160, 63, 0.20), rgba(203, 160, 63, 0.04));
  border: 1px solid rgba(203, 160, 63, 0.45);
  border-radius: 8px;
  color: var(--gold-light);
  animation: trophyReveal 0.5s ease-out backwards;
  animation-delay: calc(var(--card-index, 0) * 60ms);
  box-shadow: 0 1px 6px rgba(203, 160, 63, 0.12);
}

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

.profile-trophy-crown {
  width: 18px;
  height: 18px;
  color: var(--gold);
  filter: drop-shadow(0 0 6px rgba(203, 160, 63, 0.5));
  flex-shrink: 0;
}

.profile-trophy-year {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.05rem;
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
  color: var(--gold);
}

.profile-trophy-pts {
  font-size: 0.78rem;
  color: var(--text-secondary);
  font-variant-numeric: tabular-nums;
}

/* Sekundär-Stats: Icon-Liste statt dl-Grid */
.profile-stats-list {
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
}

.profile-stat-row {
  display: grid;
  grid-template-columns: 22px 1fr;
  grid-template-areas:
    "icon label"
    "icon value";
  column-gap: 0.7rem;
  row-gap: 2px;
  align-items: start;
  padding: 0.5rem 0.65rem;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 6px;
  font-size: 0.88rem;
}

.profile-stat-icon {
  grid-area: icon;
  display: inline-flex;
  width: 18px;
  height: 18px;
  color: var(--gold);
  opacity: 0.85;
  margin-top: 2px;
}
.profile-stat-icon svg { width: 100%; height: 100%; }

.profile-stat-label {
  grid-area: label;
  color: var(--text-muted);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  min-width: 0;
  line-height: 1.3;
}

.profile-stat-value {
  grid-area: value;
  color: #e8e8e8;
  font-weight: 600;
  text-align: left;
  min-width: 0;
  line-height: 1.4;
  /* Lange Werte wie der Vorjahres-Vergleich brechen jetzt sauber um statt das
     Label links anzuschieben. */
  overflow-wrap: anywhere;
}

.profile-stat-value .yoy-arrow {
  display: inline-block;
  margin-left: 4px;
  font-weight: 700;
}

@media (max-width: 480px) {
  /* Profile-Header: kleinerer Avatar, kompakter Crown-Badge, weniger Padding-Right
     (Close-Button reserviert eh seinen eigenen Platz), mehr Gap damit Crown-
     Badge nicht in die Pills ragt. */
  .profile-header {
    gap: 0.85rem;
    padding-right: 2rem;
  }
  .profile-avatar { width: 56px; height: 56px; font-size: 1.35rem; }
  .profile-avatar-wrap::before { inset: -8px; }
  .profile-crown-badge {
    top: -3px;
    right: -2px;
    font-size: 0.7rem;
    padding: 1px 5px 1px 3px;
    border-width: 1.2px;
  }
  .profile-crown-badge svg { width: 11px; height: 11px; }
  .profile-name { font-size: 1.6rem; }
  .profile-eyebrow { font-size: 0.65rem; letter-spacing: 0.14em; }

  /* Klassifikations-Pills: kompakter damit zwei mehr in einer Reihe passen */
  .classification-pill {
    padding: 0.15rem 0.5rem;
    font-size: 0.72rem;
  }

  /* Key-Stats-Strip: Padding und Werte nochmal etwas runter, plus Sep-Linie
     dünner, weil 3 Bebas-Werte auf 320px Modal-Body knapp sind. */
  .profile-key-stats { padding: 0.5rem 0.2rem; gap: 0.3rem; }
  .profile-key-stat-value { font-size: 1.35rem; }
  .profile-key-stat-label { font-size: 0.58rem; letter-spacing: 0.12em; }
  .profile-key-stat-sep { margin: 6px 0; }

  /* Saison-Cards Mobile: bleiben einreihig wie auf Desktop, aber die Schriften
     skalieren runter. Single-line vermeidet das Bebas-Cap-Height-clipping, das
     bei einem 2-zeiligen Stack mit overflow:hidden im Card-Container entsteht.
     Bei 320 px Viewport stehen ~270 px Cardbreite zur Verfügung — passt mit
     Year ~65 px, Rank ~22 px, Pts ~50 px und 2 Gaps locker rein. */
  .profile-season-card {
    grid-template-columns: max-content 1fr max-content;
    grid-template-areas: none;
    gap: 0.55rem;
    padding: 0.7rem 0.7rem;
    align-items: center;
    line-height: 1.3;
  }
  .profile-season-card-year {
    font-size: 0.85rem;
    line-height: 1.3;
  }
  .profile-season-card-rank {
    font-size: 1.2rem;
    line-height: 1.2;
    text-align: center;
  }
  .profile-season-card-pts {
    font-size: 0.78rem;
    line-height: 1.3;
    text-align: right;
  }

  /* Trophy-Cards kompakter */
  .profile-trophy-card { padding: 0.4rem 0.6rem; gap: 0.4rem; }
  .profile-trophy-year { font-size: 1rem; }
  .profile-trophy-pts  { font-size: 0.72rem; }
}

.classification-pill {
  display: inline-block;
  padding: 0.22rem 0.6rem;
  border-radius: 999px;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
}

.classification-pill.cls-champion {
  background: rgba(203, 160, 63, 0.18);
  border-color: rgba(203, 160, 63, 0.45);
  color: var(--gold-light);
}

.classification-pill.cls-veteran {
  background: rgba(192, 192, 192, 0.1);
  border-color: rgba(192, 192, 192, 0.25);
  color: #cccccc;
}

.classification-pill.cls-rookie {
  background: rgba(100, 160, 220, 0.12);
  border-color: rgba(100, 160, 220, 0.35);
  color: #93b6dd;
}

.classification-pill.cls-steady-eddie {
  background: rgba(120, 180, 120, 0.12);
  border-color: rgba(120, 180, 120, 0.35);
  color: #aed0a8;
}

.classification-pill.cls-wackelkandidat {
  background: rgba(220, 140, 60, 0.12);
  border-color: rgba(220, 140, 60, 0.35);
  color: #e6b275;
}

.classification-pill.cls-comeback-king {
  background: rgba(170, 110, 200, 0.12);
  border-color: rgba(170, 110, 200, 0.35);
  color: #d4a5e1;
}

.profile-stat-note {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.82rem;
}

.profile-section {
  margin: 0 0 1.1rem;
}

.profile-section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1rem;
  letter-spacing: 0.06em;
  color: var(--gold);
  margin: 0 0 0.5rem;
  text-transform: uppercase;
}

.profile-sparkline-wrap {
  background: rgba(255, 255, 255, 0.025);
  border-radius: 8px;
  padding: 0.6rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.profile-sparkline-wrap .sparkline-large {
  display: block;
  width: 100%;
  height: auto;
  max-height: 80px;
}

.profile-seasons-list {
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
  max-height: 40vh;
  overflow-y: auto;
  padding-right: 0.3rem;
}

/* Saison-Cards mit Fill-Bar (Position relativ zur Teilnehmerzahl als Background).
   Padding bewusst etwas großzügig, damit die Bebas-Glyphen oben/unten nicht in
   die overflow:hidden Kante laufen. */
.profile-season-card {
  position: relative;
  display: grid;
  grid-template-columns: max-content 1fr max-content;
  gap: 0.7rem;
  align-items: center;
  padding: 0.65rem 0.8rem;
  border-radius: 6px;
  font-size: 0.88rem;
  line-height: 1.25;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

/* Fill-Bar als gradient-Background: 0%..fill%..transparent */
.profile-season-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, var(--rank-tint, rgba(255,255,255,0.05)) 0%, var(--rank-tint, rgba(255,255,255,0.05)) var(--fill, 0%), transparent var(--fill, 0%));
  pointer-events: none;
  z-index: 0;
}

.profile-season-card > * { position: relative; z-index: 1; }

.profile-season-card.rk-1     { --rank-tint: rgba(203, 160, 63, 0.30); }
.profile-season-card.rk-2     { --rank-tint: rgba(208, 208, 208, 0.20); }
.profile-season-card.rk-3     { --rank-tint: rgba(201, 135, 72, 0.26); }
.profile-season-card.rk-mid   { --rank-tint: rgba(61, 90, 122, 0.32); }
.profile-season-card.rk-back  { --rank-tint: rgba(42, 58, 77, 0.36); }
.profile-season-card.rk-rest  { --rank-tint: rgba(31, 33, 40, 0.40); }
.profile-season-card.rk-empty { --rank-tint: rgba(255, 255, 255, 0.02); }

.profile-season-card.is-title {
  border-color: rgba(203, 160, 63, 0.55);
  box-shadow: 0 0 12px rgba(203, 160, 63, 0.12);
}

.profile-season-card.is-current {
  border-color: rgba(203, 160, 63, 0.45);
  animation: profileSeasonLivePulse 2.4s ease-in-out infinite;
}

@keyframes profileSeasonLivePulse {
  0%, 100% { box-shadow: 0 0 0 rgba(203, 160, 63, 0); }
  50%      { box-shadow: 0 0 14px rgba(203, 160, 63, 0.35); }
}

.profile-season-card-year {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.profile-season-card-rank {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 1.35rem;
  letter-spacing: 0.04em;
  text-align: center;
  font-variant-numeric: tabular-nums;
  /* Bebas-Neue hat eine sehr große cap-height — mit line-height 1 ragen die
     Glyphen aus der line-box und werden von der Card geclippt. */
  line-height: 1.15;
}
.profile-season-card.rk-1 .profile-season-card-rank { color: var(--gold); }
.profile-season-card.rk-2 .profile-season-card-rank { color: #e0e0e0; }
.profile-season-card.rk-3 .profile-season-card-rank { color: #d9986c; }
.profile-season-card.rk-mid .profile-season-card-rank { color: #93b1d0; }
.profile-season-card.rk-back .profile-season-card-rank { color: #8a9aaf; }
.profile-season-card.rk-rest .profile-season-card-rank { color: var(--text-muted); }

.profile-season-card-pts {
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  text-align: right;
  font-size: 0.92rem;
}

.season-live {
  display: inline-block;
  background: rgba(203, 160, 63, 0.2);
  color: var(--gold-light);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.05rem 0.35rem;
  border-radius: 3px;
  margin-left: 0.25rem;
  vertical-align: middle;
}

/* ============================================
   Sparkline (Welle 5b)
   ============================================ */
.sparkline {
  display: inline-block;
  vertical-align: middle;
  width: 96px;
  height: 28px;
  color: var(--text-muted);
}

.sparkline-gold  { color: var(--gold); }
.sparkline-silver { color: #b8b8b8; }
.sparkline-muted { color: #707070; }

.sparkline polyline { stroke-opacity: 0.95; }
.sparkline circle { fill: currentColor; }
.sparkline circle.dot-title {
  fill: var(--gold);
  stroke: var(--bg-elevated);
  stroke-width: 0.8;
}

.sparkline-empty {
  display: inline-block;
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.82rem;
}

.sparkline-cell {
  padding: 0.5rem 0.6rem;
  text-align: center;
  vertical-align: middle;
}

.th-sparkline {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.85rem;
}

/* Mobile: Sparkline-Spalte schrumpfen, aber sichtbar lassen */
@media (max-width: 500px) {
  .col-sparkline { width: 56px !important; }
  .th-sparkline { font-size: 0.7rem; }
  .sparkline-cell { padding: 4px 1px; }
}

@media print {
  body::before,
  .btn,
  .burger-btn,
  .countdown {
    display: none !important;
  }

  .card {
    box-shadow: none;
    border: 1px solid #ccc;
  }
}

