/* "Recibo aberto": a personal, transparent shop. Soft humanist serif for the voice,
   receipt-style numbers for the money, one emerald signature color. Phone-first, opened from WhatsApp. */
:root {
  --bg: #f2f2ee; --surface: #ffffff; --ink: #16201b; --muted: #5d6762; --line: #dcddd6; --rule: #c9cbc2;
  --accent: #0b6e4f; --accent-ink: #ffffff; --accent-soft: #e1eee7; --on-ink: #8fd8b6;
  --stamp: #16201b; --stamp-soft: #e9e9e3; --warn: #9a5b00; --warn-soft: #fbefd9; --info: #1d4ed8; --info-soft: #e8eef8;
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  padding-top: env(safe-area-inset-top, 0px);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1412; --surface: #171e1a; --ink: #e9eeea; --muted: #9ba7a0; --line: #2a332e; --rule: #3a453f;
    --accent: #4cc493; --accent-ink: #062014; --accent-soft: #15301f; --on-ink: #4cc493;
    --stamp: #e9eeea; --stamp-soft: #222b26; --warn: #f0b45a; --warn-soft: #33270f; --info: #8ab4ff; --info-soft: #18233a;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.5;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 20px 132px;
}
body.no-bar { padding-bottom: calc(32px + env(safe-area-inset-bottom, 0px)); }
.wrap { max-width: 560px; margin: 0 auto; display: grid; gap: 16px; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* Header */
.brand { display: flex; align-items: center; gap: 8px; font-size: .78rem; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.brand .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
h1 {
  font-family: var(--display); font-weight: 600; font-variation-settings: "SOFT" 100, "opsz" 72;
  font-size: clamp(2.2rem, 10vw, 2.9rem); line-height: 1; letter-spacing: -.015em; margin: 8px 0 0; text-wrap: balance;
}
h2 { font-family: var(--display); font-weight: 600; font-variation-settings: "SOFT" 100, "opsz" 24; font-size: 1.3rem; line-height: 1.15; margin: 0; text-wrap: balance; }
.sub { color: var(--muted); margin: 10px 0 0; font-size: 1rem; }
.who { margin: 12px 0 0; font-size: .9rem; font-weight: 600; color: var(--accent); }

/* Surfaces */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 18px; display: grid; gap: 14px; min-width: 0; }
.hint { font-size: .86rem; color: var(--muted); margin: 0; }
.chip { display: inline-flex; align-self: start; justify-self: start; gap: 6px; align-items: center; font-size: .82rem; font-weight: 600; color: var(--accent); background: var(--accent-soft); border-radius: 999px; padding: 5px 11px; overflow-wrap: anywhere; }
.chip.bad { color: var(--warn); background: var(--warn-soft); }

/* Delivery banner */
.drop { background: var(--ink); color: var(--bg); border-radius: 18px; padding: 16px 18px; display: grid; gap: 10px; }
.drop-k { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--on-ink); }
.drop-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.drop-grid div { display: grid; gap: 2px; min-width: 0; }
.drop-grid b { font-family: var(--mono); font-size: 1.12rem; font-weight: 600; }
.drop-grid span { font-size: .88rem; opacity: .82; }
.drop-grid b span { font-size: inherit; opacity: 1; }

/* Fields */
.field { display: grid; gap: 6px; min-width: 0; }
.field > label, .flabel { font-size: .86rem; font-weight: 600; }
input, select {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink); background: var(--bg);
  border: 1.5px solid var(--line); border-radius: 12px; padding: 13px 14px; min-height: 52px;
}
input:focus, select:focus { border-color: var(--accent); outline: none; }
input:focus-visible, select:focus-visible, button:focus-visible, a:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.money { position: relative; }
.money span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); font-family: var(--mono); font-weight: 600; color: var(--muted); pointer-events: none; }
.money input { padding-left: 54px; font-family: var(--mono); font-weight: 600; font-size: 1.2rem; font-variant-numeric: tabular-nums; }
.price-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: end; }
.stepper { display: grid; grid-template-columns: 44px 40px 44px; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; background: var(--bg); min-height: 52px; }
.stepper button { font: inherit; font-size: 1.3rem; font-weight: 600; color: var(--accent); background: none; border: 0; height: 50px; cursor: pointer; }
.stepper button:disabled { color: var(--line); cursor: default; }
.stepper output { text-align: center; font-family: var(--mono); font-weight: 600; font-size: 1.1rem; }

/* Tabs */
.tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; background: var(--stamp-soft); border-radius: 14px; padding: 5px; }
.tabs button { font: inherit; font-weight: 600; font-size: .95rem; border: 0; border-radius: 10px; min-height: 44px; background: none; color: var(--muted); cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12); }

/* Catalog: name + spec on the left, price on the right */
.catalog { display: grid; gap: 10px; }
.prod {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px; align-items: center; text-align: left;
  font: inherit; color: var(--ink); background: var(--surface); border: 1.5px solid var(--line); border-radius: 16px; padding: 15px 16px; cursor: pointer; width: 100%;
}
.prod:hover { border-color: var(--rule); }
.prod[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.prod .l { display: grid; gap: 3px; justify-items: start; min-width: 0; }
.prod .n { font-weight: 700; font-size: 1.02rem; line-height: 1.25; }
.prod .s { font-size: .84rem; color: var(--muted); }
.prod .p { text-align: right; display: grid; gap: 1px; justify-items: end; }
.prod .p b { font-family: var(--mono); font-weight: 600; font-size: 1.02rem; white-space: nowrap; }
.prod .p small { font-family: var(--mono); font-size: .76rem; color: var(--muted); white-space: nowrap; }
.prod .p small.from { font-family: var(--body); font-size: .72rem; }
.prod .tag { font-family: var(--mono); font-size: .68rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); background: var(--accent); border-radius: 6px; padding: 3px 8px; margin-bottom: 4px; }

/* The receipt */
.result {
  position: relative; background: var(--surface); border: 0; border-radius: 6px; padding: 26px 20px 24px; gap: 12px;
  -webkit-mask:
    radial-gradient(circle 7px at 50% 0, transparent 97%, #000) top / 18px 51% repeat-x,
    radial-gradient(circle 7px at 50% 100%, transparent 97%, #000) bottom / 18px 51% repeat-x;
  mask:
    radial-gradient(circle 7px at 50% 0, transparent 97%, #000) top / 18px 51% repeat-x,
    radial-gradient(circle 7px at 50% 100%, transparent 97%, #000) bottom / 18px 51% repeat-x;
}
.result .k { font-family: var(--mono); font-size: .74rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.amount { font-family: var(--mono); font-variant-numeric: tabular-nums; font-weight: 600; font-size: clamp(2.2rem, 11vw, 3rem); line-height: 1.05; color: var(--accent); overflow-wrap: anywhere; padding-bottom: 12px; border-bottom: 1.5px dashed var(--rule); }
.meta { font-size: .9rem; color: var(--muted); }
.meta b { font-family: var(--mono); color: var(--ink); font-weight: 600; }
.del-line { font-size: .92rem; font-weight: 600; color: var(--ink); display: flex; gap: 8px; align-items: baseline; }
.del-line::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; transform: translateY(-1px); }
.refund { font-size: .86rem; color: var(--muted); padding-bottom: 12px; border-bottom: 1.5px dashed var(--rule); }
.refund::before { content: "↺ "; color: var(--accent); font-weight: 700; }
details { padding-top: 2px; }
summary { cursor: pointer; font-weight: 600; font-size: .92rem; color: var(--accent); list-style: none; display: flex; justify-content: space-between; align-items: center; min-height: 36px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-family: var(--mono); font-size: 1.1rem; }
details[open] summary::after { content: "−"; }
.incl { margin: 6px 0; padding: 0; list-style: none; display: grid; gap: 8px; font-size: .94rem; }
.incl li { display: grid; grid-template-columns: 20px 1fr; gap: 8px; }
.incl li::before { content: "✓"; color: var(--accent); font-weight: 700; }
.pay { display: grid; gap: 10px; border-top: 1.5px dashed var(--rule); padding-top: 14px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; text-decoration: none; text-align: center;
  font: inherit; font-weight: 700; font-size: 1rem; cursor: pointer; border-radius: 14px; padding: 14px 18px; min-height: 52px;
  border: 1.5px solid var(--ink); background: var(--surface); color: var(--ink);
}
.btn.main { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn.block { width: 100%; }
.btn svg { width: 20px; height: 20px; flex: none; }
@media (prefers-reduced-motion: no-preference) {
  .btn, .prod, .tabs button { transition: transform .12s ease, background-color .15s, border-color .15s; }
  .btn:active, .prod:active { transform: scale(.98); }
}

/* Seals + trust */
.seals { display: flex; flex-wrap: wrap; gap: 8px; }
.seals span {
  font-family: var(--mono); font-size: .74rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--stamp); border: 1.5px solid var(--stamp); border-radius: 6px; padding: 5px 9px; transform: rotate(-1deg);
}
.seals span:nth-child(2) { transform: rotate(1deg); }
.trust { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.trust li { display: grid; grid-template-columns: 22px 1fr; gap: 2px 10px; font-size: .94rem; }
.trust li::before { content: "✓"; grid-row: span 2; color: var(--accent); font-weight: 700; }
.trust b { font-weight: 700; }
.trust span { color: var(--muted); }
.trust .num { color: var(--ink); font-weight: 600; white-space: nowrap; }
.faq { border-top: 1px solid var(--line); padding: 10px 0 2px; }
.faq:first-of-type { border-top: 0; padding-top: 0; }
.faq summary { color: var(--ink); font-size: .96rem; min-height: 40px; gap: 12px; }
.faq summary::after { color: var(--accent); }
.faq p { margin: 4px 0 10px; font-size: .92rem; color: var(--muted); }

/* Steps */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; counter-reset: s; }
.steps li { display: grid; grid-template-columns: 30px 1fr; gap: 12px; align-items: start; counter-increment: s; font-size: .95rem; }
.steps li::before {
  content: counter(s); font-family: var(--mono); font-weight: 600; font-size: .85rem;
  width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: var(--stamp-soft); color: var(--ink);
}
.fine { font-size: .84rem; color: var(--muted); display: grid; gap: 8px; }
.fine strong { color: var(--ink); }

/* Delivery choice */
.seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.seg button {
  font: inherit; font-size: .88rem; font-weight: 700; color: var(--ink); background: var(--bg);
  border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 6px; min-height: 60px; cursor: pointer;
  display: grid; gap: 2px; align-content: center; text-align: center;
}
.seg button small { font-family: var(--mono); font-size: .7rem; font-weight: 500; color: var(--muted); }
.seg button[aria-checked="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
@media (max-width: 380px) { .seg { grid-template-columns: 1fr; } }

/* Sticky bar */
.bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(0,0,0,.08);
  padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
}
.bar-in { max-width: 560px; margin: 0 auto; display: flex; gap: 12px; align-items: center; }
.bar-total { min-width: 0; flex: 1 1 auto; }
.bar-total .k { font-family: var(--mono); font-size: .68rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.bar-total .v { font-family: var(--mono); font-weight: 600; font-size: 1.2rem; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar .btn { flex: none; }
.bar .btn[aria-disabled="true"] { background: var(--stamp-soft); border-color: var(--stamp-soft); color: var(--muted); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(92px + env(safe-area-inset-bottom, 0px)); background: var(--ink); color: var(--bg); font-size: .9rem; font-weight: 600; padding: 10px 14px; border-radius: 10px; z-index: 30; max-width: calc(100% - 32px); text-align: center; }

/* Partner page */
.linkbox { font-family: var(--mono); font-size: .88rem; background: var(--bg); border: 1.5px dashed var(--accent); border-radius: 12px; padding: 12px 14px; overflow-wrap: anywhere; user-select: all; }
.btn-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ctable { width: 100%; border-collapse: collapse; font-size: .92rem; }
.ctable td { padding: 10px 0; border-bottom: 1.5px dashed var(--line); vertical-align: top; }
.ctable tr:last-child td { border-bottom: 0; }
.ctable td:last-child { text-align: right; font-family: var(--mono); font-weight: 600; color: var(--accent); white-space: nowrap; padding-left: 12px; }
.ctable small { display: block; color: var(--muted); font-size: .8rem; font-family: var(--body); font-weight: 500; }
.ctable td:last-child small { font-family: var(--mono); font-size: .76rem; }
.hero-num { color: var(--accent); white-space: nowrap; }

