/* ==========================================================================
   Beynaa public website: page sections
   Spacing follows the 1440px Figma frames, expressed as fluid ranges.
   ========================================================================== */

.hero {
    position: relative;
}

/* --- Home ---------------------------------------------------------------- */

.hero--home {
    padding-block: clamp(3.5rem, 1rem + 9vw, 10.3rem) clamp(4.5rem, 1rem + 12vw, 16.5rem);
}

.hero__tagline {
    max-width: 36.5rem;
    margin-top: clamp(1rem, 0.6rem + 1.2vw, 1.6rem);
    color: var(--c-brand);
    font-size: var(--fs-tagline);
    font-weight: 500;
    line-height: 1.47;
    text-wrap: pretty;
}

/*
 | Full-screen hero over the brand film, running up behind the transparent
 | header (the page drops the usual header offset). The film is mostly dark
 | and busy, so the copy turns light on a navy scrim, strongest behind the
 | text column and along the top edge where the nav sits.
 */
body.landing.has-video-hero {
    padding-top: 0;
}

.hero--video {
    isolation: isolate;
    overflow: clip;
    display: grid;
    align-items: center;
    min-height: 100vh;
    min-height: 100svh;
    padding-block: calc(var(--header-h) + clamp(1.5rem, 1rem + 2vw, 3rem)) clamp(4rem, 2rem + 7vw, 8rem);
    margin-bottom: clamp(3rem, 2rem + 4vw, 6rem);
    background: var(--c-ink);
}

.hero__media {
    position: absolute;
    inset: 0;
    z-index: -1;
}

.hero__video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero__media::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgb(8 9 47 / 0.6) 0%, transparent 22%),
        linear-gradient(90deg, rgb(8 9 47 / 0.82) 0%, rgb(8 9 47 / 0.55) 45%, rgb(8 9 47 / 0.12) 100%),
        linear-gradient(0deg, rgb(8 9 47 / 0.45) 0%, transparent 45%);
}

.hero--video .display {
    color: var(--c-white);
    text-shadow: 0 2px 24px rgb(8 9 47 / 0.35);
}

.hero--video .accent {
    color: #C9A74D; /* the logo gold: the text gold is too dark on navy */
}

.hero--video .hero__tagline {
    color: var(--c-glow);
}

@media (max-width: 47.99em) {
    .hero__media::after {
        background: linear-gradient(0deg, rgb(8 9 47 / 0.85) 0%, rgb(8 9 47 / 0.55) 60%, rgb(8 9 47 / 0.35) 100%);
    }
}

/* --- Centred pages (Join, Security, You're on the list) ------------------ */

.hero--center {
    --glow-top: 50%;
    padding-block: clamp(3rem, 1.5rem + 5vw, 8.2rem) clamp(6rem, 3rem + 10vw, 14rem);
    text-align: center;
}

.hero--center .display {
    margin-top: 0.6rem;
}

.hero--center .lead {
    max-width: 30rem;
    margin: clamp(1rem, 0.8rem + 0.6vw, 1.4rem) auto 0;
}

.hero--center .btn {
    margin-top: clamp(2rem, 1.5rem + 1.5vw, 3.3rem);
}

/* --- Cards --------------------------------------------------------------- */

.hero--cards {
    isolation: isolate;
    overflow: clip;
    padding-top: clamp(2.5rem, 1rem + 6vw, 9.125rem);
}

/* The halo behind the card line-up. */
.hero--cards::before {
    content: "";
    position: absolute;
    z-index: -1;
    top: clamp(6rem, 2rem + 14vw, 11rem);
    left: 34.7%;
    width: max(65.4%, 34rem);
    aspect-ratio: 942 / 820;
    border-radius: 50%;
    background: radial-gradient(56% 66% at 50% 4%, var(--c-white) 0%, var(--c-glow) 100%);
    filter: blur(64px);
    opacity: 0.9;
    pointer-events: none;
}

.cards-hero {
    display: grid;
    justify-items: start;
    gap: 2rem;
}

.cards-hero__copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 30.125rem;
}

.cards-hero__copy .display {
    margin-top: 0.7rem;
}

.cards-hero__copy .lead {
    margin-top: 1.4rem;
    line-height: 1.65;
}

.cards-hero__video {
    --btn-h: 3.375rem;
    padding-inline: 1.1rem 1.4rem;
    color: #000;
    font-size: 1.125rem;
}

.cards-hero__video .icon {
    color: var(--c-ink);
}

.cards-hero__lineup {
    justify-self: stretch;
}

.cards-hero__lineup img {
    width: 100%;
    transition: translate 0.6s var(--ease-out);
}

.cards-hero__lineup:hover img {
    translate: 0 -6px;
}

/*
 | From laptop width the line-up sits right of a 29.5% column (the design's
 | 466px start) and runs past the container edge; "Watch video" takes that
 | column beside it. The line-up tucks up by one line of the lead, whose last
 | line ("Built for the world.") is short enough to clear it. The card names
 | in the next section share the same geometry through .lineup-track.
 */
@media (min-width: 64em) {
    .cards-hero {
        grid-template-columns: 29.52% minmax(0, 1fr);
        row-gap: 0;
        column-gap: 0;
    }

    .cards-hero__copy {
        grid-column: 1 / -1;
        position: relative;
        z-index: 1;
    }

    .cards-hero__video {
        grid-area: 2 / 1;
        align-self: start;
        margin-top: 2rem;
    }

    .cards-hero__lineup {
        grid-area: 2 / 2;
        margin-top: calc(var(--fs-lead) * -1.65);
    }

    .cards-hero__lineup,
    .lineup-track {
        margin-right: calc(-1 * min(3.9375rem, var(--gutter)));
    }

    .lineup-track {
        margin-left: 29.52%;
    }
}

.cards-range {
    padding-top: 1rem;
    background: var(--c-surface-grey);
}

.card-range {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 9.5rem), 1fr));
    gap: 2.5rem 0.75rem;
    text-align: center;
}

.card-range__item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.card-range__name {
    color: var(--c-ink);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.15;
}

.card-range__tagline {
    max-width: 8.5rem;
    min-height: 2.9em;
    margin-top: 0.5rem;
    color: var(--c-brand-deep);
    font-size: 0.75rem;
    font-weight: 500;
    line-height: 1.45;
}

.card-range__item .btn {
    margin-top: 0.75rem;
    padding-inline: clamp(1rem, 0.2rem + 1.5vw, 1.9rem);
}

@media (min-width: 40em) {
    .card-range {
        grid-template-columns: repeat(5, minmax(0, 1fr));
    }
}

.cards-range__features {
    margin-top: clamp(3rem, 1.5rem + 4.5vw, 7rem);
}

.closing-line {
    margin-top: clamp(2.5rem, 1.5rem + 3vw, 5rem);
    font-size: var(--fs-body);
    line-height: 1.85;
    text-align: center;
}

.closing-line em {
    color: var(--c-brand-deep);
    font-style: normal;
}

/* --- App ----------------------------------------------------------------- */

.hero--app {
    padding-top: clamp(2rem, 1rem + 4vw, 5.125rem);
}

.hero--app .lead {
    margin-top: clamp(0.75rem, 0.6rem + 0.5vw, 1.3rem);
}

.app-showcase {
    padding-block: clamp(2.5rem, 1rem + 4.5vw, 5rem) clamp(3rem, 1.5rem + 5vw, 7.5rem);
}

/* Three phones, the middle one in front. Offsets are the design's, as a
   share of the 960px group so they hold at every width. */
.phones {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    max-width: 60rem;
    margin-inline: auto;
}

.phones__item {
    position: relative;
    filter: drop-shadow(0 28px 36px rgb(8 9 47 / 0.16));
    transition: translate 0.7s var(--ease-out), rotate 0.7s var(--ease-out);
}

.phones__item--left {
    z-index: 1;
    width: 41.9%;
    margin-top: 3.1%;
    margin-right: -11.8%;
}

.phones__item--center {
    z-index: 2;
    width: 40.4%;
}

.phones__item--right {
    z-index: 1;
    width: 43.4%;
    margin-top: 2.7%;
    margin-left: -14%;
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
    .phones:hover .phones__item--left {
        translate: -4% 2%;
        rotate: -1.5deg;
    }

    .phones:hover .phones__item--right {
        translate: 4% 2%;
        rotate: 1.5deg;
    }

    .phones:hover .phones__item--center {
        translate: 0 -2%;
    }
}

.pillars-section--three {
    padding-bottom: clamp(3rem, 2rem + 3vw, 6rem);
}

/* --- About --------------------------------------------------------------- */

.hero--about {
    padding-block: clamp(2rem, 1rem + 4vw, 6.875rem) 0;
}

.hero--about .display {
    margin-top: clamp(0.75rem, 0.5rem + 0.6vw, 1.5rem);
}

.hero--about .lead {
    max-width: 34.5rem;
    margin-top: 1.5rem;
}

/* Tile inside two hairline rings, drifting gently. */
.about-emblem {
    position: relative;
    display: grid;
    place-items: center;
    width: min(100%, 31.25rem);
    aspect-ratio: 1;
    margin-inline: auto;
}

.about-emblem::before,
.about-emblem::after {
    content: "";
    position: absolute;
    border: 1px solid #EAEAEA;
    border-radius: 50%;
}

.about-emblem::before {
    inset: 0;
}

.about-emblem::after {
    inset: 13.4%;
}

.about-emblem img {
    position: relative;
    z-index: 1;
    width: 80.6%;
    filter: drop-shadow(0 4px 21px rgb(10 6 155 / 0.3));
}

@media (prefers-reduced-motion: no-preference) {
    .about-emblem img {
        animation: emblem-float 7s ease-in-out infinite;
    }
}

@keyframes emblem-float {
    50% {
        translate: 0 -12px;
        rotate: -1.5deg;
    }
}

.values {
    padding-top: clamp(4rem, 2rem + 8vw, 12.5rem);
}

.values__list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
    gap: 2.5rem 0;
    margin-top: clamp(2.5rem, 2rem + 2vw, 4.5rem);
}

.value {
    padding-inline: clamp(1rem, 0.5rem + 1.5vw, 2.125rem);
}

.value__icon {
    width: 2.75rem;
    height: 2.75rem;
    color: var(--c-brand);
    transition: translate 0.35s var(--ease-out);
}

.value:hover .value__icon {
    translate: 0 -4px;
}

.value__title {
    margin-top: 0.4rem;
    color: var(--c-body);
    font-size: var(--fs-title);
    font-weight: 700;
    line-height: 1.65;
}

.value__text {
    max-width: 11.5rem;
    margin-top: 0.6rem;
    font-weight: 400;
    line-height: 1.67;
}

@media (min-width: 36em) {
    .values__list {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 63.99em) {
    .about-emblem {
        width: min(100%, 22rem);
    }
}

@media (min-width: 64em) {
    .values__list {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }

    .value + .value {
        border-left: 1px solid var(--c-line-soft);
    }
}

.philosophy {
    padding-top: clamp(2rem, 1rem + 4vw, 7.4rem);
}

@media (min-width: 64em) {
    .split--media {
        grid-template-columns: minmax(0, 599fr) minmax(0, 564fr);
        gap: 4.8rem;
    }
}

.philosophy__media {
    overflow: hidden;
    border-radius: var(--r-img);
}

.philosophy__media img {
    width: 100%;
    aspect-ratio: 599 / 499;
    object-fit: cover;
    transition: scale 1.2s var(--ease-out);
}

.philosophy__media:hover img {
    scale: 1.04;
}

.philosophy__copy .heading {
    margin-top: 0.95rem;
}

.philosophy__copy .body-text {
    text-wrap: wrap;
    margin-top: 1.3rem;
}

.checklist {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 2.2rem;
    margin-top: 1.8rem;
}

.checklist li {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-weight: 400;
}

.checklist .icon {
    width: 1.25rem;
    height: 1.25rem;
    color: var(--c-brand);
}

.vision {
    padding-top: clamp(3rem, 1.5rem + 5vw, 8rem);
}

.vision .heading {
    margin-top: 0.15rem;
}

.vision .body-text {
    max-width: 33rem;
    margin-top: 1.05rem;
}

/* --- Security ------------------------------------------------------------ */

.security {
    padding-top: 0;
}

.security .heading {
    margin-top: 0.15rem;
}

.security__features {
    margin-top: clamp(2rem, 1.5rem + 2vw, 3.5rem);
}

/* --- Beta form ----------------------------------------------------------- */

.hero--beta {
    --glow-top: 70%;
    padding-block: clamp(2rem, 1rem + 3vw, 4.625rem) clamp(4rem, 2rem + 8vw, 12rem);
}

.beta {
    display: grid;
    gap: clamp(2.5rem, 1.5rem + 3vw, 4rem);
    align-items: center;
}

@media (min-width: 64em) {
    .beta {
        grid-template-columns: minmax(0, 1fr) minmax(0, 38.2rem);
    }
}

.beta__copy .display {
    margin-top: 0.9rem;
}

.beta__copy .lead {
    max-width: 30.5rem;
    margin-top: 1rem;
}

.beta__card {
    padding: clamp(1.5rem, 1rem + 2.5vw, 3.125rem) clamp(1.25rem, -0.5rem + 5vw, 5rem);
    border-radius: var(--r-lg);
    background: var(--c-white);
    box-shadow: var(--sh-card);
}

.form {
    display: grid;
    gap: 1.125rem;
}

.form .check {
    margin-top: 0.9rem;
}

.form__submit {
    width: 100%;
    margin-top: 1.35rem;
}

.form__note {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.9rem;
    color: var(--c-muted);
    font-size: 1rem;
    text-align: center;
}

.form__note .icon {
    color: var(--c-muted);
}

.form__alert {
    padding: 0.8rem 1rem;
    border-radius: var(--r-field);
    background: #FDECEC;
    color: var(--c-error);
    font-size: 0.9375rem;
}

/* --- Legal texts: the rest of what the admin's editor can produce -------- */

.prose h1 {
    margin-top: 2.2em;
    color: var(--c-ink);
    font-size: clamp(1.5rem, 1.3rem + 0.8vw, 2rem);
    font-weight: 700;
    line-height: 1.25;
}

.prose h5,
.prose h6 {
    margin-top: 1.6em;
    color: var(--c-ink);
    font-size: 1rem;
    font-weight: 700;
}

.prose :where(em, i) {
    font-style: italic;
}

.prose u {
    text-decoration: underline;
}

.prose img {
    display: inline-block;
}

.prose hr {
    border: 0;
    border-top: 1px solid var(--c-line-cool);
}

.prose pre {
    overflow-x: auto;
    white-space: pre-wrap;
}

.prose table {
    display: block;
    width: 100%;
    overflow-x: auto;
    border-collapse: collapse;
}

.prose :where(th, td) {
    padding: 0.6rem 0.8rem;
    border: 1px solid var(--c-line-cool);
    text-align: left;
    vertical-align: top;
}

/* --- Contact Us ---------------------------------------------------------- */

.contact-channels {
    margin-top: clamp(1.75rem, 1.25rem + 1.5vw, 2.5rem);
}

.contact-card__hint {
    color: var(--c-muted);
    font-size: 0.875rem;
    line-height: 1.5;
}

.field__control--textarea {
    align-items: stretch;
}

textarea.field__input {
    height: auto;
    min-height: 8.5rem;
    padding: 0.85rem 1.5rem;
    line-height: 1.6;
    resize: vertical;
}

.form__note a {
    color: var(--c-brand);
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.field__required {
    color: var(--c-error);
}

.field__count {
    color: var(--c-muted);
    font-size: var(--fs-xs);
    text-align: right;
}

.form__success {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.8rem 1rem;
    border-radius: var(--r-field);
    background: #E8F6EE;
    color: #1B6B3A;
    font-size: 0.9375rem;
}

.form__success .icon {
    flex: none;
    margin-top: 0.15rem;
}

/* --- You're on the list -------------------------------------------------- */

.hero--thanks {
    --glow-top: 66%;
}

.success-mark {
    width: min(100%, 45rem);
    margin: 0 auto clamp(1.5rem, 1rem + 1.5vw, 2.3rem);
    overflow: visible;
}

.success-mark__halo {
    fill: var(--c-surface-halo);
}

.success-mark__ring {
    fill: none;
    stroke: #0A0694;
    stroke-width: 2.67;
}

.success-mark__check {
    fill: none;
    stroke: #080577;
    stroke-width: 12;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.success-mark__dot {
    fill: #080578;
    transform-box: fill-box;
    transform-origin: center;
}

@media (prefers-reduced-motion: no-preference) {
    .success-mark__ring,
    .success-mark__check {
        stroke-dasharray: 1;
        stroke-dashoffset: 1;
        animation: draw 0.8s var(--ease-out) forwards;
    }

    .success-mark__ring {
        rotate: -90deg;
        transform-box: fill-box;
        transform-origin: center;
    }

    .success-mark__check {
        animation-duration: 0.5s;
        animation-delay: 0.55s;
    }

    .success-mark__dot {
        scale: 0;
        animation:
            pop 0.45s var(--ease-out) calc(0.5s + var(--i) * 60ms) forwards,
            drift 5s ease-in-out calc(1s + var(--i) * 250ms) infinite;
    }
}

@keyframes draw {
    to {
        stroke-dashoffset: 0;
    }
}

@keyframes pop {
    to {
        scale: 1;
    }
}

@keyframes drift {
    50% {
        translate: 0 -6px;
    }
}

/* --- Text pages ---------------------------------------------------------- */

.hero--document {
    padding-block: clamp(2.5rem, 1.5rem + 4vw, 6rem) 0;
}

.hero--document .display {
    margin-top: 0.5rem;
}

.hero--document .lead {
    margin-top: 1rem;
}

.document {
    padding-top: clamp(2rem, 1rem + 3vw, 3.5rem);
}
