/* ==========================================================================
   T2S — Cabecera (spec Brilliant): dos tiras claras + mega-menú.
   Tira 1 (62px): logo + secundario + idioma + buscar + carrito.
   Tira 2 (51px): 8 familias de producto. Activa: rojo #910304, subrayado
   #b70e0c y chevron rojo flipped. Mega dropdown al hover con 2 col de
   sub-items + 2 tarjetas promocionales, sombra 0 12px 32px rgba(29,29,29,.5).
   Namespaced .t2s-hd para no colisionar con Avada.
   ========================================================================== */

.t2s-hd { font-family: var(--t2s-font-head); position: relative; z-index: 200; background: #f8f8f8; border-bottom: 1px solid #e1e1e1; }
.t2s-hd *, .t2s-hd *::before, .t2s-hd *::after { box-sizing: border-box; }

/* ── Tira 1: top (62px) ────────────────────────────────────────────────── */
.t2s-hd__top { height: 62px; padding: 0 32px; display: flex; align-items: center; border-bottom: 1px solid #e1e1e1; background: #f8f8f8; position: relative; z-index: 2; }
.t2s-hd__logo { flex: 0 0 auto; display: block; text-decoration: none; }
.t2s-hd__logo img { height: 38px; width: auto; display: block; }
.t2s-hd__space { flex: 1; }
.t2s-hd__secondary { display: flex; align-items: center; gap: 32px; }
.t2s-hd__secondary a { font-size: 14px; font-weight: 700; color: #1d1d1d; text-decoration: none; letter-spacing: .02em; text-transform: uppercase; transition: color var(--t2s-dur) var(--t2s-ease); }
.t2s-hd__secondary a:hover { color: var(--t2s-accent); }
.t2s-hd__vr { width: 1px; height: 20px; background: #e1e1e1; margin: 0 20px; flex: 0 0 auto; }
.t2s-hd__lang { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; }
.t2s-hd__lang a { color: #575757; text-decoration: none; padding: 4px 2px; }
.t2s-hd__lang a.is-active,
.t2s-hd__lang .wpml-ls-current-language > a { color: var(--t2s-accent); }
.t2s-hd__lang span.sep { color: #c6c6c6; font-weight: 500; }
.t2s-hd__ic { display: inline-flex; align-items: center; justify-content: center; background: none; border: 0; padding: 0; color: #1d1d1d; cursor: pointer; position: relative; text-decoration: none; transition: color var(--t2s-dur) var(--t2s-ease); }
.t2s-hd__ic:hover { color: var(--t2s-accent); }
.t2s-hd__ic svg { width: 20px; height: 20px; fill: currentColor; display: block; }
.t2s-hd__ic-n { font-size: 12px; font-weight: 700; margin-left: 8px; color: inherit; }
.t2s-hd__burger { display: none; }

/* ── Tira 2: categorías (51px) ─────────────────────────────────────────── */
.t2s-hd__cats { min-height: 51px; padding: 0 32px; display: flex; align-items: center; gap: 20px; background: #f8f8f8; position: relative; z-index: 2; list-style: none; margin: 0; }
.t2s-hd__cat { position: static; margin: 0; padding: 0; list-style: none; }
.t2s-hd__cat-link { display: inline-flex; align-items: center; gap: 6px; height: 51px; padding: 0; font-size: 14px; font-weight: 700; color: #1d1d1d; text-decoration: none; letter-spacing: .01em; text-transform: uppercase; line-height: 1; border-bottom: 2px solid transparent; transition: color var(--t2s-dur) var(--t2s-ease), border-color var(--t2s-dur) var(--t2s-ease); white-space: nowrap; }
.t2s-hd__chev { width: 11px; height: 6px; display: inline-block; color: #575757; transition: color var(--t2s-dur) var(--t2s-ease), transform var(--t2s-dur) var(--t2s-ease); flex: 0 0 auto; }
.t2s-hd__chev svg { width: 11px; height: 6px; display: block; }
.t2s-hd__cat.has-sub:hover .t2s-hd__cat-link,
.t2s-hd__cat.is-open .t2s-hd__cat-link { color: #910304; border-color: var(--t2s-accent); }
.t2s-hd__cat.has-sub:hover .t2s-hd__chev,
.t2s-hd__cat.is-open .t2s-hd__chev { color: #910304; transform: rotate(180deg); }

/* ── Mega dropdown ─────────────────────────────────────────────────────── */
.t2s-hd__drop { position: absolute; left: 0; right: 0; top: 100%; background: #f8f8f8; box-shadow: 0 12px 32px rgba(29,29,29,.5); padding: 32px; opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity var(--t2s-dur) var(--t2s-ease), transform var(--t2s-dur) var(--t2s-ease), visibility var(--t2s-dur); z-index: 210; }
.t2s-hd__cat.has-sub:hover .t2s-hd__drop,
.t2s-hd__cat.is-open .t2s-hd__drop { opacity: 1; visibility: visible; transform: translateY(0); }
.t2s-hd__drop-grid { display: grid; grid-template-columns: 257px 270px 1fr; gap: 96px; align-items: start; max-width: 1440px; margin: 0 auto; padding: 0 0 0 0; }
.t2s-hd__drop-grid--nopromo { grid-template-columns: 257px 270px; }
.t2s-hd__drop-col { min-width: 200px; }
.t2s-hd__drop-title { display: block; font-size: 12px; font-weight: 700; color: var(--t2s-accent); letter-spacing: .06em; text-transform: uppercase; margin: 0 0 24px; padding-top: 4px; text-decoration: none; }
a.t2s-hd__drop-title:hover { text-decoration: underline; }
.t2s-hd__drop-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.t2s-hd__drop-col li a { font-size: 14px; font-weight: 500; color: #454545; text-decoration: none; line-height: 1.35; display: inline-block; padding: 2px 0; transition: color var(--t2s-dur) var(--t2s-ease); }
.t2s-hd__drop-col li a:hover { color: var(--t2s-accent); }

/* Promos */
.t2s-hd__promos { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.t2s-hd__promo { color: inherit; text-decoration: none; display: flex; flex-direction: column; gap: 4px; }
.t2s-hd__promo-img { aspect-ratio: 352/150; border-radius: 6px; background: radial-gradient(80% 80% at 40% 30%, #f0f0f0 0%, #e1e1e1 100%); overflow: hidden; position: relative; margin-bottom: 4px; }
.t2s-hd__promo-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: 6px; display: block; }
.t2s-hd__promo-eyb { font-size: 12px; font-weight: 700; color: var(--t2s-accent); letter-spacing: .04em; text-transform: uppercase; margin: 8px 0 0; }
.t2s-hd__promo-t { font-size: 16px; font-weight: 700; color: #454545; margin: 4px 0 6px; line-height: 1.15; }
.t2s-hd__promo-cta { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: #454545; transition: color var(--t2s-dur) var(--t2s-ease); }
.t2s-hd__promo-cta svg { width: 14px; height: 12px; fill: currentColor; transition: transform var(--t2s-dur) var(--t2s-ease); }
.t2s-hd__promo:hover .t2s-hd__promo-t,
.t2s-hd__promo:hover .t2s-hd__promo-cta { color: var(--t2s-accent); }
.t2s-hd__promo:hover .t2s-hd__promo-cta svg { transform: translateX(4px); }

/* Buscador desplegable (bajo el header) */
.t2s-hd__search { display: none; border-top: 1px solid var(--t2s-line); background: var(--t2s-bg-alt); padding: 12px 32px; }
.t2s-hd__search.is-open { display: flex; gap: 12px; }
.t2s-hd__search input { flex: 1; padding: 12px 14px; border: 1px solid var(--t2s-line); border-radius: 2px; font-size: 15px; font-family: var(--t2s-font-body); }
.t2s-hd__search button { padding: 12px 22px; border: 0; background: var(--t2s-accent); color: #fff; font-family: var(--t2s-font-head); font-weight: 600; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; border-radius: 2px; cursor: pointer; }

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 1180px) {
    .t2s-hd__cats { gap: 12px; padding: 0 24px; }
    .t2s-hd__cat-link { font-size: 12.5px; padding: 0 2px; }
}

@media (max-width: 980px) {
    .t2s-hd__top { padding: 0 16px; }
    .t2s-hd__secondary, .t2s-hd__vr { display: none; }
    .t2s-hd__burger { display: inline-flex; flex-direction: column; justify-content: center; gap: 4px; width: 40px; height: 40px; background: none; border: 0; cursor: pointer; margin-left: 8px; }
    .t2s-hd__burger span { display: block; width: 22px; height: 2px; background: #1d1d1d; transition: transform var(--t2s-dur) var(--t2s-ease), opacity var(--t2s-dur) var(--t2s-ease); }
    .t2s-hd.is-menu-open .t2s-hd__burger span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
    .t2s-hd.is-menu-open .t2s-hd__burger span:nth-child(2) { opacity: 0; }
    .t2s-hd.is-menu-open .t2s-hd__burger span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

    /* Cats bar → cajón desplegable en móvil */
    .t2s-hd__cats { display: none; flex-direction: column; align-items: stretch; padding: 0; height: auto; min-height: 0; gap: 0; }
    .t2s-hd.is-menu-open .t2s-hd__cats { display: flex; }
    .t2s-hd__cat { border-bottom: 1px solid #e1e1e1; }
    .t2s-hd__cat-link { height: auto; padding: 14px 24px; justify-content: space-between; width: 100%; }
    .t2s-hd__drop { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; padding: 16px 24px; display: none; background: #fff; }
    .t2s-hd__cat.is-open .t2s-hd__drop { display: block; }
    .t2s-hd__drop-grid { grid-template-columns: 1fr !important; gap: 20px; }
    .t2s-hd__promos { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    .t2s-hd__drop, .t2s-hd__chev, .t2s-hd__cat-link, .t2s-hd__promo-cta svg, .t2s-hd__burger span { transition: none; }
}
