/* Serra — branco e preto. Uma cor de destaque só para status e para a cor de cada local. */
:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-2: #fafafa;
  --bg-3: #f4f4f5;
  --line: #ebebeb;
  --line-2: #dedede;
  --ink: #0a0a0a;
  --ink-2: #3f3f46;
  --muted: #71717a;
  --faint: #a1a1aa;
  --ok: #15803d; --ok-bg: #f0fdf4; --ok-line: #bbf7d0;
  --warn: #b45309; --warn-bg: #fffbeb; --warn-line: #fde68a;
  --bad: #b91c1c; --bad-bg: #fef2f2; --bad-line: #fecaca;
  --info: #1d4ed8; --info-bg: #eff6ff; --info-line: #bfdbfe;
  --airbnb: #e0484e; --airbnb-bg: #fff1f1;
  --r: 12px; --r-sm: 8px;
  --font: "Inter Tight", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --tabbar: 64px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--font); letter-spacing: -0.006em; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; letter-spacing: -0.02em; line-height: 1.2; }
p { margin: 0; }
img { max-width: 100%; display: block; }
.ic { display: inline-block; flex: none; stroke-width: 1.8; vertical-align: middle; }
::selection { background: #e4e4e7; }

/* ---------------------------------------------------------------- shell */
.shell { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 100dvh; }
.side { display: none; }
.main { min-width: 0; padding-bottom: calc(var(--tabbar) + 24px + env(safe-area-inset-bottom)); }
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 8px; min-height: 56px; padding: 8px 16px; background: rgba(255,255,255,.88); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid transparent; transition: border-color .15s; }
.top.scrolled { border-bottom-color: var(--line); }
.top h1 { font-size: 18px; font-weight: 600; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top-actions { display: flex; gap: 6px; align-items: center; }
.content { padding: 8px 16px 24px; max-width: 1080px; }
.content.wide { max-width: none; }

@media (min-width: 960px) {
  .shell { grid-template-columns: 232px minmax(0, 1fr); }
  .side { display: flex; flex-direction: column; position: sticky; top: 0; height: 100dvh; padding: 18px 12px; border-right: 1px solid var(--line); background: var(--bg-2); }
  .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px; padding: 4px 10px 18px; letter-spacing: -0.03em; }
  .logo { color: var(--ink); display: grid; }
  .side nav { display: flex; flex-direction: column; gap: 1px; overflow: auto; }
  .side-link { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 7px; color: var(--ink-2); font-size: 14px; font-weight: 500; border: 0; background: none; width: 100%; cursor: pointer; text-align: left; }
  .side-link:hover { background: var(--bg-3); color: var(--ink); }
  .side-link.on { background: var(--bg); color: var(--ink); box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgba(0,0,0,.04); }
  .side-sep { height: 1px; background: var(--line); margin: 10px 10px; }
  .side-foot { margin-top: auto; }
  .main { padding-bottom: 40px; }
  .top { padding: 14px 32px; min-height: 64px; }
  .top h1 { font-size: 22px; }
  .content { padding: 8px 32px 40px; }
  .tabbar, .fab, .only-mobile { display: none !important; }
}
@media (max-width: 959px) { .only-desktop { display: none !important; } }

.tabbar { position: fixed; z-index: 30; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(5, 1fr); height: calc(var(--tabbar) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); background: rgba(255,255,255,.94); backdrop-filter: blur(14px); border-top: 1px solid var(--line); }
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 11px; font-weight: 500; color: var(--faint); background: none; border: 0; cursor: pointer; }
.tab.on { color: var(--ink); }
.tab.on .ic { stroke-width: 2.2; }
.fab { position: fixed; z-index: 31; right: 16px; bottom: calc(var(--tabbar) + 16px + env(safe-area-inset-bottom)); width: 54px; height: 54px; border-radius: 16px; background: var(--ink); color: #fff; display: grid; place-items: center; box-shadow: 0 8px 24px rgba(0,0,0,.18); }

/* ---------------------------------------------------------------- utilitários */
.row { display: flex; align-items: center; gap: 10px; }
.row.top-align { align-items: flex-start; }
.wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.stack-lg { display: flex; flex-direction: column; gap: 24px; }
.grid { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 720px) { .md-g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .md-g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .md-g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .lg-split { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: start; } }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: 13.5px; }
.xs { font-size: 12.5px; }
.b { font-weight: 600; }
.num { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--mono); font-size: .92em; letter-spacing: 0; }
.truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hide { display: none !important; }
.sr { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.mt { margin-top: 16px; } .mb { margin-bottom: 16px; } .mt-s { margin-top: 8px; }
.pre { white-space: pre-line; }
.ok-t { color: var(--ok); } .bad-t { color: var(--bad); } .warn-t { color: var(--warn); }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; display: inline-block; }
.link { text-decoration: underline; text-underline-offset: 2px; text-decoration-color: var(--line-2); }

/* ---------------------------------------------------------------- botões */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 40px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--bg); color: var(--ink); font-weight: 550; font-size: 14px; cursor: pointer; white-space: nowrap; transition: background .12s, border-color .12s, transform .06s; }
.btn:hover { background: var(--bg-3); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn.primary:hover { background: #27272a; }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.ghost:hover { background: var(--bg-3); }
.btn.danger { color: var(--bad); }
.btn.sm { height: 34px; padding: 0 11px; font-size: 13.5px; border-radius: 9px; }
.btn.xs { height: 28px; padding: 0 9px; font-size: 12.5px; border-radius: 7px; gap: 5px; }
.btn.block { width: 100%; }
.btn.wa { background: #f0fdf4; border-color: #bbf7d0; color: #166534; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
.iconbtn { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; border: 0; background: none; cursor: pointer; color: var(--ink); }
.iconbtn:hover { background: var(--bg-3); }

/* ---------------------------------------------------------------- cartões e listas */
.card { background: var(--bg); border: 1px solid var(--line); border-radius: var(--r); }
.pad { padding: 16px; }
@media (min-width: 720px) { .pad { padding: 20px; } }
.card.soft { background: var(--bg-2); }
.list > * + * { border-top: 1px solid var(--line); }
.item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; min-height: 60px; }
a.item:hover, button.item:hover { background: var(--bg-2); }
.item .title { font-weight: 550; font-size: 14.5px; }
.item .sub { font-size: 13px; color: var(--muted); margin-top: 1px; }
.item .right { text-align: right; flex: none; }
.row-link { display: flex; align-items: center; gap: 12px; padding: 14px 4px; width: 100%; border: 0; background: none; font-size: 15px; font-weight: 500; cursor: pointer; text-align: left; }
.section { margin-top: 24px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.section-head h2 { font-size: 15px; font-weight: 600; }
.stat { padding: 14px 16px; }
.stat-label { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); font-weight: 500; }
.stat-value { font-size: 24px; font-weight: 600; letter-spacing: -0.03em; margin-top: 4px; font-variant-numeric: tabular-nums; }
.stat-hint { font-size: 12.5px; color: var(--muted); margin-top: 1px; }
.stat.bad .stat-value { color: var(--bad); }
.empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 36px 18px; text-align: center; color: var(--muted); font-size: 14px; }
.empty b { color: var(--ink); font-weight: 600; }
.empty .ic { color: var(--faint); margin-bottom: 4px; }
.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 16px; font-size: 14px; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; text-align: right; font-weight: 500; overflow-wrap: anywhere; }
.avatar { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; font-weight: 600; font-size: 13px; background: var(--bg-3); color: var(--ink-2); flex: none; }
.avatar.lg { width: 52px; height: 52px; font-size: 17px; }
.datebox { width: 44px; flex: none; text-align: center; border: 1px solid var(--line); border-radius: 10px; padding: 4px 0 5px; }
.datebox .d { font-size: 17px; font-weight: 650; line-height: 1.1; }
.datebox .m { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.money { font-size: 32px; font-weight: 650; letter-spacing: -0.035em; font-variant-numeric: tabular-nums; }
.progress { height: 6px; background: var(--bg-3); border-radius: 99px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: var(--ink); border-radius: 99px; }
.callout { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; font-size: 14px; border: 1px solid var(--line); background: var(--bg-2); }
.callout.bad { background: var(--bad-bg); border-color: var(--bad-line); color: #7f1d1d; }
.callout.warn { background: var(--warn-bg); border-color: var(--warn-line); color: #78350f; }
.callout.ok { background: var(--ok-bg); border-color: var(--ok-line); color: #14532d; }
.callout.info { background: var(--info-bg); border-color: var(--info-line); color: #1e3a8a; }

/* ---------------------------------------------------------------- badges */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 6px; font-size: 12px; font-weight: 550; background: var(--bg-3); color: var(--ink-2); white-space: nowrap; border: 1px solid transparent; }
.badge.outline { background: transparent; border-color: var(--line-2); }
.badge.ok, .badge.confirmada, .badge.paga, .badge.confirmado, .badge.assinado, .badge.devolvido-ok, .badge.pago { background: var(--ok-bg); color: var(--ok); }
.badge.warn, .badge.pendente, .badge.cheque, .badge.a_compensar, .badge.parcial, .badge.enviado, .badge.reservado, .badge.permuta { background: var(--warn-bg); color: var(--warn); }
.badge.bad, .badge.vencida, .badge.devolvido, .badge.cancelada, .badge.cancelado { background: var(--bad-bg); color: var(--bad); }
.badge.info, .badge.hospedado, .badge.retirado, .badge.cortesia { background: var(--info-bg); color: var(--info); }
.badge.airbnb { background: var(--airbnb-bg); color: var(--airbnb); }
.badge.dark, .badge.dono { background: var(--ink); color: #fff; }
.badge.substituida, .badge.concluida, .badge.rascunho, .badge.aberta { background: var(--bg-3); color: var(--muted); }

/* ---------------------------------------------------------------- formulários */
.form { display: flex; flex-direction: column; gap: 16px; max-width: 760px; }
.form-grid { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 640px) { .form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .form-grid .full { grid-column: 1 / -1; } }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-label { font-size: 13px; font-weight: 550; color: var(--ink-2); }
.hint { font-size: 12.5px; color: var(--muted); }
.err { font-size: 12.5px; color: var(--bad); }
.has-error .input { border-color: var(--bad); }
.input { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg); font: inherit; font-size: 16px; color: var(--ink); outline: none; transition: border-color .12s, box-shadow .12s; -webkit-appearance: none; appearance: none; }
@media (min-width: 960px) { .input { font-size: 14.5px; min-height: 40px; } }
.input:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(10,10,10,.08); }
.input::placeholder { color: var(--faint); }
textarea.input { resize: vertical; line-height: 1.5; }
textarea.input.code { font-family: var(--mono); font-size: 13.5px; min-height: 420px; }
select.input { 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'%3E%3Cpath d='m4 6 4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px; }
input[type=color].input { padding: 4px; height: 44px; }
.input-group { position: relative; }
.input-group .ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--faint); }
.input-group .input { padding-left: 38px; }
.check { display: flex; align-items: center; gap: 10px; font-size: 14.5px; cursor: pointer; padding: 6px 0; }
.check input { width: 18px; height: 18px; accent-color: var(--ink); }
.form-actions { display: flex; gap: 8px; position: sticky; bottom: calc(var(--tabbar) + env(safe-area-inset-bottom)); padding: 12px 0; background: linear-gradient(transparent, var(--bg) 30%); }
@media (min-width: 960px) { .form-actions { bottom: 0; } }
.form-actions .btn { height: 46px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow: visible; }
.chip { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 13px; border-radius: 99px; border: 1px solid var(--line-2); background: var(--bg); font-size: 13.5px; font-weight: 500; white-space: nowrap; cursor: pointer; user-select: none; }
.chip:hover { border-color: var(--faint); }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.label-t { font-size: 13px; font-weight: 600; color: var(--ink-2); }
.drop { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 20px; border: 1.5px dashed var(--line-2); border-radius: var(--r); text-align: center; color: var(--muted); font-size: 14px; cursor: pointer; }
.drop:hover { border-color: var(--ink); color: var(--ink); }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

/* ---------------------------------------------------------------- segmentado / abas */
.seg { display: flex; gap: 2px; padding: 3px; background: var(--bg-3); border-radius: 10px; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg > * { flex: 1 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 8px; border: 0; background: none; font-size: 13.5px; font-weight: 550; color: var(--muted); cursor: pointer; white-space: nowrap; }
.seg > .on { background: var(--bg); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 0 0 1px rgba(0,0,0,.03); }
.tab-panel { display: none; padding-top: 16px; }
.tab-panel.on { display: block; }

/* ---------------------------------------------------------------- toast / sheet */
.toast { display: flex; align-items: center; gap: 10px; margin: 0 16px 8px; padding: 11px 14px; border-radius: 10px; background: var(--ink); color: #fff; font-size: 14px; animation: in .2s ease-out; }
.toast.bad { background: var(--bad); }
.toast span { flex: 1; }
.toast button { background: none; border: 0; color: inherit; cursor: pointer; opacity: .7; }
@media (min-width: 960px) { .toast { margin: 0 32px 10px; max-width: 520px; } }
@keyframes in { from { opacity: 0; transform: translateY(-4px); } }
dialog.sheet { border: 0; padding: 0; margin: auto auto 0; width: 100%; max-width: 560px; max-height: 88dvh; border-radius: 18px 18px 0 0; background: var(--bg); color: var(--ink); }
dialog.sheet::backdrop { background: rgba(0,0,0,.32); }
dialog.sheet[open] { animation: up .22s cubic-bezier(.2,.8,.2,1); }
@keyframes up { from { transform: translateY(24px); opacity: .4; } }
@media (min-width: 720px) { dialog.sheet { margin: auto; border-radius: 16px; } }
.sheet-body { padding: 16px 18px calc(20px + env(safe-area-inset-bottom)); overflow: auto; max-height: 88dvh; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; font-size: 16px; }

/* ---------------------------------------------------------------- início */
.place-card { display: block; overflow: hidden; }
.place-card .cover { aspect-ratio: 16/8; background: var(--bg-3) center/cover; position: relative; }
.place-card .cover .badge { position: absolute; left: 10px; top: 10px; }
.strip { display: grid; grid-template-columns: repeat(14, 1fr); gap: 3px; margin-top: 12px; }
.strip i { height: 22px; border-radius: 4px; background: var(--bg-3); position: relative; }
.strip i.res { background: var(--ink); }
.strip i.air { background: var(--airbnb); }
.strip i.blk { background: repeating-linear-gradient(135deg, var(--line-2) 0 3px, var(--bg-3) 3px 6px); }
.strip i.today { outline: 1.5px solid var(--ink); outline-offset: 1px; }
.strip i.turn { background: linear-gradient(135deg, var(--ink) 0 48%, var(--bg) 48% 52%, var(--ink) 52%); }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12.5px; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }

/* ---------------------------------------------------------------- agenda (linha do tempo) */
.tl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); -webkit-overflow-scrolling: touch; }
.tl { display: grid; min-width: max-content; }
.tl-row { display: contents; }
.tl-name { position: sticky; left: 0; z-index: 3; display: flex; align-items: center; gap: 8px; width: 132px; padding: 0 12px; background: var(--bg); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 13px; font-weight: 550; height: 56px; }
.tl-name small { display: block; font-weight: 400; color: var(--muted); font-size: 11.5px; }
.tl-head { height: 46px; display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 11px; color: var(--muted); border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; }
.tl-head b { font-size: 14px; color: var(--ink); font-weight: 600; }
.tl-head.we { background: var(--bg-2); }
.tl-head.today b { background: var(--ink); color: #fff; border-radius: 6px; padding: 0 5px; }
.tl-corner { position: sticky; left: 0; z-index: 4; background: var(--bg); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.cell { position: relative; width: 46px; height: 56px; border-bottom: 1px solid var(--line); border-right: 1px solid #f4f4f5; }
.cell.we { background: var(--bg-2); }
.cell > a.free { position: absolute; inset: 0; }
.cell > a.free:hover { background: var(--bg-3); }
/* cada dia tem duas metades: manhã (saída) e tarde/noite (entrada) */
.seg-bar { position: absolute; top: 10px; bottom: 10px; display: flex; align-items: center; overflow: visible; color: #fff; font-size: 11.5px; font-weight: 600; }
.seg-bar.am { left: 0; width: 50%; }
.seg-bar.full:not(.end) { width: calc(100% + 1px); }
.seg-bar.pm { left: 50%; width: calc(50% + 1px); }
.seg-bar.full { left: 0; width: 100%; }
.seg-bar.start { border-top-left-radius: 7px; border-bottom-left-radius: 7px; margin-left: 2px; }
.seg-bar.end { border-top-right-radius: 7px; border-bottom-right-radius: 7px; margin-right: 2px; }
.seg-bar.res { background: var(--ink); }
.seg-bar.res.pend { background: #52525b; }
.seg-bar.air { background: var(--airbnb); }
.seg-bar.air.linked { background: var(--airbnb); box-shadow: inset 0 0 0 2px rgba(255,255,255,.35); }
.seg-bar.blk { background: repeating-linear-gradient(135deg, #d4d4d8 0 4px, #f4f4f5 4px 8px); color: var(--muted); }
.seg-bar.deal { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.seg-bar .lbl { position: absolute; left: 7px; z-index: 2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.seg-bar.am .lbl { display: none; }
.turn-mark { position: absolute; left: 50%; top: 4px; bottom: 4px; width: 2px; margin-left: -1px; background: #fff; z-index: 2; border-radius: 2px; box-shadow: 0 0 0 1px var(--line); }
.cell .today-line { position: absolute; top: 0; bottom: 0; left: 50%; width: 0; border-left: 1.5px dashed var(--ink); opacity: .25; z-index: 0; }

/* ---------------------------------------------------------------- detalhe */
.hero { display: flex; gap: 14px; align-items: center; }
.hero h2 { font-size: 20px; font-weight: 650; }
.extra { position: relative; display: flex; gap: 12px; align-items: flex-start; padding: 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg); text-align: left; cursor: pointer; width: 100%; }
.extra:hover { border-color: var(--faint); }
.extra.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.extra .ico { width: 36px; height: 36px; border-radius: 9px; display: grid; place-items: center; background: var(--bg-3); flex: none; }
.extra.on .ico { background: var(--ink); color: #fff; }
.extra .tick { position: absolute; right: 12px; top: 12px; width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--line-2); display: grid; place-items: center; }
.extra.on .tick { background: var(--ink); border-color: var(--ink); color: #fff; }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
.thumb { position: relative; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--bg-2); }
.thumb img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }
.thumb .pdf { aspect-ratio: 4/3; display: grid; place-items: center; color: var(--muted); }
.thumb .cap { font-size: 12px; padding: 6px 8px; display: flex; align-items: center; justify-content: space-between; gap: 4px; }
.thumb form { display: inline; }

/* ---------------------------------------------------------------- parcelas */
.plan-row { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, .9fr) 36px; gap: 6px; align-items: center; }
.plan-row .input { min-height: 40px; padding: 8px 10px; font-size: 14.5px; }
.sum-bar { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 10px; font-size: 14px; }
.sum-bar.ok { background: var(--ok-bg); color: var(--ok); }
.sum-bar.bad { background: var(--warn-bg); color: var(--warn); }

/* ---------------------------------------------------------------- desempenho */
.perf-bar { display: flex; height: 8px; border-radius: 99px; overflow: hidden; background: var(--bg-3); margin: 14px 0 12px; gap: 2px; }
.perf-bar span { min-width: 3px; }

/* ---------------------------------------------------------------- contrato / assinatura */
.doc { font-size: 15px; line-height: 1.7; }
.doc h1 { font-size: 19px; text-align: center; margin: 0 0 18px; }
.doc h2 { font-size: 15px; margin: 22px 0 8px; }
.doc p { margin: 0 0 10px; }
.doc ul { padding-left: 20px; margin: 0 0 10px; }
.vars { display: flex; flex-wrap: wrap; gap: 5px; }
.vars button { font-family: var(--mono); font-size: 11.5px; padding: 3px 7px; border-radius: 6px; border: 1px solid var(--line); background: var(--bg-2); cursor: pointer; }
.vars button:hover { border-color: var(--ink); }
.sigpad { position: relative; border: 1.5px solid var(--line-2); border-radius: var(--r); background: #fff; touch-action: none; }
.sigpad canvas { display: block; width: 100%; height: 190px; cursor: crosshair; }
.sigpad .base { position: absolute; left: 20px; right: 20px; bottom: 44px; border-top: 1px solid var(--line-2); pointer-events: none; }
.sigpad .ph { position: absolute; left: 0; right: 0; bottom: 18px; text-align: center; font-size: 12px; color: var(--faint); pointer-events: none; }
.steps { display: flex; gap: 6px; margin-bottom: 18px; }
.steps i { flex: 1; height: 3px; border-radius: 3px; background: var(--line); }
.steps i.on { background: var(--ink); }

/* ---------------------------------------------------------------- público */
body.public { background: var(--bg-2); }
.public-main { max-width: 640px; margin: 0 auto; padding: 24px 16px 48px; }
.auth { max-width: 380px; margin: 12vh auto 0; display: flex; flex-direction: column; gap: 14px; }
.auth h1 { font-size: 26px; font-weight: 650; }
.auth-logo { width: 44px; height: 44px; border-radius: 12px; background: var(--ink); color: #fff; display: grid; place-items: center; }
.otp { letter-spacing: .5em; text-align: center; font-family: var(--mono); font-size: 24px !important; }

/* mini calendário do local */
.mcal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; text-align: center; }
.mcal b { font-size: 11px; color: var(--faint); font-weight: 600; padding-bottom: 2px; }
.mcal-d { aspect-ratio: 1; display: grid; place-items: center; border-radius: 8px; font-size: 13px; font-weight: 500; background: var(--bg-2); }
.mcal-d:hover { outline: 1.5px solid var(--ink); }
.mcal-d.res { background: var(--ink); color: #fff; }
.mcal-d.air { background: var(--airbnb); color: #fff; }
.mcal-d.blk { background: repeating-linear-gradient(135deg, #d4d4d8 0 3px, #f4f4f5 3px 6px); color: var(--muted); }
.mcal-d.turn { background: linear-gradient(135deg, var(--ink) 0 47%, #fff 47% 53%, var(--ink) 53%); color: #fff; }
.mcal-d.today { box-shadow: 0 0 0 2px var(--bg), 0 0 0 3.5px var(--ink); }
details > summary { list-style: none; }
details > summary::-webkit-details-marker { display: none; }

.btn.primary.danger-btn { background: var(--bad); border-color: var(--bad); }
.pdf-frame { width: 100%; height: 78dvh; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-3); }
dialog.sheet.wide { max-width: 980px; }
.guest-pick { display: flex; flex-direction: column; gap: 6px; max-height: 300px; overflow: auto; }
.guest-opt { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
.guest-opt:hover { border-color: var(--faint); }
.guest-opt.on { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.guest-opt input { display: none; }

.sumrow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sumrow > div { padding: 12px 10px 12px 12px; min-width: 0; }
.sumrow > div + div { border-left: 1px solid var(--line); }
.sumrow span { display: block; font-size: 12px; color: var(--muted); font-weight: 500; }
.sumrow b { display: block; font-size: clamp(13.5px, 3.7vw, 22px); font-weight: 650; letter-spacing: -0.02em; margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.sigpad.typed { height: 190px; display: flex; align-items: center; padding: 0 24px 30px; overflow: hidden; }
#typed-preview { font-family: "Caveat", "Brush Script MT", cursive; font-weight: 600; font-size: clamp(34px, 9vw, 54px); color: #16233a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; width: 100%; }

/* faixa de dinheiro na reserva */
.money-strip { display: block; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); color: inherit; text-decoration: none; }
.money-strip:hover { border-color: var(--line-2); background: var(--bg-3); }
.link-plain { color: inherit; text-decoration: none; }
.link-plain:hover { text-decoration: underline; text-underline-offset: 3px; }

/* espaço para o botão + não cobrir o fim da lista */
body:has(.fab) .main { padding-bottom: calc(var(--tabbar) + 96px + env(safe-area-inset-bottom)); }
.pw-wrap { position: relative; }
.pw-wrap .input { padding-right: 76px; }
.pw-wrap button { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); height: 32px; padding: 0 10px; border: 0; background: none; color: var(--muted); font: inherit; font-size: 13px; font-weight: 550; cursor: pointer; }

.strip-days { display: grid; grid-template-columns: repeat(14, 1fr); gap: 3px; margin-top: 12px; font-size: 10px; color: var(--faint); text-align: center; font-weight: 600; }
.strip-days span { position: relative; white-space: nowrap; }
.strip-days span.on { color: var(--ink); font-size: 9px; }
.strip-days em { position: absolute; left: 0; top: -13px; font-style: normal; color: var(--muted); text-transform: lowercase; }

.fab { width: auto; height: 48px; padding: 0 18px 0 14px; border-radius: 99px; display: inline-flex; gap: 6px; align-items: center; font-weight: 600; font-size: 14.5px; text-decoration: none; text-transform: capitalize; }
.money-split { display: grid; gap: 0; }
.money-strip.as-div { padding: 0; }
.money-strip .ms-main { display: block; padding: 12px 14px 8px; color: inherit; text-decoration: none; }
.money-strip .ms-foot { display: flex; justify-content: space-between; gap: 10px; padding: 0 14px 12px; }
.money-strip .ms-foot a { color: inherit; }
