:root[data-theme="a"] {
  --bg:#fff; --paper:#fff; --ink:#141416; --muted:#56565e; --line:#dedee5; --soft:#f2f2f7;
  --accent:#0069d9; --danger:#c5261c; --current:#ff3b30; --editor-bg:#f2f2f7;
  --nav-bg:#f9f9f9f0; --signup:#fff; --calendar-mix:12%;
  --cut:#007aff; --wash:#168297; --perm:#a346ce; --dye:#b86100; --care:#137835; --pending:#6d6d77;
}
:root[data-theme="a"][data-color-scheme="dark"] {
  --bg:#000; --paper:#1c1c1e; --ink:#fff; --muted:#b7b7c2; --line:#39393f; --soft:#3a3a3c;
  --accent:#60adff; --danger:#ff6961; --current:#ff453a; --editor-bg:#1c1c1e;
  --nav-bg:#161618f0; --signup:#2c2c2e; --calendar-mix:26%;
  --cut:#70b6ff; --wash:#56c9da; --perm:#da8bff; --dye:#ffb85b; --care:#62d985; --pending:#c2c2cb;
}
[data-theme="a"] .app{background:var(--bg)}
[data-theme="a"] .top{padding-top:env(safe-area-inset-top);background:var(--nav-bg);border-bottom:1px solid var(--line);backdrop-filter:blur(20px)}
[data-theme="a"] .theme-heading{display:flex;flex-direction:column}
[data-theme="a"] .toolbar{order:-1;display:flex;align-items:center;padding-inline:8px}
[data-theme="a"] .toolbar button,[data-theme="a"] .date-nav button,[data-theme="a"] #theme-week button{border:0;background:none;color:var(--accent);padding:0}
[data-theme="a"] .toolbar #today{margin-right:auto;padding-inline:8px}
[data-theme="a"] .toolbar #today svg,[data-theme="a"] .toolbar button:not(#today) span,[data-theme="a"] #open-day-menu{display:none}
[data-theme="a"] .toolbar svg{vertical-align:middle}
[data-theme="a"] .date-nav{padding:5px 8px 2px 16px;gap:2px}
[data-theme="a"] #choose-date{order:-1;margin-right:auto;text-align:left;color:var(--ink);display:flex;align-items:baseline;gap:8px;min-width:0;white-space:nowrap}
[data-theme="a"] #date-title{font-size:32px;line-height:1.16}
[data-theme="a"] #year-title{font-size:20px;font-weight:600;color:var(--muted)}
[data-theme="a"] :is(#previous,#next){opacity:.86}
[data-theme="a"] #theme-week{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));padding:0 max(8px,env(safe-area-inset-right)) 13px max(8px,env(safe-area-inset-left));text-align:center}
[data-theme="a"] #theme-week button{min-width:44px;width:100%;min-height:58px;color:var(--ink);outline-offset:-3px}
[data-theme="a"] #theme-week small{display:block;color:var(--muted);font-size:13px;font-weight:650}
[data-theme="a"] #theme-week b{display:inline-grid;place-items:center;width:40px;height:40px;border-radius:50%;font-size:20px;font-weight:560}
[data-theme="a"] #theme-week button[aria-current=date] b{color:var(--accent)}
[data-theme="a"] #theme-week button[aria-pressed=true] b{background:var(--accent);color:var(--bg);font-weight:750}
[data-theme="a"] #theme-week .another-month{opacity:.65}
[data-theme="a"] :is(.table-head,.day-foot){display:none}
[data-theme="a"] #day-rows{padding:14px env(safe-area-inset-right) 40px env(safe-area-inset-left)}
[data-theme="a"] .calendar-track{position:relative}
[data-theme="a"] .calendar-time{position:absolute;left:0;right:0;display:flex;align-items:flex-start;gap:10px;font-size:17px;font-variant-numeric:tabular-nums;color:var(--muted);pointer-events:none}
[data-theme="a"] .calendar-time::after{content:"";flex:1;border-top:1px solid var(--line)}
[data-theme="a"] .calendar-time span{width:54px;flex:none;text-align:right;transform:translateY(-10px)}
[data-theme="a"] .calendar-free,[data-theme="a"] .calendar-booking{position:absolute;left:70px;right:10px;width:auto;border:0}
[data-theme="a"] .calendar-free{background:transparent;border-radius:0}
[data-theme="a"] .calendar-free:active{background:var(--soft)}
[data-theme="a"] .cut{--event:var(--cut)}
[data-theme="a"] .wash{--event:var(--wash)}
[data-theme="a"] .perm{--event:var(--perm)}
[data-theme="a"] .dye{--event:var(--dye)}
[data-theme="a"] .care{--event:var(--care)}
[data-theme="a"] :is(.pending,.custom){--event:var(--pending)}
[data-theme="a"] .calendar-booking{z-index:1;display:flex;flex-direction:column;justify-content:flex-start;gap:1px;overflow:hidden;border-radius:9px;line-height:1.18;padding:4px 10px 4px 11px;border-left:5px solid var(--event);background:color-mix(in srgb,var(--event) var(--calendar-mix),var(--bg))}
[data-theme="a"] .calendar-booking.pending{border:1.5px dashed var(--pending);padding-left:13px}
[data-theme="a"] .booking-project{color:var(--event);font-weight:720}
[data-theme="a"] .booking-gender{font-size:17px}
[data-theme="a"] .calendar-length{font-size:17px;color:var(--muted);margin-top:2px}
[data-theme="a"] .calendar-now{position:absolute;left:58px;right:0;border-top:2px solid var(--current);z-index:2;pointer-events:none}
[data-theme="a"] .calendar-now::before{content:"";position:absolute;left:-5px;top:-7px;border-radius:50%;width:12px;height:12px;background:var(--current)}
[data-theme="a"] .calendar-now span{position:absolute;right:calc(100% + 6px);top:-2px;transform:translateY(-50%);background:var(--current);color:#fff;font-size:14px;font-weight:700;padding:2px 5px;border-radius:7px;font-variant-numeric:tabular-nums}
[data-theme="a"] #editor{width:min(100%,540px);max-width:100%;border-radius:12px 12px 0 0;background:var(--editor-bg)}
[data-theme="a"] #editor::backdrop{background:#0006}
[data-theme="a"] #editor .sheet::before{content:"";width:36px;height:5px;margin:6px auto 0;border-radius:3px;background:var(--line);flex:none}
[data-theme="a"] #editor .sheet-head{display:grid;grid-template-columns:64px minmax(0,1fr) 64px;align-items:start;text-align:center;padding:1px 8px 13px;gap:1px}
[data-theme="a"] #editor .sheet-head button{border:0;background:none;color:var(--accent);font-size:17px;margin:0;padding:4px}
[data-theme="a"] #editor .sheet-head h2{font-size:17px;margin-top:11px}
[data-theme="a"] #editor .sheet-head p{font-size:15px;margin-inline:-52px;margin-top:7px}
[data-theme="a"] #save-appointment{color:var(--accent);font-weight:740}
[data-theme="a"] .editor-fields{padding:0 16px calc(22px + env(safe-area-inset-bottom))}
[data-theme="a"] .editor-field{background:var(--signup);border-bottom:1px solid var(--line);padding:8px 12px}
[data-theme="a"] #field-project{margin-bottom:16px;border-radius:10px;border:0}
[data-theme="a"] #field-project .field-heading label{color:var(--muted)}
[data-theme="a"] #custom-project,[data-theme="a"] .duration-rail-label{display:none}
[data-theme="a"] #quick-projects{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
[data-theme="a"] #quick-projects button{min-width:0;min-height:44px;background:var(--soft);border:0;border-radius:10px;font-size:17px;font-weight:650}
[data-theme="a"] #quick-projects button.selected{background:var(--accent);color:var(--bg)}
[data-theme="a"] :is(#field-gender,#field-duration){position:relative;padding-left:72px;min-height:56px}
[data-theme="a"] #field-gender{border-radius:10px 10px 0 0}
[data-theme="a"] #field-gender legend,[data-theme="a"] #field-duration .editor-label{position:absolute;inset:16px auto auto 12px}
[data-theme="a"] #field-duration{border:0;border-radius:0 0 10px 10px;margin-bottom:16px}
[data-theme="a"] #duration-grid{display:flex;align-items:center;justify-content:flex-end;gap:8px}
[data-theme="a"] .step-duration{color:var(--muted);white-space:nowrap}
[data-theme="a"] .slot-stepper{border-radius:9px;overflow:hidden;background:var(--soft)}
[data-theme="a"] .slot-stepper output{display:none}
[data-theme="a"] .slot-stepper button{border:0;background:none;border-radius:0}
[data-theme="a"] .slot-stepper button+output+button{border-left:1px solid var(--line)}
[data-theme="a"] .duration-paper-label{font-size:0}
[data-theme="a"] .duration-paper-label::after{content:"时长";font-size:17px}
[data-theme="a"] .editor-fields .segmented{margin-left:auto;width:min(100%,190px);gap:2px;background:var(--soft);padding:2px;border-radius:9px}
[data-theme="a"] .editor-fields .segmented label{min-height:44px;border:0;background:none;border-radius:7px;font-size:17px}
[data-theme="a"] .editor-fields .segmented label:has(input:checked){background:var(--signup);color:var(--ink);box-shadow:0 2px 5px #0003}
[data-theme="a"] #field-contact{display:grid;grid-template-columns:96px minmax(0,1fr);align-items:center;border-radius:10px 10px 0 0}
[data-theme="a"] #field-contact>label{margin:0}
[data-theme="a"] #field-contact input{border:0;background:none;text-align:right;padding:4px 0}
[data-theme="a"] #customer-suggestions{grid-column:1/-1}
[data-theme="a"] #customer-suggestions button{background:none;border:0;font-size:17px;padding:3px 0}
[data-theme="a"] #customer-suggestions .apply-customer{display:inline-block;margin-left:6px}
[data-theme="a"] #field-notes{border:0;border-radius:0 0 10px 10px}
[data-theme="a"] #field-notes textarea{border:0;background:none;padding:2px 0}
[data-theme="a"] #editor .editor-actions:not(:has(#delete-appointment:not([hidden]))){display:none}
