/*
 * Homepage presentation.
 *
 * A chart-like navy cut keeps the stable introduction readable while the
 * existing slideshow supplies movement and atmosphere behind it.
 */

.home-hero,
.home-main {
    --home-navy: #09283c;
    --home-navy-deep: #071e2f;
    --home-ink: #172536;
    --home-muted: #5d6876;
    --home-paper: #ffffff;
    --home-mist: #f8fafc;
    --home-line: #d7e0e6;
    --home-signal: #bd4b1d;
    --home-signal-bright: #ef7b45;
}

.home-shell {
    width: min(100% - 40px, 1200px);
    margin-inline: auto;
}

.home-eyebrow {
    margin: 0 0 12px;
    color: #ffc3a4;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    line-height: 1.4;
    text-transform: uppercase;
}

.home-eyebrow--dark {
    color: var(--home-signal);
}

/* Hero */
.home-hero {
    --home-hero-height: clamp(580px, 68dvh, 720px);
    position: relative;
    height: var(--home-hero-height);
    margin-top: calc(-1 * var(--nav-height));
    overflow: hidden;
    background: var(--home-navy-deep);
    color: #fff;
}

.home-hero > .seafarers-hero {
    height: var(--home-hero-height);
    min-height: var(--home-hero-height);
    margin-top: 0;
    z-index: auto !important;
}

.home-hero > .seafarers-hero--compact {
    padding-top: 0;
}

.home-hero .hero-slide__video,
.home-hero .seafarers-hero img:not(.slideshow-logo) {
    object-position: var(--sfr-video-focal-position, 68% center) !important;
}

.home-hero__shade {
    position: absolute;
    inset: 0 auto 0 0;
    z-index: 2;
    width: 100%;
    background: linear-gradient(110deg, rgba(7, 30, 47, 0.88) 0%, rgba(9, 40, 60, 0.68) 72%, rgba(9, 40, 60, 0.52) 100%);
    -webkit-mask-image: linear-gradient(70deg, #000 0%, #000 43%, transparent 64%);
    mask-image: linear-gradient(70deg, #000 0%, #000 43%, transparent 64%);
    pointer-events: none;
}

.home-hero .hero-scroll-cue {
    bottom: 26px;
}

.home-hero .hero-scroll-cue[hidden] {
    display: none;
}

.home-hero__content {
    position: absolute;
    inset: 0;
    z-index: 3;
    pointer-events: none;
}

.home-hero__content-inner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    height: 100%;
    padding-top: var(--nav-height);
    padding-bottom: 34px;
}

.home-hero__content h1 {
    max-width: 10ch;
    margin: 0;
    color: #fff;
    font-size: clamp(3.25rem, 4.6vw, 4.8rem);
    font-weight: 700;
    letter-spacing: -0.055em;
    line-height: 0.96;
    text-wrap: balance;
}

.home-hero__lede {
    max-width: 39rem;
    margin: 30px 0 0;
    color: #e6eef2;
    font-size: clamp(1.02rem, 1.45vw, 1.3rem);
    line-height: 1.55;
}

.home-hero__join {
    display: grid;
    grid-template-columns: auto auto 1fr;
    gap: 0 0.38rem;
    align-items: baseline;
    width: fit-content;
    max-width: 100%;
    margin-top: 27px;
    padding: 0 0 7px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.64);
    color: #fff;
    font-size: 0.98rem;
    line-height: 1.45;
    text-decoration: none;
    pointer-events: auto;
}

.home-hero__join strong {
    font-weight: 700;
}

.home-arrow {
    margin-left: 0.55rem;
    color: #ffc3a4;
    transition: transform 180ms ease;
}

.home-hero__join:hover,
.home-hero__join:focus-visible {
    border-color: #fff;
    color: #fff;
}

.home-hero__join:hover .home-arrow,
.home-hero__join:focus-visible .home-arrow {
    transform: translateX(4px);
}


/* Shared headings */
.home-main {
    background: var(--home-paper);
    color: var(--home-ink);
}

.home-main h2,
.home-main h3,
.home-main p {
    text-wrap: pretty;
}

.home-section-heading {
    display: flex;
    gap: 32px;
    align-items: end;
    justify-content: space-between;
    margin-bottom: 26px;
}

.home-section-heading h2 {
    margin: 0;
    color: var(--home-ink);
    font-size: clamp(1.7rem, 2.8vw, 2.35rem);
    letter-spacing: -0.035em;
    line-height: 1.08;
}

.home-section-heading > p {
    margin: 0 0 3px;
    color: var(--home-muted);
    font-size: 0.9rem;
}

/* Four primary routes */
.home-routes {
    padding: 54px 0 60px;
    background: var(--home-mist);
    border-bottom: 1px solid var(--home-line);
}

.home-route-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.home-route-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-height: 210px;
    padding: 24px 25px 22px;
    overflow: hidden;
    border: 1px solid var(--home-line);
    border-radius: 5px;
    background: #fff;
    box-shadow: 0 8px 24px rgba(16, 38, 55, 0.045);
    color: var(--home-ink);
    text-decoration: none;
    transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.home-route-card::before {
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 3px;
    background: var(--home-signal-bright);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 180ms ease;
}

.home-route-card:hover,
.home-route-card:focus-visible {
    border-color: #b7c6cf;
    box-shadow: 0 13px 30px rgba(16, 38, 55, 0.1);
    color: var(--home-ink);
    transform: translateY(-3px);
}

.home-route-card:hover::before,
.home-route-card:focus-visible::before {
    transform: scaleX(1);
}

.home-route-card__label {
    margin-bottom: 18px;
    color: var(--home-signal);
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.13em;
    line-height: 1.2;
    text-transform: uppercase;
}

.home-route-card h3 {
    margin: 0 0 10px;
    color: var(--home-ink);
    font-size: 1.35rem;
    letter-spacing: -0.025em;
    line-height: 1.15;
}

.home-route-card p {
    margin: 0;
    color: var(--home-muted);
    font-size: 0.92rem;
    line-height: 1.52;
}

.home-route-card .home-route-card__meta {
    margin: -2px 0 7px;
    color: var(--home-signal);
    font-size: 0.7rem;
    font-weight: 750;
    letter-spacing: 0.08em;
    line-height: 1.35;
    text-transform: uppercase;
}

.home-route-card__arrow {
    align-self: flex-end;
    margin-top: auto;
    padding-top: 16px;
    color: var(--home-signal);
    font-size: 1.1rem;
    transition: transform 180ms ease;
}

.home-route-card:hover .home-route-card__arrow,
.home-route-card:focus-visible .home-route-card__arrow {
    transform: translateX(4px);
}

/* Club credentials, kept in the same quiet rhythm as the live-conditions strip. */
.home-recognition {
    padding: 36px 0;
    border-bottom: 1px solid var(--home-line);
    background: var(--home-paper);
}

.home-recognition__inner {
    text-align: center;
}

.home-recognition h2 {
    margin: 0;
}

.home-recognition__logos {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(48px, 5vw, 64px);
    margin: 12px 0 10px;
}

.home-recognition__logos img {
    display: block;
    width: auto;
    max-width: 100%;
    height: 58px;
    object-fit: contain;
}

.home-recognition__inner > p {
    margin: 0;
    color: var(--home-muted);
    font-size: 0.9rem;
    line-height: 1.4;
}

/* Compact live conditions */
.home-weather {
    border-bottom: 1px solid var(--home-line);
    background: #fff;
}

.home-weather__inner {
    display: grid;
    grid-template-columns: minmax(270px, 1fr) auto auto;
    gap: 48px;
    align-items: center;
    min-height: 138px;
    padding-block: 25px;
}

.home-weather__intro .home-eyebrow {
    margin-bottom: 4px;
}

.home-weather h2 {
    margin: 0;
    color: var(--home-ink);
    font-size: 1.08rem;
    letter-spacing: -0.015em;
    line-height: 1.3;
}

.home-weather__intro > p:last-child {
    margin: 4px 0 0;
    color: var(--home-muted);
    font-size: 0.82rem;
    line-height: 1.4;
}

.home-weather__readings {
    display: grid;
    grid-template-columns: repeat(3, auto);
    gap: 34px;
    margin: 0;
}

.home-weather__readings[hidden] {
    display: none;
}

.home-weather__readings div {
    min-width: 70px;
}

.home-weather__readings dt {
    margin: 0 0 2px;
    color: var(--home-muted);
    font-size: 0.66rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    line-height: 1.25;
    text-transform: uppercase;
}

.home-weather__readings dd {
    margin: 0;
    color: var(--home-ink);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.3;
}

.home-weather__readings small {
    font-size: 0.74rem;
    font-weight: 600;
}

.home-text-link {
    display: inline-flex;
    gap: 10px;
    align-items: center;
    color: var(--home-signal);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.home-text-link span {
    transition: transform 180ms ease;
}

.home-text-link:hover,
.home-text-link:focus-visible {
    color: #8f3513;
}

.home-text-link:hover span,
.home-text-link:focus-visible span {
    transform: translateX(4px);
}

/* Membership invitation */
.home-membership {
    position: relative;
    overflow: hidden;
    padding: 58px 0;
    background: var(--home-navy);
    color: #fff;
}

.home-membership::after {
    content: "";
    position: absolute;
    right: -80px;
    bottom: -125px;
    width: 420px;
    height: 220px;
    border: 1px solid rgba(255, 255, 255, 0.11);
    border-radius: 50%;
    box-shadow: 0 0 0 35px rgba(255, 255, 255, 0.035), 0 0 0 70px rgba(255, 255, 255, 0.025);
    pointer-events: none;
}

.home-membership__inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 50px;
    align-items: center;
}

.home-membership h2 {
    max-width: 18ch;
    margin: 0;
    color: #fff;
    font-size: clamp(2rem, 3.2vw, 3rem);
    letter-spacing: -0.045em;
    line-height: 1.02;
}

.home-membership p:not(.home-eyebrow) {
    max-width: 47rem;
    margin: 17px 0 0;
    color: #d9e5eb;
    font-size: 1rem;
    line-height: 1.6;
}

.home-button {
    display: inline-flex;
    gap: 15px;
    align-items: center;
    justify-content: center;
    min-height: 50px;
    padding: 12px 20px;
    border-radius: 3px;
    background: var(--home-signal-bright);
    color: #10202c;
    font-weight: 750;
    line-height: 1.2;
    text-decoration: none;
    white-space: nowrap;
    transition: background 180ms ease, transform 180ms ease;
}

.home-button:hover,
.home-button:focus-visible {
    background: #ff9a68;
    color: #10202c;
    transform: translateY(-2px);
}

/* One-club identity */
.home-identity {
    padding: 58px 0 64px;
    background: var(--home-mist);
}

.home-identity__inner {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: clamp(45px, 8vw, 110px);
    align-items: start;
}

.home-identity h2 {
    max-width: 16ch;
    margin: 0;
    color: var(--home-ink);
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    letter-spacing: -0.04em;
    line-height: 1.06;
}
.home-identity__purpose {
    max-width: 42rem;
    margin: 0 0 22px;
    padding: 18px 20px;
    background: rgba(255, 255, 255, 0.72);
    border-left: 3px solid var(--home-signal);
}

.home-identity__purpose h3 {
    margin: 0 0 7px;
    color: var(--home-ink);
    font-size: 0.92rem;
    font-weight: 750;
    letter-spacing: -0.01em;
}

.home-identity__purpose p {
    margin: 0;
    color: var(--home-muted);
    font-size: 0.98rem;
    line-height: 1.55;
}


.home-identity__copy > p {
    max-width: 42rem;
    margin: 0;
    color: var(--home-muted);
    font-size: 1rem;
    line-height: 1.65;
}

.home-identity ul {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}

.home-identity li {
    padding: 6px 10px;
    border: 1px solid #c7d3da;
    border-radius: 999px;
    color: #334756;
    font-size: 0.78rem;
    font-weight: 650;
    line-height: 1.2;
}

.home-main a:focus-visible,
.home-hero a:focus-visible,
.home-hero button:focus-visible {
    outline: 3px solid #ffb58e;
    outline-offset: 4px;
}

@media (max-width: 1040px) {
    .home-route-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .home-route-card {
        min-height: 190px;
    }

    .home-weather__inner {
        grid-template-columns: minmax(250px, 1fr) auto;
        gap: 20px 42px;
    }

    .home-weather__readings {
        grid-column: 1;
        grid-row: 2;
    }

    .home-weather .home-text-link {
        grid-column: 2;
        grid-row: 1 / span 2;
    }
}

@media (max-width: 899px) {
    .home-hero {
        --home-hero-height: clamp(610px, 72dvh, 720px);
    }


    .home-hero__content h1 {
        font-size: clamp(3rem, 8.2vw, 4.65rem);
    }

    .home-hero__lede {
        max-width: 33rem;
    }
}

@media (max-width: 680px) {
    .home-shell {
        width: min(100% - 32px, 1160px);
    }

    .home-hero {
        --home-hero-height: clamp(590px, 74dvh, 690px);
    }

    .home-hero .hero-scroll-cue {
        display: none;
    }

    .home-hero__shade {
        width: 100%;
        background: linear-gradient(180deg, rgba(7, 30, 47, 0.42) 0%, rgba(7, 30, 47, 0.54) 48%, rgba(7, 30, 47, 0.62) 100%);
        -webkit-mask-image: none;
        mask-image: none;
    }

    .home-hero .hero-slide__video,
    .home-hero .seafarers-hero img:not(.slideshow-logo) {
        object-position: var(--sfr-video-focal-position, center) !important;
    }

    .home-hero__content-inner {
        justify-content: flex-end;
        padding-top: calc(var(--nav-height) + 50px);
        padding-bottom: 82px;
    }

    .home-hero__content h1 {
        max-width: 9ch;
        font-size: clamp(2.85rem, 13.6vw, 4rem);
        line-height: 0.98;
    }

    .home-hero__lede {
        margin-top: 23px;
        font-size: 1rem;
        line-height: 1.52;
    }

    .home-hero__lede br {
        display: none;
    }

    .home-hero__join {
        grid-template-columns: 1fr auto;
        margin-top: 22px;
        font-size: 0.9rem;
    }

    .home-hero__join > span:first-child {
        grid-column: 1;
    }

    .home-hero__join strong {
        grid-column: 1;
    }

    .home-hero__join .home-arrow {
        grid-column: 2;
        grid-row: 1 / span 2;
    }


    .home-section-heading {
        display: block;
        margin-bottom: 22px;
    }

    .home-section-heading > p {
        margin-top: 7px;
    }

    .home-routes {
        padding: 42px 0 48px;
    }

    .home-route-grid {
        gap: 12px;
    }

    .home-route-card {
        min-height: 204px;
        padding: 20px 18px 17px;
    }

    .home-route-card__label {
        margin-bottom: 14px;
        font-size: 0.63rem;
    }

    .home-route-card h3 {
        font-size: 1.18rem;
    }

    .home-route-card p {
        font-size: 0.84rem;
        line-height: 1.48;
    }

    .home-route-card .home-route-card__meta {
        font-size: 0.61rem;
    }

    .home-recognition {
        padding-block: 30px;
    }

    .home-recognition__logos {
        flex-direction: column;
        gap: 22px;
        margin-block: 18px 16px;
    }

    .home-recognition__logos img {
        height: 52px;
    }

    .home-weather__inner {
        grid-template-columns: 1fr;
        gap: 20px;
        padding-block: 30px;
    }

    .home-weather__readings,
    .home-weather .home-text-link {
        grid-column: 1;
        grid-row: auto;
    }

    .home-weather__readings {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 12px;
    }

    .home-weather .home-text-link {
        justify-self: start;
    }

    .home-membership {
        padding: 48px 0;
    }

    .home-membership__inner,
    .home-identity__inner {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .home-button {
        justify-self: start;
    }

    .home-identity {
        padding: 48px 0 54px;
    }
}

@media (max-width: 359px) {
    .home-route-grid {
        grid-template-columns: 1fr;
    }

    .home-route-card {
        min-height: 170px;
    }
}

@media (orientation: landscape) and (max-height: 650px) {
    .home-hero {
        --home-hero-height: max(500px, 100dvh);
    }

    .home-hero__content h1 {
        font-size: clamp(2.6rem, 7vh, 3.5rem);
    }

    .home-hero__lede {
        margin-top: 18px;
    }

    .home-hero__join {
        margin-top: 18px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-hero [id^="slide"],
    .home-arrow,
    .home-route-card,
    .home-route-card::before,
    .home-route-card__arrow,
    .home-text-link span,
    .home-button {
        transition: none !important;
    }

    .home-route-card:hover,
    .home-route-card:focus-visible,
    .home-button:hover,
    .home-button:focus-visible {
        transform: none;
    }
}
