/* =========================================================
   ARITRIWOOD - HEADER PREVIEW
   Solo se carga en la página 505
   ========================================================= */

/* Ocultar cabecera original de Kadence */
#masthead,
.site-header,
.site-header-wrap,
.site-top-header-wrap,
.site-main-header-wrap,
.site-bottom-header-wrap {
    display: none !important;
}


/* HEADER NUEVO */
.aw-custom-header {
    position: relative;
    z-index: 999;

    width: 100%;
    margin: 0;
    padding: 0;

    background: #fbfaf6;
    border-bottom: 1px solid #e6e1d8;
}

.aw-custom-header-inner {
    width: min(1220px, calc(100% - 48px));
    min-height: 92px;

    margin: 0 auto;

    display: grid;
    grid-template-columns: 170px 1fr 170px;
    align-items: center;
}


/* LOGO */
.aw-brand {
    display: flex;
    align-items: center;

    margin: 0;
    padding: 0;

    text-decoration: none;
}

.aw-brand img {
    display: block;

    width: auto !important;
    height: auto !important;

    max-width: 105px !important;
    max-height: 72px !important;

    margin: 0 !important;
    padding: 0 !important;

    object-fit: contain;
}


/* MENÚ */
.aw-main-nav {
    display: flex;
    align-items: center;
    justify-content: center;
}

.aw-main-nav ul,
.aw-nav-list {
    display: flex !important;
    align-items: center;
    justify-content: center;

    gap: 34px;

    margin: 0 !important;
    padding: 0 !important;

    list-style: none !important;
}

.aw-main-nav li,
.aw-nav-list li {
    display: block;

    margin: 0 !important;
    padding: 0 !important;

    list-style: none !important;
}

.aw-main-nav li::marker {
    content: "";
}

.aw-main-nav a {
    position: relative;

    display: block;

    padding: 35px 0 30px;

    color: #292720 !important;

    font-size: 14px;
    font-weight: 600;
    line-height: 1;

    text-decoration: none !important;
}

.aw-main-nav a::after {
    content: "";

    position: absolute;
    bottom: 21px;
    left: 0;

    width: 0;
    height: 2px;

    background: #3c472e;

    transition: width .2s ease;
}

.aw-main-nav a:hover::after,
.aw-main-nav .current-menu-item > a::after {
    width: 100%;
}


/* ACCIONES DERECHA */
.aw-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;

    gap: 20px;
}

.aw-header-actions a,
.aw-search-toggle {
    position: relative;

    display: flex;
    width: 32px;
    height: 32px;

    align-items: center;
    justify-content: center;

    margin: 0;
    padding: 0;

    border: 0 !important;
    border-radius: 0 !important;

    background: transparent !important;
    color: #292720 !important;

    box-shadow: none !important;

    cursor: pointer;
    text-decoration: none !important;
}

.aw-header-actions svg {
    display: block;

    width: 23px;
    height: 23px;

    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    stroke-linecap: round;
    stroke-linejoin: round;
}


/* CONTADOR CARRITO */
.aw-cart-count {
    position: absolute;

    top: -3px;
    right: -5px;

    display: flex;

    width: 17px;
    height: 17px;

    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #465139;
    color: #fff;

    font-size: 9px;
    font-weight: 700;
}


/* BUSCADOR */
.aw-search-panel {
    display: none;

    width: 100%;

    padding: 18px 24px;

    border-top: 1px solid #e3ded4;

    background: #f5f2eb;
}

.aw-search-panel.is-open {
    display: block;
}

.aw-search-panel form {
    display: flex;

    width: min(620px, 100%);

    margin: 0 auto;
}

.aw-search-panel input[type="search"] {
    flex: 1;

    width: auto;
    min-height: 46px;

    margin: 0;
    padding: 0 17px;

    border: 1px solid #d9d3c8 !important;
    border-radius: 5px 0 0 5px !important;

    background: #fff !important;
    color: #282820;

    box-shadow: none !important;
}

.aw-search-panel button[type="submit"] {
    min-height: 46px;

    margin: 0;
    padding: 0 25px;

    border: 0 !important;
    border-radius: 0 5px 5px 0 !important;

    background: #3c472e !important;
    color: #fff !important;

    font-size: 12px;
    font-weight: 700;

    text-transform: uppercase;
}


/* Evitar márgenes raros alrededor */
.aw-custom-header *,
.aw-custom-header *::before,
.aw-custom-header *::after {
    box-sizing: border-box;
}


/* TABLET */
@media (max-width: 900px) {

    .aw-custom-header-inner {
        grid-template-columns: 120px 1fr;
        min-height: 78px;
    }

    .aw-main-nav {
        display: none;
    }

    .aw-header-actions {
        grid-column: 2;
    }

    .aw-brand img {
        max-width: 88px !important;
        max-height: 62px !important;
    }
}


/* MÓVIL */
@media (max-width: 600px) {

    .aw-custom-header-inner {
        width: calc(100% - 28px);
    }

    .aw-header-actions {
        gap: 13px;
    }
}


/* =========================================================
   HEADER - BUSCADOR LIMPIO SIN CAJA BLANCA
   ========================================================= */

/* Quitar contenedor blanco exterior */
.aw-custom-header .aw-search-panel,
.aw-custom-header .aw-header-search,
.aw-custom-header .dgwt-wcas-search-wrapp,
.aw-custom-header .dgwt-wcas-search-form,
.aw-custom-header .dgwt-wcas-sf-wrapp {
    margin: 0 !important;
    padding: 0 !important;

    border: 0 !important;

    background: transparent !important;
    background-color: transparent !important;

    box-shadow: none !important;
}


/* Contenedor general */
.aw-custom-header .dgwt-wcas-search-wrapp {
    width: 100% !important;
    max-width: 285px !important;
}


/* Campo de búsqueda */
.aw-custom-header .dgwt-wcas-search-input,
.aw-custom-header input[type="search"] {
    width: 100% !important;
    height: 48px !important;

    margin: 0 !important;

    padding:
        0
        46px
        0
        48px !important;

    border: 1px solid transparent !important;
    border-radius: 999px !important;

    background: #efefed !important;

    color: #24231f !important;

    font-size: 14px !important;

    box-shadow: none !important;

    outline: none !important;
}


/* Placeholder */
.aw-custom-header .dgwt-wcas-search-input::placeholder,
.aw-custom-header input[type="search"]::placeholder {
    color: #77746d !important;
    opacity: 1 !important;
}


/* Focus más elegante */
.aw-custom-header .dgwt-wcas-search-input:focus,
.aw-custom-header input[type="search"]:focus {
    border-color: #d5d1c8 !important;

    background: #f2f1ee !important;

    box-shadow: none !important;
}


/* Si FiboSearch agrega otra capa blanca */
.aw-custom-header .dgwt-wcas-sf-wrapp {
    height: 48px !important;
    border-radius: 999px !important;
}


/* Quitar fondos heredados de wrappers */
.aw-custom-header .dgwt-wcas-search-wrapp *,
.aw-custom-header .aw-search-panel * {
    box-sizing: border-box;
}


/* Móvil */
@media (max-width: 700px) {

    .aw-custom-header .dgwt-wcas-search-wrapp {
        max-width: 100% !important;
    }

}


/* =========================================================
   HEADER - AJUSTE FINAL BUSCADOR
   ========================================================= */

.aw-custom-header .dgwt-wcas-sf-wrapp {
    position: relative !important;
    height: 46px !important;
}


/* Campo */
.aw-custom-header .dgwt-wcas-search-input {
    height: 46px !important;

    padding:
        0
        20px
        0
        52px !important;

    line-height: 46px !important;

    border-radius: 999px !important;

    background: #efefed !important;

    text-indent: 0 !important;
}


/* Lupa directa de FiboSearch */
.aw-custom-header
.dgwt-wcas-sf-wrapp
> .dgwt-wcas-ico-magnifier {
    position: absolute !important;

    top: 50% !important;
    left: 19px !important;
    right: auto !important;
    bottom: auto !important;

    width: 15px !important;
    height: 15px !important;

    margin: 0 !important;

    transform: translateY(-50%) !important;

    z-index: 5 !important;
}


/* Si la lupa está dentro de un botón */
.aw-custom-header
.dgwt-wcas-search-submit {
    position: absolute !important;

    top: 50% !important;
    left: 13px !important;
    right: auto !important;

    width: 30px !important;
    height: 30px !important;

    display: flex !important;

    align-items: center !important;
    justify-content: center !important;

    margin: 0 !important;
    padding: 0 !important;

    transform: translateY(-50%) !important;

    border: 0 !important;

    background: transparent !important;

    box-shadow: none !important;

    z-index: 6 !important;
}


.aw-custom-header
.dgwt-wcas-search-submit svg,
.aw-custom-header
.dgwt-wcas-search-submit
.dgwt-wcas-ico-magnifier {
    position: static !important;

    width: 15px !important;
    height: 15px !important;

    margin: 0 !important;

    transform: none !important;
}


/* Placeholder */
.aw-custom-header
.dgwt-wcas-search-input::placeholder {
    color: #77746d !important;

    font-size: 13px !important;

    opacity: 1 !important;
}
