:root {
  --font-ui: 'Inter Variable', 'Segoe UI', sans-serif;
  --font-heading: 'Manrope Variable', 'Segoe UI', sans-serif;
  --brand: #10739D;
  --brand-dark: #0b5575;
  --brand-soft: #A0CADC;
  --brand-soft-bg: rgba(160, 202, 220, 0.15);
  --bg: #F3F8FB;
  --surface: #FFFFFF;
  --surface-alt: #F8FBFD;
  --surface-row-alt: #FAFCFE;
  --text: #153447;
  --text-soft: #637D8C;
  --border: #DCEAF1;
  --border-strong: #BFD9E6;
  --positive: #16A34A;
  --positive-bg: rgba(22, 163, 74, 0.08);
  --negative: #DC2626;
  --negative-bg: rgba(220, 38, 38, 0.08);
  --shadow-sm: 0 1px 2px rgba(21, 52, 71, 0.04);
  --shadow-md: 0 4px 12px rgba(21, 52, 71, 0.06);
  --shadow-lg: 0 12px 32px rgba(21, 52, 71, 0.10);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
}
body.dark {
  --brand: #A0CADC;
  --brand-dark: #7FB8D4;
  --brand-soft: #1A4A63;
  --brand-soft-bg: rgba(160, 202, 220, 0.12);
  --bg: #091923;
  --surface: #102735;
  --surface-alt: #0D2130;
  --surface-row-alt: #0E2332;
  --text: #EAF4F8;
  --text-soft: #8FA8B5;
  --border: #244352;
  --border-strong: #355A6E;
  --positive: #34D399;
  --positive-bg: rgba(52, 211, 153, 0.12);
  --negative: #F87171;
  --negative-bg: rgba(248, 113, 113, 0.12);
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.25);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.35);
  --shadow-lg: 0 12px 32px rgba(0,0,0,0.45);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  transition: background 0.2s, color 0.2s;
}
h1, h2, h3, .logo-title, .preview-name { font-family: var(--font-heading); }
body.tabular { font-variant-numeric: tabular-nums; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
a:is([href], [onclick]), [onclick^="navigate("] { cursor: pointer; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, select, textarea { font-family: inherit; font-size: 14px; }
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }

header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--brand);
  color: #fff;
  box-shadow: 0 2px 8px rgba(16, 115, 157, 0.2);
}
body.dark header { background: #0b1e2b; box-shadow: 0 2px 8px rgba(0,0,0,0.4); }
.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 32px;
  height: 64px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  user-select: none;
}
.logo-img { width: 40px; height: 40px; display: block; object-fit: contain; flex: 0 0 auto; border-radius: 50%; }
footer .logo-img { width: 36px; height: 36px; }
.logo-text { display: flex; flex-direction: column; line-height: 1.15; }
.logo-title { font-weight: 700; font-size: 16px; color: #fff; letter-spacing: -0.01em; }
.logo-sub { font-size: 11px; color: rgba(255,255,255,0.75); font-weight: 500; }
.header-home { justify-self: start; border-radius: var(--radius-sm); }
.header-home:hover { text-decoration: none; }
.header-home:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.header-wordmark {
  font-family: var(--font-ui);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.15;
  white-space: nowrap;
  color: #fff;
}

nav.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2px;
}
.nav-link {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  transition: all 0.15s;
  cursor: pointer;
  white-space: nowrap;
}
.nav-link-counted { position: relative; }
.nav-count {
  display: inline-grid;
  place-items: center;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #d9edf7;
  color: #084c70;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
}
.main-nav .nav-count { position: absolute; top: 2px; right: 1px; }
#mobileMenu .nav-count { margin-inline-start: 5px; vertical-align: 1px; }
.nav-link:hover { color: #fff; background: rgba(255,255,255,0.12); text-decoration: none; }
.nav-link.active { color: #fff; background: rgba(255,255,255,0.2); font-weight: 600; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.header-auth { display: flex; align-items: center; gap: 6px; margin-inline-start: 8px; }
.header-social { display: flex; gap: 2px; }
.header-social .icon-btn { width: 32px; color: #fff; }
.social-link { display: inline-flex; align-items: center; gap: 8px; }
.social-link svg { width: 16px; height: 16px; }
.mobile-social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; padding: 8px 14px 0; }
.mobile-social .social-link { color: #fff; padding: 8px; }
@media (min-width: 1241px) {
  #mobileMenu { display: none !important; }
}
.icon-btn {
  width: 36px; height: 36px;
  border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,0.85);
  transition: all 0.15s;
}
.icon-btn:hover { background: rgba(255,255,255,0.15); color: #fff; }
.icon-btn svg { width: 18px; height: 18px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  transition: all 0.15s;
  white-space: nowrap;
  height: 36px;
}
.btn svg { width: 16px; height: 16px; }
.btn-ghost { 
  color: var(--brand); 
  background: rgba(16, 115, 157, 0.06); 
  border: 1px solid var(--brand-soft);
}
body.dark .btn-ghost {
  color: var(--brand);
  background: rgba(160, 202, 220, 0.08);
  border: 1px solid var(--brand-soft);
}
.btn-ghost:hover { 
  background: rgba(16, 115, 157, 0.12); 
  border-color: var(--brand);
}
body.dark .btn-ghost:hover { 
  background: rgba(160, 202, 220, 0.15); 
  border-color: var(--brand);
}
.btn-login {
  color: #fff;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.3);
}
.btn-login:hover {
  background: rgba(255,255,255,0.2);
  border-color: rgba(255,255,255,0.5);
}
.btn-login svg {
  color: #fff;
  width: 16px;
  height: 16px;
}
.btn-primary { background: #fff; color: var(--brand); }
body.dark .btn-primary { background: var(--brand); color: #091923; }
.btn-primary:hover { background: #f0f0f0; }
body.dark .btn-primary:hover { background: #C0DDEA; }
.btn-brand { background: var(--brand); color: #fff; }
.btn-brand:hover { background: var(--brand-dark); }
body.dark .btn-brand, body.dark .btn-brand:hover { color: #091923; }
body.dark .btn-brand svg, body.dark .btn-primary svg { color: inherit; stroke: currentColor; }
.btn-link { 
  color: var(--brand); 
  padding: 8px 16px;
  font-weight: 600; 
  cursor: pointer;
  border: 1px solid var(--brand-soft);
  background: rgba(16, 115, 157, 0.06);
  border-radius: var(--radius-sm);
  height: 36px;
  display: inline-flex;
  align-items: center;
  font-size: 14px;
}
body.dark .btn-link {
  background: rgba(160, 202, 220, 0.08);
}
.btn-link:hover { 
  background: var(--brand-soft-bg); 
  text-decoration: none; 
  border-color: var(--brand);
}
.mobile-toggle { display: none; }

.demo-notice {
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 3px solid var(--brand);
  padding: 12px 18px;
  margin: 20px auto;
  max-width: 1280px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--text-soft);
  display: flex;
  align-items: center;
  gap: 10px;
}
.demo-notice svg { flex-shrink: 0; color: var(--brand); }
.demo-notice strong { color: var(--text); font-weight: 600; }

.hero { padding: 32px 0 24px; }
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
  width: 100%;
}
.hero h1 {
  font-family: var(--font-ui);
  font-size: 44px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  color: var(--text);
}
.hero-sub {
  font-size: 18px;
  font-weight: 600;
  color: var(--brand);
  margin: 0 0 12px;
  letter-spacing: -0.01em;
}
.hero-lead {
  font-size: 16px;
  color: var(--text-soft);
  margin: 0 0 24px;
  max-width: 520px;
  line-height: 1.55;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.preview-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-md);
  position: relative;
  cursor: pointer;
  transition: box-shadow 0.2s, transform 0.2s;
  text-decoration: none;
  color: inherit;
  display: block;
}
.preview-card:not([href]) { cursor: default; }
.preview-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
  text-decoration: none;
}
.preview-card:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}
.preview-label {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-soft);
  background: var(--surface-alt);
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--border);
  z-index: 2;
}
.preview-carousel {
  position: relative;
  min-height: 280px;
}
.preview-slide {
  position: relative;
}
.preview-slide-content {
  transition: opacity 0.35s ease, transform 0.35s ease;
}
.preview-slide-content.fade-out {
  opacity: 0;
  transform: translateY(8px);
}
.preview-slide-content.fade-in {
  opacity: 0;
  transform: translateY(-8px);
}
.preview-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
}
.preview-name { font-size: 18px; font-weight: 700; margin: 0 0 4px; }
.preview-period { font-size: 12px; color: var(--text-soft); }
.preview-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-bottom: 16px;
}
.preview-stat-label { font-size: 11px; color: var(--text-soft); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; margin-bottom: 4px; }
.preview-stat-value { font-size: 22px; font-weight: 700; font-variant-numeric: tabular-nums; }
.preview-chart { height: 140px; position: relative; }
.preview-chart-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  font-size: 13px;
}
.preview-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--brand);
  pointer-events: none;
}
.preview-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 16px;
}
.preview-arrow {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 18px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  z-index: 3;
  position: relative;
}
.preview-arrow:hover { background: var(--surface-alt); border-color: var(--brand); color: var(--brand); }
.preview-arrow:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.preview-dots {
  display: flex;
  gap: 6px;
}
.preview-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border-strong);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: all 0.2s;
  z-index: 3;
  position: relative;
}
.preview-dot.active { background: var(--brand); width: 20px; border-radius: 4px; }
.preview-dot:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
.preview-counter {
  font-size: 11px;
  color: var(--text-soft);
  font-weight: 600;
  margin-top: 8px;
  text-align: center;
}

section { padding: 28px 0; }
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
  flex-wrap: wrap;
}
.section-title {
  font-size: clamp(22px, 2.3vw, 28px);
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0;
}
.section-sub { font-size: 14px; color: var(--text-soft); margin-top: 4px; }

.tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  width: fit-content;
  margin-bottom: 16px;
  overflow-x: auto;
}
.tabs-separate {
  display: flex;
  flex: none;
  gap: 4px;
  border-inline-start: 1px solid var(--border);
  padding-inline-start: 4px;
}
.tab {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
  transition: all 0.15s;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  border: none;
  background: none;
}
.tab:hover { color: var(--text); }
.tab.active { background: var(--brand); color: #fff; }
body.dark .tab.active { color: #091923; }
.tab .count {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: 999px;
  background: rgba(0,0,0,0.08);
  font-weight: 700;
}
body.dark .tab .count { background: rgba(0,0,0,0.25); }
.tab.active .count { background: rgba(255,255,255,0.25); }

.category-notice {
  font-size: 13px;
  color: var(--text-soft);
  margin-bottom: 12px;
  padding: 8px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 8px;
}
.category-notice svg { flex-shrink: 0; color: var(--brand); }

.toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.search-box {
  position: relative;
  flex: 1;
  min-width: 220px;
  max-width: 420px;
}
.search-box svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px; height: 16px;
  color: var(--text-soft);
}
.search-box input {
  width: 100%;
  padding: 9px 12px 9px 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  transition: all 0.15s;
}
.search-box input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(16, 115, 157, 0.15); }
.period-select {
  padding: 9px 32px 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23637D8C' stroke-width='2'><polyline points='6 9 12 15 18 9'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer;
}
.period-select:focus { outline: none; border-color: var(--brand); }
.results-count {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}
.results-count strong { color: var(--text); font-weight: 700; }

.table-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 16px;
  margin-bottom: 12px;
  font-size: 14px;
}
.table-date {
  font-size: 14px;
  color: var(--text);
  font-weight: 500;
}
.demo-hint {
  font-size: 12px;
  color: var(--text-soft);
  font-weight: 400;
}
.table-units {
  font-size: 13px;
  color: var(--text-soft);
}

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
  min-height: 24px;
  align-items: center;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: var(--brand-soft-bg);
  color: var(--brand);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  border: 1px solid transparent;
}
.chip:hover { border-color: var(--brand); }
.chip svg { width: 12px; height: 12px; }
.chip-clear {
  font-size: 12px;
  color: var(--text-soft);
  padding: 4px 8px;
  font-weight: 500;
  cursor: pointer;
}
.chip-clear:hover { color: var(--text); }

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  width: 100%;
}
.table-scroll { overflow-x: auto; }
table.stats {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  table-layout: fixed;
}
table.stats colgroup col.col-place { width: 5%; }
table.stats colgroup col.col-name { width: 24%; }
table.stats colgroup col.col-months { width: 9%; }
table.stats colgroup col.col-bets { width: 11%; }
table.stats colgroup col.col-profit { width: 13%; }
table.stats colgroup col.col-yield { width: 11%; }
table.stats colgroup col.col-maxdd { width: 13%; }
table.stats colgroup col.col-curdd { width: 14%; }
table.stats thead th {
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: 0.01em;
  line-height: 1.3;
  vertical-align: middle;
}
table.stats thead th.num { text-align: center; }
table.stats thead th.center { text-align: center; }
table.stats thead th.sort-active { color: var(--brand); }
table.stats thead th.sortable { cursor: pointer; user-select: none; transition: color 0.15s, background 0.15s; position: relative; }
table.stats thead th.sortable:hover { background: var(--surface-row-alt); color: var(--brand); }
table.stats thead th .sort-icon {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  text-align: center;
  opacity: 0.35;
  font-size: 11px;
  line-height: 1;
}
table.stats thead th.sort-active .sort-icon { opacity: 1; }
.th-label {
  display: block;
  text-align: center;
}
table.stats tbody tr {
  height: 52px;
  border-bottom: 1px solid var(--border);
  transition: background 0.1s;
  cursor: pointer;
}
table.stats tbody tr:nth-child(even) { background: var(--surface-row-alt); }
table.stats tbody tr:last-child { border-bottom: none; }
table.stats tbody tr:hover,
table.stats tbody tr:focus-within { background: var(--brand-soft-bg); }
table.stats tbody tr:hover td:first-child,
table.stats tbody tr:focus-within td:first-child { box-shadow: inset 3px 0 var(--brand); }
table.stats tbody tr:hover .name-cell-link { text-decoration: underline; }
table.stats td {
  padding: 11px 12px;
  vertical-align: middle;
  color: var(--text);
  font-size: 14px;
}
table.stats td.num {
  text-align: center;
  font-weight: 500;
  white-space: nowrap;
}
table.stats td.center { text-align: center; }
.name-cell-link {
  font-weight: 600;
  font-size: 14px;
  color: var(--text);
  text-decoration: none;
  display: block;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
  max-height: 2.7em;
  word-wrap: break-word;
}
.name-cell-link:hover { color: var(--brand); }
table.stats td.place-cell {
  text-align: center;
  color: var(--text-soft);
  font-weight: 600;
  font-size: 13px;
}
table.stats td.divider-left {
  border-left: 1px solid var(--border);
}
.val-pos { color: var(--positive); font-weight: 600; }
.val-neg { color: var(--negative); font-weight: 600; }
.val-zero { color: var(--text-soft); font-weight: 500; }
table.stats td.val-pos, .m-stat-value.val-pos, .kpi-value.val-pos, .comparison-item-value.val-pos, .preview-stat-value.val-pos {
  color: var(--positive);
  font-weight: 600;
}
table.stats td.val-neg, .m-stat-value.val-neg, .kpi-value.val-neg, .comparison-item-value.val-neg, .preview-stat-value.val-neg {
  color: var(--negative);
  font-weight: 600;
}
table.stats td.val-zero, .m-stat-value.val-zero, .kpi-value.val-zero, .comparison-item-value.val-zero, .preview-stat-value.val-zero {
  color: var(--text-soft);
  font-weight: 500;
}

.filters-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 16px;
  display: none;
}
.filters-panel.open { display: block; }
.filters-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 14px;
}
.field label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-soft);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.field input, .field select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(16, 115, 157, 0.12); }

.mobile-cards { display: none; }
.m-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 10px;
  cursor: pointer;
  transition: all 0.15s;
}
.m-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); }
.m-card-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 12px;
  gap: 10px;
}
.m-card-name { font-weight: 700; font-size: 17px; }
.m-card-name a { color: var(--text); text-decoration: none; }
.m-card-name a:hover { color: var(--brand); text-decoration: underline; }
.m-card-sub { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 6px; font-size: 12px; color: var(--text-soft); margin-top: 2px; }
.m-card-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.m-card-stats-primary { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.m-card-stats-primary .m-stat-value { font-size: clamp(12px, 3.8vw, 17px); overflow-wrap: anywhere; }
.m-card-stats-secondary { margin-top: 10px; }
.m-card-context { margin-top: 8px; font-size: 12px; color: var(--text-soft); }
.rating-freshness { margin: 6px 0 12px; }
table.stats td.rating-key { font-weight: 700; }
.m-stat-label { font-size: 10px; color: var(--text-soft); margin-bottom: 2px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.03em; }
.m-stat-value { font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-soft);
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 20px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  transition: all 0.15s;
  cursor: pointer;
}
.back-link:hover { color: var(--text); background: var(--surface); text-decoration: none; }
.back-link svg { width: 16px; height: 16px; }
.capper-hero {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}
.capper-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.capper-title {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 800;
  line-height: 1.15;
  overflow-wrap: anywhere;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
}
.capper-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  max-width: 100%;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.25;
  text-align: center;
  overflow-wrap: anywhere;
  font-weight: 700;
  background: var(--surface-alt);
  color: var(--text-soft);
  border: 1px solid var(--border);
  letter-spacing: 0.02em;
}
.capper-meta .badge-cat, .capper-meta .badge-type { min-width: 66px; }
.badge-compact { min-height: 22px; padding: 2px 8px; font-size: 11px; }
.badge-cat { background: var(--brand); color: #fff; border-color: transparent; }
body.dark .badge-cat { color: #091923; }
.capper-desc {
  font-size: 15px;
  color: var(--text-soft);
  margin: 0 0 20px;
  max-width: 720px;
  line-height: 1.55;
}
.capper-awards { margin: 0 0 20px; }
.capper-awards-heading { margin: 0 0 8px; font-size: 13px; font-weight: 700; }
.capper-awards-heading span { margin-inline-start: 6px; color: var(--text-soft); font-size: 12px; font-weight: 400; }
.capper-awards-list {
  width: fit-content;
  max-width: 100%;
  background: var(--surface-alt);
  display: flex;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  scrollbar-width: thin;
}
.capper-award {
  flex: 0 0 96px;
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 7px 4px 8px;
  border-inline-end: 1px solid var(--border);
  cursor: help;
}
.capper-award:last-child { border-inline-end: 0; }
.capper-award:hover, .capper-award:focus-visible { background: var(--brand-soft-bg); }
.capper-award:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
.capper-award-icon { display: block; width: 56px; height: 56px; }
.capper-award time, .capper-award-label { color: var(--text-soft); font-size: 12px; white-space: nowrap; }
.capper-info {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-soft);
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.capper-info strong { color: var(--text); font-weight: 600; }
.capper-dates {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin: 8px 0 10px;
  font-size: 13px;
  color: var(--text-soft);
}
.capper-dates strong { color: var(--text); }
.capper-hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.review-profile-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.review-profile-links .btn { white-space: normal; text-align: left; }

.kpi-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px;
}
.kpi-label {
  font-size: 11px;
  color: var(--text-soft);
  font-weight: 700;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.kpi-value {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
  line-height: 1.1;
}
.kpi-sub { font-size: 12px; color: var(--text-soft); margin-top: 6px; }

.chart-main {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}
.chart-main-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 12px;
}
.chart-main-title { font-size: 20px; font-weight: 700; margin: 0; letter-spacing: -0.01em; }
.chart-main-range { font-size: 13px; color: var(--text-soft); margin-top: 4px; }
.chart-main-result {
  font-size: 28px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin-top: 12px;
  letter-spacing: -0.01em;
}
.chart-main-result-label {
  font-size: 12px;
  color: var(--text-soft);
  font-weight: 500;
  margin-top: 4px;
}
.period-btns {
  display: flex;
  gap: 4px;
  padding: 3px;
  background: var(--surface-alt);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.period-btn {
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-soft);
  transition: all 0.15s;
  cursor: pointer;
  border: none;
  background: none;
}
.period-btn:hover { color: var(--text); }
.period-btn.active { background: var(--surface); color: var(--brand); box-shadow: var(--shadow-sm); font-weight: 700; }
body.dark .period-btn.active { background: var(--brand-soft); color: #091923; }
.chart-wrap { height: 320px; position: relative; }

.monthly-table {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 24px;
}
.monthly-table-header {
  font-size: 13px;
  color: var(--text-soft);
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-alt);
}
.monthly-table table { width: 100%; border-collapse: collapse; font-size: 14px; font-variant-numeric: tabular-nums; }
.monthly-table th {
  background: var(--surface-alt);
  padding: 10px 14px;
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-soft);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--border);
}
.monthly-table td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  text-align: center;
  vertical-align: middle;
}
.monthly-table td.num { font-variant-numeric: tabular-nums; font-weight: 500; }
.monthly-table tr:last-child td { border-bottom: none; }

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
}
.editorial-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  transition: all 0.15s;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.editorial-card:hover { border-color: var(--border-strong); box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.editorial-rubric {
  font-size: 11px;
  font-weight: 700;
  color: var(--brand);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 8px;
}
.editorial-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}
.editorial-excerpt {
  font-size: 14px;
  color: var(--text-soft);
  margin: 0 0 14px;
  flex: 1;
  line-height: 1.55;
}
.editorial-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--text-soft);
  padding-top: 12px;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 8px;
}
.editorial-meta .author { font-weight: 600; color: var(--text); }
.editorial-meta .rating { color: #fbbf24; font-size: 14px; letter-spacing: 2px; }
.tag-list { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  line-height: 1.25;
  padding: 3px 8px;
  background: var(--surface-alt);
  color: var(--text-soft);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid var(--border);
}

.contest-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  flex-direction: column;
}
.contest-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.contest-title { font-size: 18px; font-weight: 700; margin: 0; }
.status {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  line-height: 1.25;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.status-active { background: var(--positive-bg); color: var(--positive); }
.status-upcoming { background: var(--brand-soft-bg); color: var(--brand); }
.status-completed { background: var(--surface-alt); color: var(--text-soft); }
.contest-desc { font-size: 14px; color: var(--text-soft); margin: 0 0 14px; }
.contest-info {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 13px;
}
.contest-info-label { font-size: 11px; color: var(--text-soft); text-transform: uppercase; letter-spacing: 0.03em; margin-bottom: 2px; font-weight: 600; }
.contest-info-value { font-weight: 600; }

.contest-card-link { color: var(--text); }
.contest-card-link:hover { border-color: var(--brand); text-decoration: none; }
.contest-card-results .contest-title { font-size: clamp(20px, 2.5vw, 28px); }
.contest-results { display: grid; gap: 16px; margin-top: 22px; }
.contest-results h4 { margin: 0; font-size: 16px; }
.contest-funds, .contest-rounds { display: grid; gap: 12px; }
.contest-funds { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.contest-rounds { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.contest-funds > div, .contest-round {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-alt);
  min-width: 0;
}
.contest-funds strong { display: block; font-size: 22px; color: var(--brand); }
.contest-funds span { font-size: 14px; font-weight: 700; }
.contest-funds p, .contest-round-meta { margin: 5px 0 0; color: var(--text-soft); font-size: 13px; }
.contest-podium { display: grid; gap: 6px; padding: 0; margin: 14px 0; list-style: none; }
.contest-place {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
}
.contest-place-1 { border-color: #d2a23f; }
.contest-rank {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  color: #263849;
  background: #dce6ef;
}
.contest-place-1 .contest-rank { background: #f4d28b; color: #573605; }
.contest-place-3 .contest-rank { background: #efd4be; color: #603817; }
.contest-winners { display: grid; gap: 3px; overflow-wrap: anywhere; font-size: 14px; }
.contest-award { display: grid; text-align: right; white-space: nowrap; font-size: 13px; }
.contest-award span { color: var(--text-soft); }
.contest-breakdown { border-top: 1px solid var(--border); }
.contest-breakdown summary { padding: 10px 0; color: var(--brand); font-size: 13px; font-weight: 600; cursor: pointer; }
.contest-table-scroll { max-height: 360px; overflow: auto; }
.contest-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.contest-table th, .contest-table td { padding: 7px 8px; border-bottom: 1px solid var(--border); text-align: left; }
.contest-table th { position: sticky; top: 0; background: var(--surface-alt); }
.contest-table td:nth-child(2) { overflow-wrap: anywhere; }
.contest-rules ol { padding-inline-start: 24px; margin-bottom: 0; }
.contest-rules li + li { margin-top: 8px; }
.contest-rules ul { padding-inline-start: 20px; margin-top: 6px; }
.contest-live-standings { min-width: 0; }
.contest-live-standings h4 { margin-bottom: 10px; }
.contest-next-action {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin: 18px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface-alt);
}
.contest-deadline { display: grid; gap: 4px; font-size: 13px; }
.contest-deadline span { color: var(--text-soft); }
.contest-card-action { display: block; margin-top: 12px; color: var(--brand); font-weight: 700; }
.contest-tour-scroll {
  --contest-score-row-height: 35px;
  max-height: calc(31 * var(--contest-score-row-height));
}
.contest-tour-table { white-space: nowrap; }
.contest-tour-table tr { height: var(--contest-score-row-height); }
.contest-tour-table th, .contest-tour-table td { line-height: 20px; }
.contest-tour-table tbody th { position: static; background: transparent; }
.contest-tour-table thead th { z-index: 1; }
.contest-tour-table th:not(:nth-child(2)), .contest-tour-table td { text-align: center; }
.contest-tour-table tbody tr:where(:nth-child(even)) { background: var(--surface-alt); }
.contest-tour-table tbody .contest-tour-rank-1 { background: #fff1ce; }
.contest-tour-table tbody .contest-tour-rank-2 { background: #e8edf3; }
.contest-tour-table tbody .contest-tour-rank-3 { background: #f5e3d4; }
body.dark .contest-tour-table tbody .contest-tour-rank-1 { background: #493a22; }
body.dark .contest-tour-table tbody .contest-tour-rank-2 { background: #303d49; }
body.dark .contest-tour-table tbody .contest-tour-rank-3 { background: #48332a; }
@media (max-width: 760px) {
  .contest-rounds { grid-template-columns: 1fr; }
}
@media (max-width: 540px) {
  .contest-funds { grid-template-columns: 1fr; }
  .contest-round { padding: 10px; }
  .contest-place { gap: 6px; padding: 7px; }
  .contest-winners, .contest-award, .contest-table { font-size: 12px; }
}

.list-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-bottom: 12px;
}
.list-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; gap: 12px; }
.list-card-title { font-size: 18px; font-weight: 700; margin: 0; }
.list-card-body { font-size: 14px; color: var(--text-soft); margin-bottom: 12px; line-height: 1.55; }
.list-card-foot { font-size: 12px; color: var(--text-soft); display: flex; gap: 14px; flex-wrap: wrap; }

.blacklist-toolbar { justify-content: space-between; }
.btn.blacklist-report-trigger { background: #b91c1c; color: #fff; }
.btn.blacklist-report-trigger:hover { background: #991b1b; }
.blacklist-report {
  width: min(640px, calc(100% - 32px));
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
}
.blacklist-report::backdrop { background: rgba(10, 37, 64, .58); }
.blacklist-report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 22px;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--border);
}
.blacklist-report-header h2 { font-size: 19px; line-height: 1.3; }
.blacklist-report-close {
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  line-height: 1;
  font-size: 22px;
  cursor: pointer;
}
.blacklist-report-close:hover { color: var(--brand); border-color: var(--brand); }
@media (max-width: 560px) {
  .blacklist-report { width: 100%; max-width: none; height: 100dvh; max-height: none; border: 0; border-radius: 0; }
}
.blacklist-attachments { display: grid; gap: 8px; list-style: none; }
.blacklist-attachments:empty { display: none; }
.blacklist-attachments li { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.blacklist-attachments li span { flex: 1; overflow-wrap: anywhere; }
.blacklist-attachments img { width: 56px; height: 44px; object-fit: cover; border-radius: var(--radius-sm); }
.blacklist-attachments button {
  padding: 3px 7px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--brand);
  font: inherit;
  cursor: pointer;
}
.blacklist-table tbody tr:hover .blacklist-channel-name,
.blacklist-table tbody tr:focus-within .blacklist-channel-name { text-decoration: underline; }
.blacklist-report-hint { display: block; margin-top: 3px; }
.blacklist-report-body { padding: 18px 22px 22px; }
.blacklist-report-body p, .blacklist-report-form label span { color: var(--text-soft); font-size: 13px; font-weight: 400; }
.blacklist-report-form { display: grid; gap: 12px; margin-top: 14px; }
.blacklist-report-form label { display: block; font-size: 14px; font-weight: 600; }
.blacklist-report-form input, .blacklist-report-form textarea {
  display: block;
  width: 100%;
  margin-top: 5px;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-alt);
  color: var(--text);
  font: inherit;
  font-weight: 400;
}
.blacklist-report-form textarea { resize: vertical; }
.blacklist-report-form input[type="file"]::file-selector-button {
  margin-right: 8px;
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--brand);
  font: inherit;
  cursor: pointer;
}
#blacklist-report-files { margin-top: -7px; }
.blacklist-report-footer { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; }
.blacklist-report-footer button:disabled { opacity: .55; cursor: not-allowed; }

#blacklistList { overflow: hidden; border-radius: var(--radius-md); }
.blacklist-table { width: 100%; border-collapse: collapse; background: var(--surface); font-size: 14px; }
.blacklist-table th, .blacklist-table td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; overflow-wrap: anywhere; }
.blacklist-table thead { background: var(--negative-bg); }
.blacklist-table tbody tr { position: relative; }
.blacklist-table tbody tr:hover, .blacklist-table tbody tr:focus-within {
  background: var(--negative-bg);
}
.blacklist-table tbody tr:hover > th:first-child,
.blacklist-table tbody tr:focus-within > th:first-child { box-shadow: inset 3px 0 var(--negative); }
.blacklist-table tbody tr:hover th, .blacklist-table tbody tr:focus-within th {
  color: var(--negative);
}
.blacklist-table-date { white-space: nowrap; color: var(--text-soft); }
.blacklist-table .blacklist-table-action { width: 1%; padding-inline: 12px; }
.blacklist-table-action a {
  display: inline-grid;
  width: 22px;
  height: 22px;
  place-items: center;
  color: var(--negative);
}
.blacklist-chevron {
  width: 7px;
  height: 7px;
  border-top: 1.5px solid currentColor;
  border-right: 1.5px solid currentColor;
  transform: rotate(45deg);
}
.blacklist-table-action a::after { content: ""; position: absolute; inset: 0; cursor: pointer; }
.blacklist-table-action a:focus-visible::after { outline: 2px solid var(--negative); outline-offset: -2px; }
@media (max-width: 560px) {
  .blacklist-table { font-size: 13px; }
  .blacklist-table th, .blacklist-table td { padding: 8px 6px; }
  .blacklist-table .blacklist-table-action { padding-inline: 4px; }
}
#blacklistDetail { margin-top: 16px; }

.blacklist-title { font-size: 28px; margin-bottom: 14px; }
.blacklist-intro { max-width: 760px; margin-bottom: 24px; }
.blacklist-intro .section-sub { margin: 0 0 10px; }
.blacklist-intro a { font-size: 14px; text-decoration: underline; }
.telegram-id-guide { max-width: 760px; margin-top: 16px; }

.blacklist-card {
  background: var(--negative-bg);
  border: 1px solid rgba(220, 38, 38, 0.2);
  border-radius: var(--radius-md);
  padding: 22px;
  margin-bottom: 12px;
}
body.dark .blacklist-card { background: rgba(248, 113, 113, 0.08); border-color: rgba(248, 113, 113, 0.25); }
.blacklist-card .list-card-title { color: var(--negative); }
.blacklist-identity {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 10px;
  min-width: 0;
  overflow-wrap: anywhere;
}
.blacklist-identity span { font-size: 12px; color: var(--text-soft); }
.blacklist-status { background: rgba(220,38,38,0.15); color: var(--negative); }

.method-block {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  margin-bottom: 16px;
}
.method-block h2 { font-size: 20px; font-weight: 700; margin: 0 0 16px; letter-spacing: -0.01em; }
.method-block h3 { font-size: 15px; font-weight: 700; margin: 18px 0 8px; }
.method-block h3:first-child { margin-top: 0; }
.method-block p, .method-block li { color: var(--text-soft); font-size: 14px; line-height: 1.6; }
.method-block ul { padding-left: 20px; margin: 0; }
.method-block li { margin-bottom: 6px; }
.method-block code {
  background: var(--surface-alt);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 13px;
  font-family: 'SF Mono', Menlo, monospace;
  color: var(--text);
}
.method-details { display: none; margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); }
.method-details.open { display: block; }

.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(9, 25, 35, 0.6);
  backdrop-filter: blur(4px);
  z-index: 200;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 28px;
  max-width: 440px;
  width: 100%;
  box-shadow: var(--shadow-lg);
}
.modal h2 { font-size: 22px; font-weight: 700; margin: 0 0 16px; letter-spacing: -0.01em; }
.modal .form-group { margin-bottom: 14px; }
.modal label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--text-soft); }
.modal input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
}
.modal input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(16, 115, 157, 0.15); }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }
.modal-notice {
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-left: 3px solid var(--brand);
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--text-soft);
  margin-bottom: 16px;
  line-height: 1.5;
}

footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 40px 0 24px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}
.footer-col h4 { font-size: 12px; font-weight: 700; margin: 0 0 14px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text); }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: var(--text-soft); font-size: 14px; cursor: pointer; }
.footer-col a:hover { color: var(--brand); text-decoration: none; }
.footer-about { font-size: 14px; color: var(--text-soft); margin: 0; max-width: 320px; line-height: 1.55; }
.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  text-align: center;
  font-size: 13px;
  color: var(--text-soft);
}

.empty {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-soft);
}
.empty svg { width: 48px; height: 48px; margin-bottom: 16px; opacity: 0.4; }
.empty h3 { font-size: 18px; font-weight: 600; color: var(--text); margin: 0 0 8px; }
.empty p { font-size: 14px; margin: 0 0 20px; }

.page { display: none; animation: fadeIn 0.2s ease; }
.page.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  .preview-slide-content { transition: none !important; }
  .page { animation: none !important; }
  .preview-card:hover { transform: none; }
}

@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; gap: 28px; }
  .kpi-row { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 1240px) {
  nav.main-nav, .header-social { display: none; }
  .mobile-toggle { display: inline-flex; }
  .header-inner { grid-template-columns: auto 1fr; gap: 12px; }
  .header-actions { justify-self: end; }
}
@media (max-width: 768px) {
  .header-auth { display: none; }
  .container { padding: 0 16px; }
  .btn span.btn-label { display: none; }
  .hero { padding: 20px 0 16px; }
  .hero h1 { font-size: 32px; }
  .hero-sub { font-size: 16px; }
  .hero-lead { font-size: 15px; }
  section { padding: 20px 0; }
  .kpi-row { grid-template-columns: repeat(2, 1fr); }
  .kpi-value { font-size: 22px; }
  .chart-wrap { height: 240px; }
  .table-wrap { display: none; }
  .mobile-cards { display: block; }
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .capper-head { flex-direction: column; }
  .preview-stats { grid-template-columns: repeat(3, 1fr); }
  .preview-stat-value { font-size: 18px; }
  .chart-main-result { font-size: 24px; }
  .editorial-meta { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 420px) {
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .tabs { width: 100%; overflow-x: auto; }
  .preview-stats { grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
}

button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* Стили для страницы обзора */
.review-page {
  max-width: 820px;
  margin: 0 auto;
  padding: 40px 24px;
}
.review-header {
  margin-bottom: 32px;
}
.review-rubric {
  font-size: 13px;
  font-weight: 700;
  color: var(--brand);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 12px;
}
.review-card { min-height: 212px; }
.review-card .editorial-meta { margin-top: auto; }
.review-card-title, .review-page-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
}
.review-page-title { gap: 16px; }
.review-card-title .editorial-title, .review-page-title .review-title {
  min-width: 0;
  margin: 0;
  overflow-wrap: anywhere;
}
.review-avatar {
  display: block;
  flex: none;
  border: 1px solid var(--border);
  border-radius: 50%;
  object-fit: cover;
}
@media (max-width: 480px) {
  .review-page-title .review-avatar { width: 56px; height: 56px; }
}

.review-title {
  font-size: 36px;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  line-height: 1.2;
}
.review-title a {
  color: var(--text);
  text-decoration: none;
  transition: color 0.15s;
}
.review-title a:hover {
  color: var(--brand);
  text-decoration: underline;
}
.review-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 14px;
  color: var(--text-soft);
  margin-bottom: 8px;
}
.review-meta .author {
  font-weight: 600;
  color: var(--text);
}
.review-meta .date {
  color: var(--text-soft);
}
.review-meta .rating {
  color: #fbbf24;
  font-size: 18px;
  letter-spacing: 2px;
}
.review-content {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text);
}
.review-content p {
  margin: 0 0 20px;
}
.review-content ul {
  margin: 0 0 20px;
  padding-left: 24px;
}
.review-content ul li {
  margin-bottom: 8px;
}
.review-content strong {
  font-weight: 700;
  color: var(--text);
}
.review-image {
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 24px 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  cursor: pointer;
  transition: transform 0.2s;
}
.review-image:hover {
  transform: scale(1.01);
}
.review-image-placeholder {
  width: 100%;
  height: 400px;
  background: var(--surface-alt);
  border: 2px dashed var(--border);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  font-size: 14px;
  margin: 24px 0;
  text-align: center;
  padding: 20px;
}

/* Модальное окно для изображения */
.image-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
  cursor: pointer;
}
.image-modal.open {
  display: flex;
}
.image-modal img {
  max-width: 100%;
  max-height: 90vh;
  object-fit: contain;
  border-radius: var(--radius-md);
}
.image-modal-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  border: none;
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
}
.image-modal-close:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Brand emblem on the home page only; no frames or background. */
.hero-brand {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 24px;
  min-width: 0;
}
.hero-emblem {
  display: block;
  width: 96px;
  height: 96px;
  flex: 0 0 96px;
  object-fit: contain;
}
.hero-brand-copy { min-width: 0; }
.hero-brand h1 { margin: 0 0 8px; }
.hero-brand .hero-sub { margin: 0; font-size: 16px; line-height: 1.4; }
@media (max-width: 768px) {
  .hero-brand { gap: 14px; margin-bottom: 20px; }
  .hero-emblem { width: 64px; height: 64px; flex-basis: 64px; }
  .hero-brand .hero-sub { font-size: 14px; }
}


.source-refresh { margin-left: 10px; height: 30px; padding: 4px 10px; font-size: 12px; }
#sourceStatus[data-status="error"] { color: var(--text); }

.monthly-scroll { overflow-x: auto; }
.monthly-scroll table { min-width: 720px; }
.monthly-scroll th, .monthly-scroll td { text-align: center; white-space: nowrap; }
.monthly-demo-label { display: inline-block; margin-left: 12px; padding: 3px 8px; border: 1px solid var(--border); border-radius: 6px; font-size: 11px; }
.monthly-note { border-top: 1px solid var(--border); font-size: 11px; line-height: 1.5; }

.distance-section { margin-top: 28px; }
.distance-section h3 { font-size: 18px; margin: 0 0 8px; }
.distance-caption { font-size: 12px; line-height: 1.6; color: var(--text-soft); margin: 8px 0 16px; }
.distance-grid { display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 12px; margin: 16px 0; }
.distance-value { font-size: 25px; font-weight: 700; margin: 8px 0; font-variant-numeric: tabular-nums; }
.distance-value small { font-size: 13px; font-weight: 500; }
.distance-pair { font-size: 18px; font-weight: 700; margin: 12px 0; font-variant-numeric: tabular-nums; }
.distance-charts { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 16px; }
.distance-charts .chart-wrap { height: 240px; }
@media(max-width:1000px){.distance-grid{grid-template-columns:repeat(3,minmax(0,1fr));}}
@media(max-width:700px){.distance-grid{grid-template-columns:repeat(2,minmax(0,1fr));}.distance-charts{grid-template-columns:1fr;}}

table.stats colgroup col.col-status { width: 5%; }
table.stats colgroup col.col-name { width: 19%; }
table.stats .verification-cell { text-align: center; padding-left: 4px; padding-right: 4px; }
.verification-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; vertical-align: middle; background: #94a3b8; }
.verification-dot.is-active { background: #12ae64; }
.verification-dot.is-inactive { background: #e55353; }
.verification-dot:focus-visible { outline: 2px solid var(--brand); outline-offset: 4px; }

.year-history { margin: 24px 0; }
.year-history-head { display: flex; gap: 16px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.year-history-head h2 { font-size: 18px; margin: 0; }
.year-cards { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin-top: 14px; }
.year-card { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 18px; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 12px; font: inherit; text-align: left; cursor: pointer; }
.year-card.selected, .year-card:hover { border-color: var(--brand); }
.year-card span { font-size: 13px; }
.year-card .year-profit { font-size: 24px; font-weight: 700; }
@media(max-width:650px){.year-cards{grid-template-columns:1fr;}.year-card{padding:14px;}}

.distance-charts > .chart-main { display:flex; flex-direction:column; margin-bottom:0; min-width:0; }
.distance-charts > .chart-main .chart-wrap { margin-top:auto; flex:none; }
.distance-charts > .chart-main .distance-caption { min-height:38px; }

.alltime-results { cursor: pointer; border: 1px solid transparent; border-radius: 12px; padding: 10px; margin: -10px -10px 14px; }
.alltime-results:hover { border-color: var(--brand); }
.alltime-hint { font-size: 11px; color: var(--text-soft); font-weight: 400; margin-left: 8px; }
.alltime-results .kpi-row { grid-template-columns: repeat(4,minmax(0,1fr)); margin-bottom:0; }
@media(min-width:1300px){.alltime-results .kpi-value{font-size:25px;}}
@media(max-width:700px){.alltime-results .kpi-row{grid-template-columns:repeat(2,minmax(0,1fr));}.alltime-hint{display:block;margin-left:0;margin-top:5px;}}

.alltime-results:focus-visible { outline: 2px solid var(--brand); outline-offset: 4px; }
.alltime-title { font-size: 22px; line-height: 1.2; margin: 0 0 14px; }
.alltime-results .kpi-label { min-height: 2.8em; display: flex; align-items: flex-start; }
.alltime-results .kpi { container-type: inline-size; }
.alltime-results .kpi-primary {
  background: linear-gradient(var(--brand-soft-bg), transparent), var(--surface);
  border-color: var(--border-strong);
}
.alltime-results .kpi-primary .kpi-value { font-size: clamp(16px, 17cqi, 30px); font-weight: 800; }
.alltime-results .kpi-value { white-space: nowrap; }
.alltime-results .kpi-unit { font-size: 0.65em; font-weight: 650; color: inherit; }
.distance-dual { display:grid; grid-template-columns:1fr 1fr; gap:8px; margin:12px 0; font-variant-numeric:tabular-nums; }
.distance-dual > div { min-width:0; }
.distance-dual span { display:block; font-size:11px; color:var(--text-soft); margin-bottom:7px; }
.distance-dual strong { display:block; font-size:18px; white-space:nowrap; }
.distance-dual small { font-size:11px; font-weight:500; }
.year-card { display:block; min-width:0; padding:20px; transition:background .15s,border-color .15s; }
.year-card.selected { background:var(--surface-alt); }
.year-card-top { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.year-card-top > strong { font-size:16px; }
.year-card .year-selection { font-size:11px; color:var(--text-soft); }
.year-card .year-profit { font-size:28px; margin:18px 0; font-weight:700; font-variant-numeric:tabular-nums; line-height:1.3; }
.year-profit small { font-size:14px; font-weight:500; }
.year-metrics { display:grid; grid-template-columns:1fr 1fr; gap:18px 16px; padding-top:16px; border-top:1px solid var(--border); }
.year-metrics span, .year-odds span { display:block; font-size:12px; line-height:1.5; color:var(--text-soft); margin-bottom:5px; }
.year-metrics strong, .year-odds strong { font-size:17px; font-weight:650; font-variant-numeric:tabular-nums; }
.year-odds { display:flex; align-items:center; justify-content:space-between; gap:8px; margin-top:18px; padding-top:14px; border-top:1px solid var(--border); }
.year-odds span { margin:0; }
@media(min-width:1001px) and (max-width:1200px){.distance-dual{grid-template-columns:1fr;gap:10px;}.distance-dual > div{display:flex;align-items:center;justify-content:space-between;gap:5px;}.distance-dual span{margin-bottom:0;}}

/* One consistent grid for the six annual metrics. */
.year-metrics { grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px 12px; text-align:left; }
.year-metrics > div { min-width:0; }
.year-metrics span { font-size:11px; min-height:32px; margin:0 0 6px; line-height:16px; }
.year-metrics strong { display:block; font-size:16px; line-height:24px; white-space:nowrap; }
.year-metrics small { font-size:11px; font-weight:500; }
.year-card .year-profit { min-height:37px; }
/* Align all five distance cards to the same label, value and note rows. */
.distance-grid { align-items:stretch; }
.distance-grid > .kpi { display:grid; grid-template-rows:32px minmax(48px,auto) minmax(32px,auto); align-content:start; min-width:0; padding:18px; }
.distance-grid .kpi-label { margin:0; line-height:16px; font-size:11px; align-self:start; }
.distance-grid .distance-value, .distance-grid .distance-pair { display:flex; align-items:center; font-size:clamp(17px,1.45vw,22px); line-height:1.3; font-weight:650; margin:0; min-width:0; white-space:nowrap; gap:4px; font-variant-numeric:tabular-nums; }
.distance-grid .distance-pair { display:block; align-self:center; white-space:normal; }
.distance-grid .distance-pair > span { white-space:nowrap; }
.distance-grid .distance-pair small { font-size:11px; font-weight:500; }
.distance-grid .kpi-sub { margin:0; font-size:11px; line-height:16px; align-self:start; }
.distance-grid .distance-average { display: flex; flex-wrap: wrap; gap: 2px 10px; padding-block: 4px; }
@media(max-width:700px){.distance-grid .distance-value,.distance-grid .distance-pair{font-size:18px;}.distance-grid > .kpi{padding:14px;}}
@media(max-width:420px){.distance-grid{grid-template-columns:1fr;}.distance-grid .distance-value,.distance-grid .distance-pair{font-size:22px;}.year-metrics{gap:18px 8px;}.year-metrics strong{font-size:15px;}}

.bank-results { margin: 24px 0; }
.bank-results h2 { font-size: 18px; margin: 0 0 12px; }
.bank-results .kpi-row { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 560px) {
  .bank-results .kpi-row { grid-template-columns: 1fr; }
}

.bank-results .kpi-value small { font-size: 14px; font-weight: 500; }

.year-bank { display:flex; align-items:baseline; gap:10px; margin:-8px 0 14px; }
.year-bank span { color:var(--text-soft); font-size:12px; }
.year-bank strong { flex-shrink:0; white-space:nowrap; font-size:16px; font-variant-numeric:tabular-nums; }

.alltime-results .alltime-primary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.alltime-results .alltime-secondary { margin-top: 10px; }

.home-rating-caption { padding: 10px 14px; text-align: left; font-size: 14px; font-weight: 700; color: var(--text); background: var(--surface); }

.bookmaker-card, .bookmaker-identity, .bookmaker-actions { display: flex; align-items: center; gap: 14px; }
.bookmaker-card { justify-content: space-between; flex-wrap: wrap; }
.bookmaker-logo {
  display: grid;
  place-items: center;
  flex: 0 0 84px;
  height: 52px;
}
.bookmaker-logo img { display: block; }
.bookmaker-logo img[src$=".svg"] {
  width: 52px;
  height: 52px;
  border-radius: 50%;
}
.bookmaker-logo img[src$=".png"] { width: 84px; height: auto; }
body.dark .bookmaker-logo img[src$=".png"] {
  filter: drop-shadow(0 0 1px rgba(255, 255, 255, .85));
}
.bookmaker-card .list-card-foot { margin-top: 4px; }
.bookmaker-stars { color: #a76000; font-size: 17px; white-space: nowrap; }
body.dark .bookmaker-stars { color: #fbbf24; }

.article-card { position: relative; color: var(--text); }
.article-card-link { color: inherit; }
.article-card-link::after { content: ""; position: absolute; inset: 0; }
.article-cover {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-sm);
  margin-bottom: 14px;
}
.article-content { overflow-wrap: anywhere; }
.article-content figure { margin: 24px 0; }
.article-content figure img { display: block; max-width: 100%; max-height: 680px; margin: 0 auto; border-radius: var(--radius-sm); }
.article-content figcaption { margin-top: 8px; text-align: center; color: var(--text-soft); font-size: 13px; }
.article-content h2, .article-content h3 { margin: 24px 0 10px; }
.article-content blockquote { margin: 20px 0; padding-inline-start: 16px; border-inline-start: 3px solid var(--brand); }

@media (min-width: 951px) {
  .year-cards:has(> .year-card:nth-child(4)) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 651px) and (max-width: 950px) {
  .year-cards:has(> .year-card:nth-child(4)) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.rating-results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 10px;
}
.rating-results-bar .rating-freshness { margin: 0; }
.rating-view-switch { display: none; }
.capper-result-date { margin: -6px 0 14px; color: var(--text-soft); font-size: 13px; }
.capper-result-date strong { color: var(--text); }

@media (max-width: 768px) {
  .rating-view-switch { display: inline-flex; }
  .rating-view-switch[aria-pressed="true"] { color: var(--brand); background: var(--brand-soft-bg); }
  #page-statistics.rating-table-mobile .mobile-cards { display: none; }
  #page-statistics.rating-table-mobile .table-wrap { display: block; }
  #page-statistics table.stats { min-width: 900px; }
  #page-statistics table.stats col.col-name { width: 168px; }
  #page-statistics table.stats th:nth-child(3),
  #page-statistics table.stats td:nth-child(3) {
    position: sticky;
    left: 0;
    z-index: 1;
    box-shadow: 1px 0 var(--border);
  }
  #page-statistics table.stats td:nth-child(3) { background: var(--surface); }
  #page-statistics table.stats tr:nth-child(even) td:nth-child(3) { background: var(--surface-row-alt); }
}

[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.weekend-contest { max-width: 1000px; margin: 0 auto; }
.weekend-heading { display: flex; align-items: start; justify-content: space-between; gap: 18px; }
.weekend-heading h1 { font-size: clamp(25px,4vw,36px); margin: 4px 0 8px; }
.weekend-heading p { color: var(--text-soft); margin: 0; }
.weekend-prize { color: var(--brand); font-size: 30px; white-space: nowrap; }
.weekend-prize small { display: block; color: var(--text-soft); font-size: 12px; font-weight: 500; }
.weekend-summary { display: flex; flex-wrap: wrap; gap: 12px 28px; padding: 16px 0; margin-top: 12px; border-bottom: 1px solid var(--border); }
.weekend-rules { color: var(--text-soft); font-size: 14px; line-height: 1.6; }
.weekend-login { padding: 16px; background: var(--brand-soft-bg); border-radius: 10px; }
.weekend-login>div { display: flex; gap: 8px; margin-top: 10px; }
.weekend-day { padding: 20px 0 0; }
.weekend-day h2, .weekend-public h2 { font-size: 19px; margin: 0 0 12px; }
.weekend-match { display: grid; grid-template-columns: minmax(0,1fr) 246px; gap: 16px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--border); }
.weekend-fixture { display: grid; grid-template-columns: minmax(0,1fr) 26px minmax(0,1fr); align-items: center; gap: 12px; }
.weekend-team { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 14px; font-weight: 600; }
.weekend-team img { flex: none; object-fit: contain; }
.weekend-versus { color: var(--text-soft); text-align: center; }
.weekend-fixture > .weekend-team:first-child { flex-direction: row-reverse; text-align: right; }
.weekend-outcomes { border: 0; padding: 0; margin: 0; display: flex; gap: 6px; min-width: 0; }
.weekend-option { flex: 1; cursor: pointer; position: relative; }
.weekend-option input { position: absolute; opacity: 0; }
.weekend-option>span { display: flex; flex-direction: column; align-items: center; padding: 6px 4px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-alt); }
.weekend-option small { font-size: 11px; color: var(--text-soft); }
.weekend-option input:checked+span { color: var(--brand); border-color: var(--brand); background: var(--brand-soft-bg); }
.weekend-option input:focus-visible+span { outline: 2px solid var(--brand); outline-offset: 2px; }
.weekend-outcomes:disabled .weekend-option { cursor: default; }
.weekend-submit { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 20px 0 0; }
.weekend-submit>span { color: var(--text-soft); font-size: 13px; }
.weekend-success { padding: 12px; background: var(--brand-soft-bg); border-radius: 8px; }
.weekend-answer-scroll { overflow-x: auto; }
.weekend-answer-table { border-collapse: collapse; font-size: 13px; }
.weekend-answer-table th,.weekend-answer-table td { padding: 8px; border: 1px solid var(--border); text-align: center; min-width: 34px; }
.weekend-answer-table th:first-child { position: sticky; left: 0; background: var(--surface); min-width: 120px; text-align: left; }
button:disabled { opacity: .55; cursor: default; }
@media(max-width:650px) {
 .weekend-heading { flex-direction: column; gap: 12px; }
 .weekend-match { grid-template-columns: 1fr; gap: 10px; padding: 14px 0; }
 .weekend-team { font-size: 13px; }
 .weekend-team img { width: 26px; height: 26px; }
 .weekend-submit { flex-direction: column; align-items: stretch; }
 .weekend-outcomes { width: 100%; }
 .weekend-option>span { flex-direction: row; justify-content: center; gap: 10px; min-height: 42px; }
 #accountButton { display: inline-flex; }
}


.weekend-submit-hint { display: inline-flex; position: relative; }
.weekend-submit-hint button:disabled { pointer-events: none; }
.weekend-submit-tooltip {
  display: none;
  position: absolute;
  z-index: 3;
  right: 0;
  bottom: calc(100% + 10px);
  width: 245px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  color: var(--text);
  font-size: 13px;
}
.weekend-submit-hint:hover .weekend-submit-tooltip,
.weekend-submit-hint:focus-visible .weekend-submit-tooltip { display: block; }

/* Weekend contest prizes */
.weekend-info { margin: 24px 0; }
.weekend-prize-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.weekend-prize-grid > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); }
.weekend-prize-grid strong { color: var(--primary); }
@media (max-width: 480px) { .weekend-prize-grid { grid-template-columns: 1fr; } }

/* Personal profile */
.profile-container { padding-top:32px; padding-bottom:64px; }
.profile-container h1 { margin-bottom:24px; }
.profile-panel { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-lg); padding:26px; }
.profile-hero { display:flex; align-items:center; gap:24px; margin-bottom:24px; }
.profile-avatar { width:104px; height:104px; flex-shrink:0; border-radius:50%; background:var(--brand-soft-bg); color:var(--brand); display:grid; place-items:center; overflow:hidden; font-size:32px; font-weight:800; border:1px solid var(--border); }
.profile-avatar img { width:100%; height:100%; object-fit:cover; }
.profile-identity h2 { margin:6px 0; font-size:28px; }
.profile-identity p { color:var(--text-soft); margin-bottom:14px; }
.profile-actions { display:flex; gap:8px; flex-wrap:wrap; }
.profile-upload { cursor:pointer; }
.profile-counts { margin-left:auto; display:flex; gap:30px; text-align:center; }
.profile-counts strong { display:block; font-size:26px; color:var(--brand); }
.profile-counts span, .profile-muted { font-size:13px; color:var(--text-soft); }
.profile-tabs { display:flex; gap:8px; border-bottom:1px solid var(--border); margin-bottom:28px; padding-bottom:12px; overflow-x:auto; scrollbar-width:thin; scrollbar-color:var(--text-soft) var(--surface-alt); }
.profile-tabs button { border:0; background:transparent; color:var(--text-soft); padding:14px 18px; white-space:nowrap; cursor:pointer; font:inherit; border-bottom:3px solid transparent; }
.profile-tabs button.active { color:var(--brand); border-bottom-color:var(--brand); font-weight:700; }
.profile-section-head { display:flex; justify-content:space-between; align-items:center; gap:16px; margin-bottom:20px; }
.profile-section-head p, .profile-panel p { color:var(--text-soft); }
.profile-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px; margin-top:20px; }
.profile-panel h3 { margin:0 0 12px; }
.profile-panel p { margin:10px 0 16px; line-height:1.6; }
.profile-empty { text-align:center; padding:46px 24px; margin-top:20px; }
.profile-empty-icon { display:block; font-size:34px; color:var(--brand); margin-bottom:16px; font-weight:800; }
.profile-status { color:var(--positive); font-size:13px; display:block; margin-bottom:14px; }
.profile-metrics { display:flex; flex-wrap:wrap; gap:30px; padding:18px 0; border-top:1px solid var(--border); margin-top:18px; }
.profile-metrics span { display:block; color:var(--text-soft); font-size:12px; margin-bottom:8px; }
.profile-metrics strong { font-size:20px; }
.profile-label { display:block; font-weight:600; font-size:13px; margin:16px 0; }
.profile-label input { display:block; width:100%; box-sizing:border-box; margin-top:8px; border:1px solid var(--border-strong); border-radius:8px; padding:12px; background:var(--surface); color:var(--text); font:inherit; }
.profile-label input[readonly] { background:var(--surface-alt); }
.profile-session { margin-top:20px; display:flex; justify-content:space-between; align-items:center; gap:16px; }
.profile-container button:disabled { opacity:.55; cursor:not-allowed; }
@media(max-width:700px) {
 .profile-hero { flex-wrap:wrap; gap:18px; padding:20px; }
 .profile-avatar { width:76px; height:76px; }
 .profile-identity { flex:1; min-width:160px; }
 .profile-identity h2 { font-size:24px; overflow-wrap:anywhere; }
 .profile-counts { width:100%; justify-content:space-around; padding-top:18px; border-top:1px solid var(--border); gap:12px; }
 .profile-grid { grid-template-columns:1fr; }
 .profile-section-head,.profile-session { align-items:flex-start; flex-direction:column; }
 .profile-tabs button { padding:12px; font-size:14px; }
 .profile-panel { padding:20px; }
}

/* Account entry */
.auth-modal { position:relative; padding:34px; max-width:420px; box-sizing:border-box; max-height:calc(100dvh - 40px); overflow-y:auto; }
.auth-brand { display:block; color:var(--brand); font-weight:800; font-size:13px; letter-spacing:.04em; margin-bottom:14px; }
.auth-modal h2 { font-size:26px; margin-bottom:10px; }
.auth-intro { color:var(--text-soft); font-size:14px; line-height:1.6; margin:0 0 26px; }
.auth-close { position:absolute; top:16px; right:18px; width:32px; height:32px; padding:0; border:0; border-radius:50%; color:var(--text-soft); background:var(--surface-alt); cursor:pointer; font-size:25px; line-height:1; }
.auth-close:hover { background:var(--brand-soft-bg); color:var(--brand); }
.auth-modal .form-group { margin-bottom:18px; }
.auth-modal input { box-sizing:border-box; min-height:46px; border-radius:8px; }
.auth-modal small { display:block; margin-top:7px; color:var(--text-soft); font-size:12px; line-height:1.5; }
.auth-submit { width:100%; min-height:46px; justify-content:center; margin-top:6px; }
.auth-switch { display:flex; flex-wrap:wrap; align-items:center; justify-content:center; gap:6px; border-top:1px solid var(--border); margin:24px 0 0; padding-top:20px; font-size:14px; color:var(--text-soft); }
.auth-text-link { border:0; padding:3px 0; background:transparent; color:var(--brand); font:inherit; font-weight:700; cursor:pointer; }
.auth-text-link:hover { text-decoration:underline; }
.auth-modal [role=status]:empty { display:none; }
.auth-modal [role=status] { color:var(--negative); font-size:13px; line-height:1.5; margin:12px 0; }
.profile-label select { display:block; width:100%; margin-top:8px; padding:12px; border:1px solid var(--border-strong); background:var(--surface); color:var(--text); border-radius:8px; font:inherit; }
@media(max-width:480px) { .auth-modal { padding:26px 22px; } .auth-modal h2 { font-size:24px; } }
.claim-search-results { max-height:280px; overflow:auto; border-radius:8px; margin-top:-8px; }
.claim-search-option { width:100%; display:flex; align-items:center; justify-content:space-between; gap:16px; text-align:left; padding:14px; border:1px solid var(--border); background:var(--surface); color:var(--text); cursor:pointer; font:inherit; }
.claim-search-option:hover,.claim-search-option:focus-visible { background:var(--brand-soft-bg); border-color:var(--brand); }
.claim-search-option span { color:var(--brand); font-size:12px; }
.editorial-edit-button { margin:12px 0 24px; }
.editorial-editor-overlay { position:fixed; inset:0; z-index:400; background:rgba(9,25,35,.65); overflow-y:auto; padding:24px; }
.editorial-editor-panel { max-width:940px; margin:auto; background:var(--surface); color:var(--text); border-radius:14px; padding:30px; }
.editorial-editor-panel textarea { display:block; width:100%; box-sizing:border-box; margin-top:8px; padding:12px; color:var(--text); background:var(--surface); border:1px solid var(--border-strong); border-radius:8px; font:inherit; resize:vertical; }
.editorial-edit-body { min-height:300px; border:1px solid var(--border-strong); padding:22px; border-radius:8px; outline-color:var(--brand); white-space:pre-wrap; }
.editorial-save-bar { position:sticky; bottom:-1px; background:var(--surface); border-top:1px solid var(--border); display:flex; justify-content:space-between; align-items:center; gap:16px; padding:16px 0; margin-top:20px; }
@media(max-width:600px){.editorial-editor-overlay{padding:8px}.editorial-editor-panel{padding:18px}.editorial-edit-body{padding:14px}}

.owned-channels { margin-bottom:26px; border-color:var(--brand-soft); background:linear-gradient(110deg,var(--surface),var(--brand-soft-bg)); }
.owned-channels h2 { margin:8px 0 0; }
.owned-channel-list { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.owned-channel { display:flex; justify-content:space-between; align-items:center; gap:18px; padding:18px; border:1px solid var(--border-strong); border-radius:10px; background:var(--surface); color:var(--brand); text-decoration:none; }
.owned-channel:hover { border-color:var(--brand); background:var(--surface-alt); }
.owned-channel strong { display:block; color:var(--text); font-size:17px; }
.owned-channel small { display:block; margin-top:6px; font-size:11px; font-weight:700; color:var(--brand); }
.capper-owner { font-size:13px; margin:8px 0; color:var(--text-soft); }
.capper-owner a { color:var(--brand); font-weight:700; }
.admin-create-button { white-space:nowrap; font-weight:700; }
.cms-kind-tabs,.cms-format-bar,.cms-cover-row { display:flex; align-items:center; gap:10px; flex-wrap:wrap; margin:16px 0; }
.cms-cover-row img { width:120px; height:80px; object-fit:cover; border-radius:8px; }
.cms-categories { display:flex; flex-wrap:wrap; gap:16px; margin:20px 0; padding:18px; border:1px solid var(--border); border-radius:8px; }
.cms-categories input { margin-right:5px; }
.cms-match-row { display:grid; grid-template-columns:140px 1fr 1fr 60px 60px 60px 40px; gap:8px; margin:10px 0; align-items:center; }
.cms-match-row input { width:100%; min-width:0; border:1px solid var(--border-strong); border-radius:6px; padding:10px 6px; color:var(--text); background:var(--surface); }
.cms-preview { margin-top:20px; border:1px solid var(--border); border-radius:8px; padding:16px; }
.cms-preview summary { cursor:pointer; color:var(--brand); font-weight:700; }
.cms-preserve-lines { white-space:pre-wrap; }
.cms-match-teams { display:grid; grid-template-columns:1fr 26px 1fr; gap:10px; align-items:center; margin-bottom:10px; font-weight:700; }
.cms-match-teams span:first-child { text-align:right; }
.cms-match-teams span:nth-child(2) { text-align:center; color:var(--text-soft); }
.cms-empty-cover { height:220px; background:linear-gradient(135deg,var(--brand),var(--brand-dark)); color:white; display:grid; place-items:center; font-size:22px; font-weight:800; border-radius:8px; }
#cmsDrafts .btn { margin:6px; }
@media(max-width:700px){
 .owned-channel-list { grid-template-columns:1fr; }
 .owned-channel { padding:14px; }
 .cms-match-row { grid-template-columns:repeat(3,minmax(0,1fr)); padding:12px; border:1px solid var(--border); border-radius:8px; }
 .cms-match-row input:first-child { grid-column:1/-1; }
 .cms-match-row input:nth-child(2) { grid-column:1/3; }
 .cms-match-row input:nth-child(3) { grid-column:1/-1; }
 .admin-create-button { padding:6px 9px; font-size:12px; }
}

/* Keep the admin action legible on the blue header. */
.header-actions .admin-create-button {
 color:#fff; background:rgba(255,255,255,.12); border-color:rgba(255,255,255,.55);
}
.header-actions .admin-create-button:hover,
.header-actions .admin-create-button:focus-visible {
 color:var(--brand-dark); background:#fff; border-color:#fff;
}

.profile-victories { margin-bottom:26px; border-color:rgba(221,173,67,.45); }
.profile-victories h2 { margin:8px 0 0; }
.victory-count { padding:10px 16px; border-radius:10px; background:rgba(245,158,11,.12); font-size:25px; font-weight:800; }
.victory-card { border:1px solid rgba(221,173,67,.4); border-radius:10px; padding:20px; background:rgba(245,158,11,.04); }
.victory-place { color:#9c690b; font-size:12px; font-weight:800; display:block; margin-bottom:10px; }
.btn-danger { color:var(--negative); border:1px solid var(--negative); background:var(--negative-bg); }
.btn-danger:hover { color:#fff; background:var(--negative); }
.publication-delete { margin:12px 0 24px 8px; }
.rich-toolbar { position:sticky; top:-30px; z-index:2; display:flex; align-items:center; flex-wrap:wrap; gap:6px; padding:12px; background:var(--surface-alt); border:1px solid var(--border-strong); border-radius:8px; margin:14px 0; }
.rich-toolbar button,.rich-toolbar select { background:var(--surface); border:1px solid var(--border); border-radius:5px; padding:7px 9px; color:var(--text); font:inherit; font-size:13px; cursor:pointer; min-height:34px; }
.rich-toolbar button:hover,.rich-toolbar button:focus-visible { border-color:var(--brand); color:var(--brand); background:var(--brand-soft-bg); }
.rich-color { display:flex; align-items:center; gap:5px; font-size:13px; padding:0 5px; }
.rich-color input { width:30px; height:30px; padding:0; background:transparent; border:0; }
@media(max-width:600px){.rich-toolbar{top:-18px;padding:8px;gap:5px}.rich-toolbar button,.rich-toolbar select{padding:6px;font-size:12px}}

/* Image layout is shared between editing, preview and published text. */
.review-content { min-width:0; overflow-wrap:anywhere; }
.review-content figure { max-width:100%; box-sizing:border-box; margin-top:24px; margin-bottom:24px; }
.review-content img { max-width:100%; height:auto; box-sizing:border-box; }
.review-content figure img { display:block; max-width:100%; height:auto; }
.review-content figcaption { font-size:13px; line-height:1.5; color:var(--text-soft); text-align:center; margin-top:10px; white-space:pre-wrap; }
.editorial-edit-body img { cursor:pointer; }
.editorial-edit-body figure { margin-left:0; margin-right:0; }
.editorial-edit-body .rich-selected-image { outline:2px solid var(--brand); outline-offset:5px; border-radius:4px; }
.rich-image-panel { position:sticky; top:110px; z-index:3; background:var(--surface); border:1px solid var(--brand-soft); border-radius:10px; box-shadow:var(--shadow-md); padding:12px; margin:12px 0; }
.rich-image-panel-head { display:flex; justify-content:space-between; align-items:center; color:var(--brand); }
.rich-image-panel-head button { border:0; background:transparent; color:var(--text-soft); cursor:pointer; font-size:24px; }
.rich-image-controls { display:flex; align-items:center; flex-wrap:wrap; gap:6px; margin:8px 0; font-size:13px; }
.rich-image-controls button,.rich-image-controls select,.rich-image-upload { display:inline-flex; align-items:center; min-height:32px; padding:6px 9px; border:1px solid var(--border); border-radius:5px; background:var(--surface-alt); color:var(--text); font:inherit; font-size:13px; cursor:pointer; }
.rich-image-controls [aria-pressed=true] { color:var(--brand); border-color:var(--brand); background:var(--brand-soft-bg); }
.rich-image-controls .rich-image-delete { color:var(--negative); }
.rich-image-caption-label { display:flex; align-items:center; gap:10px; font-size:13px; color:var(--text-soft); }
.rich-image-caption-label input { flex:1; min-width:0; padding:8px 10px; border:1px solid var(--border); border-radius:6px; color:var(--text); background:var(--surface); font:inherit; }
.rich-image-status:empty { display:none; }
.rich-image-status { font-size:12px; color:var(--text-soft); margin:6px 0 0; }
@media(max-width:600px){.rich-image-panel{top:140px;padding:10px}.rich-image-caption-label{align-items:stretch;flex-direction:column;gap:5px}.rich-image-controls button,.rich-image-controls select{font-size:12px}}

.publication-new-badge { display:inline-block; margin-left:8px; padding:3px 7px; color:var(--brand); background:var(--brand-soft-bg); border:1px solid var(--brand-soft); border-radius:5px; font-size:10px; font-weight:800; letter-spacing:.03em; vertical-align:middle; }
.publication-marker-fields { padding:18px; margin:18px 0; border:1px solid var(--border-strong); background:var(--surface-alt); border-radius:10px; }
.marker-checkbox { display:flex; align-items:center; gap:8px; font-size:14px; font-weight:700; cursor:pointer; }
.marker-checkbox input { width:17px; height:17px; accent-color:var(--brand); }
.publication-settings-button { margin:12px 0 24px 8px; }
#publicationSettingsDialog { z-index:500; }
.profile-identity .profile-bio { color:var(--text); font-size:14px; line-height:1.6; white-space:pre-wrap; overflow-wrap:anywhere; max-width:55ch; margin:10px 0; }
.profile-bio-settings { margin-top:20px; }
.profile-bio-settings textarea { display:block; width:100%; box-sizing:border-box; margin-top:8px; padding:12px; border:1px solid var(--border-strong); border-radius:8px; color:var(--text); background:var(--surface); font:inherit; resize:vertical; }
#profileBioCounter { color:var(--text-soft); }
.profile-role { display:inline-block; font-size:11px; font-weight:800; letter-spacing:.06em; padding:5px 9px; border-radius:6px; line-height:1.4; }
.profile-role-participant { color:var(--brand); background:var(--brand-soft-bg); }
.profile-role-capper { color:var(--positive); background:var(--positive-bg); border:1px solid rgba(22,163,74,.25); }
.profile-role-admin { color:#9c690b; background:rgba(245,158,11,.12); border:1px solid rgba(245,158,11,.3); }
body.dark .profile-role-admin { color:#f8cb6a; }
.admin-users-list { margin-top:22px; }
.admin-user-row { display:flex; align-items:center; justify-content:space-between; gap:14px; padding:16px 0; border-top:1px solid var(--border); }
.admin-user-row .profile-role { margin-left:8px; }
@media(max-width:600px){.admin-user-row{flex-direction:column;align-items:flex-start}.admin-user-row .profile-role{margin:8px 0;display:block}}

/* Discussions and moderation inbox */
.comments-section { margin-top:38px; margin-bottom:60px; border-top:1px solid var(--border); padding-top:28px; }
.comments-heading { display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:22px; }
.comments-heading h2 { font-size:22px; margin:0; }
.comments-heading h2 span { font-size:14px; color:var(--text-soft); font-weight:500; margin-left:6px; }
.comment-composer { margin-bottom:24px; }
.comment-form,.comment-login { padding:20px; background:var(--surface); border:1px solid var(--border); border-radius:12px; }
.comment-login p { margin:0 0 12px; color:var(--text-soft); }
.comment-form-author { font-weight:700; margin-bottom:12px; }
.comment-form textarea { display:block; width:100%; min-height:100px; box-sizing:border-box; border:1px solid var(--border-strong); border-radius:8px; padding:12px; resize:vertical; color:var(--text); background:var(--surface); font:inherit; font-size:14px; line-height:1.6; }
.comment-form-footer { display:flex; justify-content:space-between; align-items:center; margin-top:12px; gap:12px; }
.comment-character-count { font-size:12px; color:var(--text-soft); }
.comment-item { padding:22px 0; border-bottom:1px solid var(--border); overflow-wrap:anywhere; }
.comment-meta { display:flex; align-items:center; gap:12px; }
.comment-avatar { width:40px; height:40px; flex-shrink:0; display:grid; place-items:center; border-radius:50%; overflow:hidden; background:var(--brand-soft-bg); color:var(--brand); font-size:13px; font-weight:800; text-decoration:none; }
.comment-avatar img { width:100%; height:100%; object-fit:cover; }
.comment-author { font-size:14px; font-weight:700; color:var(--text); text-decoration:none; }
.comment-author:hover { color:var(--brand); text-decoration:underline; }
.comment-meta .profile-role { padding:2px 5px; margin-left:5px; font-size:9px; }
.comment-meta time { display:block; color:var(--text-soft); font-size:11px; margin-top:4px; }
.comment-body { white-space:pre-wrap; font-size:14px; line-height:1.7; margin:14px 0; color:var(--text); }
.comment-actions { display:flex; align-items:center; gap:16px; }
.comment-actions button,.comment-actions a { border:0; padding:0; background:transparent; color:var(--brand); font:inherit; font-size:12px; cursor:pointer; text-decoration:none; }
.comment-actions .comment-delete { color:var(--text-soft); }
.comment-actions button:hover,.comment-actions a:hover { text-decoration:underline; }
.comment-reply-label,.comment-parent { color:var(--text-soft); font-size:12px; border-left:2px solid var(--brand-soft); padding:6px 10px; margin:8px 0; }
.comment-reply-label button { float:right; background:transparent; border:0; cursor:pointer; color:var(--text-soft); }
.comments-empty { padding:28px 0; color:var(--text-soft); font-size:14px; }
.comments-more { margin-top:20px; }
.comments-status,.comment-form [role=status] { font-size:13px; color:var(--negative); }
.comment-highlight { background:var(--brand-soft-bg); border-radius:8px; padding-left:14px; padding-right:14px; }
.admin-comments-button { position:relative; }
.comment-notification-count { position:absolute; right:-5px; top:-4px; display:grid; place-items:center; min-width:17px; height:17px; padding:0 3px; box-sizing:border-box; border-radius:9px; color:#fff; background:#df4343; font-size:10px; font-weight:800; border:1px solid var(--brand); }
.comment-dashboard-overlay { position:fixed; inset:0; z-index:600; background:rgba(9,25,35,.4); }
.comment-dashboard { position:absolute; right:0; top:0; bottom:0; width:min(500px,100%); padding:24px; box-sizing:border-box; overflow-y:auto; background:var(--surface); color:var(--text); box-shadow:var(--shadow-lg); }
.comment-dashboard-heading { display:flex; justify-content:space-between; align-items:flex-start; gap:15px; }
.comment-dashboard-heading h2 { margin:0 0 8px; font-size:24px; }
.comment-dashboard-heading p { color:var(--text-soft); font-size:13px; }
.comment-dashboard-tools { display:flex; flex-wrap:wrap; gap:6px; padding:16px 0; border-bottom:1px solid var(--border); }
.comment-dashboard-tools .btn { padding:7px 10px; font-size:12px; }
.comment-dashboard-tools .active { background:var(--brand); color:#fff; }
.comment-target { margin-bottom:14px; font-size:13px; }
.comment-target span { display:block; font-size:10px; font-weight:800; color:var(--text-soft); text-transform:uppercase; margin-bottom:4px; }
.comment-target a { color:var(--brand); font-weight:700; text-decoration:none; }
.comment-item-new { border-left:3px solid var(--brand); padding-left:12px; }
@media(max-width:600px){.comment-dashboard{padding:18px}.comment-form,.comment-login{padding:16px}.comments-heading h2{font-size:20px}.comment-meta .profile-role{font-size:8px}}
.comment-replies { margin-left:32px; padding-left:20px; border-left:2px solid var(--border-strong); }
.comment-replies .comment-item { padding-top:18px; padding-bottom:18px; }
.comment-replies-flat { margin-left:0; padding-left:14px; }
.admin-comments-button .comment-notification-count { right:-5px; top:-4px; min-width:19px; height:19px; padding:0 4px; background:#dc2626; color:#fff; font-size:11px; line-height:1; border:1px solid #fff; z-index:3; }
@media(max-width:600px){.comment-replies{margin-left:14px;padding-left:12px}.comment-replies-flat{margin-left:0;padding-left:8px}}
.ops-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin:20px 0; }
.ops-tile { text-align:left; cursor:pointer; color:var(--text); font:inherit; }
.ops-tile strong,.ops-tile span { display:block; }
.ops-tile strong { font-size:18px; margin-bottom:10px; }
.ops-tile span { color:var(--text-soft); font-size:13px; line-height:1.5; }
.ops-tile:hover { border-color:var(--brand); background:var(--surface-alt); }
.ops-backups,.ops-mail { margin-top:20px; }
.ops-backup-row { display:flex; flex-wrap:wrap; align-items:center; gap:10px; padding:16px 0; border-bottom:1px solid var(--border); }
.ops-backup-row>div { flex:1; min-width:190px; }
.ops-backup-row small { display:block; color:var(--text-soft); margin-top:6px; }
.claim-review-card,.personal-notification { margin:16px 0; }
.notification-unread { border-left:3px solid var(--brand); }
.personal-notification small { display:block; margin-bottom:12px; color:var(--text-soft); }
.account-action-panel { max-width:500px; margin:20px auto; }
.result-input-row { display:grid; grid-template-columns:1fr 200px; gap:16px; align-items:center; padding:12px 0; border-bottom:1px solid var(--border); font-size:14px; }
.result-input-row select { border:1px solid var(--border-strong); border-radius:6px; padding:10px; background:var(--surface); color:var(--text); }
#resultPrizes { width:100%; padding:12px; box-sizing:border-box; background:var(--surface); color:var(--text); border:1px solid var(--border); border-radius:8px; font:inherit; }
.contest-result-panel { margin:24px 0; }
.editor-autosave-status { color:var(--text-soft); font-size:12px; padding:8px 0; }
.auth-forgot { display:block; margin:14px auto 0; font-size:13px; }
@media(max-width:600px){.ops-grid{grid-template-columns:1fr}.result-input-row{grid-template-columns:1fr;gap:8px}}

.notification-drawer{width:min(480px,100%);padding:28px;display:flex;flex-direction:column}
.notification-tools{display:flex;justify-content:flex-end;margin:14px 0}
.notification-tools:has(button[hidden]){display:none}
.notification-empty{text-align:center;padding:48px 12px;color:var(--text-soft)}
.notification-empty>span{display:grid;place-items:center;width:64px;height:64px;margin:0 auto 18px;border-radius:50%;background:var(--brand-soft-bg);color:var(--brand);font-size:36px}
.notification-empty h3{color:var(--text);margin:0 0 10px;font-size:20px}
.notification-empty p{font-size:14px;line-height:1.7;margin:0}
.notification-drawer .personal-notification{padding:18px;margin:14px 0;border-radius:10px}
.notification-drawer .personal-notification h3{font-size:16px;margin:0 0 8px}
.notification-drawer .personal-notification p{font-size:14px;line-height:1.6}
body:has(#personalNotificationsPanel){overflow:hidden}
@media(max-width:600px){.notification-drawer{padding:20px}.notification-empty{padding-top:36px}}

#capperComments{scroll-margin-top:140px}

.capper-loading{min-height:260px}.capper-loading-indicator{display:inline-block;width:28px;height:28px;border:3px solid var(--line,#d6e4ee);border-top-color:var(--primary,#0c6c9e);border-radius:50%;animation:capper-loading-spin 1s linear infinite}.capper-loading p{color:var(--muted,#64748b)}@keyframes capper-loading-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.capper-loading-indicator{animation:none}}

.report-evidence{display:flex;flex-wrap:wrap;gap:12px}.report-evidence img{max-width:240px;max-height:240px;object-fit:contain;border:1px solid #d6e4ee;border-radius:8px}#blacklistReportStatus{overflow-wrap:anywhere}#adminReportsButton[hidden]{display:none}

/* Mobile navigation stays in one compact row; administrative actions keep icon widths. */
@media(max-width:600px){
 .header-inner{display:flex;align-items:center;justify-content:space-between;gap:8px;height:60px;padding-block:0}
 .header-wordmark{font-size:18px}.header-home{flex-shrink:0}
 .header-actions{margin-left:auto;gap:2px;min-width:0;flex-shrink:0}
 .header-actions .icon-btn{width:30px;height:36px;flex:0 0 30px}
 .header-actions .admin-create-button{font-size:0;padding:0;width:30px;height:34px;min-width:30px;margin:0;border:0}
 .header-actions .admin-create-button::before{content:'+';font-size:24px;color:#fff}
 .mobile-menu{max-height:calc(100dvh - 60px);overflow-y:auto}.mobile-menu .nav-link{padding:10px 16px}
}
.home-rating-mobile,.table-swipe-hint{display:none}
@media(max-width:768px){
 .home-rating-mobile{display:block;background:var(--surface);border:1px solid var(--border);border-radius:14px;overflow:hidden}
 .home-rating-mobile h3{font-size:15px;padding:14px 16px;margin:0;border-bottom:1px solid var(--border)}
 .home-top-row{display:grid;grid-template-columns:20px minmax(0,1fr) auto;gap:8px;align-items:center;padding:14px 12px;border-bottom:1px solid var(--border);color:var(--text)}
 .home-top-row:last-child{border-bottom:0}.home-top-row:hover{background:var(--surface-alt);text-decoration:none}
 .home-top-name strong{display:block;font-size:14px;overflow-wrap:normal;word-break:normal}.home-top-place{color:var(--text-soft);font-size:12px}
 .home-top-row small{display:block;font-size:11px;color:var(--text-soft);margin-top:4px}.home-top-value{text-align:right;white-space:nowrap;font-size:13px}
 #page-statistics .table-swipe-hint{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px;background:var(--brand-soft-bg);color:var(--brand);font-size:12px;line-height:1.5;border-bottom:1px solid var(--border)}
 .table-swipe-hint .btn{padding:5px 12px;font-size:20px;flex:none}
 #page-statistics table.stats th:nth-child(3){z-index:3}
}
/* Narrow blacklist rows keep the channel name intact and move the reason below. */
@media(max-width:600px){
 .blacklist-table,.blacklist-table tbody{display:block;width:100%}.blacklist-table thead{display:none}
 .blacklist-table tbody tr{display:grid;grid-template-columns:minmax(0,1fr) auto 18px;gap:8px 10px;padding:14px 12px;border-bottom:1px solid var(--border)}
 .blacklist-table th,.blacklist-table td{display:block;padding:0;border:0;overflow-wrap:normal;word-break:normal;hyphens:none}
 .blacklist-table tbody tr>th:first-child{grid-column:1;grid-row:1;font-size:15px;line-height:1.5;min-width:0}
 .blacklist-table tbody tr>td:nth-child(2){grid-column:1 / -1;grid-row:2;font-size:13px;color:var(--text-soft);line-height:1.6}
 .blacklist-table tbody tr>td:nth-child(3){grid-column:2;grid-row:1;font-size:11px;align-self:center}
 .blacklist-table .blacklist-table-action{grid-column:3;grid-row:1;width:auto;padding:0;align-self:center}
}
/* A selected outcome must remain distinct from keyboard focus on every screen. */
.weekend-option input:checked+span{color:#fff;background:var(--brand);border-color:var(--brand);box-shadow:inset 0 0 0 1px var(--brand),0 2px 6px rgba(0,0,0,.12)}
.weekend-option input:checked+span small{color:#fff;opacity:.95}
.weekend-option>span{position:relative;transition:background .15s,color .15s}
.weekend-option input:focus-visible+span{outline:3px solid var(--brand);outline-offset:3px}
body.dark .weekend-option input:checked+span{background:#126d99;color:#fff;border-color:#a0cadc}

/* Account confirmation and recovery actions use a full, comfortable touch target. */
.account-action-panel .account-action-primary{display:inline-flex;align-items:center;justify-content:center;min-height:48px;padding:12px 24px;margin-top:12px;border-radius:10px;font-size:15px;font-weight:700;line-height:1.4;text-decoration:none;box-shadow:0 2px 5px rgba(12,108,158,.16)}
.account-action-panel .account-action-primary:hover{background:var(--brand-dark,var(--brand));box-shadow:0 3px 8px rgba(12,108,158,.22)}
.account-action-panel .account-action-primary:focus-visible{outline:3px solid var(--brand);outline-offset:3px}
@media(max-width:600px){.account-action-panel .account-action-primary{width:100%}}

.profile-login-value{margin:8px 0 0;font-size:16px;font-weight:600;color:var(--text)}
blockquote.comment-parent{margin:12px 0;padding:8px 12px;border-left:3px solid var(--brand);background:var(--brand-soft-bg);border-radius:0 6px 6px 0;font-size:13px;line-height:1.5;overflow-wrap:anywhere}

.profile-account-details{align-self:start;padding:20px}.profile-account-details>.profile-label{margin:12px 0}.profile-account-details .profile-login-value{margin:6px 0 12px}.profile-account-details .profile-mail-settings>h3{margin-top:16px}


.reports-list{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr));gap:12px;clear:both}
.reports-list>.profile-panel{min-width:0;display:flex;flex-direction:column;align-items:flex-start}
.reports-list h3{overflow-wrap:anywhere}.reports-list .btn{margin-top:auto}
.account-identity-row{display:grid;grid-template-columns:minmax(90px,.6fr) minmax(0,1.4fr);gap:16px;align-items:start}
.account-identity-row .profile-label{margin:0}.profile-panel .account-identity-row p{margin:8px 0 0;overflow-wrap:anywhere}
.profile-security-grid>.profile-panel{padding:20px}
.profile-security-grid #profileMailSettings,.profile-security-grid .profile-mail-settings,.profile-security-grid form{display:contents}
.profile-security-grid .profile-mail-settings{padding:0}
@media(min-width:701px){
 .profile-security-grid{grid-template-rows:auto auto auto auto auto auto auto;row-gap:16px}
 .profile-security-grid>.profile-panel{display:grid;grid-row:span 7;grid-template-rows:subgrid;align-self:stretch}
 .profile-security-grid h3{grid-row:1;margin:0}
 .profile-security-grid .account-identity-row{grid-row:2}
 .profile-security-grid .profile-label{margin:0}
 .profile-security-grid .profile-account-details form>label:nth-of-type(1){grid-row:3}
 .profile-security-grid .profile-account-details form>label:nth-of-type(2){grid-row:4}
 .profile-security-grid>.profile-panel:not(.profile-account-details) form>label:nth-of-type(1){grid-row:2}
 .profile-security-grid>.profile-panel:not(.profile-account-details) form>label:nth-of-type(2){grid-row:3}
 .profile-security-grid>.profile-panel:not(.profile-account-details) form>label:nth-of-type(3){grid-row:4}
 .profile-security-grid form>.profile-muted{grid-row:5;margin:0}
 .profile-security-grid form>.btn{grid-row:6;justify-self:start;align-self:start}
 .profile-security-grid form>[role=status]{grid-row:7;margin:0}
 .profile-security-grid form>[role=status]:empty{display:none}
}
@media(max-width:700px){.profile-security-grid>.profile-panel{display:block}.profile-security-grid .profile-label{margin:16px 0}.account-identity-row{margin-bottom:16px}}

/* Keep captions aligned even when a metric wraps onto two lines. */
.distance-grid>.kpi{grid-template-rows:32px 64px minmax(32px,auto)}
.capper-desc{white-space:pre-line;overflow-wrap:anywhere}

.empty-period{padding:24px;color:var(--text-soft)}

.legal-container{padding-top:28px;max-width:1000px}.legal-container h1{font-size:clamp(24px,4vw,32px);margin-bottom:12px}.registration-consent{display:flex;gap:10px;align-items:flex-start;font-size:14px;line-height:1.5;margin:16px 0}.registration-consent input{width:18px!important;height:18px!important;flex:0 0 18px;margin-top:2px}.registration-consent a{text-decoration:underline}.legal-container article{overflow-wrap:anywhere}.legal-container [id$="actions"]{margin-bottom:16px}

.footer-bottom{display:flex;justify-content:space-between;align-items:flex-start;gap:16px 28px;text-align:left;flex-wrap:wrap}.footer-bottom>span{flex:1 1 270px;max-width:440px;line-height:1.6}.footer-documents{display:flex;flex-wrap:wrap;gap:8px 20px;max-width:670px;align-items:center}.footer-documents a{font-size:13px;color:var(--text-soft);line-height:1.6;text-decoration:none}.footer-documents a:hover{color:var(--brand);text-decoration:underline}.footer-documents a:focus-visible{outline:2px solid var(--brand);outline-offset:4px}@media(max-width:700px){.footer-bottom{flex-direction:column;gap:14px}.footer-bottom>span{flex:auto}.footer-documents{flex-direction:column;align-items:flex-start;gap:8px}}

.archive-winners{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:20px 0 28px}.archive-winners h3{overflow-wrap:anywhere}.archive-winners strong{color:var(--brand);font-size:22px}@media(max-width:650px){.archive-winners{grid-template-columns:1fr}}

/* Archived contests share the RPL prize and podium components. */
.contest-archive-winners .contest-podium { margin-bottom: 0; }
.contest-archive-table-scroll { margin-top: 14px; max-height: 520px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.contest-archive-table { font-size: 14px; }
.contest-archive-table th, .contest-archive-table td { padding: 12px 16px; }
.contest-archive-table th:first-child, .contest-archive-table td:first-child { width: 80px; text-align: center; }
.contest-archive-table th:last-child, .contest-archive-table td:last-child { width: 100px; text-align: right; font-weight: 700; }
.contest-archive-table tbody tr:nth-child(even) { background: var(--surface-alt); }
.contest-archive-table tbody tr:hover { background: var(--primary-bg); }
.contest-archive-table .contest-archive-prize-row td { font-weight: 700; }
@media (max-width: 480px) {
  .contest-archive-table th, .contest-archive-table td { padding: 10px 8px; }
  .contest-archive-table th:first-child, .contest-archive-table td:first-child { width: 52px; }
  .contest-archive-table th:last-child, .contest-archive-table td:last-child { width: 64px; }
}

.contest-archive-table tbody tr.contest-tour-rank-1 { background: #fff1ce; }
body.dark .contest-archive-table tbody tr.contest-tour-rank-1 { background: #493a22; }
.contest-archive-table tbody tr.contest-tour-rank-2 { background: #e8edf3; }
body.dark .contest-archive-table tbody tr.contest-tour-rank-2 { background: #303d49; }
.contest-archive-table tbody tr.contest-tour-rank-3 { background: #f5e3d4; }
body.dark .contest-archive-table tbody tr.contest-tour-rank-3 { background: #48332a; }

.archive-bracket-scroll { overflow-x: auto; margin-top: 16px; padding-bottom: 12px; }
.archive-bracket { display: flex; gap: 28px; width: max-content; padding-right: 4px; }
.archive-bracket-round { width: 260px; flex-shrink: 0; position: relative; }
.archive-bracket-round h5 { font-size: 14px; margin: 0 0 12px; }
.archive-bracket-slot { height: var(--slot-height); display: flex; align-items: center; position: relative; }
.archive-bracket-round:not(:last-child) .archive-bracket-slot:nth-child(odd)::after { content: ''; position: absolute; left: 100%; top: 50%; width: 13px; height: 100%; border: 1px solid var(--border); border-left: 0; }
.archive-bracket-round:not(:first-child) .archive-bracket-slot::before { content: ''; position: absolute; right: 100%; top: 50%; width: 15px; border-top: 1px solid var(--border); }
.archive-bracket-match { width: 100%; border: 1px solid var(--border); border-radius: 7px; background: var(--surface); overflow: hidden; }
.archive-bracket-player { display: grid; grid-template-columns: 23px minmax(0,1fr) 25px; gap: 4px; align-items: center; min-height: 27px; padding: 4px 6px; font-size: 13px; }
.archive-bracket-player + .archive-bracket-player { border-top: 1px solid var(--border); }
.archive-bracket-player strong { text-align: right; }
.archive-bracket-player.is-winner { background: var(--primary-bg); font-weight: 700; }
.archive-bracket-seed { color: var(--text-soft); font-size: 12px; }
.archive-bracket-third { position: absolute; top: calc(50% + 80px); left: 0; right: 0; }

/* A clearer tournament bracket, using the site's blue palette. */
.archive-bracket-scroll { padding: 20px 18px 18px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.archive-bracket { gap: 40px; }
.archive-bracket-round { width: 270px; }
.archive-bracket-round h5 { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 42px; margin-bottom: 12px; padding: 10px 12px; border-radius: 8px; color: var(--brand); background: var(--primary-bg); }
.archive-bracket-round h5 span { font-size: 12px; font-weight: 500; color: var(--text-soft); }
.archive-bracket-round:last-child > h5 { background: var(--brand); color: white; }
.archive-bracket-round:last-child > h5 span { color: white; opacity: .85; }
.archive-bracket-match { border-radius: 9px; box-shadow: 0 2px 6px rgb(10 37 64 / 6%); }
.archive-bracket-player { grid-template-columns: 24px minmax(0,1fr) 30px; gap: 6px; min-height: 34px; padding: 5px 8px; }
.archive-bracket-player > span:nth-child(2) { overflow-wrap: anywhere; }
.archive-bracket-player.is-winner { background: var(--primary-bg); box-shadow: inset 3px 0 var(--brand); }
.archive-bracket-score { display: grid; place-items: center; min-height: 24px; border-radius: 5px; background: var(--surface-alt); }
.archive-bracket-player.is-winner .archive-bracket-score { background: var(--brand); color: white; }
.archive-bracket-round:not(:last-child) .archive-bracket-slot:nth-child(odd)::after { width: 19px; border-color: var(--text-soft); opacity: .55; border-width: 2px; }
.archive-bracket-round:not(:first-child) .archive-bracket-slot::before { width: 21px; border-color: var(--text-soft); opacity: .55; border-width: 2px; }
.archive-bracket-third h5 { background: var(--surface-alt); color: var(--text); }
body.dark .archive-bracket-player.is-winner, body.dark .archive-bracket-round h5 { background: #183d52; }
body.dark .archive-bracket-round:last-child > h5 { background: var(--brand); }

/* Both native scrollbars control the same bracket. */
.archive-bracket-top-scroll { overflow-x: scroll; overflow-y: hidden; height: 20px; margin-top: 16px; scrollbar-color: var(--text-soft) var(--surface-alt); }
.archive-bracket-top-scroll > div { height: 1px; }
.archive-bracket-top-scroll::-webkit-scrollbar, .archive-bracket-scroll::-webkit-scrollbar { height: 12px; }
.archive-bracket-top-scroll::-webkit-scrollbar-track, .archive-bracket-scroll::-webkit-scrollbar-track { background: var(--surface-alt); border-radius: 8px; }
.archive-bracket-top-scroll::-webkit-scrollbar-thumb, .archive-bracket-scroll::-webkit-scrollbar-thumb { background: var(--text-soft); border: 2px solid var(--surface-alt); border-radius: 8px; }
.archive-bracket-scroll { -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain; }

.archive-bracket-scroll { scrollbar-color: var(--text-soft) var(--surface-alt); }

.archive-bracket-bye { display: block; padding: 5px 8px; color: var(--text-soft); font-size: 12px; border-top: 1px solid var(--border); }

/* Align all sections across each row of contest cards. */
#contestsList > .contest-card { display: grid; grid-template-rows: subgrid; grid-row: span 5; row-gap: 0; }
#contestsList .contest-head { align-self: start; }
#contestsList .contest-desc { align-self: start; }
#contestsList .contest-info { align-self: start; }
#contestsList .contest-card-action { align-self: end; }
@supports not (grid-template-rows: subgrid) {
  #contestsList > .contest-card { display: flex; flex-direction: column; }
  #contestsList .contest-desc { min-height: 3em; }
  #contestsList .contest-card-action { margin-top: auto; padding-top: 12px; }
}

.contest-funds-four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 760px) { .contest-funds-four { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 480px) { .contest-funds-four { grid-template-columns: 1fr; } }

.contest-place-4 .contest-rank { background: #d9eff9; color: #0c6c9e; }
body.dark .contest-place-4 .contest-rank { background: #183d52; color: #9ed9f3; }

.contest-place-extra .contest-rank { background: #edf2f7; color: #64748b; font-size: 12px; }
body.dark .contest-place-extra .contest-rank { background: #293847; color: #b9c7d5; }

/* Shared artwork with editable contest information. */
.contest-cover { position: relative; aspect-ratio: 16/9; overflow: hidden; border-radius: 9px; background: #061e34; margin-bottom: 20px; container-type: inline-size; }
.contest-cover img { display: block; width: 100%; height: 100%; object-fit: cover; }
.contest-cover-copy { position: absolute; inset: 6% auto 7% 5%; width: 51%; display: flex; flex-direction: column; align-items: flex-start; color: #fff; line-height: 1.1; }
.contest-cover-brand { color: #4ee2ed; letter-spacing: .25em; font-size: 1.8cqw; font-weight: 800; margin-bottom: 2.6cqw; }
.contest-cover-name { font-size: 3.5cqw; font-weight: 850; letter-spacing: -.03em; }
.contest-cover-number { color: #f6d36c; font-size: 8cqw; font-weight: 850; margin: .5cqw 0 2cqw; }
.contest-cover-label { color: #9ed9f3; letter-spacing: .1em; font-size: 1.8cqw; margin-top: auto; }
.contest-cover-fund { font-size: 5.4cqw; margin-top: .5cqw; white-space: nowrap; }
.contest-cover-places { border-top: 1px solid #d5b86b; padding-top: 1cqw; margin-top: 1.2cqw; font-size: 2.5cqw; }
.contest-cover-start { font-size: 1.85cqw; color: #9ed9f3; margin-top: auto; padding-top: 1.4cqw; }
.contest-card-results > .contest-cover { max-width: 920px; }
#contestsList .contest-cover { width: 100%; align-self: start; }
.contest-manager-list{display:grid;gap:10px;margin-top:18px}.contest-manager-list>.btn{justify-content:space-between;gap:16px;text-align:left;white-space:normal}.contest-manager-list small{color:var(--muted);flex-shrink:0}#contestAdminControls{margin:0 0 18px}#contestCardEditor textarea[name=results],#cmsArchiveFields textarea{font-family:monospace}#contestCardEditor details{margin:20px 0}#contestCardPreview{max-width:260px;max-height:150px;object-fit:contain}#contestCardForm>label{margin-top:14px}@media(max-width:600px){.contest-manager-list>.btn{align-items:flex-start;flex-direction:column}}

/* League groups share the contest card and bracket styling. */
.contest-group-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 16px; }
.contest-group-card { min-width: 0; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); overflow: hidden; }
.contest-group-card h5 { margin: 0; padding: 12px 14px; color: var(--brand); background: var(--primary-bg); font-size: 16px; }
.contest-group-card .contest-table { table-layout: fixed; font-size: 14px; }
.contest-group-card .group-rank { width: 44px; }
.contest-group-card .group-profit { width: 112px; }
.contest-group-card .contest-table th, .contest-group-card .contest-table td { padding: 10px 12px; vertical-align: middle; }
.contest-group-card .contest-table th:first-child, .contest-group-card .contest-table td:first-child { text-align: center; }
.contest-group-card .contest-table th:last-child, .contest-group-card .contest-table td:last-child { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.contest-group-card .group-qualified { background: var(--primary-bg); }
.contest-group-card .group-qualified td:nth-child(2) { font-weight: 700; }
.archive-bracket-profit .archive-bracket-player { grid-template-columns: minmax(0, 1fr) 66px; font-variant-numeric: tabular-nums; }
.archive-bracket-profit .archive-bracket-seed { display: none; }
@media (max-width: 700px) { .contest-group-grid { grid-template-columns: minmax(0, 1fr); } }

.contest-group-single { grid-template-columns: minmax(0, 1fr); }

.contest-audience-winners { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.contest-audience-winner { display:flex; justify-content:space-between; gap:12px; padding:12px; border:1px solid var(--border); border-radius:8px; background:var(--surface); font-size:14px; }
.contest-audience-winner strong { overflow-wrap:anywhere; }
.contest-audience-winner span { white-space:nowrap; color:var(--brand); }
@media(max-width:600px) { .contest-audience-winners { grid-template-columns:minmax(0,1fr); } }

/* Explicit column widths prevent counts and ROI from collapsing. */
.contest-full-results-scroll { max-height:none; overflow-x:auto; margin-top:18px; border:1px solid var(--border); border-radius:12px; background:var(--surface); -webkit-overflow-scrolling:touch; }
.contest-full-results { table-layout:fixed; width:100%; min-width:812px; font-size:14px; line-height:1.5; }
.contest-full-results-roi { min-width:924px; }
.contest-full-results .results-col-rank { width:56px; }
.contest-full-results .results-col-name { width:260px; }
.contest-full-results .results-col-profit { width:168px; }
.contest-full-results .results-col-bets { width:112px; }
.contest-full-results .results-col-count { width:72px; }
.contest-full-results .results-col-roi { width:112px; }
.contest-full-results th, .contest-full-results td { text-align:center; padding:14px 16px; vertical-align:middle; font-variant-numeric:tabular-nums; border-bottom:1px solid var(--border); }
.contest-full-results th { height:64px; font-size:13px; font-weight:600; color:var(--text-soft); white-space:nowrap; }
.contest-full-results th small { display:block; font-size:12px; font-weight:400; margin-top:2px; }
.contest-full-results th:nth-child(2), .contest-full-results td:nth-child(2) { text-align:left; }
.contest-full-results td:nth-child(2) { overflow-wrap:break-word; font-weight:500; }
.contest-full-results td:nth-child(3) { text-align:center; white-space:nowrap; }
.contest-full-results td:not(:nth-child(2)) { white-space:nowrap; }
.contest-full-results th:nth-child(4), .contest-full-results td:nth-child(4), .contest-full-results th:nth-child(8), .contest-full-results td:nth-child(8) { border-left:1px solid var(--border); }
.contest-full-results tbody tr:last-child td { border-bottom:0; }
.contest-full-results tbody tr:not(.contest-eligibility-divider):hover { background:var(--primary-bg); }
.contest-full-results .contest-archive-prize-row { background:var(--primary-bg); }
.contest-full-results .result-positive { color:#15803d; }
.contest-full-results .result-negative { color:#dc2626; }
.contest-full-results .result-neutral { color:var(--text-soft); }
.contest-full-results .contest-eligibility-divider td { padding:18px 24px; color:var(--text-soft); background:var(--surface-alt); text-align:left; font-weight:600; white-space:normal; }
body.dark .contest-full-results .result-positive { color:#4ade80; }
body.dark .contest-full-results .result-negative { color:#f87171; }

.contest-totals{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:24px 0}.contest-total{padding:24px;border:1px solid var(--border);border-radius:var(--radius-md);background:var(--surface);min-width:0}.contest-total span,.contest-total small{display:block}.contest-total span{font-size:15px;font-weight:600;color:var(--text-soft)}.contest-total strong{display:block;font-size:clamp(26px,3vw,38px);line-height:1.25;letter-spacing:-.04em;font-variant-numeric:tabular-nums;margin:12px 0;color:var(--brand);white-space:nowrap}.contest-total small{font-size:13px;color:var(--text-soft);line-height:1.5}@media(max-width:850px){.contest-totals{grid-template-columns:1fr}.contest-total{padding:20px}.contest-total strong{font-size:32px;margin:8px 0}}@media(prefers-reduced-motion:no-preference){.contest-total{animation:contest-total-enter .35s ease both}.contest-total:nth-child(2){animation-delay:.05s}.contest-total:nth-child(3){animation-delay:.1s}@keyframes contest-total-enter{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}}

.contest-total strong>span{color:inherit;font:inherit;letter-spacing:inherit;line-height:inherit;font-variant-numeric:tabular-nums}.contest-total{position:relative;overflow:hidden}@media(prefers-reduced-motion:no-preference){.contest-totals.is-counting .contest-total:after{content:"";position:absolute;bottom:0;left:0;height:3px;width:100%;background:var(--brand);opacity:.28;transform-origin:left;animation:contest-count-line 1.45s cubic-bezier(.2,.6,.35,1) both}@keyframes contest-count-line{from{transform:scaleX(0)}to{transform:scaleX(1)}}}

/* Compact contest totals on phones. */
@media(max-width:600px){
 .contest-totals{display:block;margin:20px 0;padding:4px 16px;border:1px solid var(--border);border-radius:var(--radius-md);background:var(--surface)}
 .contest-total{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 0;border:0;border-radius:0;background:transparent;animation:none}
 .contest-total+.contest-total{border-top:1px solid var(--border)}
 .contest-total>span{font-size:14px;line-height:1.4;min-width:0}
 .contest-total strong{flex-shrink:0;font-size:22px;line-height:1.3;margin:0;letter-spacing:-.03em}
 .contest-total small{display:none}
 .contest-totals.is-counting .contest-total:after{display:none}
}

.cms-team-editor{min-width:0}.cms-team-logo-controls{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-top:6px}.cms-team-logo-controls img{object-fit:contain}.cms-team-logo-controls .btn{font-size:12px;padding:5px 7px}.cms-match-teams>.weekend-team:first-child{justify-content:flex-end}.cms-match-teams .weekend-team img{object-fit:contain;flex-shrink:0}

.an-filters{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.an-filters label,.an-link-form label{display:flex;flex-direction:column;gap:6px;font-size:14px}.an-filters input,.an-link-form input,.an-link-form select,.an-saved-link input{padding:10px;border:1px solid var(--border-strong);border-radius:6px;background:var(--surface);color:var(--text);min-width:0;width:100%;box-sizing:border-box}.an-metrics{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:12px;margin:20px 0}.an-metrics .profile-panel{margin:0}.an-metrics span{font-size:14px;color:var(--text-soft)}.an-metrics strong{display:block;font-size:30px;color:var(--brand);margin-top:10px}.an-scroll{overflow:auto;margin:16px 0 24px;border:1px solid var(--border);border-radius:8px}.an-table{border-collapse:collapse;width:100%;font-size:14px}.an-table th,.an-table td{padding:12px 16px;text-align:left;border-bottom:1px solid var(--border);white-space:nowrap}.an-table th{background:var(--surface-alt)}.an-chart{display:flex;align-items:end;gap:3px;height:160px;border-bottom:1px solid var(--border);margin-top:24px}.an-bar{height:100%;flex:1;display:flex;align-items:end;min-width:1px}.an-bar i{display:block;width:100%;background:var(--brand);border-radius:3px 3px 0 0;opacity:.8}.an-bar:hover i{opacity:1}.an-chart-axis{display:flex;justify-content:space-between;color:var(--text-soft);font-size:13px;margin:8px 0 16px}.an-link-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.an-link-form [role=status]{grid-column:1/-1}.an-saved-link{margin-bottom:12px}#anGenerated{overflow-wrap:anywhere;margin-top:12px}#analyticsPanel .editorial-editor-panel{max-width:1160px}@media(max-width:600px){.an-link-form{grid-template-columns:1fr}.an-filters label{flex:1}.an-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.an-metrics .profile-panel{padding:14px}}

/* Consent controls must not inherit text-input sizing or block labels. */
.auth-modal label.registration-consent{display:flex;align-items:flex-start;gap:10px;margin:16px 0;font-size:14px;font-weight:400;line-height:1.5;cursor:pointer}
.auth-modal .registration-consent>input[type="checkbox"]{appearance:auto;width:18px!important;height:18px!important;min-width:18px;min-height:18px;max-height:18px;flex:0 0 18px;padding:0;margin:2px 0 0;border-radius:3px;accent-color:var(--brand);cursor:pointer;box-shadow:none}
.auth-modal .registration-consent>input[type="checkbox"]:focus-visible{outline:2px solid var(--brand);outline-offset:3px;box-shadow:none}
.auth-modal .registration-consent>span{display:block;flex:1;min-width:0;overflow-wrap:anywhere}

/* Password visibility controls: same input height and a comfortable touch target. */
.auth-modal .password-field{position:relative;width:100%}
.auth-modal .password-field input{width:100%;padding-right:52px}
.auth-modal .password-toggle{position:absolute;right:2px;top:50%;transform:translateY(-50%);display:grid;place-items:center;width:44px;height:42px;padding:0;border:0;border-radius:6px;background:transparent;color:var(--text-soft);cursor:pointer}
.auth-modal .password-toggle:hover{color:var(--brand);background:var(--bg-soft,#e8f2f8)}
.auth-modal .password-toggle:focus-visible{outline:2px solid var(--brand);outline-offset:-2px}
.password-eye-slash{display:none}
.password-toggle[aria-pressed="true"] .password-eye-slash{display:block}

.cookie-banner[hidden]{display:none}
.cookie-banner{position:fixed;bottom:0;left:0;right:0;z-index:3000;background:var(--surface,#fff);color:var(--text,#0a2540);border-top:1px solid var(--line,#d6e4ee);box-shadow:0 -4px 18px #0a254014;padding:16px 24px calc(16px + env(safe-area-inset-bottom))}
.cookie-banner-inner{max-width:1240px;margin:auto;display:flex;align-items:center;gap:24px;flex-wrap:wrap}
.cookie-banner p{flex:1;min-width:240px;margin:0;font-size:14px;line-height:1.6}
.cookie-banner a{color:var(--brand,#0c6c9e);text-decoration:underline}
.cookie-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;flex-shrink:0;width:264px}
.cookie-actions .btn{display:flex;align-items:center;justify-content:center;width:100%;height:44px;min-height:44px;min-width:0;padding:0 18px;border:1px solid transparent;border-radius:8px;font-size:14px;font-weight:600;line-height:20px;text-align:center;box-sizing:border-box;transition:background-color .15s,border-color .15s,color .15s}
.cookie-actions .btn-ghost{border-color:var(--border-strong);background:var(--surface);color:var(--brand)}
.cookie-actions .btn-ghost:hover{border-color:var(--brand);background:var(--brand-soft-bg)}
.cookie-actions .btn:focus-visible{outline:2px solid var(--brand);outline-offset:3px}
#cookieStatus:empty{display:none}
#cookieStatus{flex-basis:100%;color:var(--negative,#b91c1c)}
.cookie-settings-link{border:0;padding:0;background:none;color:inherit;font:inherit;cursor:pointer;text-decoration:underline}
@media(max-width:600px){.cookie-banner{padding:14px 16px calc(14px + env(safe-area-inset-bottom))}.cookie-banner-inner{gap:12px}.cookie-banner p{min-width:0;flex-basis:100%}.cookie-actions{width:100%}.cookie-actions .btn{flex:1}}

.admin-contact-email{display:flex;flex-direction:column;gap:4px;margin-top:6px;min-width:0;font-size:14px;line-height:1.5}
.admin-contact-email a{overflow-wrap:anywhere}
.admin-contact-email span{font-size:12px;color:var(--text-soft)}
.admin-user-row>div{min-width:0}

/* Keep publication badges separate without changing established card typography. */
.editorial-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.editorial-card-heading .editorial-rubric { flex: 1; min-width: 0; margin: 0; overflow-wrap: anywhere; }
.editorial-card-heading .publication-new-badge { flex: 0 0 auto; margin: 0; line-height: 1.3; white-space: nowrap; }
/* Emblems occupy the same full-width cover area as existing article photos. */
.article-emblem-cover { width: 100%; aspect-ratio: 4 / 3; overflow: hidden; border-radius: var(--radius-sm); margin-bottom: 14px; background: #fff; flex-shrink: 0; }
.article-emblem-cover img { display: block; width: 100%; height: 100%; object-fit: contain; }
.article-emblem-cover-dark { background: #111; }
.article-emblem-cover-ag img { transform: scale(1.45); }
.distance-summary-card .review-avatar { object-fit: contain; }

/* Edge-to-edge backgrounds only for the six owner-selected interview covers. */
.article-emblem-cover-extended { position: relative; isolation: isolate; }
.article-emblem-cover-extended .article-emblem-backdrop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(18px); transform: scale(1.2); z-index: -1; }
.article-emblem-cover-extended img:not(.article-emblem-backdrop) { position: relative; }

.article-emblem-cover-expanded img:not(.article-emblem-backdrop) { object-fit: cover; }

/* The mobile drawer inherits the header background in either theme. */
.mobile-menu{background:inherit;border-top:1px solid rgba(255,255,255,.15)}
.profile-tabs::-webkit-scrollbar{height:6px}
.profile-tabs::-webkit-scrollbar-track{background:var(--surface-alt);border-radius:6px}
.profile-tabs::-webkit-scrollbar-thumb{background:var(--text-soft);border-radius:6px}
