*{box-sizing:border-box}
.fh-cab{display:grid;grid-template-columns:280px 1fr;min-height:100vh;background:#FFFEF9;font-family:Inter,system-ui,sans-serif}
.fh-cab__sidebar{background:#0A0A0A;color:#fff;padding:18px 14px;display:flex;flex-direction:column;gap:16px;position:sticky;top:0;height:100vh;overflow:auto}
.fh-cab__logo{font-weight:900;font-size:22px;letter-spacing:-1px}
.fh-cab__logo span{color:#D4FF32}
.fh-cab__logo small{display:block;font-size:9px;letter-spacing:1px;opacity:.6;margin-top:2px;font-weight:600}
.fh-cab__nav{display:flex;flex-direction:column;gap:6px}
.fh-cab__tab{display:flex;align-items:center;gap:10px;width:100%;background:transparent;border:none;color:#8C8C8C;padding:10px 12px;border-radius:12px;cursor:pointer;font-weight:600;font-size:13px;text-align:left;transition:all .2s}
.fh-cab__tab.active{background:#fff;color:#0A0A0A}
.fh-cab__tab em{margin-left:auto;background:#222;color:#fff;font-style:normal;font-size:10px;padding:2px 7px;border-radius:100px;min-width:20px;text-align:center}
.fh-cab__tab.active em{background:#0A0A0A;color:#fff}
.fh-tab__icon{width:28px;height:28px;display:flex;align-items:center;justify-content:center;background:#1E1E1E;border-radius:8px;font-size:14px}
.fh-tab__icon.is-lime{background:#D4FF32}
.fh-loc-switch{margin-top:auto;background:#1A1A1A;padding:12px;border-radius:12px}
.fh-loc-switch label{font-size:10px;text-transform:uppercase;letter-spacing:.8px;opacity:.6;display:block;margin-bottom:6px}
.fh-select{width:100%;padding:12px 14px;border:1.5px solid #E8E6E1;border-radius:12px;background:#FFFEF9;font-size:13px;transition:all .15s;outline:none !important;box-shadow:none !important}
.fh-select:focus{border-color:#D4FF32 !important;box-shadow:0 0 0 3px rgba(212,255,50,.2) !important;outline:none !important}
.fh-select--dark{background:#2A2A2A;border-color:#3A3A3A;color:#fff}
.fh-input{width:100%;padding:12px 14px;border:1.5px solid #E8E6E1;border-radius:12px;background:#fff;font-size:13px;transition:all .15s;outline:none !important;box-shadow:none !important}
.fh-input:focus{border-color:#D4FF32 !important;box-shadow:0 0 0 3px rgba(212,255,50,.25) !important;background:#FFFEFB !important;outline:none !important}
.fh-input:hover{border-color:#D4FF32 !important}
textarea.fh-input{resize:vertical;min-height:80px}
.fh-trainer-card{display:flex;gap:10px;align-items:center;background:#1A1A1A;padding:12px;border-radius:12px}
.fh-trainer-card img{width:40px;height:40px;border-radius:100px;object-fit:cover}
.fh-trainer-card__info b{display:block;font-size:13px}
.fh-trainer-card__info span{font-size:10px;color:#D4FF32}
.fh-trainer-card__info small{font-size:10px;opacity:.6}
.fh-logout{color:#8C8C8C;font-size:12px;text-align:center;padding:8px;text-decoration:none;display:block}
.fh-cab__main{padding:28px 20px 20px;overflow:auto}
.fh-cab__section{display:none}
.fh-cab__section.active{display:block}
.fh-cab__head{display:flex;justify-content:space-between;align-items:center;margin-bottom:28px;flex-wrap:wrap;gap:12px}
.fh-cab__head h2{margin:0;font-size:24px;font-weight:900;letter-spacing:-.5px}
.fh-btn{border:none;border-radius:100px;padding:10px 16px;font-size:13px;font-weight:700;cursor:pointer;display:inline-flex;align-items:center;gap:6px;transition:all .15s;white-space:nowrap}
.fh-btn--black{background:#0A0A0A;color:#fff}
.fh-btn--white{background:#fff;border:1.5px solid #E8E6E1;color:#0A0A0A}
.fh-btn--lime{background:#D4FF32;color:#0A0A0A}
.fh-btn--small{padding:6px 10px !important;font-size:11px !important}
.fh-btn:hover{transform:translateY(-1px)}
.fh-dash__grid{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-bottom:24px;margin-top:8px}
.fh-dash__card{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:16px}
.fh-dash__card b{display:block;font-size:28px;font-weight:800}
.fh-dash__card span{font-size:12px;opacity:.6}
.fh-dash__card.is-lime{background:#D4FF32;border-color:#D4FF32}
.fh-dash__two{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.fh-dash__box{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:16px}
.fh-dash__box h3{margin:0 0 12px;font-size:13px;font-weight:800;text-transform:uppercase}
.fh-dash__item{padding:8px 10px;background:#F9F8F6;border-radius:10px;margin-bottom:6px;font-size:13px}
.fh-dash__item b{font-weight:700}
.fh-dash__item small{display:block;font-size:11px;color:#8C8C8C;margin-top:3px;line-height:1.4}
.fh-clients__grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:14px;margin-top:18px}
.fh-client-card{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:14px;transition:all .15s}
.fh-client-card:hover{border-color:#D4FF32;transform:translateY(-1px)}
.fh-client-card__top{display:flex;gap:10px}
.fh-client-card__top img{width:44px;height:44px;border-radius:100px}
.fh-client-card__top b{display:block;font-size:14px}
.fh-client-card__top small{font-size:11px;opacity:.6;display:block}
.fh-client-card__actions{margin-top:10px;display:flex;gap:6px}
.fh-programs__grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:14px;margin-top:18px}
.fh-program-card{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:14px;transition:all .2s;position:relative}
.fh-program-card:hover{border-color:#D4FF32;transform:translateY(-2px)}
.fh-filters{display:flex;justify-content:space-between;gap:12px;background:#FFFEF9;border:1px solid #F0EDE8;border-radius:14px;padding:12px;margin-bottom:20px;flex-wrap:wrap}
.fh-filters__left{display:flex;gap:6px;flex-wrap:wrap}
.fh-filters__right{display:flex;gap:8px}
.fh-filters__right .fh-select{min-width:160px}
.fh-section-group{margin-bottom:28px}
.fh-section-title{font-size:12px!important;font-weight:800!important;text-transform:uppercase!important;letter-spacing:.6px!important;color:#0A0A0A!important;background:#F5F5F0!important;border-left:4px solid #D4FF32!important;border-radius:8px!important;padding:10px 14px!important;margin:0 0 14px!important;display:flex;align-items:center;gap:8px}
.fh-section-title .fh-count{background:#D4FF32;padding:2px 8px;border-radius:100px;font-size:11px;font-weight:800}
.fh-empty{padding:16px;background:#F9F8F6;border:1px dashed #E8E6E1;border-radius:12px;text-align:center;font-size:13px;opacity:.6}
.fh-workout-card,.fh-schedule-card{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:14px 16px 16px;margin-bottom:10px;position:relative;overflow:visible!important;transition:all .15s}
.fh-workout-card:hover,.fh-schedule-card:hover{border-color:#E0DDD8;box-shadow:0 4px 12px rgba(0,0,0,.04)}
.fh-workout-card__head,.fh-schedule-card__head{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:8px}
.fh-workout-card__date,.fh-schedule-card__time{background:#FFFEF9;border:1.5px solid #D4FF32;padding:5px 12px;border-radius:100px;font-size:12px;font-weight:700;white-space:nowrap}
.fh-workout-card__date.done,.fh-schedule-card__time.done{background:#D4FF32;border-color:#D4FF32}
.fh-workout-card__client,.fh-workout-card__loc,.fh-schedule-card__client,.fh-schedule-card__loc{display:inline-flex;align-items:center;gap:4px;padding:6px 12px;border-radius:100px;font-size:12px;font-weight:600;cursor:pointer;border:1.5px solid #E8E6E1;background:#fff;transition:all .15s;max-width:180px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.fh-workout-card__client,.fh-schedule-card__client{background:#0A0A0A;color:#fff;border-color:#0A0A0A}
.fh-workout-card__client:hover,.fh-schedule-card__client:hover{background:#222;transform:translateY(-1px)}
.fh-workout-card__loc:hover,.fh-schedule-card__loc:hover{border-color:#D4FF32;background:#FFFEF9}
.fh-workout-card__loc,.fh-schedule-card__loc{background:#FFFEF9}
.fh-ic{font-size:12px;line-height:1}
.fh-workout-card__title,.fh-schedule-card__title{font-size:14px;font-weight:700;margin:6px 0 10px}
.fh-status-select{padding:6px 10px;border-radius:100px;border:1.5px solid #E8E6E1;font-size:11px;font-weight:700;cursor:pointer;background:#fff;outline:none !important}
.fh-status--planned{background:#FFFEF9!important}
.fh-status--done{background:#D4FF32!important}
.fh-ex-view--compact{margin-top:8px}
.fh-ex-item{display:flex;justify-content:space-between;align-items:center;padding:6px 10px;background:#F9F8F6;border-radius:8px;margin-bottom:4px;font-size:12px}
.fh-ex-item span{font-weight:600}
.fh-ex-item small{opacity:.6;font-size:11px}
.fh-ex-expand{background:none;border:none;color:#0A0A0A;font-size:11px;font-weight:700;cursor:pointer;text-decoration:underline;margin-top:4px}
.fh-form__grid{display:grid;grid-template-columns:1fr 1fr;gap:14px 12px}
.fh-form__grid label{font-size:12px;font-weight:600;color:#333;display:flex;flex-direction:column;gap:6px}
.fh-form__grid label small{font-weight:400;opacity:.6}
.fh-form__actions{margin-top:20px;display:flex;gap:10px;align-items:center}
.fh-form__msg{font-size:12px;opacity:.7}
.fh-ex-row{display:grid;grid-template-columns:1fr 80px 60px 60px 40px;gap:6px;margin-bottom:6px;align-items:center}
.fh-ex-row input{padding:10px 10px;border:1.5px solid #E8E6E1;border-radius:10px;font-size:12px;background:#fff;transition:all .15s;outline:none !important}
.fh-ex-row input:focus{border-color:#D4FF32 !important;box-shadow:0 0 0 2px rgba(212,255,50,.2) !important;outline:none !important}
.fh-ex-delete{background:#111;color:#fff;border:none;width:32px;height:32px;border-radius:100px;cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:16px;line-height:1;transition:all .15s}
.fh-ex-delete:hover{background:#000;transform:scale(1.05)}
.fh-modal{position:fixed;inset:0;display:none;z-index:9999;align-items:center;justify-content:center;padding:20px}
.fh-modal.open{display:flex}
.fh-modal__overlay{position:absolute;inset:0;background:rgba(0,0,0,.5);backdrop-filter:blur(4px)}
.fh-modal__content{position:relative;background:#fff;border-radius:20px;max-width:600px;width:100%;max-height:90vh;overflow:auto;padding:24px;box-shadow:0 20px 60px rgba(0,0,0,.2);animation:fhModalIn .25s ease}
@keyframes fhModalIn{from{opacity:0;transform:translateY(20px) scale(.98)}to{opacity:1;transform:translateY(0) scale(1)}}
.fh-modal__head{display:flex;justify-content:space-between;align-items:center;margin-bottom:24px}
.fh-modal__head h3{margin:0;font-size:18px;font-weight:900}
.fh-modal__close{background:#F5F5F0;border:none;width:36px;height:36px;border-radius:100px;cursor:pointer;font-size:18px;display:flex;align-items:center;justify-content:center;color:#E11;transition:all .15s}
.fh-modal__close:hover{background:#FFE8E8}
.fh-export-dropdown{position:relative}
.fh-export-dropdown__menu{position:absolute;top:100%;right:0;margin-top:6px;background:#fff;border:1.5px solid #E8E6E1;border-radius:12px;padding:6px;min-width:180px;display:none;z-index:10;box-shadow:0 10px 30px rgba(0,0,0,.1)}
.fh-export-dropdown__menu.open{display:block}
.fh-export-btn{width:100%;text-align:left;background:none;border:none;padding:8px 12px;border-radius:8px;font-size:12px;cursor:pointer}
.fh-export-btn:hover{background:#F9F8F6}
.fh-round-check{appearance:none;-webkit-appearance:none;width:22px;height:22px;border:2px solid #E8E6E1;border-radius:100px;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;position:relative;background:#fff;transition:all .2s}
.fh-round-check:checked{background:#D4FF32;border-color:#D4FF32}
.fh-round-check:checked::after{content:'✓';position:absolute;font-size:12px;font-weight:900;color:#111;top:50%;left:50%;transform:translate(-50%,-50%)}
.fh-cab__burger{display:none;position:fixed;top:12px;right:12px;z-index:10001;background:#111;border:none;width:44px;height:44px;border-radius:12px;flex-direction:column;align-items:center;justify-content:center;gap:4px}
.fh-cab__burger span{display:block;width:20px;height:2px;background:#fff;border-radius:2px}
.fh-cab__overlay{display:none;position:fixed;inset:0;background:rgba(0,0,0,.4);z-index:9998}
@media(max-width:900px){.fh-cab{grid-template-columns:1fr}.fh-cab__sidebar{position:fixed;right:0;top:0;bottom:0;width:300px;transform:translateX(100%);transition:transform .3s;z-index:9999}.fh-cab__sidebar.open{transform:translateX(0)}.fh-cab__burger{display:flex}.fh-cab__overlay.open{display:block}.fh-dash__grid{grid-template-columns:1fr 1fr}.fh-dash__two{grid-template-columns:1fr}.fh-form__grid{grid-template-columns:1fr}.fh-filters{flex-direction:column}.fh-filters__right{flex-direction:column}}
#fh-toast{position:fixed;bottom:20px;right:20px;background:#111;color:#fff;padding:12px 18px;border-radius:12px;z-index:10000;transition:all .3s;opacity:0;transform:translateY(20px);pointer-events:none}

#fh-base-workouts-modal .fh-programs__grid,
#fh-base-modal .fh-programs__grid{
  padding:20px !important;
  gap:16px !important;
}
.fh-base-card--clickable, .fh-base-workout-card{
  padding:16px !important;
  word-break:break-word;
  white-space:normal;
  overflow:hidden;
}
.fh-base-card--clickable b, .fh-base-workout-card b{
  white-space:normal !important;
  line-height:1.3 !important;
  display:block;
}
#fh-base-create-desc, #fh-base-create-ex{
  padding:12px 20px !important;
}
#fh-base-create-ex div{
  line-height:1.4;
}
#workout-pagination, #schedule-pagination, #client-workout-pagination, #client-schedule-pagination{
  flex-wrap:wrap;
  justify-content:center;
  gap:8px;
  margin:18px 0 !important;
}
#workout-pagination .fh-btn, #schedule-pagination .fh-btn, #client-workout-pagination .fh-btn, #client-schedule-pagination .fh-btn{
  min-width:36px;
  justify-content:center;
}
.fh-section-group[style*="display: none"] .fh-empty{display:none !important;}
.fh-item-check{
  width:22px !important;
  height:22px !important;
  min-width:22px !important;
  border:2.5px solid #111 !important;
  border-radius:6px !important;
  background:#fff !important;
  appearance:none;
  -webkit-appearance:none;
  display:none;
  align-items:center;
  justify-content:center;
  cursor:pointer;
}
.fh-item-check:checked{
  background:#D4FF32 !important;
  border-color:#111 !important;
}
.fh-item-check:checked::after{
  content:'✓';
  font-weight:900;
  font-size:14px;
  color:#111;
}
.fh-program-card .fh-item-check{
  position:absolute !important;
  top:10px !important;
  left:10px !important;
  z-index:5;
}
.fh-workout-card, .fh-schedule-card{
  transition:all .15s;
}
.fh-workout-card:hover, .fh-schedule-card:hover{
  transform:translateY(-1px);
  box-shadow:0 4px 12px rgba(0,0,0,.06);
}
.fh-base-card--clickable small, .fh-base-workout-card small{
  white-space:normal !important;
  display:block;
  line-height:1.4;
}
.fh-day-pill{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:8px 14px;
  border-radius:100px;
  border:1.5px solid #E8E6E1;
  background:#fff;
  cursor:pointer;
  font-size:13px;
  font-weight:700;
  transition:all .15s;
  user-select:none;
  white-space:nowrap;
}
.fh-day-pill:hover{border-color:#D4FF32;background:#FFFEF9}
.fh-day-pill:has(input:checked){background:#D4FF32;border-color:#D4FF32;color:#111;box-shadow:0 2px 8px rgba(212,255,50,.3)}
.fh-day-check{width:16px;height:16px;accent-color:#111;border-radius:4px;flex-shrink:0}
.fh-check-pill{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:10px 18px;
  border-radius:100px;
  border:1.5px solid #E8E6E1;
  background:#fff;
  cursor:pointer;
  font-weight:700;
  font-size:13px;
  transition:all .15s;
  white-space:nowrap;
  min-width:140px;
  line-height:1;
}
.fh-check-pill:hover{border-color:#D4FF32;background:#FFFEF9}
.fh-check-pill:has(input:checked){background:#D4FF32;border-color:#D4FF32;color:#111;box-shadow:0 2px 8px rgba(212,255,50,.3)}
.fh-check-pill input{flex-shrink:0;margin:0}
.fh-days-grid{display:flex;gap:8px;flex-wrap:wrap;margin-top:8px}
.fh-client-cab .fh-cab__head{margin-bottom:28px}
.fh-client-cab .fh-dash__grid{margin-top:16px}
.fh-client-stat-grid{margin-top:18px !important}
.fh-cab__section[data-section="clients"] .fh-clients__grid,
.fh-cab__section[data-section="groups"] .fh-clients__grid,
.fh-cab__section[data-section="locations"] .fh-clients__grid,
.fh-cab__section[data-section="programs"] .fh-programs__grid{
  margin-top:22px;
}
.fh-location-card-actions{display:flex;gap:6px;align-items:center;margin-top:10px}
.fh-location-card-actions .fh-btn{width:28px;height:28px;padding:0 !important;display:flex;align-items:center;justify-content:center;border-radius:100px}
.fh-modal__head + .fh-form .fh-form__grid:first-child{margin-top:4px}
#microcycle-list .fh-ex-row{grid-template-columns:120px 1fr 40px;gap:8px}
#program-ex-list .fh-ex-row{grid-template-columns:1fr 70px 60px 60px 90px 40px}
#bulk-bar-workouts, #bulk-bar-schedule, #bulk-bar-programs, #bulk-bar-clients, #bulk-bar-groups, #bulk-bar-locations{border-radius:14px;margin-bottom:16px}

.fh-modal .fh-input,
.fh-modal .fh-select,
.fh-modal input[type="text"],
.fh-modal input[type="email"],
.fh-modal input[type="tel"],
.fh-modal input[type="number"],
.fh-modal input[type="date"],
.fh-modal input[type="time"],
.fh-modal input[type="datetime-local"],
.fh-modal textarea,
.fh-modal select,
.fh-form .fh-input,
.fh-form .fh-select,
.fh-form textarea,
.fh-form select{
  border:1.5px solid #D6D3CE !important;
  background:#FFFFFF !important;
  border-radius:12px !important;
  padding:12px 14px !important;
  outline:none !important;
  box-shadow:none !important;
  -webkit-appearance:none;
  appearance:none;
  color:#111 !important;
}
.fh-modal .fh-input:focus,
.fh-modal .fh-select:focus,
.fh-modal textarea:focus,
.fh-modal select:focus,
.fh-form .fh-input:focus,
.fh-form .fh-select:focus,
.fh-form textarea:focus{
  border-color:#D4FF32 !important;
  box-shadow:0 0 0 3px rgba(212,255,50,.22) !important;
  outline:none !important;
  background:#FFFEFB !important;
}
.fh-modal .fh-input::placeholder{color:#9A9A9A}
.fh-modal *:focus-visible,
.fh-form *:focus-visible,
.fh-btn:focus,
.fh-btn:focus-visible{
  outline:none !important;
  box-shadow:0 0 0 3px rgba(212,255,50,.22) !important;
}
.fh-modal input:focus,
.fh-modal textarea:focus,
.fh-modal select:focus{
  outline:none !important;
}
.fh-autogen-checks{display:flex;gap:12px;flex-wrap:wrap;margin-top:8px}
.fh-autogen-checks .fh-check-pill{flex:1 1 160px;min-width:160px;justify-content:center}
.fh-pagination{margin:16px 0}
.fh-pagination .fh-btn--active-page{background:#111 !important;color:#fff !important;border-color:#111 !important}


/* FIX 5.1: отступ между названием локации и адресом */
.fh-client-card b + small,
.fh-client-card b + div small,
.fh-client-card > b {
  display: block;
}
.fh-client-card > b {
  margin-bottom: 6px;
  line-height: 1.3;
}
.fh-client-card > small {
  display: block;
  margin-top: 4px;
  line-height: 1.4;
  opacity: .7;
}
/* Location card specific */
.fh-clients__grid .fh-client-card {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.fh-clients__grid .fh-client-card b {
  margin-bottom: 4px;
}

/* FIX 2.5: увеличить ширину плашки Расписание */
.fh-check-pill--schedule {
  min-width: 220px !important;
  padding: 12px 22px !important;
  justify-content: center !important;
}
.fh-check-pill {
  min-width: 160px;
}
.fh-form__grid .fh-check-pill {
  flex: 1 1 180px;
}
.fh-days-grid + div .fh-check-pill {
  min-width: 180px;
}

/* FIX 6.2: замеры - красивая сетка */
.fh-measurements-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 8px;
}
.fh-measurement-item {
  background: #F9F8F6;
  padding: 10px;
  border-radius: 10px;
  border: 1px solid #F0EDE8;
}

/* FIX 8.1: дашборд empty states */
.fh-dash__box .fh-empty {
  background: #F9F8F6;
  border: 1px dashed #E8E6E1;
  border-radius: 12px;
  padding: 16px;
  text-align: center;
  font-size: 13px;
  opacity: .7;
  margin-top: 8px;
}

/* FIX 7.1: фото прогресса - hover для удаления */
.fh-client-card img {
  border-radius: 12px;
  max-width: 100%;
  height: auto;
}
.fh-client-card .fh-btn--small {
  margin-top: 6px;
}

/* FIX 2.2: модалка удаления программы */
#fh-modal-delete-program .fh-modal__content {
  border: 2px solid #111;
}
#delete-program-warning {
  transition: all .2s;
}

/* Dashboard location filtered empty */
#dash-empty-schedule-filtered {
  background: #FFFEF9;
  border-color: #D4FF32;
}


/* FIX 2.3-2.4: круглое отображение фото клиента и заглушки */
.fh-client-avatar,
#client-photo-preview,
.fh-client-card__top .fh-client-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50% !important;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  flex-shrink: 0;
  background: #F0EDE8;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
}

#client-photo-preview {
  width: 80px !important;
  height: 80px !important;
}

.fh-client-avatar img,
#client-photo-preview img,
.fh-client-card__top img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
  border-radius: 50% !important;
  display: block;
  aspect-ratio: 1 / 1;
}

/* Исправление овала - гарантируем квадрат */
.fh-client-card__top img {
  width: 56px !important;
  height: 56px !important;
  min-width: 56px;
  min-height: 56px;
}

/* Заглушка тоже круглая */
.fh-client-avatar span,
#client-photo-preview span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

/* Форма загрузки фото */
#client-photo-input {
  border: 1.5px dashed #E8E6E1;
  background: #FFFEF9;
  border-radius: 12px;
  cursor: pointer;
}
#client-photo-input:hover {
  border-color: #D4FF32;
  background: #FFFEF9;
}

/* FIX PDF - ensure export buttons visible */
.fh-export-dropdown__menu {
  z-index: 1000;
}

/* ===== FIT HUB Unified: auth forms (из плагина авторизации) ===== */
.fh-auth{max-width:440px; margin:30px auto; font-family:Inter,system-ui,sans-serif;}
.fh-auth__form{background:white; border:1px solid var(--line,#E8E6E1); border-radius:20px; padding:24px; display:flex; flex-direction:column; gap:14px;}
.fh-auth__form h3{margin:0; font-size:22px; font-weight:900; letter-spacing:-0.03em;}
.fh-auth__form label{display:flex; flex-direction:column; gap:6px; font-size:11px; font-weight:600; min-height:68px;}
.fh-auth__form input, .fh-auth__form select{padding:11px 13px; border:1px solid var(--line,#E8E6E1); border-radius:12px; font-size:13px; background:white; height:42px;}
.fh-auth-box{background:#FFFEF9; border:1px solid var(--line,#E8E6E1); border-radius:16px; padding:18px; max-width:440px; margin:20px auto; text-align:center;}
.fh-form__msg{margin-top:10px; font-size:13px; min-height:18px;}
.fh-notice{padding:10px 12px; border-radius:10px; font-size:12px; font-weight:600; margin-top:8px;}
.fh-notice--error{background:#FFF0F0; border:1px solid #FFB3B3; color:#CC0000;}
.fh-notice--success{background:#F0FFF0; border:1px solid #B3FFB3; color:#0A8A00;}
.fh-pass{position:relative;}
.fh-pass-toggle{position:absolute; right:8px; top:50%; transform:translateY(-50%); border:none; background:none; cursor:pointer; font-size:14px; padding:4px;}
/* ===== Каталог занятий ===== */
.fh-lesson-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:12px;}
.fh-lesson-card{display:flex;flex-direction:column;gap:6px;text-align:left;background:#FFFEF9;border:1px solid #E8E6E1;border-radius:14px;padding:14px;cursor:pointer;transition:all .2s;}
.fh-lesson-card:hover{border-color:#0A0A0A;transform:translateY(-2px);}
.fh-lesson-card__ico{font-size:26px;}
.fh-lesson-card__title{font-weight:800;font-size:13px;}
.fh-lesson-card__desc{font-size:11px;opacity:.65;}

/* ===== v5.2.0: Каталог занятий — карточки ===== */
.fh-lesson-grid{grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:14px;}
.fh-lesson-card{min-height:190px;justify-content:flex-start;align-items:flex-start;gap:8px;padding:16px;background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;box-shadow:0 1px 2px rgba(0,0,0,.03);}
.fh-lesson-card:hover{border-color:#0A0A0A;transform:translateY(-2px);box-shadow:0 8px 20px rgba(0,0,0,.08);}
.fh-lesson-card__ico{font-size:30px;line-height:1;}
.fh-lesson-card__title{font-size:14px;line-height:1.3;}
.fh-lesson-card__meta{font-size:11px;font-weight:700;color:#0A0A0A;background:#F9F8F6;border:1px solid #F0EDE8;border-radius:100px;padding:3px 9px;line-height:1.4;}
.fh-lesson-card__desc{font-size:12px;line-height:1.5;opacity:.65;display:-webkit-box;-webkit-line-clamp:4;-webkit-box-orient:vertical;overflow:hidden;}
/* v5.2.4: каталог занятий — как базовые программы: цвет как у сайта, длинные слова не вылезают за карточку */
.fh-lesson-card{color:#0A0A0A;min-width:0;overflow-wrap:anywhere;word-break:break-word;border:1px dashed #D4FF32;}
.fh-lesson-card__title{color:#0A0A0A;overflow-wrap:anywhere;word-break:break-word;}
.fh-lesson-card__meta{overflow-wrap:anywhere;}
.fh-lesson-card__desc{overflow-wrap:anywhere;word-break:break-word;}
/* v5.2.5: описание каталога — адаптивный перенос. Тема ставит кнопкам white-space:nowrap,
   из-за него текст шёл одной строкой и обрезался; сбрасываем, как у базовых программ */
.fh-lesson-card, .fh-lesson-card__title, .fh-lesson-card__meta, .fh-lesson-card__desc{white-space:normal !important;}
.fh-lesson-card__title, .fh-lesson-card__desc{min-width:0;}

/* ===== v5.2.0: Дни недели с полными названиями ===== */
.fh-days-grid--full{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px;}
.fh-day-pill--full{flex:1 1 150px;justify-content:flex-start;padding:10px 14px;font-size:13px;}

/* ===== v5.2.0: Уведомления клиента ===== */
.fh-notif-badge{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:100px;background:#D4FF32;color:#111;font-style:normal;font-size:11px;font-weight:800;line-height:1;}
.fh-notifications-list{display:flex;flex-direction:column;gap:12px;}
.fh-notification-card{background:#fff;border:1.5px solid #E8E6E1;border-radius:16px;padding:14px;display:flex;flex-direction:column;gap:10px;transition:all .15s;}
.fh-notification-card.is-unread{border-color:#0A0A0A;background:#FFFEF9;box-shadow:0 2px 10px rgba(0,0,0,.05);}
.fh-notification-card.is-read{opacity:.75;}
.fh-notification-card__top{display:flex;gap:12px;align-items:flex-start;}
.fh-notification-card__ico{font-size:24px;line-height:1;flex-shrink:0;}
.fh-notification-card__body{display:flex;flex-direction:column;gap:4px;min-width:0;}
.fh-notification-card__body b{font-size:14px;line-height:1.3;}
.fh-notification-card__label{font-size:11px;opacity:.6;}
.fh-notification-card__body p{margin:0;font-size:13px;line-height:1.5;opacity:.85;}
.fh-notification-card__details{margin:6px 0 0;padding:0;list-style:none;display:flex;flex-direction:column;gap:3px;}
.fh-notification-card__details li{font-size:12px;line-height:1.45;background:#F9F8F6;border-radius:8px;padding:5px 9px;}
.fh-notification-card__actions{display:flex;gap:8px;flex-wrap:wrap;}
.fh-notification-card__done{font-size:12px;font-weight:700;opacity:.6;align-self:center;}


/* =====================================================================
   МОБИЛЬНАЯ АДАПТАЦИЯ v5.2.7 — ТОЛЬКО max-width:900px / 480px.
   Десктоп НЕ трогаем: все правила ниже живут внутри @media.
   PHP/JS не менялись (кроме 3 точечных правок в shortcode.php:
   бургер в кабинете клиента + 2 класса для сеток клиента).
   ===================================================================== */
@media(max-width:900px){

  /* --- 1) Кабинет клиента: сетка — 1 колонка даже поверх инлайн-стиля --- */
  .fh-cab{grid-template-columns:1fr !important}
  .fh-cab__main{padding:16px 12px;min-width:0}
  .fh-cab__head h2{font-size:20px}
  .fh-cab__head > div{flex-wrap:wrap}
  .fh-cab__head .fh-btn{padding:10px 14px}

  /* --- 2) Сайдбар: «Выйти» — НАД блоком «Локация для дашборда» --- */
  .fh-cab__sidebar .fh-cab__logo{order:1}
  .fh-cab__sidebar .fh-cab__nav{order:2}
  .fh-cab__sidebar .fh-logout{order:3}
  .fh-cab__sidebar .fh-loc-switch{order:4;margin-top:0}
  .fh-cab__sidebar .fh-trainer-card{order:5}

  /* --- 3) Гамбургер: цвет НЕ меняется — ни при нажатии, ни при наведении, ни в фокусе --- */
  .fh-cab__burger,
  .fh-cab__burger:hover,
  .fh-cab__burger:active,
  .fh-cab__burger:focus,
  .fh-cab__burger:focus-visible{background:#111 !important;-webkit-tap-highlight-color:transparent}
  .fh-cab__burger span{background:#fff !important}

  /* --- 4) Шапки разделов и фильтры: кнопки переносятся, не уезжают за экран.
         Выпадающее меню экспорта вписывается в ширину экрана --- */
  .fh-filters__right{flex-wrap:wrap}
  .fh-filters__right .fh-select{min-width:0;flex:1 1 140px}
  .fh-export-dropdown__menu{max-width:calc(100vw - 32px);right:0;left:auto}

  /* --- 5) Строки упражнений (Программы, Тренировки):
         название — на всю ширину отдельной строкой, цифры — ниже.
         16px — iOS не зумит экран при фокусе на поле.
         !important — перебивает инлайн-стиль сетки у строк программ --- */
  .fh-ex-row{grid-template-columns:repeat(4,minmax(0,1fr)) !important}
  .fh-ex-row input{font-size:16px;min-width:0}
  .fh-ex-row input[name="ex_name[]"]{grid-column:1/-1}
  #program-ex-list .fh-ex-row{grid-template-columns:repeat(4,minmax(0,1fr)) !important}
  #program-ex-list .fh-ex-row input[name="ex_name[]"]{grid-column:1/-1}
  #program-ex-list .fh-ex-row input[name="ex_notes[]"]{grid-column:span 2}
  #microcycle-list .fh-ex-row{grid-template-columns:1fr 1fr 40px !important}

  /* --- 6) Кабинет клиента: статистика калорий 4 -> 2 колонки, прогресс 2 -> 1 --- */
  .fh-client-cal-stats{grid-template-columns:repeat(2,1fr) !important}
  .fh-client-progress-grid{grid-template-columns:1fr !important}

  /* --- 7) Модалки на мобильном: меньше отступы, чтобы влезло содержимое --- */
  .fh-modal{padding:12px}
  .fh-modal__content{padding:18px 14px;border-radius:16px;max-height:92vh}
  .fh-modal__head h3{font-size:16px}
}

/* --- Узкие телефоны: дашборд и карточки — в одну колонку --- */
@media(max-width:480px){
  .fh-dash__grid{grid-template-columns:1fr}
  .fh-clients__grid{grid-template-columns:1fr}
  .fh-cab__head h2{font-size:18px}
  .fh-modal__content{padding:16px 12px}
}


/* =====================================================================
   МОБИЛЬНАЯ АДАПТАЦИЯ v5.2.8 — правки по скриншотам (ТОЛЬКО ≤900px/480px).
   Десктоп НЕ трогаем. Исправляет пережатия из v5.2.7 и новые замечания.
   ===================================================================== */
@media(max-width:900px){

  /* 1) Дашборд: плашки в 2 колонки, компактнее (отмена 1fr из v5.2.7 на узких) */
  .fh-dash__card{padding:14px}
  .fh-dash__card b{font-size:24px}

  /* 2-3) Фильтры (Тренировки, Расписание): селекты — обычная высота.
         flex-basis 140px из v5.2.7 растягивал их в колонке на 140px в высоту */
  .fh-filters__right .fh-select{min-width:0;flex:none;width:100%}

  /* 4) Экспорт: меню открывается от ЛЕВОГО края кнопки —
         с right:0 оно уезжало за левый край экрана, когда кнопка на новой строке */
  .fh-export-dropdown__menu{left:0;right:auto}

  /* 6) Модалки — выше гамбургера (у него 10001), крестик закрытия кликабелен */
  .fh-modal{z-index:10002}

  /* 7) Крестик удаления в тренировках/расписаниях — к правому краю карточки:
         строка действий — на всю ширину, крестик отжимается вправо */
  .fh-workout-card__head > div:last-child,
  .fh-schedule-card__head > div:last-child{width:100%}
  .fh-workout-card__head button[onclick*="fht34Delete"],
  .fh-schedule-card__head button[onclick*="fht34Delete"]{margin-left:auto}

  /* 8) Гамбургер ниже, чтобы не перекрывать кнопки шапок разделов */
  .fh-cab__burger{top:64px}
}

/* Узкие телефоны: плашки дашборда — 2 колонки (отмена 1fr из v5.2.7) */
@media(max-width:480px){
  .fh-dash__grid{grid-template-columns:1fr 1fr;gap:10px}
}
