/* Landing (#43). Palette, fonts, scales, header and footer: base-oscura.css */

:root {
    --step-hero: clamp(2.0736rem, 1.5340rem + 2.6980vi, 3.6250rem);
}

/* Hero: one column, two from 54rem */
.landing-hero {
    width: min(100% - 2 * var(--space-s-l), var(--ancho));
    margin-inline: auto;
    display: grid;
    gap: calc(var(--space-xl) + var(--space-l));
    align-items: center;
    padding-block: var(--space-m-xl) var(--space-l-2xl);
}

.etiqueta {
    display: inline-block;
    margin-bottom: var(--space-m);
    padding: var(--space-3xs) var(--space-xs);
    border: 1px solid var(--borde);
    border-radius: 100px;
    color: var(--acento);
    font-family: var(--mono);
    /* One line down to 320 px: it shrinks with its column when needed */
    font-size: min(var(--step--2), 3.4cqi);
    white-space: nowrap;
}

/* The headline also follows its column, so the longest first sentence
   ("Escribe en texto plano.", about 11.3 em) stays on one line */
.texto { container-type: inline-size; }

.landing h1 {
    margin: 0 0 var(--space-m);
    font-size: min(var(--step-hero), 8.6cqi);
    font-weight: 800;
    line-height: 1.08;
    letter-spacing: -.02em;
}

.landing h1 em { font-style: normal; color: var(--acento); }

.intro {
    max-width: 33em;
    margin: 0 0 var(--space-l);
    color: var(--texto-suave);
    font-size: var(--step-0);
    line-height: 1.6;
}

.cta {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2xs);
    padding: var(--space-s) var(--space-l);
    border-radius: 100px;
    background: var(--acento);
    box-shadow: 0 10px 30px -10px rgba(243, 146, 0, .6);
    color: var(--sobre-acento);
    font-size: var(--step-1);
    font-weight: 700;
    text-decoration: none;
    transition: transform .15s;
}

.cta:hover { transform: translateY(-2px); }
.cta:focus-visible { outline: 3px solid var(--texto); outline-offset: 3px; }

.nota { margin: var(--space-s) 0 0; color: var(--texto-suave); font-size: var(--step--1); }

.ventajas {
    display: grid;
    gap: var(--space-xs);
    margin: var(--space-xl) 0 0;
    padding: 0;
    list-style: none;
}

.ventajas li { display: flex; gap: var(--space-xs); align-items: baseline; }

.ventajas li::before {
    content: "›";
    color: var(--acento);
    font-family: var(--mono);
    font-weight: 600;
}

/* Example email, tilted, with its plain text behind. The inline margin
   keeps the rotated corners inside narrow viewports */
.escena { position: relative; margin-inline: var(--space-s); }

.escena::before {
    content: "";
    position: absolute;
    inset: 8% -6% -4% 6%;
    z-index: 0;
    border-radius: 24px;
    background: radial-gradient(circle at 60% 40%, rgba(243, 146, 0, .35), transparent 65%);
    filter: blur(30px);
}

/* The plain text sits on top of the email's top-right corner, tilted the
   same way: the simple input next to what it turns into */
.plain {
    position: absolute;
    z-index: 3;
    top: -2.5rem;
    right: -2%;
    width: 70%;
    padding: var(--space-xs) var(--space-s);
    border: 1px solid var(--borde);
    border-radius: 12px;
    background: var(--superficie);
    box-shadow: 0 24px 48px -12px rgba(0, 0, 0, .75);
    color: var(--texto-suave);
    font-family: var(--mono);
    font-size: var(--step--2);
    line-height: 1.6;
    transform: rotate(6deg);
}

.plain p { margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plain .md { color: var(--acento); font-weight: 600; }

.correo {
    position: relative;
    z-index: 2;
    overflow: hidden;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 40px 80px -20px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .06);
    color: #1f1f1f;
    transform: rotate(3deg) translateY(1.25rem);
}

.correo-barra {
    display: flex;
    gap: 6px;
    padding: 10px 14px;
    border-bottom: 1px solid #e3e3e3;
    background: #f1f1f1;
}

.correo-barra span { width: 10px; height: 10px; border-radius: 50%; background: #d4d4d4; }

.correo-cab {
    padding: var(--space-xs) var(--space-m) var(--space-2xs);
    border-bottom: 1px solid #eee;
    font-family: Arial, sans-serif;
}

.correo-cab .asunto { margin: 0 0 6px; font-size: var(--step-0); font-weight: bold; }
.correo-cab .de { color: #666; font-size: var(--step--2); }

/* The generated email carries its own inline 16px type: zoom scales it
   down as a whole, like a thumbnail of the real message */
.correo-cuerpo {
    padding: var(--space-xs) var(--space-m) var(--space-s);
    zoom: .8;
}

.correo-cuerpo a { color: #1a5fb4; }
.correo-cuerpo .eg-button-link { color: #fff; }

@media (min-width: 54rem) {
    .landing-hero {
        grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
        gap: var(--space-l-2xl);
    }

    /* Top-aligned, not centred on the example: each language's email has
       a different height, and the headline must not move with it */
    .texto { align-self: start; padding-top: var(--space-xl); }

    .escena { margin-inline: 0; }
    .plain { top: -0.75rem; right: -2%; width: 52%; transform: rotate(7deg); }
    .correo { transform: rotate(4deg) translateY(1.875rem); }
    .correo-cuerpo { zoom: .82; }
}

/* Entrance: the email first, then the plain text lands on it. They animate
   translate (not transform), so their tilt stays untouched */
@keyframes aparece {
    from { opacity: 0; translate: 0 1.5rem; }
}

.correo { animation: aparece .6s ease-out .15s backwards; }
.plain { animation: aparece .5s ease-out .65s backwards; }

@media (prefers-reduced-motion: reduce) {
    .cta { transition: none; }
    .correo, .plain { animation: none; }
}
