:root {
  --bg: #0b1220;
  --bg2: #111827;
  --text: #e5e7eb;
  --muted: #9ca3af;
  --card: rgba(17, 24, 39, 0.86);
  --line: #334155;
  --badge-bg: #14532d;
  --badge-text: #dcfce7;
  --btn-bg: #38bdf8;
  --btn-text: #082f49;
  --chip-bg: #0f172a;
}

body[data-theme='light'] {
  --bg: #f1f5f9;
  --bg2: #e2e8f0;
  --text: #0f172a;
  --muted: #475569;
  --card: rgba(255, 255, 255, 0.82);
  --line: #cbd5e1;
  --badge-bg: #bbf7d0;
  --badge-text: #14532d;
  --btn-bg: #0ea5e9;
  --btn-text: #082f49;
  --chip-bg: #f8fafc;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: radial-gradient(circle at 20% 20%, #14532d22, transparent 35%),
    radial-gradient(circle at 80% 10%, #0ea5e922, transparent 30%),
    linear-gradient(125deg, var(--bg), var(--bg2));
  color: var(--text);
  min-height: 100vh;
  position: relative;
}

.bg-overlay {
  pointer-events: none;
  position: fixed;
  inset: 0;
  background-image: linear-gradient(transparent 95%, #ffffff11 96%),
    linear-gradient(90deg, transparent 95%, #ffffff11 96%);
  background-size: 64px 64px;
  opacity: 0.2;
}

header,
footer,
main {
  position: relative;
  z-index: 1;
}

header,
footer {
  max-width: 1000px;
  margin: 0 auto;
  padding: 1rem;
}

main {
  max-width: 1000px;
  margin: 0 auto;
  padding: 1rem;
}

.header-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.lang-select-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--muted);
}

select,
.theme-btn {
  border: 1px solid var(--line);
  background: var(--chip-bg);
  color: var(--text);
  border-radius: 10px;
  padding: 0.35rem 0.6rem;
  font: inherit;
}

h1,
h2,
h3 {
  margin: 0 0 0.75rem;
}

.policy,
.meta,
small {
  color: var(--muted);
}

.card,
.match {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  backdrop-filter: blur(8px);
}

.card {
  padding: 1rem;
}

.match {
  padding: 1rem;
  margin-top: 0.75rem;
}

.match-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.badge {
  padding: 0.2rem 0.65rem;
  border-radius: 999px;
  background: var(--badge-bg);
  color: var(--badge-text);
  font-size: 0.85rem;
  font-weight: 700;
}

.prob-grid {
  display: grid;
  gap: 0.6rem;
  margin: 0.75rem 0;
}

.prob-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem;
  background: var(--chip-bg);
}

.prob-top {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.35rem;
}

.prob-track {
  height: 8px;
  background: #00000022;
  border-radius: 999px;
  overflow: hidden;
}

.prob-fill {
  height: 100%;
  border-radius: 999px;
}

.prob-item.home .prob-fill {
  background: #22c55e;
}

.prob-item.draw .prob-fill {
  background: #f59e0b;
}

.prob-item.away .prob-fill {
  background: #ef4444;
}

button.secondary,
.tab-btn {
  border: none;
  border-radius: 10px;
  padding: 0.45rem 0.75rem;
  font: inherit;
  cursor: pointer;
}

button.secondary {
  background: var(--btn-bg);
  color: var(--btn-text);
  font-weight: 700;
}

.detail {
  margin-top: 0.75rem;
  border-top: 1px dashed var(--line);
  padding-top: 0.75rem;
}

.tabs {
  display: flex;
  gap: 0.45rem;
  margin-bottom: 0.6rem;
}

.tab-btn {
  background: #64748b33;
  color: var(--text);
}

.tab-btn.active {
  background: #22c55e33;
  border: 1px solid #22c55e77;
}

.tab-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip {
  background: var(--chip-bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
}


.tab-panel.column {
  flex-direction: column;
  align-items: stretch;
}

.lineup-input {
  min-height: 64px;
  border: 1px solid var(--line);
  background: var(--chip-bg);
  color: var(--text);
  border-radius: 10px;
  padding: 0.5rem;
  font: inherit;
}

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

.log-item {
  background: var(--chip-bg);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.5rem 0.65rem;
  font-size: 0.92rem;
}


.vote-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}
