/* Extras: buscador, carrito, cuenta, FAQs, newsletter, beneficios, etiquetas, WhatsApp, toast */

/* ============ UTILIDADES ============ */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.no-scroll { overflow: hidden; }
.btn-solid {
  width: 100%; padding: 16px; background: var(--ink); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  border: 1.5px solid var(--ink); transition: background .35s var(--ease), color .35s, transform .35s var(--ease);
}
.btn-solid:hover:not(:disabled) { background: #fff; color: var(--ink); }
.btn-solid:active:not(:disabled) { transform: scale(.98); }
.btn-solid:disabled { opacity: .35; cursor: not-allowed; }
.overlay-close { position: absolute; top: 18px; right: 22px; width: 42px; height: 42px; font-size: 18px; border-radius: 50%; transition: background .3s, transform .4s var(--ease); }
.overlay-close:hover { background: #f1f1f2; transform: rotate(90deg); }
.backdrop { position: fixed; inset: 0; z-index: 300; background: rgba(0,0,0,.5); opacity: 0; transition: opacity .45s ease; }
.backdrop.is-open { opacity: 1; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
[hidden] { display: none !important; }

/* ============ ETIQUETAS ============ */
.tags { position: absolute; top: 0; left: 0; z-index: 2; display: flex; }
.tag { writing-mode: vertical-rl; transform: rotate(180deg); font-size: 8.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: 10px 5px; color: #fff; }
.tag-free { background: #c8312b; }
.tag-out { background: #1b1b1d; }
.card.is-out .card-media img, .card.is-out .card-ph { opacity: .45; filter: grayscale(1); }
.card-add.is-disabled { display: block; text-align: center; background: #d9d9db; color: #555; cursor: not-allowed; }

/* ============ BENEFICIOS ============ */
.perks { max-width: 1100px; margin: 0 auto; padding: 70px 28px 90px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; border-top: 1px solid #ececee; }
.perk { text-align: center; display: grid; justify-items: center; gap: 8px; }
.perk svg { width: 34px; height: 34px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; margin-bottom: 6px; transition: transform .5s var(--ease); }
.perk:hover svg { transform: translateY(-5px) scale(1.08); }
.perk strong { font-size: 12.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.perk span { font-size: 12px; color: var(--muted); }

/* ============ FAQS ============ */
.faqs { max-width: 820px; margin: 0 auto; padding: 20px 28px 100px; }
.faqs .section-title { text-align: center; }
.faq { border-bottom: 1px solid #e3e3e6; }
.faq:first-child { border-top: 1px solid #e3e3e6; }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding: 22px 4px; font-size: 14px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; transition: padding .4s var(--ease); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 22px; font-weight: 400; transition: transform .45s var(--ease); }
.faq[open] summary::after { transform: rotate(135deg); }
.faq summary:hover { padding-left: 14px; }
.faq p { padding: 0 4px 24px; font-size: 14px; line-height: 1.7; color: #55555a; max-width: 62ch; animation: faqIn .5s var(--ease); }
@keyframes faqIn { from { opacity: 0; transform: translateY(-8px); } }

/* ============ NEWSLETTER ============ */
.join { background: var(--ink); color: #fff; padding: 100px 28px; text-align: center; }
.join-inner { max-width: 560px; margin: 0 auto; }
.join h2 { font-size: clamp(34px, 5vw, 60px); font-weight: 900; font-style: italic; letter-spacing: -.04em; text-transform: uppercase; margin-bottom: 12px; }
.join p { color: #a9a9ae; font-size: 14px; }
.join-form { display: flex; margin-top: 32px; border-bottom: 1.5px solid #fff; transition: border-color .3s; }
.join-form:focus-within { border-color: #b98aff; }
.join-form input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: #fff; font: inherit; font-size: 14px; padding: 16px 4px; }
.join-form input::placeholder { color: #77777c; }
.join-form button { font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; padding: 0 6px 0 20px; transition: letter-spacing .4s var(--ease); }
.join-form button:hover { letter-spacing: .22em; }
.join-msg { min-height: 20px; margin-top: 14px; font-size: 13px; }
.join-msg.is-ok { color: #7ee2a0; }

/* ============ BUSCADOR ============ */
.search-overlay { position: fixed; inset: 0; z-index: 400; background: rgba(255,255,255,.98); display: grid; align-items: start; justify-items: center; padding: 14vh 24px 24px;
  opacity: 0; transform: translateY(-20px); transition: opacity .4s ease, transform .5s var(--ease); overflow: auto; }
.search-overlay.is-open { opacity: 1; transform: none; }
.search-box { width: min(720px, 100%); }
.search-box input { width: 100%; border: 0; border-bottom: 2px solid var(--ink); outline: 0; background: none; font: inherit; font-size: clamp(22px, 4vw, 40px); font-weight: 800; text-transform: uppercase; padding: 14px 0; letter-spacing: -.01em; }
.search-box input::placeholder { color: #c4c4c8; }
.search-results { margin-top: 24px; }
.search-results a { display: grid; grid-template-columns: 56px 1fr auto; gap: 16px; align-items: center; padding: 12px 6px; border-bottom: 1px solid #eee; transition: background .3s, padding .4s var(--ease); }
.search-results a:hover { background: #f7f7f8; padding-left: 16px; }
.sr-img { position: relative; width: 56px; height: 72px; background: #f4f4f5; display: grid; place-items: center; overflow: hidden; }
.sr-img b { font-style: italic; font-size: 11px; color: #cfcfd2; }
.sr-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.sr-name { font-size: 12.5px; font-weight: 600; text-transform: uppercase; }
.sr-name em { font-style: normal; font-size: 10px; color: #c8312b; margin-left: 6px; }
.sr-price { font-size: 13px; font-weight: 700; }
.sr-empty { padding: 24px 0; color: var(--muted); }

/* ============ CARRITO ============ */
.cart-drawer { position: fixed; top: 0; right: 0; bottom: 0; z-index: 400; width: min(430px, 100%); background: #fff; display: flex; flex-direction: column;
  transform: translateX(100%); visibility: hidden; transition: transform .55s var(--ease), visibility 0s .55s; box-shadow: -20px 0 60px -30px rgba(0,0,0,.4); }
.cart-drawer.is-open { transform: none; visibility: visible; transition: transform .55s var(--ease); }
.cart-drawer header { display: flex; justify-content: space-between; align-items: center; padding: 20px 24px; border-bottom: 1px solid #ececee; }
.cart-drawer h2 { font-size: 14px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.cart-drawer header button { width: 38px; height: 38px; border-radius: 50%; font-size: 16px; transition: background .3s, transform .4s var(--ease); }
.cart-drawer header button:hover { background: #f1f1f2; transform: rotate(90deg); }
.ship-bar { padding: 16px 24px; background: #f7f7f8; font-size: 12px; }
.ship-track { height: 4px; background: #e3e3e6; margin-top: 10px; overflow: hidden; }
.ship-track i { display: block; height: 100%; width: 0; background: var(--ink); transition: width .6s var(--ease); }
.cart-items { flex: 1; overflow: auto; padding: 8px 24px; }
.ci { display: grid; grid-template-columns: 72px 1fr auto; gap: 16px; padding: 16px 0; border-bottom: 1px solid #eee; animation: faqIn .5s var(--ease); }
.ci-img { position: relative; width: 72px; height: 92px; background: #f4f4f5; display: grid; place-items: center; overflow: hidden; }
.ci-img span { font-style: italic; font-weight: 900; font-size: 12px; color: #cfcfd2; }
.ci-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.ci-body h3 { font-size: 11.5px; font-weight: 600; text-transform: uppercase; margin-bottom: 6px; }
.ci-body p { font-size: 13px; font-weight: 700; }
.qty { display: inline-flex; align-items: center; margin-top: 10px; border: 1px solid #ddd; }
.qty button { width: 30px; height: 30px; font-size: 16px; transition: background .25s; }
.qty button:hover { background: #f1f1f2; }
.qty span { min-width: 28px; text-align: center; font-size: 13px; font-weight: 700; }
.ci-del { align-self: start; width: 28px; height: 28px; font-size: 12px; color: var(--muted); transition: color .3s; }
.ci-del:hover { color: #c8312b; }
.cart-empty { text-align: center; padding: 70px 0; color: var(--muted); font-size: 14px; line-height: 2; }
.cart-empty a { color: var(--ink); font-weight: 700; text-decoration: underline; }
.cart-drawer footer { padding: 20px 24px 24px; border-top: 1px solid #ececee; display: grid; gap: 10px; }
.cart-total { display: flex; justify-content: space-between; font-size: 14px; font-weight: 700; text-transform: uppercase; }
.cart-total strong { font-size: 18px; }
.cart-note { font-size: 12px; color: #1f7a3d; min-height: 16px; }

/* ============ MODAL CUENTA ============ */
.modal { position: fixed; inset: 0; z-index: 400; display: grid; place-items: center; padding: 20px; background: rgba(0,0,0,.5); opacity: 0; transition: opacity .4s ease; }
.modal.is-open { opacity: 1; }
.modal-card { position: relative; width: min(420px, 100%); background: #fff; padding: 44px 36px 32px; transform: translateY(24px) scale(.98); transition: transform .55s var(--ease); }
.modal.is-open .modal-card { transform: none; }
.modal h2 { font-size: 22px; font-weight: 900; text-transform: uppercase; letter-spacing: -.01em; margin-bottom: 24px; }
.modal label { display: block; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin-bottom: 16px; }
.modal input { display: block; width: 100%; margin-top: 8px; padding: 14px; border: 1px solid #d9d9dc; font: inherit; font-size: 14px; transition: border-color .3s; }
.modal input:focus { outline: 0; border-color: var(--ink); }
.modal-foot { margin-top: 18px; text-align: center; font-size: 13px; color: var(--muted); }
.modal-foot a { color: var(--ink); font-weight: 700; text-decoration: underline; }

/* ============ WHATSAPP + TOAST ============ */
.wa-float { position: fixed; right: 22px; bottom: 22px; z-index: 90; width: 56px; height: 56px; border-radius: 50%; background: #25d366; color: #fff; display: grid; place-items: center;
  box-shadow: 0 10px 26px -8px rgba(37,211,102,.7); transition: transform .4s var(--ease); animation: waPulse 2.6s ease-out infinite; }
.wa-float svg { width: 30px; height: 30px; }
.wa-float:hover { transform: scale(1.1) rotate(-6deg); }
@keyframes waPulse { 0% { box-shadow: 0 0 0 0 rgba(37,211,102,.5), 0 10px 26px -8px rgba(37,211,102,.7); } 70%, 100% { box-shadow: 0 0 0 18px rgba(37,211,102,0), 0 10px 26px -8px rgba(37,211,102,.7); } }
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 500; transform: translate(-50%, 30px); background: var(--ink); color: #fff; padding: 14px 22px; font-size: 13px; font-weight: 600; opacity: 0; pointer-events: none; transition: opacity .4s, transform .5s var(--ease); max-width: 90vw; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.footer-bottom a:hover { color: #fff; }
@media (max-width: 900px) { .perks { grid-template-columns: 1fr 1fr; padding: 56px 14px 60px; } .faqs { padding: 10px 16px 70px; } .join { padding: 72px 20px; } }
@media (prefers-reduced-motion: reduce) { .wa-float { animation: none; } }
