/* Base compartida: colores, tipografía, botones y formularios */
:root {
  --paper: #ffffff;
  --mist: #f8eff3;
  --mist-2: #f1e4ec;
  --ink: #2b1630;
  --ink-2: #5e4a5f;
  --ink-3: #8b7a8b;
  --rose: #b4375f;
  --rose-dark: #8f2449;
  --lilac: #6f5aa8;
  --lilac-mist: #efeaf8;
  --leaf: #3f6b45;
  --leaf-mist: #e8f1e6;
  --amber: #a56a12;
  --amber-mist: #fbf0dc;
  --line: #eadde4;
  --danger: #b3261e;

  --display: 'Bodoni Moda', 'Didot', 'Times New Roman', serif;
  --body: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --script: 'Pinyon Script', 'Snell Roundhand', cursive;

  --r-sm: 6px;
  --r: 12px;
  --r-lg: 20px;
  --wrap: 1180px;
  --pad: clamp(16px, 4vw, 32px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--rose); outline-offset: 2px; border-radius: 4px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad); }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

h1, h2, h3 { font-family: var(--display); font-weight: 500; line-height: 1.08; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.3rem, 7vw, 4.4rem); }
h2 { font-size: clamp(1.7rem, 4.6vw, 2.6rem); }
h3 { font-size: 1.3rem; }
p { margin: 0; }
.muted { color: var(--ink-2); }
.small { font-size: 0.875rem; }

.wordmark { display: inline-flex; flex-direction: column; text-decoration: none; line-height: 1; }
.wordmark b { font-family: var(--script); font-weight: 400; font-size: 2.3rem; color: var(--ink); letter-spacing: 0; }
.wordmark span { font-size: 0.64rem; letter-spacing: 0.22em; color: var(--rose); margin-top: -2px; padding-left: 0.4rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 48px; padding: 0 1.4rem; border-radius: 999px; border: 1.5px solid var(--ink);
  background: var(--ink); color: #fff; font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}
.btn:hover { background: var(--rose-dark); border-color: var(--rose-dark); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { background: var(--ink); color: #fff; }
.btn.rose { background: var(--rose); border-color: var(--rose); }
.btn.rose:hover { background: var(--rose-dark); }
.btn.lilac { background: var(--lilac); border-color: var(--lilac); }
.btn.wa { background: #1f7a4d; border-color: #1f7a4d; }
.btn.wa:hover { background: #17603c; border-color: #17603c; }
.btn.block { width: 100%; }
.btn.sm { min-height: 38px; padding: 0 1rem; font-size: 0.9rem; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.field { display: grid; gap: 6px; margin-bottom: 14px; }
.field label, .label { font-size: 0.875rem; font-weight: 600; color: var(--ink-2); }
.input, select.input, textarea.input {
  width: 100%; min-height: 48px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: var(--r);
  background: #fff; font-size: 16px; transition: border-color 0.15s;
}
textarea.input { min-height: 90px; resize: vertical; }
.input:focus { border-color: var(--ink); outline: none; }
.hint { font-size: 0.8rem; color: var(--ink-3); }

.choice-row { display: flex; flex-wrap: wrap; gap: 8px; }
.choice {
  min-width: 52px; min-height: 44px; padding: 0 14px; border-radius: var(--r-sm); border: 1.5px solid var(--line);
  background: #fff; cursor: pointer; font-weight: 600; font-size: 0.95rem;
}
.choice[aria-pressed='true'] { border-color: var(--ink); background: var(--ink); color: #fff; }

.stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--line); border-radius: 999px; }
.stepper button { width: 40px; height: 40px; border: 0; background: none; font-size: 1.2rem; cursor: pointer; border-radius: 999px; }
.stepper output { min-width: 28px; text-align: center; font-weight: 700; }

.alert { padding: 12px 14px; border-radius: var(--r); font-size: 0.92rem; margin-bottom: 14px; }
.alert.error { background: #fdecea; color: var(--danger); }
.alert.ok { background: var(--leaf-mist); color: var(--leaf); }
.alert.info { background: var(--lilac-mist); color: var(--lilac); }
.alert.warn { background: var(--amber-mist); color: var(--amber); }

.demo-bar {
  background: var(--ink); color: #fff; font-size: 0.8rem; text-align: center; padding: 6px var(--pad);
}
.demo-bar a { color: #f3c7d6; }

.toast {
  position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translateX(-50%) translateY(20px); opacity: 0;
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px; font-size: 0.92rem;
  z-index: 100; transition: opacity 0.2s, transform 0.2s; pointer-events: none; max-width: calc(100% - 32px);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
