/**
 * Sweet Dripping — Catálogo público (frontend 2026)
 * Identidad visual única (Fase Identidad): negro / blanco / cyan.
 * Tokens = fuente de verdad. No inventar colores, radios ni tipografías sueltas.
 */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=Syne:wght@600;700;800&display=swap');

:root {
    /* Paleta */
    --bg: #050505;
    --bg-elevated: #0c0c0c;
    --bg-card: #101010;
    --text: #f4f4f4;
    --text-muted: rgba(244, 244, 244, 0.68);
    --soft-white: #cfcfcf;
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --cyan: #2ee6ff;
    --cyan-dim: rgba(46, 230, 255, 0.16);
    --cyan-glow: rgba(46, 230, 255, 0.35);
    /* Forma */
    --radius: 14px;
    --radius-sm: 10px;
    --shadow-card: 0 18px 40px rgba(0, 0, 0, 0.45);
    /* Tipo */
    --font-display: 'Syne', sans-serif;
    --font-body: 'DM Sans', sans-serif;
    /* Motion / foco */
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --duration-fast: 0.2s;
    --duration: 0.25s;
    --duration-med: 0.35s;
    --duration-slow: 0.55s;
    --focus-ring: 2px solid var(--cyan);
    --focus-offset: 3px;
    /* Layout */
    --header-h: 76px;
    --section-space: 3.5rem;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: clip;
}

/* Salto directo al catálogo al volver desde un producto (sin animar el recorrido) */
html.scroll-instant {
    scroll-behavior: auto !important;
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    color: var(--text);
    background:
        radial-gradient(1200px 600px at 80% -10%, rgba(46, 230, 255, 0.05), transparent 55%),
        radial-gradient(900px 500px at 10% 20%, rgba(255, 255, 255, 0.03), transparent 50%),
        var(--bg);
    min-height: 100vh;
    max-width: 100%;
    overflow-x: clip;
    display: flex;
    flex-direction: column;
    -webkit-font-smoothing: antialiased;
}

body > main,
body > .catalog-shell {
    flex: 1 0 auto;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select {
    font: inherit;
}

.container {
    width: min(1180px, calc(100% - 2.5rem));
    margin: 0 auto;
}

/* ——— Buttons ——— */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.35rem;
    border: 1px solid var(--cyan);
    background: transparent;
    color: var(--cyan);
    border-radius: 999px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.82rem;
    cursor: pointer;
    transition: background 0.25s var(--ease), color 0.25s var(--ease), border-color 0.25s var(--ease), transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.btn:focus-visible {
    outline: var(--focus-ring);
    outline-offset: var(--focus-offset);
}

@media (hover: hover) {
    .btn:hover {
        background: var(--cyan);
        color: #041016;
        box-shadow: 0 0 0 1px var(--cyan), 0 10px 28px var(--cyan-glow);
        transform: translateY(-1px);
    }
}

.btn:active {
    transform: translateY(0);
}

.btn-secondary {
    border-color: var(--border-strong);
    color: var(--text);
}

@media (hover: hover) {
    .btn-secondary:hover {
        background: rgba(255, 255, 255, 0.08);
        color: #fff;
        border-color: rgba(255, 255, 255, 0.35);
        box-shadow: none;
    }
}

.btn-whatsapp,
.btn-instagram,
.btn-tiktok,
.btn-invert {
    border-color: var(--border-strong);
    color: var(--text);
    background: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(10px);
}

.header-actions .btn-whatsapp {
    border-color: rgba(46, 230, 255, 0.65);
    color: var(--cyan);
}

@media (hover: hover) {
    .btn-whatsapp:hover,
    .btn-instagram:hover,
    .btn-tiktok:hover,
    .btn-invert:hover {
        border-color: var(--cyan);
        color: var(--cyan);
        background: rgba(46, 230, 255, 0.08);
        box-shadow: none;
    }
}

.btn-icon {
    display: inline-flex;
    line-height: 0;
}

/* ——— Header ——— */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(5, 5, 5, 0.78);
    border-bottom: 1px solid transparent;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: background 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.page-catalogo .site-header,
.page-home .site-header {
    position: fixed;
    left: 0;
    right: 0;
    /* Opción C: transparente al entrar; el degradado/blur solo al hacer scroll */
    background: transparent;
    border-bottom-color: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
}

.site-header.scrolled,
.page-catalogo .site-header.scrolled,
.page-home .site-header.scrolled,
.site-header-dark {
    background: rgba(5, 5, 5, 0.88);
    border-bottom-color: var(--border-subtle);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.header-flex {
    min-height: var(--header-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    min-width: 0;
}

.header-brand {
    flex: 0 0 auto;
}

.header-brand .header-logo {
    width: min(168px, 42vw);
    height: 56px;
    object-fit: contain;
    transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
}

@media (hover: hover) {
    .header-brand a:hover .header-logo {
        opacity: 0.9;
        transform: scale(1.02);
    }
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: nowrap;
    justify-content: flex-end;
    flex: 0 0 auto;
    min-width: 0;
}

.header-actions .header-btn {
    padding: 0.55rem 0.9rem;
    font-size: 0.72rem;
    flex-shrink: 0;
    white-space: nowrap;
}

.header-btn-label-short {
    display: none;
}

/* ——— Hero ——— */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    color: #fff;
}

.hero__media {
    position: absolute;
    inset: 0;
    background: #000 center/cover no-repeat;
    transform: scale(1.02);
    animation: heroKen 18s var(--ease) forwards;
}

.hero--bmw .hero__media {
    background-image: url('../img/hero-bmw.png');
    /* X: aire a la izquierda para texto. Y más alto → se ve gorro/cabeza */
    background-position: 72% 22%;
}

.hero__gradient {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.72) 34%, rgba(0, 0, 0, 0.28) 62%, rgba(0, 0, 0, 0.18) 100%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.12) 0%, transparent 22%, rgba(0, 0, 0, 0.55) 100%);
    z-index: 1;
}

.hero__noise {
    position: absolute;
    inset: 0;
    z-index: 2;
    opacity: 0.04;
    pointer-events: none;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero__inner {
    position: relative;
    z-index: 3;
    width: min(1180px, calc(100% - 2.5rem));
    margin: 0 auto;
    padding: calc(var(--header-h) + 2rem) 0 4.5rem;
}

.hero__copy {
    max-width: 34rem;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
}

.hero-kicker {
    font-family: var(--font-body);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--cyan);
    opacity: 0;
    animation: fadeUp 0.9s var(--ease) 0.05s forwards;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(2.4rem, 6.5vw, 4.6rem);
    font-weight: 800;
    line-height: 0.98;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    text-wrap: balance;
    opacity: 0;
    animation: fadeUp 1s var(--ease) 0.15s forwards;
}

.hero-subtitle {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.88);
    opacity: 0;
    animation: fadeUp 1s var(--ease) 0.28s forwards;
}

.hero-exclusivity {
    font-size: 0.92rem;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.62);
    opacity: 0;
    animation: fadeUp 1s var(--ease) 0.4s forwards;
}

.hero-btn {
    margin-top: 0.75rem;
    padding: 1rem 1.6rem;
    border-radius: 999px;
    opacity: 0;
    animation: fadeUp 1s var(--ease) 0.55s forwards;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes heroKen {
    from { transform: scale(1.06); }
    to { transform: scale(1.02); }
}

/* ——— Benefits ——— */
.benefits {
    width: 100%;
    border-top: 1px solid var(--border-subtle);
    border-bottom: 1px solid var(--border-subtle);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 70%),
        rgba(0, 0, 0, 0.35);
}

.benefits__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0;
}

.benefit-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.55rem;
    padding: 1.75rem 1.4rem;
    border-right: 1px solid var(--border-subtle);
}

.benefit-item:last-child {
    border-right: none;
}

.benefit-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.4rem;
    height: 2.4rem;
    color: var(--cyan);
}

.benefit-title {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: #fff;
    line-height: 1.25;
}

.benefit-flag {
    display: inline-flex;
    align-items: center;
    margin-left: 0.35rem;
    vertical-align: middle;
    border-radius: 2px;
    overflow: hidden;
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
    line-height: 0;
}

.benefit-flag svg {
    display: block;
}

.benefit-text {
    font-size: 0.88rem;
    color: var(--text-muted);
    line-height: 1.4;
    max-width: 16rem;
}

/* ——— Catalog ——— */
.catalog-shell {
    padding: var(--section-space) 0 5rem;
}

.filters {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
    border: 1px solid var(--border-subtle);
    border-radius: calc(var(--radius) + 4px);
    padding: 0.85rem;
    margin-bottom: 2rem;
}

.filters-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.95rem 1.1rem;
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    cursor: pointer;
    transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.filters-toggle:hover,
.filters.is-open .filters-toggle {
    border-color: rgba(46, 230, 255, 0.45);
    background: var(--cyan-dim);
}

.filters-toggle-text {
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    font-size: 0.82rem;
}

.filters-toggle-icon {
    color: var(--cyan);
    transition: transform 0.25s var(--ease);
}

.filters.is-open .filters-toggle-icon {
    transform: rotate(180deg);
}

.filters-content {
    padding: 1.15rem 0.35rem 0.35rem;
}

.filters-title {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

.filters-form {
    display: grid;
    gap: 1rem;
}

.filters-row {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.85rem;
}

.filters-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.filters-field label {
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.filters-field input[type="text"],
.filters-field input[type="number"],
.filters-field select {
    width: 100%;
    min-height: 44px;
    padding: 0.7rem 0.85rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
    background: #090909;
    color: var(--text);
}

.filters-field input:focus,
.filters-field select:focus {
    outline: none;
    border-color: rgba(46, 230, 255, 0.55);
    box-shadow: 0 0 0 3px var(--cyan-dim);
}

.filters-actions {
    display: flex;
    align-items: end;
    gap: 0.65rem;
    flex-wrap: wrap;
}

.filters-actions .btn {
    min-height: 44px;
}

/* ——— Product grid ——— */
.productos-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.35rem;
    align-items: stretch;
}

.producto-card {
    background: linear-gradient(165deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01) 55%, rgba(0, 0, 0, 0.2));
    border: 1px solid var(--border-subtle);
    border-radius: calc(var(--radius) + 2px);
    padding: 0.85rem 0.85rem 1.1rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    height: 100%;
    min-width: 0;
    max-width: 100%;
    box-shadow: var(--shadow-card);
    content-visibility: auto;
    contain-intrinsic-height: 440px;
    transition: transform var(--duration-med) var(--ease), border-color var(--duration-med) var(--ease), box-shadow var(--duration-med) var(--ease), background var(--duration-med) var(--ease);
}

.reveal-card {
    opacity: 0;
    transform: translateY(16px);
}

.reveal-card.is-visible {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}

.productos-grid .reveal-card.is-visible:nth-child(4n + 2) { transition-delay: 0.04s; }
.productos-grid .reveal-card.is-visible:nth-child(4n + 3) { transition-delay: 0.08s; }
.productos-grid .reveal-card.is-visible:nth-child(4n + 4) { transition-delay: 0.12s; }

@media (hover: hover) {
    .producto-card:hover {
        transform: translateY(-5px);
        border-color: rgba(46, 230, 255, 0.38);
        background: linear-gradient(165deg, rgba(46, 230, 255, 0.05), rgba(255, 255, 255, 0.015) 50%, rgba(0, 0, 0, 0.18));
        box-shadow: 0 24px 50px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(46, 230, 255, 0.1);
    }

    .producto-card:hover .product-image-frame img {
        transform: scale(1.045);
    }

    .producto-card:hover .btn {
        background: var(--cyan);
        color: #041016;
        box-shadow: 0 8px 22px var(--cyan-glow);
    }
}

.product-image-frame {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 50% 38%, rgba(46, 230, 255, 0.09), transparent 58%),
        linear-gradient(180deg, #101010, #070707);
}

.product-image-frame img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.55s var(--ease);
}

.product-image-frame--card {
    aspect-ratio: 1 / 1;
}

.producto-img-placeholder {
    color: var(--text-muted);
    font-size: 0.9rem;
    padding: 2rem;
}

.producto-card h3 {
    font-family: var(--font-display);
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.3;
    letter-spacing: -0.01em;
    min-height: 2.6em;
    color: #fff;
    overflow-wrap: anywhere;
    word-break: break-word;
}

.producto-card .precio {
    color: var(--cyan);
    font-weight: 700;
    font-size: 1.08rem;
    letter-spacing: 0.02em;
    margin-top: 0.1rem;
}

.tallas-wrap {
    min-height: 1.35em;
    color: var(--text-muted);
    font-size: 0.8rem;
    line-height: 1.4;
}

.tallas-list--horizontal {
    display: inline;
    letter-spacing: 0.01em;
}

.tallas-sep {
    display: inline-block;
    margin: 0 0.42em;
    color: rgba(244, 244, 244, 0.32);
    font-weight: 400;
}

.tallas-list--vertical {
    display: inline-block;
    line-height: 1.4;
}

.producto-card .btn {
    margin-top: auto;
    width: 100%;
    min-height: 44px;
    border-radius: 12px;
    font-size: 0.78rem;
}

/* ——— Product detail ——— */
.has-fixed-header .site-header {
    position: sticky;
}

.page-producto main.container {
    padding: 2rem 0 4rem;
}

.producto-detalle-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 2.5rem;
    align-items: start;
}

.producto-carousel {
    position: relative;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
    border: 1px solid var(--border-subtle);
    border-radius: calc(var(--radius) + 6px);
    overflow: hidden;
    box-shadow: var(--shadow-card);
}

.carousel-track {
    display: flex;
    transition: transform 0.45s var(--ease);
    border: none;
    position: relative;
    z-index: 1;
}

.carousel-slide {
    flex: 0 0 100%;
    min-width: 100%;
    padding: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.producto-img-detalle {
    width: 100%;
    max-height: min(62vh, 560px);
    object-fit: contain;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 1px solid var(--border-strong);
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    backdrop-filter: blur(8px);
    transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.2s var(--ease);
}

.carousel-btn.prev { left: 12px; }
.carousel-btn.next { right: 12px; }

@media (hover: hover) {
    .carousel-btn:hover {
        border-color: var(--cyan);
        color: var(--cyan);
        transform: translateY(-50%) scale(1.05);
    }
}

.carousel-thumbs {
    display: flex;
    justify-content: center;
    gap: 0.65rem;
    flex-wrap: wrap;
    padding: 0 1rem 1.15rem;
}

.carousel-thumb {
    border: 1px solid transparent;
    background: #000;
    padding: 4px;
    border-radius: 10px;
    cursor: pointer;
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.carousel-thumb img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    border-radius: 6px;
}

.carousel-thumb.is-active {
    border-color: transparent;
    box-shadow: 0 0 0 2px var(--cyan);
}

.carousel-single .carousel-btn.prev,
.carousel-single .carousel-btn.next {
    display: none;
}

.producto-info {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    padding: 0.5rem 0;
}

.producto-title {
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 3.5vw, 2.4rem);
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    overflow-wrap: anywhere;
    word-break: break-word;
    text-wrap: balance;
}

.talla-selector {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    max-width: 260px;
}

.talla-label {
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.talla-selector select {
    min-height: 46px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
    background: #090909;
    color: var(--text);
    padding: 0.65rem 0.8rem;
}

.precio-grande {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 700;
    color: var(--cyan);
    letter-spacing: 0.02em;
}

.producto-info .btn-whatsapp {
    align-self: flex-start;
    margin-top: 0.5rem;
    border-color: var(--cyan);
    color: var(--cyan);
}

/* ——— Custom select ——— */
select.select-native {
    position: absolute !important;
    opacity: 0 !important;
    pointer-events: none !important;
    width: 1px !important;
    height: 1px !important;
}

.custom-select {
    position: relative;
    width: 100%;
}

.custom-select-trigger {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 46px;
    padding: 0.7rem 2.4rem 0.7rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-subtle);
    background: #0a0a0a;
    color: var(--text);
    text-align: left;
    cursor: pointer;
    position: relative;
    appearance: none;
    -webkit-appearance: none;
    transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.custom-select-trigger:hover,
.custom-select.open .custom-select-trigger {
    border-color: rgba(46, 230, 255, 0.45);
    box-shadow: 0 0 0 1px rgba(46, 230, 255, 0.12);
}

.custom-select-trigger:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 2px;
}

.custom-select-trigger::after {
    content: "";
    position: absolute;
    right: 0.95rem;
    top: 50%;
    width: 0.45rem;
    height: 0.45rem;
    border-right: 2px solid var(--cyan);
    border-bottom: 2px solid var(--cyan);
    transform: translateY(-65%) rotate(45deg);
    transition: transform 0.2s var(--ease);
}

.custom-select.open .custom-select-trigger::after {
    transform: translateY(-25%) rotate(225deg);
}

.custom-select-options {
    display: none;
    flex-direction: column;
    position: absolute;
    left: 0;
    right: 0;
    top: calc(100% + 6px);
    z-index: 40;
    max-height: 260px;
    overflow-x: hidden;
    overflow-y: auto;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    background: #0a0a0a;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55);
}

.custom-select.open .custom-select-options {
    display: flex;
}

.custom-select-search-wrap {
    padding: 0.55rem;
    border-bottom: 1px solid var(--border-subtle);
    background: #000;
}

.custom-select-search {
    width: 100%;
    min-height: 40px;
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    background: #090909;
    color: var(--text);
    padding: 0.55rem 0.7rem;
}

.custom-select-search:focus {
    outline: none;
    border-color: rgba(46, 230, 255, 0.55);
}

.custom-select-search::placeholder {
    color: rgba(255, 255, 255, 0.35);
}

.custom-select-empty {
    padding: 0.8rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.custom-select-option.is-hidden {
    display: none;
}

.custom-select-option {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0.75rem 0.9rem;
    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 0;
    background: transparent;
    color: var(--text);
    text-align: left;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    transition: background 0.15s var(--ease), color 0.15s var(--ease);
}

.custom-select-option:last-child {
    border-bottom: 0;
}

.custom-select-option:hover,
.custom-select-option.is-active {
    background: var(--cyan-dim);
    color: #fff;
}

.custom-select-option:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: -2px;
}

.talla-selector .custom-select {
    width: 100%;
}

/* ——— Footer ——— */
.site-footer {
    margin-top: auto;
    border-top: 1px solid var(--border-subtle);
    background:
        radial-gradient(700px 240px at 50% 0%, rgba(46, 230, 255, 0.05), transparent 65%),
        linear-gradient(180deg, #080808, #050505);
    padding: 2.75rem 0 2rem;
    color: var(--text-muted);
}

.site-footer__inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr auto;
    gap: 1.75rem 2rem;
    align-items: center;
}

.site-footer__brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.site-footer__logo {
    width: auto;
    height: 42px;
    object-fit: contain;
}

.site-footer__name {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #fff;
}

.site-footer__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.4rem;
    justify-content: center;
}

.site-footer__nav a {
    font-size: 0.86rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--soft-white);
    transition: color 0.2s var(--ease);
}

.site-footer__nav a:hover,
.site-footer__nav a:focus-visible {
    color: var(--cyan);
}

.site-footer__social {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.65rem;
}

.site-footer__social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.45rem;
    height: 2.45rem;
    border: 1px solid var(--border-subtle);
    border-radius: 999px;
    color: var(--cyan);
    background: rgba(255, 255, 255, 0.02);
    transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.2s var(--ease);
}

.site-footer__social-link:hover,
.site-footer__social-link:focus-visible {
    border-color: rgba(46, 230, 255, 0.55);
    background: var(--cyan-dim);
    transform: translateY(-1px);
}

.site-footer__copy {
    grid-column: 1 / -1;
    text-align: center;
    font-size: 0.84rem;
    padding-top: 0.35rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* ——— Error pages ——— */
.error-page {
    min-height: 70vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    text-align: center;
    padding: 2rem;
}

.error-page h1 {
    font-family: var(--font-display);
    font-size: clamp(3rem, 10vw, 6rem);
    font-weight: 800;
    color: #fff;
    margin: 0 0 0.5rem;
}

.error-page p {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.error-page a {
    color: var(--cyan);
    font-weight: 600;
}

.error-page a:hover {
    text-decoration: underline;
}

/* ——— Responsive ——— */
@media (max-width: 1100px) {
    .productos-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .filters-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .benefits__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .benefit-item:nth-child(2n) {
        border-right: none;
    }

    .benefit-item:nth-child(-n + 2) {
        border-bottom: 1px solid var(--border-subtle);
    }
}

@media (max-width: 860px) {
    .producto-detalle-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .hero--bmw .hero__media {
        background-position: 68% 24%;
    }

    .hero__gradient {
        background:
            linear-gradient(90deg, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.7) 42%, rgba(0, 0, 0, 0.35) 100%),
            linear-gradient(180deg, rgba(0, 0, 0, 0.18) 0%, transparent 28%, rgba(0, 0, 0, 0.7) 100%);
    }
}

@media (max-width: 720px) {
    .container,
    .hero__inner {
        width: min(100% - 1.25rem, 1180px);
    }

    .productos-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.85rem;
    }

    .filters-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .filters-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .filters-actions .btn {
        width: 100%;
    }

    .hero__inner {
        padding-bottom: 3.25rem;
    }

    /* Tablet/móvil: personaje + gorro visibles */
    .hero--bmw .hero__media {
        background-position: 64% 26%;
    }

    .hero__gradient {
        background:
            linear-gradient(180deg, rgba(0, 0, 0, 0.28) 0%, rgba(0, 0, 0, 0.12) 32%, rgba(0, 0, 0, 0.72) 100%),
            linear-gradient(90deg, rgba(0, 0, 0, 0.72) 0%, rgba(0, 0, 0, 0.28) 55%, rgba(0, 0, 0, 0.2) 100%);
    }

    .hero-kicker {
        letter-spacing: 0.18em;
    }

    .hero-title {
        font-size: clamp(2rem, 9vw, 3.2rem);
        max-width: 100%;
    }

    .hero-btn {
        width: 100%;
        max-width: 22rem;
    }

    .producto-card h3 {
        font-size: 0.92rem;
        min-height: 0;
    }

    .site-footer__inner {
        grid-template-columns: minmax(0, 1fr);
        text-align: center;
        justify-items: center;
        gap: 1.35rem;
    }

    .site-footer__brand {
        flex-direction: column;
        gap: 0.55rem;
    }

    .site-footer__nav {
        justify-content: center;
    }

    .site-footer__social {
        justify-content: center;
    }

    .benefits__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .benefit-item {
        border-right: none;
        border-bottom: 1px solid var(--border-subtle);
        align-items: center;
        text-align: center;
        padding: 1.35rem 1rem;
    }

    .benefit-item:last-child {
        border-bottom: none;
    }

    .benefit-item:nth-child(-n + 2) {
        border-bottom: 1px solid var(--border-subtle);
    }

    .benefit-text {
        max-width: none;
    }
}

/* iPhone SE / 12 / 14 y similares (hasta ~600px) */
@media (max-width: 600px) {
    :root {
        --header-h: 64px;
    }

    .header-brand .header-logo {
        width: min(118px, 32vw);
        height: 44px;
    }

    .header-actions {
        gap: 0.35rem;
    }

    .header-actions .header-btn {
        padding: 0.5rem;
        min-width: 40px;
        min-height: 40px;
        justify-content: center;
    }

    /* Icon-only: el label es nodo de texto → font-size 0 lo oculta */
    .header-actions .btn-whatsapp,
    .header-actions .btn-instagram,
    .header-actions .btn-tiktok {
        font-size: 0;
        gap: 0;
        letter-spacing: 0;
    }

    .header-actions .btn-whatsapp .btn-icon,
    .header-actions .btn-instagram .btn-icon,
    .header-actions .btn-tiktok .btn-icon {
        margin: 0;
    }

    .header-btn-label-full {
        display: none;
    }

    .header-btn-label-short {
        display: inline;
        font-size: 1.05rem;
        line-height: 1;
        letter-spacing: 0;
    }

    #volver-catalogo {
        font-size: 0;
        min-width: 40px;
        padding: 0.5rem 0.65rem;
    }

    .productos-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.95rem;
    }

    .catalog-shell {
        padding: 2.25rem 0 3.5rem;
    }

    .filters,
    .productos-grid,
    .producto-card {
        max-width: 100%;
        min-width: 0;
    }

    /* Celular: personaje + gorro en el encuadre */
    .hero--bmw .hero__media {
        background-position: 62% 22%;
    }

    .hero__copy {
        max-width: 100%;
        align-items: stretch;
    }

    .page-producto main.container {
        padding: 1.25rem 0 3rem;
    }

    .page-producto .producto-info {
        align-items: center;
        text-align: center;
        gap: 1rem;
        padding: 0.25rem 0 0;
    }

    .page-producto .producto-title {
        font-size: clamp(1.35rem, 6.2vw, 1.85rem);
        line-height: 1.2;
        text-align: center;
        max-width: 22ch;
        margin-inline: auto;
    }

    .page-producto .talla-selector {
        width: 100%;
        max-width: 100%;
        align-items: stretch;
    }

    .page-producto .talla-label {
        text-align: left;
    }

    .page-producto .precio-grande {
        text-align: center;
    }

    .page-producto .producto-info .btn-whatsapp {
        align-self: stretch;
        width: 100%;
    }

    .carousel-slide {
        padding: 0.85rem;
    }

    .carousel-btn {
        width: 36px;
        height: 36px;
    }

    .carousel-btn.prev { left: 8px; }
    .carousel-btn.next { right: 8px; }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
        scroll-behavior: auto !important;
    }

    .reveal-card,
    .reveal-card.is-visible {
        opacity: 1;
        transform: none;
        transition-delay: 0s !important;
    }

    .productos-grid .reveal-card.is-visible:nth-child(n) {
        transition-delay: 0s !important;
    }
}
