/* ═══════════════════════════════════════════════════════════════════════════
   kit-card.css — the result card on the desktop (foundation.md, unit K)

   ONE card, three forms, one DOM. RT.ResultCard.build() (assets/js/v2/
   result-card.js) is NOT forked and takes no desktop option: the markup it
   emits for the phone is re-laid here by the width of the lane it is in,
   through container queries on .lane-body (container name `lane`):

     gallery   lane >= 26.5rem  the mobile poster: photo, pills, the title on
                               the photo, facts and price under it; an
                               auto-fill board, so columns come and go alone
     list      lane <  26.5rem  a row about 104px tall that can be scanned: a
                               square photo, the title on at most two lines,
                               ONE line of facts, the price at the right. Six
                               or seven to a 900px screen, in the photo's colour
     strip     lane <  12rem   a Spine: a column of thumbnails; the current
                               one grows a ring and writes its title up the
                               strip, in full. (Between 12 and 17rem the row
                               sheds its facts and price first.)

   How the row is reached without touching the builder. The photo exists only
   as an inline background-image on .result-img, and the title lives INSIDE
   that element. So in the row forms .result-img stops painting its own
   background (background-size 0) and hands the image to a ::before that
   inherits it; the ::before is the thumbnail, positioned against the card,
   and the title, now in normal flow, sits to its right. Inline styles the
   builder writes (.imgColors-cont's position / width, the <video>'s inset)
   are overridden with a priority flag; those are the only flags here besides
   the ones that answer Bootstrap's own prioritised utilities (.text-muted,
   .mb-4, .px-3, .pb-3, .d-block).

   Why 26.5rem (424px of lane BODY): a List lane is at most 28rem wide and its
   body is narrower by the lane's padding, so it is always under the line; a
   Stage beside a List in a 900px window has a body of about 430px, so it is
   always over it and shows one gallery column.

   Wrap cards in .k-cards. The selected card (the one open in the lane to the
   right) carries .is-selected or aria-current="true".

   Also here: .k-tile, the small poster for shelves and feature panels (Home's
   .hn-tile / .hn-fc-tile), which is our own markup.

   Ported from assets/css/style.css (.tinder--card, .booking-date, .img-fav,
   .imgColors-*) and pages/Home.php (.hn-fc-tile). Not copied from the old
   desktop/assets/css/components.css.
   ═══════════════════════════════════════════════════════════════════════════ */


/* ─── The board ───────────────────────────────────────────────────────────── */

.desktop-surface .k-cards {
    --k-card-min: clamp(15rem, 8rem + 14cqi, 19.5rem);   /* two across from a 34rem Stage; opens up to the phone card's width */
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, var(--k-card-min)), 1fr));
    gap: clamp(1rem, 0.55rem + 1.5cqi, 1.9rem);
    align-items: stretch;
    min-width: 0;
    margin: 0;
    padding: 0;
}

/* The col-12 mb-4 wrapper the builder emits: the grid cell sizes the card */
.desktop-surface .k-cards > .col-12 {
    display: flex;
    width: auto;
    max-width: none;
    min-width: 0;
    flex: none;
    padding: 0;
    margin: 0 !important;
}

.desktop-surface .k-cards > .col-12[hidden] { display: none; }


/* ─── Utilities the markup uses that Bootstrap 4 does not provide ─────────── */
/* Mobile defines them in style.css / v1-app.css. ._600 was a weight there;
   here it is the halbfett family. Sizes rise to the 13px floor. */

.desktop-surface .k-cards .p-relative { position: relative; }
.desktop-surface .k-cards .min-w-0    { min-width: 0; }
.desktop-surface .k-cards ._600       { font-family: var(--font-head); font-weight: normal; }

.desktop-surface .k-cards .text-xs,
.desktop-surface .k-cards .text-sm    { font-size: var(--type-meta); }

/* Bootstrap's .text-muted is a prioritised grey; mobile's is "inherit at 60%",
   which the white-on-photo labels rely on. */
.desktop-surface .k-cards .text-muted {
    color: inherit !important;
    opacity: 0.86;   /* "(0 reviews)" on a photo still has to read */
}

.desktop-surface .k-cards .line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Day chips in the facts (rt_dow_badges, the "headline" colour) */
.desktop-surface .k-cards .badge {
    padding: 0.12em 0.4em;
    border-radius: var(--r-badge);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.2;
}

.desktop-surface .k-cards .badge-avail.headline {
    border: 1px solid #fff;
    background-color: var(--itemColor);
    color: #fff;
}

.desktop-surface .k-cards .badge-inactive.headline {
    border: 1px solid rgba(255, 255, 255, 0.7);
    background-color: transparent;
    color: inherit;
}


/* ─── GALLERY: the mobile poster ──────────────────────────────────────────── */

.desktop-surface .k-cards .searchResult {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    min-width: 0;
    min-height: clamp(21rem, 19rem + 3cqi, 25rem);
    background-color: var(--rt-ink);
    border-radius: var(--r-card);
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
    color: #fff;
    font-family: var(--font-text);
    font-size: var(--type-meta);
    line-height: 1.55;
    overflow: hidden;
    cursor: pointer;
    transition:
        transform var(--dur-base) var(--ease-out),
        box-shadow var(--dur-base) var(--ease-out),
        outline-color var(--dur-fast) var(--ease-out),
        opacity var(--dur-base) var(--ease-out);
}

/* One tap target: children are inert, the heart re-enables itself */
/* The save heart is a div in the shared builder: it must stay clickable (2026-11-11: it was dead on every board). */
.desktop-surface .k-cards .searchResult :is(img, h3, p, div:not(.img-fav), video) { pointer-events: none; }

.desktop-surface .k-cards .searchResult h3 {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1.18;
    letter-spacing: -0.01em;
    margin: 0 0 0.45rem;
}

.desktop-surface .k-cards .searchResult p { margin-top: 0; }

.desktop-surface .k-cards .result-img {
    flex: 1 1 auto;
    width: 100%;
    min-height: 14rem;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

/* Footer: facts and price on the dark gradient */
.desktop-surface .k-cards .result-title2 {
    width: 100%;
    margin-top: auto;
    gap: 0.75rem;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.35) 100%);
    z-index: 0;
}

.desktop-surface .k-cards .result-title2 :is(i, svg) {
    color: color-mix(in srgb, var(--itemColor) 50%, #fff);
}

/* The price (or "Quote"): the card's colour only as a tint over white, with a soft shadow, so it
   reads on a pale palette over the dark gradient too (fixer Z, item 10: "Quote" was beige on brown) */
.desktop-surface .k-cards .result-title2 h3 {
    margin: 0;
    color: color-mix(in srgb, var(--itemColor) 26%, #fff);
    text-shadow: 0 1px 0.6rem rgba(0, 0, 0, 0.45);
    font-family: var(--font-head);
    font-size: clamp(1.5rem, 1.3rem + 0.5cqi, 1.9rem);
    line-height: 1;
    letter-spacing: var(--track-snug);
    white-space: nowrap;
}

.desktop-surface .k-cards .result-title2 h3 > sup {
    top: -0.55em;
    margin-right: 0.08em;
    font-family: var(--font-head);
    font-size: max(0.5em, 0.8125rem);
    letter-spacing: 0;
}

.desktop-surface .k-cards .result-title2 h3 + p { margin: 0.2rem 0 0 !important; line-height: 1.1; }

.desktop-surface .k-cards .highlights-cont > span {
    display: inline-block;
    margin-right: 0.6rem;
}

.desktop-surface .k-cards .highlights-cont > span:last-of-type { margin-right: 0; }

/* The place is said once. When the card has its location pill (it does
   whenever the listing has a place), the first fact is the same string again,
   and for some listings that string is a whole street address with ZIP and
   country: the pill keeps it, clipped; the facts start at the next one. */
.desktop-surface .k-cards .searchResult:has(.booking-date) .highlights-cont > span:first-child { display: none; }

/* Location pill (top-left) with the white circle */
.desktop-surface .k-cards .booking-date {
    position: absolute;
    top: 0.8rem;
    left: 0.8rem;
    max-width: calc(100% - 4.4rem);
    padding: 0.25rem 0.75rem 0.25rem 2.5rem;
    border-radius: 20px;
    background: var(--itemColorBG, var(--rt-blue));
    outline: 2px solid rgba(255, 255, 255, 0.5);
    color: #fff;
    font-size: 1rem;
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desktop-surface .k-cards .booking-date-circle {
    position: absolute;
    top: 0.2rem;
    left: 0.2rem;
    right: calc(100% - 1.8rem);
    bottom: 0.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 100%;
    background-color: #fff;
}

/* Rating pill, tucked under the location pill */
.desktop-surface .k-cards .booking-time {
    position: absolute;
    top: 2.6rem;
    left: 2.55rem;
    max-width: calc(100% - 3.4rem);
    padding: 0.2rem 0.75rem;
    border-radius: 20px;
    background: var(--itemColorBG, var(--rt-blue-dk));
    color: #fff;
    font-size: var(--type-meta);
    line-height: 1.5;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Save heart (top-right). No z-index 9999 here: a lane stacks on its own. */
.desktop-surface .k-cards .img-fav {
    position: absolute;
    z-index: 2;
    top: 0.8rem;
    right: 0.8rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 100%;
    background: #fff;
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm);
    color: var(--rt-ink);
    font-size: 1rem;
    pointer-events: auto;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-spring), background var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-cards .img-fav.isSaved {
    background: var(--tilt-pink);
    outline-color: var(--rt-pink-lt);
    color: #fff;
}

.desktop-surface .k-cards .img-fav:active { transform: scale(0.9); }

/* The colour wash under the title: five blobs from the photo's palette */
.desktop-surface .k-cards .imgColors-cont {
    display: flex;
    overflow: visible;
}

.desktop-surface .k-cards .imgColors-item.cards {
    --base-y: -12%;
    --offset-amount: 2.5%;
    position: absolute;
    width: 130%;
    aspect-ratio: 1;
    border-radius: 100%;
    background: radial-gradient(circle at center, var(--itemColorF) 45%, var(--itemColor0) 70%);
}

.desktop-surface .k-cards .imgColors-item.c1 { left: 0;    transform: translate(-35%, calc(var(--base-y) + 0 * var(--offset-amount))); }
.desktop-surface .k-cards .imgColors-item.c2 { left: 25%;  transform: translate(-35%, calc(var(--base-y) + 1 * var(--offset-amount))); }
.desktop-surface .k-cards .imgColors-item.c3 { left: 50%;  transform: translate(-35%, calc(var(--base-y) + 2 * var(--offset-amount))); }
.desktop-surface .k-cards .imgColors-item.c4 { left: 75%;  transform: translate(-35%, calc(var(--base-y) + 3 * var(--offset-amount))); }
.desktop-surface .k-cards .imgColors-item.c5 { left: 100%; transform: translate(-35%, calc(var(--base-y) + 4 * var(--offset-amount))); }

.desktop-surface .k-cards .imgColors-content.cards {
    position: relative;
    z-index: 2;
    width: 100%;
    padding-block: 0.5rem;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0) 100%);
    line-height: normal;
}

.desktop-surface .k-cards .imgColors-content.cards > p:empty { display: none; }

/* Selected, focused, hovered. The ring is an INSET outline: the card's box,
   and so its place in the row, does not change when it is chosen. */
.desktop-surface .k-cards .searchResult.is-selected,
.desktop-surface .k-cards .searchResult[aria-current="true"] {
    outline: 5px solid var(--rt-pink);
    outline-offset: -5px;
    box-shadow: var(--shadow-cont-sm);
}

/* The same ring drawn ABOVE the card's own layers: in the poster form the photo and its colour band
   (z-index 2) paint over an inset outline, so the chosen card read as unmarked (fixer Z, item 4).
   --k-ring follows the outline width each form sets (5px poster, 4px row, 3px strip). */
.desktop-surface .k-cards .searchResult.is-selected::after,
.desktop-surface .k-cards .searchResult[aria-current="true"]::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 4;
    border-radius: inherit;
    box-shadow: inset 0 0 0 var(--k-ring, 5px) var(--rt-pink);
    pointer-events: none;
}

.desktop-surface .k-cards .searchResult:focus-visible {
    outline: 5px solid var(--rt-blue);
    outline-offset: -5px;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-cards .searchResult:hover {
        transform: translateY(-4px);
        box-shadow: var(--shadow-cont-hover);
    }

    .desktop-surface .k-cards .img-fav:hover { transform: scale(1.1); }
}


/* ─── LIST: a row to scan (lane under 26.5rem) ──────────────────────────────── */

@container lane (width < 26.5rem) {
    .desktop-surface .k-cards {
        grid-template-columns: minmax(0, 1fr);
        gap: 0.5rem;
    }

    .desktop-surface .k-cards .searchResult {
        --_thumb: calc(5.5rem + 4 * var(--up));   /* 88px, a little more on a big screen */
        display: flex;
        flex-direction: column;
        justify-content: center;
        gap: 0.2rem;
        min-height: calc(var(--_thumb) + 1rem);
        padding: 0.5rem 0.75rem 0.5rem calc(var(--_thumb) + 1.25rem);
        border-radius: 0.9rem;
        background: color-mix(in srgb, var(--itemColorBG, var(--rt-blue)) 32%, #121A25);
        box-shadow: 0 0.5rem 1rem -0.5rem rgba(0, 0, 0, 0.35);
        line-height: 1.4;
    }

    /* The photo steps aside: .result-img stops painting it, its ::before
       (which inherits the same image) becomes the square thumbnail. */
    .desktop-surface .k-cards .result-img {
        position: static;
        flex: none;
        min-height: 0;
        background-size: 0 0;
    }

    .desktop-surface .k-cards .result-img::before {
        content: "";
        position: absolute;
        top: 0.5rem;
        left: 0.5rem;
        width: var(--_thumb);
        height: var(--_thumb);
        border-radius: 0.6rem;
        background-image: inherit;
        background-size: cover;
        background-position: center center;
        background-repeat: no-repeat;
    }

    .desktop-surface .k-cards .result-img > video {
        inset: 0.5rem auto auto 0.5rem !important;
        width: var(--_thumb) !important;
        height: var(--_thumb) !important;
        border-radius: 0.6rem;
    }

    /* Out: both pills (the place is the first fact; a rating line is for the
       listing itself) and the colour wash */
    .desktop-surface .k-cards .booking-date,
    .desktop-surface .k-cards .booking-time,
    .desktop-surface .k-cards .imgColors-item { display: none; }

    .desktop-surface .k-cards .imgColors-cont {
        position: static !important;
        display: block;
        width: 100% !important;
        padding-right: 2rem;   /* clear of the heart */
    }

    .desktop-surface .k-cards .imgColors-content.cards {
        padding: 0 !important;
        background: none;
    }

    .desktop-surface .k-cards .searchResult h3 {
        font-size: calc(1rem + var(--up));
        line-height: 1.2;
        margin: 0;
    }

    .desktop-surface .k-cards .img-fav {
        top: 0.45rem;
        right: 0.45rem;
        width: 1.75rem;
        height: 1.75rem;
        font-size: 0.8rem;
        outline-width: 1px;
        box-shadow: none;
    }

    /* One line: facts at the left, the price at the right */
    .desktop-surface .k-cards .result-title2 {
        align-items: flex-end;
        margin-top: 0;
        padding: 0 !important;
        background: none;
    }

    /* The facts: whole ones only. They wrap, and the line is one line tall, so
       a fact that does not fit is simply not shown: no "..." row, no half fact.
       The place may be a long string (some listings carry a whole street
       address there): it is cut at about twenty characters, which keeps a ZIP
       and a country off the row and leaves the next fact room. */
    .desktop-surface .k-cards .searchResult:has(.booking-date) .highlights-cont > span:first-child { display: block; }

    .desktop-surface .k-cards .highlights-cont {
        display: flex;
        flex-wrap: wrap;
        align-items: baseline;
        gap: 0 0.7rem;
        height: 1.4em;
        overflow: hidden;
        color: rgba(255, 255, 255, 0.92);
    }

    .desktop-surface .k-cards .highlights-cont > span {
        flex: 0 0 auto;
        max-width: 100%;
        margin: 0;
        line-height: 1.4;
        white-space: nowrap;
    }

    .desktop-surface .k-cards .highlights-cont > span:first-child {
        flex: 0 1 auto;
        min-width: 0;
        max-width: min(100%, 20ch);
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .desktop-surface .k-cards .highlights-cont > .d-block { display: none !important; }

    .desktop-surface .k-cards .result-title2 h3 {
        font-size: calc(1.5rem + 2 * var(--up));
        line-height: 0.95;
    }

    .desktop-surface .k-cards .result-title2 h3 + p { margin-top: 0.1rem !important; }

    /* The chosen row: its own colour turned up, a pink ring inside the box and
       a pink bar down its left edge. The rest step back a little. */
    .desktop-surface .k-cards .searchResult.is-selected,
    .desktop-surface .k-cards .searchResult[aria-current="true"] {
        background: color-mix(in srgb, var(--itemColorBG, var(--rt-blue)) 42%, #121A25);
        outline-width: 4px;
        outline-offset: -4px;
        --k-ring: 4px;
        box-shadow: 0 0 0 3px rgba(235, 93, 143, 0.35), 0 0.75rem 1.25rem -0.5rem rgba(0, 0, 0, 0.45);
    }

    .desktop-surface .k-cards:has(.is-selected, [aria-current="true"]) .searchResult:not(.is-selected, [aria-current="true"]) {
        opacity: 0.9;
    }

    @media (hover: hover) and (pointer: fine) {
        .desktop-surface .k-cards .searchResult:hover {
            transform: translateX(3px);
            opacity: 1;
        }
    }
}

/* Narrower still: the row keeps its thumbnail and title and sheds the rest */
@container lane (width < 17rem) {
    .desktop-surface .k-cards .searchResult {
        --_thumb: 3.25rem;
        padding: 0.5rem 0.6rem 0.5rem calc(var(--_thumb) + 1.1rem);
    }

    .desktop-surface .k-cards .result-title2,
    .desktop-surface .k-cards .img-fav { display: none !important; }

    .desktop-surface .k-cards .imgColors-cont { padding-right: 0; }

    .desktop-surface .k-cards .searchResult h3 { font-size: max(0.875rem, var(--type-meta)); }
}


/* ─── STRIP: a Spine's filmstrip (lane under 12rem) ───────────────────────── */

@container lane (width < 12rem) {
    .desktop-surface .k-cards { gap: 0.5rem; }

    .desktop-surface .k-cards .searchResult {
        display: block;
        min-height: 0;
        aspect-ratio: 1;
        padding: 0;
        border-radius: 0.8rem;
        outline-width: 2px;
        box-shadow: none;
    }

    .desktop-surface .k-cards .result-img::before {
        inset: 0 0 auto 0;
        width: 100%;
        height: auto;
        aspect-ratio: 1;
        border-radius: 0;
    }

    .desktop-surface .k-cards .result-img > video {
        inset: 0 0 auto 0 !important;
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 1;
        border-radius: 0;
    }

    .desktop-surface .k-cards .imgColors-cont { display: none; }

    /* The current item: a ring, and its title written up the strip IN FULL
       (14px or more; it is only cut if it would run past 36rem) */
    .desktop-surface .k-cards .searchResult.is-selected,
    .desktop-surface .k-cards .searchResult[aria-current="true"] {
        aspect-ratio: auto;
        padding: calc(100% + 0.6rem) 0 0.8rem;
        outline-width: 3px;
        outline-offset: -3px;
        --k-ring: 3px;
        box-shadow: 0 0 0 3px rgba(235, 93, 143, 0.35);
    }

    .desktop-surface .k-cards .searchResult.is-selected .imgColors-cont,
    .desktop-surface .k-cards .searchResult[aria-current="true"] .imgColors-cont {
        display: block;
        padding: 0;
    }

    .desktop-surface .k-cards .searchResult.is-selected h3,
    .desktop-surface .k-cards .searchResult[aria-current="true"] h3 {
        display: block;
        max-height: 36rem;
        margin: 0 auto;
        writing-mode: vertical-rl;
        rotate: 180deg;   /* runs up the strip, as the stage's own Spine title does (lanes.css) */
        font-size: max(0.875rem, var(--type-meta));
        line-height: 1.15;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    @media (hover: hover) and (pointer: fine) {
        .desktop-surface .k-cards .searchResult:hover { transform: scale(1.06); }
    }
}


/* ─── .k-tile: the small poster ───────────────────────────────────────────── */
/* For shelves and feature panels (Home's "New on RedTulip", "Just for you").
   Set --k-photo inline. A price .k-pill goes top-left; the title sits on a
   dark gradient at the foot.
     <a class="k-tile" style="--k-photo: url(...)">
         <span class="k-pill">$24</span>
         <span class="k-tile-title"><span>Raw honey, one pound</span></span>
     </a>
   .k-tiles is a shelf: one row of whole tiles, more of them in a wide lane.
   Tiles past the row are clipped, not removed: give them tabindex="-1" (or
   trim the list) where the shelf is long. */

.desktop-surface .k-tiles {
    --k-tile-min: clamp(7rem, 5.5rem + 5cqi, 10.5rem);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(var(--k-tile-min), 1fr));   /* auto-fit: a short shelf still fills its row */
    /* ONE whole row: as many tiles as fit, the rest fall into rows of no
       height and are clipped. Never an orphan tile alone on a second row. */
    grid-template-rows: auto;
    grid-auto-rows: 0;
    gap: 0 clamp(0.6rem, 0.4rem + 0.8cqi, 1.1rem);
    min-width: 0;
    margin: -0.4rem -0.3rem 0;
    padding: 0.4rem 0.3rem 0;   /* room for a tile's lift inside the clip; no room below, or the next row would show */
    overflow: hidden;
}

/* --grid: a feature panel's board. A fixed EVEN count per row (two, or four
   when the panel is wide), so four or six tiles always fill whole rows. */
.desktop-surface .k-tiles--grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: none;
    grid-auto-rows: auto;
    gap: clamp(0.6rem, 0.4rem + 0.8cqi, 1.1rem);
    margin: 0;
    padding: 0;
    overflow: visible;
}

@container (width >= 36rem) {
    .desktop-surface .k-tiles--grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.desktop-surface .k-tile {
    position: relative;
    display: block;
    min-width: 0;
    aspect-ratio: 1 / 1.2;
    border: 2px solid rgba(255, 255, 255, 0.85);
    border-radius: var(--r-tile);
    background: var(--rt-ink) var(--k-photo, none) center / cover no-repeat;
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.16);
    color: #fff;
    text-align: left;
    overflow: hidden;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base) var(--ease-out);
}

.desktop-surface .k-tile > .k-pill {
    position: absolute;
    z-index: 1;
    top: 0.45rem;
    left: 0.45rem;
}

.desktop-surface .k-tile-title {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 1.9rem 0.65rem 0.55rem;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.45) 55%, rgba(0, 0, 0, 0) 100%);
    color: #fff;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.2;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
}

/* The clamp lives on an inner span: clamping the padded box lets a third
   line show through the padding */
.desktop-surface .k-tile-title > span {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.desktop-surface .k-tile.is-selected,
.desktop-surface .k-tile[aria-current="true"] {
    border-color: var(--rt-pink);
    outline: 3px solid var(--rt-pink);
    outline-offset: -5px;
}

.desktop-surface .k-tile:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 2px;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-tile:hover {
        transform: translateY(-3px);
        box-shadow: 0 0.9rem 1.6rem rgba(0, 0, 0, 0.28);
    }
}

@media (prefers-reduced-motion: reduce) {
    .desktop-surface .k-cards .searchResult,
    .desktop-surface .k-cards .img-fav,
    .desktop-surface .k-tile { transition: none; }

    .desktop-surface .k-cards .searchResult:hover,
    .desktop-surface .k-tile:hover { transform: none; }
}
