/*
 * Cero FSE — front.css
 * Único CSS del front: cabecera, pie, hero, bandas full-bleed, FAQ y formulario.
 *
 */

/* ---------- Base ---------- */
html {
        scroll-behavior: smooth;
        overflow-x: clip;
}
html, body, * {
  scrollbar-width: thin;
  scrollbar-color: var(--wp--preset--color--forest) var(--wp--preset--color--paper);
}

[id] { scroll-margin-top: 5.5rem; } /* anclas #contacto bajo la cabecera sticky */

a {
        text-decoration-thickness: 1px;
        text-underline-offset: 0.2em;
}

:focus-visible {
        outline: 2px solid var(--wp--preset--color--forest);
        outline-offset: 2px;
}

body { overflow-wrap: break-word; }
        :where(.wp-block-columns) {
        margin-bottom: 2.75em;
}

/* ---------- Cabecera sticky (regla confirmada) ---------- */
.wp-site-blocks > .wp-block-template-part:first-child {
        position: sticky;
        top: 0;
        z-index: 999;
        background-color:#fbfaf680;
        -webkit-backdrop-filter: blur(15px);
        backdrop-filter: blur(15px);
        /*background: var(--wp--preset--color--paper);*/
        border-bottom: 1px solid var(--wp--preset--color--line);
}

body.admin-bar .wp-site-blocks > .wp-block-template-part:first-child { top: 32px; }

@media (max-width: 782px) {
        body.admin-bar .wp-site-blocks > .wp-block-template-part:first-child { top: 46px; }
}

/* ---------- Cabecera (interior) ---------- */
.cero-header {
        padding-block: 0.8rem;
}

.cero-header .cero-logo {
        display: inline-flex;
        align-items: center;
        text-decoration: none;
}

.cero-header .cero-logo svg,
.cero-header .cero-logo img {
        height: 44px;
        width: auto;
        display: block;
}

/* Logotipo textual (marcador mientras no haya SVG definitivo) */
.cero-header .cero-logo--text {
        font-size: 1.15rem;
        font-weight: 600;
        color: var(--wp--preset--color--ink);
        text-decoration: none;
        white-space: nowrap;
}

.cero-header .cero-logo--text strong {
        color: var(--wp--preset--color--forest);
}

.cero-header .wp-block-navigation { font-weight: 500; }

.cero-header .wp-block-navigation a { text-decoration: none; }

.cero-header .wp-block-button__link {
        padding-block: 0.55rem;
        padding-inline: 1.4rem;
        font-size: 0.85rem;
}

/* ---------- Contenido principal ---------- */
.cero-main {
        padding-block: clamp(2.5rem, 6vw, 5rem) clamp(3rem, 7vw, 5.5rem);
}

.cero-kicker {
        color: var(--wp--preset--color--forest);
        font-weight: 600;
        font-size: 0.8rem;
        letter-spacing: 0.12em;
        text-transform: uppercase;
        margin: 0 0 0.6rem;
}

.cero-hero { padding-block: clamp(0.5rem, 2vw, 1.5rem); }

/* Columnas en Z: contenido centrado verticalmente */
@media (min-width: 782px) {
        .cero-z > .wp-block-column {
                display: flex;
                flex-direction: column;
                justify-content: center;
        }
}

/* ---------- Bandas a ancho completo (align:full) ----------
 * v1.3: las bandas llevan align "full" en el patrón. Con
 * useRootPaddingAwareAlignments (theme.json) los hijos alignfull escapan al
 * padding raíz y el fondo llega a los bordes sin pelear con el margin
 * auto !important que core impone a los hijos no-full del layout
 * constrained. padding-inline re-alinea el contenido con la página
 * (34rem = contentSize 68rem / 2). */
.cero-band,
.cero-dark,
.cero-mint {
        padding-inline: max(1.25rem, calc(50vw - 34rem));
        padding-block: clamp(3.25rem, 7vw, 5.5rem);
}

/* ---------- Tarjetas ---------- */
.cero-card {
        border-radius: 20px;
        padding: clamp(1.75rem, 3.5vw, 2.75rem);
        height: 100%;
}

.cero-card > * { max-width: none; }

.cero-card hr.wp-block-separator {
        border: 0;
        border-top: 1px solid rgba(24, 21, 18, 0.14);
        margin: 0.4rem 0 1.2rem;
}

/* Tarjeta de cita (tinta) */
.cero-claim {
        font-size: clamp(1.5rem, 2.8vw, 2.2rem);
        line-height: 1.3;
        font-weight: 500;
        margin: 0;
}

/* ---------- Listas con ✓ ---------- */
.cero-list {
        list-style: none;
        margin: 0;
        padding: 0;
}

.cero-list li {
        position: relative;
        padding-left: 2.1rem;
        margin: 0 0 0.8rem;
}

.cero-list li::before {
        content: "✓";
        position: absolute;
        left: 0;
        top: 0.05em;
        width: 1.35rem;
        height: 1.35rem;
        border-radius: 50%;
        background: var(--wp--preset--color--forest);
        color: #fff;
        font-size: 0.8rem;
        font-weight: 700;
        line-height: 1.35rem;
        text-align: center;
}

/* ---------- Banda forest (Pide tu cita) ---------- */
.cero-band h2 {
        color: var(--wp--preset--color--paper);
        margin: 0 0 1.5rem;
}

.cero-band a {
        color: var(--wp--preset--color--paper); /* el tema pinta enlaces verde: invisible sobre forest */
}

.cero-band__label {
        font-size: 0.75rem;
        font-weight: 600;
        letter-spacing: 0.08em;
        text-transform: uppercase;
        opacity: 0.75;
        margin: 0 0 0.3rem;
}

.cero-band p { margin: 0; }

.cero-band__label { margin-bottom: 0.3rem; }


.cero-band + * {
        margin-block-start: 3.5rem;
        margin-block-end: 3rem;
}


.cero-band__label {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.55rem;
        margin-bottom: 0.55rem;
}

.cero-band__label::before {
        content: "";
        width: 1.5rem;
        height: 1.5rem;
        flex: 0 0 auto;
        background-color: var(--wp--preset--color--paper);
        opacity: 0.92;
        -webkit-mask-repeat: no-repeat;
        mask-repeat: no-repeat;
        -webkit-mask-position: left center;
        mask-position: left center;
        -webkit-mask-size: contain;
        mask-size: contain;
}

.cero-band .wp-block-column:nth-child(1) .cero-band__label::before { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.91.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.36 1.9.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.91.34 1.85.57 2.81.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E"); }
.cero-band .wp-block-column:nth-child(2) .cero-band__label::before { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4' width='18' height='18' rx='2'/%3E%3Cpath d='M16 2v4M8 2v4M3 10h18'/%3E%3C/svg%3E"); }
.cero-band .wp-block-column:nth-child(3) .cero-band__label::before { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13S3 17 3 10a9 9 0 0 1 18 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 10c0 7-9 13-9 13S3 17 3 10a9 9 0 0 1 18 0z'/%3E%3Ccircle cx='12' cy='10' r='3'/%3E%3C/svg%3E"); }
.cero-band .wp-block-column:nth-child(4) .cero-band__label::before { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 6v6l4 2'/%3E%3C/svg%3E"); }


/* Respaldo si alguna página aún usa el bloque dinámico cero/contact-band */
.cero-band__grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 1.5rem;
}

.cero-band__value {
        margin: 0;
        font-weight: 550;
        line-height: 1.45;
}

/* ---------- Sección oscura (Tu tipo de implante) ---------- */
.cero-dark h2,
.cero-dark h3 {
        color: var(--wp--preset--color--paper);
}

.cero-dark p {
        color: rgba(251, 250, 246, 0.78);
}

.cero-dark .wp-block-button__link {
        background: transparent;
        color: var(--wp--preset--color--paper);
        border: 1px solid rgba(251, 250, 246, 0.45);
}

.cero-dark .wp-block-button__link:hover {
        background: var(--wp--preset--color--paper);
        color: var(--wp--preset--color--ink);
}

/* ---------- FAQ ---------- */
.cero-faq h3 {
        margin: 0;
        padding: 1.4rem 0 0.55rem;
        border-top: 1px solid var(--wp--preset--color--line);
        font-size: 1.1rem;
        font-weight: 550;
        color: var(--wp--preset--color--ink);
}

.cero-faq h3::before {
        content: "";
        display: inline-block;
        width: 0.55rem;
        height: 0.55rem;
        border-radius: 50%;
        background: var(--wp--preset--color--forest);
        margin-right: 0.7rem;
        vertical-align: 0.12em;
}

.cero-faq p {
        margin: 0;
        padding-bottom: 1.4rem;
        color: var(--wp--preset--color--muted);
        max-width: 62ch;
}

.cero-faq > :last-child {
        border-bottom: 1px solid var(--wp--preset--color--line);
}

/* Respaldo FAQ con <details> (bloque cero/schema-faq) */
.cero-faq details {
        background: #fff;
        border: 1px solid var(--wp--preset--color--line);
        border-radius: 0.9rem;
        padding: 1rem 1.25rem;
}

.cero-faq details + details { margin-top: 0.75rem; }

.cero-faq summary {
        cursor: pointer;
        font-weight: 550;
        display: flex;
        justify-content: space-between;
        align-items: baseline;
        gap: 1rem;
        list-style: none;
}

.cero-faq summary::-webkit-details-marker { display: none; }

.cero-faq summary::after {
        content: "+";
        flex: 0 0 auto;
        font-weight: 400;
        color: var(--wp--preset--color--muted);
}

.cero-faq details[open] summary::after { content: "–"; }

.cero-faq details > p {
        margin: 0.75rem 0 0;
        padding: 0;
        border: 0;
        color: var(--wp--preset--color--muted);
        max-width: none;
}

/* ---------- Formulario (bloque cero/lead-form) ---------- */
.cero-form {
        /*max-width: 42rem;*/
        margin-inline: auto;
}

.cero-form h2 { margin-bottom: 0.5rem; }

.cero-form__intro { margin-bottom: 1.5rem; }

.cero-form__grid {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.1rem;
}

.cero-form__field { margin: 0; }

.cero-form__field--full { grid-column: 1 / -1; }

.cero-form label {
        display: block;
        font-size: 0.95rem;
        font-weight: 600;
        margin-bottom: 0.4rem;
}

.cero-form input[type="text"],
.cero-form input[type="email"],
.cero-form input[type="tel"],
.cero-form select,
.cero-form textarea {
        width: 100%;
        border: 1px solid var(--wp--preset--color--line);
        border-radius: 12px;
        padding: 0.85rem 1rem;
        font: inherit;
        background: #fff;
        color: inherit;
        box-sizing: border-box;
}

.cero-form input:focus,
.cero-form select:focus,
.cero-form textarea:focus {
        border-color: var(--wp--preset--color--forest);
        box-shadow: 0 0 0 3px rgba(30, 107, 74, 0.14);
        outline: none;
}
.cero-form form .cero-form__grid {
        column-gap: 1.25rem !important;
        row-gap: 1.25rem !important;
}
.cero-form select {
        -webkit-appearance: none;
        appearance: none;
        min-height: 3.4rem;
        line-height: 1.55;
        padding: 0.85rem 2.5rem 0.85rem 1rem !important;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none' stroke='%231E6B4A' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-position: right 1rem center;
}

.cero-form__consent {
        display: flex;
        align-items: flex-start;
        gap: 0.6rem;
}

.cero-form__consent label {
        font-weight: 400;
        font-size: 0.85rem;
        line-height: 1.55;
        margin: 0;
}

.cero-form__consent input[type="checkbox"] {
        width: 1.15rem;
        height: 1.15rem;
        margin-top: 0.18rem;
        flex: 0 0 auto;
        accent-color: var(--wp--preset--color--forest);
}

/* Honeypot: fuera de pantalla */
.cero-form__hp {
        position: absolute;
        left: -9999px;
        width: 1px;
        height: 1px;
        overflow: hidden;
}

.cero-form__actions { display: flex; }

.cero-form button[type="submit"] {
        padding: 0.9rem 2.4rem;
        border: 0;
        border-radius: 999px;
        background: var(--wp--preset--color--forest);
        color: #fff;
        font: inherit;
        font-size: 0.95rem;
        font-weight: 550;
        cursor: pointer;
}

.cero-form button[type="submit"]:hover {
        background: var(--wp--preset--color--ink);
}

.cero-form.is-sending .wp-block-button__link,
.cero-form button[type="submit"][disabled] {
        opacity: 0.6;
        pointer-events: none;
}

.cero-form__msg {
        display: none;
        margin: 0;
        padding: 0.8rem 1rem;
        border-radius: 0.6rem;
        font-size: 0.9rem;
}

.cero-form__msg.is-ok {
        display: block;
        background: var(--wp--preset--color--mint);
        color: #14532d;
}

.cero-form__msg.is-error {
        display: block;
        background: #fdecea;
        color: #8a1f1a;
}

.cero-turnstile { min-height: 65px; }

/* ---------- Pie ---------- */
.cero-footer {
        padding-block: clamp(3rem, 6vw, 4.5rem) clamp(1.75rem, 3vw, 2.5rem);
        margin-top: 0;
}

.cero-footer a {
        color: var(--wp--preset--color--paper);
        text-underline-offset: 0.2em;
}

.cero-footer .wp-block-heading {
        font-size: 0.85rem;
        font-weight: 600;
        letter-spacing: 0.1em;
        text-transform: uppercase;
        color: rgba(251, 250, 246, 0.65);
        margin: 0 0 0.9rem;
}

.cero-footer ul {
        list-style: none;
        margin: 0;
        padding: 0;
}

.cero-footer li { margin: 0 0 0.45rem; }

.cero-footer p { margin: 0 0 0.8rem; }

.cero-footer__bottom {
        border-top: 1px solid rgba(251, 250, 246, 0.18);
        margin-top: 2.5rem !important;
        padding-top: 1.25rem;
        font-size: 0.85rem;
        color: rgba(251, 250, 246, 0.65);
}

/* ---------- Responsive ---------- */
@media (max-width: 781px) {
        .cero-header .cero-logo svg,
        .cero-header .cero-logo img { height: 34px; }
        .cero-form__grid { grid-template-columns: 1fr; }
        .cero-band,
        .cero-dark,
        .cero-mint { padding-block: clamp(2.5rem, 9vw, 3.5rem); }
}

@media (prefers-reduced-motion: reduce) {
        html { scroll-behavior: auto; }
}

@media print {
        .cero-form__actions { display: none; }
}

/* ---- efectos ------*/
@keyframes destelloCaptacion {
    0% {
        background-position: 0% 0%;
    }
    100% {
        background-position: 400% 0%;
    }
}

.cero-band.has-forest-background-color {
    background-color: var(--wp--preset--color--forest) !important;
    background-image: linear-gradient(
        135deg,
        #8EC030 0%,
        #62BC73 25%,
        #35B9B8 50%,
        #62BC73 75%,
        #8EC030 100%
    ) !important;
    background-size: 400% 100% !important;
    animation: destelloCaptacion 12s linear infinite !important;
    will-change: background-position;
}

@media (prefers-reduced-motion: reduce) {
    .cero-band.has-forest-background-color {
        animation: none !important;
        background-size: 100% 100% !important;
        background-image: linear-gradient(135deg, #8EC030 0%, #62BC73 50%, #35B9B8 100%) !important;
    }
}

/* ---------- Botón flotante de WhatsApp ---------- */
.cero-wa {
        position: fixed;
        right: clamp(1rem, 3vw, 2rem);
        bottom: clamp(1rem, 3vw, 2rem);
        z-index: 90; /* bajo la cabecera (999), sobre el contenido */
        display: grid;
        place-items: center;
        width: 3.5rem;
        height: 3.5rem;
        border-radius: 999px;
        background: var(--wp--preset--color--forest);
        color: var(--wp--preset--color--paper);
        box-shadow: 0 10px 24px rgba(30, 107, 74, 0.35);
        transition: transform .2s ease, box-shadow .2s ease;
}

.cero-wa svg { width: 1.75rem; height: 1.75rem; display: block; }

.cero-wa:hover,
.cero-wa:focus-visible {
        transform: translateY(-3px);
        box-shadow: 0 14px 28px rgba(30, 107, 74, 0.45);
        color: var(--wp--preset--color--paper);
}

.cero-wa:focus-visible {
        outline: 2px solid var(--wp--preset--color--paper);
        outline-offset: 3px;
}

@media (max-width: 781px) {
        .cero-wa { width: 3rem; height: 3rem; }
        .cero-wa svg { width: 1.5rem; height: 1.5rem; }
}