/* === ESTILOS ESPECÍFICOS PARA EL CATÁLOGO === */

.menu-container {
    min-height: 100vh;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%);
    background-attachment: fixed;
}

/* === BANNER DE HORARIOS DINÁMICO === */
.schedule-banner {
    background: rgba(16, 185, 129, 0.15);
    backdrop-filter: blur(10px);
    padding: 12px 20px;
    text-align: center;
    border-bottom: 1px solid rgba(16, 185, 129, 0.3);
    animation: slideDown 0.5s ease-out;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--text-color);
}

body.light-mode .schedule-banner {
    background: rgba(16, 185, 129, 0.1);
    border-bottom-color: rgba(16, 185, 129, 0.4);
}

.schedule-banner.after-hours {
    background: rgba(59, 130, 246, 0.15);
    border-bottom-color: rgba(59, 130, 246, 0.3);
}

body.light-mode .schedule-banner.after-hours {
    background: rgba(59, 130, 246, 0.1);
    border-bottom-color: rgba(59, 130, 246, 0.4);
}

.banner-icon {
    font-size: 18px;
}

.banner-text {
    font-size: 14px;
    font-weight: 500;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* === BOTÓN DE TEMA === */
.theme-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 20px;
    backdrop-filter: blur(10px);
    position: absolute;
    right: 0;
    top: 0;
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(15deg);
}

body.light-mode .theme-toggle {
    background: rgba(0, 0, 0, 0.1);
    border-color: rgba(0, 0, 0, 0.2);
}

body.light-mode .theme-toggle:hover {
    background: rgba(0, 0, 0, 0.2);
}

/* === HEADER DEL CATÁLOGO === */
.menu-header {
    padding: 20px 0;
    border-bottom: 1px solid var(--divider-color);
    margin-bottom: 20px;
}

.header-top {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 20px;
}

.back-btn {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 8px;
    color: var(--text-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    justify-self: start;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateX(-2px);
}

.store-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
    justify-self: start;
}

.store-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
}

.store-status-menu {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Logo móvil - oculto en desktop */
.logo-mobile {
    display: none;
}

/* Logo desktop - visible en desktop */
.logo-center {
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-img-desktop,
.logo-img-mobile {
    width: 120px;
    height: 120px;
    object-fit: contain;
}

/* === SECCIÓN DE BÚSQUEDA === */
.search-section {
    margin-bottom: 20px;
}

.search-container {
    display: flex;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    margin: 0 auto;
}

.search-input {
    flex: 1;
    padding: 15px 20px;
    border: none;
    outline: none;
    font-size: 16px;
    background: transparent;
    color: #333;
}

.search-input::placeholder {
    color: #666;
}

.search-btn {
    background: var(--button-bg);
    color: white;
    border: none;
    padding: 15px 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: #033a61;
}

/* === FILTROS DE CATEGORÍAS === */
.categories-section {
    margin-bottom: 30px;
}

.categories-container {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 10px 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

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

.category-filter {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 10px 16px;
    border-radius: 25px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.3s ease;
    font-weight: 500;
    font-size: 13px;
    min-width: fit-content;
}

body.light-mode .category-filter {
    background: rgba(4, 74, 118, 0.08);
    color: var(--text-color);
    border-color: rgba(4, 74, 118, 0.2);
}

.category-filter:hover,
.category-filter.active {
    background: var(--button-bg);
    border-color: var(--button-bg);
    transform: translateY(-2px);
    color: #ffffff;
}

body.light-mode .category-filter:hover,
body.light-mode .category-filter.active {
    background: var(--button-bg);
    border-color: var(--button-bg);
    color: #ffffff;
}

/* === CONTENIDO DEL CATÁLOGO === */
.catalog-content {
    min-height: 400px;
    position: relative;
}

/* Estados de carga y vacío */
.loading-state,
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    text-align: center;
    color: var(--text-color);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid var(--text-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-icon {
    font-size: 4rem;
    opacity: 0.5;
    margin-bottom: 20px;
}

.empty-state h3 {
    margin-bottom: 10px;
    font-size: 1.5rem;
}

.empty-state p {
    opacity: 0.8;
    margin-bottom: 20px;
}

/* === GRID DE PRODUCTOS === */
.products-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    padding: 20px 0;
    align-items: stretch; /* Clave para igualar alturas */
}

.product-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    /* Flexbox para igualar alturas */
    flex: 1 1 300px; /* grow, shrink, base width */
    max-width: 380px; /* Evitar que se estiren demasiado */
    min-width: 280px; /* Ancho mínimo */
    display: flex;
    flex-direction: column;
    height: auto; /* Permite que crezca según contenido */
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

/* Badge de "Más Vendido" u "Oferta" */
.badge-bestseller {
    position: absolute;
    top: 12px;
    left: 12px;
    background: linear-gradient(135deg, #FF6B35 0%, #F7931E 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    box-shadow: 0 2px 10px rgba(255, 107, 53, 0.4);
    animation: gentle-pulse 3s infinite;
    z-index: 2;
}

@keyframes gentle-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Badge de envío */
.shipping-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #10B981;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3);
    z-index: 2;
}

/* Sistema de calificación */
.rating {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.stars {
    color: #FFA500;
    font-size: 14px;
    letter-spacing: 2px;
}

.reviews-count {
    font-size: 0.85rem;
    color: #6b7280;
}

/* Pricing mejorado */
.product-pricing {
    margin-bottom: 10px;
    min-height: auto; /* Permite que se ajuste al contenido */
}

.price-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    min-height: 2.1rem; /* Altura consistente para precios */
}

/* Monto de ahorro */
.savings-amount {
    background: rgba(16, 185, 129, 0.2);
    color: #10B981;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    display: inline-block;
    min-height: 1.8rem; /* Espacio reservado incluso si no existe */
}

/* Información de delivery */
.delivery-info {
    font-size: 0.85rem;
    color: #6b7280;
    margin: 10px 0;
    display: flex;
    align-items: center;
    gap: 5px;
}

.product-image {
    height: 350px;
    min-height: 350px; /* Altura fija para consistencia */
    max-height: 350px;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    flex-shrink: 0; /* No permite que se comprima */
}

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

.product-image .product-emoji {
    font-size: 3.5rem;
}

.product-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #ef4444;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.product-info {
    padding: 20px;
    color: #333;
    display: flex;
    flex-direction: column;
    flex: 1; /* Ocupa todo el espacio disponible */
}

.product-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 8px;
    line-height: 1.3;
    color: #1f2937;
    min-height: 2.6rem; /* Altura mínima para 2 líneas */
}

.product-description {
    font-size: 0.9rem;
    color: #6b7280;
    margin-bottom: 15px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.8rem; /* Altura mínima para 2 líneas */
}

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

.current-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--button-bg);
}

.original-price {
    font-size: 1rem;
    color: #9ca3af;
    text-decoration: line-through;
}

.discount-badge {
    background: #ef4444;
    color: white;
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 600;
}

.add-to-cart {
    width: 100%;
    background: var(--button-bg);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    margin-top: auto; /* Empuja el botón al final */
}

.add-to-cart:hover {
    background: #033a61;
    transform: translateY(-1px);
}

.add-to-cart:active {
    transform: translateY(0);
}

.add-to-cart.success {
    background: #10B981 !important;
    transform: scale(1.05);
}

@keyframes cartPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.15); }
}

.cart-float.pulse {
    animation: cartPulse 0.5s ease-out;
}

/* === WHATSAPP FLOTANTE === */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    z-index: 999;
    color: white;
}

.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

/* === CARRITO FLOTANTE === */
.cart-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--button-bg);
    color: white;
    padding: 15px 20px;
    border-radius: 50px;
    box-shadow: 0 8px 25px rgba(4, 74, 118, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 200px;
}

.cart-float:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(4, 74, 118, 0.5);
}

/* Cuando el carrito está visible, el WhatsApp sube */
.whatsapp-float.cart-visible {
    bottom: 120px;
}

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

.cart-count {
    font-size: 0.85rem;
    opacity: 0.9;
    display: block;
}

.cart-total {
    font-size: 1.1rem;
    font-weight: 700;
    display: block;
}

.cart-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.cart-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* === MODAL DE CHECKOUT === */
.checkout-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.checkout-modal .modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--overlay-bg);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    border-radius: 20px;
    padding: 30px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    z-index: 1;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e5e7eb;
}

.modal-header h2 {
    margin: 0;
    color: #1f2937;
    font-size: 1.5rem;
}

.modal-close {
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 5px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: #f3f4f6;
    color: #374151;
}

/* === RESUMEN DEL PEDIDO === */
.order-summary {
    margin-bottom: 25px;
}

.order-summary h3 {
    color: #1f2937;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.order-items {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 15px 0;
    border-bottom: 1px solid #f3f4f6;
    gap: 15px;
}

.order-item:last-child {
    border-bottom: none;
}

.item-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.item-name {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 2px;
    font-size: 0.95rem;
}

.item-quantity-control {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 5px 0;
}

.quantity-btn-small {
    width: 26px;
    height: 26px;
    background: rgba(4, 74, 118, 0.1);
    border: 1px solid rgba(4, 74, 118, 0.2);
    border-radius: 6px;
    color: var(--button-bg);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.quantity-btn-small:hover {
    background: var(--button-bg);
    color: white;
    transform: scale(1.05);
}

.quantity-btn-small:active {
    transform: scale(0.95);
}

.item-quantity {
    font-weight: 600;
    color: #1f2937;
    min-width: 25px;
    text-align: center;
    font-size: 0.95rem;
}

.item-details {
    font-size: 0.85rem;
    color: #6b7280;
}

.item-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.item-price {
    font-weight: 600;
    color: var(--button-bg);
    font-size: 1rem;
}

.remove-item-btn {
    width: 30px;
    height: 30px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 6px;
    color: #ef4444;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.remove-item-btn:hover {
    background: #ef4444;
    color: white;
    transform: scale(1.05);
}

.remove-item-btn:active {
    transform: scale(0.95);
}

.order-total {
    border-top: 1px solid #e5e7eb;
    padding-top: 15px;
}

.subtotal,
.delivery-cost,
.total {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.total {
    font-weight: 700;
    font-size: 1.1rem;
    color: #1f2937;
    border-top: 1px solid #e5e7eb;
    padding-top: 8px;
    margin-top: 8px;
}

/* === OPCIONES DE ENTREGA === */
.delivery-section {
    margin-bottom: 25px;
}

.delivery-section h3 {
    color: #1f2937;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.delivery-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.delivery-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.delivery-option:hover {
    border-color: var(--button-bg);
    background: #f8fafc;
}

.delivery-option input[type="radio"] {
    display: none;
}

.radio-custom {
    width: 20px;
    height: 20px;
    border: 2px solid #d1d5db;
    border-radius: 50%;
    position: relative;
    transition: all 0.3s ease;
}

.delivery-option input[type="radio"]:checked + .radio-custom {
    border-color: var(--button-bg);
}

.delivery-option input[type="radio"]:checked + .radio-custom::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 10px;
    height: 10px;
    background: var(--button-bg);
    border-radius: 50%;
}

.option-text {
    flex: 1;
}

.option-text strong {
    display: block;
    color: #1f2937;
    font-size: 1rem;
    margin-bottom: 2px;
}

.option-text small {
    color: #6b7280;
    font-size: 0.85rem;
}

/* === FORMULARIO DEL CLIENTE === */
.customer-form {
    margin-bottom: 25px;
}

.customer-form h3 {
    color: #1f2937;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    color: #374151;
    font-weight: 500;
    margin-bottom: 5px;
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #d1d5db;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    font-family: var(--font-family);
    background: #ffffff;
    color: #1f2937;
}

body.light-mode .form-group input,
body.light-mode .form-group textarea {
    background: #ffffff;
    color: #1a202c;
    border: 2px solid #d1d5db;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--button-bg);
    box-shadow: 0 0 0 3px rgba(4, 74, 118, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* === ACCIONES DEL MODAL === */
.modal-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.btn-primary,
.btn-secondary {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    font-family: var(--font-family);
}

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

.btn-primary:hover {
    background: #033a61;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
}

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

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
    .menu-container {
        padding: 0 15px;
    }

    .header-top {
        display: flex;
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }

    .back-btn {
        align-self: flex-start;
    }

    .store-info {
        text-align: center;
        align-items: center;
    }

    /* Ocultar logo desktop en móvil */
    .logo-center {
        display: none;
    }

    /* Mostrar logo móvil (debajo del nombre) */
    .logo-mobile {
        display: block;
        text-align: center;
        margin-top: 10px;
    }

    .store-title {
        font-size: 1.3rem;
    }

    .products-grid {
        gap: 20px;
        justify-content: center; /* Centra las tarjetas en móvil */
    }

    .product-card {
        flex: 1 1 280px;
        max-width: 100%; /* Permite que ocupen todo el ancho en móvil */
    }

    .categories-container {
        justify-content: flex-start;
    }

    .whatsapp-float {
        bottom: 15px;
        right: 15px;
        width: 55px;
        height: 55px;
    }

    .whatsapp-float.cart-visible {
        bottom: 110px;
    }

    .cart-float {
        bottom: 15px;
        right: 15px;
        left: 15px;
        border-radius: 15px;
        min-width: auto;
    }

    .modal-content {
        padding: 20px;
        margin: 10px;
        max-height: 85vh;
    }

    .modal-actions {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        padding: 15px;
    }
}

@media (max-width: 480px) {
    .search-container {
        margin: 0 -5px;
    }

    .categories-container {
        margin: 0 -15px;
        padding: 10px 15px;
    }

    .products-grid {
        flex-direction: column; /* Una columna en pantallas muy pequeñas */
    }

    .product-card {
        max-width: 100%;
        min-width: 100%;
        height: auto; /* Permitir que crezca */
        overflow: visible; /* Mostrar todo el contenido */
    }

    /* Resetear todas las alturas mínimas en móvil */
    .product-name {
        min-height: auto;
    }

    .product-description {
        min-height: auto;
    }

    .product-pricing {
        min-height: auto;
    }

    .price-container {
        min-height: auto;
    }

    .savings-amount {
        min-height: auto;
    }

    /* Asegurar que product-info ocupe todo el espacio */
    .product-info {
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    /* Asegurar que imagen no se deforme */
    .product-image {
        overflow: hidden; /* Mantener overflow hidden solo en imagen */
    }

    .delivery-options {
        gap: 8px;
    }

    .delivery-option {
        padding: 12px;
    }
}

/* === MODAL DE PRODUCTO === */
.product-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.product-modal.hidden {
    opacity: 0;
    pointer-events: none;
}

.product-modal .modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--overlay-bg);
    backdrop-filter: blur(5px);
}

.modal-product-content {
    position: relative;
    background: var(--modal-bg);
    border-radius: 20px;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    z-index: 1001;
    display: flex;
    flex-direction: column;
}

body.light-mode .modal-product-content {
    background: var(--modal-bg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}

/* Botón de regresar */
.modal-back-btn {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 50%;
    color: var(--text-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    z-index: 10;
}

.modal-back-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateX(-3px);
}

/* Layout del modal */
.modal-product-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 60px 40px 40px 40px;
    align-items: start;
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.3) transparent;
}

.modal-product-layout::-webkit-scrollbar {
    width: 8px;
}

.modal-product-layout::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.modal-product-layout::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 4px;
}

.modal-product-layout::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.5);
}

/* Lado izquierdo: Imágenes */
.modal-product-images {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

.main-image-container {
    position: relative;
    width: 100%;
    height: 400px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

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

/* Botones del carrusel */
.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    color: var(--gradient-start);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.carousel-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.1);
}

.carousel-btn.hidden {
    display: none;
}

.carousel-btn.prev-btn {
    left: 15px;
}

.carousel-btn.next-btn {
    right: 15px;
}

/* Thumbnails */
.thumbnails-wrapper {
    position: relative;
    width: 100%;
    max-width: 250px;
}

.image-thumbnails {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 5px 30px;
    max-height: 100px;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.image-thumbnails::-webkit-scrollbar {
    display: none;
}

.image-thumbnails.hidden {
    display: none;
}

/* Botones de navegación de thumbnails */
.thumbnail-nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    color: var(--gradient-start);
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    z-index: 10;
}

.thumbnail-nav-btn:hover {
    background: white;
    transform: translateY(-50%) scale(1.15);
    box-shadow: 0 3px 15px rgba(0, 0, 0, 0.4);
}

.thumbnail-nav-btn.visible {
    display: flex;
}

.thumbnail-nav-btn.prev {
    left: 0;
}

.thumbnail-nav-btn.next {
    right: 0;
}

.thumbnail {
    flex-shrink: 0;
    width: 70px;
    height: 70px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.05);
}

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

.thumbnail:hover {
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

.thumbnail.active {
    border-color: var(--button-bg);
    box-shadow: 0 0 10px rgba(4, 74, 118, 0.5);
}

/* Lado derecho: Información */
.modal-product-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.modal-product-name {
    font-family: 'Rubik', sans-serif;
    font-size: 32px;
    font-weight: 700;
    color: var(--text-color);
    margin: 0;
    line-height: 1.2;
}

/* Precios */
.modal-product-prices {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.modal-price-now {
    font-family: 'Rubik', sans-serif;
    font-size: 42px;
    font-weight: 800;
    color: var(--text-color);
    line-height: 1;
}

.modal-price-before {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.6);
}

.modal-price-before.hidden {
    display: none;
}

.modal-price-before .label {
    font-weight: 400;
}

.modal-price-before .value {
    text-decoration: line-through;
    font-weight: 500;
}

/* Descripción */
.modal-product-description {
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    border-left: 4px solid var(--button-bg);
}

body.light-mode .modal-product-description {
    background: rgba(4, 74, 118, 0.05);
}

.modal-product-description h3 {
    font-family: 'Rubik', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-color);
    margin: 0 0 10px 0;
}

.modal-product-description p {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-secondary);
    margin: 0;
}

/* Selector de variantes */
.modal-variants {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.modal-variants label {
    font-family: 'Rubik', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
}

.variant-selector {
    width: 100%;
    padding: 12px 16px;
    font-family: 'Rubik', sans-serif;
    font-size: 15px;
    background: var(--input-bg);
    border: 2px solid var(--input-border);
    border-radius: 12px;
    color: var(--text-color);
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

.variant-selector:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.3);
}

body.light-mode .variant-selector:hover {
    background: #f9fafb;
    border-color: #9ca3af;
}

.variant-selector:focus {
    border-color: var(--button-bg);
    background: rgba(255, 255, 255, 0.15);
}

body.light-mode .variant-selector:focus {
    background: #ffffff;
}

.variant-selector option {
    background: #1a2332;
    color: white;
    padding: 10px;
}

body.light-mode .variant-selector option {
    background: #ffffff;
    color: #1a202c;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-10px); }
    75% { transform: translateX(10px); }
}

/* Control de cantidad */
.modal-quantity-control {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.modal-quantity-control label {
    font-family: 'Rubik', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 10px 20px;
    width: fit-content;
}

body.light-mode .quantity-selector {
    background: #f3f4f6;
}

.quantity-btn {
    width: 36px;
    height: 36px;
    background: var(--button-bg);
    border: none;
    border-radius: 8px;
    color: #ffffff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.quantity-btn:hover {
    background: #055fa3;
    transform: scale(1.1);
}

.quantity-btn:active {
    transform: scale(0.95);
}

.quantity-btn svg,
.quantity-btn svg path {
    color: #ffffff;
    stroke: #ffffff;
}

body.light-mode .quantity-btn svg,
body.light-mode .quantity-btn svg path {
    color: #ffffff;
    stroke: #ffffff;
}

.quantity-selector input {
    width: 60px;
    text-align: center;
    font-family: 'Rubik', sans-serif;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-color);
    background: transparent;
    border: none;
    outline: none;
}

/* Botón agregar al carrito */
.modal-add-to-cart {
    width: 100%;
    padding: 18px 24px;
    background: var(--button-bg);
    color: #ffffff;
    border: none;
    border-radius: 12px;
    font-family: 'Rubik', sans-serif;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
}

.modal-add-to-cart:hover {
    background: #033a61;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(4, 74, 118, 0.3);
}

.modal-add-to-cart:active {
    transform: translateY(0);
}

.modal-add-to-cart.success {
    background: #10B981 !important;
    transform: scale(1.05);
}

/* Políticas de garantías */
.product-guarantees {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 15px;
    background: rgba(16, 185, 129, 0.1);
    border-radius: 8px;
    margin-top: 15px;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

body.light-mode .product-guarantees {
    background: rgba(16, 185, 129, 0.08);
    border-color: rgba(16, 185, 129, 0.4);
}

.guarantee-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-color);
    font-size: 14px;
}

.guarantee-icon {
    font-size: 18px;
}

/* Líneas de Atención */
.contact-lines {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid var(--divider-color);
}

.contact-title {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 12px;
}

.contact-links {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.contact-link {
    color: var(--text-color);
    text-decoration: none;
    font-size: 14px;
    padding: 10px 0;
    border-bottom: 1px solid var(--divider-color);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    opacity: 0.85;
}

.contact-link:last-child {
    border-bottom: none;
}

.contact-link:hover {
    opacity: 1;
    padding-left: 8px;
}

.contact-link.instagram-link:hover {
    color: #E1306C;
}

.contact-link.whatsapp-link:hover {
    color: #25D366;
}

/* Modo claro */
body.light-mode .contact-link {
    color: #1a202c;
}

body.light-mode .contact-link:hover {
    color: #044A76;
}

body.light-mode .contact-link.instagram-link:hover {
    color: #E1306C;
}

body.light-mode .contact-link.whatsapp-link:hover {
    color: #25D366;
}

/* Responsive para tablets */
@media (max-width: 768px) {
    .modal-product-layout {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 50px 25px 30px 25px;
    }

    .main-image-container {
        height: 300px;
    }

    .modal-product-name {
        font-size: 26px;
    }

    .modal-price-now {
        font-size: 36px;
    }

    .modal-product-content {
        width: 95%;
        max-height: 95vh;
    }

    .carousel-btn {
        width: 35px;
        height: 35px;
    }

    .carousel-btn.prev-btn {
        left: 10px;
    }

    .carousel-btn.next-btn {
        right: 10px;
    }

    .thumbnails-wrapper {
        max-width: 200px;
    }

    .thumbnail {
        width: 55px;
        height: 55px;
    }

    .thumbnail-nav-btn {
        width: 24px;
        height: 24px;
    }
}

/* Responsive para móviles */
@media (max-width: 480px) {
    .modal-product-layout {
        padding: 50px 20px 25px 20px;
        gap: 20px;
    }

    .main-image-container {
        height: 250px;
    }

    .modal-back-btn {
        top: 15px;
        left: 15px;
        width: 36px;
        height: 36px;
    }

    .modal-product-name {
        font-size: 22px;
    }

    .modal-price-now {
        font-size: 32px;
    }

    .modal-product-description {
        padding: 15px;
    }

    .modal-product-description h3 {
        font-size: 16px;
    }

    .modal-product-description p {
        font-size: 14px;
    }

    .modal-add-to-cart {
        padding: 16px 20px;
        font-size: 16px;
    }

    .modal-info-btn {
        padding: 14px 20px;
        font-size: 15px;
    }

    .thumbnail {
        width: 60px;
        height: 60px;
    }

    .quantity-selector {
        padding: 8px 15px;
    }

    .quantity-btn {
        width: 32px;
        height: 32px;
    }

    .quantity-selector input {
        font-size: 18px;
        width: 50px;
    }

    .thumbnails-wrapper {
        max-width: 190px;
    }

    .thumbnail {
        width: 50px;
        height: 50px;
    }

    .thumbnail-nav-btn {
        width: 22px;
        height: 22px;
    }

    .thumbnail-nav-btn svg {
        width: 12px;
        height: 12px;
    }
}

/* ============================================
   FOOTER COPYRIGHT - BARRA NEGRA PROFESIONAL
   ============================================ */

.site-footer {
    margin-top: 100vh;
    padding: 20px 15px;
    text-align: center;
    background: #1a1a1a;
    border-top: 1px solid #333;
}

.site-footer .copyright {
    color: #ffffff;
    font-size: 14px;
    margin: 0 0 8px 0;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.site-footer .developer {
    color: #888888;
    font-size: 12px;
    margin: 0;
    font-weight: 300;
}

/* Responsive */
@media (max-width: 768px) {
    .site-footer {
        margin-top: 30px;
        padding: 15px 10px;
    }

    .site-footer .copyright {
        font-size: 12px;
    }

    .site-footer .developer {
        font-size: 11px;
    }
}
