:root {
  /* 3-layer dark premium: page / primary card / secondary surface */
  --bg: #0c1016;
  --bg2: #141a24;
  --card: #171e2a;
  --card-2: #1c2430;
  --card-border: rgba(255, 255, 255, 0.10);
  --text: #f5f5f7;
  --muted: #9aa7b8;
  --accent: #d6b75e;
  --accent-2: #3ddc97;
  --accent-soft: rgba(214, 183, 94, 0.12);
  --danger: #ff6b6b;
  --warn: #ffb020;
  --ok: #3ddc97;
  --pick: #7aa2ff;
  --radius: 14px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --tabbar-h: 58px;
  --topbar-h: 48px;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  min-height: 100%;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
}
body { overscroll-behavior-y: contain; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}
.app {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  max-width: 480px;
  margin: 0 auto;
  position: relative;
  background: linear-gradient(180deg, #10161f 0%, var(--bg) 42%);
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: calc(10px + var(--safe-top)) 14px 10px;
  background: rgba(12, 16, 22, 0.94);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--card-border);
  min-height: calc(var(--topbar-h) + var(--safe-top));
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.brand-mark {
  width: 36px; height: 36px; border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), #c9921a);
  color: #1a1200; font-weight: 800; display: grid; place-items: center;
  flex-shrink: 0;
}
.brand-title { font-weight: 700; font-size: 16px; line-height: 1.1; }
.brand-sub { font-size: 12px; color: var(--muted); }
.topbar-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.week-select-wrap select {
  appearance: none;
  background: var(--bg2);
  color: var(--text);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 8px 28px 8px 10px;
  font-size: 13px;
  max-width: 120px;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 14px) 55%, calc(100% - 9px) 55%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.icon-btn, .back-btn, .ghost-btn, .primary-btn, .tab {
  font: inherit; cursor: pointer; border: 0;
}
.icon-btn {
  width: 40px; height: 40px; border-radius: 12px;
  background: var(--bg2); color: var(--text); font-size: 18px;
  border: 1px solid var(--card-border);
}
.main {
  flex: 1;
  padding: 12px 12px calc(var(--tabbar-h) + var(--safe-bottom) + 16px);
  width: 100%;
  overflow-x: hidden;
}
.view[hidden] { display: none !important; }
.status-line {
  color: var(--muted);
  font-size: 13px;
  margin: 0 2px 10px;
  min-height: 1.2em;
}
.status-line.is-error { color: var(--danger); }
.match-list { display: flex; flex-direction: column; gap: 10px; }
.match-card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 12px;
  width: 100%;
  text-align: left;
  color: inherit;
  display: block;
  box-shadow: 0 8px 24px rgba(0,0,0,0.18);
}
.match-card:active { transform: scale(0.995); }
.card-top {
  display: flex; justify-content: space-between; gap: 8px;
  align-items: flex-start; margin-bottom: 8px;
}
.card-meta { font-size: 11px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px; }
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600;
  background: rgba(255,255,255,0.06);
}
.badge-live { background: rgba(255, 80, 80, 0.18); color: #ff8e8e; }
.badge-fin { background: rgba(61, 220, 151, 0.14); color: var(--ok); }
.badge-sched { background: rgba(122, 162, 255, 0.14); color: var(--pick); }
.badge-pending { background: rgba(255, 196, 80, 0.16); color: #ffd27a; }
.badge-ht { background: rgba(255, 160, 80, 0.16); color: #ffb070; }
.badge-post, .badge-cancel { background: rgba(255,255,255,0.08); color: var(--muted); }
.teams {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  align-items: center;
  margin: 6px 0 10px;
}
.team {
  display: flex; align-items: center; gap: 8px; min-width: 0;
}
.team.away { justify-content: flex-end; text-align: right; }
.team img {
  width: 28px; height: 28px; border-radius: 50%;
  background: #0a0e14; object-fit: contain; flex-shrink: 0;
}
.team-name {
  font-size: 13px; font-weight: 600; line-height: 1.25;
  overflow-wrap: anywhere; word-break: break-word;
}
.score {
  font-variant-numeric: tabular-nums;
  font-weight: 800; font-size: 18px; letter-spacing: 0.02em;
  min-width: 54px; text-align: center;
}
.card-bottom {
  display: flex; justify-content: space-between; align-items: center; gap: 8px;
  flex-wrap: wrap;
}
.pick-chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: rgba(122, 162, 255, 0.14);
  color: #c9d8ff;
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 12px; font-weight: 700;
}
.conf {
  font-size: 12px; color: var(--muted);
}
.risk-LOW { color: var(--ok); }
.risk-MED, .risk-MEDIUM { color: var(--warn); }
.risk-HIGH, .risk-NO_DATA { color: var(--danger); }

.tabbar {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 0;
  width: min(480px, 100%);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  padding: 8px 10px calc(8px + var(--safe-bottom));
  background: rgba(11, 15, 20, 0.96);
  border-top: 1px solid var(--card-border);
  backdrop-filter: blur(14px);
  z-index: 30;
}
.tab {
  background: transparent;
  color: var(--muted);
  border-radius: 12px;
  padding: 10px 6px;
  font-size: 13px;
  font-weight: 600;
}
.tab-active {
  color: var(--text);
  background: rgba(245, 197, 66, 0.12);
}

.back-btn {
  background: transparent;
  color: var(--accent);
  padding: 6px 0 12px;
  font-size: 14px;
  font-weight: 600;
}
.detail-root, .standings-root, .coupons-root {
  display: flex; flex-direction: column; gap: 12px;
}
.panel {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 12px;
}
.panel h3 {
  margin: 0 0 10px;
  font-size: 14px;
  color: var(--accent);
}
.kv { display: grid; grid-template-columns: 1fr auto; gap: 6px 10px; font-size: 13px; }
.kv span:last-child { color: var(--muted); text-align: right; }
.form-row, .h2h-row, .inj-row {
  display: flex; justify-content: space-between; gap: 8px;
  font-size: 13px; padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.form-row:last-child, .h2h-row:last-child, .inj-row:last-child { border-bottom: 0; }
.muted { color: var(--muted); }
.pill {
  display: inline-block; min-width: 22px; text-align: center;
  border-radius: 6px; padding: 2px 6px; font-weight: 700; font-size: 11px;
}
.pill-W { background: rgba(61,220,151,.18); color: var(--ok); }
.pill-D { background: rgba(255,255,255,.08); color: var(--muted); }
.pill-L { background: rgba(255,107,107,.18); color: var(--danger); }

.standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.standings-table th, .standings-table td {
  padding: 8px 4px;
  text-align: left;
  border-bottom: 1px solid rgba(255,255,255,0.05);
  vertical-align: middle;
}
.standings-table th { color: var(--muted); font-weight: 600; font-size: 11px; }
.standings-table td.num, .standings-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.standings-table tr.is-home td { background: rgba(122,162,255,0.08); }
.standings-table tr.is-away td { background: rgba(245,197,66,0.08); }
.team-cell { max-width: 140px; overflow-wrap: anywhere; }

.coupon-toolbar { margin-bottom: 10px; }
.primary-btn {
  background: linear-gradient(135deg, var(--accent), #d4a017);
  color: #1a1200;
  font-weight: 700;
  border-radius: 12px;
  padding: 10px 14px;
  width: 100%;
}
.ghost-btn {
  background: transparent;
  color: var(--muted);
  padding: 10px;
  width: 100%;
}
.coupon-card .coupon-head {
  display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px;
}
.coupon-card .coupon-name { font-weight: 700; font-size: 14px; }
.coupon-meta { font-size: 12px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 8px; }
.coupon-matches { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.coupon-match {
  display: grid;
  grid-template-columns: 28px 1fr auto;
  gap: 8px;
  font-size: 12px;
  align-items: center;
}

.error-card {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 12px);
  width: min(440px, calc(100% - 24px));
  background: #2a1518;
  border: 1px solid rgba(255,107,107,0.35);
  border-radius: 16px;
  padding: 14px;
  z-index: 50;
  box-shadow: 0 12px 40px rgba(0,0,0,0.45);
}
.error-title { font-weight: 700; margin-bottom: 6px; }
.error-body { color: #ffc9c9; font-size: 13px; margin-bottom: 12px; overflow-wrap: anywhere; }
.noscript {
  padding: 24px; text-align: center; color: var(--danger);
}
.empty {
  padding: 24px 12px;
  text-align: center;
  color: var(--muted);
  font-size: 14px;
}
.skeleton {
  height: 88px; border-radius: var(--radius);
  background: linear-gradient(90deg, #141a24 0%, #1b2431 50%, #141a24 100%);
  background-size: 200% 100%;
  animation: shimmer 1.2s infinite linear;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
@media (min-width: 481px) {
  .app { border-left: 1px solid var(--card-border); border-right: 1px solid var(--card-border); }
}


/* --- Mobile V2 polish extensions --- */
.match-no {
  font-size: 12px;
  font-weight: 800;
  color: var(--text);
  letter-spacing: 0.02em;
}
.league-name {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
}
.card-meta { align-items: baseline; }
.score { min-width: 64px; }
.badge-ht { background: rgba(255, 176, 32, 0.18); color: var(--warn); }
.badge-post, .badge-cancel { background: rgba(255,255,255,0.08); color: var(--muted); }
.conf-high { color: var(--ok); }
.conf-med { color: var(--warn); }
.conf-low { color: var(--danger); }
.conf-pending { color: var(--muted); }
.result-flag {
  margin-top: 8px;
  font-size: 11px;
  font-weight: 700;
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
}
.result-hit { background: rgba(61,220,151,.16); color: var(--ok); }
.result-miss { background: rgba(255,107,107,.16); color: var(--danger); }
.match-card.is-hit { border-color: rgba(61,220,151,.35); }
.match-card.is-miss { border-color: rgba(255,107,107,.35); }
.toolbar-row { margin-bottom: 8px; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--card-border);
  background: var(--bg2);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 12px;
  font-weight: 600;
}
.chip-active {
  color: var(--text);
  background: rgba(245,197,66,0.14);
  border-color: rgba(245,197,66,0.35);
}
.search-wrap { display: block; margin-bottom: 10px; }
.search-wrap input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--card-border);
  background: var(--bg2);
  color: var(--text);
  padding: 10px 12px;
  font: inherit;
  font-size: 14px;
}
.guarantee-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-top: 8px;
}
.ghost-btn.compact { padding: 10px 8px; width: 100%; border: 1px solid var(--card-border); border-radius: 12px; }
.live-root { display: flex; flex-direction: column; gap: 12px; }
.detail-section {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
}
.detail-section summary {
  list-style: none;
  cursor: pointer;
  padding: 12px;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  user-select: none;
}
.detail-section summary::-webkit-details-marker { display: none; }
.detail-section-body { padding: 0 12px 12px; }
.subhead { margin: 12px 0 6px; font-size: 12px; color: var(--muted); font-weight: 700; }
.login-gate {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(5,8,12,0.92);
  display: grid;
  place-items: center;
  padding: 20px;
  padding-top: calc(20px + var(--safe-top));
  padding-bottom: calc(20px + var(--safe-bottom));
}
.login-gate[hidden] { display: none !important; }
.login-card {
  width: min(360px, 100%);
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 18px;
  padding: 18px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.45);
}
.login-label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin: 10px 0 6px;
}
.login-input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--card-border);
  background: var(--bg2);
  color: var(--text);
  padding: 11px 12px;
  font: inherit;
}
.login-error {
  color: var(--danger);
  font-size: 13px;
  margin: 10px 0;
}
body.view-detail-open { overflow: auto; }
.team-logo-fallback {
  width: 28px; height: 28px; border-radius: 50%;
  background: #1a2230; border: 1px solid rgba(255,255,255,0.08); display: inline-block; flex-shrink: 0;
}
.week-select-wrap select { max-width: 148px; }

/* --- Astra F01–F08 / design polish --- */
.match-no {
  font-size: 13px;
  font-weight: 800;
  color: var(--muted);
  letter-spacing: 0.01em;
  line-height: 1;
}
.score.is-live { color: var(--text); }
.live-dot {
  color: #ff4d4d;
  margin: 0 2px;
  animation: livePulse 1.2s ease-in-out infinite;
  display: inline-block;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}
.detail-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 2px 0 10px;
  margin: 0 -2px 0;
  scrollbar-width: none;
}
.detail-tabs::-webkit-scrollbar { display: none; }
.detail-tab {
  flex: 0 0 auto;
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--card-border);
  background: var(--bg2);
  color: var(--muted);
  border-radius: 999px;
  padding: 7px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}
.detail-tab.active {
  color: var(--text);
  background: rgba(245,197,66,0.16);
  border-color: rgba(245,197,66,0.4);
}
.detail-tab-panels { display: flex; flex-direction: column; gap: 12px; }
.detail-hero .match-no { font-size: 14px; color: var(--muted); }

/* --- Startup splash (visual only; never blocks boot) --- */
.startup-splash {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, #0d131c 0%, #0b0f14 55%, #0b0f14 100%);
  color: var(--text);
  opacity: 1;
  transition: opacity 0.28s ease;
  pointer-events: none;
  padding: calc(16px + var(--safe-top)) 16px calc(16px + var(--safe-bottom));
}
.startup-splash.is-done { opacity: 0; }
.startup-splash-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}
.startup-mark {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  font-size: 28px;
  box-shadow: 0 12px 40px rgba(245, 197, 66, 0.22);
  animation: splashPop 0.7s ease-out both;
}
.startup-title {
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.02em;
  color: var(--text);
}
.startup-sub {
  font-size: 13px;
  color: var(--muted);
}
@keyframes splashPop {
  0% { transform: scale(0.86); opacity: 0.55; }
  60% { transform: scale(1.04); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .startup-mark { animation: none; }
  .startup-splash { transition: none; }
}

/* --- Compact SW update banner (lifecycle) --- */
.sw-update-banner {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  top: calc(10px + var(--safe-top));
  z-index: 180;
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(440px, calc(100% - 24px));
  padding: 10px 12px;
  border-radius: 12px;
  background: #161d28;
  border: 1px solid rgba(245, 197, 66, 0.35);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4);
  color: var(--text);
}
.sw-update-text { flex: 1; font-size: 13px; font-weight: 700; }
.sw-update-btn {
  appearance: none;
  border: 0;
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
  background: var(--accent);
  color: #1a1200;
  cursor: pointer;
}



/* --- Final product polish --- */
body.auth-gated #app,
body.auth-gated .tabbar { display: none !important; }
.text-btn {
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--card-border);
  background: var(--bg2);
  color: var(--text);
  border-radius: 12px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 700;
}
.hero-teams { margin: 10px 0 12px; }
.hero-team { flex-direction: column; gap: 8px; }
.team.away.hero-team { align-items: flex-end; }
.team.home.hero-team { align-items: flex-start; }
.hero-logo, .detail-hero .team img.hero-logo {
  width: 52px; height: 52px; border-radius: 50%;
  background: #0a0e14; object-fit: contain; flex-shrink: 0;
  opacity: 1; /* fix washed-out logos */
  filter: none;
}
.team img { opacity: 1; }
.hero-score { font-size: 26px; min-width: 72px; }
.hero-kick { text-align: center; }
.detail-tabs {
  padding-left: 2px;
  padding-right: 2px;
  scroll-padding-inline: 12px;
  mask-image: linear-gradient(90deg, transparent 0, #000 8px, #000 calc(100% - 8px), transparent 100%);
}
.detail-tab { padding: 8px 14px; }
.venue-photo-wrap {
  margin-top: 12px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--card-border);
}
.venue-photo {
  display: block;
  width: 100%;
  max-height: 160px;
  object-fit: cover;
  opacity: 1;
}
.coupon-preview-selected {
  border-color: rgba(245, 197, 66, 0.45);
  box-shadow: 0 0 0 1px rgba(245, 197, 66, 0.18), 0 10px 28px rgba(0,0,0,0.25);
}
.notif-compact .ghost-btn.compact { width: auto; padding: 8px 12px; }
.standings-table th, .standings-table td { white-space: nowrap; }
.standings-table td.team-cell { white-space: normal; }
.detail-root {
  padding-bottom: calc(var(--tabbar-h) + var(--safe-bottom) + 24px);
}


/* --- Premium UI restoration v7 --- */
.brand-sub {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 42vw;
}
.live-hub-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: 0 2px 4px;
}
.live-hub-title {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  color: var(--accent);
}
.live-bell {
  width: 36px;
  height: 36px;
  font-size: 16px;
  flex-shrink: 0;
}
.live-empty { font-weight: 600; color: var(--muted); }
.hero-teams .hero-team {
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
}
.team.home.hero-team,
.team.away.hero-team {
  align-items: center;
  justify-content: flex-start;
  text-align: center;
}
.hero-team .team-name { text-align: center; }
.info-card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.info-card {
  background: var(--bg2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 10px;
}
.info-card-label { font-size: 11px; color: var(--muted); margin-bottom: 4px; }
.info-card-value { font-size: 13px; font-weight: 600; overflow-wrap: anywhere; }
.prob-bars { display: flex; flex-direction: column; gap: 8px; }
.prob-bar-row { display: grid; grid-template-columns: 18px 1fr 40px; gap: 8px; align-items: center; }
.prob-bar-label { font-weight: 800; font-size: 12px; }
.prob-bar-track {
  height: 8px; border-radius: 999px; background: rgba(255,255,255,0.06); overflow: hidden;
}
.prob-bar-fill {
  height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, var(--pick), var(--accent));
}
.prob-bar-pct { font-size: 12px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }
.form-stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.form-stat-card {
  background: var(--bg2); border: 1px solid var(--card-border);
  border-radius: 12px; padding: 10px;
}
.form-stat-title { font-size: 12px; font-weight: 700; margin-bottom: 6px; }
.form-gbm { display: flex; gap: 6px; flex-wrap: wrap; }
.gbm { font-size: 12px; font-weight: 800; padding: 3px 8px; border-radius: 8px; }
.gbm-g { background: rgba(61,220,151,.16); color: var(--ok); }
.gbm-b { background: rgba(255,255,255,.08); color: var(--muted); }
.gbm-m { background: rgba(255,107,107,.16); color: var(--danger); }
.inj-team-grid { display: flex; flex-direction: column; gap: 10px; }
.inj-team-card {
  background: var(--bg2); border: 1px solid var(--card-border);
  border-radius: 12px; padding: 10px;
}
.inj-team-name { font-weight: 700; margin-bottom: 8px; }
.inj-pill-row { display: flex; flex-wrap: wrap; gap: 6px; }
.inj-pill {
  display: inline-flex; gap: 4px; align-items: center;
  background: rgba(255,255,255,0.06); border-radius: 999px;
  padding: 4px 10px; font-size: 12px;
}
/* Live event rows — minute | icon | desc (390px-safe, no break-all, no 200px rows) */
.timeline { display: flex; flex-direction: column; gap: 4px; }
.event-row {
  display: grid;
  grid-template-columns: 40px 28px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 6px 0;
  min-height: 0;
  max-height: none;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 13px;
}
.event-min {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-weight: 700;
  text-align: center;
}
.event-icon { text-align: center; line-height: 1; }
.event-desc {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: normal;
  white-space: normal;
}
@media (max-width: 390px) {
  .event-row {
    grid-template-columns: 36px 24px minmax(0, 1fr);
    gap: 6px;
    font-size: 12px;
    padding: 5px 0;
  }
}
.timeline-row {
  display: grid; grid-template-columns: 40px 22px 1fr; gap: 8px;
  align-items: start; font-size: 13px;
  padding: 6px 0; border-bottom: 1px solid rgba(255,255,255,0.04);
}
.timeline-min { font-variant-numeric: tabular-nums; color: var(--muted); font-weight: 700; }
.timeline-icon { text-align: center; }
.stat-compare { margin: 8px 0; }
.stat-compare-top {
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px;
  font-size: 12px; margin-bottom: 4px;
}
.stat-compare-top span:last-child { text-align: right; }
.stat-compare-bars {
  display: flex; height: 6px; border-radius: 999px; overflow: hidden;
  background: rgba(255,255,255,0.06);
}
.stat-compare-bars span:first-child { background: var(--pick); }
.stat-compare-bars span:last-child { background: var(--accent); }
.lineup-grid { display: flex; flex-direction: column; gap: 10px; }
.lineup-card {
  background: var(--bg2); border: 1px solid var(--card-border);
  border-radius: 12px; padding: 10px;
}
.lineup-team { font-weight: 700; margin-bottom: 6px; }
.lineup-section-label {
  font-size: 11px; color: var(--muted); font-weight: 700;
  margin: 8px 0 4px; text-transform: uppercase; letter-spacing: 0.04em;
}
.lineup-player { font-size: 12px; padding: 3px 0; }
.detail-tabs {
  scroll-padding-inline: 16px;
  padding-left: 4px;
  padding-right: 16px;
}
.detail-tab-panel.tab-panel-enter {
  animation: tabPanelInForward 200ms ease both;
}
.detail-tab-panel.tab-panel-enter-forward {
  animation: tabPanelInForward 220ms ease both;
}
.detail-tab-panel.tab-panel-enter-back {
  animation: tabPanelInBack 220ms ease both;
}
@keyframes tabPanelInForward {
  from { opacity: 0; transform: translateX(12px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes tabPanelInBack {
  from { opacity: 0; transform: translateX(-12px); }
  to { opacity: 1; transform: translateX(0); }
}
@media (prefers-reduced-motion: reduce) {
  .detail-tab-panel.tab-panel-enter,
  .detail-tab-panel.tab-panel-enter-forward,
  .detail-tab-panel.tab-panel-enter-back { animation: none; }
  .live-dot { animation: none; }
}
.coupon-preview-selected {
  outline: 2px solid rgba(245, 197, 66, 0.55);
}
.ghost-btn.guarantee-selected {
  outline: 2px solid rgba(245, 197, 66, 0.65);
  color: var(--accent, #f5c542);
}
.smart-coupon-hint { color: var(--muted); }


/* --- Week dashboard summary (main Maçlar) --- */
.week-dashboard { margin: 0 0 10px; }
.week-dashboard-card {
  background: linear-gradient(145deg, rgba(245,197,66,0.10), rgba(22,29,40,0.95));
  border: 1px solid rgba(245,197,66,0.28);
  border-radius: 14px;
  padding: 12px 14px;
}
.wd-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.wd-week { font-weight: 800; font-size: 15px; }
.wd-countdown {
  font-size: 12px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
  white-space: nowrap;
}
.wd-countdown.is-closed { color: var(--muted); }
.wd-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 6px;
}
.wd-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
}
.wd-chip b { color: var(--text); font-size: 13px; }
.wd-chip.wd-live b { color: #ff6b6b; }
.wd-ready {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
}
.wd-note { font-size: 11px; margin-top: 4px; }

/* Header: no awkward wrap at 390px */
.brand { min-width: 0; flex: 1 1 auto; }
.brand > div { min-width: 0; }
.brand-sub {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: min(42vw, 160px);
}
@media (max-width: 390px) {
  .brand-sub { max-width: 120px; font-size: 11px; }
  .brand-title { font-size: 15px; }
}

/* ANALİZ sections */
.analiz-stack { display: flex; flex-direction: column; gap: 12px; }
.analiz-section {
  background: var(--bg2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 12px;
}
.analiz-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.analiz-section-title {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.01em;
}
.analiz-pick-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}
.analiz-pick-main strong { font-size: 28px; font-weight: 800; color: var(--accent); }
.analiz-odd-boxes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.analiz-odd-box {
  text-align: center;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 8px 4px;
}
.analiz-odd-box span { display: block; font-size: 11px; color: var(--muted); font-weight: 700; }
.analiz-odd-box b { display: block; margin-top: 2px; font-size: 15px; font-variant-numeric: tabular-nums; }
.analiz-reasons { margin: 0; padding-left: 18px; }
.analiz-reasons li { margin: 4px 0; font-size: 13px; line-height: 1.35; }
.team-compare { display: flex; flex-direction: column; gap: 10px; }
.team-compare-head {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  align-items: center;
  margin-bottom: 2px;
}
.team-compare-side {
  display: flex; align-items: center; gap: 8px; min-width: 0;
  font-size: 13px; font-weight: 800;
}
.team-compare-side.away { justify-content: flex-end; text-align: right; }
.team-compare-side .tc-name { overflow-wrap: anywhere; line-height: 1.2; }
.team-compare-vs {
  font-size: 11px; font-weight: 800; letter-spacing: 0.06em;
  color: var(--accent); text-transform: uppercase;
}
.team-compare-row {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) 42px;
  gap: 8px;
  align-items: center;
  font-size: 12px;
}
.team-compare-row .tc-val { font-variant-numeric: tabular-nums; font-weight: 700; }
.team-compare-row .tc-val.home { text-align: left; }
.team-compare-row .tc-val.away { text-align: right; }
.team-compare-mid { min-width: 0; }
.team-compare-label {
  display: block; text-align: center; font-size: 10px; font-weight: 700;
  color: var(--muted); letter-spacing: 0.02em; margin-bottom: 4px;
}
.team-compare-bars {
  display: flex;
  gap: 3px;
  height: 6px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(255,255,255,0.06);
}
.team-compare-bars .tc-bar-slot {
  flex: 1 1 50%;
  display: flex;
  min-width: 0;
  height: 100%;
}
.team-compare-bars .tc-bar-slot.home { justify-content: flex-end; }
.team-compare-bars .tc-bar-slot.away { justify-content: flex-start; }
.team-compare-bars .tc-bar {
  height: 100%;
  background: rgba(214,183,94,0.55);
  min-width: 0;
  max-width: 100%;
}
.team-compare-bars .tc-bar.home { border-radius: 999px 0 0 999px; }
.team-compare-bars .tc-bar.away { border-radius: 0 999px 999px 0; }
.team-compare-bars .tc-bar.is-lead { background: rgba(214,183,94,0.92); }
.team-compare-bars .tc-bar.is-weak { background: rgba(255,255,255,0.14); }

.global-bookmakers-toggle {
  margin-top: 4px;
  border: 1px solid var(--card-border);
  border-radius: 10px;
  overflow: hidden;
  background: rgba(0,0,0,0.15);
}
.global-bookmakers-toggle > summary {
  display: flex; align-items: center; gap: 8px;
  list-style: none; cursor: pointer;
  padding: 8px 10px; font-size: 12px; font-weight: 700;
}
.global-bookmakers-toggle > summary::-webkit-details-marker { display: none; }
.global-bookmakers-toggle > summary small { margin-left: auto; color: var(--muted); }
.global-bookmakers { border-top: 1px solid var(--card-border); }
.global-bookmaker-head, .global-bookmaker-row {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) repeat(3, minmax(42px, 0.72fr));
  gap: 8px; align-items: center;
  padding: 7px 10px; border-top: 1px solid rgba(255,255,255,0.04);
  font-size: 11px;
}
.global-bookmaker-head { border-top: 0; color: var(--muted); font-weight: 700; }
.global-bookmaker-head > span:not(:first-child),
.global-bookmaker-row > span { text-align: right; font-variant-numeric: tabular-nums; }
.global-bookmaker-row > strong {
  min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left;
}
@media (max-width: 390px) {
  .global-bookmaker-head, .global-bookmaker-row {
    grid-template-columns: minmax(0, 1.35fr) repeat(3, minmax(38px, 0.72fr));
    gap: 5px;
    padding-left: 8px; padding-right: 8px;
  }
}

.detail-panel-viewport { min-height: 120px; }
.detail-shell { display: flex; flex-direction: column; gap: 0; }
.card-updated { color: var(--muted); font-size: 10px; font-weight: 700; white-space: nowrap; }


/* --- Final visual product parity (v11) --- */
html { color-scheme: dark only; background: #0b0f14; }
body.view-detail-open .topbar {
  padding-top: calc(6px + var(--safe-top));
  padding-bottom: 6px;
  min-height: calc(44px + var(--safe-top));
}
body.view-detail-open .brand-sub { display: none; }
body.view-detail-open .week-select-wrap { display: none; }
body.view-detail-open #btn-refresh { display: none; }
/* logout remains reachable */

.detail-chrome {
  position: sticky;
  top: 0;
  z-index: 8;
  background: rgba(11, 15, 20, 0.96);
  backdrop-filter: blur(12px);
  padding-bottom: 2px;
  border-bottom: 1px solid var(--card-border);
}
.detail-shell .detail-hero {
  margin-bottom: 0;
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  box-shadow: none;
}
.detail-shell .detail-tabs {
  padding-top: 8px;
  margin-bottom: 0;
}
.detail-panel-viewport {
  position: relative;
  min-height: 180px;
  margin-top: 10px;
}
.detail-tab-panel.tab-panel-enter,
.detail-tab-panel.tab-panel-enter-forward,
.detail-tab-panel.tab-panel-enter-back {
  animation-duration: 200ms;
}

.fs-section-title {
  font-size: 13px; font-weight: 800; margin: 0 0 8px; color: var(--accent);
}
.fs-match-list { display: flex; flex-direction: column; gap: 8px; }
.fs-match-row {
  background: var(--bg2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 8px 10px;
}
.fs-match-meta { font-size: 11px; color: var(--muted); margin-bottom: 6px; }
.fs-match-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px auto;
  gap: 4px 8px;
  align-items: stretch;
}
.fs-sides {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 4px;
  min-width: 0;
}
.fs-side {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  font-size: 13px;
  min-height: 22px;
}
.fs-scores {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 4px;
  align-items: center;
  justify-items: end;
}
.fs-logo, img.fs-logo {
  width: 22px; height: 22px; border-radius: 50%;
  object-fit: contain; background: #0a0e14;
}
.team-logo-fallback.fs-logo { width: 22px; height: 22px; }
.fs-name { font-weight: 600; overflow-wrap: anywhere; line-height: 1.25; }
.fs-score {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  min-width: 1.25em;
  text-align: right;
  line-height: 1.25;
}
.fs-pill-col {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  min-width: 22px;
}
.fs-pill-col .pill {
  font-size: 10px;
  font-weight: 800;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 6px;
  display: inline-grid;
  place-items: center;
}

.form-team-block {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 12px;
}
.form-team-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; margin-bottom: 8px;
}
.form-stat-grid-compact {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}
.form-recent-label {
  margin: 10px 0 6px;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.form-gbm { display: flex; flex-wrap: wrap; gap: 4px; }
.gbm {
  font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 999px;
  background: rgba(255,255,255,0.06);
}
.gbm-g { color: var(--ok); background: rgba(61,220,151,.14); }
.gbm-b { color: var(--muted); }
.gbm-m { color: var(--danger); background: rgba(255,107,107,.14); }
.form-stat-card { padding: 6px 8px; }
.form-stat-title { font-size: 10px; margin-bottom: 4px; }

.standing-head, .standing-row {
  display: grid;
  grid-template-columns: 28px 22px minmax(0,1.4fr) repeat(3, minmax(42px, 0.55fr));
  gap: 6px;
  align-items: center;
  font-size: 12px;
}
.standing-head {
  color: var(--muted); font-weight: 700; font-size: 10px;
  padding: 0 4px 6px; border-bottom: 1px solid rgba(255,255,255,0.06);
  margin-bottom: 4px;
}
.standing-row {
  padding: 7px 4px;
  border-radius: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.standing-row.is-home { background: rgba(122,162,255,0.10); }
.standing-row.is-away { background: rgba(245,197,66,0.10); }
.standing-team-name { overflow-wrap: anywhere; font-weight: 600; }
.standing-num { text-align: right; font-variant-numeric: tabular-nums; color: var(--muted); }
.standing-pts { color: var(--text); }
.standing-rank-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 25px; height: 25px; border-radius: 7px;
  font-weight: 800; font-variant-numeric: tabular-nums;
  background: rgba(255,255,255,0.06); color: var(--text);
}
.standing-rank-badge.rank-zone-1 { background:#0d5d92; color:#fff; }
.standing-rank-badge.rank-zone-2 { background:#27a8df; color:#fff; }
.standing-rank-badge.rank-zone-3 { background:#980a36; color:#fff; }
.standing-rank-badge.rank-zone-4 { background:#c48a00; color:#fff; }
.standing-rank-badge.rank-zone-drop { background:#c90000; color:#fff; }
.standing-rank-badge.rank-zone-neutral { background: rgba(255,255,255,0.06); }
.standing-legend {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; font-size: 11px; color: var(--muted);
}
.standing-legend-item { display: inline-flex; align-items: center; gap: 6px; }
.standing-legend-item .standing-rank-badge { min-width: 14px; height: 14px; border-radius: 4px; }

.inj-team-name {
  display: flex; align-items: center; gap: 8px;
  font-weight: 700; margin-bottom: 8px;
}
.inj-player-list { display: flex; flex-direction: column; gap: 6px; }
.inj-player-row {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  font-size: 13px;
}
.inj-player-name { font-weight: 600; }
.inj-reason { font-size: 12px; color: var(--muted); }

.analiz-group-label {
  font-size: 11px; font-weight: 800; letter-spacing: 0.06em;
  color: var(--accent); margin: 4px 0 2px;
}
.analiz-subblock { margin-bottom: 10px; }
.analiz-subhead {
  font-size: 11px; font-weight: 700; color: var(--muted); margin-bottom: 6px;
}

.timeline-row.timeline-home,
.timeline-row.timeline-away {
  display: grid;
  grid-template-columns: 1fr 44px 1fr;
  gap: 6px;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.timeline-side {
  display: flex; align-items: center; gap: 6px; font-size: 12px; min-width: 0;
}
.timeline-side-home { justify-content: flex-end; text-align: right; }
.timeline-side-away { justify-content: flex-start; text-align: left; }
.timeline-row .timeline-min { text-align: center; }
.timeline-body { overflow-wrap: anywhere; word-break: normal; }
.wd-perf { color: var(--accent) !important; font-weight: 700; }

@media (max-width: 390px) {
  .standing-head, .standing-row {
    grid-template-columns: 24px 18px minmax(0,1.3fr) repeat(3, minmax(36px, 0.5fr));
    font-size: 11px;
  }
}


/* --- Focused premium UX pass (v12) --- */
.topbar {
  padding: calc(6px + var(--safe-top)) 12px 6px;
  min-height: calc(var(--topbar-h) + var(--safe-top));
  gap: 8px;
}
.topbar-main, .topbar-detail {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  width: 100%;
  min-width: 0;
}
/* P0: HTML hidden must win over display:flex (double-header regression). */
.topbar-main[hidden], .topbar-detail[hidden],
.topbar [hidden] {
  display: none !important;
}
.topbar-detail { justify-content: flex-start; gap: 8px; }
.brand-compact {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex: 1 1 auto;
}
.brand-mark-img {
  width: 28px; height: 28px; border-radius: 8px;
  object-fit: cover; flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), #c9921a);
}
.topbar-detail .brand-mark-img { width: 24px; height: 24px; border-radius: 7px; }
.brand-mark-sm {
  width: 28px; height: 28px; border-radius: 8px; font-size: 13px;
}
.brand-mark-img + .brand-mark-sm { display: none; }
.brand-mark-img[hidden] + .brand-mark-sm { display: grid; }
.icon-btn-sm {
  width: 34px; height: 34px; border-radius: 10px; font-size: 16px;
}
.week-select-wrap select {
  max-width: 132px;
  padding: 6px 26px 6px 8px;
  font-size: 12px;
  font-weight: 700;
}
.text-btn-quiet {
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  padding: 6px 8px;
  border-radius: 8px;
}
.back-btn-compact {
  width: 34px; height: 34px; border-radius: 10px;
  background: var(--bg2); color: var(--text);
  border: 1px solid var(--card-border);
  font-size: 22px; line-height: 1; font-weight: 700;
  display: grid; place-items: center; flex-shrink: 0;
}
.detail-top-label {
  font-weight: 800; font-size: 15px; letter-spacing: 0.01em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
body.view-detail-open .topbar {
  padding-top: calc(4px + var(--safe-top));
  padding-bottom: 4px;
  min-height: calc(40px + var(--safe-top));
}
body.view-detail-open .topbar-main { display: none !important; }
body.view-detail-open #btn-logout { display: none; }
.detail-back-legacy { display: none !important; }

/* GENEL compact */
.genel-stack { display: flex; flex-direction: column; gap: 10px; }
.genel-block {
  background: var(--bg2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 10px 12px;
}
.genel-block-title {
  font-size: 11px; font-weight: 800; letter-spacing: 0.05em;
  color: var(--accent); text-transform: uppercase; margin-bottom: 6px;
}
.genel-venue-main { font-weight: 700; font-size: 14px; }
.genel-venue-meta { font-size: 12px; margin-top: 2px; }
.venue-photo-compact { margin-top: 8px; max-height: 120px; }
.venue-photo-compact .venue-photo { max-height: 120px; object-fit: cover; width: 100%; border-radius: 10px; }
.genel-rank-row, .genel-eksik-row, .genel-form-row {
  display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; font-size: 13px;
}
.genel-snap-grid { display: flex; flex-direction: column; gap: 8px; }
.genel-snap-team { display: flex; gap: 8px; align-items: flex-start; font-size: 12px; }
.genel-snap-name { font-weight: 700; }
.genel-snap-meta { color: var(--muted); margin-top: 2px; }
.genel-scorer-list { display: flex; flex-direction: column; gap: 4px; font-size: 13px; }
.genel-scorer { font-weight: 600; }
.genel-stat-row {
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px;
  font-size: 12px; padding: 3px 0; align-items: center;
}
.genel-stat-row span:last-child { text-align: right; }
.form-dots { display: inline-flex; gap: 3px; vertical-align: middle; margin-left: 6px; }
.form-dot {
  width: 8px; height: 8px; border-radius: 50%; display: inline-block;
  background: rgba(255,255,255,0.2);
}
.form-dot-w { background: var(--ok); }
.form-dot-d { background: var(--muted); }
.form-dot-l { background: var(--danger); }

/* ANALİZ compact matrix */
.analiz-stack-compact { gap: 10px; }
.analiz-stack-compact .analiz-section { padding: 10px; }
.piyasa-matrix { display: flex; flex-direction: column; gap: 4px; }
.piyasa-head, .piyasa-row {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) repeat(3, minmax(40px, 0.55fr));
  gap: 4px; align-items: center; font-size: 12px;
}
.piyasa-head { color: var(--muted); font-weight: 700; font-size: 11px; padding-bottom: 4px; border-bottom: 1px solid rgba(255,255,255,0.06); }
.piyasa-head span:not(:first-child), .piyasa-cell { text-align: center; font-variant-numeric: tabular-nums; }
.piyasa-lab { font-weight: 700; overflow-wrap: anywhere; }
.piyasa-cells { font-size: 11px; }
.oynanma-fill { background: linear-gradient(90deg, #7aa2ff, #5b7fd9) !important; }

/* Timeline unknown centered on axis */
.timeline-row.timeline-unknown {
  display: grid;
  grid-template-columns: 1fr 44px 1fr;
  gap: 6px;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}
.timeline-center-stack {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  text-align: center; font-size: 11px; min-width: 0;
}
.timeline-center-stack .timeline-body {
  max-width: 42vw; overflow-wrap: anywhere; color: var(--muted);
}

/* Finger-follow swipe panel */
.detail-panel-viewport {
  overflow: hidden;
  touch-action: pan-y;
}
.detail-tab-panel {
  will-change: auto;
  backface-visibility: hidden;
}
@media (prefers-reduced-motion: reduce) {
  .detail-tab-panel.tab-panel-enter,
  .detail-tab-panel.tab-panel-enter-forward,
  .detail-tab-panel.tab-panel-enter-back {
    animation: none !important;
  }
}

@media (max-width: 390px) {
  .week-select-wrap select { max-width: 118px; font-size: 11px; }
  .piyasa-head, .piyasa-row {
    grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(34px, 0.5fr));
    font-size: 11px;
  }
  .analiz-pick-main strong { font-size: 24px; }
}


/* --- Physical premium restoration (v13) --- */
.startup-splash { background: #0c1016; }
.startup-mark-img {
  width: 76px; height: 76px; border-radius: 20px; object-fit: cover;
  box-shadow: 0 12px 32px rgba(0,0,0,.38);
  background: linear-gradient(135deg, var(--accent), #a8842a);
}
.startup-title { font-weight: 800; font-size: 22px; letter-spacing: .02em; }
.panel, .match-card, .week-dashboard-card, .analiz-section, .genel-block {
  background: var(--card);
  border-color: var(--card-border);
  box-shadow: 0 6px 18px rgba(0,0,0,0.14);
}
.genel-block, .form-stat-card, .inj-team-card, .coupon-card {
  background: var(--card-2);
}
.overflow-wrap { position: relative; }
.overflow-menu {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 40;
  min-width: 140px; padding: 6px;
  background: var(--card-2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  box-shadow: 0 12px 28px rgba(0,0,0,.35);
}
.overflow-item {
  display: block; width: 100%; text-align: left;
  background: transparent; color: var(--text);
  border: 0; border-radius: 8px;
  padding: 10px 12px; font: inherit; font-weight: 600; cursor: pointer;
}
.overflow-item:active { background: var(--accent-soft); }
.live-hub-header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; margin: 0 2px 8px;
}
.live-hub-title { margin: 0; font-size: 16px; font-weight: 800; }
.live-bell-info:empty { display: none; }
.analiz-outcome-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
}
.analiz-outcome-card {
  background: var(--card-2);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 10px;
}
.analiz-outcome-card h5 {
  margin: 0 0 8px; font-size: 12px; color: var(--muted); font-weight: 700;
}
.analiz-outcome-triple {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; text-align: center;
}
.analiz-outcome-triple span { display: block; font-size: 11px; color: var(--muted); }
.analiz-outcome-triple b { display: block; font-size: 15px; margin-top: 2px; }
.analiz-official-note {
  margin-top: 6px; font-size: 11px; color: var(--muted);
}
.piyasa-row-muted .piyasa-lab { color: var(--muted); font-weight: 600; }
.genel-section-title {
  font-size: 13px; font-weight: 800; margin: 0 0 8px; letter-spacing: .01em;
}
.genel-mac-bilgi, .genel-mac-oncesi {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 12px;
}
.standing-legend-item { display: inline-flex; align-items: center; gap: 6px; margin-right: 10px; font-size: 11px; }
.smart-coupon-hint { margin: 4px 0 2px !important; min-height: 0; }
.coupons-root:empty { min-height: 0; }


/* Adaptive Coupon Engine V1 preview controls */
.adaptive-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-end;
  margin-top: 10px;
}
.adaptive-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12px;
  color: var(--muted, #8b93a7);
}
.adaptive-field input,
.adaptive-field select {
  min-width: 96px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.25);
  color: inherit;
}
.coupon-match.adaptive-match {
  grid-template-columns: 28px minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: start;
}
.coupon-match.adaptive-match .adaptive-why {
  grid-column: 1 / -1;
  margin: 4px 0 2px 28px;
  min-width: 0;
  width: auto;
  max-width: 100%;
}
.adaptive-why summary {
  cursor: pointer;
  font-size: 12px;
  color: var(--accent, #6ea8fe);
}
.adaptive-why .why-body {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: pre-wrap;
}
.pick-chip.protection {
  border-color: rgba(110, 168, 254, 0.45);
  color: #9ec1ff;
}
.home-adaptive-note {
  font-size: 11px;
  color: var(--muted);
  margin: 6px 0 0;
}
@media (max-width: 390px) {
  .adaptive-row { gap: 6px; }
  .adaptive-field input, .adaptive-field select { min-width: 84px; }
  .coupon-match.adaptive-match .adaptive-why { margin-left: 0; }
}


/* Manual coupon builder */
.manual-toolbar{margin-top:14px}
.saved-coupon-kicker{margin:18px 2px 8px}
.manual-coupon-card{padding:12px}
.manual-fields{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin:10px 0}
.manual-fields label{display:flex;flex-direction:column;gap:4px;font-size:12px;font-weight:700;color:var(--muted)}
.manual-fields input{appearance:none;border:1px solid var(--line);border-radius:10px;padding:10px;background:var(--bg);color:var(--text);font-weight:700}
.manual-coupon-rows{display:grid;gap:7px}
.manual-teams{font-size:13px;font-weight:700;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.manual-no{font-weight:800;font-variant-numeric:tabular-nums}
.manual-picks{display:flex;gap:5px}
.manual-pick{width:34px;height:34px;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--text);font-weight:800;font-size:14px}
.manual-pick.is-selected{background:var(--accent);border-color:var(--accent);color:#fff}
.manual-pick:disabled{opacity:.4}
.manual-savebar{position:sticky;bottom:calc(var(--tabbar-h, 64px) + env(safe-area-inset-bottom));z-index:3;display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:12px;padding:10px;border:1px solid var(--line);border-radius:14px;background:var(--surface)}
.manual-savebar [data-manual-summary]{font-size:13px;font-weight:800}
.manual-savebar button:disabled{opacity:.45}

/* Product pick home card (final_picks only) */
.product-pick{display:flex;flex-direction:column;gap:4px;width:100%;text-align:left}
.product-pick-row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.product-pick-meta{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;font-size:12px}
.covered-picks{color:var(--muted);font-size:12px}
.covered-picks strong{color:var(--text);font-weight:800}
.conf-pct{font-variant-numeric:tabular-nums;font-weight:800}
.conf-reason{font-size:11px;color:var(--muted);line-height:1.35}
.prematch-pred-label{font-size:11px;font-weight:700;color:var(--warn);letter-spacing:.01em}
.width-badge{display:inline-flex;align-items:center;padding:2px 8px;border-radius:999px;font-size:11px;font-weight:800;border:1px solid var(--line);background:rgba(255,255,255,.04)}
.width-badge.width-1{border-color:rgba(61,220,151,.35);color:var(--ok)}
.width-badge.width-2{border-color:rgba(255,196,77,.4);color:var(--warn)}
.width-badge.width-3{border-color:rgba(255,107,107,.4);color:var(--danger)}
.analiz-pick-main{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.analiz-covered{margin-top:8px;font-size:13px;color:var(--muted)}
.analiz-covered strong{color:var(--text)}

/* Manual coupon UX */
.manual-coupon-row{display:grid;grid-template-columns:28px minmax(0,1fr) auto auto;gap:8px;align-items:center;padding:8px 0;border-bottom:1px solid var(--line)}
.manual-coupon-row .manual-picks{grid-column:1 / -1;justify-content:flex-start}
.manual-coupon-row.is-incomplete{opacity:.92}
.manual-coupon-row.is-blocked,.manual-coupon-row.is-closed{opacity:.55}
.manual-coupon-row.is-blocked .manual-pick,.manual-coupon-row.is-closed .manual-pick{pointer-events:none}
.manual-incomplete{font-size:11px;font-weight:800;color:var(--danger)}
.manual-block-badge{grid-column:1 / -1;font-size:11px;font-weight:700;color:var(--warn)}
.manual-width{font-size:11px;font-weight:800;min-width:44px;text-align:center}
.manual-closed-banner{display:flex;flex-direction:column;gap:4px;padding:10px 12px;margin:8px 0 12px;border-radius:12px;border:1px solid rgba(255,107,107,.35);background:rgba(255,107,107,.08);font-size:13px}
.manual-closed-banner strong{color:var(--danger)}
.manual-preview-card{margin-top:12px;padding:12px;border:1px solid var(--line);border-radius:14px;background:var(--surface)}
.manual-preview-meta{display:flex;flex-wrap:wrap;gap:10px;font-size:12px;font-weight:700;margin:8px 0}
.manual-preview-rows{display:grid;gap:4px;max-height:220px;overflow:auto}
.manual-preview-row{display:grid;grid-template-columns:28px 1fr auto;gap:8px;font-size:12px;padding:4px 0;border-bottom:1px solid var(--line)}
.manual-preview-actions{display:flex;justify-content:flex-end;gap:8px;margin-top:12px}
.primary-btn{appearance:none;border:0;border-radius:12px;padding:10px 14px;font-weight:800;background:var(--accent);color:#111}
@media(max-width:390px){
  .manual-coupon-row{grid-template-columns:26px minmax(0,1fr) auto}
  .product-pick-meta{flex-direction:column;align-items:flex-start}
}
