/* ============================================================
   Charcutería La Reina - Estilo tienda (estilo "La Parisienne")
   Capa que se carga DESPUÉS de style.css solo en páginas públicas.
   NO afecta al panel de administración (POS).
   ============================================================ */

:root {
    --bg: #F2ECE9;
    --bg-card: #ffffff;
    --border: #E4D7CD;
    --text: #241c17;
    --text-light: #7A6F66;
    --primary: #AF0B14;
    --primary-dark: #8E0A10;
    --primary-light: #CD1B25;
    --secondary: #FBCD21;
    --secondary-dark: #A67C08;
    --secondary-soft: #F9E9BD;
    --shadow: 0 2px 10px rgba(120, 84, 40, 0.06);
    --radius: 18px;
    --radius-sm: 10px;
    --accent-bg: #ffffff;
    --accent-2: #FBCD21;
    --header-h: 118px;
}

body {
    background-color: var(--bg);
    color: var(--text);
}

/* Guardas: evitan desbordes horizontales y reinflado de texto en móviles */
html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

html,
body {
    overflow-x: hidden;
}

img,
video,
canvas,
svg {
    max-width: 100%;
    height: auto;
}

/* ============================================================
   Cabecera clara (logo | menú desplegable | carrito)
   ============================================================ */

.site-top {
    background: #fff;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 2px 14px rgba(120, 84, 40, 0.08);
}

.site-top::before {
    content: '';
    display: block;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary) 55%, var(--primary));
}

.site-top .header {
    background: #fff;
    border-bottom: none;
    box-shadow: none;
    padding: 0.75rem 0;
}

.logo__card {
    background: transparent;
    box-shadow: none;
    border: none;
    border-radius: 0;
    padding: 0;
    height: 44px;
}

.logo__texto {
    display: flex;
    flex-direction: column;
    line-height: 1.05;
    margin-left: 0.6rem;
}

.logo__texto strong {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.05rem;
    letter-spacing: 1px;
    color: var(--primary-dark);
    text-transform: uppercase;
}

.logo__texto small {
    font-size: 0.62rem;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    color: var(--secondary-dark);
}

.header__actions {
    gap: 0.7rem;
}

.btn-cart {
    background: var(--primary);
    border: none;
    color: #fff;
    border-radius: 999px;
    padding: 0.5rem 1.2rem;
    box-shadow: none;
    gap: 0.5rem;
    transition: background-color 0.25s ease, transform 0.12s ease;
}

.btn-cart:hover {
    background: var(--primary-light);
    color: #fff;
}

.btn-cart:active {
    transform: scale(0.97);
}

.btn-cart .badge {
    background: #fff;
    color: var(--primary);
    margin-left: 0.1rem;
}

.menu-toggler {
    border-color: var(--border);
    background: #fff;
}

.menu-toggler span {
    background: var(--primary-dark);
}

/* Menú superior */
.main-nav {
    background: #fff;
    border-bottom: 1px solid var(--border);
    box-shadow: none;
    position: relative;
    z-index: 110;
}

.main-nav__inner {
    justify-content: center;
    gap: 0.1rem;
    padding: 0.35rem 1rem;
    position: relative;
}

.main-nav .nav__link {
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    padding: 0.42rem 1.05rem;
    border-radius: 999px;
    white-space: nowrap;
}

.main-nav .nav__link:hover {
    background: rgba(175, 11, 20, 0.06);
    color: var(--primary);
}

.main-nav .nav__link.active {
    background: none;
    color: var(--primary);
    font-weight: 700;
    box-shadow: none;
    position: relative;
}

.main-nav .nav__link.active::after {
    content: '';
    position: absolute;
    left: 1.05rem;
    right: 1.05rem;
    bottom: 0.1rem;
    height: 2px;
    background: var(--secondary);
    border-radius: 2px;
}

/* --- Menú desplegable de categorías --- */

.nav-drop {
    position: relative;
}

.nav-drop__btn {
    border: none;
    background: none;
    font-family: inherit;
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    padding: 0.42rem 1.05rem;
    border-radius: 999px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.nav-drop__btn:hover,
.nav-drop.abierto .nav-drop__btn {
    background: rgba(175, 11, 20, 0.06);
    color: var(--primary);
}

.nav-drop__flecha {
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.nav-drop.abierto .nav-drop__flecha {
    transform: rotate(180deg);
}

.nav-drop__panel {
    display: none;
    position: fixed;
    top: 116px;
    left: 50%;
    transform: translateX(-50%);
    width: min(680px, 86vw);
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 18px 44px rgba(90, 60, 30, 0.16);
    padding: 1rem 1.1rem;
    z-index: 120;
}

.nav-drop:hover .nav-drop__panel,
.nav-drop.abierto .nav-drop__panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.15rem 1.1rem;
}

.nav-drop__titulo {
    grid-column: 1 / -1;
    font-size: 0.7rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--secondary-dark);
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.5rem;
    margin-bottom: 0.35rem;
}

.nav-drop__cat {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
    padding: 0.42rem 0.6rem;
    border-radius: 8px;
    color: var(--text);
    text-decoration: none;
    font-size: 0.88rem;
}

.nav-drop__cat:hover {
    background: rgba(175, 11, 20, 0.06);
    color: var(--primary);
}

.nav-drop__cat sub {
    font-size: 0.68rem;
    color: var(--text-light);
}

/* ============================================================
   Portada clara y elegante
   ============================================================ */

.hero {
    background: linear-gradient(135deg, #E4232F 0%, var(--primary) 45%, var(--primary-dark) 78%, #6B060C 100%);
    color: #F6EFE7;
    border-bottom: none;
}

.hero::before {
    display: none;
}

.hero__inner {
    padding: 3.2rem 1rem 3rem;
}

.hero__badge {
    background: var(--secondary);
    border: none;
    color: var(--primary-dark);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 0.35rem 1.1rem;
}

.hero__titulo,
.hero__titulo span {
    font-family: Georgia, 'Times New Roman', serif;
    color: #F6EFE7;
}

.hero__titulo span {
    color: var(--secondary);
}

.hero__texto {
    color: rgba(246, 239, 231, 0.92);
}

.hero__cta .btn--primary {
    background: var(--secondary);
    color: var(--primary-dark);
}

.hero__cta .btn--primary:hover,
.hero__cta .btn--primary:focus {
    background: #FCE55A;
    color: var(--primary-dark);
}

.hero__cta .btn--ghost {
    border-color: rgba(246, 239, 231, 0.55);
    color: #F6EFE7;
}

.hero__cta .btn--ghost:hover {
    background: rgba(246, 239, 231, 0.14);
    color: #fff;
}

.hero__stats span {
    background: rgba(246, 239, 231, 0.14);
    border: 1px solid rgba(246, 239, 231, 0.3);
    color: #F6EFE7;
}

.hero__logo img {
    border-radius: 16px;
    border: none;
    box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28), 0 0 0 3px rgba(246, 239, 231, 0.32);
}

/* ============================================================
   Botones tipo "pill" y campos
   ============================================================ */

.btn {
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.4px;
    padding: 0.7rem 1.5rem;
    box-shadow: none;
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.12s ease;
}

.btn--primary {
    background: var(--primary);
    border: none;
}

.btn--primary:hover,
.btn--primary:focus {
    background: var(--primary-light);
}

.btn--secondary {
    background: var(--secondary-soft);
    border: 1px solid var(--border);
    color: var(--primary-dark);
}

.btn--secondary:hover,
.btn--secondary:focus {
    background: #F4D98B;
    border-color: var(--secondary);
    color: var(--primary-dark);
}

.btn--ghost {
    background: transparent;
    border: 1.5px solid rgba(142, 10, 16, 0.55);
    color: var(--primary-dark);
}

.btn--ghost:hover,
.btn--ghost:focus {
    background: rgba(175, 11, 20, 0.08);
    color: var(--primary-dark);
}

.btn--large {
    padding: 0.85rem 1.7rem;
    font-size: 1.05rem;
}

.busqueda {
    margin-top: 2rem;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 999px;
    box-shadow: var(--shadow);
    padding: 0.45rem 0.45rem 0.45rem 1.2rem;
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.busqueda__input {
    border: none;
    background: transparent;
    font-size: 0.95rem;
    box-shadow: none !important;
    outline: none;
    min-width: 0;
}

.busqueda .btn {
    border-radius: 999px;
    padding: 0.55rem 1.4rem;
    white-space: nowrap;
}

/* ============================================================
   Secciones
   ============================================================ */

.seccion__encabezado h2 {
    font-family: Georgia, 'Times New Roman', serif;
    color: var(--primary-dark);
    font-size: 1.7rem;
    letter-spacing: 0.4px;
}

.seccion__encabezado h2::after {
    background: linear-gradient(90deg, var(--secondary), #F6E08A);
}

/* ============================================================
   Tarjetas de categorías
   ============================================================ */

.categorias-grid {
    gap: 1.1rem;
}

.categoria-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
}

.categoria-card:hover {
    box-shadow: 0 14px 30px rgba(110, 76, 36, 0.13);
    transform: translateY(-4px);
    border-color: var(--secondary);
}

/* Fondo neutro y cálido para todas las categorías */
body .categoria-card .categoria-card__img {
    background: linear-gradient(150deg, #f6ecd9, #efe0c6);
}

.categoria-card__body strong {
    font-family: Georgia, 'Times New Roman', serif;
    color: var(--primary-dark);
    font-weight: 600;
    letter-spacing: 0.8px;
}

.categoria-card__body small {
    color: var(--text-light);
    font-size: 0.8rem;
}

/* ============================================================
   Tarjetas de producto
   ============================================================ */

.productos-grid {
    gap: 1.1rem;
}

/* "Lo más vendido": única fila que se desplaza sola */
#destacadosGrid.productos-grid {
    display: block;
}

.mas-vendidos {
    overflow: hidden;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
}

.mas-vendidos__track {
    display: flex;
    width: max-content;
    animation: mas-vendidos-scroll 45s linear infinite;
}

.mas-vendidos__track .producto-card {
    flex: 0 0 auto;
    width: 250px;
    margin-right: 1rem;
}

.mas-vendidos:hover .mas-vendidos__track,
.mas-vendidos:focus-within .mas-vendidos__track {
    animation-play-state: paused;
}

@keyframes mas-vendidos-scroll {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-50%);
    }
}

@media (max-width: 640px) {
    .mas-vendidos__track .producto-card {
        width: 205px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .mas-vendidos__track {
        animation: none;
        flex-wrap: wrap;
        width: 100%;
    }

    .mas-vendidos__track .producto-card {
        width: calc(50% - 0.55rem);
        margin-right: 0;
    }
}

.producto-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: none;
    transition: box-shadow 0.25s, transform 0.25s;
}

.producto-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 16px 34px rgba(110, 76, 36, 0.14);
}

.producto-card__imagen {
    height: auto;
    aspect-ratio: 1 / 1.02;
    background: linear-gradient(150deg, #f6ecd9, #efe0c6);
    margin: 0.65rem 0.65rem 0;
    border-radius: 12px;
    overflow: hidden;
    font-size: 3.4rem;
}

.producto-card__foto {
    object-fit: cover;
    transition: transform 0.4s ease;
}

.producto-card:hover .producto-card__foto {
    transform: scale(1.05);
}

/* Badge "agotado" sobre la imagen */
.producto-card--agotado .producto-card__imagen::after {
    content: 'AGOTADO';
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(36, 28, 23, 0.55);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 2px;
}

.producto-card__body {
    padding: 0.85rem 1rem 1rem;
    gap: 0.3rem;
}

.producto-card__categoria {
    color: var(--secondary-dark);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 1.3px;
    text-transform: uppercase;
}

.producto-card__nombre {
    font-size: 1.02rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.3;
}

.producto-card__descripcion {
    font-size: 0.85rem;
    color: var(--text-light);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.producto-card__precio {
    color: var(--primary-dark);
    font-size: 1.25rem;
    font-weight: 800;
}

.producto-card__stock {
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.cantidad-control input {
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.4rem 0.6rem;
    width: 76px;
}

.cantidad-control .btn {
    flex: 1;
    padding: 0.5rem 1rem;
}

.cantidad-control .btn[disabled],
.producto-card .btn[disabled] {
    background: #eee6db;
    color: #b3a79a;
}

/* Selector de sabor/variedad en las tarjetas de producto */
.sabor-select {
    margin: 0.6rem 0;
}
.sabor-select__label {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted, #8a7a6a);
    margin-bottom: 0.3rem;
}
.sabor-select__campo {
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.5rem 0.65rem;
    background: #fff;
    color: var(--text);
}
.carrito-item__sabor,
.resumen-item__sabor,
.cart-drawer__sabor {
    color: var(--text-muted, #8a7a6a);
    font-weight: 400;
}

/* "Lo más vendido": tarjetas compactas */
#destacadosGrid .producto-card__imagen {
    aspect-ratio: 1 / 0.86;
    margin: 0.5rem 0.5rem 0;
    border-radius: 12px;
    height: auto;
}

#destacadosGrid .producto-card__body {
    padding: 0.6rem 0.7rem 0.8rem;
}

/* ============================================================
   Página de categoría: breadcrumb + layout con sidebar
   ============================================================ */

.breadcrumb {
    margin: 1.2rem 0 0;
    font-size: 0.8rem;
    color: var(--text-light);
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.breadcrumb a {
    color: var(--secondary-dark);
    text-decoration: none;
    font-weight: 600;
}

.breadcrumb a:hover {
    color: var(--primary);
}

.breadcrumb__sep {
    margin: 0 0.45rem;
    color: var(--border);
}

.categoria-volver {
    border-color: var(--border);
    color: var(--text-light);
    font-weight: 500;
}

.categoria-volver:hover {
    background: rgba(175, 11, 20, 0.06);
    color: var(--primary);
}

.cat-layout {
    display: grid;
    grid-template-columns: 220px 1fr;
    gap: 1.6rem;
    align-items: start;
    margin-top: 0.6rem;
}

.cat-main {
    min-width: 0;
}

.cat-layout > * {
    min-width: 0;
}

.cat-sidebar {
    min-width: 0;
    position: sticky;
    top: calc(var(--header-h) + 10px);
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.1rem 1rem;
}

.cat-sidebar__titulo {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--secondary-dark);
    border-bottom: 1px solid var(--border);
    padding-bottom: 0.6rem;
    margin-bottom: 0.6rem;
}

.cat-sidebar__nav {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.cat-sidebar__link {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.4rem;
    padding: 0.42rem 0.55rem;
    border-radius: 9px;
    text-decoration: none;
    color: var(--text);
    font-size: 0.88rem;
    border-left: 2px solid transparent;
}

.cat-sidebar__link:hover {
    background: rgba(175, 11, 20, 0.05);
    color: var(--primary);
}

.cat-sidebar__link.active {
    background: rgba(175, 11, 20, 0.07);
    color: var(--primary);
    font-weight: 600;
    border-left-color: var(--primary);
}

.cat-sidebar__link sub {
    font-size: 0.68rem;
    color: var(--text-light);
}

.categoria-apartado {
    background: linear-gradient(135deg, #fff 0%, #fbf4e8 100%);
    border: 1px solid var(--border);
    border-radius: 18px;
    padding: 1.5rem 1.6rem 1.1rem;
}

.categoria-apartado h2 {
    font-size: 1.8rem;
}

.categoria-portada {
    position: relative;
    max-width: 640px;
    margin: 1.1rem auto 0;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid var(--border);
    box-shadow: 0 10px 26px rgba(110, 76, 36, 0.16);
}

.categoria-portada img {
    display: block;
    width: 100%;
    height: 178px;
    object-fit: cover;
    border-radius: 0;
    border: none;
    box-shadow: none;
}

.subcategorias-chips {
    max-width: 100%;
}

.subcategorias-chips .pos-chip {
    border-radius: 999px;
    font-size: 0.78rem;
}

.subcategorias-chips .pos-chip.active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* ============================================================
   Carrito / checkout / pedido
   ============================================================ */

.carrito-header,
.checkout-header,
.pedido-header {
    padding: 1.6rem 0 0.8rem;
}

.carrito-header h2,
.checkout-header h2,
.pedido-header h2 {
    font-family: Georgia, 'Times New Roman', serif;
    color: var(--primary-dark);
    font-size: 1.7rem;
}

.carrito-vacio,
.carrito-item,
.resumen,
.checkout-form,
.pedido-tarjeta {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.resumen {
    position: sticky;
    top: calc(var(--header-h) + 10px);
}

.resumen h3 {
    color: var(--primary-dark);
}

.resumen__linea,
.resumen__total {
    color: var(--text);
}

.resumen__total {
    color: var(--primary-dark);
}

.resumen hr {
    border-top-color: var(--border);
}

.checkout-form h3,
.checkout-form h3:first-child {
    color: var(--primary-dark);
}

.form-group input,
.form-group select,
.form-group textarea {
    border-color: var(--border);
    border-radius: 12px;
    background: #fdfaf6;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline-color: var(--secondary);
    border-color: transparent;
    background: #fff;
}

.radio-linea {
    border-color: var(--border);
    border-radius: 14px;
}

.pedido-consulta__form .busqueda__input {
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.6rem 1.1rem;
    background: #fff;
}

/* ============================================================
   Carrito flotante (drawer) — estilo premium
   ============================================================ */

/* En el botón del carrito solo icono + contador, sin la palabra */
.btn-cart__label {
    display: none;
}

.cart-drawer {
    background: var(--bg);
}

.cart-drawer__header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    padding: 1.15rem 1.2rem;
}

.cart-drawer__titulo-box {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.cart-drawer__titulo {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.25rem;
    letter-spacing: 0.5px;
    margin: 0;
}

.cart-drawer__count {
    background: rgba(255, 255, 255, 0.16);
    border: 1px solid rgba(255, 255, 255, 0.35);
    color: #fff;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 0.22rem 0.7rem;
    border-radius: 999px;
    white-space: nowrap;
}

.cart-drawer__cerrar {
    background: #fff;
    color: var(--primary-dark);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.18);
}

.cart-drawer__cerrar:hover {
    background: var(--secondary);
    color: #fff;
}

.cart-drawer__items {
    padding: 1rem 1.1rem;
    gap: 0.85rem;
}

.cart-drawer__item {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 0.7rem;
    box-shadow: var(--shadow);
}

.cart-drawer__foto {
    flex: 0 0 62px;
    width: 62px;
    height: 62px;
    border-radius: 12px;
    overflow: hidden;
    background: #f3e8db url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b8903e' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3h2l2.4 12.2a2 2 0 0 0 2 1.8h7.7a2 2 0 0 0 2-1.6L21 7H6'/%3E%3Ccircle cx='9' cy='20' r='1.4'/%3E%3Ccircle cx='18' cy='20' r='1.4'/%3E%3C/svg%3E") no-repeat center;
    background-size: 26px 26px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-drawer__foto img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.cart-drawer__cuerpo {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
}

.cart-drawer__cabecera {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.5rem;
}

.cart-drawer__nombre {
    font-size: 0.94rem;
    line-height: 1.3;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.cart-drawer__precio-und {
    display: block;
    color: var(--text-light);
    font-size: 0.78rem;
    margin-top: 0.15rem;
}

.cart-drawer__fila-control {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.6rem;
    margin-top: 0.6rem;
}

.cart-drawer__item .cantidad-input button {
    width: 30px;
    height: 30px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: #fff;
    color: var(--primary);
    font-size: 1.05rem;
}

.cart-drawer__item .cantidad-input button:hover {
    background: var(--primary);
    color: #fff;
}

.cart-drawer__item .cantidad-input input {
    width: 46px;
    padding: 0.32rem;
    border-radius: 999px;
    background: #fff;
    font-weight: 600;
    color: var(--text);
}

.cart-drawer__quitar {
    background: none;
    border: none;
    color: #b9a78f;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
    flex: 0 0 auto;
    padding: 0;
    transition: background-color 0.2s, color 0.2s;
}

.cart-drawer__quitar:hover {
    color: var(--primary);
    background: rgba(175, 11, 20, 0.08);
}

.cart-drawer__subtotal {
    background: rgba(251, 205, 33, 0.18);
    color: var(--primary-dark);
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.32rem 0.75rem;
    border-radius: 999px;
    white-space: nowrap;
}

.cart-drawer__vacio {
    color: var(--text-light);
    font-size: 0.92rem;
    line-height: 1.6;
    padding: 1.4rem 1rem;
    background: #fff;
    border: 1px dashed var(--border);
    border-radius: 16px;
    font-weight: 600;
}

.cart-drawer__footer {
    border-top: 1px solid var(--border);
    background: #fff;
    padding: 1rem 1.1rem 1.15rem;
    box-shadow: 0 -6px 18px rgba(120, 84, 40, 0.05);
}

.cart-drawer__linea {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 0.9rem;
    color: var(--text-light);
    padding: 0.18rem 0;
}

.cart-drawer__linea span:last-child {
    font-weight: 600;
    color: var(--text);
}

.cart-drawer__total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin: 0.6rem 0 0.95rem;
    padding: 0.75rem 0.95rem;
    background: linear-gradient(135deg, #F7EBD3, #EEDBC0);
    border: 1px solid var(--border);
    border-radius: 14px;
}

.cart-drawer__total span:first-child {
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    font-size: 0.76rem;
    color: var(--primary-dark);
}

.cart-drawer__total #cartDrawerTotal {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1.55rem;
    font-weight: 700;
    color: var(--primary);
    white-space: nowrap;
}

/* ============================================================
   Footer
   ============================================================ */

.footer {
    background: linear-gradient(120deg, #1d1611, #2b211a 60%, #1d1611);
    color: rgba(255, 255, 255, 0.78);
}

.footer__col h4 {
    color: var(--secondary);
}

.footer__logo {
    background: transparent;
    border-radius: 0;
    padding: 0;
}

/* ============================================================
   Adaptable
   ============================================================ */

@media (max-width: 1000px) {
    .main-nav .nav__link,
    .nav-drop__btn {
        padding: 0.42rem 0.7rem;
        font-size: 0.72rem;
        letter-spacing: 1px;
    }

    .cat-layout {
        grid-template-columns: 1fr;
    }

    .cat-sidebar {
        position: static;
    }

    .cat-sidebar__nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.3rem 0.6rem;
    }

    .cat-sidebar__link {
        border-left: none;
        border-bottom: 2px solid transparent;
    }

    .cat-sidebar__link.active {
        border-bottom-color: var(--primary);
    }
}

/* Header y portada compactos (teléfonos y tablets) */
@media (max-width: 900px) {
    .site-top .header {
        padding: 0.4rem 0;
    }

    .header__inner {
        flex-direction: row;
        flex-wrap: nowrap;
        gap: 0.35rem;
        padding: 0;
    }

    .logo__card {
        height: 38px;
        padding: 0;
        border-radius: 0;
    }

    .logo__img {
        height: 30px;
    }

    .logo__texto small {
        display: none;
    }

    .logo__texto strong {
        font-size: 0.82rem;
    }

    .btn-cart {
        padding: 0.4rem 0.75rem;
        font-size: 0.8rem;
        gap: 0.35rem;
    }

    .hero__inner {
        padding: 1.6rem 1rem 1.9rem;
    }

    .hero__logo img {
        width: 110px;
        border-radius: 12px;
    }

    .hero__badge {
        font-size: 0.66rem;
    }

    .hero__titulo,
    .hero__titulo span {
        font-size: 1.9rem;
    }

    .hero__texto {
        font-size: 0.95rem;
    }

    /* ----- Contenido compacto para pantallas medianas y móviles ----- */

    .seccion {
        padding: 1.8rem 0 0.5rem;
    }

    .seccion__encabezado {
        margin-bottom: 1rem;
    }

    .seccion__encabezado h2 {
        font-size: 1.4rem;
    }

    .breadcrumb {
        margin-top: 0.9rem;
        font-size: 0.74rem;
    }

    .productos-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.8rem;
    }

    #destacadosGrid.productos-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.7rem;
    }

    .producto-card__nombre {
        font-size: 0.94rem;
    }

    .producto-card__precio {
        font-size: 1.12rem;
    }

    .producto-card__imagen {
        margin: 0.55rem 0.55rem 0;
        border-radius: 10px;
        height: auto;
    }

    #destacadosGrid .producto-card__imagen {
        margin: 0.45rem 0.45rem 0;
    }

    .cantidad-control .btn {
        font-size: 0;
    }

    .cantidad-control .btn::before {
        content: 'Añadir';
        font-size: 0.8rem;
        font-weight: 600;
    }

    .cantidad-control .btn:disabled::before {
        content: 'Agotado';
    }

    .categoria-apartado {
        padding: 1.25rem 1.2rem 0.7rem;
        border-radius: 15px;
    }

    .categoria-apartado h2 {
        font-size: 1.5rem;
    }

    .categoria-volver {
        font-size: 0.8rem;
        padding: 0.28rem 0.7rem;
    }

    .categoria-portada {
        border-radius: 14px;
    }

    .categoria-portada img {
        height: 150px;
    }

    /* Sidebar de categorías: fila con scroll horizontal */
    .cat-sidebar {
        position: static;
    }

    .cat-sidebar__nav {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 0.3rem 0.5rem;
    }

    .cat-sidebar__link {
        padding: 0.34rem 0.7rem;
        font-size: 0.82rem;
        white-space: nowrap;
        border-left: none;
        border-bottom: 2px solid transparent;
        border-radius: 999px;
    }

    .cat-sidebar__link.active {
        border-bottom-color: var(--primary);
        background: rgba(175, 11, 20, 0.07);
    }

    .pasos {
        gap: 0.9rem;
    }

    .pago-banner {
        padding: 1.3rem 1.2rem;
    }

    .footer__grid {
        gap: 1.3rem;
        padding: 1.8rem 1rem 1.2rem;
    }
}

/* Menú superior convertible en cajón lateral (móvil y tablets) */
@media (max-width: 980px) {
    .menu-toggler {
        display: flex;
    }

    .main-nav {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: min(320px, 84vw);
        background: #fff;
        border-left: 1px solid var(--border);
        z-index: 950;
        transform: translateX(110%);
        transition: transform 0.3s ease;
        box-shadow: -6px 0 24px rgba(0, 0, 0, 0.18);
    }

    .main-nav.abierto {
        transform: translateX(0);
    }

    .main-nav .main-nav__inner {
        flex-direction: column;
        align-items: stretch;
        gap: 0.15rem;
        background: #fff;
        padding: 1.4rem 1rem;
        overflow-y: auto;
        overflow-x: hidden;
        justify-content: flex-start;
    }

    .main-nav .nav__link,
    .nav-drop__btn {
        color: var(--text);
        background: #fff;
        font-size: 1rem;
        padding: 0.8rem 1rem;
        border-radius: 10px;
        text-align: left;
        letter-spacing: 0.8px;
    }

    .main-nav .nav__link:hover,
    .nav-drop__btn:hover {
        color: var(--primary);
        background: #F2ECE9;
    }

    .main-nav .nav__link.active {
        color: var(--primary);
        background: #fff;
    }

    .main-nav .nav__link.active::after {
        display: none;
    }

    .nav-drop__panel,
    .nav-drop:hover .nav-drop__panel,
    .nav-drop.abierto .nav-drop__panel {
        position: absolute;
        top: 100%;
        left: 1rem;
        right: 1rem;
        transform: none;
        display: none;
        width: auto;
        grid-template-columns: 1fr;
        box-shadow: 0 12px 28px rgba(70, 40, 15, 0.18);
        border: 1px solid var(--border);
        border-radius: 12px;
        background: #fff;
        padding: 0.8rem 0.9rem;
        z-index: 80;
    }

    .nav-drop.abierto .nav-drop__panel {
        display: grid;
    }

    .nav-drop__titulo {
        color: var(--secondary-dark);
    }

    .nav__link--pedido {
        border-top: 1px solid var(--border);
        border-radius: 0 !important;
        margin-top: 0.6rem;
    }
}

@media (max-width: 640px) {
    :root {
        --header-h: 100px;
    }

    section[id] {
        scroll-margin-top: 100px;
    }

    /* Header compacto en una sola fila */
    .header__inner {
        flex-direction: row;
        gap: 0.4rem;
        padding: 0.45rem 0 0.35rem;
    }

    .header__inner > .logo,
    .header__inner > .header__actions {
        align-self: auto;
        justify-content: space-between;
        display: flex;
        align-items: center;
    }

    .logo__card {
        height: 38px;
        padding: 0;
        border-radius: 0;
    }

    .logo__img {
        height: 30px;
    }

    .logo__texto {
        margin-left: 0.45rem;
    }

    .logo__texto strong {
        font-size: 0.82rem;
    }

    .logo__texto small {
        display: none;
    }

    .btn-cart {
        padding: 0.38rem 0.7rem;
        font-size: 0.78rem;
        gap: 0.35rem;
    }

    .btn-cart__icon {
        width: 16px;
        height: 16px;
    }

    .menu-toggler {
        width: 36px;
        height: 36px;
    }

    /* Portada compacta */
    .hero__inner {
        padding: 1.3rem 1rem 1.6rem;
    }

    .hero__logo img {
        width: 88px;
        border-radius: 10px;
    }

    .hero__badge {
        font-size: 0.6rem;
        padding: 0.22rem 0.7rem;
        letter-spacing: 1.4px;
        margin-bottom: 0.65rem;
    }

    .hero__titulo,
    .hero__titulo span {
        font-size: 1.6rem;
    }

    .hero__texto {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }

    .hero__cta {
        gap: 0.45rem;
    }

    .hero__cta .btn--lg {
        flex: 1;
        width: auto;
        padding: 0.6rem 0.5rem;
        font-size: 0.86rem;
    }

    .hero__stats {
        gap: 0.4rem;
        margin-top: 1rem;
    }

    .hero__stats span {
        font-size: 0.7rem;
        padding: 0.24rem 0.75rem;
    }

    /* Secciones y búsqueda compactas */
    .seccion {
        padding: 1.4rem 0 0.4rem;
    }

    .seccion__encabezado {
        margin-bottom: 0.9rem;
    }

    .seccion__encabezado h2 {
        font-size: 1.28rem;
    }

    .seccion__encabezado p {
        font-size: 0.84rem;
        margin-top: 0.25rem;
    }

    .busqueda {
        margin-top: 1.1rem;
        padding: 0.4rem;
        border-radius: 16px;
        flex-wrap: wrap;
    }

    .busqueda__input {
        flex-basis: 100%;
        min-width: 0;
        font-size: 0.88rem;
        padding: 0.35rem 0.6rem;
    }

    .busqueda .btn {
        flex: 1;
        padding: 0.5rem 0.6rem;
        font-size: 0.85rem;
    }

    /* Grid y tarjetas de producto compactas */
    .productos-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.7rem;
    }

    .producto-card {
        border-radius: 14px;
    }

    .producto-card__imagen {
        margin: 0.45rem 0.45rem 0;
        border-radius: 9px;
        aspect-ratio: 1 / 1.05;
    }

    .producto-card__body {
        padding: 0.55rem 0.6rem 0.75rem;
        gap: 0.22rem;
    }

    .producto-card__categoria {
        font-size: 0.6rem;
        letter-spacing: 0.9px;
    }

    .producto-card__nombre {
        font-size: 0.86rem;
        line-height: 1.25;
    }

    .producto-card__precio {
        font-size: 1.05rem;
    }

    .producto-card__footer {
        margin-top: 0.35rem;
    }

    .cantidad-control {
        flex-direction: row;
        align-items: center;
        margin-top: 0.4rem;
    }

    .cantidad-control input {
        width: 58px;
        padding: 0.35rem 0.3rem;
        font-size: 0.85rem;
        border-radius: 999px;
    }

    .cantidad-control .btn {
        flex: 1;
        padding: 0.45rem 0.5rem;
        font-size: 0;
    }

    .cantidad-control .btn::before {
        content: 'Añadir';
        font-size: 0.76rem;
        font-weight: 600;
    }

    .cantidad-control .btn:disabled::before {
        content: 'Agotado';
    }

    /* Destacados: tarjetas compactas */
    #destacadosGrid.productos-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.55rem;
    }

    #destacadosGrid .producto-card__imagen {
        margin: 0.4rem 0.4rem 0;
    }

    #destacadosGrid .producto-card__body {
        padding: 0.5rem 0.55rem 0.65rem;
    }

    .producto-card--agotado .producto-card__imagen::after {
        font-size: 0.65rem;
        letter-spacing: 1.5px;
    }

    /* Página de categoría */
    .breadcrumb {
        margin-top: 0.8rem;
        font-size: 0.68rem;
    }

    .breadcrumb__sep {
        margin: 0 0.3rem;
    }

    .cat-layout {
        gap: 0.9rem;
        margin-top: 0.4rem;
    }

    .cat-sidebar {
        padding: 0.7rem 0.7rem 0.55rem;
        border-radius: 12px;
    }

    .cat-sidebar__titulo {
        font-size: 0.6rem;
        padding-bottom: 0.4rem;
        margin-bottom: 0.45rem;
    }

    .cat-sidebar__nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        gap: 0.25rem;
        padding-bottom: 0.25rem;
        scrollbar-width: none;
    }

    .cat-sidebar__nav::-webkit-scrollbar {
        display: none;
    }

    .cat-sidebar__link {
        padding: 0.28rem 0.6rem;
        font-size: 0.76rem;
        white-space: nowrap;
        border-left: none;
        border-bottom: 2px solid transparent;
        border-radius: 999px;
    }

    .cat-sidebar__link.active {
        border-bottom-color: var(--primary);
        background: rgba(175, 11, 20, 0.07);
    }

    .cat-sidebar__link sub {
        display: none;
    }

    .categoria-apartado {
        padding: 0.95rem 0.9rem 0.5rem;
        border-radius: 14px;
    }

    .categoria-apartado h2 {
        font-size: 1.35rem;
        margin-top: 0.15rem;
    }

    .categoria-volver {
        font-size: 0.75rem;
        padding: 0.22rem 0.6rem;
        margin-bottom: 0.5rem;
    }

    .categoria-portada {
        border-radius: 12px;
        margin-top: 0.85rem;
    }

    .categoria-portada img {
        height: 120px;
    }

    .subcategorias-chips {
        gap: 0.3rem;
        margin-bottom: 0.75rem;
    }

    .subcategorias-chips .pos-chip {
        font-size: 0.72rem;
        padding: 0.22rem 0.55rem;
    }

    /* Cómo pedir y pago */
    .pasos {
        gap: 0.75rem;
    }

    .paso {
        padding: 1.1rem 1rem;
    }

    .pago-banner {
        flex-direction: column;
        text-align: center;
        padding: 1.1rem 1rem;
        border-radius: 14px;
    }

    .resumen,
    .checkout-form {
        border-radius: 14px;
        padding: 1rem;
    }

    .resumen {
        position: static;
    }

    .footer__grid {
        gap: 1.1rem;
        padding: 1.6rem 1rem 1.1rem;
    }
}

@media (max-width: 480px) {
    .btn-cart__label {
        display: none;
    }

    .productos-grid {
        gap: 0.55rem;
    }

    .producto-card__imagen {
        margin: 0.4rem 0.4rem 0;
    }

    .producto-card__body {
        padding: 0.5rem 0.55rem 0.65rem;
    }

    .cantidad-control {
        gap: 0.25rem;
    }

    .cantidad-control input {
        width: 52px;
    }

    .hero__titulo,
    .hero__titulo span {
        font-size: 1.45rem;
    }
}