/* Training panels: intro | table (or age cards) | photo */
.training-panel {
  display: grid;
  grid-template-columns: minmax(280px, 1fr) 1.6fr minmax(240px, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: center;
  scroll-margin-top: calc(var(--header-height) + 1rem);
}

.training-panel:hover {
  transform: none; /* panels are containers, not clickable cards */
  box-shadow: var(--shadow-small);
}

.training-panel__intro h2 {
  margin-bottom: 0.5rem;
}

.training-panel__intro > p:not(.section-eyebrow) {
  color: var(--color-muted);
  font-size: var(--text-small);
}

.training-panel__benefits {
  grid-template-columns: 1fr 1fr;
  margin-block: 1.1rem 1.4rem;
}

.info-card__icon--green {
  background: #e6f2ea;
  color: var(--accent-kids);
}

.training-panel__photo img {
  width: 100%;
  height: 100%;
  min-height: 240px;
  max-height: 360px;
  object-fit: cover;
  border-radius: var(--radius-small);
}

/* Schedule table */
.schedule-wrap {
  overflow-x: auto;
  border-radius: var(--radius-small);
  border: 1px solid var(--color-border);
}

.schedule th,
.schedule td {
  padding: 0.8rem 0.7rem;
  text-align: left;
  font-size: 0.83rem;
}

.schedule thead th {
  background: var(--color-navy);
  color: var(--color-white);
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: var(--text-tiny);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.schedule tbody tr:nth-child(even) {
  background: var(--color-surface);
}

.schedule tbody td:first-child {
  font-weight: 600;
  color: var(--text-heading);
}

.schedule tbody td:last-child {
  color: var(--color-primary);
  font-weight: 600;
}

/* Kids age cards */
.age-cards {
  display: grid;
  gap: 1rem;
}

.age-card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-small);
  padding: 1.1rem 1.25rem;
  background: var(--color-surface);
}

.age-card b {
  display: block;
  font-family: var(--font-heading);
  text-transform: uppercase;
  color: var(--accent-kids);
}

.age-card span {
  display: block;
  font-weight: 600;
  font-size: var(--text-small);
  color: var(--text-heading);
  margin-bottom: 0.25rem;
}

.age-card p {
  font-size: var(--text-tiny);
  color: var(--color-muted);
}

/* Coach cards */
.coach-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

.coach-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.35rem;
}

.coach-card__photo {
  width: min(100%, 208px);
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-small);
  overflow: hidden;
  background: var(--color-surface);
  margin-bottom: 0.75rem;
}

.coach-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.coach-card__role {
  color: var(--color-primary) !important;
  font-weight: 600;
  font-size: var(--text-tiny);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.coach-card__facts {
  display: grid;
  gap: 0.2rem;
  font-size: var(--text-small);
  color: var(--color-muted);
  margin-bottom: 0.5rem;
}

@media (max-width: 1199px) {
  .training-panel {
    grid-template-columns: 1fr 1.5fr;
  }

  .training-panel__photo {
    grid-column: 1 / -1;
  }

  .training-panel__photo img {
    min-height: 0;
    max-height: 280px;
  }
}

/* Schedule table becomes stacked schedule cards on mobile */
@media (max-width: 767px) {
  .training-panel {
    grid-template-columns: 1fr;
  }

  .schedule-wrap {
    border: none;
    overflow: visible;
  }

  .schedule thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }

  .schedule,
  .schedule tbody,
  .schedule tr,
  .schedule td {
    display: block;
    width: 100%;
  }

  .schedule tr {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-small);
    margin-bottom: 0.75rem;
    padding: 0.5rem 0;
    background: var(--surface-card);
    box-shadow: var(--shadow-small);
  }

  .schedule tbody tr:nth-child(even) {
    background: var(--surface-card);
  }

  .schedule td {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.45rem 1rem;
    white-space: normal;
  }

  .schedule td::before {
    content: attr(data-label);
    font-family: var(--font-heading);
    font-size: var(--text-tiny);
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-muted);
  }

  .training-panel__benefits {
    grid-template-columns: 1fr;
  }

  .training-panel .btn {
    width: 100%;
  }
}

/* Temporarily hide coaches section */
#coaches {
  display: none;
}

/* ============================================================
   Dark theme overrides for training page
   ============================================================ */
html[data-theme="dark"] .info-card__icon--green {
  background: rgba(29, 107, 60, 0.2);
}

html[data-theme="dark"] .schedule-wrap {
  border-color: rgba(255, 255, 255, 0.06);
}

html[data-theme="dark"] .schedule thead th {
  background: linear-gradient(135deg, #FF5A47, #FF7A3D);
  color: #ffffff;
}

html[data-theme="dark"] .schedule tbody tr:nth-child(even) {
  background: #1A1A20;
}

html[data-theme="dark"] .age-card {
  background: #1A1A20;
  border-color: rgba(255, 255, 255, 0.06);
}
