/* ===========================================================================
   RKFocus — landing page. Loads after css/base.css.
   ======================================================================== */

:root {
    /* The seam is in vw, not %, so the glass edge, the logotype and the mask
       that cuts the logotype out of the glass all resolve against one basis. */
    --seam: 46vw;

    /* Logotype geometry — generated with the artwork in wordmark.php. */
    --word-em-w: 3.3708;
    --word-aspect: 4.3609;
    --word-split: 0.265;
    --word-fs: clamp(66px, 15.5vw, 250px);
    --word-w: calc(var(--word-fs) * var(--word-em-w));
    --word-h: calc(var(--word-w) / var(--word-aspect));
    --word-x: calc(var(--seam) - var(--word-w) * var(--word-split));
}

/* --- page-specific micro type ------------------------------------------- */

.hero__eyebrow,
.hero__index,
.card__meta,
.card__n,
.card__go,
.hero__credit,
.hero__cue {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.18em;
    text-transform: uppercase;
}

/* ===========================================================================
   Navbar — landing page only: floats over the hero instead of boxing it in.
   ======================================================================== */

body.home-page .rkf-navbar {
    position: fixed;
    top: 0;
    left: 0;
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border-bottom-color: transparent;
}

/* A soft gradient instead of a bar, so the hero reads edge to edge. */
body.home-page .rkf-navbar::before {
    content: '';
    position: absolute;
    inset: -1px 0 auto 0;
    height: 180px;
    background: linear-gradient(180deg, rgba(8, 9, 11, 0.66), rgba(8, 9, 11, 0));
    pointer-events: none;
    z-index: -1;
    transition: opacity 0.4s ease;
}

/* Past the hero it settles into a solid bar. */
body.home-page .rkf-navbar.is-scrolled {
    background: rgba(8, 9, 11, 0.86);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom-color: var(--line);
}

body.home-page .rkf-navbar.is-scrolled::before {
    opacity: 0;
}

/* The hero already says the name at 250px. The mark alone is enough up there. */
body.home-page .rkf-navbar:not(.is-scrolled) .rkf-wordmark {
    opacity: 0;
}

/* ===========================================================================
   Hero
   ======================================================================== */

.hero {
    position: relative;
    height: 100svh;
    min-height: 620px;
    overflow: hidden;
    background: var(--ink-2);
    isolation: isolate;
}

.hero__stage,
.hero__slide,
.hero__slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.hero__slide {
    opacity: 0;
    transition: opacity 1.4s ease;
}

.hero__slide.is-active {
    opacity: 1;
}

.hero__slide img {
    object-fit: cover;
    object-position: center;
    filter: saturate(0.94) contrast(1.03);
    transform: scale(1.085);
}

/* The panel has a genuine hole in it, so the drift is simply seen through the
   opening — nothing needs to be kept in register. */
.hero__slide.is-active img {
    animation: hero-drift 26s var(--ease) forwards;
}

@keyframes hero-drift {
    from {
        transform: scale(1.085);
    }

    to {
        transform: scale(1);
    }
}

.hero__scrim {
    position: absolute;
    inset: 0;
    z-index: 1;
    background:
        linear-gradient(180deg, rgba(8, 9, 11, 0.34) 0%, rgba(8, 9, 11, 0) 38%),
        linear-gradient(0deg, rgba(8, 9, 11, 0.72) 0%, rgba(8, 9, 11, 0) 52%);
}

/* The frosted half, with the "rk" of the logotype cut out of it. The mask is
   two layers — the panel, minus the letterforms — composited with `exclude`,
   so the opening is a genuine hole: whatever moves behind the hero is simply
   seen through it, unblurred, with nothing to keep in register. */
.hero__glass {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: var(--seam);
    z-index: 3;
    backdrop-filter: blur(15px) saturate(1.5) brightness(1.2);
    -webkit-backdrop-filter: blur(15px) saturate(1.5) brightness(1.2);
    /* The ivory veil is a luminance floor. Real frosted glass scatters ambient
       light and never reads as pure black, and without it a hero frame that is
       near-black behind the panel leaves nothing for the opening to read
       against — which now matters, because the frame changes every visit. */
    background:
        linear-gradient(90deg, rgba(242, 239, 232, 0.06), rgba(242, 239, 232, 0.022)),
        linear-gradient(90deg, rgba(8, 9, 11, 0.58), rgba(8, 9, 11, 0.26));

    /* Generated alongside the artwork in wordmark.php — same outlines, same viewBox. */
    --rk-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 6903.38 1583'%3E%3Cg transform='translate(-148 1560)'%3E%3Cpath fill='%23fff' d='M368 0L148 0L148-1118L361-1118L361-938L373-938Q404-1030 481-1082Q558-1134 656-1134Q677-1134 704-1132.50Q731-1131 749-1128L749-918Q737-922 703-926Q669-930 634-930Q558-930 497-898Q436-866 402-809.50Q368-753 368-679 M1250.84-577L1050.84-377L1050.84-646L1087.84-646L1528.84-1118L1792.84-1118L1287.84-577L1250.84-577M1067.84 0L847.84 0L847.84-1490L1067.84-1490L1067.84 0M1823.84 0L1551.84 0L1154.84-528L1306.84-684'/%3E%3C/g%3E%3C/svg%3E");
}

@supports (mask-composite: exclude) or (-webkit-mask-composite: xor) {
    .hero__glass {
        -webkit-mask-image: linear-gradient(#000, #000), var(--rk-mask);
        mask-image: linear-gradient(#000, #000), var(--rk-mask);
        -webkit-mask-size: 100% 100%, var(--word-w) var(--word-h);
        mask-size: 100% 100%, var(--word-w) var(--word-h);
        -webkit-mask-position: 0 0, var(--word-x) center;
        mask-position: 0 0, var(--word-x) center;
        -webkit-mask-repeat: no-repeat, no-repeat;
        mask-repeat: no-repeat, no-repeat;
        -webkit-mask-composite: xor;
        mask-composite: exclude;
    }
}

@supports not ((backdrop-filter: blur(2px)) or (-webkit-backdrop-filter: blur(2px))) {
    .hero__glass {
        background: linear-gradient(90deg, rgba(8, 9, 11, 0.86), rgba(8, 9, 11, 0.62));
    }
}

/* The logotype box. `left`/`top` here and the mask's position/size above are
   the same expressions against the same origin, so the hole and the artwork
   cannot drift apart at any viewport width. */
.hero__word {
    position: absolute;
    z-index: 4;
    left: var(--word-x);
    top: calc(50% - var(--word-h) / 2);
    width: var(--word-w);
    height: var(--word-h);
    margin: 0;
    pointer-events: none;
}

.hero__wordmark {
    display: block;
    width: 100%;
    height: 100%;
}

/* Explicitly opt out of the icon defaults on `svg` above: a stroke here is
   measured in viewBox units, so it lands as a sub-pixel hairline tracing the
   opening. */
.hero__wordmark-rk,
.hero__wordmark-focus {
    fill: var(--ivory);
    stroke: none;
}

.hero__wordmark-focus {
    filter: drop-shadow(0 2px 40px rgba(8, 9, 11, 0.45));
}

/* Where the panel can be cut, the hole is the letterform — drawing it as ink
   as well would double it up. Must follow the fills above to win on order. */
@supports (mask-composite: exclude) or (-webkit-mask-composite: xor) {
    .hero__wordmark-rk {
        fill: transparent;
    }
}

/* --- left panel --- */

.hero__panel {
    position: absolute;
    z-index: 5;
    left: var(--pad-x);
    bottom: clamp(46px, 8vh, 92px);
    width: min(384px, calc(var(--seam) - var(--pad-x) - 32px));
}

.hero__eyebrow {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--faint);
    margin-bottom: 26px;
}

.hero__eyebrow-rule {
    flex: 1 1 auto;
    height: 1px;
    background: var(--line);
    max-width: 46px;
}

.hero__notes {
    position: relative;
    min-height: 196px;
}

.hero__note {
    transition: opacity 0.7s ease, transform 0.7s var(--ease);
}

.hero__note:not(.is-active) {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: translateY(14px);
    pointer-events: none;
}

.hero__index {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--ivory);
    margin-bottom: 14px;
}

.hero__index span {
    width: 26px;
    height: 1px;
    background: var(--gold);
    opacity: 0.7;
}

.hero__copy {
    font-size: 15px;
    line-height: 1.66;
    color: var(--muted);
    margin-bottom: 26px;
    max-width: 34ch;
}

/* --- controls --- */

.hero__controls {
    position: absolute;
    z-index: 5;
    right: var(--pad-x);
    bottom: clamp(46px, 8vh, 92px);
    display: flex;
    align-items: center;
    gap: 26px;
}

.hero__dots {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero__dot {
    width: 24px;
    height: 12px;
    position: relative;
}

.hero__dot::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 24px;
    height: 1px;
    background: rgba(242, 239, 232, 0.3);
    transition: background 0.5s ease, transform 0.5s var(--ease);
    transform-origin: left center;
}

.hero__dot.is-active::after {
    background: var(--gold);
}

.hero__dot:hover::after {
    background: var(--ivory);
}

.hero__arrows {
    display: flex;
    gap: 6px;
}

.hero__arrow {
    width: 46px;
    height: 46px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    color: var(--muted);
    transition: color 0.4s ease, border-color 0.4s ease, background 0.4s ease;
}

.hero__arrow svg {
    width: 22px;
    height: 12px;
}

.hero__arrow:hover {
    color: var(--ivory);
    border-color: rgba(242, 239, 232, 0.34);
    background: rgba(242, 239, 232, 0.05);
}

.hero__credit {
    position: absolute;
    z-index: 5;
    right: var(--pad-x);
    bottom: calc(clamp(46px, 8vh, 92px) + 66px);
    color: var(--faint);
    text-align: right;
    letter-spacing: 0.14em;
}

.hero__credit-item {
    display: none;
}

.hero__credit-item.is-active {
    display: inline;
}

.hero__cue {
    position: absolute;
    z-index: 5;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    writing-mode: vertical-rl;
    color: var(--muted);
    letter-spacing: 0.22em;
    transition: color 0.4s ease;
}

.hero__cue:hover {
    color: var(--ivory);
}

.hero__cue-line {
    width: 1px;
    height: 74px;
    background: linear-gradient(180deg, var(--line), rgba(242, 239, 232, 0.42));
}

/* ===========================================================================
   Collections
   ======================================================================== */

.collections {
    padding: clamp(84px, 12vh, 150px) var(--pad-x) clamp(40px, 6vw, 80px);
    max-width: 1560px;
    margin: 0 auto;
}

.collections__head {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    align-items: end;
    gap: clamp(24px, 4vw, 72px);
    padding-top: 26px;
    border-top: 1px solid var(--line);
}

.collections__head .section-eyebrow {
    grid-column: 1 / -1;
    margin-bottom: clamp(30px, 4.5vw, 62px);
}

.collections__title {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(36px, 5.4vw, 78px);
    line-height: 1.04;
    letter-spacing: -0.01em;
}

.collections__title em {
    font-style: italic;
    color: var(--gold);
}

.collections__aside p {
    color: var(--muted);
    font-size: 15px;
    line-height: 1.7;
    max-width: 42ch;
    margin-left: auto;
}

.collections__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(28px, 4.5vw, 84px);
    margin-top: clamp(56px, 8vw, 120px);
}

.collections__col {
    display: flex;
    flex-direction: column;
    gap: clamp(48px, 7vw, 130px);
}

/* The offset that keeps the index from reading as a grid of tiles. */
.collections__col:nth-child(2) {
    margin-top: clamp(52px, 9vw, 170px);
}

.collections__empty {
    grid-column: 1 / -1;
    color: var(--muted);
    padding: 80px 0;
}

/* --- card --- */

.card__link {
    display: block;
}

.card__frame {
    position: relative;
    display: block;
    overflow: hidden;
    aspect-ratio: var(--card-ratio, 1.4);
    background: var(--ink-2);
}

.card__frame::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    transition: border-color 0.8s var(--ease);
}

.card__frame::before {
    content: '';
    position: absolute;
    inset: 0 0 auto 0;
    height: 120px;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(8, 9, 11, 0.45), rgba(8, 9, 11, 0));
}

.card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: saturate(0.94) contrast(1.03) brightness(0.94);
    transform: scale(1.001);
    transition: transform 1.4s var(--ease), filter 0.9s ease;
}

.card__link:hover .card__img,
.card__link:focus-visible .card__img {
    transform: scale(1.05);
    filter: saturate(1) contrast(1.03) brightness(1);
}

.card__link:hover .card__frame::after,
.card__link:focus-visible .card__frame::after {
    border-color: rgba(242, 239, 232, 0.22);
}

.card__n {
    position: absolute;
    top: 16px;
    left: 18px;
    z-index: 2;
    color: rgba(242, 239, 232, 0.82);
}

.card__foot {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
    margin-top: 20px;
    padding-top: 18px;
    border-top: 1px solid var(--line);
}

.card__names {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.card__name {
    font-family: var(--serif);
    font-size: clamp(23px, 2.3vw, 36px);
    line-height: 1.05;
    letter-spacing: 0.002em;
    transition: color 0.5s ease;
}

.card__link:hover .card__name,
.card__link:focus-visible .card__name {
    color: var(--gold);
}

.card__meta {
    color: var(--faint);
    letter-spacing: 0.16em;
}

.card__go {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
    color: var(--muted);
    opacity: 0.42;
    transition: opacity 0.6s ease, transform 0.6s var(--ease);
}

.card__go svg {
    width: 22px;
    height: 12px;
}

.card__link:hover .card__go,
.card__link:focus-visible .card__go {
    opacity: 1;
    transform: translateX(4px);
}

/* ===========================================================================
   Closing
   ======================================================================== */

.closing {
    max-width: 1560px;
    margin: 0 auto;
    padding: clamp(90px, 14vw, 190px) var(--pad-x) clamp(80px, 10vw, 140px);
}

.closing .section-eyebrow {
    padding-top: 26px;
    border-top: 1px solid var(--line);
    margin-bottom: clamp(30px, 5vw, 60px);
}

.closing__line {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(28px, 3.9vw, 56px);
    line-height: 1.16;
    letter-spacing: -0.005em;
    max-width: 20ch;
}

.closing__line em {
    font-style: italic;
    color: var(--gold);
}

.closing__links {
    display: flex;
    flex-wrap: wrap;
    gap: clamp(24px, 4vw, 56px);
    margin-top: clamp(38px, 5vw, 66px);
}

    transform: none;
}

/* ===========================================================================
   Responsive
   ======================================================================== */

@media (max-width: 1100px) {
    :root {
        --seam: 52vw;
    }

    .hero__panel {
        width: min(340px, calc(var(--seam) - var(--pad-x) - 24px));
    }
}

@media (max-width: 880px) {
    .hero {
        height: auto;
        min-height: 100svh;
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        padding-bottom: 40px;
    }

    .hero__glass,
    .hero__cue {
        display: none;
    }

    .hero__scrim {
        background:
            linear-gradient(180deg, rgba(8, 9, 11, 0.6) 0%, rgba(8, 9, 11, 0) 30%),
            linear-gradient(0deg, rgba(8, 9, 11, 0.95) 26%, rgba(8, 9, 11, 0.6) 54%, rgba(8, 9, 11, 0) 86%);
    }

    /* No frosted panel on small screens, so there is nothing to punch through:
       the logotype goes solid and rejoins the stacked flow. */
    .hero__word {
        position: relative;
        left: auto;
        top: auto;
        width: min(calc(100vw - var(--pad-x) * 2), 460px);
        height: auto;
        margin: 0 var(--pad-x) 26px;
    }

    .hero__wordmark {
        height: auto;
    }

    .hero__wordmark-rk {
        fill: var(--ivory);
    }

    .hero__panel {
        position: relative;
        left: auto;
        bottom: auto;
        width: auto;
        padding: 0 var(--pad-x);
    }

    .hero__eyebrow {
        margin-bottom: 20px;
    }

    .hero__notes {
        min-height: 178px;
    }

    .hero__copy {
        max-width: none;
    }

    .hero__controls {
        position: relative;
        right: auto;
        bottom: auto;
        margin-top: 34px;
        padding: 0 var(--pad-x);
        justify-content: space-between;
    }

    .hero__credit {
        position: relative;
        right: auto;
        bottom: auto;
        margin-top: 26px;
        padding: 0 var(--pad-x);
        text-align: left;
    }

    .collections__head {
        grid-template-columns: 1fr;
        align-items: start;
    }

    .collections__aside p {
        margin-left: 0;
    }

    .collections__grid {
        grid-template-columns: 1fr;
        gap: clamp(48px, 12vw, 90px);
    }

    .collections__col {
        gap: clamp(48px, 12vw, 90px);
    }

    .collections__col:nth-child(2) {
        margin-top: 0;
    }
}

@media (max-width: 560px) {
    .hero__arrow {
        width: 42px;
        height: 42px;
    }

    .site-foot__inner {
        flex-direction: column;
        gap: 30px;
    }
}

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

    .hero__slide img,
    .hero__slide.is-active img {
        animation: none;
        transform: none;
    }

    .js .reveal,
    .js .reveal.is-in {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .card__img,
    .link-cta svg,
    .card__go {
        transition: none;
    }
}
