/* ============================================
   VARIABLES
   ============================================ */

:root {
    --primary: #8B7355;
    --secondary: #D4A574;
    --dark: #2C2C2C;
    --light: #F5F3F0;
    --white: #FFFFFF;
    --border: #E8E8E8;
    --success: #4CAF50;
    --danger: #E74C3C;
    
    --font-serif: 'Georgia', serif;
    --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    
    --radius: 8px;
    --shadow: 0 2px 8px rgba(0,0,0,0.1);
    --shadow-hover: 0 8px 20px rgba(0,0,0,0.15);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    color: var(--dark);
    background: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: 2.8rem;
}

h2 {
    font-size: 2rem;
    color: var(--dark);
}

h3 {
    font-size: 1.3rem;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   BOTONES
   ============================================ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: var(--radius);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    font-size: 0.95rem;
}

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

.btn-primary:hover {
    background: #6B5345;
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.btn-secondary {
    background: var(--secondary);
    color: var(--white);
}

.btn-secondary:hover {
    background: #C49463;
}

/* ============================================
   NAVBAR
   ============================================ */

.navbar {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
}

.logo-icon {
    font-size: 1.8rem;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-name {
    font-size: 1.1rem;
    color: var(--primary);
}

.logo-sub {
    font-size: 0.75rem;
    color: var(--secondary);
    letter-spacing: 1px;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.nav-link {
    font-weight: 600;
    font-size: 0.9rem;
    position: relative;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--secondary);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cart-btn {
    background: var(--light);
    border: none;
    padding: 10px 15px;
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 600;
    position: relative;
    transition: var(--transition);
    font-size: 0.9rem;
}

.cart-btn:hover {
    background: var(--secondary);
    color: var(--white);
}

.cart-count {
    background: var(--danger);
    color: var(--white);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    position: absolute;
    top: -8px;
    right: -8px;
}

.btn-whatsapp {
    background: #25D366;
    color: var(--white);
    padding: 10px 15px;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
}

.btn-whatsapp:hover {
    background: #1fb85c;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 2.5px;
    background: var(--dark);
    border-radius: 2px;
    transition: var(--transition);
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
    background: linear-gradient(135deg, #8B7355 0%, #6B5345 100%);
    color: var(--white);
    padding: 80px 20px;
    text-align: center;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 15px;
}

.hero p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    opacity: 0.95;
}

.hero .btn {
    padding: 15px 40px;
    font-size: 1rem;
}

/* ============================================
   BÚSQUEDA Y FILTROS
   ============================================ */

.search-section {
    padding: 30px 20px;
    background: var(--light);
}

.search-box {
    display: flex;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.search-box input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius) 0 0 var(--radius);
    font-size: 1rem;
    border-right: none;
}

.search-box button {
    padding: 12px 20px;
    background: var(--primary);
    color: var(--white);
    border: 1px solid var(--primary);
    border-radius: 0 var(--radius) var(--radius) 0;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.search-box button:hover {
    background: #6B5345;
}

.filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid var(--border);
    background: var(--white);
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
    font-size: 0.9rem;
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* ============================================
   PROMO BANNER
   ============================================ */

.promo-banner {
    background: linear-gradient(90deg, #E74C3C 0%, #C0392B 100%);
    color: var(--white);
    padding: 30px 20px;
    text-align: center;
}

.promo-content h2 {
    color: var(--white);
    font-size: 2rem;
    margin-bottom: 10px;
}

.promo-content p {
    font-size: 1rem;
    margin: 5px 0;
}

/* ============================================
   PRODUCTOS
   ============================================ */

.products-section {
    padding: 60px 20px;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    color: var(--dark);
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
}

.product-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
    cursor: pointer;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-hover);
    border-color: var(--secondary);
}

.product-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    position: relative;
    background: var(--light);
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--danger);
    color: var(--white);
    padding: 5px 10px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 0.85rem;
}

.product-info {
    padding: 15px;
}

.product-category {
    font-size: 0.8rem;
    color: var(--secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 5px;
}

.product-name {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--dark);
}

.product-description {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 12px;
    line-height: 1.4;
}

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

.product-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary);
}

.product-original-price {
    font-size: 0.9rem;
    color: #999;
    text-decoration: line-through;
}

.product-discount {
    background: var(--danger);
    color: var(--white);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
}

.btn-view {
    width: 100%;
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 10px;
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition);
}

.btn-view:hover {
    background: #6B5345;
}

/* ============================================
   CARRITO MODAL
   ============================================ */

.cart-modal {
    position: fixed;
    right: -400px;
    top: 0;
    width: 400px;
    height: 100vh;
    background: var(--white);
    box-shadow: -5px 0 20px rgba(0,0,0,0.2);
    transition: right 0.3s ease;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.cart-modal.open {
    right: 0;
}

.cart-content {
    display: flex;
    flex-direction: column;
    height: 100%;
    padding: 20px;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 15px;
}

.cart-header h3 {
    margin: 0;
}

.close-cart {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

.cart-items {
    flex: 1;
    overflow-y: auto;
}

.cart-item {
    display: flex;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid var(--border);
}

.cart-item-image {
    width: 80px;
    height: 80px;
    border-radius: var(--radius);
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 600;
    margin-bottom: 5px;
}

.cart-item-price {
    color: var(--primary);
    font-weight: 700;
    margin-bottom: 8px;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    gap: 5px;
}

.cart-item-quantity button {
    background: var(--light);
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.cart-item-remove {
    color: var(--danger);
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    margin-top: 8px;
}

.empty-cart {
    text-align: center;
    color: #999;
    padding: 40px 20px;
}

.cart-total {
    padding: 20px 0;
    border-top: 2px solid var(--border);
    border-bottom: 2px solid var(--border);
    display: flex;
    justify-content: space-between;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 20px;
}

#checkoutBtn {
    width: 100%;
}

/* ============================================
   MODAL DE PRODUCTO
   ============================================ */

.product-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 1500;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.product-modal.open {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius);
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    z-index: 10;
    color: var(--dark);
}

.modal-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 30px;
}

#modalImage {
    width: 100%;
    border-radius: var(--radius);
    max-height: 400px;
    object-fit: cover;
}

.modal-info h2 {
    margin-bottom: 15px;
}

.modal-description {
    color: #666;
    line-height: 1.8;
    margin-bottom: 20px;
}

.modal-details {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    padding: 20px 0;
    margin-bottom: 20px;
}

.modal-details p {
    margin: 10px 0;
    font-size: 0.95rem;
}

.modal-price {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.modal-price .price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.modal-price .original-price {
    color: #999;
    text-decoration: line-through;
}

.modal-actions {
    display: flex;
    gap: 15px;
}

.modal-actions input {
    width: 60px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    text-align: center;
    font-weight: 600;
}

.modal-actions button {
    flex: 1;
}

/* ============================================
   SECCIÓN DE OFERTAS
   ============================================ */

.offers-section {
    padding: 60px 20px;
    background: var(--light);
}

.offers-section h2 {
    text-align: center;
    margin-bottom: 40px;
}

.offers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}

.offer-card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    position: relative;
    transition: var(--transition);
}

.offer-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.offer-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--danger);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.9rem;
}

.offer-card h3 {
    margin-top: 15px;
    margin-bottom: 10px;
}

.offer-card p {
    color: #666;
    margin-bottom: 20px;
}

.btn-offer {
    display: inline-block;
    padding: 10px 20px;
    background: var(--primary);
    color: var(--white);
    border-radius: var(--radius);
    font-weight: 600;
    transition: var(--transition);
}

.btn-offer:hover {
    background: #6B5345;
}

/* ============================================
   CONTACTO
   ============================================ */

.contact-section {
    padding: 60px 20px;
}

.contact-section h2 {
    text-align: center;
    margin-bottom: 40px;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.contact-info {
    text-align: center;
}

.contact-info h3 {
    margin-bottom: 15px;
    color: var(--primary);
}

.contact-info p {
    color: #666;
    margin-bottom: 15px;
    line-height: 1.8;
}

.contact-info .btn {
    display: inline-block;
}

/* ============================================
   ABOUT SECTION
   ============================================ */

.about-section {
    padding: 60px 20px;
    background: var(--light);
}

.about-section h2 {
    text-align: center;
    margin-bottom: 40px;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.about-text {
    color: #666;
    line-height: 1.8;
}

.about-text p {
    margin-bottom: 15px;
}

.about-text ul {
    list-style: none;
    margin: 20px 0;
}

.about-text li {
    margin: 10px 0;
}

.about-image img {
    width: 100%;
    border-radius: var(--radius);
    box-shadow: var(--shadow-hover);
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
    background: var(--dark);
    color: var(--white);
    padding: 40px 20px 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.footer-brand h3 {
    color: var(--secondary);
    margin-bottom: 10px;
}

.footer-brand p {
    color: #aaa;
}

.footer-column h4 {
    margin-bottom: 15px;
    color: var(--secondary);
}

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

.footer-column li {
    margin-bottom: 10px;
}

.footer-column a {
    color: #aaa;
    transition: var(--transition);
}

.footer-column a:hover {
    color: var(--secondary);
}

.footer-bottom {
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    color: #aaa;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }
    
    .hamburger {
        display: flex;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .cart-modal {
        width: 100%;
        right: -100%;
    }
    
    .modal-body {
        grid-template-columns: 1fr;
        gap: 20px;
        padding: 20px;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .about-content {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .navbar-container {
        gap: 10px;
    }
    
    .logo-text {
        display: none;
    }
    
    .nav-right {
        gap: 8px;
    }
    
    .btn-whatsapp {
        padding: 8px 12px;
        font-size: 0.8rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .filters {
        gap: 5px;
    }
    
    .filter-btn {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
}
