:root {
  --bg: #050302;
  --bg-soft: #0c0804;
  --panel: #090503;
  --line: #4c2a05;
  --line-soft: #2f1a04;
  --amber: #ff9a1f;
  --amber-soft: #c87713;
  --text: #ffa52f;
  --text-soft: #a76519;
  --danger: #ff4a4a;
  --success: #78d47f;
  --safe-top: env(safe-area-inset-top, 0px);
  --island-clearance: calc(var(--safe-top) + 0.95rem);
}

/* Total 90 extended mode: fixture structure, score typography, animation cadence */
body[data-theme="t90"] .favorite-banner {
  background:
    linear-gradient(120deg, rgba(var(--fav-rgb), 0.22), rgba(63, 83, 122, 0.1) 42%, rgba(9, 12, 17, 0.95)),
    var(--panel);
}

body[data-theme="t90"] .fixture-item {
  border-color: #8390a6;
  border-radius: 1.05rem;
  background:
    linear-gradient(165deg, rgba(255, 122, 24, 0.1), rgba(111, 138, 191, 0.08) 50%, rgba(10, 14, 22, 0.95)),
    #0b0f16;
  box-shadow:
    inset 0 0 0 1px rgba(182, 196, 222, 0.08),
    0 6px 16px rgba(0, 0, 0, 0.24);
}

body[data-theme="t90"] .fixture-item:hover {
  border-color: #ff9d3d;
  transform: translateY(-2px);
}

body[data-theme="t90"] .summary-main {
  gap: 0.65rem;
}

body[data-theme="t90"] .fixture-meta-row {
  justify-content: space-between;
}

body[data-theme="t90"] .teams.scoreline {
  gap: 0.95rem;
}

body[data-theme="t90"] .score-center {
  min-width: 158px;
  gap: 0.6rem;
}

body[data-theme="t90"] .team-badge {
  width: 20px;
  height: 20px;
  border-color: #8d98aa;
}

body[data-theme="t90"] .team-score {
  width: 2.15rem;
  height: 2.15rem;
  border-width: 2px;
  border-color: #8d98ab;
  color: #fdf2e6;
  background: radial-gradient(circle at 35% 30%, rgba(255, 155, 63, 0.32), rgba(19, 25, 36, 0.95));
  font-size: 1.22rem;
  line-height: 1;
  text-shadow: 0 0 8px rgba(255, 168, 88, 0.35);
}

body[data-theme="t90"] .fixture-details {
  color: #b6c0d3;
}

body[data-theme="t90"] .game-day-message.gameday,
body[data-theme="t90"] .status-pill.live,
body[data-theme="t90"] .match-state.live {
  animation: t90-alert 0.75s infinite steps(2, end);
}

body[data-theme="t90"] .goal-flash {
  background:
    radial-gradient(circle at center, rgba(255, 170, 84, 0.26), rgba(6, 10, 16, 0.92) 55%),
    repeating-linear-gradient(
      0deg,
      rgba(255, 210, 120, 0.08) 0,
      rgba(255, 210, 120, 0.08) 1px,
      transparent 1px,
      transparent 4px
    ),
    rgba(8, 11, 17, 0.92);
}

body[data-theme="t90"] .goal-flash.active {
  animation: t90-goal-overlay 7.1s ease-out both;
}

body[data-theme="t90"] .goal-word {
  color: #ffe9c7;
  text-shadow:
    0 0 8px rgba(255, 184, 103, 0.9),
    0 0 20px rgba(255, 139, 42, 0.72);
  animation: t90-goal-stage-a 2.45s steps(12, end) both;
}

body[data-theme="t90"] .goal-team-name {
  color: #ffe2be;
  text-shadow: 0 0 12px rgba(255, 168, 88, 0.65);
  animation: t90-goal-stage-b 2.3s 2.25s steps(10, end) both;
}

body[data-theme="t90"] .goal-scoreline {
  color: #fff4e5;
  text-shadow: 0 0 12px rgba(255, 180, 105, 0.62);
  animation: t90-goal-stage-c 2.25s 4.55s steps(10, end) both;
}

body[data-theme="t90"] .favorite-goal-cinematic {
  background:
    radial-gradient(circle at 22% 50%, rgba(255, 168, 88, 0.32), transparent 52%),
    radial-gradient(circle at 80% 48%, rgba(117, 149, 218, 0.22), transparent 48%),
    linear-gradient(180deg, rgba(8, 12, 20, 0.92), rgba(6, 9, 15, 0.97)),
    repeating-linear-gradient(
      0deg,
      rgba(255, 189, 111, 0.08) 0,
      rgba(255, 189, 111, 0.08) 1px,
      transparent 1px,
      transparent 4px
    );
}

body[data-theme="t90"] .favorite-goal-cinematic.active {
  animation: t90-favorite-goal-overlay 8.1s ease-out both;
}

body[data-theme="t90"] .favorite-goal-word {
  color: #ffe9c7;
  text-shadow:
    0 0 10px rgba(255, 191, 120, 0.95),
    0 0 28px rgba(255, 139, 42, 0.75),
    0 0 48px rgba(255, 115, 23, 0.5);
  animation: t90-favorite-goal-stage-a 2.8s steps(14, end) both;
}

body[data-theme="t90"] .favorite-goal-team {
  color: #ffe5c4;
  animation: t90-favorite-goal-stage-b 2.5s 2.55s steps(12, end) both;
}

body[data-theme="t90"] .favorite-goal-score {
  color: #fff5e9;
  animation: t90-favorite-goal-stage-c 2.35s 5.15s steps(12, end) both;
}

@keyframes t90-alert {
  0% { opacity: 1; transform: translateY(0); }
  50% { opacity: 0.52; transform: translateY(-1px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes t90-goal-overlay {
  0% { opacity: 0; }
  5% { opacity: 1; }
  93% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes t90-goal-stage-a {
  0% { opacity: 0; transform: scale(0.88); filter: blur(1px); }
  18% { opacity: 1; transform: scale(1.03); filter: blur(0); }
  76% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.06); }
}

@keyframes t90-goal-stage-b {
  0% { opacity: 0; transform: translateY(10px); }
  18% { opacity: 1; transform: translateY(0); }
  76% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-3px); }
}

@keyframes t90-goal-stage-c {
  0% { opacity: 0; transform: translateY(10px); }
  22% { opacity: 1; transform: translateY(0); }
  80% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-3px); }
}

@keyframes t90-favorite-goal-overlay {
  0% { opacity: 0; }
  5% { opacity: 1; }
  94% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes t90-favorite-goal-stage-a {
  0% { opacity: 0; transform: scale(0.86); filter: blur(1px); }
  18% { opacity: 1; transform: scale(1.04); filter: blur(0); }
  78% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.08); }
}

@keyframes t90-favorite-goal-stage-b {
  0% { opacity: 0; transform: translateY(12px); }
  18% { opacity: 1; transform: translateY(0); }
  78% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-4px); }
}

@keyframes t90-favorite-goal-stage-c {
  0% { opacity: 0; transform: translateY(12px); }
  22% { opacity: 1; transform: translateY(0); }
  82% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-4px); }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--text);
  min-height: 100vh;
  font-family: "VT323", monospace;
  font-size: 1.08rem;
  touch-action: manipulation;
  background:
    repeating-linear-gradient(
      0deg,
      rgba(255, 150, 40, 0.03) 0,
      rgba(255, 150, 40, 0.03) 1px,
      transparent 1px,
      transparent 5px
    ),
    radial-gradient(circle at 15% 12%, rgba(255, 160, 40, 0.07), transparent 38%),
    radial-gradient(circle at 86% 88%, rgba(255, 130, 22, 0.06), transparent 34%),
    var(--bg);
}

body[data-theme="t90"] {
  --bg: #0b0d12;
  --bg-soft: #11141a;
  --panel: #13171f;
  --line: #6c7483;
  --line-soft: #3d4658;
  --amber: #ff7a18;
  --amber-soft: #ff9d3d;
  --text: #f5f7ff;
  --text-soft: #b3bdcf;
  --danger: #ff3a3a;
  --success: #9fff84;
  background:
    radial-gradient(circle at 10% 0%, rgba(255, 132, 40, 0.22), transparent 36%),
    radial-gradient(circle at 88% 100%, rgba(106, 160, 255, 0.14), transparent 38%),
    repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.018) 0,
      rgba(255, 255, 255, 0.018) 1px,
      transparent 1px,
      transparent 4px
    ),
    linear-gradient(180deg, #0b0d12, #090b10 55%, #06070b);
}

body[data-theme="club"] {
  --bg: var(--club-bg, #050302);
  --panel: var(--club-panel, #090503);
  --line: var(--club-line, #4c2a05);
  --line-soft: var(--club-line-soft, #2f1a04);
  --amber: var(--club-primary, #ff9a1f);
  --amber-soft: var(--club-secondary, #c87713);
  --text: var(--club-text, #ffa52f);
  --text-soft: var(--club-text-soft, #a76519);
  background:
    radial-gradient(circle at 10% 0%, var(--club-primary, #ff9a1f), transparent 38%),
    radial-gradient(circle at 88% 100%, var(--club-secondary, #c87713), transparent 40%),
    repeating-linear-gradient(
      0deg,
      rgba(255, 170, 84, 0.07) 0,
      rgba(255, 170, 84, 0.07) 1px,
      transparent 1px,
      transparent 5px
    ),
    var(--bg);
}

.skip-link {
  position: fixed;
  left: 0.6rem;
  top: calc(var(--safe-top) + 0.45rem);
  z-index: 1200;
  transform: translateY(-170%);
  padding: 0.35rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 0.5rem;
  background: #130802;
  color: var(--text);
  text-decoration: none;
  transition: transform 180ms ease;
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.app-shell {
  width: min(1180px, 100% - 1.4rem);
  margin: max(0.85rem, calc(var(--safe-top) + 0.8rem)) auto 1rem;
}

.app-splash {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 142, 0, 0.11), rgba(0, 0, 0, 0.95) 58%),
    #050201;
  opacity: 1;
  visibility: visible;
  transition: opacity 220ms ease, visibility 220ms ease;
}

.app-splash.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.app-splash-inner {
  width: min(88vw, 420px);
  border: 1px solid var(--line);
  border-radius: 1rem;
  padding: 1rem 1.1rem;
  background: rgba(11, 6, 2, 0.9);
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(255, 153, 32, 0.12);
}

.app-splash-inner h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 2.7rem);
}

.app-splash-inner p {
  margin: 0.35rem 0 0.75rem;
  color: var(--text-soft);
}

.app-splash-loader {
  display: inline-block;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 2px solid rgba(255, 154, 31, 0.3);
  border-top-color: #ff9a1f;
  animation: splash-spin 0.8s linear infinite;
}

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

img {
  max-width: 100%;
}

.hero-bar,
.panel,
.favorite-banner,
.footer {
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 153, 0, 0.04), transparent 34%),
    var(--panel);
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.08);
  min-width: 0;
}

body[data-theme="t90"] .hero-bar,
body[data-theme="t90"] .panel,
body[data-theme="t90"] .favorite-banner,
body[data-theme="t90"] .footer {
  border-color: #8e98aa;
  background:
    linear-gradient(160deg, rgba(255, 122, 24, 0.12), rgba(76, 108, 167, 0.09) 45%, rgba(9, 12, 17, 0.95)),
    var(--panel);
  box-shadow:
    inset 0 0 0 1px rgba(198, 210, 236, 0.1),
    0 8px 28px rgba(0, 0, 0, 0.28);
  border-radius: 1.2rem;
}

body[data-theme="club"] .hero-bar,
body[data-theme="club"] .panel,
body[data-theme="club"] .favorite-banner,
body[data-theme="club"] .footer {
  border-color: var(--club-line, var(--line));
  background:
    linear-gradient(180deg, rgba(255, 153, 0, 0.07), transparent 34%),
    var(--panel);
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.12);
}

.hero-bar {
  border-radius: 1.05rem;
  padding: 1rem 1rem 0.85rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  margin-bottom: 0.9rem;
  overflow: visible;
}

.mobile-tabs-panel {
  display: none;
  padding: 0.45rem;
  margin-bottom: 0.7rem;
}

.main-tabs-panel {
  padding: 0.45rem;
  margin-bottom: 0.7rem;
  overflow: visible;
}

.main-tabs {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.4rem;
  align-items: stretch;
  padding: 0.08rem;
}

.main-tab-btn {
  min-width: 0;
  min-height: 2.26rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1;
  box-sizing: border-box;
}

.panel-enter {
  animation: panel-enter-fade 200ms ease;
}

@keyframes panel-enter-fade {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.35rem;
}

.mobile-tab-btn {
  min-width: 0;
  text-align: center;
}

.hero-actions {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.hero-left {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.hero-controls {
  display: inline-flex;
  align-items: center;
  gap: 0.42rem;
  flex-wrap: wrap;
}

.settings-menu {
  position: relative;
  z-index: 640;
}

.account-menu {
  position: relative;
  z-index: 640;
}

.notifications-menu {
  position: relative;
  z-index: 640;
}

.settings-panel {
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  width: min(360px, calc(100vw - 1.2rem));
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  background: #090503;
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.08);
  padding: 0.55rem;
  z-index: 650;
}

.settings-cog-btn {
  min-width: 2.1rem;
  width: 2.1rem;
  height: 2.1rem;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-size: 1.15rem;
}

.account-menu .settings-panel {
  left: auto;
  right: 0;
}

.notifications-menu .settings-panel {
  left: auto;
  right: 0;
}

.notifications-badge {
  position: absolute;
  top: -0.34rem;
  right: -0.34rem;
  min-width: 1.08rem;
  height: 1.08rem;
  border-radius: 999px;
  border: 1px solid #b56e16;
  background: #1a0f05;
  color: #ffcf8b;
  font-size: 0.75rem;
  line-height: 1.08rem;
  text-align: center;
  padding: 0 0.18rem;
}

.notifications-panel {
  width: min(380px, calc(100vw - 1.2rem));
}

.notifications-list {
  display: grid;
  gap: 0.35rem;
  max-height: 280px;
  overflow: auto;
  padding-right: 0.15rem;
}

.notification-row {
  border: 1px solid var(--line-soft);
  border-radius: 0.6rem;
  background: rgba(255, 153, 32, 0.05);
  padding: 0.35rem 0.42rem;
}

.notification-row p {
  margin: 0;
  line-height: 1.1;
}

.notification-time {
  color: var(--text-soft);
  font-size: 0.9rem;
}

.lifetime-points-pill {
  margin: 0;
  padding: 0.3rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 153, 32, 0.07);
  color: var(--text-soft);
  white-space: nowrap;
}

body[data-theme="t90"] .settings-panel {
  border-color: #8d98ab;
  background: #0d121b;
  box-shadow: inset 0 0 0 1px rgba(151, 172, 209, 0.15);
}

.settings-group + .settings-group {
  margin-top: 0.55rem;
  padding-top: 0.55rem;
  border-top: 1px dashed var(--line-soft);
}

.settings-label {
  margin: 0 0 0.35rem;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-size: 0.95rem;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.theme-btn {
  min-height: 1.9rem;
  padding: 0.2rem 0.6rem;
  font-size: 0.92rem;
  border-color: #7a4a10;
}

.theme-btn.active {
  border-color: #b56510;
  color: #ffb452;
  background: rgba(255, 153, 32, 0.16);
}

.feature-btn {
  min-height: 1.9rem;
  padding: 0.2rem 0.65rem;
  font-size: 0.92rem;
  border-color: #7a4a10;
}

.feature-btn.active {
  border-color: #e5a24d;
  color: #ffe1b5;
  background: linear-gradient(180deg, rgba(255, 171, 77, 0.24), rgba(255, 130, 22, 0.1));
}

.player-pop-main {
  min-height: 1.95rem;
  min-width: 10.4rem;
  width: 100%;
  padding: 0.3rem 0.7rem;
  border-radius: 999px;
  border-color: #7a4a10;
  position: relative;
  justify-content: center;
}

.player-pop-main.active {
  border-color: #e5a24d;
  color: #ffe1b5;
  background: linear-gradient(180deg, rgba(255, 171, 77, 0.24), rgba(255, 130, 22, 0.1));
}

.player-source-toggle {
  display: flex;
  gap: 0.35rem;
  margin-top: 0.35rem;
}

.player-source-btn {
  flex: 1;
  min-width: 0;
  min-height: 1.85rem;
  padding: 0.18rem 0.45rem;
  font-size: 0.9rem;
  border-color: #704311;
}

.player-source-btn.active {
  border-color: #c0771d;
  color: #ffcb8a;
  background: rgba(255, 153, 32, 0.14);
}

body[data-theme="t90"] .player-source-btn {
  border-color: #7f8ea8;
  color: #d6deed;
}

body[data-theme="t90"] .player-source-btn.active {
  border-color: #ff9d3d;
  color: #fff4e4;
  background: rgba(255, 122, 24, 0.22);
}

body[data-theme="t90"] .feature-btn {
  border-color: #8d98ab;
  color: #f4f8ff;
}

body[data-theme="t90"] .feature-btn.active {
  border-color: #ff9d3d;
  color: #fff7eb;
  background: linear-gradient(180deg, rgba(255, 122, 24, 0.35), rgba(255, 122, 24, 0.14));
}

body[data-theme="t90"] .player-pop-main {
  border-color: #8d98ab;
  color: #f4f8ff;
}

body[data-theme="t90"] .player-pop-main.active {
  border-color: #ff9d3d;
  color: #fff7eb;
  background: linear-gradient(180deg, rgba(255, 122, 24, 0.35), rgba(255, 122, 24, 0.14));
}

.player-pop-score-badge {
  position: absolute;
  top: -0.34rem;
  right: -0.34rem;
  min-width: 1.08rem;
  height: 1.08rem;
  border-radius: 999px;
  border: 1px solid #b56e16;
  background: #1a0f05;
  color: #ffcf8b;
  font-size: 0.75rem;
  line-height: 1.08rem;
  text-align: center;
  padding: 0 0.18rem;
}

.player-pop-score-badge.all-complete {
  border: 2px solid #63d874;
  color: #d4ffe0;
  background: #0f2a15;
  box-shadow: 0 0 0 1px rgba(99, 216, 116, 0.28);
}

.dream-team-nav {
  position: relative;
}

.dream-team-toggle.disabled {
  border-color: #5c452e;
  color: #8f6e44;
  opacity: 0.65;
}

.dream-team-toggle.active {
  border-color: #c98220;
  color: #ffd29a;
}

.dream-team-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.6rem;
  height: 1.4rem;
  margin-left: 0.28rem;
  padding: 0 0.34rem;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  background: rgba(255, 153, 32, 0.09);
  color: var(--text-soft);
  font-size: 0.92rem;
  line-height: 1;
}

.dream-team-hint {
  position: static;
  width: 100%;
  margin: 0.35rem 0 0;
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 0.65rem;
  background: #0c0703;
  color: var(--text-soft);
  z-index: 61;
}

.player-dvd-layer {
  position: fixed;
  inset: 0;
  z-index: 1200;
  pointer-events: none;
}

body.player-quiz-open::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 50% 35%, rgba(0, 0, 0, 0.42), rgba(0, 0, 0, 0.74)),
    rgba(0, 0, 0, 0.45);
  z-index: 1190;
  pointer-events: none;
}

.player-dvd-layer.quiz-active {
  pointer-events: auto;
}

.player-dvd-avatar {
  position: absolute;
  width: 94px;
  height: 94px;
  border-radius: 50%;
  border: 2px solid rgba(255, 170, 84, 0.86);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 170, 84, 0.24), rgba(11, 7, 3, 0.92)),
    #0d0905;
  box-shadow:
    0 0 0 1px rgba(255, 170, 84, 0.35),
    0 0 16px rgba(255, 140, 38, 0.28);
  overflow: hidden;
  padding: 0.2rem;
  pointer-events: auto;
  cursor: pointer;
  touch-action: manipulation;
}

.player-dvd-avatar.quiz-fade {
  animation: player-avatar-quiz-fade 260ms ease forwards;
}

body[data-theme="t90"] .player-dvd-avatar {
  border-color: rgba(233, 241, 255, 0.8);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 139, 42, 0.34), rgba(9, 14, 22, 0.96)),
    #0f1622;
  box-shadow:
    0 0 0 1px rgba(161, 179, 209, 0.35),
    0 0 18px rgba(123, 156, 231, 0.22);
}

.player-dvd-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

.player-dvd-name {
  position: absolute;
  max-width: min(70vw, 280px);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(10, 6, 2, 0.94);
  color: var(--text);
  padding: 0.22rem 0.6rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: 0 0 0 1px rgba(255, 164, 50, 0.24);
  pointer-events: none;
}

.player-dvd-name.prominent {
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) !important;
  max-width: min(90vw, 520px);
  font-size: clamp(1.55rem, 5.6vw, 2.6rem);
  padding: 0.36rem 1rem;
  text-align: center;
  border-width: 2px;
  z-index: 81;
  box-shadow:
    0 0 0 2px rgba(255, 164, 50, 0.24),
    0 0 22px rgba(255, 153, 32, 0.34);
}

.player-quiz-card {
  position: absolute;
  left: 50%;
  top: calc(50% + 44px);
  transform: translate(-50%, -50%);
  width: min(420px, calc(100vw - 1.2rem));
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background: rgba(10, 6, 2, 0.96);
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.11);
  padding: 0.7rem;
  pointer-events: auto;
  z-index: 1202;
}

.player-quiz-focus {
  position: absolute;
  left: 50%;
  top: calc(50% - 168px);
  transform: translateX(-50%);
  width: 122px;
  height: 122px;
  border-radius: 50%;
  border: 2px solid rgba(255, 170, 84, 0.9);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 170, 84, 0.2), rgba(11, 7, 3, 0.95)),
    #0d0905;
  box-shadow:
    0 0 0 1px rgba(255, 170, 84, 0.35),
    0 0 22px rgba(255, 140, 38, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
  z-index: 1204;
}

.player-quiz-focus.active {
  animation: player-quiz-focus-in 260ms ease forwards;
}

.player-quiz-focus.answer-correct {
  animation: player-quiz-focus-correct 640ms ease both;
}

.player-quiz-focus.answer-wrong {
  animation: player-quiz-focus-wrong 520ms ease both;
}

.player-quiz-focus-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 50%;
}

.player-quiz-title {
  margin: 0 0 0.55rem;
  text-align: center;
  color: var(--text);
  letter-spacing: 0.05em;
}

.player-quiz-options {
  display: grid;
  gap: 0.38rem;
}

.player-quiz-option {
  width: 100%;
  text-align: center;
}

.player-quiz-feedback {
  position: absolute;
  left: 50%;
  bottom: 14%;
  transform: translateX(-50%);
  border-radius: 999px;
  border: 1px solid var(--line);
  padding: 0.25rem 0.8rem;
  background: rgba(10, 6, 2, 0.96);
  color: var(--text);
  pointer-events: none;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.player-quiz-feedback.correct {
  color: #d8ffe1;
  border-color: #3ea95a;
  background: rgba(24, 67, 36, 0.9);
  animation: quiz-pop 0.9s steps(2, end);
}

.player-quiz-feedback.wrong {
  color: #ffd7d7;
  border-color: #c73f3f;
  background: rgba(71, 21, 21, 0.9);
  animation: quiz-shake 0.65s;
}

@keyframes quiz-pop {
  0% { opacity: 0; transform: translateX(-50%) scale(0.92); }
  25% { opacity: 1; transform: translateX(-50%) scale(1.05); }
  100% { opacity: 1; transform: translateX(-50%) scale(1); }
}

@keyframes quiz-shake {
  0% { transform: translateX(-50%) translateX(0); }
  20% { transform: translateX(-50%) translateX(-7px); }
  40% { transform: translateX(-50%) translateX(7px); }
  60% { transform: translateX(-50%) translateX(-5px); }
  80% { transform: translateX(-50%) translateX(5px); }
  100% { transform: translateX(-50%) translateX(0); }
}

@keyframes player-avatar-quiz-fade {
  0% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(0.9); }
}

@keyframes player-quiz-focus-in {
  0% { opacity: 0; transform: translateX(-50%) scale(0.88); }
  100% { opacity: 1; transform: translateX(-50%) scale(1); }
}

@keyframes player-quiz-focus-correct {
  0% { opacity: 1; transform: translateX(-50%) scale(1); }
  45% { opacity: 1; transform: translateX(-50%) scale(1.08); }
  100% { opacity: 0; transform: translateX(-50%) scale(0.88); }
}

@keyframes player-quiz-focus-wrong {
  0% { opacity: 1; transform: translateX(-50%) translateX(0) scale(1); }
  24% { transform: translateX(-50%) translateX(-8px) scale(1.02); }
  48% { transform: translateX(-50%) translateX(8px) scale(1.02); }
  72% { transform: translateX(-50%) translateX(-5px) scale(1.01); }
  100% { opacity: 1; transform: translateX(-50%) translateX(0) scale(1); }
}

body[data-theme="t90"] .player-dvd-name {
  border-color: #8d98ab;
  background: rgba(10, 14, 22, 0.95);
  color: #f2f6ff;
  box-shadow: 0 0 0 1px rgba(136, 161, 213, 0.3);
}

body[data-theme="t90"] .player-dvd-name.prominent {
  box-shadow:
    0 0 0 2px rgba(154, 177, 216, 0.3),
    0 0 24px rgba(129, 160, 231, 0.3);
}

body[data-theme="t90"] .player-pop-score-badge {
  border-color: #9ab0d4;
  background: #101726;
  color: #dfe8fb;
}

body[data-theme="t90"] .player-quiz-card {
  border-color: #7f8ea8;
  background: rgba(9, 14, 22, 0.96);
  box-shadow: inset 0 0 0 1px rgba(151, 172, 209, 0.14);
}

body[data-theme="t90"] .player-quiz-focus {
  border-color: rgba(233, 241, 255, 0.82);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 139, 42, 0.34), rgba(9, 14, 22, 0.96)),
    #0f1622;
  box-shadow:
    0 0 0 1px rgba(161, 179, 209, 0.35),
    0 0 18px rgba(123, 156, 231, 0.22);
}

body[data-theme="t90"] .dream-team-toggle.disabled {
  border-color: #61718d;
  color: #8b9bb8;
}

.dream-team-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.dream-team-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.dream-team-overlay {
  position: fixed;
  top: calc(var(--safe-top) + 0.9rem);
  right: 0.7rem;
  bottom: 0.7rem;
  left: 0.7rem;
  z-index: 700;
  overflow: auto;
  padding: 0.8rem;
  background:
    linear-gradient(180deg, rgba(255, 153, 0, 0.08), rgba(0, 0, 0, 0.88) 42%),
    #0a0503;
  box-shadow:
    inset 0 0 0 1px rgba(255, 152, 17, 0.16),
    0 22px 60px rgba(0, 0, 0, 0.55);
}

body.dream-team-overlay-open {
  overflow: hidden;
}

body.dream-team-overlay-open::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 50% 30%, rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.72)),
    rgba(0, 0, 0, 0.45);
  z-index: 690;
  pointer-events: none;
}

.dream-team-overlay .dream-team-list {
  margin-top: 0.4rem;
}

.league-member-overlay {
  position: fixed;
  top: calc(var(--safe-top) + 0.95rem);
  right: 1rem;
  bottom: 1rem;
  left: 1rem;
  z-index: 710;
  overflow: auto;
  padding: 0.8rem;
  background:
    linear-gradient(180deg, rgba(255, 153, 0, 0.08), rgba(0, 0, 0, 0.9) 42%),
    #0a0503;
  box-shadow:
    inset 0 0 0 1px rgba(255, 152, 17, 0.16),
    0 22px 60px rgba(0, 0, 0, 0.55);
}

body.league-member-overlay-open {
  overflow: hidden;
}

body.league-member-overlay-open::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 50% 30%, rgba(0, 0, 0, 0.52), rgba(0, 0, 0, 0.72)),
    rgba(0, 0, 0, 0.45);
  z-index: 700;
  pointer-events: none;
}

.league-member-body {
  margin-top: 0.45rem;
  display: grid;
  gap: 0.7rem;
}

.member-compare-sticky {
  position: sticky;
  top: 0.12rem;
  z-index: 6;
  display: flex;
  justify-content: flex-end;
  padding: 0.2rem 0 0.28rem;
  background: linear-gradient(180deg, rgba(10, 5, 3, 0.98), rgba(10, 5, 3, 0.22));
}

.member-compare-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  min-width: 8.8rem;
  border: 1px solid #8a3939;
  border-radius: 999px;
  padding: 0.16rem 0.74rem;
  color: #ffd4d4;
  background: linear-gradient(180deg, rgba(149, 38, 38, 0.34), rgba(76, 20, 20, 0.28));
  font-size: 0.98rem;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 140ms ease, filter 140ms ease, border-color 140ms ease, color 140ms ease;
}

.member-compare-toggle-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.08);
}

.member-compare-toggle-btn:active {
  transform: translateY(1px);
}

.member-compare-toggle-btn.on {
  border-color: #2f8f44;
  color: #d9ffe0;
  background: linear-gradient(180deg, rgba(57, 153, 78, 0.35), rgba(26, 95, 46, 0.28));
}

.member-compare-toggle-btn.off {
  border-color: #973f3f;
  color: #ffd4d4;
  background: linear-gradient(180deg, rgba(149, 38, 38, 0.34), rgba(76, 20, 20, 0.28));
}

.member-compare-toggle-btn.disabled {
  border-color: var(--line-soft);
  color: var(--text-soft);
  background: rgba(40, 26, 10, 0.5);
  cursor: not-allowed;
  opacity: 0.75;
}

.member-view-group {
  border: 1px solid var(--line-soft);
  border-radius: 0.75rem;
  padding: 0.55rem;
  background: rgba(255, 153, 32, 0.04);
}

.member-view-group h4,
.member-view-group h5 {
  margin: 0 0 0.35rem;
}

.member-points-summary {
  display: grid;
  gap: 0.45rem;
}

.member-points-summary.one {
  grid-template-columns: 1fr;
}

.member-points-summary.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.member-points-card {
  border: 1px solid var(--line-soft);
  border-radius: 0.68rem;
  padding: 0.4rem 0.45rem;
  background: rgba(8, 5, 2, 0.72);
  display: grid;
  gap: 0.12rem;
}

.member-points-card p {
  margin: 0;
  color: var(--text-soft);
}

.member-points-card strong {
  color: var(--text);
}

.member-pred-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 0.5rem;
}

.member-pred-card {
  border: 1px solid var(--line-soft);
  border-radius: 0.72rem;
  padding: 0.45rem;
  background: rgba(8, 5, 2, 0.72);
}

.member-pred-card header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.42rem;
  margin-bottom: 0.24rem;
}

.member-pred-card h5 {
  margin: 0;
  line-height: 1.05;
}

.member-pred-final {
  color: var(--text-soft);
  margin-bottom: 0.3rem;
}

.member-pred-compare {
  display: grid;
  gap: 0.35rem;
}

.member-pred-compare.one {
  grid-template-columns: 1fr;
}

.member-pred-compare.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.member-pred-side {
  border: 1px solid var(--line-soft);
  border-radius: 0.62rem;
  padding: 0.3rem 0.35rem;
  display: grid;
  justify-items: center;
  gap: 0.12rem;
}

.member-pred-label {
  font-size: 0.86rem;
  color: var(--text-soft);
}

.member-pred-score {
  font-size: 1.32rem;
  color: var(--text);
}

.member-pred-outcome {
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.03rem 0.4rem;
  font-size: 0.82rem;
}

.member-pred-outcome.perfect {
  border-color: #2f8f44;
  color: #d7ffe0;
  background: rgba(60, 140, 76, 0.22);
}

.member-pred-outcome.result {
  border-color: #8092b8;
  color: #dbe6ff;
  background: rgba(102, 123, 168, 0.2);
}

.member-pred-outcome.pending {
  color: var(--text-soft);
}

.member-pred-outcome.miss {
  border-color: #a03f3f;
  color: #ffd3d3;
  background: rgba(138, 50, 50, 0.18);
}

.member-team-compare {
  display: grid;
  gap: 0.6rem;
}

.member-team-compare.one {
  grid-template-columns: 1fr;
}

.member-team-compare.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.member-team-card {
  border: 1px solid var(--line-soft);
  border-radius: 0.8rem;
  padding: 0.5rem;
  background: rgba(7, 4, 2, 0.78);
}

.member-team-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.3rem;
}

.member-team-head h5 {
  margin: 0;
}

.member-formation-pill {
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.04rem 0.4rem;
  color: var(--text-soft);
}

.member-pitch-wrap {
  display: grid;
  gap: 0.34rem;
  border: 1px solid var(--line-soft);
  border-radius: 0.7rem;
  padding: 0.45rem 0.35rem;
  background:
    radial-gradient(circle at 50% 38%, rgba(255, 153, 32, 0.09), rgba(0, 0, 0, 0) 65%),
    rgba(10, 6, 3, 0.68);
}

.member-pitch-lane {
  display: grid;
  gap: 0.32rem;
}

.member-pitch-slot {
  min-height: 4.6rem;
  border: 1px dashed var(--line-soft);
  border-radius: 0.62rem;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 0.12rem;
  padding: 0.2rem;
}

.member-pitch-slot.filled {
  border-style: solid;
  background: rgba(255, 153, 32, 0.08);
}

.member-pitch-avatar-ring {
  width: 2rem;
  height: 2rem;
  border: 1px solid #b26e1f;
  border-radius: 50%;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #120a04;
}

.member-pitch-avatar {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  object-fit: contain;
}

.member-pitch-avatar-fallback {
  font-size: 0.95rem;
  color: var(--text-soft);
}

.member-pitch-badge {
  position: absolute;
  right: -0.32rem;
  bottom: -0.26rem;
  width: 0.82rem;
  height: 0.82rem;
  border-radius: 50%;
  border: 1px solid #b26e1f;
  background: #090503;
}

.member-pitch-name {
  font-size: 0.82rem;
  line-height: 1;
  text-align: center;
}

.member-pitch-empty {
  font-size: 0.84rem;
  color: var(--text-soft);
  opacity: 0.7;
}

.member-bench-wrap {
  margin-top: 0.34rem;
  display: grid;
  gap: 0.2rem;
}

.member-bench-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.26rem;
}

.member-bench-pill {
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.04rem 0.34rem;
  color: var(--text-soft);
  font-size: 0.82rem;
}

.member-staff-line {
  margin-top: 0.32rem;
  display: flex;
  align-items: baseline;
  gap: 0.3rem;
}

.squad-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.25rem;
}

#squad-panel #squad-body {
  padding-top: 0.35rem;
}

#squad-panel {
  margin-bottom: 0.9rem;
}

.squad-list {
  display: grid;
  gap: 0.5rem;
}

.squad-item {
  border: 1px solid transparent;
  border-radius: 0.8rem;
}

.squad-item.open {
  border-color: var(--line-soft);
  background: rgba(255, 153, 32, 0.04);
}

.squad-row {
  border: 1px solid var(--line-soft);
  border-radius: 0.72rem;
  padding: 0.52rem 0.62rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.squad-goal-flash {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  border-radius: 0.72rem;
  background:
    radial-gradient(circle at center, rgba(66, 219, 148, 0.12), rgba(0, 0, 0, 0.9) 55%),
    repeating-linear-gradient(
      0deg,
      rgba(112, 255, 170, 0.07) 0,
      rgba(112, 255, 170, 0.07) 1px,
      transparent 1px,
      transparent 5px
    ),
    rgba(2, 15, 8, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
}

.squad-goal-flash.active {
  display: flex;
  animation: goal-overlay 4.6s ease-out both;
}

.squad-goal-flash .goal-stage {
  position: absolute;
  width: calc(100% - 0.7rem);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0;
}

.squad-goal-flash .goal-word {
  font-size: clamp(1.2rem, 3.2vw, 1.8rem);
  color: #baffd8;
  text-shadow: 0 0 6px rgba(112, 255, 170, 0.9);
  animation: goal-stage-a 1.8s steps(8, end) both;
}

.squad-goal-flash .goal-team-name {
  font-size: clamp(0.95rem, 2.4vw, 1.2rem);
  color: #9fffcf;
  text-shadow: 0 0 10px rgba(86, 255, 164, 0.6);
  animation: goal-stage-b 1.8s 1.55s steps(8, end) both;
}

.squad-goal-flash .goal-scoreline {
  font-size: clamp(1rem, 2.6vw, 1.3rem);
  color: #fff4e6;
  text-shadow: 0 0 10px rgba(103, 255, 177, 0.62);
  animation: goal-stage-c 1.8s 3s steps(8, end) both;
}

.squad-main {
  min-width: 0;
  display: grid;
}

.squad-line {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 0.38rem;
}

.player-no-circle {
  width: 1.5rem;
  height: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid #8a5214;
  background: rgba(255, 153, 32, 0.05);
  color: #ffc06a;
  font-size: 0.93rem;
  line-height: 1;
  flex-shrink: 0;
}

.player-no-circle.missing {
  border-color: var(--line-soft);
  color: var(--text-soft);
  opacity: 0.75;
}

.player-cutout {
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 0.35rem;
  object-fit: contain;
  border: 1px solid var(--line-soft);
  background: #120a04;
  padding: 0.08rem;
  flex-shrink: 0;
}

.squad-name {
  color: var(--text);
}

.squad-meta {
  color: var(--text-soft);
}

.squad-star {
  min-width: 2rem;
  padding: 0;
}

.squad-star.active {
  color: #ffd78f;
  border-color: #c98220;
}

.squad-detail {
  border-top: 1px dashed var(--line-soft);
  margin-top: 0.32rem;
  padding: 0.5rem 0.62rem 0.58rem;
}

.squad-detail-grid {
  display: grid;
  gap: 0.38rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.squad-detail-grid .label {
  display: block;
  color: var(--text-soft);
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.squad-detail-grid .value {
  display: block;
  color: var(--text);
}

.squad-summary {
  margin: 0.45rem 0 0;
  color: var(--text-soft);
  line-height: 1.2;
}

.dream-team-list {
  display: grid;
  gap: 0.6rem;
}

.dream-group {
  border: 1px solid var(--line-soft);
  border-radius: 0.78rem;
  padding: 0.45rem;
}

.dream-controls {
  display: grid;
  gap: 0.45rem;
}

.dream-controls-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.dream-formation-select {
  min-height: 1.95rem;
  border: 1px solid var(--line);
  border-radius: 0.62rem;
  background: #090503;
  color: var(--text);
  font: inherit;
  padding: 0.1rem 0.42rem;
}

.dream-counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.8rem;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.05rem 0.5rem;
  color: var(--text-soft);
  text-align: center;
  white-space: nowrap;
}

.dream-pitch {
  display: grid;
  gap: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--line-soft);
  border-radius: 0.95rem;
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 153, 32, 0.12), transparent 56%),
    linear-gradient(180deg, rgba(255, 153, 32, 0.07), transparent 30%),
    rgba(11, 7, 3, 0.8);
  box-shadow:
    inset 0 0 0 1px rgba(255, 152, 17, 0.09),
    0 8px 22px rgba(0, 0, 0, 0.26);
}

.pitch-lane {
  display: grid;
  width: min(940px, 100%);
  margin: 0 auto;
  align-items: start;
  gap: 0.55rem;
}

.dream-pitch-open .pitch-lane,
.dream-pitch-formation .pitch-lane {
  opacity: 0;
  transform: translateY(8px);
  animation: pitch-lane-in 360ms ease forwards;
  animation-delay: var(--lane-delay, 0ms);
}

.pitch-slot {
  width: 100%;
  max-width: 190px;
  justify-self: center;
  min-height: 118px;
  border: 1px dashed #5e3810;
  border-radius: 0.95rem;
  background: rgba(255, 153, 32, 0.035);
  color: var(--text-soft);
  padding: 0.4rem 0.32rem 0.34rem;
  font: inherit;
  display: grid;
  justify-items: center;
  align-content: center;
  gap: 0.28rem;
  transition: transform 140ms ease, border-color 140ms ease, background-color 140ms ease;
  text-align: center;
  overflow: hidden;
}

.dream-pitch-open .pitch-slot,
.dream-pitch-formation .pitch-slot {
  opacity: 0;
  transform: translateY(6px) scale(0.97);
  animation: pitch-slot-in 430ms ease forwards;
  animation-delay: var(--slot-delay, 0ms);
}

.pitch-slot.filled {
  border-style: solid;
  border-color: #b86d17;
  color: #ffd9a4;
  background:
    radial-gradient(circle at 50% 20%, rgba(255, 176, 74, 0.14), rgba(255, 153, 32, 0.04) 58%),
    rgba(255, 153, 32, 0.07);
}

.pitch-slot.filled:hover {
  transform: translateY(-1px);
  border-color: #d58a2e;
}

.pitch-slot.swap-active {
  border-color: #ffbf74;
  box-shadow:
    inset 0 0 0 1px rgba(255, 196, 124, 0.55),
    0 0 0 2px rgba(255, 196, 124, 0.24);
}

.pitch-slot.swap-target {
  border-color: #d18a31;
  background: rgba(255, 153, 32, 0.1);
}

.dream-pitch-player .pitch-slot.filled {
  animation: pitch-player-swap 520ms ease both;
  animation-delay: var(--slot-delay, 0ms);
}

.dream-pitch-formation .pitch-slot.filled {
  animation: pitch-formation-shift 620ms ease both;
  animation-delay: var(--slot-delay, 0ms);
}

.pitch-slot:disabled {
  opacity: 0.75;
  cursor: not-allowed;
}

.pitch-avatar-ring {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 2px solid #b87424;
  background: #140a04;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  flex-shrink: 0;
}

.pitch-avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

.pitch-avatar-fallback {
  font-size: 1.3rem;
  color: #ffcf8b;
}

.pitch-badge {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 1px solid #b87424;
  background: #120a04;
  object-fit: contain;
  position: absolute;
  right: -7px;
  bottom: -7px;
  z-index: 2;
}

.pitch-lane.compact {
  gap: 0.35rem;
}

.pitch-lane.compact .pitch-slot {
  min-height: 102px;
  padding: 0.28rem 0.2rem 0.26rem;
}

.pitch-lane.compact .pitch-avatar-ring {
  width: 44px;
  height: 44px;
}

.pitch-lane.compact .pitch-badge {
  width: 14px;
  height: 14px;
  right: -5px;
  bottom: -5px;
}

.pitch-lane.compact .pitch-player-name {
  font-size: clamp(0.68rem, 2.2vw, 0.86rem);
  min-height: 2em;
}

.pitch-player-name {
  color: #ffe2bc;
  text-align: center;
  line-height: 1.05;
  font-size: clamp(0.78rem, 2.8vw, 1.02rem);
  overflow-wrap: anywhere;
  word-break: break-word;
  width: 100%;
  max-width: 100%;
  min-height: 2.1em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pitch-empty {
  margin-top: 0;
  color: #9d6e3d;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  width: 100%;
  text-align: center;
}

@keyframes pitch-lane-in {
  0% { opacity: 0; transform: translateY(8px); }
  100% { opacity: 1; transform: translateY(0); }
}

@keyframes pitch-slot-in {
  0% { opacity: 0; transform: translateY(6px) scale(0.97); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes pitch-player-swap {
  0% { filter: brightness(1.18); transform: scale(0.96); }
  60% { filter: brightness(1.06); transform: scale(1.02); }
  100% { filter: brightness(1); transform: scale(1); }
}

@keyframes pitch-formation-shift {
  0% { opacity: 0; transform: translateY(10px) scale(0.95); }
  65% { opacity: 1; transform: translateY(0) scale(1.02); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.dream-actions-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  flex-wrap: wrap;
}

.dream-assign-xi,
.dream-assign-bench {
  min-width: 2.4rem;
}

.dream-group h4 {
  margin: 0 0 0.35rem;
  color: var(--text);
}

.pool-group > .muted {
  margin: 0 0 0.4rem;
  line-height: 1.2;
}

.dream-pool-drop {
  margin: 0 0 0.5rem;
}

.pool-group .dream-row {
  padding-block: 0.38rem;
}

.pool-group .dream-actions-inline {
  justify-content: flex-end;
}

.account-auth-box {
  display: grid;
  gap: 0.35rem;
}

.account-recovery-box {
  display: grid;
  gap: 0.35rem;
  margin-top: 0.15rem;
  padding-top: 0.2rem;
  border-top: 1px dashed var(--line-soft);
}

.account-input {
  width: 100%;
  min-height: 2rem;
  border: 1px solid var(--line);
  border-radius: 0.6rem;
  background: #090503;
  color: var(--text);
  font: inherit;
  padding: 0.22rem 0.5rem;
}

.account-actions {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
}

.account-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-top: 0.4rem;
}

.account-checkbox input[type="checkbox"] {
  accent-color: var(--accent);
  width: 18px;
  height: 18px;
}

.account-avatar-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.06rem;
  width: 3.05rem;
  height: 3.05rem;
  border-radius: 0.42rem;
}

.account-toggle-avatar {
  width: 2.84rem;
  height: 2.84rem;
  border-radius: 0.34rem;
  border: 1px solid rgba(255, 181, 84, 0.88);
  object-fit: contain;
  object-position: center;
  background: radial-gradient(circle at 35% 30%, rgba(255, 176, 79, 0.3), #0f0703 72%);
  padding: 0.05rem;
  display: block;
  box-shadow: 0 0 0 2px rgba(255, 168, 72, 0.2), 0 0.35rem 0.85rem rgba(0, 0, 0, 0.42);
  image-rendering: auto;
}

.account-toggle-avatar-fallback {
  font-size: 0.95rem;
  line-height: 1;
}

.avatar-editor {
  border: 1px solid var(--line-soft);
  border-radius: 0.65rem;
  padding: 0.66rem;
  display: grid;
  gap: 0.62rem;
  background: rgba(255, 255, 255, 0.02);
}

.avatar-editor-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.avatar-hero-preview {
  position: relative;
  border-radius: 1rem;
  padding: 0.92rem;
  border: 1px solid var(--line-soft);
  background: radial-gradient(circle at 50% 20%, rgba(255, 196, 102, 0.14), rgba(14, 8, 4, 0.88));
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 15.8rem;
  aspect-ratio: 3 / 4;
  overflow: visible;
  isolation: isolate;
}

.avatar-hero-img {
  width: min(16.4rem, 86vw);
  height: min(24rem, 122vw);
  border-radius: 0.75rem;
  object-fit: contain;
  object-position: center center;
  border: 2px solid rgba(255, 178, 86, 0.45);
  background: radial-gradient(circle at 35% 30%, rgba(255, 176, 79, 0.2), #0f0703 70%);
  box-shadow: 0 0.4rem 1.2rem rgba(0, 0, 0, 0.45);
  position: relative;
  z-index: 1;
  transform-origin: 50% 62%;
  animation: avatar-hero-idle 6.2s ease-in-out infinite;
}

.avatar-hero-glow {
  position: absolute;
  inset: 5.5%;
  border-radius: 1rem;
  border: 1px solid rgba(255, 179, 90, 0.18);
  pointer-events: none;
  z-index: 0;
}

.avatar-editor-head-meta {
  display: grid;
  gap: 0.1rem;
  justify-items: end;
  text-align: right;
}

.avatar-head-hint {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.avatar-save-state {
  font-size: 0.73rem;
  color: var(--success);
  border: 1px solid rgba(102, 233, 158, 0.42);
  border-radius: 0.44rem;
  background: rgba(20, 58, 36, 0.5);
  padding: 0.1rem 0.4rem;
  line-height: 1.2;
  justify-self: end;
}

.avatar-save-state.saving {
  color: #ffd8a6;
  border-color: rgba(255, 182, 99, 0.45);
  background: rgba(62, 36, 8, 0.6);
}

.avatar-save-state.error {
  color: #ffb3b3;
  border-color: rgba(255, 120, 120, 0.42);
  background: rgba(58, 18, 18, 0.58);
}

.account-avatar-preview {
  width: 5.2rem;
  height: 7.2rem;
  border-radius: 0.7rem;
  border: 1px solid var(--amber-soft);
  background: radial-gradient(circle at 35% 30%, rgba(255, 176, 79, 0.22), #0f0703 72%);
  object-fit: contain;
  padding: 0.08rem;
  animation: avatar-bob 4.6s ease-in-out infinite;
  box-shadow: 0 0.2rem 0.8rem rgba(0, 0, 0, 0.35);
}

@keyframes avatar-bob {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  }
}

body[data-motion="minimal"] .account-avatar-preview {
  animation: none;
}

body[data-motion="minimal"] .avatar-hero-img {
  animation: none;
}

@keyframes avatar-hero-idle {
  0%,
  100% {
    transform: translateY(0) rotate(-0.35deg);
  }
  50% {
    transform: translateY(-3px) rotate(0.35deg);
  }
}

.avatar-editor-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.42rem;
}

.avatar-editor-field {
  display: grid;
  gap: 0.22rem;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.avatar-editor-field.hidden {
  display: none;
}

.avatar-editor-field .account-input {
  min-height: 1.85rem;
  pointer-events: auto;
  cursor: pointer;
  position: relative;
  z-index: 1;
  -webkit-appearance: menulist;
  appearance: menulist;
}

.avatar-color-input {
  padding: 0.08rem;
  min-height: 1.85rem;
}

.avatar-builder-signedout {
  margin-top: 0.2rem;
}

.avatar-unlock-meta {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.avatar-presets-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.45rem;
}

.avatar-preset-card {
  border: 1px solid var(--line-soft);
  border-radius: 0.7rem;
  background: rgba(6, 3, 2, 0.65);
  padding: 0.4rem;
  display: grid;
  gap: 0.25rem;
  justify-items: center;
  text-align: center;
  color: var(--text);
  min-height: 8rem;
  transition: border-color 160ms ease, transform 160ms ease, opacity 160ms ease, box-shadow 160ms ease;
}

.avatar-preset-card img {
  width: 100%;
  max-width: 5.2rem;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  border-radius: 0.5rem;
  border: 1px solid var(--line-soft);
  background: radial-gradient(circle at 35% 30%, rgba(255, 176, 79, 0.15), #0f0703 72%);
}

.avatar-preset-card:hover:not(:disabled) {
  transform: translateY(-1px);
  border-color: var(--amber);
}

.avatar-preset-card.selected {
  border-color: var(--amber);
  box-shadow: 0 0 0 1px rgba(255, 171, 74, 0.4);
}

.avatar-preset-card.pending-confirm {
  border-color: #f7b666;
  box-shadow: 0 0 0 1px rgba(247, 182, 102, 0.45), 0 0 16px rgba(247, 182, 102, 0.2);
}

.avatar-preset-card.confirmed-fx {
  animation: avatar-selected-fx 620ms ease-out both;
}

.avatar-preset-card.locked {
  opacity: 0.84;
}

.avatar-preset-card.locked:not(:disabled) .avatar-preset-card-badge {
  color: #ffe4bf;
  border-color: rgba(255, 183, 92, 0.6);
}

.avatar-preset-card:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.avatar-preset-card-label {
  font-size: 0.72rem;
  line-height: 1.2;
}

.avatar-preset-card-badge {
  font-size: 0.68rem;
  line-height: 1.1;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.12rem 0.4rem;
  color: var(--text-muted);
}

.avatar-future-note {
  margin: 0;
  padding-top: 0.18rem;
  border-top: 1px solid rgba(255, 171, 74, 0.22);
}

@keyframes avatar-selected-fx {
  0% {
    transform: scale(0.98);
    box-shadow: 0 0 0 0 rgba(255, 176, 79, 0.55);
  }
  60% {
    transform: scale(1.03);
    box-shadow: 0 0 0 9px rgba(255, 176, 79, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255, 176, 79, 0);
  }
}

.avatar-unlock-toggle-btn {
  justify-self: start;
  min-height: 1.85rem;
  font-size: 0.74rem;
}

.avatar-unlock-rail.hidden {
  display: none;
}

#avatar-builder-card .avatar-editor {
  border-style: solid;
  border-color: var(--line);
  background: linear-gradient(180deg, rgba(255, 168, 72, 0.08), rgba(255, 168, 72, 0.02));
}

.avatar-template-strip {
  display: grid;
  grid-template-columns: auto repeat(5, minmax(0, 1fr));
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem;
  border-radius: 0.7rem;
  border: 1px solid var(--line-soft);
  background: rgba(7, 4, 2, 0.55);
}

.avatar-template-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}

.avatar-template-btn {
  border-radius: 0.6rem;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.02);
  padding: 0.18rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: border-color 160ms ease, transform 160ms ease;
  cursor: pointer;
}

.avatar-template-btn.active,
.avatar-template-btn:hover {
  border-color: var(--amber);
  transform: translateY(-1px);
}

.avatar-template-preview {
  width: 2.6rem;
  height: 3.1rem;
  border-radius: 0.45rem;
  object-fit: contain;
  object-position: center center;
  background: radial-gradient(circle at 38% 28%, rgba(255, 176, 79, 0.15), #0f0703 70%);
}

.avatar-personality-row {
  display: grid;
  grid-template-columns: auto repeat(3, minmax(0, 1fr));
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem;
  border-radius: 0.7rem;
  border: 1px solid var(--line-soft);
  background: rgba(7, 4, 2, 0.5);
}

.avatar-personality-btn.active {
  border-color: var(--amber);
  box-shadow: 0 0 0 1px rgba(255, 184, 84, 0.35);
  background: rgba(255, 168, 72, 0.12);
}

.avatar-editor-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.4rem;
}

.avatar-tab-btn {
  min-height: 2rem;
  font-size: 0.85rem;
  border-radius: 0.6rem;
  border: 1px solid var(--line-soft);
  background: rgba(10, 6, 3, 0.6);
}

.avatar-tab-btn.active {
  border-color: var(--amber);
  box-shadow: 0 0 0 1px rgba(255, 184, 84, 0.35);
  background: rgba(255, 168, 72, 0.1);
}

.mission-title-with-avatar {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
}

.league-member-avatar,
.member-profile-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.62rem;
  border: 1px solid var(--line-soft);
  overflow: hidden;
  background: #0d0703;
  flex: 0 0 auto;
}

.league-member-avatar {
  width: 2.2rem;
  height: 2.8rem;
}

.member-profile-avatar {
  width: 3rem;
  height: 3.8rem;
}

.league-member-avatar img,
.member-profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center top;
  background: radial-gradient(circle at 36% 30%, rgba(255, 176, 79, 0.12), #0f0703 70%);
  padding: 0.06rem;
  display: block;
}

.member-card-title-with-avatar {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.settings-note {
  margin: 0.2rem 0 0;
  line-height: 1.2;
}

.settings-note.error {
  color: #ff8f8f;
}

.fun-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
}

#fun-zone-panel.home-focus .fun-card {
  display: none;
}

#fun-zone-panel.home-focus #story-panel,
#fun-zone-panel.home-focus #family-league-panel {
  display: block;
}

#fun-zone-panel.home-focus .fun-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

#family-league-panel.compact-home .family-controls {
  display: none;
}

#family-league-panel.compact-home .family-row {
  padding-block: 0.16rem;
}

#family-league-panel.compact-home .mission-sub {
  opacity: 0.92;
}

.family-home-controls {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 0.28rem;
}

.family-home-toggle-btn {
  min-height: 1.9rem;
}

.fun-card {
  border: 1px solid var(--line-soft);
  border-radius: 0.8rem;
  padding: 0.55rem;
  background: rgba(10, 6, 3, 0.56);
}

.compact-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.35rem;
}

.compact-head h4 {
  margin: 0;
  color: var(--text);
}

.fun-info-btn {
  width: 1.3rem;
  min-width: 1.3rem;
  height: 1.3rem;
  min-height: 1.3rem;
  padding: 0;
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 153, 32, 0.08);
  color: var(--text-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-size: 0.95rem;
}

.fun-info-btn:hover,
.fun-info-btn:focus-visible {
  border-color: var(--amber-soft);
  color: var(--text);
}

.fun-guide {
  margin: -0.05rem 0 0.42rem;
  padding: 0.3rem 0.38rem;
  border: 1px dashed var(--line-soft);
  border-radius: 0.55rem;
  color: var(--text-soft);
  background: rgba(255, 153, 32, 0.06);
  line-height: 1.08;
}

.mission-row,
.family-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  border-top: 1px dashed var(--line-soft);
  padding: 0.35rem 0;
  position: relative;
  overflow: hidden;
}

.family-row {
  cursor: pointer;
}

.family-row:focus-visible {
  outline: 2px solid #c98220;
  outline-offset: 2px;
  border-radius: 0.62rem;
}

.mission-goal-flash {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  border-radius: 0.62rem;
  background:
    radial-gradient(circle at center, rgba(66, 219, 148, 0.12), rgba(0, 0, 0, 0.9) 55%),
    repeating-linear-gradient(
      0deg,
      rgba(112, 255, 170, 0.07) 0,
      rgba(112, 255, 170, 0.07) 1px,
      transparent 1px,
      transparent 5px
    ),
    rgba(2, 15, 8, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
}

.mission-goal-flash.active {
  display: flex;
  animation: goal-overlay 4.6s ease-out both;
}

.mission-goal-flash .goal-stage {
  position: absolute;
  width: calc(100% - 0.6rem);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0;
}

.mission-goal-flash .goal-word {
  font-size: clamp(1.2rem, 3.2vw, 1.8rem);
  color: #baffd8;
  text-shadow: 0 0 6px rgba(112, 255, 170, 0.9);
  animation: goal-stage-a 1.8s steps(8, end) both;
}

.mission-goal-flash .goal-team-name {
  font-size: clamp(0.95rem, 2.4vw, 1.2rem);
  color: #9fffcf;
  text-shadow: 0 0 10px rgba(86, 255, 164, 0.6);
  animation: goal-stage-b 1.8s 1.55s steps(8, end) both;
}

.mission-goal-flash .goal-scoreline {
  font-size: clamp(1rem, 2.6vw, 1.3rem);
  color: #fff4e6;
  text-shadow: 0 0 10px rgba(103, 255, 177, 0.62);
  animation: goal-stage-c 1.8s 3s steps(8, end) both;
}

.mission-row:first-child,
.family-row:first-child {
  border-top: 0;
}

.mission-text {
  min-width: 0;
}

.mission-title {
  color: var(--text);
  line-height: 1.1;
}

.mission-sub {
  color: var(--text-soft);
  line-height: 1.05;
}

.story-list {
  display: grid;
  gap: 0.45rem;
}

.story-item {
  border: 1px solid var(--line-soft);
  border-radius: 0.65rem;
  padding: 0.38rem 0.45rem;
  background: rgba(255, 153, 32, 0.04);
}

.story-item.story-skeleton {
  display: grid;
  gap: 0.34rem;
  min-height: 3.6rem;
  padding-block: 0.52rem;
}

.story-item h5 {
  margin: 0 0 0.2rem;
  color: var(--text);
  font-size: 1.04rem;
}

.story-item p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.15;
}

.story-item.loading {
  position: relative;
  overflow: hidden;
}

.story-item.loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 165, 47, 0) 0%,
    rgba(255, 165, 47, 0.12) 48%,
    rgba(255, 165, 47, 0) 100%
  );
  transform: translateX(-100%);
  animation: story-loading-sweep 1.25s linear infinite;
  pointer-events: none;
}

.family-controls {
  display: grid;
  gap: 0.32rem;
  margin-bottom: 0.25rem;
}

.family-season-countdown {
  margin: 0;
  color: var(--text-soft);
}

.family-options-panel {
  display: grid;
  gap: 0.35rem;
  padding: 0.4rem;
  border: 1px dashed var(--line-soft);
  border-radius: 0.62rem;
  background: rgba(0, 0, 0, 0.2);
}

.family-points {
  display: inline-flex;
  min-width: 2rem;
  justify-content: center;
  align-items: center;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.05rem 0.42rem;
}

.title-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 0.28rem;
}

.title-badge-ghost {
  opacity: 0.45;
}

.family-row.active {
  background: rgba(255, 153, 32, 0.09);
  border-radius: 0.62rem;
  padding-inline: 0.35rem;
}

.challenge-card {
  min-height: 8.5rem;
}

#pop-quiz-panel .player-pop-main,
#dream-team-card .dream-team-toggle {
  width: 100%;
}

.club-quiz-body {
  margin-top: 0.35rem;
  display: grid;
  gap: 0.42rem;
}

.club-quiz-image {
  width: 100%;
  max-height: 9.5rem;
  object-fit: contain;
  object-position: center;
  border-radius: 0.68rem;
  border: 1px solid var(--line-soft);
  background: rgba(8, 5, 3, 0.6);
}

.club-quiz-options {
  display: grid;
  gap: 0.34rem;
}

.club-quiz-option {
  width: 100%;
  justify-content: flex-start;
  text-align: left;
  padding-inline: 0.56rem;
}

.club-quiz-feedback {
  margin: 0;
  color: var(--text-soft);
}

.club-quiz-feedback.correct {
  color: #9ff5a8;
}

.club-quiz-feedback.wrong {
  color: #ffc2c2;
}

.challenge-block {
  display: grid;
  gap: 0.38rem;
}

.challenge-skeleton {
  display: grid;
  gap: 0.34rem;
  min-height: 5.2rem;
  align-content: start;
}

.challenge-stat-row {
  display: flex;
  align-items: center;
  gap: 0.42rem;
}

.challenge-stat-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.8rem;
  min-height: 2rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.05rem 0.5rem;
  color: var(--text);
  background: rgba(255, 153, 32, 0.08);
}

.challenge-stat-copy {
  min-width: 0;
}

.challenge-stat-title {
  margin: 0;
  color: var(--text);
  line-height: 1.05;
}

.challenge-stat-sub {
  margin: 0.12rem 0 0;
  color: var(--text-soft);
  line-height: 1.05;
}

.challenge-footnote {
  margin: 0;
  color: var(--text-soft);
  opacity: 0.9;
}

.challenge-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.28rem;
}

.challenge-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  border: 1px solid var(--line-soft);
  border-radius: 0.55rem;
  padding: 0.2rem 0.36rem;
  background: rgba(255, 153, 32, 0.04);
}

.challenge-achievement-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.34rem;
}

.challenge-achievement-list li {
  border: 1px solid var(--line-soft);
  border-radius: 0.62rem;
  padding: 0.28rem 0.34rem;
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: center;
  gap: 0.36rem;
  background: rgba(255, 153, 32, 0.04);
}

.challenge-achievement-list li.locked {
  opacity: 0.76;
  border-style: dashed;
}

.challenge-achievement-list li.locked .challenge-achievement-icon {
  filter: grayscale(0.65);
}

.challenge-achievement-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.45rem;
  height: 1.45rem;
  border-radius: 999px;
  border: 1px solid var(--line-soft);
  background: rgba(255, 153, 32, 0.08);
}

.challenge-achievement-text {
  min-width: 0;
  display: grid;
  gap: 0.05rem;
}

.challenge-achievement-text strong {
  color: var(--text);
  line-height: 1.05;
}

.challenge-achievement-text small {
  color: var(--text-soft);
  line-height: 1.05;
}

.challenge-achievement-progress {
  margin-top: 0.12rem;
  color: #ffc37b;
}

.higher-lower-body {
  margin-top: 0.35rem;
  display: grid;
  gap: 0.42rem;
}

.higher-lower-status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.28rem;
}

.higher-lower-player {
  border: 1px solid var(--line-soft);
  border-radius: 0.7rem;
  background: rgba(255, 153, 32, 0.04);
  display: grid;
  justify-items: center;
  gap: 0.26rem;
  padding: 0.4rem;
  text-align: center;
}

.higher-lower-player.top {
  box-shadow: inset 0 0 0 1px rgba(255, 153, 32, 0.12);
}

.higher-lower-player.bottom {
  box-shadow: inset 0 0 0 1px rgba(102, 160, 255, 0.12);
}

.higher-lower-cutout {
  width: 3.6rem;
  height: 3.6rem;
  object-fit: contain;
  border-radius: 50%;
  border: 1px solid var(--line-soft);
  background: rgba(8, 5, 3, 0.76);
}

.higher-lower-meta {
  display: grid;
  gap: 0.06rem;
}

.higher-lower-meta strong {
  line-height: 1;
}

.higher-lower-meta span {
  color: var(--text-soft);
  line-height: 1;
}

.higher-lower-controls {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.higher-lower-arrow {
  min-width: 3rem;
  min-height: 2.2rem;
  font-size: 1.15rem;
  line-height: 1;
}

.higher-lower-arrow.up {
  border-color: #2e9850;
  color: #d7ffe2;
  background: linear-gradient(180deg, rgba(58, 158, 86, 0.3), rgba(22, 88, 42, 0.28));
}

.higher-lower-arrow.down {
  border-color: #af4545;
  color: #ffd4d4;
  background: linear-gradient(180deg, rgba(178, 63, 63, 0.3), rgba(94, 26, 26, 0.28));
}

.hl-correct {
  border-color: #2f8f44;
  color: #d7ffe0;
  background: rgba(60, 140, 76, 0.22);
}

.hl-wrong {
  border-color: #a03f3f;
  color: #ffd3d3;
  background: rgba(138, 50, 50, 0.2);
}

.fixture-predict {
  border: 1px solid var(--line-soft);
  border-radius: 0.7rem;
  padding: 0.65rem;
  margin-top: 0.4rem;
  background: rgba(255, 153, 32, 0.03);
}

.predict-head {
  color: var(--text);
  margin-bottom: 0.4rem;
}

.predict-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 0.7rem;
  justify-content: stretch;
  margin-top: 0.2rem;
}

.predict-score-stack {
  display: grid;
  grid-template-rows: auto auto;
  align-items: center;
  justify-items: stretch;
  gap: 0.35rem;
  min-width: 0;
}

.predict-stepper {
  display: grid;
  grid-template-columns: 2.55rem minmax(0, 1fr) 2.55rem;
  gap: 0.32rem;
  align-items: center;
}

.predict-team-label {
  max-width: 100%;
  color: var(--text-soft);
  font-size: 0.82rem;
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left;
}

.predict-score-sep {
  font-size: 1.15rem;
  color: var(--text-soft);
  line-height: 1;
  align-self: center;
  justify-self: center;
  min-width: 0.6rem;
}

.predict-step-btn {
  width: 2.55rem;
  min-width: 2.55rem;
  min-height: 2.55rem;
  height: 2.55rem;
  padding: 0;
  border-radius: 0.72rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  line-height: 1;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.predict-step-btn.plus {
  border-color: #2f8f44;
  color: #dcffe1;
  background: linear-gradient(180deg, rgba(66, 156, 84, 0.45), rgba(31, 105, 49, 0.45));
}

.predict-step-btn.minus {
  border-color: #c8372b;
  color: #ffd9d9;
  background: linear-gradient(180deg, rgba(204, 68, 54, 0.45), rgba(126, 34, 28, 0.45));
}

.predict-input {
  width: 100%;
  min-height: 2.55rem;
  border: 1px solid var(--line);
  border-radius: 0.72rem;
  background: #090503;
  color: var(--text);
  font: inherit;
  text-align: center;
  font-size: 1.4rem;
  padding: 0.1rem 0.2rem;
}

.predict-input::-webkit-outer-spin-button,
.predict-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.predict-input[type="number"] {
  -moz-appearance: textfield;
}

.predict-status {
  margin-top: 0.46rem;
  color: var(--text-soft);
}

.predict-success-label {
  display: inline-flex;
  margin-top: 0.26rem;
  border-radius: 999px;
  border: 1px solid #2f8f44;
  background: rgba(60, 140, 76, 0.22);
  color: #d7ffe0;
  padding: 0.08rem 0.5rem;
}

.predict-status.success {
  color: #d7ffe0;
  text-shadow: 0 0 10px rgba(90, 235, 130, 0.28);
}

.predict-quick-row {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.35rem;
}

.predict-chip {
  min-width: 0;
  padding: 0.28rem 0.4rem;
}

.predict-save-btn {
  grid-column: 1 / -1;
  justify-self: start;
}

.reward-toast {
  position: fixed;
  left: 50%;
  bottom: max(0.95rem, env(safe-area-inset-bottom));
  transform: translate(-50%, 14px);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(6, 8, 11, 0.94);
  color: var(--text);
  padding: 0.32rem 0.82rem;
  z-index: 1300;
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
}

.reward-toast.active {
  opacity: 1;
  transform: translate(-50%, 0);
}

.reward-toast.success {
  border-color: #2f8f44;
  color: #d7ffe0;
  box-shadow: 0 0 18px rgba(90, 235, 130, 0.2);
}

.avatar-unlock-modal {
  position: fixed;
  inset: 0;
  z-index: 1360;
  background: rgba(0, 0, 0, 0.56);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.avatar-unlock-card {
  width: min(460px, calc(100vw - 2rem));
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background: #090503;
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.12);
  padding: 0.8rem;
  display: grid;
  gap: 0.5rem;
}

.avatar-unlock-card h3 {
  margin: 0;
}

#avatar-unlock-status.error {
  color: #ff9aa1;
}

.league-invite-modal {
  position: fixed;
  inset: 0;
  z-index: 1350;
  background: rgba(0, 0, 0, 0.56);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.league-invite-card {
  width: min(520px, calc(100vw - 2rem));
  border: 1px solid var(--line);
  border-radius: 0.9rem;
  background: #090503;
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.12);
  padding: 0.8rem;
  display: grid;
  gap: 0.5rem;
}

.league-invite-card h3 {
  margin: 0;
}

#league-invite-auth-box {
  display: grid;
  gap: 0.5rem;
}

#league-invite-status.error {
  color: #ff9aa1;
}

@media (max-width: 860px) {
  .main-tabs {
    display: flex;
    gap: 0.4rem;
    overflow-x: auto;
    padding-bottom: 0.1rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }

  .main-tab-btn {
    flex: 0 0 auto;
    min-width: 5.7rem;
    min-height: 2.2rem;
  }

  .predict-form {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .predict-score-sep {
    display: none;
  }

  .predict-stepper {
    grid-template-columns: 2.35rem minmax(0, 1fr) 2.35rem;
  }

  .predict-quick-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .predict-save-btn {
    grid-column: 1 / -1;
    width: fit-content;
  }
}

@media (max-width: 980px) {
  :root {
    --island-clearance: calc(var(--safe-top) + 1.18rem);
  }

  .fun-grid {
    grid-template-columns: 1fr;
    gap: 0.72rem;
  }

  .member-team-compare.two,
  .member-pred-compare.two,
  .member-points-summary.two {
    grid-template-columns: 1fr;
  }

  .member-pred-grid {
    grid-template-columns: 1fr;
  }

  #fun-zone-panel.home-focus .fun-grid {
    grid-template-columns: 1fr;
  }

  .avatar-editor-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .avatar-editor-grid {
    grid-template-columns: 1fr;
  }

  .avatar-hero-preview {
    min-height: 12.8rem;
    padding: 0.75rem;
  }

  .account-avatar-preview {
    width: 5rem;
    height: 6.8rem;
  }

  .avatar-template-strip {
    grid-template-columns: 1fr;
  }

  .avatar-template-label {
    text-align: left;
  }

  .avatar-personality-row {
    grid-template-columns: 1fr;
  }

  .avatar-editor-tabs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.dream-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 0.28rem 0;
  border-top: 1px dashed var(--line-soft);
}

.dream-row.swap-active {
  background: rgba(255, 153, 32, 0.09);
  border-radius: 0.62rem;
  padding-inline: 0.32rem;
}

.dream-row.swap-target {
  background: rgba(255, 153, 32, 0.04);
  border-radius: 0.62rem;
  padding-inline: 0.32rem;
}

.dream-row:first-of-type {
  border-top: 0;
}

.dream-main {
  min-width: 0;
  display: grid;
  grid-template-columns: auto auto auto minmax(0, 1fr);
  align-items: center;
  gap: 0.42rem;
}

.dream-badge {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--line-soft);
  object-fit: contain;
  background: #120a04;
}

.dream-text {
  display: grid;
  min-width: 0;
}

.dream-name {
  color: var(--text);
}

.dream-meta {
  color: var(--text-soft);
}

.dream-remove {
  min-height: 1.8rem;
  padding: 0.1rem 0.5rem;
}

.player-dvd-layer.revealed .player-dvd-avatar {
  animation: player-pop-fade 1s ease forwards;
}

.player-dvd-layer.revealed .player-dvd-name {
  animation: player-name-rise 4s ease forwards;
}

@keyframes player-pop-fade {
  0% { opacity: 1; }
  70% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes player-name-rise {
  0% { opacity: 0; }
  8% { opacity: 1; }
  88% { opacity: 1; }
  100% { opacity: 0; }
}

.game-day-message {
  margin: 0;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 153, 32, 0.08);
  color: #ffbf74;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.game-day-message.gameday {
  color: #ffd3d3;
  border-color: #c83a2e;
  background: rgba(255, 72, 72, 0.25);
  animation: pulse 0.95s infinite steps(2, end);
}

.game-day-message.countdown {
  color: #ffbe6d;
  border-color: #8d5512;
  background: rgba(255, 153, 32, 0.14);
}

.game-day-message.neutral {
  color: var(--text-soft);
  border-color: var(--line-soft);
  background: rgba(255, 153, 32, 0.05);
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: "VT323", monospace;
  color: var(--text);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.btn,
.kickoff-time,
.match-state,
.status-pill,
.score-sep {
  font-family: "VT323", monospace;
}

h1 {
  font-size: clamp(1.7rem, 5.4vw, 2.8rem);
  line-height: 1;
  text-shadow: 0 0 8px rgba(255, 151, 24, 0.22);
}

body[data-theme="t90"] h1 {
  color: #ff8b2a;
  text-shadow:
    0 0 8px rgba(255, 139, 42, 0.55),
    0 0 16px rgba(255, 139, 42, 0.25);
}

.btn,
.date-picker,
.favorite-picker-btn {
  background: #0a0603;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  font: inherit;
  min-height: 2.1rem;
}

body[data-theme="t90"] .btn,
body[data-theme="t90"] .date-picker,
body[data-theme="t90"] .favorite-picker-btn {
  border-radius: 999px;
  border-color: #8d98ab;
  background: linear-gradient(180deg, rgba(13, 18, 27, 0.9), rgba(10, 13, 20, 0.92));
  color: #f4f8ff;
}

body[data-theme="club"] .btn,
body[data-theme="club"] .date-picker,
body[data-theme="club"] .favorite-picker-btn {
  border-color: var(--club-line, var(--line));
  color: var(--club-text, var(--text));
}

.btn {
  padding: 0.45rem 0.8rem;
  cursor: pointer;
  transition: transform 140ms ease, border-color 140ms ease, color 140ms ease;
}

.btn:hover {
  border-color: var(--amber-soft);
  color: #ffb251;
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(1px) scale(0.985);
  box-shadow: inset 0 2px 0 rgba(0, 0, 0, 0.35);
}

.btn.danger {
  border-color: #9f2b2b;
  color: #ffb3b3;
  background: rgba(140, 18, 18, 0.2);
}

.btn.danger:hover {
  border-color: #d63c3c;
  color: #ffd5d5;
}

body[data-theme="t90"] .btn:hover {
  border-color: #ff9d3d;
  color: #ffffff;
}

body[data-theme="club"] .btn:hover {
  border-color: var(--club-primary, var(--amber));
  color: #ffdcb2;
}

.btn-primary {
  background: linear-gradient(180deg, #ff9a1f, #c36b11);
  border-color: #a95e11;
  color: #150c02;
  font-weight: 700;
}

.favorite-banner {
  --fav-rgb: 255, 154, 31;
  --fav-border: var(--line);
  position: sticky;
  top: var(--island-clearance);
  z-index: 10;
  border-radius: 1.05rem;
  padding: 0.85rem;
  margin-bottom: 0.9rem;
  border-color: var(--fav-border);
  background:
    linear-gradient(180deg, rgba(var(--fav-rgb), 0.11), rgba(0, 0, 0, 0) 32%),
    var(--panel);
  box-shadow:
    inset 0 0 0 1px rgba(var(--fav-rgb), 0.18),
    0 0 24px rgba(var(--fav-rgb), 0.08);
}

.favorite-empty {
  text-align: center;
  color: var(--text-soft);
}

.favorite-content {
  display: grid;
  grid-template-columns: minmax(260px, 1.2fr) 2fr;
  gap: 0.7rem;
  align-items: center;
}

.favorite-team-block {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
}

.favorite-team-meta h2 {
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  line-height: 1;
  margin: 0 0 0.25rem;
}

.favorite-form {
  margin-top: 0.35rem;
  display: inline-flex;
  align-items: center;
  gap: 0.26rem;
}

.favorite-form-right {
  margin-top: 0;
}

.form-label {
  color: var(--text-soft);
  margin-right: 0.2rem;
}

.form-pill {
  width: 1.3rem;
  height: 1.3rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-soft);
  font-size: 0.82rem;
  line-height: 1;
}

.form-pill.win {
  border-color: #2d8040;
  background: rgba(60, 140, 76, 0.25);
  color: #d7ffe0;
}

.form-pill.loss {
  border-color: #c8372b;
  background: rgba(200, 55, 43, 0.25);
  color: #ffd2d2;
}

.form-pill.draw {
  border-color: #2e68c5;
  background: rgba(56, 114, 214, 0.3);
  color: #dceaff;
}

.form-pill.neutral {
  border-color: rgba(140, 100, 46, 0.7);
  background: rgba(115, 78, 26, 0.26);
  color: #d8b98c;
}

.favorite-logo {
  width: 56px;
  height: 56px;
  object-fit: contain;
  background: #120a04;
  border: 1px solid var(--line);
  border-radius: 0.7rem;
  padding: 0.2rem;
}

.label,
.muted,
.fixture-detail {
  color: var(--text-soft);
}

.favorite-fixture-block {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(var(--fav-rgb), 0.4);
  border-radius: 0.75rem;
  padding: 0.55rem;
  background: rgba(0, 0, 0, 0.28);
}

.favorite-fixture-block.loading {
  position: relative;
}

.favorite-fixture-block.loading::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 0.7rem;
  background: linear-gradient(
    90deg,
    rgba(255, 165, 47, 0) 0%,
    rgba(255, 165, 47, 0.1) 48%,
    rgba(255, 165, 47, 0) 100%
  );
  transform: translateX(-100%);
  animation: story-loading-sweep 1.2s linear infinite;
  pointer-events: none;
}

.favorite-fixture-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  margin-bottom: 0.22rem;
}

.favorite-fixture-block .skeleton-line {
  height: 0.62rem;
}

.ticker-loading {
  display: block;
  width: 100%;
}

.ticker-loading .skeleton-line {
  display: block;
  height: 0.56rem;
}

@keyframes story-loading-sweep {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.favorite-goal-cinematic {
  position: absolute;
  inset: 0;
  z-index: 8;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.7rem;
  background:
    radial-gradient(circle at 22% 50%, rgba(120, 255, 196, 0.28), transparent 52%),
    radial-gradient(circle at 80% 48%, rgba(120, 255, 196, 0.16), transparent 48%),
    linear-gradient(180deg, rgba(0, 17, 10, 0.92), rgba(0, 8, 4, 0.97)),
    repeating-linear-gradient(
      0deg,
      rgba(130, 255, 195, 0.08) 0,
      rgba(130, 255, 195, 0.08) 1px,
      transparent 1px,
      transparent 4px
    );
  box-shadow:
    inset 0 0 0 1px rgba(140, 255, 202, 0.25),
    0 0 22px rgba(80, 255, 170, 0.25);
}

.favorite-goal-cinematic.active {
  animation: favorite-goal-overlay 7.4s ease-out both;
}

.favorite-goal-stage {
  position: absolute;
  width: calc(100% - 1.1rem);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  opacity: 0;
}

.favorite-goal-word {
  font-size: clamp(2.6rem, 9vw, 4.1rem);
  color: #c6ffea;
  text-shadow:
    0 0 8px rgba(133, 255, 201, 0.85),
    0 0 22px rgba(78, 255, 173, 0.7),
    0 0 44px rgba(33, 204, 128, 0.45);
  animation: favorite-goal-stage-a 2.5s steps(12, end) both;
}

.favorite-goal-team {
  font-size: clamp(1.9rem, 5.8vw, 2.8rem);
  color: #a6ffd8;
  text-shadow: 0 0 14px rgba(95, 255, 175, 0.65);
  animation: favorite-goal-stage-b 2.35s 2.35s steps(10, end) both;
}

.favorite-goal-score {
  font-size: clamp(1.6rem, 5vw, 2.25rem);
  color: #e6fff3;
  text-shadow: 0 0 12px rgba(125, 255, 195, 0.65);
  animation: favorite-goal-stage-c 2.15s 4.8s steps(10, end) both;
}

.status-pill {
  margin: 0;
  display: inline-block;
  font-size: 0.74rem;
  letter-spacing: 0.05em;
  padding: 0.14rem 0.5rem;
  border-radius: 999px;
  text-transform: uppercase;
  border: 1px solid #684312;
  color: #ffbf72;
  background: rgba(255, 153, 32, 0.11);
}

.status-pill.live {
  color: #ffd8d8;
  border-color: #d23b2f;
  background: rgba(255, 72, 72, 0.3);
  animation: pulse 0.95s infinite steps(2, end);
}

body[data-theme="t90"] .status-pill.live {
  border-color: #ff3a3a;
  color: #ffe8e8;
  background: rgba(255, 58, 58, 0.32);
}

.status-pill.gameday {
  background: rgba(255, 160, 25, 0.22);
  border-color: #9a5e15;
}

.status-pill.final {
  color: #d5ffd8;
  border-color: #2f8f44;
  background: rgba(60, 140, 76, 0.28);
}

body[data-theme="t90"] .status-pill.final {
  border-color: #77e56f;
  color: #e9ffe7;
  background: rgba(120, 231, 114, 0.22);
}

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

@keyframes favorite-goal-overlay {
  0% { opacity: 0; }
  5% { opacity: 1; }
  92% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes favorite-goal-stage-a {
  0% { opacity: 0; transform: scale(0.9); filter: blur(1px); }
  16% { opacity: 1; transform: scale(1.02); filter: blur(0); }
  74% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.04); }
}

@keyframes favorite-goal-stage-b {
  0% { opacity: 0; transform: translateY(12px); }
  16% { opacity: 1; transform: translateY(0); }
  74% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-3px); }
}

@keyframes favorite-goal-stage-c {
  0% { opacity: 0; transform: translateY(12px); }
  20% { opacity: 1; transform: translateY(0); }
  78% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-3px); }
}

.fixture-line,
.fixture-detail {
  margin: 0.15rem 0;
  font-size: 0.93rem;
}

.live-strip {
  margin-top: 0.45rem;
  border-top: 1px dashed var(--line-soft);
  padding-top: 0.35rem;
  color: var(--amber);
  font-size: 0.86rem;
  overflow: hidden;
  white-space: nowrap;
}

.ticker-content {
  display: inline-block;
  padding-left: 100%;
  animation: ticker-slide 18s linear infinite;
}

.live-strip.ticker-static {
  white-space: normal;
  overflow: visible;
}

.live-strip.ticker-static .ticker-content {
  display: block;
  padding-left: 0;
  animation: none;
}

@keyframes ticker-slide {
  from { transform: translateX(0); }
  to { transform: translateX(-100%); }
}

.favorite-picker-btn,
.date-picker {
  padding: 0.35rem 0.5rem;
}

.date-picker {
  min-width: 150px;
  max-width: 100%;
}

.favorite-picker {
  position: relative;
}

.favorite-picker-btn {
  width: 100%;
  min-height: 2.35rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  cursor: pointer;
}

.picker-fab {
  width: 2.35rem;
  min-width: 2.35rem;
  height: 2.35rem;
  min-height: 2.35rem;
  border-radius: 999px;
  padding: 0;
  justify-content: center;
}

.picker-fab .picker-selected {
  width: 100%;
  justify-content: center;
}

.picker-fab .picker-logo {
  width: 22px;
  height: 22px;
}

.picker-selected {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
  overflow: hidden;
}

.picker-logo {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 1px solid var(--line-soft);
  background: #120a04;
  object-fit: contain;
  flex-shrink: 0;
}

.picker-chevron {
  color: var(--text-soft);
  line-height: 1;
}

.favorite-picker-menu {
  position: fixed;
  top: var(--favorite-picker-menu-top, 6rem);
  left: var(--favorite-picker-menu-left, 0.6rem);
  width: var(--favorite-picker-menu-width, min(360px, calc(100vw - 1.2rem)));
  max-width: calc(100vw - 1.2rem);
  min-width: 280px;
  max-height: var(--favorite-picker-menu-max-height, 320px);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: #090503;
  z-index: 620;
  box-shadow: inset 0 0 0 1px rgba(255, 152, 17, 0.08);
}

.header-picker {
  z-index: 610;
}

.favorite-option {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line-soft);
  background: transparent;
  color: var(--text);
  text-align: left;
  padding: 0.52rem 0.6rem;
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  cursor: pointer;
  font: inherit;
  font-size: 1.06rem;
  line-height: 1.1;
  transition: background-color 140ms ease;
}

.favorite-option:last-child {
  border-bottom: 0;
}

.favorite-option:hover {
  background: rgba(255, 152, 17, 0.08);
}

.option-logo {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid var(--line-soft);
  object-fit: contain;
  background: #120a04;
  flex-shrink: 0;
}

.option-text {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
  gap: 0.08rem;
}

.option-team {
  color: var(--text);
  overflow-wrap: anywhere;
  word-break: break-word;
}

.option-league {
  color: var(--text-soft);
  font-size: 0.94rem;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.clear-option .option-league {
  color: #9a6a2d;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.controls-panel,
.grid-layout {
  margin-bottom: 0;
}

.panel {
  border-radius: 1.05rem;
  padding: 0.7rem;
  margin: 0;
}

main {
  display: grid;
  gap: 0.9rem;
}

.filter-toolbar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.filter-group {
  border: 1px solid var(--line-soft);
  border-radius: 0.8rem;
  padding: 0.5rem;
  background: rgba(255, 149, 18, 0.03);
}

.filter-label {
  margin: 0 0 0.38rem;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-size: 0.95rem;
}

.league-controls,
.date-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.date-controls {
  margin-top: 0;
}

.date-nav {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.date-arrow-btn {
  min-width: 2.1rem;
  width: 2.1rem;
  padding: 0;
  line-height: 1;
  font-size: 0.95rem;
  border-color: #9a5d14;
}

.date-arrow-btn:hover {
  border-color: #c87917;
}

.league-btn.active,
.date-quick-btn.active {
  border-color: #b56510;
  color: #ffb452;
}

body[data-theme="t90"] .league-btn.active,
body[data-theme="t90"] .date-quick-btn.active,
body[data-theme="t90"] .theme-btn.active {
  border-color: #ff9d3d;
  color: #fff8ef;
  background: linear-gradient(180deg, rgba(255, 122, 24, 0.32), rgba(255, 122, 24, 0.16));
}

.grid-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
}

.panel-head {
  margin-bottom: 0.55rem;
}

.list {
  display: grid;
  gap: 0.55rem;
}

.fixture-item {
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  background: #080502;
  transition: border-color 140ms ease, transform 140ms ease;
  position: relative;
}

.fixture-item:hover {
  border-color: #8f5411;
  transform: translateY(-1px);
}

.fixture-item.has-favorite {
  border-color: #a96518;
}

.fixture-ribbon {
  border: 1px solid #8f5411;
  border-radius: 999px;
  padding: 0.1rem 0.42rem;
  color: #ffcb82;
  background: rgba(255, 153, 32, 0.12);
  font-size: 0.72rem;
  line-height: 1;
  white-space: nowrap;
}

.fixture-corner-badges {
  position: absolute;
  top: 0.44rem;
  right: 0.55rem;
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
  z-index: 2;
}

.fixture-ribbon-predicted {
  border-color: #2b8f4b;
  color: #d9ffe3;
  background: rgba(43, 143, 75, 0.2);
}

.fixture-focus {
  border-color: #d58a2a;
  box-shadow: inset 0 0 0 1px rgba(255, 172, 72, 0.24);
}

.fixture-dimmed {
  opacity: 0.58;
  transform: scale(0.992);
}

.fixture-item summary {
  list-style: none;
  cursor: pointer;
  padding: 0.55rem;
  position: relative;
  overflow: hidden;
}

.fixture-item summary::-webkit-details-marker {
  display: none;
}

.summary-main {
  display: grid;
  gap: 0.5rem;
}

.fixture-meta-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}

.kickoff-time,
.match-state {
  font-size: 0.72rem;
  white-space: nowrap;
  border-radius: 999px;
  line-height: 1;
  padding: 0.22rem 0.42rem;
  border: 1px solid var(--line);
  color: #f5ac4e;
  background: #120902;
}

.match-state.live {
  border-color: #c8372b;
  color: #ffcbcb;
  background: #42100d;
}

body[data-theme="t90"] .match-state.live {
  border-color: #ff3a3a;
  color: #ffe8e8;
  background: rgba(255, 58, 58, 0.32);
}

.match-state.final {
  border-color: #2d8040;
  color: #ccf4d1;
  background: #10311a;
}

body[data-theme="t90"] .match-state.final {
  border-color: #77e56f;
  color: #e9ffe7;
  background: rgba(120, 231, 114, 0.22);
}

.teams {
  min-width: 0;
  color: var(--text);
  font-size: 0.95rem;
}

.teams.scoreline {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.75rem;
}

.goal-flash {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.6rem;
  background:
    radial-gradient(circle at center, rgba(66, 219, 148, 0.12), rgba(0, 0, 0, 0.9) 55%),
    repeating-linear-gradient(
      0deg,
      rgba(112, 255, 170, 0.07) 0,
      rgba(112, 255, 170, 0.07) 1px,
      transparent 1px,
      transparent 5px
    ),
    rgba(2, 15, 8, 0.92);
}

.goal-flash.active {
  animation: goal-overlay 6.6s ease-out both;
}

.goal-stage {
  position: absolute;
  width: calc(100% - 1rem);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0;
}

.goal-word {
  font-size: clamp(2rem, 7vw, 3.1rem);
  color: #baffd8;
  text-shadow:
    0 0 6px rgba(112, 255, 170, 0.9),
    0 0 16px rgba(79, 231, 150, 0.7);
  animation: goal-stage-a 2.2s steps(10, end) both;
}

.goal-team-name {
  font-size: clamp(1.5rem, 5vw, 2.15rem);
  color: #9fffcf;
  text-shadow: 0 0 10px rgba(86, 255, 164, 0.6);
  animation: goal-stage-b 2.2s 2.1s steps(8, end) both;
}

.goal-scoreline {
  font-size: clamp(1.35rem, 4.6vw, 1.95rem);
  color: #d8ffe8;
  text-shadow: 0 0 8px rgba(99, 247, 164, 0.6);
  animation: goal-stage-c 2.1s 4.3s steps(8, end) both;
}

@keyframes goal-overlay {
  0% { opacity: 0; }
  6% { opacity: 1; }
  88% { opacity: 1; }
  100% { opacity: 0; }
}

@keyframes goal-stage-a {
  0% { opacity: 0; transform: scale(0.92); }
  18% { opacity: 1; transform: scale(1); }
  74% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.03); }
}

@keyframes goal-stage-b {
  0% { opacity: 0; transform: translateY(8px); }
  18% { opacity: 1; transform: translateY(0); }
  74% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-2px); }
}

@keyframes goal-stage-c {
  0% { opacity: 0; transform: translateY(8px); }
  20% { opacity: 1; transform: translateY(0); }
  76% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(-2px); }
}

@keyframes score-pop {
  0% { transform: scale(1); }
  35% { transform: scale(1.2); }
  75% { transform: scale(0.94); }
  100% { transform: scale(1); }
}

.team-col {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.home-col {
  justify-content: flex-end;
  text-align: right;
}

.away-col {
  justify-content: flex-start;
  text-align: left;
}

.home-team,
.away-team {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.score-center {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  justify-content: center;
  min-width: 130px;
  max-width: 100%;
}

.team-badge {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  object-fit: contain;
  background: #120a04;
  border: 1px solid var(--line-soft);
}

.team-score {
  width: 1.75rem;
  height: 1.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid #7a4810;
  color: var(--amber);
  background: #170c03;
  font-weight: 700;
}

.team-score-inline {
  display: none;
}

.team-score.leading {
  border: 2px solid #ffc05f;
  box-shadow: 0 0 0 1px rgba(255, 192, 95, 0.25);
}

.team-score.score-update {
  animation: score-pop 780ms steps(6, end);
}

body[data-theme="t90"] .team-score.leading {
  border-color: #ffb04f;
  box-shadow:
    0 0 0 1px rgba(255, 176, 79, 0.45),
    0 0 12px rgba(255, 176, 79, 0.35);
}

.score-sep {
  color: var(--text-soft);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.fixture-details {
  padding: 0 0.55rem 0.6rem;
  color: var(--text-soft);
  line-height: 1.35;
}

.detail-grid {
  display: grid;
  gap: 0.25rem;
}

.detail-row {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  align-items: baseline;
  gap: 0.4rem;
}

.detail-label {
  color: #d39a4f;
}

.detail-value {
  color: var(--text-soft);
}

.detail-empty {
  margin: 0.4rem 0 0;
  color: #9b6f37;
}

.stats-block {
  margin-top: 0.45rem;
  border-top: 1px dashed var(--line-soft);
  padding-top: 0.35rem;
  display: grid;
  gap: 0.18rem;
}

.highlights-block {
  margin-top: 0.45rem;
  border-top: 1px dashed var(--line-soft);
  padding-top: 0.35rem;
  display: grid;
  gap: 0.22rem;
}

.highlights-link {
  justify-self: start;
  min-height: 1.9rem;
  padding: 0.2rem 0.55rem;
}

.stats-title {
  margin: 0 0 0.1rem;
  color: var(--text);
}

.stat-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto auto;
  align-items: baseline;
  gap: 0.32rem;
}

.stat-label {
  color: var(--text-soft);
}

.stat-home,
.stat-away {
  color: var(--text);
}

.stat-sep {
  color: #9e6e35;
}

.fixture-details.loading {
  opacity: 0.72;
}

.fixture-skeleton,
.table-skeleton {
  border: 1px solid var(--line-soft);
  border-radius: 0.8rem;
  padding: 0.58rem;
  display: grid;
  gap: 0.44rem;
  background: #080502;
}

.skeleton-line {
  display: block;
  height: 0.64rem;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(138, 88, 32, 0.35), rgba(255, 161, 58, 0.3), rgba(138, 88, 32, 0.35));
  background-size: 220% 100%;
  animation: skeleton-shift 1.35s linear infinite;
}

.skeleton-line.w-20 { width: 20%; }
.skeleton-line.w-40 { width: 40%; }
.skeleton-line.w-45 { width: 45%; }
.skeleton-line.w-65 { width: 65%; }
.skeleton-line.w-90 { width: 90%; }

@keyframes skeleton-shift {
  0% { background-position: 120% 0; }
  100% { background-position: -120% 0; }
}

.tables-wrap {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.table-card {
  border: 1px solid var(--line);
  border-radius: 0.85rem;
  padding: 0.5rem;
  background: #080502;
  transition: border-color 140ms ease;
}

.table-band-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.38rem 0.5rem 0.15rem;
}

.legend-pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line-soft);
  border-radius: 999px;
  padding: 0.08rem 0.45rem;
  font-size: 0.84rem;
  color: var(--text-soft);
}

.legend-pill.europe,
tr.table-band-europe td:first-child {
  border-left: 2px solid #3e8cff;
}

.legend-pill.promotion,
tr.table-band-promotion td:first-child {
  border-left: 2px solid #2fbf70;
}

.legend-pill.playoff,
tr.table-band-playoff td:first-child {
  border-left: 2px solid #7f6cff;
}

.legend-pill.relegation,
tr.table-band-relegation td:first-child {
  border-left: 2px solid #d94f4f;
}

tr.table-band-europe td {
  background: linear-gradient(90deg, rgba(62, 140, 255, 0.12), transparent 42%);
}

tr.table-band-promotion td {
  background: linear-gradient(90deg, rgba(47, 191, 112, 0.12), transparent 42%);
}

tr.table-band-playoff td {
  background: linear-gradient(90deg, rgba(127, 108, 255, 0.12), transparent 42%);
}

tr.table-band-relegation td {
  background: linear-gradient(90deg, rgba(217, 79, 79, 0.12), transparent 42%);
}

.table-card:hover {
  border-color: #8f5411;
}

.table-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.4rem;
}

.league-logo {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

.table-card h4 {
  color: #ffb452;
  margin: 0;
}

.table-scroll {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 450px;
}

th,
td {
  padding: 0.34rem;
  text-align: left;
  border-bottom: 1px solid var(--line-soft);
  white-space: nowrap;
}

th {
  color: var(--text-soft);
  font-weight: 600;
}

.footer {
  border-radius: 1.05rem;
  padding: 0.6rem 0.75rem;
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
  font-size: 0.95rem;
  color: var(--text-soft);
}

.footer-right {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.debug-btn {
  min-height: 1.85rem;
  padding: 0.2rem 0.55rem;
  font-size: 0.92rem;
  border-color: #6a4010;
  color: #e9a44a;
}

.debug-btn:hover {
  border-color: #b36a17;
  color: #ffc166;
}

.hidden {
  display: none !important;
}

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 360ms ease,
    transform 420ms ease;
  transition-delay: var(--reveal-delay, 0ms);
}

.reveal-on-scroll.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* Keep the header out of a transformed stacking context so fixed menus layer correctly */
.hero-bar.reveal-on-scroll.in-view {
  transform: none;
}

body[data-motion="minimal"] .ticker-content,
body[data-motion="minimal"] .goal-flash.active,
body[data-motion="minimal"] .favorite-goal-cinematic.active,
body[data-motion="minimal"] .team-score.score-update,
body[data-motion="minimal"] .skeleton-line,
body[data-motion="minimal"] .status-pill.live,
body[data-motion="minimal"] .match-state.live,
body[data-motion="minimal"] .game-day-message.gameday,
body[data-motion="minimal"] .dream-pitch-open .pitch-lane,
body[data-motion="minimal"] .dream-pitch-formation .pitch-lane,
body[data-motion="minimal"] .dream-pitch-open .pitch-slot,
body[data-motion="minimal"] .dream-pitch-formation .pitch-slot,
body[data-motion="minimal"] .dream-pitch-player .pitch-slot.filled,
body[data-motion="minimal"] .dream-pitch-formation .pitch-slot.filled {
  animation: none !important;
}

body[data-motion="minimal"] .dream-pitch-open .pitch-lane,
body[data-motion="minimal"] .dream-pitch-formation .pitch-lane,
body[data-motion="minimal"] .dream-pitch-open .pitch-slot,
body[data-motion="minimal"] .dream-pitch-formation .pitch-slot {
  opacity: 1 !important;
  transform: none !important;
}

body[data-motion="minimal"] * {
  transition-duration: 90ms !important;
}

body[data-motion="arcade"] .team-score.score-update {
  animation-duration: 1020ms;
}

body[data-motion="arcade"] .fixture-focus {
  box-shadow:
    inset 0 0 0 1px rgba(255, 172, 72, 0.36),
    0 0 16px rgba(255, 153, 32, 0.22);
}

.empty,
.error {
  color: var(--text-soft);
  border: 1px dashed var(--line);
  border-radius: 0.8rem;
  padding: 0.6rem;
}

.error {
  color: #ff7f7f;
}

@media (max-width: 1000px) {
  .filter-toolbar {
    grid-template-columns: 1fr;
  }

  .favorite-content {
    grid-template-columns: 1fr;
  }

  .tables-wrap {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  html,
  body {
    overflow-x: hidden;
  }

  .hero-bar {
    flex-direction: column;
    align-items: flex-start;
    padding: 0.84rem 0.84rem 0.76rem;
    gap: 0.55rem;
  }

  .hero-left h1 {
    letter-spacing: 0.04em;
    line-height: 1.02;
  }

  .hero-left {
    width: 100%;
    justify-content: space-between;
  }

  .hero-controls {
    width: 100%;
    justify-content: space-between;
  }

  .hero-actions {
    width: 100%;
    display: grid;
    grid-template-columns: auto auto auto 1fr auto;
    align-items: center;
    column-gap: 0.45rem;
    row-gap: 0.45rem;
    position: relative;
  }

  .settings-menu {
    grid-column: 1;
    justify-self: start;
  }

  .account-menu {
    grid-column: 2;
    justify-self: start;
  }

  .notifications-menu {
    grid-column: 3;
    justify-self: start;
  }

  .lifetime-points-pill {
    grid-column: 4;
    justify-self: start;
    min-width: 0;
  }

  .game-day-message {
    grid-column: 1 / -1;
    width: 100%;
    text-align: center;
    margin: 0;
  }

  .settings-panel {
    position: static;
    width: 100%;
    max-width: 100%;
  }

  .feature-btn,
  .hero-actions .btn {
    min-height: 2.35rem;
  }

  .player-source-toggle {
    flex-direction: column;
  }

  .dream-team-head {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .dream-team-actions {
    width: 100%;
    justify-content: center;
  }

  .dream-team-actions .btn {
    flex: 1 1 0;
    min-width: 0;
  }

  .dream-team-overlay {
    top: calc(var(--safe-top) + 1.15rem);
    right: 0.45rem;
    bottom: 0.45rem;
    left: 0.45rem;
    padding: 0.62rem;
  }

  .dream-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .squad-detail-grid {
    grid-template-columns: 1fr;
  }

  .pitch-lane {
    justify-content: center;
  }

  .pitch-slot {
    max-width: none;
  }

  .pitch-lane.compact .pitch-slot {
    min-height: 96px;
    padding: 0.2rem 0.15rem;
  }

  .pitch-lane.compact .pitch-player-name {
    font-size: 0.7rem;
  }

  .dream-actions-inline {
    width: 100%;
  }

  .dream-actions-inline .btn {
    flex: 1 1 0;
    min-width: 0;
  }

  .dream-controls-row {
    justify-content: center;
    text-align: center;
  }

  .dream-controls-row label {
    width: 100%;
    text-align: center;
  }

  .header-picker {
    grid-column: 1 / -1;
    width: 100%;
    display: flex;
    justify-content: stretch;
    min-width: 0;
  }

  .header-picker .picker-fab {
    width: 100%;
    min-width: 0;
    height: auto;
    min-height: 2.6rem;
    margin-left: 0;
    border-radius: 0.8rem;
    padding: 0.38rem 0.65rem;
    justify-content: space-between;
  }

  .header-picker .picker-fab .picker-selected {
    width: 100%;
    justify-content: flex-start;
    gap: 0.5rem;
  }

  .header-picker .picker-fab .picker-logo {
    width: 20px;
    height: 20px;
  }

  #favorite-picker-text.sr-only {
    position: static;
    width: auto;
    height: auto;
    padding: 0;
    margin: 0;
    overflow: visible;
    clip: auto;
    white-space: nowrap;
    border: 0;
  }

  .header-picker .favorite-picker-menu {
    left: var(--favorite-picker-menu-left, 0.5rem);
    width: var(--favorite-picker-menu-width, calc(100vw - 1rem));
    min-width: 0;
    max-width: calc(100vw - 1rem);
    top: var(--favorite-picker-menu-top, 7rem);
    max-height: var(--favorite-picker-menu-max-height, min(56vh, 360px));
    z-index: 760;
  }

  .favorite-option {
    padding: 0.62rem 0.65rem;
    gap: 0.6rem;
    font-size: 1.12rem;
  }

  .option-logo {
    width: 26px;
    height: 26px;
  }

  .app-shell {
    width: calc(100% - 1rem);
    margin: max(0.6rem, calc(var(--safe-top) + 0.95rem)) auto;
  }

  .panel {
    padding: 0.72rem;
    margin-bottom: 0.72rem;
  }

  .panel-head {
    margin-bottom: 0.5rem;
  }

  .fun-card {
    padding: 0.68rem;
  }

  .mission-sub,
  .muted {
    line-height: 1.22;
  }

  .mobile-tabs-panel {
    display: none;
  }

  .mobile-tab-btn.active {
    border-color: var(--amber-soft);
    color: #ffcf8f;
    background: rgba(255, 153, 32, 0.12);
  }

  .filter-group,
  .favorite-picker-menu,
  .fixture-item,
  .favorite-fixture-block,
  .table-card {
    max-width: 100%;
  }

  .date-controls .btn,
  .league-controls .btn {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 2.24rem;
  }

  .date-picker {
    width: 100%;
    min-width: 0;
  }

  .date-nav {
    width: 100%;
  }

  .date-arrow-btn {
    flex: 0 0 2.1rem;
  }

  .predict-chip,
  .predict-save-btn {
    min-height: 2.2rem;
  }

  .home-team,
  .away-team,
  #favorite-name,
  #favorite-picker-text {
    overflow-wrap: anywhere;
    word-break: break-word;
  }

  .teams.scoreline {
    grid-template-columns: 1fr;
    gap: 0.35rem;
  }

  .home-col,
  .away-col {
    justify-content: space-between;
    text-align: left;
    width: 100%;
  }

  .score-center {
    display: none;
  }

  .team-score-inline {
    display: inline-flex;
  }

  .home-col .home-team,
  .away-col .away-team {
    flex: 1;
    min-width: 0;
  }

  .home-col .home-team {
    margin-right: 0.35rem;
  }

  .away-col .away-team {
    order: 2;
    margin: 0 0.35rem 0 0.35rem;
  }

  .away-col .away-badge {
    order: 1;
  }

  .away-col .away-inline-score {
    order: 3;
  }

  .fixture-corner-badges {
    top: 0.35rem;
    right: 0.42rem;
  }

  .fixture-ribbon {
    font-size: 0.68rem;
  }

  .fixture-line,
  .fixture-detail,
  .teams {
    font-size: 0.88rem;
  }

  .avatar-presets-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .detail-row {
    grid-template-columns: 84px minmax(0, 1fr);
    gap: 0.3rem;
  }

  .footer-right {
    width: 100%;
    justify-content: space-between;
  }

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

  #table-panel table {
    min-width: 0;
  }

  #table-panel th,
  #table-panel td {
    padding: 0.28rem 0.24rem;
    font-size: 0.9rem;
  }

  /* Keep the table readable on iPhone by hiding secondary columns */
  #table-panel th:nth-child(4),
  #table-panel td:nth-child(4),
  #table-panel th:nth-child(5),
  #table-panel td:nth-child(5),
  #table-panel th:nth-child(6),
  #table-panel td:nth-child(6) {
    display: none;
  }
}
