/*
Theme Name:   RedStihl
Theme URI:    https://grupodopamina.cl/
Author:       Grupo Dopamina
Version:      1.0
Text Domain:  redstihl
*/

@font-face {
	font-family: 'ContrafaceText';
	src: url('fonts/STIHLContrafaceText.woff2') format('woff2');
	font-weight: normal;
	font-style: normal;
}

@font-face {
	font-family: 'ContrafaceText-Bold';
	src: url('fonts/STIHLContrafaceText-Bold.woff2') format('woff2');
	font-weight: bold;
	font-style: normal;
}

@font-face {
	font-family: 'ContrafaceDisplayTitling';
	src: url('fonts/STIHLContrafaceDisplayTitling.woff2') format('woff2');
	font-weight: normal;
	font-style: normal;
}

@font-face {
	font-family: 'Ampero-Light';
	src: url('fonts/Ampero-Light.woff2') format('woff2');
	font-weight: 300;
	font-style: normal;
}

body {
	margin: 0;
	font-family: sans-serif;
}

section {
	padding: 60px;
	color: #fff;
}

.hidden {
	display: none;
}

.btn {
	display: inline-block;
	padding: 0.8em 1.5em;
	background: #ed720f;
	color: #fff !important;
	text-decoration: none !important;
	font-size: 1.4em;
	font-weight:normal;
	border-radius: 5px;
	border:2px solid #ed720f;
	text-transform: uppercase;
	font-family: 'ContrafaceDisplayTitling', sans-serif;
	transition: all ease 0.3s;
	white-space: nowrap;
}
.btn.small {
	flex: 1;
	padding: 0.6em;
	text-align: center;
}
.btn:hover{
	background: #fff;
	color: #d65a00 !important;
}
.btn.green{
	background: #00b430;
	border:2px solid #00b430;
}
.btn.green:hover{
	background: #fff;
	color: #00b430;
}
.btn:disabled{
	background: #ccc !important;
	color: #333 !important;
	border-color:#ccc !important;
	pointer-events: none;
	cursor: not-allowed;
}

input[type="text"],
input[type="email"],
input[type="tel"], select {
	padding: 8px 16px;
	font-size: 1.4em;
	border-radius: 5px;
	border: none;
	font-family: 'ContrafaceText', Arial, Helvetica, sans-serif;
	color:#000;
}
input[type="text"]:not(:placeholder-shown),
input[type="email"]:not(:placeholder-shown),
input[type="tel"]:not(:placeholder-shown) {
	font-size:2em;
	padding: 4px 8px;
}
::placeholder {
	color: #999;
}

p{
	font-size:1.3em;
	color: #333;
	line-height: 20px;
	margin-bottom:10px;
}

h1{
	font-family: 'ContrafaceDisplayTitling', sans-serif;
	font-size: 4em;
	text-align: center;
	text-transform: uppercase;
	color: #000;
	margin-bottom:20px;
}
h2 {
	font-family: 'ContrafaceDisplayTitling', sans-serif;
	font-size: 3.4em;
	text-align: center;
	text-transform: uppercase;
	color: #000;
}
h3 {
	font-family: 'ContrafaceDisplayTitling', sans-serif;
	font-size: 3em;
	text-align: center;
	text-transform: uppercase;
	color: #000;
}
h4 {
	font-family: 'ContrafaceDisplayTitling', sans-serif;
	font-size: 2.4em;
	text-align: center;
	text-transform: uppercase;
	color: #000;
}

.line-bottom::after {
	content: "";
	display: block;
	width: 30px;
	height: 5px;
	background: #333;
	height: 10px;
}

.page-content {
	min-height:50vh;
}
.page-content p, .page-content ol, .page-content ul, .page-content th, .page-content td {
	font-family: 'ContrafaceText', sans-serif;
	font-size: 1.6em;
	line-height: 1.5;
	color: #333;
}
.page-content th{
	font-family: 'ContrafaceText-Bold', sans-serif;
	background:#333;
	color:#fff;
	text-align:left;
	padding: 12px 8px;
}

.page-content strong{
    font-family: 'ContrafaceText-Bold', sans-serif;
}
.page-content td{
	padding: 12px 8px;
	border-bottom: 1px solid #eee;
	text-align: left;
}
.page-content a {
	color: #ed720f;
	text-decoration: none;
}
.page-content a:hover {
	text-decoration: underline;
}
.page-content td .btn{
	color:#fff;
	text-decoration: none !important;
	font-size: 0.875em;
}
.page-content td .btn:hover{
	color:#ed720f;
}

.separador{
	border-top: 2px solid #ed720f;
	width: 100%;
	margin: 40px 0;
}

.category-slider-section {
    padding: 60px 0;
    background-color: #f5f5f5;
    overflow: hidden;
}

.swiper {
    --swiper-navigation-color: #ed720f; /* Define el color para las flechas */
    --swiper-pagination-color: #ed720f; /* Define el color para la paginación activa */

    /* Si quieres que las flechas sean un poco más grandes, puedes añadir esto: */
    --swiper-navigation-size: 34px; /* El valor por defecto es 44px, puedes ajustarlo */
}

.swiper {
    width: 100%;
    margin: 0 auto;
    padding: 20px 0 50px;
}


.swiper-slide {
    height: 100%;
    display: flex;
    flex-direction: column;
}


.category-card {
    background-color: #ffffff;
    text-align: center;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-image-container {
    height: 220px; 
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
}

.card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;	
}

.card-content {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-title {
    font-size: 22px;
    font-weight: bold;
    text-transform: uppercase;
    color: #333;
    margin: 0 0 10px 0;
}

.card-description {
    min-height: 3.2em; 
    font-size: 16px;
    color: #666;
    line-height: 1.6;
    margin: 0 0 25px 0;
}

.card-button {
    display: inline-block;
    background-color: #ed720f;
    color: #fff;
    padding: 14px 28px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease;
    align-self: center; /* Centra el botón horizontalmente */
}

.card-button:hover {
    background-color: #d86f12;
}

/* Personalización de Swiper (sin cambios) */
.swiper-button-next, .swiper-button-prev {
    color: #ed720f;
}

.swiper-pagination-bullet-active {
    background: #ed720f;
}


#productos-bateria .swiper-slide {
    height: 100%;
    display: flex;
    flex-direction: column;
}

#productos-bateria .category-card {
    background-color: #ffffff;
    text-align: center;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.07);
    display: flex;
    flex-direction: column;
    flex-grow: 1; /* La tarjeta se estira para llenar la altura del slide */
}

#productos-bateria .card-image-container {
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
}

#productos-bateria .card-image-container img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* --- CAMBIO CLAVE 1: El contenedor del contenido ahora es flexible --- */
#productos-bateria .card-content {
    flex-grow: 1; /* Ocupa todo el espacio vertical sobrante */
    display: flex;
    flex-direction: column;
    /* Empuja el título hacia arriba y el botón hacia abajo */
    justify-content: space-between; 
}

/* --- CAMBIO CLAVE 2: Altura mínima para el título --- */
#productos-bateria .card-title {
    font-size: 22px;
    font-weight: bold;
    text-transform: uppercase;
    color: #333;
    margin: 0 0 15px 0; /* Un poco de margen inferior */
    /* Reservamos espacio suficiente para 2 líneas de texto, incluso si solo hay una.
       Esto evita el "salto" de altura entre tarjetas. */
    min-height: 2.8em; /* 2 líneas (line-height 1.4 * 2) */
    display: flex; /* Para centrar verticalmente el texto si es una sola línea */
    align-items: center;
    justify-content: center;
}

#productos-bateria .card-button {
    display: inline-block;
    background-color: #ed720f;
    color: #fff;
    padding: 14px 28px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: bold;
    transition: background-color 0.3s ease;
    align-self: center;
}

#productos-bateria .card-button:hover {
    background-color: #d86f12;
}

/* El nuevo contenedor general necesita ser un punto de referencia */
.swiper-container-wrapper {
    position: relative;
    padding: 0 40px; /* Espacio para que las flechas no se salgan de la pantalla */
}

/* Las flechas se posicionan relativas al nuevo contenedor */
.swiper-button-next,
.swiper-button-prev {
    /* Mantenemos el color naranja */
    color: #ed720f;
}

/* La paginación ahora está en el flujo normal del documento */
.swiper-pagination {
    /* Ya no necesita 'position: absolute' ni 'bottom' */
    position: static; 
    margin-top: 25px; /* Creamos el espacio que querías debajo del slider */
}

/* Hacemos que los bullets activos sigan siendo naranjas */
.swiper-pagination-bullet-active {
    background: #ed720f;
}

.swiper-pagination-bullet.swiper-pagination-bullet-active{
    background: #ed720f;
}
/* ==========================================================================
   Estilos para Slider de Marcas - Logos Rectangulares y Uniformes
   ========================================================================== */

.brands-slider-section .brand-logo {
    /* 1. Creamos el "marco" rectangular invisible para cada logo. */
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%; /* El marco ocupa todo el espacio del slide */
    height: 120px; /* Definimos una altura fija para todos los marcos */
    padding: 10px; /* Un poco de espacio interno */
    box-sizing: border-box;
}

.brands-slider-section .brand-logo img {
    /* 2. Hacemos que la imagen se comporte dentro del marco. */
    max-width: 100%;
    max-height: 100%;

    /* 3. La magia de object-fit:
       - 'contain' asegura que la imagen entera sea visible sin deformarse.
       - La imagen se redimensiona para caber dentro de las dimensiones del marco. */
    object-fit: contain;

    /* Estilos adicionales para un look más limpio */
    filter: grayscale(100%);
    opacity: 0.8;
    transition: all 0.3s ease;
}

.brands-slider-section .brand-logo img:hover {
    filter: grayscale(0%);
    opacity: 1;
}

.brands-slider-section .swiper-button-prev,
.brands-slider-section .swiper-button-next,
.brands-slider-section .swiper-pagination {
     color: #ed720f;
}

/* ==========================================================================
   Estilos Mejorados para el Acordeón de Categorías
   ========================================================================== */

/* --- Estilo para las categorías principales --- */
.category-accordion .parent-cat {
    position: relative;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    margin-bottom: 8px;
    background-color: #f9f9f9; /* Color de fondo gris tenue */
    transition: background-color 0.2s ease;
}
.category-accordion .parent-cat.active {
    background-color: #f0f0f0;
}
.category-accordion .parent-cat a {
    display: block;
    padding: 12px 35px 12px 15px; /* Espacio para el texto y para el botón */
    text-decoration: none;
    color: #333;
    font-weight: bold;
    text-transform: uppercase;
}

/* --- Estilo para el botón +/- --- */
.category-accordion .accordion-toggle {
    position: absolute;
    right: 0;
    top: 0;
    width: 45px;
    height: 100%;
    cursor: pointer;
    font-size: 24px;
    font-weight: bold;
    color: #ed720f; /* Color naranja solicitado */
    display: flex;
    align-items: center;
    justify-content: center;
    border-left: 1px solid #e0e0e0;
}

/* --- Estilo para la lista de sub-categorías --- */
.sub-cat-list {
    display: none;
    list-style: none; /* Quitamos las viñetas por defecto */
    margin: 0;
    padding: 0 15px 15px 30px; /* Espaciado interno */
    border-top: 1px solid #e0e0e0;
}
.sub-cat-list li {
    padding: 6px 0;
}

/* --- Estilo para el TEXTO de las sub-categorías (La corrección principal) --- */
.sub-cat-list li a {
    font-size: .9rem;  /* Tamaño más pequeño y predecible. ¡Ajusta este valor si es necesario! */
    font-weight: normal; /* Asegura que no sea negrita */
    text-transform: none; /* Asegura que no esté todo en mayúsculas */
    color: #555;
    text-decoration: none;
    transition: color 0.2s ease;
}
.sub-cat-list li a:hover {
    color: #ed720f;
}


.product-title-action {
    font-size: .9em !important;
    margin: 10px 0 !important;
    text-align: center !important;
    min-height: 3em !important; /* Asegura espacio para dos líneas */
    display: flex !important; /* Para centrar verticalmente el texto si es una sola línea */
    align-items: center !important;
    justify-content: center !important;
}

.btn-small-action {
    margin-top: auto !important;
    display: inline-block !important;
    background-color: #ed720f !important;
    color: #fff !important;
    padding: 8px !important;
    border-radius: 5px !important;
    text-decoration: none !important;
    font-weight: bold !important;
    transition: background-color 0.3s ease !important;
    align-self: center !important; /* Centra el botón horizontalmente */
    font-size: .8em !important;
    width: 100% !important;
    text-align: center !important;
    text-wrap: wrap !important;
}

.btn-small-action:hover {
    background-color: #d86f12 !important;
}

.woocommerce ul.products {
    display: flex;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0; 
}

.woocommerce ul.products li.product {
    float: none; 
    display: flex;
    flex-direction: column;
    height: auto;
    background: #ffffff; /* Fondo blanco para la tarjeta */
    border: 1px solid #e9e9e9; /* Borde gris muy claro y sutil */
    border-radius: 8px; /* Esquinas redondeadas para un look moderno */
    padding: 15px; /* Un poco de espacio interior */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05); /* Sombra suave para dar profundidad */
    transition: all 0.3s ease-in-out; 
}

.woocommerce ul.products li.product .button, .wc-block-cart__submit-button {
    margin-top: auto !important;
    display: inline-block !important;
    background-color: #ed720f !important;
    color: #fff !important;
    padding: 8px !important;
    border-radius: 5px !important;
    text-decoration: none !important;
    font-weight: bold !important;
    transition: background-color 0.3s ease !important;
    align-self: center !important; /* Centra el botón horizontalmente */
    font-size: .8em !important;
    width: 100% !important;
    text-align: center !important;
    text-wrap: wrap !important;
}

.wc-block-components-checkout-place-order-button {
    margin-top: auto !important;
    background-color: #ed720f !important;
    color: #fff !important;
    padding: 8px !important;
    border-radius: 5px !important;
    text-decoration: none !important;
    font-weight: bold !important;
    align-self: center !important; /* Centra el botón horizontalmente */
    font-size: .8em !important;
    text-align: center !important;
    text-wrap: wrap !important;
}

.wc-block-cart__submit-button {
    font-size: 1.2em !important;
    padding-top: 12px !important;
}

.woocommerce-breadcrumb {
    font-size: 16px !important;
    color: #222 !important;
    text-transform: capitalize;
}

.woocommerce-breadcrumb a {
    text-decoration: none !important;
    font-weight: bold !important;
    text-transform: capitalize !important;
}

.woocommerce-product-attributes-item {
    font-size: 0.9em !important;
}

.woocommerce-product-attributes-item p {
    font-size: 0.9em !important;
    padding: 8px !important;
}

.woocommerce table.shop_attributes tr:nth-child(even) th {
    background: #33333397 !important;
}

.woocommerce nav.woocommerce-pagination.blog ul li a.current {
    background: #e9e6ed;
    color: #816f98;
    font-size: 1.2em;
}

.woocommerce nav.woocommerce-pagination.blog ul li a {
    margin: 0;
    text-decoration: none;
    padding: 0;
    line-height: 1;
    font-size: 1.6em;
    font-weight: 400;
    padding: .6em;
    min-width: 1em;
    display: block;
    color: #ed720f;
    font-family: 'ContrafaceText', sans-serif;
}

.woocommerce nav.woocommerce-pagination.blog ul li span {
    margin: 0;
    text-decoration: none;
    padding: 0;
    line-height: 1;
    font-size: 1.6em;
    font-weight: 400;
    padding: .6em;
    min-width: 1em;
    display: block;
    font-family: 'ContrafaceText', sans-serif;
}

.wc-block-checkout__add-note {
    color: #000 !important;
}

#add_payment_method table.cart img, .woocommerce-cart table.cart img, .woocommerce-checkout table.cart img {
    width: 150px;
    box-shadow: none;
}

@media (max-width: 768px) {
	.footer-nav li{
		text-align: center;
	}
	.footer-nav ul.separado {
		padding-right: 0;
		padding-bottom:20px;
		border-right: none;
		border-bottom: 2px solid #fff;
	}
	section {
		padding: 20px;
	}
}