/* Reset y Variables */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #1a5490;
    --secondary-color: #ff6b35;
    --accent-color: #2ecc71;
    --dark-color: #2c3e50;
    --light-color: #ecf0f1;
    --text-color: #333;
    --border-color: #ddd;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-hover: 0 4px 20px rgba(0,0,0,0.15);
}

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

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2563eb 100%);
    padding: 20px 0;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
    color: white;
}

.logo img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.logo h1 {
    font-size: 24px;
    font-weight: 700;
    white-space: nowrap;
}

.search-bar {
    flex: 1;
    max-width: 600px;
}

.search-form {
    display: flex;
    gap: 10px;
}

#search-input {
    flex: 1;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    outline: none;
    box-shadow: var(--shadow);
}

.search-btn {
    padding: 12px 30px;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.search-btn:hover {
    background-color: #e55a2b;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* Navbar con Categorías */
.navbar {
    background-color: white;
    padding: 15px 0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    margin-bottom: 20px;
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

.categories-wrapper {
    flex: 1;
    overflow: hidden;
    position: relative;
    mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 20px, black calc(100% - 20px), transparent);
}

.categories-carousel {
    display: flex;
    gap: 15px;
    padding: 5px 0;
    overflow-x: auto;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.categories-carousel::-webkit-scrollbar {
    display: none;
}

.category-item {
    padding: 10px 20px;
    background-color: var(--light-color);
    color: var(--dark-color);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    white-space: nowrap;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.category-item:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.nav-arrow {
    background-color: var(--primary-color);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.nav-arrow:hover {
    background-color: var(--secondary-color);
    transform: scale(1.1);
}

.nav-arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

/* Banners Carousel */
.banners-section {
    max-width: 1400px;
    margin: 0 auto 40px;
    padding: 0 20px;
    position: relative;
}

.banners-carousel {
    display: flex;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: var(--shadow-hover);
    height: 400px;
}

.banner-slide {
    min-width: 100%;
    height: 100%;
    position: relative;
}

.banner-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 32px;
    font-weight: bold;
}

.banner-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(255,255,255,0.9);
    color: var(--primary-color);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: var(--shadow);
}

.banner-arrow-left {
    left: 10px;
}

.banner-arrow-right {
    right: 10px;
}

.banner-arrow:hover {
    background-color: white;
    transform: translateY(-50%) scale(1.1);
}

.banner-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 15px;
}

.banner-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ccc;
    cursor: pointer;
    transition: all 0.3s ease;
}

.banner-dot.active {
    background-color: var(--primary-color);
    width: 30px;
    border-radius: 6px;
}

/* Main Content */
.main-content {
    max-width: 1400px;
    margin: 0 auto 40px;
    padding: 0 20px;
}

.section-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 30px;
    text-align: center;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 25px;
    margin-bottom: 40px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    border: 1px solid #f0f0f0;
    position: relative;
}

.product-card:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.15);
    border-color: var(--primary-color);
}

.product-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    background-color: var(--light-color);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 10px;
}

.product-info {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-grow: 1;
}

.product-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--dark-color);
    margin: 0;
    min-height: 40px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0;
}

.product-btn {
    padding: 10px 20px;
    background-color: var(--secondary-color);
    color: white;
    text-decoration: none;
    text-align: center;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-top: auto;
}

.product-btn:hover {
    background-color: #e55a2b;
    transform: translateY(-2px);
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.page-btn {
    padding: 10px 18px;
    background-color: white;
    color: var(--primary-color);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    border: 2px solid var(--primary-color);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.page-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.page-btn.active {
    background-color: var(--primary-color);
    color: white;
}

/* Brands Section */
.brands-section {
    background-color: white;
    padding: 40px 20px;
    margin-bottom: 40px;
}

.brands-section .section-title {
    margin-bottom: 30px;
}

.brands-carousel-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 15px;
    position: relative;
}

.brands-carousel {
    flex: 1;
    display: flex;
    gap: 30px;
    overflow-x: auto;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.brands-carousel::-webkit-scrollbar {
    display: none;
}

.brand-item {
    min-width: 150px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--light-color);
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.brand-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: grayscale(100%);
    transition: filter 0.3s ease;
}

.brand-item:hover img {
    filter: grayscale(0%);
}

.brand-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    font-weight: 600;
}

.brand-arrow {
    background-color: var(--primary-color);
    color: white;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.brand-arrow:hover {
    background-color: var(--secondary-color);
    transform: scale(1.1);
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--dark-color) 0%, #34495e 100%);
    color: white;
    padding: 50px 20px 20px;
    margin-top: 60px;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-bottom: 30px;
}

.footer-section h3 {
    font-size: 20px;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.footer-section p {
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-section i {
    color: var(--secondary-color);
    width: 20px;
}

.whatsapp-link {
    color: #25d366;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.whatsapp-link:hover {
    color: #128c7e;
    text-decoration: underline;
}

.social-icons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.social-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-icon:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px) scale(1.1);
}

.social-icon.whatsapp:hover {
    background-color: #25d366;
}

.map-container {
    position: relative;
}

.map-container iframe {
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.map-note {
    font-size: 12px;
    color: #bbb;
    margin-top: 10px;
    font-style: italic;
}

.footer-bottom {
    max-width: 1400px;
    margin: 0 auto;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    color: #bbb;
}

/* Responsive Design */
@media (max-width: 1200px) {
    .products-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 992px) {
    .header-container {
        flex-direction: column;
        gap: 20px;
    }
    
    .search-bar {
        max-width: 100%;
    }
    
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .footer-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .logo h1 {
        font-size: 18px;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .footer-container {
        grid-template-columns: 1fr;
    }
    
    .banners-carousel {
        height: 250px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .banner-arrow {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
    
    .category-item {
        padding: 8px 15px;
        font-size: 14px;
    }
}

