:root {
    /* --- PALETA VIBRANTE Y MÁGICA --- */
    --bg: linear-gradient(135deg, #0f0f1e 0%, #1a0f2e 50%, #2d0a3d 100%);
    --bg-nav: #1a1a2e;
    --card: #2d2d44;
    --primary: #ff006e;
    --primary-900: #c70052;
    --secondary: #8338ec;
    --accent: #ffbe0b;
    --accent-glow: #00f5ff;
    --cream: #f5e6c8;
    --text: #ffffff;
    --text-light: #e0e0e0;
    --muted: #b0b0b0;
    --glow: 0 10px 40px rgba(255, 0, 110, 0.2);
    --border-light: rgba(255, 0, 110, 0.15);
    --shadow-glow: 0 0 30px rgba(131, 56, 236, 0.3);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Poppins, system-ui, sans-serif;
    scroll-behavior: smooth;
    min-height: 100vh;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.08;
    background-image: 
        radial-gradient(2px 2px at 10% 20%, #ffbe0b 30%, transparent 50%),
        radial-gradient(1.5px 1.5px at 70% 30%, #ff006e 40%, transparent 60%),
        radial-gradient(1px 1px at 40% 60%, #8338ec 30%, transparent 50%);
    z-index: 0;
    animation: bgFloat 20s ease-in-out infinite;
}

@keyframes bgFloat {
    0%, 100% { opacity: 0.08; }
    50% { opacity: 0.15; }
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s;
}

.container {
    width: min(1100px, 92%);
    margin-inline: auto;
    position: relative;
    z-index: 1;
}

/* =========================================
   1. HEADER COMPACTO CON DOBLE IMAGEN
   ========================================= */
.main-header {
    position: relative;
    background: linear-gradient(180deg, rgba(138, 43, 226, 0.1) 0%, rgba(255, 0, 110, 0.05) 100%);
    padding: 2rem 0;
    overflow: hidden;
    border-bottom: 1px solid var(--border-light);
}

.header-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

@media (max-width: 900px) {
    .header-grid {
        grid-template-columns: 1fr;
    }
}

.header-text-col {
    text-align: left;
    z-index: 2;
}

.main-header h1 {
    font-family: 'Cinzel', serif;
    font-size: clamp(2.2rem, 5vw, 4rem);
    line-height: 1.1;
    margin-bottom: 10px;
    color: var(--cream);
}

.main-header .accent-text {
    color: var(--cream);
    display: block;
    font-size: 0.6em;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 5px;
}

/* Imagen Móvil (Oculta en PC por defecto) */
.mobile-image-wrapper {
    display: none;
}

.main-header .intro {
    font-family: 'Poppins', sans-serif;
    font-size: 1.05rem;
    color: var(--muted);
    margin-bottom: 15px;
    /* Reducido drásticamente (era 2rem) */
    line-height: 1.5;
    max-width: 500px;
}

.header-chips {
    display: flex;
    gap: 8px;
    justify-content: flex-start;
    flex-wrap: wrap;
    margin-bottom: 20px;
    /* Reducido */
}

.chip {
    background: rgba(255, 0, 110, 0.15);
    border: 1.5px solid rgba(255, 0, 110, 0.4);
    color: #ffbe0b;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 0, 110, 0.2);
}

.chip:hover {
    background: rgba(255, 0, 110, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 0, 110, 0.3);
}

/* Columna Imagen PC */
.header-image-col {
    display: flex;
    /* Visible en PC */
    justify-content: center;
    align-items: center;
}

.image-frame {
    position: relative;
    width: 100%;
    max-width: 500px;
    border-radius: 20px;
    overflow: hidden;
    transform: perspective(1000px) rotateY(-2deg);
    transition: all 0.4s ease;
    box-shadow: 
        0 20px 40px rgba(255, 0, 110, 0.3),
        0 0 30px rgba(131, 56, 236, 0.2);
    border: 1px solid rgba(255, 190, 11, 0.2);
}

.image-frame:hover {
    transform: perspective(1000px) rotateY(0deg) translateY(-8px) scale(1.02);
    box-shadow: 
        0 30px 60px rgba(255, 0, 110, 0.4),
        0 0 50px rgba(131, 56, 236, 0.3),
        inset 0 0 20px rgba(255, 190, 11, 0.1);
}

.hero-image {
    width: 100%;
    height: auto;
    border-radius: 20px;
    display: block;
    object-fit: cover;
    aspect-ratio: 4/3;
    animation: heroImageFade 1s ease-out, floatingMotion 6s ease-in-out infinite 1s;
    position: relative;
}

@keyframes heroImageFade {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes floatingMotion {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-12px);
    }
}

.glow-effect {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255, 0, 110, 0.3) 0%, rgba(131, 56, 236, 0.2) 40%, rgba(255, 255, 255, 0) 70%);
    z-index: -1;
    pointer-events: none;
    animation: glowPulse 4s ease-in-out infinite;
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.6; transform: translate(-50%, -50%) scale(1); }
    50% { opacity: 1; transform: translate(-50%, -50%) scale(1.1); }
}

/* =========================================
   NAVBAR
   ========================================= */
.navbar {
    background-color: rgba(26, 26, 46, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 0, 110, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 0.8rem 0;
    box-shadow: 0 8px 32px rgba(255, 0, 110, 0.15);
}

.nav-container {
    width: min(1200px, 92%);
    margin: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icono {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.logo-texto {
    display: flex;
    flex-direction: column;
    text-align: left;
}

.logo-nombre {
    font-family: Cinzel, serif;
    font-size: 1.2rem;
    color: var(--text);
    font-weight: 700;
    line-height: 1;
}

.logo-ubicacion {
    font-family: Poppins, sans-serif;
    font-size: 0.7rem;
    color: #00f5ff;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-shadow: 0 0 10px rgba(0, 245, 255, 0.4);
}

.nav-menu {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-menu a {
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: uppercase;
    transition: all 0.3s ease;
    color: var(--text-light);
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff006e, #00f5ff);
    transition: width 0.3s ease;
}

.nav-menu a:hover {
    color: #ffbe0b;
}

.nav-menu a:hover::after {
    width: 100%;
}

.mobile-toggle {
    display: none;
    background: rgba(255, 0, 110, 0.1);
    border: 1px solid rgba(255, 0, 110, 0.3);
    border-radius: 8px;
    padding: 6px;
    cursor: pointer;
    color: #ffbe0b;
    transition: all 0.3s ease;
}

.mobile-toggle:hover {
    background: rgba(255, 0, 110, 0.2);
    box-shadow: 0 0 15px rgba(255, 0, 110, 0.3);
}

/* =========================================
   GENERALES
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    cursor: pointer;
    color: #fff;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transition: left 0.4s ease;
    z-index: 0;
}

.btn:hover::before {
    left: 100%;
}

.btn span, .btn i {
    position: relative;
    z-index: 1;
}

.btn:hover {
    transform: translateY(-3px);
}

.btn.whatsapp {
    background: linear-gradient(135deg, #25D366, #128C7E);
    border: 1px solid rgba(37, 211, 102, 0.3);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.35);
}

.btn.whatsapp:hover {
    box-shadow: 0 10px 30px rgba(37, 211, 102, 0.5);
}

.btn.primary {
    background: linear-gradient(135deg, #ffbe0b, #ff006e);
    color: #000;
    border: 1px solid rgba(255, 190, 11, 0.3);
    box-shadow: 0 6px 20px rgba(255, 190, 11, 0.35);
}

.btn.primary:hover {
    box-shadow: 0 10px 30px rgba(255, 190, 11, 0.5);
}

.small-btn {
    padding: 6px 14px;
    font-size: 0.8rem;
}

.section {
    padding: 50px 0;
}

.section h2 {
    font-family: Cinzel, serif;
    color: var(--cream);
    font-size: 2.2rem;
    text-align: center;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.divider {
    height: 2px;
    width: 40px;
    background: var(--cream);
    opacity: 1;
}

.lead {
    text-align: center;
    color: var(--muted);
    margin-bottom: 30px;
    font-weight: 400;
    font-size: 1rem;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.card {
    background: var(--card);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    box-shadow: var(--glow);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-5px);
    border-color: var(--accent);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.card-img-wrapper {
    width: 100%;
    height: 200px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(255, 0, 110, 0.1), rgba(131, 56, 236, 0.1));
}

.card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    animation: imgFadeIn 0.8s ease-out backwards;
    position: relative;
}

.card-img-wrapper img::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0) 0%, 
        rgba(255, 255, 255, 0.3) 50%, 
        rgba(255, 255, 255, 0) 100%);
    animation: shimmerShine 3s infinite;
    pointer-events: none;
}

@keyframes imgFadeIn {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes shimmerShine {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
        opacity: 0;
    }
}

.card:nth-child(1) .card-img-wrapper img { animation-delay: 0.1s; }
.card:nth-child(2) .card-img-wrapper img { animation-delay: 0.2s; }
.card:nth-child(3) .card-img-wrapper img { animation-delay: 0.3s; }
.card:nth-child(4) .card-img-wrapper img { animation-delay: 0.4s; }
.card:nth-child(5) .card-img-wrapper img { animation-delay: 0.5s; }
.card:nth-child(6) .card-img-wrapper img { animation-delay: 0.6s; }
.card:nth-child(7) .card-img-wrapper img { animation-delay: 0.7s; }
.card:nth-child(8) .card-img-wrapper img { animation-delay: 0.8s; }
.card:nth-child(9) .card-img-wrapper img { animation-delay: 0.9s; }
.card:nth-child(10) .card-img-wrapper img { animation-delay: 1s; }
.card:nth-child(11) .card-img-wrapper img { animation-delay: 1.1s; }
.card:nth-child(12) .card-img-wrapper img { animation-delay: 1.2s; }

.card:hover .card-img-wrapper img {
    transform: scale(1.12) rotate(1deg);
    filter: brightness(1.15);
}

.card-body {
    padding: 20px;
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center; /* centra botones y elementos dentro de la card */
}

/* Asegurar que los botones dentro de cards y paneles queden centrados */
.card-body .btn,
.panel .btn {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    margin-top: 12px;
}

/* Botón específico dentro de card */
.card-cta {
    margin-top: 12px;
    align-self: center;
}

/* Centrar el CTA del header */
.cta-header { display: flex; justify-content: center; }


.card-body h3 {
    font-family: Cinzel, serif;
    margin: 0 0 8px;
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-900);
}

.card-body p {
    margin: 0;
    color: var(--muted);
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Carrusel y Footer */
.carousel {
    overflow: hidden;
    position: relative;
    max-width: 800px;
    margin: auto;
    border-radius: 20px;
    background: #fff;
    border: 1px solid var(--border-light);
    box-shadow: var(--glow);
}

.slides {
    display: flex;
    transition: transform 0.5s ease;
}

.slide {
    min-width: 100%;
    padding: 30px 20px;
    display: flex;
    justify-content: center;
}

.testimonial-card {
    text-align: center;
    max-width: 600px;
    color: var(--text);
}

.wh-avatar {
    width: 50px;
    height: 50px;
    background: #eee;
    border-radius: 50%;
    margin: 0 auto 10px;
    border: 2px solid var(--accent);
}

.wh-bubble {
    font-style: italic;
    margin-top: 8px;
    line-height: 1.5;
    color: var(--muted);
    font-size: 0.95rem;
}

.controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    padding-bottom: 15px;
}

.ctrl {
    background: var(--accent);
    border: none;
    color: white;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 50%;
    font-weight: bold;
}

.contact {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}

.panel {
    background: rgba(45,45,68,0.88);
    padding: 25px;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,0.04);
    box-shadow: 0 10px 40px rgba(0,0,0,0.45), var(--glow);
    backdrop-filter: blur(8px);
    color: var(--text-light);
}

.panel h2,
.panel h3 {
    color: var(--cream);
    margin-top: 0;
    font-size: 1.5rem;
}

.panel ul {
    list-style: none;
    padding: 0;
    margin-top: 10px;
}

.panel li {
    margin-bottom: 8px;
    color: var(--muted);
}

.panel li i {
    color: var(--accent);
    margin-right: 8px;
}

footer {
    text-align: center;
    padding: 30px 0;
    background: #111;
    color: #bbb;
    margin-top: 40px;
}

.floating-cta {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: pulse 2s infinite;
}

.whatsapp-icon {
    width: 60px;
    filter: drop-shadow(0 0 10px rgba(0, 0, 0, 0.5));
}

.badge18 {
    background: #300;
    color: #fbb;
    padding: 2px 6px;
    font-size: 10px;
    border-radius: 4px;
    margin-bottom: -5px;
    position: relative;
    z-index: 2;
    border: 1px solid #600;
}

.aviso-mayores {
    background: #2a0505;
    color: #ffb4b4;
    text-align: center;
    padding: 0.5rem;
    font-size: 0.85rem;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

/* --- RESPONSIVE MÓVIL --- */
@media (max-width: 900px) {
    .header-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 15px;
        /* Súper compacto */
    }

    .main-header {
        padding: 2rem 0;
        /* Menos padding en móvil */
    }

    .header-text-col {
        text-align: center;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    /* Mostrar imagen interna en móvil y dar estilos */
    .mobile-image-wrapper {
        display: block;
        width: 100%;
        max-width: 350px;
        margin: 10px 0 15px;
        border-radius: 15px;
        overflow: hidden;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    }

    .mobile-hero-image {
        width: 100%;
        height: auto;
        display: block;
        animation: mobileHeroSlide 0.8s ease-out;
    }

    @keyframes mobileHeroSlide {
        0% {
            opacity: 0;
            transform: translateY(20px);
        }
        100% {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* Ocultar la columna derecha en móvil */
    .header-image-col {
        display: none;
    }

    .header-chips {
        justify-content: center;
    }

    .main-header .intro {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 768px) {
    .contact {
        grid-template-columns: 1fr;
    }

    .mobile-toggle {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-nav);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
        border-top: 1px solid #eee;
    }

    .nav-menu.active {
        display: flex;
    }

    /* Mobile Image Animation Optimizations */
    .card-img-wrapper img {
        will-change: transform, filter;
    }

    .card:nth-child(1) .card-img-wrapper img { animation-delay: 0.05s; }
    .card:nth-child(2) .card-img-wrapper img { animation-delay: 0.1s; }
    .card:nth-child(3) .card-img-wrapper img { animation-delay: 0.15s; }
    .card:nth-child(4) .card-img-wrapper img { animation-delay: 0.2s; }
    .card:nth-child(5) .card-img-wrapper img { animation-delay: 0.25s; }
    .card:nth-child(6) .card-img-wrapper img { animation-delay: 0.3s; }
    .card:nth-child(7) .card-img-wrapper img { animation-delay: 0.35s; }
    .card:nth-child(8) .card-img-wrapper img { animation-delay: 0.4s; }
    .card:nth-child(9) .card-img-wrapper img { animation-delay: 0.45s; }
    .card:nth-child(10) .card-img-wrapper img { animation-delay: 0.5s; }
    .card:nth-child(11) .card-img-wrapper img { animation-delay: 0.55s; }
    .card:nth-child(12) .card-img-wrapper img { animation-delay: 0.6s; }

    /* Touch-friendly active state for mobile */
    .card:active .card-img-wrapper img {
        transform: scale(1.08) rotate(0.5deg);
        filter: brightness(1.1);
    }

    /* Testimonios mobile optimization */
    .testimonio-img {
        will-change: transform, filter;
    }

    .testimonio-card:active .testimonio-img {
        transform: scale(1.05) rotate(-0.5deg);
        filter: brightness(1.08) saturate(1.05);
    }
}

/* Reduced motion accessibility support - All devices */
@media (prefers-reduced-motion: reduce) {
    .card-img-wrapper img,
    .testimonio-img,
    .card,
    .testimonio-card {
        animation: none !important;
        transition: none !important;
        will-change: auto !important;
    }

    .card:hover .card-img-wrapper img,
    .card:active .card-img-wrapper img,
    .testimonio-card:hover .testimonio-img,
    .testimonio-card:active .testimonio-img {
        transform: none !important;
        filter: none !important;
    }
}

/* Extra small mobile optimization (480px and below) */
@media (max-width: 480px) {
    .card-img-wrapper img {
        animation-duration: 0.6s;
    }

    .card:nth-child(1) .card-img-wrapper img { animation-delay: 0s; }
    .card:nth-child(2) .card-img-wrapper img { animation-delay: 0.05s; }
    .card:nth-child(3) .card-img-wrapper img { animation-delay: 0.1s; }
    .card:nth-child(4) .card-img-wrapper img { animation-delay: 0.15s; }
    .card:nth-child(5) .card-img-wrapper img { animation-delay: 0.2s; }
    .card:nth-child(6) .card-img-wrapper img { animation-delay: 0.25s; }
    .card:nth-child(7) .card-img-wrapper img { animation-delay: 0.3s; }
    .card:nth-child(8) .card-img-wrapper img { animation-delay: 0.35s; }
    .card:nth-child(9) .card-img-wrapper img { animation-delay: 0.4s; }
    .card:nth-child(10) .card-img-wrapper img { animation-delay: 0.45s; }
    .card:nth-child(11) .card-img-wrapper img { animation-delay: 0.5s; }
    .card:nth-child(12) .card-img-wrapper img { animation-delay: 0.55s; }

    /* Reduce transform intensity on small screens */
    .card:active .card-img-wrapper img {
        transform: scale(1.05) rotate(0.25deg) !important;
        filter: brightness(1.08) !important;
    }

    .testimonio-card:active .testimonio-img {
        transform: scale(1.03) rotate(-0.25deg) !important;
        filter: brightness(1.06) saturate(1.03) !important;
    }
}

/* Barra de urgencia superior (marquee de una sola línea) */
.urgency-bar {
    position: static;
    width: 100%;
    background: #b00020; /* rojo intenso */
    color: var(--cream);
    text-align: left;
    padding: 8px 12px;
    font-weight: 700;
    z-index: 999;
    box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    font-size: 0.95rem;
    margin-bottom: 12px; /* separación del header */
    overflow: hidden;
}

.urgency-marquee { overflow: hidden; white-space: nowrap; }
.urgency-marquee span { display: inline-block; padding-left: 100%; animation: marquee 12s linear infinite; }

@keyframes marquee {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-100%); }
}

/* Ajustes responsive para marquee */
@media (max-width: 480px) {
    .urgency-marquee span { animation-duration: 8s; }
}

.btn.whatsapp.whatsapp-pulse,
.floating-cta.whatsapp-pulse {
    animation: pulse 1.8s infinite;
}

/* Nota local / gancho de confianza */
.local-hook {
    color: var(--cream);
    background: rgba(255,255,255,0.02);
    padding: 12px 16px;
    border-radius: 12px;
    margin: 18px 0;
    font-size: 0.95rem;
    text-align: center;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.02);
}

/* Centrar botones dentro del panel principal */
.panel-cta {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 16px;
}