/* ========================================================================== 
   Coach OS — Coach workspace UI v2
   UI-only redesign. Scoped to body.coach-ui-v2.
   ========================================================================== */
body.coach-ui-v2{
  --coach-navy:#071e36;
  --coach-navy-2:#102f4c;
  --coach-orange:#f06413;
  --coach-orange-dark:#d94f05;
  --coach-bg:#f7f9fb;
  --coach-card:#ffffff;
  --coach-ink:#10233e;
  --coach-muted:#68768b;
  --coach-line:#e2e7ed;
  --coach-soft:#f2f5f8;
  --coach-blue:#2f6fe4;
  --coach-purple:#7157e8;
  --coach-green:#15a05d;
  --coach-amber:#e89a13;
  --coach-red:#e44b55;
  background:var(--coach-bg);
  color:var(--coach-ink);
}
body.coach-ui-v2 .app-shell{min-height:100vh;background:var(--coach-bg)}
body.coach-ui-v2 .sidebar{
  width:var(--sidebar-w);
  height:100vh;
  padding:18px 14px 16px;
  background:var(--coach-navy);
  overflow:hidden;
}
body.coach-ui-v2 .brand{height:54px;margin-bottom:14px;padding:0 7px 12px}
body.coach-ui-v2 .brand-mark{width:27px;height:27px;color:var(--coach-orange)}
body.coach-ui-v2 .brand-name{font-size:19px;letter-spacing:-.25px}
body.coach-ui-v2 .nav{gap:5px;overflow:visible;min-height:0}
body.coach-ui-v2 .nav-item{
  height:45px;
  border-radius:7px;
  padding:0 13px;
  gap:13px;
  color:#e8edf3;
  font-size:14px;
  font-weight:500;
}
body.coach-ui-v2 .nav-item svg{width:20px;height:20px;stroke-width:1.8}
body.coach-ui-v2 .nav-item:hover{background:rgba(255,255,255,.07)}
body.coach-ui-v2 .nav-item.active{background:#1a3854;color:#fff;font-weight:650}
body.coach-ui-v2 .nav-item.active::before{left:-14px;top:9px;bottom:9px;width:4px;background:var(--coach-orange);border-radius:0 4px 4px 0}
body.coach-ui-v2 .sidebar-help{
  margin:0 6px;
  padding:12px 10px 4px;
  border:0;
  border-top:1px solid rgba(255,255,255,.14);
  border-radius:0;
  color:#dce5ed;
}
body.coach-ui-v2 .sidebar-help strong{font-size:12px;margin:0 0 5px;color:#fff}
body.coach-ui-v2 .sidebar-help strong::before{content:"";width:8px;height:8px;border:2px solid var(--coach-orange);border-radius:50%}
body.coach-ui-v2 .sidebar-help p{margin:0;font-size:10.5px;line-height:1.55;color:#aebdca}
body.coach-ui-v2 .sidebar-help a{display:none}
body.coach-ui-v2 .main{background:var(--coach-bg);min-width:0}
body.coach-ui-v2 .utility-header{
  height:78px;
  padding:0 24px 0 28px;
  background:#fff;
  border-bottom:1px solid var(--coach-line);
  gap:14px;
}
body.coach-ui-v2 .header-title{min-width:270px}
body.coach-ui-v2 .header-title h1{font-size:25px;line-height:1.1;letter-spacing:-.55px;color:var(--coach-ink)}
body.coach-ui-v2 .header-title p{margin-top:5px;color:var(--coach-muted);font-size:11.5px}
body.coach-ui-v2 .profile{font-weight:600;color:var(--coach-ink);white-space:nowrap}
body.coach-ui-v2 .avatar{width:36px;height:36px;background:var(--coach-navy)}
body.coach-ui-v2 .coach-role-badge{font-size:10px;padding:4px 9px;background:#f4f1ff;border-color:#d9d0ff;color:#5742bd}
body.coach-ui-v2 #module-root{min-height:calc(100vh - 78px);overflow-x:hidden;background:var(--coach-bg)}
body.coach-ui-v2 .primary-slot{min-width:0}
.coach-header-tools{display:flex;align-items:center;gap:12px}
.coach-global-search{
  width:285px;height:38px;display:flex;align-items:center;gap:8px;
  padding:0 12px;border:1px solid var(--coach-line);border-radius:8px;background:#fff;color:#7b8798;
}
.coach-global-search svg{width:17px;height:17px;flex:0 0 auto}
.coach-global-search input{min-width:0;width:100%;height:100%;border:0;outline:0;background:transparent;color:var(--coach-ink);font:inherit;font-size:11.5px}
.coach-global-search input::placeholder{color:#9aa5b3}
.coach-header-cta{height:39px!important;border-radius:7px!important;padding:0 16px!important;white-space:nowrap;background:var(--coach-orange)!important;border-color:var(--coach-orange)!important}
.coach-header-cta:hover{background:var(--coach-orange-dark)!important}

.coach-workspace-v2{padding:18px 24px 24px;font-family:Inter,"Noto Sans Devanagari","Nirmala UI",Arial,sans-serif;color:var(--coach-ink)}
.coach-page{display:flex;flex-direction:column;gap:14px;min-width:0}
.coach-page svg,.coach-workspace-v2 svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.cw-loading-v2,.cw-load-error{min-height:420px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;background:#fff;border:1px solid var(--coach-line);border-radius:12px;color:var(--coach-muted)}
.cw-loading-v2 span{width:30px;height:30px;border:3px solid #e7ebef;border-top-color:var(--coach-orange);border-radius:50%;animation:cw-spin .8s linear infinite}
@keyframes cw-spin{to{transform:rotate(360deg)}}
.cw-load-error svg{width:28px;height:28px;color:var(--coach-red)}
.cw-load-error strong{font-size:16px;color:var(--coach-ink)}
.cw-load-error p,.cw-load-error span{margin:0;font-size:12px}
.cw-privacy-foot{display:flex;align-items:center;gap:8px;margin-top:14px;padding:0 4px;color:#748298;font-size:10.5px}
.cw-privacy-foot svg{width:15px;height:15px;color:var(--coach-green)}

.cw-kpi-grid{display:grid;gap:11px;min-width:0}
.cw-kpi-grid.six{grid-template-columns:repeat(6,minmax(0,1fr))}
.cw-kpi-grid.five{grid-template-columns:repeat(5,minmax(0,1fr))}
.cw-kpi-grid.four{grid-template-columns:repeat(4,minmax(0,1fr))}
.cw-kpi-v2{min-width:0;min-height:94px;display:flex;align-items:center;gap:12px;padding:14px;background:#fff;border:1px solid var(--coach-line);border-radius:11px}
.cw-kpi-icon{width:39px;height:39px;display:grid;place-items:center;border-radius:10px;flex:0 0 auto;background:#edf3ff;color:var(--coach-blue)}
.cw-kpi-v2>div{min-width:0}
.cw-kpi-v2 span:not(.cw-kpi-icon){display:block;color:#394b63;font-size:10.5px;font-weight:650;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-kpi-v2 strong{display:block;margin-top:4px;color:var(--coach-ink);font-size:23px;line-height:1;font-weight:720}
.cw-kpi-v2 small{display:block;margin-top:7px;color:var(--coach-muted);font-size:9.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-kpi-v2.tone-purple .cw-kpi-icon{background:#f1edff;color:var(--coach-purple)}
.cw-kpi-v2.tone-green .cw-kpi-icon{background:#eaf8f0;color:var(--coach-green)}
.cw-kpi-v2.tone-amber .cw-kpi-icon{background:#fff5e5;color:var(--coach-amber)}
.cw-kpi-v2.tone-red .cw-kpi-icon{background:#fff0f1;color:var(--coach-red)}

.cw-card{min-width:0;background:#fff;border:1px solid var(--coach-line);border-radius:11px;overflow:hidden}
.cw-card>header{min-height:54px;display:flex;align-items:center;justify-content:space-between;gap:14px;padding:12px 15px;border-bottom:1px solid #edf0f3}
.cw-card>header h2{display:flex;align-items:center;gap:8px;margin:0;color:var(--coach-ink);font-size:13.5px;font-weight:700}
.cw-card>header h2 svg{width:17px;height:17px;color:#37516b}
.cw-card>header p{margin:3px 0 0;color:var(--coach-muted);font-size:9.5px}
.cw-card>header>a{color:var(--coach-orange);text-decoration:none;font-size:10px;font-weight:700;white-space:nowrap}
.cw-dashboard-grid{display:grid;grid-template-columns:minmax(0,1.8fr) minmax(300px,.75fr);gap:13px;align-items:start}
.cw-card-clients{grid-row:span 2}
.cw-card-wide{grid-column:1/-1}
.cw-lower-grid{display:grid;grid-template-columns:1fr 1fr;gap:13px}

.cw-table-wrap{width:100%;overflow:auto}
.cw-table{width:100%;border-collapse:collapse;table-layout:auto;font-size:10.5px;color:#415169}
.cw-table th{padding:9px 12px;text-align:left;color:#6e7c8f;font-size:8.5px;font-weight:700;text-transform:uppercase;letter-spacing:.04em;background:#fafbfc;border-bottom:1px solid var(--coach-line);white-space:nowrap}
.cw-table td{padding:10px 12px;border-bottom:1px solid #edf0f3;vertical-align:middle;line-height:1.4}
.cw-table tbody tr:last-child td{border-bottom:0}
.cw-table tbody tr[data-client]{cursor:pointer}
.cw-table tbody tr[data-client]:hover,.cw-table tbody tr[data-client].selected{background:#f2f7ff}
.cw-table td>b{display:block;color:#263c54;font-size:10.5px}
.cw-table td>small{display:block;color:#8490a0;font-size:9px;margin-top:2px;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cw-client-cell{display:flex;align-items:center;gap:9px;min-width:145px}
.cw-client-cell>span:last-child{min-width:0}
.cw-client-cell b{display:block;color:#20344c;font-size:10.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-client-cell small{display:block;color:#7b8796;font-size:9px;margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-avatar{width:31px;height:31px;display:grid;place-items:center;flex:0 0 31px;border-radius:50%;background:#3768d7;color:#fff;font-size:9.5px;font-weight:750}
.cw-avatar.xl{width:50px;height:50px;flex-basis:50px;font-size:14px}
.cw-avatar.xxl{width:68px;height:68px;flex-basis:68px;font-size:22px;background:var(--coach-navy)}
.cw-pill{display:inline-flex;align-items:center;justify-content:center;min-width:48px;height:21px;padding:0 8px;border-radius:999px;font-size:8.5px;font-weight:750;text-transform:capitalize;white-space:nowrap;background:#edf0f3;color:#596779}
.cw-pill.green,.cw-pill.goal{background:#e8f7ef;color:#168251}
.cw-pill.amber,.cw-pill.commitment{background:#fff3df;color:#b66d00}
.cw-pill.red{background:#ffecee;color:#ca3542}
.cw-pill.blue,.cw-pill.session{background:#eaf1ff;color:#336dcc}
.cw-pill.purple{background:#f1edff;color:#674fd0}
.cw-pill.neutral,.cw-pill.item{background:#eff2f5;color:#607084}
.cw-mini-btn,.cw-row-action{height:28px;display:inline-flex;align-items:center;justify-content:center;padding:0 10px;border:1px solid #dfe4e9;border-radius:6px;background:#fff;color:#233a52;text-decoration:none;font-size:9.5px;font-weight:650;cursor:pointer}
.cw-row-action:hover,.cw-mini-btn:hover{border-color:#aeb9c4;background:#fafbfd}

.cw-empty{min-height:130px;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:22px;text-align:center;color:var(--coach-muted)}
.cw-empty-icon{width:28px!important;height:28px!important;margin-bottom:8px;color:#7d8da0}
.cw-empty strong{color:var(--coach-ink);font-size:12px}
.cw-empty p{max-width:430px;margin:5px 0 0;font-size:10.5px;line-height:1.5}
.cw-empty span{margin-top:7px;color:#9a6a3e;font-size:9.5px}

.cw-follow-list,.cw-activity-list{padding:4px 14px 10px}
.cw-follow-item{display:grid;grid-template-columns:auto minmax(0,1fr) auto auto;align-items:center;gap:9px;padding:10px 0;border-bottom:1px solid #edf0f3}
.cw-follow-item:last-child{border-bottom:0}
.cw-follow-item b,.cw-activity b{display:block;color:#263c54;font-size:10.5px}
.cw-follow-item small,.cw-activity small{display:block;margin-top:2px;color:#7c8999;font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-follow-item a{color:var(--coach-orange);text-decoration:none;font-size:9.5px;font-weight:700;white-space:nowrap}
.cw-activity{display:grid;grid-template-columns:auto minmax(0,1fr) auto auto;align-items:center;gap:10px;padding:9px 0;border-bottom:1px solid #edf0f3}
.cw-activity:last-child{border-bottom:0}
.cw-activity time{color:#8390a0;font-size:8.5px;white-space:nowrap}
.cw-activity-dot{width:27px;height:27px;display:grid;place-items:center;border-radius:50%;background:#edf3ff;color:var(--coach-blue)}
.cw-activity-dot svg{width:14px;height:14px}
.cw-activity-dot.commitment{background:#eaf8f0;color:var(--coach-green)}
.cw-activity-dot.session{background:#f1edff;color:var(--coach-purple)}
.cw-quick-actions{min-height:54px;display:flex;align-items:center;gap:10px;padding:8px 13px;background:#fff;border:1px solid var(--coach-line);border-radius:11px;overflow:auto}
.cw-quick-actions b{display:flex;align-items:center;gap:7px;margin-right:5px;font-size:11px;white-space:nowrap}
.cw-quick-actions a{height:34px;display:inline-flex;align-items:center;padding:0 14px;border:1px solid #e0e5ea;border-radius:7px;color:#31475e;text-decoration:none;font-size:9.5px;font-weight:650;white-space:nowrap}

.cw-filterbar{min-height:46px;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:6px 8px;background:#fff;border:1px solid var(--coach-line);border-radius:10px}
.cw-filterbar>span{padding-right:8px;color:#7b8797;font-size:9.5px}
.cw-filterchips{display:flex;align-items:center;gap:7px;overflow:auto}
.cw-filterchips button,.cw-settings-tabs button,.cw-report-range button{height:31px;padding:0 13px;border:1px solid #e0e5eb;border-radius:7px;background:#fff;color:#42546a;font-size:9.5px;font-weight:650;white-space:nowrap;cursor:pointer}
.cw-filterchips button.on,.cw-settings-tabs button.on,.cw-report-range button.on{border-color:var(--coach-orange);color:var(--coach-orange);background:#fff8f3}
.cw-filterchips b{display:inline-grid;place-items:center;min-width:18px;height:18px;margin-left:4px;border-radius:50%;background:#edf0f4;font-size:8px}
.cw-client-layout{display:grid;grid-template-columns:minmax(0,1fr) 310px;gap:13px;align-items:start}
.cw-client-table-card{overflow:hidden}
.cw-client-preview{background:#fff;border:1px solid var(--coach-line);border-radius:11px;overflow:hidden}
.cw-client-preview>header{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:11px;padding:15px;border-bottom:1px solid #edf0f3}
.cw-client-preview h2{margin:0;font-size:14px;color:var(--coach-ink)}
.cw-client-preview header p{margin:3px 0 0;color:#778597;font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-preview-badges{display:flex;gap:6px;padding:10px 14px;border-bottom:1px solid #edf0f3}
.cw-preview-badges span{padding:5px 7px;border:1px solid #e4e8ec;border-radius:999px;color:#5e6e82;font-size:8px}
.cw-client-preview section{padding:13px 14px;border-bottom:1px solid #edf0f3}
.cw-client-preview section h3{margin:0 0 9px;color:#344a61;font-size:9px;text-transform:uppercase;letter-spacing:.05em}
.cw-stat-row{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.cw-stat-row span{padding:8px 5px;border:1px solid #e7ebef;border-radius:7px;text-align:center;color:#718095;font-size:8px}
.cw-stat-row b{display:block;margin-top:3px;color:var(--coach-ink);font-size:15px}
.cw-preview-highlight{padding:10px;background:#f7f9fb;border:1px solid #e5e9ed;border-radius:8px}
.cw-preview-highlight b{font-size:10.5px;color:#263b52}
.cw-preview-highlight p{margin:5px 0;color:#627286;font-size:9px;line-height:1.45}
.cw-preview-highlight time,.cw-preview-share time{font-size:8px;color:#8793a2}
.cw-preview-share{display:flex;gap:8px;padding:8px 0;border-bottom:1px solid #edf0f3}
.cw-preview-share:last-child{border-bottom:0}
.cw-preview-share>div{min-width:0}
.cw-preview-share b{display:block;font-size:9.5px;color:#2b4057}
.cw-preview-share small{display:block;margin:2px 0;color:#748294;font-size:8.5px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.cw-client-preview footer{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:13px}
.cw-primary-btn,.cw-secondary-btn{height:35px;display:inline-flex;align-items:center;justify-content:center;border-radius:7px;text-decoration:none;font-size:9.5px;font-weight:700;cursor:pointer}
.cw-primary-btn{border:1px solid var(--coach-orange);background:var(--coach-orange);color:#fff}
.cw-primary-btn:disabled{opacity:.45;cursor:not-allowed}
.cw-secondary-btn{border:1px solid #dfe4e9;background:#fff;color:#273d54}
.cw-primary-btn.full,.cw-secondary-btn.full{width:100%;margin-top:10px}
.cw-boundary-list{display:flex;flex-direction:column;gap:10px;padding:15px}
.cw-boundary-list span{display:flex;align-items:center;gap:8px;color:#526277;font-size:10px}
.cw-boundary-list svg{width:15px;height:15px;color:var(--coach-green)}

.cw-follow-layout,.cw-risk-layout,.cw-exercise-layout{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(285px,.65fr);gap:13px;align-items:start}
.cw-agenda,.cw-selected-alert{min-height:330px}
.cw-checklist{display:flex;flex-direction:column;gap:9px;padding:14px 16px}
.cw-checklist span{display:flex;align-items:center;gap:8px;color:#526277;font-size:10px}
.cw-checklist svg{width:15px;height:15px;color:#8c9aaa}

.cw-exercise-list{padding:2px 14px 8px}
.cw-exercise-item{display:grid;grid-template-columns:auto minmax(130px,.8fr) 55px minmax(150px,1fr) auto;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid #edf0f3}
.cw-exercise-item:last-child{border-bottom:0}
.cw-template-icon{width:34px;height:34px;display:grid;place-items:center;border-radius:9px;background:#edf3ff;color:var(--coach-blue)}
.cw-template-icon.t2{background:#f1edff;color:var(--coach-purple)}
.cw-template-icon.t3{background:#fff3df;color:var(--coach-amber)}
.cw-template-icon.t4{background:#eaf8f0;color:var(--coach-green)}
.cw-exercise-item b{display:block;font-size:10.5px;color:#263b53}
.cw-exercise-item small{display:block;margin-top:3px;color:#6b75ca;font-size:8.5px}
.cw-exercise-item time{font-size:9px;color:#53647a}
.cw-exercise-item p{margin:0;color:#69788c;font-size:9px;line-height:1.4}
.cw-exercise-item button{height:28px;padding:0 10px;border:1px solid #e0e5ea;border-radius:6px;background:#fff;color:#768294;font-size:9px}

.cw-report-range{display:flex;justify-content:flex-end;gap:0}
.cw-report-range button{border-radius:0;border-right:0}
.cw-report-range button:first-child{border-radius:7px 0 0 7px}
.cw-report-range button:last-child{border-radius:0 7px 7px 0;border-right:1px solid #e0e5eb}
.cw-report-grid{display:grid;grid-template-columns:1.15fr .85fr .75fr;gap:13px}
.cw-chart-card,.cw-donut-card,.cw-insights{min-height:280px}
.cw-bar-chart{padding:14px 16px}
.cw-bar-chart>div{display:grid;grid-template-columns:105px minmax(80px,1fr) 24px;align-items:center;gap:9px;margin-bottom:14px}
.cw-bar-chart>div:last-child{margin-bottom:0}
.cw-bar-chart span{font-size:9px;color:#47596e;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-bar-chart i{height:8px;background:#edf0f4;border-radius:999px;overflow:hidden}
.cw-bar-chart i b{display:block;height:100%;background:var(--coach-purple);border-radius:999px}
.cw-bar-chart strong{font-size:9px;color:#31465c;text-align:right}
.cw-distribution{display:flex;align-items:center;justify-content:center;gap:24px;padding:22px 12px}
.cw-donut{width:128px;height:128px;display:grid;place-items:center;align-content:center;border-radius:50%;background:conic-gradient(var(--coach-purple) 0 calc(var(--goal)*1%),var(--coach-green) calc(var(--goal)*1%) calc((var(--goal) + var(--commit))*1%),#4e8be8 calc((var(--goal) + var(--commit))*1%) 100%);position:relative}
.cw-donut::after{content:"";position:absolute;inset:25px;background:#fff;border-radius:50%}
.cw-donut strong,.cw-donut span{position:relative;z-index:1}
.cw-donut strong{font-size:23px;color:var(--coach-ink)}
.cw-donut span{font-size:8px;color:#758296}
.cw-legend{display:flex;flex-direction:column;gap:10px}
.cw-legend span{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:7px;color:#56667a;font-size:9px}
.cw-legend i{width:8px;height:8px;border-radius:50%;background:var(--coach-purple)}
.cw-legend i.commitment{background:var(--coach-green)}
.cw-legend i.session{background:#4e8be8}
.cw-insight-list{padding:12px 15px}
.cw-insight-list>div{padding:9px 0;border-bottom:1px solid #edf0f3}
.cw-insight-list>div:last-child{border-bottom:0}
.cw-insight-list b{font-size:10px;color:#2d4259}
.cw-insight-list p{margin:4px 0 0;color:#718095;font-size:9px;line-height:1.45}

.cw-settings-tabs{display:flex;gap:18px;padding:0 12px;background:#fff;border:1px solid var(--coach-line);border-radius:10px}
.cw-settings-tabs button{height:43px;padding:0 4px;border:0;border-radius:0;background:transparent;position:relative}
.cw-settings-tabs button.on::after{content:"";position:absolute;left:0;right:0;bottom:-1px;height:2px;background:var(--coach-orange)}
.cw-settings-layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:13px;align-items:start}
.cw-settings-layout main,.cw-settings-layout aside{display:flex;flex-direction:column;gap:13px}
.cw-profile-card{display:flex;align-items:center;gap:14px;padding:15px}
.cw-profile-card>div{min-width:0;flex:1}
.cw-profile-card h2{margin:0;font-size:15px;color:var(--coach-ink)}
.cw-profile-card p{margin:4px 0;color:#65758a;font-size:10px}
.cw-profile-card small{color:#8793a2;font-size:9px}
.cw-setting-rows{padding:3px 15px 10px}
.cw-setting-rows>div{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 0;border-bottom:1px solid #edf0f3}
.cw-setting-rows>div:last-child{border-bottom:0}
.cw-setting-rows b{display:block;font-size:10px;color:#30455c}
.cw-setting-rows small{display:block;margin-top:2px;color:#8390a0;font-size:8.5px}
.cw-switch{width:34px;height:19px;display:block;border-radius:999px;background:#d9dee4;position:relative}
.cw-switch::after{content:"";position:absolute;top:3px;left:3px;width:13px;height:13px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.12)}
.cw-switch.on{background:var(--coach-orange)}
.cw-switch.on::after{left:18px}
.cw-pref-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;padding:14px}
.cw-pref-grid label{padding:10px;border:1px solid #e4e8ed;border-radius:7px;color:#758296;font-size:8.5px}
.cw-pref-grid strong{display:block;margin-top:5px;color:#30455c;font-size:10px}
.cw-account-list{display:flex;flex-direction:column;gap:0;padding:4px 14px 12px}
.cw-account-list>span{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 0;border-bottom:1px solid #edf0f3;color:#66768a;font-size:9.5px}
.cw-account-list>span:last-child{border-bottom:0}
.cw-account-list b{color:#293f56}

.cw-help-search{height:48px;display:flex;align-items:center;gap:10px;padding:0 16px;background:#fff;border:1px solid var(--coach-line);border-radius:9px;color:#718094}
.cw-help-search input{width:100%;height:100%;border:0;outline:0;background:transparent;color:var(--coach-ink);font:inherit;font-size:11px}
.cw-help-categories{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:9px}
.cw-help-categories article{min-width:0;display:flex;align-items:center;gap:9px;padding:12px;background:#fff;border:1px solid var(--coach-line);border-radius:9px}
.cw-help-categories article>svg{width:26px;height:26px;padding:5px;border-radius:8px;background:#edf3ff;color:var(--coach-blue);box-sizing:content-box}
.cw-help-categories b{display:block;font-size:9.5px;color:#2d4259;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-help-categories small{display:block;margin-top:3px;color:#7e8a9a;font-size:7.8px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.cw-help-layout{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:13px;align-items:start}
.cw-help-layout main,.cw-help-layout aside{display:flex;flex-direction:column;gap:13px}
.cw-help-articles{display:grid;grid-template-columns:1fr 1fr;gap:9px;padding:13px}
.cw-help-articles a{position:relative;display:flex;flex-direction:column;min-height:78px;padding:12px 65px 12px 12px;border:1px solid #e3e8ed;border-radius:8px;text-decoration:none}
.cw-help-articles b{font-size:10.5px;color:#2b4058}
.cw-help-articles span{margin-top:5px;color:#718095;font-size:9px;line-height:1.4}
.cw-help-articles em{position:absolute;right:12px;top:50%;transform:translateY(-50%);color:var(--coach-orange);font-size:9px;font-style:normal;font-weight:700}
.cw-help-page details{border-bottom:1px solid #edf0f3;margin:0 14px}
.cw-help-page details:last-child{border-bottom:0}
.cw-help-page summary{padding:11px 0;color:#334a61;font-size:10px;font-weight:650;cursor:pointer}
.cw-help-page details p{margin:0 0 11px;color:#718095;font-size:9px;line-height:1.5}
.cw-support-options{padding:2px 14px}
.cw-support-options a{display:block;padding:11px 0;border-bottom:1px solid #edf0f3;text-decoration:none}
.cw-support-options b{display:block;color:#30465d;font-size:10px}
.cw-support-options span{display:block;margin-top:3px;color:#7b8898;font-size:8.5px}
.cw-help-note{margin:0;padding:14px;color:#66768a;font-size:9.5px;line-height:1.55}

@media(max-width:1320px){
  body.coach-ui-v2{--sidebar-w:220px}
  .cw-kpi-grid.six{grid-template-columns:repeat(3,minmax(0,1fr))}
  .cw-help-categories{grid-template-columns:repeat(4,minmax(0,1fr))}
  .coach-global-search{width:225px}
}
@media(max-width:1100px){
  body.coach-ui-v2{--sidebar-w:68px}
  body.coach-ui-v2 .sidebar{padding-left:8px;padding-right:8px}
  body.coach-ui-v2 .sidebar-help{display:none}
  .coach-global-search{display:none}
  .cw-kpi-grid.five{grid-template-columns:repeat(3,minmax(0,1fr))}
  .cw-dashboard-grid,.cw-client-layout,.cw-follow-layout,.cw-risk-layout,.cw-exercise-layout,.cw-settings-layout,.cw-help-layout{grid-template-columns:1fr}
  .cw-card-clients{grid-row:auto}
  .cw-report-grid{grid-template-columns:1fr 1fr}
  .cw-insights{grid-column:1/-1}
}
@media(max-width:900px){
  body.coach-ui-v2 .main{padding-bottom:70px}
  .coach-workspace-v2{padding:10px 10px 85px}
  .cw-kpi-grid.six,.cw-kpi-grid.five,.cw-kpi-grid.four{display:flex;overflow:auto;gap:8px}
  .cw-kpi-v2{min-width:180px}
  .cw-dashboard-grid,.cw-lower-grid,.cw-report-grid{display:block}
  .cw-dashboard-grid>.cw-card,.cw-lower-grid>.cw-card,.cw-report-grid>.cw-card{margin-bottom:10px}
  .cw-help-categories{display:flex;overflow:auto}
  .cw-help-categories article{min-width:170px}
  .cw-help-articles{grid-template-columns:1fr}
  .cw-client-preview{margin-top:10px}
  .cw-filterbar{align-items:flex-start;flex-direction:column}
  .cw-filterbar>span{padding:0 6px 5px}
  .cw-exercise-item{grid-template-columns:auto 1fr auto}
  .cw-exercise-item p{grid-column:2/-1}
  .cw-exercise-item button{display:none}
}
@media print{
  body.coach-ui-v2 .sidebar,body.coach-ui-v2 .utility-header,body.coach-ui-v2 .cw-privacy-foot{display:none!important}
  body.coach-ui-v2 .main{grid-column:1!important}
  .coach-workspace-v2{padding:0}
  .cw-card,.cw-kpi-v2{break-inside:avoid}
}

/* ========================================================================== 
   v19.1 — Coach typography matched to Client UI
   Font-size only. No layout, logic, sync, auth, API, storage or backend changes.
   ========================================================================== */
body.coach-ui-v2 .brand-name{font-size:20px}
body.coach-ui-v2 .sidebar-help strong{font-size:13px}
body.coach-ui-v2 .sidebar-help p{font-size:12px}
body.coach-ui-v2 .header-title h1{font-size:23px}
body.coach-ui-v2 .header-title p{font-size:12px}
body.coach-ui-v2 .coach-role-badge{font-size:11px}
.coach-global-search input{font-size:12px}

.coach-workspace-v2{font-size:12.5px}
.cw-load-error strong{font-size:16px}
.cw-load-error p,.cw-load-error span{font-size:12.5px}
.cw-privacy-foot{font-size:12px}

.cw-kpi-v2 span:not(.cw-kpi-icon){font-size:11px}
.cw-kpi-v2 strong{font-size:20px}
.cw-kpi-v2 small{font-size:10.5px}

.cw-card>header h2{font-size:16px}
.cw-card>header p{font-size:12px}
.cw-card>header>a{font-size:12px}

.cw-table{font-size:12.5px}
.cw-table th{font-size:11.5px}
.cw-table td>b{font-size:13px}
.cw-table td>small{font-size:11px}
.cw-client-cell b{font-size:13px}
.cw-client-cell small{font-size:11px}
.cw-avatar{font-size:10.5px}
.cw-avatar.xl{font-size:14px}
.cw-avatar.xxl{font-size:22px}
.cw-pill{font-size:11px}
.cw-mini-btn,.cw-row-action{font-size:12px}

.cw-empty strong{font-size:14px}
.cw-empty p{font-size:12.5px}
.cw-empty span{font-size:11px}
.cw-follow-item b,.cw-activity b{font-size:12.5px}
.cw-follow-item small,.cw-activity small{font-size:11px}
.cw-follow-item a{font-size:12px}
.cw-activity time{font-size:10.5px}

.cw-quick-actions b{font-size:12.5px}
.cw-quick-actions a{font-size:12px}
.cw-filterbar>span{font-size:12px}
.cw-filterchips button,.cw-settings-tabs button,.cw-report-range button{font-size:12px}
.cw-filterchips b{font-size:10px}

.cw-client-preview h2{font-size:16px}
.cw-client-preview header p{font-size:11px}
.cw-preview-badges span{font-size:10.5px}
.cw-client-preview section h3{font-size:11px}
.cw-stat-row span{font-size:10.5px}
.cw-stat-row b{font-size:17px}
.cw-preview-highlight b{font-size:12.5px}
.cw-preview-highlight p{font-size:11px}
.cw-preview-highlight time,.cw-preview-share time{font-size:10px}
.cw-preview-share b{font-size:12px}
.cw-preview-share small{font-size:10.5px}
.cw-primary-btn,.cw-secondary-btn{font-size:12px}
.cw-boundary-list span,.cw-checklist span{font-size:12px}

.cw-exercise-item b{font-size:12.5px}
.cw-exercise-item small{font-size:10.5px}
.cw-exercise-item time{font-size:10.5px}
.cw-exercise-item p{font-size:11px}
.cw-exercise-item button{font-size:11.5px}

.cw-bar-chart span,.cw-bar-chart strong{font-size:10.5px}
.cw-donut strong{font-size:20px}
.cw-donut span{font-size:10px}
.cw-legend span{font-size:11px}
.cw-insight-list b{font-size:12.5px}
.cw-insight-list p{font-size:11px}

.cw-profile-card h2{font-size:16px}
.cw-profile-card p{font-size:12px}
.cw-profile-card small{font-size:11px}
.cw-setting-rows b{font-size:12.5px}
.cw-setting-rows small{font-size:11px}
.cw-pref-grid label{font-size:11px}
.cw-pref-grid strong{font-size:12.5px}
.cw-account-list>span{font-size:12px}

.cw-help-search input{font-size:12.5px}
.cw-help-categories b{font-size:12.5px}
.cw-help-categories small{font-size:10.5px}
.cw-help-articles b{font-size:12.5px}
.cw-help-articles span{font-size:11px}
.cw-help-articles em{font-size:11px}
.cw-help-page summary{font-size:12.5px}
.cw-help-page details p{font-size:11px}
.cw-support-options b{font-size:12.5px}
.cw-support-options span{font-size:11px}
.cw-help-note{font-size:11px}

/* ========================================================================== 
   v20 — Coach UI compact implementation
   UI-only update. No backend, database, sync, auth or API logic changed.
   Focus: denser layouts, reduced empty space, client-matched typography.
   ========================================================================== */
body.coach-ui-v2 .utility-header{height:74px;padding:0 20px 0 24px}
body.coach-ui-v2 .header-title{min-width:240px}
body.coach-ui-v2 .header-title h1{font-size:22px}
body.coach-ui-v2 .header-title p{margin-top:4px}
.coach-header-tools{gap:10px}
.coach-global-search{height:36px;width:260px;border-radius:10px}
.coach-header-cta{height:36px!important;padding:0 14px!important}

.coach-workspace-v2{padding:16px 20px 20px}
.coach-page{gap:12px}
.cw-loading-v2,.cw-load-error{min-height:300px;border-radius:14px}
.cw-privacy-foot{margin-top:10px;padding:0 2px}

.cw-kpi-grid{gap:10px}
.cw-kpi-v2{min-height:86px;padding:12px 14px;border-radius:14px;box-shadow:0 1px 2px rgba(16,35,62,.04)}
.cw-kpi-icon{width:42px;height:42px;border-radius:12px}
.cw-kpi-v2 strong{margin-top:3px}
.cw-kpi-v2 small{margin-top:5px;line-height:1.3;white-space:normal}

.cw-card{border-radius:14px;box-shadow:0 1px 2px rgba(16,35,62,.04)}
.cw-card>header{min-height:50px;padding:11px 14px}
.cw-card>header h2{font-size:15px}
.cw-card>header p{margin-top:2px;line-height:1.35}
.cw-card>header>a{font-size:11.5px}

.cw-dashboard-grid{grid-template-columns:minmax(0,1.75fr) minmax(320px,.95fr);gap:12px}
.cw-card-clients{grid-row:span 2}
.cw-card-wide{grid-column:1/-1}
.cw-lower-grid,.cw-client-layout,.cw-follow-layout,.cw-risk-layout,.cw-exercise-layout,.cw-settings-layout,.cw-help-layout,.cw-report-grid{gap:12px}

.cw-table{font-size:12px}
.cw-table th{padding:9px 11px;background:#fbfcfd}
.cw-table td{padding:10px 11px}
.cw-table td>small,.cw-client-cell small,.cw-follow-item small,.cw-activity small,.cw-preview-highlight p,.cw-preview-share small,.cw-insight-list p,.cw-help-note{line-height:1.4}
.cw-client-cell{gap:10px}
.cw-avatar{width:32px;height:32px;flex-basis:32px}
.cw-pill{height:22px;padding:0 9px}
.cw-mini-btn,.cw-row-action,.cw-primary-btn,.cw-secondary-btn{border-radius:8px}

.cw-empty{min-height:96px;padding:16px 18px}
.cw-empty p{margin-top:4px;max-width:420px}
.cw-empty span{margin-top:5px}

.cw-follow-list,.cw-activity-list,.cw-exercise-list,.cw-bar-chart,.cw-insight-list{padding-left:14px;padding-right:14px}
.cw-follow-item,.cw-activity{padding:10px 0}
.cw-activity-dot{width:28px;height:28px}
.cw-activity-dot.red{background:#fff0f1;color:var(--coach-red)}
.cw-activity-dot.amber{background:#fff5e5;color:var(--coach-amber)}
.cw-activity-dot.green{background:#eaf8f0;color:var(--coach-green)}
.cw-activity-dot.purple{background:#f1edff;color:var(--coach-purple)}
.cw-quick-actions{min-height:48px;padding:8px 12px;border-radius:14px}
.cw-quick-actions a{height:32px;padding:0 12px}

.cw-filterbar{min-height:44px;padding:7px 10px;border-radius:12px}
.cw-filterchips{gap:6px;flex-wrap:wrap}
.cw-filterchips button,.cw-settings-tabs button,.cw-report-range button{height:30px;padding:0 12px}
.cw-filterchips b{min-width:18px;height:18px}

.cw-client-preview{border-radius:14px}
.cw-client-preview>header{padding:14px}
.cw-preview-badges{padding:9px 14px;gap:6px;flex-wrap:wrap}
.cw-preview-badges span{padding:5px 8px}
.cw-client-preview section{padding:12px 14px}
.cw-stat-row{gap:8px}
.cw-stat-row span{padding:9px 7px}
.cw-preview-highlight{padding:10px 11px;border-radius:10px}
.cw-preview-share{padding:8px 0}
.cw-client-preview footer{padding:12px 14px;gap:8px}

.cw-follow-detail .cw-side-detail{padding:14px}
.cw-side-person{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:10px;padding-bottom:12px;border-bottom:1px solid #edf0f3}
.cw-side-person h3{margin:0;font-size:15px;color:var(--coach-ink)}
.cw-side-person p{margin:4px 0 0;color:#6f7e91;font-size:11px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cw-detail-meta{display:grid;grid-template-columns:1fr;gap:10px;padding:12px 0}
.cw-detail-meta span{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;padding-bottom:10px;border-bottom:1px solid #edf0f3;color:#607084;font-size:11px}
.cw-detail-meta span:last-child{padding-bottom:0;border-bottom:0}
.cw-detail-meta b{color:#2c4159;font-size:12px}
.cw-detail-meta em{font-style:normal;color:#6f7e91;text-align:right}
.cw-detail-block{padding:12px 0;border-top:1px solid #edf0f3}
.cw-detail-block:first-of-type{border-top:0}
.cw-detail-block header{margin-bottom:8px}
.cw-detail-block h4{margin:0;color:#2c4159;font-size:12.5px}
.cw-detail-block p{margin:0;color:#68788b;font-size:11px;line-height:1.5}
.cw-progress-mini{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:start;padding:10px 12px;background:#f7f9fb;border:1px solid #e7ebef;border-radius:10px}
.cw-progress-mini b{display:block;color:#243850;font-size:12px}
.cw-progress-mini small{display:block;margin-top:4px;color:#708094;font-size:10.5px;line-height:1.45}
.cw-progress-mini strong{display:grid;place-items:center;min-width:34px;height:34px;border-radius:10px;background:#eef3ff;color:var(--coach-blue);font-size:12px}
.cw-detail-actions{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding-top:12px;border-top:1px solid #edf0f3}
.cw-detail-actions .cw-primary-btn,.cw-detail-actions .cw-secondary-btn{width:100%;margin-top:0}

.cw-outcome-list{padding:8px 14px 12px}
.cw-outcome-item{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:10px;align-items:flex-start;padding:10px 0;border-bottom:1px solid #edf0f3}
.cw-outcome-item:last-child{border-bottom:0}
.cw-outcome-item b{display:block;font-size:12px;color:#263c54}
.cw-outcome-item small{display:block;margin-top:2px;color:#6d7c8f;font-size:11px}
.cw-outcome-item p{margin:5px 0 0;color:#7b8899;font-size:10.5px;line-height:1.45}
.cw-outcome-item time{color:#8793a2;font-size:10px;white-space:nowrap}

.cw-agenda,.cw-selected-alert,.cw-chart-card,.cw-donut-card,.cw-insights{min-height:auto}
.cw-checklist{padding:14px}
.cw-checklist span{align-items:flex-start}
.cw-exercise-item{padding:10px 0}
.cw-template-icon{width:36px;height:36px;border-radius:10px}
.cw-exercise-item button{height:30px}

.cw-bar-chart>div{margin-bottom:12px}
.cw-distribution{padding:18px 14px;gap:18px}
.cw-donut{width:120px;height:120px}
.cw-donut::after{inset:24px}
.cw-help-search{height:46px;border-radius:12px}
.cw-help-categories article{padding:12px;border-radius:12px}
.cw-help-articles{gap:10px;padding:12px 14px 14px}
.cw-help-articles a{min-height:76px;border-radius:10px}
.cw-support-options{padding:2px 14px 10px}
.cw-support-options a{padding:10px 0}

@media(max-width:1320px){
  .cw-dashboard-grid{grid-template-columns:1fr 340px}
}
@media(max-width:1100px){
  .cw-dashboard-grid,.cw-client-layout,.cw-follow-layout,.cw-risk-layout,.cw-exercise-layout,.cw-settings-layout,.cw-help-layout,.cw-report-grid{grid-template-columns:1fr}
  .cw-detail-actions{grid-template-columns:1fr}
}
@media(max-width:900px){
  .coach-workspace-v2{padding:10px 10px 82px}
  .cw-kpi-v2{min-width:188px}
  .cw-quick-actions{display:grid;grid-auto-flow:column;grid-auto-columns:max-content;overflow:auto}
}

/* ========================================================================== 
   v22 — Coach layout fit corrections
   UI-only: remove unnecessary horizontal tracking and use full available width.
   Typography intentionally unchanged from v21.
   ========================================================================== */

/* Dashboard: Risk Queue Snapshot was removed from UI, so Priority Follow-ups
   and Recent Client Activity now use the full content width. */
.cw-dashboard-page .cw-dashboard-grid{
  grid-template-columns:minmax(0,1fr);
}
.cw-dashboard-page .cw-card-clients{
  grid-row:auto;
}
.cw-dashboard-page .cw-card-wide{
  grid-column:auto;
}
.cw-dashboard-page .cw-card-clients .cw-table-wrap{
  overflow-x:hidden;
}
.cw-dashboard-page .cw-card-clients .cw-table{
  width:100%;
  table-layout:fixed;
}
.cw-dashboard-page .cw-card-clients .cw-table th,
.cw-dashboard-page .cw-card-clients .cw-table td{
  padding-left:9px;
  padding-right:9px;
}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(1),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(1){width:23%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(2),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(2){width:28%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(3),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(3){width:7%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(4),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(4){width:11%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(5),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(5){width:9%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(6),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(6){width:13%}
.cw-dashboard-page .cw-card-clients .cw-table th:nth-child(7),
.cw-dashboard-page .cw-card-clients .cw-table td:nth-child(7){width:9%}

/* Clients: keep selected-client detail panel and fit all table columns on
   desktop without horizontal dragging. Risk column is no longer shown. */
.cw-clients-page .cw-client-layout{
  grid-template-columns:minmax(0,1fr) 300px;
  align-items:start;
}
.cw-clients-page .cw-client-table-card .cw-table-wrap{
  overflow-x:hidden;
}
.cw-clients-page .cw-client-table{
  width:100%;
  table-layout:fixed;
}
.cw-clients-page .cw-client-table th,
.cw-clients-page .cw-client-table td{
  padding-left:7px;
  padding-right:7px;
}
.cw-clients-page .cw-client-table th:nth-child(1),
.cw-clients-page .cw-client-table td:nth-child(1){width:24%}
.cw-clients-page .cw-client-table th:nth-child(2),
.cw-clients-page .cw-client-table td:nth-child(2){width:9%}
.cw-clients-page .cw-client-table th:nth-child(3),
.cw-clients-page .cw-client-table td:nth-child(3){width:20%}
.cw-clients-page .cw-client-table th:nth-child(4),
.cw-clients-page .cw-client-table td:nth-child(4){width:7%}
.cw-clients-page .cw-client-table th:nth-child(5),
.cw-clients-page .cw-client-table td:nth-child(5){width:11%}
.cw-clients-page .cw-client-table th:nth-child(6),
.cw-clients-page .cw-client-table td:nth-child(6){width:9%}
.cw-clients-page .cw-client-table th:nth-child(7),
.cw-clients-page .cw-client-table td:nth-child(7){width:11%}
.cw-clients-page .cw-client-table th:nth-child(8),
.cw-clients-page .cw-client-table td:nth-child(8){width:9%}
.cw-clients-page .cw-client-table td:not(:first-child){
  overflow:hidden;
  text-overflow:ellipsis;
}
.cw-clients-page .cw-client-preview{
  min-width:0;
}

@media(max-width:1180px){
  .cw-clients-page .cw-client-layout{
    grid-template-columns:1fr;
  }
  .cw-clients-page .cw-client-table-card .cw-table-wrap{
    overflow-x:auto;
  }
  .cw-clients-page .cw-client-table{
    min-width:760px;
  }
}

/* ========================================================================== 
   v23 — Client table readability + vertical-space cleanup
   UI-only. Typography scale is unchanged.
   ========================================================================== */

/* Keep the client list readable without horizontal dragging. The redundant
   Latest Type column is merged into Latest Activity in the rendered UI. */
.cw-clients-page .cw-client-layout{
  grid-template-columns:minmax(0,1fr) 340px;
  align-items:start;
}
.cw-clients-page .cw-client-main-stack{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:12px;
}
.cw-clients-page .cw-client-table-card .cw-table-wrap{
  overflow-x:hidden;
}
.cw-clients-page .cw-client-table{
  width:100%;
  min-width:0;
  table-layout:fixed;
}
.cw-clients-page .cw-client-table th,
.cw-clients-page .cw-client-table td{
  padding-left:8px;
  padding-right:8px;
}
.cw-clients-page .cw-client-table th{
  white-space:nowrap;
  overflow:visible;
  text-overflow:clip;
}
.cw-clients-page .cw-client-table th:nth-child(1),
.cw-clients-page .cw-client-table td:nth-child(1){width:23%}
.cw-clients-page .cw-client-table th:nth-child(2),
.cw-clients-page .cw-client-table td:nth-child(2){width:30%}
.cw-clients-page .cw-client-table th:nth-child(3),
.cw-clients-page .cw-client-table td:nth-child(3){width:7%}
.cw-clients-page .cw-client-table th:nth-child(4),
.cw-clients-page .cw-client-table td:nth-child(4){width:12%}
.cw-clients-page .cw-client-table th:nth-child(5),
.cw-clients-page .cw-client-table td:nth-child(5){width:9%}
.cw-clients-page .cw-client-table th:nth-child(6),
.cw-clients-page .cw-client-table td:nth-child(6){width:11%}
.cw-clients-page .cw-client-table th:nth-child(7),
.cw-clients-page .cw-client-table td:nth-child(7){width:8%}
.cw-clients-page .cw-client-table td:not(:first-child){
  overflow:hidden;
  text-overflow:ellipsis;
}
.cw-clients-page .cw-client-table td:nth-child(2) small{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.cw-clients-page .cw-client-recent{
  margin:0;
}
.cw-clients-page #cwDetail{
  min-width:0;
}
.cw-clients-page .cw-assignment-boundary-full{
  width:100%;
}
.cw-clients-page .cw-assignment-boundary-full .cw-boundary-list{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:10px 18px;
  padding:14px 16px;
}
.cw-clients-page .cw-assignment-boundary-full .cw-boundary-list span{
  margin:0;
}

@media(max-width:1240px){
  .cw-clients-page .cw-client-layout{grid-template-columns:1fr}
  .cw-clients-page #cwDetail{order:2}
  .cw-clients-page .cw-client-main-stack{order:1}
  .cw-clients-page .cw-client-table-card .cw-table-wrap{overflow-x:auto}
  .cw-clients-page .cw-client-table{min-width:760px}
}
@media(max-width:900px){
  .cw-clients-page .cw-assignment-boundary-full .cw-boundary-list{grid-template-columns:1fr}
}

/* ========================================================================== 
   v24 — Coach Clients table + header alignment polish
   UI-only. Font sizes and backend/data logic are unchanged.
   ========================================================================== */

/* Header: keep Prepare Session, coach identity and account controls separated. */
body.coach-ui-v2 .utility-header{
  gap:10px;
  padding-left:22px;
  padding-right:18px;
}
body.coach-ui-v2 .header-title{
  flex:0 1 430px;
  min-width:250px;
}
body.coach-ui-v2 .utility-header>.spacer{
  min-width:8px;
}
body.coach-ui-v2 .primary-slot{
  flex:0 1 auto;
  overflow:visible;
}
.coach-header-tools{
  gap:8px;
  min-width:0;
}
.coach-global-search{
  width:230px;
  max-width:230px;
  flex:0 1 230px;
}
.coach-header-cta{
  min-width:132px;
  max-width:132px;
  flex:0 0 132px;
  overflow:hidden;
  text-overflow:ellipsis;
}
body.coach-ui-v2 .profile{
  flex:0 0 auto;
  gap:7px;
  margin-left:2px;
}
body.coach-ui-v2 .profile .avatar{
  width:32px;
  height:32px;
  flex:0 0 32px;
}
body.coach-ui-v2 .auth-account,
body.coach-ui-v2 .coach-role-badge{
  flex:0 0 auto;
}

/* Clients table: explicit widths and spacing so every heading is readable. */
.cw-clients-page .cw-client-layout{
  grid-template-columns:minmax(0,1fr) 320px;
}
.cw-clients-page .cw-client-table{
  width:100%;
  table-layout:fixed;
}
.cw-clients-page .cw-client-table th,
.cw-clients-page .cw-client-table td{
  box-sizing:border-box;
  padding-left:9px;
  padding-right:9px;
}
.cw-clients-page .cw-client-table th{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:clip;
}
.cw-clients-page .cw-client-table th:nth-child(1),
.cw-clients-page .cw-client-table td:nth-child(1){width:22%}
.cw-clients-page .cw-client-table th:nth-child(2),
.cw-clients-page .cw-client-table td:nth-child(2){width:28%}
.cw-clients-page .cw-client-table th:nth-child(3),
.cw-clients-page .cw-client-table td:nth-child(3){width:7%}
.cw-clients-page .cw-client-table th:nth-child(4),
.cw-clients-page .cw-client-table td:nth-child(4){width:14%}
.cw-clients-page .cw-client-table th:nth-child(5),
.cw-clients-page .cw-client-table td:nth-child(5){width:10%}
.cw-clients-page .cw-client-table th:nth-child(6),
.cw-clients-page .cw-client-table td:nth-child(6){width:9%}
.cw-clients-page .cw-client-table th:nth-child(7),
.cw-clients-page .cw-client-table td:nth-child(7){width:10%}

/* Numeric/status/action columns line up cleanly and do not visually merge. */
.cw-clients-page .cw-client-table th:nth-child(n+3),
.cw-clients-page .cw-client-table td:nth-child(n+3){
  text-align:center;
}
.cw-clients-page .cw-client-table th:nth-child(4),
.cw-clients-page .cw-client-table th:nth-child(5),
.cw-clients-page .cw-client-table th:nth-child(6),
.cw-clients-page .cw-client-table th:nth-child(7){
  padding-left:11px;
  padding-right:11px;
}
.cw-clients-page .cw-client-table td:nth-child(2) small{
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

/* Action is a simple compact text action instead of a bulky draggable-looking box. */
.cw-clients-page .cw-client-table .cw-row-action{
  height:28px;
  min-width:0;
  width:auto;
  padding:0 4px;
  border:0;
  background:transparent;
  color:var(--coach-orange);
  border-radius:0;
  white-space:nowrap;
  font-weight:700;
}
.cw-clients-page .cw-client-table .cw-row-action:hover{
  background:transparent;
  color:var(--coach-orange-dark);
  text-decoration:underline;
}

@media(max-width:1320px){
  .coach-global-search{width:205px;max-width:205px;flex-basis:205px}
  .coach-header-cta{min-width:122px;max-width:122px;flex-basis:122px;padding-left:10px!important;padding-right:10px!important}
  .cw-clients-page .cw-client-layout{grid-template-columns:minmax(0,1fr) 300px}
}
@media(max-width:1180px){
  body.coach-ui-v2 .header-title{flex-basis:330px}
  .coach-global-search{width:185px;max-width:185px;flex-basis:185px}
  .cw-clients-page .cw-client-layout{grid-template-columns:1fr}
  .cw-clients-page .cw-client-table-card .cw-table-wrap{overflow-x:auto}
  .cw-clients-page .cw-client-table{min-width:760px}
}
