/**
 * Estructura tipo Colmena — secciones claras y jerarquía visual
 * Referencia: https://sistemacolmena.com/
 */

/* Orden visual: catálogo → beneficios → planes → testimonios → stats */
.site-flow {
    display: flex;
    flex-direction: column;
}

.site-flow .productos-catalog { order: 1; }
.site-flow #beneficios { order: 2; }
.site-flow .products--planes { order: 3; }
.site-flow .testimonios-section { order: 4; }
.site-flow .stats-bar { order: 5; }

/* —— Navegación —— */
.nav-menu--structured {
    gap: 1.5rem;
}

.nav-link--cta-outline {
    padding: 0.5rem 1rem;
    border: 1.5px solid var(--ciade-border-strong, #cbd5e1);
    border-radius: var(--ciade-radius, 0.75rem);
}

/* —— Portada con imagen CIADE (ciadelanding) —— */
.hero-cover--branded {
    padding-top: 4.25rem;
    background: #fff;
    overflow: hidden;
}

/* Solo logo CIADE (sin banner promocional) */
.logo-main--ciade {
    height: 2.75rem;
    width: auto;
    max-width: 11.5rem;
    object-fit: contain;
    object-position: left center;
    mix-blend-mode: multiply;
}

.logo-footer--ciade {
    height: 3rem;
    width: auto;
    max-width: 12rem;
    object-fit: contain;
    margin-bottom: 1rem;
}

/* Showcase: texto + foto profesional */
.hero-cover__showcase {
    position: relative;
    background: #fff;
}

.hero-cover__waves {
    position: absolute;
    inset: auto 0 0 0;
    height: 42%;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(ellipse 90% 80% at 85% 100%, rgb(118 200 177 / 0.55), transparent 60%),
        radial-gradient(ellipse 70% 60% at 30% 100%, rgb(45 125 94 / 0.35), transparent 55%),
        linear-gradient(180deg, transparent 0%, rgb(232 248 243 / 0.9) 100%);
}

.hero-cover__showcase-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    gap: clamp(1rem, 3vw, 2.5rem);
    align-items: center;
    max-width: 76rem;
    margin: 0 auto;
    padding: clamp(1.5rem, 3vw, 2.5rem) 1.5rem clamp(2rem, 4vw, 3rem);
    min-height: clamp(380px, 52vw, 520px);
}

.hero-cover__eyebrow-top {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    color: #2d7d5e;
    margin-bottom: 0.75rem;
}

.hero-cover__title-main {
    margin: 0 0 0.5rem;
    line-height: 1.05;
}

.hero-cover__fenix-num {
    display: block;
    font-size: clamp(2.25rem, 5vw, 3.25rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    color: #1a3a5c;
}

.hero-cover__title-sub {
    display: block;
    font-size: clamp(1.125rem, 2.5vw, 1.5rem);
    font-weight: 700;
    color: #1a3a5c;
    margin-top: 0.25rem;
}

.hero-cover__tagline-italic {
    font-size: 1.0625rem;
    font-style: italic;
    font-weight: 500;
    color: #2d7d5e;
    margin-bottom: 0.75rem;
}

.hero-cover__lead {
    font-size: 1rem;
    line-height: 1.7;
    color: #475569;
    max-width: 28rem;
    margin-bottom: 1.5rem;
}

.hero-cover__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

.btn-whatsapp {
    background: #25d366 !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 4px 14px rgb(37 211 102 / 0.35);
}

.btn-whatsapp:hover {
    background: #1fb855 !important;
    transform: translateY(-1px);
    filter: none;
}

.hero-cover__trust {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.hero-cover__trust li {
    font-size: 0.875rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.hero-cover__trust i {
    color: #2d7d5e;
    font-size: 0.9375rem;
}

.hero-cover__figure {
    position: relative;
    height: 100%;
    min-height: clamp(280px, 38vw, 460px);
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
}

.hero-cover__photo {
    width: 100%;
    height: auto;
    max-height: 100%;
    object-fit: contain;
    object-position: right bottom;
    filter: drop-shadow(0 20px 40px rgb(26 58 92 / 0.12));
}

/* Franja ondulada con titular */
.hero-cover__wave {
    position: relative;
    margin-top: -2px;
    background: linear-gradient(135deg, #2d7d5e 0%, #1e5f5c 40%, #1a3a5c 100%);
    padding: 2.25rem 1.5rem 2.75rem;
    text-align: center;
    clip-path: ellipse(120% 100% at 50% 100%);
}

.hero-cover__wave-inner {
    max-width: 40rem;
    margin: 0 auto;
}

.hero-cover__eyebrow {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    color: rgb(255 255 255 / 0.85);
    margin-bottom: 0.5rem;
}

.hero-cover__headline {
    font-size: clamp(1.75rem, 4.5vw, 2.75rem);
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin: 0 0 0.5rem;
}

.hero-cover__tagline {
    font-size: clamp(0.9375rem, 2vw, 1.125rem);
    color: rgb(255 255 255 / 0.92);
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.35rem;
}

.hero-cover__fenix-logo {
    height: 1.5rem;
    width: auto;
    vertical-align: middle;
    filter: brightness(0) invert(1);
}

/* Zona inferior: preview + formulario */
.hero-cover__bottom {
    background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
    padding: 0 1.5rem 3.5rem;
    margin-top: -1.5rem;
}

.hero-cover__bottom-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
    max-width: 72rem;
    margin: 0 auto;
    padding-top: 1.5rem;
}

.hero-preview__card {
    background: #fff;
    border: 1px solid var(--ciade-border);
    border-radius: var(--ciade-radius-xl);
    padding: 1.25rem 1.5rem;
    box-shadow: var(--ciade-shadow-md);
}

.hero-preview__header {
    display: flex;
    gap: 0.35rem;
    margin-bottom: 0.75rem;
}

.hero-preview__dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: #e2e8f0;
}

.hero-preview__dot:first-child { background: #f87171; }
.hero-preview__dot:nth-child(2) { background: #fbbf24; }
.hero-preview__dot:nth-child(3) { background: #34d399; }

.hero-preview__welcome {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--ciade-text);
    margin-bottom: 1rem;
}

.hero-preview__metrics {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.hero-preview__metric {
    background: var(--ciade-surface);
    border-radius: var(--ciade-radius);
    padding: 0.75rem;
}

.hero-preview__metric-label {
    display: block;
    font-size: 0.6875rem;
    color: var(--ciade-text-muted);
    margin-bottom: 0.25rem;
}

.hero-preview__metric strong {
    font-size: 1.125rem;
    color: var(--ciade-brand);
    letter-spacing: -0.02em;
}

.hero-preview__up {
    display: block;
    font-size: 0.6875rem;
    color: var(--ciade-success);
    font-weight: 600;
    margin-top: 0.15rem;
}

.hero-preview__list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hero-preview__list li {
    font-size: 0.8125rem;
    color: var(--ciade-text-muted);
    padding: 0.35rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.hero-preview__list i {
    color: var(--ciade-success);
    font-size: 0.875rem;
}

.hero-lead-card--cover {
    position: relative;
    z-index: 2;
    margin-top: -0.5rem;
}

/* Panel formulario hero */
.hero-lead-card {
    background: #fff;
    border: 1px solid var(--ciade-border, #e2e8f0);
    border-radius: var(--ciade-radius-2xl, 1.5rem);
    padding: 2rem;
    box-shadow: var(--ciade-shadow-md, 0 10px 25px -5px rgb(15 76 129 / 0.12));
}

.hero-lead-card__title {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--ciade-text);
    margin-bottom: 0.35rem;
}

.hero-lead-card__subtitle {
    font-size: 0.875rem;
    color: var(--ciade-text-muted);
    margin-bottom: 1.25rem;
}

.hero-lead-form .form-group {
    margin-bottom: 0.875rem;
}

.hero-lead-form label {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--ciade-text);
    margin-bottom: 0.35rem;
}

.hero-lead-form label .required {
    color: #dc2626;
}

.hero-lead-form input,
.hero-lead-form select {
    width: 100%;
    padding: 0.7rem 0.875rem;
    border: 1.5px solid var(--ciade-border);
    border-radius: var(--ciade-radius);
    font-size: 0.9375rem;
    font-family: inherit;
}

.hero-lead-form input:focus,
.hero-lead-form select:focus {
    outline: none;
    border-color: var(--ciade-brand);
    box-shadow: 0 0 0 3px rgb(15 76 129 / 0.12);
}

/* Cita / confianza */
.trust-quote {
    background: var(--ciade-brand, #0f4c81);
    color: #fff;
    padding: 2.5rem 1.5rem;
    text-align: center;
}

.trust-quote__inner {
    max-width: 48rem;
    margin: 0 auto;
}

.trust-quote blockquote {
    font-size: clamp(1.125rem, 2.5vw, 1.375rem);
    font-weight: 500;
    line-height: 1.6;
    margin: 0;
    font-style: normal;
}

.trust-quote blockquote strong {
    font-weight: 800;
    color: #7dd3fc;
}

.trust-quote__cta {
    margin-top: 1.25rem;
}

.trust-quote__cta a {
    color: #fff;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Catálogo productos (tarjetas resumen) */
.productos-catalog {
    padding: 0 0 4.5rem;
    background: #fff;
}

.productos-catalog__banner {
    max-width: 56rem;
    margin: 0 auto 2rem;
    padding: 0 1.5rem;
}

.productos-catalog__banner img {
    width: 100%;
    height: auto;
    border-radius: var(--ciade-radius-lg);
    box-shadow: var(--ciade-shadow-sm);
}

.productos-catalog__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.catalog-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid var(--ciade-border);
    border-radius: var(--ciade-radius-xl);
    padding: 0;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    height: 100%;
}

.catalog-card__visual {
    height: 5.5rem;
    overflow: hidden;
    background: linear-gradient(135deg, #2d7d5e, #1e5f5c);
}

.catalog-card__visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    opacity: 0.95;
}

.catalog-card h3,
.catalog-card p,
.catalog-card .catalog-card__link {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
}

.catalog-card h3 {
    padding-top: 1.25rem;
    margin-bottom: 0.5rem;
}

.catalog-card p {
    flex: 1;
    margin-bottom: 1rem;
}

.catalog-card .catalog-card__link {
    padding-bottom: 1.25rem;
}

.catalog-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--ciade-shadow-md);
    border-color: rgb(15 76 129 / 0.25);
    background: #fff;
}

.catalog-card__icon {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: var(--ciade-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    margin-bottom: 1rem;
}

.catalog-card__icon--blue {
    background: linear-gradient(135deg, #dbeafe, #bfdbfe);
    color: #1d4ed8;
}

.catalog-card__icon--green {
    background: linear-gradient(135deg, #d1fae5, #a7f3d0);
    color: #047857;
}

.catalog-card__icon--violet {
    background: linear-gradient(135deg, #ede9fe, #ddd6fe);
    color: #6d28d9;
}

.catalog-card__icon--amber {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #b45309;
}

.catalog-card__icon--cyan {
    background: linear-gradient(135deg, #cffafe, #a5f3fc);
    color: #0e7490;
}

.catalog-card__icon--slate {
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    color: #334155;
}

.catalog-card h3 {
    font-size: 1.125rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--ciade-text);
}

.catalog-card p {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--ciade-text-muted);
    flex: 1;
    margin-bottom: 1rem;
}

.catalog-card__link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--ciade-brand);
    text-decoration: none;
}

.catalog-card__link:hover {
    gap: 0.5rem;
}

/* Beneficios grid tipo Colmena */
.benefits--structured .benefits-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.benefits--structured .benefit-item {
    text-align: center;
    padding: 1.5rem 1rem;
    background: #fff;
    border: 1px solid var(--ciade-border);
    border-radius: var(--ciade-radius-xl);
}

.benefits--structured .benefit-icon {
    width: 3rem;
    height: 3rem;
    margin: 0 auto 1rem;
    border-radius: 50%;
    background: linear-gradient(135deg, rgb(15 76 129 / 0.1), rgb(14 165 233 / 0.08));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--ciade-brand);
    font-size: 1.25rem;
}

.benefits--structured .benefit-item h3 {
    font-size: 0.9375rem;
    font-weight: 700;
    margin-bottom: 0.35rem;
}

.benefits--structured .benefit-item p {
    font-size: 0.8125rem;
    line-height: 1.5;
    margin: 0;
}

/* Planes y precios */
.products--planes {
    background: var(--ciade-surface);
    padding: 4.5rem 0;
}

.products--planes .featured-products {
    display: none;
}

.products--planes .products-grid {
    margin-top: 0;
}

/* Testimonios */
.testimonios-section {
    padding: 4.5rem 0;
    background: #fff;
}

.testimonios-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.testimonio-card {
    background: var(--ciade-surface);
    border: 1px solid var(--ciade-border);
    border-radius: var(--ciade-radius-xl);
    padding: 1.75rem;
}

.testimonio-card__quote {
    font-size: 0.9375rem;
    line-height: 1.65;
    color: var(--ciade-text-muted);
    margin-bottom: 1.25rem;
    font-style: italic;
}

.testimonio-card__quote strong {
    color: var(--ciade-brand);
    font-style: normal;
    font-weight: 700;
}

.testimonio-card__author {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.testimonio-card__avatar {
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 50%;
    background: var(--ciade-gradient-brand);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.875rem;
}

.testimonio-card__name {
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--ciade-text);
}

.testimonio-card__role {
    font-size: 0.8125rem;
    color: var(--ciade-text-subtle);
}

/* Barra de estadísticas */
.stats-bar {
    background: var(--ciade-brand);
    color: #fff;
    padding: 3rem 1.5rem;
}

.stats-bar__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 56rem;
    margin: 0 auto;
    text-align: center;
}

.stats-bar__number {
    display: block;
    font-size: clamp(2rem, 4vw, 2.75rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1;
    margin-bottom: 0.35rem;
}

.stats-bar__label {
    font-size: 0.9375rem;
    opacity: 0.9;
    font-weight: 500;
}

/* CTA final */
.cta-banner {
    padding: 4rem 1.5rem;
    background: linear-gradient(135deg, #0f4c81 0%, #1a6bb5 50%, #0ea5e9 100%);
    text-align: center;
    color: #fff;
}

.cta-banner h2 {
    color: #fff;
    font-size: clamp(1.5rem, 3vw, 2.25rem);
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.cta-banner p {
    color: rgb(255 255 255 / 0.88);
    font-size: 1.0625rem;
    margin-bottom: 1.5rem;
}

.cta-banner .btn {
    background: #fff;
    color: var(--ciade-brand);
    box-shadow: 0 4px 20px rgb(0 0 0 / 0.15);
}

.cta-banner .btn:hover {
    transform: translateY(-2px);
    filter: none;
}

/* Secciones secundarias (menos prominentes) */
.layout-section-secondary {
    border-top: 1px solid var(--ciade-border);
}

.layout-section-secondary > .container > .section-header .section-eyebrow {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--ciade-text-subtle);
    margin-bottom: 0.5rem;
}

/* Demo simplificado (sin formulario duplicado) */
.demo--compact {
    padding: 3rem 0;
    background: var(--ciade-surface);
}

.demo--compact .demo-content {
    display: block;
    text-align: center;
    max-width: 36rem;
    margin: 0 auto;
}

.demo--compact .demo-form {
    display: none;
}

.section-eyebrow {
    display: block;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--ciade-brand);
    margin-bottom: 0.5rem;
}

/* Footer estructurado */
.footer--structured .footer-content {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 2rem;
}

.footer-products-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.25rem 1rem;
}

@media (max-width: 1024px) {
    .hero-cover__showcase-inner {
        grid-template-columns: 1fr;
        min-height: auto;
        text-align: center;
    }

    .hero-cover__lead {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-cover__actions {
        justify-content: center;
    }

    .hero-cover__trust {
        align-items: center;
    }

    .hero-cover__figure {
        min-height: 240px;
        justify-content: center;
    }

    .hero-cover__photo {
        object-position: center bottom;
        max-width: 100%;
    }

    .hero-cover__bottom-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .hero-preview {
        order: 2;
    }

    .hero-lead-card--cover {
        order: 1;
        margin-top: 0;
    }

    .productos-catalog__grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .benefits--structured .benefits-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .testimonios-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .hero-cover__actions {
        flex-direction: column;
    }

    .hero-cover__actions .btn {
        width: 100%;
        justify-content: center;
    }

    .hero-cover__wave {
        padding: 1.75rem 1rem 2.25rem;
    }

    .hero-cover__bottom {
        padding-bottom: 2.5rem;
    }

    .productos-catalog__grid {
        grid-template-columns: 1fr;
    }

    .benefits--structured .benefits-grid {
        grid-template-columns: 1fr;
    }

    .stats-bar__grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .footer--structured .footer-content {
        grid-template-columns: 1fr;
    }
}

