@font-face {
  font-family: "Archivo Black";
  font-weight: 400;
  font-display: swap;
  src: url(/fonts/archivo-black-latin.woff2) format("woff2");
}
@font-face {
  font-family: "DM Sans";
  font-weight: 100 1000;
  font-display: swap;
  src: url(/fonts/dm-sans-latin.woff2) format("woff2");
}

:root {
  color-scheme: light dark;
  --page: light-dark(#F3F5F8, #0B0E13);
  --ink: light-dark(#12161C, #EEF2F5);
  --sub: light-dark(#5A6573, #9AA6B3);
  --surf: light-dark(#FFFFFF, #161B23);
  --surf2: light-dark(#F3F5F8, #1E242E);
  --line: light-dark(#E2E7ED, #2A323D);
  --night: #12161C;
  --green: #34D27B;
  --green-ink: light-dark(#127A43, #5BE39A);
  --green-soft: light-dark(#E3F8EC, #123A26);
  --snow: light-dark(#DDEBF7, #16283A);
  --snow-ink: light-dark(#1D4E7A, #9CC8EE);
  --amber: light-dark(#FFF2D6, #3A2C10);
  --amber-ink: light-dark(#8A5A00, #F4C46B);
  --danger: light-dark(#B42318, #FF8B80);
}

* { box-sizing: border-box; min-width: 0; }
html, body { margin: 0; }
body {
  background: var(--page);
  color: var(--ink);
  font: 16px/1.45 "DM Sans", system-ui, sans-serif;
  overflow-x: clip;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
}
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
.app { width: 100%; max-width: 560px; margin: 0 auto; flex: 1; display: flex; flex-direction: column; background: var(--surf2); }
.hidden { display: none !important; }

.hero { background: var(--night); color: #fff; padding: 16px 20px 30px; }
.row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 8px; font: 400 22px/1 "Archivo Black", sans-serif; letter-spacing: .04em; }
.brand svg { width: 18px; height: 28px; }
.loc { background: #1F2630; border: 0; color: #D8DEE5; border-radius: 20px; padding: 7px 12px; font-size: 14px; display: inline-flex; gap: 6px; align-items: center; }
.loc svg { width: 14px; height: 14px; }
.hi { font-size: 26px; font-weight: 700; line-height: 1.15; margin: 18px 0 4px; letter-spacing: -.01em; }
.hero .muted { color: #A9B4C2; margin: 0; }

.wx { margin: -16px 16px 0; position: relative; background: var(--snow); color: var(--snow-ink); border-radius: 20px; padding: 14px 16px; display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: center; }
.wx svg { width: 40px; height: 40px; }
.wx b { display: block; color: var(--ink); }

details.prices { margin: 12px 16px 0; background: var(--surf); border: 1px solid var(--line); border-radius: 20px; padding: 12px 16px; }
details.prices summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; justify-content: space-between; }
details.prices summary::after { content: "Show"; color: var(--green-ink); font-weight: 700; font-size: 14px; }
details.prices[open] summary::after { content: "Hide"; }
details.prices table { width: 100%; border-collapse: collapse; margin-top: 8px; font-size: 15px; }
details.prices td { padding: 6px 0; border-top: 1px solid var(--line); vertical-align: top; }
details.prices td:last-child { text-align: right; white-space: nowrap; padding-left: 8px; font-weight: 700; }
details.prices ul { margin: 8px 0 2px; padding-left: 18px; color: var(--sub); font-size: 14px; }

.msgs { flex: 1; padding: 16px 14px 8px; display: flex; flex-direction: column; gap: 8px; }
.b { max-width: 82%; padding: 9px 13px; border-radius: 18px; font-size: 15px; white-space: pre-wrap; overflow-wrap: anywhere; }
.b.bot { background: var(--surf); border: 1px solid var(--line); align-self: flex-start; border-bottom-left-radius: 6px; }
.b.customer { background: var(--green); color: #0B0E13; align-self: flex-end; border-bottom-right-radius: 6px; }
.b.manager { background: var(--amber); color: var(--ink); align-self: flex-start; border-bottom-left-radius: 6px; }
.b.manager::before { content: "Manager"; display: block; font-size: 12px; font-weight: 700; color: var(--amber-ink); }

.dock { position: sticky; bottom: 0; background: var(--surf); border-top: 1px solid var(--line); padding: 12px 14px calc(12px + env(safe-area-inset-bottom)); display: grid; gap: 10px; box-shadow: 0 -8px 24px -18px rgba(0,0,0,.35); }
.widget { display: grid; grid-auto-rows: max-content; gap: 10px; max-height: 58svh; overflow-y: auto; }
.lbl { font-weight: 700; font-size: 15px; margin: 2px 0 -2px; }
.opts { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { border: 1.5px solid var(--line); background: var(--surf); border-radius: 14px; min-height: 44px; padding: 8px 14px; font-weight: 500; text-align: left; }
.opt small { display: block; color: var(--sub); font-weight: 400; font-size: 13px; }
.opt.on, .opt:active { border-color: var(--green); background: var(--green-soft); }
.days { flex: none; display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.day { flex: none; width: 58px; border: 1.5px solid var(--line); background: var(--surf); border-radius: 14px; padding: 8px 0; text-align: center; line-height: 1.15; }
.day small { display: block; font-size: 12px; color: var(--sub); }
.day b { font-size: 19px; }
.day.on { border-color: var(--green); background: var(--green-soft); }
.field { display: grid; gap: 4px; font-size: 14px; color: var(--sub); font-weight: 500; }
input[type=text], input[type=email], input[type=tel], input:not([type]), textarea {
  width: 100%; border: 1.5px solid var(--line); background: var(--surf); border-radius: 14px; padding: 10px 12px; font-size: 16px; color: var(--ink);
}
textarea { resize: vertical; min-height: 72px; }
.radio { display: flex; gap: 8px; flex-wrap: wrap; }
.radio label { flex: 1; display: flex; align-items: center; gap: 8px; border: 1.5px solid var(--line); border-radius: 14px; padding: 10px 12px; font-weight: 500; color: var(--ink); background: var(--surf); }
.radio label:has(input:checked) { border-color: var(--green); background: var(--green-soft); }
.radio input { accent-color: #1E9C58; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.check input { width: 22px; height: 22px; accent-color: #1E9C58; flex: none; margin-top: 1px; }
.waiver { background: var(--surf2); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; font-size: 14px; color: var(--sub); white-space: pre-wrap; }
.card { background: var(--surf); border: 1px solid var(--line); border-radius: 20px; padding: 14px 16px; }
.review div { padding: 3px 0; font-size: 15px; }
.review .k { color: var(--sub); }
.sum { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.sum small { display: block; color: var(--sub); font-size: 13px; }
.sum b { font-size: 22px; white-space: nowrap; }
.cta { background: var(--green); color: #0B0E13; border: 0; border-radius: 16px; min-height: 50px; padding: 0 20px; font-weight: 700; font-size: 16px; }
.cta:disabled { opacity: .45; cursor: default; }
.ghost { background: var(--surf2); border: 1px solid var(--line); border-radius: 14px; min-height: 44px; padding: 0 14px; font-weight: 700; }
.linkbtn { background: none; border: 0; color: var(--green-ink); font-weight: 700; padding: 4px 0; font-size: 14px; }
.compose { display: flex; gap: 8px; }
.compose input { flex: 1; }
.compose button { width: 48px; flex: none; border: 0; border-radius: 14px; background: var(--green); display: grid; place-items: center; }
.compose button svg { width: 22px; height: 22px; }
.error { color: var(--danger); font-size: 14px; margin: 0; }
.ok { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 6px 0; }
.ok .tick { width: 64px; height: 64px; border-radius: 50%; background: var(--green); display: grid; place-items: center; animation: pop .4s ease-out; }
.ok .tick svg { width: 34px; height: 34px; }
.ok h2 { margin: 0; font-size: 22px; }
.ok p { margin: 0; color: var(--sub); }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ok .tick { animation: none; } }

.chip { display: inline-flex; align-items: center; font-size: 13px; font-weight: 700; border-radius: 20px; padding: 3px 10px; background: var(--green-soft); color: var(--green-ink); white-space: nowrap; }
.chip.wait { background: var(--amber); color: var(--amber-ink); }
.chip.off { background: var(--surf2); color: var(--sub); }
.sec { padding: 18px 16px 4px; }
.sec h2 { font-size: 19px; margin: 0 0 12px; letter-spacing: -.01em; display: flex; align-items: center; gap: 8px; }
.stack { display: grid; gap: 10px; }
.job { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: start; }
.job .when { grid-row: span 2; background: var(--surf2); border-radius: 14px; padding: 6px 10px; text-align: center; line-height: 1.1; font-weight: 700; white-space: nowrap; }
.job .when small { display: block; font-size: 12px; color: var(--sub); font-weight: 500; }
.job p { margin: 0; color: var(--sub); font-size: 14px; }
.job dl { grid-column: 1 / -1; display: grid; grid-template-columns: max-content 1fr; gap: 3px 12px; margin: 8px 0 0; font-size: 14px; }
.job dt { color: var(--sub); }
.job dd { margin: 0; overflow-wrap: anywhere; }
.job .act { grid-column: 1 / -1; display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.job .act button { flex: 1; min-height: 44px; border-radius: 14px; }
.job.faded { opacity: .6; }
.thread { display: flex; flex-direction: column; gap: 6px; margin: 10px 0; max-height: 320px; overflow-y: auto; padding: 8px; background: var(--surf2); border-radius: 14px; }
.tabs { position: sticky; bottom: 0; display: grid; grid-template-columns: 1fr 1fr; background: var(--surf); border-top: 1px solid var(--line); padding: 6px 6px calc(10px + env(safe-area-inset-bottom)); }
.tab { background: none; border: 0; display: grid; justify-items: center; gap: 2px; font-size: 12px; color: var(--sub); padding: 6px 0; min-height: 44px; position: relative; }
.tab svg { width: 24px; height: 24px; }
.tab.on { color: var(--green-ink); font-weight: 700; }
.dot { position: absolute; top: 2px; right: calc(50% - 22px); background: #E5484D; color: #fff; font-size: 11px; font-weight: 700; border-radius: 9px; min-width: 18px; height: 18px; display: grid; place-items: center; padding: 0 4px; }
.note { color: var(--sub); font-size: 14px; }
.flash { margin: 12px 16px 0; background: var(--green-soft); color: var(--green-ink); border-radius: 14px; padding: 10px 14px; font-weight: 700; font-size: 14px; }
.opts.times { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.opts.times .opt { text-align: center; padding: 8px 4px; font-size: 15px; }
