/* ==========================================================================
   1. VARIABLES Y RESET
   ========================================================================== */
:root {
    --bg-body: #f0f8ff;
    --text-main: #333333;
    --text-sub: #555555;
    --bg-card: #ffffff;
    --border-card: #e0e0e0;
    --shadow-card: 0 12px 24px rgba(0,0,0,0.18);
    --shadow-card-hover: 0 16px 32px rgba(0,0,0,0.25);
    --primary: #007799;
    --primary-light: #00aacc;
    --accent-dark: #e0f7fa;
    --btn-hover-dark: #00bcd4;
    --active-nav-bg: rgba(0, 119, 153, 0.15);
    --active-nav-border: #007799;
    --mud: #4a2f13;
    --clean: #e0f7fa;
    --font-main: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
    --broom-width: 85px;
}

body.dark-mode {
    --bg-body: #121212;
    --text-main: #eeeeee;
    --text-sub: #b0b0b0;
    --bg-card: #1e1e1e;
    --border-card: #333333;
    --shadow-card: 0 12px 24px rgba(0, 188, 212, 0.2);
    --shadow-card-hover: 0 16px 32px rgba(0, 188, 212, 0.4);
    --accent-dark: #80deea;
    --btn-hover-dark: #00acc1;
    --active-nav-bg: rgba(0, 188, 212, 0.25);
    --active-nav-border: #00e5ff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: var(--font-main);
    background-color: var(--bg-body);
    color: var(--text-main);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: background-color 0.3s, color 0.3s;
}
a { color: inherit; text-decoration: none; }
.skip-link {
    position: absolute; top: -40px; left: 0; background: var(--primary);
    color: #fff; padding: 8px 16px; z-index: 9999; transition: top 0.2s;
}
.skip-link:focus { top: 0; }

/* ==========================================================================
   2. HEADER: ESTADO BASE (PÁGINAS INTERNAS / LIMPIO)
   ========================================================================== */
.barro-header {
    position: fixed; top: 0; left: 0; width: 100%; height: 90px; z-index: 1000;
    background-color: var(--clean);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: background-color 0.3s;
}
.barro-header .fondo-limpio {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-color: transparent; z-index: 10;
    clip-path: inset(0 0 0 0);
}
.barro-header .menu-navegacion ul { opacity: 1; }
.barro-header .cepillo-movimiento { display: none; }

.contenedor-header {
    position: relative; z-index: 20; width: 100%; max-width: 1200px;
    margin: 0 auto; height: 100%; display: flex; align-items: center;
    justify-content: space-between; padding: 0 20px; gap: 15px;
}

.barro-header .datos-cabecera { list-style: none; display: flex; gap: 12px; font-size: 12px; color: #333; }
.barro-header .datos-cabecera a { color: #007799; font-weight: 600; transition: color 0.2s; }
.barro-header .datos-cabecera a:hover { color: var(--primary-light); }
.barro-header .cepillo-logo { font-size: 20px; font-weight: 700; color: #003344; transition: color 0.3s; flex-shrink: 0; }

/* ==========================================================================
   3. NAVEGACIÓN: SIN EFECTO "BOCADILLO"
   ========================================================================== */
.menu-navegacion {
    flex: 1; display: flex; justify-content: flex-end; min-width: 0;
}
.menu-navegacion ul {
    display: flex; flex-wrap: nowrap; gap: 8px; align-items: center;
    justify-content: flex-end; list-style: none; margin: 0; padding: 0;
}
.menu-navegacion li { white-space: nowrap; flex-shrink: 0; }

.menu-navegacion .selector-tema {
    display: flex; gap: 6px; align-items: center;
    margin-left: 14px; padding-left: 14px;
    border-left: 1px solid rgba(0,0,0,0.15);
}
body.dark-mode .menu-navegacion .selector-tema { border-left-color: rgba(255,255,255,0.2); }

/* ==========================================================================
   4. ANIMACIÓN SOLO EN INDEX (CORREGIDA - CEPILLO SINCRONIZADO CON BARRO)
   ========================================================================== */
header.barro-header[data-page="index"] {
    background-color: var(--mud);
    background-image: radial-gradient(#36200b 15%, transparent 16%), radial-gradient(#5c3a1a 15%, transparent 16%);
    background-size: 30px 30px, 45px 45px;
}
header.barro-header[data-page="index"] .fondo-limpio {
    background-color: var(--clean);
    clip-path: inset(0 0 0 100vw);
    animation: revelarMud 3.5s linear forwards 0.2s;
    will-change: clip-path;
    transform: translateZ(0);
}
@keyframes revelarMud {
    0% { clip-path: inset(0 0 0 100vw); }
    100% { clip-path: inset(0 0 0 0); }
}

header.barro-header[data-page="index"] .menu-navegacion ul {
    opacity: 0;
    animation: fadeInMenu 0.8s ease-out forwards 3.2s;
}
@keyframes fadeInMenu { to { opacity: 1; } }

header.barro-header[data-page="index"] .cepillo-movimiento {
    display: block;
    position: fixed;
    top: 2px;
    left: 0;
    width: var(--broom-width);
    height: var(--broom-width);
    z-index: 1001;
    pointer-events: none;
    transform: translateX(calc(100vw - var(--broom-width)));
    animation: barrerCepillo 3.5s linear forwards 0.2s;
    will-change: transform;
    transform: translateZ(0);
}
@keyframes barrerCepillo {
    0% {
        transform: translateX(calc(100vw - var(--broom-width)));
    }
    100% {
        transform: translateX(calc(-1 * var(--broom-width)));
    }
}
header.barro-header[data-page="index"] .cepillo-movimiento img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* ==========================================================================
   5. BOTONES Y ESTADOS
   ========================================================================== */
.barro-header .btn-3d {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 8px 14px; background: #ffffff; color: #003344;
    border: 1px solid #d0d0d0; border-radius: 6px; font-weight: 600;
    transition: all 0.2s; box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}
.barro-header .btn-3d[aria-current="page"] {
    background: var(--active-nav-bg); border-color: var(--active-nav-border);
    color: var(--primary); font-weight: 700; box-shadow: inset 0 0 0 2px var(--active-nav-border);
    pointer-events: none;
}
.barro-header .btn-tema {
    background: #f8f9fa; border: 1px solid #ccc; padding: 6px 8px;
    border-radius: 50%; cursor: pointer; font-size: 15px; transition: all 0.2s; color: #333;
    display: flex; align-items: center; justify-content: center; width: 32px; height: 32px;
}
.barro-header .btn-tema.activo { background: var(--primary); color: #fff; border-color: var(--primary); }

.barro-header .btn-3d:hover {
    transform: translateY(-2px); background: #007799; color: #fff;
    border-color: #007799; box-shadow: 0 6px 0 #005577, 0 8px 12px rgba(0,0,0,0.15);
}

/* ==========================================================================
   6. MODO OSCURO (BLINDADO)
   ========================================================================== */
body.dark-mode .barro-header:not([data-page="index"]) {
    background-color: #1a237e !important;
}
body.dark-mode .barro-header:not([data-page="index"]) .fondo-limpio {
    background-color: transparent !important;
}

body.dark-mode .barro-header[data-page="index"] {
    background-color: #4a2f13 !important;
    background-image: radial-gradient(#36200b 15%, transparent 16%), radial-gradient(#5c3a1a 15%, transparent 16%) !important;
    background-size: 30px 30px, 45px 45px !important;
}
body.dark-mode .barro-header[data-page="index"] .fondo-limpio {
    background-color: #1a237e !important;
}

body.dark-mode .barro-header .datos-cabecera { color: #ccc; }
body.dark-mode .barro-header .datos-cabecera a { color: #00e5ff; }
body.dark-mode .barro-header .cepillo-logo { color: #e0f7fa; }
body.dark-mode .barro-header .btn-3d {
    background: #1e293b; color: #e0f7fa; border: 1px solid #475569;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
body.dark-mode .barro-header .btn-3d[aria-current="page"] {
    background: var(--active-nav-bg); border-color: var(--active-nav-border); color: #00e5ff;
}
body.dark-mode .barro-header .btn-tema {
    background: #0f172a; color: #e0f7fa; border: 1px solid #334155;
}
body.dark-mode .barro-header .btn-tema.activo { background: #00e5ff; color: #121212; }
body.dark-mode .barro-header .btn-3d:hover {
    background: #00bcd4; color: #121212; border-color: #00bcd4;
    box-shadow: 0 6px 0 #00838f, 0 8px 12px rgba(0,0,0,0.3);
}

body.dark-mode .hero p { color: var(--accent-dark); }

/* ==========================================================================
   7. CONTENIDO Y COMPONENTES
   ========================================================================== */
.contenido-principal { margin-top: 90px; padding: 40px 20px; flex: 1; max-width: 1400px; margin-inline: auto; width: 100%; }

.hero { text-align: center; margin-bottom: 50px; }
.hero h1 { font-size: 2.4rem; margin-bottom: 15px; color: var(--primary); }
.hero p { font-size: 1.15rem; color: var(--text-sub); margin-bottom: 30px; transition: color 0.3s; }
.hero-ctas { display: flex; gap: 15px; justify-content: center; flex-wrap: wrap; }

.btn-brillante {
    position: relative; display: inline-flex; align-items: center; gap: 10px;
    padding: 14px 32px; background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff; font-weight: 700; border: none; border-radius: 50px;
    cursor: pointer; text-decoration: none; overflow: hidden; transition: transform 0.2s, box-shadow 0.2s;
    font-size: 1.1rem;
}
.btn-brillante:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,119,153,0.4); }
.btn-brillante::before {
    content: ''; position: absolute; top: 0; left: 100%; width: 3px; height: 100%;
    background: #fff; box-shadow: 0 0 8px 2px rgba(255,255,255,0.8); transition: left 0.4s;
}
.btn-brillante:hover::before { left: -3px; }
.btn-brillante .estrella { opacity: 0; transform: scale(0.5); transition: all 0.3s 0.3s; }
.btn-brillante:hover .estrella { opacity: 1; transform: scale(1); animation: brillo 1s infinite alternate; }
@keyframes brillo { 0%,100%{text-shadow:0 0 5px #fff} 50%{text-shadow:0 0 15px #ff0} }

.btn-whatsapp {
    padding: 12px 24px; background: #fff; color: #25D366; border: 2px solid #25D366;
    border-radius: 50px; text-decoration: none; font-weight: 600; transition: all 0.2s;
}
.btn-whatsapp:hover { background: #25D366; color: #fff; }

.grid-layout { 
    display: grid; 
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); 
    gap: 30px; 
    margin-bottom: 50px; 
}

.tarjeta {
    background: var(--bg-card); padding: 30px; border-radius: 16px;
    border: 1px solid var(--border-card); transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: var(--shadow-card);
}
.tarjeta:hover { transform: translateY(-8px); box-shadow: var(--shadow-card-hover); }
.tarjeta h3 { text-align: center; margin-bottom: 20px; color: var(--primary); font-size: 1.4rem; }
body.dark-mode .tarjeta h3 { color: var(--accent-dark); }

/* MEJORA: Tablas dentro de tarjetas sin scroll horizontal */
.tarjeta .contenedor-tabla {
    overflow-x: auto;
    margin: 0 -5px;
    padding: 0 5px;
}

.tabla-especificaciones {
    width: 100%;
    min-width: 280px;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.tabla-especificaciones th, 
.tabla-especificaciones td { 
    padding: 12px 10px; 
    border-bottom: 1px solid var(--border-card); 
    text-align: left;
    white-space: normal;
    word-break: break-word;
}
.tabla-especificaciones th { 
    background: var(--bg-body); 
    color: var(--primary); 
    font-weight: 700; 
}
body.dark-mode .tabla-especificaciones th { 
    background: #252525; 
    color: var(--accent-dark); 
}

.cta-final { text-align: center; margin-top: 40px; }
.cta-final .btn-brillante { font-size: 1.25rem; padding: 16px 40px; }

.formulario-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
    background: var(--bg-card); padding: 30px; border-radius: 16px;
    border: 1px solid var(--border-card); box-shadow: var(--shadow-card);
}
.form-full { grid-column: 1 / -1; }
.grupo-input { display: flex; flex-direction: column; gap: 6px; }
.grupo-input label { font-weight: 600; font-size: 0.95rem; }
.grupo-input input, .grupo-input textarea {
    padding: 12px; border: 1px solid var(--border-card); border-radius: 8px;
    background: var(--bg-body); color: var(--text-main); font-family: inherit; font-size: 1rem;
    transition: border-color 0.2s;
}
.grupo-input input:focus, .grupo-input textarea:focus { outline: none; border-color: var(--primary); }

.pie-pagina { background: #333; color: #fff; padding: 40px 20px 30px; margin-top: auto; }
.contenido-footer { max-width: 1200px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; gap: 15px; text-align: center; }
.menu-footer { display: flex; gap: 15px; flex-wrap: wrap; justify-content: center; }
.menu-footer a:hover { color: var(--accent-dark); }
.selector-tema-footer { display: flex; gap: 8px; }
.legales { font-size: 13px; opacity: 0.8; }
.legales a { color: #ccc; text-decoration: none; margin: 0 5px; }
.legales a:hover { color: #fff; }

a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
    outline: 3px solid var(--accent-dark); outline-offset: 2px;
}

/* ==========================================================================
   8. RESPONSIVE - CON SELECT NATIVO PARA MÓVIL
   ========================================================================== */

/* SELECT nativo para móvil - oculto por defecto */
.menu-select-movil {
    display: none;
}

/* Pantallas grandes: tarjetas más anchas */
@media (min-width: 1200px) {
    .grid-layout {
        grid-template-columns: repeat(3, minmax(360px, 1fr));
        gap: 32px;
    }
}

/* Tablets (entre 769px y 1199px) */
@media (min-width: 769px) and (max-width: 1199px) {
    .grid-layout {
        grid-template-columns: repeat(auto-fit, minmax(330px, 1fr));
        gap: 25px;
    }
    .tabla-especificaciones {
        font-size: 0.85rem;
    }
    .tabla-especificaciones th,
    .tabla-especificaciones td {
        padding: 10px 8px;
    }
}

/* Tablets (entre 769px y 992px) - ajustes de menú */
@media (min-width: 769px) and (max-width: 992px) {
    .menu-navegacion ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 6px;
    }
    .btn-3d {
        padding: 6px 12px;
        font-size: 13px;
    }
    .datos-cabecera {
        gap: 8px;
        font-size: 10px;
    }
    .contenido-principal {
        margin-top: 100px;
    }
}

/* Móviles (menos de 768px) - aquí se activa el SELECT nativo */
@media (max-width: 768px) {
    /* Mostrar SELECT, ocultar UL */
    .menu-select-movil {
        display: block !important;
        width: 100%;
        max-width: 250px;
        padding: 10px;
        border-radius: 8px;
        background: #007799;
        color: white;
        font-weight: bold;
        border: none;
        cursor: pointer;
        font-size: 16px;
        margin: 0 auto;
    }
    
    .menu-navegacion ul {
        display: none !important;
    }
    
    /* Ajustes generales del header */
    .barro-header {
        height: auto;
        padding: 15px 0;
    }
    
    .contenedor-header {
        flex-direction: column;
        gap: 12px;
    }
    
    .datos-cabecera {
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px;
        font-size: 10px;
    }
    
    .menu-navegacion {
        width: 100%;
        justify-content: center;
    }
    
    .btn-tema {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
    
    /* Selector de tema en móvil */
    .menu-navegacion .selector-tema {
        justify-content: center;
        border-left: none;
        margin-left: 0;
        padding-left: 0;
        margin-top: 10px;
    }
    
    .contenido-principal {
        margin-top: 280px;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    .hero-ctas {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-brillante, .btn-whatsapp {
        width: 100%;
        justify-content: center;
    }
    
    .formulario-grid {
        grid-template-columns: 1fr;
    }
    
    .tarjeta .contenedor-tabla {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .tabla-especificaciones {
        min-width: 500px;
    }
    
    /* Inicio: fotos laterales en columna */
    .inicio-wrapper {
        flex-direction: column;
        align-items: center;
    }
    
    .foto-lateral {
        max-width: 250px;
        width: 100%;
    }
    
    .foto-lateral img {
        height: auto;
        aspect-ratio: 1 / 1;
    }
    
    .tarjetas-wrapper .grid-layout {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   10. IMÁGENES ANTES/DESPUÉS (SERVICIOS) - SIMÉTRICAS ABAJO
   ========================================================================== */
.imagenes-antes-despues {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin: 50px 0 30px;
    flex-wrap: wrap;
}

.bloque-imagen {
    flex: 1;
    min-width: 280px;
    max-width: 400px;
    text-align: center;
    position: relative;
}

.bloque-imagen img {
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 20px;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    display: block;
}

.bloque-imagen img:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}

.badge-antes, .badge-despues {
    display: inline-block;
    margin-top: 15px;
    padding: 8px 20px;
    font-weight: bold;
    font-size: 1rem;
    border-radius: 40px;
    background: #333;
    color: white;
    letter-spacing: 1px;
}

.badge-antes {
    background: #b85c1a;
}

.badge-despues {
    background: #007799;
}

body.dark-mode .badge-antes {
    background: #e67e22;
}

body.dark-mode .badge-despues {
    background: #00aacc;
}

@media (max-width: 700px) {
    .imagenes-antes-despues {
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }
    
    .bloque-imagen {
        max-width: 100%;
        width: 100%;
    }
}

/* ==========================================================================
   11. FOTOS LATERALES EN MISMA FILA QUE TARJETAS (INICIO)
   ========================================================================== */
.inicio-wrapper {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 30px;
    margin: 50px 0;
}

.foto-lateral {
    flex: 0 0 260px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
}

.foto-lateral img {
    width: 100%;
    height: 260px;
    object-fit: cover;
    border-radius: 16px;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    display: block;
}

.foto-lateral img:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}

.badge-foto {
    text-align: center;
    font-size: 0.9rem;
    font-weight: bold;
    padding: 10px;
    background: var(--primary);
    color: white;
    border-radius: 40px;
}

body.dark-mode .badge-foto {
    background: var(--accent-dark);
    color: #121212;
}

.tarjetas-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
}

.tarjetas-wrapper .grid-layout {
    margin-bottom: 0;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    width: 100%;
}

@media (max-width: 992px) {
    .inicio-wrapper {
        flex-direction: column;
        align-items: center;
    }
    
    .foto-lateral {
        flex: 0 0 auto;
        width: 100%;
        max-width: 300px;
    }
    
    .foto-lateral img {
        height: auto;
        aspect-ratio: 1 / 1;
    }
    
    .tarjetas-wrapper {
        width: 100%;
    }
    
    .tarjetas-wrapper .grid-layout {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1400px) {
    .foto-lateral {
        flex: 0 0 300px;
    }
    
    .foto-lateral img {
        height: 300px;
    }
}

/* ==========================================================================
   12. PÁGINA NOSOTROS
   ========================================================================== */
.nosotros-wrapper {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 30px;
    margin: 50px 0;
}

.foto-lateral-nosotros {
    flex: 0 0 280px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
}

.foto-lateral-nosotros img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: top center;
    border-radius: 16px;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    display: block;
    background: var(--bg-card);
}

.foto-lateral-nosotros img:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}

.badge-nosotros {
    text-align: center;
    font-size: 0.9rem;
    font-weight: bold;
    padding: 10px;
    background: var(--primary);
    color: white;
    border-radius: 40px;
}

body.dark-mode .badge-nosotros {
    background: var(--accent-dark);
    color: #121212;
}

.tarjetas-nosotros {
    flex: 1;
    display: flex;
    align-items: center;
}

.grid-nosotros {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
    width: 100%;
}

.tarjeta-nosotros {
    background: var(--bg-card);
    padding: 25px;
    border-radius: 16px;
    border: 1px solid var(--border-card);
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    text-align: center;
}

.tarjeta-nosotros:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}

.tarjeta-nosotros h3 {
    color: var(--primary);
    margin-bottom: 12px;
    font-size: 1.2rem;
}

.tarjeta-nosotros p {
    color: var(--text-sub);
    font-size: 0.9rem;
}

body.dark-mode .tarjeta-nosotros h3 {
    color: var(--accent-dark);
}

@media (max-width: 992px) {
    .nosotros-wrapper {
        flex-direction: column;
        align-items: center;
    }
    
    .foto-lateral-nosotros {
        flex: 0 0 auto;
        width: 100%;
        max-width: 280px;
    }
    
    .foto-lateral-nosotros img {
        aspect-ratio: 1 / 1;
    }
    
    .grid-nosotros {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (min-width: 1400px) {
    .foto-lateral-nosotros {
        flex: 0 0 320px;
    }
}

/* ==========================================================================
   13. PÁGINA TARIFAS - VERSIÓN DEFINITIVA (CHALETS MÁS ALTOS + TEJADO)
   ========================================================================== */
.tarifas-wrapper {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    justify-content: center;
    gap: 40px;
    margin: 50px auto;
    max-width: 1600px;
    width: 100%;
}

.foto-lateral-tarifas {
    flex: 0 0 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
}

.foto-lateral-tarifas img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: center 15%;
    border-radius: 16px;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    display: block;
    background: var(--bg-card);
}

.foto-lateral-tarifas img:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-card-hover);
}

.badge-tarifas {
    text-align: center;
    font-size: 0.9rem;
    font-weight: bold;
    padding: 10px;
    background: var(--primary);
    color: white;
    border-radius: 40px;
}

body.dark-mode .badge-tarifas {
    background: var(--accent-dark);
    color: #121212;
}

.tablas-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tarjetas-columna {
    display: flex;
    flex-direction: column;
    gap: 30px;
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
}

.tarjeta-tarifa {
    background: var(--bg-card);
    padding: 30px;
    border-radius: 16px;
    border: 1px solid var(--border-card);
    box-shadow: var(--shadow-card);
    transition: transform 0.3s, box-shadow 0.3s;
    width: 100%;
}

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

.tarjeta-tarifa h3 {
    text-align: center;
    margin-bottom: 25px;
    color: var(--primary);
    font-size: 1.5rem;
}

body.dark-mode .tarjeta-tarifa h3 {
    color: var(--accent-dark);
}

.tarjeta-tarifa .contenedor-tabla {
    overflow-x: auto;
}

.tarjeta-tarifa .tabla-especificaciones {
    width: 100%;
    font-size: 1rem;
}

.tarjeta-tarifa .tabla-especificaciones th,
.tarjeta-tarifa .tabla-especificaciones td {
    padding: 15px 12px;
}

@media (max-width: 1200px) {
    .tarifas-wrapper {
        gap: 30px;
    }
    
    .foto-lateral-tarifas {
        flex: 0 0 260px;
    }
    
    .tarjetas-columna {
        max-width: 750px;
    }
    
    .tarjeta-tarifa h3 {
        font-size: 1.3rem;
    }
    
    .tarjeta-tarifa .tabla-especificaciones {
        font-size: 0.9rem;
    }
}

@media (max-width: 992px) {
    .tarifas-wrapper {
        flex-direction: column;
        align-items: center;
    }
    
    .foto-lateral-tarifas {
        flex: 0 0 auto;
        width: 100%;
        max-width: 300px;
    }
    
    .foto-lateral-tarifas img {
        aspect-ratio: 1 / 1;
    }
    
    .tarjetas-columna {
        max-width: 100%;
    }
}

@media (min-width: 1400px) {
    .foto-lateral-tarifas {
        flex: 0 0 350px;
    }
    
    .tarjetas-columna {
        max-width: 1050px;
        gap: 35px;
    }
    
    .tarjeta-tarifa {
        padding: 35px;
    }
    
    .tarjeta-tarifa h3 {
        font-size: 1.7rem;
    }
}
/* ====================================================== */
/* AVISO DE COOKIES */
/* ====================================================== */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #1e1e1e;
    color: #f5f5f5;
    padding: 15px 20px;
    z-index: 9999;
    transform: translateY(100%);
    transition: transform 0.4s ease-in-out;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.2);
    font-family: var(--font-main);
}

.cookie-banner.mostrar {
    transform: translateY(0);
}

.cookie-contenido {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 15px;
}

.cookie-contenido p {
    margin: 0;
    font-size: 0.9rem;
    flex: 1;
}

.cookie-botones {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.cookie-btn {
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.cookie-btn.aceptar {
    background: #007799;
    color: white;
}

.cookie-btn.aceptar:hover {
    background: #00aacc;
    transform: scale(1.02);
}

.cookie-btn.rechazar {
    background: transparent;
    color: #ccc;
    border: 1px solid #555;
}

.cookie-btn.rechazar:hover {
    background: #333;
    color: white;
}

.cookie-link {
    color: #00aacc;
    text-decoration: none;
    font-size: 0.85rem;
}

.cookie-link:hover {
    text-decoration: underline;
}

/* Modo claro */
body:not(.dark-mode) .cookie-banner {
    background: #ffffff;
    color: #333333;
    box-shadow: 0 -4px 12px rgba(0,0,0,0.1);
}

body:not(.dark-mode) .cookie-btn.rechazar {
    color: #666;
    border-color: #ccc;
}

body:not(.dark-mode) .cookie-btn.rechazar:hover {
    background: #f0f0f0;
    color: #333;
}

/* Responsive */
@media (max-width: 768px) {
    .cookie-contenido {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-botones {
        justify-content: center;
    }
}
/* ====================================================== */
/* TARIFAS - CENTRAR TARJETAS EN MÓVIL SIN SCROLL */
/* ====================================================== */

@media (max-width: 768px) {
    /* Eliminar scroll horizontal de toda la página */
    html, body {
        overflow-x: hidden !important;
        width: 100% !important;
    }
    
    /* Contenedor principal */
    .tarifas-wrapper {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        padding: 20px 15px !important;
        box-sizing: border-box !important;
    }
    
    /* Ocultar fotos laterales en móvil */
    .foto-lateral-tarifas {
        display: none !important;
    }
    
    /* Contenedor de las tarjetas */
    .tablas-wrapper {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }
    
    /* Las 3 tarjetas en columna */
    .tarjetas-columna {
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 20px !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        padding: 0 !important;
        box-sizing: border-box !important;
    }
    
    /* Cada tarjeta centrada y con ancho correcto */
    .tarjeta-tarifa {
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 auto !important;
        padding: 15px !important;
        box-sizing: border-box !important;
        text-align: center !important;
    }
    
    /* Título de tarjeta */
    .tarjeta-tarifa h3 {
        font-size: 1.2rem !important;
        text-align: center !important;
        margin-bottom: 15px !important;
    }
    
    /* Contenedor de tabla con scroll horizontal dentro de la tarjeta */
    .tarjeta-tarifa .contenedor-tabla {
        overflow-x: auto !important;
        width: 100% !important;
        -webkit-overflow-scrolling: touch !important;
        text-align: left !important;
    }
    
    /* Tabla */
    .tarjeta-tarifa .tabla-especificaciones {
        width: 100% !important;
        min-width: 280px !important;
        font-size: 0.75rem !important;
        margin: 0 auto !important;
    }
    
    .tarjeta-tarifa .tabla-especificaciones th,
    .tarjeta-tarifa .tabla-especificaciones td {
        padding: 8px 6px !important;
        font-size: 0.7rem !important;
        white-space: nowrap !important;
    }
}
/* ====================================================== */
/* TARIFAS - RESPONSIVE COMPLETO (RESPALDO) */
/* ====================================================== */

@media (max-width: 768px) {
    /* Ocultar fotos laterales */
    .foto-lateral-tarifas {
        display: none !important;
    }
    
    /* Eliminar scroll horizontal */
    .tarifas-wrapper {
        overflow-x: hidden !important;
        padding: 0 15px !important;
        width: 100% !important;
    }
    
    /* Tarjetas en columna centradas */
    .tarjetas-columna {
        display: flex !important;
        flex-direction: column !important;
        gap: 20px !important;
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
    }
    
    /* Cada tarjeta ocupa todo el ancho */
    .tarjeta-tarifa {
        width: 100% !important;
        max-width: 100% !important;
        padding: 15px !important;
        margin: 0 !important;
    }
    
    /* Título más pequeño */
    .tarjeta-tarifa h3 {
        font-size: 1.2rem !important;
    }
    
    /* Tabla compacta */
    .tarjeta-tarifa .tabla-especificaciones {
        font-size: 0.75rem !important;
    }
    
    .tarjeta-tarifa .tabla-especificaciones th,
    .tarjeta-tarifa .tabla-especificaciones td {
        padding: 8px 5px !important;
        font-size: 0.7rem !important;
        white-space: nowrap !important;
    }
}