/* ==========================================================================
   Comestibles Lozano · Tienda
   Mobile first: lo base es para celular; los @media agregan para pantallas grandes.
   ========================================================================== */

.skip-link { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: 999px; }
.skip-link:focus { left: 8px; }

/* Barra de anuncio -------------------------------------------------------- */
.announce { background: var(--accent); color: #fff; text-align: center; font-size: .88rem; font-weight: 600; padding: .5rem var(--gutter); }

/* Encabezado -------------------------------------------------------------- */
.site-header { position: sticky; top: 0; z-index: 40; background: #fff; border-bottom: 1px solid var(--line); }
.header-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-areas: "toggle brand cart" "search search search";
  align-items: center;
  gap: .5rem .75rem;
  padding-block: .5rem .75rem;
}
.nav-toggle { grid-area: toggle; display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 0; border-radius: 12px; background: transparent; }
.nav-toggle:hover { background: var(--cream-2); }
.brand { grid-area: brand; justify-self: center; display: block; }
.brand img { height: 50px; width: auto; max-width: none; } /* sin max-width el logo se aplasta cuando el menú no cabe */
.cart-link {
  grid-area: cart; position: relative; display: inline-flex; align-items: center; gap: .5rem;
  height: 44px; padding: 0 .7rem; border-radius: 999px; text-decoration: none; font-weight: 600;
}
.cart-link:hover { background: var(--cream-2); }
.cart-link .cart-text { display: none; }
.cart-count {
  position: absolute; top: 2px; right: 0; min-width: 20px; height: 20px; padding: 0 5px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 999px; background: var(--accent); color: #fff; font-size: .72rem; font-weight: 700;
}
.header-search { grid-area: search; position: relative; }
.header-search .input { min-height: 44px; padding-left: 2.6rem; border-radius: 999px; background: var(--cream); border-color: var(--line); }
.header-search .icon { position: absolute; left: .95rem; top: 50%; transform: translateY(-50%); color: var(--ink-3); pointer-events: none; }

.site-nav { display: none; }
.site-nav.is-open {
  display: flex; flex-direction: column; position: fixed; inset: 0; z-index: 60;
  background: var(--paper); padding: 1rem var(--gutter) 2rem; overflow-y: auto;
}
.site-nav .nav-close { align-self: flex-end; }
.site-nav a { display: flex; align-items: center; gap: .75rem; padding: .9rem .25rem; font-size: 1.15rem; font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line); }
.site-nav a[aria-current="page"] { color: var(--accent); }
.site-nav .nav-section { margin-top: 1.25rem; font-family: var(--font-mono); font-size: .75rem; letter-spacing: .12em; text-transform: uppercase; color: var(--amber); }
.site-nav .nav-cats a { font-size: 1rem; font-weight: 500; }
body.nav-open { overflow: hidden; }

.category-bar { border-top: 1px solid var(--line); background: var(--paper); }
.category-bar .container { display: flex; gap: .4rem; overflow-x: auto; padding-block: .55rem; scrollbar-width: none; }
.category-bar .container::-webkit-scrollbar { display: none; }

@media (min-width: 980px) {
  .header-row { grid-template-columns: auto minmax(220px, 420px) 1fr auto; grid-template-areas: "brand search nav cart"; gap: 1.5rem; padding-block: .6rem; }
  .nav-toggle, .site-nav .nav-close, .site-nav .nav-section, .site-nav .nav-cats { display: none; }
  .brand { justify-self: start; }
  .brand img { height: 62px; }
  .site-nav, .site-nav.is-open { grid-area: nav; display: flex; flex-direction: row; position: static; padding: 0; background: none; justify-content: flex-end; gap: .25rem; overflow: visible; }
  .site-nav a { padding: .5rem .8rem; font-size: .96rem; border: 0; border-radius: 999px; white-space: nowrap; }
  .site-nav a:hover { background: var(--cream-2); }
  .cart-link { padding: 0 1rem 0 .8rem; border: 1.5px solid var(--line-strong); }
  .cart-link .cart-text { display: inline; }
  .cart-count { position: static; }
}
/* Portátiles pequeños y tablets horizontales (980–1119 px): el menú completo no cabe con holgura, se compacta. */
@media (min-width: 980px) and (max-width: 1119px) {
  .header-row { grid-template-columns: auto minmax(140px, 300px) 1fr auto; gap: 1rem; }
  .site-nav a { padding: .5rem .55rem; font-size: .92rem; }
  .cart-link { padding: 0 .8rem 0 .65rem; }
}

/* Mensajes flash ---------------------------------------------------------- */
.flash-area { padding-top: 1rem; display: grid; gap: .5rem; }

/* Secciones --------------------------------------------------------------- */
.section { padding-block: 3rem; }
.section-alt { background: var(--cream-2); }
.section-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.section-head h2 { margin: 0; }
.section-head p { margin: .35rem 0 0; color: var(--ink-2); }
.lead { font-size: 1.12rem; color: var(--ink-2); max-width: 38rem; }
@media (min-width: 768px) { .section { padding-block: 4.5rem; } }

/* Portada ----------------------------------------------------------------- */
.hero { background: var(--ink); color: #f6efe6; overflow: hidden; }
.hero-grid { display: grid; gap: 2.5rem; padding-block: 2.75rem 3.25rem; align-items: center; }
.hero .eyebrow { color: var(--gold); }
.hero h1 { color: #fff; max-width: 14ch; }
.hero h1 em { font-style: normal; color: var(--gold); }
.hero .lead { color: #d9cbbb; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin: 1.75rem 0 1.5rem; }
.hero .btn-outline { --btn-fg: #fff; border-color: rgba(255, 255, 255, .35); }
.hero .btn-outline:hover { background: rgba(255, 255, 255, .08); border-color: #fff; }
.hero-points { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; margin: 0; padding: 0; list-style: none; font-size: .92rem; color: #d9cbbb; }
.hero-points li { display: inline-flex; align-items: center; gap: .4rem; }
.hero-points .icon { color: var(--gold); width: 18px; height: 18px; }
.hero-art { position: relative; display: grid; place-items: center; padding: 1.5rem 0; }
/* Ancho fijo: así el espacio del logo queda reservado antes de que cargue (sin saltos de diseño). */
.hero-logo-card { position: relative; z-index: 1; width: min(100%, 420px); background: #fff; border-radius: 28px; padding: 1.25rem 1.5rem; box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .7); transform: rotate(-2deg); }
.hero-logo-card img { width: 100%; aspect-ratio: 579 / 302; }
.hero-bubble {
  position: absolute; z-index: 2; display: inline-flex; align-items: center; gap: .45rem;
  background: var(--paper); color: var(--ink); border-radius: 999px; padding: .5rem .9rem;
  font-size: .86rem; font-weight: 600; box-shadow: var(--shadow-lg); text-decoration: none;
}
.hero-bubble .icon { color: var(--amber); width: 18px; height: 18px; }
.hero-bubble:nth-of-type(1) { top: 0; left: 2%; transform: rotate(-4deg); }
.hero-bubble:nth-of-type(2) { top: 6%; right: 0; transform: rotate(3deg); }
.hero-bubble:nth-of-type(3) { bottom: 2%; left: 0; transform: rotate(2deg); }
.hero-bubble:nth-of-type(4) { bottom: -4%; right: 4%; transform: rotate(-3deg); }
/* En celular solo caben dos etiquetas sin tapar el logo. */
@media (max-width: 599px) { .hero-bubble:nth-of-type(n+3) { display: none; } .hero-bubble { font-size: .8rem; } }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.1fr .9fr; padding-block: 4.5rem 5rem; }
}

/* Categorías -------------------------------------------------------------- */
.category-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }
.category-tile {
  display: flex; flex-direction: column; gap: .75rem; padding: 1.1rem;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  text-decoration: none; transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}
.category-tile:hover { border-color: var(--amber); transform: translateY(-2px); box-shadow: var(--shadow); }
.category-tile .tile-icon { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 12px; background: var(--amber-soft); color: var(--amber); }
.category-tile strong { font-family: var(--font-display); font-size: 1.05rem; line-height: 1.2; }
.category-tile span { font-size: .85rem; color: var(--ink-3); }
@media (min-width: 640px) { .category-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 980px) { .category-grid { grid-template-columns: repeat(5, 1fr); } }

/* Tarjeta de producto ----------------------------------------------------- */
.product-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
@media (min-width: 640px) { .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; } }
@media (min-width: 1024px) { .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; } }

.product-card {
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  transition: box-shadow .15s ease, border-color .15s ease;
}
.product-card:hover { box-shadow: var(--shadow); border-color: var(--line-strong); }
.pc-media { position: relative; display: block; aspect-ratio: 1; background: #fff; border-bottom: 1px solid var(--line); }
.pc-media img { width: 100%; height: 100%; object-fit: contain; padding: 8%; }
.pc-flags { position: absolute; top: .55rem; left: .55rem; display: flex; flex-direction: column; gap: .3rem; align-items: flex-start; }
.pc-body { display: flex; flex-direction: column; gap: .35rem; padding: .8rem .85rem .9rem; flex: 1; }
.pc-cat { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; color: var(--amber); }
.pc-name { font-family: var(--font-body); font-size: .95rem; font-weight: 600; line-height: 1.3; letter-spacing: 0; margin: 0; flex: 1; }
.pc-name a { text-decoration: none; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.pc-name a:hover { color: var(--accent); }
.price { display: flex; flex-wrap: wrap; align-items: baseline; gap: .1rem .4rem; }
.price strong { font-family: var(--font-display); font-size: 1.15rem; letter-spacing: -.01em; }
.price .per { font-size: .82rem; color: var(--ink-3); }
.price s { font-size: .85rem; color: var(--ink-3); }
.pc-add { margin-top: .35rem; }
.pc-add .btn { width: 100%; min-height: 40px; font-size: .9rem; }

/* Imagen de respaldo cuando el producto aún no tiene foto */
.ph { width: 100%; height: 100%; display: grid; place-items: center; background: var(--amber-soft); color: var(--amber); }
.ph svg { width: 34%; height: 34%; stroke-width: 1.25; opacity: .8; }
.ph-1 { background: var(--green-soft); color: var(--green); }
.ph-2 { background: var(--red-soft); color: var(--red); }
.ph-3 { background: var(--cream-2); color: var(--ink-2); }
/* Bolsa genérica de 1 kg para los «x kilogramo» sin foto: sobre el color de la categoría, sin el relleno de las fotos reales */
.ph.ph-generic img { width: 86%; height: 86%; padding: 0; object-fit: contain; }
.cart-thumb .ph.ph-generic img { width: 92%; height: 92%; }

.stock-tag { font-size: .78rem; font-weight: 600; }
.stock-tag.is-low { color: var(--warn); }
.stock-tag.is-out { color: var(--ink-3); }

/* Catálogo ---------------------------------------------------------------- */
.page-head { padding-block: 1.75rem 1.25rem; }
.page-head h1 { font-size: clamp(1.75rem, 4vw, 2.6rem); margin-bottom: .35rem; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; font-size: .85rem; color: var(--ink-3); margin-bottom: .85rem; }
.breadcrumbs a { text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent); }
.catalog-tools { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; justify-content: space-between; margin-bottom: 1.25rem; }
.catalog-tools .select { width: auto; min-height: 42px; border-radius: 999px; padding-inline: 1rem 2rem; }
.catalog-layout { display: grid; gap: 1.5rem; padding-bottom: 3rem; }
.catalog-side { display: none; }
@media (min-width: 1024px) {
  .catalog-layout { grid-template-columns: 240px 1fr; align-items: start; }
  .catalog-side { display: block; position: sticky; top: 150px; }
  .catalog-side a { display: flex; justify-content: space-between; gap: .5rem; padding: .55rem .75rem; border-radius: 10px; text-decoration: none; font-size: .95rem; }
  .catalog-side a:hover { background: var(--cream-2); }
  .catalog-side a.is-active { background: var(--ink); color: #fff; }
  .catalog-side a span { color: var(--ink-3); font-size: .85rem; }
  .catalog-side a.is-active span { color: var(--gold); }
}
.empty-state { text-align: center; padding: 3rem 1rem; background: var(--paper); border: 1px dashed var(--line-strong); border-radius: var(--radius-lg); }
.empty-state .icon-lg { margin: 0 auto 1rem; color: var(--amber); width: 44px; height: 44px; }

/* Ficha de producto ------------------------------------------------------- */
.product-page { padding-bottom: 3rem; }
.pp-grid { display: grid; gap: 1.5rem; }
.pp-media { aspect-ratio: 1; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.pp-media img { width: 100%; height: 100%; object-fit: contain; padding: 6%; }
.pp-info h1 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
.pp-price strong { font-size: 2rem; }
.pp-meta { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; margin: .5rem 0 1.25rem; font-size: .9rem; color: var(--ink-3); }
.pp-buy { display: flex; flex-wrap: wrap; gap: .75rem; align-items: stretch; padding: 1rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 1.25rem; }
.pp-buy .btn { flex: 1 1 200px; }
.pp-perks { display: grid; gap: .65rem; margin: 0 0 1.5rem; padding: 0; list-style: none; }
.pp-perks li { display: flex; gap: .7rem; align-items: flex-start; font-size: .94rem; color: var(--ink-2); }
.pp-perks .icon { color: var(--green); margin-top: 2px; }
.pp-desc { border-top: 1px solid var(--line); padding-top: 1.25rem; color: var(--ink-2); white-space: pre-line; }
@media (min-width: 860px) { .pp-grid { grid-template-columns: 1fr 1fr; gap: 3rem; align-items: start; } .pp-media { position: sticky; top: 150px; } }

/* Selector de cantidad */
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line-strong); border-radius: 999px; background: #fff; height: 46px; }
.qty button { width: 42px; height: 100%; border: 0; background: transparent; font-size: 1.2rem; font-weight: 600; border-radius: 999px; }
.qty button:hover { background: var(--cream-2); }
.qty input { width: 3.2rem; height: 100%; border: 0; text-align: center; font-weight: 700; background: transparent; -moz-appearance: textfield; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-select { min-height: 46px; border-radius: 999px; width: auto; padding-inline: 1rem 2.2rem; font-weight: 600; }
.qty-sm { height: 38px; }
.qty-sm button { width: 34px; }
.qty-sm input { width: 2.6rem; }

/* Carrito ----------------------------------------------------------------- */
.cart-layout { display: grid; gap: 1.5rem; padding-bottom: 3rem; }
.cart-lines { display: grid; gap: .75rem; }
.cart-line {
  display: grid; grid-template-columns: 72px 1fr; gap: .4rem .9rem; align-items: start;
  padding: .85rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
}
.cart-thumb { width: 72px; height: 72px; border-radius: 12px; overflow: hidden; background: #fff; border: 1px solid var(--line); grid-row: span 2; }
.cart-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.cart-thumb .ph svg { width: 46%; height: 46%; }
.cart-name { font-weight: 600; line-height: 1.3; text-decoration: none; }
.cart-name:hover { color: var(--accent); }
.cart-controls { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }
.cart-controls form { display: flex; align-items: center; gap: .4rem; }
.cart-line-total { font-family: var(--font-display); font-weight: 700; font-size: 1.1rem; }
.link-btn { border: 0; background: none; padding: .3rem; color: var(--ink-3); display: inline-flex; align-items: center; gap: .3rem; font-size: .85rem; border-radius: 8px; }
.link-btn:hover { color: var(--red); background: var(--red-soft); }
.summary { padding: 1.25rem; display: grid; gap: .75rem; align-content: start; }
.summary h2 { font-size: 1.25rem; margin: 0; }
.summary-row { display: flex; justify-content: space-between; gap: 1rem; font-size: .96rem; }
.summary-row.total { border-top: 1px solid var(--line); padding-top: .75rem; font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; }
.summary .note { font-size: .85rem; color: var(--ink-3); margin: 0; }
.progress { height: 8px; border-radius: 999px; background: var(--cream-2); overflow: hidden; }
.progress span { display: block; height: 100%; background: var(--green); border-radius: inherit; }
@media (min-width: 900px) {
  .cart-layout { grid-template-columns: 1fr 360px; align-items: start; }
  .summary { position: sticky; top: 150px; }
  .cart-line { grid-template-columns: 88px 1fr; }
  .cart-thumb { width: 88px; height: 88px; }
}

/* Pago (checkout) ---------------------------------------------------------- */
.checkout-layout { display: grid; gap: 1.25rem; padding-bottom: 3rem; }
.co-step { padding: 1.25rem; }
.co-step h2 { display: flex; align-items: center; gap: .65rem; font-size: 1.2rem; margin-bottom: 1rem; }
.step-n { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--ink); color: #fff; font-family: var(--font-mono); font-size: .85rem; }
.choice-grid { display: grid; gap: .65rem; margin-bottom: 1rem; }
@media (min-width: 560px) { .choice-grid { grid-template-columns: 1fr 1fr; } }
.choice { position: relative; display: flex; gap: .8rem; align-items: flex-start; padding: 1rem; border: 1.5px solid var(--line-strong); border-radius: var(--radius); background: #fff; cursor: pointer; transition: border-color .15s ease, background-color .15s ease; }
.choice:hover { border-color: var(--ink-2); }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice .choice-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--cream-2); color: var(--ink-2); flex: none; }
.choice strong { display: block; }
.choice small { display: block; color: var(--ink-3); font-size: .85rem; line-height: 1.35; margin-top: .15rem; }
.choice .choice-price { margin-left: auto; font-weight: 700; white-space: nowrap; }
.choice:has(input:checked) { border-color: var(--accent-line); background: var(--accent-tint); box-shadow: var(--focus); }
.choice:has(input:checked) .choice-icon { background: var(--accent); color: #fff; }
.choice:has(input:focus-visible) { box-shadow: var(--focus); }
[data-when] { display: none; }
[data-when].is-visible { display: block; }
.no-js [data-when] { display: block; }
.mini-lines { display: grid; gap: .5rem; max-height: 260px; overflow-y: auto; padding-right: .25rem; }
.mini-line { display: flex; justify-content: space-between; gap: .75rem; font-size: .9rem; }
.mini-line span:first-child { color: var(--ink-2); }
@media (min-width: 960px) {
  .checkout-layout { grid-template-columns: 1fr 380px; align-items: start; }
  .checkout-layout .summary { position: sticky; top: 150px; }
}

/* Seguimiento del pedido -------------------------------------------------- */
.order-page { padding-bottom: 3rem; }
.thanks { padding: 1.5rem; margin-bottom: 1.5rem; background: var(--ink); color: #f6efe6; border-radius: var(--radius-lg); display: grid; gap: 1rem; }
.thanks h1 { color: #fff; font-size: clamp(1.6rem, 4vw, 2.3rem); margin: 0; }
.thanks p { margin: 0; color: #d9cbbb; }
.thanks .eyebrow { color: var(--gold); margin: 0; }
.thanks .actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.order-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .75rem 1rem; align-items: center; margin-bottom: 1.25rem; }
.order-code { font-family: var(--font-mono); font-size: 1.35rem; font-weight: 700; letter-spacing: .04em; }
.tracker { list-style: none; margin: 0 0 1.5rem; padding: 1.25rem; display: grid; gap: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.tracker li { position: relative; display: grid; grid-template-columns: 34px 1fr; gap: .9rem; padding-bottom: 1.25rem; }
.tracker li:last-child { padding-bottom: 0; }
.tracker li::before { content: ""; position: absolute; left: 16px; top: 34px; bottom: 0; width: 2px; background: var(--line); }
.tracker li:last-child::before { display: none; }
.tracker .dot { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--line-strong); background: #fff; color: var(--ink-3); position: relative; z-index: 1; }
.tracker .dot .icon { width: 16px; height: 16px; }
.tracker strong { display: block; padding-top: .3rem; }
.tracker small { color: var(--ink-3); }
.tracker .is-done .dot { background: var(--green); border-color: var(--green); color: #fff; }
.tracker .is-done::before { background: var(--green); }
.tracker .is-current .dot { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 0 0 6px var(--accent-soft); }
.tracker .is-current strong { color: var(--accent); }
@media (min-width: 760px) {
  .tracker { grid-template-columns: repeat(4, 1fr); padding: 1.5rem 1.25rem; }
  .tracker li { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: .5rem; padding: 0 .5rem; }
  .tracker li::before { left: calc(50% + 17px); right: calc(-50% + 17px); top: 16px; bottom: auto; width: auto; height: 2px; }
  .tracker strong { padding-top: 0; }
}
.order-layout { display: grid; gap: 1.25rem; }
.order-layout .card { padding: 1.25rem; }
.order-layout h2 { font-size: 1.15rem; }
.info-list { display: grid; gap: .85rem; margin: 0; }
.info-list dt { font-size: .78rem; font-family: var(--font-mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.info-list dd { margin: .1rem 0 0; }
.item-row { display: flex; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid var(--line); }
.item-row:last-of-type { border-bottom: 0; }
.item-row small { display: block; color: var(--ink-3); }
.history { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.history li { display: grid; gap: .1rem; padding-left: 1rem; border-left: 2px solid var(--line); font-size: .92rem; }
.history time { font-size: .8rem; color: var(--ink-3); }
@media (min-width: 900px) { .order-layout { grid-template-columns: 1fr 380px; align-items: start; } }

.narrow { max-width: 520px; margin-inline: auto; }
.form-card { padding: 1.5rem; }

/* Páginas informativas ---------------------------------------------------- */
.prose { max-width: 760px; color: var(--ink-2); }
.prose h2 { color: var(--ink); font-size: 1.4rem; margin-top: 2rem; }
.prose h3 { color: var(--ink); margin-top: 1.5rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: .4rem; }
.feature-grid { display: grid; gap: .9rem; }
@media (min-width: 700px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .feature-grid.cols-3 { grid-template-columns: repeat(3, 1fr); } .feature-grid.cols-4 { grid-template-columns: repeat(4, 1fr); } }
.feature { padding: 1.35rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-lg); }
.feature .num { font-family: var(--font-mono); font-size: .85rem; color: var(--amber); font-weight: 600; }
.feature h3 { margin: .5rem 0 .35rem; }
.feature p { margin: 0; color: var(--ink-2); font-size: .95rem; }
.feature .icon { color: var(--amber); width: 26px; height: 26px; }
.feature.is-dark { background: var(--ink); border-color: var(--ink); color: #f6efe6; }
.feature.is-dark p { color: #d9cbbb; }
.feature.is-dark .num, .feature.is-dark .icon { color: var(--gold); }

.band { background: var(--ink); color: #f6efe6; border-radius: var(--radius-lg); padding: 2rem 1.5rem; display: grid; gap: 1.25rem; align-items: center; }
.band h2 { color: #fff; margin: 0 0 .35rem; }
.band p { margin: 0; color: #d9cbbb; }
.band .eyebrow { color: var(--gold); }
@media (min-width: 800px) { .band { grid-template-columns: 1fr auto; padding: 2.5rem 3rem; } }

.store-list { display: grid; gap: .9rem; }
@media (min-width: 700px) { .store-list { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .store-list { grid-template-columns: repeat(3, 1fr); } }
.store-card { padding: 1.25rem; display: grid; gap: .6rem; align-content: start; }
.store-card h2 { margin: 0; font-size: 1.2rem; letter-spacing: -.01em; display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.nearest { display: flex; flex-wrap: wrap; gap: .5rem .9rem; align-items: center; margin-top: .25rem; }
.nearest-field { display: flex; flex-wrap: wrap; gap: .4rem .75rem; align-items: center; margin-top: .5rem; }
.store-card p { margin: 0; display: flex; gap: .55rem; align-items: flex-start; color: var(--ink-2); font-size: .94rem; }
.store-card p .icon { color: var(--amber); width: 18px; height: 18px; margin-top: 2px; }
.store-card .actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .4rem; }
.store-map { height: 380px; border-radius: var(--radius-lg); border: 1px solid var(--line); overflow: hidden; margin-bottom: 1.5rem; z-index: 0; }
@media (min-width: 900px) { .store-map { height: 460px; } }

.contact-grid { display: grid; gap: .9rem; }
@media (min-width: 700px) { .contact-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .contact-grid { grid-template-columns: repeat(4, 1fr); } }
.contact-card { padding: 1.35rem; display: grid; gap: .5rem; align-content: start; text-decoration: none; }
.contact-card .icon { width: 28px; height: 28px; color: var(--amber); }
.contact-card strong { font-family: var(--font-display); font-size: 1.15rem; }
.contact-card span { color: var(--ink-2); font-size: .94rem; word-break: break-word; }
a.contact-card:hover { border-color: var(--amber); box-shadow: var(--shadow); }

.toc { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }

/* Pie de página ----------------------------------------------------------- */
.site-footer { background: var(--ink); color: #d9cbbb; margin-top: 2rem; font-size: .94rem; }
.footer-grid { display: grid; gap: 2rem; padding-block: 3rem 2rem; }
.footer-brand img { width: 170px; background: #fff; border-radius: 16px; padding: .5rem .75rem; margin-bottom: 1rem; }
.site-footer h3 { color: #fff; font-family: var(--font-mono); font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: .9rem; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-contact li { display: flex; gap: .55rem; align-items: center; }
.footer-contact .icon { width: 18px; height: 18px; color: var(--gold); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .12); padding-block: 1.25rem; font-size: .84rem; display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; justify-content: space-between; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr 1.2fr; } }

/* WhatsApp flotante y aviso de carrito ------------------------------------ */
.wa-float {
  position: fixed; right: 16px; bottom: 16px; z-index: 50;
  width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center;
  background: #1f9d55; color: #fff; box-shadow: var(--shadow-lg);
  transition: transform .15s ease;
}
.wa-float:hover { transform: scale(1.06); }
.wa-float svg { width: 30px; height: 30px; }

.toast {
  position: fixed; left: 50%; bottom: 84px; z-index: 70; transform: translate(-50%, 20px);
  width: min(92vw, 440px); display: flex; gap: .75rem; align-items: center;
  padding: .85rem 1rem; border-radius: var(--radius); background: var(--ink); color: #fff;
  box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity .2s ease, transform .2s ease;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast .icon { color: #7fd69c; }
.toast p { margin: 0; flex: 1; font-size: .92rem; }
.toast a { color: var(--gold); font-weight: 700; white-space: nowrap; }
@media (min-width: 768px) { .toast { left: auto; right: 24px; bottom: 24px; transform: translateY(20px); } .toast.is-visible { transform: none; } }

/* Maní, la mascota guía ---------------------------------------------------
   El dibujo (.mascot) es siempre el mismo; el globo y el botón usan los colores de la paleta de la tienda. */
.mascot { display: block; width: 100%; height: auto; overflow: visible; }
.m-body { animation: m-bob 3.6s ease-in-out infinite; }
.m-eyes { transform-box: view-box; transform-origin: 60px 34px; animation: m-blink 5.5s infinite; }
.m-arm { transform-box: view-box; transform-origin: 88px 82px; }
@keyframes m-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
@keyframes m-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes m-wave { 0%, 100% { transform: rotate(0); } 25% { transform: rotate(-17deg); } 75% { transform: rotate(13deg); } }
/* Saluda al llegar, al pasar el mouse y mientras habla. En reposo el brazo se queda arriba, quieto. */
.guide.is-intro .is-wave .m-arm,
.guide.is-open .is-wave .m-arm,
.guide-btn:hover .is-wave .m-arm { animation: m-wave .9s ease-in-out 3; }

.mascot-empty { width: 96px; margin: 0 auto 1rem; }

.guide { position: fixed; left: 14px; bottom: 14px; z-index: 45; display: flex; flex-direction: column; align-items: flex-start; gap: .65rem; }
.guide[hidden], .guide-bubble[hidden], .guide-hello[hidden], .guide-dot[hidden], .guide-restore[hidden] { display: none !important; }
.no-js .guide, .nav-open .guide { display: none; }
@media (min-width: 768px) { .guide { left: 22px; bottom: 20px; } }

.guide-btn {
  position: relative; width: 72px; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 20px;
  filter: drop-shadow(0 8px 10px rgba(43, 29, 20, .24)); transition: transform .18s ease;
}
.guide-btn:hover { transform: translateY(-3px) rotate(-3deg); }
.guide-btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
@media (min-width: 768px) { .guide-btn { width: 86px; } }
.guide-dot {
  position: absolute; top: 2px; right: -2px; width: 15px; height: 15px; border-radius: 50%;
  background: var(--accent); border: 2px solid #fff; animation: guide-ping 1.8s ease-out infinite;
}
@keyframes guide-ping { 0% { box-shadow: 0 0 0 0 var(--accent-ring); } 70%, 100% { box-shadow: 0 0 0 9px transparent; } }

.guide-bubble {
  position: relative; width: min(300px, calc(100vw - 28px)); padding: .95rem 1.05rem .8rem;
  background: var(--card); color: var(--ink); border: 1px solid var(--line-strong); border-radius: 18px 18px 18px 6px;
  box-shadow: var(--shadow-lg); transform-origin: 28px 100%; animation: guide-pop .22s ease-out;
}
.guide-bubble::after {
  content: ""; position: absolute; left: 26px; bottom: -8px; width: 14px; height: 14px;
  background: var(--card); border: 1px solid var(--line-strong); border-top: 0; border-left: 0; transform: rotate(45deg);
}
@keyframes guide-pop { from { opacity: 0; transform: translateY(8px) scale(.94); } to { opacity: 1; transform: none; } }
/* Saludo corto de la primera visita: se quita solo y el consejo completo espera a que lo pidan. */
.guide-hello {
  position: relative; margin-left: 8px; padding: .55rem .95rem; font: inherit; font-size: .9rem; font-weight: 600; color: var(--ink);
  background: var(--card); border: 1px solid var(--line-strong); border-radius: 999px 999px 999px 6px;
  box-shadow: var(--shadow); cursor: pointer; transform-origin: 20px 100%; animation: guide-pop .25s ease-out;
}
.guide-hello:hover { background: var(--cream-2); }
.guide-hello:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.guide-name { display: block; font-family: var(--font-mono); font-size: .7rem; letter-spacing: .1em; text-transform: uppercase; color: var(--amber); margin-bottom: .35rem; padding-right: 1.8rem; }
.guide-text { margin: 0 0 .75rem; font-size: .95rem; line-height: 1.45; }
.guide-links { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: .55rem; }
.guide-x { position: absolute; top: .45rem; right: .45rem; width: 32px; height: 32px; display: grid; place-items: center; border: 0; background: none; border-radius: 50%; color: var(--ink-3); cursor: pointer; }
.guide-x:hover { background: var(--cream-2); color: var(--ink); }
.guide-x .icon { width: 16px; height: 16px; }
.guide-off { border: 0; background: none; padding: .25rem 0; font: inherit; font-size: .8rem; color: var(--ink-3); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.guide-off:hover { color: var(--ink); }
.guide-restore { color: rgba(255, 255, 255, .75); }
.guide-restore:hover { color: #fff; background: rgba(255, 255, 255, .12); }

@media print {
  .site-header, .site-footer, .wa-float, .announce, .no-print { display: none !important; }
  body { background: #fff; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
  .m-body, .m-eyes, .m-arm, .guide-dot, .guide-bubble, .guide-hello { animation: none !important; }
}
