/* ======== DEFINICIÓN DE TEMAS (VARIABLES) ======== */
:root[data-theme="light"] {
    --bg-color: #ffffff;
    --bg-secondary: #f4f7fa;
    --text-color: #0a0b1e;
    --text-secondary: #4a4a4a;
    --border-color: #e0e0e0;
    --primary-blue: #007bff; 
    --primary-blue-dark: #0056b3;
    --card-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    --card-shadow-hover: 0 6px 20px rgba(0, 0, 0, 0.1);
    --bg-card: #ffffff; /* Fondo tarjeta en modo claro */
    
    --bg-color-blur: rgba(255, 255, 255, 0.95);
    --border-color-blur: rgba(224, 224, 224, 0.8);

    --logo-blue-original: #111739; 
}

:root[data-theme="dark"] {
    --bg-color: #0a0b1e;
    --bg-secondary: #10122e;
    --text-color: #f0f0f0; 
    --text-secondary: #b0b0b0;
    --border-color: #003c4f;
    --primary-blue: #00bfff;
    --primary-blue-dark: #00a4db;
    --card-shadow: 0 0 25px rgba(0, 191, 255, 0.1);
    --card-shadow-hover: 0 0 35px rgba(0, 191, 255, 0.3);
    --bg-card: #15193c; /* Fondo tarjeta en modo oscuro */

    --bg-color-blur: rgba(10, 11, 30, 0.95);
    --border-color-blur: rgba(0, 60, 79, 0.8);
}

/* ======== RESET BÁSICO ======== */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { 
    scroll-behavior: smooth; 
    scroll-padding-top: 140px; 
}

body {
    font-family: 'Roboto', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: hidden;
}
.container { width: 90%; max-width: 1400px; margin: 0 auto; }
a { text-decoration: none; color: var(--primary-blue); transition: color 0.3s ease; }
h1, h2, h3, h4, h5 { font-family: 'Exo 2', sans-serif; font-weight: 700; }

/* ======== HEADER ======== */
.main-header { position: sticky; top: 0; z-index: 100; }
.header-top {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}
.header-top-content {
    display: flex; justify-content: space-between; align-items: center; padding: 1.2rem 0; gap: 2rem;
}

.logo {
    font-family: 'Exo 2', sans-serif; font-size: 2rem; font-weight: 700;
    flex-shrink: 0; display: flex; align-items: center; gap: 0.5rem;
    transition: color 0.3s ease; filter: none;
}
.logo .logo-svg { height: 2.5rem; width: auto; filter: none; transition: filter 0.3s ease; }
[data-theme="light"] .logo { color: var(--logo-blue-original); }
[data-theme="light"] .logo:hover { color: var(--primary-blue); }
[data-theme="dark"] .logo { color: var(--text-color); }
[data-theme="dark"] .logo:hover { color: var(--primary-blue); }
.logo:hover .logo-svg { filter: brightness(1.8); }

.header-icons { display: flex; align-items: center; gap: 1.5rem; font-size: 1.3rem; }

/* CONTADOR CARRITO */
.cart-icon-container {
    position: relative !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}
#cart-count {
    position: absolute;
    top: -8px;
    right: -10px;
    background: var(--primary-blue);
    color: white;
    font-size: 0.7rem;
    padding: 0;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-weight: bold;
    display: none; 
    align-items: center;
    justify-content: center;
    z-index: 10;
    pointer-events: none;
}

.header-icons a:hover { color: var(--primary-blue); }
#theme-toggle { background: none; border: none; cursor: pointer; font-size: 1.3rem; color: var(--text-secondary); }
#theme-toggle:hover { color: var(--primary-blue); }
[data-theme="light"] .fa-sun { display: none; }
[data-theme="dark"] .fa-moon { display: none; }

.main-nav { 
    background: var(--bg-color-blur); 
    border-bottom: 1px solid var(--border-color-blur); 
    -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); 
}
.main-nav ul { display: flex; list-style: none; }
.main-nav li { margin-right: 2.5rem; }
.main-nav a {
    display: block; padding: 1rem 0; color: var(--text-color);
    font-weight: 700; font-family: 'Exo 2', sans-serif; transition: color 0.3s ease;
}
.main-nav a:hover, .main-nav a.active { color: var(--primary-blue); }
.main-nav i { margin-right: 0.5rem; }

.header-slogan {
    flex-grow: 1; display: flex; align-items: center; justify-content: center; gap: 10px;
    color: var(--text-secondary); font-family: 'Exo 2', sans-serif; font-weight: 600; font-size: 1.1rem; opacity: 0.8;
}
.header-slogan i { color: var(--primary-blue); font-size: 1.4rem; }

/* ======== HERO & HOME ======== */
.hero-comercial {
    background: var(--bg-secondary); padding: 6rem 0; position: relative; overflow: hidden; z-index: 0; 
}
#hero-canvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; }
.hero-content { position: relative; z-index: 10; display: flex; align-items: center; gap: 3rem; }
.hero-text { flex-basis: 50%; text-align: left; }
.hero-text h1 { font-size: 3.5rem; color: var(--text-color); margin-bottom: 1rem; }
.hero-text p { font-size: 1.25rem; color: var(--text-secondary); max-width: 700px; margin-bottom: 2.5rem; }
.hero-slider { flex-basis: 50%; max-width: 500px; }
.swiper { width: 100%; border-radius: 12px; box-shadow: var(--card-shadow-hover); }
.swiper-slide { text-align: center; font-size: 18px; background: #fff; display: flex; justify-content: center; align-items: center; }
.swiper-slide img { display: block; width: 100%; height: 100%; object-fit: cover; }
.swiper-pagination-bullet { background-color: var(--text-secondary); }
.swiper-pagination-bullet-active { background-color: var(--primary-blue); }

.btn { padding: 0.8rem 1.8rem; font-weight: 700; border-radius: 5px; transition: all 0.3s ease; font-family: 'Exo 2', sans-serif; text-transform: uppercase; font-size: 0.9rem; border: 2px solid var(--primary-blue); }
.btn-primary { background-color: var(--primary-blue); color: #fff; }
.btn-primary:hover { background-color: var(--primary-blue-dark); border-color: var(--primary-blue-dark); color: #fff; transform: translateY(-3px); }
.btn-secondary { background-color: transparent; color: var(--primary-blue); }
.btn-secondary:hover { background-color: var(--primary-blue); color: #fff; transform: translateY(-3px); }

/* ======== TIENDA Y PRODUCTOS ======== */
.fixed-background { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -1; background-color: var(--bg-secondary); pointer-events: none; }

.products-section { padding: 3rem 0; background: transparent; position: relative; }

.shop-layout { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; }

/* Sidebar Filtros (General / Desktop) */
.filters-sidebar {
    background: var(--bg-color); padding: 1.5rem; border-radius: 12px; border: 1px solid var(--border-color);
    box-shadow: var(--card-shadow); position: sticky; top: 150px; max-height: 80vh; overflow-y: auto;
}
.filter-block { margin-bottom: 1.5rem; border-bottom: 1px solid var(--border-color); padding-bottom: 1.5rem; }
.filter-block:last-child { border-bottom: none; margin-bottom: 0; padding-bottom: 0; }
.filter-block h4 { font-size: 1rem; margin-bottom: 1rem; color: var(--text-color); display: flex; align-items: center; justify-content: space-between; }

.search-input-wrapper input, .filter-select { width: 100%; padding: 0.6rem; border-radius: 6px; border: 1px solid var(--border-color); background: var(--bg-secondary); color: var(--text-color); font-family: inherit; }

/* Checkboxes */
.checkbox-list { display: flex; flex-direction: column; gap: 0.6rem; max-height: 200px; overflow-y: auto; padding-right: 5px; }
.checkbox-item { display: flex; align-items: center; gap: 8px; font-size: 0.9rem; color: var(--text-secondary); cursor: pointer; }
.checkbox-item input { accent-color: var(--primary-blue); width: 16px; height: 16px; cursor: pointer; }
.checkbox-item:hover { color: var(--primary-blue); }

/* Slider Precio */
.price-slider-container { padding: 0 5px; }
.price-values { display: flex; justify-content: space-between; font-size: 0.85rem; font-weight: bold; margin-bottom: 10px; color: var(--primary-blue); }
.range-slider { position: relative; width: 100%; height: 5px; margin-top: 5px; }
.slider-track { position: absolute; width: 100%; height: 5px; background: var(--border-color); border-radius: 5px; }
.range-slider input[type="range"] { position: absolute; width: 100%; pointer-events: none; -webkit-appearance: none; background: none; top: -6px; z-index: 2; }
.range-slider input[type="range"]::-webkit-slider-thumb { pointer-events: auto; height: 18px; width: 18px; border-radius: 50%; background: var(--primary-blue); -webkit-appearance: none; box-shadow: 0 2px 5px rgba(0,0,0,0.2); cursor: pointer; margin-top: 1px; }

/* Grid Productos */
.products-content { width: 100%; }
.products-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.results-count { font-size: 0.9rem; color: var(--text-secondary); font-weight: bold; }
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.5rem; }

.product-card { background: var(--bg-color); border: 1px solid var(--border-color); border-radius: 12px; overflow: hidden; transition: transform 0.3s ease, box-shadow 0.3s ease; position: relative; display: flex; flex-direction: column; }
.product-card:hover { transform: translateY(-5px); box-shadow: var(--card-shadow-hover); border-color: var(--primary-blue); }
.card-clickable-area { cursor: pointer; flex-grow: 1; display: flex; flex-direction: column; }
.product-image { width: 100%; height: 200px; object-fit: contain; background: #fff; border-bottom: 1px solid var(--border-color); padding: 10px; }
.product-info { padding: 1.2rem; flex-grow: 1; display: flex; flex-direction: column; }
.product-category { font-size: 0.75rem; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 0.3rem; }
.product-title { font-size: 1.1rem; color: var(--text-color); margin-bottom: 0.5rem; line-height: 1.3; font-weight: 600; }
.product-price { font-size: 1.2rem; font-weight: 700; color: var(--primary-blue); margin-top: auto; }

.add-to-cart-btn { margin: 0 1.2rem 1.2rem 1.2rem; padding: 0.7rem; background: transparent; border: 2px solid var(--primary-blue); color: var(--primary-blue); border-radius: 6px; font-weight: 700; cursor: pointer; transition: all 0.3s ease; display: flex; justify-content: center; align-items: center; gap: 0.5rem; }
.add-to-cart-btn:hover { background: var(--primary-blue); color: #fff; }

.loader-placeholder { grid-column: 1 / -1; text-align: center; padding: 3rem; color: var(--text-secondary); font-size: 1.2rem; }

/* Botones Móvil */
.mobile-filter-btn { display: none; width: 100%; padding: 12px; background: var(--primary-blue); color: white; border: none; font-weight: bold; border-radius: 8px; margin-bottom: 1.5rem; cursor: pointer; text-transform: uppercase; }

/* ESTILOS NUEVOS DE ESTRUCTURA MÓVIL */
.sidebar-header-mobile, .mobile-apply-footer { display: none; } /* Ocultos en desktop */

.btn-clean-filters { width: 100%; margin-top: 1rem; padding: 0.6rem; background: transparent; border: 1px dashed var(--text-secondary); color: var(--text-secondary); border-radius: 6px; cursor: pointer; transition: 0.3s; }
.btn-clean-filters:hover { border-color: var(--primary-blue); color: var(--primary-blue); }

/* ======== SERVICIOS Y SOPORTE ======== */
.services { padding: 6rem 0; text-align: center; position: relative; z-index: 1; }
.services h2 { font-size: 2.8rem; margin-bottom: 3rem; color: var(--text-color); }
.service-container { 
    display: flex; 
    justify-content: space-around; 
    gap: 2rem; 
    flex-wrap: wrap; 
    align-items: flex-start; /* <--- ESTA LÍNEA SOLUCIONA EL ESTIRAMIENTO */
}
.service-card { background: var(--bg-secondary); padding: 2.5rem 2rem; border-radius: 8px; border: 1px solid var(--border-color); flex-basis: 380px; flex-grow: 1; transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease; box-shadow: var(--card-shadow); text-align: left; }
.service-card:hover { transform: translateY(-10px); box-shadow: var(--card-shadow-hover); border-color: var(--primary-blue); }
.service-card h3 { color: var(--primary-blue); margin-bottom: 1rem; font-size: 1.5rem; }
.service-card p { color: var(--text-secondary); }

.support-section { padding: 6rem 0; background: var(--bg-color); position: relative; z-index: 1; }
.support-section h2 { text-align: center; margin-bottom: 4rem; font-size: 2.8rem; color: var(--text-color); }
.support-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: start; }
.support-info { display: flex; flex-direction: column; gap: 2rem; }
.support-desc { font-size: 1.1rem; color: var(--text-secondary); margin-bottom: 1rem; }
.contact-item { display: flex; align-items: center; gap: 1.5rem; padding: 1.5rem; background: var(--bg-secondary); border-radius: 12px; border: 1px solid var(--border-color); transition: transform 0.3s ease, box-shadow 0.3s ease; }
.contact-item:hover { transform: translateX(5px); box-shadow: var(--card-shadow-hover); border-color: var(--primary-blue); }
.icon-box { font-size: 1.8rem; color: var(--primary-blue); width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; background: rgba(0, 123, 255, 0.1); border-radius: 50%; flex-shrink: 0; }
.contact-text h4 { font-size: 1.1rem; color: var(--text-color); margin-bottom: 0.2rem; }
.contact-text p { color: var(--text-secondary); font-size: 1rem; }
.social-media-block h4 { margin-bottom: 1rem; color: var(--text-color); }
.social-icons { display: flex; gap: 1rem; }
.social-link { width: 45px; height: 45px; border-radius: 50%; background: var(--bg-secondary); border: 1px solid var(--border-color); display: flex; align-items: center; justify-content: center; font-size: 1.2rem; color: var(--text-secondary); transition: all 0.3s ease; }
.social-link:hover { color: #fff; transform: translateY(-3px); border-color: transparent; }
.social-link.fb:hover { background: #1877F2; }
.social-link.ins:hover { background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%); }
.social-link.tik:hover { background: #000; }

.support-form-wrapper { background: var(--bg-secondary); padding: 2.5rem; border-radius: 12px; box-shadow: var(--card-shadow); border: 1px solid var(--border-color); }
.contact-form h3 { margin-bottom: 1.5rem; color: var(--text-color); }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 500; color: var(--text-color); }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 0.8rem; border: 1px solid var(--border-color); border-radius: 6px; background: var(--bg-color); color: var(--text-color); font-family: 'Roboto', sans-serif; font-size: 1rem; transition: border-color 0.3s ease; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--primary-blue); box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1); }
.full-width { width: 100%; }
footer { text-align: center; padding: 3rem; border-top: 1px solid var(--border-color); margin-top: 4rem; color: var(--text-secondary); background: var(--bg-secondary); }

/* ============ MODAL ============ */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.6); backdrop-filter: blur(5px); z-index: 1000; display: flex; justify-content: center; align-items: center; opacity: 0; visibility: hidden; transition: all 0.3s ease; padding: 1rem; }
.modal-overlay.active { opacity: 1; visibility: visible; }
.modal-content { background: var(--bg-color); width: 100%; max-width: 900px; border-radius: 16px; position: relative; overflow: hidden; box-shadow: 0 15px 40px rgba(0,0,0,0.2); border: 1px solid var(--border-color); transform: translateY(20px); transition: transform 0.3s ease; max-height: 90vh; overflow-y: auto; }
.modal-overlay.active .modal-content { transform: translateY(0); }

.modal-close { position: -webkit-sticky; position: sticky; top: 15px; float: right; margin-right: 15px; margin-bottom: -35px; z-index: 100; background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(4px); box-shadow: 0 4px 15px rgba(0,0,0,0.15); border: 1px solid var(--border-color); width: 35px; height: 35px; border-radius: 50%; cursor: pointer; font-size: 1.2rem; color: var(--text-color); transition: all 0.2s; display: flex; align-items: center; justify-content: center; }
.modal-close:hover { background: var(--primary-blue); color: #fff; transform: rotate(90deg); }

.modal-body { display: flex; flex-wrap: wrap; }
.modal-image-col { flex: 1 1 300px; background: var(--bg-secondary); padding: 2rem; display: flex; flex-direction: column; gap: 1rem; justify-content: flex-start; align-items: center;}
.modal-info-col { flex: 1 1 300px; padding: 2.5rem; display: flex; flex-direction: column; }
.main-image-container { width: 100%; height: 300px; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.main-image-container img { max-height: 100%; max-width: 100%; object-fit: contain; cursor: zoom-in; }
.modal-thumbnails { display: flex; gap: 10px; justify-content: center; padding: 10px; overflow-x: auto; flex-wrap: wrap; }
.thumb-img { width: 60px; height: 60px; border-radius: 6px; border: 2px solid transparent; cursor: pointer; object-fit: cover; background: #fff; transition: all 0.2s; }
.thumb-img:hover { transform: translateY(-2px); }
.thumb-img.active { border-color: var(--primary-blue); opacity: 1; box-shadow: 0 0 10px rgba(0,123,255,0.3); }

.modal-badges-row { display: flex; gap: 10px; margin-bottom: 0.8rem; flex-wrap: wrap; }
.modal-badge { display: inline-flex; align-items: center; gap: 6px; background: var(--bg-secondary); color: var(--text-secondary); padding: 0.3rem 0.8rem; border-radius: 20px; font-size: 0.8rem; text-transform: uppercase; font-weight: bold; border: 1px solid var(--border-color); }
.badge-new { background-color: #e3f2fd; color: #0d47a1; border-color: #bbdefb; } 
.badge-used { background-color: #e6f4ea; color: #137333; border-color: #c6efce; } 
.badge-refurbished { background-color: #feefc3; color: #b06000; border-color: #feefc3; }

#modal-title { font-size: 2rem; line-height: 1.2; margin-bottom: 0.5rem; color: var(--text-color); }
.modal-price { font-size: 1.8rem; font-weight: 700; color: var(--primary-blue); margin-bottom: 1.5rem; }
.specs-grid { display: flex; gap: 1rem; margin-bottom: 1.5rem; flex-wrap: wrap; background: var(--bg-secondary); padding: 1rem; border-radius: 8px; border: 1px solid var(--border-color); }
.spec-item { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; color: var(--text-color); font-weight: 500; }
.spec-item i { color: var(--primary-blue); }
.modal-description p { color: var(--text-secondary); font-size: 0.95rem; line-height: 1.6; margin-bottom: 1.5rem; word-wrap: break-word; }
.modal-meta { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--border-color); margin-bottom: 1.5rem; }
.modal-meta p { color: var(--text-secondary); font-size: 0.9rem; }
.modal-action-btn { width: 100%; padding: 1rem; background: var(--primary-blue); color: white; border: none; border-radius: 8px; font-size: 1.1rem; font-weight: bold; cursor: pointer; transition: background 0.3s; font-family: 'Exo 2', sans-serif; text-transform: uppercase; }
.modal-action-btn:hover { background: var(--primary-blue-dark); }

/* ESTILO RESTAURADO: BOTÓN COMPARTIR */
.btn-share-link {
    background: transparent; border: 1px solid var(--border-color); padding: 8px 12px; border-radius: 6px;
    cursor: pointer; color: var(--text-secondary); font-size: 0.9rem; display: flex; align-items: center; gap: 8px;
    margin-top: 10px; transition: all 0.3s ease; font-family: inherit;
}
.btn-share-link:hover { border-color: var(--primary-blue); color: var(--primary-blue); background: rgba(0, 123, 255, 0.05); }

/* ============ CARRITO ============ */
.cart-modal-content { max-width: 500px; display: flex; flex-direction: column; height: 100vh; margin-left: auto; border-radius: 0; transform: translateX(100%); transition: transform 0.3s ease; }
.modal-overlay.active .cart-modal-content { transform: translateX(0); }
.cart-header { padding: 1.5rem; border-bottom: 1px solid var(--border-color); background: var(--bg-secondary); display: flex; justify-content: space-between; align-items: center; }
.cart-header h3 { margin: 0; color: var(--text-color); }
.cart-body { flex-grow: 1; overflow-y: auto; padding: 1.5rem; }
.cart-footer { padding: 1.5rem; border-top: 1px solid var(--border-color); background: var(--bg-secondary); }
.cart-item { display: flex; gap: 1rem; align-items: center; margin-bottom: 1.5rem; padding-bottom: 1.5rem; border-bottom: 1px dashed var(--border-color); }
.cart-item img { width: 70px; height: 70px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border-color); }
.cart-item-info { flex-grow: 1; }
.cart-item-info h4 { font-size: 1rem; margin-bottom: 0.3rem; color: var(--text-color); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cart-item-price { font-weight: bold; color: var(--primary-blue); font-size: 0.95rem; }
.cart-item-controls { display: flex; align-items: center; gap: 0.5rem; background: var(--bg-secondary); border-radius: 6px; padding: 0.2rem; }
.cart-item-controls button { width: 28px; height: 28px; border: none; background: #fff; border-radius: 4px; cursor: pointer; font-weight: bold; color: var(--text-color); box-shadow: 0 2px 5px rgba(0,0,0,0.05); }
.cart-item-controls span { font-size: 0.9rem; font-weight: bold; min-width: 20px; text-align: center; }
.cart-item-remove { background: none; border: none; color: #ff4757; cursor: pointer; font-size: 1.1rem; padding: 0.5rem; }
.cart-total-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.5rem; font-size: 1.2rem; }
.cart-actions { display: flex; gap: 1rem; }
.btn-primary-cart, .btn-secondary-cart { padding: 0.8rem; border-radius: 8px; font-weight: bold; cursor: pointer; border: none; font-family: 'Exo 2', sans-serif; text-transform: uppercase; font-size: 0.9rem; flex: 1; display: flex; align-items: center; justify-content: center; gap: 8px; }
.btn-primary-cart { background: #25D366; color: white; }
.btn-secondary-cart { background: #e0e0e0; color: #333; }

/* Lightbox */
.lightbox-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.95); z-index: 2000; display: flex; justify-content: center; align-items: center; opacity: 0; visibility: hidden; transition: all 0.3s ease; }
.lightbox-overlay.active { opacity: 1; visibility: visible; }
.lightbox-overlay img { max-width: 90%; max-height: 90%; border-radius: 4px; box-shadow: 0 0 30px rgba(255,255,255,0.1); }
.lightbox-close { position: absolute; top: 20px; right: 20px; background: none; border: none; color: white; font-size: 2rem; cursor: pointer; z-index: 2005; }

/* Toast */
.toast-notification { position: fixed; bottom: 20px; right: 20px; background: #333; color: white; padding: 12px 24px; border-radius: 8px; box-shadow: 0 5px 15px rgba(0,0,0,0.3); z-index: 2000; transform: translateY(100px); opacity: 0; transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55); }
.toast-notification.show { transform: translateY(0); opacity: 1; }

/* ======== RESPONSIVE GLOBAL ======== */
@media (max-width: 900px) {
    html { scroll-padding-top: 240px; }
    .header-top-content { flex-wrap: wrap; justify-content: center; gap: 0.8rem; padding: 0.8rem 0; }
    .logo { font-size: 1.5rem; }
    .header-icons { font-size: 1.1rem; gap: 1rem; }
    .main-nav { overflow-x: auto; }
    .main-nav ul { justify-content: flex-start; white-space: nowrap; width: max-content; }
    .support-grid { grid-template-columns: 1fr; gap: 3rem; }
    
    .shop-layout { grid-template-columns: 1fr; }
    
    /* FIX DEFINITIVO MÓVIL: USAR DVH PARA EVITAR QUE EL NAVEGADOR TAPE EL BOTÓN */
    .filters-sidebar { 
        position: fixed; 
        top: 0 !important; 
        left: 0; 
        width: 100%; 
        
        /* LA CLAVE: 100dvh se ajusta automáticamente si la barra del navegador aparece/desaparece */
        height: 100vh; 
        height: 100dvh; 
        
        max-height: none; 
        z-index: 10000 !important; 
        border-radius: 0; 
        transform: translateX(-100%); 
        transition: transform 0.3s ease; 
        padding: 0; 
        display: flex; 
        flex-direction: column;
        background-color: var(--bg-color);
    }
    
    .filters-sidebar.active { transform: translateX(0); }
    
    /* Header del Sidebar */
    .sidebar-header-mobile { 
        display: flex; 
        justify-content: space-between; 
        align-items: center; 
        flex-shrink: 0; 
        padding: 1.2rem;
        border-bottom: 1px solid var(--border-color);
        background-color: var(--bg-color);
    }
    .sidebar-header-mobile h3 { margin: 0; font-size: 1.3rem; }
    .sidebar-header-mobile button { background: none; border: none; font-size: 1.8rem; color: var(--text-color); cursor: pointer; padding: 5px; }

    /* Cuerpo Scrollable */
    .filters-scroll-container {
        flex-grow: 1; 
        overflow-y: auto; 
        padding: 1.5rem;
        padding-bottom: 100px; /* Espacio extra para asegurar que se vea lo último */
    }

    /* Footer Fijo con Botón Resultados (Ajustado) */
    .mobile-apply-footer {
        display: block;
        flex-shrink: 0; 
        width: 100%;
        padding: 1.2rem;
        background: var(--primary-blue);
        color: white;
        font-weight: bold;
        text-transform: uppercase;
        border: none;
        cursor: pointer;
        text-align: center;
        font-family: 'Exo 2', sans-serif;
        
        /* Asegura que no se pegue al borde en iPhones sin botón home */
        padding-bottom: max(1.2rem, env(safe-area-inset-bottom)); 
        box-shadow: 0 -4px 10px rgba(0,0,0,0.1); /* Sombra para separarlo visualmente */
    }

    /* Botón flotante inicial "Filtrar y Buscar" */
    .mobile-filter-btn { 
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 8px;
        position: fixed; 
        bottom: 25px; 
        left: 50%;
        transform: translateX(-50%);
        width: 90%; 
        max-width: 400px;
        z-index: 900; 
        box-shadow: 0 5px 20px rgba(0,0,0,0.3);
        margin-bottom: 0;
    }
    
    .btn-clean-filters { width: 100%; margin-top: 1rem; padding: 0.6rem; background: transparent; border: 1px dashed var(--text-secondary); color: var(--text-secondary); border-radius: 6px; cursor: pointer; transition: 0.3s; }
    .btn-clean-filters:hover { border-color: var(--primary-blue); color: var(--primary-blue); }
}

@media (max-width: 768px) {
    .hero-content { flex-direction: column; gap: 2rem; }
    .hero-text { text-align: center; }
    .hero-slider { max-width: 100%; width: 100%; }
    .hero-text h1 { font-size: 2.5rem; } 
    .modal-content { width: auto; margin: 1rem; max-height: 85vh; max-width: calc(100% - 2rem); align-self: center; }
    .modal-body { flex-direction: column; }
    .modal-image-col { padding: 0; height: auto; min-height: auto; }
    .main-image-container { height: 250px; background: #fff; padding: 10px; border-bottom: 1px solid var(--border-color); }
    .modal-info-col { padding: 1.5rem; }
    .modal-close { top: 10px; right: 10px; width: 32px; height: 32px; font-size: 1rem; margin-right: 0; margin-bottom: 0; }
}

/* --- Estilos para la lista desplegable de servicios (Legacy) --- */

.service-card {
    cursor: pointer; /* Indicar que es clickeable */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service-card:hover {
    transform: translateY(-5px);
}

.service-cta-wrapper {
    margin-top: 15px;
    text-align: center;
    font-weight: 500;
    color: var(--primary-blue);
}

.service-details {
    display: none; /* Oculto por defecto */
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    animation: fadeIn 0.4s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.price-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* Legacy items de lista, se sobreescribe con el grid de micro-cards */
.price-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px dashed #eee;
    font-size: 0.95rem;
}

.price-list li:last-child {
    border-bottom: none;
}

.loading-item {
    justify-content: center !important;
    color: #888;
    font-style: italic;
}

.service-card.active .fa-chevron-down {
    transform: rotate(180deg);
    transition: transform 0.3s ease;
}

/* ======== NUEVO DISEÑO: MICRO-CARDS DE SERVICIOS ======== */

/* El contenedor que reemplaza al UL simple */
.service-details ul.price-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Responsivo automático */
    gap: 15px;
    padding: 15px 0;
    list-style: none;
    border: none; /* Quitamos bordes del ul legacy */
}

/* Resetear estilos de LI para que no choquen */
.service-details ul.price-list li {
    display: block;
    border: none;
    padding: 0;
}

/* Cada tarjeta de servicio individual */
.service-micro-card {
    background: var(--bg-card);
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 12px;
    padding: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    position: relative;
    overflow: hidden;
}

[data-theme="dark"] .service-micro-card {
    border-color: rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.03);
}

.service-micro-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    border-color: var(--primary-blue);
}

/* Decoración lateral */
.service-micro-card::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: var(--primary-blue);
    opacity: 0.7;
}

.micro-card-header h4 {
    margin: 0 0 8px 0;
    font-size: 1.1rem;
    color: var(--text-primary);
    font-weight: 700;
}

.micro-card-desc {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 15px;
    line-height: 1.4;
    flex-grow: 1; /* Empuja el precio hacia abajo */
}

.micro-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid rgba(0,0,0,0.05);
    padding-top: 12px;
    margin-top: 10px;
}

[data-theme="dark"] .micro-card-footer {
    border-top-color: rgba(255,255,255,0.1);
}

.micro-card-price {
    font-weight: 700;
    color: var(--primary-blue);
    font-size: 1.1rem;
}

.micro-card-price.variable {
    font-size: 0.95rem;
    color: var(--text-secondary);
    font-style: italic;
}

.btn-micro-action {
    background: rgba(37, 211, 102, 0.1); /* Color WhatsApp suave */
    color: #25D366;
    border: none;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-micro-action:hover {
    background: #25D366;
    color: white;
    transform: scale(1.1);
}