/* Coach console: dark 240px sidebar (CoachNav) and a dense main column. */

.coach { background: var(--canvas-coach); min-height: 100vh; display: flex; align-items: stretch; }

.coach-nav {
  flex: 0 0 240px; min-height: 100vh; position: sticky; top: 0; align-self: flex-start;
  background: var(--nav); color: #FFFFFF;
  display: flex; flex-direction: column; gap: 24px; padding: 20px 12px;
}
.coach-nav .brand { padding: 0 8px; height: 40px; }
.coach-nav__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.coach-nav__link {
  display: flex; align-items: center; gap: 10px; height: 44px; padding: 0 12px; border-radius: 10px;
  color: var(--nav-text); font-size: 14.5px; font-weight: 500; text-decoration: none;
}
.coach-nav__link:hover { background: var(--nav-active); color: #FFFFFF; }
.coach-nav__link[aria-current="page"] { background: var(--nav-active); color: #FFFFFF; font-weight: 600; }
.coach-nav__link[aria-disabled="true"] { opacity: 0.45; pointer-events: none; }
.coach-nav__label { flex: 1; }
.coach-nav__badge {
  min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px;
  background: var(--badge); color: var(--ink); font-size: 12px; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.coach-nav__me { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 12px 8px; border-top: 1px solid var(--nav-line); }
.coach-nav__avatar {
  width: 36px; height: 36px; border-radius: 18px; background: #3A424A; flex: none;
  display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 600;
}
.coach-nav__who { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.coach-nav__name { font-size: 14px; font-weight: 600; }
.coach-nav__meta { font-size: 12.5px; color: var(--nav-muted); }
.coach-nav__signout { background: none; border: none; color: var(--nav-muted); font: 500 12.5px var(--font); cursor: pointer; padding: 0; }
.coach-nav__signout:hover { color: #FFFFFF; }

.coach-main {
  flex: 1 1 560px; min-width: 0; max-width: 1200px;
  padding: 28px 32px 40px; display: flex; flex-direction: column; gap: 24px;
}
.coach-main .button { height: 44px; font-size: 14.5px; border-radius: 10px; }
.coach-main .button--small { height: 36px; font-size: 13.5px; }
.coach-main .input { height: 44px; font-size: 14.5px; border-radius: 10px; border-color: var(--field-line); }

.page-head { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; justify-content: space-between; }
.page-head__titles { display: flex; flex-direction: column; gap: 4px; }
.page-head__date { font-size: 13.5px; color: var(--ink-2); font-weight: 500; }
.page-head h1 { font-size: 30px; line-height: 36px; }
.page-head__actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-l); padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; }
.stat__label { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.stat__value { font: 600 30px/1.1 var(--font-display); }
.stat__aside { font: 500 14px var(--font); color: var(--ink-2); }
.stat--warn { background: var(--warn-soft); border-color: var(--warn-line); }
.stat--warn .stat__label { color: var(--warn); font-weight: 600; }
.stat--warn .stat__value { color: var(--warn); }

.columns { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.columns__main { flex: 2 1 480px; min-width: 0; }
.columns__side { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }

.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 12.5px; font-weight: 600; color: var(--ink-2); padding: 10px 20px; border-bottom: 1px solid var(--line); }
.table td { padding: 12px 20px; border-bottom: 1px solid var(--line-soft); }
.table tr:last-child td { border-bottom: none; }
.table a { font-weight: 600; text-decoration: none; }

.time { width: 52px; font-size: 14px; font-weight: 600; flex: none; }
.tally { display: flex; justify-content: space-between; font-size: 14px; }
.tally--warn { color: var(--warn); }

.settings-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }

.invite-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.invite-form .field { flex: 1 1 200px; }

@media (max-width: 900px) {
  .coach { flex-direction: column; }
  .coach-nav { position: static; min-height: auto; flex-basis: auto; width: 100%; gap: 12px; }
  .coach-nav__list { flex-direction: row; overflow-x: auto; }
  .coach-nav__link { white-space: nowrap; }
  .coach-nav__me { margin-top: 0; }
  .coach-main { padding: 20px 16px 32px; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

.settings-grid .card > .button, .settings-grid .card > form { align-self: flex-start; }
