:root {
  color-scheme: light;
  --canvas: #f2f4f6;
  --surface: #fff;
  --surface-soft: #f1f3f5;
  --ink: #1c242d;
  --muted: #4d5b68;
  --line: #d8dee4;
  --control-line: #818e9b;
  --focus: #21588a;
  --gold: #ffd400;
  --gold-line: #a37c00;
  --gold-ink: #151515;
}

* { box-sizing: border-box; }
.gruntr-owner [hidden] { display: none !important; }
.gruntr-owner {
  background: var(--canvas);
  color: var(--ink);
  font: 16px/1.5 system-ui, sans-serif;
  margin: 0;
  min-width: 0;
}
.gruntr-owner a { color: var(--focus); }
.gruntr-owner button, .gruntr-owner input, .gruntr-owner select { font: inherit; }
.gruntr-owner :focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.gruntr-owner h1, .gruntr-owner h2, .gruntr-owner h3 { line-height: 1.2; margin: 0; }
.gruntr-owner h1 { font-size: clamp(1.6rem, 4vw, 2.15rem); }
.gruntr-owner h2 { font-size: 1.2rem; }
.gruntr-owner h3 { font-size: 1.05rem; }
.owner-skip { position: absolute; top: 12px; left: -999px; background: var(--surface); z-index: 3; padding: 10px; }
.owner-skip:focus { left: 12px; }
.owner-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px max(18px, calc((100% - 1160px) / 2));
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.owner-header .owner-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-size: 1.12rem;
  font-weight: 750;
}
.owner-brand img { flex: none; border-radius: 10px; }
.owner-heading-row, .owner-report-controls, .owner-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 9px;
}

.owner-main { width: min(100% - 36px, 1160px); margin: 24px auto 72px; }
.owner-card {
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.owner-access { max-width: 520px; }
.owner-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.owner-nav a {
  border: 1px solid var(--control-line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--surface);
  padding: 9px 13px;
  text-decoration: none;
}
.owner-nav a[aria-current="page"] { color: var(--gold-ink); border-color: var(--gold-line); background: var(--gold); font-weight: 700; }
.owner-panel > h1, .owner-panel > .owner-heading-row { margin-bottom: 14px; }
.owner-groups {
  display: grid;
  grid-template-columns: minmax(205px, .8fr) minmax(0, 2fr);
  grid-template-areas: "cities users" "cities boards";
  gap: 14px;
  align-items: start;
}
.owner-city-browser { grid-area: cities; }
.owner-spotter-users { grid-area: users; }
.owner-boards { grid-area: boards; }
.owner-city-picker { width: 100%; margin-top: 12px; }
.gruntr-owner input, .gruntr-owner select {
  color: var(--ink);
  border: 1px solid var(--control-line);
  border-radius: 7px;
  background: var(--surface);
  min-height: 44px;
  padding: 6px 9px;
  min-width: 0;
}
.gruntr-owner input::placeholder { color: var(--muted); opacity: 1; }
.owner-status { font-size: .93rem; color: var(--muted); margin: 9px 0; }
.owner-status:empty { display: none; }
.owner-list { margin: 10px 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.owner-club {
  width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  background: var(--surface-soft);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  display: grid;
  gap: 4px;
  cursor: pointer;
  text-align: left;
}
.owner-club[aria-pressed="true"] { border-color: var(--focus); }
.owner-meta { color: var(--muted); font-size: .87rem; margin: 0; overflow-wrap: anywhere; }
.owner-user-intro { margin-top: 5px; }
.owner-user-list { max-height: 26rem; overflow: auto; margin: 12px 0; }
.owner-user-city + .owner-user-city { margin-top: 14px; }
.gruntr-owner .owner-user-city h3 { background: var(--surface-soft); padding: 8px 10px; border-radius: 6px; }
.owner-user-city ul { list-style: none; margin: 0; padding: 0 10px; }
.owner-user-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  flex-wrap: wrap;
  column-gap: 12px;
  padding: 7px 0;
  overflow-wrap: anywhere;
}
.owner-user-row + .owner-user-row { border-top: 1px solid var(--line); }
.owner-club-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 170px), 1fr)); gap: 8px; }
.owner-heading-row, .gruntr-owner .admin-section-heading { justify-content: space-between; }
.gruntr-owner .admin-section-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.owner-posts-panel { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 14px; }
.owner-post-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  overflow-wrap: anywhere;
}
.owner-boards .owner-post-card { background: var(--canvas); }
.owner-post-text { white-space: pre-wrap; overflow-wrap: anywhere; margin: 10px 0; }
.owner-post-card blockquote { margin: 8px 0 10px; padding-left: 12px; border-inline-start: 2px solid var(--line); }
.owner-actions { margin-top: 10px; }
.owner-studio, .owner-trainers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 26rem), 1fr));
  gap: 14px;
  align-items: start;
}
.owner-trainer-action { padding-block: 0; }
.owner-trainer-action[open] { padding-bottom: 16px; }
.owner-trainer-action summary {
  cursor: pointer;
  font-size: 1.15rem;
  font-weight: 700;
  padding-block: 12px;
}
.owner-trainer-fields {
  border: 0;
  padding: 0;
  margin-inline: 0;
  min-inline-size: 0;
}
.owner-studio-form, .owner-trainer-fields {
  display: grid;
  gap: 6px;
  margin-top: 14px;
}
.owner-studio-form label, .owner-trainer-fields label { font-weight: 650; }
.owner-studio-form :is(input, select), .owner-trainer-fields input { width: 100%; margin-bottom: 5px; }
.owner-studio-form .button, .owner-trainer-fields .button { justify-self: start; }
.owner-trainer-list:empty { display: none; }
.owner-trainer-row {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
  overflow-wrap: anywhere;
}
.owner-trainer-row .owner-heading-row { align-items: baseline; }
.owner-trainer-state { color: var(--muted); font-size: .82rem; font-weight: 650; }
.owner-trainer-studio { margin: 7px 0 0; }
.owner-trainer-client-count { margin-top: 5px; }
.owner-trainer-clients { margin-bottom: 0; gap: 0; }
.owner-trainer-client {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  border-top: 1px solid var(--line);
  padding-block: 8px;
}
.owner-trainer-client:last-child { padding-bottom: 0; }
.gruntr-owner .owner-trainer-client .button { background: var(--surface); }
.owner-studio-key {
  margin-top: 14px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-soft);
}
.gruntr-owner .owner-studio-key input {
  width: 100%;
  margin-top: 8px;
  font-family: ui-monospace, monospace;
}
.owner-studio-list:empty { display: none; }
.owner-studio-link {
  display: flex;
  justify-content: space-between;
  align-items: start;
  flex-wrap: wrap;
  gap: 8px 12px;
  padding-block: 8px;
  overflow-wrap: anywhere;
}
.owner-studio-link + .owner-studio-link { border-top: 1px solid var(--line); }
.gruntr-owner .button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ink);
  background: var(--surface-soft);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 11px;
  min-height: 44px;
  line-height: 1.25;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
}
.gruntr-owner .button-dark { color: var(--gold-ink); background: var(--gold); border-color: var(--gold-line); }
.gruntr-owner .button:disabled { opacity: .55; cursor: default; }
.gruntr-owner .owner-workspace-link {
  min-height: 48px;
  padding: 8px 14px;
  font-size: 1rem;
  line-height: 1.2;
  text-align: center;
}
.gruntr-owner .coach-approvals-panel { padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.gruntr-owner .coach-approval-card-actions .button { padding-inline: 4px; }

@media (max-width: 690px) {
  .owner-groups {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "cities" "users" "boards";
  }
  .owner-main { width: calc(100% - 24px); }
}
@media (max-width: 405px) {
  .owner-header { gap: 10px; padding-inline: 12px; }
  .owner-header .owner-brand { font-size: 1rem; }
  .owner-report-controls { gap: 6px; }
  .gruntr-owner .coach-approval-card-actions .button { font-size: .82rem; }
}
