/* =========================================================
   Páginas internas: producto (Process, Merco) y contacto.
   Depende de master.css (tokens y componentes).
   ========================================================= */

/* ---------- Cabecera de página ---------- */

.page-hero {
    position: relative;
    padding: calc(var(--nav-h) + 112px) 0 clamp(80px, 9vw, 128px);
    overflow: hidden;
    isolation: isolate;
    background:
        radial-gradient(110% 70% at 75% -10%, #0e2d52 0%, rgba(5, 14, 27, 0) 60%),
        var(--night-900);
}

.page-hero__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(40px, 5vw, 80px);
    align-items: center;
}

.page-hero .display {
    margin: 22px 0 24px;
    font-size: clamp(2.5rem, 1rem + 4.2vw, 5rem);
}

.page-hero .lead {
    max-width: 58ch;
}

.page-hero__logo {
    width: auto;
    height: clamp(44px, 4vw, 60px);
    margin-top: 28px;
}

.page-hero__logo--stacked {
    height: clamp(68px, 6vw, 92px);
}

.page-hero__ctas {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 40px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--text-2);
    transition: color 0.3s ease;
}

.back-link svg {
    width: 14px;
    height: 14px;
    transition: transform 0.5s var(--ease-out);
}

.back-link:hover {
    color: var(--text);
}

.back-link:hover svg {
    transform: translateX(-3px);
}

/* Vitrina con la ilustración del producto */
.showcase {
    position: relative;
    overflow: hidden;
    aspect-ratio: 560 / 360;
    border-radius: var(--radius-lg);
    background:
        radial-gradient(70% 90% at 50% 0%, rgba(33, 128, 187, 0.32), transparent 70%),
        linear-gradient(to right, rgba(255, 255, 255, 0.035) 1px, transparent 1px) 0 0 / 32px 32px,
        linear-gradient(to bottom, rgba(255, 255, 255, 0.035) 1px, transparent 1px) 0 0 / 32px 32px,
        linear-gradient(180deg, #0b1f39 0%, #07162a 100%);
    box-shadow: inset 0 0 0 1px var(--line), 0 40px 80px -40px rgba(0, 0, 0, 0.7);
}

.showcase > svg {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.showcase__img {
    position: absolute;
    inset: 0;
    margin: auto;
    width: 46%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.5));
}

/* Sección oscura seguida de la zona clara (.sheet), que se superpone */
.section--before-sheet,
.section--features {
    padding-top: 0;
    padding-bottom: calc(var(--section-y) * 0.6 + var(--radius-xl));
}

/* Capacidades del producto (reutiliza .pillar) */
.features {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.features .pillar {
    min-height: 250px;
}

.features .pillar h3 {
    padding-top: 48px;
}


/* ---------- Contacto ---------- */

.contact {
    position: relative;
    min-height: 100svh;
    padding: calc(var(--nav-h) + 104px) 0 120px;
    overflow: hidden;
    isolation: isolate;
    background:
        radial-gradient(110% 70% at 80% -10%, #0e2d52 0%, rgba(5, 14, 27, 0) 60%),
        var(--night-900);
}

.contact__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: clamp(40px, 6vw, 96px);
    align-items: start;
}

.contact .display {
    margin: 22px 0 24px;
    font-size: clamp(2.5rem, 1rem + 4vw, 4.75rem);
}

.contact-list {
    display: grid;
    gap: 12px;
    margin-top: 48px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px 16px 16px;
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: inset 0 0 0 1px var(--line);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

a.contact-item:hover {
    background: rgba(255, 255, 255, 0.06);
    box-shadow: inset 0 0 0 1px var(--line-2);
}

.contact-item__icon {
    display: grid;
    flex: none;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 14px;
    color: var(--brand-300);
    background: rgba(108, 194, 240, 0.08);
    box-shadow: inset 0 0 0 1px rgba(108, 194, 240, 0.2);
}

.contact-item__icon svg {
    width: 20px;
    height: 20px;
}

.contact-item small {
    display: block;
    margin-bottom: 2px;
    font-family: var(--font-mono);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-3);
}

.contact-item strong {
    font-size: 16px;
    font-weight: 500;
    line-height: 1.4;
    color: var(--text);
}

.contact .socials {
    margin-top: 32px;
}

/* Tarjeta del formulario */
.form-card {
    padding: clamp(28px, 4vw, 48px);
    border-radius: var(--radius-lg);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.02));
    box-shadow: inset 0 0 0 1px var(--line-2), 0 40px 100px -40px rgba(0, 0, 0, 0.8);
    -webkit-backdrop-filter: blur(20px);
    backdrop-filter: blur(20px);
}

.form-card__title {
    margin-bottom: 28px;
    font-size: 24px;
    font-weight: 500;
    letter-spacing: -0.03em;
}

.form {
    display: grid;
    gap: 20px;
}

.form__row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.field label {
    display: block;
    margin-bottom: 8px;
    font-size: 13.5px;
    color: var(--text-2);
}

.field label abbr {
    text-decoration: none;
    color: var(--brand-300);
}

.field input,
.field textarea {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    border: 0;
    border-radius: 14px;
    background: rgba(3, 10, 20, 0.55);
    box-shadow: inset 0 0 0 1px var(--line-2);
    font-size: 15.5px;
    color: var(--text);
    transition: box-shadow 0.3s ease, background-color 0.3s ease;
}

.field textarea {
    height: 148px;
    padding: 14px 16px;
    line-height: 1.55;
    resize: vertical;
}

.field input::placeholder,
.field textarea::placeholder {
    color: var(--text-3);
    opacity: 0.75;
}

.field input:hover,
.field textarea:hover {
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22);
}

.field input:focus,
.field textarea:focus {
    outline: none;
    background: rgba(3, 10, 20, 0.75);
    box-shadow: inset 0 0 0 1px var(--brand-300), 0 0 0 4px rgba(108, 194, 240, 0.14);
}

.field.is-invalid input,
.field.is-invalid textarea {
    box-shadow: inset 0 0 0 1px #ff8f8f, 0 0 0 4px rgba(255, 143, 143, 0.12);
}

.field__error {
    margin-top: 6px;
    font-size: 12.5px;
    color: #ffb0b0;
}

.field__error:empty {
    display: none;
}

.check {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--text-2);
    cursor: pointer;
}

.check input {
    flex: none;
    width: 20px;
    height: 20px;
    margin-top: 1px;
    border-radius: 6px;
    background: rgba(3, 10, 20, 0.55);
    box-shadow: inset 0 0 0 1px var(--line-2);
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.check input:checked {
    background: var(--brand-300) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12' fill='none' stroke='%23050e1b' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2.8 6.2l2.1 2.1 4.3-4.6'/%3E%3C/svg%3E") center / 12px no-repeat;
    box-shadow: none;
}

.check a {
    color: var(--text);
    text-decoration: underline;
    text-decoration-color: rgba(255, 255, 255, 0.3);
    text-underline-offset: 3px;
}

.check.is-invalid input {
    box-shadow: inset 0 0 0 1px #ff8f8f;
}

.form .btn {
    width: 100%;
    margin-top: 4px;
}

.form__status {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(61, 220, 151, 0.08);
    box-shadow: inset 0 0 0 1px rgba(61, 220, 151, 0.28);
    font-size: 14px;
    line-height: 1.5;
    color: #bff3da;
}

.form__status svg {
    flex: none;
    width: 16px;
    height: 16px;
    margin-top: 2px;
    color: var(--mint);
}

.form__note {
    margin-top: 28px;
    padding-top: 22px;
    border-top: 1px solid var(--line);
    font-size: 14px;
    color: var(--text-3);
}

.form__note a {
    color: var(--text);
    font-weight: 500;
}


@supports (overflow: clip) {
    .page-hero,
    .showcase,
    .contact {
        overflow: clip;
    }
}


/* ---------- Pie compacto ---------- */

.footer--compact .footer__bottom {
    border-top: 0;
}

.footer__legal {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
}

.footer__legal a {
    color: var(--text-3);
    transition: color 0.3s ease;
}

.footer__legal a:hover {
    color: var(--text);
}


/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
    .page-hero__inner,
    .contact__inner {
        grid-template-columns: minmax(0, 1fr);
    }

    .showcase {
        max-width: 720px;
    }

    .features {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .page-hero {
        padding-top: calc(var(--nav-h) + 72px);
    }

    .contact {
        padding-top: calc(var(--nav-h) + 72px);
        padding-bottom: 80px;
    }

    .page-hero__ctas .btn {
        flex: 1 1 100%;
    }

    .features {
        grid-template-columns: minmax(0, 1fr);
    }

    .features .pillar {
        min-height: 0;
    }

    .form__row {
        grid-template-columns: minmax(0, 1fr);
    }
}
