/* Área do barbeiro: feita para o celular, uma coluna, ações grandes. */
.muted { color: var(--muted); }
.mark, .av { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-family: var(--f-display); font-weight: 900; font-size: 18px; flex: none; }
.mark { border: 1.5px solid var(--brass); color: var(--brass); }
.av { background: var(--brass); color: #16130d; }

/* login */
.b-login { min-height: 100vh; display: grid; place-items: center; background: var(--ink); padding: 24px max(16px, env(safe-area-inset-right, 0px)) 24px max(16px, env(safe-area-inset-left, 0px)); }
.b-login-card { width: 100%; max-width: 420px; background: var(--surface); border-radius: 16px; padding: 28px; display: grid; gap: 16px; box-shadow: var(--shadow); }
.b-login-card h1 { font-size: 34px; margin-top: 4px; }
.b-login-card > .muted { margin-top: -10px; }
.b-login-card #demoLogin, .b-login-card #realLogin { display: grid; gap: 14px; }
.lbl { font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.who-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.who { display: flex; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); cursor: pointer; text-align: left; font-weight: 700; font-size: 13.5px; line-height: 1.2; min-width: 0; }
.who .av { width: 34px; height: 34px; font-size: 14px; background: var(--ink); color: var(--brass); }
.who span:last-child { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.who.on { border-color: var(--brass); box-shadow: inset 0 0 0 1px var(--brass); background: color-mix(in srgb, var(--brass-soft) 60%, var(--surface)); }
.pin { font-size: 22px; letter-spacing: .5em; text-align: center; font-variant-numeric: tabular-nums; }
.hint { font-size: 12.5px; color: var(--muted); background: var(--paper); padding: 10px 12px; border-radius: var(--radius-sm); }
.hint:empty { display: none; }
.form-err { color: var(--bad); font-weight: 600; font-size: 14px; }
.form-err:empty { display: none; }
.back-link { font-size: 13px; color: var(--muted); text-decoration: none; text-align: center; }

/* topo */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--ink); }
.b-head { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--ink); color: var(--on-ink); }
.b-head-in, .b-main, .b-days { max-width: 720px; margin: 0 auto; }
.b-head-in { display: flex; align-items: center; gap: 12px; padding: 14px max(16px, env(safe-area-inset-right, 0px)) 10px max(16px, env(safe-area-inset-left, 0px)); }
.b-hello { display: grid; line-height: 1.25; min-width: 0; }
.b-hello strong { font-family: var(--f-display); font-size: 22px; font-weight: 800; text-transform: uppercase; }
.b-hello span { font-size: 13px; color: var(--on-ink-muted); }
.b-out { margin-left: auto; background: transparent; color: var(--on-ink-muted); border-color: rgba(255,255,255,.18); }
.b-days-wrap { overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid rgba(255,255,255,.08); }
.b-days-wrap::-webkit-scrollbar { display: none; }
.b-days { display: flex; gap: 6px; padding: 4px max(16px, env(safe-area-inset-right, 0px)) 12px max(16px, env(safe-area-inset-left, 0px)); width: max-content; min-width: 100%; }
.b-day { flex: none; width: 56px; padding: 8px 0 7px; border-radius: 10px; border: 1px solid rgba(255,255,255,.1); background: transparent; color: var(--on-ink); display: grid; gap: 1px; justify-items: center; cursor: pointer; position: relative; }
.b-day small { font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--on-ink-muted); }
.b-day strong { font-family: var(--f-display); font-size: 22px; font-weight: 800; line-height: 1; }
.b-day em { font-style: normal; font-size: 10.5px; color: var(--on-ink-muted); font-variant-numeric: tabular-nums; }
.b-day.on { background: var(--brass); border-color: var(--brass); color: #16130d; }
.b-day.on small, .b-day.on em { color: rgba(22,19,13,.7); }
.b-day[disabled] { opacity: .35; cursor: default; }

/* conteúdo */
.b-main { padding: 18px max(16px, env(safe-area-inset-right, 0px)) calc(40px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 16px; }
.demo-note { font-size: 12.5px; font-weight: 700; color: var(--brass-strong); background: var(--brass-soft); padding: 8px 12px; border-radius: var(--radius-sm); }
.b-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.b-stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: grid; gap: 2px; min-width: 0; }
.b-stat span { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.b-stat strong { font-family: var(--f-display); font-size: 26px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.b-next { background: var(--ink); color: var(--on-ink); border-radius: 14px; padding: 18px; display: grid; gap: 10px; }
.b-next .tag-now { font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--brass); }
.b-next h3 { font-size: 28px; }
.b-next p { color: var(--on-ink-muted); font-size: 14px; }
.b-next .row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.b-next .btn-quiet { background: transparent; color: var(--on-ink); border-color: rgba(255,255,255,.22); }

.b-list-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 4px; }
.b-list-head h2 { font-size: 24px; }
.b-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.b-item { display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; cursor: pointer; text-align: left; width: 100%; }
.b-item.past { opacity: .72; }
.b-item .t { font-family: var(--f-display); font-weight: 800; font-size: 22px; line-height: 1; font-variant-numeric: tabular-nums; }
.b-item .t small { display: block; font-family: var(--f-body); font-size: 11.5px; font-weight: 600; color: var(--muted); margin-top: 4px; }
.b-item .c { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.b-item .c-top { display: flex; justify-content: space-between; gap: 8px; align-items: start; }
.b-item strong { font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.b-item .c-top .pill { flex: none; }
.b-item .svc { font-size: 13px; color: var(--muted); }
.b-item .val { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
.b-item .note { font-size: 12.5px; background: var(--paper); border-radius: 6px; padding: 6px 8px; color: var(--text); }
.b-item.block { background: repeating-linear-gradient(-45deg, color-mix(in srgb, var(--muted) 8%, var(--surface)) 0 8px, var(--surface) 8px 16px); }
.b-item.cancelado strong { text-decoration: line-through; }
.b-gap { display: flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--muted); padding: 2px 4px; font-variant-numeric: tabular-nums; }
.b-gap::before, .b-gap::after { content: ""; flex: 1; border-top: 1px dashed var(--line); }
.b-empty { text-align: center; padding: 36px 16px; color: var(--muted); background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }

/* folha de detalhes */
.b-modal { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.b-modal-back { position: absolute; inset: 0; background: rgba(10,10,12,.55); }
.b-sheet { position: relative; width: 100%; max-width: 560px; max-height: 90vh; overflow: auto; background: var(--surface); border-radius: 18px 18px 0 0; padding: 20px max(18px, env(safe-area-inset-right, 0px)) calc(20px + env(safe-area-inset-bottom, 0px)) max(18px, env(safe-area-inset-left, 0px)); }
@media (min-width: 600px) { .b-modal { align-items: center; } .b-sheet { border-radius: 16px; } }
.b-sheet-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.b-sheet-head h2 { font-size: 26px; }
.x { width: 38px; height: 38px; border: 1px solid var(--line); background: var(--surface); border-radius: 50%; font-size: 22px; line-height: 1; cursor: pointer; color: var(--muted); flex: none; }
.detail { margin: 0 0 16px; display: grid; gap: 10px; }
.detail div { display: grid; grid-template-columns: 100px minmax(0, 1fr); gap: 10px; font-size: 14.5px; }
.detail dt { color: var(--muted); }
.detail dd { margin: 0; font-weight: 600; }
.acts { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.acts .full { grid-column: 1 / -1; }
.form-stack { display: grid; gap: 14px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

@media (max-width: 380px) { .b-stat strong { font-size: 22px; } .who-grid { grid-template-columns: 1fr; } }

/* avisos no celular + forma de pagamento */
.b-push { margin: 0 0 14px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); display: grid; gap: 8px; }
.b-push summary { cursor: pointer; font-weight: 800; }
.b-push[open] summary { margin-bottom: 4px; }
.b-item .val .selo { margin-left: 6px; }

/* ---------- abas Agenda / Produtos ---------- */
.b-tabs { max-width: 720px; margin: 0 auto; display: flex; gap: 4px; padding: 0 max(16px, env(safe-area-inset-left, 0px)) 8px; }
.b-tabs button { flex: 1; height: 38px; border: 0; border-radius: 999px; background: rgba(255,255,255,.06); color: var(--on-ink-muted); font: inherit; font-weight: 800; font-size: 14px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.b-tabs button[aria-selected="true"] { background: var(--brass); color: #15171a; }
.b-badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--bad); color: #fff; font-size: 11.5px; display: inline-grid; place-items: center; }

/* ---------- produtos ---------- */
.b-prod { display: grid; gap: 14px; }
.b-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: grid; gap: 10px; }
.b-card h3 { font-family: var(--f-display); font-weight: 800; font-size: 22px; text-transform: uppercase; letter-spacing: .02em; margin: 0; }
.b-card .b-empty { padding: 18px 12px; }
.b-faltas, .b-uso { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.falta { display: grid; gap: 4px; padding: 10px 12px; border-radius: var(--radius-sm); border-left: 4px solid var(--warn); background: var(--warn-soft); }
.falta.acabou { border-left-color: var(--bad); background: var(--bad-soft); }
.falta-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.nv { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; padding: 2px 8px; border-radius: 999px; background: var(--warn); color: #fff; white-space: nowrap; }
.nv.acabou { background: var(--bad); }
.seg2 { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.seg2 button { height: 44px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: transparent; color: var(--text); font: inherit; font-weight: 800; cursor: pointer; }
.seg2 button.on[data-nivel="acabando"] { border-color: var(--warn); background: var(--warn-soft); color: var(--warn); }
.seg2 button.on[data-nivel="acabou"] { border-color: var(--bad); background: var(--bad-soft); color: var(--bad); }
.qty { display: grid; grid-template-columns: 48px minmax(0, 1fr) auto 48px; gap: 8px; align-items: center; }
.qty .btn { height: 44px; font-size: 22px; padding: 0; }
.qty input { text-align: center; font-weight: 800; font-size: 18px; }
.qty span { color: var(--muted); font-weight: 700; font-size: 13px; }
.b-uso li { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.b-uso li:last-child { border-bottom: 0; }
.b-uso li > span:first-child { flex: 1; min-width: 0; }
.b-uso small { color: var(--muted); }
.b-uso .x { width: 30px; height: 30px; border-radius: 50%; border: 1px solid var(--line); background: none; color: var(--muted); cursor: pointer; font-size: 16px; flex: none; }
