:root {
  --green: #2f7a3d;
  --green-dark: #1e5a29;
  --blue: #1c7fb5;
  --ink: #1b2430;
  --muted: #5b6b78;
  --bg: #f6f8f7;
  --card: #ffffff;
  --border: #e2e8e4;
  --radius: 10px;
}

* { box-sizing: border-box; }
html { color-scheme: light; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.5;
}
a { color: var(--green-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* header */
.site-header {
  background: var(--green-dark);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
  flex-wrap: wrap;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 1.1rem;
  margin-right: auto;
}
.brand:hover { text-decoration: none; }
.brand-logo { width: 36px; height: 36px; }
.main-nav { display: flex; gap: 18px; flex-wrap: wrap; }
.main-nav a { color: #eafaf0; font-weight: 500; }
.main-nav a:hover { color: #fff; text-decoration: underline; }
.nav-toggle, .nav-burger { display: none; }

@media (max-width: 720px) {
  .nav-burger {
    display: block;
    margin-left: auto;
    font-size: 1.5rem;
    color: #fff;
    cursor: pointer;
    background: none;
    border: none;
    padding: 8px;
  }
  .main-nav {
    flex-basis: 100%;
    flex-direction: column;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height .2s ease;
  }
  .main-nav a { padding: 10px 0; border-top: 1px solid rgba(255,255,255,.15); }
  .nav-toggle:checked ~ .main-nav { max-height: 400px; padding-bottom: 10px; }
}

/* hero */
.hero {
  background: linear-gradient(rgba(20,50,30,.55), rgba(20,50,30,.55)), url("../img/hero-courts.jpg") center/cover no-repeat;
  color: #fff;
  padding: 64px 0;
}
.hero h1 { font-size: 2.4rem; margin: 0 0 12px; }
.hero p { font-size: 1.15rem; max-width: 640px; margin: 0 0 20px; }
.hero-contact { display: flex; gap: 18px; flex-wrap: wrap; font-size: .95rem; }
.hero-contact a { color: #fff; text-decoration: underline; }

.page-header {
  background: var(--green);
  color: #fff;
  padding: 40px 0;
}
.page-header h1 { margin: 0 0 6px; }
.page-header p { margin: 0; opacity: .9; }

section { padding: 40px 0; }
section h2 { font-size: 1.5rem; margin: 0 0 20px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.section-head h2 { margin: 0; }

/* cards / grids */
.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}
.card h3 { margin: 0 0 8px; font-size: 1.1rem; }
.card .price { font-weight: 700; color: var(--green-dark); font-size: 1.2rem; margin: 8px 0; }
.card .muted { color: var(--muted); font-size: .9rem; }

button.card {
  font: inherit;
  text-align: left;
  width: 100%;
  cursor: pointer;
  color: inherit;
  transition: box-shadow .15s ease, border-color .15s ease;
}
button.card:hover {
  border-color: var(--green);
  box-shadow: 0 2px 10px rgba(0,0,0,.06);
}

.trainer-dialog {
  border: none;
  border-radius: var(--radius);
  padding: 32px;
  max-width: 460px;
  width: 92%;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 10px 40px rgba(0,0,0,.2);
  opacity: 0;
  transform: scale(.94) translateY(10px);
  transition: opacity .2s ease, transform .2s ease;
}
.trainer-note-strong { font-size: 1.05rem; font-weight: 700; color: var(--ink); margin: 0 0 6px; }
.trainer-groups { margin: 8px 0 18px; }
.trainer-groups table { font-size: .9rem; }
.trainer-groups th, .trainer-groups td { padding: 8px 10px; }
.ball-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}
.trainer-dialog.is-open {
  opacity: 1;
  transform: scale(1) translateY(0);
}
.trainer-dialog::backdrop {
  background: rgba(15,30,20,0);
  transition: background-color .2s ease;
}
.trainer-dialog.is-open::backdrop {
  background: rgba(15,30,20,.55);
}
.trainer-dialog h3 { margin: 0 0 10px; font-size: 1.3rem; }
.trainer-dialog .badge { margin-bottom: 12px; }
#trainer-dialog-note p { margin: 0 0 4px; }
.trainer-dialog p { margin: 0 0 8px; }
.dialog-close {
  float: right;
  background: none;
  border: none;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  color: var(--muted);
  padding: 0 0 8px 8px;
}
.dialog-close:hover { color: var(--ink); }

.badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 600;
  background: #e7f3ea;
  color: var(--green-dark);
}
.badge.blue { background: #e5f2f8; color: var(--blue); }
.badge.muted { background: #eee; color: var(--muted); }

/* tables */
table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: var(--radius); overflow: hidden; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); font-size: .95rem; }
th { background: #eef4ef; font-weight: 600; }
tr:last-child td { border-bottom: none; }
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); }
.table-wrap table { border: none; border-radius: 0; }

.match-list { list-style: none; margin: 0; padding: 0; }
.match-list li {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 14px; border-bottom: 1px solid var(--border); font-size: .95rem;
}
.match-list li:last-child { border-bottom: none; }
.match-sides { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.match-sides .winner { font-weight: 700; }
.match-score { font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; }
.match-date { color: var(--muted); font-size: .85rem; white-space: nowrap; }

.group-block { margin-bottom: 32px; }
.group-block h3 { margin: 0 0 10px; }

.round-block { margin-bottom: 28px; }
.round-block h3 { margin: 0 0 10px; }

.empty { color: var(--muted); font-style: italic; padding: 16px 0; }

.content-body p { margin: 0 0 14px; }
.content-body ul { padding-left: 20px; }

.back-link { display: inline-block; margin-bottom: 16px; }

.filters { display: flex; gap: 10px; margin-bottom: 20px; flex-wrap: wrap; }
.filters a { padding: 6px 14px; border-radius: 999px; border: 1px solid var(--border); background: var(--card); color: var(--ink); font-size: .9rem; }
.filters a.active { background: var(--green-dark); color: #fff; border-color: var(--green-dark); }

/* footer */
.site-footer { background: #10281a; color: #cfe3d4; margin-top: 40px; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; padding: 32px 0 16px; flex-wrap: wrap; }
.footer-inner a { color: #cfe3d4; }
.footer-nav { display: flex; flex-direction: column; gap: 8px; }
.copyright { text-align: center; color: #7f9989; font-size: .8rem; padding-bottom: 20px; margin: 0; }

@media (max-width: 600px) {
  .hero { padding: 44px 0; }
  .hero h1 { font-size: 1.8rem; }
  section { padding: 28px 0; }
}
