/* =========================================================
   Puro Bueno GT — sistema global (se carga después de todo)
   ========================================================= */

/* 1. Paleta de Astra en claro.
   La paleta heredada estaba en modo oscuro (textos #FFFFFF / #E7F6FF y
   fondos #010101): dejaba títulos invisibles en Marcas y Mi cuenta y el
   menú del celular blanco sobre blanco. */
:root,
body{
  --pb-caramel-ink:#8a5530; /* caramelo legible sobre blanco y crema (≥5.5:1) */
  --ast-global-color-0:#684027; /* enlaces y acento */
  --ast-global-color-1:#3b2115; /* hover */
  --ast-global-color-2:#3b2115; /* títulos */
  --ast-global-color-3:#5a4638; /* texto */
  --ast-global-color-4:#ffffff; /* fondo de contenido */
  --ast-global-color-5:#f8f3ed; /* fondo secundario */
  --ast-global-color-6:#f8f3ed;
  --ast-global-color-7:#e7d9ca; /* bordes */
  --ast-global-color-8:#3b2115;
}
::selection{background:#efe2d1;color:#3b2115}
input,textarea,select{caret-color:#a46a3d}

/* 2. Foco visible y coherente en todo el sitio */
:where(a,button,input,select,textarea,summary,[tabindex]):focus-visible{
  outline:2px solid #684027;outline-offset:3px;border-radius:4px;
}
/* Astra quita el contorno de los campos (input:focus{outline:none}); se devuelve al usar teclado. */
body :is(input,select,textarea):focus-visible{outline:2px solid #684027!important;outline-offset:2px!important}
/* Astra pone un punteado de 1px en enlaces y botones; el foco de teclado es igual en todo el sitio. */
body :is(a,button,summary,[tabindex]):focus-visible{outline:2px solid #684027!important;outline-offset:3px!important}
.pb-site-footer :is(a,button):focus-visible{outline-color:#f6e8da!important}

/* 3. Encabezado */
.site-header .menu-link{text-transform:uppercase}
.site-header .menu-link:hover,
.site-header .current-menu-item > .menu-link,
.site-header .current_page_item > .menu-link{color:var(--pb-caramel-ink)!important}
.ast-site-identity .site-title a{color:#3b2115!important}
.site-header .site-description{font-size:13px!important;color:#766759!important}

/* 4. Menú del celular (Astra ≤ 921px) */
.ast-header-break-point .site-description{display:none!important}
.ast-header-break-point .ast-mobile-menu-trigger-minimal,
.ast-header-break-point button.menu-toggle{
  display:inline-flex!important;align-items:center;justify-content:center;
  min-width:44px;min-height:44px;padding:10px!important;
  color:#3b2115!important;background:transparent!important;border-radius:8px;
}
.ast-header-break-point button.menu-toggle:hover,
.ast-header-break-point button.menu-toggle[aria-expanded="true"]{background:#f8f3ed!important;color:#3b2115!important}
.ast-header-break-point button.menu-toggle svg,
.ast-header-break-point button.menu-toggle .ast-mobile-svg{fill:currentColor!important;color:inherit!important;width:22px;height:22px}

.ast-mobile-header-content,
.ast-mobile-header-content .main-header-menu,
.ast-mobile-header-content .main-navigation,
.ast-mobile-header-content .ast-builder-menu-mobile{background:#f8f3ed!important}
.ast-mobile-header-content{border-top:1px solid #e7d9ca!important;border-bottom:1px solid #e7d9ca!important}
.ast-mobile-header-content .main-header-menu .menu-item > .menu-link,
.ast-header-break-point .ast-mobile-header-content .menu-item > .menu-link{
  display:flex!important;align-items:center;min-height:52px;
  padding:0 20px!important;background:transparent!important;
  color:#3b2115!important;font-size:14px!important;letter-spacing:.1em!important;
  border-bottom:1px solid #e7d9ca!important;
}
.ast-mobile-header-content .main-header-menu .menu-item:last-child > .menu-link{border-bottom:0!important}
.ast-header-break-point .ast-mobile-header-content .menu-item > .menu-link:hover,
.ast-header-break-point .ast-mobile-header-content .current-menu-item > .menu-link,
.ast-header-break-point .ast-mobile-header-content .current_page_item > .menu-link{background:#efe2d1!important;color:#3b2115!important}
.ast-header-break-point .ast-mobile-header-content .current-menu-item > .menu-link{font-weight:800!important}

/* 5. Campos heredados del modo oscuro (Mi cuenta, formularios de WooCommerce) */
body :is(input[type="text"],input[type="email"],input[type="password"],input[type="tel"],input[type="search"],input[type="number"],textarea,select){
  background-color:#fff;color:#3b2115;border-color:#d9c7b4;
}
body ::placeholder{color:#887362;opacity:1}
body label,body legend{color:#3b2115}
/* Mi cuenta: el plugin de venta imprime #os-piloto-cuenta-contraste, pensado
   para el tema oscuro (botones grises, enlaces #d4d4d4). Se gana con body.* */
body.woocommerce-page .woocommerce :is(input[type="text"],input[type="email"],input[type="password"],input[type="tel"],textarea,select){
  background:#fff!important;color:#3b2115!important;-webkit-text-fill-color:#3b2115!important;
  border:1px solid #d9c7b4!important;border-radius:8px!important;min-height:44px;caret-color:#a46a3d!important;
}
body.woocommerce-page .woocommerce :is(input,textarea,select):focus{outline:2px solid #684027!important;outline-offset:2px!important;border-color:#a46a3d!important}
body.woocommerce-page .woocommerce :is(input,textarea)::placeholder{color:#887362!important}
body.woocommerce-page .woocommerce :is(.button,button[type="submit"]){
  background:#6b3f25!important;color:#fff!important;border:0!important;border-radius:8px!important;
  min-height:44px;padding:0 22px!important;font:700 13px/1 'DM Sans',sans-serif!important;letter-spacing:.06em;
}
body.woocommerce-page .woocommerce :is(.button,button[type="submit"]):hover{background:#452817!important;color:#fff!important}
body.woocommerce-page .woocommerce a:not(.button),
body.woocommerce-page .woocommerce-MyAccount-navigation a{color:#684027!important;text-decoration:underline;text-underline-offset:3px}
body.woocommerce-page .woocommerce-MyAccount-navigation-link.is-active a{color:#3b2115!important;background:#efe2d1!important;border-color:#d9c7b4!important}
body.woocommerce-page .woocommerce :is(.woocommerce-info,.woocommerce-message,.woocommerce-error){
  background:#f8f3ed!important;color:#3b2115!important;-webkit-text-fill-color:#3b2115!important;border-top-color:#a46a3d!important;
}
body.woocommerce-page .woocommerce-password-hint,
body.woocommerce-page .woocommerce-privacy-policy-text,
body.woocommerce-page .woocommerce-privacy-policy-text p{color:#5a4638!important}
body.woocommerce-page .woocommerce-password-strength{color:#3b2115!important;background:#f8f3ed!important;border-color:#d9c7b4!important}
body.woocommerce-account .main-header-menu .current-menu-item > a{color:var(--pb-caramel-ink)!important}
body .woocommerce form .required,body .woocommerce .required{color:#a3261c!important;text-decoration:none}

/* 6. Plugin de venta (ficha, tallas, carrito, confirmar pedido): piel clara.
   El plugin trae una interfaz oscura (#191919, textos #f2f2f2). */
body .os-piloto-ui{color:#3b2115!important}
body .os-piloto-ui :is(h2,h3){color:#3b2115!important;font-family:'Cormorant Garamond',Georgia,serif;font-weight:600}
body .os-piloto-ui a:not(.os-piloto-cta):not(.button){color:#684027!important;text-decoration:underline;text-underline-offset:3px}
body .os-piloto-box{background:#f8f3ed!important;border:1px solid #e7d9ca!important;border-radius:14px!important;color:#3b2115!important}
/* Ficha sin tallas en línea: el aviso repetía lo que ya dice el botón. */
body #os-piloto:has(> .os-piloto-whatsapp-hint:only-child){display:none!important}
body .os-piloto-whatsapp-hint .os-piloto-arrow{color:#a46a3d!important}
body .os-piloto-size span{background:#fff!important;border:1px solid #d9c7b4!important;color:#3b2115!important;border-radius:8px!important;min-height:48px}
body .os-piloto-size input:checked + span{background:#3b2115!important;border-color:#3b2115!important;color:#fff!important}
body .os-piloto-size input:disabled + span{opacity:.45;text-decoration:line-through}
body .os-piloto-size input:focus-visible + span{outline:2px solid #684027!important;outline-offset:2px!important}
body .os-piloto-fit-note,body .os-piloto-aviso{background:#fff!important;border:1px solid #e7d9ca!important;border-radius:10px!important;color:#3b2115!important}
body .os-piloto-aviso.os-error{background:#fbeeec!important;border-color:#e3b4ae!important;color:#7a1f16!important}
body .os-piloto-ui :is(input[type="text"],input[type="search"],input[type="tel"],input[type="email"],input[type="number"],select,textarea){
  background:#fff!important;color:#3b2115!important;-webkit-text-fill-color:#3b2115!important;border:1px solid #d9c7b4!important;border-radius:8px!important;min-height:44px}
body .os-piloto-ui input[type="file"]{color:#3b2115!important}
body .os-piloto-destino::after{color:#684027!important}
body .os-piloto-cobertura,body .os-piloto-line small,body .os-piloto-admin-preview .os-piloto-summary-item small{color:#5a4638!important}
body .os-piloto-line,body .os-piloto-admin-preview .os-piloto-summary-item{border-color:#e7d9ca!important}
body .os-piloto-item img{background:#eef1f4!important;object-fit:contain!important}
body :is(.os-piloto-ui button,.os-piloto-cta){background:#6b3f25!important;color:#fff!important;border:0!important;border-radius:8px!important;min-height:46px;font-weight:700}
body :is(.os-piloto-ui button,.os-piloto-cta):hover{background:#452817!important;color:#fff!important}
body :is(.os-piloto-ui button.os-piloto-secondary,.os-piloto-secondary){background:#fff!important;color:#6b3f25!important;border:1px solid #6b3f25!important}
body :is(.os-piloto-ui button.os-piloto-secondary,.os-piloto-secondary):hover{background:#efe2d1!important;color:#3b2115!important}
body .os-piloto-ui .os-piloto-opcion{color:#3b2115!important;background:#fff!important;min-height:44px}
body .os-piloto-ui .os-piloto-opcion:hover,body .os-piloto-ui .os-piloto-opcion[aria-selected="true"]{background:#efe2d1!important}
body .os-piloto-floating{background:#6b3f25!important;color:#fff!important;box-shadow:0 6px 18px rgba(59,33,21,.25)}
body .os-piloto-floating:hover{background:#452817!important;color:#fff!important}

body.woocommerce-page .woocommerce form.login,
body.woocommerce-page .woocommerce form.register{border-color:#e7d9ca!important;border-radius:14px!important}
