/* The owner's space: a phone app look, same white, cream and ink as her shop. On a computer it stays a phone-wide column. */
body.admin-mode .top, body.admin-mode .foot, body.admin-mode .skip { display: none !important; }
body.admin-mode { background: var(--cream); }
.adm { max-width: 520px; min-height: 100svh; margin: 0 auto; background: var(--paper); position: relative; }
@media (min-width: 560px) { .adm { box-shadow: 0 0 0 1px var(--line), 0 30px 80px -40px rgba(60, 40, 20, .35); } }
.adm svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.adm-top {
  position: sticky; top: 0; z-index: 20; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px;
  padding: 12px 16px; background: rgba(251, 248, 243, .94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line);
}
.adm-top .logo { font-size: 26px; justify-self: start; }
.adm-top h1 { font-family: var(--kufi); font-size: 20px; text-align: center; }
.adm-top .icon-btn, .adm-top > span { justify-self: end; }
.icon-btn { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: var(--ink); }
.adm-back { justify-self: start; text-decoration: none; color: var(--mute); font-size: 15px; }
.adm-main { padding: 16px 16px 110px; }

.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%); z-index: 25; width: min(520px, 100%);
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: end;
  padding: 8px 6px calc(8px + env(safe-area-inset-bottom)); background: rgba(255, 255, 255, .96); border-top: 1px solid var(--line); backdrop-filter: blur(8px);
}
.tabbar a { display: grid; justify-items: center; gap: 2px; text-decoration: none; color: var(--mute); font-size: 12px; padding: 4px 0; }
.tabbar a.on { color: var(--ink); font-weight: 600; }
.tabbar a.plus svg { width: 26px; height: 26px; padding: 12px; box-sizing: content-box; border-radius: 50%; background: var(--ink); color: #fff; margin-top: -26px; box-shadow: 0 10px 24px -8px rgba(27, 24, 25, .5); }

/* lock */
.adm.lock { display: grid; place-items: center; padding: 24px; }
.lock-in { display: grid; gap: 14px; text-align: center; max-width: 340px; }
.lock-in .logo { font-size: 56px; }
.lock-in h1 { font-family: var(--kufi); font-size: 28px; }
.lock-in p { color: var(--mute); margin: 0; }

/* today */
.hello { margin: 0 0 12px; color: var(--mute); }
.sum { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 8px; }
.sum a { display: grid; gap: 0; padding: 12px 6px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); text-decoration: none; text-align: center; }
.sum b { font-family: var(--kufi); font-size: 28px; line-height: 1.2; font-variant-numeric: tabular-nums; }
.sum span { font-size: 12px; color: var(--mute); line-height: 1.3; }
.asec { margin-top: 22px; }
.asec h2 { font-family: var(--kufi); font-size: 19px; margin-bottom: 6px; display: flex; align-items: center; gap: 8px; }
.asec h2 i { font-style: normal; font-family: var(--sans); font-size: 12px; font-weight: 600; background: var(--ink); color: #fff; border-radius: 999px; padding: 0 8px; line-height: 20px; }
.muted.small { font-size: 13px; }

.arow { display: grid; grid-template-columns: 48px 1fr auto; gap: 12px; align-items: center; padding: 10px; margin-bottom: 8px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); cursor: pointer; }
.arow img { width: 48px; height: 62px; object-fit: cover; object-position: top; border-radius: 999px 999px 6px 6px; background: var(--cream); }
.arow-t { display: grid; min-width: 0; line-height: 1.45; }
.arow-t b { font-weight: 600; }
.arow-t span, .arow-t small { color: var(--mute); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; }
.arow-a { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.arow.fit { grid-template-columns: 52px 1fr auto; cursor: default; }
.arow .time { font-weight: 600; font-variant-numeric: tabular-nums; text-align: center; }
.warn { color: var(--taken); font-style: normal; }
.ok { color: var(--free); }

.stg { display: inline-block; padding: 1px 9px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; }
.st-pending { background: var(--prep-bg); color: var(--prep); }
.st-confirmed { background: #ece6fb; color: #5a43a8; }
.st-out { background: var(--taken-bg); color: var(--taken); }
.st-returned { background: #e4eef8; color: #2d5f8f; }
.st-cleaned { background: var(--free-bg); color: var(--free); }
.st-cancelled { background: #eee; color: #777; }

/* bookings */
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); margin-bottom: 10px; }
.seg button, .seg label span { display: block; border: 0; background: none; padding: 8px 4px; border-radius: 10px; cursor: pointer; color: var(--mute); font-weight: 500; text-align: center; }
.seg button.on, .seg input:checked + span { background: var(--ink); color: #fff; }
.seg label input { position: absolute; opacity: 0; pointer-events: none; }
.search { width: 100%; height: 46px; padding: 0 14px; border-radius: 14px; border: 1px solid var(--line-strong); background: var(--card); font-size: 16px; margin-bottom: 8px; }
.day-h { font-family: var(--kufi); font-size: 17px; margin: 18px 0 8px; color: var(--mute); }
.empty-note { text-align: center; padding: 30px 0; }

.bk-head { display: grid; grid-template-columns: 74px 1fr; gap: 14px; align-items: center; margin-bottom: 14px; }
.bk-head img { width: 74px; height: 98px; object-fit: cover; object-position: top; border-radius: 999px 999px 8px 8px; background: var(--cream); }
.bk-head div { display: grid; gap: 2px; justify-items: start; }
.bk-head b { font-family: var(--kufi); font-size: 22px; }
.bk-head span { color: var(--mute); }
.track { list-style: none; margin: 0 0 14px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; counter-reset: s; }
.track li { position: relative; text-align: center; font-size: 12.5px; color: var(--mute); padding-top: 18px; }
.track li::before { content: ""; position: absolute; top: 4px; inset-inline: 0; height: 4px; border-radius: 999px; background: var(--line); }
.track li.on { color: var(--ink); font-weight: 600; }
.track li.on::before { background: var(--ink); }
.primary-act { margin-bottom: 14px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 14px 16px; margin-bottom: 12px; }
.card h3 { font-family: var(--kufi); font-size: 18px; margin-bottom: 8px; }
.client { margin: 0 0 10px; display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; }
.money { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 6px 0; }
.money dt { color: var(--mute); }
.money dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.money dd.big { font-family: var(--kufi); font-size: 22px; }
.btn-row.two { grid-template-columns: 1fr 1fr; }
.card textarea, .sheet textarea { width: 100%; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line-strong); background: var(--paper); font: inherit; resize: vertical; }
.logl { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 14px; }
.logl span { color: var(--mute); margin-inline-end: 8px; font-variant-numeric: tabular-nums; }
.btn.danger { background: var(--taken); }
.btn.danger-t { color: var(--taken); }

/* new booking */
.stepper { list-style: none; margin: 0 0 16px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.stepper li { text-align: center; font-size: 12.5px; padding: 6px 0; border-radius: 10px; background: var(--card); border: 1px solid var(--line); color: var(--mute); }
.stepper li.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.stepper li.done { color: var(--ink); }
.pick { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.pick-d { display: grid; gap: 2px; padding: 6px; border-radius: 16px; border: 1px solid var(--line); background: var(--card); cursor: pointer; text-align: center; }
.pick-d img { width: 100%; aspect-ratio: 5 / 7; object-fit: cover; object-position: top; border-radius: 999px 999px 8px 8px; }
.pick-d b { font-size: 13px; font-weight: 600; line-height: 1.3; }
.pick-d small { color: var(--mute); font-size: 11.5px; }
.pick-d.on { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.chosen { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.chosen img { width: 46px; height: 60px; object-fit: cover; object-position: top; border-radius: 999px 999px 6px 6px; }
.chosen b { font-family: var(--kufi); font-size: 20px; }
.size.wide { min-width: 0; padding: 0 14px; }
.avail { padding: 12px 14px; border-radius: 14px; margin: 4px 0 8px; }
.avail.yes { background: var(--free-bg); color: var(--free); }
.avail.no { background: var(--taken-bg); color: var(--taken); }
.recap { display: flex; gap: 12px; align-items: center; padding: 12px; border-radius: 16px; background: var(--cream); margin-top: 8px; }
.recap img { width: 46px; height: 60px; object-fit: cover; object-position: top; border-radius: 999px 999px 6px 6px; }
.recap div { display: grid; line-height: 1.5; }
.recap span { color: var(--mute); font-size: 14px; }

/* dresses */
.tool { display: flex; gap: 8px; align-items: center; }
.tool .search { margin: 0; }
.tool .btn { white-space: nowrap; min-height: 46px; }
.legend-s { display: flex; gap: 14px; font-size: 12.5px; color: var(--mute); margin: 10px 0; }
.legend-s span { display: flex; align-items: center; gap: 5px; }
.legend-s i, .z { border-radius: 999px; }
.legend-s i { width: 9px; height: 9px; }
.free { --c: var(--free); --b: var(--free-bg); }
.out { --c: var(--taken); --b: var(--taken-bg); }
.clean { --c: #2d5f8f; --b: #e4eef8; }
.legend-s i { background: var(--c); }
.dgrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 10px; }
.dcard { display: grid; gap: 2px; text-decoration: none; }
.dimg { position: relative; aspect-ratio: 5 / 7; border-radius: 999px 999px 10px 10px; overflow: hidden; background: var(--cream); display: grid; place-items: center; }
.dimg img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.dimg .hid, .dimg .r360 { position: absolute; bottom: 8px; padding: 1px 8px; border-radius: 999px; font-size: 11.5px; }
.dimg .hid { right: 8px; background: var(--ink); color: #fff; }
.dimg .r360 { left: 8px; background: #fff; }
.dcard b { font-weight: 600; margin-top: 6px; }
.dcard small { color: var(--mute); font-size: 12.5px; }
.zs { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.z { font-size: 12px; padding: 0 7px; line-height: 20px; background: var(--b); color: var(--c); font-variant-numeric: tabular-nums; }
.dphoto { display: grid; justify-items: center; gap: 8px; margin-bottom: 14px; }
.dimg.big { width: min(220px, 60vw); }
.btn.file { cursor: pointer; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; text-align: center; }
.stats b { display: block; font-family: var(--kufi); font-size: 22px; }
.stats span { font-size: 12px; color: var(--mute); line-height: 1.35; display: block; }
.colrow { display: flex; gap: 8px; }
.colrow input[type=color] { width: 50px; padding: 4px; flex: none; }
.switch { display: flex; align-items: center; gap: 10px; margin: 6px 0 14px; cursor: pointer; }
.switch input { width: 22px; height: 22px; accent-color: var(--ink); }
.check { display: flex; align-items: center; gap: 10px; padding: 12px 14px; margin: 8px 0; border-radius: 14px; background: var(--paper); border: 1px solid var(--line); cursor: pointer; font-weight: 500; }
.check input { width: 22px; height: 22px; accent-color: var(--ink); }

/* bottom sheet */
.sheet-wrap { position: fixed; inset: 0; z-index: 80; background: rgba(27, 24, 25, .4); display: grid; align-items: end; justify-items: center; }
.sheet { width: min(520px, 100%); max-height: 88svh; overflow: auto; background: var(--paper); border-radius: 24px 24px 0 0; padding: 10px 18px calc(22px + env(safe-area-inset-bottom)); }
.sheet-grip { width: 44px; height: 5px; border-radius: 999px; background: var(--line-strong); margin: 0 auto 10px; }
.sheet h2 { font-family: var(--kufi); font-size: 22px; margin-bottom: 8px; }
.sheet .seg.two-way { grid-auto-columns: 1fr; }
.sheet .seg label { position: relative; }

/* forms inside the phone column must never push it wider */
.adm .two > *, .adm .field { min-width: 0; }
.adm .field input, .adm .field select { min-width: 0; }
.colrow > input { flex: 1 1 0; min-width: 0; }

/* login and first password */
.lock-in .field { text-align: start; }
.lock-in .check { justify-content: center; }
.lock-in .small { font-size: 13px; }

/* messages sit above the tab bar, not on it */
body.admin-mode .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }

/* a button followed by a card in the settings needs air */
.adm-main > .btn + .card { margin-top: 18px; }
