/**
 * ============================================
 * ESTILOS PRINCIPALES DEL SITIO
 * Sistema de repuestos de tractores
 * ============================================
 */

/* ============================================
   RESET Y CONFIGURACIÓN BASE
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Colores principales */
    --primary-color: #21618C; 
    --primary-dark: #2876a9;
    --secondary-color: #308FCF;
    --accent-color: #e74c3c;
    
    /* Colores de fondo */
    --bg-light: #f8f9fa;
    --bg-dark: #273746;
    
    /* Colores de texto */
    --text-dark: #333;
    --text-light: #666;
    --text-white: #fff;
    
    /* Sombras */
    --shadow-sm: 0 2px 4px rgba(0,0,0,0.1);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.15);
    
    /* Transiciones */
    --transition: all 0.3s ease;
    
    /* Tamaños */
    --header-height: 70px;
    --container-max-width: 1200px;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
}

/* Contenedor principal */
.container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 15px;
}

/* Títulos de sección */
.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 3rem;
    color: var(--primary-color);
    position: relative;
    padding-bottom: 1rem;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--secondary-color);
}

/* ============================================
   ENCABEZADO Y NAVEGACIÓN
   ============================================ */
.header {
    background-color: var(--bg-dark);
    color: var(--text-white);
    height: var(--header-height);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-md);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

/* Logo */
.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--text-white);
}

.logo img {
    
    width: 200px;
    height: 63px;
    /* height: 55px; */
    /* margin-bottom: 48px; */
}

img{
    display: block;
    margin-top: -11px;
    width: 100%;
    height: 100%;
}

/*.logo i {
    font-size: 2rem;
    color: var(--primary-color);
}*/

/* Navegación */
.nav-list {
    display: flex;
    list-style: none;
    gap: 2rem;
}

.nav-list a {
    color: var(--text-white);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: 5px;
}

.nav-list a:hover,
.nav-list a.active {
    background-color: var(--primary-color);
    transform: translateY(-2px);
}

/* Botón menú móvil */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--text-white);
    transition: var(--transition);
}

/* ============================================
   SECCIÓN HERO
   ============================================ */
.hero {
    position: relative;
    height: 600px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-white);
    overflow: hidden;
}

/* Overlay con imagen de fondo y capa oscura para legibilidad */
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('../assets/img/img.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* Capa oscura sobre la imagen para mejorar legibilidad del texto */
.hero-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0.6) 50%,
        rgba(0, 0, 0, 0.5) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.8);
    animation: fadeInUp 1s ease;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    line-height: 1.8;
    background-color: rgba(0, 0, 0, 0.7);
    padding: 1.5rem 2rem;
    border-radius: 10px;
    backdrop-filter: blur(5px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: fadeInUp 1s ease 0.2s both;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease 0.4s both;
}

/* Animación de entrada */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   BOTONES
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 50px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: var(--text-white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background-color: #21618C;
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-white);
    border: 2px solid var(--text-white);
}

.btn-secondary:hover {
    background-color: var(--text-white);
    color: var(--primary-color);
    transform: translateY(-3px);
}

/* ============================================
   SECCIÓN DE CARACTERÍSTICAS
   ============================================ */
.features {
    padding: 5rem 0;
    background-color: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    text-align: center;
    padding: 2rem;
    border-radius: 10px;
    transition: var(--transition);
    background-color: white;
    box-shadow: var(--shadow-sm);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: var(--text-white);
    border-radius: 50%;
    font-size: 2rem;
}

.feature-card h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

.feature-card p {
    color: var(--text-light);
    line-height: 1.8;
}

/* ============================================
   SECCIÓN DE PRODUCTOS
   ============================================ */
.products-showcase {
    padding: 80px 0;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    position: relative;
    overflow: hidden;
}

.products-showcase::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
    pointer-events: none;
}

.products-showcase .container {
    position: relative;
    z-index: 1;
}

.products-intro {
    text-align: center;
    font-size: 1.1rem;
    color: #555;
    margin-bottom: 50px;
    font-weight: 300;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 25px;
    max-width: 1000px;
    margin: 0 auto;
}

.product-item {
    background: white;
    padding: 30px 20px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    cursor: default;
    border: 2px solid transparent;
}

.product-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.product-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.product-item:hover .product-icon {
    transform: rotateY(360deg);
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
}

.product-icon i {
    font-size: 32px;
    color: white;
}

.product-item h4 {
    margin: 0;
    font-size: 1rem;
    color: #333;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* Responsive */
@media (max-width: 768px) {
    .products-showcase {
        padding: 60px 0;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .product-item {
        padding: 25px 15px;
    }
    
    .product-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 15px;
    }
    
    .product-icon i {
        font-size: 28px;
    }
    
    .product-item h4 {
        font-size: 0.9rem;
    }
    
    .products-intro {
        font-size: 1rem;
        margin-bottom: 35px;
        padding: 0 15px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .product-item {
        padding: 20px 10px;
    }
    
    .product-icon {
        width: 50px;
        height: 50px;
    }
    
    .product-icon i {
        font-size: 24px;
    }
}

/* ============================================
   SECCIÓN DE MARCAS
   ============================================ */
.brands {
    padding: 5rem 0;
    background-color: var(--bg-light);
}

.brands-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.brand-item-link {
    text-decoration: none;
    display: block;
}

.brand-item {
    background-color: white;
    padding: 2rem;
    text-align: center;
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    border-radius: 10px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.brand-item:hover {
    transform: translateY(-10px) scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* Estilos para logos de marcas */
.brand-logo {
    max-width: 100%;
    max-height: 100px;
    width: auto;
    height: auto;
    object-fit: contain;
    /* Efecto gris por defecto */
    filter: grayscale(100%) brightness(1.2);
    transition: all 0.4s ease;
}

/* Efecto hover: quitar gris y mostrar color */
.brand-item:hover .brand-logo {
    filter: grayscale(0%) brightness(1);
    transform: scale(1.1);
}

/* Para navegadores que no soporten filter */
@supports not (filter: grayscale(100%)) {
    .brand-logo {
        opacity: 0.6;
    }
    
    .brand-item:hover .brand-logo {
        opacity: 1;
    }
}

/* ============================================
   LLAMADO A LA ACCIÓN (CTA)
   ============================================ */
.cta {
    padding: 5rem 0;
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    color: var(--text-white);
    text-align: center;
}

.cta-content h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-content p {
    font-size: 1.3rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

/* ============================================
   PIE DE PÁGINA
   ============================================ */
/*.footer {
    background-color: var(--bg-dark);
    color: var(--text-white);
    padding: 3rem 0 1rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col h3 {
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.footer-list {
    list-style: none;
}

.footer-list li {
    padding: 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-list a {
    color: var(--text-white);
    text-decoration: none;
    transition: var(--transition);
}

.footer-list a:hover {
    color: var(--secondary-color);
    padding-left: 5px;
}

.footer-list i {
    color: var(--primary-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--primary-color);
    color: var(--text-white);
    border-radius: 50%;
    transition: var(--transition);
    text-decoration: none;
}

.social-links a:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}*/

/******* .footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    opacity: 0.7;
} ********/
/* Sección inferior del footer */ /**
.footer-bottom {
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-credits {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 2rem;
}

.company-info {
    flex: 1;
    text-align: left;
}

.company-info p {
    margin: 0.5rem 0;
}

.footer-tagline {
    font-size: 0.85rem;
    opacity: 0.7;
} ****/

/* ============================================
   ESTILOS FOOTER RESPONSIVE
   ============================================ */

.footer {
    background-color: var(--bg-dark);
    color: white;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
    overflow-x: hidden;
}

.footer .container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-col {
    min-width: 0; /* Importante para permitir que el contenido se ajuste */
}

.footer-col h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--secondary-color);
    font-weight: 600;
    word-wrap: break-word;
}

.footer-col p {
    line-height: 1.6;
    opacity: 0.9;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.footer-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-list li {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.footer-list li i {
    margin-top: 0.2rem;
    flex-shrink: 0;
    opacity: 0.8;
}

.footer-list li span {
    word-break: break-word;
    overflow-wrap: break-word;
}

.footer-list li a {
    color: white;
    text-decoration: none;
    opacity: 0.9;
    transition: var(--transition);
}

.footer-list li a:hover {
    opacity: 1;
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    flex-wrap: wrap;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: var(--transition);
    text-decoration: none;
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding-top: 2rem;
    margin-top: 2rem;
}

.footer-credits {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.company-info {
    flex: 1;
    min-width: 250px;
}

.company-info p {
    margin: 0.5rem 0;
    opacity: 0.9;
    word-wrap: break-word;
}

.footer-tagline {
    font-size: 0.85rem;
    opacity: 0.7 !important;
}

.developer-credit {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    opacity: 0.8;
    flex-wrap: wrap;
}

.developer-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: white;
    text-decoration: none;
    transition: var(--transition);
    padding: 0.25rem 0.5rem;
    border-radius: 5px;
}

.developer-link:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.1);
}

.developer-logo {
    height: 20px;
    width: auto;
    max-width: 100px;
}

.developer-name {
    font-weight: 600;
}

/* ============================================
   RESPONSIVE - TABLETS
   ============================================ */
@media (max-width: 992px) {
    .footer {
        padding: 2.5rem 0 1rem;
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
    
    .footer-col:last-child {
        grid-column: 1 / -1;
    }
}

/* ============================================
   RESPONSIVE - MÓVILES
   ============================================ */
@media (max-width: 768px) {
    .footer {
        padding: 2rem 0 1rem;
        margin-top: 3rem;
    }
    
    .footer .container {
        padding: 0 0.5rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-col {
        text-align: left;
    }
    
    .footer-col h3 {
        font-size: 1.1rem;
        margin-bottom: 0.8rem;
    }
    
    .footer-list li {
        font-size: 0.9rem;
        margin-bottom: 0.6rem;
    }
    
    .social-links {
        justify-content: flex-start;
    }
    
    .social-links a {
        width: 38px;
        height: 38px;
        font-size: 1.1rem;
    }
    
    .footer-bottom {
        padding-top: 1.5rem;
        margin-top: 1.5rem;
    }
    
    .footer-credits {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .company-info {
        min-width: 100%;
    }
    
    .company-info p {
        font-size: 0.85rem;
    }
    
    .developer-credit {
        justify-content: center;
        font-size: 0.85rem;
    }
}

/* ============================================
   RESPONSIVE - MÓVILES PEQUEÑOS
   ============================================ */
@media (max-width: 480px) {
    .footer {
        padding: 1.5rem 0 1rem;
    }
    
    .footer-grid {
        gap: 1.5rem;
    }
    
    .footer-col h3 {
        font-size: 1rem;
    }
    
    .footer-list li {
        font-size: 0.85rem;
        gap: 0.4rem;
    }
    
    .footer-list li i {
        font-size: 0.9rem;
    }
    
    .social-links a {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    
    .company-info p {
        font-size: 0.8rem;
    }
    
    .footer-tagline {
        font-size: 0.75rem;
    }
    
    .developer-credit {
        font-size: 0.75rem;
    }
    
    .developer-logo {
        height: 16px;
    }
}

/* Prevenir desbordamiento de texto largo */
@media (max-width: 768px) {
    .footer * {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
}


/* Crédito del desarrollador */
.developer-credit {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9rem;
    opacity: 0.8;
}

.developer-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    color: white;
    padding: 0.5rem 1rem;
    background: rgba(255,255,255,0.1);
    border-radius: 25px;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.2);
}

.developer-link:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Opción 1: Logo/Imagen */
.developer-logo {
    width: 30px;
    height: 30px;
    object-fit: contain;
    border-radius: 50%;
    /*background: white;
    padding: 2px;*/
}

.developer-logo { 
    margin-top: -4px;
}


/* ============================================
   BOTÓN FLOTANTE DE WHATSAPP
   ============================================ */
.whatsapp-float {
    position: fixed;
    bottom: 150px;
    right: 30px;
    width: 60px;
    height: 60px;
    background-color: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    z-index: 999;
    text-decoration: none;
    animation: pulse 2s infinite;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    background-color: #128C7E;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    50% {
        box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
    }
}

/* ============================================
   RESPONSIVE - TABLETS
   ============================================ */
@media (max-width: 768px) {
    /* Menú hamburguesa visible */
    .menu-toggle {
        display: flex;
    }
    
    /* Navegación móvil */
    .nav {
        position: absolute;
        top: var(--header-height);
        left: 0;
        right: 0;
        background-color: var(--bg-dark);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }
    
    .nav.active {
        max-height: 400px;
    }
    
    .nav-list {
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
    }
    
    .nav-list li {
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-list a {
        display: block;
        padding: 1rem 2rem;
    }
    
    /* Hero más pequeño */
    .hero {
        height: 500px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
        padding: 1rem 1.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

/* ============================================
   RESPONSIVE - MÓVILES
   ============================================ */
@media (max-width: 480px) {
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        padding: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .cta-content h2 {
        font-size: 1.8rem;
    }
    
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
}