:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --ink: #17202a;
  --muted: #667085;
  --line: #d9dee7;
  --accent: #0f766e;
  --accent-dark: #115e59;
  --warn: #b45309;
  --soft: #edf7f5;
}
* { box-sizing: border-box; }
body { min-height: 100vh; margin: 0; padding-bottom: 58px; font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); background: var(--bg); display: flex; flex-direction: column; }
a { color: inherit; text-decoration: none; }
.topbar { position: sticky; top: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; min-height: 64px; padding: 0 20px; background: rgba(255,255,255,.94); border-bottom: 1px solid var(--line); backdrop-filter: blur(10px); }
.brand-stack { display: grid; gap: 2px; min-width: 0; }
.brand { font-weight: 800; font-size: 20px; color: var(--accent-dark); }
.nav { display: flex; gap: 14px; align-items: center; color: var(--muted); font-size: 14px; }
.nav-user { color: var(--ink); font-weight: 800; white-space: nowrap; }
.nav-user-mobile { display: none; }
.mobile-identity-row { display: none; }
.mobile-trainer-name { color: var(--muted); font-weight: 750; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: right; }
.logout-link { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.logout-link .icon { width: 18px; height: 18px; }
.top-nav-select { width: auto; min-width: 132px; max-width: 180px; min-height: 36px; margin-left: auto; padding: 6px 32px 6px 10px; color: var(--ink); font-size: 14px; font-weight: 700; text-align: left; text-align-last: left; }
.shell { position: relative; width: min(1120px, calc(100% - 28px)); margin: 22px auto 24px; flex: 1 0 auto; }
.login-panel { min-height: calc(100vh - 190px); display: grid; grid-template-columns: 1.2fr .8fr; gap: 32px; align-items: center; }
.login-side { display: grid; gap: 12px; }
.desktop-price-tile { margin-top: 22px; background: var(--panel); border: 1px solid var(--accent); border-radius: 8px; box-shadow: 0 10px 28px rgba(15, 23, 42, .06); overflow: hidden; }
.desktop-price-tile summary { min-height: 56px; padding: 0 20px; cursor: pointer; color: #fff; background: var(--accent); font-weight: 850; list-style: none; display: flex; align-items: center; justify-content: center; text-align: center; }
.desktop-price-tile summary::-webkit-details-marker { display: none; }
.desktop-price-tile summary:hover { background: var(--accent-dark); }
.desktop-price-tile[open] summary { margin-bottom: 0; }
.desktop-price-list { display: grid; padding: 8px 20px 10px; background: #fff; }
.desktop-price-list div { display: grid; grid-template-columns: 90px minmax(130px, 1fr) minmax(110px, 1fr) auto; gap: 14px; align-items: baseline; padding: 10px 0; border-top: 1px solid var(--line); }
.desktop-price-list div:first-child { border-top: 0; }
.desktop-price-list span { color: var(--muted); }
.desktop-price-list b { color: var(--accent-dark); text-align: right; white-space: nowrap; }
.trainer-signup-tile { display: flex; min-height: 56px; align-items: center; justify-content: center; margin-top: 12px; padding: 0 20px; background: var(--accent); color: #fff; border: 1px solid var(--accent); border-radius: 8px; box-shadow: 0 10px 28px rgba(15, 23, 42, .06); font-weight: 850; text-align: center; }
.trainer-signup-tile:hover { background: var(--accent-dark); color: #fff; }
.mobile-signup-tile { display: none; }
.mobile-price-tile { display: none; }
.site-footer { position: fixed; left: 50%; bottom: 18px; z-index: 4; transform: translateX(-50%); width: min(1120px, calc(100% - 28px)); padding: 8px 0 0; border-top: 1px solid var(--line); display: grid; justify-items: center; gap: 5px; color: var(--muted); font-size: 12px; line-height: 1.25; text-align: center; background: rgba(246, 247, 249, .96); backdrop-filter: blur(8px); }
.site-footer nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.site-footer a { color: var(--accent-dark); font-weight: 700; }
h1 { margin: 0; font-size: 40px; line-height: 1.08; letter-spacing: 0; }
h2 { margin: 0 0 14px; font-size: 20px; }
.eyebrow { margin: 0 0 10px; text-transform: uppercase; letter-spacing: .08em; color: var(--accent-dark); font-size: 12px; font-weight: 800; }
.muted, .hint { color: var(--muted); }
.form-card, .panel, .exercise-card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 10px 28px rgba(15, 23, 42, .06); }
.form-card { display: grid; gap: 16px; padding: 22px; }
label { display: grid; gap: 7px; font-size: 14px; font-weight: 650; }
input, textarea, select { width: 100%; min-height: 42px; border: 1px solid var(--line); border-radius: 7px; padding: 9px 11px; font: inherit; background: #fff; }
textarea { min-height: 72px; resize: vertical; }
button, .pager a { border: 0; border-radius: 7px; background: var(--accent); color: #fff; min-height: 42px; padding: 0 16px; font-weight: 750; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
button:hover, .pager a:hover { background: var(--accent-dark); }
.flash { padding: 12px 14px; border-radius: 8px; margin-bottom: 16px; background: var(--soft); border: 1px solid #b7e4dc; }
.flash.error { background: #fff1f2; border-color: #fecdd3; }
.page-head { display: flex; gap: 18px; justify-content: space-between; align-items: flex-end; margin-bottom: 18px; padding-right: 48px; }
.page-head h1 { font-size: 32px; }
.page-help-button { position: absolute; top: 0; right: 0; z-index: 2; width: 38px; min-height: 38px; padding: 0; border: 1px solid var(--line); background: #fff; color: var(--accent-dark); box-shadow: 0 10px 28px rgba(15, 23, 42, .08); }
.page-help-button:hover { background: var(--soft); }
.page-help-button .icon { width: 20px; height: 20px; }
.athlete-head { align-items: center; }
.pager { display: flex; gap: 8px; flex-wrap: wrap; }
.pager a { background: #1f2937; min-height: 38px; font-size: 14px; }
.status-pill { padding: 10px 12px; border-radius: 999px; border: 1px solid #b7e4dc; background: var(--soft); color: var(--accent-dark); font-weight: 750; }
.note-line { padding: 12px 14px; background: #fff7ed; border: 1px solid #fed7aa; color: var(--warn); border-radius: 8px; }
.exercise-list { display: grid; gap: 16px; }
.exercise-card { display: grid; grid-template-columns: 190px 1fr; overflow: hidden; }
.exercise-card img { width: 100%; height: 100%; min-height: 190px; object-fit: cover; background: #eef2f7; }
.exercise-main { padding: 18px; }
.exercise-title { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.exercise-title h2 { margin-bottom: 4px; }
.exercise-title p { margin: 0; color: var(--muted); }
.exercise-title span { flex: 0 0 auto; background: var(--soft); color: var(--accent-dark); border-radius: 999px; padding: 7px 10px; font-weight: 800; font-size: 13px; }
.targets { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.targets span { border: 1px solid var(--line); border-radius: 999px; padding: 6px 9px; font-size: 13px; background: #fff; }
.cue { margin: 0 0 8px; color: var(--muted); }
.trainer-note { margin: 0 0 14px; padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--soft); }
.set-form { display: grid; gap: 10px; }
.set-row { display: grid; grid-template-columns: 80px repeat(3, 64px); gap: 8px; align-items: center; margin: 8px 0 4px; }
.short-input { width: 64px; min-width: 0; text-align: center; }
.check { display: flex; grid-template-columns: auto; align-items: center; gap: 6px; color: var(--muted); font-weight: 650; }
.check input { width: auto; min-height: auto; }
.grid.two { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.panel { padding: 18px; margin-bottom: 16px; }
.legal-content { display: grid; gap: 16px; }
.legal-content article { display: grid; gap: 4px; }
.legal-content h2 { margin: 0; font-size: 18px; }
.legal-content p { margin: 0; color: var(--muted); line-height: 1.55; }
.list-row, .log-row { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.list-row:first-of-type, .log-row:first-of-type { border-top: 0; }
.list-row small, td small { display: block; color: var(--muted); margin-top: 3px; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { color: var(--muted); font-size: 13px; }
.inline-form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline-form select { width: auto; min-height: 36px; }
.inline-form label { display: flex; gap: 6px; align-items: center; font-weight: 600; color: var(--muted); }
.inline-form button { min-height: 36px; }
.empty { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 28px; }
@media (max-width: 760px) {
  .topbar { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 12px; align-items: center; padding: 12px 14px; min-height: auto; background: linear-gradient(180deg, #edf7f5 0%, #f7fbfa 100%); border-bottom-color: #b7e4dc; box-shadow: 0 8px 22px rgba(15, 94, 89, .08); }
  .brand-stack { align-self: center; display: contents; }
  .brand { grid-column: 1; grid-row: 1; }
  .nav { display: grid; grid-template-columns: minmax(112px, 1fr) 40px; gap: 8px; justify-content: end; justify-self: end; align-items: center; }
  .tenant-logo, .nav-user-desktop { display: none; }
  .mobile-identity-row { grid-column: 1 / -1; grid-row: 2; display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 12px; align-items: baseline; width: 100%; }
  .nav-user-mobile { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: 14px; line-height: 1.15; }
  .mobile-trainer-name { justify-self: end; max-width: 54vw; font-size: 13px; line-height: 1.15; }
  .top-nav-select { min-width: 112px; max-width: 132px; min-height: 38px; justify-self: end; }
  .logout-link { width: 40px; min-height: 38px; justify-content: center; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
  .logout-link span { display: none; }
  .logout-link .icon { width: 21px; height: 21px; }
  .login-panel, .grid.two { grid-template-columns: 1fr; }
  .login-panel { min-height: 0; gap: 16px; align-items: start; }
  .login-panel h1 { font-size: 30px; line-height: 1.06; }
  .login-panel .form-card { padding: 18px; gap: 14px; }
  .desktop-price-tile { display: none; }
  .login-panel > div:first-child > .trainer-signup-tile { display: none; }
  .mobile-price-tile { display: block; width: calc(100% - 36px); margin-inline: auto; background: var(--panel); border: 1px solid var(--accent); border-radius: 7px; box-shadow: 0 10px 28px rgba(15, 23, 42, .06); overflow: hidden; }
  .mobile-price-tile summary { min-height: 42px; padding: 0 18px; cursor: pointer; color: #fff; background: var(--accent); font-weight: 850; list-style: none; display: flex; align-items: center; justify-content: center; text-align: center; }
  .mobile-price-tile summary::-webkit-details-marker { display: none; }
  .mobile-price-tile summary:hover { background: var(--accent-dark); }
  .mobile-price-list { display: grid; gap: 8px; padding: 12px 18px; background: #fff; }
  .mobile-price-list div { display: grid; gap: 2px; padding-top: 8px; border-top: 1px solid var(--line); }
  .mobile-price-list div:first-child { border-top: 0; padding-top: 0; }
  .mobile-price-list span { color: var(--muted); font-size: 13px; }
  .mobile-price-list b { color: var(--accent-dark); }
  .mobile-signup-tile { display: flex; width: calc(100% - 36px); min-height: 42px; margin: 0 auto; padding: 0 18px; border-radius: 7px; }
  body { padding-bottom: 62px; }
  .site-footer { bottom: 14px; gap: 4px; padding-top: 6px; font-size: 11px; }
  .site-footer nav { justify-content: center; gap: 8px; }
  h1 { font-size: 30px; }
  .page-head { display: grid; align-items: stretch; width: 100%; padding-right: 42px; }
  .page-help-button { top: 0; right: 0; width: 34px; min-height: 34px; }
  .page-head .mobile-redundant-title { display: none; }
  .page-head .eyebrow { margin-bottom: 0; }
  .exercise-card { grid-template-columns: 1fr; }
  .exercise-card img { height: 170px; min-height: 170px; }
  .set-row { grid-template-columns: 76px repeat(3, 58px); gap: 7px; margin: 8px 0 4px; }
  .short-input { width: 58px; min-height: 38px; padding: 7px 6px; }
  .set-row .check { grid-column: 2 / span 3; }
  .table-panel { overflow-x: auto; }
}

.stack-form { display: grid; gap: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 760px) { .form-grid { grid-template-columns: 1fr; } }
.trainer-message-form { display: grid; grid-template-columns: 1fr 46px; gap: 12px; align-items: end; max-width: 860px; }
.trainer-message-form label { margin: 0; }
.trainer-message-form label:first-child { grid-column: 1 / -1; }
.trainer-message-form input { min-height: 42px; }
.trainer-message-form textarea { min-height: 42px; height: 42px; resize: vertical; }
.trainer-message-send { width: 46px; min-height: 42px; flex-basis: 46px; background: var(--accent); border-color: var(--accent); }
.trainer-message-send:hover { background: var(--accent-dark); }
.trainer-message-send .icon { width: 22px; height: 22px; }
.trainer-message-send .icon { filter: brightness(0) invert(1); }
@media (max-width: 760px) {
  .trainer-message-form { grid-template-columns: 1fr 46px; }
  .trainer-message-send { justify-self: end; }
}

.inline-form input[type="date"], .inline-form input[type="number"] { width: auto; min-height: 36px; max-width: 150px; }
.archive-list { display: grid; gap: 10px; margin-top: 14px; }
.archive-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.archive-card strong { display: block; font-size: 17px; }
.archive-card small { display: block; margin-top: 3px; color: var(--muted); }
@media (max-width: 760px) { .archive-card { grid-template-columns: 1fr; align-items: start; } }

.check-group { display: grid; gap: 8px; border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.check-group legend { color: var(--muted); font-weight: 750; padding: 0 6px; }
.check-group label { display: flex; grid-template-columns: auto; align-items: center; gap: 8px; font-weight: 600; }
.check-group input { width: auto; min-height: auto; }



.athlete-row { display: grid; grid-template-columns: minmax(220px, 1fr) auto; gap: 18px; align-items: center; padding: 14px 0; border-top: 1px solid var(--line); }
.athlete-row:first-of-type { border-top: 0; }
.athlete-info small, .athlete-row small { display: block; color: var(--muted); margin-top: 4px; }
.athlete-row.archived { opacity: .75; }
.row-actions { display: flex; flex-wrap: wrap; gap: 14px; justify-content: flex-end; align-items: center; }
.row-actions form { margin: 0; }
.profile-action { color: var(--accent-dark); font-weight: 750; }
.text-action { min-height: 0; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 14px; font-weight: 650; }
.text-action:hover { background: transparent; color: var(--ink); text-decoration: underline; }
.danger-text { color: #b42318; }
.danger-text:hover { color: #8f1d14; }
@media (max-width: 760px) { .athlete-row { grid-template-columns: 1fr; align-items: start; } .row-actions { justify-content: flex-start; gap: 12px; } }

.athlete-card { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 16px; align-items: center; padding: 12px 0; border-top: 1px solid var(--line); }
.athlete-card:first-of-type { border-top: 0; padding-top: 0; }
.athlete-card.archived { opacity: .78; }
.athlete-card-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 10px; min-width: 0; }
.athlete-card-head strong { display: inline; font-size: 18px; line-height: 1.2; }
.athlete-card-head small { flex-basis: 100%; display: block; color: var(--muted); margin-top: 2px; }
.athlete-contact { color: var(--muted); min-width: 0; overflow-wrap: anywhere; }
.athlete-contact::before { content: "- "; color: var(--muted); }
.athlete-menu-row { display: flex; justify-content: flex-end; }
.athlete-action-select { width: 220px; max-width: 100%; min-height: 40px; margin-left: auto; padding: 0 34px 0 12px; text-align: left; text-align-last: left; }
.compact-select { width: 150px; max-width: 150px; min-height: 36px; justify-self: end; }
.hidden-action-form { display: none; }
.confirm-modal[hidden] { display: none; }
.confirm-modal { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 18px; background: rgba(15, 23, 42, .34); }
.confirm-dialog { width: min(420px, 100%); padding: 22px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 24px 80px rgba(15, 23, 42, .22); }
.confirm-dialog h2 { margin: 0 0 8px; }
.confirm-dialog p { margin: 0; color: var(--muted); line-height: 1.4; }
.confirm-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 18px; }
.button-secondary, .button-danger { min-height: 40px; padding: 0 14px; border-radius: 7px; font-weight: 800; display: inline-flex; align-items: center; justify-content: center; }
.button-secondary { border: 1px solid var(--line); background: #fff; color: var(--ink); }
.button-danger { border: 1px solid #f0b8b2; background: #b42318; color: #fff; }
.button-danger:hover { background: #8f1d14; color: #fff; text-decoration: none; }
.message-modal { position: fixed; inset: 0; z-index: 35; display: grid; place-items: center; padding: 18px; background: rgba(15, 23, 42, .36); }
.message-dialog { width: min(560px, 100%); max-height: min(680px, calc(100vh - 36px)); overflow: auto; padding: 22px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 24px 80px rgba(15, 23, 42, .26); }
.message-dialog-head { margin-bottom: 14px; }
.message-dialog-head h2 { margin: 0; }
.message-popup-list { display: grid; gap: 12px; margin-bottom: 14px; }
.message-popup-card { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 44px; gap: 10px; padding: 14px 62px 14px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.message-popup-card strong { display: block; font-size: 17px; }
.message-popup-card small { display: block; margin-top: 3px; color: var(--muted); }
.message-popup-card p { grid-column: 1 / -1; margin: 0; color: var(--ink); line-height: 1.45; }
.message-popup-card form { position: absolute; top: 12px; right: 12px; margin: 0; }
.message-read-btn { width: 40px; min-height: 40px; flex-basis: 40px; background: var(--accent); border-color: var(--accent); }
.message-read-btn:hover { background: var(--accent-dark); }
.message-read-btn .icon { width: 20px; height: 20px; filter: brightness(0) invert(1); }
.athlete-card-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.athlete-action-form { margin: 0; }
.athlete-action-tile { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font: inherit; font-weight: 750; line-height: 1.2; display: flex; align-items: center; justify-content: center; text-align: center; }
.athlete-action-tile:hover { background: var(--soft); color: var(--accent-dark); text-decoration: none; }
.athlete-action-tile.danger { color: #b42318; }
.athlete-action-tile.danger:hover { background: #fff5f5; color: #8f1d14; }
@media (max-width: 760px) { .athlete-card { grid-template-columns: 1fr; gap: 8px; padding: 14px 0; } .athlete-card-head { display: grid; gap: 3px; } .athlete-card-head strong { font-size: 18px; } .athlete-contact::before { content: ""; } .athlete-menu-row { width: 100%; justify-content: flex-end; } .athlete-action-select { width: 180px; max-width: 100%; margin-left: auto; justify-self: end; } .compact-select { width: 150px; max-width: 150px; margin-left: auto; justify-self: end; } .athlete-card-actions { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 420px) { .athlete-card-actions { grid-template-columns: 1fr; } }

.set-form textarea { width: 100%; }

.set-row strong { white-space: nowrap; }

.instruction-line { margin: 10px 0 0; color: var(--muted); font-weight: 700; }
.schema-strip { display: grid; grid-template-columns: auto repeat(3, minmax(72px, auto)); gap: 8px; align-items: center; margin: 14px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #f8fafc; color: var(--muted); }
.schema-strip strong { color: var(--ink); }
.set-log { display: grid; gap: 10px; margin-top: 14px; }
.set-log h3 { margin: 0; font-size: 16px; }
.set-line { display: grid; grid-template-columns: 64px 86px 86px minmax(88px, 1fr); gap: 8px; align-items: end; }
.set-line label { gap: 4px; color: var(--muted); font-size: 12px; font-weight: 700; }
.set-line input { width: 86px; min-height: 38px; text-align: center; }
.save-state { min-height: 18px; color: var(--muted); font-size: 12px; }
.save-state[data-mode="ok"] { color: var(--accent-dark); }
.save-state[data-mode="error"] { color: #b42318; }
.note-input { margin-top: 14px; color: var(--muted); }
.note-input textarea { margin-top: 6px; width: 100%; }
@media (max-width: 760px) {
  .schema-strip { grid-template-columns: 1fr; gap: 4px; }
  .set-line { grid-template-columns: 64px 72px 72px; align-items: end; }
  .set-line input { width: 72px; min-height: 38px; }
  .set-line .save-state { grid-column: 2 / span 2; }
}

/* Athlete training card polish */
.exercise-list { display: grid; gap: 18px; }
.exercise-card { display: block; width: 100%; overflow: hidden; }
.exercise-main { padding: 18px; }
.exercise-title { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; }
.exercise-title h2 { margin: 0 0 5px; font-size: 28px; line-height: 1.08; overflow-wrap: anywhere; }
.exercise-title p { margin: 0; color: var(--muted); font-size: 18px; line-height: 1.25; }
.exercise-title span { align-self: start; white-space: nowrap; }
.instruction-line { margin: 12px 0 0; color: var(--muted); font-weight: 700; font-size: 15px; }
.schema-strip { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 16px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #f8fafc; color: var(--muted); }
.schema-strip strong { color: var(--ink); margin-right: 4px; }
.schema-strip span { white-space: nowrap; }
.previous-set-strip { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; margin: -6px 0 14px; padding: 8px 10px; border: 1px solid #b7e4dc; border-radius: 8px; background: var(--soft); color: var(--muted); font-size: 14px; }
.previous-set-strip strong { color: var(--accent-dark); margin-right: 2px; }
.previous-set-strip span { white-space: nowrap; }
.set-log { display: grid; gap: 8px; margin-top: 12px; }
.set-log h3 { margin: 0 0 2px; font-size: 16px; color: var(--ink); }
.set-line { display: grid; grid-template-columns: 58px 72px 72px minmax(72px, 1fr); gap: 8px; align-items: center; }
.set-line strong { white-space: nowrap; font-size: 16px; }
.set-line label { display: block; font-size: 0; line-height: 0; }
.set-line input { width: 72px; min-height: 40px; padding: 7px 8px; border-radius: 8px; text-align: center; font-size: 16px; }
.extra-set-list { display: grid; gap: 8px; }
.extra-set-line { padding-top: 2px; }
.schema-request-check { display: inline-flex !important; align-items: center; gap: 6px; min-height: 34px; font-size: 13px !important; line-height: 1.2 !important; color: var(--muted); }
.schema-request-check input { width: 18px; min-height: 18px; padding: 0; }
.add-extra-set { justify-self: start; margin-top: 2px; color: var(--accent-dark); font-weight: 800; }
.save-state { min-height: 18px; color: var(--muted); font-size: 12px; line-height: 1.2; }
.save-state[data-mode="ok"] { color: var(--accent-dark); }
.save-state[data-mode="error"] { color: #b42318; }
.note-input { display: block; margin-top: 14px; color: var(--muted); font-size: 0; line-height: 0; }
.note-input textarea { margin-top: 0; width: 100%; min-height: 78px; font-size: 16px; line-height: 1.35; }
.note-input .save-state { display: block; margin-top: 5px; font-size: 12px; line-height: 1.2; }
@media (max-width: 760px) {
  .shell { width: min(100% - 24px, 720px); margin-top: 18px; margin-bottom: 18px; }
  .exercise-list { gap: 12px; }
  .exercise-main { padding: 14px; }
  .exercise-title h2 { font-size: 25px; }
  .exercise-title p { font-size: 16px; }
  .schema-strip { margin: 12px 0; padding: 8px 10px; }
  .previous-set-strip { margin: -4px 0 10px; padding: 7px 9px; gap: 5px; font-size: 13px; }
  .set-log { gap: 2px; margin-top: 8px; }
  .set-log h3 { font-size: 17px; margin-bottom: 2px; }
  .set-line { grid-template-columns: 58px 64px 64px; gap: 6px; min-height: 36px; margin: 0; align-items: center; }
  .set-line strong { font-size: 16px; }
  .set-line input { width: 64px; min-height: 34px; padding: 5px 7px; font-size: 15px; }
  .extra-set-line { grid-template-columns: 58px 64px 64px; }
  .extra-set-line .schema-request-check { grid-column: 2 / span 2; min-height: 24px; }
  .set-line .save-state { grid-column: 2 / span 2; min-height: 0; margin-top: 0; }
  .set-line .save-state:empty { display: none; }
  .note-input { margin-top: 8px; }
  .note-input textarea { min-height: 58px; }
}
@media (max-width: 390px) {
  .set-line { grid-template-columns: 54px 62px 62px; gap: 6px; }
  .set-line input { width: 62px; }
  .exercise-title h2 { font-size: 24px; }
}

.progress-picker { margin-bottom: 16px; }
.progress-picker label { max-width: 420px; }
.progress-title-block, .athlete-context-title { flex: 1; min-width: 0; }
.progress-kicker-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; width: 100%; }
.progress-kicker-row .eyebrow { margin-bottom: 0; }
.progress-action-select { width: 190px; max-width: 190px; justify-self: end; margin-left: auto; }
.metric-row { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line); }
.metric-row:first-of-type { border-top: 0; }
#progressChart { width: 100%; max-width: 100%; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.date-detail-button { min-height: 0; padding: 0; border: 0; background: transparent; color: var(--accent-dark); font: inherit; font-weight: 800; text-align: left; }
.date-detail-button:hover { background: transparent; color: var(--accent-dark); text-decoration: underline; }
.history-value-modal[hidden] { display: none; }
.history-value-modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 18px; background: rgba(15, 23, 42, .24); }
.history-value-dialog { position: relative; width: min(380px, 100%); padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 24px 80px rgba(15, 23, 42, .22); }
.history-value-dialog h2 { margin-right: 44px; }
.history-value-dialog [data-history-value-content] { display: grid; gap: 7px; color: var(--muted); }
.history-value-dialog strong { color: var(--ink); }
.history-value-dialog small { display: block; }
.subtitle-help { display: flex; align-items: center; gap: 8px; margin-top: 20px; }
.subtitle-help p { margin: 0; }
.help-trigger { width: 30px; min-height: 30px; flex-basis: 30px; background: #fff; }
.help-modal[hidden] { display: none; }
.help-modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 18px; background: rgba(15, 23, 42, .34); }
.help-dialog { position: relative; width: min(520px, 100%); padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: #fff; box-shadow: 0 24px 80px rgba(15, 23, 42, .22); }
.help-dialog h2 { margin-right: 44px; }
.help-dialog p { margin: 10px 0 0; color: var(--muted); line-height: 1.45; }
.help-dialog strong { color: var(--ink); }
.help-close { position: absolute; top: 14px; right: 14px; width: 32px; min-height: 32px; flex-basis: 32px; }

/* Mobile athlete header polish */
.note-line { padding: 10px 12px; font-size: 15px; line-height: 1.35; }
@media (max-width: 760px) {
  .athlete-head h1 { font-size: 28px; line-height: 1.12; }
  .athlete-head .muted { font-size: 16px; }
  .note-line { padding: 9px 11px; font-size: 15px; }
}
@media (max-width: 390px) {
  .athlete-head h1 { font-size: 25px; }
}

.cardio-line { display: grid; grid-template-columns: minmax(110px, 1fr) 78px 78px minmax(72px, 1fr); gap: 8px; align-items: end; }
.cardio-line label { gap: 4px; color: var(--muted); font-size: 12px; font-weight: 700; }
.cardio-line input { min-height: 40px; padding: 7px 8px; border-radius: 8px; font-size: 16px; }
.cardio-line input[name="cardio_level"], .cardio-line input[name="cardio_minutes"] { text-align: center; }
@media (max-width: 760px) {
  .athlete-head { gap: 12px; margin-bottom: 14px; }
  .athlete-head h1 { font-size: 20px; line-height: 1.15; }
  .athlete-head .muted { font-size: 15px; margin-top: 8px; }
  .athlete-head .mobile-training-trainer { display: none; }
  .cardio-line { grid-template-columns: 1fr 72px 72px; }
  .cardio-line .save-state { grid-column: 1 / span 3; }
}
@media (max-width: 390px) {
  .athlete-head h1 { font-size: 19px; }
}

.compact-days { padding-bottom: 10px; }
.day-progress-row { display: grid; grid-template-columns: minmax(180px, 1fr) auto; gap: 12px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); }
.day-progress-row:first-of-type { border-top: 0; }
.day-progress-row span { font-weight: 650; }
.day-progress-row small { color: var(--muted); white-space: nowrap; }
@media (max-width: 760px) { .day-progress-row { grid-template-columns: 1fr; gap: 2px; } .day-progress-row small { white-space: normal; } }

a.day-progress-row { color: inherit; text-decoration: none; }
a.day-progress-row:hover span { color: var(--accent-dark); }
.result-row { display: flex; flex-wrap: wrap; gap: 10px; padding: 10px 0; color: var(--muted); }
.result-row strong { color: var(--ink); }
.result-table { display: grid; gap: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; margin-top: 10px; }
.result-table > div { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; padding: 9px 11px; border-top: 1px solid var(--line); }
.result-table > div:first-child { border-top: 0; }
.result-head { background: #f8fafc; color: var(--muted); font-weight: 750; }

.dashboard-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.dashboard-tile { display: grid; gap: 8px; padding: 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 10px 28px rgba(15, 23, 42, .06); }
.dashboard-tile strong { font-size: 22px; }
.dashboard-tile span { color: var(--muted); line-height: 1.35; }
.transfer-trainer-list { display: grid; gap: 8px; margin-top: 10px; }
.transfer-trainer-card { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: pointer; }
.transfer-trainer-card input { width: auto; min-height: auto; }
.transfer-trainer-card small { display: block; color: var(--muted); margin-top: 2px; }
.transfer-pending-list { display: grid; gap: 8px; margin-top: 10px; }
.transfer-pending-list div { display: grid; gap: 2px; padding: 9px 0; border-top: 1px solid var(--line); }
.transfer-pending-list div:first-child { border-top: 0; }
.transfer-pending-list span, .transfer-pending-list small { color: var(--muted); }
.narrow-panel { max-width: 720px; }
.plan-price-list { display: grid; gap: 6px; padding: 10px 0 2px; }
.plan-price-row { display: grid; grid-template-columns: 82px minmax(130px, 1fr) minmax(140px, auto); gap: 12px; align-items: baseline; padding: 8px 0; border-top: 1px solid var(--line); }
.plan-price-row:first-child { border-top: 0; }
.plan-price-row span { color: var(--muted); }
.plan-price-row b { text-align: right; color: var(--accent-dark); }
@media (max-width: 560px) { .plan-price-row { grid-template-columns: 1fr; gap: 2px; } .plan-price-row b { text-align: left; } }
.search-panel { margin-bottom: 14px; }
.search-panel label { max-width: 420px; }
.comment-card { padding: 12px 0; border-top: 1px solid var(--line); }
.comment-card:first-of-type { border-top: 0; }
.comment-card span { display: block; margin-top: 4px; color: var(--muted); }
.comment-card p { margin: 8px 0 0; }
.comment-card.is-read { opacity: .78; }
.comment-card-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.comment-status { min-height: 28px; padding: 5px 9px; border-radius: 999px; background: #fff7ed; border: 1px solid #fed7aa; color: var(--warn); font-weight: 800; }
.comment-reply-form { display: grid; gap: 10px; margin-top: 12px; }
.comment-reply-form textarea { min-height: 86px; }
.comment-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.comment-action-btn { width: 42px; min-height: 42px; flex-basis: 42px; }
.trainer-reply { margin-top: 12px; padding: 11px 12px; border: 1px solid #b7e4dc; border-radius: 8px; background: var(--soft); }
.trainer-reply p { margin: 5px 0 0; color: var(--muted); }
.history-cards { display: none; }
@media (max-width: 760px) {
  .progress-head, .athlete-context-head { display: grid; grid-template-columns: 1fr; gap: 8px; margin-bottom: 12px; width: 100%; }
  .progress-title-block, .athlete-context-title { display: block; min-width: 0; width: 100%; }
  .progress-kicker-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; min-height: 38px; padding-right: 0; }
  .progress-kicker-row .eyebrow { font-size: 11px; min-width: 0; }
  .progress-action-select { position: static; flex: 0 0 148px; width: 148px; min-height: 36px; max-width: 148px; margin-left: auto; padding-top: 6px; padding-bottom: 6px; }
  .progress-head h1, .athlete-context-head h1 { font-size: 28px; line-height: 1.08; margin-top: 10px; }
  .progress-head .page-actions, .athlete-context-head .page-actions { margin-top: -2px; }
  .dashboard-tiles { grid-template-columns: 1fr; }
  .dashboard-tile { padding: 16px; }
  .dashboard-tile strong { font-size: 20px; }
  .dashboard-head { gap: 8px; margin-bottom: 10px; }
  .dashboard-head h1 { font-size: 26px; line-height: 1.08; }
  .dashboard-head .muted { margin: 4px 0 0; font-size: 15px; }
  .dashboard-head .status-pill { width: fit-content; padding: 6px 10px; font-size: 14px; line-height: 1.15; }
  .history-cards { display: grid; gap: 10px; }
  .history-card { border: 1px solid var(--line); border-radius: 8px; padding: 12px; background: #fff; }
  .history-card div { display: flex; justify-content: space-between; gap: 10px; }
  .history-card span, .history-card small { color: var(--muted); }
  .history-card p { margin: 8px 0 0; }
  .table-panel .history-cards + table { display: none; }
}

.progress-days { display: grid; gap: 10px; }
.progress-day-card { display: grid; grid-template-columns: minmax(120px, 1fr) auto; gap: 4px 12px; align-items: center; padding: 14px 16px; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 22px rgba(15, 23, 42, .04); }
.progress-day-card strong { font-size: 20px; }
.progress-day-card span { color: var(--muted); font-weight: 650; }
.progress-day-card small { grid-column: 1 / -1; color: var(--muted); }
.progress-day-card:hover { border-color: #b7e4dc; }
@media (max-width: 760px) {
  .progress-day-card { grid-template-columns: 1fr auto; padding: 13px 14px; }
  .progress-day-card strong { font-size: 19px; }
}

.schedule-panel { width: calc(100vw - 32px); margin-left: calc(50% - 50vw + 16px); margin-right: calc(50% - 50vw + 16px); padding: 0; overflow: hidden; }
.schedule-scroll { max-height: 72vh; overflow: auto; }
.schedule-matrix { min-width: 1180px; border-collapse: separate; border-spacing: 0; }
.schedule-matrix th, .schedule-matrix td { width: 220px; min-width: 220px; vertical-align: top; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 10px; }
.schedule-matrix thead th { position: sticky; top: 0; z-index: 2; background: #f8fafc; font-size: 14px; text-align: left; }
.schedule-matrix tbody th { position: sticky; left: 0; z-index: 1; width: 74px; min-width: 74px; background: #f8fafc; color: var(--accent-dark); }
.schedule-matrix thead th:first-child { left: 0; z-index: 3; width: 74px; min-width: 74px; }
.schedule-day-head { display: flex; justify-content: space-between; gap: 8px; color: inherit; text-decoration: none; margin-bottom: 8px; }
.schedule-day-head strong { font-size: 14px; white-space: nowrap; }
.schedule-day-head span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.schedule-day-head.schedule-status-done { padding: 5px 7px; border: 1px solid #abefc6; border-radius: 7px; background: #ecfdf3; color: #067647; }
.schedule-day-head.schedule-status-missed { padding: 5px 7px; border: 1px solid #fecdca; border-radius: 7px; background: #fff1f0; color: #b42318; }
.schedule-day-head.schedule-status-future { padding: 5px 7px; border: 1px solid transparent; border-radius: 7px; }
.schedule-exercises { display: grid; gap: 6px; }
.schedule-exercise { border: 1px solid var(--line); border-radius: 7px; padding: 7px 8px; background: #fff; }
.schedule-exercise strong { display: block; font-size: 13px; line-height: 1.2; }
.schedule-exercise small { display: block; margin-top: 3px; color: var(--muted); font-size: 12px; line-height: 1.25; }
.schedule-result { color: var(--accent-dark) !important; }
.schedule-result b { color: var(--accent-dark); }
@media (max-width: 760px) {
  .schedule-panel { width: calc(100vw - 16px); margin-left: calc(50% - 50vw + 8px); margin-right: calc(50% - 50vw + 8px); }
  .schedule-scroll { max-height: none; }
  .schedule-matrix { min-width: 960px; }
  .schedule-matrix th, .schedule-matrix td { width: 176px; min-width: 176px; padding: 8px; }
  .schedule-matrix tbody th, .schedule-matrix thead th:first-child { width: 58px; min-width: 58px; }
}

.exercise-admin-list { display: grid; gap: 8px; }
.exercise-admin-row, .exercise-admin-edit { display: grid; gap: 7px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.exercise-row-top { display: grid; grid-template-columns: minmax(0, 1fr) 34px; gap: 12px; align-items: start; }
.exercise-admin-static { display: grid; gap: 3px; min-width: 0; }
.exercise-admin-static strong { line-height: 1.2; }
.exercise-admin-static span, .exercise-cue, .exercise-admin-inline-meta, .exercise-admin-row-foot { color: var(--muted); }
.exercise-action-slot { width: 34px; min-height: 34px; display: flex; justify-content: flex-end; }
.exercise-admin-inline-meta { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; margin-top: 1px; }
.source-pill { display: inline-flex; align-items: center; min-height: 24px; padding: 0 9px; border-radius: 999px; background: var(--soft); color: var(--accent-dark); font-weight: 800; font-size: 12px; }
.icon-btn { width: 34px; min-height: 34px; padding: 0; border-radius: 7px; background: #f8fafc; color: var(--ink); border: 1px solid var(--line); font-size: 16px; display: inline-flex; align-items: center; justify-content: center; flex: 0 0 34px; }
.icon-btn:hover { background: var(--soft); color: var(--accent-dark); }
.exercise-admin-edit { border-color: #b7e4dc; background: #fbfefe; }
.exercise-admin-edit-grid { display: grid; grid-template-columns: minmax(200px, 1.4fr) 130px 130px 150px minmax(180px, 1fr); gap: 10px; }
.exercise-admin-edit-grid label { gap: 5px; }
.exercise-admin-edit-grid input, .exercise-admin-edit-grid select { min-height: 38px; padding: 7px 9px; }
.exercise-admin-row-foot { display: flex; justify-content: space-between; gap: 12px; align-items: center; }
.inline-actions { display: flex; gap: 10px; align-items: center; }
.inline-actions button { min-height: 36px; }
@media (max-width: 760px) { .inline-actions { justify-content: flex-end; width: 100%; } .inline-actions button { margin-right: auto; } .inline-actions .compact-select { margin-left: auto; } }
@media (max-width: 900px) { .exercise-admin-edit-grid { grid-template-columns: 1fr 1fr; } .exercise-admin-row-foot { align-items: flex-start; flex-direction: column; } }
@media (max-width: 560px) { .exercise-admin-row, .exercise-admin-edit { padding: 11px 12px; } .exercise-row-top { grid-template-columns: minmax(0, 1fr) 34px; } .exercise-admin-edit-grid { grid-template-columns: 1fr; } }



.panel-headline { display: flex; justify-content: space-between; gap: 12px; align-items: center; margin-bottom: 14px; }
.panel-headline h2 { margin-bottom: 0; }
.search-form { display: grid; grid-template-columns: minmax(220px, 420px) auto auto; gap: 10px; align-items: end; }
.search-form button { min-height: 42px; }
@media (max-width: 760px) { .panel-headline { align-items: flex-start; } .search-form { grid-template-columns: 1fr; align-items: stretch; } }

.personal-cue-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: end; margin: 10px 0 14px; }
.personal-cue-form textarea { min-height: 48px; }
.personal-cue-form button { min-height: 38px; }
@media (max-width: 760px) { .personal-cue-form { grid-template-columns: 1fr; } }

.schema-list { display: grid; gap: 10px; }
.schema-list-card { display: grid; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.schema-list-row { display: grid; gap: 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.schema-list-row:hover { border-color: #b7e4dc; }
.schema-list-row span { color: var(--muted); }
.training-day-result { border-left: 4px solid var(--line); }
.training-day-result.status-volbracht { border-left-color: #0f8a5f; }
.training-day-result.status-deels { border-left-color: #d97706; }
.training-day-result.status-niet-gestart { border-left-color: #b42318; }
.schema-list-card .schema-list-row { padding: 0; border: 0; border-radius: 0; background: transparent; }
.schema-hub { display: grid; gap: 12px; }
.schema-hub-card { border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; box-shadow: 0 10px 28px rgba(15, 23, 42, .04); }
.schema-hub-card summary { display: grid; grid-template-columns: minmax(0, 1fr); gap: 3px; padding: 16px 18px; cursor: pointer; list-style: none; }
.schema-hub-card summary::-webkit-details-marker { display: none; }
.schema-hub-card summary strong { font-size: 22px; }
.schema-hub-card summary span { color: var(--muted); font-weight: 650; }
.schema-hub-card[open] summary { border-bottom: 1px solid var(--line); background: #fbfefe; }
.schema-hub-card > form, .schema-hub-card > .schema-list { padding: 16px 18px; }
.schema-copy-form { display: grid; grid-template-columns: minmax(180px, 1.2fr) minmax(150px, .8fr) auto; gap: 8px; align-items: end; }
.schema-copy-form label { gap: 4px; font-size: 12px; color: var(--muted); }
.schema-copy-form input { min-height: 36px; padding: 7px 8px; }
.schema-copy-form button { min-height: 36px; }
.schema-delete-program-form { margin-top: 8px; display: flex; justify-content: flex-end; }
.schema-delete-program-form button { min-height: 34px; padding: 6px 10px; }
@media (max-width: 560px) { .schema-copy-form { grid-template-columns: 1fr; } }
.schema-status-panel { padding-top: 14px; padding-bottom: 14px; }
.schema-exercise-form { display: grid; grid-template-columns: minmax(220px, 1.8fr) repeat(5, minmax(90px, 1fr)) auto; gap: 10px; align-items: end; }
.schema-exercise-form .schema-wide { grid-column: 1 / -2; }
.schema-exercise-form textarea { min-height: 48px; }
.schema-planned-list { display: grid; gap: 12px; }
.schema-planned-row { display: grid; grid-template-columns: minmax(190px, 1.5fr) 86px 76px repeat(4, minmax(86px, 1fr)); gap: 10px; align-items: end; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.schema-planned-title { display: grid; gap: 3px; align-self: center; }
.schema-planned-title span { color: var(--muted); }
.schema-planned-row label { gap: 4px; font-size: 12px; color: var(--muted); }
.schema-planned-row input, .schema-planned-row textarea { min-height: 36px; padding: 7px 8px; }
.schema-planned-row .schema-wide { grid-column: 1 / -2; }
.schema-planned-row textarea { min-height: 48px; }
.schema-row-actions { display: flex; justify-content: flex-end; }
.schema-row-actions button { min-height: 36px; }
.schema-delete-form { margin: -6px 0 4px 12px; }
.trainer-day-mutate { margin: 12px 0 8px; }
@media (max-width: 980px) { .schema-exercise-form, .schema-planned-row { grid-template-columns: 1fr 1fr; } .schema-exercise-form .schema-wide, .schema-planned-row .schema-wide { grid-column: 1 / -1; } .schema-row-actions { justify-content: flex-start; } }
@media (max-width: 560px) { .schema-exercise-form, .schema-planned-row { grid-template-columns: 1fr; } .schema-delete-form { margin-left: 0; } }

.schema-board { display: grid; grid-template-columns: minmax(360px, .95fr) minmax(420px, 1.05fr); gap: 16px; align-items: start; }
.mobile-schema-builder { display: none; }
.schema-board-instruction { margin: -6px 0 14px; color: var(--muted); font-weight: 700; }
.exercise-palette, .schema-days-panel { position: sticky; top: 86px; max-height: calc(100vh - 110px); overflow: auto; }
.exercise-tile-list { display: grid; gap: 10px; margin-top: 12px; padding-right: 3px; }
.schema-repeat-days { margin-top: 10px; }
.schema-repeat-days legend { font-size: 12px; }
.exercise-build-tile { display: grid; gap: 10px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; cursor: grab; }
.exercise-build-tile.is-filtered-out { display: none !important; }
.exercise-build-tile:active { cursor: grabbing; }
.exercise-build-tile.is-selected { border-color: #b7e4dc; background: var(--soft); }
.exercise-build-head { display: grid; gap: 3px; }
.exercise-build-head span { color: var(--muted); font-weight: 650; }
.exercise-build-values { display: grid; grid-template-columns: 64px repeat(4, minmax(58px, 1fr)); gap: 8px; }
.exercise-build-values label, .exercise-build-cue { gap: 4px; font-size: 12px; color: var(--muted); }
.exercise-build-values input { min-height: 34px; padding: 6px 7px; }
.exercise-build-cue textarea { min-height: 48px; padding: 7px 8px; }
.schema-day-stack { display: grid; gap: 10px; }
.schema-drop-day { border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; }
.schema-drop-day[open] { border-color: #cbd5e1; }
.schema-drop-day.is-drop-target { border-color: #b7e4dc; background: var(--soft); }
.schema-drop-day summary { display: grid; grid-template-columns: minmax(0, 1fr) 34px; gap: 10px; align-items: center; padding: 12px 14px; cursor: pointer; }
.schema-drop-day summary span { display: grid; gap: 3px; }
.schema-drop-day summary small { color: var(--muted); font-weight: 650; }
.schema-day-dropzone { display: grid; gap: 10px; padding: 0 14px 14px; }
.drop-hint { margin: 0; padding: 10px 12px; border: 1px dashed #b7c4d4; border-radius: 8px; color: var(--muted); background: #f8fafc; }
.add-selected-day { justify-self: end; align-self: start; }
.schema-day-items { display: grid; gap: 8px; }
.schema-day-item { display: grid; gap: 2px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.schema-day-item span, .schema-day-item small { color: var(--muted); }
.schema-item-actions { display: flex; gap: 7px; align-items: center; justify-content: flex-end; margin-top: 6px; }
.schema-item-actions form { display: inline-flex; gap: 6px; align-items: center; width: auto; }
.schema-item-actions select { min-height: 32px; padding: 5px 28px 5px 8px; font-size: 13px; }
.danger-icon { color: #b42318; border-color: #f0b8b2; background: #fff5f5; }
@media (max-width: 980px) {
  .schema-board { grid-template-columns: 1fr; }
  .exercise-palette, .schema-days-panel { position: static; max-height: none; overflow: visible; }
}
@media (max-width: 560px) {
  .exercise-build-values { grid-template-columns: 1fr 1fr; }
  .schema-drop-day summary { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .schema-board, .schema-board-instruction { display: none; }
  .mobile-schema-builder { display: grid; gap: 12px; }
  .mobile-day-stack { display: grid; gap: 10px; }
  .mobile-day-card { border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; }
  .mobile-day-card summary { display: grid; gap: 3px; padding: 12px 14px; cursor: pointer; }
  .mobile-day-card summary span { color: var(--muted); font-weight: 650; }
  .mobile-add-exercise { display: grid; gap: 10px; padding: 0 14px 14px; border-bottom: 1px solid var(--line); }
  .mobile-add-exercise select, .mobile-add-exercise input, .mobile-add-exercise textarea { min-height: 38px; padding: 7px 8px; }
  .mobile-quick-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
  .mobile-quick-fields label { gap: 4px; font-size: 12px; color: var(--muted); }
  .mobile-day-card .schema-day-items { padding: 12px 14px 14px; }
}

.brand { display: inline-flex; align-items: center; min-width: 0; }
.brand-logo { display: block; height: 68px; width: auto; max-width: 380px; }
.tenant-logo { width: auto; max-width: 92px; height: 34px; object-fit: contain; border-radius: 4px; }
.logo-preview { display: inline-flex; align-items: center; justify-content: flex-start; min-height: 48px; margin-bottom: 2px; }
.logo-preview img { width: auto; max-width: 180px; max-height: 64px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; padding: 6px; background: #fff; }
.trainer-identity { display: inline-flex; align-items: center; gap: 8px; margin: 7px 0 0; color: var(--muted); font-weight: 700; }
.trainer-identity img { width: auto; max-width: 96px; height: 30px; object-fit: contain; border-radius: 4px; }
.topbar .icon { width: 22px; height: 22px; }
.icon { display: inline-block; width: 20px; height: 20px; object-fit: contain; vertical-align: middle; }
.icon-btn .icon { width: 18px; height: 18px; }
.app-page-icon { width: 34px; height: 34px; }
@media (max-width: 760px) { .brand-logo { height: 56px; max-width: 300px; } .tenant-logo { max-width: 70px; height: 28px; } }

.page-head .eyebrow { display: inline-flex; align-items: center; gap: 7px; }
.page-head .eyebrow::before { content: ''; width: 18px; height: 18px; flex: 0 0 18px; background: url('/static/logo/color/icon.svg') center / contain no-repeat; }
@media (max-width: 760px) {
  .page-head .eyebrow.mobile-redundant-title { display: none; }
}

.page-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.two-column { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.button-secondary { background: #fff; color: var(--ink); border: 1px solid var(--line); }
.button-secondary:hover { background: var(--soft); color: var(--accent-dark); }
.button-secondary.danger { color: #b42318; border-color: #f0b8b2; }
.button-secondary.danger:hover { background: #fff5f5; color: #8f1d14; }

.appointment-list { display: grid; gap: 10px; }
.appointment-card { display: grid; gap: 7px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.appointment-card div { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.appointment-card strong { font-size: 18px; }
.appointment-card span, .appointment-card small { color: var(--muted); }
.appointment-card p { margin: 0; font-weight: 750; }
.appointment-card form { margin-top: 3px; }
.appointment-card button { min-height: 34px; padding: 6px 10px; }
.appointment-calendar-select { justify-self: start; margin-top: 3px; }

.nutrition-intro { display: grid; gap: 5px; margin-bottom: 16px; }
.nutrition-intro strong { font-size: 22px; }
.nutrition-intro span, .nutrition-intro p { color: var(--muted); margin: 0; }
.athlete-nutrition { display: grid; gap: 14px; }
.nutrition-builder { display: grid; grid-template-columns: minmax(280px, .75fr) minmax(360px, 1.25fr); gap: 16px; align-items: start; }
.nutrition-plan-panel, .nutrition-palette { position: sticky; top: 86px; }
.day-checks { display: flex; flex-wrap: wrap; gap: 8px; border: 1px solid var(--line); border-radius: 8px; padding: 10px; }
.day-checks legend { color: var(--muted); font-weight: 750; padding: 0 6px; }
.day-checks label { display: inline-flex; width: auto; min-height: 30px; align-items: center; gap: 6px; padding: 3px 8px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-size: 13px; }
.day-checks input { width: auto; min-height: auto; }
.meal-drag-card { display: grid; gap: 3px; padding: 12px; border: 1px dashed #9fb4c8; border-radius: 8px; background: #f8fafc; cursor: grab; }
.meal-drag-card:active { cursor: grabbing; }
.meal-drag-card span { color: var(--muted); }
.nutrition-delete-plan-form { margin-top: 10px; display: flex; justify-content: flex-end; }
.nutrition-delete-plan-form button { min-height: 34px; padding: 6px 10px; }
.nutrition-days { display: grid; gap: 10px; }
.nutrition-day-detail { border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; }
.nutrition-day-detail[open] { border-color: #cbd5e1; }
.nutrition-day-detail.is-drop-target { border-color: #b7e4dc; background: var(--soft); }
.nutrition-day-detail summary { display: grid; grid-template-columns: minmax(0, 1fr); gap: 3px; padding: 12px 14px; cursor: pointer; }
.nutrition-day-detail summary span { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.nutrition-day-detail summary small { color: var(--muted); font-weight: 650; }
.nutrition-day-body { display: grid; gap: 9px; padding: 0 14px 14px; }
.meal-edit-card { border: 1px solid var(--line); border-radius: 8px; background: #fff; overflow: hidden; }
.meal-edit-card summary { padding: 10px 12px; background: #f8fafc; }
.meal-edit-card summary span { display: block; min-width: 0; overflow-wrap: anywhere; }
.meal-edit-form { display: grid; gap: 10px; padding: 12px; }
.nutrition-board { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.nutrition-day { display: grid; gap: 10px; align-content: start; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #f8fafc; }
.nutrition-day h3 { margin: 0; font-size: 18px; }
.meal-card { display: grid; gap: 7px; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.meal-head { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.meal-head span, .meal-card small { color: var(--muted); }
.meal-card p { margin: 0; font-weight: 750; }
.macro-fields { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.macro-row { display: flex; flex-wrap: wrap; gap: 6px; }
.macro-row span { display: inline-flex; min-height: 24px; align-items: center; padding: 0 8px; border-radius: 999px; background: var(--soft); color: var(--accent-dark); font-size: 12px; font-weight: 800; }
.meal-card form { justify-self: end; margin-top: -2px; }
@media (max-width: 760px) {
  .page-actions { justify-content: flex-start; width: 100%; }
  .two-column { grid-template-columns: 1fr; }
  .nutrition-builder { grid-template-columns: 1fr; }
  .nutrition-plan-panel, .nutrition-palette { position: static; }
  .appointment-card div { display: grid; gap: 2px; }
  .nutrition-board { grid-template-columns: 1fr; }
  .athlete-nutrition { gap: 12px; }
  .athlete-nutrition .nutrition-intro { margin: 0; padding: 0 2px; }
  .athlete-nutrition .nutrition-intro strong { display: none; }
  .athlete-nutrition .nutrition-intro span { font-size: 15px; }
  .athlete-nutrition .nutrition-intro p { font-size: 16px; line-height: 1.35; }
  .athlete-nutrition .nutrition-board { gap: 10px; }
  .athlete-nutrition .nutrition-day { padding: 0; border: 0; border-radius: 0; background: transparent; }
  .athlete-nutrition .nutrition-day h3 { font-size: 19px; padding: 0 2px; }
  .athlete-nutrition .meal-card { padding: 12px 14px; border-radius: 8px; }
  .macro-fields { grid-template-columns: 1fr 1fr; }
}

button.icon-btn.trainer-message-send {
  width: 46px;
  min-height: 42px;
  flex-basis: 46px;
  background: var(--accent);
  border-color: var(--accent);
}
button.icon-btn.trainer-message-send:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}
button.icon-btn.trainer-message-send .icon {
  width: 22px;
  height: 22px;
  filter: none;
}
