:root {
  --bg: #faf8f4;
  --surface: #fff;
  --sand: #f4eee5;
  --sand-line: #e5d8c8;
  --line: #ebe4d9;
  --ink: #25231f;
  --muted: #74695d;
  --accent: #0e2a1e;        /* deep CASA LUXE green */
  --accent-ink: #fff;
  --gold: #c6a872;          /* champagne gold, pulled from the logo */
  --danger: #9a3b2b;
  --ok: #3d6b49;
  --whatsapp: #1b7d44;     /* white text on it: 5.2:1 */
  --focus: #8a6d35;        /* focus ring, 4.6:1 on the page colour */

  --serif: 'Frank Ruhl Libre', Georgia, serif;
  --sans: 'Assistant', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --radius: 10px;
  --gutter: 16px;
  --page: 1600px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.5 var(--sans);
}
img { display: block; max-width: 100%; }
h1, h2, h3 { margin: 0; line-height: 1.2; }
p { margin: 0; }
[hidden] { display: none !important; }
input[type="checkbox"] { accent-color: var(--accent); }

/* The brand: the gold monogram next to the CASA LUXE wordmark. Sizes shrink with .brand--sm. */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  text-decoration: none;
  line-height: 1;
}
.brand__mark {
  display: block;
  height: 48px;
  width: auto;
}
.brand__word {
  font-family: var(--serif);
  font-size: 26px;
  letter-spacing: 0.2em;
  /* letter-spacing adds space after the last letter; pull it back so the word centers */
  margin-inline-end: -0.2em;
}
.brand--sm { gap: 8px; }
.brand--sm .brand__mark { height: 32px; }
.brand--sm .brand__word { font-size: 18px; }

.demo-banner {
  background: #fff4d6;
  color: #5c4a14;
  font-size: 14px;
  text-align: center;
  padding: 8px var(--gutter);
  border-bottom: 1px solid #ecd9a0;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: var(--accent);
  color: var(--accent-ink);
  font: 600 15px/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
}
.btn:disabled { opacity: 0.5; cursor: default; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--gold); }
.btn--link { background: none; color: var(--muted); padding-inline: 8px; text-decoration: underline; }
.btn--danger { background: none; color: var(--danger); border-color: currentColor; }
.btn--whatsapp { background: var(--whatsapp); }
.btn--block { width: 100%; }
.btn:focus-visible, .chip:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 2px;
}

.chip {
  min-height: 40px;
  padding: 8px 18px;
  border: 1px solid var(--gold);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font: 15px var(--sans);
  cursor: pointer;
}
.chip[aria-pressed='true'] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }

/* − 2 + quantity control */
.stepper {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--accent);
  border-radius: 8px;
  overflow: hidden;
}
.stepper button {
  width: 40px;
  height: 42px;
  border: 0;
  background: var(--surface);
  color: var(--ink);
  font-size: 20px;
  cursor: pointer;
}
.stepper button:disabled { color: #c9c0b3; cursor: default; }
.stepper output { min-width: 28px; text-align: center; font-weight: 700; }

/* Forms */
.field { display: grid; gap: 6px; font-size: 14px; font-weight: 600; }
.field small { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #d9cfc1;
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  font: 16px var(--sans); /* 16px keeps iOS from zooming on focus */
}
.field textarea { min-height: 80px; resize: vertical; }
.field [aria-invalid='true'] { border-color: var(--danger); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-error { color: var(--danger); font-size: 14px; min-height: 1.5em; }

/* Bottom sheet on phones, centered dialog on wider screens */
.sheet {
  width: 100%;
  max-width: 520px;
  max-height: 92dvh;
  margin: auto auto 0;
  padding: 0;
  border: 0;
  border-radius: 16px 16px 0 0;
  background: var(--surface);
  color: var(--ink);
}
.sheet::backdrop { background: rgb(20 18 15 / 0.45); }
@media (min-width: 640px) {
  .sheet { margin: auto; border-radius: 16px; }
}
.sheet__head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px var(--gutter);
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.sheet__head h2 { font-size: 20px; }
.sheet__close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: var(--sand);
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.sheet__body { padding: var(--gutter) var(--gutter) calc(var(--gutter) + env(safe-area-inset-bottom)); display: grid; gap: 16px; }

.toast {
  position: fixed;
  inset-inline: 16px;
  bottom: 24px;
  z-index: 100;
  max-width: 420px;
  margin: 0 auto;
  padding: 12px 16px;
  border-radius: 10px;
  background: var(--accent);
  color: var(--accent-ink);
  text-align: center;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.2s, transform 0.2s;
  pointer-events: none;
}
.toast.is-visible { opacity: 1; transform: none; }
.toast.is-error { background: var(--danger); }
