html{scrollbar-gutter:stable}
@media(min-width:1024px){
  #app:has(>.workspace-nav)>:is(.app-topbar,.workspace-nav,.customer-layout,.ready-layout,.footer){width:90%;max-width:none;margin-left:auto;margin-right:auto;padding-left:0;padding-right:0}
  #app:has(>.workspace-nav)>.workspace-nav a{padding-left:0;padding-right:0}
}
.workspace-nav{max-width:1216px;margin:auto;display:flex;gap:26px;padding:0 24px;border-bottom:1px solid var(--line)}
.workspace-nav a{min-height:52px;display:flex;align-items:center;text-decoration:none;color:var(--muted);font-size:14px;border-bottom:2px solid transparent;padding:0 3px}
.workspace-nav a[aria-current=page]{border-color:var(--green);color:var(--green);font-weight:650}
.customer-layout,.ready-layout{max-width:1152px;margin-left:auto;margin-right:auto;padding-left:28px;padding-right:28px;min-width:0}
.customer-layout{margin-top:36px;margin-bottom:60px}
.customer-heading{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-bottom:28px}
.customer-heading h1{font-family:Georgia,serif;font-size:42px;letter-spacing:-1px;margin:0 0 10px;overflow-wrap:anywhere}
.customer-heading h1[tabindex="-1"]:focus{outline:none}
.customer-heading .eyebrow{margin-bottom:11px}.customer-heading p:last-child{font-size:14px;color:var(--muted);margin:0}
.customer-heading>.btn{flex-shrink:0}.customer-panel{background:var(--white);border:1px solid var(--line);border-radius:18px;overflow:hidden}
.customer-toolbar{padding:24px;display:grid;grid-template-columns:minmax(0,1fr) 210px;gap:24px;border-bottom:1px solid var(--line);align-items:end}
.customer-toolbar label{display:block;font-size:12px;font-weight:600;margin-bottom:8px}.customer-search-controls{display:flex;gap:10px}
.customer-search-controls input{min-width:0}.customer-search-controls .btn{min-width:68px;padding:10px 16px}.customer-filter{min-width:0}
.customer-result-count{padding:17px 24px;color:var(--muted);font-size:12px;overflow-wrap:anywhere}
.customer-columns,.customer-row{display:grid;grid-template-columns:minmax(0,1.1fr) 175px minmax(0,1fr) 113px;gap:22px;align-items:center;padding:17px 24px}
.customer-columns{background:#f2f4ed;color:var(--muted);font-size:10px;font-weight:650;letter-spacing:1.1px;padding-top:11px;padding-bottom:11px}
.customer-list{margin:0;padding:0;list-style:none}.customer-row{min-height:100px;border-bottom:1px solid #e8e9e1}.customer-row:last-child{border-bottom:0}
.customer-identity{display:flex;gap:13px;align-items:center;min-width:0}.customer-identity>div{min-width:0}
.customer-avatar{width:42px;height:42px;background:#e7eedf;color:var(--green);border-radius:13px;display:grid;place-items:center;font-size:13px;font-weight:650;flex-shrink:0}
.customer-name{font-size:15px;font-weight:650;text-decoration:none;overflow-wrap:anywhere}.customer-name:hover{text-decoration:underline}
.customer-phone{font-size:13px;white-space:nowrap;text-decoration:none;min-height:44px;display:flex;align-items:center;font-variant-numeric:tabular-nums}
.customer-phone:hover{text-decoration:underline}.customer-note{font-size:12px;color:var(--muted);line-height:1.6;margin:0;overflow-wrap:anywhere;white-space:pre-line;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.customer-open{font-size:12px;padding:9px 5px;gap:6px}.customer-open svg{width:16px;height:16px}
.customer-badge{display:block;width:fit-content;background:#eee7dc;color:#79613f;border-radius:5px;font-size:10px;font-weight:650;padding:3px 7px;margin-top:5px}
.customer-heading>.customer-badge{font-size:12px;flex-shrink:0;padding:6px 11px}.customer-pagination{display:flex;align-items:center;justify-content:space-between;gap:12px;border-top:1px solid var(--line);padding:18px 24px}
.customer-pagination .btn{font-size:12px;min-height:44px;padding:8px 12px}.customer-pagination span{font-size:12px;color:var(--muted)}
.customer-loading{padding:50px 24px;text-align:center;font-size:14px;color:var(--muted);margin:0}
.customer-empty{text-align:center;padding:50px 24px 60px;max-width:480px;margin:auto}.customer-empty h2{font:26px Georgia,serif;letter-spacing:-.5px;margin:18px 0 12px}
.customer-empty p{font-size:14px;color:var(--muted);margin-bottom:24px}.customer-empty-symbol{width:56px;height:56px;border-radius:18px;background:var(--wash);color:var(--green);display:grid;place-items:center;margin:auto}
.customer-empty .btn{font-size:14px}.customer-editor{max-width:800px}.customer-back{display:inline-flex;align-items:center;gap:6px;min-height:44px;font-size:13px;text-decoration:none;color:var(--muted);margin-bottom:20px}
.customer-back:hover{color:var(--green)}.customer-form-card{padding:28px;background:var(--white);border:1px solid var(--line);border-radius:18px}
.customer-fields{margin:0;padding:0;border:0;min-width:0}.customer-fields:disabled input,.customer-fields:disabled textarea{background:#f4f4ee;color:#64716b;opacity:1}
.customer-note-meta{display:flex;justify-content:space-between;gap:10px;font-size:11px;color:var(--muted);margin-top:8px}
.customer-form-footer{border-top:1px solid var(--line);padding-top:22px;display:flex;align-items:center;justify-content:space-between;gap:20px}
.customer-form-footer .save-status{max-width:160px;line-height:1.5}.customer-form-footer>div{display:flex;align-items:center;gap:8px}.customer-form-footer .btn{font-size:13px;padding:12px 14px}
.customer-record-footer{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:20px}.customer-record-footer p{font-size:12px;color:var(--muted);margin:0}
.customer-record-footer .btn{font-size:12px;min-height:44px}.customer-archive{color:#875342;background:transparent;border-color:#d7cfc1}.customer-archive:hover:not(:disabled){background:#f4e9de}
textarea[aria-invalid=true]{border-color:var(--error)}
.customer-dialog{width:min(440px,calc(100% - 32px));border:1px solid var(--line);border-radius:18px;padding:28px;background:var(--white);color:var(--ink);box-shadow:0 20px 70px #18392b30}.customer-dialog::backdrop{background:#142d2366}.customer-dialog h2{font:27px Georgia,serif;letter-spacing:-.5px;line-height:1.2;margin-bottom:15px}.customer-dialog p{font-size:14px;color:var(--muted);overflow-wrap:anywhere;margin-bottom:24px}.customer-dialog form{display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap}.customer-dialog .btn{font-size:13px;padding:12px 16px}
@media(max-width:600px){.customer-layout,.ready-layout{padding-left:16px;padding-right:16px}}
@media(max-width:850px){.customer-columns,.customer-row{grid-template-columns:minmax(0,1fr) 165px 105px;gap:14px}.customer-columns span:nth-child(3){display:none}.customer-note{grid-column:1/-1;grid-row:2;margin-left:55px}.customer-row{padding-top:20px;padding-bottom:20px}.customer-open{grid-column:3;grid-row:1}}
@media(max-width:600px){.workspace-nav{padding:0 20px;gap:24px}.workspace-nav a{font-size:13px;min-height:49px}.customer-layout{margin-top:25px;padding:0 16px;margin-bottom:36px}.customer-heading{flex-wrap:wrap;gap:18px;margin-bottom:22px}.customer-heading h1{font-size:34px}.customer-heading>.btn{width:100%}.customer-heading>.customer-badge{margin:0}.customer-heading .eyebrow{font-size:10px;letter-spacing:1.6px}.customer-toolbar{padding:18px;grid-template-columns:1fr;gap:15px}.customer-filter{display:flex;gap:12px;align-items:center}.customer-filter label{margin:0;flex-shrink:0}.customer-filter select{min-height:44px;font-size:14px;padding:9px 10px}.customer-result-count{padding:15px 18px}.customer-columns{display:none}.customer-row{grid-template-columns:minmax(0,1fr) auto;gap:0 10px;padding:18px}.customer-identity{grid-column:1/-1;grid-row:1;align-items:flex-start}.customer-avatar{width:39px;height:39px;border-radius:11px}.customer-name{font-size:15px}.customer-phone{grid-column:1;grid-row:2;margin-left:52px;min-height:40px;font-size:12px}.customer-open{grid-column:2;grid-row:2;padding:6px 0;font-size:11px;min-height:40px}.customer-open svg{width:13px}.customer-note{grid-row:3;margin-left:52px;margin-top:5px;font-size:12px}.customer-pagination{padding:16px 14px;gap:8px}.customer-pagination .btn{padding:9px 8px;font-size:11px;gap:3px}.customer-pagination svg{width:15px}.customer-pagination span{font-size:11px}.customer-empty{padding:36px 20px 42px}.customer-empty h2{font-size:24px}.customer-form-card{padding:22px 18px;border-radius:16px}.customer-back{margin-bottom:16px}.customer-form-footer{flex-direction:column;align-items:stretch;gap:13px;padding-top:18px}.customer-form-footer .save-status{max-width:none;font-size:11px}.customer-form-footer>div{display:grid;grid-template-columns:auto minmax(0,1fr)}.customer-form-footer .btn{padding:12px 10px}.customer-record-footer{flex-wrap:wrap;gap:12px}.customer-record-footer .btn{margin-left:auto}.customer-form-card textarea{min-height:140px}.customer-editor .customer-heading{display:block}.customer-editor .customer-heading>.customer-badge{margin-top:12px}}
@media(max-width:360px){.customer-row{padding:16px 14px}.customer-phone{margin-left:0;font-size:12px}.customer-note{margin-left:0}.customer-identity{margin-bottom:5px}.customer-form-footer .btn{font-size:12px}.customer-toolbar{padding:16px 14px}.customer-search-controls{gap:7px}}
.customer-check{display:flex;align-items:flex-start;gap:12px;min-height:44px;font-size:14px;cursor:pointer}.customer-check input{width:18px;height:18px;min-width:18px;margin:3px 0 0;padding:0;accent-color:var(--green)}.customer-check small{display:block;margin-top:5px;line-height:1.5;font-size:12px;color:var(--muted)}.customer-flags{display:grid;gap:16px;margin:20px 0}.customer-rating{border:0;padding:0;margin:18px 0}.customer-rating legend{font-size:13px;margin-bottom:10px}.customer-stars{display:flex;flex-wrap:wrap;align-items:center;gap:6px}.customer-stars label{display:grid;place-items:center;position:relative;width:42px;height:44px;border:1px solid var(--line);border-radius:8px;cursor:pointer}.customer-stars input{position:absolute;opacity:0;width:100%;height:100%;margin:0}.customer-stars span{font-size:26px;color:#b8b9ae}.customer-stars .is-rated span{color:#9d711c}.customer-stars label:focus-within{outline:2px solid var(--green);outline-offset:2px}.customer-banned{color:#984338!important}.customer-reference-results{display:grid;gap:6px;max-height:260px;overflow:auto;margin-top:12px}.customer-reference-results .btn{justify-content:space-between;text-align:left;gap:12px}.customer-reference-results small{font-size:12px;color:var(--muted)}.customer-referrer-choice{display:flex;flex-wrap:wrap;align-items:center;gap:8px 16px;background:var(--wash);padding:8px 12px;margin-bottom:10px;border-radius:8px}.customer-referrer-choice span{font-size:12px}.customer-history{margin-top:24px}
.customer-history-heading{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 16px;margin-bottom:8px}
.customer-history-heading h2{margin:0}.customer-history-total{padding:5px 10px;border-radius:20px;background:var(--wash);color:var(--green);font-size:12px;font-weight:600;white-space:nowrap;font-variant-numeric:tabular-nums}
.customer-history>.field-hint{margin:0 0 8px}.customer-history-list{padding:0;margin:0;list-style:none}.customer-history-list>li+li{border-top:1px solid var(--line)}
.customer-history-link{display:grid;grid-template-columns:minmax(0,1fr) max-content;align-items:center;gap:16px;min-height:60px;padding:10px 0;color:var(--ink);text-decoration:none;border-radius:4px}
.customer-history-link:hover{background:var(--wash)}.customer-history-link:hover .customer-history-main strong{color:var(--green)}
.customer-history-main,.customer-history-meta{display:grid;gap:2px;min-width:0}.customer-history-main strong{font-size:14px;line-height:20px;font-variant-numeric:tabular-nums}.customer-history-main>span{font-size:12px;line-height:18px;color:var(--muted);overflow-wrap:anywhere}
.customer-history-meta{justify-items:end;text-align:right;max-width:180px}.customer-history-price{font-size:14px;line-height:20px;font-variant-numeric:tabular-nums;white-space:nowrap}
.customer-history-status{font-size:11px;line-height:18px;font-weight:600;padding:0 6px;border-radius:4px;white-space:nowrap;background:#edf0e7;color:#566b58}.customer-history-status.status-completed{background:#dfeee5;color:#24583d}.customer-history-status.status-no_show{background:#fff0d6;color:#805710}.customer-history-status.status-cancelled{background:#f5e9e1;color:#853b2f}
.customer-history-discount{font-size:11px;line-height:16px;color:var(--muted);overflow-wrap:anywhere}.customer-history .customer-pagination{padding:12px 0 0;margin-top:2px}
@media(max-width:600px){.customer-history-heading h2{font-size:20px}.customer-history-total{font-size:11px;padding:4px 8px}.customer-history-link{gap:10px;padding:8px 0;min-height:56px}.customer-history-main strong{font-size:12px}.customer-history-price{font-size:13px}.customer-history-meta{max-width:120px}}


.customer-stars .customer-ban-toggle{margin-left:6px;color:#8b625d;border-color:#d8bdb8;background:#fffaf9}
.customer-ban-toggle svg{width:23px;height:23px;pointer-events:none}
.customer-stars .customer-ban-toggle:has(input:checked){color:#fff;background:#a43832;border-color:#a43832;box-shadow:0 0 0 2px #f5deda}
.customer-ban-description{margin:12px 0 0;padding:10px 12px;border:1px solid #e3bdb7;border-radius:8px;background:#fff0ed;color:#8a302b;font-size:12px;line-height:1.6}
.customer-ban-description[hidden]{display:none}

html.customer-popup-open{overflow:hidden}
.customer-create-popup{width:min(760px,calc(100% - 48px));max-width:none;max-height:calc(100dvh - 48px);margin:auto;padding:0;border:1px solid var(--line);border-radius:18px;background:var(--white);color:var(--ink);box-shadow:0 24px 80px #12362d33;overflow:hidden}
.customer-create-popup[open]{display:flex;flex-direction:column}
.customer-create-popup::backdrop{background:#102e285c;backdrop-filter:blur(2px)}
.customer-popup-header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:14px 22px;border-bottom:1px solid var(--line)}
.customer-popup-header h1{margin:0;font:28px/1.2 Georgia,serif;letter-spacing:-.5px}
.customer-popup-header .btn{min-height:44px;padding:9px 12px;font-size:13px}
.customer-popup-header svg{width:18px;height:18px}
.customer-popup-body{padding:22px;min-height:0;overflow:auto;overscroll-behavior:contain}
.customer-popup-body .customer-back,.customer-popup-body .customer-heading{display:none}
.customer-popup-body .customer-form-card{border:0;border-radius:0;padding:0}
.customer-popup-body .customer-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px 20px}
.customer-popup-body .customer-fields>.field{margin:0;min-width:0}
.customer-popup-body #customer-referral,.customer-popup-body .customer-flags,.customer-popup-body .customer-fields>.field:last-child{grid-column:1/-1}
.customer-popup-body .customer-rating{margin:0;min-width:0}
.customer-popup-body textarea{min-height:88px;height:88px}
.customer-popup-body .customer-form-footer{margin-top:18px;padding-top:16px}
.busy .customer-popup-body{opacity:.75;pointer-events:none}
@media(max-width:600px){.customer-create-popup{width:calc(100% - 16px);max-height:calc(100dvh - 16px);border-radius:12px}.customer-popup-header{padding:10px 14px}.customer-popup-header h1{font-size:23px}.customer-popup-body{padding:16px}.customer-popup-body .customer-fields{grid-template-columns:minmax(0,1fr);gap:14px}.customer-popup-body .customer-form-footer>div{width:100%}}

.customer-list-panel .customer-columns,.customer-list-panel .customer-row{grid-template-columns:minmax(180px,1.2fr) 160px minmax(110px,.7fr) 78px minmax(150px,1.4fr) 105px;gap:18px}
.customer-list-panel .customer-columns>span{display:block}
.customer-list-meta{display:contents}
.customer-list-panel{container:customer-list / inline-size}
.customer-channel{display:grid;gap:4px;font-size:13px;overflow-wrap:anywhere;min-width:0}.customer-channel small{font-size:11px;color:var(--muted)}
.customer-channel-label{display:inline-flex;align-items:center;gap:7px;min-width:0;max-width:100%;line-height:18px;color:var(--green)}
.customer-channel-label>span:last-child{min-width:0}
.customer-channel-icon{display:inline-flex;align-items:center;justify-content:center;flex:0 0 26px;width:26px;height:26px;border-radius:7px;color:#fff}
.customer-channel-icon svg{display:block;width:20px;height:20px;flex:none}
.customer-channel-icon.is-instagram{background:linear-gradient(135deg,#7638c4,#c82878 55%,#c66b20)}
.customer-channel-icon.is-whatsapp{background:#168b46}
.customer-channel-icon.is-phone{background:#2563c4}
.customer-channel-icon.is-walk_in{background:#ac591a}
.customer-channel-icon.is-referral{background:#7953b6}
.customer-channel-icon.is-online{background:#087c8a}
.customer-list-rating{display:flex;align-items:center;gap:4px;font-size:14px;font-weight:700;color:var(--muted)}.customer-list-rating.has-rating{color:#85621e}.customer-list-rating>span{font-size:19px}.customer-list-rating small{font-size:11px;font-weight:400}
.customer-detail-page.customer-editor{max-width:1200px}.customer-detail-layout{display:grid;grid-template-columns:minmax(0,1fr) 420px;gap:26px;align-items:start}
.customer-detail-layout>.customer-history{margin-top:0;min-width:0}.customer-detail-sidebar{position:sticky;top:24px;max-height:calc(100dvh - 48px);overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;min-width:0}
.customer-detail-sidebar .customer-form-card{padding:20px}.customer-detail-sidebar .field{margin-bottom:14px}.customer-detail-sidebar .field input,.customer-detail-sidebar .field select{min-height:44px;padding:10px 12px;font-size:14px}
.customer-detail-sidebar .field label{font-size:12px}.customer-detail-sidebar .field-hint{font-size:11px}.customer-detail-sidebar textarea{height:88px;min-height:88px;font-size:13px}
.customer-detail-sidebar .customer-rating{margin:14px 0}.customer-detail-sidebar .customer-flags{margin:14px 0}.customer-detail-sidebar .customer-check{font-size:13px}.customer-detail-sidebar .customer-check small{font-size:11px}
.customer-detail-sidebar .customer-stars{gap:4px}.customer-detail-sidebar .customer-stars label{width:36px;height:36px}.customer-detail-sidebar .customer-stars span{font-size:23px}.customer-detail-sidebar .customer-stars>.btn{min-height:36px;padding:6px;font-size:11px}
.customer-detail-sidebar .customer-form-footer{display:grid;gap:8px;padding-top:14px}.customer-detail-sidebar .customer-form-footer .save-status{max-width:none;font-size:11px}.customer-detail-sidebar .customer-form-footer>div{display:grid;grid-template-columns:auto minmax(0,1fr)}.customer-detail-sidebar .customer-form-footer .btn{min-height:44px;padding:10px;font-size:12px}
.customer-detail-sidebar .customer-record-footer{margin:10px 0 0;gap:8px;flex-wrap:wrap;padding:0 4px}.customer-detail-sidebar .customer-record-footer .btn{font-size:11px;min-height:40px;padding:8px 10px}.customer-detail-sidebar .customer-record-footer p{font-size:11px}
.customer-cancellation-history{list-style:none;margin:0 0 12px;padding:0;display:grid;gap:6px}.customer-cancellation-history>li{display:flex;align-items:flex-start;gap:8px;padding:8px 10px;border-radius:7px;background:#fbf2ef;color:#853b2f}.customer-cancellation-history>li.is-restored{background:#edf4ee;color:#24583d}.customer-cancellation-history>li>div{min-width:0;flex:1}
.customer-cancellation-icon{display:flex;align-items:center;height:18px}.customer-cancellation-icon svg{width:16px;height:16px}.customer-cancellation-meta{display:flex;align-items:baseline;flex-wrap:wrap;gap:4px 12px;font-size:12px;line-height:18px}.customer-cancellation-meta time{font-size:11px;font-weight:600}.customer-cancellation-history p{margin:4px 0 0;font-size:12px;line-height:18px;white-space:pre-wrap;overflow-wrap:anywhere}
@media(max-width:1100px){.customer-list-panel .customer-columns{display:none}.customer-list-panel .customer-row{grid-template-columns:minmax(0,1fr) auto;gap:8px 18px;padding:18px}.customer-list-panel .customer-identity{grid-column:1;grid-row:1}.customer-list-panel .customer-open{grid-column:2;grid-row:1;margin:0}.customer-list-panel .customer-phone{grid-column:1;grid-row:2;margin:0;min-height:32px}.customer-list-panel .customer-channel{grid-column:2;grid-row:2}.customer-list-panel .customer-list-rating{grid-column:2;grid-row:3}.customer-list-panel .customer-note{grid-column:1;grid-row:3;margin:0}.customer-detail-layout{grid-template-columns:minmax(0,1fr) 370px;gap:20px}}
@media(max-width:900px){.customer-detail-layout{grid-template-columns:minmax(0,1fr)}.customer-detail-sidebar{position:static;max-height:none;overflow:visible;order:-1}.customer-detail-sidebar .customer-form-card{padding:20px}}
@media(max-width:600px){.customer-list-panel .customer-row{gap:8px 12px}.customer-list-panel .customer-identity{grid-column:1/-1}.customer-list-panel .customer-open{grid-row:4}.customer-list-panel .customer-note{grid-column:1/-1;grid-row:3}.customer-list-panel .customer-list-rating{grid-column:1;grid-row:4}.customer-list-panel .customer-channel{font-size:12px}.customer-detail-page .customer-heading h1{font-size:30px}.customer-detail-layout{gap:20px}.customer-detail-sidebar .customer-form-card{padding:18px}.customer-detail-sidebar .customer-form-footer{flex-direction:row}}

.customer-detail-popup{width:min(1280px,calc(100% - 48px));height:min(920px,calc(100dvh - 48px));background:var(--wash)}
.customer-detail-popup .customer-popup-header{background:var(--white);flex-shrink:0}
.customer-detail-popup .customer-popup-header h1{overflow-wrap:anywhere;min-width:0}.customer-detail-popup .customer-popup-header>.btn{flex-shrink:0}
.customer-detail-popup .customer-popup-body{flex:1;scrollbar-gutter:stable}
.customer-detail-popup .customer-detail-layout{grid-template-columns:minmax(0,1fr) 400px;gap:22px}
.customer-detail-popup .customer-form-card{padding:20px;border:1px solid var(--line);border-radius:16px}
.customer-detail-popup .customer-fields{display:block}
.customer-detail-popup .customer-fields>.field{margin-bottom:14px}
.customer-detail-popup .customer-detail-sidebar{top:0;max-height:min(800px,calc(100dvh - 168px))}
.customer-detail-popup .customer-form-footer{margin-top:0}
.customer-detail-popup .customer-history-heading h2{font-size:22px}
@media(max-width:900px){.customer-detail-popup .customer-detail-layout{grid-template-columns:minmax(0,1fr)}.customer-detail-popup .customer-detail-sidebar{max-height:none}}
@media(max-width:600px){.customer-detail-popup{width:calc(100% - 16px);height:calc(100dvh - 16px);max-height:calc(100dvh - 16px)}.customer-detail-popup .customer-popup-body{padding:14px;scrollbar-gutter:auto}.customer-detail-popup .customer-form-card{padding:16px}}

/* Use the available list width, including the space taken by the side menu. */
@container customer-list (min-width:601px) and (max-width:960px){
  .customer-list-panel .customer-columns,.customer-list-panel .customer-row{grid-template-columns:40px minmax(0,1.6fr) minmax(0,1fr) 64px 44px;column-gap:12px;padding-left:18px;padding-right:18px}
  .customer-list-panel .customer-columns{display:grid;align-items:center}
  .customer-list-panel .customer-columns>span{grid-row:1}
  .customer-columns>span:first-child{grid-column:1/3}
  .customer-list-panel .customer-columns>span:nth-child(2),.customer-list-panel .customer-columns>span:nth-child(5){display:none}
  .customer-columns>span:nth-child(3){grid-column:3}
  .customer-columns>span:nth-child(4){grid-column:4}
  .customer-columns>span:last-child{grid-column:5}
  .customer-list-panel .customer-row{grid-template-columns:40px minmax(0,1.6fr) minmax(0,1fr) 64px 44px;gap:0 12px;min-height:80px;padding:12px 18px;align-items:center}
  .customer-list-panel .customer-identity{display:contents}
  .customer-list-panel .customer-avatar{grid-column:1;grid-row:1/3;width:40px;height:40px;border-radius:11px;font-size:12px}
  .customer-list-panel .customer-identity>div{grid-column:2;grid-row:1;align-self:end}
  .customer-list-panel .customer-name{display:block;font-size:16px;line-height:22px}
  .customer-list-panel .customer-badge{display:inline-block;margin:4px 4px 0 0}
  .customer-list-panel .customer-phone{grid-column:2;grid-row:2;align-self:start;min-height:32px;margin:0;font-size:13px;line-height:18px}
  .customer-list-panel .customer-list-meta{display:contents}
  .customer-list-panel .customer-channel{grid-column:3;grid-row:1/3;font-size:12px;line-height:18px}
  .customer-list-panel .customer-list-rating{grid-column:4;grid-row:1/3;white-space:nowrap;font-size:13px}
  .customer-list-panel .customer-note{grid-column:2/5;grid-row:3;margin:2px 0 0;font-size:12px;line-height:18px;-webkit-line-clamp:2}
  .customer-list-panel .customer-note:not(.has-note){display:none}
  .customer-list-panel .customer-note.has-note::before{content:'Not: ';font-weight:600}
  .customer-list-panel .customer-open{grid-column:5;grid-row:1/3;width:44px;min-height:44px;margin:0;padding:0;border:1px solid var(--line);border-radius:10px;background:var(--white)}
  .customer-list-panel .customer-open svg{width:18px;height:18px}
  .customer-list-panel .customer-open-label{display:none}
}

/* Compact phone list: contact information first, optional details underneath. */
@container customer-list (max-width:600px){
  .customer-list-panel .customer-columns{display:none}
  .customer-list-panel .customer-toolbar{padding:14px;gap:10px}
  .customer-list-panel .customer-search-controls{gap:8px}
  .customer-list-panel .customer-search-controls input{min-height:44px;padding:10px 12px;font-size:16px}
  .customer-list-panel .customer-search-controls .btn{min-width:56px;min-height:44px;padding:8px 12px}
  .customer-list-panel .customer-filter select{min-width:0;font-size:16px}
  .customer-list-panel .customer-result-count{padding:12px 14px}
  .customer-list-panel .customer-row{grid-template-columns:36px minmax(0,1fr) 44px;gap:0 9px;min-height:0;padding:12px 14px;align-items:start}
  .customer-list-panel .customer-identity{display:contents}
  .customer-list-panel .customer-avatar{grid-column:1;grid-row:1/3;align-self:center;width:36px;height:36px;border-radius:10px;font-size:12px}
  .customer-list-panel .customer-identity>div{grid-column:2;grid-row:1;align-self:end}
  .customer-list-panel .customer-name{display:block;font-size:15px;line-height:20px}
  .customer-list-panel .customer-badge{display:inline-block;margin:4px 4px 0 0}
  .customer-list-panel .customer-phone{grid-column:2;grid-row:2;min-height:32px;margin:0;font-size:13px;line-height:18px}
  .customer-list-panel .customer-open{grid-column:3;grid-row:1/3;align-self:center;width:44px;min-height:44px;padding:0;border:1px solid var(--line);border-radius:10px;background:var(--white)}
  .customer-list-panel .customer-open svg{width:18px;height:18px}
  .customer-list-panel .customer-open-label{display:none}
  .customer-list-panel .customer-list-meta{display:grid;grid-column:2/-1;grid-row:3;grid-template-columns:minmax(0,1fr) auto;gap:4px 10px;align-items:center;margin-top:2px;min-width:0}
  .customer-list-panel .customer-channel{grid-column:1;grid-row:auto;display:flex;flex-wrap:wrap;align-items:center;gap:2px 6px;font-size:12px;line-height:18px;color:var(--muted)}
  .customer-list-panel .customer-channel>span:not(.customer-channel-label){padding:2px 6px;border-radius:5px;background:var(--wash);color:var(--green)}
  .customer-list-panel .customer-channel small{font-size:11px;line-height:16px;overflow-wrap:anywhere}
  .customer-list-panel .customer-list-rating{grid-column:2;grid-row:auto;justify-self:end;gap:3px;font-size:12px;line-height:20px;white-space:nowrap}
  .customer-list-panel .customer-list-rating>span{font-size:15px}
  .customer-list-panel .customer-note{grid-column:1/-1;grid-row:auto;margin:0;font-size:12px;line-height:18px;-webkit-line-clamp:2}
  .customer-list-panel .customer-list-meta:has(.has-rating):not(:has(.has-channel))>.customer-note{grid-column:1;grid-row:1}
  .customer-list-panel .customer-list-meta:has(.has-rating):not(:has(.has-channel))>.customer-list-rating{grid-row:1;align-self:start}
  .customer-list-panel .customer-list-meta:not(.has-details),.customer-list-panel .customer-channel:not(.has-channel),.customer-list-panel .customer-list-rating:not(.has-rating),.customer-list-panel .customer-note:not(.has-note){display:none}
}
.customer-detail-main{min-width:0;display:flex;flex-direction:column;gap:20px}
.customer-detail-actions{display:flex;justify-content:flex-end;margin:0 0 18px}
@media(max-width:600px){.customer-detail-actions{margin-bottom:14px}.customer-detail-actions .btn{width:100%;min-height:44px}}
.customer-account h2{margin:0}.customer-account h3{font-size:15px;margin:22px 0 10px}
.customer-account-heading{display:flex;justify-content:space-between;gap:12px;align-items:start}
.customer-account-heading p{margin:6px 0 16px;color:var(--muted);font-size:13px}
.customer-account-heading select{display:block;min-height:44px}
.customer-account-balance{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:12px;padding:16px;border:1px solid var(--line);border-radius:12px;background:var(--wash)}
.customer-account-balance span{display:block;font-size:13px;margin-bottom:4px}
.customer-account-balance strong{font-size:25px;font-variant-numeric:tabular-nums}
.customer-account-actions{display:flex;flex-wrap:wrap;gap:8px}
.customer-account-history{list-style:none;padding:0;margin:0;max-height:440px;overflow:auto}
.customer-account-history li{display:flex;justify-content:space-between;gap:12px;padding:13px 0;border-bottom:1px solid var(--line);font-size:13px}
.customer-account-history li>div{min-width:0}.customer-account-history time,.customer-account-history span,.customer-account-history small{display:block;color:var(--muted);font-size:12px;margin-top:4px}
.customer-account-history p{margin:6px 0 0;overflow-wrap:anywhere}.customer-account-entry-amount{text-align:right;flex-shrink:0;font-variant-numeric:tabular-nums}
.customer-account-entry-amount .is-credit{color:var(--green)}
.customer-account-dialog{width:min(460px,calc(100vw - 24px));max-width:calc(100vw - 24px);max-height:calc(100dvh - 24px);overflow:auto;box-sizing:border-box}
.customer-account-dialog form{display:block}.customer-account-dialog .field{margin-bottom:16px}.customer-account-dialog input,.customer-account-dialog select{width:100%;box-sizing:border-box;min-height:44px}
@media(max-width:400px){.customer-account-history li{flex-direction:column;gap:4px}.customer-account-entry-amount{text-align:left}.customer-account-balance{padding:12px}.customer-account-actions .btn{padding-inline:12px}}

.customer-detail-main>.customer-history{margin-top:0}
.customer-history{container-type:inline-size;container-name:customer-history}
.customer-history-table{width:100%;border-collapse:collapse;table-layout:fixed;font-size:13px}
.customer-history-table th{padding:10px 0;text-align:left;color:var(--muted);font-size:11px;font-weight:600;border-bottom:1px solid var(--line)}
.customer-history-table th:first-child{width:30%}.customer-history-table th:last-child{width:32%;text-align:right}
.customer-history-table td{padding:10px 0;vertical-align:middle;overflow-wrap:anywhere}
.customer-history-table tbody+tbody{border-top:1px solid var(--line)}
.customer-history-appointment{display:flex;flex-direction:column;justify-content:center;min-height:44px;color:var(--ink);text-decoration:none;font-variant-numeric:tabular-nums}
.customer-history-appointment:hover strong{text-decoration:underline;color:var(--green)}
.customer-history-appointment span,.customer-history-service>span{display:block;font-size:12px;color:var(--muted);line-height:18px}
.customer-history-table .customer-history-service{padding-left:12px;padding-right:12px}.customer-history-service>strong{font-weight:500;line-height:20px}
.customer-history-amount .customer-history-meta{max-width:none}.customer-history-amount .customer-history-price{white-space:normal}
.customer-history-repeat.btn{gap:6px;margin-top:6px;min-height:40px;padding:8px 10px;font-size:12px;white-space:nowrap}
.customer-history-repeat svg{width:15px;height:15px}
.customer-history-table .customer-history-cancellation td{padding:0 0 10px}.customer-history-cancellation .customer-cancellation-history{margin-bottom:0}
.customer-history-table.is-compact td{padding-top:6px;padding-bottom:6px}
.customer-history-table.is-compact .customer-history-appointment{min-height:36px;font-size:12px;line-height:18px}
.customer-history-table.is-compact .customer-history-service{padding-left:8px;padding-right:8px}
.customer-history-table.is-compact .customer-history-service>strong{font-size:12px;line-height:18px}
.customer-history-table.is-compact .customer-history-service>span{font-size:11px;line-height:16px}
.customer-history-table.is-compact .customer-history-meta{grid-template-columns:minmax(0,1fr) auto;gap:2px 6px;align-items:center}
.customer-history-table.is-compact .customer-history-meta>:not(.customer-history-repeat){grid-column:1}
.customer-history-table.is-compact .customer-history-meta>.customer-history-discount{grid-column:1/-1;grid-row:3;font-size:10px}
.customer-history-table.is-compact .customer-history-price{font-size:12px;line-height:18px}
.customer-history-table.is-compact .customer-history-status{font-size:10px;padding:0 4px;line-height:16px}
.customer-history-table.is-compact .customer-history-repeat{grid-column:2;grid-row:1/3;min-width:32px;min-height:32px;padding:7px;margin:0}
.customer-history-table.is-compact .customer-history-cancellation td{padding-top:0;padding-bottom:4px}
.customer-cancellation-details>summary{display:flex;align-items:center;gap:5px;min-height:24px;font-size:11px;line-height:16px;color:var(--muted);cursor:pointer;list-style:none}
.customer-cancellation-details>summary::-webkit-details-marker{display:none}
.customer-cancellation-details>summary::before{content:'›';flex:none;font-size:16px;transition:transform .15s}
.customer-cancellation-details[open]>summary::before{transform:rotate(90deg)}
.customer-cancellation-details>summary>span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.customer-cancellation-details[open] .customer-cancellation-history{margin:2px 0 4px}
@container customer-history (max-width:480px){
  .customer-history-table,.customer-history-table tbody{display:block}.customer-history-table thead{display:none}
  .customer-history-table tr{display:grid;grid-template-columns:minmax(0,1fr) minmax(88px,auto);column-gap:10px;padding:8px 0}
  .customer-history-table td{padding:0;min-width:0}
  .customer-history-date{grid-column:1;grid-row:1}.customer-history-appointment{flex-direction:row;flex-wrap:wrap;justify-content:flex-start;align-items:center;gap:0 6px;min-height:36px;font-size:12px}
  .customer-history-table .customer-history-service{grid-column:1;grid-row:2;padding:0}
  .customer-history-service>strong{font-size:12px;line-height:18px}.customer-history-service>span{font-size:11px}
  .customer-history-amount{grid-column:2;grid-row:1/3;align-self:center;max-width:120px}.customer-history-amount .customer-history-price{font-size:13px}
  .customer-history-repeat.btn{min-height:44px}
  .customer-history-table .customer-history-cancellation{display:block;padding:0}.customer-history-cancellation td{display:block}
  .customer-history-table.is-compact tr:not(.customer-history-cancellation){grid-template-columns:minmax(0,1fr) 104px;padding:4px 0;column-gap:8px}
  .customer-history-table.is-compact td{padding-top:0;padding-bottom:0}
  .customer-history-table.is-compact .customer-history-appointment{min-height:24px}
  .customer-history-table.is-compact .customer-history-service{padding:0;line-height:18px}
  .customer-history-table.is-compact .customer-history-service>span{display:inline}
  .customer-history-table.is-compact .customer-history-service>span::before{content:' · '}
  .customer-history-table.is-compact .customer-history-repeat{min-width:32px;min-height:32px}
  .customer-history-table.is-compact .customer-history-amount{width:104px;max-width:104px}
  .customer-history .customer-pagination{gap:8px;flex-wrap:wrap}.customer-history .customer-pagination .btn{padding:8px 10px;min-height:40px}
}

.customer-credit-balance{display:flex;align-items:baseline;flex-wrap:wrap;gap:4px 10px;max-width:100%;padding:10px 12px;margin:12px 0;border:1px solid #d2e3d7;border-radius:8px;background:#edf5ef;color:var(--green);font-size:13px;overflow-wrap:anywhere}.customer-credit-balance>span{font-size:12px}.customer-credit-balance>strong{font-size:15px;font-variant-numeric:tabular-nums}.customer-credit-balance.is-compact{display:inline-flex;margin:5px 0 0;padding:3px 6px;gap:2px 6px;border-radius:5px;line-height:17px}.customer-credit-balance.is-compact>span{font-size:10px}.customer-credit-balance.is-compact>strong{font-size:12px}
