/* =========================================================
   COLORES DE LA MARCA (sacados del logo)
   ========================================================= */
:root {
  --rojo: #8b1a1a;
  --rojo-oscuro: #5c0f0f;
  --rojo-claro: #b3261e;
  --oro: #d9a84e;
  --crema: #f7efe3;
  --negro: #151010;
  --gris: #6b5f5a;
  --blanco: #ffffff;
  --verde-wa: #25d366;
  --radio: 14px;
  --sombra: 0 10px 30px rgba(40, 10, 10, .12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { font-family: "Inter", system-ui, sans-serif; color: var(--negro); background: var(--crema); line-height: 1.55; }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: "Cinzel", Georgia, serif; line-height: 1.2; }
.container { width: min(1180px, 100% - 32px); margin-inline: auto; }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 24px; border-radius: 999px; border: 2px solid transparent; font: 600 15px "Inter", sans-serif; cursor: pointer; text-decoration: none; transition: transform .15s, background .2s; }
.btn:hover { transform: translateY(-2px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn--primary { background: var(--rojo); color: var(--blanco); }
.btn--primary:hover { background: var(--rojo-claro); }
.btn--ghost { border-color: var(--oro); color: var(--oro); }
.btn--whatsapp { background: var(--verde-wa); color: #fff; }
.btn--sm { padding: 8px 16px; font-size: 14px; }
.btn--block { width: 100%; }

/* ---------- Topbar y cabecera ---------- */
.topbar { background: var(--negro); color: var(--oro); text-align: center; font-size: 13px; padding: 8px 16px; }
.header { position: sticky; top: 0; z-index: 50; background: var(--rojo-oscuro); color: var(--blanco); box-shadow: 0 2px 12px rgba(0,0,0,.25); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 0; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand__logo { height: 52px; width: auto; }
.brand__name { display: block; font-family: "Cinzel", serif; font-weight: 800; font-size: 18px; color: var(--oro); }
.brand__sub { display: block; font-size: 12px; opacity: .85; letter-spacing: .08em; text-transform: uppercase; }
.nav { display: flex; gap: 26px; }
.nav a { text-decoration: none; font-weight: 500; opacity: .9; }
.nav a:hover { color: var(--oro); }
.header__actions { display: flex; gap: 10px; }
.cart-btn, .menu-btn { position: relative; background: rgba(255,255,255,.1); border: 0; color: #fff; font-size: 20px; width: 46px; height: 46px; border-radius: 50%; cursor: pointer; }
.account-btn { display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,.1); border: 0; color: #fff; height: 46px; padding: 0 16px 0 12px; border-radius: 999px; cursor: pointer; font: 600 14px "Inter", sans-serif; }
.account-btn:hover { background: rgba(255,255,255,.18); }
.account-btn svg { width: 22px; height: 22px; fill: #fff; flex-shrink: 0; }
.cart-btn__count { position: absolute; top: -4px; right: -4px; background: var(--oro); color: var(--negro); font-size: 12px; font-weight: 700; min-width: 20px; height: 20px; border-radius: 10px; display: grid; place-items: center; }
.menu-btn { display: none; }

/* ---------- Hero ---------- */
.hero { background: radial-gradient(circle at 75% 40%, #7a1d1d 0%, var(--rojo-oscuro) 40%, var(--negro) 100%); color: var(--blanco); padding: 80px 0; overflow: hidden; }
.hero__inner { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; }
.badge { display: inline-block; border: 1px solid var(--oro); color: var(--oro); padding: 6px 14px; border-radius: 999px; font-size: 13px; margin-bottom: 18px; }
.hero h1 { font-size: clamp(32px, 5vw, 54px); margin-bottom: 18px; }
.hero h1 span { color: var(--oro); }
.hero p { font-size: 18px; opacity: .9; max-width: 560px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin: 30px 0 40px; }
.hero__stats { display: flex; flex-wrap: wrap; gap: 36px; list-style: none; }
.hero__stats strong { display: block; font-size: 26px; color: var(--oro); font-family: "Cinzel", serif; }
.hero__stats span { font-size: 13px; opacity: .8; }
.hero__logo img { width: 100%; max-width: 380px; margin-inline: auto; }

/* ---------- Ventajas ---------- */
.features { background: var(--blanco); padding: 40px 0; }
.features__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.feature { text-align: center; }
.feature span { font-size: 34px; }
.feature h3 { font-size: 17px; margin: 8px 0 4px; color: var(--rojo); }
.feature p { font-size: 14px; color: var(--gris); }

/* ---------- Secciones ---------- */
.section { padding: 80px 0; }
.section--dark { background: var(--negro); color: var(--blanco); }
.section--alt { background: var(--blanco); }
.section__head { text-align: center; margin-bottom: 40px; }
.section__head h2 { font-size: clamp(28px, 4vw, 40px); color: var(--rojo); }
.section--dark .section__head h2 { color: var(--oro); }
.section__head p { color: var(--gris); margin-top: 8px; }
.section--dark .section__head p { color: #cbbfb8; }

/* ---------- Filtros ---------- */
.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-bottom: 32px; }
.chip { border: 2px solid var(--rojo); background: transparent; color: var(--rojo); padding: 8px 18px; border-radius: 999px; font: 600 14px "Inter", sans-serif; cursor: pointer; }
.chip.is-active, .chip:hover { background: var(--rojo); color: #fff; }

/* ---------- Productos ---------- */
.products { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }
.product { background: var(--blanco); color: var(--negro); border-radius: var(--radio); overflow: hidden; box-shadow: var(--sombra); display: flex; flex-direction: column; transition: transform .2s; }
.product:hover { transform: translateY(-4px); }
.product__media { position: relative; aspect-ratio: 4/3; background: linear-gradient(135deg, #fbe9e2, #f1cfc3); display: grid; place-items: center; }
.product__media img { width: 100%; height: 100%; object-fit: cover; }
.product__emoji { font-size: 72px; }
.tag { position: absolute; top: 12px; left: 12px; background: var(--rojo); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 6px; text-transform: uppercase; }
.product__body { padding: 18px; display: flex; flex-direction: column; flex: 1; }
.product__cat { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--rojo-claro); font-weight: 600; }
.product h3 { font-family: "Inter", sans-serif; font-size: 18px; margin: 4px 0 6px; }
.product p { font-size: 14px; color: var(--gris); flex: 1; }
.product__foot { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; gap: 10px; }
.price s { color: var(--gris); font-size: 13px; margin-right: 6px; }
.price strong { font-size: 22px; color: var(--rojo); }
.price small { color: var(--gris); }

/* ---------- Nosotros ---------- */
.about { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: start; }
.about h2 { font-size: 34px; color: var(--rojo); margin-bottom: 18px; }
.about p { margin-bottom: 14px; }
.reviews { background: var(--negro); color: #fff; padding: 30px; border-radius: var(--radio); }
.reviews h3 { color: var(--oro); margin-bottom: 18px; }
.reviews blockquote { border-left: 3px solid var(--oro); padding: 4px 0 4px 16px; margin-bottom: 18px; font-style: italic; }
.reviews blockquote span { display: block; color: var(--oro); font-style: normal; margin-top: 4px; }

/* ---------- Contacto ---------- */
.contact { display: grid; grid-template-columns: 1fr 1.2fr; gap: 40px; align-items: center; }
.contact h2 { font-size: 32px; color: var(--rojo); margin-bottom: 20px; }
.contact__list { list-style: none; display: grid; gap: 14px; font-size: 17px; }
.contact__list a { color: var(--rojo); font-weight: 600; }
.contact__hours { display: flex; align-items: flex-start; gap: 10px; }
.contact__hours strong { display: block; margin-bottom: 6px; }
.hours-list { list-style: none; display: grid; gap: 4px; font-size: 14px; }
.hours-list li { display: flex; justify-content: space-between; gap: 24px; min-width: 240px; color: var(--gris); }
.hours-list li span:first-child { color: var(--negro); font-weight: 600; }
.hours-list .is-closed { color: var(--rojo-claro); font-weight: 600; }
.contact__map { width: 100%; height: 340px; border: 0; border-radius: var(--radio); box-shadow: var(--sombra); }

/* ---------- Pie ---------- */
.footer { background: var(--negro); color: #bdb1aa; padding: 28px 0; font-size: 14px; }
.footer__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; }

/* ---------- Carrito ---------- */
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); opacity: 0; pointer-events: none; transition: .25s; z-index: 90; }
.cart { position: fixed; top: 0; right: 0; height: 100%; width: min(420px, 100%); background: var(--blanco); z-index: 100; display: flex; flex-direction: column; transform: translateX(100%); transition: transform .3s; }
.overlay.is-open { opacity: 1; pointer-events: auto; }
.cart.is-open { transform: none; }
.cart__head { display: flex; justify-content: space-between; align-items: center; padding: 20px; border-bottom: 1px solid #eee; }
.cart__head h3 { color: var(--rojo); }
.icon-btn { background: none; border: 0; font-size: 20px; cursor: pointer; }
.cart__items { flex: 1; overflow-y: auto; padding: 10px 20px; }
.cart-item { display: flex; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid #f1e8e3; }
.cart-item__emoji { font-size: 34px; }
.cart-item__info { flex: 1; }
.cart-item__info small { display: block; color: var(--gris); }
.qty { display: inline-flex; align-items: center; gap: 10px; margin-top: 6px; }
.qty button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--rojo); background: #fff; color: var(--rojo); cursor: pointer; font-size: 16px; }
.empty { text-align: center; color: var(--gris); padding: 60px 0; }
.cart__foot { padding: 20px; border-top: 1px solid #eee; display: grid; gap: 8px; }
.row { display: flex; justify-content: space-between; gap: 10px; }
.row--total { font-size: 18px; border-top: 1px solid #eee; padding-top: 10px; margin-bottom: 8px; }
.cart__hint { font-size: 13px; color: var(--rojo-claro); text-align: center; }

/* ---------- Mi cuenta ---------- */
.auth-tabs { display: flex; gap: 8px; margin-bottom: 18px; }
.auth-tab { flex: 1; padding: 10px; border: 2px solid var(--rojo); background: transparent; color: var(--rojo); border-radius: 999px; font: 600 14px "Inter", sans-serif; cursor: pointer; }
.auth-tab.is-active { background: var(--rojo); color: #fff; }
.account-form { display: grid; gap: 12px; }
.account-form label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; color: var(--gris); }
.form-error { color: var(--rojo-claro); font-size: 13px; min-height: 16px; }
.account-hello { display: flex; align-items: center; justify-content: space-between; padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid #eee; }
.account-subtitle { color: var(--rojo); margin-bottom: 12px; }
.admin-link { display: block; text-align: center; background: var(--negro); color: var(--oro); text-decoration: none; font-weight: 700; padding: 12px; border-radius: 10px; margin-bottom: 20px; }
.admin-link:hover { opacity: .9; }
.account-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 20px; }
.account-summary div { background: var(--crema); border-radius: 10px; padding: 12px; text-align: center; }
.account-summary span { display: block; font-size: 12px; color: var(--gris); margin-bottom: 4px; }
.account-summary strong { font-family: "Cinzel", serif; font-size: 19px; color: var(--rojo); }
.account-datos { border: 1px solid #eee; border-radius: 10px; padding: 4px 14px; margin-bottom: 20px; }
.account-datos summary { cursor: pointer; font-weight: 700; color: var(--rojo); padding: 10px 0; }
.account-datos .account-form { padding-bottom: 14px; }
.account-datos input:disabled { background: #f5f1ee; color: var(--gris); }
.pedido-card { border: 1px solid #eee; border-radius: 10px; padding: 14px; margin-bottom: 12px; }
.pedido-card__head { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--gris); margin-bottom: 8px; }
.pedido-estado { font-weight: 700; padding: 2px 10px; border-radius: 999px; font-size: 12px; }
.pedido-estado--pendiente { background: #fdf0d5; color: #a15c00; }
.pedido-estado--confirmado { background: #dcedea; color: #147a6a; }
.pedido-estado--entregado { background: #e1f0d8; color: #3f7d20; }
.pedido-estado--cancelado { background: #fbdede; color: var(--rojo); }
.pedido-card__items { list-style: none; font-size: 14px; display: grid; gap: 2px; margin-bottom: 8px; }
.pedido-card__total { display: flex; justify-content: space-between; font-size: 14px; border-top: 1px solid #f1e8e3; padding-top: 8px; }

/* ---------- Checkout ---------- */
.modal { position: fixed; inset: 0; z-index: 110; display: grid; place-items: center; padding: 16px; pointer-events: none; opacity: 0; transition: .25s; }
.modal.is-open { opacity: 1; pointer-events: auto; }
.modal__box { background: #fff; width: min(620px, 100%); max-height: 92vh; overflow-y: auto; border-radius: var(--radio); padding-bottom: 20px; display: grid; gap: 14px; }
.modal__box > *:not(.cart__head) { margin-inline: 20px; }
.modal__box .btn--block { width: auto; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid label { display: grid; gap: 4px; font-size: 13px; font-weight: 600; color: var(--gris); }
.form-grid .full { grid-column: 1 / -1; }
input, select, textarea { font: 15px "Inter", sans-serif; padding: 10px 12px; border: 1px solid #ddd; border-radius: 8px; width: 100%; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--oro); border-color: transparent; }
.checkout__summary { background: var(--crema); border-radius: 10px; padding: 14px; display: grid; gap: 6px; font-size: 14px; }
.check { display: flex; gap: 8px; align-items: center; font-size: 13px; }
.check input { width: auto; }

/* ---------- Aviso ---------- */
.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 100px); background: var(--negro); color: #fff; padding: 12px 22px; border-radius: 999px; z-index: 200; transition: transform .3s; font-size: 14px; max-width: calc(100% - 32px); text-align: center; }
.toast.is-open { transform: translate(-50%, 0); }

/* ---------- Volver arriba ---------- */
.back-to-top { position: fixed; right: 24px; bottom: 24px; width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--rojo); color: #fff; font-size: 22px; cursor: pointer; box-shadow: var(--sombra); opacity: 0; pointer-events: none; transform: translateY(10px); transition: opacity .25s, transform .25s, background .2s; z-index: 80; }
.back-to-top.is-visible { opacity: 1; pointer-events: auto; transform: none; }
.back-to-top:hover { background: var(--rojo-claro); }

/* ---------- Móvil ---------- */
@media (max-width: 860px) {
  .menu-btn { display: block; }
  .nav { position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--rojo-oscuro); max-height: 0; overflow: hidden; transition: max-height .3s; }
  .nav.is-open { max-height: 320px; }
  .nav a { padding: 14px 16px; border-top: 1px solid rgba(255,255,255,.1); }
  .hero { padding: 50px 0; }
  .hero__inner, .about, .contact { grid-template-columns: 1fr; }
  .hero__logo { order: -1; }
  .hero__logo img { max-width: 200px; }
  .features__grid { grid-template-columns: repeat(2, 1fr); }
  .brand__name { font-size: 15px; }
  .account-btn { width: 46px; padding: 0; justify-content: center; }
  .account-btn span { display: none; }
}
@media (max-width: 480px) {
  .form-grid { grid-template-columns: 1fr; }
  .hero__stats { gap: 20px; }
}
