:root {
  --bg: #f6f4ef;
  --surface: #ffffff;
  --surface-2: #f0ede6;
  --text: #1d1b16;
  --muted: #6b665b;
  --border: #e3ded3;
  --accent: #0b6e4f;
  --accent-ink: #ffffff;
  --accent-soft: #e2f1ea;
  --warn: #8a5a00;
  --danger: #b3261e;
  --danger-ink: #ffffff;
  --radius: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14130f;
    --surface: #1d1c17;
    --surface-2: #26251f;
    --text: #f1eee6;
    --muted: #a7a194;
    --border: #34322a;
    --accent: #3fbf8c;
    --accent-ink: #0d1a14;
    --accent-soft: #183126;
    --warn: #e0b45a;
    --danger: #f2948c;
    --danger-ink: #2b0705;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  display: flex; flex-direction: column;
}
button { font: inherit; color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.bar {
  position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between;
  padding: 10px 16px; background: var(--bg); border-bottom: 1px solid var(--border);
}
.brand { display: flex; align-items: center; gap: 8px; font-weight: 650; font-size: 18px; }
.logo {
  width: 28px; height: 28px; border-radius: 8px; background: var(--accent); color: var(--accent-ink);
  display: grid; place-items: center; font-size: 15px;
}
.ghost { background: none; border: 1px solid var(--border); border-radius: 999px; padding: 6px 12px; cursor: pointer; }

.log { flex: 1; overflow-y: auto; padding: 16px 16px 8px; display: flex; flex-direction: column; gap: 12px;
  max-width: 720px; width: 100%; margin: 0 auto; }
.intro h1 { font-size: 24px; margin: 24px 0 6px; letter-spacing: -0.01em; }
.intro p { margin: 0 0 16px; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1px solid var(--border); background: var(--surface); border-radius: 999px; padding: 8px 14px;
  cursor: pointer; text-align: left; }
.chip:hover { border-color: var(--accent); }

.msg { max-width: 88%; padding: 10px 14px; border-radius: var(--radius); white-space: pre-wrap; word-wrap: break-word; }
.msg.user { align-self: flex-end; background: var(--accent); color: var(--accent-ink); border-bottom-right-radius: 4px; }
.msg.bot { align-self: flex-start; background: var(--surface); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.msg.note { align-self: center; background: none; color: var(--muted); font-size: 13px; padding: 2px; }

.card { align-self: stretch; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px; }
.card h3 { margin: 0 0 2px; font-size: 16px; }
.card .sub { color: var(--muted); font-size: 14px; margin: 0 0 10px; }
.row { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.muted { color: var(--muted); font-size: 14px; }
.price { font-weight: 650; white-space: nowrap; }

.carousel { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 4px;
  align-self: stretch; }
.tile { flex: 0 0 min(78%, 260px); scroll-snap-align: start; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.tile .name { font-weight: 650; }
.tile .from { margin-top: auto; padding-top: 8px; }

.btn { border: 0; border-radius: 10px; padding: 10px 14px; background: var(--accent); color: var(--accent-ink);
  font-weight: 600; cursor: pointer; min-height: 44px; }
.btn.secondary { background: var(--surface-2); color: var(--text); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.small { min-height: 36px; padding: 6px 12px; font-size: 14px; }
.actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.actions .btn { flex: 1 1 140px; }
a.btn { text-decoration: none; display: inline-grid; place-items: center; }

.rooms { display: flex; flex-direction: column; gap: 8px; }
.room { border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; display: grid;
  grid-template-columns: 1fr auto; gap: 4px 12px; align-items: center; }
.room .btn { grid-row: span 2; }

.lines { width: 100%; border-collapse: collapse; margin: 8px 0; font-size: 15px; }
.lines td { padding: 6px 0; border-bottom: 1px solid var(--border); }
.lines td:last-child { text-align: right; white-space: nowrap; }
.lines tr.total td { font-weight: 700; border-bottom: 0; padding-top: 10px; }
dl.facts { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 8px 0; font-size: 15px; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }
.code { font: 600 22px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: .08em; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; background: var(--accent-soft);
  color: var(--accent); font-size: 13px; font-weight: 600; }
.badge.warn { background: transparent; color: var(--warn); border: 1px solid currentColor; }
.chips.amenities { margin: 6px 0; }
.chips.amenities span { font-size: 13px; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); }

form.guest { display: grid; gap: 10px; }
form.guest label { display: grid; gap: 4px; font-size: 14px; color: var(--muted); }
form.guest input { font: inherit; color: var(--text); background: var(--bg); border: 1px solid var(--border);
  border-radius: 10px; padding: 10px 12px; min-height: 44px; }
form.guest input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.status { max-width: 720px; width: 100%; margin: 0 auto; padding: 0 16px 6px; color: var(--muted); font-size: 14px; }
.status::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 8px;
  background: var(--accent); animation: pulse 1s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .status::before { animation: none; } }

.composer { position: sticky; bottom: 0; display: flex; gap: 8px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: var(--bg); border-top: 1px solid var(--border); max-width: 720px; width: 100%; margin: 0 auto; }
.composer textarea { flex: 1; resize: none; font: inherit; color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: 22px; padding: 10px 16px; max-height: 140px; }
.composer button { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--accent);
  color: var(--accent-ink); display: grid; place-items: center; cursor: pointer; flex: none; align-self: flex-end; }
.composer button:disabled { opacity: .5; }
.composer button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.composer button.mic { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.composer button.mic.recording { background: var(--danger); color: var(--danger-ink); border-color: var(--danger);
  animation: mic-pulse 1.4s ease-in-out infinite; }
@keyframes mic-pulse { 50% { opacity: .7; } }
@media (prefers-reduced-motion: reduce) { .composer button.mic.recording { animation: none; } }

@media print {
  body * { visibility: hidden; }
  .printable, .printable * { visibility: visible; }
  .printable { position: absolute; inset: 0; border: 0; }
  .printable .actions { display: none; }
}
