/* Sol de Gràcia · pedidos para recoger
   Estilo minimal póster: blanco y negro, Playfair Display + Josefin Sans */

:root {
  --ink: #141210;
  --ink2: #3a342e;
  --muted: #645b53;
  --soft: #f5f2ed;
  --line: #d8d1c8;
  --bg: #ffffff;
  --red: #a51f22;
  --ok: #1d6436;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Josefin Sans", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.45;
  font-variant-numeric: lining-nums tabular-nums;
}
button, input, textarea, select { font: inherit; color: inherit; }
a { color: var(--ink); }
a:hover { color: var(--ink2); }
img { max-width: 100%; }
h1, h2, h3 { font-family: var(--serif); font-weight: 900; line-height: 1.05; margin: 0; }
p { margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

.wrap { max-width: 760px; margin: 0 auto; padding: 0 20px; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: 0.26em; text-transform: uppercase; }

/* estrella y separador */
.star { width: 22px; height: 22px; fill: var(--ink); display: block; flex: 0 0 auto; }
.star.s { width: 12px; height: 12px; }
.divider { display: flex; align-items: center; justify-content: center; gap: 10px; }
.divider span { width: 70px; height: 1.5px; background: var(--ink); }

/* botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 14px 22px 11px;
  border: 2px solid var(--ink); border-radius: 0;
  background: var(--ink); color: #fff;
  font-weight: 600; font-size: 15px; letter-spacing: 0.12em; text-transform: uppercase;
  text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--ink2); border-color: var(--ink2); color: #fff; }
.btn.sec { background: #fff; color: var(--ink); }
.btn.sec:hover { background: var(--soft); color: var(--ink); }
.btn.peq { min-height: 40px; padding: 10px 14px 7px; font-size: 13px; letter-spacing: 0.1em; }
.btn.full { width: 100%; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; flex: 0 0 auto; }
.btn:focus-visible, .chip:focus-visible, .paso:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 3px solid var(--ink); outline-offset: 2px;
}

/* ---------- Página cliente ---------- */
.hero { text-align: center; padding-top: 34px; padding-bottom: 30px; }
.hero .logo { width: 104px; height: 104px; object-fit: contain; display: block; margin: 0 auto; }
.hero .eyebrow { margin-top: 14px; }
.hero h1 { margin-top: 10px; font-size: clamp(44px, 11vw, 68px); letter-spacing: -0.01em; }
.hero h1 span { display: block; margin-top: 8px; font-style: italic; font-weight: 500; font-size: 0.48em; line-height: 1.15; }
.hero .divider { margin-top: 22px; }
.datos {
  margin: 22px auto 0; padding: 0; list-style: none;
  display: grid; grid-template-columns: 1fr 1fr; border: 1.5px solid var(--ink);
}
.datos li { padding: 14px 12px 12px; }
.datos li + li { border-left: 1.5px solid var(--ink); }
.datos .eyebrow { font-size: 11px; display: block; }
.datos strong { display: block; margin-top: 6px; font-family: var(--serif); font-weight: 900; font-size: 22px; line-height: 1.1; }
.datos small { display: block; margin-top: 3px; font-size: 14px; color: var(--muted); }
.aviso {
  margin-top: 14px; display: flex; gap: 10px; align-items: center; justify-content: center;
  font-weight: 600; font-size: 15px;
}
.aviso svg { width: 20px; height: 20px; flex: 0 0 auto; }
.demo-banner {
  background: var(--soft); border-bottom: 1.5px solid var(--ink);
  font-size: 13px; text-align: center; padding: 9px 16px 7px; letter-spacing: 0.04em;
}
.ultimo {
  margin-top: 16px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border: 1.5px dashed var(--ink); padding: 10px 14px 8px; text-align: left; font-size: 15px;
}
.ultimo button { background: none; border: 0; padding: 6px 0; font-weight: 600; text-decoration: underline; cursor: pointer; }

.pasos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: 0 0 26px; padding: 0; list-style: none; counter-reset: p; }
.pasos li { text-align: center; padding: 0 6px; font-size: 14px; line-height: 1.3; color: var(--ink2); }
.pasos li::before {
  counter-increment: p; content: counter(p);
  display: block; margin: 0 auto 6px; width: 34px; height: 34px; line-height: 36px;
  border: 1.5px solid var(--ink); border-radius: 50%;
  font-family: var(--serif); font-weight: 900; font-size: 17px; color: var(--ink);
}

.catalogo { padding-bottom: 130px; }
.cat-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; border-top: 1.5px solid var(--ink); padding-top: 22px; }
.cat-head h2 { font-size: 34px; }
.cat-head span { font-size: 14px; color: var(--muted); }
.buscar { position: relative; display: block; margin-top: 16px; }
.buscar svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; }
.buscar input {
  width: 100%; height: 50px; padding: 4px 14px 0 44px;
  border: 1.5px solid var(--ink); border-radius: 0; background: #fff; font-size: 17px;
  -webkit-appearance: none; appearance: none;
}
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 14px 0 4px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: 0 0 auto; min-height: 40px; padding: 10px 14px 7px;
  border: 1.5px solid var(--ink); background: #fff; cursor: pointer;
  font-size: 14px; font-weight: 600; letter-spacing: 0.06em; white-space: nowrap;
}
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; }

.lista { list-style: none; margin: 10px 0 0; padding: 0; }
.item { display: flex; align-items: center; gap: 14px; padding: 16px 0 14px; border-bottom: 1px solid var(--line); }
.item-txt { flex: 1 1 auto; min-width: 0; }
.item h3 { font-size: 21px; line-height: 1.15; }
.item .meta { margin-top: 4px; font-size: 14px; color: var(--muted); line-height: 1.35; }
.item-der { flex: 0 0 auto; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.precio { font-family: var(--serif); font-weight: 900; font-size: 21px; }
.item.agotada h3, .item.agotada .precio { color: var(--muted); }
.tag-agotada { font-size: 12px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--red); }
.vacio { padding: 40px 0; text-align: center; color: var(--muted); }

.stepper { display: inline-flex; align-items: center; border: 1.5px solid var(--ink); }
.stepper button {
  width: 44px; height: 42px; border: 0; background: #fff; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.stepper button:hover { background: var(--soft); }
.stepper button svg { width: 16px; height: 16px; }
.stepper output { min-width: 30px; text-align: center; font-weight: 600; font-size: 17px; padding-top: 3px; }

.barra {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: #fff; border-top: 1.5px solid var(--ink);
}
.barra .btn { max-width: 728px; margin: 0 auto; display: flex; width: 100%; justify-content: space-between; }
.barra .btn .t { font-family: var(--serif); font-size: 20px; letter-spacing: 0; text-transform: none; font-weight: 900; }

/* hoja de pedido (dialog) */
dialog.hoja {
  width: 100%; max-width: 640px; max-height: 100dvh; height: 100dvh; margin: 0 auto;
  padding: 0; border: 0; background: #fff; color: var(--ink);
}
@media (min-width: 700px) {
  dialog.hoja { height: auto; max-height: calc(100dvh - 40px); margin-top: 20px; border: 2px solid var(--ink); }
}
dialog::backdrop { background: rgba(20, 18, 16, 0.55); }
.hoja-in { padding: 0 20px 28px; }
.hoja-top {
  position: sticky; top: 0; z-index: 2; background: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 16px 0 12px; border-bottom: 1.5px solid var(--ink);
}
.hoja-top h2 { font-size: 30px; }
.cerrar { width: 44px; height: 44px; border: 1.5px solid var(--ink); background: #fff; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.cerrar svg { width: 18px; height: 18px; }
.lineas { list-style: none; margin: 0; padding: 0; }
.linea { display: flex; align-items: center; gap: 12px; padding: 14px 0 12px; border-bottom: 1px solid var(--line); }
.linea .n { flex: 1 1 auto; min-width: 0; }
.linea .n strong { display: block; font-family: var(--serif); font-size: 18px; line-height: 1.2; }
.linea .n small { color: var(--muted); font-size: 14px; }
.linea .imp { flex: 0 0 auto; font-weight: 600; min-width: 66px; text-align: right; }
.total-fila { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 0 4px; }
.total-fila span { font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; font-size: 14px; }
.total-fila strong { font-family: var(--serif); font-size: 34px; }
.nota-pago { font-size: 14px; color: var(--muted); }

.form { margin-top: 24px; display: grid; gap: 16px; }
.form h3 { font-size: 24px; }
.campo label { display: block; font-size: 13px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 6px; }
.campo label small { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--muted); font-size: 13px; }
.campo input, .campo textarea {
  width: 100%; border: 1.5px solid var(--ink); border-radius: 0; background: #fff;
  padding: 13px 14px 10px; font-size: 17px; -webkit-appearance: none; appearance: none;
}
.campo textarea { min-height: 80px; resize: vertical; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; line-height: 1.4; cursor: pointer; }
.check input { width: 22px; height: 22px; margin: 0; flex: 0 0 auto; accent-color: var(--ink); }
.trampa { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.error { color: var(--red); font-weight: 600; font-size: 15px; }

/* confirmación */
.hecho { text-align: center; padding: 34px 0 60px; }
.hecho .ok { width: 64px; height: 64px; margin: 0 auto; border: 2px solid var(--ink); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.hecho .ok svg { width: 30px; height: 30px; }
.hecho h1 { margin-top: 18px; font-size: clamp(40px, 10vw, 58px); }
.codigo-grande {
  margin: 22px auto 0; display: inline-block; border: 2px solid var(--ink);
  padding: 16px 26px 12px;
}
.codigo-grande .eyebrow { font-size: 12px; }
.codigo-grande strong { display: block; margin-top: 6px; font-family: var(--serif); font-size: 52px; line-height: 1; letter-spacing: 0.04em; }
.hecho .resumen { max-width: 520px; margin: 26px auto 0; text-align: left; }
.hecho .instr { max-width: 520px; margin: 22px auto 0; display: grid; gap: 10px; text-align: left; font-size: 16px; }
.hecho .instr p { display: flex; gap: 10px; }
.hecho .instr .star { width: 14px; height: 14px; margin-top: 3px; }
.hecho .acc { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }

footer.pie { text-align: center; font-size: 13px; color: var(--muted); padding: 24px 20px 40px; letter-spacing: 0.06em; }

/* catálogo real: fotos, filtros y notas */
.selects { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.selects select {
  width: 100%; min-height: 44px; border: 1.5px solid var(--ink); border-radius: 0; background: #fff;
  padding: 8px 30px 6px 12px; font-size: 15px; -webkit-appearance: none; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink) 50%), linear-gradient(135deg, var(--ink) 50%, transparent 50%);
  background-position: calc(100% - 16px) 52%, calc(100% - 11px) 52%; background-size: 5px 5px; background-repeat: no-repeat;
}
.selects select:disabled { opacity: 0.4; }
.item { align-items: flex-start; }
.item .foto { flex: 0 0 64px; width: 64px; height: 64px; object-fit: contain; background: #fff; }
.item .foto.vacia { display: flex; align-items: center; justify-content: center; background: var(--soft); color: var(--muted); }
.item .foto.vacia svg { width: 28px; height: 28px; }
.item h3 { font-size: 19px; }
.notas-cata { margin-top: 6px; font-size: 14px; }
.notas-cata summary { cursor: pointer; font-weight: 600; letter-spacing: 0.04em; padding: 4px 0; list-style: none; }
.notas-cata summary::-webkit-details-marker { display: none; }
.notas-cata summary::after { content: " +"; }
.notas-cata[open] summary::after { content: " –"; }
.notas-cata p { margin-top: 4px; color: var(--ink2); line-height: 1.45; }
.mas-wrap { text-align: center; padding: 22px 0 0; }
@media (max-width: 420px) {
  .item { gap: 10px; }
  .item .foto { flex-basis: 52px; width: 52px; height: 52px; }
  .item h3 { font-size: 17px; }
}

/* cuadrícula de productos (móvil: 2 por fila) */
.grid-cat { list-style: none; margin: 14px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 12px; }
@media (min-width: 560px) { .grid-cat { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 740px) { .grid-cat { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.grid-cat .vacio { grid-column: 1 / -1; }
.card { display: flex; flex-direction: column; min-width: 0; }
.card-ver {
  flex: 1 1 auto; display: flex; flex-direction: column; align-items: stretch; gap: 0;
  background: none; border: 0; padding: 0; margin: 0; text-align: left; cursor: pointer; color: inherit; font: inherit;
}
.card-ver:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.card-foto { position: relative; display: block; aspect-ratio: 1 / 1; background: #fff; border: 1px solid var(--line); }
.en-carrito .card-foto { border: 2px solid var(--ink); }
.card-foto .foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 6px; box-sizing: border-box; }
.card-foto .foto.vacia { display: flex; align-items: center; justify-content: center; background: var(--soft); color: var(--muted); padding: 0; }
.card-foto .foto.vacia svg { width: 34%; height: 34%; }
.card-n { position: absolute; top: 6px; right: 6px; min-width: 28px; height: 28px; padding: 3px 7px 0; border-radius: 14px; background: var(--ink); color: #fff; font-weight: 600; font-size: 15px; line-height: 25px; text-align: center; }
.card-nombre {
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  margin-top: 9px; font-family: var(--serif); font-weight: 700; font-size: 16px; line-height: 1.22;
}
.card-meta { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); line-height: 1.3; }
.card-precio { margin-top: 6px; font-family: var(--serif); font-weight: 900; font-size: 20px; }
.card-ctrl { margin-top: 8px; }
.card-ctrl .anadir-btn { width: 100%; }
.card-ctrl .stepper { width: 100%; justify-content: space-between; }
.card-ctrl .stepper button { flex: 0 0 44px; }

/* ficha de producto */
dialog.ficha .ficha-foto { margin-top: 14px; aspect-ratio: 1 / 1; max-height: 46vh; width: 100%; position: relative; background: #fff; }
dialog.ficha .ficha-foto .foto { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
dialog.ficha .ficha-foto .foto.vacia { display: flex; align-items: center; justify-content: center; background: var(--soft); }
.ficha-precio { margin-top: 14px; font-family: var(--serif); font-weight: 900; font-size: 32px; }
.ficha-datos { margin: 12px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; border-top: 1.5px solid var(--ink); padding-top: 12px; }
.ficha-datos dt { font-size: 11px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); }
.ficha-datos dd { margin: 2px 0 0; font-size: 16px; }
.ficha-t { margin-top: 18px; font-size: 22px; }
.ficha-desc { margin-top: 6px; color: var(--ink2); line-height: 1.5; }
.ficha-ctrl { margin-top: 20px; position: sticky; bottom: 0; background: #fff; padding: 10px 0 calc(6px + env(safe-area-inset-bottom)); }
.ficha-ctrl .stepper { width: 100%; justify-content: space-between; }
.ficha-ctrl .stepper button { flex: 0 0 64px; height: 48px; }

/* lámpara: con luz, la página toma un tono amarillento; sin luz, blanco y negro */
body { transition: background-color .12s linear; }
body.luz { background: #FFF3CF; }
body.luz .barra { background: #FFF3CF; }
body.luz .demo-banner { background: #FBE7A8; }
body.luz .datos li, body.luz .ultimo { background: rgba(255, 255, 255, .35); }
.hero { position: relative; padding-top: 0; }
.lampara { display: block; margin: 0 auto -6px; width: 120px; height: 140px; padding: 0; border: 0; background: none; cursor: pointer; position: relative; z-index: 1; }
.lampara svg { width: 100%; height: 100%; overflow: visible; }
.lampara .bulbo { fill: #cfc8bf; transition: fill .08s; }
.lampara .bulbo-halo { fill: #FFD84D; opacity: 0; transition: opacity .08s; }
body.luz .lampara .bulbo { fill: #FFE07A; }
body.luz .lampara .bulbo-halo { opacity: .55; }
.lampara:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }
.cono {
  position: absolute; left: 50%; top: 92px; width: min(560px, 140%); height: 520px; transform: translateX(-50%);
  background: linear-gradient(to bottom, rgba(255, 214, 77, .55), rgba(255, 214, 77, 0) 85%);
  clip-path: polygon(44% 0, 56% 0, 100% 100%, 0 100%);
  opacity: 0; transition: opacity .08s; pointer-events: none;
}
body.luz .cono { opacity: 1; }
.hero > *:not(.cono) { position: relative; }
.chiste { margin-top: 12px; font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--ink2); }
@media (prefers-reduced-motion: reduce) { body, .cono, .lampara .bulbo, .lampara .bulbo-halo { transition: none; } }
.hero .logo { mix-blend-mode: multiply; }

/* sin luz: una sombra suave arriba para que se note el apagón */
html, body { overflow-x: clip; }
.hero::before {
  content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 100vw; height: 560px; pointer-events: none;
  background: linear-gradient(to bottom, rgba(20, 18, 16, .22), rgba(20, 18, 16, .08) 45%, rgba(20, 18, 16, 0));
  opacity: 0; transition: opacity .12s linear;
}
body:not(.luz) .hero::before { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .hero::before { transition: none; } }

/* ---------- tipografía de soldegracia.com: Archivo (variable, con ancho) ---------- */
@font-face {
  font-family: "Archivo"; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("fonts/archivo-latin-wdth-normal.woff2") format("woff2-variations");
  unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}
@font-face {
  font-family: "Archivo"; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("fonts/archivo-latin-ext-wdth-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}
:root { --serif: "Archivo", system-ui, sans-serif; --sans: "Archivo", system-ui, sans-serif; }
body { font-variation-settings: "wdth" 100; line-height: 1.55; }
/* titulares y cifras: estrechos y gruesos, como en soldegracia.com */
h1, h2, h3, .precio, .card-precio, .ficha-precio, .total-fila strong, .codigo-grande strong, .datos strong,
.big-total strong, .pedido .cod, .resumen-v strong, .barra .btn .t, .ficha-t, .form h3, .pasos li::before {
  font-weight: 800; font-variation-settings: "wdth" 62; letter-spacing: -.005em;
}
.hero h1 { font-size: clamp(52px, 15vw, 84px); line-height: .9; }
.hero h1 span, .chiste { font-style: normal; font-weight: 500; font-variation-settings: "wdth" 100; letter-spacing: 0; }
.hero h1 span { font-size: .34em; margin-top: 12px; }
.chiste { font-size: 17px; }
.card-nombre { font-weight: 700; font-variation-settings: "wdth" 100; }
.card-precio, .precio { font-variation-settings: "wdth" 75; }
.linea .n strong, .item h3 { font-weight: 700; font-variation-settings: "wdth" 100; }
.eyebrow, .btn, .chip, .metodo, .tabs button, .campo label, .badge { font-weight: 700; }
.btn { padding: 12px 22px; }
.btn.peq { padding: 9px 14px; }
.chip { padding: 9px 14px; }
.buscar input, .campo input, .campo textarea, .selects select { padding-top: 10px; padding-bottom: 10px; }
.stepper output { padding-top: 0; }

/* separador fino y aviso de "no se puede entrar" centrado */
.sep-fino { width: 120px; height: 0; border: 0; border-top: 1.5px solid var(--ink); margin: 22px auto 0; }
.aviso { display: flex; align-items: center; justify-content: center; gap: 12px; max-width: 30ch; margin: 16px auto 0; text-align: left; line-height: 1.35; }
.aviso svg { width: 26px; height: 26px; flex: 0 0 26px; }

.pie .by { display: block; margin-top: 8px; font-size: 12px; letter-spacing: .08em; }

.stock-aviso { max-width: 34ch; margin: 14px auto 0; padding: 12px 14px; border: 1.5px dashed var(--ink); font-size: 15px; line-height: 1.4; text-align: center; }

/* tarjeta «otras cervezas que no salen en la web» */
.card-otras .card-ver { cursor: default; }
.card-otras .otras-ico { position: relative; border: 1.5px dashed var(--ink); background: #fff; }
.card-otras .otras-ico b { position: absolute; right: 22%; top: 18%; font-family: var(--serif); font-weight: 900; font-size: 34px; line-height: 1; }
.otra-linea .btn { flex: 0 0 auto; }
