:root {
  --bg: #eef1f5;
  --surface: #ffffff;
  --ink: #0b1f3a;
  --muted: #5b6b7c;
  --line: #d7dde5;
  --accent: #e85a1b;
  --accent-soft: rgba(232, 90, 27, 0.1);
  --ok: #0b6bcb;
  --radius: 12px;
  --shadow: 0 10px 30px rgba(11, 31, 58, 0.06);
  --font: "Geologica", "Segoe UI", system-ui, sans-serif;
}

/* Global −5%: all rem/em type scales from a smaller root. */
html {
  font-size: 95%;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(232, 90, 27, 0.12), transparent 55%),
    radial-gradient(900px 400px at 100% 0%, rgba(11, 31, 58, 0.08), transparent 50%),
    var(--bg);
}

.pub {
  width: 100%;
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
  padding: 1.5rem 1.25rem 3rem;
  box-sizing: border-box;
}

/* iframe on eskase.gr (?embed=1): no site chrome, fill the frame */
body.is-embed {
  min-height: 0;
  background: var(--bg);
}
.pub.pub--embed {
  max-width: none;
  padding: 0.85rem 0.85rem 1.25rem;
}
.pub.pub--embed .pub__header {
  margin-bottom: 0.75rem;
}

/* Desktop front pages + embeds: almost full viewport width */
@media (min-width: 801px) {
  .pub,
  .pub.eskase-embed {
    width: 100%;
    max-width: min(95vw, 100%);
    margin-left: auto;
    margin-right: auto;
  }
}

.pub__header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem 1rem;
  margin-bottom: 1rem;
}
.pub__brand {
  display: flex;
  align-items: center;
  gap: 0.95rem;
  min-width: 0;
  flex: 1 1 16rem;
}
.pub__logo {
  display: block;
  height: 56px;
  width: auto;
  max-width: 180px;
  object-fit: contain;
  flex: 0 0 auto;
}
.pub__eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
}
.pub__header h1 {
  margin: 0;
  font-size: clamp(1.5rem, 3vw, 1.9rem);
  letter-spacing: -0.02em;
}
.pub__lead {
  margin: 0.4rem 0 0;
  color: var(--muted);
  max-width: 36rem;
}

.pub-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 1rem 0 1.1rem;
}
.pub-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 650;
}
.pub-nav a:hover { border-color: var(--accent); color: var(--accent); }
.pub-nav a.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  justify-content: space-between;
  align-items: center;
  padding: 0.85rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.toolbar__day,
.toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
}
.toolbar__label {
  margin-left: 0.25rem;
  font-weight: 700;
}

.btn {
  appearance: none;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  border-radius: 8px;
  min-height: 36px;
  padding: 0 0.85rem;
  font: inherit;
  font-weight: 650;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn:hover { border-color: #9aa8b8; }
.btn.is-active {
  border-color: var(--ink);
  background: var(--ink);
  color: #fff;
}
.btn--site {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 0 1.05rem;
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
  font-weight: 750;
  letter-spacing: 0.01em;
  box-shadow: 0 8px 18px rgba(232, 90, 27, 0.22);
}
.btn--site:hover {
  border-color: #cf4c12;
  background: #cf4c12;
  color: #fff;
}

input[type="date"],
select {
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 0.55rem;
  font: inherit;
  background: #fff;
  color: var(--ink);
}

.filters-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
.filters-toggle__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.35rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
}
.filters-toggle__count[hidden] {
  display: none !important;
}
.filters-toggle.is-active .filters-toggle__count {
  background: #fff;
  color: var(--ink);
}

.filters {
  margin: 0.75rem 0 0.35rem;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.filters[hidden] {
  display: none !important;
}
.filters__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(11.5rem, 1fr));
  gap: 0.75rem;
}
.filters__field {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.filters__field label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.filters__field select {
  width: 100%;
}
.filters__actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.85rem;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0.9rem 0 0.65rem;
}
.chips--categories {
  margin-top: 0.35rem;
}
.chips--categories[hidden] {
  display: none !important;
}
.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 3.1rem;
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
}
.chip--category {
  min-width: 0;
  max-width: 100%;
  text-align: center;
  line-height: 1.25;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.is-active {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

/* Embed inside eskase.gr */
.eskase-embed {
  margin: 0.5rem 0 1rem;
}
.eskase-embed .toolbar {
  box-shadow: none;
}
.eskase-embed .chip {
  appearance: none;
}

.status {
  min-height: 1.25rem;
  margin-bottom: 0.55rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--muted);
}
.status.is-error { color: #b42318; }

/* Full-viewport loader while embed day data loads (also inlined by embed.js). */
.eskase-loader {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  background: rgba(248, 250, 252, 0.72);
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}
.eskase-loader[hidden] {
  display: none !important;
}
.eskase-loader__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  min-width: 9.5rem;
  padding: 1.25rem 1.4rem;
  border-radius: 16px;
  background: #fff;
  border: 1px solid rgba(11, 31, 58, 0.1);
  box-shadow: 0 18px 40px rgba(11, 31, 58, 0.14);
}
.eskase-loader__spinner {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 50%;
  border: 3px solid rgba(11, 31, 58, 0.12);
  border-top-color: #e85a1b;
  animation: eskase-spin 0.7s linear infinite;
}
.eskase-loader__text {
  margin: 0;
  color: #0b1f3a;
  font: 700 0.92rem/1.2 Segoe UI, system-ui, sans-serif;
  letter-spacing: 0.02em;
}
@keyframes eskase-spin {
  to { transform: rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .eskase-loader__spinner {
    animation: none;
    border-top-color: #0b1f3a;
  }
}

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: auto;
}

.grid {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}
.grid th,
.grid td {
  padding: 0.7rem 0.65rem;
  border-bottom: 1px solid #eef1f4;
  text-align: left;
  vertical-align: middle;
}
.col-referee_a_name,
.col-referee_b_name,
.col-official_hf_name,
.col-official_table_name,
.col-official_24_name {
  white-space: normal;
  overflow: visible;
  word-break: break-word;
  min-width: 8.5rem;
}
.ref-fee {
  display: inline-block;
  margin-left: 0.15rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  background: #e8eef6;
  color: var(--ink);
  font-weight: 800;
  font-size: 0.88em;
  letter-spacing: 0.01em;
  white-space: nowrap;
  vertical-align: baseline;
}
.ref-fee--total {
  background: #cfe0f5;
  box-shadow: inset 0 0 0 1px rgba(15, 23, 42, 0.08);
}
.grid th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #f7f9fb;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.grid th.is-sortable {
  padding: 0;
}
.th-sort {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  min-height: 2.4rem;
  padding: 0.55rem 0.65rem;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  text-align: left;
}
.th-sort:hover { color: var(--accent); }
.th-sort__label { min-width: 0; }
.th-sort__icon {
  flex: 0 0 auto;
  width: 0.55rem;
  height: 0.55rem;
  opacity: 0.35;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat;
  position: relative;
}
.th-sort__icon::before,
.th-sort__icon::after {
  content: "";
  position: absolute;
  left: 50%;
  width: 0;
  height: 0;
  border-left: 0.28rem solid transparent;
  border-right: 0.28rem solid transparent;
  transform: translateX(-50%);
}
.th-sort__icon::before {
  top: -0.12rem;
  border-bottom: 0.28rem solid currentColor;
}
.th-sort__icon::after {
  bottom: -0.12rem;
  border-top: 0.28rem solid currentColor;
}
.grid th.is-sorted .th-sort { color: var(--accent); }
.grid th.is-sorted .th-sort__icon { opacity: 1; }
.grid th.is-sorted--asc .th-sort__icon::after { opacity: 0.25; }
.grid th.is-sorted--desc .th-sort__icon::before { opacity: 0.25; }
.grid td { font-size: 0.95rem; }
.grid .time {
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  white-space: nowrap;
}
.score-live {
  display: flex;
  align-items: center;
  margin-bottom: 0.2rem;
}
.grid .score {
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  white-space: nowrap;
  font-size: 1.2rem;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.grid td.col-score {
  white-space: nowrap;
  vertical-align: middle;
}
.grid .muted { color: var(--muted); }
.grid tr.is-played td { color: var(--ink); }

/* Desktop: one row per match, thin green border, clear gap between games. */
@media (min-width: 801px) {
  .grid--matches {
    border-collapse: separate;
    border-spacing: 0 0.55rem;
  }
  .grid--matches tbody tr.match-row--periods {
    display: none;
  }
  .grid--matches tbody tr.match-row--main.has-score {
    outline: 1px solid #1f9d55;
    outline-offset: 0;
  }
  .grid--matches .col-score {
    width: 11rem;
    min-width: 9.5rem;
    white-space: normal;
    vertical-align: middle;
  }
  .grid--matches .periods-inline {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.3rem;
    margin-top: 0.35rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    max-width: 100%;
    padding-bottom: 0.1rem;
  }
  .grid--matches .periods-inline .period-chip {
    flex: 0 0 auto;
    min-height: 1.45rem;
    font-size: 0.75rem;
    padding: 0.1rem 0.45rem 0.1rem 0.25rem;
  }
}
.periods-inline {
  display: none;
}

.periods-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.35rem 0.15rem;
}
.periods-kicker {
  flex: 0 0 auto;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}
.periods-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}
.period-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 1.7rem;
  padding: 0.15rem 0.55rem 0.15rem 0.3rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f7faf8;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--ink);
  white-space: nowrap;
}
.period-chip__n {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.15rem;
  height: 1.15rem;
  border-radius: 999px;
  background: rgba(31, 157, 85, 0.12);
  color: #167a42;
  font-size: 0.68rem;
  font-weight: 800;
}

.grid tr.is-postponed td,
.grid tr.is-cancelled td { color: var(--muted); }
.grid tr.is-postponed {
  background: rgba(180, 35, 24, 0.06);
}
.grid tr.is-postponed td {
  background: rgba(180, 35, 24, 0.06);
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 1.5rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  background: #eef2f6;
  color: var(--muted);
}
.badge--played { background: #e7f2fb; color: var(--ok); }
.badge--scheduled { background: var(--accent-soft); color: var(--accent); }
.badge--postponed {
  background: rgba(180, 35, 24, 0.12);
  color: #b42318;
}
.badge--cancelled { background: #f3f4f6; color: var(--muted); }

.team-name {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
  max-width: 100%;
  vertical-align: middle;
}
.team-name__logo {
  width: 1.35rem;
  height: 1.35rem;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 4px;
  background: #f4f7fa;
}
.team-name__text {
  min-width: 0;
  overflow-wrap: anywhere;
}

/* Live indicator (basket.gr-style pulsing red dot + Live). */
.live-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: #ff0000;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
}
.live-badge__dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff0000;
  box-shadow: 0 0 0 0 rgba(255, 0, 0, 0.7);
  transform: scale(1);
  animation: live-pulse 2s ease infinite;
  flex-shrink: 0;
}
@keyframes live-pulse {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(255, 0, 0, 0.7);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 10px rgba(255, 0, 0, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(255, 0, 0, 0);
  }
}
@media (prefers-reduced-motion: reduce) {
  .live-badge__dot {
    animation: none;
  }
}

.crew-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
}
.crew-btn {
  appearance: none;
  width: 100%;
  min-height: 34px;
  padding: 0 0.55rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
}
.crew-btn:hover {
  border-color: var(--ink);
}
.crew-btn.is-empty {
  color: var(--muted);
  border-style: dashed;
}
.grid--matches .col-crew {
  width: 11.5rem;
  min-width: 10.5rem;
}
.grid--matches .col-time {
  width: 4.5rem;
}
.grid--matches .col-score {
  width: 5.5rem;
}
.grid--matches .col-status_label {
  width: 9rem;
}

.crew-pop {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.crew-pop[hidden] {
  display: none !important;
}
.crew-pop__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(11, 31, 58, 0.45);
}
.crew-pop__dialog {
  position: relative;
  z-index: 1;
  width: min(22rem, 100%);
  max-height: min(70vh, 28rem);
  overflow: auto;
  padding: 1rem 1rem 0.9rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 18px 48px rgba(11, 31, 58, 0.22);
}
.crew-pop__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}
.crew-pop__title {
  margin: 0;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}
.crew-pop__x {
  appearance: none;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  cursor: pointer;
}
.crew-pop__list {
  list-style: none;
  margin: 0 0 0.85rem;
  padding: 0;
}
.crew-pop__list li {
  padding: 0.65rem 0.15rem;
  border-bottom: 1px solid #eef1f4;
  font-weight: 650;
}
.crew-pop__list li:last-child {
  border-bottom: 0;
}
.crew-pop__list li.crew-pop__total {
  border-bottom: 0 !important;
  padding-top: 0.15rem !important;
  color: #c62828 !important;
  font-size: 0.85em !important;
  font-weight: 700 !important;
}
.crew-pop__empty {
  color: var(--muted);
  font-weight: 500 !important;
}
.crew-pop__close {
  width: 100%;
}
body.crew-pop-open {
  overflow: hidden;
}

.empty {
  padding: 2.5rem 1.25rem;
  text-align: center;
  color: var(--muted);
}

.pub-absences {
  margin: 0 0 1rem;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: grid;
  gap: 0.85rem;
}
.pub-absences[hidden] {
  display: none !important;
}
.pub-absences__title {
  margin: 0 0 0.4rem;
  font-size: 1.12rem;
  font-weight: 700;
  color: #c62828;
}
.pub-absences__total {
  font-weight: 700;
  color: #c62828;
}
/* Higher specificity so WP theme ul/li bullets don't win inside the embed. */
.pub.eskase-embed .pub-absences__list,
.pub-absences__list {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-wrap: wrap;
  gap: 0.2rem 0;
  row-gap: 0.35rem;
}
.pub.eskase-embed .pub-absences__list li,
.pub-absences__list li {
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 0.92rem;
  font-weight: 650;
  line-height: 1.35;
}
.pub.eskase-embed .pub-absences__list li::before,
.pub-absences__list li::before {
  content: none !important;
  display: none !important;
}
.pub.eskase-embed .pub-absences__list li:not(:last-child)::after,
.pub-absences__list li:not(:last-child)::after {
  content: ",";
  margin-right: 0.45rem;
  font-weight: 650;
}
.pub-absences__note {
  color: var(--muted);
  font-weight: 500;
}

.pub__foot {
  margin-top: 1.25rem;
  font-size: 0.82rem;
  color: var(--muted);
}
.pub__foot a { color: var(--ink); font-weight: 650; }
.pub__foot-site {
  color: var(--accent) !important;
}

@media (max-width: 800px) {
  .pub { padding: 0.85rem 0.7rem 2.25rem; }
  .pub__header {
    align-items: stretch;
  }
  .pub__brand {
    align-items: flex-start;
    gap: 0.75rem;
  }
  .pub__logo {
    height: 44px;
    max-width: 140px;
  }
  .pub__header h1 { font-size: 1.4rem; }
  .btn--site {
    width: 100%;
    min-height: 46px;
  }

  .pub-nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin: 0.85rem -0.15rem 1rem;
    padding: 0 0.15rem 0.15rem;
  }
  .pub-nav::-webkit-scrollbar { display: none; }
  .pub-nav a {
    flex: 0 0 auto;
    min-height: 40px;
  }

  .toolbar {
    padding: 0.75rem;
  }
  .toolbar__day,
  .toolbar__actions {
    width: 100%;
  }
  .toolbar__day .btn,
  .toolbar__actions .btn {
    min-height: 44px;
  }
  .toolbar__day .btn {
    min-width: 44px;
    padding: 0;
  }
  .toolbar__actions .filters-toggle {
    width: 100%;
    justify-content: center;
  }
  .toolbar__day input[type="date"] {
    flex: 1;
    min-width: 0;
    min-height: 44px;
    font-size: 16px;
  }
  .toolbar__label {
    display: block;
    width: 100%;
    margin: 0.2rem 0 0;
    font-size: 0.88rem;
  }
  .filters__field select {
    min-height: 44px;
    font-size: 16px;
  }

  .chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    margin: 0.75rem -0.15rem 0.55rem;
    padding: 0 0.15rem 0.2rem;
  }
  .chips::-webkit-scrollbar { display: none; }
  .chip {
    flex: 0 0 auto;
    min-height: 36px;
  }

  .table-wrap {
    background: transparent;
    border: 0;
    box-shadow: none;
    overflow: visible;
  }

  .grid {
    min-width: 0;
    display: block;
  }
  .grid thead {
    display: none;
  }
  .grid tbody {
    display: block;
  }
  .grid tbody tr {
    display: grid;
    grid-template-columns: 4.5rem 1fr;
    gap: 0.35rem 0.75rem;
    margin: 0 0 0.7rem;
    padding: 0.85rem;
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
  }
  .grid--matches tbody tr.match-row--main {
    margin: 0 0 0.85rem;
    padding: 0.95rem 0.9rem 0.85rem;
  }
  /* Mobile: periods live under the score; hide the extra periods row. */
  .grid--matches tbody tr.match-row--periods {
    display: none !important;
  }
  .grid--matches .periods-inline {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.35rem;
    margin-top: 0.45rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    max-width: 100%;
    padding-bottom: 0.15rem;
  }
  .grid--matches .periods-inline .period-chip {
    flex: 0 0 auto;
    min-height: 1.85rem;
    font-size: 0.88rem;
    padding: 0.15rem 0.5rem 0.15rem 0.28rem;
  }
  .grid tbody tr.match-row--main.has-score {
    outline: none;
    border: 1px solid #1f9d55;
    box-shadow: none;
  }
  /* No leftover accent line beside the time */
  .grid tbody tr.match-row--main.has-score td:first-child {
    box-shadow: none;
  }
  .grid tbody tr.is-postponed {
    background: rgba(180, 35, 24, 0.07);
    border-color: rgba(180, 35, 24, 0.18);
  }
  .grid tbody tr.is-postponed td {
    background: transparent;
  }
  .grid tbody td {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    border: 0;
    padding: 0;
    min-width: 0;
    font-size: 0.95rem;
  }
  .grid tbody td::before {
    content: attr(data-label);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted);
  }
  .grid tbody td.time {
    grid-column: 1;
    grid-row: 1;
    font-size: 1.05rem;
  }
  .grid:not(.grid--matches) tbody td:nth-child(2) {
    grid-column: 2;
    grid-row: 1;
    font-weight: 650;
  }
  .grid:not(.grid--matches) tbody td:nth-child(n+3) {
    grid-column: 1 / -1;
  }

  /* Matches cards: score + periods together; status last */
  .grid--matches tbody tr.match-row--main {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "time venue"
      "home home"
      "away away"
      "comp comp"
      "score score"
      "crew crew"
      "status status";
    gap: 0.5rem 0.75rem;
  }
  .grid--matches tbody td.col-time {
    grid-area: time;
    font-size: 1.2rem;
    font-weight: 800;
  }
  .grid--matches tbody td.col-time::before {
    display: none;
  }
  .grid--matches tbody td.col-venue_name {
    grid-area: venue;
    align-items: flex-end;
    text-align: right;
    font-weight: 650;
  }
  .grid--matches tbody td.col-venue_name::before {
    text-align: right;
  }
  .grid--matches tbody td.col-home_label {
    grid-area: home;
    font-size: 1.05rem;
    font-weight: 750;
  }
  .grid--matches tbody td.col-away_label {
    grid-area: away;
    font-size: 1.02rem;
    font-weight: 700;
  }
  .grid--matches tbody td.col-competition_name {
    grid-area: comp;
    color: var(--muted);
    font-size: 0.92rem;
  }
  .grid--matches tbody td.col-score {
    grid-area: score;
    white-space: normal;
    padding: 0.55rem 0.65rem;
    border-radius: 10px;
    background: #f4f7fb;
    gap: 0.2rem;
  }
  .grid--matches tbody td.col-score .score {
    font-size: 1.65rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--ink);
  }
  .grid--matches tbody td.col-score::before {
    margin-bottom: 0.1rem;
  }
  .grid--matches tbody td.col-crew {
    grid-area: crew;
    margin-top: 0.15rem;
  }
  .grid--matches tbody td.col-crew::before {
    display: none;
  }
  .grid--matches tbody td.col-status_label {
    grid-area: status;
    margin-top: 0.15rem;
    padding-top: 0.65rem;
    border-top: 1px solid var(--line);
    align-items: flex-start;
  }
  .grid--matches tbody td.col-status_label .badge {
    min-height: 1.75rem;
    padding: 0 0.7rem;
    font-size: 0.78rem;
  }
  .grid--matches tbody td.col-status_label .live-badge {
    font-size: 0.82rem;
    min-height: 1.75rem;
  }
  .grid--matches tbody td.col-status_label .live-badge__dot {
    width: 6px;
    height: 6px;
  }
  .grid--matches .crew-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.45rem;
  }
  .grid--matches .crew-btn {
    width: 100%;
    min-height: 44px;
    font-size: 0.8rem;
  }

  .empty {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius);
  }
}

/* ---- Βαθμολογία (ΕΟΚ standings) ---- */
.standings-toolbar .standings-updated {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
}
.standings-groups {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  margin-top: 0.85rem;
}
.standings-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.standings-card h2 {
  margin: 0;
  padding: 0.85rem 1rem;
  font-size: 1rem;
  font-weight: 750;
  border-bottom: 1px solid var(--line);
  background: #f7f9fb;
}
.standings-table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.standings-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.standings-table th,
.standings-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid var(--line);
  text-align: center;
  white-space: nowrap;
}
.standings-table th {
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--muted);
  font-weight: 700;
  background: #fafbfc;
}
.standings-table td.standings-team,
.standings-table th:nth-child(2) {
  text-align: left;
  white-space: normal;
  min-width: 10rem;
}
.standings-table td.standings-rank {
  font-weight: 750;
  color: var(--muted);
  width: 2.5rem;
}
.standings-table td.standings-pts {
  font-weight: 800;
  color: var(--ink);
}
.standings-table tbody tr:last-child td {
  border-bottom: 0;
}
.standings-table tbody tr:nth-child(even) {
  background: rgba(0, 0, 0, 0.015);
}
.pub__foot-meta {
  display: block;
  margin-top: 0.35rem;
}
@media (max-width: 800px) {
  .standings-card h2 {
    font-size: 0.92rem;
    padding: 0.75rem 0.85rem;
  }
  .standings-table {
    font-size: 0.82rem;
  }
  .standings-table th,
  .standings-table td {
    padding: 0.45rem 0.5rem;
  }
}
