/* KAJU Staff — shadcn/ui design language (zinc theme, new-york style) */
:root{
  --background:0 0% 100%;--foreground:240 10% 3.9%;
  --card:0 0% 100%;--card-foreground:240 10% 3.9%;
  --popover:0 0% 100%;
  --primary:240 5.9% 10%;--primary-foreground:0 0% 98%;
  --secondary:240 4.8% 95.9%;--muted:240 4.8% 95.9%;--muted-foreground:240 3.8% 46.1%;
  --accent:240 4.8% 95.9%;
  --destructive:0 84.2% 60.2%;--destructive-foreground:0 0% 98%;
  --success:142 71% 35%;
  --border:240 5.9% 90%;--input:240 5.9% 90%;--ring:240 10% 3.9%;
  --chart-1:12 76% 61%;--chart-2:173 58% 39%;--chart-3:262 52% 55%;--chart-4:43 74% 49%;--chart-5:240 4% 60%;
  --radius:.5rem;
  --nav-h:62px;
  font-family:"Geist",ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,sans-serif;
  color-scheme:light;
}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]){
  --background:240 10% 3.9%;--foreground:0 0% 98%;
  --card:240 10% 3.9%;--card-foreground:0 0% 98%;--popover:240 10% 3.9%;
  --primary:0 0% 98%;--primary-foreground:240 5.9% 10%;
  --secondary:240 3.7% 15.9%;--muted:240 3.7% 15.9%;--muted-foreground:240 5% 64.9%;--accent:240 3.7% 15.9%;
  --destructive:0 72% 51%;--success:142 60% 50%;
  --border:240 3.7% 15.9%;--input:240 3.7% 15.9%;--ring:240 4.9% 83.9%;
  --chart-1:220 70% 60%;--chart-2:160 60% 45%;--chart-3:280 65% 65%;--chart-4:30 80% 55%;--chart-5:240 5% 55%;
  color-scheme:dark;
}}
:root[data-theme="dark"]{
  --background:240 10% 3.9%;--foreground:0 0% 98%;
  --card:240 10% 3.9%;--card-foreground:0 0% 98%;--popover:240 10% 3.9%;
  --primary:0 0% 98%;--primary-foreground:240 5.9% 10%;
  --secondary:240 3.7% 15.9%;--muted:240 3.7% 15.9%;--muted-foreground:240 5% 64.9%;--accent:240 3.7% 15.9%;
  --destructive:0 72% 51%;--success:142 60% 50%;
  --border:240 3.7% 15.9%;--input:240 3.7% 15.9%;--ring:240 4.9% 83.9%;
  --chart-1:220 70% 60%;--chart-2:160 60% 45%;--chart-3:280 65% 65%;--chart-4:30 80% 55%;--chart-5:240 5% 55%;
  color-scheme:dark;
}
/* aliases used by inline styles in app.js */
:root,:root[data-theme]{
  --bg:hsl(var(--background));--ink:hsl(var(--foreground));--mute:hsl(var(--muted-foreground));--line:hsl(var(--border));
  --wood:hsl(var(--foreground));--wood-soft:hsl(var(--muted));--bad:hsl(var(--destructive));--ok:hsl(var(--success));
  --r1:hsl(var(--chart-1));--r2:hsl(var(--chart-2));--r3:hsl(var(--chart-3));--r4:hsl(var(--chart-4));--r5:hsl(var(--chart-5));
  --shadow:0 1px 3px 0 rgb(0 0 0/.06),0 1px 2px -1px rgb(0 0 0/.06);
  --shadow-sm:0 1px 2px 0 rgb(0 0 0/.05);
}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]){
  --bg:hsl(var(--background));--ink:hsl(var(--foreground));--mute:hsl(var(--muted-foreground));--line:hsl(var(--border));
  --wood:hsl(var(--foreground));--wood-soft:hsl(var(--muted));--bad:hsl(var(--destructive));--ok:hsl(var(--success));
  --r1:hsl(var(--chart-1));--r2:hsl(var(--chart-2));--r3:hsl(var(--chart-3));--r4:hsl(var(--chart-4));--r5:hsl(var(--chart-5));
}}

*{box-sizing:border-box;border-color:hsl(var(--border))}
html,body{margin:0;background:hsl(var(--background));color:hsl(var(--foreground));-webkit-text-size-adjust:100%;-webkit-font-smoothing:antialiased}
body{font-size:14px;line-height:1.5;padding-bottom:calc(var(--nav-h) + env(safe-area-inset-bottom) + 24px)}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer}
h1,h2,h3{margin:0;line-height:1.2;font-weight:600;letter-spacing:-.025em}
h1{font-size:24px}
h2{font-size:16px}
h3{font-size:14px}
a{color:hsl(var(--foreground));text-underline-offset:4px}
.mute{color:hsl(var(--muted-foreground))}
.small{font-size:13px}
.num{font-variant-numeric:tabular-nums}
:focus-visible{outline:2px solid hsl(var(--ring));outline-offset:2px}

/* layout */
.top{position:sticky;top:0;z-index:5;background:hsl(var(--background)/.9);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  padding:calc(env(safe-area-inset-top) + 10px) 16px 10px;display:flex;align-items:center;gap:8px;border-bottom:1px solid hsl(var(--border))}
.top .brand{font-weight:700;letter-spacing:-.01em;font-size:15px;color:hsl(var(--foreground))}
.top .who{margin-left:auto;display:flex;gap:4px;align-items:center}
.brand-wrap{display:flex;align-items:center;gap:8px}
.logo-img{height:22px;width:auto;display:block;transition:filter .2s}
.brand-staff{font-size:11px;letter-spacing:.12em;text-transform:uppercase;font-weight:500}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .logo-img{filter:invert(1)}}
:root[data-theme="dark"] .logo-img{filter:invert(1)}
:root[data-theme="light"] .logo-img{filter:none}
.logo-login{width:140px;height:auto;display:block;margin:0 auto 8px;transition:filter .2s}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .logo-login{filter:invert(1)}}
:root[data-theme="dark"] .logo-login{filter:invert(1)}
.wrap{max-width:720px;margin:0 auto;padding:20px 16px}
.stack>*+*{margin-top:16px}
.row{display:flex;gap:8px;align-items:center}
.between{justify-content:space-between}
.wrapf{flex-wrap:wrap}
.grow{flex:1;min-width:0}

/* card */
.card{background:hsl(var(--card));color:hsl(var(--card-foreground));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);padding:16px;box-shadow:var(--shadow)}
.card.tight{padding:14px}
.sec-h{display:flex;justify-content:space-between;align-items:center;margin:28px 0 10px}
.sec-h h2{font-size:15px;font-weight:600;color:hsl(var(--foreground))}

/* staff calendar embed */
.staff-cal-wrap{width:100%;height:calc(100vh - 120px - env(safe-area-inset-top) - env(safe-area-inset-bottom))}
.staff-cal-frame{width:100%;height:100%;border:none;background:hsl(var(--background))}

/* bottom nav */
nav.tabs{position:fixed;left:0;right:0;bottom:0;z-index:6;background:hsl(var(--background)/.95);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);
  border-top:1px solid hsl(var(--border));display:grid;grid-template-columns:repeat(6,1fr);padding-bottom:env(safe-area-inset-bottom)}
nav.tabs a{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;height:var(--nav-h);
  text-decoration:none;color:hsl(var(--muted-foreground));font-size:10px;font-weight:500}
nav.tabs a.on{color:hsl(var(--foreground))}
nav.tabs a.on svg{stroke-width:2.2}
nav.tabs svg{width:22px;height:22px}

/* buttons — shadcn Button */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;white-space:nowrap;border-radius:var(--radius);
  font-size:14px;font-weight:500;height:36px;padding:0 16px;border:1px solid hsl(var(--input));background:hsl(var(--background));
  box-shadow:var(--shadow-sm);transition:background .15s,color .15s,opacity .15s;text-decoration:none;color:hsl(var(--foreground))}
.btn:hover{background:hsl(var(--accent))}
.btn.primary{background:hsl(var(--primary));color:hsl(var(--primary-foreground));border-color:transparent;box-shadow:var(--shadow)}
.btn.primary:hover{background:hsl(var(--primary)/.9)}
.btn.danger{background:hsl(var(--destructive));color:hsl(var(--destructive-foreground));border-color:transparent}
.btn.danger:hover{background:hsl(var(--destructive)/.9)}
.btn.ghost{background:transparent;border-color:transparent;box-shadow:none}
.btn.ghost:hover{background:hsl(var(--accent))}
.btn.sm{height:32px;padding:0 12px;font-size:13px;border-radius:calc(var(--radius) - 2px)}
.btn.block{width:100%;height:40px}
.btn:disabled{opacity:.5;pointer-events:none}
.btn svg{width:16px;height:16px;flex:none}
.sheet-f .btn{height:40px}
.icon-btn{border:0;background:transparent;width:36px;height:36px;border-radius:var(--radius);color:hsl(var(--foreground));display:inline-flex;align-items:center;justify-content:center}
.icon-btn:hover{background:hsl(var(--accent))}
.icon-btn svg{width:18px;height:18px}

/* quick actions */
.qa{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
@media (min-width:560px){.qa{grid-template-columns:repeat(5,1fr)}}
.qa button{background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);padding:14px 6px 12px;display:flex;flex-direction:column;
  align-items:center;gap:8px;font-size:13px;font-weight:500;box-shadow:var(--shadow);min-height:92px;transition:background .15s,transform .1s}
.qa button:hover{background:hsl(var(--accent))}
.qa button:active{transform:scale(.97)}
.qa .ic{width:40px;height:40px;border-radius:var(--radius);background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center}
.qa .ic svg{width:20px;height:20px}

/* toggle chips */
.chips{display:flex;flex-wrap:wrap;gap:8px}
.chip{border:1px solid hsl(var(--input));background:hsl(var(--background));border-radius:var(--radius);padding:0 14px;height:40px;font-size:14px;font-weight:500;box-shadow:var(--shadow-sm)}
.chip.on{background:hsl(var(--primary));border-color:hsl(var(--primary));color:hsl(var(--primary-foreground))}
/* tabs — shadcn Tabs */
.seg{display:inline-flex;align-items:center;background:hsl(var(--muted));border-radius:var(--radius);padding:3px;height:36px}
.seg button{border:0;background:transparent;height:30px;padding:0 12px;border-radius:calc(var(--radius) - 2px);font-weight:500;font-size:14px;color:hsl(var(--muted-foreground))}
.seg button.on{background:hsl(var(--background));color:hsl(var(--foreground));box-shadow:var(--shadow)}

/* badge */
.badge{display:inline-flex;align-items:center;border-radius:calc(var(--radius) - 2px);padding:2px 8px;font-size:12px;font-weight:600;
  background:hsl(var(--secondary));color:hsl(var(--foreground));border:1px solid transparent}
.badge.bad{background:hsl(var(--destructive));color:hsl(var(--destructive-foreground))}
.badge.ok{background:transparent;border-color:hsl(var(--border));color:hsl(var(--success))}
.badge.warn{background:transparent;border-color:hsl(var(--border))}
.dot{width:8px;height:8px;border-radius:50%;display:inline-block;flex:none;vertical-align:middle}

/* lists */
.list{background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);overflow:hidden;box-shadow:var(--shadow)}
.li{display:flex;gap:12px;padding:12px 14px;align-items:flex-start;border-top:1px solid hsl(var(--border));transition:background .15s}
.li[data-log],.li[data-exp],.li[data-bk],.li[data-sh],.li[data-st],.li[data-it],.li[data-add]{cursor:pointer}
.li[data-log]:hover,.li[data-exp]:hover,.li[data-bk]:hover,.li[data-sh]:hover,.li[data-st]:hover,.li[data-it]:hover{background:hsl(var(--muted)/.5)}
.li:first-child{border-top:0}
.li .ic{width:36px;height:36px;border-radius:var(--radius);background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center;flex:none}
.li .ic svg{width:18px;height:18px}
.li .t{font-weight:500}
.day-h{font-size:13px;font-weight:500;color:hsl(var(--muted-foreground));margin:20px 2px 8px}

/* history collapse */
.day-toggle{display:flex;align-items:center;gap:8px;width:100%;padding:12px 4px;margin-top:12px;
  font-size:14px;font-weight:600;color:hsl(var(--foreground));background:none;border:none;border-bottom:1px solid hsl(var(--border));cursor:pointer}
.day-toggle-arrow{width:18px;height:18px;display:grid;place-items:center;transition:transform .2s;color:hsl(var(--muted-foreground))}
.day-toggle-arrow svg{width:14px;height:14px}
.day-toggle.open .day-toggle-arrow{transform:rotate(90deg)}
.day-body{display:none;padding:0 0 8px}
.day-body.open{display:block}

.room-toggle{display:flex;align-items:center;gap:8px;width:100%;padding:10px 8px;margin-top:6px;
  background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:var(--radius);cursor:pointer;color:hsl(var(--foreground))}
.room-toggle-arrow{width:16px;height:16px;display:grid;place-items:center;transition:transform .2s;color:hsl(var(--muted-foreground));flex:none}
.room-toggle-arrow svg{width:12px;height:12px}
.room-toggle.open .room-toggle-arrow{transform:rotate(90deg)}
.room-toggle.open{border-radius:var(--radius) var(--radius) 0 0;border-bottom-color:transparent}
.room-body{display:none;padding:8px 10px 10px;background:hsl(var(--card));border:1px solid hsl(var(--border));border-top:0;
  border-radius:0 0 var(--radius) var(--radius);margin-bottom:4px}
.room-body.open{display:block}

.hist-cal{display:grid;grid-template-columns:repeat(7,1fr);gap:2px;margin-top:8px;text-align:center}
.hist-cal-hdr{font-size:11px;font-weight:600;color:hsl(var(--muted-foreground));padding:4px 0}
.hist-cal-day{font-size:13px;padding:6px 0;border-radius:var(--radius);cursor:pointer;background:none;border:none;color:hsl(var(--foreground));position:relative}
.hist-cal-day:hover{background:hsl(var(--muted))}
.hist-cal-day.empty{cursor:default}
.hist-cal-day.today{font-weight:700;color:hsl(var(--primary))}
.hist-cal-day.sel{background:hsl(var(--primary));color:hsl(var(--primary-foreground));font-weight:600}
.hist-cal-day.has-logs::after{content:"";position:absolute;bottom:2px;left:50%;transform:translateX(-50%);width:4px;height:4px;border-radius:50%;background:hsl(var(--primary))}
.hist-cal-day.sel.has-logs::after{background:hsl(var(--primary-foreground))}
.hist-cal-day.muted{color:hsl(var(--muted-foreground)/.5)}
.hist-filters{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:10px}
.hist-filters input[type="search"]{grid-column:1/-1}
.hist-boxes{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
@media(min-width:500px){.hist-boxes{grid-template-columns:repeat(4,1fr)}}
@media(max-width:360px){.hist-boxes{grid-template-columns:repeat(2,1fr)}}
.hist-box{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;
  padding:12px 6px;min-height:80px;background:hsl(var(--muted));border:1px solid hsl(var(--border));border-radius:var(--radius);text-align:center}
.hist-box-ic{width:28px;height:28px;display:grid;place-items:center;color:hsl(var(--muted-foreground))}
.hist-box-ic svg{width:22px;height:22px}
.hist-box-label{font-size:12px;font-weight:500;line-height:1.2}
.thumbs{display:flex;gap:6px;margin-top:8px;flex-wrap:wrap}
.thumbs img{width:56px;height:56px;object-fit:cover;border-radius:calc(var(--radius) - 2px);border:1px solid hsl(var(--border));background:hsl(var(--muted))}
.empty{padding:28px 16px;text-align:center;color:hsl(var(--muted-foreground))}

/* stock — shadcn Progress */
.stock-n{font-size:24px;font-weight:600;min-width:56px;text-align:right;letter-spacing:-.025em}
.bar{height:6px;border-radius:999px;background:hsl(var(--primary)/.12);overflow:hidden;margin-top:8px}
.bar i{display:block;height:100%;background:hsl(var(--primary));border-radius:999px}
.bar i.low{background:hsl(var(--destructive))}

/* forms — shadcn Input / Label / Select */
label.f{display:block;font-size:14px;font-weight:500;line-height:1;margin:18px 0 8px;color:hsl(var(--foreground))}
.in{width:100%;border:1px solid hsl(var(--input));background:hsl(var(--muted)/.45);border-radius:var(--radius);padding:0 12px;font-size:16px;height:40px;
  box-shadow:var(--shadow-sm);transition:box-shadow .15s}
select.in{appearance:none;-webkit-appearance:none;padding-right:34px;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%2371717a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' viewBox='0 0 24 24'%3E%3Cpath d='m7 15 5 5 5-5M7 9l5-5 5 5'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 10px center;background-color:hsl(var(--muted)/.45)}
textarea.in{height:auto;min-height:72px;padding:8px 12px;resize:vertical}
.in:focus{outline:none;box-shadow:0 0 0 1px hsl(var(--ring))}
.in::placeholder{color:hsl(var(--muted-foreground))}
input[type=checkbox]{width:16px;height:16px;accent-color:hsl(var(--primary))}
.stepper{display:flex;align-items:center;width:max-content;border:1px solid hsl(var(--input));border-radius:var(--radius);overflow:hidden;box-shadow:var(--shadow-sm)}
.stepper button{width:44px;height:40px;border:0;background:hsl(var(--background));font-size:18px;font-weight:500}
.stepper button:hover{background:hsl(var(--accent))}
.stepper input{width:64px;text-align:center;border:0;border-left:1px solid hsl(var(--input));border-right:1px solid hsl(var(--input));background:transparent;height:40px;font-size:16px;font-weight:600}
.stepper input:focus{outline:none}
.photos-in{display:flex;gap:8px;flex-wrap:wrap}
.photos-in .ph{position:relative}
.photos-in img{width:72px;height:72px;object-fit:cover;border-radius:var(--radius);border:1px solid hsl(var(--border))}
.photos-in .x{position:absolute;top:-6px;right:-6px;width:22px;height:22px;border-radius:50%;border:0;background:hsl(var(--primary));color:hsl(var(--primary-foreground));font-size:13px;line-height:1}
.add-photo{width:72px;height:72px;border-radius:var(--radius);border:1px dashed hsl(var(--input));display:grid;place-items:center;color:hsl(var(--muted-foreground));background:transparent;cursor:pointer}
.add-photo:hover{background:hsl(var(--accent))}
.add-photo svg{width:22px;height:22px}

/* drawer — shadcn Drawer (vaul) */
.scrim{position:fixed;inset:0;background:rgb(0 0 0/.8);z-index:20;display:flex;align-items:flex-end;justify-content:center;animation:fade .15s}
.sheet{background:hsl(var(--background));width:100%;max-width:640px;max-height:92vh;overflow:auto;border:1px solid hsl(var(--border));border-bottom:0;
  border-radius:12px 12px 0 0;padding:8px 16px calc(16px + env(safe-area-inset-bottom));animation:up .22s cubic-bezier(.32,.72,0,1)}
@media (min-width:700px){.scrim{align-items:center}.sheet{border-radius:calc(var(--radius) + 4px);border-bottom:1px solid hsl(var(--border));box-shadow:0 10px 30px rgb(0 0 0/.2)}}
.sheet .grab{width:100px;height:6px;border-radius:999px;background:hsl(var(--muted));margin:8px auto 14px}
.sheet-h{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:2px}
.sheet-h h2{font-size:18px}
.sheet-f{position:sticky;bottom:calc(-16px - env(safe-area-inset-bottom));background:hsl(var(--background));padding:14px 0 6px;margin-top:20px;display:flex;gap:8px}
@keyframes up{from{transform:translateY(40px);opacity:.4}}
@keyframes fade{from{opacity:0}}

/* toast — sonner */
#toast{position:fixed;left:50%;bottom:calc(var(--nav-h) + env(safe-area-inset-bottom) + 14px);transform:translateX(-50%) translateY(16px);
  background:hsl(var(--popover));color:hsl(var(--foreground));border:1px solid hsl(var(--border));box-shadow:0 4px 12px rgb(0 0 0/.1);
  padding:12px 16px;border-radius:var(--radius);font-weight:500;font-size:13px;opacity:0;pointer-events:none;transition:.2s;z-index:40;
  width:max-content;max-width:calc(100% - 32px)}
#toast.on{opacity:1;transform:translateX(-50%) translateY(0)}

/* login — InputOTP style */
.login{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:24px 16px;gap:20px}
.login .logo{width:56px;height:56px;border-radius:12px}
.login .logo-login{margin-bottom:4px}
.login .brand{color:hsl(var(--muted-foreground))!important;letter-spacing:.02em!important;font-weight:500!important}
.pin-dots{display:flex;height:48px}
.pin-dots i{width:44px;height:48px;border:1px solid hsl(var(--input));border-left-width:0;display:grid;place-items:center;box-shadow:var(--shadow-sm);position:relative}
.pin-dots i:first-child{border-left-width:1px;border-radius:var(--radius) 0 0 var(--radius)}
.pin-dots i:last-child{border-radius:0 var(--radius) var(--radius) 0}
.pin-dots i.f::after{content:"";width:10px;height:10px;border-radius:50%;background:hsl(var(--foreground))}
.pad{display:grid;grid-template-columns:repeat(3,76px);gap:10px}
.pad button{height:60px;border-radius:var(--radius);border:1px solid hsl(var(--input));background:hsl(var(--background));font-size:22px;font-weight:500;box-shadow:var(--shadow-sm)}
.pad button:hover,.pad button:active{background:hsl(var(--accent))}
.pad button.ghost{border:0;background:transparent;box-shadow:none;font-size:14px;color:hsl(var(--muted-foreground))}
#go{min-width:248px!important;height:40px}
.shake{animation:shake .35s}
@keyframes shake{25%{transform:translateX(-6px)}75%{transform:translateX(6px)}}

/* guest calendar */
.gcal{overflow-x:auto;-webkit-overflow-scrolling:touch;border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);background:hsl(var(--card));box-shadow:var(--shadow)}
.gcal-inner{min-width:640px}
.gcal-row{display:grid;grid-template-columns:78px repeat(var(--days),minmax(40px,1fr));border-top:1px solid hsl(var(--border));position:relative}
.gcal-row:first-child{border-top:0}
.gcal-row .rl{position:sticky;left:0;background:hsl(var(--card));z-index:2;padding:8px;font-size:13px;font-weight:500;border-right:1px solid hsl(var(--border));display:flex;align-items:center;gap:6px}
.gcal-head .dc{font-size:11px;text-align:center;padding:6px 0;color:hsl(var(--muted-foreground));border-left:1px solid hsl(var(--border))}
.gcal-head .dc b{display:block;font-size:14px;font-weight:600;color:hsl(var(--foreground))}
.gcal-head .dc.today{background:hsl(var(--muted))}
.gcal-head .dc.today b{display:inline-grid;place-items:center;width:26px;height:26px;border-radius:50%;background:hsl(var(--primary));color:hsl(var(--primary-foreground));margin-top:1px}
.gcal-cell{border-left:1px solid hsl(var(--border));min-height:48px}
.gcal-cell.today{background:hsl(var(--muted)/.6)}
.gbar{grid-row:1;z-index:1;margin:8px 2px;border-radius:calc(var(--radius) - 2px);padding:4px 8px;font-size:12px;font-weight:600;color:#fff;overflow:hidden;
  white-space:nowrap;text-overflow:ellipsis;border:0;text-align:left;align-self:center;min-height:32px;line-height:1.2}
.gbar small{display:block;font-weight:500;opacity:.85;font-size:11px}

/* bookings timeline (Hostaway-style) */
.tl-wrap{border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);overflow:hidden;background:hsl(var(--card))}
.tl-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch}
.tl-head{display:flex;border-bottom:1px solid hsl(var(--border));background:hsl(var(--accent)/.3)}
.tl-head .tl-label{width:60px;min-width:60px;position:sticky;left:0;z-index:3;background:hsl(var(--accent)/.3);border-right:1px solid hsl(var(--border))}
.tl-dh{flex:1;min-width:28px;padding:4px 0;text-align:center}
.tl-dh.today{background:hsl(var(--primary)/.2)}
.tl-dow{font-size:8px;color:hsl(var(--muted-foreground))}
.tl-dn{font-size:10px;font-weight:500}
.tl-dn.today{color:hsl(var(--primary))}
.tl-row{display:flex;border-bottom:1px solid hsl(var(--border)/.5);min-height:36px}
.tl-row:last-child{border-bottom:0}
.tl-row .tl-label{width:60px;min-width:60px;position:sticky;left:0;z-index:3;background:hsl(var(--card));border-right:1px solid hsl(var(--border));padding:8px 6px;font-size:10px;font-weight:500;display:flex;align-items:center}
.tl-cells{display:flex;flex:1;position:relative}
.tl-cell{flex:1;min-width:28px;border-right:1px solid hsl(var(--border)/.1)}
.tl-cell.today{background:hsl(var(--primary)/.1)}
.tl-bar{position:absolute;top:4px;bottom:4px;border-radius:4px;padding:0 6px;font-size:9px;font-weight:600;color:#fff;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;border:0;display:flex;align-items:center;margin-left:2px;cursor:pointer;transition:opacity .15s}
.tl-bar:hover{opacity:.85}
.tl-bar span{overflow:hidden;text-overflow:ellipsis}

/* channel legend */
.cal-legend{display:flex;flex-wrap:wrap;gap:10px;font-size:11px;color:hsl(var(--muted-foreground))}
.cal-legend span{display:flex;align-items:center;gap:4px}
.dot-ch{display:inline-block;width:8px;height:8px;border-radius:2px;flex-shrink:0}

/* channel bg chips */
.bg-airbnb{background:rgba(255,90,95,.15);color:#ff5a5f}
.bg-bookingcom{background:rgba(0,53,128,.2);color:#4a90d9}
.bg-direct{background:rgba(5,150,105,.15);color:#34d399}
.bg-other{background:rgba(13,148,136,.15);color:#2dd4bf}

/* guest cards */
.guest-grid{display:grid;gap:8px}
.guest-card{background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 2px);padding:10px 12px;cursor:pointer;transition:border-color .15s}
.guest-card:hover{border-color:hsl(var(--primary)/.3)}
.guest-card svg{width:14px;height:14px}
.guest-av{width:36px;height:36px;border-radius:50%;background:hsl(var(--muted)/.3);display:grid;place-items:center;flex-shrink:0}
.guest-av svg{width:16px;height:16px;color:hsl(var(--muted-foreground))}
.wa-btn{width:36px;height:36px;border-radius:50%;background:rgba(37,211,102,.15);display:grid;place-items:center;flex-shrink:0;color:#25d366}
.wa-btn svg{width:16px;height:16px}
.wa-btn:hover{background:rgba(37,211,102,.25)}
.badge-sm{font-size:10px;font-weight:500;background:hsl(var(--muted)/.5);padding:1px 6px;border-radius:8px}
.badge-in{font-size:10px;font-weight:700;background:rgba(16,185,129,.2);color:#34d399;padding:2px 8px;border-radius:4px}
.badge-out{font-size:10px;font-weight:700;background:rgba(245,158,11,.2);color:#fbbf24;padding:2px 8px;border-radius:4px}
.badge-stay{font-size:10px;font-weight:700;background:hsl(var(--muted)/.5);color:hsl(var(--muted-foreground));padding:2px 8px;border-radius:4px}
.badge-up{font-size:10px;font-weight:700;background:hsl(var(--muted)/.5);color:hsl(var(--muted-foreground));padding:2px 8px;border-radius:4px}
.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}

/* door code (small lock) */
.door-code{display:flex;align-items:center;gap:2px;margin-top:4px;font-size:11px;font-weight:600;color:hsl(var(--foreground))}
.door-code svg{width:12px;height:12px;color:hsl(var(--muted-foreground))}

/* expandable guest profile */
.gc-expand{border-top:1px solid hsl(var(--border)/.5);margin-top:8px;padding-top:8px}
.gc-profile{display:flex;flex-direction:column;gap:8px}
.gc-profile svg{width:12px;height:12px;vertical-align:-1px}
.gc-stats{display:flex;gap:6px;flex-wrap:wrap}
.gc-stat{font-size:11px;font-weight:500;background:hsl(var(--primary)/.1);color:hsl(var(--primary));padding:2px 8px;border-radius:4px}
.gc-stat.returning{background:rgba(16,185,129,.15);color:#34d399}
.gc-history{margin-top:2px}
.gc-stays{width:100%;border-collapse:collapse;font-size:10px;color:hsl(var(--muted-foreground))}
.gc-stays td{padding:2px 6px 2px 0}
.gc-stays td.t{color:hsl(var(--foreground)/.8);font-weight:500}

/* upcoming collapse */
.cal-collapse{display:flex;align-items:center;gap:8px;width:100%;padding:10px 14px;margin-top:18px;border:1px solid hsl(var(--border));border-radius:var(--radius);background:hsl(var(--card));cursor:pointer;text-align:left}
.cal-collapse svg{width:16px;height:16px;color:hsl(var(--muted-foreground));transition:transform .15s}
.cal-collapse.open svg:last-child{transform:rotate(90deg)}
.cal-collapse-body{margin-top:8px;display:grid;gap:8px}

/* table / report */
table.t{width:100%;border-collapse:collapse;font-size:13px}
table.t th,table.t td{padding:8px 6px;border-bottom:1px solid hsl(var(--border));text-align:right}
table.t tbody tr:last-child td{border-bottom:0}
table.t th:first-child,table.t td:first-child{text-align:left}
table.t thead th{color:hsl(var(--muted-foreground));font-weight:500;height:36px}
table.t tbody tr:hover{background:hsl(var(--muted)/.5)}
.hbar{display:grid;grid-template-columns:110px 1fr auto;gap:10px;align-items:center;font-size:13px;margin:8px 0}
.hbar .b{height:8px;border-radius:999px;background:hsl(var(--chart-2))}
.kpis{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}
.kpi .v{font-size:24px;font-weight:700;letter-spacing:-.025em;line-height:1.2;margin-top:2px}
.kpi .l{font-size:13px;color:hsl(var(--muted-foreground));font-weight:500}

/* daily routine */
/* action buttons group */
.action-row{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:20px}
.action-row.tri{grid-template-columns:repeat(3,1fr)}
.action-btn{display:flex;flex-direction:column;align-items:center;gap:6px;padding:14px 8px;text-align:center;
  background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow);transition:background .15s,transform .1s}
.action-btn:hover{background:hsl(var(--accent))}
.action-btn:active{transform:scale(.98)}
.action-btn .ic-md{width:36px;height:36px;border-radius:var(--radius);display:grid;place-items:center;flex:none}
.action-btn .ic-md svg{width:20px;height:20px}
.action-btn.routine .ic-md{background:hsl(var(--primary));color:hsl(var(--primary-foreground))}
.action-btn.checkin .ic-md{background:hsl(var(--success)/.15);color:hsl(var(--success))}
.action-btn.checkout .ic-md{background:hsl(var(--chart-1)/.15);color:hsl(var(--chart-1))}
.action-btn .t{font-size:13px;font-weight:600}
.action-btn .small{font-size:11px}
.sec-label{font-size:13px;font-weight:600;text-transform:uppercase;letter-spacing:.04em;
  color:hsl(var(--muted-foreground));margin:16px 0 6px;padding-bottom:6px;border-bottom:1px solid hsl(var(--border))}

.routine-btn{width:100%;display:flex;align-items:center;gap:14px;padding:16px 18px;margin-top:20px;
  background:hsl(var(--card));border:2px solid hsl(var(--primary));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow);text-align:left;transition:background .15s,transform .1s}
.routine-btn:hover{background:hsl(var(--accent))}
.routine-btn:active{transform:scale(.98)}
.routine-btn .ic-lg{width:48px;height:48px;border-radius:var(--radius);background:hsl(var(--primary));color:hsl(var(--primary-foreground));display:grid;place-items:center;flex:none}
.routine-btn .ic-lg svg{width:24px;height:24px}
.routine-btn .t{font-size:16px;font-weight:600}
.routine-rooms{display:flex;flex-direction:column;gap:10px;margin-top:12px}
.routine-room-card{display:flex;align-items:center;gap:12px;padding:12px 14px;
  background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow)}
.routine-room-card .room-icon{width:44px;height:44px;border-radius:calc(var(--radius) + 2px);
  display:grid;place-items:center;flex:none;
  background:hsl(var(--muted));color:hsl(var(--foreground))}
.routine-room-card .room-icon svg{width:22px;height:22px}
.routine-room-card .room-name{font-size:15px;font-weight:600;flex:1;min-width:0}
.routine-room-actions{display:flex;gap:6px;flex:none}
.routine-room-actions button{padding:10px 18px;border-radius:var(--radius);font-size:13px;font-weight:600;
  transition:all .15s;border:1px solid transparent}
.routine-room-actions .act-clean{background:hsl(var(--primary));color:hsl(var(--primary-foreground))}
.routine-room-actions .act-clean:active{transform:scale(.95)}
.routine-room-actions .act-dnd{background:hsl(var(--muted));color:hsl(var(--muted-foreground))}
.routine-room-actions .act-dnd:active{transform:scale(.95)}
.routine-room-card.completed{opacity:.55}
.routine-room-card.completed .room-icon{background:hsl(var(--success) / .2);color:hsl(var(--success))}
.routine-room-card.is-dnd{opacity:.55}
.routine-room-card.is-dnd .room-icon{background:hsl(var(--muted));color:hsl(var(--muted-foreground))}
.room-status{font-size:12px;font-weight:600;flex:none}
.room-status.done{color:hsl(var(--success))}
.room-status.dnd{color:hsl(var(--muted-foreground))}
.room-status.wip{color:hsl(var(--primary))}
.routine-room-card.area-btn{cursor:pointer;transition:all .15s}
.routine-room-card.area-btn:hover{background:hsl(var(--accent))}
.routine-room-card.area-btn:active{transform:scale(.97)}

/* routine clean/dnd choice */
.routine-choice{display:flex;flex-direction:column;gap:10px;margin-top:8px}
.routine-choice-btn{display:flex;align-items:center;gap:14px;padding:18px;width:100%;
  background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow);text-align:left;transition:background .15s,transform .1s}
.routine-choice-btn:hover{background:hsl(var(--accent))}
.routine-choice-btn:active{transform:scale(.98)}
.routine-choice-btn .ic-lg{width:48px;height:48px;border-radius:var(--radius);display:grid;place-items:center;flex:none}
.routine-choice-btn.clean .ic-lg{background:hsl(var(--success)/.15);color:hsl(var(--success))}
.routine-choice-btn.dnd .ic-lg{font-size:24px}
.routine-choice-btn .t{font-size:16px;font-weight:600}

/* area grid */
.area-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-top:8px}
@media (max-width:360px){.area-grid{grid-template-columns:repeat(2,1fr)}}
@media (min-width:500px){.area-grid{grid-template-columns:repeat(4,1fr)}}
.area-card{display:flex;flex-direction:column;align-items:center;gap:6px;padding:12px 6px;position:relative;
  background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow);transition:background .15s,transform .1s}
.area-card:hover{background:hsl(var(--accent))}
.area-card:active{transform:scale(.97)}
.area-card.done{border-color:hsl(var(--success));background:hsl(var(--success)/.08)}
.area-icon{width:36px;height:36px;border-radius:var(--radius);background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center}
.area-icon svg{width:20px;height:20px}
.area-card.done .area-icon{background:hsl(var(--success)/.2);color:hsl(var(--success))}
.area-label{font-size:12px;font-weight:500;text-align:center;line-height:1.2}
.area-check{position:absolute;top:6px;right:6px;color:hsl(var(--success))}
.area-check svg{width:16px;height:16px}
.area-progress{text-align:center;margin-top:14px;font-size:13px;font-weight:500;color:hsl(var(--muted-foreground))}

/* task boxes (level 3) */
.task-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.task-box{display:flex;flex-direction:column;align-items:center;gap:6px;padding:14px 8px;
  background:hsl(var(--card));border:2px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  box-shadow:var(--shadow-sm);transition:background .15s,border-color .15s,transform .1s;text-align:center}
.task-box:active{transform:scale(.97)}
.task-box.on{border-color:hsl(var(--success));background:hsl(var(--success)/.1)}
.task-ic{width:32px;height:32px;border-radius:var(--radius);background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center}
.task-ic svg{width:18px;height:18px}
.task-box.on .task-ic{background:hsl(var(--success)/.2);color:hsl(var(--success))}
.task-label{font-size:12px;font-weight:500;line-height:1.25}
.lvl-box,.qty-box{pointer-events:auto;cursor:pointer}
.lvl-box:active,.qty-box:active{transform:scale(.97)}
.lvl-btns{display:flex;gap:4px;flex-wrap:wrap;justify-content:center;margin-top:4px}
.lvl-btn{border:1px solid hsl(var(--border));background:hsl(var(--muted));color:hsl(var(--foreground));border-radius:calc(var(--radius) - 2px);padding:2px 6px;font-size:10px;font-weight:500;cursor:pointer}
.lvl-btn.on{border-color:hsl(var(--success));background:hsl(var(--success)/.15);color:hsl(var(--success))}
.qty-stepper{display:flex;align-items:center;gap:0;margin-top:6px;border:1px solid hsl(var(--border));border-radius:calc(var(--radius) - 2px);overflow:hidden}
.qty-m,.qty-p{width:32px;height:28px;border:none;background:hsl(var(--muted));color:hsl(var(--foreground));font-size:16px;font-weight:600;cursor:pointer;display:grid;place-items:center}
.qty-m:active,.qty-p:active{background:hsl(var(--muted-foreground)/.2)}
.qty-val{width:32px;text-align:center;font-size:14px;font-weight:600;color:hsl(var(--foreground));background:hsl(var(--card))}
.qty-box.on .qty-val{color:hsl(var(--success))}
.qty-box.on .qty-m,.qty-box.on .qty-p{background:hsl(var(--success)/.12);color:hsl(var(--success))}
.routine-checks{display:flex;flex-direction:column;gap:2px;margin-top:8px}
.routine-row{display:flex;align-items:center;gap:8px;padding:10px 4px;border-bottom:1px solid hsl(var(--border))}
.routine-row:last-child{border-bottom:0}
.routine-check{display:flex;align-items:center;gap:10px;flex:1;min-width:0;cursor:pointer;font-size:14px;font-weight:500}
.routine-check input[type=checkbox]{width:20px;height:20px;accent-color:hsl(var(--primary));flex:none}
.set-sub{padding-left:24px;border-left:2px solid hsl(var(--border));margin-left:12px;margin-bottom:4px}
.set-sub .routine-row{padding:6px 4px}
.set-sub .routine-check{font-size:13px}
.ic-sm{width:28px;height:28px;border-radius:4px;background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center;flex:none}
.ic-sm svg{width:15px;height:15px}
.stepper.sm{transform:scale(.85);transform-origin:right center}
.stepper.sm input{width:48px}

/* history grouped */
.hist-room-card{background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);
  padding:14px;margin-top:8px;box-shadow:var(--shadow);cursor:pointer;transition:background .15s}
.hist-room-card:hover{background:hsl(var(--muted)/.5)}
.hist-tasks{display:flex;flex-wrap:wrap;gap:6px}
.hist-task{display:inline-flex;align-items:center;gap:4px;background:hsl(var(--muted));border-radius:calc(var(--radius) - 2px);
  padding:4px 10px;font-size:13px;font-weight:500}
.ic-xs{width:18px;height:18px;display:grid;place-items:center;flex:none;color:hsl(var(--muted-foreground))}
.ic-xs svg{width:13px;height:13px}

/* drag-and-drop sort */
.sort-drag{opacity:.25;transform:scale(.95)}
.sort-ghost{opacity:.92;transform:scale(1.05);box-shadow:0 8px 24px rgba(0,0,0,.35);border-radius:calc(var(--radius) + 4px);transition:none}
.sort-placeholder{border:2px dashed hsl(var(--muted-foreground)/.35);border-radius:var(--radius);background:hsl(var(--muted)/.3);box-sizing:border-box}
.task-grid,.area-grid{transition:none}
.task-grid>[data-sort-id],.area-grid>[data-sort-id]{transition:transform .15s ease}


/* admin console */
.admin-tabs{display:flex;gap:4px;overflow-x:auto;padding:2px 0 12px;-webkit-overflow-scrolling:touch}
.admin-tab{display:flex;align-items:center;gap:5px;padding:8px 14px;border:1.5px solid hsl(var(--border));
  border-radius:calc(var(--radius) + 2px);background:hsl(var(--card));font-size:13px;font-weight:500;white-space:nowrap;cursor:pointer;transition:all .15s}
.admin-tab.on{border-color:hsl(var(--foreground));background:hsl(var(--foreground));color:hsl(var(--background))}
.admin-tab.on .ic-xs{color:hsl(var(--background))}
.admin-stock-row{display:flex;align-items:center;gap:8px;padding:6px 0;border-bottom:1px solid hsl(var(--border)/.5)}
.admin-stock-row:last-child{border-bottom:0}
.bar.sm{width:60px;flex:none}
.admin-log-row{padding:10px 0;border-bottom:1px solid hsl(var(--border)/.5)}
.admin-log-row:last-child{border-bottom:0}
.admin-staff-stats{display:flex;flex-wrap:wrap;gap:6px}
.admin-stat-chip{display:flex;align-items:center;gap:8px;padding:6px 12px;background:hsl(var(--muted));border-radius:calc(var(--radius) + 2px);font-size:13px}

/* checkout sections — accordion */
.co-sections{display:flex;flex-direction:column;gap:8px}
.co-sec{background:hsl(var(--card));border:1px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);box-shadow:var(--shadow-sm);overflow:hidden;transition:border-color .2s}
.co-sec-h{display:flex;align-items:center;gap:8px;padding:14px;font-weight:600;font-size:15px;cursor:pointer;-webkit-tap-highlight-color:transparent}
.co-sec-title{flex:1}
.co-sec-done{display:none;color:hsl(var(--success))}
.co-sec.done .co-sec-done{display:flex}
.co-sec.done .co-sec-ic{color:hsl(var(--success))}
.co-sec.done{border-color:hsl(var(--success)/.4)}
.co-sec-body{max-height:0;overflow:hidden;padding:0 14px;transition:max-height .25s ease,padding .25s ease}
.co-sec.open .co-sec-body{max-height:800px;padding:0 14px 14px}
.co-chips{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}
@media(min-width:420px){.co-chips{grid-template-columns:repeat(3,1fr)}}
.co-chips .chip{display:flex;flex-direction:column;align-items:center;gap:6px;padding:14px 8px;
  border:2px solid hsl(var(--border));border-radius:calc(var(--radius) + 4px);background:hsl(var(--card));
  font-size:12px;font-weight:500;cursor:pointer;transition:all .15s;text-align:center;min-height:72px;justify-content:center}
.co-chips .chip .co-chip-ic{width:28px;height:28px;border-radius:var(--radius);background:hsl(var(--muted));color:hsl(var(--foreground));display:grid;place-items:center}
.co-chips .chip .co-chip-ic svg{width:16px;height:16px}
.co-chips .chip:active{transform:scale(.96)}
.co-chips .chip.on{border-color:hsl(var(--success));background:hsl(var(--success)/.1);color:hsl(var(--success))}
.co-chips .chip.on .co-chip-ic{background:hsl(var(--success)/.2);color:hsl(var(--success))}
.co-chips .chip.alert.on{border-color:hsl(var(--destructive));background:hsl(var(--destructive)/.1);color:hsl(var(--destructive))}
.co-chips .chip.alert.on .co-chip-ic{background:hsl(var(--destructive)/.2);color:hsl(var(--destructive))}
.ci-qty-grid{gap:8px}.ci-qty-grid .qty-box{min-height:auto;padding:10px 8px}
.co-sec-body .routine-checks{margin:0}.co-sec-body .routine-row{padding:4px 0}
.ci-fields{display:flex;flex-direction:column;gap:10px}.ci-field{display:flex;flex-direction:column;gap:4px}.ci-field-label{font-size:13px;color:var(--c3);font-weight:500}

/* phone copy button */
.copy-btn{width:36px;height:36px;border-radius:50%;background:hsl(var(--muted));display:grid;place-items:center;flex-shrink:0;color:hsl(var(--foreground));border:none;cursor:pointer;transition:background .15s}
.copy-btn:hover{background:hsl(var(--accent))}
.copy-btn svg{width:16px;height:16px}
.copy-btn.copied{background:hsl(var(--success)/.15);color:hsl(var(--success))}

/* history compact list */
.hist-li{display:flex;gap:10px;padding:10px 12px;align-items:center;border-top:1px solid hsl(var(--border));cursor:pointer;transition:background .15s}
.hist-li:first-child{border-top:0}
.hist-li:hover{background:hsl(var(--muted)/.5)}
.hist-li .ic-sm{flex:none}
.hist-li-info{flex:1;min-width:0}
.hist-li-top{display:flex;align-items:center;gap:6px}
.hist-li-detail{display:none;padding:8px 12px 10px;border-top:1px solid hsl(var(--border)/.5);background:hsl(var(--muted)/.3)}
.hist-li-detail.open{display:block}

/* staff report */
.staff-report-sec{margin-top:16px}
.staff-report-sec h3{font-size:14px;margin-bottom:8px}
.report-row{display:flex;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid hsl(var(--border)/.5);cursor:pointer}
.report-row:last-child{border-bottom:0}
.report-row:hover{background:hsl(var(--muted)/.3)}
.report-detail{display:none;padding:6px 12px 10px;background:hsl(var(--muted)/.2)}
.report-detail.open{display:block}
.report-detail .li{padding:6px 0;border-top:1px solid hsl(var(--border)/.3)}
.report-detail .li:first-child{border-top:0}

.ldr-items{display:flex;flex-direction:column;gap:6px}
.ldr-item{display:flex;align-items:center;gap:10px;padding:8px 12px;border-radius:var(--radius);background:hsl(var(--muted)/.25)}
.ldr-item .grow{font-weight:500;font-size:14px}
.ldr-item{flex-wrap:wrap}
.ldr-miss-label{display:flex;align-items:center;gap:4px;width:100%;order:10;margin-top:4px;cursor:pointer;font-size:12px;color:hsl(var(--muted-foreground))}
.ldr-miss-cb{accent-color:hsl(var(--destructive));width:16px;height:16px;cursor:pointer}
.ldr-miss-cb:checked+.ldr-miss-box{color:hsl(var(--destructive));font-weight:600}
.ldr-item:has(.ldr-miss-cb:checked){background:hsl(var(--destructive)/.08)}
.ldr-miss-qty{display:flex;align-items:center;gap:2px;width:100%;order:11;margin-top:4px;font-size:12px}
.ldr-miss-qty.hide{display:none}
.ldr-miss-qty .qty-btn{width:24px;height:24px;border:1px solid hsl(var(--border));border-radius:var(--radius);background:hsl(var(--muted)/.3);font-size:14px;font-weight:600;cursor:pointer;display:grid;place-items:center;color:hsl(var(--fg))}
.ldr-miss-qty .ldr-mq-val{min-width:20px;text-align:center;font-weight:600;font-size:13px;color:hsl(var(--destructive))}
.qty-stepper{display:flex;align-items:center;gap:0;border:1px solid hsl(var(--border));border-radius:var(--radius);overflow:hidden}
.qty-stepper button{width:32px;height:32px;border:0;background:hsl(var(--muted)/.3);font-size:16px;font-weight:600;cursor:pointer;display:grid;place-items:center;color:hsl(var(--fg))}
.qty-stepper button:active{background:hsl(var(--muted)/.6)}
.qty-stepper .qty-val{min-width:36px;text-align:center;font-weight:600;font-size:14px}
.ldr-qc-list{display:flex;flex-direction:column;gap:4px}
.ldr-qc-row{padding:10px 12px;border-radius:var(--radius);background:hsl(var(--muted)/.25);cursor:pointer}
.ldr-qc-row.issue{background:hsl(var(--destructive)/.08)}
.ldr-qc-badge{width:24px;height:24px;border-radius:50%;display:grid;place-items:center}
.ldr-qc-badge.pass{background:hsl(var(--success)/.15);color:hsl(var(--success))}
.ldr-qc-badge.fail{background:hsl(var(--destructive)/.15);color:hsl(var(--destructive))}
.ldr-qc-issue{padding-top:8px}

.hist-chips{display:flex;gap:6px;margin:10px 0 8px;overflow-x:auto;-webkit-overflow-scrolling:touch}
.hist-chips .chip{display:inline-flex;align-items:center;gap:4px;padding:5px 12px;border-radius:20px;font-size:13px;white-space:nowrap;border:1px solid var(--line);background:var(--bg);color:var(--t2);cursor:pointer}
.hist-chips .chip svg{width:14px;height:14px}
.hist-chips .chip.on{background:var(--accent);color:#fff;border-color:var(--accent)}

.checks-detail{margin-top:6px;display:flex;flex-direction:column;gap:4px}
.chk-row{display:flex;flex-wrap:wrap;gap:4px}
.chk-tag{display:inline-flex;align-items:center;gap:3px;font-size:11px;padding:2px 7px;border-radius:8px;white-space:nowrap}
.chk-tag.ok{background:hsl(var(--success)/.12);color:hsl(var(--success))}
.chk-tag.fail{background:hsl(var(--destructive)/.12);color:hsl(var(--destructive))}
.chk-tag svg{width:11px;height:11px}
.co-detail-row{display:flex;align-items:baseline;gap:6px;flex-wrap:wrap;font-size:12px}
.co-detail-row svg{width:12px;height:12px;vertical-align:-1px}

.viewer{position:fixed;inset:0;background:rgb(0 0 0/.92);z-index:50;display:flex;align-items:center;justify-content:center}
.viewer img{max-width:100%;max-height:100%}

/* inventory collapsible groups */
.inv-group{margin-top:6px;border-radius:var(--radius);overflow:hidden;border:1px solid hsl(var(--border))}
.inv-group-h{display:flex;align-items:center;gap:8px;padding:10px 12px;cursor:pointer;font-weight:500;font-size:14px;list-style:none;background:hsl(var(--card));user-select:none}
.inv-group-name{font-weight:600}
.inv-group-h::-webkit-details-marker{display:none}
.inv-chev{display:flex;transition:transform .15s}
.inv-chev svg{width:16px;height:16px}
.inv-group[open] .inv-chev{transform:rotate(90deg)}
.inv-group .list{border-top:1px solid hsl(var(--border))}
.inv-sub{border-top:1px solid hsl(var(--border))}
.inv-sub-h{display:flex;align-items:center;gap:6px;padding:6px 12px;font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.04em;color:hsl(var(--muted-foreground));background:hsl(var(--muted));cursor:pointer;list-style:none;user-select:none}
.inv-sub-h::-webkit-details-marker{display:none}
.inv-chev-sm{display:flex;margin-left:auto;transition:transform .15s}
.inv-chev-sm svg{width:12px;height:12px}
.inv-sub[open] .inv-chev-sm{transform:rotate(90deg)}
.inv-sub .list{border-top:1px solid hsl(var(--border))}
.item-hist-list .li.sm{padding:6px 0;min-height:0}
.item-hist-list .li.sm .t{font-size:13px}
.item-hist-wrap .sec-h{padding:0;margin-bottom:4px}
.item-hist-wrap .sec-h h3{font-size:13px}
.inv-cd{display:inline-flex;align-items:center;gap:2px}
.inv-cd svg{width:11px;height:11px;color:hsl(var(--success))}
.item-photo-wrap{display:flex;flex-direction:column;align-items:center;gap:4px;margin-left:auto;flex-shrink:0}
.item-photo-thumb{width:56px;height:56px;object-fit:cover;border-radius:10px;cursor:pointer;border:1px solid hsl(var(--border))}
.item-photo-btn{cursor:pointer;display:inline-flex;align-items:center;gap:3px;font-size:11px;white-space:nowrap;padding:2px 6px}
.item-photo-btn input{display:none}
.inv-item-thumb{width:36px;height:36px;object-fit:cover;border-radius:6px;flex-shrink:0}
.scroll-up-fab{position:fixed;bottom:72px;right:16px;width:44px;height:44px;border-radius:50%;background:hsl(var(--card));border:1px solid hsl(var(--border));box-shadow:0 2px 8px rgba(0,0,0,.3);display:flex;align-items:center;justify-content:center;z-index:90;cursor:pointer;transition:opacity .2s}
.scroll-up-fab svg{width:22px;height:22px}
.scroll-up-fab.hidden{opacity:0;pointer-events:none}
#nl-badge-frame{display:none!important}
