/* SalonPro master studio refresh — no stock photos, live records only.
   Entirely staff-scoped, owner dashboards and guest booking remain unchanged. */
.master-workspace{background:#f8f8f5;color:#244238}
.master-workspace .app-top{
  background:rgba(255,254,250,.96);border-bottom:1px solid #e5ebe3;
  box-shadow:0 4px 17px #25493806;
}
.master-workspace .app-top .mobile-brand .brand{color:#224c3a}
.master-workspace .page{max-width:1190px}
.master-studio-hero.master-premium-hero{
  min-height:244px;display:grid;grid-template-columns:minmax(0,1fr) minmax(255px,.53fr);
  gap:clamp(20px,4vw,56px);align-items:center;padding:33px clamp(28px,4vw,48px);
  background:linear-gradient(125deg,#eaf3eb 0%,#f6f7ef 55%,#f3ece2 100%);
  border:1px solid #e0e8dd;border-radius:26px;box-shadow:0 17px 55px #264a350d;
}
.master-studio-hero .master-premium-hero-copy{gap:10px}
.master-studio-hero .master-premium-eyebrow{font-size:.65rem;letter-spacing:.15em;color:#638871}
.master-studio-hero h1{font-size:clamp(2.1rem,3.4vw,3.1rem);letter-spacing:-.065em}
.master-studio-hero p{color:#778978;font-size:.9rem}
.master-studio-primary-actions{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin-top:12px}
.master-studio-primary-actions .master-premium-new{
  display:inline-flex;align-items:center;justify-content:center;gap:9px;
  min-height:49px;margin:0;padding:12px 18px;box-shadow:0 12px 25px #1e624127;
  border-radius:13px;white-space:normal;
}
.master-studio-share-button{
  display:inline-flex;align-items:center;justify-content:center;gap:9px;
  min-height:49px;padding:11px 17px;border:1px solid #c5d8cb;border-radius:13px;
  background:#fffefa;color:#285c45;font-size:.88rem;font-weight:800;cursor:pointer;
  box-shadow:0 5px 15px #27533e0b;transition:background .18s,transform .18s;
}
.master-studio-share-button:hover{background:#eaf4ec;transform:translateY(-1px)}
.master-studio-profile-card{
  display:grid;gap:19px;padding:23px;background:#ffffffd9;border:1px solid #e0e9df;
  border-radius:21px;box-shadow:0 16px 42px #254d3410;min-width:0;
}
.master-studio-profile-top{display:flex;gap:14px;align-items:center;min-width:0}
.master-studio-profile-avatar{
  flex:0 0 64px;width:64px;height:68px;display:grid;place-items:center;
  border-radius:17px;overflow:hidden;background:linear-gradient(135deg,#c4e0c9,#8bb39a);
  color:#285d42;font-size:1.65rem;font-weight:900;
}
.master-studio-profile-avatar>img{width:100%;height:100%;object-fit:cover}
.master-studio-profile-copy{display:grid;gap:4px;align-content:center;min-width:0}
.master-studio-profile-copy>small{font-size:.72rem;color:#7e9483;font-weight:750}
.master-studio-profile-copy>strong{
  font-size:1.06rem;color:#224a37;overflow-wrap:anywhere;line-height:1.35;
}
.master-studio-profile-badge{
  display:inline-flex;align-items:center;gap:5px;width:max-content;max-width:100%;
  font-size:.68rem;font-weight:800;padding:5px 9px;border-radius:99px;
  line-height:1.2;
}
.master-studio-profile-badge.is-published{color:#2f7b52;background:#e4f4e8}
.master-studio-profile-badge.is-draft{color:#8c6a39;background:#fff1dd}
.master-studio-edit-link{
  display:flex;justify-content:space-between;align-items:center;gap:10px;
  border-top:1px solid #e4eae1;padding-top:14px;color:#366c4b;
  font-size:.82rem;font-weight:850;
}
.master-studio-edit-link:hover{color:#1c5137}
.master-workspace .master-premium-dashboard{gap:17px}
.master-workspace .master-premium-stats{gap:12px}
.master-workspace .master-premium-stat{
  min-height:132px;padding:19px 22px;border-radius:20px;gap:4px;
  background:linear-gradient(160deg,#fffefa,#f9fcf7);
  border:1px solid #e4eae2;box-shadow:0 8px 29px #3153370a;
}
.master-workspace .master-premium-stat:after{width:110px;height:110px;bottom:-54px;right:-28px}
.master-workspace .master-premium-stat strong{font-size:2.2rem}
.master-workspace .master-premium-stat-icon{width:39px;height:39px}
.master-workspace .master-premium-diary{
  border-radius:24px;padding:24px;background:#fffefa;box-shadow:0 14px 38px #254a340a;
}
.master-workspace .master-premium-diary-head h2{font-size:1.5rem}
.master-workspace .master-premium-day-label{background:#eef5ef;border:1px solid #dfebde}
.master-workspace .master-premium-date-quick{background:#f6f8f3}
.master-workspace .master-premium-visit.master-visit{
  background:#fff;border-color:#e3eae1;border-left-color:#6fa989;
  border-radius:16px;box-shadow:0 7px 25px #31523608;
}
.master-workspace .master-premium-client-avatar{
  background:#e3f0e6;color:#356e4e;border-radius:50%;
}
.master-workspace .master-premium-empty{background:#f3f8f2;border:1px dashed #c8ddcc}
.master-workspace :is(.master-studio-share-button,.master-studio-edit-link,.master-studio-primary-actions button):focus-visible{
  outline:3px solid #79b899;outline-offset:3px;
}
@media(max-width:900px){
 .master-studio-hero.master-premium-hero{
   grid-template-columns:minmax(0,1fr) minmax(225px,.55fr);gap:16px;padding:27px;
 }
 .master-studio-profile-card{padding:17px;gap:14px}
 .master-studio-profile-avatar{width:51px;height:56px;flex-basis:51px;border-radius:14px}
 .master-studio-profile-copy>strong{font-size:.93rem}
}
@media(max-width:650px){
 .master-workspace .app-top{min-height:66px;background:#fffefa}
 .master-workspace .app-top>.muted{display:none!important}
 .master-workspace .mobile-brand{flex:1}
 .master-workspace .mobile-brand .brand-name{max-width:none!important}
 .master-workspace .app-top .top-actions{gap:7px}
 .master-workspace .app-top .lang{
   font-size:.7rem;padding:7px 9px;border-color:#e2e8df;border-radius:11px;
 }
 .master-workspace .inbox-top-link{background:#f4f8f3}
 .master-workspace #logoutTop{display:none}
 .master-workspace .page{
   padding:14px 14px calc(132px + env(safe-area-inset-bottom));
 }
 .master-workspace .master-premium-dashboard{gap:15px}
 .master-studio-hero.master-premium-hero{
   display:grid;grid-template-columns:1fr;gap:18px;min-height:0;
   border-radius:23px;padding:23px 19px;
 }
 .master-studio-hero h1{font-size:clamp(1.85rem,7vw,2.55rem)}
 .master-studio-hero p{font-size:.83rem;max-width:none;line-height:1.6}
 .master-studio-primary-actions{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(0,1fr);
   width:100%;gap:8px;margin-top:8px}
 .master-studio-primary-actions .master-premium-new{
   min-width:0;width:100%;max-width:none;min-height:47px;
   margin:0;padding:10px 11px;font-size:.78rem;gap:7px;
 }
 .master-studio-share-button{min-height:47px;width:100%;padding:10px 8px;font-size:.79rem;gap:6px}
 .master-studio-profile-card{
   background:#fffefaed;display:flex;flex-wrap:wrap;align-items:center;
   border-radius:16px;padding:12px 13px;gap:8px;
 }
 .master-studio-profile-top{flex:1 1 170px;gap:10px}
 .master-studio-profile-avatar{width:45px;height:48px;flex-basis:45px;border-radius:13px;font-size:1.25rem}
 .master-studio-profile-copy>small{font-size:.62rem}
 .master-studio-profile-copy>strong{font-size:.84rem}
 .master-studio-profile-badge{font-size:.58rem;padding:4px 7px}
 .master-studio-edit-link{
   border:0;padding:0;flex:0 0 auto;min-width:33px;height:37px;
   justify-content:center;gap:5px;font-size:0;border-radius:10px;
   background:#e9f3ec;
 }
 .master-studio-edit-link svg{width:18px;height:18px}
 .master-workspace .master-premium-stats{gap:8px}
 .master-workspace .master-premium-stat{
   min-height:126px;border-radius:16px;padding:12px 10px;gap:5px;
 }
 .master-workspace .master-premium-stat-label{min-height:34px;font-size:.66rem;line-height:1.28}
 .master-workspace .master-premium-stat strong{font-size:1.9rem}
 .master-workspace .master-premium-stat-icon{width:33px;height:33px;border-radius:10px}
 .master-workspace .master-premium-stat-icon svg{width:18px;height:18px}
 .master-workspace .master-premium-diary{border-radius:19px;padding:18px 13px}
 .master-workspace .master-premium-diary-head h2{font-size:1.3rem}
 .master-workspace .master-premium-day-label{font-size:.65rem}
 .master-workspace .master-premium-visit.master-visit{padding:13px 10px}
 /* Five destinations, a comfortable touch area and no multi-line labels. */
 .master-workspace .bottomnav{
   position:fixed;bottom:calc(9px + env(safe-area-inset-bottom));left:12px;right:12px;
   z-index:10;display:grid!important;grid-template-columns:repeat(5,minmax(0,1fr))!important;
   gap:4px;padding:8px!important;background:#fffefaed;
   border:1px solid #dfe9e0;border-radius:21px;
   box-shadow:0 10px 38px #20473422;
   -webkit-backdrop-filter:blur(17px);backdrop-filter:blur(17px);
 }
 .master-workspace .bottomnav>a,
 .master-workspace .bottomnav>.mobile-more-trigger{
   min-width:0;width:100%;min-height:57px;
   display:flex;flex-direction:column;align-items:center;justify-content:center;
   gap:4px;position:relative;margin:0;
   padding:6px 3px!important;border-radius:14px;
   background:transparent;color:#839285;line-height:1.1!important;
   font-weight:800;font-size:.67rem!important;text-decoration:none;
   white-space:nowrap;overflow-wrap:normal;
 }
 .master-workspace .bottomnav .ico,
 .master-workspace .bottomnav .ico svg{
   width:23px;height:23px;display:inline-grid;place-items:center;
 }
 .master-workspace .bottomnav a.active,
 .master-workspace .bottomnav>.mobile-more-trigger.active{
   background:#255842;color:white!important;
 }
 .master-workspace .bottomnav a.active .ico,
 .master-workspace .bottomnav>.mobile-more-trigger.active .ico{color:white}
 .master-workspace .bottomnav a.active:after{display:none!important}
 .master-workspace .bottomnav .master-unread-badge:not([hidden]){
   top:0;right:calc(50% - 25px);min-width:17px;height:17px;
 }
 .master-workspace .mobile-more-scrim:not([hidden]){
   z-index:11;background:#112d2299;-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px);
 }
 .master-workspace .mobile-more-panel:not([hidden]){
   z-index:12;left:12px;right:12px;
   bottom:calc(93px + env(safe-area-inset-bottom));
   background:#fffefa;border:1px solid #d9e7da;
   padding:18px;border-radius:23px;box-shadow:0 25px 70px #0f342c31;
 }
 .master-workspace .mobile-more-title{
   display:flex;justify-content:space-between;align-items:center;
   gap:15px;color:#264e3a;font-size:.99rem;font-weight:850;
   margin:0 0 14px;
 }
 .master-workspace #mobileMoreClose{
   display:grid;place-items:center;min-width:36px;height:36px;
   padding:0;border:1px solid #dfe9de;border-radius:10px;
   color:#50775d;background:#f6faf4;cursor:pointer;
 }
 .master-workspace .mobile-more-grid{grid-template-columns:1fr;gap:9px}
 .master-workspace .mobile-extra-link{
   min-height:56px;background:#f5f8f3;border:1px solid #e6ebe2;
   border-radius:14px;color:#375e45;font-size:.9rem;font-weight:800;
   padding:12px 14px;gap:15px;
 }
 .master-workspace .mobile-extra-link .ico{color:#4e8a66}
 .master-workspace .mobile-extra-link.active{border-color:#80b393;background:#eaf5ea}
}
@media(max-width:370px){
 .master-workspace .page{padding-inline:9px}
 .master-studio-hero.master-premium-hero{padding:18px 14px}
 .master-studio-primary-actions .master-premium-new{font-size:.73rem}
 .master-studio-share-button{font-size:.74rem}
 .master-workspace .bottomnav{left:7px;right:7px;padding:6px!important}
 .master-workspace .bottomnav>a,
 .master-workspace .bottomnav>.mobile-more-trigger{font-size:.62rem!important}
}
@media(prefers-reduced-motion:reduce){
 .master-workspace .master-studio-share-button{transition:none}
}

/* Package 7: staff daily work queue, intentionally limited to master workspace. */
.master-workspace .master-workday-attention{
  display:flex;align-items:center;gap:12px;width:100%;padding:15px 19px;
  border:1px solid #e7d5b7;border-radius:17px;background:#fff8eb;color:#875e28;
  font-size:.86rem;font-weight:780;text-align:left;cursor:pointer;
}
.master-workspace .master-workday-attention span{flex:1}
.master-workspace .master-workday-attention b{font-weight:900}
.master-workspace .master-workday-attention:hover{background:#fff1d7}
.master-workspace .master-workday-filters{
  display:flex;gap:8px;flex-wrap:wrap;margin:0 0 16px;
}
.master-workspace .master-workday-filter{
  display:inline-flex;align-items:center;justify-content:center;gap:7px;
  border:1px solid #dce8df;background:#f7faf7;color:#526c59;
  border-radius:12px;padding:10px 12px;font-size:.76rem;font-weight:800;min-height:44px;
}
.master-workspace .master-workday-filter[aria-pressed="true"]{
  background:#275e44;border-color:#275e44;color:#fff;
}
.master-workspace .master-workday-filter span{
  display:inline-grid;place-items:center;min-width:21px;height:21px;
  padding:0 5px;border-radius:30px;background:#e4ede5;color:#335c42;font-size:.7rem;
}
.master-workspace .master-workday-filter[aria-pressed="true"] span{
  color:#28553e;background:#f8fff8;
}
.master-workspace .master-premium-visit.master-visit[hidden],
.master-workspace .master-workday-empty[hidden]{display:none!important}
.master-workspace .master-workday-empty{
  padding:30px 16px;text-align:center;border:1px dashed #cddfcf;
  background:#f8fbf7;border-radius:15px;color:#6e8071;font-size:.86rem;
}
.master-workspace .master-workday-confirming{
  background:#fff3d6!important;color:#7b5421!important;
  border:1px solid #d6ab63!important;
}
.master-workspace .master-workday-filter:focus-visible,
.master-workspace .master-workday-attention:focus-visible{
  outline:3px solid #8bc29a;outline-offset:3px;
}
@media(max-width:650px){
  .master-workspace .master-workday-attention{padding:13px 12px;font-size:.75rem}
  .master-workspace .master-workday-filters{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px}
  .master-workspace .master-workday-filter{padding:9px 6px;font-size:.72rem}
}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-workday-attention{scroll-behavior:auto}
}

/* Package 8: private appointment details, scoped to staff workday. */
.master-workspace .master-client-card{
  margin-top:2px;border:1px solid #e1ebdf;border-radius:14px;background:#f8fbf7;
  min-width:0;overflow:hidden;
}
.master-workspace .master-client-card>summary{
  display:flex;align-items:center;gap:9px;cursor:pointer;list-style:none;
  font-size:.79rem;font-weight:850;padding:12px 14px;color:#386149;
}
.master-workspace .master-client-card>summary::-webkit-details-marker{display:none}
.master-workspace .master-client-card>summary>span{flex:1}
.master-workspace .master-client-card>summary>svg:last-child{transition:transform .18s ease}
.master-workspace .master-client-card[open]>summary>svg:last-child{transform:rotate(180deg)}
.master-workspace .master-client-card-content{display:grid;gap:13px;padding:2px 14px 14px}
.master-workspace .master-client-card-facts{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.master-workspace .master-client-card-facts>div,
.master-workspace .master-client-card-phone{display:grid;gap:5px;min-width:0}
.master-workspace .master-client-card-facts small,
.master-workspace .master-client-card-phone small{font-size:.68rem;color:#708777;font-weight:700}
.master-workspace .master-client-card-facts strong{font-size:.8rem;color:#244f37}
.master-workspace .master-client-card-contact{display:grid;gap:11px;border-top:1px solid #e2ece0;padding-top:12px}
.master-workspace .master-client-card-phone b{font-size:.95rem;color:#274f3a;overflow-wrap:anywhere}
.master-workspace .master-client-card-buttons{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.master-workspace .master-client-card-link{
  min-height:42px;display:flex;justify-content:center;align-items:center;gap:7px;
  background:#fff;border:1px solid #d3e2d5;border-radius:11px;
  font:inherit;font-size:.72rem;font-weight:850;color:#335c42;
  text-decoration:none;padding:8px;cursor:pointer;text-align:center;
}
.master-workspace .master-client-card-link.is-whatsapp{background:#e3f6eb;border-color:#c5e7d0;color:#217044}
.master-workspace .master-client-card-link:hover{border-color:#8fbaa0}
.master-workspace .master-client-card-note,.master-workspace .master-client-card-unavailable{
  margin:0;font-size:.69rem;line-height:1.5;color:#728576;
}
.master-workspace .master-client-card>summary:focus-visible,
.master-workspace .master-client-card-link:focus-visible{outline:3px solid #8fbe9d;outline-offset:2px}
@media(max-width:370px){.master-workspace .master-client-card-buttons{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-client-card>summary>svg:last-child{transition:none}
}

/* Master's client-facing profile editor: premium identity / share showcase.
   Scope strictly to staff accounts; owner and public booking pages are untouched. */
.master-workspace .master-profile-editor-layout{
  grid-template-columns:minmax(0,1.08fr) minmax(0,.92fr);
  align-items:start;gap:20px;
}
.master-workspace .master-profile-editor-panel{
  min-width:0;padding:0;overflow:hidden;border:1px solid #e0e9df;
  border-radius:24px;background:#fffefa;box-shadow:0 13px 38px #234c3310;
}
.master-workspace .master-profile-identity{
  position:relative;isolation:isolate;overflow:hidden;
  display:grid;align-content:start;gap:0;
  padding:26px 27px 24px;
  background:linear-gradient(125deg,#e9f2e9 0%,#f4f6ee 60%,#f5eee5 100%);
  border-bottom:1px solid #dce7da;
}
.master-workspace .master-profile-identity:after{
  content:"";position:absolute;z-index:-1;right:-65px;top:-92px;
  width:235px;height:235px;border-radius:50%;
  border:1px solid #aecdb771;box-shadow:0 0 0 36px #e4f1e443,0 0 0 76px #ffffff42;
  pointer-events:none;
}
.master-workspace .master-profile-identity .master-public-status{
  width:max-content;max-width:100%;font-size:.72rem;font-weight:850;
  border:1px solid #f0d9b5;margin:0 0 15px;
}
.master-workspace .master-profile-identity .master-public-status.is-live{
  border-color:#b9ddc3;
}
.master-workspace .master-profile-identity .master-public-self{
  align-items:center;gap:18px;margin:0;
}
.master-workspace .master-profile-identity .master-owner-avatar{
  width:88px;height:96px;flex:0 0 88px;
  border-radius:19px;background:linear-gradient(135deg,#c9e4cf,#81b194);
  color:#1e5639;font-size:2.05rem;box-shadow:0 12px 27px #285b3820;
}
.master-workspace .master-profile-identity .master-public-self>div{min-width:0}
.master-workspace .master-profile-identity .master-public-self h2{
  font-size:clamp(1.3rem,2.25vw,1.85rem);letter-spacing:-.045em;
  color:#234d38;line-height:1.2;overflow-wrap:anywhere;
}
.master-workspace .master-profile-identity .master-public-self p{
  font-size:.82rem;line-height:1.6;color:#66806e;margin-top:9px;
}
.master-workspace .master-profile-identity .master-share-panel{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;
  margin:24px 0 0;padding:18px 0 0;border-top:1px solid #cddfce;
}
.master-workspace .master-profile-identity .master-share-panel .button{
  min-width:0;min-height:47px;margin:0;display:inline-flex;
  justify-content:center;align-items:center;gap:6px;
  padding:10px 11px;border-radius:12px;font-size:.78rem;
  font-weight:800;line-height:1.3;text-align:center;white-space:normal;
}
.master-workspace .master-profile-identity #masterNativeShare{
  order:-3;background:#285e45;color:#fff;border:1px solid #285e45;
  box-shadow:0 10px 24px #225b3924;
}
.master-workspace .master-profile-identity #masterNativeShare:hover{background:#1d4c35}
.master-workspace .master-profile-identity #masterCopyMyLink{
  order:-2;background:#fffefa;color:#285e45;border:1px solid #cbdfcf;
}
.master-workspace .master-profile-identity .master-share-panel>a{
  order:-1;grid-column:1/-1;background:#eef6ed;color:#31644a;border:1px solid #d3e6d5;
}
.master-workspace .master-profile-editor-panel #masterProfileEditForm{
  padding:25px 27px 27px;gap:15px;
}
.master-workspace .master-profile-editor-panel #masterProfileEditForm :is(input,textarea){
  border-radius:12px;max-width:100%;
}
.master-workspace .master-profile-editor-panel #masterProfileEditForm>button[type=submit]{
  min-height:47px;justify-self:start;
  border-radius:12px;padding-inline:24px;
}
.master-workspace .master-profile-editor-layout .master-public-gallery-panel{
  min-width:0;border-radius:24px;padding:26px;
  border:1px solid #e0e9df;background:#fffefa;
  box-shadow:0 13px 38px #234c330d;
}
.master-workspace .master-profile-editor-layout .master-public-gallery-panel>h2{
  color:#284f3a;font-size:1.3rem;letter-spacing:-.035em;
}
.master-workspace .master-profile-editor-layout .master-portfolio-tile{
  border-radius:16px;border-color:#dfe9df;
  box-shadow:0 8px 25px #2445320a;
}
.master-workspace .master-profile-editor-layout .master-portfolio-tile img{
  aspect-ratio:4/3;object-fit:cover;
}
.master-workspace .master-profile-editor-layout :is(
  #masterNativeShare,#masterCopyMyLink,.master-share-panel>a,
  #masterProfileEditForm button):focus-visible{
  outline:3px solid #79b899;outline-offset:3px;
}
@media(max-width:900px){
  .master-workspace .master-profile-editor-layout{grid-template-columns:1fr}
}
@media(max-width:650px){
  .master-workspace .master-profile-editor-layout{gap:14px}
  .master-workspace .master-profile-editor-panel,
  .master-workspace .master-profile-editor-layout .master-public-gallery-panel{border-radius:20px}
  .master-workspace .master-profile-identity{padding:19px 17px 20px}
  .master-workspace .master-profile-identity .master-owner-avatar{
    width:62px;height:68px;flex-basis:62px;border-radius:14px;font-size:1.65rem;
  }
  .master-workspace .master-profile-identity .master-public-self{gap:12px}
  .master-workspace .master-profile-identity .master-public-self h2{font-size:1.25rem}
  .master-workspace .master-profile-identity .master-public-self p{font-size:.75rem}
  .master-workspace .master-profile-identity .master-share-panel{
    gap:8px;margin-top:17px;padding-top:15px;
  }
  .master-workspace .master-profile-identity .master-share-panel .button{
    min-height:49px;font-size:.74rem;padding:9px 8px;
  }
  .master-workspace .master-profile-editor-panel #masterProfileEditForm{padding:20px 17px}
  .master-workspace .master-profile-editor-panel #masterProfileEditForm>button[type=submit]{
    width:100%;justify-content:center;
  }
  .master-workspace .master-profile-editor-layout .master-public-gallery-panel{padding:20px 17px}
}
@media(max-width:390px){
  .master-workspace .master-profile-identity .master-share-panel{grid-template-columns:1fr}
  .master-workspace .master-profile-identity .master-share-panel>a{grid-column:auto}
  .master-workspace .master-profile-editor-layout .master-portfolio-list{grid-template-columns:1fr}
}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-profile-identity .master-share-panel .button{transition:none}
}

/* Master-owned portrait picker; scoped to their editor and mobile workspace. */
.master-workspace .master-self-avatar-form{
  display:grid;gap:9px;margin:18px 0 0;
  padding:15px;border:1px solid #cfe0d3;border-radius:17px;
  background:#ffffffab;min-width:0;
}
.master-workspace .master-self-avatar-form strong{
  color:#22563e;font-size:.94rem;
}
.master-workspace .master-self-avatar-form label{
  font-size:.82rem;font-weight:750;color:#315b42;
}
.master-workspace .master-self-avatar-form input[type=file]{
  display:block;max-width:100%;min-width:0;
  color:#375744;font-size:.8rem;
}
.master-workspace .master-self-avatar-form input[type=file]::file-selector-button{
  padding:10px 12px;margin:0 10px 0 0;border-radius:11px;
  border:1px solid #bdd5c5;background:#f7fbf8;color:#255941;
  font-weight:750;cursor:pointer;
}
.master-workspace .master-self-avatar-form small{
  color:#647d6c;line-height:1.5;font-size:.75rem;
}
.master-workspace .master-self-avatar-form [role=status]{
  min-height:0;margin:0;color:#255b42;font-size:.78rem;
  overflow-wrap:anywhere;
}
.master-workspace .master-self-avatar-form button{
  display:inline-flex;align-items:center;justify-content:center;
  gap:8px;min-height:44px;justify-self:start;
}
.master-workspace .master-self-avatar-preview{
  width:110px;height:120px;object-fit:cover;border-radius:16px;
  border:2px solid #cce0d1;box-shadow:0 7px 18px #25553b16;
}
.master-workspace .master-self-avatar-preview[hidden]{display:none}
@media(max-width:650px){
  .master-workspace .master-self-avatar-form{padding:13px;margin-top:15px}
  .master-workspace .master-self-avatar-form button{width:100%;justify-self:stretch}
  .master-workspace .master-self-avatar-form input[type=file]{
    font-size:16px;max-width:100%;
  }
}

/* Android master dashboard audit: compact header, one-line brand, action
   panel and five equal bottom destinations. Scoped away from owner/public UI. */
@media(max-width:650px){
 .master-workspace .app-top{
   height:59px;min-height:59px;padding:6px 11px;gap:6px;
 }
 .master-workspace .mobile-brand{flex:1 1 auto;min-width:0}
 .master-workspace .mobile-brand .brand{
   white-space:nowrap;font-size:.87rem;gap:6px;
 }
 .master-workspace .mobile-brand .brand-mark{
   width:30px;height:30px;flex:0 0 30px;
 }
 .master-workspace .mobile-brand .brand-name{
   display:block;white-space:nowrap!important;line-height:1.12;max-width:none!important;
 }
 .master-workspace .mobile-brand .brand-name>span{display:inline!important}
 .master-workspace .app-top .top-actions{gap:5px;flex:0 0 auto}
 .master-workspace .inbox-top-link{width:34px;height:34px}
 .master-workspace .app-top .lang{min-height:35px;padding:7px;font-size:.68rem}
 .master-workspace .page{
   padding:10px 12px calc(94px + env(safe-area-inset-bottom));
 }
 .master-workspace .master-premium-dashboard{gap:11px}
 .master-studio-hero.master-premium-hero{
   padding:17px 15px;gap:12px;border-radius:19px;
 }
 .master-studio-hero .master-premium-hero-copy{gap:7px}
 .master-studio-hero .master-premium-eyebrow{
   font-size:.59rem;letter-spacing:.11em;
 }
 .master-studio-hero h1{font-size:clamp(1.62rem,6.4vw,2rem);line-height:1.15}
 .master-studio-hero p{font-size:.78rem;line-height:1.45}
 .master-studio-primary-actions{
   margin-top:5px;gap:7px;grid-template-columns:minmax(0,1.3fr) minmax(0,.88fr);
 }
 .master-studio-primary-actions .master-premium-new,
 .master-studio-share-button{
   min-height:43px;padding:8px 7px;font-size:.74rem;gap:6px;
 }
 .master-studio-primary-actions :is(button,button svg){max-width:100%}
 .master-studio-primary-actions svg{width:18px;height:18px}
 .master-studio-profile-card{padding:10px 11px;gap:7px}
 .master-studio-profile-top{flex:1 1 160px;gap:8px}
 .master-studio-profile-avatar{
   width:41px;height:43px;flex-basis:41px;border-radius:11px;
 }
 .master-studio-profile-copy>small{font-size:.6rem;line-height:1.2}
 .master-studio-profile-copy>strong{font-size:.85rem}
 .master-studio-profile-badge{font-size:.55rem;padding:3px 6px}
 .master-studio-edit-link{min-width:31px;height:34px}
 .master-workspace .master-premium-stats{gap:7px}
 .master-workspace .master-premium-stat{
   min-height:108px;padding:10px 9px;gap:4px;border-radius:14px;
 }
 .master-workspace .master-premium-stat-icon{
   width:30px;height:30px;margin-bottom:0;border-radius:9px;
 }
 .master-workspace .master-premium-stat-icon svg{width:17px;height:17px}
 .master-workspace .master-premium-stat-label{
   min-height:29px;font-size:.63rem;line-height:1.23;
 }
 .master-workspace .master-premium-stat strong{font-size:1.6rem}
 .master-workspace .bottomnav{
   grid-template-columns:repeat(5,minmax(0,1fr))!important;
   left:9px;right:9px;bottom:calc(7px + env(safe-area-inset-bottom));
   padding:6px!important;gap:3px;
 }
 .master-workspace .bottomnav>a,
 .master-workspace .bottomnav>.mobile-more-trigger{
   min-height:54px;gap:3px;padding:5px 1px!important;
   font-size:.64rem!important;white-space:nowrap;
 }
 .master-workspace .bottomnav .ico,
 .master-workspace .bottomnav .ico svg{width:21px;height:21px}
 .master-workspace .mobile-more-panel:not([hidden]){
   bottom:calc(84px + env(safe-area-inset-bottom));
 }
}
@media(max-width:370px){
 .master-workspace .app-top{padding:6px 8px}
 .master-workspace .mobile-brand .brand{font-size:.79rem;gap:4px}
 .master-workspace .mobile-brand .brand-mark{width:27px;height:27px;flex-basis:27px}
 .master-workspace .page{padding-inline:9px}
 .master-workspace .bottomnav{left:7px;right:7px;padding:5px!important;gap:2px}
 .master-workspace .bottomnav>a,
 .master-workspace .bottomnav>.mobile-more-trigger{font-size:.59rem!important;padding:4px 1px!important}
}

/* Small-screen finishing pass for master profile, inbox, and public Q&A.
   Scoped to these views; salon bookings and payment forms keep their own layouts. */
@media(max-width:650px){
  .master-workspace .page-header{gap:7px;align-items:flex-start}
  .master-workspace .page-header h1{
    font-size:clamp(1.42rem,6vw,1.68rem);line-height:1.18;
    letter-spacing:-.025em;overflow-wrap:anywhere;margin-top:2px
  }
  .master-workspace .page-desc{font-size:.79rem;line-height:1.45;margin-top:5px}
  .master-workspace .master-chat-inbox{gap:12px;min-width:0}
  .master-workspace .master-chat-inbox .card{
    min-width:0;padding:14px;border-radius:15px
  }
  .master-workspace .master-chat-inbox .section-title{
    gap:8px;margin-bottom:9px;align-items:flex-start;flex-wrap:wrap
  }
  .master-workspace .master-chat-inbox .section-title h2{
    font-size:1.12rem;line-height:1.25;overflow-wrap:anywhere
  }
  .master-workspace .master-chat-inbox .section-title .button{
    min-height:40px;padding:8px 10px;font-size:.78rem;border-radius:10px
  }
  .master-workspace .master-chat-thread-stack{margin-top:8px;gap:7px}
  .master-workspace .master-chat-thread-item{gap:4px;padding:10px 12px;border-radius:10px}
  .master-workspace .master-chat-client{font-size:.9rem}
  .master-workspace .master-chat-preview{font-size:.78rem}
  .master-workspace .master-chat-messages{
    max-height:320px;min-height:0;margin:8px 0;padding:11px 9px;
    gap:8px;border-radius:13px
  }
  .master-workspace .master-chat-bubble{
    max-width:90%;padding:9px 12px;border-radius:13px
  }
  .master-workspace .master-chat-bubble small{
    margin-bottom:3px;font-size:.66rem;opacity:.88
  }
  .master-workspace .master-chat-bubble p{font-size:.83rem;line-height:1.4}
  .master-workspace .master-chat-reply{gap:8px}
  .master-workspace .master-chat-reply textarea{
    min-height:72px;padding:9px 10px;font-size:.85rem
  }
  .master-workspace .master-chat-reply .button{
    min-height:42px;padding:8px 13px;font-size:.83rem;border-radius:10px
  }
  .master-workspace .master-contact-fieldset{
    min-width:0;margin:5px 0 14px;padding:12px 13px;
    border-radius:13px
  }
  .master-workspace .master-contact-fieldset legend{
    max-width:100%;padding:0 5px;font-size:.85rem;
    line-height:1.25;white-space:normal;overflow-wrap:anywhere
  }
  .master-workspace .master-contact-fieldset>p.muted{
    margin:2px 0 11px;font-size:.79rem;line-height:1.4
  }
  .master-workspace .master-contact-fieldset .field{gap:5px}
  .master-workspace .master-contact-fieldset .field label{font-size:.8rem}
  .master-workspace .master-contact-fieldset #masterWhatsappPhone{
    min-height:43px;padding:8px 11px;font-size:.85rem
  }
  .master-workspace .master-contact-fieldset label.privacy{
    margin-top:10px;gap:8px;font-size:.75rem;line-height:1.4
  }
  .master-workspace .master-contact-fieldset label.privacy input{
    width:19px;height:19px;min-height:19px;margin-top:1px
  }
  .master-workspace .master-profile-editor-panel #masterProfileEditForm{
    gap:12px
  }
  .master-workspace .master-profile-editor-panel #masterBio{
    min-height:105px;resize:vertical
  }
  .master-chat-public-section{padding:14px 0;scroll-margin-top:14px}
  .master-chat-public-card{padding:14px;border-radius:15px}
  .master-chat-public-card .fields{gap:11px}
  .master-chat-public-card textarea{min-height:78px}
  .master-chat-public-card .master-chat-messages{
    min-height:0;max-height:300px;padding:10px 8px;
    margin:10px 0;gap:8px
  }
  .master-chat-public-card .master-chat-utilities{
    margin-top:10px;gap:7px
  }
  .master-chat-public-card .master-chat-utilities .button{
    flex:1 1 130px;min-height:42px;padding:8px 10px;font-size:.79rem
  }
  .master-chat-public-card .master-chat-bubble{
    max-width:90%;padding:9px 11px;border-radius:13px
  }
  .master-chat-public-card .master-chat-bubble p{font-size:.83rem}
}

/* Staff workday quick access — live selected-day count, no hash navigation.
   All rules are scoped to the master's workspace. */
.master-workspace .master-studio-schedule-jump{
  display:inline-flex;align-items:center;justify-content:flex-start;
  gap:9px;max-width:100%;min-height:42px;padding:9px 13px;
  background:#fffefa;border:1px solid #c9dfcd;border-radius:11px;
  color:#265d43;font-size:.76rem;font-weight:760;line-height:1.3;
  text-align:left;cursor:pointer;box-shadow:0 4px 13px #244e3610;
}
.master-workspace .master-studio-schedule-jump span{
  flex:1;min-width:0;overflow-wrap:anywhere;
}
.master-workspace .master-studio-schedule-jump b{
  color:#174f36;font-weight:900;font-variant-numeric:tabular-nums;
}
.master-workspace .master-studio-schedule-jump > svg{flex:0 0 auto}
.master-workspace .master-studio-schedule-jump:hover{
  background:#f3faf4;border-color:#8bb89a;
}
.master-workspace .master-studio-schedule-jump:focus-visible{
  outline:3px solid #79b899;outline-offset:3px;
}
.master-workspace #masterVisitsTitle{
  scroll-margin-top:20px;
}
.master-workspace #masterVisitsTitle:focus-visible{outline:2px solid #79b899;outline-offset:4px}
@media(max-width:650px){
  .master-workspace .master-studio-schedule-jump{
    width:100%;min-height:41px;padding:8px 11px;
    font-size:.71rem;border-radius:10px;
  }
  .master-workspace .master-premium-diary{
    min-width:0;padding:12px 10px;border-radius:16px;
  }
  .master-workspace .master-premium-diary-head{
    margin-bottom:11px;gap:7px;
  }
  .master-workspace .master-premium-diary-head h2{
    font-size:1.14rem;
  }
  .master-workspace .master-premium-day-label{
    padding:6px 8px;font-size:.64rem;line-height:1.35;
  }
  .master-workspace .master-premium-calendar-filter{
    display:grid;grid-template-columns:minmax(0,1fr);
    gap:8px;margin-bottom:12px!important;
  }
  .master-workspace .master-premium-date-row{
    flex:initial;min-width:0;width:100%;gap:6px;
  }
  .master-workspace .master-premium-arrow{
    flex:0 0 40px;width:40px;height:43px;
    border-radius:10px;
  }
  .master-workspace .master-premium-date-field{
    min-width:0;min-height:43px;padding:0 7px;border-radius:10px;gap:5px;
  }
  .master-workspace .master-premium-date-field input[type=date]{
    min-width:0;width:100%;font-size:.86rem;min-height:42px;
  }
  .master-workspace .master-premium-date-actions{
    display:grid;grid-template-columns:repeat(3,minmax(0,1fr));
    min-width:0;width:100%;gap:6px;
  }
  .master-workspace .master-premium-date-quick{
    min-width:0;min-height:43px;padding:6px 5px;
    gap:5px;font-size:.68rem;line-height:1.2;
    white-space:normal;overflow-wrap:anywhere;text-align:center;
    border-radius:9px;
  }
  .master-workspace .master-premium-date-quick svg{
    width:15px;height:15px;flex:0 0 15px;
  }
  .master-workspace .master-premium-visits-header{
    padding-top:11px;margin-bottom:9px;gap:7px;
  }
  .master-workspace .master-premium-visits-header h2{font-size:1rem}
  .master-workspace .master-premium-visits-count{
    white-space:normal;text-align:right;font-size:.65rem;
    padding:5px 7px;
  }
  .master-workspace .master-workday-filters{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:6px;margin-bottom:11px;
  }
  .master-workspace .master-workday-filter{
    min-width:0;min-height:41px;padding:7px 5px;
    font-size:.69rem;line-height:1.25;
    white-space:normal;overflow-wrap:anywhere;
  }
  .master-workspace .master-premium-visit.master-visit{
    grid-template-columns:minmax(0,1fr);gap:8px;
    padding:10px;border-radius:12px;
  }
  .master-workspace .master-premium-visit-time{
    display:flex;align-items:baseline;gap:8px;
    min-width:0;border-right:0;border-bottom:1px solid #e8eee8;
    padding:0 0 6px;
  }
  .master-workspace .master-premium-visit-time strong{
    font-size:1.08rem;
  }
  .master-workspace .master-premium-visit-time span{
    font-size:.72rem;
  }
  .master-workspace .master-premium-visit-detail{min-width:0;gap:7px}
  .master-workspace .master-premium-visit .master-actions{
    display:grid;grid-template-columns:repeat(2,minmax(0,1fr));
    gap:6px;
  }
  .master-workspace .master-premium-visit .master-actions .button{
    min-width:0;min-height:39px;padding:7px 6px;
    font-size:.71rem;white-space:normal;overflow-wrap:anywhere;
  }
  .master-workspace .master-client-card{border-radius:11px}
  .master-workspace .master-client-card>summary{
    min-height:41px;padding:9px 10px;
  }
  .master-workspace .master-client-card-content{padding:2px 10px 11px}
}
@media(max-width:355px){
  .master-workspace .master-premium-date-quick{
    flex-direction:column;gap:3px;font-size:.63rem;
  }
  .master-workspace .master-workday-filter{font-size:.65rem}
}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-studio-schedule-jump{transition:none}
}

/* Master's work hours and absence planner. Staff-only, no owner/public impact. */
.master-workspace .master-timeoff-page{
  display:grid;gap:14px;min-width:0;
}
.master-workspace .master-timeoff-summary{
  display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;
}
.master-workspace .master-timeoff-summary>span{
  display:flex;align-items:center;gap:9px;min-width:0;
  padding:13px 15px;border:1px solid #e0e9df;border-radius:13px;
  background:#fffefa;color:#647d6e;font-size:.8rem;font-weight:750;
}
.master-workspace .master-timeoff-summary>span svg{
  flex:0 0 18px;color:#367954;
}
.master-workspace .master-timeoff-summary strong{
  margin-left:auto;color:#23563e;white-space:nowrap;
  font-size:1.03rem;font-variant-numeric:tabular-nums;
}
.master-workspace .master-timeoff-page .master-availability-grid{
  grid-template-columns:minmax(0,.92fr) minmax(0,1.08fr);gap:13px;min-width:0;
}
.master-workspace .master-timeoff-page .card{
  min-width:0;padding:18px;border-radius:15px;
  border:1px solid #e0e9e1;background:#fffefa;
  box-shadow:0 4px 18px #234a3708;
}
.master-workspace .master-timeoff-page h2{
  margin:0 0 8px;font-size:1.1rem;line-height:1.3;
  color:#214b38;overflow-wrap:anywhere;
}
.master-workspace .master-timeoff-page .muted{
  margin:0;font-size:.75rem;line-height:1.45;color:#788b7d;
}
.master-workspace .master-hours-list{
  display:grid;gap:0;margin-top:11px;border:1px solid #e4ece5;
  border-radius:10px;overflow:hidden;
}
.master-workspace .master-hours-row{
  display:flex;align-items:center;justify-content:space-between;
  gap:12px;min-height:40px;padding:9px 12px;
  border:0;border-bottom:1px solid #eaf0e9;
  background:#fff;color:#2f4f3c;font-size:.79rem;
}
.master-workspace .master-hours-row:last-child{border-bottom:0}
.master-workspace .master-hours-row b{font-weight:770}
.master-workspace .master-hours-row span{
  font-size:.75rem;font-weight:820;white-space:nowrap;
  color:#27674a;font-variant-numeric:tabular-nums;
}
.master-workspace .master-hours-row.is-day-off{
  background:#f8f9f6;color:#778a7d;
}
.master-workspace .master-hours-row.is-day-off span{
  color:#8c998d;font-weight:680;
}
.master-workspace .master-leave-create-panel #masterLeaveForm{
  display:grid;gap:10px;margin-top:10px;min-width:0;
}
.master-workspace .master-leave-create-panel .field{
  min-width:0;gap:5px;
}
.master-workspace .master-leave-create-panel .field label{
  color:#41624d;font-size:.75rem;font-weight:770;
}
.master-workspace .master-leave-create-panel :is(input,select){
  width:100%;min-width:0;max-width:100%;
  min-height:43px;padding:8px 10px;border-radius:10px;
  border:1px solid #d9e6d9;background:#fff;
  color:#294d39;font-size:.88rem;
}
.master-workspace .master-leave-create-panel .master-hour-pair{
  grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;
}
.master-workspace .master-leave-validation{
  margin:0;padding:10px 11px;min-width:0;
  border:1px solid #cfe4d5;border-radius:10px;
  color:#266244;background:#edf8f0;
  font-size:.78rem;line-height:1.45;font-weight:760;
  overflow-wrap:anywhere;
}
.master-workspace .master-leave-validation[data-kind="error"]{
  border-color:#efcfbf;color:#9b4636;background:#fff3ed;
}
.master-workspace .master-leave-limit{
  margin:0;color:#7c8c81;font-size:.7rem;line-height:1.5;
}
.master-workspace .master-leave-create-panel button[type=submit]{
  min-height:43px;justify-self:start;
  padding:9px 17px;border-radius:10px;font-weight:810;
}
.master-workspace .master-leave-create-panel button[disabled]{opacity:.55;cursor:not-allowed}
.master-workspace .master-slot-heading{
  display:flex;align-items:flex-start;justify-content:space-between;
  gap:12px;margin-bottom:11px;
}
.master-workspace .master-slot-heading>div{min-width:0}
.master-workspace .master-slot-readonly{
  display:inline-flex;align-items:center;flex:0 0 auto;
  border:1px solid #dbe6dd;border-radius:30px;
  padding:5px 9px;background:#f2f7f3;
  color:#66816e;font-size:.67rem;font-weight:780;
}
.master-workspace .master-slot-form{
  display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.2fr) auto;
  align-items:end;gap:10px;min-width:0;
}
.master-workspace .master-slot-form .field{min-width:0;gap:5px}
.master-workspace .master-slot-form .field label{
  color:#41624d;font-size:.75rem;font-weight:770;
}
.master-workspace .master-slot-form :is(input,select){
  min-width:0;width:100%;max-width:100%;min-height:44px;
  padding:8px 10px;border:1px solid #d9e6d9;
  border-radius:10px;background:#fff;
  color:#294d39;font-size:.85rem;
}
.master-workspace .master-slot-form button{
  display:inline-flex;justify-content:center;align-items:center;
  gap:7px;min-height:44px;padding:8px 13px;
  font-size:.77rem;white-space:nowrap;border-radius:10px;
}
.master-workspace .master-slot-results{
  min-width:0;margin-top:12px;padding:11px 12px;
  border-radius:11px;background:#f7faf6;border:1px solid #e4ede3;
  color:#617a67;font-size:.78rem;line-height:1.5;
  overflow-wrap:anywhere;
}
.master-workspace .master-slot-results p{margin:0 0 8px}
.master-workspace .master-slot-results p:last-child{margin-bottom:0}
.master-workspace .master-slot-results strong{color:#295d40}
.master-workspace .master-slot-times{
  display:flex;flex-wrap:wrap;gap:7px;
}
.master-workspace .master-slot-times span{
  display:inline-flex;align-items:center;justify-content:center;
  min-width:66px;padding:7px 10px;
  border:1px solid #cfe2d1;border-radius:8px;
  background:#fff;color:#2c6847;font-weight:790;
  font-size:.8rem;font-variant-numeric:tabular-nums;
}
.master-workspace .master-leaves-heading{
  display:flex;align-items:center;justify-content:space-between;
  gap:10px;margin-bottom:10px;
}
.master-workspace .master-leaves-heading h2{margin:0}
.master-workspace .master-leaves-heading span{
  display:grid;place-items:center;min-width:27px;height:27px;
  padding:0 6px;border-radius:8px;background:#ecf5ed;
  color:#306c4c;font-size:.8rem;font-weight:850;
}
.master-workspace .master-leaves .stack{display:grid;gap:7px}
.master-workspace .master-leave-row{
  display:flex;align-items:center;justify-content:space-between;
  gap:10px;flex-wrap:wrap;min-width:0;
  padding:11px 12px;border:1px solid #e7eee8;
  border-radius:10px;background:#fafcf9;
}
.master-workspace .master-leave-row>div{min-width:0}
.master-workspace .master-leave-row b{
  font-size:.78rem;color:#30543b;overflow-wrap:anywhere;
}
.master-workspace .master-leave-row .item-sub{
  color:#7d907f;font-size:.73rem;overflow-wrap:anywhere;
}
.master-workspace .master-leave-row button{
  min-height:36px;padding:7px 11px;border-radius:8px;
  font-size:.73rem;white-space:normal;
}
.master-workspace .master-timeoff-page :is(input,select,button):focus-visible{
  outline:3px solid #80b99a;outline-offset:2px;
}
@media(max-width:900px){
  .master-workspace .master-timeoff-page .master-availability-grid{
    grid-template-columns:minmax(0,1fr);
  }
}
@media(max-width:650px){
  .master-workspace .master-timeoff-page{gap:9px}
  .master-workspace .master-timeoff-summary{gap:7px}
  .master-workspace .master-timeoff-summary>span{
    flex-wrap:wrap;gap:6px;padding:10px;
    min-height:58px;border-radius:11px;
    font-size:.66rem;line-height:1.3;
  }
  .master-workspace .master-timeoff-summary strong{font-size:.94rem}
  .master-workspace .master-timeoff-page .card{
    padding:12px;border-radius:12px;
  }
  .master-workspace .master-timeoff-page h2{font-size:1rem}
  .master-workspace .master-hours-row{
    min-height:38px;padding:8px 10px;font-size:.73rem;
  }
  .master-workspace .master-hours-row span{font-size:.72rem}
  .master-workspace .master-leave-create-panel #masterLeaveForm{
    gap:8px;
  }
  .master-workspace .master-leave-create-panel button[type=submit]{
    width:100%;justify-self:stretch;min-height:43px;
  }
  .master-workspace .master-slot-heading{
    flex-wrap:wrap;gap:7px;
  }
  .master-workspace .master-slot-form{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
  }
  .master-workspace .master-slot-form .field:nth-child(2){min-width:0}
  .master-workspace .master-slot-form button{
    grid-column:1/-1;min-width:0;width:100%;
  }
  .master-workspace .master-slot-readonly{font-size:.63rem}
  .master-workspace .master-slot-results{padding:10px;margin-top:9px}
  .master-workspace .master-slot-times{gap:6px}
  .master-workspace .master-slot-times span{
    min-width:60px;padding:6px 8px;font-size:.75rem;
  }
  .master-workspace .master-leave-row{
    padding:9px;gap:7px;
  }
  .master-workspace .master-leave-row button{
    min-height:36px;
  }
}
@media(max-width:355px){
  .master-workspace .master-timeoff-summary>span{
    align-content:start;font-size:.61rem;padding:8px;
  }
  .master-workspace .master-timeoff-summary>span svg{width:15px;height:15px}
  .master-workspace .master-slot-form{grid-template-columns:minmax(0,1fr)}
  .master-workspace .master-slot-form button{grid-column:auto}
}

/* Staff appointment history — on-demand read-only data for the assigned master. */
.master-workspace .master-client-history{
  display:grid;gap:8px;min-width:0;
}
.master-workspace .master-client-history-toggle{
  display:flex;align-items:center;gap:9px;width:100%;
  min-height:43px;padding:9px 12px;border:1px solid #d5e6d8;
  border-radius:11px;background:#fffefa;color:#2e6248;
  cursor:pointer;font:inherit;font-size:.76rem;font-weight:820;
  text-align:left;line-height:1.3;
}
.master-workspace .master-client-history-toggle>span{
  flex:1;min-width:0;overflow-wrap:anywhere;
}
.master-workspace .master-client-history-toggle>svg{flex:0 0 16px}
.master-workspace .master-client-history-toggle>svg:last-child{
  transition:transform .18s ease;
}
.master-workspace .master-client-history-toggle[aria-expanded="true"]>svg:last-child{
  transform:rotate(180deg);
}
.master-workspace .master-client-history-toggle:hover{
  background:#eff8f0;border-color:#accfb8;
}
.master-workspace .master-client-history-toggle:focus-visible,
.master-workspace .master-client-card-link.is-reminder:focus-visible{
  outline:3px solid #79b899;outline-offset:2px;
}
.master-workspace .master-client-history-toggle:disabled{
  cursor:progress;opacity:.68;
}
.master-workspace .master-client-history-results{
  display:grid;gap:10px;min-width:0;
  padding:11px;border-radius:11px;
  border:1px solid #e0eae0;background:#f6faf6;
  color:#5c7565;font-size:.76rem;
}
.master-workspace .master-client-history-results[hidden]{display:none}
.master-workspace .master-client-history-stats{
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));
  gap:5px;min-width:0;
}
.master-workspace .master-client-history-stats>span{
  display:grid;align-content:start;gap:4px;
  min-width:0;padding:8px 6px;border-radius:8px;
  background:#fff;border:1px solid #e0ebe0;
  color:#6c8272;text-align:center;
  font-size:.63rem;line-height:1.3;overflow-wrap:anywhere;
}
.master-workspace .master-client-history-stats b{
  color:#245f42;font-size:.97rem;font-variant-numeric:tabular-nums;
}
.master-workspace .master-client-history-visits{
  display:grid;gap:0;list-style:none;padding:0;margin:0;
  border:1px solid #e1ebe2;border-radius:9px;overflow:hidden;
}
.master-workspace .master-client-history-visits li{
  display:flex;align-items:center;justify-content:space-between;
  min-width:0;gap:9px;padding:9px 10px;background:#fff;
  border-bottom:1px solid #edf1ec;
}
.master-workspace .master-client-history-visits li:last-child{border-bottom:0}
.master-workspace .master-client-history-visits li>span:first-child{
  display:grid;gap:4px;min-width:0;overflow-wrap:anywhere;
}
.master-workspace .master-client-history-visits strong{
  color:#31553d;font-size:.74rem;font-weight:820;
}
.master-workspace .master-client-history-visits small{
  color:#788b7b;font-size:.71rem;
}
.master-workspace .master-client-history-visits .status{
  flex:0 0 auto;max-width:42%;text-align:center;
  font-size:.66rem;padding:5px 7px;white-space:normal;
}
.master-workspace .master-client-history-empty{
  margin:0;line-height:1.5;color:#78917c;font-size:.74rem;
}
.master-workspace .master-client-card-link.is-reminder{
  background:#fff8eb;border-color:#e5d4b3;color:#80622f;
  grid-column:1/-1;
}
.master-workspace .master-client-card-link.is-reminder:hover{
  background:#fff1d4;border-color:#cdb581;
}
@media(max-width:650px){
  .master-workspace .master-client-history-toggle{
    min-height:43px;padding:9px 10px;font-size:.74rem;
  }
  .master-workspace .master-client-history-results{
    padding:8px;gap:8px;
  }
  .master-workspace .master-client-history-stats{gap:4px}
  .master-workspace .master-client-history-stats>span{
    padding:7px 4px;font-size:.6rem;
  }
  .master-workspace .master-client-history-visits li{
    padding:8px;gap:6px;
  }
  .master-workspace .master-client-history-visits strong{font-size:.69rem}
}
@media(max-width:355px){
  .master-workspace .master-client-history-stats{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
  .master-workspace .master-client-history-stats>span{font-size:.56rem}
  .master-workspace .master-client-history-visits .status{font-size:.59rem}
}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-client-history-toggle>svg:last-child{
    transition:none;
  }
}

/* Staff-only follow-up booking: reuse the tested appointment form safely. */
.master-workspace .master-repeat-booking{
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  width:100%;min-height:42px;margin-top:4px;
  padding:9px 12px;border:1px solid #b6d8bd;border-radius:10px;
  background:#edf8ee;color:#296848;font-weight:790;
  font-size:.75rem;line-height:1.3;text-align:center;
}
.master-workspace .master-repeat-booking:hover{
  border-color:#8cbb9a;background:#e5f5e8;
}
.master-workspace .master-repeat-booking:focus-visible{
  outline:3px solid #7cb795;outline-offset:3px;
}
/* The dialog is outside .master-workspace, but has its own scoped backdrop. */
.master-booking-backdrop .master-repeat-client{
  display:flex;align-items:center;gap:10px;min-width:0;
  padding:11px 12px;margin-bottom:3px;
  border:1px solid #d6e7d7;border-radius:11px;background:#f3faf4;
  color:#397454;
}
.master-booking-backdrop .master-repeat-client>span{
  flex:1;min-width:0;display:grid;gap:3px;
}
.master-booking-backdrop .master-repeat-client small{
  font-size:.72rem;color:#728c77;font-weight:690;
}
.master-booking-backdrop .master-repeat-client strong{
  font-size:.86rem;font-weight:850;color:#23563a;overflow-wrap:anywhere;
}
.master-booking-backdrop .master-repeat-client>svg{
  flex:0 0 auto;
}
@media(max-width:650px){
  .master-workspace .master-repeat-booking{
    min-height:41px;font-size:.71rem;padding:8px 9px;
  }
  .master-booking-backdrop .master-repeat-client{
    padding:10px;gap:8px;
  }
}

/* Staff-only weekly date navigation and private booking search. */
.master-workspace .master-week-strip{
  display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:7px;
  min-width:0;margin:0 0 15px;
}
.master-workspace .master-week-day{
  display:grid;place-items:center;align-content:center;gap:5px;
  min-width:0;min-height:65px;padding:8px 2px;
  border:1px solid #e1ebe2;border-radius:12px;
  color:#637d6c;background:#f7faf6;
  font:inherit;cursor:pointer;text-align:center;
}
.master-workspace .master-week-day span{
  max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  font-size:.68rem;font-weight:730;line-height:1.1;
}
.master-workspace .master-week-day strong{
  font-size:1.03rem;font-weight:850;line-height:1.2;font-variant-numeric:tabular-nums;
}
.master-workspace .master-week-day.is-today:not(.is-selected){
  border-color:#a4c7ac;color:#29694b;background:#f0f8f0;
}
.master-workspace .master-week-day.is-selected{
  background:#2f694b;color:#fff;border-color:#2f694b;
  box-shadow:0 6px 17px #2f694b30;
}
.master-workspace .master-week-day:hover:not(.is-selected){
  background:#ebf5ec;border-color:#a4c8af;
}
.master-workspace .master-search-panel{
  display:grid;gap:8px;min-width:0;
  margin:0 0 18px;padding:14px;
  border:1px solid #dae8dc;border-radius:14px;background:#f8fbf8;
}
.master-workspace .master-search-form{display:grid;gap:7px;min-width:0}
.master-workspace .master-search-form>label{
  color:#315841;font-size:.83rem;font-weight:850;
}
.master-workspace .master-search-controls{
  display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;
  min-width:0;align-items:center;
}
.master-workspace .master-search-controls input{
  min-width:0;width:100%;min-height:44px;
  padding:9px 12px;border-radius:10px;border:1px solid #d4e1d5;
  font:inherit;font-size:.84rem;color:#264b34;background:#fff;
}
.master-workspace .master-search-controls button{
  display:inline-flex;align-items:center;justify-content:center;gap:7px;
  min-height:44px;padding:9px 15px;font-size:.76rem;font-weight:790;
  white-space:nowrap;border-radius:10px;
}
.master-workspace .master-search-hint{
  margin:0;color:#829388;font-size:.68rem;line-height:1.4;
}
.master-workspace .master-search-results{
  display:grid;gap:8px;min-width:0;padding:9px;
  border:1px solid #e2eae1;border-radius:11px;background:#fff;
}
.master-workspace .master-search-results[hidden]{display:none}
.master-workspace .master-search-results-head{
  display:flex;align-items:center;justify-content:space-between;
  gap:8px;flex-wrap:wrap;color:#3c6449;font-size:.75rem;
}
.master-workspace .master-search-results-head small{
  color:#8a7048;font-size:.68rem;
}
.master-workspace .master-search-hits{display:grid;gap:5px;min-width:0}
.master-workspace .master-search-hit{
  display:grid;grid-template-columns:minmax(0,1fr) auto 16px;
  align-items:center;gap:10px;width:100%;min-width:0;
  padding:10px;border:1px solid #e4ece3;border-radius:9px;
  background:#fcfdfa;color:#315841;font:inherit;cursor:pointer;text-align:left;
}
.master-workspace .master-search-hit:hover{
  background:#eef7ef;border-color:#add0b7;
}
.master-workspace .master-search-hit>span{
  min-width:0;display:grid;gap:3px;
}
.master-workspace .master-search-hit>span:nth-child(2){text-align:right}
.master-workspace .master-search-hit strong{
  font-size:.77rem;font-weight:820;overflow-wrap:anywhere;
}
.master-workspace .master-search-hit b{
  font-size:.73rem;font-weight:810;white-space:nowrap;
}
.master-workspace .master-search-hit small{
  font-size:.67rem;color:#7c9080;overflow-wrap:anywhere;
}
.master-workspace .master-search-hit svg{width:16px;height:16px;flex:0 0 16px}
.master-workspace .master-search-empty{
  margin:2px 0;color:#748676;font-size:.77rem;
}
.master-workspace .master-next-open{
  width:100%;min-width:0;font:inherit;text-align:left;cursor:pointer;
  color:inherit;
}
.master-workspace .master-next-open-copy{
  flex:1;min-width:0;display:grid;gap:3px;overflow-wrap:anywhere;
}
.master-workspace .master-next-open-copy strong{
  color:#355a41;font-size:.8rem;
}
.master-workspace .master-next-open-copy small{
  color:#788a7a;font-size:.7rem;
}
.master-workspace .master-next-open>svg:last-child{
  width:16px;height:16px;flex:0 0 16px;color:#47835f;
}
.master-workspace .master-next-open:hover{background:#edf7ed;border-color:#b3d1b8}
.master-workspace .master-premium-visit.master-search-highlight{
  border-color:#3f9360;border-left-color:#267a49;
  background:#f2fbf3;
  box-shadow:0 0 0 3px #86c99a66,0 10px 26px #245c3820;
  scroll-margin-top:16px;
}
.master-workspace :is(.master-week-day,.master-search-hit,.master-search-controls input,
 .master-search-controls button,.master-next-open):focus-visible,
.master-workspace .master-premium-visit.master-search-highlight:focus-visible{
  outline:3px solid #79b997;outline-offset:2px;
}
@media(max-width:650px){
  .master-workspace .master-week-strip{gap:4px;margin-bottom:11px}
  .master-workspace .master-week-day{
    min-height:52px;padding:6px 1px;border-radius:9px;gap:4px;
  }
  .master-workspace .master-week-day span{font-size:.57rem}
  .master-workspace .master-week-day strong{font-size:.92rem}
  .master-workspace .master-search-panel{
    padding:10px;gap:7px;margin-bottom:12px;border-radius:11px;
  }
  .master-workspace .master-search-controls{gap:6px}
  .master-workspace .master-search-controls input{
    min-height:43px;padding:7px 9px;font-size:.78rem;
  }
  .master-workspace .master-search-controls button{
    min-height:43px;padding:7px 10px;font-size:.69rem;
  }
  .master-workspace .master-search-hit{
    padding:9px 7px;gap:6px;
  }
  .master-workspace .master-search-hit strong{font-size:.71rem}
  .master-workspace .master-search-hit b{font-size:.67rem}
  .master-workspace .master-search-hit small{font-size:.62rem}
}
@media(max-width:355px){
  .master-workspace .master-week-day span{font-size:.51rem}
  .master-workspace .master-week-day strong{font-size:.85rem}
  .master-workspace .master-search-hit{
    grid-template-columns:minmax(0,1fr) auto;gap:6px;
  }
  .master-workspace .master-search-hit>svg:last-child{display:none}
  .master-workspace .master-search-controls button{padding:7px 8px}
}
@media(prefers-reduced-motion:reduce){
  .master-workspace .master-premium-visit.master-search-highlight{scroll-behavior:auto}
}


/* Selected-day staff quick focus: open the actual current or next visit,
   never infer a new booking or expose other masters' private information. */
.master-workspace .master-focus-visit{
  display:grid;grid-template-columns:46px minmax(0,1fr) auto;
  align-items:center;gap:12px;width:100%;min-width:0;
  padding:13px 15px;margin:0;border:1px solid #b9d8c2;border-radius:15px;
  background:linear-gradient(115deg,#f0faf2,#fffefa);color:#275540;
  box-shadow:0 5px 22px #275c3f0a;font:inherit;text-align:left;cursor:pointer;
}
.master-workspace .master-focus-visit:hover{background:#eaf8ee;border-color:#89b79a}
.master-workspace .master-focus-visit:focus-visible{
  outline:3px solid #75b68e;outline-offset:3px;
}
.master-workspace .master-focus-symbol{
  display:grid;place-items:center;width:44px;height:44px;
  border-radius:12px;background:#dcefe0;color:#276d45;
}
.master-workspace .master-focus-copy{
  display:grid;gap:3px;min-width:0;overflow-wrap:anywhere;
}
.master-workspace .master-focus-copy small{
  font-size:.69rem;font-weight:850;color:#438262;line-height:1.3;
}
.master-workspace .master-focus-copy strong{
  font-size:.94rem;color:#234f38;line-height:1.3;
}
.master-workspace .master-focus-copy>span{
  color:#627c68;font-size:.76rem;line-height:1.35;
}
.master-workspace .master-focus-cta{
  display:inline-flex;align-items:center;justify-content:center;gap:6px;
  min-height:42px;padding:7px 10px;border-radius:10px;
  background:#dbeee0;color:#286844;font-size:.72rem;
  font-weight:820;line-height:1.25;text-align:center;
}
.master-workspace .master-focus-cta svg{width:16px;height:16px;flex:0 0 16px}
@media(max-width:650px){
  .master-workspace .master-focus-visit{
    grid-template-columns:38px minmax(0,1fr);gap:9px;
    padding:11px;min-height:86px;border-radius:12px;
  }
  .master-workspace .master-focus-symbol{
    width:38px;height:38px;border-radius:10px;
  }
  .master-workspace .master-focus-copy strong{font-size:.85rem}
  .master-workspace .master-focus-copy>span{font-size:.7rem}
  .master-workspace .master-focus-cta{
    grid-column:2;justify-self:start;min-height:35px;
    padding:5px 9px;font-size:.68rem;
  }
}


/* Staff visit outcome: explicit reversible confirmation, no automatic writes. */
.master-workspace .master-status-tools{
  display:grid;gap:9px;min-width:0;
}
.master-workspace .master-status-review{
  display:grid;grid-template-columns:minmax(0,1fr) auto;
  align-items:center;gap:5px 9px;min-width:0;
  padding:11px 12px;border:1px solid #e2c68f;border-radius:11px;
  background:#fff9e9;color:#795727;
}
.master-workspace .master-status-review[hidden]{display:none!important}
.master-workspace .master-status-review strong{
  min-width:0;font-size:.79rem;line-height:1.35;
  font-weight:850;overflow-wrap:anywhere;
}
.master-workspace .master-status-review>span{
  grid-column:1;grid-row:2;min-width:0;
  color:#876b40;font-size:.7rem;line-height:1.4;
}
.master-workspace .master-status-review [data-master-status-cancel]{
  grid-column:2;grid-row:1/3;
  min-height:44px;padding:8px 12px;white-space:nowrap;
  font-size:.72rem;border-color:#d7b879;
}
.master-workspace .master-status-tools [data-master-appointment]:focus-visible,
.master-workspace .master-status-review [data-master-status-cancel]:focus-visible{
  outline:3px solid #c6a869;outline-offset:2px;
}
@media(max-width:650px){
  .master-workspace .master-status-tools .master-actions .button{
    min-height:44px;line-height:1.25;
  }
  .master-workspace .master-status-review{
    grid-template-columns:minmax(0,1fr) auto;
    gap:5px 7px;padding:9px;border-radius:10px;
  }
  .master-workspace .master-status-review strong{font-size:.72rem}
  .master-workspace .master-status-review>span{font-size:.64rem}
  .master-workspace .master-status-review [data-master-status-cancel]{
    min-height:44px;padding:7px 9px;font-size:.69rem;
  }
}
@media(max-width:355px){
  .master-workspace .master-status-review{grid-template-columns:minmax(0,1fr)}
  .master-workspace .master-status-review>span{grid-column:1;grid-row:auto}
  .master-workspace .master-status-review [data-master-status-cancel]{
    grid-column:1;grid-row:auto;justify-self:start;
  }
}


/* Staff workday pulse: compact, scoped shortcuts from real selected-day rows. */
.master-workspace .master-day-pulse{
  display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;min-width:0;
}
.master-workspace .master-pulse-card{
  display:grid;align-content:center;justify-items:start;gap:5px;min-width:0;
  min-height:76px;padding:11px 13px;border:1px solid #d6e6da;
  border-radius:12px;background:#f4faf5;color:#2e6547;
  font:inherit;text-align:left;cursor:pointer;
}
.master-workspace .master-pulse-card-action{
  background:#fffaf0;border-color:#e7d9b7;color:#8b652e;
}
.master-workspace .master-pulse-card-next{
  background:#f6f8fb;border-color:#d8e3ea;color:#365d72;
}
.master-workspace .master-pulse-card:not(:disabled):hover{
  border-color:#8fbd9e;box-shadow:0 3px 13px #274f3514;
}
.master-workspace .master-pulse-card[aria-pressed="true"]{
  border-color:#3d885c;box-shadow:inset 0 0 0 1px #3d885c;
}
.master-workspace .master-pulse-card:disabled{
  opacity:.65;cursor:default;
}
.master-workspace .master-pulse-card:focus-visible{
  outline:3px solid #78b792;outline-offset:2px;
}
.master-workspace .master-pulse-label{
  min-width:0;max-width:100%;font-size:.73rem;font-weight:760;
  line-height:1.3;overflow-wrap:anywhere;
}
.master-workspace .master-pulse-value{
  min-width:0;max-width:100%;font-size:1.3rem;font-weight:880;
  line-height:1.14;font-variant-numeric:tabular-nums;
}
@media(max-width:650px){
  .master-workspace .master-day-pulse{gap:6px}
  .master-workspace .master-pulse-card{
    min-height:68px;padding:9px 8px;border-radius:10px;gap:5px;
  }
  .master-workspace .master-pulse-label{font-size:.68rem}
  .master-workspace .master-pulse-value{font-size:1.12rem}
}
@media(max-width:355px){
  .master-workspace .master-day-pulse{gap:5px}
  .master-workspace .master-pulse-card{padding:8px 5px}
  .master-workspace .master-pulse-label{font-size:.62rem}
  .master-workspace .master-pulse-value{font-size:1.04rem}
}


/* Mobile master client history: never lock collapse during private fetch;
   distinguish the latest five rows from the full historical totals. */
.master-workspace .master-client-history-toggle{
  min-height:44px;
}
.master-workspace .master-client-history-results[aria-busy="true"]{
  border-style:dashed;
  border-color:#b4ceb8;
  background:#f5faf6;
}
.master-workspace .master-client-history-latest{
  display:flex;align-items:center;gap:4px;flex-wrap:wrap;
  margin:0;padding:4px 2px 0;min-width:0;
  color:#627c6c;font-size:.72rem;font-weight:690;
  line-height:1.35;
}
.master-workspace .master-client-history-latest b{
  color:#245e42;font-size:.77rem;font-weight:840;
  font-variant-numeric:tabular-nums;
}
@media(max-width:650px){
  .master-workspace .master-client-history-toggle{
    min-height:44px;
  }
  .master-workspace .master-client-history-visits li{
    min-height:44px;
  }
}
@media(max-width:355px){
  .master-workspace .master-client-history-visits li{
    display:grid;grid-template-columns:minmax(0,1fr);align-items:start;gap:6px;
  }
  .master-workspace .master-client-history-visits li .status{
    justify-self:start;max-width:100%;white-space:normal;
  }
}
