:root {
  --ink: #172a3a;
  --navy: #0d2232;
  --blue: #087ca7;
  --cyan: #13b5d1;
  --lime: #c6df42;
  --paper: #f6f7f2;
  --white: #fff;
  --muted: #71808b;
  --line: #dfe5e4;
  --success: #2d8a65;
  --shadow: 0 18px 60px rgba(17, 40, 56, .12);
}

* { box-sizing: border-box; }
html { width:100%; overflow-x:hidden; -webkit-text-size-adjust:100%; }
body { width:100%; margin: 0; overflow-x:hidden; font-family: "DM Sans", sans-serif; color: var(--ink); background: var(--paper); }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button, a, input, select, textarea { -webkit-tap-highlight-color: rgba(19,181,209,.18); }
img { max-width:100%; }
.hidden { display: none !important; }
.sr-only { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

.brand { display: flex; align-items: center; color: inherit; }
.brand img { display: block; object-fit: contain; }
.brand-wordmark img { width: min(410px, 78vw); height: auto; }
.brand-compact { width: 58px; height: 58px; overflow: hidden; border-radius: 9px; background: #000; }
.brand-compact img { width: 100%; height: 100%; }
.brand-mark { width: 42px; height: 42px; border: 3px solid var(--cyan); border-radius: 50%; position: relative; }
.brand-mark::after { content: ""; position: absolute; width: 25px; height: 4px; background: var(--lime); left: 21px; top: 17px; transform: rotate(-18deg); border-radius: 4px; }
.brand-copy strong { display: block; font-family: Oswald, sans-serif; font-size: 21px; letter-spacing: .04em; line-height: 1; }
.brand-copy small { font-size: 8px; letter-spacing: .17em; text-transform: uppercase; color: var(--muted); }

.login-shell { min-height: 100vh; display: grid; grid-template-columns: 1.1fr .9fr; background: #000; }
.login-hero { padding: 45px 7vw; color: white; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; background:#000; }
.login-hero::before { content: ""; width: 520px; height: 520px; border: 90px solid rgba(19,181,209,.12); border-radius: 50%; position: absolute; right: -180px; bottom: -230px; }
.login-hero .brand-copy small { color: #a9bcc8; }
.hero-copy { max-width: 610px; position: relative; z-index: 1; }
.eyebrow { color: var(--cyan); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; font-weight: 700; }
h1, h2, h3, p { margin-top: 0; }
.hero-copy h1 { font-family: Oswald, sans-serif; font-size: clamp(48px, 6vw, 86px); line-height: .96; text-transform: uppercase; margin: 18px 0 24px; }
.hero-copy h1 span { color: var(--lime); }
.hero-copy p { color: #bfd0d9; font-size: 18px; max-width: 520px; line-height: 1.6; }
.hero-tagline { display:block; width: min(260px,60vw); margin-top: 26px; border-radius: 8px; }
.login-note { color: #718b9c; font-size: 13px; }
.login-panel { background: var(--paper); display: grid; place-items: center; padding: 30px; border-radius: 38px 0 0 38px; }
.login-card { width: min(420px, 100%); }
.login-card h2 { font-family: Oswald, sans-serif; font-size: 36px; text-transform: uppercase; margin-bottom: 8px; }
.subtle { color: var(--muted); line-height: 1.5; }
.role-tabs { display: flex; background: #e8edeb; padding: 5px; border-radius: 12px; margin: 28px 0 22px; }
.role-tab { flex: 1; border: 0; padding: 11px; background: transparent; border-radius: 9px; color: var(--muted); font-weight: 600; }
.role-tab.active { background: white; color: var(--ink); box-shadow: 0 2px 9px rgba(10,30,42,.08); }
.field { margin-bottom: 17px; }
.field label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 7px; }
.field input, .field select, .field textarea { width: 100%; border: 1px solid var(--line); background: white; border-radius: 11px; padding: 13px 14px; outline: none; color: var(--ink); }
.field textarea { resize: vertical; min-height: 94px; }
#session-details,#template-details { min-height:150px; line-height:1.6; white-space:pre-wrap; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(19,181,209,.12); }
.primary-btn, .secondary-btn { border: 0; border-radius: 11px; padding: 13px 18px; font-weight: 700; }
.primary-btn { background: var(--lime); color: #203017; }
.primary-btn:hover { filter: brightness(.96); }
.secondary-btn { background: white; border: 1px solid var(--line); color: var(--ink); }
.full-btn { width: 100%; }
.demo-hint { margin-top: 18px; font-size: 12px; color: var(--muted); background: #edf1ef; padding: 12px; border-radius: 10px; }
.secure-note { margin: 26px 0 20px; font-size: 12px; font-weight: 700; color: var(--success); background: #e7f2ed; padding: 11px 13px; border-radius: 10px; }
.install-app-link { width: 100%; margin: 20px 0 8px; border: 1px solid rgba(19,181,209,.34); background: linear-gradient(135deg, rgba(19,181,209,.12), rgba(194,232,39,.18)); color: var(--ink); border-radius: 12px; padding: 13px 16px; font-weight: 800; text-align: center; box-shadow: 0 8px 22px rgba(10,30,42,.07); }
.install-app-link:hover { border-color: var(--cyan); transform: translateY(-1px); }
.install-app-status { min-height: 18px; margin: 0 0 18px; color: var(--muted); font-size: 12px; line-height: 1.45; }
.loading-screen { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 20px; background: var(--paper); }
.loading-pulse { width: 42px; height: 42px; border-radius: 50%; border: 4px solid #dbe3e1; border-top-color: var(--cyan); animation: spin .8s linear infinite; }
.loading-screen p { color: var(--muted); }
@keyframes spin { to { transform: rotate(360deg); } }

.app-shell { min-height: 100vh; }
.topbar { min-height: 96px; background: #000; border-bottom: 2px solid #00bfff; box-shadow:0 0 0 1px rgba(0,191,255,.35) inset,0 8px 28px rgba(0,60,120,.16); padding: 9px clamp(14px, 3.4vw, 54px); display: flex; align-items: center; justify-content: space-between; gap:22px; position: sticky; top: 0; z-index: 10; }
.brand-banner { display:flex; align-items:center; min-width:0; flex:1 1 auto; max-width:min(1040px, calc(100vw - 350px)); }
.brand-banner-inner { width:fit-content; max-width:100%; display:flex; align-items:center; justify-content:flex-start; gap:1cm; padding:7px 12px 7px 16px; border:2px solid #009dff; border-radius:18px; background:#000; box-shadow:0 0 22px rgba(0,157,255,.48), inset 0 0 20px rgba(0,157,255,.16); }
.banner-wordmark { width:clamp(420px,46vw,620px); max-height:70px; object-fit:contain; object-position:left center; }
.banner-tagline { width:clamp(105px,11vw,145px); max-height:70px; object-fit:contain; object-position:left center; }
.mobile-brand { display:none; }
.top-actions { display: flex; align-items: center; gap: 18px; }
.top-action-stack { display:flex; flex-direction:column; align-items:flex-end; gap:5px; }
.top-data-actions { display:flex; gap:6px; align-items:center; justify-content:flex-end; }
.top-data-actions button,
.top-data-actions a { border:1px solid rgba(0,191,255,.32); background:rgba(0,191,255,.08); color:#d5e6ee; border-radius:999px; padding:4px 8px; font-size:11px; font-weight:800; line-height:1; cursor:pointer; text-decoration:none; }
.top-data-actions button:hover,
.top-data-actions button:focus,
.top-data-actions a:hover,
.top-data-actions a:focus { color:#fff; border-color:#00bfff; background:rgba(0,191,255,.18); }
.user-chip { display: flex; align-items: center; gap: 10px; }
.topbar .user-chip strong { color:#fff; }
.topbar .subtle { color:#b8ceda !important; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: white; font-weight: 700; }
.topbar .avatar { background:#082033; border:1px solid rgba(0,191,255,.5); }
.logout { border: 0; background: transparent; color: #d5e6ee; }
.logout:hover,.logout:focus { color:#00bfff; }
.main { width: min(1180px, 92%); margin: 34px auto 70px; }
.welcome { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.welcome h1 { font-family: Oswald, sans-serif; text-transform: uppercase; font-size: clamp(35px, 5vw, 58px); line-height: 1; margin: 5px 0 8px; }
.coach-assignment-line { margin-top:8px; color:#52636d; font-size:14px; }
.coach-assignment-line strong { color:var(--navy); }
.welcome-actions { display: flex; gap: 9px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.athlete-view-head { align-items:flex-start; }
.coach-athlete-actions { width:min(760px,100%); display:grid; grid-template-columns:repeat(4,minmax(130px,1fr)); gap:10px; align-items:end; justify-content:end; }
.coach-athlete-actions .athlete-switcher { grid-column:span 2; min-width:0; width:100%; }
.coach-athlete-actions #compare-athlete-calendars { grid-column:span 2; }
.coach-athlete-actions #coach-athlete-month-pdf { grid-column:span 2; }
.coach-athlete-actions > button { width:100%; min-height:50px; justify-content:center; padding:10px 14px; }
.athlete-switcher { display:flex; flex-direction:column; gap:4px; min-width:190px; color:var(--muted); font-size:10px; font-weight:900; letter-spacing:.08em; text-transform:uppercase; }
.athlete-switcher select { width:100%; min-height:38px; border:1px solid var(--line); border-radius:10px; background:#fff; color:var(--navy); padding:8px 10px; font-size:13px; font-weight:800; text-transform:none; letter-spacing:0; }
.athlete-switcher select:focus { outline:2px solid rgba(0,191,255,.28); border-color:var(--cyan); }
.date-pill { background: var(--navy); color: white; border-radius: 14px; padding: 13px 18px; white-space: nowrap; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.stat { background: white; border: 1px solid var(--line); padding: 20px; border-radius: 16px; }
.stat-value { font-family: Oswald, sans-serif; font-size: 34px; }
.stat-label { color: var(--muted); font-size: 13px; }
.dashboard-grid { display: grid; grid-template-columns: 1fr 330px; gap: 22px; align-items: start; }
.card { background: white; border: 1px solid var(--line); border-radius: 18px; box-shadow: 0 7px 24px rgba(20,50,65,.04); }
.card-head { padding: 20px 22px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; }
.card-head h2 { font-family: Oswald, sans-serif; text-transform: uppercase; margin: 0; font-size: 24px; }
.month-nav { display: flex; gap: 7px; align-items: center; }
.icon-btn { width: 34px; height: 34px; border: 1px solid var(--line); background: white; border-radius: 9px; }
.calendar { padding: 18px; }
.calendar-weekday-row,.calendar-week-row { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:7px; align-items:stretch; min-width:0; overflow:visible; }
.calendar-week-rows { display:grid; gap:7px; }
.week-actions-spacer { width:34px; }
.weekdays, .calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 7px; min-width:0; }
.weekdays div { text-align: center; color: var(--muted); font-size: 11px; font-weight: 700; text-transform: uppercase; padding-bottom: 8px; min-width:0; }
.day { min-height: 92px; min-width:0; border: 1px solid var(--line); border-radius: 10px; padding: 8px; background: #fff; display:flex; flex-direction:column; overflow:hidden; }
.day-top { display:flex; align-items:center; justify-content:space-between; }
.day.muted { background: #f7f8f6; color: #b5bdbd; }
.day.month-jump { cursor:pointer; transition:border-color .15s, background .15s, color .15s, transform .15s; }
.day.month-jump:hover,.day.month-jump:focus { border-color:var(--cyan); background:#eefbfc; color:var(--blue); outline:none; transform:translateY(-1px); }
.day.today { border-color: var(--cyan); box-shadow: inset 0 0 0 1px var(--cyan); }
.day-num { font-size: 12px; font-weight: 700; }
.day-actions { display:flex; align-items:center; gap:3px; }
.day-add,.day-race-btn { width:22px; height:22px; border:0; border-radius:6px; font-weight:700; line-height:1; opacity:.25; transition:.15s; }
.day-add { background:#e6f5f8; color:var(--blue); }
.day-race-btn { display:grid; place-items:center; padding:0; background:#f2f6df; color:#5d661b; font-size:13px; }
.day-drag-btn { width:auto; min-width:30px; height:22px; padding:0 6px; border:0; border-radius:6px; background:#edf4ff; color:#2765a6; font-size:9px; font-weight:950; line-height:1; opacity:.4; cursor:grab; }
.day-drag-btn.dragging,.week-drag-btn.dragging { opacity:.65; cursor:grabbing; transform:scale(.97); }
.day:hover .day-add,.day-add:focus,.day:hover .day-race-btn,.day-race-btn:focus { opacity:1; }
.day:hover .day-drag-btn,.day-drag-btn:focus { opacity:1; }
.day-actions button:disabled { opacity:.1; cursor:not-allowed; }
.week-share-btn { width:25px; height:25px; display:grid; place-items:center; align-self:flex-end; margin-top:auto; padding:5px; border:0; border-radius:8px; background:#dff3e8; color:#168b51; opacity:.45; transition:.15s; }
.week-share-btn svg { width:100%; height:100%; overflow:visible; }
.week-share-btn path:first-child { fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.week-share-btn path:last-child { fill:currentColor; stroke:none; }
.day:hover .week-share-btn,.week-share-btn:focus { opacity:1; transform:translateY(-1px); box-shadow:0 4px 10px rgba(22,139,81,.18); }
.week-actions { display:flex; align-items:center; justify-content:flex-end; gap:4px; align-self:flex-end; margin-top:auto; }
.calendar-week-row > .week-actions { align-self:stretch; justify-content:center; flex-direction:column; min-width:34px; margin-top:0; padding:4px 0; border:1px solid var(--line); border-radius:10px; background:#fbfcfa; }
.week-actions .week-share-btn { align-self:auto; margin-top:0; }
.week-copy-btn { width:25px; height:25px; display:grid; place-items:center; padding:0; border:0; border-radius:8px; background:#e4efff; color:#2765a6; font-size:17px; line-height:1; opacity:.45; transition:.15s; }
.day:hover .week-copy-btn,.week-copy-btn:focus { opacity:1; transform:translateY(-1px); box-shadow:0 4px 10px rgba(39,101,166,.18); }
.week-download-btn { width:30px; height:25px; display:grid; place-items:center; padding:0; border:0; border-radius:8px; background:#f2f6df; color:#5d661b; font-size:9px; font-weight:900; line-height:1; opacity:.45; transition:.15s; cursor:pointer; }
.day:hover .week-download-btn,.week-download-btn:focus { opacity:1; transform:translateY(-1px); box-shadow:0 4px 10px rgba(93,102,27,.16); }
.calendar-week-row:hover .week-share-btn,.calendar-week-row:hover .week-copy-btn,.calendar-week-row:hover .week-download-btn,.calendar-week-row:hover .week-drag-btn,.week-share-btn:focus,.week-copy-btn:focus,.week-download-btn:focus,.week-drag-btn:focus { opacity:1; transform:translateY(-1px); }
.week-drag-btn { height:25px; padding:0 8px; border:0; border-radius:8px; background:#e4efff; color:#2765a6; font-size:9px; font-weight:950; text-transform:uppercase; letter-spacing:.04em; opacity:.48; transition:.15s; cursor:grab; }
.day:hover .week-drag-btn,.week-drag-btn:focus { opacity:1; transform:translateY(-1px); box-shadow:0 4px 10px rgba(39,101,166,.18); }
.session-chip { display: block; width: 100%; min-width:0; border: 1px solid #24d6ee; border-radius: 8px; padding: 6px 7px; margin-top: 7px; text-align: left; font-size: 10.5px; font-weight: 850; line-height: 1.18; background: #aef5ff; color: #052b3a; box-shadow: inset 0 0 0 1px rgba(255,255,255,.34), 0 2px 7px rgba(8,124,167,.08); overflow:hidden; }
.session-chip[draggable="true"] { cursor:grab; }
.session-chip.dragging { opacity:.55; cursor:grabbing; transform:scale(.98); }
.day.drop-target { outline:2px dashed var(--cyan); outline-offset:-5px; background:#f0fbfd; }
.session-chip-type,.session-chip-name { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.session-chip-type { font-weight:950; letter-spacing:-.01em; }
.session-chip-name { margin-top:2px; font-size:9.5px; font-weight:850; opacity:1; }
.session-chip.easy,.session-chip.long { background:#aef5ff; color:#052b3a; border-color:#24d6ee; }
.session-chip.quality,.session-chip.interval,.session-chip.hill,.session-chip.tempo,.session-chip.threshold,.session-chip.steady,.session-chip.fartlek { background: #0047AB; color: #fff; border-color:#00337c; text-shadow:0 1px 1px rgba(0,18,56,.28); box-shadow: inset 0 0 0 1px rgba(255,255,255,.22), 0 2px 8px rgba(0,71,171,.22); }
.session-chip.rest { background: #f4f6f2; color: #44535d; border: 1px dashed #aebdbb; box-shadow:none; }
.session-chip.incomplete { background: #a30209; color: #fff; border: 2px solid #470707; text-shadow:0 1px 1px rgba(80,0,0,.22); }
.session-chip.completed {
  background: #058731;
  color: #c9f2cc;
  border-color: #39ff14;
  text-decoration: none;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 0 0 2px rgba(57,255,20,.14);
}
.session-chip.unplanned-run { background:#FF5C00!important; color:#fff!important; border-color:#ff8a45!important; text-decoration:none!important; text-shadow:0 1px 1px rgba(92,22,0,.35); box-shadow: inset 0 0 0 1px rgba(255,255,255,.25), 0 0 0 2px rgba(255,92,0,.14), 0 4px 12px rgba(255,92,0,.2)!important; }
.session-chip.race:not(.completed) { background:#8A00C4; color:#fff; border:1px solid #b935ff; text-shadow:0 1px 1px rgba(46,0,70,.3); box-shadow:0 0 0 2px rgba(138,0,196,.16), 0 0 14px rgba(138,0,196,.18); }
.calendar-context-menu { position: fixed; z-index: 120; width: min(230px, calc(100vw - 16px)); padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: 0 18px 42px rgba(8, 28, 42, .24); }
.calendar-context-title { padding: 6px 8px 7px; color: var(--navy); font-size: 12px; font-weight: 900; border-bottom: 1px solid var(--line); margin-bottom: 5px; }
.calendar-context-menu button { display: block; width: 100%; padding: 9px 10px; border: 0; border-radius: 10px; background: transparent; color: var(--navy); text-align: left; font-size: 13px; font-weight: 800; cursor: pointer; }
.calendar-context-menu button:hover:not(:disabled), .calendar-context-menu button:focus:not(:disabled) { background: #eff9fb; color: var(--blue); outline: none; }
.calendar-context-menu button.danger { color: #b5473f; }
.calendar-context-menu button.danger:hover:not(:disabled), .calendar-context-menu button.danger:focus:not(:disabled) { background: #fff0ef; color: #9c302c; }
.calendar-context-menu button:disabled { opacity: .42; cursor: not-allowed; }
.calendar-context-menu small { display: block; padding: 7px 8px 4px; color: var(--muted); font-size: 10px; line-height: 1.25; }
.race-chip { display:block; width:100%; margin-top:6px; padding:5px 6px; overflow:hidden; border:1px solid #b935ff; border-radius:7px; background:#8A00C4; color:#fff; text-align:left; font-size:10.5px; font-weight:950; line-height:1.15; text-overflow:ellipsis; white-space:nowrap; text-shadow:0 1px 1px rgba(46,0,70,.3); box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 2px 8px rgba(138,0,196,.18); }
.race-chip:hover,.race-chip:focus { border-color:#d46cff; box-shadow:0 0 0 2px rgba(138,0,196,.28), 0 0 16px rgba(138,0,196,.22); }
.compare-main { width:100%; max-width:none; padding:0 clamp(12px,1.5vw,28px); margin-top:24px; }
.compare-head { align-items:flex-start; margin-bottom:18px; }
.compare-head > div { max-width:980px; }
.compare-calendar-layout { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:clamp(10px,1.2vw,18px); align-items:start; }
.compare-calendar-panel { min-width:0; overflow:hidden; }
.compare-panel-head { display:grid; gap:12px; padding:16px; border-bottom:1px solid var(--line); background:linear-gradient(180deg,#fff,#fbfcfa); }
.compare-panel-select-row { display:grid; grid-template-columns:minmax(0,2fr) minmax(150px,1fr); gap:10px; align-items:end; }
.compare-panel-head .athlete-switcher { width:100%; min-width:0; }
.compare-panel-month-row { display:flex; align-items:center; justify-content:space-between; gap:12px; min-width:0; }
.compare-panel-month-controls { display:flex; align-items:center; gap:10px; min-width:0; }
.compare-panel-month-controls h2 { margin:0; font-family:Oswald,sans-serif; font-size:clamp(22px,1.8vw,30px); line-height:1; text-transform:uppercase; white-space:nowrap; }
.compare-panel-month-controls .month-nav { width:auto; flex:0 0 auto; justify-content:flex-start; }
.compare-panel-month-controls .icon-btn { width:38px; height:38px; }
.compare-panel-head .compact-btn { flex:0 0 auto; padding:9px 12px; white-space:nowrap; }
.compare-calendar-panel .calendar { padding:12px; overflow-x:auto; -webkit-overflow-scrolling:touch; }
.compare-calendar-panel .weekdays,
.compare-calendar-panel .calendar-grid { min-width:0; gap:5px; }
.compare-calendar-panel .day { min-height:88px; padding:6px; }
.compare-calendar-panel .session-chip,
.compare-calendar-panel .race-chip { font-size:9.5px; padding:5px 6px; margin-top:5px; }
.compare-calendar-panel .day-actions { flex-wrap:wrap; justify-content:flex-end; max-width:94px; }
.compare-week-actions { width:100%; }
.side-card { padding-bottom: 8px; }
.next-session { padding: 21px; }
.type-badge { display: inline-block; color: #586717; background: #edf4c9; border-radius: 99px; padding: 6px 10px; font-size: 11px; font-weight: 700; text-transform: uppercase; }
.type-badge.rest { color: #667781; background: #eef1f0; }
.type-badge.race { color:#fff; background:#8A00C4; box-shadow:0 0 0 1px #b935ff inset; }
.next-session h3 { font-size: 24px; margin: 14px 0 8px; }
.meta-list { list-style: none; padding: 0; margin: 18px 0; }
.meta-list li { padding: 8px 0; border-bottom: 1px solid #edf0ef; display: flex; justify-content: space-between; font-size: 13px; }
.meta-list span { color: var(--muted); }
.recent { padding: 0 21px 12px; }
.recent-item { width:100%; padding:14px 0; border:0; border-bottom:1px solid var(--line); display:flex; gap:12px; text-align:left; background:transparent; color:inherit; }
.recent-item:hover strong { color:var(--blue); }
.recent-dot { width: 9px; height: 9px; margin-top: 5px; background: var(--success); border-radius: 50%; flex: 0 0 auto; }
.recent-item strong { display: block; font-size: 13px; }
.recent-item small { color: var(--muted); }
.athlete-lower-grid { display: grid; grid-template-columns: 1.45fr .75fr; gap: 22px; margin-top: 22px; align-items: start; }
.empty-state { text-align: center; padding: 42px 20px; color: var(--muted); }
.empty-state strong { color: var(--ink); }
.empty-state p { margin: 7px 0 0; }
.feeling { display: inline-block; padding: 5px 9px; border-radius: 99px; background: #e5f3ed; color: #2b7358; font-size: 11px; font-weight: 700; }
.feeling.alert { background: #f8e1e1; color: #9a3f3f; }
.progress-body { padding: 24px; text-align: center; }
.progress-ring { --progress: 0deg; width: 150px; height: 150px; margin: 0 auto 22px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(var(--lime) var(--progress), #e7ebe8 0); position: relative; }
.progress-ring::after { content: ""; position: absolute; inset: 13px; border-radius: 50%; background: white; }
.progress-ring div { position: relative; z-index: 1; }
.progress-ring strong { display: block; font-family: Oswald, sans-serif; font-size: 36px; }
.progress-ring small { display: block; color: var(--muted); }
.progress-metrics { display: grid; grid-template-columns: repeat(3,1fr); gap: 5px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 16px 0; margin-bottom: 16px; }
.progress-metrics strong { display: block; font-size: 19px; }
.progress-metrics span { display: block; color: var(--muted); font-size: 10px; }
.load-progress-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; margin:0 0 16px; }
.load-progress-metrics > div { padding:11px; border-radius:10px; background:#f2f7e1; text-align:center; }
.load-progress-metrics strong,.load-progress-metrics span { display:block; }
.load-progress-metrics strong { color:var(--navy); font-size:17px; }
.load-progress-metrics span { margin-top:2px; color:var(--muted); font-size:9px; text-transform:uppercase; }
.athlete-cards { display: grid; grid-template-columns: repeat(3,1fr); gap: 12px; padding: 18px; }
.athlete-card { border: 1px solid var(--line); border-radius: 13px; padding: 14px; min-width: 0; }
.athlete-card-top { display: flex; gap: 10px; align-items: center; }
.athlete-card-top .avatar { width: 34px; height: 34px; font-size: 11px; flex: 0 0 auto; }
.athlete-card-top strong, .athlete-card-top span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.athlete-name-link,.profile-name-link { border:0; background:transparent; color:var(--ink); padding:0; text-align:left; font-weight:700; }
.athlete-name-link:hover,.profile-name-link:hover { color:var(--blue); text-decoration:underline; }
.athlete-name-link { font-size:14px; }
.athlete-card-top span { color: var(--muted); font-size: 10px; margin-top: 2px; }
.athlete-contact { margin:14px 0 4px; display:grid; grid-template-columns:1fr 1.5fr; gap:8px 12px; }
.athlete-contact div { min-width:0; }
.athlete-contact dt { color:var(--muted); font-size:9px; text-transform:uppercase; letter-spacing:.05em; }
.athlete-contact dd { margin:2px 0 0; font-size:11px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.mini-progress { height: 5px; margin: 14px 0 8px; background: #e7ebe8; border-radius: 99px; overflow: hidden; }
.mini-progress i { display: block; height: 100%; background: var(--lime); border-radius: inherit; }
.athlete-card-meta { display: flex; justify-content: space-between; gap: 5px; color: var(--muted); font-size: 9px; }
.coach-dashboard-columns { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:18px; align-items:start; }
.coach-dashboard-columns > .card { min-width:0; }
.coach-athletes-card .athlete-list-row { grid-template-columns:38px minmax(0,1fr); gap:10px; padding:10px; }
.coach-athletes-card .athlete-status-pill { grid-column:2; justify-self:start; padding:5px 8px; font-size:9px; }
.coach-athletes-card .athlete-list-metrics { grid-column:1/-1; grid-template-columns:1fr 1fr; text-align:left; gap:4px; font-size:10px; }
.coach-athletes-card .athlete-list-main span { font-size:11px; }
.coach-recent-card .coach-table table { min-width:720px; }
.coach-dashboard-session-list { display:grid; gap:9px; max-height:720px; overflow-y:auto; padding:12px 14px 16px; }
.coach-dashboard-session-item { min-width:0; padding:12px; border:1px solid var(--line); border-radius:13px; background:#fbfcfa; box-shadow:0 4px 12px rgba(6,26,38,.06); }
.coach-dashboard-session-item.completed-session { box-shadow:inset 4px 0 0 rgba(5,135,49,.54),0 4px 12px rgba(6,26,38,.06); }
.coach-dashboard-session-item.upcoming-session { box-shadow:inset 4px 0 0 rgba(0,179,255,.62),0 4px 12px rgba(6,26,38,.06); }
.coach-dashboard-session-kicker { display:flex; align-items:flex-start; justify-content:space-between; gap:8px; margin-bottom:7px; color:var(--muted); font-size:9px; font-weight:900; letter-spacing:.04em; text-transform:uppercase; }
.coach-dashboard-session-kicker span { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.coach-dashboard-session-kicker span:last-child { text-align:right; }
.coach-dashboard-session-title { display:block; width:100%; margin:0 0 8px; overflow:hidden; color:var(--navy); font-size:13px; font-weight:950; text-align:left; text-overflow:ellipsis; white-space:nowrap; }
.coach-dashboard-athlete-line { display:flex; align-items:baseline; gap:7px; min-width:0; }
.coach-dashboard-athlete-line .athlete-name-link { min-width:0; overflow:hidden; font-size:12px; text-overflow:ellipsis; white-space:nowrap; }
.coach-dashboard-athlete-line > span { min-width:0; overflow:hidden; color:var(--muted); font-size:10px; text-overflow:ellipsis; white-space:nowrap; }
.coach-dashboard-session-result { display:grid; gap:2px; margin-top:9px; padding-top:8px; border-top:1px solid var(--line); }
.coach-dashboard-session-result strong { min-width:0; overflow:hidden; color:var(--ink); font-size:11px; text-overflow:ellipsis; white-space:nowrap; }
.coach-dashboard-session-result span { min-width:0; overflow:hidden; color:var(--muted); font-size:10px; text-overflow:ellipsis; white-space:nowrap; }
.athlete-list { display:grid; gap:8px; padding:12px 16px 16px; }
.athlete-folder-list { gap:10px; }
.athlete-folder { overflow:hidden; border:1px solid var(--line); border-radius:14px; background:#fbfcfa; }
.athlete-folder summary { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 14px; cursor:pointer; list-style:none; }
.athlete-folder summary::-webkit-details-marker { display:none; }
.athlete-folder summary::before { content:"▸"; color:var(--blue); font-weight:900; transition:.18s; }
.athlete-folder[open] summary::before { transform:rotate(90deg); }
.athlete-folder summary div { flex:1; min-width:0; }
.athlete-folder summary strong { display:block; font-family:Oswald,sans-serif; color:var(--navy); font-size:18px; text-transform:uppercase; }
.athlete-folder summary span { display:block; margin-top:2px; color:var(--muted); font-size:11px; }
.athlete-folder summary em { min-width:30px; padding:5px 9px; border-radius:999px; background:#e6f5f8; color:var(--blue); text-align:center; font-style:normal; font-size:11px; font-weight:900; }
.athlete-folder-rows { display:grid; gap:8px; padding:0 10px 10px; }
.athlete-list-row { display:grid; grid-template-columns:42px minmax(0,1fr) auto minmax(230px,.9fr); gap:12px; align-items:center; padding:12px; border:1px solid var(--line); border-radius:12px; background:#fff; }
.athlete-list-row.is-inactive { opacity:.62; }
.athlete-list-main { min-width:0; }
.athlete-list-main span { display:block; margin-top:3px; overflow:hidden; color:var(--muted); font-size:12px; text-overflow:ellipsis; white-space:nowrap; }
.athlete-status-pill { justify-self:start; padding:6px 9px; border-radius:999px; background:#e5f3ed; color:#27684f; font-size:10px; font-weight:900; text-transform:uppercase; white-space:nowrap; }
.athlete-status-pill.attention { background:#f8e1e1; color:#9a3f3f; }
.athlete-status-pill.inactive { background:#eef1f0; color:#708089; }
.athlete-list-metrics { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; color:var(--muted); font-size:11px; text-align:right; }
.athlete-list-metrics span { min-width:0; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.athlete-list-metrics strong { color:var(--ink); }
.text-alert { color: #a23f3f; font-weight: 700; }
.back-link { border:0; background:transparent; color:var(--blue); padding:0; margin:0 0 18px; font-weight:700; }
.profile-manager { display:grid; grid-template-columns:minmax(320px,.8fr) 1.2fr; gap:22px; align-items:start; }
.profile-form { padding:24px; }
.profile-form small { display:block; color:var(--muted); margin-top:7px; }
.profile-avatar-preview { width:72px; height:72px; border-radius:50%; display:grid; place-items:center; margin:0 auto 24px; background:var(--navy); color:white; font-family:Oswald,sans-serif; font-size:26px; }
.active-toggle { display:flex; align-items:center; gap:9px; padding:12px 0 20px; font-size:13px; font-weight:700; }
.active-toggle input { accent-color:var(--blue); width:18px; height:18px; }
.profile-list { padding:8px 20px 18px; }
.profile-category-list { display:grid; gap:10px; padding-top:12px; }
.profile-category { border:1px solid var(--line); border-radius:14px; background:#fbfcfa; overflow:hidden; }
.profile-category summary { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 14px; cursor:pointer; list-style:none; }
.profile-category summary::-webkit-details-marker { display:none; }
.profile-category summary strong { display:block; color:var(--navy); font-size:14px; }
.profile-category summary span { display:block; color:var(--muted); font-size:11px; margin-top:2px; }
.profile-category summary em { min-width:28px; height:28px; display:grid; place-items:center; border-radius:999px; background:#eaf6fb; color:var(--blue); font-style:normal; font-weight:900; }
.profile-category-rows { padding:0 14px 4px; }
.profile-category .profile-row:last-child { border-bottom:0; }
.profile-row { display:grid; grid-template-columns:42px minmax(0,1fr) auto auto auto; align-items:center; gap:12px; padding:14px 0; border-bottom:1px solid var(--line); }
.profile-row:last-child { border-bottom:0; }
.profile-row-copy { min-width:0; }
.profile-row-copy strong,.profile-row-copy span { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.profile-name-link { display:block; font-size:13px; }
.profile-row-copy span { color:var(--muted); font-size:12px; margin-top:3px; }
.athlete-title-row { display:flex; align-items:center; gap:16px; }
.avatar.large { width:68px; height:68px; font-size:20px; }
.athlete-info-grid { display:grid; grid-template-columns:.6fr 1fr 1.5fr 1fr; gap:12px; margin-bottom:22px; }
.athlete-info-grid > div { background:white; border:1px solid var(--line); border-radius:13px; padding:15px; min-width:0; }
.athlete-info-grid span { display:block; color:var(--muted); font-size:10px; text-transform:uppercase; letter-spacing:.06em; margin-bottom:5px; }
.athlete-info-grid strong { display:block; font-size:13px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.athlete-info-grid a { color:var(--blue); text-decoration:none; }

.modal-backdrop { position: fixed; inset: 0; background: rgba(6,23,34,.72); display: grid; place-items: center; padding: 20px; z-index: 30; }
.modal { width: min(590px, 100%); max-height: 92vh; overflow: auto; background: var(--paper); border-radius: 20px; box-shadow: var(--shadow); }
.modal-top { padding: 24px 26px; background: var(--navy); color: white; position: relative; }
.modal-top h2 { font-family: Oswald, sans-serif; text-transform: uppercase; font-size: 32px; margin: 10px 40px 4px 0; }
.close { position: absolute; right: 17px; top: 17px; border: 0; background: rgba(255,255,255,.12); color: white; width: 34px; height: 34px; border-radius: 50%; }
.modal-body { padding: 25px 26px; }
.workout-block { background: white; border-left: 4px solid var(--cyan); padding: 16px; border-radius: 0 10px 10px 0; line-height: 1.55; margin: 17px 0; white-space:pre-line; }
.detail-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 15px 0; }
.detail { background: white; padding: 12px; border-radius: 10px; }
.race-priority-strip { display:flex; align-items:center; justify-content:space-between; gap:12px; margin:0 0 14px; padding:13px 15px; border:1px solid #dbe9a8; border-radius:13px; background:#fbfdea; }
.race-priority-strip strong { color:var(--navy); font-size:15px; }
.race-goal-pill { display:inline-flex; align-items:center; width:max-content; padding:7px 11px; border-radius:999px; font-size:10px; font-weight:900; text-transform:uppercase; letter-spacing:.05em; }
.race-goal-pill.goal { color:#5d3b00; background:#ffe3a3; }
.race-goal-pill.sub_goal { color:#075f72; background:#dff5f8; }
.race-goal-pill.non_goal { color:#667781; background:#eef1f0; }
.training-focus-card { display:flex; align-items:center; justify-content:space-between; gap:16px; margin:10px 0 20px; padding:13px 15px; border:1px solid #b9e8ff; border-radius:12px; background:#effaff; }
.training-focus-card small { color:var(--muted); font-weight:700; }
.training-focus-card strong { color:var(--blue); text-align:right; }
.training-focus-card span { color:var(--muted); font-size:11px; line-height:1.4; text-align:right; }
.load-score-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:9px; margin:0 0 20px; }
.load-score-grid > div { padding:13px; border:1px solid #dbe9a8; border-radius:12px; background:#f8fbe9; }
.load-score-grid small,.load-score-grid span { display:block; color:var(--muted); font-size:10px; line-height:1.35; }
.load-score-grid strong { display:block; margin:4px 0 2px; color:var(--navy); font-size:18px; }
.training-focus-label { display:inline-block; margin-top:6px; padding:4px 8px; border-radius:999px; background:#eaf8ff; color:#0878b9; font-size:.78rem; font-weight:800; }
.repeat-results-card { margin:0 0 22px; padding:18px; border:1px solid #b9e8ff; border-radius:14px; background:#f4fbff; }
.fit-upload-card { margin:0 0 20px; padding:18px; border:1px dashed #8fcbd8; border-radius:14px; background:#f5fcfd; }
.fit-upload-copy h4 { margin:4px 0 5px; color:var(--navy); font-size:18px; }
.fit-upload-copy p { margin:0 0 13px; color:var(--muted); font-size:12px; line-height:1.5; }
.fit-upload-button { display:inline-flex; align-items:center; justify-content:center; cursor:pointer; }
.fit-upload-status { margin:10px 0 0; color:var(--muted); font-size:12px; font-weight:700; }
.workout-feedback-card { margin:0 0 20px; padding:18px; border:1px solid #b9e8ff; border-radius:14px; background:#f4fbff; }
.workout-feedback-head { display:flex; justify-content:space-between; align-items:start; gap:12px; margin-bottom:8px; }
.workout-feedback-head h4 { margin:4px 0 0; color:var(--navy); font-size:17px; }
.workout-feedback-head > span { padding:5px 8px; border-radius:99px; background:#dff7e9; color:#24724d; font-size:9px; font-weight:900; text-transform:uppercase; }
.workout-feedback-card > p { margin:0 0 12px; color:var(--muted); font-size:12px; line-height:1.5; }
.workout-feedback-actions { display:flex; flex-wrap:wrap; gap:8px; }
.workout-feedback-card textarea { width:100%; min-height:125px; margin-top:12px; padding:13px 14px; resize:vertical; border:1px solid #9dd4e9; border-radius:11px; background:white; color:var(--ink); font:inherit; line-height:1.5; }
.workout-feedback-card textarea:focus { outline:none; border-color:var(--blue); box-shadow:0 0 0 3px rgba(0,157,220,.12); }
.workout-feedback-card button:disabled { opacity:.45; cursor:not-allowed; }
.workout-feedback-status { min-height:18px; margin:8px 0 10px!important; color:#24724d!important; font-size:11px!important; font-weight:700; }
.saved-workout-feedback { margin-top:18px; }
.fit-analysis-card { margin-top:16px; padding:17px; border:1px solid #b9dce4; border-radius:14px; background:white; }
.fit-analysis-head { display:flex; justify-content:space-between; align-items:start; gap:14px; margin-bottom:14px; }
.fit-analysis-head h4 { margin:4px 0 0; color:var(--navy); font-size:17px; text-transform:capitalize; }
.fit-verified { padding:5px 9px; border-radius:99px; background:#dceee7; color:#296e54; font-size:10px; font-weight:800; text-transform:uppercase; }
.fit-comparison-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.fit-comparison-grid > div { padding:11px; border:1px solid var(--line); border-radius:10px; background:#fafcfb; }
.fit-comparison-grid small,.fit-comparison-grid span { display:block; color:var(--muted); font-size:10px; }
.fit-comparison-grid strong { display:block; margin:4px 0 3px; color:var(--navy); font-size:15px; }
.fit-laps { margin-top:13px; border-top:1px solid var(--line); }
.fit-laps summary { padding:11px 0 3px; color:var(--blue); font-size:12px; font-weight:800; cursor:pointer; }
.fit-lap-table { max-height:270px; overflow:auto; margin-top:8px; border:1px solid var(--line); border-radius:10px; }
.fit-lap-table th,.fit-lap-table td { padding:8px 10px; white-space:nowrap; font-size:11px; }
.fit-analysis-meta { display:flex; flex-wrap:wrap; gap:7px; margin-top:12px; }
.fit-analysis-meta span:not(:empty) { padding:5px 8px; border-radius:7px; background:#eff3f2; color:var(--muted); font-size:10px; font-weight:700; }
.fit-history-badge { display:inline-flex; margin-left:7px; padding:3px 6px; border-radius:6px; background:#e4efff; color:#2765a6; font-size:9px; font-weight:900; vertical-align:middle; }
.fit-progress-metrics { grid-column:1/-1; display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:8px; width:100%; margin-top:12px; }
.fit-progress-metrics > div { padding:10px; border-radius:9px; background:#f2f7f8; text-align:center; }
.fit-progress-metrics strong,.fit-progress-metrics span { display:block; }
.fit-progress-metrics strong { color:var(--navy); font-size:14px; }
.fit-progress-metrics span { margin-top:2px; color:var(--muted); font-size:9px; text-transform:uppercase; }
.unplanned-run-modal .modal-top { background:linear-gradient(135deg,#0d2232 0%,#172a3a 72%,#FF5C00 150%); }
.unplanned-warning { margin:0 0 16px; padding:14px 15px; border-left:5px solid #FF5C00; border-radius:12px; background:#fff1e8; color:#8b2f00; font-size:13px; font-weight:800; line-height:1.45; }
.unplanned-title-card { margin:0 0 16px; padding:14px 16px; border:1px solid rgba(255,92,0,.35); border-radius:14px; background:linear-gradient(135deg,#fff7ef,#fff); }
.unplanned-title-card small { display:block; color:var(--muted); font-size:10px; font-weight:900; text-transform:uppercase; letter-spacing:.08em; }
.unplanned-title-card strong { display:block; margin-top:5px; color:#FF5C00; font-size:22px; }
.unplanned-target-control { margin:0 0 18px; padding:15px; border:1px solid #ffd0b5; border-radius:14px; background:#fffaf6; }
.unplanned-target-control > small,.unplanned-result-hint { display:block; margin-top:9px; color:#8b5b42; font-size:11px; font-weight:800; line-height:1.4; }
.unplanned-result-hint { margin:0 0 9px; padding:9px 11px; border-radius:10px; background:#fff4ec; }
.unplanned-result-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
.unplanned-run-modal .modal-actions .primary-btn { background:#FF5C00; color:#fff; }
.unplanned-run-modal .modal-actions .primary-btn:hover { filter:brightness(.96); }
.repeat-results-head { display:flex; justify-content:space-between; align-items:start; gap:16px; }
.repeat-results-head h4 { margin:5px 0 0; font-size:17px; }
.repeat-unit { display:flex; align-items:center; gap:8px; color:var(--muted); font-size:12px; font-weight:700; }
.repeat-unit select { border:1px solid var(--line); border-radius:8px; padding:8px; background:white; }
.repeat-set { margin-top:16px; }
.repeat-set h5 { margin:0 0 9px; color:var(--navy); font-size:13px; text-transform:uppercase; letter-spacing:.05em; }
.repeat-set-heading { display:flex; justify-content:space-between; align-items:end; gap:12px; margin-bottom:9px; }
.repeat-set-heading h5 { margin:0 0 3px; }
.repeat-set-heading span { color:var(--muted); font-size:11px; font-weight:700; }
.repeat-result-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(105px,1fr)); gap:9px; }
.repeat-result-field { margin:0; }
.repeat-result-field input { background:white; }
.repeat-manual-rep-actions { display:flex; align-items:center; flex-wrap:wrap; gap:9px; margin-top:10px; }
.repeat-manual-rep-actions .secondary-btn { min-height:36px; padding:8px 12px; }
.repeat-manual-rep-actions small { color:var(--muted); font-size:11px; font-weight:700; }
.modal-backdrop[data-fit-imported="true"] .repeat-manual-rep-actions,
.modal-backdrop[data-runner-imported="true"] .repeat-manual-rep-actions { display:none; }
.repeat-pace,.pace-preview,.saved-rep-pace { display:block; margin-top:4px; color:var(--blue); font-size:11px; font-weight:900; line-height:1.25; }
.saved-rep-pace { color:#62707a; font-size:10px; }
.repeat-average { display:flex; justify-content:space-between; align-items:center; gap:12px; margin-top:17px; padding:13px 14px; border-radius:10px; background:var(--navy); color:white; }
.repeat-average span { color:#c8d8df; font-size:12px; font-weight:700; text-transform:uppercase; letter-spacing:.05em; }
.repeat-average strong { color:var(--cyan); font-size:20px; }
.repeat-average.set-average { margin-top:10px; padding:9px 11px; background:#eaf4f7; color:var(--navy); }
.repeat-average.set-average span { color:var(--muted); font-size:10px; }
.repeat-average.set-average strong { color:var(--blue); font-size:16px; }
.repeat-average.pace-average strong { color:#0047AB; }
.repeat-average.overall-average { margin-top:18px; }
.auto-splits summary { color:var(--navy); font-weight:900; }
.auto-split-table { margin-top:12px; }
.auto-split-table h5 { margin:0 0 8px; color:var(--blue); font-size:13px; text-transform:uppercase; letter-spacing:.05em; }
.logged-workout-link { border:0; padding:0; background:transparent; color:var(--blue); font:inherit; font-weight:800; text-align:left; text-decoration:underline; text-decoration-color:#9bdcf7; text-underline-offset:3px; }
.logged-workout-link:hover { color:var(--navy); }
.saved-workout-heading { margin:7px 0 17px; font-size:24px; }
.saved-result-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:9px; margin-bottom:18px; }
.saved-result-grid > div,.saved-segments > div,.saved-repeat-grid > div { padding:12px; border:1px solid var(--line); border-radius:10px; background:white; }
.saved-result-grid small,.saved-segments small,.saved-repeat-grid small,.saved-notes small { display:block; color:var(--muted); margin-bottom:4px; font-size:11px; text-transform:uppercase; letter-spacing:.04em; }
.saved-result-grid strong,.saved-segments strong,.saved-repeat-grid strong { color:var(--navy); font-size:13px; }
.saved-breakdown { margin:0 0 18px; padding:16px; border-radius:14px; background:#f4fbff; border:1px solid #b9e8ff; }
.saved-segments { display:grid; grid-template-columns:1fr 1fr; gap:9px; margin-bottom:14px; }
.saved-repeat-set + .saved-repeat-set { margin-top:15px; }
.saved-repeat-set h5 { margin:0 0 8px; color:var(--navy); }
.saved-repeat-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(90px,1fr)); gap:8px; }
.saved-repeat-grid > .is-unplanned-rep { border-color:#7adfff; box-shadow:inset 0 3px 0 rgba(0,179,255,.2); }
.saved-inside-splits { display:grid; gap:5px; margin-top:9px; padding-top:8px; border-top:1px solid #dcecf3; }
.saved-inside-splits span { display:flex; align-items:center; justify-content:space-between; gap:8px; }
.saved-inside-splits span small { margin:0; color:#5b7180; font-size:9px; letter-spacing:.02em; text-transform:none; }
.saved-inside-splits span strong { color:var(--blue); font-family:ui-monospace,SFMono-Regular,Consolas,monospace; font-size:11px; }
.saved-set-average { margin-top:8px; color:var(--muted); font-size:12px; text-align:right; }
.saved-notes { padding:15px; border-radius:12px; background:white; }
.saved-notes p { margin:3px 0 14px; }
.share-backdrop { position:fixed; inset:0; z-index:70; display:grid; place-items:center; padding:20px; background:rgba(6,23,34,.78); }
.share-dialog { position:relative; width:min(430px,100%); padding:26px; border-radius:18px; background:white; box-shadow:var(--shadow); }
.share-dialog h3 { margin:7px 35px 8px 0; font-size:24px; }
.share-dialog p { margin:0 0 20px; color:var(--muted); line-height:1.5; }
.share-close { position:absolute; right:16px; top:16px; width:34px; height:34px; border:0; border-radius:50%; background:#edf1ef; color:var(--navy); font-size:20px; }
.share-actions { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.share-option { display:flex; justify-content:center; align-items:center; min-height:48px; border:0; border-radius:11px; color:white; font-weight:800; text-decoration:none; }
.share-option.whatsapp { background:#168b51; }
.share-option.business { background:#075e54; }
.share-option:hover { filter:brightness(.94); }
.share-note { margin:14px 0 0!important; padding:10px 12px; border-radius:10px; background:#eef7f3; color:#2c7257!important; font-size:12px; }
.month-pdf-choice-grid { display:grid; gap:12px; }
.month-pdf-choice-card { display:grid; grid-template-columns:minmax(160px,.6fr) minmax(0,1.4fr); gap:12px; align-items:center; padding:14px; border:1px solid var(--line); border-radius:14px; background:#fbfcfa; }
.month-pdf-choice-card strong,.month-pdf-choice-card span { display:block; }
.month-pdf-choice-card strong { color:var(--navy); font-family:Oswald,sans-serif; font-size:22px; text-transform:uppercase; }
.month-pdf-choice-card span { margin-top:3px; color:var(--muted); font-size:13px; }
.month-pdf-actions { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:8px; }
.month-pdf-actions .secondary-btn { min-height:44px; padding:9px 10px; }
.message-layout { display:grid; grid-template-columns:340px minmax(0,1fr); gap:22px; align-items:start; }
.message-layout.athlete-only { grid-template-columns:minmax(0,760px); justify-content:center; }
.message-list-card,.message-thread-card { overflow:hidden; }
.message-thread-list { display:grid; gap:8px; padding:12px; max-height:68vh; overflow:auto; }
.message-thread-link { width:100%; display:grid; grid-template-columns:38px minmax(0,1fr) auto; gap:10px; align-items:center; padding:11px; border:1px solid var(--line); border-radius:12px; background:#fff; color:inherit; text-align:left; }
.message-thread-link.active { border-color:var(--cyan); box-shadow:0 0 0 3px rgba(19,181,209,.1); }
.message-thread-link strong,.message-thread-link span { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.message-thread-link strong { font-size:13px; }
.message-thread-link span { margin-top:2px; color:var(--muted); font-size:11px; }
.message-thread-link em { min-width:24px; padding:4px 6px; border-radius:999px; background:#eef3f2; color:var(--muted); font-size:10px; font-style:normal; font-weight:900; text-align:center; }
.message-thread-head { display:flex; align-items:center; gap:12px; padding:20px 22px; border-bottom:1px solid var(--line); background:#fbfcfa; }
.message-thread-head h2 { margin:0; font-family:Oswald,sans-serif; text-transform:uppercase; font-size:24px; }
.message-thread-body { min-height:360px; max-height:58vh; overflow:auto; padding:20px; background:linear-gradient(180deg,#f7f9f6,#eef4f4); }
.message-bubble { width:min(78%,560px); margin:0 0 12px; padding:12px 14px; border-radius:16px 16px 16px 4px; background:white; border:1px solid var(--line); box-shadow:0 5px 18px rgba(20,50,65,.05); }
.message-bubble.mine { margin-left:auto; border-radius:16px 16px 4px 16px; background:#e6f7fb; border-color:#bee9f2; }
.message-meta { display:flex; justify-content:space-between; gap:12px; margin-bottom:5px; color:var(--muted); font-size:10px; text-transform:uppercase; letter-spacing:.04em; }
.message-meta strong { color:var(--blue); }
.message-bubble p { margin:0; line-height:1.5; white-space:pre-wrap; }
.message-empty { min-height:260px; display:grid; place-content:center; }
.message-compose { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:10px; padding:16px 18px 10px; border-top:1px solid var(--line); background:white; }
.message-compose textarea { width:100%; min-height:58px; max-height:180px; resize:vertical; border:1px solid var(--line); border-radius:12px; padding:12px 13px; outline:none; }
.message-compose textarea:focus { border-color:var(--cyan); box-shadow:0 0 0 3px rgba(19,181,209,.12); }
.message-help { margin:0; padding:0 18px 16px; color:var(--muted); font-size:11px; line-height:1.45; }
.message-settings { margin-bottom:18px; padding:0; overflow:hidden; }
.message-settings summary { cursor:pointer; padding:16px 18px; font-weight:800; color:var(--navy); }
.message-settings-grid { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:10px; padding:0 18px 12px; }
.message-settings-grid label { display:flex; align-items:center; gap:8px; min-width:0; padding:10px 11px; border:1px solid var(--line); border-radius:12px; background:#fbfcfa; color:var(--ink); font-size:12px; font-weight:700; }
.message-settings-grid input { width:auto; }
.message-settings-grid select { width:auto; min-width:82px; border:1px solid var(--line); border-radius:9px; padding:6px 8px; background:white; }
.structured-plan-summary { display:grid; grid-template-columns:repeat(3,1fr); gap:9px; margin:0 0 20px; }
.structured-plan-summary > div { padding:12px; border:1px solid var(--line); border-radius:10px; background:white; }
.structured-plan-summary small { display:block; color:var(--muted); margin-bottom:4px; }
.structured-plan-summary strong { font-size:13px; }
.structured-plan-summary > .structured-plan-steps { grid-column:1 / -1; }
.planned-step-structure { display:grid; gap:12px; }
.planned-step-set { display:grid; gap:8px; padding:12px; border:1px solid var(--line); border-radius:10px; background:#f8fbfc; }
.planned-step-set-title { display:block; font-size:15px; color:var(--navy); }
.structured-plan-summary .planned-step-set-title { font-size:15px; }
.planned-step-item { display:grid; gap:3px; padding-left:12px; border-left:3px solid rgba(21,169,190,.35); }
.planned-step-label { display:block; font-weight:600; color:var(--muted); }
.planned-step-prescription { color:var(--navy); font-weight:600; }
.planned-step-recovery { color:var(--muted); }
.planned-step-set-recovery { display:block; padding:10px 12px; border-radius:9px; background:rgba(21,169,190,.1); color:var(--navy); }
.planned-step-warmup,.planned-step-cooldown { margin:0 0 12px; }
.planned-step-cooldown { margin:12px 0 0; }
.planned-step-custom-instructions { margin-top:14px; padding-top:12px; border-top:1px solid var(--line); }
.planned-step-custom-instructions p { margin:6px 0 0; white-space:pre-line; }
.completion-segments-card { margin:0 0 18px; padding:17px; border:1px solid var(--line); border-radius:14px; background:white; }
.completion-segment { display:grid; grid-template-columns:.7fr 1.3fr; gap:14px; align-items:end; padding-top:13px; }
.completion-segment + .completion-segment { margin-top:13px; border-top:1px solid var(--line); }
.completion-segment h5 { margin:0 0 4px; font-size:15px; }
.completion-segment span { color:var(--muted); font-size:12px; }
.completion-segment-fields { display:grid; grid-template-columns:1fr 1fr; gap:9px; }
.completion-segment-fields .field { margin:0; }
.structured-segment-grid { display:grid; grid-template-columns:1fr 1fr; gap:14px; margin-bottom:17px; padding-bottom:17px; border-bottom:1px solid var(--line); }
input[readonly] { background:#edf3f5; color:var(--navy); font-weight:800; }
.detail small { display: block; color: var(--muted); margin-bottom: 3px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; }
.plan-modal-actions { flex-wrap:wrap; align-items:stretch; }
.plan-modal-actions > button { flex:1 1 145px; min-width:0; margin-left:0; white-space:normal; }
.plan-modal-actions > .future-completion-note { flex:1 1 100%; }

.coach-table { overflow-x: auto; }
.coach-table { -webkit-overflow-scrolling: touch; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 15px 18px; border-bottom: 1px solid var(--line); font-size: 13px; }
th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.status { display: inline-block; padding: 5px 9px; border-radius: 99px; font-size: 11px; font-weight: 700; }
.status.done { background: #dceee7; color: #296e54; }
.status.pending { background: #f1eee2; color: #847235; }
.status.inactive { background:#ecefee; color:#758087; }
.row-actions { white-space: nowrap; text-align: right; }
.table-btn { border: 1px solid var(--line); background: white; border-radius: 8px; padding: 7px 10px; color: var(--ink); font-size: 12px; margin-left: 5px; }
.table-btn:hover { border-color: var(--cyan); }
.table-btn.danger { color: #a34848; }
.coach-modal { width: min(760px, 100%); }
.workout-builder { background:white; border:1px solid var(--line); border-radius:13px; padding:16px; margin:0 0 18px; }
.builder-row { display:grid; grid-template-columns:.55fr 1fr; gap:14px; align-items:end; }
.builder-row + .builder-row { grid-template-columns:.55fr 1fr 1fr; margin-top:16px; padding-top:16px; border-top:1px solid var(--line); }
.builder-row.reps-builder { grid-template-columns:.55fr 1fr 1fr; }
.sets-count-row { grid-template-columns:minmax(130px,220px); margin-bottom:14px; }
.rep-set-builders { display:grid; gap:12px; }
.rep-set-builder { padding:14px; border:1px solid #cbdadd; border-radius:12px; background:#f7faf9; }
.rep-set-builder h4 { margin:0 0 12px; color:var(--navy); font-size:14px; }
.rep-set-head { display:flex; align-items:start; justify-content:space-between; gap:12px; margin-bottom:12px; }
.rep-set-head h4 { margin:0; }
.rep-line-list { display:grid; gap:12px; }
.rep-line-builder { padding:12px; border:1px solid var(--line); border-radius:11px; background:white; }
.rep-line-head { display:flex; align-items:center; justify-content:space-between; gap:10px; margin-bottom:10px; }
.rep-line-head strong { color:var(--blue); font-size:12px; text-transform:uppercase; letter-spacing:.05em; }
.rep-details-row { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-top:10px; }
.add-rep-line-btn { width:100%; margin-top:12px; }
.structured-builder.sets-disabled .rep-set-builder:not(:first-child) { display:none; }
.set-rest-bottom { margin-top:14px; padding:14px; border:1px solid #b9e3ec; border-radius:12px; background:#f1fbfd; }
.set-rest-bottom .metric-control { max-width:360px; }
.count-control label,.metric-control > label { display:block; font-size:12px; font-weight:700; margin-bottom:7px; }
.optional-metric-control small { display:block; margin-top:7px; color:var(--muted); font-size:11px; line-height:1.4; }
.count-control select { width:100%; border:1px solid var(--line); border-radius:9px; padding:10px; background:white; }
.metric-toggle { display:flex; padding:3px; background:#edf1ef; border-radius:8px; margin-bottom:7px; }
.metric-mode,.sets-option { flex:1; border:0; background:transparent; padding:6px 8px; border-radius:6px; color:var(--muted); font-size:11px; font-weight:700; }
.metric-mode.active,.sets-option.active { background:var(--navy); color:white; }
.sets-decision { max-width:230px; margin-bottom:16px; }
.sets-decision > label { display:block; font-size:12px; font-weight:700; margin-bottom:7px; }
.sets-toggle { width:150px; }
.optional-label { color:var(--muted); font-size:10px; font-weight:500; margin-left:5px; }
.metric-value { display:grid; grid-template-columns:1fr 70px; gap:7px; }
.metric-value input,.metric-value select { width:100%; border:1px solid var(--line); border-radius:9px; padding:10px; background:white; }
.time-suffix { display:grid; place-items:center; border:1px solid var(--line); border-radius:9px; background:#f3f5f3; color:var(--muted); font-size:11px; font-weight:700; }
.rpe-guide { margin:-4px 0 18px; border:1px solid var(--line); border-radius:11px; background:white; overflow:hidden; }
.rpe-guide summary { cursor:pointer; padding:11px 14px; color:var(--blue); font-size:12px; font-weight:700; }
.rpe-guide img { display:block; width:100%; height:auto; border-top:1px solid var(--line); }
.rpe-guide.compact { margin:0 0 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-row.three { grid-template-columns: .8fr 1fr 1fr; }
.athlete-picker { border: 0; padding: 0; margin: 5px 0 20px; }
.athlete-picker legend { font-size: 13px; font-weight: 700; margin-bottom: 9px; }
.session-athlete-picker { border:1px solid var(--line); border-radius:11px; background:#f8faf9; overflow:hidden; }
.session-athlete-picker > summary { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:11px 13px; cursor:pointer; list-style:none; color:var(--navy); font-size:13px; font-weight:800; }
.session-athlete-picker > summary::-webkit-details-marker { display:none; }
.session-athlete-picker > summary::after { content:'▾'; color:var(--blue); font-size:13px; transition:transform .18s ease; }
.session-athlete-picker[open] > summary::after { transform:rotate(180deg); }
.session-athlete-picker > summary strong { margin-left:auto; color:var(--muted); font-size:11px; font-weight:800; }
.session-athlete-picker-body { padding:11px 13px 13px; border-top:1px solid var(--line); background:white; }
.athlete-select-actions { display:flex; gap:7px; margin-bottom:9px; }
.athlete-select-actions button { padding:6px 10px; border:1px solid #bfd4d8; border-radius:8px; background:#f3fafb; color:#176074; font-size:11px; font-weight:800; cursor:pointer; }
.athlete-select-actions button:hover { border-color:var(--cyan); background:#e8f8fb; }
.athlete-checks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.athlete-checks label { display: flex; align-items: center; gap: 9px; padding: 10px; background: white; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-size: 13px; }
.athlete-checks label:has(input:checked) { border-color: var(--cyan); background: #effbfc; }
.athlete-checks input { accent-color: var(--blue); }
.avatar.mini { width: 29px; height: 29px; font-size: 10px; }
.toast { position: fixed; right: 24px; bottom: 24px; background: var(--navy); color: white; padding: 14px 18px; border-radius: 11px; box-shadow: var(--shadow); transform: translateY(120px); opacity: 0; transition: .25s; z-index: 50; }
.toast.show { transform: translateY(0); opacity: 1; }
.session-form-status { min-height: 22px; margin: 4px 0 12px; color: #b42318; font-size: .92rem; font-weight: 700; }
.copy-week-modal { width:min(650px,100%); }
.copy-week-source { display:flex; flex-direction:column; gap:4px; margin-bottom:18px; padding:14px 16px; border-left:4px solid var(--cyan); border-radius:0 10px 10px 0; background:#f1fafc; }
.copy-week-source strong { color:var(--navy); }
.copy-week-source span { color:var(--muted); font-size:12px; }
.copy-week-preview { display:flex; flex-direction:column; gap:4px; margin-top:4px; padding:14px; border:1px solid var(--line); border-radius:11px; background:#f8faf9; }
.copy-week-preview span { color:var(--muted); font-size:10px; font-weight:800; letter-spacing:.05em; text-transform:uppercase; }
.copy-week-preview strong { color:var(--navy); }
.copy-week-preview small { color:var(--muted); }
.session-library-picker { display:grid; grid-template-columns:minmax(180px,.8fr) minmax(300px,1.2fr); gap:14px; align-items:end; margin-bottom:17px; padding:14px; border:1px solid #b9e3ec; border-radius:13px; background:#f2fbfd; }
.session-library-picker label { display:block; margin-bottom:4px; color:var(--navy); font-size:13px; font-weight:800; }
.session-library-picker small { color:var(--muted); font-size:11px; line-height:1.35; }
.session-library-picker-controls { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:8px; }
.session-library-picker select { min-width:0; height:42px; padding:0 11px; border:1px solid var(--line); border-radius:9px; background:white; color:var(--ink); }

/* Coach reports */
.report-heading { align-items:center; }
.report-filters { padding:18px; margin-bottom:18px; }
.report-filters .field { margin:0; }
.report-stats { grid-template-columns:repeat(6,1fr); }
.load-stat { border-color:#dbe9a8; background:#fbfdea; }
.report-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-top:16px; }
.report-chart { padding:0 16px 14px; }
.report-bar-row { display:grid; grid-template-columns:58px minmax(0,1fr) 72px; gap:10px; align-items:center; padding:8px 0; border-bottom:1px solid var(--line); }
.report-bar-row span { color:var(--muted); font-size:11px; font-weight:800; }
.report-bar-row div { height:12px; overflow:hidden; border-radius:999px; background:#edf3f5; }
.report-bar-row i { display:block; height:100%; border-radius:999px; background:linear-gradient(90deg,var(--cyan),var(--lime)); }
.report-bar-row strong { color:var(--navy); font-size:12px; text-align:right; }
.report-chart small { display:block; margin-top:10px; color:var(--muted); font-size:11px; }
.effort-chart .report-bar-row i { background:linear-gradient(90deg,#c7ea38,#ffb000,#f05252); }
.report-graph-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; margin-top:16px; }
.report-graph-grid .card:first-child { grid-column:auto; }
.report-delta-chart { padding:0 18px 18px; }
.report-delta-row { display:grid; grid-template-columns:58px minmax(0,1fr) 118px; gap:10px; align-items:center; padding:8px 0; border-bottom:1px solid var(--line); }
.report-delta-row span { color:var(--muted); font-size:11px; font-weight:800; }
.report-delta-row div { height:12px; overflow:hidden; border-radius:999px; background:#edf3f5; }
.report-delta-row i { display:block; height:100%; border-radius:999px; background:#9aa7ad; }
.report-delta-row.up i { background:linear-gradient(90deg,#bce832,#39ff14); }
.report-delta-row.down i { background:linear-gradient(90deg,#ffb4aa,#f05252); }
.report-delta-row strong { color:var(--navy); font-size:12px; text-align:right; }
.report-delta-chart small,.report-line-chart small { display:block; margin-top:10px; color:var(--muted); font-size:11px; }
.benchmark-trend-card { padding:0 16px 14px; }
.benchmark-trend-card h3 { margin:0 0 3px; color:var(--navy); font-size:15px; line-height:1.25; }
.benchmark-trend-card p { margin-bottom:6px; }
.report-line-chart svg { width:min(100%,520px); height:138px; display:block; margin:4px auto 0; overflow:visible; }
.report-line-chart line { stroke:#dce5e5; stroke-width:1.2; }
.report-line-chart polyline { fill:none; stroke:#00bfff; stroke-width:2.4; stroke-linecap:round; stroke-linejoin:round; filter:drop-shadow(0 0 2px rgba(0,191,255,.45)); }
.report-line-chart circle { fill:#00bfff; stroke:var(--navy); stroke-width:1.2; filter:drop-shadow(0 0 2px rgba(0,191,255,.42)); }
.report-line-meta { display:flex; justify-content:space-between; gap:12px; margin-top:8px; color:var(--muted); font-size:12px; }
.report-line-meta strong { color:var(--navy); }
.report-line-chart.empty { padding-top:6px; }
.effort-profile-chart .report-bar-row i { background:linear-gradient(90deg,#dff5f8,#13b5d1,#0b2638); }
.effort-distribution-smart { padding:0 16px 14px; display:grid; grid-template-columns:126px minmax(0,1fr); gap:14px; align-items:center; }
.effort-donut { width:118px; aspect-ratio:1; border-radius:50%; background:conic-gradient(var(--effort-stops)); display:grid; place-items:center; box-shadow:0 0 10px rgba(0,191,255,.16); }
.effort-donut > div { width:70px; aspect-ratio:1; border-radius:50%; background:#fff; display:grid; place-items:center; text-align:center; box-shadow:inset 0 0 0 1px var(--line); }
.effort-donut strong { color:var(--navy); font-size:21px; line-height:1; }
.effort-donut span { color:var(--muted); font-size:10px; font-weight:900; text-transform:uppercase; }
.effort-legend { display:grid; gap:8px; width:100%; }
.effort-legend div { display:grid; grid-template-columns:12px minmax(0,1fr) auto auto; gap:8px; align-items:center; color:var(--navy); font-size:12px; }
.effort-legend i { width:12px; height:12px; border-radius:50%; box-shadow:0 0 8px rgba(0,191,255,.25); }
.effort-legend strong { font-weight:950; }
.effort-legend small { color:var(--muted); font-weight:800; }
.effort-distribution-smart .report-chart { grid-column:1/-1; padding:4px 0 0; width:100%; }
.training-load-combo { padding:0 16px 14px; display:grid; gap:12px; }
.training-load-chart { border:1px solid var(--line); border-radius:13px; padding:10px; background:#fbfcfa; }
.training-load-chart h3 { margin:0 0 6px; color:var(--navy); font-size:15px; }
.training-load-summary { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.training-load-summary span { padding:10px; border-radius:12px; background:#f1fbfd; color:var(--muted); font-size:12px; }
.training-load-summary strong { display:block; color:var(--blue); font-size:22px; }
.training-load-combo-card { grid-column:auto; }
.athlete-report-card { margin-top:22px; }
.weekly-mileage-strip { margin:22px 0 0; grid-template-columns:2fr 1fr 1fr; }
.athlete-report-filters { padding:0 18px 16px; }
.athlete-benchmark-filter-row { margin-top:12px; }
.athlete-report-stats { grid-template-columns:repeat(6,1fr); padding:0 18px; margin-bottom:18px; }
.athlete-report-grid { padding:0 18px 18px; margin-top:0; }
.athlete-report-grid .card { box-shadow:none; }
.athlete-report-grid .card-head h2 { font-size:20px; }
.athlete-report-benchmarks { padding:0 18px 18px; }
.athlete-report-benchmarks h3 { margin:0 0 12px; color:var(--navy); font-family:Oswald,sans-serif; font-size:23px; text-transform:uppercase; }
.athlete-benchmark-panel { overflow:hidden; border:1px solid var(--line); border-radius:13px; background:white; }
.athlete-benchmark-panel + .athlete-benchmark-panel { margin-top:10px; }
.athlete-benchmark-panel summary { display:flex; align-items:center; justify-content:space-between; gap:12px; padding:13px 15px; cursor:pointer; list-style:none; color:var(--navy); font-weight:900; }
.athlete-benchmark-panel summary::-webkit-details-marker,.expandable-card summary::-webkit-details-marker { display:none; }
.athlete-benchmark-panel summary::before { content:"▸"; color:var(--blue); transition:.18s; }
.athlete-benchmark-panel[open] summary::before { transform:rotate(90deg); }
.athlete-benchmark-panel summary span { flex:1; }
.athlete-benchmark-panel summary strong { color:var(--muted); font-size:11px; text-transform:uppercase; letter-spacing:.05em; }
.athlete-benchmark-panel .coach-table { border-top:1px solid var(--line); }
.expandable-card { overflow:hidden; }
.rpe-pace-card { margin-top:20px; overflow:hidden; }
.rpe-pace-body { padding:0 18px 18px; }
.rpe-pace-table { overflow:auto; border:1px solid var(--line); border-radius:12px; background:white; }
.rpe-pace-table table { width:100%; border-collapse:collapse; min-width:300px; }
.rpe-pace-table th,.rpe-pace-table td { padding:9px 10px; border-bottom:1px solid #edf0ef; color:var(--navy); font-size:12px; text-align:left; }
.rpe-pace-table th { color:var(--muted); font-size:10px; text-transform:uppercase; letter-spacing:.05em; }
.rpe-pace-table tr:last-child td { border-bottom:0; }
.rpe-pace-table td:last-child { color:var(--blue); font-weight:950; white-space:nowrap; }
.shoe-tracker-card { margin-top:20px; }
.compact-btn { min-height:36px; padding:8px 12px; border-radius:10px; font-size:12px; }
.shoe-list { padding:0 18px 18px; }
.shoe-row { display:grid; grid-template-columns:minmax(0,1fr); gap:10px; padding:13px; border:1px solid var(--line); border-radius:14px; background:#fff; }
.shoe-row + .shoe-row,.archived-shoes { margin-top:10px; }
.shoe-row strong { display:block; color:var(--navy); font-size:15px; }
.shoe-row span { display:block; color:var(--muted); font-size:12px; }
.shoe-row.archived { opacity:.72; background:#f7f8f4; }
.shoe-metrics { display:grid; grid-template-columns:1fr 1fr 1fr; gap:8px; }
.shoe-metrics span { padding:9px; border-radius:10px; background:#f4fafb; text-align:center; }
.shoe-metrics strong { font-size:16px; }
.shoe-actions { display:flex; gap:8px; flex-wrap:wrap; justify-content:flex-end; }
.archived-shoes summary { cursor:pointer; color:var(--muted); font-weight:900; font-size:12px; text-transform:uppercase; letter-spacing:.06em; }
.shoe-completion-field { margin-top:10px; }
.empty-inline { padding:12px; border:1px dashed var(--line); border-radius:10px; background:#f8faf7; color:var(--muted); font-size:13px; }
.expandable-card > summary { list-style:none; cursor:pointer; }
.expandable-card > summary .card-head { margin:0; }
.expandable-card > summary .card-head::before { content:"▸"; color:var(--blue); font-size:18px; font-weight:900; }
.expandable-card[open] > summary .card-head::before { transform:rotate(90deg); }
.expandable-body { border-top:1px solid var(--line); }
.benchmark-count-btn { border:1px solid #b9e3ec; border-radius:999px; padding:6px 10px; background:#effbfc; color:#075f72; font-weight:900; cursor:pointer; }
.benchmark-count-btn:hover { border-color:var(--cyan); background:#dff5f8; }
.benchmark-detail-modal { width:min(920px,100%); }
.benchmark-detail-table table { min-width:820px; }
.report-structure { display:grid; grid-template-columns:1fr 1fr; gap:10px; padding:0 18px 18px; }
.report-structure div,.report-structure-card { padding:13px; border:1px solid var(--line); border-radius:12px; background:#f8faf9; }
.report-structure-card { width:100%; text-align:left; color:inherit; font:inherit; cursor:pointer; transition:.15s ease; }
.report-structure-card:hover,.report-structure-card:focus { border-color:var(--cyan); box-shadow:0 0 0 3px rgba(19,181,209,.12); transform:translateY(-1px); }
.report-structure-card em { display:block; margin-top:8px; color:var(--blue); font-size:10px; font-style:normal; font-weight:900; text-transform:uppercase; letter-spacing:.06em; }
.report-structure strong { display:block; color:var(--navy); font-size:13px; }
.report-structure span { color:var(--muted); font-size:11px; line-height:1.4; }
.report-table table { min-width:920px; }
.training-load-info-modal .modal-body { display:grid; gap:14px; }
.science-card { padding:18px; border:1px solid var(--line); border-radius:14px; background:white; }
.science-card h3 { margin:0 0 9px; color:var(--navy); font-size:20px; }
.science-card p { margin:0 0 10px; color:#334654; line-height:1.55; }
.formula-box { display:grid; gap:4px; margin:10px 0; padding:13px 14px; border-left:4px solid var(--lime); border-radius:10px; background:#f7fbdf; }
.formula-box strong { color:var(--navy); }
.formula-box span { color:var(--muted); font-size:12px; }
.science-list { margin:12px 0 0; padding-left:18px; color:#334654; line-height:1.5; }
.science-list li + li { margin-top:7px; }
.sources-card a { color:var(--blue); font-weight:800; }

/* Workout library */
.library-heading { align-items:center; }
.library-toolbar { display:grid; grid-template-columns:minmax(260px,1fr) minmax(190px,.38fr) auto; gap:14px; align-items:end; padding:18px; margin-bottom:30px; }
.library-search span,.library-filter span { display:block; margin-bottom:7px; color:var(--muted); font-size:11px; font-weight:800; letter-spacing:.05em; text-transform:uppercase; }
.library-search input,.library-filter select { width:100%; height:46px; padding:0 14px; border:1px solid var(--line); border-radius:11px; background:white; color:var(--ink); outline:none; }
.library-search input:focus,.library-filter select:focus { border-color:var(--cyan); box-shadow:0 0 0 3px rgba(19,181,209,.12); }
.library-count { min-width:82px; height:46px; display:flex; align-items:center; justify-content:center; gap:6px; padding:0 14px; border-radius:11px; background:var(--navy); color:white; }
.library-count strong { font-family:Oswald,sans-serif; font-size:23px; }
.library-count span { color:#b8c9d2; font-size:11px; }
.library-section + .library-section { margin-top:38px; }
.library-section-head { display:flex; justify-content:space-between; align-items:end; gap:18px; margin-bottom:15px; }
.library-section-head h2 { margin-bottom:4px; font-family:Oswald,sans-serif; font-size:27px; text-transform:uppercase; }
.library-section-head p { margin:0; color:var(--muted); font-size:13px; }
.library-grid { display:grid; grid-template-columns:1fr; gap:8px; }
.workout-template-groups { display:grid; gap:10px; }
.workout-type-group { overflow:hidden; border:1px solid var(--line); border-radius:14px; background:#fbfcfa; box-shadow:0 4px 14px rgba(17,40,56,.035); }
.workout-type-group summary { display:grid; grid-template-columns:auto minmax(0,1fr); gap:11px; align-items:center; padding:12px 14px; cursor:pointer; list-style:none; }
.workout-type-group summary::-webkit-details-marker { display:none; }
.workout-type-group summary::after { content:"⌄"; justify-self:end; grid-column:2; grid-row:1; color:var(--blue); font-size:16px; font-weight:900; transition:transform .16s ease; }
.workout-type-group[open] summary::after { transform:rotate(180deg); }
.workout-type-group summary strong { display:block; color:var(--navy); font-size:14px; line-height:1.15; }
.workout-type-group summary small { display:block; margin-top:2px; color:var(--muted); font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.04em; }
.workout-type-group .compact-library-grid { padding:0 10px 10px; }
.library-card { min-width:0; display:grid; grid-template-columns:minmax(0,1fr) auto; overflow:hidden; border:1px solid var(--line); border-radius:12px; background:white; box-shadow:0 4px 14px rgba(17,40,56,.045); transition:box-shadow .18s ease,border-color .18s ease; }
.library-card:hover,.library-card:focus-within { border-color:#9ed6e1; box-shadow:0 10px 26px rgba(17,40,56,.09); }
.library-card-main { width:100%; padding:10px 14px; border:0; background:transparent; color:inherit; text-align:left; cursor:pointer; }
.library-card-summary { display:grid; grid-template-columns:130px minmax(180px,1fr) minmax(160px,.8fr) auto; gap:14px; align-items:center; }
.workout-type-pill,.library-source { display:inline-flex; align-items:center; width:max-content; border-radius:99px; font-size:10px; font-weight:800; }
.workout-type-pill { padding:6px 9px; color:#075f72; background:#dff5f8; }
.workout-type-pill.type-rest { color:#667781; background:#eef1f0; border:1px dashed #c9d2d1; }
.workout-type-pill.type-interval,.workout-type-pill.type-hill,.workout-type-pill.type-fartlek { color:#5d661b; background:#edf4c9; }
.workout-type-pill.type-tempo,.workout-type-pill.type-threshold,.workout-type-pill.type-steady { color:#774e10; background:#fff0cb; }
.workout-type-pill.type-race { color:#063640; background:#00f5ff; }
.library-source { padding:5px 8px; background:#eef1f0; color:var(--muted); }
.library-source.custom { background:#e5f3ed; color:#27684f; }
.library-card h3 { margin:0 0 3px; color:var(--navy); font-size:15px; line-height:1.25; }
.library-prescription { margin:0; color:var(--blue); font-size:11px; font-weight:800; }
.library-focus { min-height:0; margin:0; color:var(--muted); font-size:11px; line-height:1.4; }
.library-meta { display:flex; gap:5px; flex-wrap:nowrap; justify-content:flex-end; }
.library-meta span { padding:5px 8px; border-radius:7px; background:#f2f5f4; color:#667781; font-size:10px; font-weight:700; }
.library-card-details { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:12px; max-height:0; margin:0; padding:0; overflow:hidden; opacity:0; border-top:1px solid transparent; transition:max-height .2s ease,opacity .16s ease,margin .2s ease,padding .2s ease; }
.library-card:hover .library-card-details,.library-card:focus-within .library-card-details { max-height:170px; margin-top:10px; padding-top:10px; opacity:1; border-top-color:var(--line); }
.library-card-details small { color:#6a7b84; font-size:9px; font-weight:900; letter-spacing:.04em; text-transform:uppercase; }
.library-card-details p { display:-webkit-box; margin:3px 0 0; overflow:hidden; color:var(--ink); font-size:10px; line-height:1.4; -webkit-line-clamp:3; -webkit-box-orient:vertical; }
.library-card-actions { display:flex; flex-wrap:wrap; align-items:center; justify-content:flex-end; gap:5px; padding:8px 10px; border-left:1px solid var(--line); background:#fafbf9; }
.library-card-actions .table-btn { margin:0; }
.library-empty,.library-no-results { padding:30px; border:1px dashed #b9c9c9; border-radius:17px; background:rgba(255,255,255,.55); text-align:center; }
.library-empty { grid-column:1/-1; }
.library-empty strong,.library-no-results strong { display:block; margin-bottom:6px; font-size:17px; }
.library-empty p,.library-no-results span { display:block; margin-bottom:16px; color:var(--muted); font-size:13px; }
.library-no-results { margin-top:22px; }
.template-preview-modal { width:min(680px,100%); }
.template-preview-hero { display:flex; flex-direction:column; align-items:flex-start; gap:8px; margin-bottom:15px; padding:17px; border-radius:14px; background:var(--navy); color:white; }
.template-preview-hero > strong { margin-top:3px; font-family:Oswald,sans-serif; font-size:27px; }
.template-preview-hero > span:last-child { color:#b9ced8; font-size:13px; }
.focus-callout { display:flex; flex-direction:column; gap:4px; margin-bottom:17px; padding:13px 15px; border-left:4px solid var(--lime); border-radius:0 10px 10px 0; background:#f2f6df; }
.focus-callout small,.template-detail small { color:var(--muted); font-size:10px; font-weight:800; letter-spacing:.05em; text-transform:uppercase; }
.focus-callout span { color:#52636d; font-size:12px; line-height:1.45; }
.set-rpe-control select { min-width:170px; }
.warmup-picker-field { padding:12px; border:1px dashed #b9dce4; border-radius:12px; background:#f7fcfd; }
.warmup-library-section { margin-top:38px; padding-top:30px; border-top:1px solid var(--line); }
.workout-type-library-section { margin-top:38px; padding-top:30px; border-top:1px solid var(--line); }
.type-base-list { display:flex; flex-wrap:wrap; gap:7px; margin:-4px 0 14px; }
.workout-type-card .library-prescription { color:#52636d; }
.workout-type-card.is-inactive { opacity:.72; }
.active-toggle { display:flex; align-items:center; gap:9px; margin:4px 0 14px; padding:11px 12px; border:1px solid var(--line); border-radius:11px; background:#f8faf9; color:var(--ink); font-size:13px; font-weight:800; }
.active-toggle input { width:auto; accent-color:var(--blue); }
.warmup-card-summary { grid-template-columns:120px minmax(170px,1fr) minmax(220px,1fr) auto; }
.warmup-card .library-focus { color:#435662; }
.template-detail { padding:14px 15px; border:1px solid var(--line); border-radius:12px; background:white; }
.template-detail p { margin:5px 0 0; color:#435662; font-size:13px; line-height:1.6; white-space:pre-line; }
.template-detail + .template-detail { margin-top:10px; }
.template-detail-grid { display:grid; grid-template-columns:1fr 1fr; gap:10px; margin:10px 0; }
.template-detail-grid .template-detail + .template-detail { margin-top:0; }
.template-editor-modal { width:min(780px,100%); }

@media (max-width: 1100px) {
  .compare-main { padding:0 14px; }
  .compare-calendar-layout { grid-template-columns:1fr; }
}

@media (max-width: 900px) {
  .topbar { min-height:96px; gap:14px; padding:10px 18px; }
  .brand-banner { max-width:none; }
  .brand-banner-inner { gap:1cm; padding:6px 10px 6px 13px; border-radius:16px; }
  .banner-wordmark { width:clamp(280px,44vw,470px); max-height:62px; }
  .banner-tagline { width:clamp(78px,12vw,118px); max-height:60px; }
  .top-actions { gap:12px; }
  .coach-athlete-actions { grid-template-columns:repeat(2,minmax(150px,1fr)); width:100%; }
  .coach-athlete-actions .athlete-switcher,
  .coach-athlete-actions #compare-athlete-calendars,
  .coach-athlete-actions #coach-athlete-month-pdf { grid-column:span 2; }
  .login-shell { grid-template-columns: 1fr; }
  .login-hero { min-height: 370px; padding: 35px 7vw; }
  .login-panel { border-radius: 28px 28px 0 0; margin-top: -28px; z-index: 2; padding: 45px 25px; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .athlete-lower-grid { grid-template-columns: 1fr; }
  .athlete-cards { grid-template-columns: repeat(2,1fr); }
  .athlete-list-row { grid-template-columns:42px minmax(0,1fr) auto; }
  .athlete-list-metrics { grid-column:2/-1; text-align:left; }
  .coach-dashboard-columns { grid-template-columns:1fr; }
  .profile-manager { grid-template-columns:1fr; }
  .athlete-info-grid { grid-template-columns:1fr 1fr; }
  .library-card-summary { grid-template-columns:110px minmax(170px,1fr) auto; }
  .library-focus { grid-column:2/-1; }
  .message-layout { grid-template-columns:1fr; }
  .message-thread-list { max-height:none; }
  .compare-main { width:100%; padding:0 14px; }
}
@media (max-width: 620px) {
  body { background:#f3f5ef; }
  input, select, textarea { font-size:16px; }
  .primary-btn, .secondary-btn, .table-btn, .share-option, .install-app-link { min-height:44px; }
  .topbar { min-height: 68px; height:auto; padding: 9px 14px; gap:10px; border-bottom-width:2px; }
  .brand-banner { flex:0 0 auto; }
  .brand-banner-inner { display:none; }
  .mobile-brand { display:block; width:46px; height:46px; flex:0 0 auto; border:1px solid rgba(0,191,255,.42); box-shadow:0 0 12px rgba(0,191,255,.28); }
  .brand-compact { width:46px; height:46px; flex:0 0 auto; }
  .brand-copy small, .user-chip > div:not(.avatar) { display: none; }
  .top-actions { gap:10px; }
  .top-action-stack { gap:3px; }
  .top-data-actions { gap:4px; }
  .top-data-actions button,
  .top-data-actions a { padding:3px 6px; font-size:10px; }
  .avatar { width:36px; height:36px; }
  .logout { min-height:40px; padding:0 4px; font-weight:800; }
  .main { width: 100%; padding:0 12px; margin-top: 18px; margin-bottom:56px; }
  .welcome { align-items: start; flex-direction:column; gap:14px; margin-bottom:20px; }
  .welcome h1 { font-size:38px; }
  .welcome-actions { width:100%; justify-content: flex-start; gap:8px; }
  .welcome-actions > button { flex:1 1 140px; padding-left:12px; padding-right:12px; }
  .coach-athlete-actions { display:flex; width:100%; }
  .coach-athlete-actions .athlete-switcher { flex:1 1 100%; }
  .coach-athlete-actions #compare-athlete-calendars,
  .coach-athlete-actions #coach-athlete-month-pdf { grid-column:auto; }
  .coach-athlete-actions > button { flex:1 1 140px; min-height:42px; }
  .athlete-switcher { width:100%; min-width:0; flex:1 1 100%; }
  .athlete-switcher select { min-height:44px; font-size:16px; }
  .compare-main { padding:0 10px; }
  .compare-panel-head { gap:10px; padding:12px; }
  .compare-panel-select-row { grid-template-columns:1fr; }
  .compare-panel-month-row { align-items:stretch; flex-direction:column; }
  .compare-panel-month-controls { width:100%; justify-content:space-between; }
  .compare-panel-month-controls .month-nav { width:auto; justify-content:flex-start; }
  .compare-panel-head .compact-btn { width:100%; min-height:44px; }
  .compare-calendar-panel .calendar { padding:8px; overflow-x:auto !important; -webkit-overflow-scrolling:touch; touch-action:pan-x; }
  .compare-calendar-panel .calendar .weekdays,
  .compare-calendar-panel .calendar .calendar-grid { width:auto; min-width:560px; grid-template-columns:repeat(7,minmax(72px,1fr)); }
  .compare-calendar-panel .day { min-height:86px; }
  .day-drag-btn { height:28px; min-width:38px; opacity:1; font-size:9px; }
  .week-drag-btn { height:30px; opacity:1; }
  .date-pill { display: none; }
  .stats { gap: 8px; }
  .stat { padding: 14px 10px; }
  .stat-value { font-size: 27px; }
  .card { border-radius:16px; }
  .card-head { padding:16px; align-items:flex-start; gap:12px; flex-direction:column; }
  .card-head h2 { font-size:22px; }
  .month-nav { width:100%; justify-content:space-between; }
  .icon-btn { width:44px; height:44px; border-radius:12px; font-size:18px; }
  .calendar { padding: 12px; overflow-x:auto; -webkit-overflow-scrolling:touch; }
  .weekdays, .calendar-grid { min-width:660px; gap: 6px; }
  .weekdays div { font-size:10px; padding-bottom:6px; }
  .day { min-height: 98px; padding: 7px; border-radius:12px; }
  .day-top { flex-direction:row; align-items:center; gap:5px; }
  .day-num { font-size:13px; }
  .day-actions { justify-content:flex-end; gap:3px; }
  .day-add,.day-race-btn { opacity:1; }
  .day-actions .day-add,.day-actions .day-race-btn { width:28px; height:28px; padding:0; font-size:15px; opacity:1; border-radius:8px; }
  .session-chip,.race-chip { font-size:10px; height:auto; min-height:30px; padding:6px 7px; margin-top:6px; line-height:1.15; }
  .week-actions { gap:5px; }
  .week-share-btn,.week-copy-btn,.week-download-btn { width:30px; height:30px; opacity:1; }
  .week-copy-btn { font-size:18px; }
  .week-download-btn { font-size:9px; }
  .detail-grid { grid-template-columns: 1fr; }
  .race-priority-strip { align-items:flex-start; flex-direction:column; }
  .athlete-cards { grid-template-columns: 1fr; }
  .athlete-list { padding:10px; }
  .athlete-list-row { grid-template-columns:38px minmax(0,1fr); align-items:start; }
  .athlete-status-pill { grid-column:2; justify-self:start; }
  .athlete-list-metrics { grid-column:1/-1; grid-template-columns:1fr 1fr; text-align:left; }
  .athlete-contact { grid-template-columns:1fr; }
  .athlete-contact dd { white-space:normal; overflow:visible; }
  .athlete-lower-grid { margin-top:14px; }
  .athlete-info-grid { grid-template-columns:1fr; }
  .athlete-title-row { align-items:flex-start; gap:12px; }
  .avatar.large { width:56px; height:56px; flex:0 0 auto; }
  .profile-row { grid-template-columns:36px minmax(0,1fr) auto auto; }
  .profile-row .status { display:none; }
  .profile-list { padding:4px 14px 14px; }
  .form-row, .form-row.three, .athlete-checks { grid-template-columns: 1fr; }
  .session-library-picker,.session-library-picker-controls { grid-template-columns:1fr; }
  .builder-row,.builder-row + .builder-row,.builder-row.reps-builder { grid-template-columns:1fr; }
  .rep-set-head,.rep-line-head { flex-direction:column; align-items:flex-start; }
  .rep-details-row { grid-template-columns:1fr; }
  .structured-segment-grid,.structured-plan-summary,.completion-segment-fields { grid-template-columns:1fr; }
  .completion-segment { grid-template-columns:1fr; }
  .saved-result-grid,.saved-segments { grid-template-columns:1fr 1fr; }
  .fit-comparison-grid,.fit-progress-metrics,.load-progress-metrics,.load-score-grid { grid-template-columns:1fr 1fr; }
  .fit-analysis-head { flex-direction:column; }
  .fit-lap-table, .coach-table { margin-left:-2px; margin-right:-2px; }
  .fit-lap-table table, .coach-table table { min-width:640px; }
  .repeat-results-card,.fit-upload-card,.workout-feedback-card,.completion-segments-card,.workout-builder { padding:14px; }
  .repeat-set-heading,.repeat-results-head,.workout-feedback-head { flex-direction:column; align-items:flex-start; }
  .repeat-result-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .repeat-average { align-items:flex-start; flex-direction:column; gap:4px; }
  .share-actions { grid-template-columns:1fr; }
  .month-pdf-choice-card { grid-template-columns:1fr; }
  .month-pdf-actions { grid-template-columns:1fr; }
  .share-backdrop { padding:12px; align-items:end; }
  .share-dialog { border-radius:18px 18px 10px 10px; padding:22px 18px calc(18px + env(safe-area-inset-bottom)); }
  .message-thread-list { max-height:260px; }
  .message-thread-head { padding:16px; }
  .message-thread-body { min-height:330px; max-height:58vh; padding:14px; }
  .message-bubble { width:92%; }
  .message-settings-grid { grid-template-columns:1fr; }
  .message-settings-grid label { align-items:flex-start; }
  .message-compose { grid-template-columns:1fr; padding:14px; }
  .message-compose button { width:100%; }
  .message-help { padding:0 14px 14px; }
  .modal-backdrop { padding:0; align-items:end; place-items:end center; }
  .modal { width:100%; max-height:94dvh; border-radius:20px 20px 0 0; }
  .modal-top { padding:20px 18px; }
  .modal-top h2 { font-size:27px; margin-right:42px; }
  .close { width:40px; height:40px; right:14px; top:14px; }
  .modal-body { padding:18px 14px calc(22px + env(safe-area-inset-bottom)); }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions button { width: 100%; }
  .toast { left:12px; right:12px; bottom:calc(14px + env(safe-area-inset-bottom)); text-align:center; }
  .library-toolbar { grid-template-columns:1fr; }
  .report-stats,.report-grid,.report-graph-grid { grid-template-columns:1fr; }
  .report-graph-grid .card:first-child { grid-column:auto; }
  .report-structure { grid-template-columns:1fr; }
  .report-bar-row { grid-template-columns:52px minmax(0,1fr) 68px; }
  .report-delta-row { grid-template-columns:52px minmax(0,1fr) 94px; }
  .report-line-chart svg { height:124px; }
  .effort-distribution-smart { grid-template-columns:1fr; justify-items:center; padding-left:12px; padding-right:12px; }
  .effort-legend { width:100%; }
  .training-load-summary { grid-template-columns:1fr; }
  .training-load-combo { padding-left:12px; padding-right:12px; }
  .athlete-report-filters,.athlete-report-grid,.athlete-report-benchmarks { padding-left:12px; padding-right:12px; }
  .athlete-report-stats { grid-template-columns:1fr 1fr; padding-left:12px; padding-right:12px; }
  .library-count { width:100%; }
  .library-grid { grid-template-columns:1fr; }
  .library-card { grid-template-columns:1fr; }
  .library-card-summary { grid-template-columns:1fr auto; gap:8px 12px; }
  .warmup-card-summary { grid-template-columns:1fr auto; }
  .library-card-summary .workout-type-pill { grid-column:1; }
  .library-card-title { grid-column:1/-1; }
  .library-focus { grid-column:1/-1; }
  .library-meta { grid-column:2; grid-row:1; }
  .library-card-details { grid-template-columns:1fr; max-height:none; margin-top:10px; padding-top:10px; opacity:1; border-top-color:var(--line); }
  .library-card-actions { justify-content:flex-start; border-top:1px solid var(--line); border-left:0; }
  .library-card-actions .table-btn { flex:1 1 118px; }
  .template-detail-grid { grid-template-columns:1fr; }
  .template-detail-grid .template-detail + .template-detail { margin-top:10px; }
}
@media (max-width: 430px) {
  .login-hero { min-height:300px; padding:26px 20px 42px; }
  .hero-copy h1 { font-size:42px; }
  .hero-copy p { font-size:15px; }
  .hero-tagline { display:none; }
  .login-panel { padding:32px 18px; }
  .role-tabs { margin:22px 0 18px; }
  .main { padding:0 10px; }
  .welcome h1 { font-size:33px; }
  .stats { grid-template-columns:1fr; }
  .stat { display:flex; align-items:center; justify-content:space-between; }
  .fit-comparison-grid,.fit-progress-metrics,.load-progress-metrics,.load-score-grid,.saved-result-grid,.saved-segments { grid-template-columns:1fr; }
  .repeat-result-grid { grid-template-columns:1fr; }
  .library-card-summary { grid-template-columns:1fr; }
  .library-meta { grid-column:1; grid-row:auto; justify-content:flex-start; }
  .workout-type-pill,.library-source { width:max-content; }
}
@media (hover:none) {
  .day-add,.day-race-btn,.week-share-btn,.week-copy-btn,.week-download-btn { opacity:1; }
  .library-card-details { max-height:none; margin-top:10px; padding-top:10px; opacity:1; border-top-color:var(--line); }
}
@media (max-width: 620px) {
  select { font-size:13px !important; line-height:1.2; }
  select option,
  select optgroup { font-size:13px; line-height:1.2; }
  .field select,
  .athlete-switcher select,
  .library-filter select,
  .session-library-picker select,
  .session-library-picker-controls select { min-height:36px; height:38px; padding:6px 9px; font-size:13px !important; border-radius:9px; }
  .workout-template-groups { gap:8px; }
  .workout-type-group { border-radius:12px; }
  .workout-type-group summary { min-height:44px; padding:9px 10px; gap:8px; }
  .workout-type-group summary strong { font-size:13px; }
  .workout-type-group summary small { font-size:9px; }
  .workout-type-group .compact-library-grid { padding:0 7px 7px; gap:7px; }
  .library-card-main { padding:7px 9px; }
  .library-card-summary { grid-template-columns:minmax(0,1fr) auto; gap:5px 8px; }
  .library-card h3 { font-size:14px; line-height:1.15; }
  .library-prescription { font-size:10px; line-height:1.2; }
  .library-focus { font-size:10px; line-height:1.25; }
  .library-meta { gap:4px; }
  .library-meta span,
  .library-source,
  .workout-type-pill { padding:4px 7px; font-size:9px; line-height:1.1; }
  .library-card-details { display:none !important; max-height:0 !important; margin:0 !important; padding:0 !important; opacity:0 !important; border-top:0 !important; }
  .library-card-actions { gap:5px; padding:6px 7px; }
  .library-card-actions .table-btn { min-height:34px; flex:1 1 104px; padding:6px 8px; font-size:11px; }
  .warmup-card-summary { grid-template-columns:minmax(0,1fr) auto; }
}
/* Mobile overflow fixes: calendar fits the screen; data tables scroll inside their cards. */
@media (max-width: 620px) {
  html,
  body {
    overflow-x: hidden;
  }

  .app-shell,
  .main,
  .card,
  .calendar,
  .side-card,
  .next-session,
  .recent,
  .progress-body {
    max-width: 100%;
    min-width: 0;
  }

  .calendar {
    display: block;
    max-width: 100%;
    overflow-x: visible !important;
    overflow-y: visible;
  }

  .calendar .weekdays,
  .calendar .calendar-grid {
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    gap: 4px;
  }

  .calendar .weekdays div {
    overflow: hidden;
    font-size: 8px;
    text-overflow: clip;
  }

  .calendar .day {
    min-width: 0;
    min-height: 76px;
    padding: 5px 3px;
    overflow: hidden;
  }

  .calendar .day-top {
    min-width: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .calendar .day-actions {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 2px;
  }

  .calendar .day-actions button:disabled {
    display: none;
  }

  .calendar .day-actions .day-add,
  .calendar .day-actions .day-race-btn {
    width: 17px;
    height: 17px;
    border-radius: 5px;
    font-size: 10px;
  }

  .calendar .session-chip,
  .calendar .race-chip {
    min-width: 0;
    min-height: 18px;
    max-height: 30px;
    padding: 4px 3px;
    overflow: hidden;
    font-size: 8px;
    font-weight: 950;
    line-height: 1.1;
    text-overflow: ellipsis;
  }

  .calendar .week-actions {
    gap: 2px;
  }

  .calendar .week-share-btn,
  .calendar .week-copy-btn,
  .calendar .week-download-btn {
    width: 20px;
    height: 20px;
  }

  .coach-table,
  .fit-lap-table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
  }

  .coach-table::after,
  .fit-lap-table::after {
    content: "Swipe sideways for more";
    display: block;
    padding: 8px 10px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 800;
    text-align: right;
  }
}

@media (max-width: 620px) {
  .coach-athlete-grid,
  .coach-athlete-grid > div,
  .coach-athlete-grid > .card {
    width:100%;
    min-width:0;
  }

  .coach-athlete-grid .calendar {
    max-width:100%;
    overflow-x:auto !important;
    overflow-y:visible;
    -webkit-overflow-scrolling:touch;
    touch-action:pan-x;
  }

  .coach-athlete-grid .calendar::after {
    content:"Swipe sideways for full coach calendar";
    display:block;
    padding:8px 2px 0;
    color:var(--muted);
    font-size:10px;
    font-weight:800;
    text-align:right;
  }

  .coach-athlete-grid .calendar .weekdays,
  .coach-athlete-grid .calendar .calendar-grid {
    width:auto;
    min-width:560px;
    grid-template-columns:repeat(7,minmax(72px,1fr));
    gap:5px;
  }

  .coach-athlete-grid .calendar .day {
    min-height:88px;
    padding:6px;
    overflow:hidden;
  }

  .coach-athlete-grid .calendar .day-top {
    flex-direction:row;
    align-items:flex-start;
  }

  .coach-athlete-grid .calendar .day-actions {
    flex-wrap:wrap;
    justify-content:flex-end;
  }

  .coach-athlete-grid .progress-body {
    width:100%;
    max-width:100%;
    overflow:visible;
    padding:18px 12px;
  }

  .coach-athlete-grid .progress-ring {
    width:min(140px,60vw);
    height:min(140px,60vw);
  }

  .coach-athlete-grid .progress-metrics,
  .coach-athlete-grid .fit-progress-metrics {
    grid-template-columns:1fr 1fr;
  }
}

@media (max-width: 430px) {
  .coach-athlete-grid .calendar .weekdays,
  .coach-athlete-grid .calendar .calendar-grid {
    min-width:520px;
    grid-template-columns:repeat(7,minmax(66px,1fr));
  }
}

/* Compact density refinements: trims unused white space while keeping phone tap targets usable. */
@media (min-width: 621px) {
  .card-head { padding:18px 20px; }
  .stat { padding:17px 18px; }
  .next-session { padding:18px; }
  .progress-body { padding:21px; }
  .athlete-info-grid > div { padding:13px 14px; }
  .profile-form { padding:21px; }
  .modal-top { padding:22px 24px; }
  .modal-body { padding:22px 24px; }
  .detail { padding:10px 11px; }
  .field { margin-bottom:14px; }
  .field input,
  .field select,
  .field textarea { padding:11px 12px; }
  .workout-builder,
  .repeat-results-card,
  .fit-upload-card,
  .workout-feedback-card,
  .completion-segments-card { padding:15px; }
  .rep-set-builder { padding:12px; }
  .rep-line-builder { padding:10px; }
  th, td { padding:12px 15px; }
}

@media (max-width: 620px) {
  .topbar { min-height:58px; padding:8px 12px; }
  .brand-compact { width:40px; height:40px; }
  .avatar { width:32px; height:32px; }
  .logout { min-height:36px; }
  .main { padding:0 9px; margin-top:12px; margin-bottom:42px; }
  .welcome { gap:9px; margin-bottom:14px; }
  .welcome h1 { font-size:31px; margin-bottom:4px; }
  .welcome-actions { gap:6px; }
  .welcome-actions > button { padding-left:9px; padding-right:9px; }
  .primary-btn,
  .secondary-btn,
  .share-option,
  .install-app-link { min-height:42px; padding:10px 13px; border-radius:10px; }
  .table-btn { min-height:36px; padding:6px 9px; }

  .field { margin-bottom:11px; }
  .field label { margin-bottom:5px; font-size:12px; }
  .field input,
  .field select,
  .field textarea { padding:9px 10px; border-radius:9px; }
  .field textarea { min-height:76px; }
  #session-details,#template-details { min-height:130px; line-height:1.55; }
  .form-row { gap:10px; }

  .stats { gap:6px; margin-bottom:14px; }
  .stat { padding:10px 11px; border-radius:13px; }
  .stat-value { font-size:24px; line-height:1; }
  .stat-label { font-size:11px; line-height:1.2; }
  .card { border-radius:14px; }
  .card-head { padding:11px 12px; gap:7px; }
  .card-head h2 { font-size:20px; }
  .icon-btn { width:38px; height:38px; border-radius:10px; }

  .calendar { padding:7px; }
  .calendar .weekdays,
  .calendar .calendar-grid { gap:3px; }
  .calendar .weekdays div { font-size:7.5px; padding-bottom:4px; }
  .calendar .day { min-height:68px; padding:4px 3px; border-radius:10px; }
  .calendar .day-actions .day-add,
  .calendar .day-actions .day-race-btn { width:16px; height:16px; font-size:9px; border-radius:5px; }
  .calendar .session-chip,
  .calendar .race-chip { min-height:17px; max-height:27px; padding:3px 3px; margin-top:4px; font-size:7.5px; font-weight:950; }
  .calendar .week-share-btn,
  .calendar .week-copy-btn,
  .calendar .week-download-btn { width:18px; height:18px; }
  .coach-athlete-grid .calendar .day { min-height:78px; padding:5px; }
  .coach-athlete-grid .calendar .weekdays,
  .coach-athlete-grid .calendar .calendar-grid { min-width:500px; grid-template-columns:repeat(7,minmax(62px,1fr)); gap:4px; }

  .next-session { padding:14px; }
  .type-badge { padding:4px 8px; font-size:10px; }
  .next-session h3 { margin:10px 0 6px; font-size:20px; }
  .meta-list { margin:12px 0; }
  .meta-list li { padding:6px 0; }
  .recent { padding:0 14px 8px; }
  .recent-item { padding:10px 0; gap:9px; }

  .athlete-info-grid { gap:8px; margin-bottom:14px; }
  .athlete-info-grid > div { padding:10px 11px; border-radius:11px; }
  .athlete-title-row { gap:9px; }
  .avatar.large { width:48px; height:48px; }
  .athlete-lower-grid { gap:14px; }
  .athlete-list-row { padding:9px; gap:8px; border-radius:10px; }
  .athlete-list { gap:6px; padding:8px; }
  .athlete-folder summary { padding:10px 11px; }
  .athlete-folder-rows { gap:6px; padding:0 7px 7px; }
  .profile-form { padding:14px; }
  .profile-list { padding:2px 10px 10px; }
  .profile-row { gap:8px; padding:10px 0; }
  .active-toggle { padding:9px 0 13px; }

  .progress-body,
  .coach-athlete-grid .progress-body { padding:13px 10px; }
  .progress-ring,
  .coach-athlete-grid .progress-ring { width:min(116px,50vw); height:min(116px,50vw); margin-bottom:12px; }
  .progress-ring::after { inset:10px; }
  .progress-ring strong { font-size:30px; }
  .progress-metrics { padding:10px 0; margin-bottom:10px; }
  .load-progress-metrics { gap:6px; margin-bottom:10px; }
  .load-progress-metrics > div { padding:8px 6px; border-radius:8px; }
  .fit-progress-metrics { gap:6px; margin-top:8px; }
  .fit-progress-metrics > div { padding:8px 6px; }

  .modal { max-height:95dvh; border-radius:16px 16px 0 0; }
  .modal-top { padding:14px 14px; }
  .modal-top h2 { font-size:23px; margin:6px 38px 2px 0; }
  .modal-body { padding:12px 11px calc(16px + env(safe-area-inset-bottom)); }
  .modal-actions { gap:8px; margin-top:16px; }
  .close { width:34px; height:34px; right:10px; top:10px; }
  .detail-grid { gap:7px; margin:10px 0; }
  .detail { padding:9px 10px; border-radius:9px; }
  .workout-block { margin:11px 0; padding:12px; line-height:1.45; }
  .training-focus-card { margin:8px 0 12px; padding:10px 11px; gap:10px; }
  .load-score-grid { gap:7px; margin-bottom:12px; }
  .load-score-grid > div { padding:9px; }
  .race-priority-strip { gap:8px; margin-bottom:10px; padding:10px 11px; border-radius:11px; }

  .workout-builder,
  .repeat-results-card,
  .fit-upload-card,
  .workout-feedback-card,
  .completion-segments-card { padding:10px; margin-bottom:12px; border-radius:12px; }
  .builder-row,
  .builder-row + .builder-row,
  .builder-row.reps-builder,
  .structured-segment-grid { gap:9px; }
  .structured-segment-grid { margin-bottom:11px; padding-bottom:11px; }
  .rep-set-builders,
  .rep-line-list { gap:8px; }
  .rep-set-builder,
  .rep-line-builder,
  .set-rest-bottom { padding:9px; border-radius:10px; }
  .rep-set-head,
  .rep-line-head { gap:6px; margin-bottom:7px; }
  .rep-details-row { gap:8px; margin-top:8px; }
  .metric-toggle { margin-bottom:5px; }
  .metric-value { gap:5px; grid-template-columns:1fr 62px; }
  .metric-value input,
  .metric-value select,
  .count-control select { padding:8px 9px; border-radius:8px; }
  .time-suffix { font-size:10px; }
  .add-rep-line-btn { margin-top:8px; }
  .repeat-set { margin-top:11px; }
  .repeat-average { margin-top:12px; padding:10px 11px; }
  .repeat-average.set-average { padding:8px 9px; }
  .completion-segment { gap:9px; padding-top:10px; }
  .completion-segment + .completion-segment { margin-top:10px; }
  .completion-segment h5 { font-size:14px; }
  .fit-analysis-card { margin-top:12px; padding:11px; }
  .fit-comparison-grid > div { padding:8px; }
  .workout-feedback-card textarea { min-height:92px; padding:10px 11px; }

  th, td { padding:9px 10px; font-size:12px; }
  .empty-state { padding:26px 14px; }
  .report-filters { padding:12px; margin-bottom:12px; }
  .report-grid { gap:12px; margin-top:12px; }
  .report-chart { padding:0 12px 12px; }
  .weekly-mileage-strip { grid-template-columns:1fr; }
  .shoe-list { padding:0 12px 12px; }
  .shoe-metrics { grid-template-columns:1fr; }
  .shoe-actions { justify-content:stretch; }
  .shoe-actions .table-btn { flex:1; }
  .report-structure { gap:7px; padding:0 12px 12px; }
  .report-structure div,
  .report-structure-card { padding:10px; border-radius:10px; }
  .science-card { padding:12px; }

  .library-toolbar { padding:12px; margin-bottom:18px; gap:10px; }
  .library-search input,
  .library-filter select,
  .library-count { height:40px; }
  .library-section + .library-section,
  .warmup-library-section,
  .workout-type-library-section { margin-top:24px; padding-top:20px; }
  .library-section-head { gap:10px; margin-bottom:10px; }
  .library-section-head h2 { font-size:22px; }
  .library-card-main { padding:8px 10px; }
  .library-card-summary { gap:6px 9px; }
  .library-card-details { margin-top:7px; padding-top:7px; }
  .library-card-actions { padding:7px 8px; }
  .template-preview-hero,
  .template-detail,
  .focus-callout,
  .warmup-picker-field,
  .session-library-picker,
  .copy-week-source,
  .copy-week-preview { padding:10px; margin-bottom:10px; border-radius:10px; }

  .message-thread-head { padding:12px; }
  .message-thread-body { min-height:260px; padding:10px; }
  .message-compose { padding:10px; gap:8px; }
  .message-help { padding:0 10px 10px; }
  .share-dialog { padding:16px 14px calc(14px + env(safe-area-inset-bottom)); }
}

.benchmark-context-card,
.benchmark-context-preview {
  margin:14px 0;
  padding:14px;
  border:1px solid rgba(0,174,239,.18);
  border-radius:16px;
  background:linear-gradient(135deg,rgba(0,174,239,.08),rgba(190,232,38,.12));
}
.benchmark-context-preview.muted {
  background:#f7faf5;
  border-color:#dfe8d9;
}
.benchmark-context-card h4,
.benchmark-context-preview h4 {
  margin:4px 0 10px;
  font-size:17px;
}
.benchmark-context-preview p {
  margin:6px 0 0;
  color:var(--muted);
}
.benchmark-context-list {
  display:grid;
  gap:8px;
}
.benchmark-context-list div {
  display:grid;
  gap:3px;
  padding:10px;
  border-radius:12px;
  background:rgba(255,255,255,.78);
  box-shadow:inset 0 0 0 1px rgba(10,31,46,.06);
}
.benchmark-context-list strong {
  color:var(--ink);
  font-size:13px;
}
.benchmark-context-list span,
.benchmark-context-list small {
  color:var(--muted);
  font-size:12px;
}

@media (max-width: 430px) {
  .calendar .day { min-height:64px; }
  .coach-athlete-grid .calendar .day { min-height:74px; }
  .coach-athlete-grid .calendar .weekdays,
  .coach-athlete-grid .calendar .calendar-grid { min-width:480px; grid-template-columns:repeat(7,minmax(60px,1fr)); }
  .welcome h1 { font-size:29px; }
  .stat { padding:9px 10px; }
  .modal-top h2 { font-size:21px; }
}

/* Calendar week actions menu and fixed-width workout cards.
   Layout-only patch: uses existing RacePace variables and does not change fonts or colour tokens. */
.calendar-week-row { position:relative; }
.calendar-week-row > .week-actions {
  position:relative;
  align-self:stretch;
  justify-content:center;
  align-items:center;
  flex-direction:column;
  width:34px;
  min-width:34px;
  margin-top:0;
  padding:0;
  border:0;
  background:transparent;
  overflow:visible;
  z-index:2;
}

.week-actions.dropdown-container { overflow:visible; }
.week-actions-toggle {
  width:34px;
  height:34px;
  display:grid;
  place-items:center;
  padding:0;
  border:1px solid var(--line);
  border-radius:10px;
  background:var(--white);
  color:var(--navy);
  font-size:18px;
  font-weight:900;
  line-height:1;
  cursor:pointer;
  transition:.15s;
}
.week-actions-toggle:hover,
.week-actions-toggle:focus {
  border-color:var(--cyan);
  color:var(--blue);
  outline:none;
  transform:translateY(-1px);
}
.week-actions-menu {
  display:none;
  position:absolute;
  top:100%;
  right:0;
  margin-top:6px;
  z-index:160;
  min-width:168px;
  padding:6px;
  border:1px solid var(--line);
  border-radius:12px;
  background:var(--white);
  box-shadow:var(--shadow);
  flex-direction:column;
  gap:2px;
}
.week-actions-menu.show { display:flex; }

.week-actions-menu button.week-copy-btn,
.week-actions-menu button.week-download-btn,
.week-actions-menu button.week-share-btn {
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:8px;
  width:100% !important;
  height:auto !important;
  min-height:0 !important;
  padding:9px 10px !important;
  margin:0 !important;
  border:0 !important;
  border-radius:8px !important;
  background:transparent !important;
  color:var(--navy) !important;
  font-size:12px !important;
  font-weight:800 !important;
  line-height:1.2 !important;
  opacity:1 !important;
  box-shadow:none !important;
  text-align:left !important;
  transform:none !important;
}
.week-actions-menu button.week-copy-btn:hover,
.week-actions-menu button.week-download-btn:hover,
.week-actions-menu button.week-share-btn:hover,
.week-actions-menu button.week-copy-btn:focus,
.week-actions-menu button.week-download-btn:focus,
.week-actions-menu button.week-share-btn:focus {
  color:var(--blue) !important;
  outline:none;
}
.week-actions-menu svg {
  width:15px;
  height:15px;
  flex:0 0 15px;
}
.week-actions-menu span {
  display:inline-flex;
  align-items:center;
}
.calendar .session-chip {
  max-width:100%;
  min-width:0;
  overflow:hidden !important;
  white-space:nowrap;
}
.calendar .session-chip-type {
  max-width:100%;
  min-width:0;
  overflow:hidden;
  text-overflow:clip;
  white-space:nowrap;
  container-type:inline-size;
}
.calendar .session-chip-name {
  max-width:100%;
  min-width:0;
  overflow:hidden;
  text-overflow:clip;
  white-space:nowrap;
  container-type:inline-size;
}
.calendar .session-chip-marquee {
  display:inline-block;
  width:max-content;
  max-width:none;
  padding-right:18px;
  white-space:nowrap;
  transform:translateX(0);
  will-change:transform;
}
.calendar .session-chip-type .session-chip-marquee {
  animation:session-chip-type-scroll 16s ease-in-out 1s infinite;
}
.calendar .session-chip-name .session-chip-marquee {
  animation:session-chip-name-scroll 16s ease-in-out 1s infinite;
}
@keyframes session-chip-type-scroll {
  0%,8% { transform:translateX(0); }
  18%,32% { transform:translateX(min(0px, calc(100cqw - 100%))); }
  42%,100% { transform:translateX(0); }
}
@keyframes session-chip-name-scroll {
  0%,50% { transform:translateX(0); }
  60%,74% { transform:translateX(min(0px, calc(100cqw - 100%))); }
  84%,100% { transform:translateX(0); }
}
@media (prefers-reduced-motion:reduce) {
  .calendar .session-chip-marquee { animation:none; }
}
.calendar .day {
  min-width:0;
  overflow:hidden;
}

/* Coach mobile calendar alignment patch.
   Layout-only: keeps existing RacePace colours and fonts unchanged. */
@media (max-width: 620px) {
  .coach-athlete-grid .calendar {
    max-width: 100%;
    overflow-x: visible !important;
    overflow-y: visible;
    touch-action: auto;
  }

  .coach-athlete-grid .calendar::after {
    content: none !important;
    display: none !important;
  }

  .coach-athlete-grid .calendar-weekday-row,
  .coach-athlete-grid .calendar-week-row {
    grid-template-columns: minmax(0, 1fr) 28px;
    gap: 4px;
    min-width: 0;
    align-items: stretch;
    overflow: visible;
  }

  .coach-athlete-grid .week-actions-spacer {
    width: 28px;
    min-width: 28px;
  }

  .coach-athlete-grid .calendar .weekdays,
  .coach-athlete-grid .calendar .calendar-grid {
    width: 100% !important;
    min-width: 0 !important;
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 3px;
  }

  .coach-athlete-grid .calendar .day {
    min-width: 0;
    min-height: 72px;
    padding: 4px 3px;
    overflow: hidden;
  }

  .coach-athlete-grid .calendar .day-top {
    min-width: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }

  .coach-athlete-grid .calendar .day-actions {
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 2px;
  }

  .coach-athlete-grid .calendar-week-row > .week-actions {
    position: relative;
    width: 28px;
    min-width: 28px;
    height: 100%;
    align-self: stretch;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    overflow: visible;
    z-index: 25;
  }

  .coach-athlete-grid .week-actions-toggle {
    width: 28px;
    height: 28px;
    border-radius: 10px;
    font-size: 15px;
  }

  .coach-athlete-grid .week-actions-menu {
    top: calc(50% + 18px);
    right: 0;
    left: auto;
    margin-top: 0;
    min-width: min(168px, calc(100vw - 36px));
  }
}

@media (max-width: 430px) {
  .coach-athlete-grid .calendar-weekday-row,
  .coach-athlete-grid .calendar-week-row {
    grid-template-columns: minmax(0, 1fr) 24px;
    gap: 3px;
  }

  .coach-athlete-grid .week-actions-spacer,
  .coach-athlete-grid .calendar-week-row > .week-actions {
    width: 24px;
    min-width: 24px;
  }

  .coach-athlete-grid .week-actions-toggle {
    width: 24px;
    height: 24px;
    border-radius: 9px;
    font-size: 14px;
  }

  .coach-athlete-grid .calendar .day {
    min-height: 68px;
    padding: 4px 2px;
  }
}


/* Coach mobile calendar hard fix v94.
   Layout-only patch: does not change RacePace colours or fonts.
   The coach calendar gets its own class so the mobile week menu cannot fall back inside the 7-day grid. */
@media (max-width: 620px) {
  .calendar.coach-calendar:not(.compare-calendar) {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
    touch-action: auto !important;
  }

  .calendar.coach-calendar:not(.compare-calendar)::after {
    content: none !important;
    display: none !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .calendar-weekday-row,
  .calendar.coach-calendar:not(.compare-calendar) .calendar-week-row {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 26px !important;
    gap: 3px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
    align-items: stretch !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .weekdays,
  .calendar.coach-calendar:not(.compare-calendar) .calendar-grid {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    display: grid !important;
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 3px !important;
    overflow: visible !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .week-actions-spacer,
  .calendar.coach-calendar:not(.compare-calendar) .calendar-week-row > .week-actions {
    width: 26px !important;
    min-width: 26px !important;
    max-width: 26px !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .calendar-week-row > .week-actions {
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    align-self: stretch !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    background: transparent !important;
    overflow: visible !important;
    z-index: 80 !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .week-actions-toggle {
    width: 24px !important;
    height: 24px !important;
    min-width: 24px !important;
    min-height: 24px !important;
    padding: 0 !important;
    border-radius: 9px !important;
    font-size: 14px !important;
    line-height: 1 !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .week-actions-menu {
    position: absolute !important;
    top: calc(50% + 16px) !important;
    right: 0 !important;
    left: auto !important;
    margin: 0 !important;
    transform: none !important;
    min-width: min(168px, calc(100vw - 36px)) !important;
    z-index: 220 !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .day {
    min-width: 0 !important;
    overflow: hidden !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .session-chip,
  .calendar.coach-calendar:not(.compare-calendar) .race-chip {
    max-width: 100% !important;
    min-width: 0 !important;
  }
}

@media (max-width: 430px) {
  .calendar.coach-calendar:not(.compare-calendar) .calendar-weekday-row,
  .calendar.coach-calendar:not(.compare-calendar) .calendar-week-row {
    grid-template-columns: minmax(0, 1fr) 22px !important;
    gap: 2px !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .week-actions-spacer,
  .calendar.coach-calendar:not(.compare-calendar) .calendar-week-row > .week-actions {
    width: 22px !important;
    min-width: 22px !important;
    max-width: 22px !important;
  }

  .calendar.coach-calendar:not(.compare-calendar) .week-actions-toggle {
    width: 21px !important;
    height: 21px !important;
    min-width: 21px !important;
    min-height: 21px !important;
    font-size: 13px !important;
  }
}


/* Coach athlete dashboard action buttons: icon-only, same RacePace colours/fonts */
.coach-action-icon-bar {
  width:min(780px,100%);
  display:flex;
  flex-wrap:wrap;
  align-items:flex-end;
  justify-content:flex-end;
  gap:8px;
}
.coach-action-icon-bar .athlete-switcher {
  flex:1 1 260px;
  max-width:340px;
  min-width:220px;
  width:auto;
}
.coach-action-icon-bar .dashboard-action-btn {
  flex:0 0 46px;
  width:46px;
  min-width:46px;
  height:46px;
  min-height:46px;
  padding:0;
  display:grid;
  place-items:center;
  line-height:1;
}
.coach-action-icon-bar .dashboard-action-svg {
  width:22px;
  height:22px;
  fill:none;
  stroke:currentColor;
  stroke-width:2;
  stroke-linecap:round;
  stroke-linejoin:round;
  pointer-events:none;
}
.coach-action-icon-bar #add-athlete-session .dashboard-action-svg {
  width:24px;
  height:24px;
}

@media (max-width: 900px) {
  .coach-action-icon-bar {
    display:flex;
    width:100%;
    justify-content:flex-start;
  }
  .coach-action-icon-bar .athlete-switcher {
    flex:1 1 100%;
    max-width:none;
    min-width:0;
  }
  .coach-action-icon-bar .dashboard-action-btn {
    flex:0 0 44px;
    width:44px;
    min-width:44px;
    height:44px;
    min-height:44px;
  }
}

@media (max-width: 430px) {
  .coach-action-icon-bar {
    gap:6px;
  }
  .coach-action-icon-bar .dashboard-action-btn {
    flex:0 0 41px;
    width:41px;
    min-width:41px;
    height:41px;
    min-height:41px;
  }
  .coach-action-icon-bar .dashboard-action-svg {
    width:20px;
    height:20px;
  }
}


/* Coach dashboard/action icons: electric-blue buttons with white icons */
.coach-action-icon-bar .dashboard-action-btn {
  border:1px solid rgba(255,255,255,.42) !important;
  background:linear-gradient(135deg,#00bfff 0%,#087ca7 58%,#0d2232 150%) !important;
  color:#fff !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.18),0 9px 22px rgba(0,191,255,.22) !important;
}
.coach-action-icon-bar .dashboard-action-btn:hover,
.coach-action-icon-bar .dashboard-action-btn:focus {
  color:#fff !important;
  border-color:rgba(255,255,255,.7) !important;
  background:linear-gradient(135deg,#13d7ff 0%,#087ca7 52%,#0d2232 145%) !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.25),0 11px 26px rgba(0,191,255,.3) !important;
  transform:translateY(-1px);
  outline:none;
}
.coach-action-icon-bar .dashboard-action-svg {
  color:#fff;
  stroke:#fff;
}
.coach-dashboard-actions {
  width:auto;
  max-width:360px;
  flex:0 1 auto;
  align-items:center;
}
.coach-dashboard-actions .dashboard-action-btn {
  flex:0 0 48px;
  width:48px;
  min-width:48px;
  height:48px;
  min-height:48px;
}
.coach-dashboard-actions .dashboard-action-svg {
  width:23px;
  height:23px;
}

@media (max-width: 900px) {
  .coach-dashboard-actions {
    width:100%;
    max-width:none;
    justify-content:flex-start;
  }
}


/* Refined RacePace action icons and full button colouring */
.dashboard-action-svg .icon-plus-badge {
  fill:#fff;
  stroke:#fff;
  stroke-width:1.7;
}
.dashboard-action-svg .icon-plus-mark {
  stroke:#087ca7;
  stroke-width:1.8;
  stroke-linecap:round;
}
.dashboard-action-svg.badge-plus-svg {
  width:25px;
  height:25px;
}
#coach-athlete-month-pdf .dashboard-action-svg,
#manage-athletes .dashboard-action-svg,
#add-session .dashboard-action-svg,
#add-athlete-session .dashboard-action-svg,
#add-athlete-race .dashboard-action-svg {
  width:25px;
  height:25px;
}

/* Keep text buttons full-size, but give coach tool areas the same electric-blue treatment */
.profile-manager .primary-btn,
.profile-manager .secondary-btn,
.profile-form .primary-btn,
.profile-form .secondary-btn,
.library-heading .primary-btn,
.library-section-head .secondary-btn,
.library-empty .secondary-btn,
.template-editor-modal .primary-btn,
.template-editor-modal .secondary-btn,
.session-library-picker .secondary-btn,
.report-heading .primary-btn,
.month-pdf-choice-grid .secondary-btn,
.month-pdf-backdrop .modal-actions .secondary-btn,
.month-pdf-actions .secondary-btn,
.coach-modal .modal-actions .primary-btn,
.coach-modal .modal-actions .secondary-btn {
  border:1px solid rgba(255,255,255,.42) !important;
  background:linear-gradient(135deg,#00bfff 0%,#087ca7 58%,#0d2232 150%) !important;
  color:#fff !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.18),0 9px 22px rgba(0,191,255,.22) !important;
}
.profile-manager .primary-btn:hover,
.profile-manager .primary-btn:focus,
.profile-manager .secondary-btn:hover,
.profile-manager .secondary-btn:focus,
.profile-form .primary-btn:hover,
.profile-form .primary-btn:focus,
.profile-form .secondary-btn:hover,
.profile-form .secondary-btn:focus,
.library-heading .primary-btn:hover,
.library-heading .primary-btn:focus,
.library-section-head .secondary-btn:hover,
.library-section-head .secondary-btn:focus,
.library-empty .secondary-btn:hover,
.library-empty .secondary-btn:focus,
.template-editor-modal .primary-btn:hover,
.template-editor-modal .primary-btn:focus,
.template-editor-modal .secondary-btn:hover,
.template-editor-modal .secondary-btn:focus,
.session-library-picker .secondary-btn:hover,
.session-library-picker .secondary-btn:focus,
.report-heading .primary-btn:hover,
.report-heading .primary-btn:focus,
.month-pdf-choice-grid .secondary-btn:hover,
.month-pdf-choice-grid .secondary-btn:focus,
.month-pdf-backdrop .modal-actions .secondary-btn:hover,
.month-pdf-backdrop .modal-actions .secondary-btn:focus,
.month-pdf-actions .secondary-btn:hover,
.month-pdf-actions .secondary-btn:focus,
.coach-modal .modal-actions .primary-btn:hover,
.coach-modal .modal-actions .primary-btn:focus,
.coach-modal .modal-actions .secondary-btn:hover,
.coach-modal .modal-actions .secondary-btn:focus {
  color:#fff !important;
  border-color:rgba(255,255,255,.7) !important;
  background:linear-gradient(135deg,#13d7ff 0%,#087ca7 52%,#0d2232 145%) !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.25),0 11px 26px rgba(0,191,255,.3) !important;
  transform:translateY(-1px);
  outline:none;
}
.profile-manager .table-btn:not(.danger),
.library-card-actions .table-btn:not(.danger),
.report-structure-card {
  border:1px solid rgba(0,191,255,.45) !important;
  background:linear-gradient(135deg,rgba(0,191,255,.14),rgba(8,124,167,.08)) !important;
  color:#087ca7 !important;
}
.profile-manager .table-btn:not(.danger):hover,
.profile-manager .table-btn:not(.danger):focus,
.library-card-actions .table-btn:not(.danger):hover,
.library-card-actions .table-btn:not(.danger):focus,
.report-structure-card:hover,
.report-structure-card:focus {
  border-color:#00bfff !important;
  background:linear-gradient(135deg,#00bfff 0%,#087ca7 58%,#0d2232 150%) !important;
  color:#fff !important;
  box-shadow:0 9px 22px rgba(0,191,255,.22) !important;
}

/* Athlete dashboard action buttons: RacePace blue, fixed height, no scrolling text */
.athlete-dashboard-actions {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  width:min(620px,100%);
  align-items:stretch;
  justify-content:end;
}
.athlete-dashboard-actions .athlete-action-btn {
  min-width:0;
  width:100%;
  height:58px;
  min-height:58px;
  max-height:58px;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  padding:0 16px;
  border:1px solid rgba(255,255,255,.42) !important;
  background:linear-gradient(135deg,#00bfff 0%,#087ca7 58%,#0d2232 150%) !important;
  color:#fff !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.18),0 9px 22px rgba(0,191,255,.22) !important;
  text-align:center;
  white-space:nowrap;
}
.athlete-dashboard-actions .athlete-action-btn:hover,
.athlete-dashboard-actions .athlete-action-btn:focus {
  color:#fff !important;
  border-color:rgba(255,255,255,.7) !important;
  background:linear-gradient(135deg,#13d7ff 0%,#087ca7 52%,#0d2232 145%) !important;
  box-shadow:inset 0 0 0 1px rgba(255,255,255,.25),0 11px 26px rgba(0,191,255,.3) !important;
  transform:translateY(-1px);
  outline:none;
}
.athlete-dashboard-actions .athlete-action-scroll {
  position:relative;
}
.athlete-action-marquee {
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  max-width:100%;
  min-width:0;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  animation:none;
}
.athlete-dashboard-actions .athlete-action-btn:not(.athlete-action-scroll) .athlete-action-marquee {
  animation:none;
}
.athlete-whatsapp-icon {
  flex:0 0 auto;
  width:22px;
  height:22px;
  color:#fff;
}
.athlete-whatsapp-icon path:first-child {
  fill:none;
  stroke:currentColor;
  stroke-width:1.8;
  stroke-linecap:round;
  stroke-linejoin:round;
}
.athlete-whatsapp-icon path:last-child {
  fill:currentColor;
  stroke:none;
}
.athlete-dashboard-actions .date-pill {
  grid-column:1 / -1;
  justify-self:end;
}
@media (min-width: 901px) {
  .athlete-dashboard-actions .athlete-action-btn {
    height:60px;
    min-height:60px;
    max-height:60px;
  }
}
@media (max-width: 640px) {
  .athlete-dashboard-actions {
    width:100%;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:9px;
  }
  .athlete-dashboard-actions .athlete-action-btn {
    height:54px;
    min-height:54px;
    max-height:54px;
    padding:0 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .athlete-action-marquee {
    animation:none;
    min-width:0;
    overflow:hidden;
    text-overflow:ellipsis;
  }
}


/* v100 dashboard icon refresh: stronger blue button theme + descriptive icons */
.coach-action-icon-bar .dashboard-action-btn {
  border: 1px solid rgba(38, 232, 255, .95) !important;
  border-radius: 16px !important;
  background: linear-gradient(180deg, #0f70ff 0%, #0b58db 40%, #083ea8 70%, #062a73 100%) !important;
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.22),
    inset 0 0 0 2px rgba(0,175,255,.18),
    0 0 0 1px rgba(0,191,255,.18),
    0 10px 22px rgba(5,72,188,.28),
    0 0 16px rgba(0,234,255,.12) !important;
}
.coach-action-icon-bar .dashboard-action-btn:hover,
.coach-action-icon-bar .dashboard-action-btn:focus {
  border-color: #54f0ff !important;
  background: linear-gradient(180deg, #1584ff 0%, #0d64f0 42%, #0a47ba 72%, #072f7e 100%) !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.3),
    inset 0 0 0 2px rgba(0,210,255,.22),
    0 12px 24px rgba(5,72,188,.32),
    0 0 20px rgba(0,234,255,.18) !important;
}
.coach-dashboard-actions .dashboard-action-btn,
.coach-athlete-actions .dashboard-action-btn {
  flex: 0 0 50px;
  width: 50px;
  min-width: 50px;
  height: 50px;
  min-height: 50px;
}
.coach-action-icon-bar .dashboard-action-svg {
  width: 24px;
  height: 24px;
}
.coach-action-icon-bar .dashboard-speed-lines {
  stroke: #43f0ff;
  stroke-width: 1.7;
  stroke-linecap: round;
}
#manage-athletes .dashboard-action-svg,
#add-session .dashboard-action-svg,
#add-athlete-session .dashboard-action-svg {
  width: 26px;
  height: 26px;
}
@media (max-width: 430px) {
  .coach-dashboard-actions .dashboard-action-btn,
  .coach-athlete-actions .dashboard-action-btn {
    flex: 0 0 44px;
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
  }
}


/* v101 unify text buttons with the same RacePace electric-blue style */
.primary-btn,
.secondary-btn,
.table-btn:not(.danger) {
  border: 1px solid rgba(38, 232, 255, .95);
  background: linear-gradient(180deg, #12a9ff 0%, #0b68f0 38%, #0847ba 70%, #062f81 100%);
  color: #fff;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.22),
    inset 0 0 0 1px rgba(0,175,255,.18),
    0 0 0 1px rgba(0,191,255,.18),
    0 10px 22px rgba(5,72,188,.22),
    0 0 16px rgba(0,234,255,.10);
}
.primary-btn:hover,
.primary-btn:focus,
.secondary-btn:hover,
.secondary-btn:focus,
.table-btn:not(.danger):hover,
.table-btn:not(.danger):focus {
  color: #fff;
  border-color: #54f0ff;
  background: linear-gradient(180deg, #19beff 0%, #0d79ff 38%, #0a54cf 70%, #073793 100%);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.28),
    inset 0 0 0 1px rgba(0,210,255,.20),
    0 12px 24px rgba(5,72,188,.28),
    0 0 18px rgba(0,234,255,.14);
}
/* keep destructive buttons distinct */
.table-btn.danger,
.secondary-btn.danger,
.primary-btn.danger {
  border-color: rgba(240,82,82,.8) !important;
}


/* v102 icon cleanup */
.coach-action-icon-bar .dashboard-speed-lines,
.dashboard-action-svg .dashboard-speed-lines { display:none !important; }


/* v103 final button colour sweep: force all remaining text buttons and athlete page buttons to match the shiny icon-button theme */
.primary-btn,
.secondary-btn,
.table-btn:not(.danger),
.report-heading #download-report-pdf,
.library-heading #new-workout-template,
.month-pdf-choice-grid .secondary-btn,
.month-pdf-backdrop .modal-actions .secondary-btn,
.month-pdf-actions .secondary-btn,
.athlete-dashboard-actions .athlete-action-btn,
.athlete-dashboard-actions .secondary-btn,
.welcome-actions .athlete-action-btn,
.profile-manager .primary-btn,
.profile-manager .secondary-btn,
.profile-form .primary-btn,
.profile-form .secondary-btn,
.library-heading .primary-btn,
.library-section-head .secondary-btn,
.library-empty .secondary-btn,
.template-editor-modal .primary-btn,
.template-editor-modal .secondary-btn,
.session-library-picker .secondary-btn,
.report-heading .primary-btn,
.coach-modal .modal-actions .primary-btn,
.coach-modal .modal-actions .secondary-btn,
.modal-actions .primary-btn,
.modal-actions .secondary-btn {
  border: 1px solid rgba(38, 232, 255, .95) !important;
  background: linear-gradient(180deg, #12a9ff 0%, #0b68f0 38%, #0847ba 70%, #062f81 100%) !important;
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.22),
    inset 0 0 0 1px rgba(0,175,255,.18),
    0 0 0 1px rgba(0,191,255,.18),
    0 10px 22px rgba(5,72,188,.22),
    0 0 16px rgba(0,234,255,.10) !important;
}
.primary-btn:hover,
.primary-btn:focus,
.secondary-btn:hover,
.secondary-btn:focus,
.table-btn:not(.danger):hover,
.table-btn:not(.danger):focus,
.report-heading #download-report-pdf:hover,
.report-heading #download-report-pdf:focus,
.library-heading #new-workout-template:hover,
.library-heading #new-workout-template:focus,
.month-pdf-choice-grid .secondary-btn:hover,
.month-pdf-choice-grid .secondary-btn:focus,
.month-pdf-backdrop .modal-actions .secondary-btn:hover,
.month-pdf-backdrop .modal-actions .secondary-btn:focus,
.month-pdf-actions .secondary-btn:hover,
.month-pdf-actions .secondary-btn:focus,
.athlete-dashboard-actions .athlete-action-btn:hover,
.athlete-dashboard-actions .athlete-action-btn:focus,
.welcome-actions .athlete-action-btn:hover,
.welcome-actions .athlete-action-btn:focus,
.profile-manager .primary-btn:hover,
.profile-manager .primary-btn:focus,
.profile-manager .secondary-btn:hover,
.profile-manager .secondary-btn:focus,
.profile-form .primary-btn:hover,
.profile-form .primary-btn:focus,
.profile-form .secondary-btn:hover,
.profile-form .secondary-btn:focus,
.library-heading .primary-btn:hover,
.library-heading .primary-btn:focus,
.library-section-head .secondary-btn:hover,
.library-section-head .secondary-btn:focus,
.library-empty .secondary-btn:hover,
.library-empty .secondary-btn:focus,
.template-editor-modal .primary-btn:hover,
.template-editor-modal .primary-btn:focus,
.template-editor-modal .secondary-btn:hover,
.template-editor-modal .secondary-btn:focus,
.session-library-picker .secondary-btn:hover,
.session-library-picker .secondary-btn:focus,
.report-heading .primary-btn:hover,
.report-heading .primary-btn:focus,
.coach-modal .modal-actions .primary-btn:hover,
.coach-modal .modal-actions .primary-btn:focus,
.coach-modal .modal-actions .secondary-btn:hover,
.coach-modal .modal-actions .secondary-btn:focus,
.modal-actions .primary-btn:hover,
.modal-actions .primary-btn:focus,
.modal-actions .secondary-btn:hover,
.modal-actions .secondary-btn:focus {
  border-color: #54f0ff !important;
  background: linear-gradient(180deg, #19beff 0%, #0d79ff 38%, #0a54cf 70%, #073793 100%) !important;
  color: #fff !important;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.28),
    inset 0 0 0 1px rgba(0,210,255,.20),
    0 12px 24px rgba(5,72,188,.28),
    0 0 18px rgba(0,234,255,.14) !important;
}
/* Keep danger buttons red so destructive actions remain obvious */
.table-btn.danger,
.secondary-btn.danger,
.primary-btn.danger,
#delete-session-btn,
#delete-race-btn {
  border-color: rgba(240,82,82,.85) !important;
  background: #f8e1e1 !important;
  color: #9a3f3f !important;
  box-shadow: none !important;
}

/* v104 coach browser calendar snapshot collapse */
.coach-calendar-head-actions {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:10px;
  min-width:0;
}
.coach-snapshot-head-actions {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
}
.coach-snapshot-toggle,
.coach-snapshot-hide,
.coach-snapshot-show {
  min-height:34px;
  padding:8px 12px;
  font-size:11px;
  line-height:1;
  white-space:nowrap;
}
.coach-athlete-calendar-panel {
  min-width:0;
}
.coach-snapshot-panel {
  min-width:0;
}
.coach-athlete-grid.snapshot-collapsed {
  grid-template-columns: minmax(0, 1fr);
}
.coach-athlete-grid.snapshot-collapsed .coach-snapshot-panel {
  display:none;
}
.coach-athlete-grid.snapshot-collapsed .calendar {
  overflow-x:visible;
}
@media (min-width: 901px) {
  .coach-athlete-grid.snapshot-collapsed .calendar-weekday-row,
  .coach-athlete-grid.snapshot-collapsed .calendar-week-row {
    grid-template-columns:minmax(0,1fr) auto;
  }
  .coach-athlete-grid.snapshot-collapsed .day {
    min-height:108px;
  }
}
@media (max-width: 900px) {
  .coach-snapshot-hide,
  .coach-snapshot-show {
    display:none !important;
  }
  .coach-athlete-grid.snapshot-collapsed {
    grid-template-columns:1fr;
  }
  .coach-athlete-grid.snapshot-collapsed .coach-snapshot-panel {
    display:block;
  }
}

/* v105 login centering + mobile calendar landscape hint */
.login-hero {
  align-items: center;
  text-align: center;
}
.login-hero .brand-wordmark,
.login-hero .brand,
.login-hero .hero-copy,
.login-hero .login-note {
  margin-left: auto;
  margin-right: auto;
}
.hero-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero-copy p {
  margin-left: auto;
  margin-right: auto;
}
.hero-tagline {
  margin-left: auto;
  margin-right: auto;
}
.login-note {
  width: 100%;
  margin-top: 20px;
  color: #9fdff6;
  font-size: 15px;
  font-weight: 900;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.calendar-mobile-landscape-hint {
  display: none;
}
@media (max-width: 900px) {
  .calendar-mobile-landscape-hint {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    margin: 0 0 10px;
    padding: 7px 10px;
    color: var(--muted);
    font-size: 11px;
    font-weight: 800;
    line-height: 1.25;
    text-align: center;
  }
  .calendar-mobile-landscape-hint svg {
    width: 17px;
    height: 17px;
    flex: 0 0 auto;
    fill: none;
    stroke: var(--cyan);
    stroke-width: 1.9;
    stroke-linecap: round;
    stroke-linejoin: round;
  }
}
@media (orientation: landscape) and (max-width: 900px) {
  .calendar-mobile-landscape-hint {
    display: none;
  }
}

/* v106 login portal title above wordmark */
.login-brand-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.login-brand-stack .login-note {
  margin-top: 0;
  margin-bottom: 0;
}
.login-brand-stack .brand-wordmark {
  margin-left: auto;
  margin-right: auto;
}

/* v107 completed workout card colour lock */
.session-chip.completed {
  background: #058731 !important;
  color: #c9f2cc !important;
  border-color: #39ff14 !important;
}

/* v109 add session icon changed to stopwatch */
#add-session .dashboard-action-svg,
#add-athlete-session .dashboard-action-svg {
  width: 26px;
  height: 26px;
}

/* v111 compact mobile dropdown lists */
select,
select option,
select optgroup {
  font-size: 14px;
  line-height: 1.25;
}

select {
  max-width: 100%;
  min-width: 0;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 900px) {
  select,
  select option,
  select optgroup {
    font-size: 13px !important;
    line-height: 1.22 !important;
  }

  select {
    min-height: 44px;
    padding: 9px 34px 9px 12px !important;
    border-radius: 12px;
  }

  .athlete-switcher select,
  .coach-action-icon-bar .athlete-switcher select,
  #session-template-picker,
  #library-category,
  #race-athlete,
  #session-type,
  #template-type,
  #profile-group,
  #athlete-group,
  #report-athlete,
  #athlete-report-athlete,
  #completion-shoe,
  #warmup-category,
  [id$="-warmup-template"] {
    font-size: 13px !important;
    line-height: 1.2 !important;
  }

  .athlete-switcher,
  .coach-action-icon-bar .athlete-switcher {
    min-width: 0;
  }
}

@media (max-width: 430px) {
  select,
  select option,
  select optgroup {
    font-size: 12.5px !important;
  }

  select {
    min-height: 42px;
    padding-top: 8px !important;
    padding-bottom: 8px !important;
  }
}

/* v114 keep unplanned workout cards neon orange, even when completed */
.session-chip.unplanned-run,
.session-chip.unplanned-run.completed,
.session-chip.completed.unplanned-run {
  background: #FF5C00 !important;
  border-color: #FF5C00 !important;
  color: #fff !important;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.22),
    0 0 0 2px rgba(255,92,0,.18),
    0 4px 12px rgba(255,92,0,.28) !important;
}

.session-chip.unplanned-run .session-chip-type,
.session-chip.unplanned-run .session-chip-name,
.session-chip.unplanned-run.completed .session-chip-type,
.session-chip.unplanned-run.completed .session-chip-name {
  color: #fff !important;
}

/* v117 athlete dashboard distance swap */
.weekly-mileage-strip {
  grid-template-columns: 1fr;
}
.weekly-mileage-strip .stat {
  width: 100%;
}

/* v118 weekly current/planned distance colours */
.weekly-distance-value {
  display: inline-flex;
  align-items: baseline;
  gap: 0;
  white-space: nowrap;
}

.weekly-distance-current-low {
  color: #e8b754;
}

.weekly-distance-current-under {
  color: #FF5C00;
}

.weekly-distance-current-close {
  color: #8ced85;
}

.weekly-distance-current-on {
  color: #058731;
}

.weekly-distance-current-over {
  color: #FF5C00;
}

.weekly-distance-planned {
  color: #058731;
}

.weekly-distance-separator {
  color: var(--ink);
}

.weekly-distance-value small {
  color: var(--ink);
  margin-left: .16em;
}

/* v119 estimated distance field for timed workouts */
.timed-distance-estimate {
  margin-top: 12px;
}

.timed-distance-estimate.hidden {
  display: none !important;
}

.km-inline-field {
  display: flex;
  align-items: center;
  gap: 8px;
}

.km-inline-field input {
  min-width: 0;
}

.km-inline-field span {
  color: var(--muted);
  font-weight: 900;
}

/* v120 timed interval rest distance and auto-estimate support */
.repeat-rest-distance-field {
  max-width: 260px;
  margin-top: 10px;
}

.repeat-rest-distance-field input {
  max-width: 170px;
}

.timed-distance-estimate small,
.repeat-rest-distance-field small {
  color: var(--muted);
}

/* v123 athlete dashboard small icon buttons + quick section navigation */
.athlete-dashboard-actions.coach-action-icon-bar {
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.athlete-dashboard-icon-btn {
  flex: 0 0 50px;
  width: 50px;
  min-width: 50px;
  height: 50px;
  min-height: 50px;
}

.athlete-dashboard-icon-btn .dashboard-action-svg {
  width: 25px;
  height: 25px;
}

.athlete-quick-links {
  margin-bottom: 18px;
}

.athlete-quick-link-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.athlete-quick-link-grid .dashboard-action-btn {
  flex: 0 0 50px;
  width: 50px;
  min-width: 50px;
  height: 50px;
  min-height: 50px;
}

.athlete-quick-link-grid .dashboard-action-svg {
  width: 25px;
  height: 25px;
}

.back-to-top-btn {
  min-height: 32px;
  padding: 7px 10px;
  font-size: 11px;
  line-height: 1;
  white-space: nowrap;
}

.section-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.report-benchmark-head {
  margin-bottom: 12px;
}

#athlete-top,
#athlete-report-section,
#athlete-report-weekly-mileage,
#athlete-report-training-load,
#athlete-report-benchmark-graph,
#athlete-report-benchmark-tables,
#athlete-report-effort,
#athlete-training-history,
#athlete-progress-snapshot,
#athlete-pace-calculator,
#athlete-running-shoes {
  scroll-margin-top: 92px;
}

@media (max-width: 700px) {
  .athlete-dashboard-actions.coach-action-icon-bar {
    justify-content: flex-start;
  }

  .athlete-dashboard-icon-btn,
  .athlete-quick-link-grid .dashboard-action-btn {
    flex-basis: 44px;
    width: 44px;
    min-width: 44px;
    height: 44px;
    min-height: 44px;
  }

  .athlete-dashboard-icon-btn .dashboard-action-svg,
  .athlete-quick-link-grid .dashboard-action-svg {
    width: 23px;
    height: 23px;
  }

  .athlete-quick-link-grid {
    gap: 8px;
  }

  .back-to-top-btn {
    font-size: 10.5px;
    padding: 7px 9px;
  }
}

/* v152 athlete button structure and custom icon buttons */
.dashboard-action-img {
  width: 26px;
  height: 26px;
  object-fit: contain;
  filter: brightness(0) invert(1);
  display: block;
}

.dashboard-action-combo {
  position: relative;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
}

.dashboard-action-combo .dashboard-action-svg {
  width: 30px;
  height: 30px;
}

.dashboard-action-badge-img {
  position: absolute;
  right: -3px;
  top: -4px;
  width: 14px;
  height: 14px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.athlete-dashboard-button-row,
.athlete-page-button-row {
  display: grid;
  gap: 10px;
  align-items: start;
}

.athlete-dashboard-button-row {
  grid-template-columns: repeat(6, minmax(62px, 1fr));
  width: min(100%, 560px);
}

.athlete-page-button-row.toolbox-row {
  grid-template-columns: repeat(3, minmax(72px, 1fr));
  width: min(100%, 360px);
}

.athlete-page-button-row.reports-row {
  grid-template-columns: repeat(5, minmax(62px, 1fr));
  width: min(100%, 520px);
}

.athlete-icon-tile-btn {
  width: 100%;
  min-width: 0;
  height: auto;
  min-height: 70px;
  padding: 8px 5px 7px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.athlete-icon-tile-btn .dashboard-action-svg {
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
}

.athlete-icon-tile-btn .dashboard-action-img {
  width: 27px;
  height: 27px;
}

.athlete-icon-tile-btn .dashboard-action-combo {
  width: 29px;
  height: 29px;
}

.athlete-icon-label {
  display: block;
  max-width: 100%;
  color: #fff;
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1.05;
  text-align: center;
  white-space: nowrap;
}

.athlete-page-menu-card {
  margin-bottom: 18px;
}

.athlete-screen-head .back-link {
  margin-bottom: 10px;
}

.back-link {
  border: 0;
  background: transparent;
  color: var(--blue);
  font-weight: 900;
  padding: 0;
  cursor: pointer;
}

.back-to-top-btn {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  line-height: 1;
  white-space: nowrap;
}

.back-to-top-btn .dashboard-action-img,
.back-to-top-btn .dashboard-action-svg {
  width: 17px;
  height: 17px;
  flex: 0 0 17px;
}

.athlete-tools-grid {
  align-items: start;
}

.athlete-races-card .card-head {
  align-items: center;
}

.athlete-race-list {
  display: grid;
  gap: 10px;
}

.athlete-race-row {
  width: 100%;
  border: 1px solid var(--line);
  background: #fbfcfa;
  border-radius: 18px;
  padding: 14px;
  text-align: left;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
}

.athlete-race-row:hover {
  border-color: rgba(0, 179, 255, .55);
  box-shadow: 0 8px 22px rgba(5, 72, 188, .10);
}

.athlete-race-title {
  color: var(--ink);
  font-weight: 900;
  font-size: 15px;
  line-height: 1.2;
}

.athlete-race-meta,
.athlete-race-countdown {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.35;
}

.athlete-race-countdown {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
}

.athlete-race-arrow {
  color: var(--blue);
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
}

@media (max-width: 700px) {
  .athlete-dashboard-button-row {
    grid-template-columns: repeat(6, minmax(44px, 1fr));
    width: 100%;
    gap: 8px 6px;
  }

  .athlete-page-button-row.toolbox-row {
    grid-template-columns: repeat(3, minmax(64px, 1fr));
    width: 100%;
  }

  .athlete-page-button-row.reports-row {
    grid-template-columns: repeat(5, minmax(50px, 1fr));
    width: 100%;
    gap: 8px 6px;
  }

  .athlete-icon-tile-btn {
    min-height: 64px;
    padding: 7px 3px 6px;
    border-radius: 14px;
  }

  .athlete-icon-tile-btn .dashboard-action-svg,
  .athlete-icon-tile-btn .dashboard-action-img {
    width: 24px;
    height: 24px;
    flex-basis: 24px;
  }

  .athlete-icon-tile-btn .dashboard-action-combo {
    width: 25px;
    height: 25px;
  }

  .athlete-icon-tile-btn .dashboard-action-combo .dashboard-action-svg {
    width: 25px;
    height: 25px;
  }

  .athlete-icon-tile-btn .dashboard-action-badge-img {
    width: 12px;
    height: 12px;
    right: -3px;
    top: -4px;
  }

  .athlete-icon-label {
    font-size: 9.2px;
  }

  .athlete-races-card .card-head {
    align-items: flex-start;
  }

  .athlete-races-card .card-head .primary-btn {
    width: 100%;
    justify-content: center;
  }
}


/* v160 athlete right-click / long-press quick complete popover */
.athlete-quick-complete-popover {
  position: fixed;
  z-index: 3000;
  width: min(280px, calc(100vw - 24px));
  background: #ffffff;
  border: 1px solid rgba(0, 179, 255, .38);
  border-radius: 18px;
  box-shadow: 0 18px 50px rgba(6, 26, 38, .22);
  padding: 12px;
}

.athlete-quick-complete-form {
  display: grid;
  gap: 10px;
}

.athlete-quick-complete-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.athlete-quick-complete-head span {
  display: block;
  color: var(--blue);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.athlete-quick-complete-head strong {
  display: block;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.15;
}

.athlete-quick-complete-close {
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #f8faf6;
  color: var(--ink);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.athlete-quick-complete-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.athlete-quick-complete-fields label {
  position: relative;
  display: grid;
  gap: 4px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.athlete-quick-complete-fields input {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 9px;
  font: inherit;
  font-weight: 900;
  color: var(--ink);
  background: #fbfcfa;
}

.athlete-quick-complete-fields small {
  position: absolute;
  right: 9px;
  bottom: 10px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
}

.athlete-quick-complete-fields label:first-child input {
  padding-right: 31px;
}

.athlete-quick-complete-save {
  width: 100%;
  justify-content: center;
  min-height: 38px;
  border-radius: 12px;
}



/* v161 coach race dashboard screens */
.coach-races-card {
  max-width: 980px;
}

.coach-race-month-list {
  display: grid;
  gap: 12px;
}

.coach-race-month {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fbfcfa;
  overflow: hidden;
}

.coach-race-month summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 15px 16px;
  cursor: pointer;
}

.coach-race-month summary::-webkit-details-marker {
  display: none;
}

.coach-race-month summary strong {
  display: block;
  color: var(--ink);
  font-size: 17px;
  font-weight: 950;
}

.coach-race-month summary span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.coach-race-month summary em {
  color: var(--blue);
  font-style: normal;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.coach-race-month[open] summary {
  border-bottom: 1px solid var(--line);
  background: rgba(0, 179, 255, .06);
}

.coach-race-list {
  padding: 12px;
}

.coach-race-row {
  background: #ffffff;
}

.compact-empty {
  padding: 14px;
}

#coach-races .dashboard-action-img,
#coach-athlete-races .dashboard-action-img {
  width: 25px;
  height: 25px;
}



/* v162 clickable athlete names in coach completed list */
.coach-table-athlete-link {
  display: inline-block;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-weight: 950;
  text-align: left;
  cursor: pointer;
}

.coach-table-athlete-link:hover,
.coach-table-athlete-link:focus {
  color: var(--blue);
  text-decoration: underline;
  outline: none;
}



/* v163 coach dashboard quick athlete search */
.coach-athlete-quick-search {
  position: relative;
  flex: 0 1 250px;
  min-width: 220px;
  align-self: center;
  display: grid;
  gap: 4px;
  margin-left: auto;
}

.coach-athlete-quick-search label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 950;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.coach-athlete-search-wrap {
  position: relative;
}

.coach-athlete-search-wrap input {
  width: 100%;
  min-height: 43px;
  border: 1px solid rgba(0, 179, 255, .35);
  border-radius: 14px;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-weight: 850;
  padding: 10px 12px;
  box-shadow: 0 10px 28px rgba(6, 26, 38, .08);
}

.coach-athlete-search-wrap input:focus {
  outline: 3px solid rgba(0, 179, 255, .18);
  border-color: var(--blue);
}

.coach-athlete-search-results {
  position: absolute;
  z-index: 2400;
  top: calc(100% + 7px);
  left: 0;
  right: 0;
  display: grid;
  gap: 4px;
  max-height: 300px;
  overflow-y: auto;
  padding: 7px;
  border: 1px solid rgba(0, 179, 255, .35);
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 18px 45px rgba(6, 26, 38, .18);
}

.coach-athlete-search-option {
  width: 100%;
  border: 0;
  border-radius: 12px;
  background: transparent;
  display: grid;
  gap: 2px;
  padding: 9px 10px;
  text-align: left;
  cursor: pointer;
}

.coach-athlete-search-option span {
  color: var(--ink);
  font-weight: 950;
}

.coach-athlete-search-option small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.coach-athlete-search-option:hover,
.coach-athlete-search-option.is-selected {
  background: rgba(0, 179, 255, .10);
}

.coach-athlete-search-empty {
  padding: 11px 10px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
}

@media (max-width: 900px) {
  .coach-athlete-quick-search {
    width: 100%;
    min-width: 0;
    flex-basis: 100%;
    order: 2;
    margin-left: 0;
  }

  .coach-dashboard-actions {
    order: 3;
  }
}



/* v164 app feature page */
.athlete-feature-actions {
  justify-content: flex-end;
}

.feature-page {
  display: grid;
  gap: 18px;
}

.feature-heading {
  align-items: flex-start;
}

.feature-new-highlight {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 18px;
  align-items: start;
  border-color: rgba(0, 179, 255, .45);
  background: linear-gradient(135deg, rgba(0,179,255,.12), #ffffff 44%, #ffffff);
  box-shadow: 0 16px 42px rgba(6, 26, 38, .12);
}

.feature-new-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 11px;
  border-radius: 999px;
  background: #06131d;
  color: var(--blue);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .08em;
  text-transform: uppercase;
  white-space: nowrap;
}

.feature-new-highlight h2,
.feature-intro h2,
.feature-section h2 {
  margin: 0 0 8px;
  color: var(--blue);
  font-weight: 950;
}

.feature-new-highlight p,
.feature-intro p,
.feature-section p {
  margin: 0 0 10px;
  color: var(--ink);
}

.feature-quick-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin: 12px 0;
}

.feature-quick-grid span {
  border: 1px solid rgba(0, 179, 255, .25);
  border-radius: 999px;
  background: #f7fbff;
  color: var(--ink);
  padding: 6px 9px;
  font-size: 12px;
  font-weight: 850;
}

.feature-device-tip {
  color: var(--muted) !important;
  font-size: 13px;
}

.feature-intro {
  display: grid;
  gap: 14px;
}

.feature-promise {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  background: #06131d;
  border-radius: 14px;
  padding: 10px;
}

.feature-promise span {
  color: #ffffff;
  text-align: center;
  font-weight: 950;
}

.feature-section-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.feature-section {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #ffffff;
  padding: 16px;
  box-shadow: 0 12px 32px rgba(6, 26, 38, .06);
}

.feature-section ul {
  margin: 0;
  padding-left: 20px;
}

.feature-section li {
  margin: 6px 0;
  color: var(--ink);
}

.feature-share-modal {
  max-width: 760px;
}

.feature-share-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0;
}

.feature-athlete-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  max-height: 320px;
  overflow: auto;
  padding: 4px;
}

.feature-athlete-option {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fbfcfa;
  padding: 10px;
  cursor: pointer;
}

.feature-athlete-option input {
  width: 18px;
  height: 18px;
  accent-color: var(--blue);
}

.feature-athlete-option span {
  display: grid;
  gap: 2px;
}

.feature-athlete-option strong {
  color: var(--ink);
  font-weight: 950;
}

.feature-athlete-option small {
  color: var(--muted);
  font-weight: 800;
}

.feature-share-links {
  margin-top: 10px;
}

.feature-share-ready {
  display: grid;
  gap: 8px;
  border: 1px solid rgba(0, 179, 255, .25);
  border-radius: 16px;
  background: rgba(0, 179, 255, .06);
  padding: 12px;
}

@media (max-width: 760px) {
  .feature-new-highlight,
  .feature-section-grid,
  .feature-promise,
  .feature-athlete-list {
    grid-template-columns: 1fr;
  }

  .feature-new-highlight {
    gap: 12px;
  }
}



/* v165 feature WhatsApp app-open buttons */
.feature-whatsapp-app-link {
  width: 100%;
  text-align: center;
  font: inherit;
  cursor: pointer;
}



/* v168 sport-specific workout builder */
.gym-builder {
  display: grid;
  gap: 14px;
}

.gym-workout-mode .warmup-picker-field,
.gym-workout-mode .form-row.hidden {
  display: none !important;
}

.gym-builder .metric-control {
  border-color: rgba(0, 179, 255, .28);
  background: rgba(0, 179, 255, .06);
}



/* v169 emergency restore: keep v166 dashboard/icon button sizing */
.coach-action-icon-bar .dashboard-action-btn {
  overflow: hidden;
}

.coach-action-icon-bar .dashboard-action-svg svg {
  max-width: 100%;
  max-height: 100%;
}



/* v170-clean Add Sport dropdown colours and sport workout cards */
.athlete-add-sport-dropdown {
  position: fixed;
  z-index: 9999;
  min-width: 220px;
  border: 1px solid rgba(6, 26, 38, .12);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 18px 48px rgba(6, 26, 38, .18);
  padding: 8px;
}

.athlete-add-sport-title {
  padding: 8px 10px 6px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.athlete-add-sport-dropdown button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  justify-content: flex-start;
  border: 0;
  border-radius: 12px;
  background: var(--sport-color);
  color: var(--sport-text);
  padding: 10px 11px;
  font-weight: 950;
  cursor: pointer;
  margin: 4px 0;
  box-shadow: inset 0 -10px 20px rgba(0,0,0,.08);
}

.athlete-add-sport-dropdown button:hover,
.athlete-add-sport-dropdown button:focus {
  transform: translateY(-1px);
  outline: 2px solid rgba(6,26,38,.18);
}

.sport-colour-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: currentColor;
  border: 2px solid rgba(255,255,255,.65);
}

.session-chip.unplanned-run {
  border: 2px solid #FF5C00 !important;
}

.session-chip.unplanned-run[style*="--sport-color"] {
  box-shadow: inset 5px 0 0 var(--sport-color), 0 4px 12px rgba(6,26,38,.08);
}

.sport-box,
.fit-upload-card.sport-box,
.unplanned-title-card.sport-box {
  border: 2px solid #FF5C00 !important;
  box-shadow: inset 5px 0 0 var(--sport-color), 0 8px 18px rgba(6,26,38,.06);
}

.gym-body-field {
  margin-top: 12px;
}



/* v172 orange border scope: only athlete-created unplanned workouts */
.session-chip.completed:not(.unplanned-run),
.session-chip.easy:not(.unplanned-run),
.session-chip.quality:not(.unplanned-run),
.session-chip.race:not(.unplanned-run),
.race-chip {
  border-color: var(--line) !important;
}

.session-chip:not(.unplanned-run) {
  box-shadow: 0 4px 12px rgba(6,26,38,.08);
}



/* v174 swim target fix and unplanned sport chip colours */
.session-chip.unplanned-run {
  background: var(--sport-color) !important;
  color: var(--sport-text) !important;
  border: 2px solid #FF5C00 !important;
  text-decoration: none !important;
  text-shadow: none !important;
  box-shadow: inset 5px 0 0 rgba(255,255,255,.30), 0 4px 12px rgba(6,26,38,.12) !important;
}

.session-chip.unplanned-run.completed {
  background: var(--sport-color) !important;
  color: var(--sport-text) !important;
  border-color: #FF5C00 !important;
  box-shadow: inset 5px 0 0 rgba(255,255,255,.30), 0 4px 12px rgba(6,26,38,.12) !important;
}

.session-chip.unplanned-run .session-chip-type,
.session-chip.unplanned-run .session-chip-name {
  color: var(--sport-text) !important;
}

.session-chip.unplanned-run.sport-swim,
.session-chip.unplanned-run.sport-run {
  text-shadow: none !important;
}

.session-chip:not(.unplanned-run).completed {
  background: #058731;
  color: #c9f2cc;
  border-color: #39ff14;
}


/* v178 coach search cleanup + athlete dashboard icon-only buttons */
.coach-athlete-search-results[hidden] {
  display: none !important;
}

.athlete-dashboard-button-row .athlete-icon-label {
  display: none !important;
}

.athlete-dashboard-button-row .athlete-icon-tile-btn {
  min-height: 58px;
  padding: 8px;
  gap: 0;
  justify-content: center;
}



/* v179 Add Sport tight crop and shared tile sizing */
#athlete-add-sport .add-sport-main-img {
  width: 27px !important;
  height: 27px !important;
  max-width: 27px !important;
  max-height: 27px !important;
  object-fit: contain !important;
  display: block !important;
  margin: 0 auto !important;
}



/* v181 default running shoe */
.shoe-title-line {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.shoe-default-badge {
  display: inline-flex !important;
  width: auto;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(0, 179, 255, .14);
  color: var(--blue) !important;
  font-size: 10px !important;
  font-weight: 950;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.shoe-row.default-shoe {
  border-color: rgba(0, 179, 255, .48);
  box-shadow: inset 4px 0 0 var(--blue);
}

.default-shoe-help {
  display: block;
  margin: -5px 0 12px;
  color: var(--muted);
  font-size: 12px;
}



/* v182 future-completion protection and sport-colour completion lock */
.future-completion-note {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 9px 12px;
  border: 1px solid rgba(0, 179, 255, .28);
  border-radius: 12px;
  background: rgba(0, 179, 255, .08);
  color: var(--navy);
  font-size: 12px;
  font-weight: 850;
}

.unplanned-date-mode-message {
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px solid rgba(5, 135, 49, .22);
  border-radius: 12px;
  background: rgba(5, 135, 49, .07);
  color: #155d2d;
  font-size: 12px;
  font-weight: 800;
}

.unplanned-date-mode-message.upcoming {
  border-color: rgba(0, 179, 255, .30);
  background: rgba(0, 179, 255, .08);
  color: var(--navy);
}

#unplanned-completion-fields[hidden] {
  display: none !important;
}

.calendar .session-chip.sport-colour-lock,
.calendar .session-chip.sport-colour-lock.completed {
  background: var(--sport-color) !important;
  color: var(--sport-text) !important;
  text-decoration: none !important;
  text-shadow: none !important;
}

.calendar .session-chip.sport-colour-lock .session-chip-type,
.calendar .session-chip.sport-colour-lock .session-chip-name,
.calendar .session-chip.sport-colour-lock.completed .session-chip-type,
.calendar .session-chip.sport-colour-lock.completed .session-chip-name {
  color: var(--sport-text) !important;
}

.calendar .session-chip.sport-colour-lock.unplanned-run,
.calendar .session-chip.sport-colour-lock.unplanned-run.completed {
  border: 2px solid #FF5C00 !important;
  box-shadow: inset 5px 0 0 rgba(255,255,255,.30), 0 4px 12px rgba(6,26,38,.12) !important;
}

.calendar .session-chip.sport-colour-lock:not(.unplanned-run),
.calendar .session-chip.sport-colour-lock.completed:not(.unplanned-run) {
  border-color: var(--line) !important;
  box-shadow: 0 4px 12px rgba(6,26,38,.08) !important;
}



/* v183 same-day Unplanned Run date lock */
#unplanned-date:disabled {
  opacity: 1;
  color: var(--navy);
  background: rgba(0, 179, 255, .08);
  border-color: rgba(0, 179, 255, .32);
  cursor: not-allowed;
}



/* v187 coach workout ranges and FIT workout import */
.simple-distance-range {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid rgba(0, 179, 255, .24);
  border-radius: 14px;
  background: rgba(0, 179, 255, .055);
}

.simple-distance-range.hidden,
.simple-range-fields.hidden {
  display: none !important;
}

.simple-range-toggle {
  margin-bottom: 10px;
}

.simple-range-fields {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: end;
  gap: 10px;
}

.range-divider {
  padding-bottom: 12px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.range-km-input {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.range-km-input span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.metric-control input:disabled,
.metric-control select:disabled {
  opacity: .52;
  cursor: not-allowed;
  background: #eef2f3;
}

.fit-workout-import-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin: 12px 0 16px;
  padding: 14px;
  border: 1px solid rgba(0, 179, 255, .28);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(0,179,255,.07), rgba(255,255,255,.92));
}

.fit-workout-import-card h3 {
  margin: 3px 0 5px;
  color: var(--navy);
  font-size: 18px;
}

.fit-workout-import-card p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.45;
}

.fit-workout-import-button {
  white-space: nowrap;
  cursor: pointer;
}

.fit-workout-import-status {
  grid-column: 1 / -1;
  padding-top: 2px;
}

@media (max-width: 640px) {
  .simple-range-fields {
    grid-template-columns: minmax(0, 1fr) 22px minmax(0, 1fr);
    gap: 6px;
  }

  .fit-workout-import-card {
    grid-template-columns: 1fr;
  }

  .fit-workout-import-button {
    width: 100%;
    text-align: center;
  }
}



/* v188 FIT workout importer binding fix */
.workout-builder.fit-import-flash {
  animation: fit-import-flash-v188 1.35s ease;
}

@keyframes fit-import-flash-v188 {
  0% {
    box-shadow: 0 0 0 0 rgba(0, 179, 255, .5);
  }
  35% {
    box-shadow: 0 0 0 5px rgba(0, 179, 255, .22);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(0, 179, 255, 0);
  }
}



/* v189 full-width desktop calendars and athlete side-panel collapse */
.athlete-calendar-head-actions {
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:10px;
  min-width:0;
}

.athlete-sidebar-hide,
.athlete-sidebar-show {
  min-height:34px;
  padding:8px 12px;
  font-size:11px;
  line-height:1;
  white-space:nowrap;
}

.athlete-calendar-card,
.athlete-calendar-sidebar {
  min-width:0;
}

.athlete-calendar-grid.athlete-sidebar-collapsed {
  grid-template-columns:minmax(0,1fr);
}

.athlete-calendar-grid.athlete-sidebar-collapsed .athlete-calendar-sidebar {
  display:none;
}

.athlete-calendar-grid.athlete-sidebar-collapsed .calendar {
  overflow-x:visible;
}

@media (min-width: 901px) {
  .main.calendar-main {
    width:calc(100% - 28px);
    max-width:none;
    margin-left:auto;
    margin-right:auto;
  }

  .athlete-calendar-grid.athlete-sidebar-collapsed .day,
  .coach-athlete-grid.snapshot-collapsed .day {
    min-height:112px;
  }
}

@media (max-width: 900px) {
  .athlete-sidebar-hide,
  .athlete-sidebar-show {
    display:none !important;
  }

  .athlete-calendar-grid.athlete-sidebar-collapsed {
    grid-template-columns:1fr;
  }

  .athlete-calendar-grid.athlete-sidebar-collapsed .athlete-calendar-sidebar {
    display:block;
  }
}



/* v190 separate athlete and coach login portals */
.login-portal-switch {
  display:block;
  width:100%;
  margin:18px 0 0;
  padding:10px 8px 2px;
  border:0;
  background:transparent;
  color:var(--blue);
  font-size:12px;
  font-weight:900;
  text-align:center;
  text-decoration:underline;
  text-underline-offset:3px;
  cursor:pointer;
}

.login-portal-switch:hover,
.login-portal-switch:focus {
  color:var(--navy);
}

.coach-login-shell .login-note {
  color:#b9f1ff;
}

.coach-login-shell .login-hero .eyebrow {
  color:#65ddff;
}

.coach-login-shell .hero-copy h1 span {
  color:#00bfff;
}

@media (max-width: 620px) {
  .login-portal-switch {
    min-height:44px;
    padding-top:14px;
  }
}



/* v191 athlete mobile greeting and fullscreen calendar */
.athlete-mobile-greeting {
  display:none;
}

.athlete-calendar-fullscreen-trigger {
  display:none;
}

@media (max-width: 900px) {
  .athlete-dashboard-topbar {
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:12px;
  }

  .athlete-dashboard-topbar .brand-banner {
    flex:0 0 auto;
    max-width:none;
  }

  .athlete-dashboard-topbar .brand-banner-inner {
    display:none;
  }

  .athlete-dashboard-topbar .mobile-brand {
    display:block;
    width:52px;
    height:52px;
    flex:0 0 auto;
    border:1px solid rgba(0,191,255,.42);
    box-shadow:0 0 12px rgba(0,191,255,.28);
  }

  .athlete-dashboard-topbar .user-chip > div:not(.avatar) {
    display:none;
  }

  .athlete-mobile-greeting {
    display:flex;
    min-width:0;
    flex-direction:column;
    justify-content:center;
    line-height:1.05;
  }

  .athlete-mobile-greeting > span {
    color:#65ddff;
    font-size:9px;
    font-weight:950;
    letter-spacing:.13em;
    text-transform:uppercase;
  }

  .athlete-mobile-greeting strong {
    margin-top:3px;
    color:#fff;
    font-family:Oswald,sans-serif;
    font-size:clamp(20px,3.4vw,28px);
    line-height:1;
    text-transform:uppercase;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }

  .athlete-mobile-greeting small {
    margin-top:4px;
    color:#b8ceda;
    font-size:11px;
    white-space:nowrap;
    overflow:hidden;
    text-overflow:ellipsis;
  }

  .athlete-dashboard-intro > .eyebrow,
  .athlete-dashboard-intro > h1,
  .athlete-dashboard-intro > .subtle {
    display:none;
  }

  .athlete-dashboard-intro {
    width:100%;
  }

  .athlete-dashboard-intro .coach-assignment-line {
    margin-top:0;
  }
}

@media (max-width: 620px) {
  .athlete-dashboard-topbar {
    min-height:76px;
    padding:8px 10px;
    gap:8px;
  }

  .athlete-dashboard-topbar .mobile-brand,
  .athlete-dashboard-topbar .brand-compact {
    width:42px;
    height:42px;
  }

  .athlete-dashboard-topbar .top-actions {
    gap:7px;
  }

  .athlete-dashboard-topbar .top-action-stack {
    gap:2px;
  }

  .athlete-dashboard-topbar .logout {
    min-height:30px;
    padding:0 2px;
    font-size:13px;
  }

  .athlete-dashboard-topbar .top-data-actions button {
    padding:3px 7px;
    font-size:9px;
  }

  .athlete-mobile-greeting > span {
    font-size:7px;
  }

  .athlete-mobile-greeting strong {
    font-size:clamp(17px,5.6vw,23px);
  }

  .athlete-mobile-greeting small {
    font-size:9px;
  }

  .athlete-calendar-card .card-head {
    gap:10px;
  }

  .athlete-calendar-head-actions {
    width:100%;
    display:flex;
    align-items:stretch;
    gap:9px;
  }

  .athlete-calendar-card .month-nav {
    width:auto;
    flex:0 0 auto;
    justify-content:flex-start;
    gap:8px;
  }

  .athlete-calendar-fullscreen-trigger {
    display:flex;
    min-width:0;
    flex:1 1 auto;
    align-items:center;
    justify-content:center;
    gap:8px;
    min-height:44px;
    padding:8px 12px;
    border:2px solid rgba(0,179,255,.42);
    border-radius:12px;
    background:rgba(0,179,255,.08);
    color:var(--blue);
    font-size:12px;
    cursor:pointer;
  }

  .athlete-calendar-fullscreen-trigger span {
    font-size:20px;
    line-height:1;
  }

  .athlete-calendar-fullscreen-trigger strong {
    overflow:hidden;
    text-overflow:ellipsis;
    white-space:nowrap;
  }

  body.athlete-calendar-fullscreen-active {
    overflow:hidden !important;
    overscroll-behavior:none;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen {
    position:fixed;
    inset:0;
    z-index:3000;
    width:100vw;
    max-width:none;
    height:100dvh;
    max-height:100dvh;
    margin:0;
    display:flex;
    flex-direction:column;
    border:0;
    border-radius:0;
    background:#fff;
    overflow:hidden;
    box-shadow:none;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .card-head {
    position:sticky;
    top:0;
    z-index:4;
    flex:0 0 auto;
    padding:max(12px,env(safe-area-inset-top)) 12px 10px;
    border-radius:0;
    background:#fff;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .calendar {
    flex:1 1 auto;
    min-height:0;
    max-height:none;
    padding:10px 8px max(12px,env(safe-area-inset-bottom));
    overflow-y:auto !important;
    overflow-x:hidden !important;
    overscroll-behavior:contain;
    -webkit-overflow-scrolling:touch;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .calendar-mobile-landscape-hint {
    margin-bottom:6px;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .day {
    min-height:clamp(76px,12.2dvh,108px);
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .athlete-calendar-fullscreen-trigger {
    border-color:#f05a28;
    background:#fff3ee;
    color:#b83d18;
  }
}

@media (max-width: 390px) {
  .athlete-dashboard-topbar {
    grid-template-columns:40px minmax(0,1fr) auto;
    gap:6px;
  }

  .athlete-mobile-greeting > span,
  .athlete-mobile-greeting small {
    display:none;
  }

  .athlete-mobile-greeting strong {
    font-size:18px;
  }

  .athlete-calendar-fullscreen-trigger {
    padding-left:8px;
    padding-right:8px;
    font-size:10px;
  }
}



/* v192 athlete-only feature guide and effort chart navigation */
.feature-coach-divider {
  padding:18px;
  border-color:rgba(255,92,0,.3);
  background:linear-gradient(135deg,rgba(255,92,0,.08),#fff 48%);
}

.feature-coach-divider h2 {
  margin:3px 0 6px;
  color:var(--navy);
  font-family:Oswald,sans-serif;
  text-transform:uppercase;
}

.feature-coach-divider p {
  margin:0;
  color:var(--muted);
}

.coach-feature-grid {
  margin-top:-4px;
}

.coach-only-feature {
  border-color:rgba(255,92,0,.24);
}

.coach-only-feature h2 {
  color:#c94b1e;
}

#athlete-report-effort-chart {
  scroll-margin-top:18px;
}



/* v193 calendar stats, rotation-safe fullscreen and coach top-bar titles */
.calendar-title-distance {
  display:flex;
  align-items:center;
  gap:18px;
  min-width:0;
}

.calendar-title-distance h2 {
  flex:0 1 auto;
}

.calendar-week-distance {
  display:flex;
  align-items:baseline;
  gap:7px;
  min-width:0;
  padding:6px 10px;
  border:1px solid rgba(0,179,255,.24);
  border-radius:11px;
  background:rgba(0,179,255,.055);
}

.calendar-week-distance > span {
  color:var(--muted);
  font-size:9px;
  font-weight:950;
  letter-spacing:.08em;
  text-transform:uppercase;
  white-space:nowrap;
}

.calendar-week-distance .weekly-distance-value {
  white-space:nowrap;
}

.calendar-week-distance .weekly-distance-current,
.calendar-week-distance .weekly-distance-planned {
  font-family:Oswald,sans-serif;
  font-size:20px;
}

.calendar-week-distance .weekly-distance-value small {
  font-size:10px;
}

.athlete-sidebar-stats-card {
  padding:0;
  overflow:hidden;
}

.athlete-sidebar-stats {
  display:grid;
  grid-template-columns:1fr 1fr;
}

.athlete-sidebar-stats > div {
  min-width:0;
  padding:18px 14px;
  text-align:center;
}

.athlete-sidebar-stats > div + div {
  border-left:1px solid var(--line);
}

.athlete-sidebar-stats strong,
.athlete-sidebar-stats span {
  display:block;
}

.athlete-sidebar-stats strong {
  color:var(--navy);
  font-family:Oswald,sans-serif;
  font-size:32px;
  line-height:1;
}

.athlete-sidebar-stats span {
  margin-top:5px;
  color:var(--muted);
  font-size:10px;
  font-weight:850;
  text-transform:uppercase;
}

.coach-athlete-stats {
  grid-template-columns:repeat(2,minmax(0,1fr));
}

.coach-calendar-fullscreen-trigger {
  display:flex;
  min-height:36px;
  align-items:center;
  justify-content:center;
  gap:7px;
  padding:7px 11px;
  border:1px solid rgba(0,179,255,.34);
  border-radius:10px;
  background:rgba(0,179,255,.07);
  color:var(--blue);
  font-size:11px;
  font-weight:900;
  cursor:pointer;
}

.coach-calendar-fullscreen-trigger span {
  font-size:18px;
  line-height:1;
}

/* Fullscreen styling is intentionally outside width media queries.
   This keeps it active after portrait/landscape rotation changes viewport width. */
body.athlete-calendar-fullscreen-active,
body.coach-calendar-fullscreen-active {
  overflow:hidden !important;
  overscroll-behavior:none;
}

.athlete-calendar-card.athlete-mobile-fullscreen,
.coach-athlete-calendar-card.coach-calendar-fullscreen {
  position:fixed !important;
  inset:0 !important;
  z-index:3000 !important;
  width:100vw !important;
  max-width:none !important;
  height:100dvh !important;
  max-height:100dvh !important;
  margin:0 !important;
  display:flex !important;
  flex-direction:column !important;
  border:0 !important;
  border-radius:0 !important;
  background:#fff !important;
  overflow:hidden !important;
  box-shadow:none !important;
}

.athlete-calendar-card.athlete-mobile-fullscreen .card-head,
.coach-athlete-calendar-card.coach-calendar-fullscreen .card-head {
  position:sticky;
  top:0;
  z-index:4;
  flex:0 0 auto;
  padding:max(12px,env(safe-area-inset-top)) 12px 10px;
  border-radius:0;
  background:#fff;
}

.athlete-calendar-card.athlete-mobile-fullscreen .calendar,
.coach-athlete-calendar-card.coach-calendar-fullscreen .calendar {
  flex:1 1 auto;
  min-height:0;
  max-height:none;
  padding:10px 8px max(12px,env(safe-area-inset-bottom));
  overflow:auto !important;
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
}

.athlete-calendar-card.athlete-mobile-fullscreen .athlete-calendar-fullscreen-trigger,
.coach-athlete-calendar-card.coach-calendar-fullscreen .coach-calendar-fullscreen-trigger {
  display:flex !important;
  border-color:#f05a28;
  background:#fff3ee;
  color:#b83d18;
}

.coach-topbar-page-title {
  min-width:0;
  flex:1 1 auto;
  padding:0 14px;
  text-align:center;
}

.coach-topbar-page-title span,
.coach-topbar-page-title strong {
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.coach-topbar-page-title span {
  color:#65ddff;
  font-size:9px;
  font-weight:950;
  letter-spacing:.13em;
  text-transform:uppercase;
}

.coach-topbar-page-title strong {
  margin-top:3px;
  color:#fff;
  font-family:Oswald,sans-serif;
  font-size:clamp(22px,2.3vw,34px);
  line-height:1;
  text-transform:uppercase;
}

.coach-page-topbar + .main > .welcome h1 {
  display:none;
}

.coach-page-topbar + .main > .welcome {
  margin-top:4px;
}

@media (min-width: 901px) {
  .coach-page-topbar .brand-banner {
    flex:0 1 38%;
  }

  .coach-page-topbar .top-actions {
    flex:0 0 auto;
  }
}

@media (max-width: 900px) {
  .coach-page-topbar {
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:10px;
  }

  .coach-page-topbar .brand-banner {
    flex:0 0 auto;
    max-width:none;
  }

  .coach-page-topbar .brand-banner-inner {
    display:none;
  }

  .coach-page-topbar .mobile-brand {
    display:block;
    width:48px;
    height:48px;
  }

  .coach-page-topbar .user-chip > div:not(.avatar) {
    display:none;
  }

  .coach-topbar-page-title {
    padding:0 4px;
  }

  .coach-topbar-page-title strong {
    font-size:clamp(18px,4vw,27px);
  }

  .coach-topbar-page-title span {
    font-size:8px;
  }

  .athlete-calendar-fullscreen-trigger {
    display:flex;
  }
}

@media (max-width: 620px) {
  .calendar-title-distance {
    width:100%;
    justify-content:space-between;
    gap:8px;
  }

  .calendar-title-distance h2 {
    font-size:21px;
  }

  .calendar-week-distance {
    gap:5px;
    padding:5px 8px;
  }

  .calendar-week-distance > span {
    font-size:8px;
  }

  .calendar-week-distance .weekly-distance-current,
  .calendar-week-distance .weekly-distance-planned {
    font-size:18px;
  }

  .athlete-calendar-sidebar {
    display:flex;
    flex-direction:column;
  }

  .athlete-sidebar-stats-card {
    order:-1;
    margin:12px 0 0;
  }

  .coach-calendar-head-actions {
    width:100%;
    flex-wrap:wrap;
  }

  .coach-calendar-fullscreen-trigger {
    flex:1 1 140px;
    min-height:44px;
  }

  .coach-page-topbar {
    min-height:76px;
    padding:8px 10px;
    gap:7px;
  }

  .coach-page-topbar .mobile-brand,
  .coach-page-topbar .brand-compact {
    width:40px;
    height:40px;
  }

  .coach-topbar-page-title strong {
    font-size:17px;
  }

  .coach-topbar-page-title span {
    display:none;
  }
}

@media (orientation:landscape) {
  .athlete-calendar-card.athlete-mobile-fullscreen .calendar,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .calendar {
    padding-top:7px;
  }

  .athlete-calendar-card.athlete-mobile-fullscreen .day,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .day {
    min-height:78px;
  }
}



/* v194 coach settings, athlete header cleanup and athlete top-bar titles */
.top-settings-menu {
  position:relative;
}

.top-settings-toggle {
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  padding:0;
  border:1px solid rgba(0,191,255,.48);
  border-radius:12px;
  background:rgba(0,191,255,.10);
  color:#e7f8ff;
  cursor:pointer;
}

.top-settings-toggle:hover,
.top-settings-toggle:focus,
.top-settings-toggle[aria-expanded="true"] {
  color:#fff;
  border-color:#00bfff;
  background:rgba(0,191,255,.22);
}

.top-settings-toggle .dashboard-action-svg,
.top-settings-toggle svg {
  width:21px;
  height:21px;
}

.top-settings-toggle .top-settings-gear {
  fill:#fff;
}

.top-settings-dropdown {
  position:absolute;
  top:calc(100% + 8px);
  right:0;
  z-index:3200;
  width:180px;
  padding:7px;
  border:1px solid rgba(0,191,255,.28);
  border-radius:13px;
  background:#071925;
  box-shadow:0 14px 34px rgba(0,0,0,.32);
}

.top-settings-dropdown[hidden] {
  display:none !important;
}

.top-settings-dropdown button,
.top-settings-dropdown a {
  width:100%;
  min-height:38px;
  display:flex;
  align-items:center;
  padding:8px 11px;
  border:0;
  border-radius:9px;
  background:transparent;
  color:#dcecf3;
  font-size:12px;
  font-weight:850;
  text-align:left;
  text-decoration:none;
  cursor:pointer;
}

.top-settings-dropdown button:hover,
.top-settings-dropdown button:focus,
.top-settings-dropdown a:hover,
.top-settings-dropdown a:focus {
  background:rgba(0,191,255,.16);
  color:#fff;
}

.calendar-week-distance {
  padding-left:12px;
  padding-right:12px;
}

.athlete-demographics-inline {
  display:flex;
  align-items:center;
  gap:10px;
  flex:0 0 auto;
}

.athlete-demographics-inline > div {
  min-width:120px;
  padding:9px 11px;
  border:1px solid var(--line);
  border-radius:12px;
  background:#fff;
}

.athlete-demographics-inline span,
.athlete-demographics-inline strong {
  display:block;
}

.athlete-demographics-inline span {
  color:var(--muted);
  font-size:8px;
  font-weight:900;
  letter-spacing:.06em;
  text-transform:uppercase;
}

.athlete-demographics-inline strong {
  margin-top:3px;
  color:var(--navy);
  font-size:12px;
  white-space:nowrap;
}

.coach-athlete-mobile-stats {
  display:none;
  margin-top:14px;
}

.coach-athlete-sidebar-stats {
  overflow:hidden;
}

.topbar-page-title {
  min-width:0;
  flex:1 1 auto;
  padding:0 14px;
  text-align:center;
}

.topbar-page-title span,
.topbar-page-title strong {
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.topbar-page-title span {
  color:#65ddff;
  font-size:9px;
  font-weight:950;
  letter-spacing:.13em;
  text-transform:uppercase;
}

.topbar-page-title strong {
  margin-top:3px;
  color:#fff;
  font-family:Oswald,sans-serif;
  font-size:clamp(22px,2.3vw,34px);
  line-height:1;
  text-transform:uppercase;
}

.athlete-page-topbar + .main > .athlete-screen-head h1,
.athlete-page-topbar + .main > .welcome h1,
.athlete-page-topbar + .main.feature-page > .feature-heading h1 {
  display:none;
}

@media (min-width:901px) {
  .page-title-topbar .brand-banner {
    flex:0 1 38%;
  }

  .page-title-topbar .top-actions {
    flex:0 0 auto;
  }
}

@media (max-width:900px) {
  .coach-page-topbar,
  .athlete-page-topbar {
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:10px;
  }

  .page-title-topbar .brand-banner {
    flex:0 0 auto;
    max-width:none;
  }

  .page-title-topbar .brand-banner-inner {
    display:none;
  }

  .page-title-topbar .mobile-brand {
    display:block;
    width:48px;
    height:48px;
  }

  .page-title-topbar .user-chip > div:not(.avatar) {
    display:none;
  }

  .topbar-page-title {
    padding:0 4px;
  }

  .topbar-page-title strong {
    font-size:clamp(18px,4vw,27px);
  }

  .topbar-page-title span {
    font-size:8px;
  }

  .athlete-demographics-inline {
    display:none;
  }

  .coach-athlete-mobile-stats {
    display:block;
  }

  .coach-athlete-sidebar-stats {
    display:none;
  }
}

@media (max-width:620px) {
  .page-title-topbar {
    min-height:76px;
    padding:8px 10px;
    gap:7px;
  }

  .page-title-topbar .mobile-brand,
  .page-title-topbar .brand-compact {
    width:40px;
    height:40px;
  }

  .topbar-page-title strong {
    font-size:17px;
  }

  .topbar-page-title span {
    display:none;
  }

  .top-settings-toggle {
    width:36px;
    height:36px;
  }

  .top-settings-dropdown {
    position:fixed;
    top:70px;
    right:10px;
    width:min(220px,calc(100vw - 20px));
  }

  .coach-athlete-mobile-stats {
    margin-top:12px;
  }
}



/* v195 athlete profile modal, desktop athlete fullscreen and mobile cleanup */
.athlete-list-only-card {
  overflow:hidden;
}

.athlete-profile-modal {
  width:min(720px,100%);
}

.athlete-profile-modal .modal-body {
  padding:20px 24px 24px;
}

.athlete-profile-modal-form {
  padding:0;
}

.athlete-profile-modal-form .modal-actions {
  margin-top:18px;
}

.athlete-title-row {
  align-items:center;
}

.athlete-dashboard-topbar .athlete-topbar-page-title {
  display:block;
}

.athlete-dashboard-intro > .eyebrow,
.athlete-dashboard-intro > h1,
.athlete-dashboard-intro > .subtle {
  display:none !important;
}

@media (min-width:901px) {
  .athlete-calendar-fullscreen-trigger {
    display:flex;
    min-height:36px;
    align-items:center;
    justify-content:center;
    gap:7px;
    padding:7px 11px;
    border:1px solid rgba(0,179,255,.34);
    border-radius:10px;
    background:rgba(0,179,255,.07);
    color:var(--blue);
    font-size:11px;
    font-weight:900;
    cursor:pointer;
  }

  .athlete-calendar-fullscreen-trigger span {
    font-size:18px;
    line-height:1;
  }
}

@media (max-width:900px) {
  .athlete-dashboard-topbar .athlete-topbar-page-title {
    display:none;
  }

  .coach-athlete-calendar-card .month-nav {
    display:none !important;
  }

  .athlete-page-topbar + .main > .athlete-screen-head > div > .eyebrow,
  .athlete-page-topbar + .main > .athlete-screen-head > div > h1,
  .athlete-page-topbar + .main > .athlete-screen-head > div > .subtle,
  .athlete-page-topbar + .main > .welcome > div > .eyebrow,
  .athlete-page-topbar + .main > .welcome > div > h1,
  .athlete-page-topbar + .main > .welcome > div > .subtle {
    display:none !important;
  }

  .athlete-page-topbar + .main .athlete-page-menu-card > .card-head {
    display:none;
  }

  .athlete-page-topbar + .main .athlete-page-menu-card {
    padding-top:0;
  }

  .athlete-page-topbar + .main .athlete-page-button-row {
    border-top:0;
  }
}

@media (max-width:620px) {
  .athlete-profile-backdrop {
    padding:8px;
  }

  .athlete-profile-modal {
    max-height:96dvh;
    border-radius:16px;
  }

  .athlete-profile-modal .modal-top {
    padding:18px 18px 15px;
  }

  .athlete-profile-modal .modal-body {
    padding:16px;
  }
}



/* v196 unplanned-run approval and intuitive reports */
.calendar-context-menu .approve-run {
  color:#076b2d;
  background:#e5f7ec;
  font-weight:950;
}
.calendar .session-chip.coach-approved-run,
.calendar .session-chip.coach-approved-run.completed,
.calendar .session-chip.unplanned-run.coach-approved-run.completed {
  background:#058731 !important;
  color:#c9f2cc !important;
  border-color:#39ff14 !important;
  box-shadow:0 4px 12px rgba(5,135,49,.22) !important;
}
.calendar .session-chip.coach-approved-run .session-chip-type,
.calendar .session-chip.coach-approved-run .session-chip-name {
  color:#c9f2cc !important;
}
.report-data-point,
.report-data-bar {
  cursor:pointer;
}
.report-data-point {
  fill:#fff;
  stroke:#00aeea;
  stroke-width:2.5;
  transition:r .15s,fill .15s,stroke-width .15s;
}
.report-data-point:hover,
.report-data-point:focus {
  r:6;
  fill:#00bfff;
  stroke-width:3;
  outline:none;
}
.report-data-bar:hover,
.report-data-bar:focus {
  background:rgba(0,179,255,.07);
  border-radius:8px;
  outline:none;
}
.report-graph-tooltip {
  position:fixed;
  z-index:5000;
  max-width:min(320px,calc(100vw - 16px));
  padding:9px 11px;
  border:1px solid rgba(0,191,255,.35);
  border-radius:10px;
  background:#071925;
  color:#f3fbff;
  box-shadow:0 10px 28px rgba(0,0,0,.28);
  font-size:11px;
  font-weight:800;
  line-height:1.35;
  pointer-events:none;
}
.athlete-benchmark-workspace,
.coach-benchmark-workspace {
  display:grid;
  grid-template-columns:minmax(300px,.85fr) minmax(0,1.6fr);
  gap:22px;
  align-items:start;
  margin-top:22px;
}
.coach-benchmark-tables {
  min-width:0;
}
.coach-benchmark-tables > .card:first-child,
.athlete-report-benchmarks {
  margin-top:0 !important;
}
#athlete-report-benchmark-graph,
#coach-report-benchmark-graph {
  scroll-margin-top:18px;
  position:sticky;
  top:12px;
}
.interactive-report-chart small {
  display:block;
  margin-top:8px;
}
@media (max-width:900px) {
  .athlete-benchmark-workspace,
  .coach-benchmark-workspace {
    grid-template-columns:1fr;
  }
  #athlete-report-benchmark-graph,
  #coach-report-benchmark-graph {
    position:static;
  }
}



/* v197 definitive report renderer fix */
.athlete-mileage-graph-grid > #athlete-report-weekly-mileage,
.athlete-mileage-graph-grid > #athlete-report-monthly-mileage {
  min-width:0;
}

.athlete-benchmark-workspace,
.coach-benchmark-workspace {
  display:grid !important;
  grid-template-columns:minmax(310px,.9fr) minmax(0,1.65fr) !important;
  gap:22px !important;
  align-items:start !important;
  margin-top:22px !important;
}

.athlete-report-benchmarks,
.coach-benchmark-tables {
  min-width:0;
}

#athlete-report-benchmark-graph,
#coach-report-benchmark-graph {
  scroll-margin-top:18px;
}

.report-data-point,
.report-data-bar {
  touch-action:manipulation;
}

.report-graph-tooltip {
  white-space:normal;
}

@media (max-width:900px) {
  .athlete-benchmark-workspace,
  .coach-benchmark-workspace {
    grid-template-columns:1fr !important;
  }
}



/* v198 weekly intensity shading, FIT guides and icon-only back-to-top */
.calendar-week-days.week-intensity-shaded {
  padding:2px;
  border-radius:13px;
  background:linear-gradient(90deg,var(--week-shade-start),var(--week-shade-end));
  box-shadow:inset 0 0 0 1px rgba(7,25,37,.08);
}

.calendar-week-days.week-intensity-shaded .day {
  background:rgba(255,255,255,.60);
  backdrop-filter:saturate(.92);
}

.calendar-week-days.week-intensity-shaded .day.muted {
  background:rgba(255,255,255,.72);
}

.week-actions-menu {
  min-width:248px;
  max-height:min(520px,75vh);
  overflow-y:auto;
}

.week-theme-menu-label {
  padding:7px 10px 5px;
  color:var(--muted);
  font-size:9px;
  font-weight:950;
  letter-spacing:.09em;
  text-transform:uppercase;
}

.week-actions-menu button.week-theme-btn {
  display:grid;
  grid-template-columns:42px minmax(0,1fr);
  align-items:center;
  gap:9px;
  width:100%;
  min-height:42px;
  padding:8px 10px;
  border:1px solid transparent;
  border-radius:9px;
  background:transparent;
  color:var(--navy);
  font-size:11px;
  font-weight:850;
  line-height:1.2;
  text-align:left;
  cursor:pointer;
}

.week-actions-menu button.week-theme-btn i {
  width:42px;
  height:13px;
  border:1px solid rgba(7,25,37,.12);
  border-radius:999px;
  background:linear-gradient(90deg,var(--theme-start),var(--theme-end));
}

.week-actions-menu button.week-theme-btn:hover,
.week-actions-menu button.week-theme-btn:focus,
.week-actions-menu button.week-theme-btn.active {
  border-color:rgba(0,179,255,.25);
  background:rgba(0,179,255,.07);
  outline:none;
}

.week-actions-menu button.week-theme-btn.active::after {
  content:'✓';
  color:#087b3d;
  font-weight:950;
}

.week-actions-divider {
  height:1px;
  margin:5px 7px;
  background:var(--line);
}

.fit-export-guide-links {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:7px;
  margin:10px 0 13px;
}

.fit-export-guide-links > span {
  width:100%;
  color:var(--muted);
  font-size:10px;
  font-weight:850;
}

.fit-export-guide-links a {
  display:inline-flex;
  align-items:center;
  min-height:34px;
  padding:7px 10px;
  border:1px solid rgba(0,179,255,.30);
  border-radius:9px;
  background:#fff;
  color:var(--blue);
  font-size:10px;
  font-weight:900;
  text-decoration:none;
}

.fit-export-guide-links a:hover,
.fit-export-guide-links a:focus {
  border-color:var(--blue);
  background:#eaf8ff;
  outline:none;
}

.back-to-top-btn {
  width:36px;
  min-width:36px;
  height:36px;
  min-height:36px;
  padding:0 !important;
  justify-content:center;
  gap:0;
}

@media (max-width:700px) {
  .week-actions-menu {
    min-width:min(248px,calc(100vw - 24px));
  }

  .fit-export-guide-links a {
    flex:1 1 132px;
    justify-content:center;
  }
}



/* v199 revised weekly shading and clickable PDF guides */
.calendar-week-days.week-intensity-shaded {
  position:relative;
  isolation:isolate;
}

.calendar-week-days.week-intensity-shaded .day {
  position:relative;
  z-index:2;
}

.week-reload-label {
  position:absolute;
  inset:50% 10px auto;
  z-index:1;
  transform:translateY(-50%);
  color:rgba(42,72,42,.32);
  font-family:Oswald,sans-serif;
  font-size:clamp(22px,3.2vw,42px);
  font-weight:950;
  letter-spacing:.08em;
  line-height:1;
  text-align:center;
  text-transform:uppercase;
  pointer-events:none;
  user-select:none;
}

.week-theme-help {
  display:block;
  padding:4px 10px 7px;
  color:var(--muted);
  font-size:9px;
  line-height:1.35;
}

.fit-export-guide-links > small {
  width:100%;
  color:var(--muted);
  font-size:9px;
  line-height:1.35;
}

@media (max-width:700px) {
  .week-reload-label {
    font-size:clamp(16px,6vw,26px);
    letter-spacing:.04em;
  }
}



/* v200 clear athlete-created sport chips */
.calendar .session-chip.sport-detail-chip .session-chip-type {
  line-height:1.05;
}

.calendar .session-chip.sport-detail-chip .session-chip-name {
  margin-top:3px;
  font-size:9px;
  line-height:1.05;
  opacity:.96;
}

/* v204 fullscreen calendar interaction layers */
body.athlete-calendar-fullscreen-active .modal-backdrop,
body.coach-calendar-fullscreen-active .modal-backdrop {
  z-index:3300;
}

body.athlete-calendar-fullscreen-active .athlete-quick-complete-popover,
body.coach-calendar-fullscreen-active .calendar-context-menu {
  z-index:3350;
}

body.athlete-calendar-fullscreen-active .share-backdrop,
body.coach-calendar-fullscreen-active .share-backdrop {
  z-index:3400;
}

body.athlete-calendar-fullscreen-active .toast,
body.coach-calendar-fullscreen-active .toast {
  z-index:3500;
}

/* v210 Session Runner pace guidance fields */
.workout-builder .pace-guidance-builder{display:grid;grid-template-columns:minmax(180px,.8fr) minmax(280px,1.2fr);align-items:end;gap:14px;margin-top:14px;padding:14px;border:1px solid rgba(0,179,255,.18);border-radius:16px;background:rgba(0,179,255,.045)}
.workout-builder .pace-guidance-builder>div:first-child{display:grid;gap:4px;align-self:center}
.workout-builder .pace-guidance-builder>div:first-child>label{font-weight:800;color:var(--ink)}
.workout-builder .pace-guidance-builder>div:first-child>small{color:var(--muted);line-height:1.35}
.workout-builder .pace-guidance-fields{display:grid;grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);align-items:end;gap:10px}
.workout-builder .pace-guidance-input{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;border:1px solid var(--line);border-radius:12px;background:#fff;overflow:hidden}
.workout-builder .pace-guidance-input input{min-width:0;border:0;border-radius:0;box-shadow:none;background:transparent}
.workout-builder .pace-guidance-input input:focus{outline:0;box-shadow:inset 0 0 0 2px rgba(0,179,255,.35)}
.workout-builder .pace-guidance-input span{padding:0 10px;color:var(--muted);font-size:.78rem;font-weight:800}
.workout-builder .pace-guidance-divider{padding-bottom:13px;color:var(--muted);font-size:.78rem;font-weight:800;text-transform:uppercase}
@media (max-width:720px){.workout-builder .pace-guidance-builder{grid-template-columns:1fr}.workout-builder .pace-guidance-fields{grid-template-columns:minmax(0,1fr) auto minmax(0,1fr)}}
@media (max-width:430px){.workout-builder .pace-guidance-fields{grid-template-columns:1fr}.workout-builder .pace-guidance-divider{padding:0;text-align:center}}

/* v211 RPE-chart pacing source controls */
.workout-builder .pace-guidance-controls{display:grid;gap:10px;min-width:0}
.workout-builder .pace-guidance-controls>.field{display:grid;gap:6px}
.workout-builder .pace-guidance-controls select{width:100%}
.workout-builder .pace-guidance-rpe-note{display:block;color:var(--muted);font-size:.75rem;line-height:1.4}
.workout-builder .pace-guidance-rpe-note.hidden,
.workout-builder .pace-guidance-fields.hidden{display:none}

/* v218 compact coach session viewer/editor actions */
.coach-session-workout-modal .modal-actions,
.coach-session-editor-modal .modal-actions {
  display:flex;
  flex-flow:row wrap;
  align-items:center;
  justify-content:flex-end;
  gap:7px;
}
.coach-session-workout-modal .modal-actions > button,
.coach-session-editor-modal .modal-actions > button {
  flex:0 1 auto;
  width:auto;
  min-width:0;
  max-width:100%;
  min-height:36px;
  margin-left:0;
  padding:8px 12px;
  border-radius:9px;
  font-size:12px;
  line-height:1.2;
  white-space:normal;
}
.coach-session-workout-modal .plan-modal-actions > button {
  flex:0 1 auto;
}
@media (max-width:700px) {
  .coach-session-workout-modal .modal-actions,
  .coach-session-editor-modal .modal-actions {
    flex-direction:row;
  }
  .coach-session-workout-modal .modal-actions > button,
  .coach-session-editor-modal .modal-actions > button {
    flex:1 1 calc(50% - 4px);
    width:auto;
  }
}
@media (max-width:380px) {
  .coach-session-workout-modal .modal-actions > button,
  .coach-session-editor-modal .modal-actions > button {
    flex-basis:100%;
  }
}

/* v224 stepped-run builder and RPE requirement ranges */
.coach-session-editor-modal .rpe-requirement-control,
.template-editor-modal .rpe-requirement-control {
  display:grid;
  gap:8px;
  margin-top:14px;
  padding:14px;
  border:1px solid rgba(0,179,255,.2);
  border-radius:16px;
  background:rgba(0,179,255,.045);
}
.coach-session-editor-modal .rpe-requirement-control > label,
.template-editor-modal .rpe-requirement-control > label {
  font-weight:850;
  color:var(--ink);
}
.coach-session-editor-modal .rpe-requirement-control > small,
.template-editor-modal .rpe-requirement-control > small {
  color:var(--muted);
  line-height:1.4;
}
.coach-session-editor-modal .rpe-requirement-fields,
.template-editor-modal .rpe-requirement-fields,
.workout-builder .set-rpe-range-fields {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);
  gap:10px;
  align-items:end;
}
.coach-session-editor-modal .rpe-requirement-divider,
.template-editor-modal .rpe-requirement-divider,
.workout-builder .set-rpe-range-fields > span {
  padding-bottom:13px;
  color:var(--muted);
  font-size:.76rem;
  font-weight:850;
  text-transform:uppercase;
}
.workout-builder .stepped-run-builder {
  display:grid;
  gap:16px;
}
.workout-builder .stepped-run-head {
  display:grid;
  grid-template-columns:minmax(180px,.55fr) minmax(260px,1.45fr);
  gap:14px;
  align-items:stretch;
}
.workout-builder .stepped-run-total {
  display:grid;
  align-content:center;
  gap:3px;
  padding:14px 16px;
  border:1px solid rgba(0,179,255,.25);
  border-radius:16px;
  background:linear-gradient(135deg,rgba(0,179,255,.1),rgba(0,95,255,.035));
}
.workout-builder .stepped-run-total small,
.workout-builder .stepped-run-total span {
  color:var(--muted);
}
.workout-builder .stepped-run-total strong {
  color:var(--ink);
  font-size:1.15rem;
}
.workout-builder .stepped-run-steps {
  display:grid;
  gap:12px;
}
.workout-builder .stepped-run-step {
  display:grid;
  gap:12px;
  padding:15px;
  border:1px solid rgba(0,179,255,.18);
  border-left:4px solid var(--blue);
  border-radius:16px;
  background:#fff;
  box-shadow:0 8px 20px rgba(15,35,55,.05);
}
.workout-builder .stepped-run-step-head > div {
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:8px;
}
.workout-builder .stepped-run-step-head span {
  color:var(--blue-dark);
  font-size:.78rem;
  font-weight:900;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.workout-builder .stepped-run-step-head strong {
  color:var(--ink);
}
.workout-builder .stepped-run-step-fields {
  display:grid;
  grid-template-columns:minmax(240px,.9fr) minmax(300px,1.1fr);
  gap:14px;
  align-items:start;
}
.workout-builder .stepped-run-step .rpe-requirement-control {
  margin:0;
  padding:0;
  border:0;
  border-radius:0;
  background:transparent;
}
.workout-builder .stepped-run-pace-note {
  color:var(--muted);
  line-height:1.4;
}
@media (max-width:780px) {
  .workout-builder .stepped-run-head,
  .workout-builder .stepped-run-step-fields {
    grid-template-columns:1fr;
  }
}
@media (max-width:480px) {
  .coach-session-editor-modal .rpe-requirement-fields,
  .template-editor-modal .rpe-requirement-fields,
  .workout-builder .set-rpe-range-fields {
    grid-template-columns:1fr;
  }
  .coach-session-editor-modal .rpe-requirement-divider,
  .template-editor-modal .rpe-requirement-divider,
  .workout-builder .set-rpe-range-fields > span {
    padding:0;
    text-align:center;
  }
  .workout-builder .stepped-run-step {
    padding:12px;
  }
}


/* v233 subtle matte finish for standard calendar session chips */
.calendar .session-chip:not(.long-progression):not(.long-multipaced) {
  position:relative;
  isolation:isolate;
  filter:drop-shadow(0 2px 3px rgba(6,26,38,.16));
}
.calendar .session-chip:not(.long-progression):not(.long-multipaced)::after {
  content:"";
  position:absolute;
  z-index:0;
  top:1px;
  right:1px;
  left:1px;
  height:42%;
  border-radius:inherit;
  background:linear-gradient(180deg,rgba(255,255,255,.34) 0%,rgba(255,255,255,.14) 58%,rgba(255,255,255,0) 100%);
  opacity:.72;
  pointer-events:none;
}
.calendar .session-chip:not(.long-progression):not(.long-multipaced) .session-chip-type,
.calendar .session-chip:not(.long-progression):not(.long-multipaced) .session-chip-name {
  position:relative;
  z-index:1;
}

/* v226 long progression calendar chip gradient */
.calendar .session-chip.long-progression:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock),
.calendar .session-chip.long-multipaced:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock) {
  background: linear-gradient(135deg, #aef5ff 0%, #13b5d1 42%, #0047AB 100%) !important;
  color: #fff !important;
  border-color: #13b5d1 !important;
  text-shadow: 0 1px 2px rgba(0, 18, 56, .72) !important;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.3), 0 3px 10px rgba(0,71,171,.24) !important;
}
.calendar .session-chip.long-progression:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock) .session-chip-type,
.calendar .session-chip.long-progression:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock) .session-chip-name,
.calendar .session-chip.long-multipaced:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock) .session-chip-type,
.calendar .session-chip.long-multipaced:not(.completed):not(.incomplete):not(.unplanned-run):not(.sport-colour-lock) .session-chip-name {
  color: #fff !important;
}

/* v234 visual interval workout creator */
.workout-builder .visual-workout-creator {
  margin:0 0 14px;
  padding:16px;
  border:1px solid rgba(0,179,255,.28);
  border-radius:18px;
  background:linear-gradient(145deg,#f7fcfe 0%,#edf7fb 58%,#f8faf9 100%);
  box-shadow:0 14px 30px rgba(17,42,58,.08);
}
.workout-builder .visual-workout-heading {
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:16px;
  margin-bottom:14px;
}
.workout-builder .visual-workout-heading h3 { margin:3px 0 4px; color:var(--navy); font-size:20px; }
.workout-builder .visual-workout-heading p { max-width:650px; margin:0; color:var(--muted); font-size:12px; line-height:1.5; }
.workout-builder .visual-workout-hint {
  flex:0 0 auto;
  padding:7px 10px;
  border:1px solid rgba(0,179,255,.25);
  border-radius:999px;
  background:rgba(255,255,255,.82);
  color:var(--blue);
  font-size:10px;
  font-weight:900;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.workout-builder .visual-workout-layout {
  display:grid;
  grid-template-columns:minmax(210px,250px) minmax(0,1fr);
  gap:14px;
  align-items:start;
}
.workout-builder .visual-workout-palette {
  max-height:560px;
  overflow:auto;
  padding:12px;
  border:1px solid rgba(23,42,58,.1);
  border-radius:15px;
  background:rgba(255,255,255,.76);
}
.workout-builder .visual-workout-palette-group + .visual-workout-palette-group { margin-top:15px; padding-top:14px; border-top:1px solid var(--line); }
.workout-builder .visual-workout-warmup-group > summary {
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:8px;
  padding:2px 0;
  color:var(--navy);
  cursor:pointer;
  list-style:none;
  font-size:10px;
  font-weight:900;
  letter-spacing:.09em;
  text-transform:uppercase;
}
.workout-builder .visual-workout-warmup-group > summary::-webkit-details-marker { display:none; }
.workout-builder .visual-workout-warmup-group > summary::after { content:'▾'; color:var(--blue); transition:transform .16s ease; }
.workout-builder .visual-workout-warmup-group[open] > summary::after { transform:rotate(180deg); }
.workout-builder .visual-workout-warmup-group > summary small {
  grid-column:1 / -1;
  overflow:hidden;
  color:var(--muted);
  font-size:9px;
  font-weight:700;
  letter-spacing:0;
  text-overflow:ellipsis;
  text-transform:none;
  white-space:nowrap;
}
.workout-builder .visual-workout-warmup-group > .visual-workout-palette-list { margin-top:9px; }
.workout-builder .visual-workout-palette-label {
  display:block;
  margin:0 0 8px;
  color:var(--navy);
  font-size:10px;
  font-weight:900;
  letter-spacing:.09em;
  text-transform:uppercase;
}
.workout-builder .visual-workout-palette-list { display:grid; gap:8px; }
.workout-builder .visual-palette-block {
  display:grid;
  width:100%;
  gap:2px;
  padding:10px 11px;
  border:1px solid rgba(23,42,58,.12);
  border-radius:12px;
  background:#fff;
  color:var(--ink);
  text-align:left;
  cursor:grab;
  box-shadow:0 5px 12px rgba(17,42,58,.06);
  transition:transform .16s ease,border-color .16s ease,box-shadow .16s ease;
}
.workout-builder .visual-palette-block:hover,
.workout-builder .visual-palette-block:focus { transform:translateY(-1px); border-color:rgba(0,179,255,.6); box-shadow:0 8px 18px rgba(0,179,255,.12); }
.workout-builder .visual-palette-block:active { cursor:grabbing; }
.workout-builder .visual-palette-block.active { border-color:var(--blue); box-shadow:inset 0 0 0 1px var(--blue),0 7px 16px rgba(0,179,255,.12); }
.workout-builder .visual-palette-block small { color:var(--blue); font-size:9px; font-weight:900; letter-spacing:.06em; text-transform:uppercase; }
.workout-builder .visual-palette-block strong { color:var(--navy); font-size:12px; line-height:1.25; }
.workout-builder .visual-palette-block span { color:var(--muted); font-size:10px; line-height:1.3; }
.workout-builder .visual-palette-format { border-left:4px solid #405a70; }
.workout-builder .visual-palette-pyramid { border-left:4px solid #7a54a3; background:linear-gradient(135deg,#fff,#faf7fd); }
.workout-builder .visual-palette-set { border-left:4px solid var(--blue); }
.workout-builder .visual-palette-step { border-left:4px solid #22a6c7; }
.workout-builder .visual-palette-cooldown { border-left:4px solid var(--navy); }
.workout-builder .visual-workout-stage { min-width:0; }
.workout-builder .visual-workout-canvas {
  position:relative;
  display:grid;
  gap:10px;
  min-height:230px;
  padding:14px;
  border:1px dashed rgba(0,179,255,.46);
  border-radius:16px;
  background:rgba(255,255,255,.9);
}
.workout-builder .visual-workout-canvas::before {
  content:'';
  position:absolute;
  top:24px;
  bottom:24px;
  left:28px;
  width:2px;
  border-radius:3px;
  background:linear-gradient(var(--blue),rgba(0,179,255,.14),var(--navy));
  pointer-events:none;
}
.workout-builder .visual-workout-block,
.workout-builder .visual-workout-set,
.workout-builder .visual-workout-recovery {
  position:relative;
  z-index:1;
  margin-left:0;
  border-radius:14px;
  box-shadow:0 8px 18px rgba(17,42,58,.08);
}
.workout-builder .visual-workout-block {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px 12px 12px 42px;
  border:1px solid rgba(0,179,255,.22);
  background:linear-gradient(135deg,#f4fdff,#fff);
  cursor:grab;
}
.workout-builder .visual-workout-block::before,
.workout-builder .visual-workout-set::before,
.workout-builder .visual-workout-recovery::before {
  content:'';
  position:absolute;
  left:21px;
  top:19px;
  width:12px;
  height:12px;
  border:3px solid #fff;
  border-radius:50%;
  background:var(--blue);
  box-shadow:0 0 0 2px rgba(0,179,255,.35);
}
.workout-builder .visual-workout-cooldown { border-color:rgba(23,42,58,.22); background:linear-gradient(135deg,#f4f7f9,#fff); }
.workout-builder .visual-workout-cooldown::before { background:var(--navy); box-shadow:0 0 0 2px rgba(23,42,58,.22); }
.workout-builder .visual-workout-block-copy { display:grid; min-width:0; gap:2px; }
.workout-builder .visual-workout-block-copy small,
.workout-builder .visual-workout-set header small,
.workout-builder .visual-workout-recovery small { color:var(--blue); font-size:9px; font-weight:900; letter-spacing:.07em; text-transform:uppercase; }
.workout-builder .visual-workout-block-copy strong,
.workout-builder .visual-workout-set header strong,
.workout-builder .visual-workout-recovery strong { color:var(--navy); font-size:13px; }
.workout-builder .visual-workout-block-copy span { color:var(--muted); font-size:10px; }
.workout-builder .visual-workout-set {
  padding:12px 12px 12px 42px;
  border:1px solid rgba(0,179,255,.32);
  background:linear-gradient(145deg,#f0fbff,#fff 60%);
  cursor:grab;
}
.workout-builder .visual-workout-set > header { display:flex; align-items:center; justify-content:space-between; gap:12px; margin-bottom:9px; }
.workout-builder .visual-workout-set > header > div:first-child { display:grid; gap:2px; }
.workout-builder .visual-workout-step-list { display:grid; gap:7px; }
.workout-builder .visual-workout-step {
  position:relative;
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto;
  align-items:center;
  gap:9px;
  padding:10px;
  border:1px solid rgba(23,42,58,.12);
  border-radius:11px;
  background:#fff;
  cursor:grab;
  box-shadow:0 4px 10px rgba(17,42,58,.05);
}
.workout-builder .visual-workout-drag-handle { color:#86a5af; font-size:15px; font-weight:900; letter-spacing:-4px; }
.workout-builder .visual-workout-step-copy { display:grid; min-width:0; gap:2px; }
.workout-builder .visual-workout-step-copy small { color:var(--blue); font-size:9px; font-weight:900; text-transform:uppercase; }
.workout-builder .visual-workout-step-copy strong { overflow:hidden; color:var(--navy); font-size:12px; line-height:1.3; text-overflow:ellipsis; white-space:nowrap; }
.workout-builder .visual-workout-step-copy span { color:var(--muted); font-size:9px; line-height:1.25; }
.workout-builder .visual-workout-block-actions { display:flex; align-items:center; gap:4px; flex:0 0 auto; }
.workout-builder .visual-workout-block-actions button,
.workout-builder .visual-workout-recovery button {
  min-width:30px;
  min-height:28px;
  padding:4px 7px;
  border:1px solid rgba(23,42,58,.12);
  border-radius:8px;
  background:#fff;
  color:var(--navy);
  font-size:10px;
  font-weight:800;
  cursor:pointer;
}
.workout-builder .visual-workout-block-actions button:hover,
.workout-builder .visual-workout-block-actions button:focus,
.workout-builder .visual-workout-recovery button:hover,
.workout-builder .visual-workout-recovery button:focus { border-color:var(--blue); color:var(--blue); }
.workout-builder .visual-workout-block-actions button.danger { color:#b73131; }
.workout-builder .visual-workout-add-step,
.workout-builder .visual-workout-canvas-end {
  width:100%;
  padding:8px 10px;
  border:1px dashed rgba(0,179,255,.42);
  border-radius:10px;
  background:rgba(0,179,255,.035);
  color:var(--blue);
  font-size:10px;
  font-weight:900;
  cursor:pointer;
}
.workout-builder .visual-workout-canvas-end { position:relative; z-index:1; margin-left:0; padding:11px 14px 11px 42px; text-align:left; }
.workout-builder .visual-workout-recovery {
  display:flex;
  align-items:center;
  gap:10px;
  padding:9px 10px 9px 42px;
  border:1px solid rgba(23,42,58,.11);
  background:#f4f7f8;
}
.workout-builder .visual-workout-recovery::before { top:13px; background:#758d96; box-shadow:0 0 0 2px rgba(117,141,150,.2); }
.workout-builder .visual-workout-recovery strong { margin-right:auto; font-size:11px; }
.workout-builder .visual-workout-trash {
  display:grid;
  place-items:center;
  gap:2px;
  min-height:58px;
  margin-top:9px;
  border:1px dashed rgba(183,49,49,.3);
  border-radius:13px;
  background:rgba(183,49,49,.035);
  color:#a34343;
  text-align:center;
  opacity:.68;
  transition:opacity .16s ease,background .16s ease,border-color .16s ease,transform .16s ease;
}
.workout-builder .visual-workout-trash strong { font-size:11px; }
.workout-builder .visual-workout-trash span { font-size:9px; }
.workout-builder .visual-workout-creator.is-dragging .visual-workout-trash { opacity:1; transform:translateY(-1px); }
.workout-builder [data-visual-drop-kind].is-drag-over { border-color:var(--blue) !important; background:rgba(0,179,255,.1) !important; box-shadow:0 0 0 3px rgba(0,179,255,.12) !important; }
.workout-builder .visual-workout-trash.is-drag-over { border-color:#b73131 !important; background:rgba(183,49,49,.12) !important; box-shadow:0 0 0 3px rgba(183,49,49,.1) !important; }
.workout-builder .is-being-dragged { opacity:.45; }
.workout-builder .visual-workout-details {
  border:1px solid var(--line);
  border-radius:14px;
  background:#fff;
  overflow:hidden;
}
.workout-builder .visual-workout-details > summary {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px 14px;
  cursor:pointer;
  list-style:none;
  color:var(--navy);
  font-size:12px;
  font-weight:900;
}
.workout-builder .visual-workout-details > summary::-webkit-details-marker { display:none; }
.workout-builder .visual-workout-details > summary::after { content:'▾'; margin-left:auto; color:var(--blue); transition:transform .16s ease; }
.workout-builder .visual-workout-details[open] > summary::after { transform:rotate(180deg); }
.workout-builder .visual-workout-details > summary small { color:var(--muted); font-size:10px; font-weight:600; }
.workout-builder .visual-workout-details-body { padding:14px; border-top:1px solid var(--line); }
.workout-builder .visual-detail-metric { display:contents; }
.workout-builder .visual-detail-metric.hidden { display:none; }
@media (max-width:820px) {
  .workout-builder .visual-workout-layout { grid-template-columns:1fr; }
  .workout-builder .visual-workout-palette { max-height:none; overflow:visible; }
  .workout-builder .visual-workout-palette-list { display:flex; overflow-x:auto; padding:2px 2px 7px; scroll-snap-type:x proximity; }
  .workout-builder .visual-palette-block { flex:0 0 180px; scroll-snap-align:start; }
  .workout-builder .visual-workout-palette-list.compact .visual-palette-block { flex-basis:160px; }
}
@media (max-width:520px) {
  .workout-builder .visual-workout-creator { padding:12px; border-radius:15px; }
  .workout-builder .visual-workout-heading { display:grid; gap:8px; }
  .workout-builder .visual-workout-hint { justify-self:start; }
  .workout-builder .visual-workout-canvas { padding:10px; }
  .workout-builder .visual-workout-canvas::before { left:21px; }
  .workout-builder .visual-workout-block,
  .workout-builder .visual-workout-set,
  .workout-builder .visual-workout-recovery,
  .workout-builder .visual-workout-canvas-end { padding-left:34px; }
  .workout-builder .visual-workout-block::before,
  .workout-builder .visual-workout-set::before,
  .workout-builder .visual-workout-recovery::before { left:14px; }
  .workout-builder .visual-workout-step { grid-template-columns:auto minmax(0,1fr); }
  .workout-builder .visual-workout-step .visual-workout-block-actions { grid-column:1 / -1; justify-content:flex-end; }
  .workout-builder .visual-workout-block { align-items:flex-start; }
  .workout-builder .visual-workout-block > .visual-workout-block-actions { flex-wrap:wrap; justify-content:flex-end; }
  .workout-builder .visual-workout-details > summary { display:grid; grid-template-columns:1fr auto; }
  .workout-builder .visual-workout-details > summary small { grid-column:1 / -1; }
}

/* v237 birthday reminders and fullscreen calendar paint stability */
.coach-birthday-reminders {
  margin-top:22px;
  overflow:hidden;
}
.coach-birthday-reminder-list {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(190px,1fr));
  gap:9px;
  padding:0 14px 16px;
}
.coach-birthday-reminder {
  display:flex;
  min-width:0;
  align-items:center;
  gap:10px;
  padding:10px 11px;
  border:1px solid rgba(0,179,255,.22);
  border-radius:12px;
  background:#f7fcff;
  color:var(--navy);
  text-align:left;
  cursor:pointer;
}
.coach-birthday-reminder:hover,
.coach-birthday-reminder:focus {
  border-color:var(--cyan);
  background:#edfaff;
  outline:none;
}
.coach-birthday-reminder.is-today {
  border-color:rgba(255,92,0,.48);
  background:#fff5ef;
  box-shadow:0 4px 12px rgba(255,92,0,.10);
}
.coach-birthday-date {
  flex:0 0 auto;
  min-width:48px;
  padding:7px 8px;
  border-radius:9px;
  background:var(--navy);
  color:#fff;
  font-family:Oswald,sans-serif;
  font-size:15px;
  font-weight:800;
  text-align:center;
  text-transform:uppercase;
}
.coach-birthday-reminder.is-today .coach-birthday-date {
  background:#d94d17;
}
.coach-birthday-copy {
  display:grid;
  min-width:0;
  gap:2px;
}
.coach-birthday-copy strong,
.coach-birthday-copy small {
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.coach-birthday-copy strong {
  font-size:12px;
  font-weight:950;
}
.coach-birthday-copy small {
  color:var(--muted);
  font-size:10px;
  font-weight:800;
}
.coach-birthday-empty {
  display:grid;
  gap:3px;
  padding:0 14px 16px;
  color:var(--muted);
  font-size:11px;
}
.coach-birthday-empty strong {
  color:var(--navy);
}

@media (orientation:landscape) {
  .athlete-calendar-card.athlete-mobile-fullscreen .calendar,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .calendar {
    -webkit-overflow-scrolling:auto;
    scroll-behavior:auto;
  }
  .athlete-calendar-card.athlete-mobile-fullscreen .calendar-week-days.week-intensity-shaded .day,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .calendar-week-days.week-intensity-shaded .day {
    -webkit-backdrop-filter:none;
    backdrop-filter:none;
  }
  .athlete-calendar-card.athlete-mobile-fullscreen .session-chip-marquee,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .session-chip-marquee {
    animation:none !important;
    transform:none !important;
    will-change:auto !important;
  }
  .athlete-calendar-card.athlete-mobile-fullscreen .session-chip-type,
  .athlete-calendar-card.athlete-mobile-fullscreen .session-chip-name,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .session-chip-type,
  .coach-athlete-calendar-card.coach-calendar-fullscreen .session-chip-name {
    container-type:normal;
  }
}

/* v238 compact planned-session actions in athlete and coach workout windows */
.modal .plan-modal-actions {
  display:flex;
  flex-flow:row wrap;
  align-items:center;
  justify-content:flex-end;
  gap:7px;
}
.modal .plan-modal-actions > button {
  flex:0 1 auto;
  width:auto;
  min-width:0;
  max-width:100%;
  min-height:34px;
  margin-left:0;
  padding:7px 11px;
  border-radius:9px;
  font-size:11px;
  line-height:1.2;
  white-space:normal;
}
@media (max-width:700px) {
  .modal .plan-modal-actions { flex-direction:row; }
  .modal .plan-modal-actions > button { flex:0 1 auto; width:auto; }
}


/* v240 Google Play privacy and account controls */
.login-policy-links{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  margin-top:14px;
  color:var(--muted);
  font-size:12px;
  font-weight:700;
}
.login-policy-links a{
  color:var(--muted);
  text-underline-offset:3px;
}
.login-policy-links a:hover,
.login-policy-links a:focus{color:var(--blue)}
.top-privacy-link{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:36px;
  padding:0 12px;
  border:1px solid rgba(255,255,255,.24);
  border-radius:10px;
  color:inherit;
  text-decoration:none;
  font-size:12px;
  font-weight:800;
  white-space:nowrap;
}
.top-settings-dropdown .top-privacy-link{
  width:100%;
  justify-content:flex-start;
  min-height:auto;
  padding:10px 12px;
  border:0;
  border-radius:8px;
}
.top-privacy-link:hover,
.top-privacy-link:focus{background:rgba(0,179,255,.13)}
@media(max-width:720px){
  .athlete-feature-actions .top-privacy-link{padding:0 9px;font-size:10px}
}


/* v245 mobile visual builder and portrait calendar chip refinements */
@media (min-width:821px) {
  .workout-builder .visual-workout-warmup-group > summary,
  .workout-builder .visual-workout-option-group > summary {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    gap:4px 8px;
    padding:2px 0;
    color:var(--navy);
    cursor:pointer;
    list-style:none;
    font-size:10px;
    font-weight:900;
    letter-spacing:.09em;
    text-transform:uppercase;
    pointer-events:auto;
  }
  .workout-builder .visual-workout-option-group > summary::-webkit-details-marker { display:none; }
  .workout-builder .visual-workout-option-group > summary::after {
    content:'▾';
    grid-column:2;
    grid-row:1 / span 2;
    color:var(--blue);
    transition:transform .16s ease;
  }
  .workout-builder .visual-workout-option-group[open] > summary::after { transform:rotate(180deg); }
  .workout-builder .visual-workout-option-group > summary small {
    display:block;
    grid-column:1;
    overflow:hidden;
    color:var(--muted);
    font-size:9px;
    font-weight:700;
    letter-spacing:0;
    text-overflow:ellipsis;
    text-transform:none;
    white-space:nowrap;
  }
  .workout-builder .visual-workout-option-group > .visual-workout-palette-list { margin-top:9px; }
}
@media (max-width:820px) {
  .workout-builder,
  .workout-builder .structured-builder,
  .workout-builder .visual-workout-creator,
  .workout-builder .visual-workout-layout,
  .workout-builder .visual-workout-palette,
  .workout-builder .visual-workout-stage,
  .workout-builder .visual-workout-canvas,
  .workout-builder .visual-workout-details,
  .workout-builder .visual-workout-details-body,
  .workout-builder .rep-set-builders,
  .workout-builder .rep-set-builder,
  .workout-builder .rep-line-builder {
    width:100%;
    max-width:100%;
    min-width:0;
    box-sizing:border-box;
  }
  .workout-builder { overflow:hidden; }
  .workout-builder .visual-workout-creator { padding:10px; }
  .workout-builder .visual-workout-heading { margin-bottom:10px; }
  .workout-builder .visual-workout-heading h3 { font-size:18px; }
  .workout-builder .visual-workout-heading p { font-size:11px; line-height:1.4; }
  .workout-builder .visual-workout-hint { display:none; }
  .workout-builder .visual-workout-layout { display:block; }
  .workout-builder .visual-workout-palette {
    max-height:none;
    overflow:visible;
    padding:0;
    border:0;
    background:transparent;
  }
  .workout-builder .visual-workout-palette > [data-visual-palette] { display:grid; gap:7px; }
  .workout-builder .visual-workout-palette-group,
  .workout-builder .visual-workout-palette-group + .visual-workout-palette-group {
    margin:0;
    padding:0;
    border:1px solid rgba(23,42,58,.12);
    border-radius:11px;
    background:rgba(255,255,255,.9);
    overflow:hidden;
  }
  .workout-builder .visual-workout-warmup-group > summary,
  .workout-builder .visual-workout-option-group > summary {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:center;
    gap:5px 8px;
    padding:9px 10px;
    color:var(--navy);
    cursor:pointer;
    list-style:none;
    font-size:10px;
    font-weight:900;
    letter-spacing:.07em;
    text-transform:uppercase;
  }
  .workout-builder .visual-workout-warmup-group > summary::-webkit-details-marker,
  .workout-builder .visual-workout-option-group > summary::-webkit-details-marker { display:none; }
  .workout-builder .visual-workout-warmup-group > summary::after,
  .workout-builder .visual-workout-option-group > summary::after {
    content:'▾';
    grid-column:2;
    grid-row:1 / span 2;
    color:var(--blue);
    font-size:12px;
    transition:transform .16s ease;
  }
  .workout-builder .visual-workout-warmup-group[open] > summary::after,
  .workout-builder .visual-workout-option-group[open] > summary::after { transform:rotate(180deg); }
  .workout-builder .visual-workout-warmup-group > summary small,
  .workout-builder .visual-workout-option-group > summary small {
    grid-column:1;
    overflow:hidden;
    color:var(--muted);
    font-size:9px;
    font-weight:700;
    letter-spacing:0;
    text-overflow:ellipsis;
    text-transform:none;
    white-space:nowrap;
  }
  .workout-builder .visual-workout-palette-list,
  .workout-builder .visual-workout-palette-list.compact {
    display:grid;
    grid-template-columns:1fr;
    gap:6px;
    overflow:visible;
    margin:0;
    padding:0 8px 8px;
    scroll-snap-type:none;
  }
  .workout-builder .visual-workout-palette-list .visual-palette-block,
  .workout-builder .visual-workout-palette-list.compact .visual-palette-block {
    width:100%;
    max-width:100%;
    min-width:0;
    flex:none;
    padding:8px 9px;
    border-radius:9px;
    box-shadow:0 3px 8px rgba(17,42,58,.05);
    scroll-snap-align:none;
  }
  .workout-builder .visual-palette-block strong { font-size:11px; }
  .workout-builder .visual-palette-block span { font-size:9px; }
  .workout-builder .visual-workout-stage { margin-top:9px; }
  .workout-builder .visual-workout-canvas { min-height:0; padding:8px; gap:7px; }
  .workout-builder .visual-workout-canvas::before { left:18px; }
  .workout-builder .visual-workout-block,
  .workout-builder .visual-workout-set,
  .workout-builder .visual-workout-recovery,
  .workout-builder .visual-workout-canvas-end { padding-left:29px; }
  .workout-builder .visual-workout-block::before,
  .workout-builder .visual-workout-set::before,
  .workout-builder .visual-workout-recovery::before { left:11px; }
  .workout-builder .visual-workout-block,
  .workout-builder .visual-workout-set { border-radius:11px; }
  .workout-builder .visual-workout-block-copy strong,
  .workout-builder .visual-workout-set header strong { font-size:12px; }
  .workout-builder .visual-workout-step {
    grid-template-columns:minmax(0,1fr);
    gap:5px;
    padding:8px;
  }
  .workout-builder .visual-workout-drag-handle { display:none; }
  .workout-builder .visual-workout-step-copy strong {
    overflow:visible;
    text-overflow:clip;
    white-space:normal;
  }
  .workout-builder .visual-workout-step .visual-workout-block-actions,
  .workout-builder .visual-workout-block > .visual-workout-block-actions {
    grid-column:auto;
    justify-content:flex-start;
    flex-wrap:wrap;
  }
  .workout-builder .visual-workout-block-actions button,
  .workout-builder .visual-workout-recovery button { min-width:27px; min-height:27px; padding:3px 6px; }
  .workout-builder .visual-workout-trash { min-height:48px; }
  .workout-builder .visual-workout-details-body { padding:9px; }
  .workout-builder input,
  .workout-builder select,
  .workout-builder textarea { max-width:100%; min-width:0; box-sizing:border-box; }
}
@media (max-width:620px) and (orientation:portrait) {
  .calendar .session-chip {
    min-height:29px;
    max-height:none;
    padding:4px 3px;
    line-height:1.08;
  }
  .calendar .session-chip-type,
  .calendar .session-chip-name {
    line-height:1.08;
    text-overflow:ellipsis;
  }
  .calendar .session-chip-type { font-size:7.6px; }
  .calendar .session-chip-name { margin-top:2px; font-size:7.2px; }
  .calendar .session-chip-marquee {
    display:block;
    width:auto;
    max-width:100%;
    padding-right:0;
    overflow:hidden;
    text-overflow:ellipsis;
    transform:none !important;
    animation:none !important;
    will-change:auto;
  }
}

/* v249 Coach dashboard Multi-timer icon and per-step Session Runner completion controls */
.dashboard-action-img--multi-timer-icon {
  filter:none;
}
.workout-builder .metric-control-label-row {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  min-width:0;
}
.workout-builder .metric-control-label-row > label {
  min-width:0;
}
.workout-builder .runner-step-mode-toggle {
  display:inline-flex;
  flex:0 0 auto;
  gap:2px;
  padding:2px;
  border:1px solid rgba(0,179,255,.28);
  border-radius:7px;
  background:rgba(0,179,255,.07);
}
.workout-builder .runner-step-mode-option {
  min-width:26px;
  min-height:22px;
  padding:2px 5px;
  border:0;
  border-radius:5px;
  background:transparent;
  color:var(--muted);
  font-size:9px;
  font-weight:900;
  line-height:1;
  letter-spacing:.04em;
  cursor:pointer;
}
.workout-builder .runner-step-mode-option.active {
  background:var(--blue);
  color:#fff;
  box-shadow:0 2px 5px rgba(0,179,255,.24);
}
.workout-builder .runner-step-mode-option:focus-visible {
  outline:2px solid rgba(0,179,255,.45);
  outline-offset:1px;
}
.athlete-profile-view {
  display:grid;
  gap:16px;
}
.athlete-profile-view .profile-avatar-preview {
  margin-inline:auto;
}
.athlete-profile-view dl {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:10px;
  margin:0;
}
.athlete-profile-view dl > div {
  min-width:0;
  padding:11px 12px;
  border:1px solid var(--line);
  border-radius:10px;
  background:rgba(255,255,255,.035);
}
.athlete-profile-view dt {
  margin-bottom:4px;
  color:var(--muted);
  font-size:11px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.athlete-profile-view dd {
  margin:0;
  overflow-wrap:anywhere;
  color:var(--text);
  font-weight:700;
}
.athlete-profile-pin-note {
  margin:0;
  color:var(--muted);
  font-size:12px;
}
.calendar,
.calendar * {
  -webkit-user-select:none;
  user-select:none;
}
.calendar .session-chip {
  -webkit-touch-callout:none;
}
@media (max-width:700px) {
  .athlete-profile-view dl {
    grid-template-columns:1fr;
  }
}
.planned-step-runner-mode {
  margin:7px 0 11px;
  color:var(--muted);
  font-size:12px;
}
.planned-step-runner-mode strong {
  color:var(--text);
}

/* v250 coach dashboard consistency ranking */
.coach-consistency-list { display:grid; gap:10px; }
.coach-consistency-row { width:100%; display:grid; grid-template-columns:34px minmax(0,1fr) auto; align-items:center; gap:10px; padding:12px; border:1px solid rgba(0,179,255,.18); border-radius:14px; background:linear-gradient(145deg,rgba(255,255,255,.98),rgba(238,249,255,.94)); color:inherit; text-align:left; cursor:pointer; box-shadow:0 7px 18px rgba(16,37,54,.07); }
.coach-consistency-row:hover,.coach-consistency-row:focus-visible { border-color:rgba(0,179,255,.58); transform:translateY(-1px); box-shadow:0 10px 22px rgba(16,37,54,.11); }
.coach-consistency-rank { display:grid; place-items:center; width:32px; height:32px; border-radius:50%; background:#102536; color:#fff; font-family:"Oswald",sans-serif; font-size:16px; }
.coach-consistency-main { min-width:0; display:grid; gap:4px; }
.coach-consistency-main strong { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.coach-consistency-main small { color:var(--muted); font-size:11px; }
.coach-consistency-progress { display:block; height:6px; overflow:hidden; border-radius:999px; background:rgba(16,37,54,.11); }
.coach-consistency-progress i { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,#00b3ff,#126bff); }
.coach-consistency-rate { color:#0875ad; font-family:"Oswald",sans-serif; font-size:19px; font-weight:600; }
@media (max-width:520px){.coach-consistency-row{grid-template-columns:30px minmax(0,1fr) auto;padding:10px;}.coach-consistency-rank{width:28px;height:28px;font-size:14px}.coach-consistency-rate{font-size:17px}}

/* v254 athlete calendar library, birthday messages and RPE pace previews */
.library-source.calendar{
  background:rgba(36,171,171,.14);
  color:#146d73;
}
.coach-birthday-reminder-list{
  grid-template-columns:repeat(auto-fit,minmax(290px,1fr));
}
.coach-birthday-reminder-item{
  display:grid;
  min-width:0;
  border:1px solid rgba(0,179,255,.20);
  border-radius:14px;
  background:#f7fcff;
  overflow:hidden;
}
.coach-birthday-reminder-item.is-today{
  border-color:rgba(86,190,70,.46);
  background:#f0ffe9;
  box-shadow:0 5px 16px rgba(86,190,70,.13);
}
.coach-birthday-reminder-item .coach-birthday-reminder{
  width:100%;
  border:0;
  border-radius:0;
  background:transparent;
}
.coach-birthday-message{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  align-items:center;
  gap:10px;
  padding:10px 11px;
  border-top:1px solid rgba(0,179,255,.14);
  background:rgba(183,255,126,.24);
}
.coach-birthday-message p{
  margin:0;
  color:#173827;
  font-size:12px;
  line-height:1.45;
}
.coach-birthday-message .table-btn{
  white-space:nowrap;
}
.workout-builder .rpe-pace-guidance-preview{
  display:grid;
  gap:6px;
  padding:10px 11px;
  border:1px solid rgba(0,179,255,.22);
  border-radius:12px;
  background:#f6fcff;
}
.workout-builder .rpe-pace-guidance-preview.hidden{
  display:none;
}
.workout-builder .rpe-pace-guidance-preview>small{
  color:var(--muted);
  font-size:.72rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.workout-builder .rpe-pace-preview-row{
  display:flex;
  justify-content:space-between;
  gap:12px;
  color:var(--ink);
  font-size:.78rem;
}
.workout-builder .rpe-pace-preview-row span{
  color:#087a9c;
  font-weight:800;
  text-align:right;
}
.workout-builder .rpe-pace-preview-row.is-empty span,
.workout-builder .rpe-pace-preview-empty{
  color:#a04c29;
}
@media (max-width:620px){
  .coach-birthday-message{grid-template-columns:1fr}
  .coach-birthday-message .table-btn{justify-self:start}
  .workout-builder .rpe-pace-preview-row{display:grid;gap:2px}
  .workout-builder .rpe-pace-preview-row span{text-align:left}
}


/* v255 compact coach birthday reminders and birthday-only athlete profile message */
.coach-birthday-reminder-list {
  grid-template-columns:repeat(auto-fit,minmax(190px,1fr));
}
.athlete-profile-birthday-message {
  display:grid;
  gap:6px;
  width:100%;
  margin:2px 0 14px;
  padding:13px 15px;
  border:1px solid rgba(86,190,70,.42);
  border-radius:14px;
  background:linear-gradient(135deg,rgba(183,255,126,.34),rgba(0,179,255,.10));
  color:#173827;
}
.athlete-profile-birthday-message span {
  color:#0875ad;
  font-size:.72rem;
  font-weight:900;
  letter-spacing:.07em;
  text-transform:uppercase;
}
.athlete-profile-birthday-message p {
  margin:0;
  font-size:.92rem;
  font-weight:700;
  line-height:1.5;
}
