/* ═══════════════════════════════════════════════════════════════════════════
   kit.css — the desktop kit (docs/plans/desktop/foundation.md, unit K)

   The mobile app's parts, re-scaled for the space a lane gives them. Every
   later desktop unit builds with these, so a screen looks like RedTulip
   before anyone designs it. See them all at /{territory}/Dev-Kit/.

   Ported from (never loaded here): assets/css/style.css (.rbox, the gradient
   headers, .savedItem tilt cards, .categories-cont rows), assets/css/app.css
   (the BUTTON SYSTEM at its end, .kb-seg, .rt-ss), pages/Home.php (.hn-head,
   the Race to 100 and feature panels). Tokens live in desktop.css.

   Rules of this sheet
   - Prefix k-. Demo-only layout for the kit page is k-demo-, in the last
     section. Classes that SHARED code emits (the result card, intlTel) keep
     their own names and are styled here or in kit-card.css.
   - Every selector starts .desktop-surface: desktop.css pins h1 and h3 at
     (0,1,1), and a kit role on a heading has to win without a priority flag.
     One uniform base specificity, (0,2,0); a lane-family sheet loads later.
   - Fluid by construction: clamp() with cqi, auto-fit / minmax() grids, flex
     wrap. A part changes FORM through `@container lane (...)` on the
     .lane-body it is in, never through a viewport query. The only media
     queries are prefers-reduced-motion and (hover: hover).
   - Soehne has no weight axis: a rule names a family and pins font-weight
     normal. Always the full `background:` shorthand on anything with a fill
     (the fills are images; a background-color never overrides one).
   - No overlays. Things that would have been a modal or a popover are the
     disclosure (section 13), which pushes the content under it.
   - No text under 13px: the smallest size is --type-meta.

   Contents
     1  Tones                 8  Chips, pills, badges, status
     2  Type roles            9  Rows
     3  The wave and wash    10  Form controls
     4  Panels               11  Keeper, price lines, alert, empty state
     5  Section header       12  Meter
     6  Stat cards, tilt set 13  Disclosure
     7  Buttons              14  Lane progress, arrival, the Spine
                             14b Parts for the slice (Ask, Browse, Focus,
                                 Act, loading)
                             15  Reduced motion
                             16  The kit page (k-demo-)
                             17  The parts page (k-scene-)
                             18  The inline calendar (RT.Calendar
                                 inline mode, .rtcal-inline)
   ═══════════════════════════════════════════════════════════════════════════ */


/* ─── 1. TONES ────────────────────────────────────────────────────────────── */
/* A tone class names a colour family ON THE ELEMENT THAT PAINTS (a button, a
   panel head, a tilt card, a chip). The properties are registered as
   non-inheriting, so a pink panel head does not turn the buttons under it
   pink; where @property is missing they inherit, which is only a softer
   default. Parts read them with a blue fallback.
   A non-inheriting property does not reach a child or a pseudo-element, so a
   part whose paint is drawn by one (a meter's bar, a status dot, a tick)
   copies the tone into a private, inheriting --_name on itself first. */

@property --tone       { syntax: '*'; inherits: false; }
@property --tone-lt    { syntax: '*'; inherits: false; }
@property --tone-dk    { syntax: '*'; inherits: false; }
@property --tone-slt   { syntax: '*'; inherits: false; }
@property --tone-ink   { syntax: '*'; inherits: false; }
@property --tone-fill  { syntax: '*'; inherits: false; }
@property --tone-head  { syntax: '*'; inherits: false; }
@property --tone-tilt  { syntax: '*'; inherits: false; }
@property --tone-ghost { syntax: '*'; inherits: false; }
@property --tone-glow  { syntax: '*'; inherits: false; }
@property --tone-on    { syntax: '*'; inherits: false; }   /* the text colour ON the tone's fill: white, or navy ink on amber */
@property --tone-deep  { syntax: '*'; inherits: false; }   /* the family's darkest step: text on its own wash (a soft badge) */

.desktop-surface .k-tone-blue {
    --tone: var(--rt-blue); --tone-lt: var(--rt-blue-lt); --tone-dk: var(--rt-blue-dk); --tone-slt: var(--rt-blue-slt);
    --tone-ink: var(--ink-blue); --tone-fill: var(--fill-blue); --tone-head: var(--head-blue);
    --tone-tilt: var(--tilt-blue); --tone-ghost: var(--ghost-blue); --tone-glow: var(--glow-blue);
    --tone-deep: var(--rt-blue-bl);
}

.desktop-surface .k-tone-pink {
    --tone: var(--rt-pink); --tone-lt: var(--rt-pink-lt); --tone-dk: var(--rt-pink-dk); --tone-slt: var(--rt-pink-slt);
    --tone-ink: var(--ink-pink); --tone-fill: var(--fill-pink); --tone-head: var(--head-pink);
    --tone-tilt: var(--tilt-pink); --tone-ghost: var(--ghost-pink); --tone-glow: var(--glow-pink);
    --tone-deep: var(--rt-pink-bl);
}

.desktop-surface .k-tone-teal {
    --tone: var(--rt-teal); --tone-lt: var(--rt-teal-lt); --tone-dk: var(--rt-teal-dk); --tone-slt: var(--rt-teal-slt);
    --tone-ink: var(--ink-teal); --tone-fill: var(--fill-teal); --tone-head: var(--head-teal);
    --tone-tilt: var(--tilt-teal); --tone-ghost: var(--ghost-teal); --tone-glow: var(--glow-teal);
    --tone-deep: var(--rt-teal-bl);
}

.desktop-surface .k-tone-purple {
    --tone: var(--rt-purple); --tone-lt: var(--rt-purple-lt); --tone-dk: var(--rt-purple-dk); --tone-slt: var(--rt-purple-slt);
    --tone-ink: var(--ink-purple); --tone-fill: var(--fill-purple); --tone-head: var(--head-purple);
    --tone-tilt: var(--tilt-purple); --tone-ghost: var(--ghost-purple); --tone-glow: var(--glow-purple);
    --tone-deep: var(--rt-purple-bl);
}

.desktop-surface .k-tone-green {
    --tone: var(--rt-success); --tone-lt: var(--rt-success-lt); --tone-dk: var(--rt-success-dk); --tone-slt: var(--rt-success-slt);
    --tone-ink: var(--ink-green); --tone-fill: var(--fill-green); --tone-head: var(--head-green);
    --tone-tilt: var(--tilt-green); --tone-ghost: var(--ghost-green); --tone-glow: var(--glow-green);
    --tone-deep: var(--rt-success-bl);
}

.desktop-surface .k-tone-amber {
    --tone: var(--rt-amber-md); --tone-lt: var(--rt-amber-lt); --tone-dk: var(--rt-amber-ink); --tone-slt: #FFF1D6;
    --tone-ink: var(--ink-amber); --tone-fill: var(--fill-amber); --tone-head: var(--head-sunrise);
    --tone-tilt: var(--tilt-amber); --tone-ghost: var(--ghost-amber); --tone-glow: var(--glow-amber);
    --tone-deep: #5C3200;
    --tone-on: var(--rt-ink);
}

.desktop-surface .k-tone-navy {
    --tone: var(--rt-navy-2); --tone-lt: #4A6F9C; --tone-dk: var(--rt-navy-1); --tone-slt: #DFE7F1;
    --tone-ink: var(--ink-navy); --tone-fill: var(--fill-navy); --tone-head: var(--head-navy);
    --tone-tilt: var(--tilt-navy); --tone-ghost: var(--ghost-navy); --tone-glow: var(--glow-navy);
    --tone-deep: var(--rt-navy-1);
}

.desktop-surface .k-tone-slate {
    --tone: var(--rt-slate-solid); --tone-lt: #8B98A6; --tone-dk: #33424F; --tone-slt: #E6EAEE;
    --tone-ink: var(--ink-slate); --tone-fill: var(--fill-slate); --tone-head: var(--fill-slate);
    --tone-tilt: var(--fill-slate); --tone-ghost: var(--ghost-slate); --tone-glow: rgba(70, 90, 110, 0.28);
    --tone-deep: #2A3743;
}

/* Head-only tones: a pink family whose header is the checklist's sunrise, and
   Hoku's blue-to-pink sweep. */
.desktop-surface .k-tone-sunrise {
    --tone: var(--rt-pink); --tone-lt: var(--rt-pink-lt); --tone-dk: var(--rt-pink-dk); --tone-slt: var(--rt-pink-slt);
    --tone-ink: var(--ink-pink); --tone-fill: var(--fill-pink); --tone-head: var(--head-sunrise);
    --tone-tilt: var(--tilt-pink); --tone-ghost: var(--ghost-pink); --tone-glow: var(--glow-pink);
    --tone-deep: var(--rt-pink-bl);
}

.desktop-surface .k-tone-hoku {
    --tone: var(--rt-purple); --tone-lt: var(--rt-purple-lt); --tone-dk: var(--rt-purple-dk); --tone-slt: var(--rt-purple-slt);
    --tone-ink: var(--ink-purple); --tone-fill: var(--fill-purple); --tone-head: var(--head-hoku);
    --tone-tilt: var(--tilt-purple); --tone-ghost: var(--ghost-purple); --tone-glow: var(--glow-purple);
    --tone-deep: var(--rt-purple-bl);
}


/* ─── 2. TYPE ROLES ───────────────────────────────────────────────────────── */
/* display: the greeting ("Hey, Logan!"). title: a page or lane title. Both
   are soehne-halbfett at -.04em, white on the wave (.k-on-dark) or ink on glass.
   (soehne-fett is the Home hero, the picker headline and the word mark only: --font-mark.)
   section: a panel or shelf title (halbfett). lead / body / meta: prose.
   mono + eyebrow: ids, counts, the small caps line over a title. */

.desktop-surface .k-display,
.desktop-surface .k-title {
    font-family: var(--font-head);
    font-weight: normal;
    letter-spacing: var(--track-tight);
    color: var(--text);
    margin: 0;
    text-wrap: balance;
}

.desktop-surface .k-display {
    font-size: var(--type-display);
    line-height: var(--lh-display);
}

.desktop-surface .k-title {
    font-size: var(--type-title);
    line-height: var(--lh-title);
}

.desktop-surface .k-section {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1.15;
    letter-spacing: var(--track-snug);
    color: var(--text);
    margin: 0;
}

.desktop-surface .k-lead {
    font-family: var(--font-text);
    font-weight: normal;
    font-size: var(--type-lead);
    line-height: 1.45;
    color: var(--text-soft);
    margin: 0;
}

.desktop-surface .k-body {
    font-family: var(--font-text);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: var(--lh-body);
    color: var(--text);
    margin: 0;
}

.desktop-surface .k-meta {
    font-family: var(--font-text);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.4;
    color: var(--text-soft);
    margin: 0;
}

.desktop-surface .k-mono {
    font-family: var(--font-mono);
    font-weight: normal;
    font-size: var(--type-mono);
    line-height: 1.4;
    letter-spacing: 0;
    margin: 0;
}

.desktop-surface .k-eyebrow {
    font-family: var(--font-head);   /* the phone's small caps line is spaced sans, not mono */
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.3;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-soft);
    margin: 0;
}

/* Emphasis is a family, never a weight */
.desktop-surface .k-strong { font-family: var(--font-head); font-weight: normal; }

/* On the wave, a photo or a dark panel */
.desktop-surface .k-on-dark {
    color: #fff;
    text-shadow: var(--shadow-text);
}

.desktop-surface .k-on-dark.k-soft { color: rgba(255, 255, 255, 0.78); }   /* the second line of a greeting */
.desktop-surface .k-on-dark.k-eyebrow,
.desktop-surface .k-on-dark.k-meta { color: rgba(255, 255, 255, 0.9); text-shadow: none; }

/* Text in a tone (panel titles are blue on mobile: "All Messages") */
.desktop-surface .k-ink-tone { color: var(--tone-ink, var(--ink-blue)); }


/* ─── 3. THE WAVE AND THE WASH ────────────────────────────────────────────── */
/* What a panel sits on. A page root opts in with .k-waved (the hero wave
   behind its top) and / or .k-washed (the soft colour across the stage). Both
   are painted on the page's CONTAINER (.lane-body, or .desktop-main before
   the stage manager moves the page into a lane) so they bleed to its edges
   whatever padding it has: the wave must never be a box (audit section 6,
   row 10).

   The wave fades in from the left so the shell's live rail shows through and
   the two read as one shape. INTERIM: when the shell carries its own canvas
   and aurora across the stage (unit H), delete these two rules and the two
   classes; nothing else depends on them. */

/* ─── 4. PANELS ───────────────────────────────────────────────────────────── */
/* .rbox: 85% white glass, a soft white outline, the heavy floating shadow.
   Parts: -head (plain, or a gradient when it carries a tone), -body, -foot.
   Variants: --navy (Race to 100), --tint (the whole panel in a tone: "New on
   RedTulip"), --photo (a blurred photo in the listing's colour: "Just for
   you"), --flat (no shadow: a panel inside a panel). */

.desktop-surface .k-panel {
    /* A panel is a size container (unnamed): the cqi in every token read
       INSIDE it resolves against the panel, so a panel that is one of four
       across a wide Stage is set like the phone, not like the lane. Queries
       named `lane` still reach the lane. The panel's own padding and radius
       resolve against the lane. It must be given its width (a block, a grid
       cell, a stretched flex item): containment means it cannot shrink-wrap. */
    container-type: inline-size;
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    background: var(--glass-bg);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    outline: var(--glass-outline);
    border-radius: var(--r-panel);
    box-shadow: var(--shadow-cont);
    color: var(--text);
    overflow: hidden;
}

.desktop-surface .k-panel--flat { box-shadow: none; }

.desktop-surface .k-panel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-md);
    padding: var(--pad-panel);
    background: var(--tone-head, none);
}

.desktop-surface .k-panel-head > * { margin: 0; }
.desktop-surface .k-panel-head-text { flex: 1 1 12rem; min-width: 0; }

.desktop-surface .k-panel-title {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1.15;
    letter-spacing: var(--track-snug);
    color: var(--ink-blue);
    margin: 0;
}

.desktop-surface .k-panel-sub {
    font-family: var(--font-text);
    font-size: var(--type-meta);
    line-height: 1.4;
    color: var(--text-soft);
    margin: 0.15rem 0 0;
}

/* A head that carries a tone is a gradient with white type */
.desktop-surface .k-panel-head[class*="k-tone-"] { color: #fff; }
.desktop-surface .k-panel-head[class*="k-tone-"] .k-panel-title { color: #fff; }
.desktop-surface .k-panel-head[class*="k-tone-"] .k-panel-sub { color: #fff; }

.desktop-surface .k-panel-body { padding: var(--pad-panel); min-width: 0; }
.desktop-surface .k-panel-head + .k-panel-body:not(.k-panel-body--flush) { padding-top: 0; }
.desktop-surface .k-panel-head[class*="k-tone-"] + .k-panel-body:not(.k-panel-body--flush) { padding-top: var(--pad-panel); }
.desktop-surface .k-panel-body--flush { padding: 0; }

.desktop-surface .k-panel-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-sm) var(--space-md);
    padding: var(--space-md) var(--pad-panel);
    border-top: 1px solid var(--glass-rule);
}

/* --navy: the dark panel. White type, a lighter band for the foot. */
.desktop-surface .k-panel--navy {
    background: var(--fill-navy);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    color: #fff;
}

.desktop-surface .k-panel--navy .k-panel-title,
.desktop-surface .k-panel--tint .k-panel-title,
.desktop-surface .k-panel--photo .k-panel-title { color: #fff; }

.desktop-surface .k-panel--navy .k-panel-sub,
.desktop-surface .k-panel--navy .k-meta,
.desktop-surface .k-panel--navy .k-body { color: rgba(255, 255, 255, 0.9); }

.desktop-surface .k-panel--navy .k-eyebrow { color: rgba(255, 255, 255, 0.82); }

.desktop-surface .k-panel--navy .k-panel-foot {
    border-top: 0;
    background: rgba(102, 166, 255, 0.16);
}

/* --tint: translucent glass in the panel's own tone (put the tone class on
   the panel). Holds poster tiles; the title is white. */
.desktop-surface .k-panel--tint {
    background: var(--tone-head, var(--head-pink));
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    color: #fff;
}

.desktop-surface .k-panel--tint .k-panel-head { background: none; }
.desktop-surface .k-panel--tint .k-panel-sub { color: #fff; }

/* --photo: set --k-photo (a url()) and --k-color (the photo's dominant
   colour) inline. The photo is blurred into the colour, so any title reads. */
.desktop-surface .k-panel--photo {
    --k-color: #5A4334;
    background: color-mix(in srgb, var(--k-color) 48%, #000);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    color: #fff;
    isolation: isolate;
}

.desktop-surface .k-panel--photo::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: -12%;
    background: var(--k-photo, none) center / cover no-repeat;
    filter: blur(22px) saturate(1.15);
    opacity: 0.45;
    -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 96%);
    mask-image: linear-gradient(to bottom, #000 30%, transparent 96%);
}

.desktop-surface .k-panel--photo .k-panel-head { background: none; text-shadow: 0 1px 8px rgba(0, 0, 0, 0.35); }
.desktop-surface .k-panel--photo .k-panel-sub { color: #fff; }
.desktop-surface .k-panel--photo .k-panel-foot { border-top: 0; justify-content: center; }


/* ─── 5. SECTION HEADER ───────────────────────────────────────────────────── */
/* The shelf heading (.hn-head): its own light box so the title, the blurb and
   "See all" read at any scroll position over the wave or the wash. */

.desktop-surface .k-sechead {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-md);
    padding: 0.85rem var(--pad-panel);
    border-radius: var(--r-panel);
    background: var(--ghost-pink), rgba(255, 255, 255, 0.35);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
}

.desktop-surface .k-sechead-text { flex: 1 1 10rem; min-width: 0; }

.desktop-surface .k-sechead-title {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1.15;
    letter-spacing: var(--track-snug);
    color: var(--text);
    margin: 0;
}

.desktop-surface .k-sechead-blurb {
    font-size: var(--type-meta);
    line-height: 1.4;
    color: var(--text-soft);
    margin: 0.1rem 0 0;
}


/* ─── 6. STAT CARDS AND THE TILT SET ──────────────────────────────────────── */
/* .k-stats: the quiet trio inside a panel ("2 ACTIVE / 0 VIEWS"). The number
   takes the tile's tone.
   .k-tilt: the coloured cards that lean (Keeper Dashboard, Storefront). Outer
   cards tilt away from the middle one; a pointer straightens and lifts the
   card under it. A card is a link, a button or a plain figure. */

.desktop-surface .k-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(5rem, 1fr));
    gap: var(--space-sm);
}

.desktop-surface .k-stat {
    display: grid;
    gap: 0.15rem;
    justify-items: center;
    padding: var(--space-md) var(--space-sm);
    border-radius: 0.75rem;
    background: var(--tile-fill);
    text-align: center;
}

.desktop-surface .k-stat-num {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1.1;
    color: var(--tone-ink, var(--ink-blue));
}

.desktop-surface .k-stat-label {
    font-family: var(--font-text);
    font-size: var(--type-meta);
    line-height: 1.2;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-soft);
}

.desktop-surface .k-tilt {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(5.25rem, 1fr));   /* three across from a 20rem lane */
    max-width: 36rem;                                                 /* and a card never far outgrows its phone size */
    gap: clamp(0.75rem, 0.4rem + 1.4cqi, 1.5rem);
    padding: 0.75rem 0.6rem;   /* room for the lean: a tilted corner stays inside its lane */
}

.desktop-surface .k-tilt-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    min-width: 0;
    aspect-ratio: 1 / 1.2;
    padding: var(--space-md) var(--space-sm);
    border-radius: var(--r-card);
    --_lt: var(--tone-lt, var(--rt-blue-lt));
    background: var(--tone-tilt, var(--tilt-blue));
    outline: 2px solid var(--_lt);
    box-shadow: var(--shadow-cont-sm);
    color: var(--tone-on, #fff);
    text-align: center;
    transition: transform var(--dur-slow) var(--ease-spring), box-shadow var(--dur-base) var(--ease-out);
}

.desktop-surface .k-tilt-card:nth-child(3n + 1) { transform: translateY(0.5rem) rotate(-5deg); }
.desktop-surface .k-tilt-card:nth-child(3n)     { transform: translateY(0.5rem) rotate(5deg); }

.desktop-surface .k-tilt-icon {
    font-size: clamp(1.9rem, 1.3rem + 2.2cqi, 3rem);
    line-height: 1;
    color: var(--_lt);
}

.desktop-surface .k-tilt-num {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: clamp(2rem, 1.3rem + 2.6cqi, 3.4rem);
    line-height: 0.95;
    letter-spacing: var(--track-tight);
}

.desktop-surface .k-tilt-label {
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.15;
}

.desktop-surface .k-tilt-note {
    font-size: var(--type-meta);
    line-height: 1.1;
    opacity: 0.85;
}

.desktop-surface :is(a, button).k-tilt-card:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 3px;
}

.desktop-surface :is(a, button).k-tilt-card:active {
    transform: scale(0.97);
    transition-duration: var(--dur-press);
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-tilt-card:hover {
        transform: translateY(-0.5rem) rotate(0deg) scale(1.04);   /* the liveliness is the travel (a lean of 5deg undone, a lift of a full rem), not overshoot */
        box-shadow: var(--shadow-cont-hover);
        z-index: 1;
    }
}


/* ─── 7. BUTTONS ──────────────────────────────────────────────────────────── */
/* One paint language (app.css BUTTON SYSTEM), three ranks:
     .k-btn .................. primary: the tone's 160deg fill, a white ring,
                               a glow in its own colour. One per lane.
     .k-btn--secondary ....... glass tinted toward the tone, a 2px ring in the
                               tone. Engaged = the solid fill.
     .k-btn--ghost ........... glass only, text in the tone. The quiet one.
     .k-btn--light ........... a white pill for a dark panel.
   Sizes --sm / --lg (the hero pill, icon at the left) / --block.
   Engaged has one look and three triggers: the press (:active), a selection
   (aria-pressed="true" or .is-on), and a real pointer's hover.
   Loading: aria-busy="true". Disabled: the attribute, or aria-disabled.
   .k-iconbtn: the round glass button (back, close, the save heart). */

.desktop-surface .k-btn {
    --_fill: var(--tone-fill, var(--fill-blue));
    --_ink: var(--tone-ink, var(--ink-blue));
    --_on: var(--tone-on, #fff);
    --_ghost: var(--tone-ghost, var(--ghost-blue));
    --_glow: var(--tone-glow, var(--glow-blue));
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.55em;
    min-height: 2.75rem;
    max-width: 100%;
    padding: 0.5em 1.6em;
    border: 0;
    border-radius: var(--r-pill);
    background: var(--_fill);
    box-shadow: 0 0.375rem 0.875rem var(--_glow);
    outline: var(--glass-outline);
    outline-offset: 0;
    color: var(--_on);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.15;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    transition:
        transform var(--dur-base) var(--ease-spring),
        filter var(--dur-fast) var(--ease-out),
        box-shadow var(--dur-fast) var(--ease-out),
        color var(--dur-fast) var(--ease-out);
}

.desktop-surface a.k-btn:hover { color: var(--_on); }

.desktop-surface .k-btn--secondary {
    background: var(--_ghost);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    box-shadow: inset 0 0 0 2px var(--_ink);
    color: var(--_ink);
}

.desktop-surface .k-btn--ghost {
    background: var(--_ghost);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    box-shadow: none;
    color: var(--_ink);
}

.desktop-surface .k-btn--light {
    background: #fff;
    box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.25);
    color: var(--text);
}

/* A link styled as a button keeps its ink when hover is not available (touch); where hover
   fills the button (the (hover: hover) block below) the ink must turn with it, so this rule
   is limited to devices without hover. 2026-11-11: it made "View Storefront" purple on purple. */
@media (hover: none) {
    .desktop-surface a.k-btn--secondary:hover,
    .desktop-surface a.k-btn--ghost:hover { color: var(--_ink); }
}
.desktop-surface a.k-btn--light:hover { color: var(--text); }

/* Sizes */
.desktop-surface .k-btn--sm {
    min-height: 2.125rem;
    padding: 0.3em 1em;
    font-size: var(--type-meta);
}

.desktop-surface .k-btn--lg {
    min-height: clamp(3.25rem, 2.9rem + 1cqi, 4rem);
    padding: 0.55em 1.75em;
    font-size: var(--type-lead);
    box-shadow: 0 0.6rem 1.4rem var(--_glow), var(--shadow-cont-sm-lt);
}

.desktop-surface .k-btn--block { display: flex; width: 100%; }

/* Engaged: the solid fill and white text */
.desktop-surface .k-btn--secondary:active,
.desktop-surface .k-btn--secondary[aria-pressed="true"],
.desktop-surface .k-btn--secondary.is-on,
.desktop-surface .k-btn--ghost:active,
.desktop-surface .k-btn--ghost[aria-pressed="true"],
.desktop-surface .k-btn--ghost.is-on {
    background: var(--_fill);
    box-shadow: 0 0.375rem 0.875rem var(--_glow);
    color: var(--_on);
}

.desktop-surface .k-btn:active {
    transform: scale(0.97);
    filter: brightness(0.94);
    transition-duration: var(--dur-press);
}

.desktop-surface .k-btn:focus-visible,
.desktop-surface .k-iconbtn:focus-visible {
    outline: 3px solid #fff;
    box-shadow: 0 0 0 6px var(--_ink, var(--rt-blue));
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-btn:hover {
        transform: translateY(-1px);
        filter: brightness(1.06) saturate(1.05);
    }

    .desktop-surface .k-btn:not(.k-btn--secondary, .k-btn--ghost, .k-btn--light):hover {
        box-shadow: 0 0.65rem 1.5rem var(--_glow);
    }

    .desktop-surface .k-btn--secondary:hover,
    .desktop-surface .k-btn--ghost:hover {
        background: var(--_fill);
        box-shadow: 0 0.375rem 0.875rem var(--_glow);
        color: var(--_on);
    }
}

/* Loading: the label holds its width, a ring spins in its place */
.desktop-surface .k-btn[aria-busy="true"] {
    color: transparent;
    pointer-events: none;
}

.desktop-surface .k-btn[aria-busy="true"] > * { visibility: hidden; }

.desktop-surface .k-btn[aria-busy="true"]::after {
    content: "";
    position: absolute;
    inset: 0;
    margin: auto;
    width: 1.25em;
    height: 1.25em;
    border-radius: 50%;
    border: 0.18em solid color-mix(in srgb, var(--_on) 40%, transparent);
    border-top-color: var(--_on);
    animation: k-spin 720ms linear infinite;
}

.desktop-surface .k-btn--secondary[aria-busy="true"]::after,
.desktop-surface .k-btn--ghost[aria-busy="true"]::after,
.desktop-surface .k-btn--light[aria-busy="true"]::after {
    border-color: color-mix(in srgb, var(--_ink) 30%, transparent);
    border-top-color: var(--_ink);
}

/* Disabled: quiet grey, no glow, no ring in a tone; the label still reads (5:1). */
.desktop-surface .k-btn:disabled,
.desktop-surface .k-btn[aria-disabled="true"] {
    background: #E3E7EC;
    box-shadow: none;
    outline-color: rgba(255, 255, 255, 0.7);
    color: #566170;
    cursor: not-allowed;
    filter: none;
    transform: none;
}

.desktop-surface .k-btn--secondary:disabled,
.desktop-surface .k-btn--secondary[aria-disabled="true"],
.desktop-surface .k-btn--ghost:disabled,
.desktop-surface .k-btn--ghost[aria-disabled="true"] {
    background: rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 0 0 2px #C3CAD3;
    color: #566170;
}

/* Icon button */
.desktop-surface .k-iconbtn {
    --_ink: var(--tone-ink, var(--rt-ink));
    display: inline-grid;
    place-items: center;
    flex: none;
    width: 2.75rem;
    height: 2.75rem;
    border: 0;
    border-radius: 50%;
    background: var(--glass-bg);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
    color: var(--_ink);
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-spring), background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-iconbtn--sm { width: 2.125rem; height: 2.125rem; font-size: 0.9rem; }

.desktop-surface .k-iconbtn[aria-pressed="true"],
.desktop-surface .k-iconbtn.is-on {
    background: var(--tone-tilt, var(--tilt-pink));
    outline-color: var(--tone-lt, var(--rt-pink-lt));
    color: #fff;
}

.desktop-surface .k-iconbtn:active { transform: scale(0.92); transition-duration: var(--dur-press); }

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-iconbtn:hover { transform: scale(1.08); }
}

/* A row of buttons that wraps */
.desktop-surface .k-btns {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-sm);
}


/* ─── 8. CHIPS, PILLS, BADGES, STATUS ─────────────────────────────────────── */
/* .k-chip: a filter you can press (Bookings: All / Needs action / Upcoming).
   Resting = the secondary button's glass in its tone, pressed = the fill.
   .k-pill: a label on a photo (the price on a tile). Not a control.
   .k-badge: a small filled word (ACTIVE, NEW). --soft tints instead of fills.
   .k-status: a dot and a word on a white chip (Currently Away). */

.desktop-surface .k-chips {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs) var(--space-sm);
}

.desktop-surface .k-chip {
    --_fill: var(--tone-fill, var(--fill-blue));
    --_ink: var(--tone-ink, var(--ink-blue));
    --_on: var(--tone-on, #fff);
    --_ghost: var(--tone-ghost, var(--ghost-blue));
    --_glow: var(--tone-glow, var(--glow-blue));
    display: inline-flex;
    align-items: center;
    gap: 0.45em;
    min-height: 2.25rem;
    padding: 0.3em 1.05em;
    border: 0;
    border-radius: var(--r-pill);
    background: var(--_ghost), rgba(255, 255, 255, 0.55);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    box-shadow: inset 0 0 0 2px var(--_ink);
    outline: var(--glass-outline);
    color: var(--_ink);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-spring), color var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-chip[aria-pressed="true"],
.desktop-surface .k-chip.is-on,
.desktop-surface .k-chip:active {
    background: var(--_fill);
    box-shadow: 0 0.3rem 0.75rem var(--_glow);
    color: var(--_on);
}

.desktop-surface .k-chip:active { transform: scale(0.96); transition-duration: var(--dur-press); }
.desktop-surface .k-chip:focus-visible { outline: 3px solid #fff; box-shadow: 0 0 0 6px var(--_ink); }

.desktop-surface .k-chip-count {
    font-family: var(--font-text);
    opacity: 0.9;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-chip:hover { transform: translateY(-2px); }
}

.desktop-surface .k-pill {
    display: inline-flex;
    align-items: baseline;
    gap: 0.3em;
    padding: 0.2em 0.6em;
    border-radius: 2rem;
    background: var(--glass-bg-dark);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    color: #fff;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.25;
    white-space: nowrap;
}

.desktop-surface .k-pill small {
    font-family: var(--font-text);
    font-size: 1em;
    font-weight: normal;
    opacity: 0.92;
}

.desktop-surface .k-pill--light {
    background: #fff;
    color: var(--text);
    box-shadow: 0 0.2rem 0.6rem rgba(0, 0, 0, 0.18);
}

.desktop-surface .k-pill--tone {
    background: var(--tone-dk, var(--rt-purple-dk));
}

.desktop-surface .k-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35em;
    padding: 0.18em 0.5em;
    border-radius: var(--r-badge);
    background: var(--tone-fill, var(--fill-blue));
    color: var(--tone-on, #fff);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.2;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    white-space: nowrap;
}

.desktop-surface .k-badge--soft {
    background: var(--tone-slt, var(--rt-blue-slt));
    color: var(--tone-deep, var(--rt-blue-bl));   /* the family's darkest step on its own wash: 7:1 or better */
}

.desktop-surface .k-badge--plain {
    text-transform: none;
    letter-spacing: 0;
}

.desktop-surface .k-status {
    --_dot: var(--tone, var(--rt-success));
    display: inline-flex;
    align-items: center;
    gap: 0.45em;
    padding: 0.2em 0.6em;
    border-radius: 0.4rem;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-ctl);
    color: var(--text);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.25;
    white-space: nowrap;
}

.desktop-surface .k-status::before {
    content: "";
    flex: none;
    width: 0.65em;
    height: 0.65em;
    border-radius: 50%;
    background: var(--_dot);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--_dot) 25%, transparent);
}

.desktop-surface .k-status--live::before { animation: k-pulse 1.8s var(--ease-out) infinite; }


/* ─── 9. ROWS ─────────────────────────────────────────────────────────────── */
/* The "door": an icon, what it opens, a chevron (.category-item). On a
   desktop a door opens the lane to its right, so the chevron leans that way
   under the pointer and the open door stays marked (aria-current). Use an
   <a>, or a <button> for a lane change with no URL of its own. */

.desktop-surface .k-rows {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 0;
    list-style: none;
}

.desktop-surface .k-row {
    display: flex;
    align-items: center;
    gap: var(--space-sm) var(--space-md);
    width: 100%;
    padding: var(--space-md) var(--pad-panel);
    border: 0;
    border-top: 1px solid var(--glass-rule);
    background: none;
    color: var(--rt-slate);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.25;
    text-align: left;
    text-decoration: none;
    cursor: pointer;
    transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-row-icon {
    display: inline-grid;
    place-items: center;
    width: 1.75rem;
    color: var(--tone, var(--rt-blue));
    font-size: 1.1em;
}

.desktop-surface .k-row-main { flex: 1 1 auto; min-width: 0; display: grid; gap: 0.1rem; }
.desktop-surface .k-row > :not(.k-row-main) { flex: none; }
/* The label wraps rather than cut: a door's name is never truncated */
.desktop-surface .k-row-title { overflow-wrap: anywhere; }

.desktop-surface .k-row-sub {
    font-family: var(--font-text);
    font-size: var(--type-meta);
    color: var(--text-soft);
}

.desktop-surface .k-row-meta {
    font-family: var(--font-text);
    font-size: var(--type-meta);
    color: var(--text-faint);
    white-space: nowrap;
}

.desktop-surface .k-row-chev {
    color: var(--rt-slate);
    font-size: 0.95em;
    transition: transform var(--dur-base) var(--ease-out);
}

.desktop-surface .k-row[aria-current="true"],
.desktop-surface .k-row.is-on {
    background: linear-gradient(90deg, var(--rt-blue-slt), rgba(224, 237, 255, 0));
    color: var(--ink-blue);
    box-shadow: inset 4px 0 0 var(--rt-blue);
}

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

.desktop-surface .k-row:active { background: var(--rt-blue-slt); }

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-row:hover { background: rgba(224, 237, 255, 0.6); color: var(--rt-blue-dk); }
    .desktop-surface .k-row:hover .k-row-chev { transform: translateX(0.3rem); }
}

/* A narrow lane drops the trailing note, never the label */
@container lane (width < 22rem) {
    .desktop-surface .k-row-meta { display: none; }
}


/* ─── 10. FORM CONTROLS ───────────────────────────────────────────────────── */
/* White glass with a 2px edge that turns blue and glows on focus. Labels are
   halbfett in ink, sentence case (never the tracked caps of the old desktop).
   .k-field wraps label + control + hint or error. */

.desktop-surface .k-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr));
    gap: var(--space-md);
    align-items: start;
}

.desktop-surface .k-field {
    display: grid;
    gap: 0.4rem;
    min-width: 0;
    align-content: start;
}

.desktop-surface .k-field--wide { grid-column: 1 / -1; }

.desktop-surface .k-label {
    display: block;
    margin: 0;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.25;
    color: var(--text);
}

.desktop-surface .k-hint,
.desktop-surface .k-error {
    margin: 0;
    font-size: var(--type-meta);
    line-height: 1.35;
    color: var(--text-soft);
}

.desktop-surface .k-error { color: var(--rt-crimson); font-family: var(--font-head); }

.desktop-surface .k-input,
.desktop-surface .k-select,
.desktop-surface .k-textarea {
    display: block;
    width: 100%;
    min-width: 0;
    min-height: 3rem;
    padding: 0.65em 1em;
    border: 2px solid rgba(30, 40, 53, 0.14);
    border-radius: var(--r-ctl);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-ctl);
    color: var(--text);
    font-family: var(--font-text);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.3;
    outline: none;
    transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-textarea { min-height: 6.5rem; line-height: 1.5; resize: vertical; }

.desktop-surface .k-input::placeholder,
.desktop-surface .k-textarea::placeholder { color: var(--text-faint); opacity: 1; }

.desktop-surface .k-input:focus,
.desktop-surface .k-select:focus,
.desktop-surface .k-textarea:focus {
    border-color: var(--rt-blue);
    box-shadow: 0 0 0 4px rgba(44, 117, 222, 0.2);
}

.desktop-surface .k-input[aria-invalid="true"],
.desktop-surface .k-select[aria-invalid="true"],
.desktop-surface .k-textarea[aria-invalid="true"] {
    border-color: var(--rt-crimson);
    box-shadow: 0 0 0 4px rgba(167, 58, 84, 0.14);
}

.desktop-surface .k-input:disabled,
.desktop-surface .k-select:disabled,
.desktop-surface .k-textarea:disabled {
    background: rgba(240, 243, 246, 0.9);
    color: var(--text-faint);
    cursor: not-allowed;
}

/* The Ask pill: the Hoku and search input (Home's #Text-Input). An icon at
   the left, glass, fully round. Wrap an .k-input in .k-ask. */
.desktop-surface .k-ask {
    position: relative;
    display: flex;
    align-items: center;
    min-width: 0;
}

.desktop-surface .k-ask > .k-ask-icon {
    position: absolute;
    z-index: 1;   /* the input's backdrop-filter makes it a stacking context */
    left: 1.1rem;
    color: var(--text);
    font-size: 1.15rem;
    pointer-events: none;
}

.desktop-surface .k-ask > .k-input {
    min-height: clamp(3.25rem, 2.9rem + 1cqi, 4rem);
    padding-left: 3.1rem;
    border-radius: var(--r-pill);
    border-color: rgba(255, 255, 255, 0.55);
    background: var(--glass-bg);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    box-shadow: var(--shadow-cont-sm-lt);
    font-family: var(--font-head);
    font-size: var(--type-lead);
    text-overflow: ellipsis;
}

/* A <textarea class="k-input"> in .k-ask grows with what is typed and lets a
   long prompt wrap to two lines (the phone's glass pill), never cut mid-word. */
.desktop-surface .k-ask > textarea.k-input {
    field-sizing: content;
    min-height: clamp(3.25rem, 2.9rem + 1cqi, 4rem);
    max-height: 9rem;
    padding-block: 0.85em;
    border-radius: 1.75rem;
    line-height: 1.3;
    resize: none;
}

.desktop-surface .k-ask > .k-input::placeholder { text-overflow: ellipsis; }

/* The round search / send button at the end of the pill, and the clear x */
.desktop-surface .k-ask > .k-ask-go {
    position: absolute;
    z-index: 1;
    right: 0.45rem;
    bottom: 0.45rem;
    width: 2.6rem;
    height: 2.6rem;
    box-shadow: 0 0.3rem 0.75rem var(--glow-pink);
}

.desktop-surface .k-ask:has(> .k-ask-go) > .k-input { padding-right: 3.6rem; }

@container lane (width < 26rem) {
    .desktop-surface .k-ask > .k-input { font-size: var(--type-body); }
}

.desktop-surface .k-ask > .k-input:focus {
    border-color: var(--rt-blue);
    box-shadow: 0 0 0 4px rgba(44, 117, 222, 0.22), var(--shadow-cont-sm-lt);
}

/* Select: the native control, our chevron */
.desktop-surface .k-select {
    -webkit-appearance: none;
    appearance: none;
    padding-right: 2.6em;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%231E2835' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") right 1em center / 0.75em auto no-repeat,
        rgba(255, 255, 255, 0.92);
    cursor: pointer;
}

/* Stepper: Quantity, Adults (Details' quantity pill) */
.desktop-surface .k-stepper {
    display: grid;
    grid-template-columns: auto minmax(2.5rem, 1fr) auto;
    align-items: center;
    width: 100%;
    max-width: 20rem;
    min-height: 3rem;
    padding: 0.2rem;
    border: 2px solid rgba(30, 40, 53, 0.14);
    border-radius: var(--r-pill);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-ctl);
}

.desktop-surface .k-stepper-btn {
    display: grid;
    place-items: center;
    width: 2.6rem;
    height: 2.6rem;
    border: 0;
    border-radius: 50%;
    background: none;
    color: var(--text);
    font-size: 0.95rem;
    cursor: pointer;
    transition: background var(--dur-fast) var(--ease-out), transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .k-stepper-btn:active { transform: scale(0.88); transition-duration: var(--dur-press); }
.desktop-surface .k-stepper-btn:focus-visible { outline: 3px solid var(--rt-purple); outline-offset: -2px; }
.desktop-surface .k-stepper-btn:disabled { color: #B9C0C9; cursor: not-allowed; }

.desktop-surface .k-stepper-val {
    text-align: center;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-section);
    line-height: 1;
    color: var(--rt-purple-deep);
    font-variant-numeric: tabular-nums;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .k-stepper-btn:not(:disabled):hover { background: var(--rt-purple-slt); }
}

/* Segmented switch (.kb-seg): one of a few. The chosen side is the dark fill. */
.desktop-surface .k-seg {
    --_fill: var(--tone-fill, var(--fill-navy));
    --_glow: var(--tone-glow, var(--glow-navy));
    display: flex;
    gap: 4px;
    min-width: 0;
    padding: 4px;
    border-radius: 2rem;
    background: var(--glass-bg);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
}

.desktop-surface .k-seg-btn {
    flex: 1 1 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45em;
    min-width: 0;
    min-height: 2.5rem;
    padding: 0.35em 0.9em;
    border: 0;
    border-radius: 2rem;
    background: none;
    color: #5A6474;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.15;
    white-space: nowrap;
    cursor: pointer;
    transition: color var(--dur-fast) var(--ease-out), transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .k-seg-btn[aria-pressed="true"],
.desktop-surface .k-seg-btn.is-on {
    background: var(--_fill);
    box-shadow: 0 0.25rem 0.6rem var(--_glow);
    color: var(--tone-on, #fff);
}

.desktop-surface .k-seg-btn:active { transform: scale(0.96); transition-duration: var(--dur-press); }
.desktop-surface .k-seg-btn:focus-visible { outline: 3px solid var(--rt-blue); outline-offset: 1px; }

.desktop-surface .k-seg--sm .k-seg-btn { min-height: 2rem; padding: 0.25em 0.7em; }

/* Range (.rt-ss): the native control, a filled track. JS writes --k-pct. */
.desktop-surface .k-range {
    --k-pct: 50%;
    -webkit-appearance: none;
    appearance: none;
    display: block;
    width: 100%;
    height: 1.75rem;
    margin: 0;
    background: none;
    cursor: pointer;
}

.desktop-surface .k-range::-webkit-slider-runnable-track {
    height: 0.5rem;
    border-radius: 1rem;
    background:
        linear-gradient(to right, var(--rt-blue-lt), var(--rt-blue)) 0 0 / var(--k-pct) 100% no-repeat,
        #D5DAE1;
}

.desktop-surface .k-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 1.6rem;
    height: 1.6rem;
    margin-top: -0.55rem;
    border: 2px solid var(--rt-blue);
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(21, 56, 105, 0.3);
    transition: transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .k-range:active::-webkit-slider-thumb { transform: scale(1.15); }

.desktop-surface .k-range::-moz-range-track {
    height: 0.5rem;
    border-radius: 1rem;
    background: #E5E7EB;
}

.desktop-surface .k-range::-moz-range-progress {
    height: 0.5rem;
    border-radius: 1rem;
    background: linear-gradient(to right, var(--rt-blue-lt), var(--rt-blue));
}

.desktop-surface .k-range::-moz-range-thumb {
    width: 1.4rem;
    height: 1.4rem;
    border: 2px solid var(--rt-blue);
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(21, 56, 105, 0.3);
}

.desktop-surface .k-range:focus-visible { outline: 3px solid var(--rt-blue); outline-offset: 4px; border-radius: 1rem; }

.desktop-surface .k-range-row {
    display: flex;
    align-items: center;
    gap: var(--space-md);
}

.desktop-surface .k-range-val {
    flex: none;
    min-width: 4.5rem;
    text-align: right;
    font-family: var(--font-head);
    font-size: var(--type-body);
    color: var(--ink-blue);
    font-variant-numeric: tabular-nums;
}

/* Checkbox, radio, switch: a real input, hidden, and a drawn box after it */
.desktop-surface .k-check,
.desktop-surface .k-switch {
    --_fill: var(--tone-fill, var(--fill-blue));
    --_glow: var(--tone-glow, var(--glow-blue));
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    margin: 0;
    font-family: var(--font-text);
    font-size: var(--type-body);
    line-height: 1.3;
    color: var(--text);
    cursor: pointer;
}

.desktop-surface .k-check > input,
.desktop-surface .k-switch > input {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
}

.desktop-surface .k-check-box {
    flex: none;
    display: grid;
    place-items: center;
    width: 1.5rem;
    height: 1.5rem;
    border: 2px solid rgba(30, 40, 53, 0.28);
    border-radius: 0.45rem;
    background: #fff;
    transition: background var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-check-box::after {
    content: "";
    width: 0.4rem;
    height: 0.75rem;
    margin-top: -0.15rem;
    border: solid #fff;
    border-width: 0 0.17rem 0.17rem 0;
    transform: rotate(45deg) scale(0);
    transition: transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .k-check > input:checked + .k-check-box {
    border-color: transparent;
    background: var(--_fill);
    box-shadow: 0 0.2rem 0.5rem var(--_glow);
}

.desktop-surface .k-check > input:checked + .k-check-box::after { transform: rotate(45deg) scale(1); }

.desktop-surface .k-check--radio .k-check-box { border-radius: 50%; }

.desktop-surface .k-check--radio .k-check-box::after {
    width: 0.6rem;
    height: 0.6rem;
    margin: 0;
    border: 0;
    border-radius: 50%;
    background: #fff;
    transform: scale(0);
}

.desktop-surface .k-check--radio > input:checked + .k-check-box::after { transform: scale(1); }

.desktop-surface .k-check > input:focus-visible + .k-check-box,
.desktop-surface .k-switch > input:focus-visible + .k-switch-track {
    outline: 3px solid var(--rt-blue);
    outline-offset: 2px;
}

.desktop-surface .k-switch-track {
    flex: none;
    position: relative;
    width: 3rem;
    height: 1.75rem;
    border-radius: 2rem;
    background: #C9D1DA;
    transition: background var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-switch-track::after {
    content: "";
    position: absolute;
    top: 0.2rem;
    left: 0.2rem;
    width: 1.35rem;
    height: 1.35rem;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3);
    transition: transform var(--dur-base) var(--ease-out);
}

.desktop-surface .k-switch { --_fill: var(--tone-fill, var(--fill-green)); }
.desktop-surface .k-switch > input:checked + .k-switch-track { background: var(--_fill); }
.desktop-surface .k-switch > input:checked + .k-switch-track::after { transform: translateX(1.25rem); }

.desktop-surface .k-checks {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm) var(--space-lg);
}

/* Phone: a skin over libs/intlTel (it wraps the input in .iti). The country
   list is a menu anchored under its own field, which the no-overlay rule
   allows. Put .k-phone on the wrapper and .k-input on the input. */
.desktop-surface .k-phone .iti { display: block; width: 100%; }

.desktop-surface .k-phone .iti__selected-flag {
    padding: 0 0.6rem 0 1rem;
    border-radius: var(--r-ctl) 0 0 var(--r-ctl);
    background: none;
}

.desktop-surface .k-phone .iti__selected-dial-code {
    font-family: var(--font-head);
    font-size: var(--type-body);
    color: var(--text);
}

.desktop-surface .k-phone .iti__arrow { border-top-color: var(--text-soft); }
.desktop-surface .k-phone .iti__arrow--up { border-bottom-color: var(--text-soft); }

.desktop-surface .k-phone .iti__dropdown-content {
    margin-top: 0.4rem;
    border: 0;
    border-radius: var(--r-ctl);
    background: #fff;
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
    overflow: hidden;
}

.desktop-surface .k-phone .iti__search-input {
    width: 100%;
    padding: 0.7em 1em;
    border: 0;
    border-bottom: 1px solid var(--glass-rule);
    font-family: var(--font-text);
    font-size: var(--type-body);
    outline: none;
}

.desktop-surface .k-phone .iti__country-list {
    max-width: 100%;
    border-radius: var(--r-ctl);   /* the menu's own corner, so its scroll track never squares it */
    font-family: var(--font-text);
    font-size: var(--type-body);
    color: var(--text);
    white-space: normal;
}

.desktop-surface .k-phone .iti__country { padding: 0.55rem 1rem; }
.desktop-surface .k-phone .iti__country.iti__highlight { background: var(--rt-blue-slt); }
.desktop-surface .k-phone .iti__dial-code { color: var(--text-soft); }


/* ─── 11. KEEPER, PRICE LINES, ALERT, EMPTY STATE ─────────────────────────── */
/* .k-avatar: a round photo with the white ring. Size with --k-size.
   .k-keeper: every listing comes with its person ("Meet your local Keeper").
   .k-price + .k-lines: the money in the open, beside the button.
   .k-alert: an inline notice (.alertBox). Never a toast.
   .k-empty: nothing here yet, and what to do about it. */

.desktop-surface .k-avatar {
    --k-size: 3.25rem;
    flex: none;
    display: block;
    width: var(--k-size);
    height: var(--k-size);
    border-radius: 50%;
    background: #fff center / cover no-repeat;
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
    object-fit: cover;
}

.desktop-surface .k-keeper {
    display: grid;
    gap: var(--space-md);
    padding: var(--pad-panel);
    border-radius: var(--r-panel);
    background: linear-gradient(160deg, rgba(224, 237, 255, 0.95), rgba(232, 223, 255, 0.8));
    outline: var(--glass-outline);
}

.desktop-surface .k-keeper-who {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    min-width: 0;
}

.desktop-surface .k-keeper-id { min-width: 0; display: grid; gap: 0.3rem; }

.desktop-surface .k-keeper-name {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.25rem 0.6rem;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-lead);
    line-height: 1.2;
    color: var(--text);
    margin: 0;
}

.desktop-surface .k-keeper-acts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr));
    gap: var(--space-sm);
}

/* The Keeper's two doors are real buttons: 40px or more, 15px or more */
.desktop-surface .k-keeper-acts > .k-btn {
    min-height: 2.75rem;
    padding-inline: 1em;
    font-size: max(0.9375rem, var(--type-meta));
}

.desktop-surface .k-price {
    display: inline-flex;
    align-items: baseline;
    gap: 0.12em;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: clamp(2.375rem, 1.9rem + 2.2cqi, 3.5rem);   /* the money in the open: the strongest thing in its block */
    line-height: 1;
    letter-spacing: var(--track-tight);
    color: var(--text);
    white-space: nowrap;
}

.desktop-surface .k-price > sup {
    top: 0;
    align-self: flex-start;
    margin-top: 0.15em;
    font-family: var(--font-head);
    font-size: 0.42em;
    letter-spacing: 0;
    color: var(--text);
}

.desktop-surface .k-price > small {
    margin-left: 0.4em;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: max(0.36em, var(--type-meta));
    letter-spacing: 0;
    color: var(--text-soft);
}

.desktop-surface .k-lines { display: grid; margin: 0; }

.desktop-surface .k-line {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--space-md);
    padding: 0.5rem 0;
    font-size: var(--type-body);
    line-height: 1.35;
    color: var(--text);
}

.desktop-surface .k-line > dt,
.desktop-surface .k-line > .k-line-label {
    font-family: var(--font-text);
    font-weight: normal;
    color: var(--text-soft);
    min-width: 0;
}

.desktop-surface .k-line > dd,
.desktop-surface .k-line > .k-line-amt {
    margin: 0;
    font-family: var(--font-head);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.desktop-surface .k-line--total {
    margin-top: 0.35rem;
    padding-top: 0.85rem;
    border-top: 1px solid var(--line);
    font-size: var(--type-lead);
}

.desktop-surface .k-line--total > dt,
.desktop-surface .k-line--total > .k-line-label {
    font-family: var(--font-head);
    letter-spacing: var(--track-snug);
    color: var(--text);
}

.desktop-surface .k-line--total > dd,
.desktop-surface .k-line--total > .k-line-amt {
    font-family: var(--font-head);
    font-size: 1.25em;
    letter-spacing: var(--track-snug);
}

.desktop-surface .k-alert {
    --_ink: var(--tone-ink, var(--ink-blue));
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    padding: var(--space-md) var(--pad-panel);
    border-radius: var(--r-ctl);
    background: var(--tone-slt, var(--rt-blue-slt));
    box-shadow: inset 4px 0 0 var(--tone, var(--rt-blue));
    color: var(--text);
    font-size: var(--type-body);
    line-height: 1.4;
}

.desktop-surface .k-alert > :is(i, svg) {
    flex: none;
    margin-top: 0.15em;
    color: var(--_ink);
    font-size: 1.2em;
}

.desktop-surface .k-alert > div > * { margin: 0; }

.desktop-surface .k-empty {
    display: grid;
    justify-items: center;
    gap: var(--space-md);
    padding: var(--space-xl) var(--pad-panel);
    text-align: center;
}

.desktop-surface .k-empty-art {
    display: grid;
    place-items: center;
    width: clamp(6.5rem, 5rem + 6cqi, 9rem);
    aspect-ratio: 1 / 1.2;
    margin-bottom: var(--space-sm);
    border-radius: var(--r-card);
    background: var(--tone-tilt, var(--tilt-pink));
    outline: 2px solid var(--tone-lt, var(--rt-pink-lt));
    box-shadow: var(--shadow-cont-sm);
    color: color-mix(in srgb, var(--tone-dk, var(--rt-pink-dk)) 70%, transparent);
    font-size: clamp(2.5rem, 1.9rem + 2.5cqi, 3.5rem);
    transform: rotate(-4deg);
}

.desktop-surface .k-empty > .k-meta,
.desktop-surface .k-empty > .k-body { max-width: 34ch; }


/* ─── 12. METER ───────────────────────────────────────────────────────────── */
/* A thin progress bar: the checklist head, the Race to 100 rows. Set --k-val
   (a percentage) inline. On a tone it fills in that tone; --on-dark for a
   white-on-colour head. */

.desktop-surface .k-meter {
    --k-val: 0%;
    --_fill: var(--tone-fill, var(--fill-blue));
    display: block;
    width: 100%;
    height: 0.45rem;
    border-radius: 1rem;
    background: rgba(30, 40, 53, 0.1);
    overflow: hidden;
}

/* The bar is the full track, slid left by what is missing: a change of value
   moves a transform, so nothing lays out while it animates. The track clips
   it; max() keeps a small dot showing at zero. */
.desktop-surface .k-meter::before {
    content: "";
    display: block;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: var(--_fill);
    transform: translateX(calc(max(var(--k-val), 0.45rem) - 100%));
    transition: transform var(--dur-slow) var(--ease-out);
}

.desktop-surface .k-meter--on-dark { background: rgba(255, 255, 255, 0.18); }
.desktop-surface .k-meter--on-dark:not([class*="k-tone-"]) { --_fill: #fff; }

/* The race: name, bar, count. The count never wraps; the name gives way. */
/* One grid for the whole race, each row a subgrid: the names share a column
   as wide as the longest (up to a cap), so every bar starts on the same line. */
.desktop-surface .k-race {
    display: grid;
    grid-template-columns: minmax(0, max-content) minmax(5.5rem, 1fr) auto;
    gap: var(--space-sm) var(--space-md);
    margin: 0;
    padding: 0;
    list-style: none;
}

.desktop-surface .k-race-row {
    display: grid;
    grid-column: 1 / -1;
    grid-template-columns: subgrid;
    align-items: center;
    font-size: var(--type-body);
}

.desktop-surface .k-race-name {
    max-inline-size: clamp(4.5rem, 32cqi, 12rem);
    font-family: var(--font-head);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.desktop-surface .k-race-count {
    font-family: var(--font-head);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.desktop-surface .k-race-count > small {
    font-family: var(--font-text);
    font-size: 1em;
    opacity: 0.85;
}


/* ─── 13. DISCLOSURE ──────────────────────────────────────────────────────── */
/* The replacement for every modal and popover: it opens IN PLACE and pushes
   what is under it down. Two forms, same look:
     <details class="k-disclosure"><summary class="k-disclosure-sum">…</summary>
         <div class="k-disclosure-body">…</div></details>
       No script. Opens with the keyboard. Where the browser exposes
       ::details-content the body grows as a grid row (0fr to 1fr), the same
       way .k-reveal does; elsewhere it unfolds in place (transform, opacity).
     <div class="k-reveal" data-open> <div class="k-reveal-body">…</div></div>
       For a body opened by a control somewhere else (the Book button): the
       script toggles the data-open attribute and aria-expanded on its control. */

.desktop-surface .k-disclosure { min-width: 0; }

.desktop-surface .k-disclosure-sum {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    padding: 0.4rem 0;
    list-style: none;
    color: var(--ink-blue);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    line-height: 1.25;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
}

.desktop-surface .k-disclosure-sum::-webkit-details-marker { display: none; }
.desktop-surface .k-disclosure-sum::marker { content: ""; }

.desktop-surface .k-disclosure-sum:focus-visible {
    outline: 3px solid var(--rt-blue);
    outline-offset: 3px;
    border-radius: 0.4rem;
}

.desktop-surface .k-disclosure-chev {
    flex: none;
    font-size: 0.85em;
    transition: transform var(--dur-base) var(--ease-out);
}

.desktop-surface .k-disclosure[open] > .k-disclosure-sum .k-disclosure-chev { transform: rotate(90deg); }

.desktop-surface .k-disclosure::details-content {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows var(--dur-slow) var(--ease-out), content-visibility var(--dur-slow) allow-discrete;
}

.desktop-surface .k-disclosure[open]::details-content { grid-template-rows: 1fr; }

.desktop-surface .k-disclosure[open] > .k-disclosure-body {
    animation: k-unfold var(--dur-base) var(--ease-out) both;
}

/* No padding on the body itself: a grid item cannot be shorter than its own
   padding, and the closed row has to reach zero. */
.desktop-surface .k-disclosure-body {
    min-height: 0;
    overflow: hidden;
}

.desktop-surface .k-disclosure-body::before,
.desktop-surface .k-disclosure-body::after {
    content: "";
    display: block;
    height: var(--space-xs);
}

.desktop-surface .k-reveal {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows var(--dur-slow) var(--ease-out);
}

.desktop-surface .k-reveal[data-open] { grid-template-rows: 1fr; }

.desktop-surface .k-reveal-body {
    min-height: 0;
    overflow: hidden;
    visibility: hidden;
    transition: visibility 0s linear var(--dur-slow);
}

.desktop-surface .k-reveal[data-open] > .k-reveal-body {
    visibility: visible;
    transition-delay: 0s;
}


/* ─── 14. LANE PROGRESS, ARRIVAL, THE SPINE ───────────────────────────────────────── */
/* Progress: the stage manager sets aria-busy="true" on a .lane while its next
   page loads; the old content stays and a line runs along the lane's top
   edge. Drawn on the lane BODY (the scroller) as a sticky first box, so it
   holds the top at any scroll position without the lane being positioned.
   Works for any [aria-busy="true"] parent of a .lane-body.

   Arrival: .k-arrive on a container makes its children rise into place one
   after another (--arrive-step apart). The first twelve are counted here;
   past that, script may write --i inline. Add the class when content lands
   and remove it on animationend if the same nodes will arrive again. */

.desktop-surface [aria-busy="true"] > .lane-body::before {
    content: "";
    position: sticky;
    z-index: 6;
    top: 0;
    display: block;
    height: 3px;
    margin-bottom: -3px;
    border-radius: 3px;
    background:
        linear-gradient(90deg, transparent 0%, var(--rt-teal) 25%, var(--rt-blue) 50%, var(--rt-pink) 75%, transparent 100%)
        0 0 / 45% 100% no-repeat;
    animation: k-lane-progress 1.15s var(--ease-house) infinite;
    pointer-events: none;
}

.desktop-surface [aria-busy="true"] > .lane-body > :not(.k-demo-lanehead) {
    opacity: 0.6;
    transition: opacity var(--dur-base) var(--ease-out);
}

.desktop-surface .k-arrive > * {
    animation: k-arrive var(--dur-slow) var(--ease-out) both;
    animation-delay: calc(var(--i, 0) * var(--arrive-step));
}

.desktop-surface .k-arrive > :nth-child(1)  { --i: 0; }
.desktop-surface .k-arrive > :nth-child(2)  { --i: 1; }
.desktop-surface .k-arrive > :nth-child(3)  { --i: 2; }
.desktop-surface .k-arrive > :nth-child(4)  { --i: 3; }
.desktop-surface .k-arrive > :nth-child(5)  { --i: 4; }
.desktop-surface .k-arrive > :nth-child(6)  { --i: 5; }
.desktop-surface .k-arrive > :nth-child(7)  { --i: 6; }
.desktop-surface .k-arrive > :nth-child(8)  { --i: 7; }
.desktop-surface .k-arrive > :nth-child(9)  { --i: 8; }
.desktop-surface .k-arrive > :nth-child(10) { --i: 9; }
.desktop-surface .k-arrive > :nth-child(11) { --i: 10; }
.desktop-surface .k-arrive > :nth-child(n + 12) { --i: 11; }

@keyframes k-arrive {
    from { opacity: 0; transform: translateY(1.1rem) scale(0.97); }
    to   { opacity: 1; transform: none; }
}

@keyframes k-unfold {
    from { opacity: 0; transform: translateY(-0.4rem); }
    to   { opacity: 1; transform: none; }
}

@keyframes k-lane-progress {
    from { background-position: -80% 0; }
    to   { background-position: 180% 0; }
}

@keyframes k-spin {
    to { transform: rotate(360deg); }
}

@keyframes k-pulse {
    0%   { box-shadow: 0 0 0 0 color-mix(in srgb, var(--_dot) 55%, transparent); }
    100% { box-shadow: 0 0 0 0.5rem color-mix(in srgb, var(--_dot) 0%, transparent); }
}


/* The Spine. lanes.css builds it and leaves the dress to the kit. Its DOM
   (app.js): .lane[data-lane][data-w="spine"][data-spine="strip" | "live"] >
   button.lane-spine > .lane-spine-thumb, .lane-spine-name, .lane-spine-title,
   .lane-spine-count.
   Two forms:
     strip   the button is the whole lane: the head, the lane's current item
             as a thumbnail, its title, a count.
     live    the lane's own board stays on screen under the head as a
             filmstrip (kit-card.css, strip form), still clickable.
   The dress gives both the same HEAD, top to bottom:
     1  a return control: a pink disc with a chevron pointing back (the whole
        strip is the button; app.js labels it "Back to {title}")
     2  the lane's own icon (search, results, a listing, an action)
     3  the title, running up the strip at 14px or more, IN FULL: the head is
        as tall as its text and is only cut if it would pass three fifths of
        the lane
     4  the count, a pink pill
   For that the live form's head stops being a fixed-height grip: the lane
   becomes a column, the head takes what its text needs, the filmstrip takes
   the rest. (That re-lays two of lanes.css's boxes from here; see the unit's
   report.) .lane-spine-name (the lane's own name, when the title says
   something else) is the small caps line above the title. */

.desktop-surface .lane-spine {
    gap: 0.6rem;
    padding: 0.55rem 0 0.7rem;
    background: var(--glass-bg-soft);
    -webkit-backdrop-filter: var(--glass-blur);
    backdrop-filter: var(--glass-blur);
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.7);
    border-radius: var(--r-panel);
    color: var(--text);
    font-family: var(--font-head);
}

/* 1: the return control */
.desktop-surface :is(.lane, .k-scene-lane)[data-w="spine"] > .lane-spine::before {
    content: "";
    order: -3;
    flex: none;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 16'%3E%3Cpath d='M8 2L2 8l6 6' fill='none' stroke='%23fff' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 45% 50% / 0.55rem auto no-repeat,
        var(--fill-pink);
    box-shadow: 0 0.3rem 0.7rem var(--glow-pink), 0 0 0 2px rgba(255, 255, 255, 0.7);
    opacity: 1;
    transition: transform var(--dur-base) var(--ease-spring);
}

/* 2: the lane's icon */
.desktop-surface :is(.lane, .k-scene-lane)[data-w="spine"] > .lane-spine::after {
    content: "";
    order: -2;
    flex: none;
    width: 1.2rem;
    height: 1.2rem;
    background: var(--ink-pink);
    -webkit-mask: var(--_lane-icon) center / contain no-repeat;
    mask: var(--_lane-icon) center / contain no-repeat;
}

.desktop-surface :is(.lane, .k-scene-lane)[data-lane="ask"] {
    --_lane-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='10.5' cy='10.5' r='7' fill='none' stroke='%23000' stroke-width='2.6'/%3E%3Cpath d='M16 16l5.5 5.5' stroke='%23000' stroke-width='2.8' stroke-linecap='round'/%3E%3C/svg%3E");
}

.desktop-surface :is(.lane, .k-scene-lane)[data-lane="browse"] {
    --_lane-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Crect x='3' y='3' width='7.5' height='7.5' rx='2'/%3E%3Crect x='13.5' y='3' width='7.5' height='7.5' rx='2'/%3E%3Crect x='3' y='13.5' width='7.5' height='7.5' rx='2'/%3E%3Crect x='13.5' y='13.5' width='7.5' height='7.5' rx='2'/%3E%3C/svg%3E");
}

.desktop-surface :is(.lane, .k-scene-lane)[data-lane="focus"] {
    --_lane-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 3h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2zm1 14h12l-4-6-3 4-2-2.500z'/%3E%3C/svg%3E");
}

.desktop-surface :is(.lane, .k-scene-lane)[data-lane="act"] {
    --_lane-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zm5.200 7.700-6 6.300a1.200 1.200 0 0 1-1.700 0l-2.700-2.800 1.700-1.700 1.850 1.900 5.150-5.400z'/%3E%3C/svg%3E");
}

.desktop-surface .lane-spine-thumb {
    outline: var(--glass-outline);
    box-shadow: var(--shadow-cont-sm-lt);
    background: var(--tilt-pink);
}

/* 3: the title, in full */
.desktop-surface .lane-spine-name {
    flex: none;
    writing-mode: vertical-rl;
    rotate: 180deg;
    font-family: var(--font-head);
    font-size: calc(0.8125rem + var(--up));
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-soft);
}

.desktop-surface .lane-spine-name:empty { display: none; }

.desktop-surface .lane-spine-title {
    flex: 0 1 auto;
    font-family: var(--font-head);
    font-size: calc(max(0.875rem, min(26cqi, 1.0625rem)) + var(--up));
    letter-spacing: 0;
}

/* 4: the count */
.desktop-surface .lane-spine-count {
    background: var(--fill-pink);
    box-shadow: 0 0.2rem 0.5rem var(--glow-pink);
    font-family: var(--font-head);
    font-size: calc(0.8125rem + var(--up));
}

.desktop-surface .lane-spine:hover,
.desktop-surface .lane-spine:focus-visible { background: var(--glass-bg); }

.desktop-surface .lane-spine:hover::before { transform: translateX(-2px) scale(1.06); }

/* The live form: a column, the head as tall as its text, the filmstrip under it */
.desktop-surface .lane[data-w="spine"][data-spine="live"] {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.desktop-surface .lane[data-w="spine"][data-spine="live"] > .lane-spine {
    position: relative;
    inset: auto;
    flex: 0 0 auto;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0.6rem;
    height: auto;
    max-height: 60%;
    padding: 0.55rem 0 0.7rem;
}

.desktop-surface .lane[data-w="spine"][data-spine="live"] > .lane-spine > .lane-spine-name,
.desktop-surface .lane[data-w="spine"][data-spine="live"] > .lane-spine > .lane-spine-title { display: block; }

.desktop-surface .lane[data-w="spine"][data-spine="live"] > .lane-body {
    position: relative;
    inset: auto;
    flex: 1 1 0;
    width: auto;
    min-height: 0;
}

@media (prefers-reduced-motion: reduce) {
    .desktop-surface .lane-spine:hover::before { transform: none; }
}


/* ─── 14b. PARTS FOR THE SLICE ────────────────────────────────────────────── */
/* What the seeker slice is built from, each ported from the phone's own part
   and each fluid in its lane. See them in lanes at /{territory}/Dev-Parts/.

     Ask      .k-hero (greeting, Hoku line, ask input, doors)
              .k-filters > .k-filter; .k-days > .k-day; .k-who; .k-stepper--sm
     Browse   .k-shelf (a titled one-row shelf); .k-onerow; .k-idcard
     Focus    .k-split (+ -main, -corner); .k-mosaic; .k-titleblock; .k-facts;
              .k-story > .k-story-sec; .k-reviews; .k-ring; .k-review; .k-buy
     Act      .k-pick; .k-slots; .k-choices > .k-choice; .k-gate; .k-code;
              .k-state (success, error, empty: the same block as .k-empty)
     Loading  .k-skel (+ --line, --title, --photo, --pill, --circle);
              .k-skel-card; .k-skel-row */

/* ── The Ask block: Home's hero. A greeting, Hoku's line, the ask input and
      the doors. It is SHORT: with lanes on screen it takes about a quarter of
      the stage, so the say and the ask sit side by side when there is room. */
.desktop-surface .k-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-md) var(--space-xl);
    min-width: 0;
}

.desktop-surface .k-hero-say {
    flex: 1 1 24rem;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.1rem var(--space-lg);   /* the line sits beside the greeting when there is room, under it when not */
    min-width: 0;
}

.desktop-surface .k-hero-say > .k-display { font-size: clamp(2.4rem, 1.3rem + 3.2cqi, calc(5.25rem + 9 * var(--up))); }

.desktop-surface .k-hero-line {
    margin: 0;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: clamp(1.35rem, 1rem + 1.3cqi, calc(2.25rem + 3 * var(--up)));
    line-height: 1.1;
    letter-spacing: var(--track-tight);
}

.desktop-surface .k-hero-ask {
    flex: 1.35 1 34rem;   /* three doors side by side, or the block takes its own row */
    display: grid;
    gap: var(--space-sm);
    min-width: 0;
}

/* Doors: the hero's three ways in. Equal pills that wrap. */
.desktop-surface .k-doors {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 10.5rem), 1fr));
    gap: var(--space-sm);
}

.desktop-surface .k-doors > .k-btn {
    min-height: 3rem;
    padding-inline: 0.9em;
    font-size: max(0.9375rem, var(--type-meta));
    white-space: nowrap;
}

/* ── Search filters. Groups that sit one under another in a List-width Ask
      lane and side by side in a Stage-width one (auto-fit, no query). */
.desktop-surface .k-filters {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 17.5rem), 1fr));
    gap: var(--space-lg);
    align-items: start;
    min-width: 0;
}

.desktop-surface .k-filter {
    display: grid;
    gap: var(--space-sm);
    align-content: start;
    min-width: 0;
}

.desktop-surface .k-filter--wide { grid-column: 1 / -1; }
.desktop-surface .k-filter > .k-seg { max-width: 26rem; }
.desktop-surface .k-filter > .k-ask { max-width: 46rem; }

.desktop-surface .k-filter-label {
    display: flex;
    align-items: center;
    gap: 0.5em;
    margin: 0;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-lead);
    line-height: 1.2;
    letter-spacing: var(--track-snug);
    color: var(--text);
}

.desktop-surface .k-filter-label > :is(i, svg) { color: var(--rt-purple-deep); font-size: 0.9em; }

/* The day strip (.daySlot): a tile per day, pressed = chosen */
.desktop-surface .k-days {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));   /* eight days are always two whole rows */
    gap: var(--space-xs);
}

.desktop-surface .k-day {
    display: grid;
    justify-items: center;
    gap: 0.1rem;
    min-width: 0;
    padding: 0.5rem 0.25rem;
    border: 0;
    border-radius: 0.85rem;
    background: var(--ghost-purple), rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 0 0 2px var(--rt-purple-dk);
    color: var(--ink-purple);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1.2;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-spring), color var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-day-dow { letter-spacing: 0.04em; text-transform: uppercase; }
.desktop-surface .k-day-date { font-family: var(--font-text); }
.desktop-surface .k-day > :is(i, svg) { opacity: 0.35; }

.desktop-surface .k-day[aria-pressed="true"] {
    background: var(--fill-purple);
    box-shadow: 0 0.3rem 0.75rem var(--glow-purple);
    color: #fff;
}

.desktop-surface .k-day[aria-pressed="true"] > :is(i, svg) { opacity: 1; }
.desktop-surface .k-day:active { transform: scale(0.95); transition-duration: var(--dur-press); }
.desktop-surface .k-day:focus-visible { outline: 3px solid var(--rt-purple-dk); outline-offset: 2px; }

/* Who: a label and a small stepper per row */
.desktop-surface .k-who { display: grid; gap: var(--space-xs); }

.desktop-surface .k-who-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    min-height: 3.25rem;
    padding: 0.35rem 0.5rem 0.35rem 1rem;
    border-radius: var(--r-ctl);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-ctl);
}

.desktop-surface .k-who-name {
    display: grid;
    min-width: 0;
    font-family: var(--font-head);
    font-size: var(--type-body);
    line-height: 1.2;
    color: var(--text);
}

.desktop-surface .k-who-name > small {
    font-family: var(--font-text);
    font-size: var(--type-meta);
    color: var(--text-soft);
}

.desktop-surface .k-stepper--sm {
    flex: none;
    width: auto;
    grid-template-columns: auto 2.25rem auto;
    min-height: 2.5rem;
    padding: 0.1rem;
    border-color: transparent;
    background: var(--rt-purple-slt);
    box-shadow: none;
}

.desktop-surface .k-stepper--sm .k-stepper-btn { width: 2.25rem; height: 2.25rem; }

/* ── Shelves. .k-onerow turns any grid into one row of whole cells: what does
      not fit is clipped, so a shelf never ends in an orphan. .k-shelf is a
      section header over such a row. */
.desktop-surface .k-shelf {
    display: grid;
    gap: var(--space-sm);
    min-width: 0;
}

.desktop-surface .k-onerow {
    --k-min: 16rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, var(--k-min)), 1fr));
    grid-template-rows: auto;
    grid-auto-rows: 0;
    gap: 0 var(--space-md);
    min-width: 0;
    margin: -0.4rem -0.3rem 0;
    padding: 0.4rem 0.3rem 0;   /* no room below the row, or the next row would show */
    overflow: hidden;
}

/* The identity card (Home's Keeper carousel card): the Keeper in their own
   colour, a cover photo fading into it, four of their listings, one door.
   Set --k-color and --k-photo inline. */
.desktop-surface .k-idcard {
    --k-color: #4A3A5E;
    container-type: inline-size;   /* its tiles count their columns from the card, not the lane */
    position: relative;
    isolation: isolate;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border-radius: var(--r-feature);
    background: color-mix(in srgb, var(--k-color) 46%, #000);
    color: #fff;
    overflow: hidden;
}

.desktop-surface .k-idcard::before {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0 0 auto 0;
    height: 62%;
    background: var(--k-photo, none) center top / cover no-repeat;
    opacity: 0.55;
    -webkit-mask-image: linear-gradient(to bottom, #000 25%, transparent 100%);
    mask-image: linear-gradient(to bottom, #000 25%, transparent 100%);
}

.desktop-surface .k-idcard-head {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    padding: var(--space-md) var(--space-md) var(--space-sm);
    min-width: 0;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.45);
}

.desktop-surface .k-idcard-head > .k-avatar { --k-size: 2.9rem; }

.desktop-surface .k-idcard-name {
    margin: 0;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-lead);
    line-height: 1.15;
    letter-spacing: var(--track-snug);
    color: #fff;
}

.desktop-surface .k-idcard-meta {
    margin: 0;
    font-size: var(--type-meta);
    line-height: 1.3;
    color: rgba(255, 255, 255, 0.92);
}

.desktop-surface .k-idcard > .k-tiles { margin: 0; padding: 0 var(--space-md); overflow: visible; }
.desktop-surface .k-idcard .k-tile { aspect-ratio: 1; }

.desktop-surface .k-idcard-lip {
    display: flex;
    justify-content: center;
    padding: var(--space-sm) var(--space-md) var(--space-md);
}

/* ── Focus: the listing. .k-split puts the story in the main column and the
      price panel in the corner when the lane is wide; in a narrow lane the
      corner comes first so the price and the button are never below a scroll. */
.desktop-surface .k-split {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-lg);
    align-items: start;
    min-width: 0;
}

.desktop-surface .k-split-main { display: grid; gap: var(--space-lg); min-width: 0; }
.desktop-surface .k-split-corner { display: grid; gap: var(--space-md); min-width: 0; order: -1; }

@container lane (width >= 50rem) {
    .desktop-surface .k-split { grid-template-columns: minmax(0, 1fr) clamp(18rem, 32cqi, 26rem); }

    .desktop-surface .k-split-corner {
        order: 0;
        position: sticky;
        top: var(--space-md);
    }
}

/* Photo mosaic: one large and up to four small in a wide lane, the first
   alone in a narrow one. Each is a button (it opens the photo in place). */
.desktop-surface .k-mosaic {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.4rem;
    min-width: 0;
    border-radius: var(--r-panel);
    overflow: hidden;
}

.desktop-surface .k-mosaic-photo {
    position: relative;
    display: none;
    min-width: 0;
    border: 0;
    padding: 0;
    background: var(--rt-ink) var(--k-photo, none) center / cover no-repeat;
    cursor: pointer;
}

.desktop-surface .k-mosaic-photo:first-child {
    display: block;
    aspect-ratio: 4 / 3;
}

.desktop-surface .k-mosaic-photo > .k-pill {
    position: absolute;
    right: 0.6rem;
    bottom: 0.6rem;
}

.desktop-surface .k-mosaic-photo:focus-visible { outline: 4px solid var(--rt-blue); outline-offset: -4px; }

@container lane (width >= 34rem) {
    .desktop-surface .k-mosaic {
        grid-template-columns: 2fr 1fr 1fr;
        grid-template-rows: 1fr 1fr;
        aspect-ratio: 2.1 / 1;
    }

    .desktop-surface .k-mosaic-photo { display: block; }

    .desktop-surface .k-mosaic-photo:first-child {
        grid-row: 1 / -1;
        aspect-ratio: auto;
    }

    .desktop-surface .k-mosaic-photo:first-child > .k-pill { display: none; }
}

/* Title block: id, the title, the rating line, the facts, share and save */
.desktop-surface .k-titleblock {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: var(--space-xs) var(--space-md);
    align-items: start;
    min-width: 0;
}

.desktop-surface .k-titleblock > * { grid-column: 1; margin: 0; }

.desktop-surface .k-titleblock-acts {
    grid-column: 2;
    grid-row: 1 / span 2;
    display: flex;
    gap: var(--space-xs);
}

.desktop-surface .k-rating {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    font-family: var(--font-head);
    font-size: var(--type-body);
    color: var(--text-soft);
}

.desktop-surface .k-rating > :is(i, svg) { color: var(--rt-amber-md); }

/* Facts: the headline chips on a light surface (icon in a tone, word in ink) */
.desktop-surface .k-facts {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-xs) var(--space-md);
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: var(--type-body);
    line-height: 1.35;
    color: var(--text);
}

.desktop-surface .k-facts > li { display: inline-flex; align-items: baseline; gap: 0.45em; }
.desktop-surface .k-facts > li > :is(i, svg) { color: var(--ink-blue); font-size: 0.9em; }

/* Story: the listing's sections, a rule between them */
.desktop-surface .k-story { display: grid; gap: var(--space-lg); min-width: 0; }

.desktop-surface .k-story-sec {
    display: grid;
    gap: var(--space-sm);
    min-width: 0;
    padding-top: var(--space-lg);
    border-top: 1px solid var(--line);
}

.desktop-surface .k-story-sec > * { margin: 0; }
.desktop-surface .k-story-sec > .k-body { max-width: 68ch; }

/* Score ring: a number in a ring that fills to --k-val (0 to 100) */
.desktop-surface .k-ring {
    --k-val: 0;
    --k-size: 4.25rem;
    --_c: var(--tone, var(--rt-purple));
    flex: none;
    display: grid;
    place-items: center;
    width: var(--k-size);
    aspect-ratio: 1;
    border-radius: 50%;
    background: conic-gradient(var(--_c) calc(var(--k-val) * 1%), rgba(30, 40, 53, 0.12) 0);
    color: var(--text);
    font-family: var(--font-head);
    font-size: calc(var(--k-size) * 0.3);
    line-height: 1;
    letter-spacing: var(--track-snug);
}

.desktop-surface .k-ring::before {
    content: "";
    grid-area: 1 / 1;
    width: 76%;
    aspect-ratio: 1;
    border-radius: 50%;
    background: #fff;
}

.desktop-surface .k-ring > * { grid-area: 1 / 1; z-index: 1; }

.desktop-surface .k-reviews { display: grid; gap: var(--space-md); min-width: 0; }

.desktop-surface .k-reviews-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-md) var(--space-lg);
}

.desktop-surface .k-reviews-head > .k-ring { --k-size: clamp(5rem, 4rem + 4cqi, 7rem); }

.desktop-surface .k-scores {
    flex: 1 1 14rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(5.75rem, 1fr));
    gap: var(--space-sm);
    margin: 0;
    padding: 0;
    list-style: none;
}

.desktop-surface .k-scores > li {
    display: grid;
    justify-items: center;
    gap: 0.3rem;
    font-size: var(--type-meta);
    line-height: 1.2;
    color: var(--text-soft);
    text-align: center;
}

.desktop-surface .k-review {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: var(--space-xs) var(--space-md);
    padding: var(--space-md);
    border-radius: var(--r-ctl);
    background: rgba(255, 255, 255, 0.7);
    box-shadow: var(--shadow-ctl);
}

.desktop-surface .k-review > .k-avatar { --k-size: 2.75rem; grid-row: span 2; }
.desktop-surface .k-review-who { margin: 0; font-family: var(--font-head); font-size: var(--type-body); color: var(--text); }
.desktop-surface .k-review-who > small { margin-left: 0.5em; font-family: var(--font-text); font-size: var(--type-meta); color: var(--text-soft); }
.desktop-surface .k-review > .k-body { grid-column: 2; }

/* The corner price panel: the price, what it covers, the one action */
.desktop-surface .k-buy > .k-panel-body { display: grid; gap: var(--space-md); }

.desktop-surface .k-buy-top {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--space-sm) var(--space-md);
}

/* ── Act: booking. .k-pick is one selection (a title, a line of help, the
      control). */
.desktop-surface .k-picks { display: grid; gap: var(--space-lg); min-width: 0; }

.desktop-surface .k-pick {
    display: grid;
    gap: var(--space-sm);
    min-width: 0;
}

.desktop-surface .k-pick + .k-pick {
    padding-top: var(--space-lg);
    border-top: 1px solid var(--line);
}

.desktop-surface .k-pick-title {
    margin: 0;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-lead);
    line-height: 1.2;
    letter-spacing: var(--track-snug);
    color: var(--text);
}

.desktop-surface .k-pick-sub { margin: -0.25rem 0 0; font-size: var(--type-meta); line-height: 1.35; color: var(--text-soft); }

.desktop-surface .k-slots {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(5.75rem, 1fr));
    gap: var(--space-xs);
}

.desktop-surface .k-slots > .k-chip { justify-content: center; }

/* A choice: a card you pick one of (fulfilment, a cancellation policy). A real
   radio inside a label; the chosen card takes the tone's ring and a tick. */
.desktop-surface .k-choices {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr));
    gap: var(--space-sm);
}

.desktop-surface .k-choice {
    --_ink: var(--tone-ink, var(--ink-purple));
    --_slt: var(--tone-slt, var(--rt-purple-slt));
    --_fill: var(--tone-fill, var(--fill-purple));
    position: relative;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.15rem var(--space-sm);
    margin: 0;
    padding: 0.8rem 1rem;
    border-radius: var(--r-ctl);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: inset 0 0 0 2px rgba(30, 40, 53, 0.14), var(--shadow-ctl);
    color: var(--text);
    cursor: pointer;
    transition: background var(--dur-fast) var(--ease-out);
}

.desktop-surface .k-choice > input {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.desktop-surface .k-choice-mark {
    grid-row: span 2;
    display: grid;
    place-items: center;
    width: 1.5rem;
    height: 1.5rem;
    border: 2px solid rgba(30, 40, 53, 0.28);
    border-radius: 50%;
    background: #fff;
}

.desktop-surface .k-choice-mark::after {
    content: "";
    width: 0.6rem;
    height: 0.6rem;
    border-radius: 50%;
    background: #fff;
    transform: scale(0);
    transition: transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .k-choice-title { grid-column: 2; font-family: var(--font-head); font-size: var(--type-body); line-height: 1.2; }
.desktop-surface .k-choice-sub { grid-column: 2; font-size: var(--type-meta); line-height: 1.3; color: var(--text-soft); }
.desktop-surface .k-choice-end { grid-column: 3; grid-row: 1 / span 2; font-family: var(--font-head); font-size: var(--type-body); white-space: nowrap; }

.desktop-surface .k-choice:has(> input:checked) {
    background: var(--_slt);
    box-shadow: inset 0 0 0 3px var(--_ink);
}

.desktop-surface .k-choice:has(> input:checked) .k-choice-mark { border-color: transparent; background: var(--_fill); }
.desktop-surface .k-choice:has(> input:checked) .k-choice-mark::after { transform: scale(1); }
.desktop-surface .k-choice:has(> input:focus-visible) { outline: 3px solid var(--_ink); outline-offset: 2px; }

/* The gate: sign in or create an account, in the Act lane, beside the listing */
.desktop-surface .k-gate > .k-panel-body {
    display: grid;
    gap: var(--space-sm);
    justify-items: start;
}

.desktop-surface .k-gate-art {
    display: grid;
    place-items: center;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 50%;
    background: var(--tone-fill, var(--fill-pink));
    box-shadow: 0 0.375rem 0.875rem var(--tone-glow, var(--glow-pink));
    color: var(--tone-on, #fff);
    font-size: 1.3rem;
}

.desktop-surface .k-gate .k-btns { width: 100%; }
.desktop-surface .k-gate .k-btns > .k-btn { flex: 1 1 9rem; }

/* The passcode: six boxes, one digit each */
.desktop-surface .k-code {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: clamp(0.3rem, 2cqi, 0.6rem);
    max-width: 23rem;
}

.desktop-surface .k-code > .k-input {
    min-height: 3.5rem;
    padding: 0;
    text-align: center;
    font-family: var(--font-head);
    font-size: 1.6rem;
    letter-spacing: 0;
}

/* .k-state: one block for "nothing here", "that failed" and "done". The same
   look as .k-empty; the tone says which (pink empty, amber error, green done). */
.desktop-surface .k-state {
    display: grid;
    justify-items: center;
    gap: var(--space-sm);
    padding: var(--space-lg) var(--pad-panel);
    text-align: center;
}

.desktop-surface .k-state > .k-empty-art { margin-bottom: var(--space-sm); color: rgba(255, 255, 255, 0.92); }
.desktop-surface .k-state > .k-empty-art.k-tone-amber { color: var(--rt-ink); }
.desktop-surface .k-state > :is(.k-meta, .k-body) { max-width: 36ch; }
.desktop-surface .k-state > .k-btns { justify-content: center; margin-top: var(--space-xs); }

/* ── Loading: skeletons. Grey shapes where content will be, breathing (an
      opacity pulse: nothing lays out). Compose them in markup; -card and -row
      are the two ready-made ones (a gallery card, a list row). */
.desktop-surface .k-skel {
    display: block;
    min-width: 0;
    border-radius: 0.6rem;
    background: rgba(30, 40, 53, 0.11);
    animation: k-skel 1.1s var(--ease-house) infinite alternate;
}

.desktop-surface .k-skel--line   { height: 0.9em; width: var(--k-w, 100%); border-radius: 1rem; }
.desktop-surface .k-skel--title  { height: 1.5rem; width: var(--k-w, 70%); border-radius: 1rem; }
.desktop-surface .k-skel--photo  { aspect-ratio: var(--k-ratio, 4 / 3); border-radius: var(--r-card); }
.desktop-surface .k-skel--pill   { height: 2.5rem; width: var(--k-w, 8rem); border-radius: var(--r-pill); }
.desktop-surface .k-skel--circle { width: var(--k-w, 3rem); aspect-ratio: 1; border-radius: 50%; }

.desktop-surface .k-skel-card {
    display: grid;
    gap: var(--space-sm);
    align-content: start;
    min-width: 0;
    padding: 0 0 var(--space-md);
    border-radius: var(--r-card);
    background: rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.6);
    overflow: hidden;
}

.desktop-surface .k-skel-card > .k-skel--photo { border-radius: 0; }
.desktop-surface .k-skel-card > :not(.k-skel--photo) { margin-inline: var(--space-md); }

.desktop-surface .k-skel-row {
    display: grid;
    grid-template-columns: 5.5rem minmax(0, 1fr);
    align-items: center;
    gap: var(--space-sm) var(--space-md);
    min-height: 6.5rem;
    padding: 0.5rem;
    border-radius: 0.9rem;
    background: rgba(255, 255, 255, 0.6);
}

.desktop-surface .k-skel-row > .k-skel--photo { --k-ratio: 1; border-radius: 0.6rem; }
.desktop-surface .k-skel-row > div { display: grid; gap: 0.55rem; }

.desktop-surface .k-skels { display: grid; gap: var(--space-sm); min-width: 0; }

@keyframes k-skel {
    from { opacity: 1; }
    to   { opacity: 0.45; }
}


/* ─── 15. REDUCED MOTION ──────────────────────────────────────────────────── */
/* Instant layout, no travel (direction.md rule 4). The spinner and the lane
   line keep turning: they are status, not decoration. */

@media (prefers-reduced-motion: reduce) {
    .desktop-surface [class^="k-"],
    .desktop-surface [class*=" k-"],
    .desktop-surface [class^="k-"]::before,
    .desktop-surface [class*=" k-"]::before,
    .desktop-surface [class^="k-"]::after,
    .desktop-surface [class*=" k-"]::after {
        transition-duration: 0.01ms !important;
    }

    .desktop-surface .k-arrive > *,
    .desktop-surface .k-disclosure[open] > .k-disclosure-body,
    .desktop-surface .k-status--live::before,
    .desktop-surface .k-skel {
        animation: none;
    }

    .desktop-surface .k-disclosure::details-content { transition: none; }

    .desktop-surface .k-tilt-card:hover { transform: none; }
}


/* ─── 16. THE KIT PAGE (k-demo-) ──────────────────────────────────────────── */
/* Layout for desktop/pages/Dev-Kit.php only. Nothing outside that page may
   use a k-demo- class. The sample lanes are real .lane-body containers
   (container: lane / inline-size), so every part above is seen answering its
   own column, and Dev-Kit.js runs the same fit rule the stage manager does
   (minimum sizes read from the probes below, which resolve the --lane-*
   tokens to pixels). */

.desktop-surface .k-demo {
    position: relative;
    display: flow-root;
    min-width: 0;
}

/* In a lane of its own (not the old .desktop-main frame) the page brings its gutter */
.desktop-surface .lane > .lane-body:not(.is-legacy) > .k-demo {
    padding: clamp(1.5rem, 2.4cqi, 2.5rem) clamp(1.5rem, 3cqi, 3rem);
}

/* Hero: on the wave, and short. Once lanes are showing a hero takes about a
   quarter of the stage: the greeting on one line, the second line and the
   action beside it when the hero is wide, the tilt set at the right. */
.desktop-surface .k-demo-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-sm) var(--space-xl);
    padding: 0 0 var(--space-md) clamp(0rem, 3cqi - 1.5rem, 3rem);
}

.desktop-surface .k-demo-hero-text {
    flex: 1 1 22rem;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    gap: var(--space-xs) var(--space-xl);
    min-width: 0;
}

.desktop-surface .k-demo-hero-text > .k-eyebrow { grid-column: 1 / -1; }
.desktop-surface .k-demo-hero-text > .k-display { grid-row: span 2; white-space: nowrap; }
.desktop-surface .k-demo-hero-text > .k-title { align-self: end; font-size: clamp(1.5rem, 1rem + 1.6cqi, calc(2.5rem + 3 * var(--up))); }
.desktop-surface .k-demo-hero-text > .k-btns { align-self: start; }

/* A narrow hero stacks the same four pieces */
@container (width < 92rem) {
    .desktop-surface .k-demo-hero-text { grid-template-columns: minmax(0, 1fr); }
    .desktop-surface .k-demo-hero-text > .k-display { grid-row: auto; white-space: normal; }
    .desktop-surface .k-demo-hero-text > .k-title { display: none; }   /* the hero stays a quarter of the stage */
}

.desktop-surface .k-demo-hero-side {
    flex: 0 1 clamp(21rem, 16rem + 10cqi, 31rem);
    min-width: 0;
}

.desktop-surface .k-demo-hero-side .k-tilt-card { aspect-ratio: 1 / 1; }

/* The stage: three sample lanes in a row */
.desktop-surface .k-demo-stage {
    position: relative;
    display: flex;
    align-items: stretch;
    gap: var(--lane-gap);
    min-width: 0;
    height: clamp(34rem, 100vh - 2.5rem, 70rem);
}

.desktop-surface .k-demo-stage[data-unrolled] {
    height: auto;
    align-items: flex-start;
}

.desktop-surface .k-demo-lane {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border-radius: var(--r-feature);
    background: var(--glass-bg-faint);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
    overflow: hidden;
    transition: flex var(--lane-dur) var(--lane-ease);
}

.desktop-surface .k-demo-lane[data-w="stage"] { flex: 1 1 var(--lane-stage-min); }
.desktop-surface .k-demo-lane[data-w="list"]  { flex: 0 0 var(--lane-list); }
.desktop-surface .k-demo-lane[data-w="spine"] { flex: 0 0 var(--lane-spine); }

.desktop-surface .k-demo-lane > .lane-body {
    container: lane / inline-size;
    flex: 1 1 auto;
    min-height: 0;
    height: auto;
    margin: 0;
    padding: 0 var(--space-md) var(--space-lg);
    overflow: hidden auto;
    scrollbar-width: thin;
    scrollbar-color: rgba(30, 40, 53, 0.25) transparent;
    visibility: visible;
}

.desktop-surface .k-demo-stage[data-unrolled] .k-demo-lane > .lane-body { overflow: visible; }

/* Lane head: kit-only chrome (which sample lane, which form, the width
   switch). It never ships, so it is a quiet line: the lane's own heading
   under it is the heaviest thing in the lane. */
.desktop-surface .k-demo-lanehead {
    position: sticky;
    z-index: 5;
    top: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0 var(--space-sm);
    margin: 0 calc(-1 * var(--space-md)) var(--space-sm);
    padding: 0.3rem var(--space-md);
    background: rgba(255, 255, 255, 0.82);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    opacity: 0.9;
}

.desktop-surface .k-demo-lanename {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    min-width: 0;
}

.desktop-surface .k-demo-lanename > .k-badge {
    padding: 0;
    background: none;
    color: var(--text-soft);
    font-family: var(--font-mono);
    letter-spacing: 0;
}

.desktop-surface .k-demo-lanename > .k-meta { font-family: var(--font-mono); }

.desktop-surface .k-demo-lanehead .k-seg {
    padding: 0;
    background: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    outline: 0;
    box-shadow: none;
}

.desktop-surface .k-demo-lanehead .k-seg-btn {
    flex: none;
    min-height: 1.75rem;
    padding: 0.15em 0.6em;
    font-family: var(--font-text);
    color: var(--text-soft);
}

.desktop-surface .k-demo-lanehead .k-seg-btn[aria-pressed="true"] {
    background: rgba(30, 40, 53, 0.08);
    box-shadow: none;
    color: var(--text);
}

.desktop-surface .k-demo-part { display: grid; gap: var(--space-md); min-width: 0; align-content: start; }
.desktop-surface .k-demo-part > .k-eyebrow { color: var(--ink-pink); }

/* Parts of unequal height flow in equal columns that balance (as many as fit
   21rem), so a short part never leaves a hole beside a tall one. The two wide
   parts (type, panels) span every column. */
.desktop-surface .k-demo-parts {
    display: grid;   /* not CSS multi-column: Safari does not paint composited children in later columns */
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr));
    gap: var(--space-lg);
    align-items: start;
    margin-top: var(--space-xl);
}

.desktop-surface .k-demo-part {
    break-inside: avoid;
    margin-bottom: var(--space-xl);
}

.desktop-surface .k-demo-part--wide { grid-column: 1 / -1; }

/* Panels: one, two or four across, never three (four panels in three columns
   leave an empty slot), each as tall as its row so no column ends early. */
.desktop-surface .k-demo-panels {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-lg);
    align-items: stretch;
}

@container lane (width >= 42rem) {
    .desktop-surface .k-demo-panels { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

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

/* Sample copy that describes the part instead of belonging to it: hidden here
   until Dev-Kit.php drops the line (see the unit's report). */
.desktop-surface .k-demo-part .k-disclosure + .k-meta { display: none; }

.desktop-surface .k-demo-specimen { display: grid; gap: var(--space-sm); }

.desktop-surface .k-demo-specimen-dark {
    display: grid;
    gap: var(--space-xs);
    padding: var(--space-lg) var(--pad-panel);
    border-radius: var(--r-panel);
    background: var(--wave-mesh);
    box-shadow: var(--shadow-cont-sm-lt);
    overflow: hidden;
}

.desktop-surface .k-demo-stack { display: grid; gap: var(--space-md); min-width: 0; }

.desktop-surface .k-demo-restore { display: none; }

/* A spine-wide sample lane holds only its return control and its cards */
@container lane (width < 12rem) {
    .desktop-surface .k-demo-parts,
    .desktop-surface .k-demo-lanename,
    .desktop-surface .k-demo-lead,
    .desktop-surface .k-demo-lanehead .k-seg { display: none; }

    .desktop-surface .k-demo-restore {
        display: inline-grid;
        background: var(--fill-pink);
        outline-color: rgba(255, 255, 255, 0.7);
        color: #fff;
    }

    .desktop-surface .k-demo-lanehead {
        justify-content: center;
        margin-inline: -0.5rem;
        padding: 0.5rem 0;
        background: none;
        -webkit-backdrop-filter: none;
        backdrop-filter: none;
        opacity: 1;
    }
}

.desktop-surface .k-demo-lane[data-w="spine"] > .lane-body { padding-inline: 0.5rem; }

@container lane (width < 26rem) {
    .desktop-surface .k-demo-lanehead .k-seg-label { display: none; }
}

/* Probes: zero-height boxes whose widths are the lane tokens, for the fit rule */
.desktop-surface .k-demo-probe {
    position: absolute;
    top: 0;
    left: 0;
    height: 0;
    visibility: hidden;
    pointer-events: none;
}

.desktop-surface .k-demo-probe[data-probe="list"]  { width: var(--lane-list); }
.desktop-surface .k-demo-probe[data-probe="spine"] { width: var(--lane-spine); }
.desktop-surface .k-demo-probe[data-probe="stage"] { width: var(--lane-stage-min); }
.desktop-surface .k-demo-probe[data-probe="gap"]   { width: var(--lane-gap); }

@media (prefers-reduced-motion: reduce) {
    .desktop-surface .k-demo-lane { transition: none; }
}


/* ─── 17. THE PARTS PAGE (k-scene-) ───────────────────────────────────────── */
/* Layout for desktop/pages/Dev-Parts.php only. A scene is a row of sample
   lanes, each with a real job (Ask, Browse, Focus, Act) and a real
   .lane-body (container: lane / inline-size), arranged the way the stage
   arranges them: the previous lane a List beside the lane in use. The row is
   a container itself (scene), so a third lane leaves when there is no room
   for it: a rule about the space, not about the screen. */

.desktop-surface .k-scenes {
    display: grid;
    gap: var(--space-xl);
    min-width: 0;
}

/* The old page frame (3rem at each side) leaves a 900px window 54px short of
   a List beside a Stage: a narrow stage gives that room back. */
@container (width < 56rem) {
    .desktop-surface .lane > .lane-body.is-legacy > .k-scenes { margin-inline: -1.75rem; }
}

.desktop-surface .lane > .lane-body:not(.is-legacy) > .k-scenes {
    padding: clamp(1rem, 2cqi, 2.25rem) clamp(1rem, 2.4cqi, 3rem);
}

/* The hero is as tall as its content and the first scene follows closely:
   with lanes on screen the Ask block is about a quarter of the stage */
.desktop-surface .k-scenes > .k-hero { margin-bottom: calc(var(--space-md) - var(--space-xl)); }

.desktop-surface .k-scene { display: grid; gap: var(--space-sm); min-width: 0; }

.desktop-surface .k-scene-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0 var(--space-md);
    padding-inline: var(--space-xs);
}

.desktop-surface .k-scene-head > .k-eyebrow { color: var(--ink-pink); }

.desktop-surface .k-scene-stage {
    container: scene / inline-size;
    display: flex;
    align-items: flex-start;
    gap: var(--lane-gap);
    min-width: 0;
}

/* A real lane is as tall as the stage and scrolls by itself. Here the lanes
   are unrolled so every part can be seen, and the shorter lane of a pair
   keeps to the top of the screen while the longer one scrolls past it. */
.desktop-surface .k-scene-stage:not([data-wrap]) > .k-scene-lane {
    position: sticky;
    top: var(--space-sm);
}

/* A row of parts that is not a lane arrangement (three cards of one step, the
   three states) may wrap: real lanes never do. */
.desktop-surface .k-scene-stage[data-wrap] { flex-wrap: wrap; }
.desktop-surface .k-scene-stage[data-wrap] > .k-scene-lane[data-w="list"] { flex: 1 1 var(--lane-list); }
.desktop-surface .k-scene-stage[data-wrap] > .k-scene-lane[data-w="stage"] { flex: 2 1 var(--lane-stage-min); }

.desktop-surface .k-scene-lane {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border-radius: var(--r-feature);
    background: var(--glass-bg-faint);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.75);
    overflow: hidden;
}

.desktop-surface .k-scene-lane[data-w="stage"] { flex: 1 1 0; min-width: var(--lane-stage-min); }
.desktop-surface .k-scene-lane[data-w="list"]  { flex: 0 1 var(--lane-list); min-width: 20rem; }
.desktop-surface .k-scene-lane[data-w="spine"] { flex: 0 0 var(--lane-spine); }

.desktop-surface .k-scene-lane > .lane-body {
    container: lane / inline-size;
    flex: 1 1 auto;
    display: grid;
    gap: var(--space-md);
    align-content: start;
    min-width: 0;
    padding: var(--space-md);
}

.desktop-surface .k-scene-lane[data-w="spine"] > .lane-body { padding: 0.4rem; }

/* The sample Spine uses the stage's own Spine markup (.lane-spine) so the
   kit's dress is seen on it; outside a real .lane it needs to be shown. */
.desktop-surface .k-scene-lane[data-w="spine"] > .lane-spine {
    position: relative;
    inset: auto;
    flex: 0 0 auto;
    height: auto;
    max-height: 60%;
    opacity: 1;
    visibility: visible;
}

.desktop-surface .k-scene-lane[data-w="spine"] > .lane-spine > .lane-spine-title { display: block; }

/* The lane's heading is its header: what the lane is for, in its own words */
.desktop-surface .k-scene-lanehead {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-xs) var(--space-sm);
    min-width: 0;
}

.desktop-surface .k-scene-lanehead > .k-section { letter-spacing: var(--track-tight); }

/* A third lane (two steps back) folds away before the lane in use is squeezed */
@container scene (width < 66rem) {
    .desktop-surface .k-scene-lane[data-fold="first"] { display: none; }
}

@container lane (width < 12rem) {
    .desktop-surface .k-scene-lanehead { display: none; }
}

/* A lane's sticky column in the kit: the lane with less in it keeps to the top */
.desktop-surface .k-scene-stack { display: grid; gap: var(--space-md); min-width: 0; align-content: start; }


/* ─── 18. THE INLINE CALENDAR (RT.Calendar, inline mode) ──────────────────── */
/* assets/js/rt-calendar.js with `inline:` mounts its card INSIDE a lane, in
   the flow (div.rtcal-inline > .rtcal-card: a top bar with Clear and Close,
   the date readout, the months, Continue). Until the integration these rules
   lived only in the old components.css, drawn for the full-screen modal; this
   is the inline card's whole look on kit tokens, so the month grid reads as
   the same family as the day strip (.k-days) and the time slots (.k-slots):
   purple rings and ink, the pressed purple fill and glow for a chosen day, the
   pink ring for today. The modal (mobile, and the old pages) is untouched: it
   is never .rtcal-inline. A lane sheet may size it further (lane-act.css
   draws its own; lane-ask.css fits it to a filter column). */

.desktop-surface .rtcal-inline {
    --cal:      var(--rt-purple);
    --cal-dk:   var(--rt-purple-dk);
    --cal-lt:   var(--rt-purple-lt);
    --cal-slt:  var(--rt-purple-slt);
    --cal-ring: var(--rt-pink-lt);
    position: static;
    display: block;
}

.desktop-surface .rtcal-inline[hidden] { display: none; }

.desktop-surface .rtcal-inline .rtcal-card {
    display: flex;
    flex-direction: column;
    width: 100%;
    max-height: 32rem;
    border: 0;
    border-radius: var(--r-panel);
    background: rgba(255, 255, 255, 0.94);
    box-shadow: var(--shadow-ctl);
    outline: var(--glass-outline);
    overflow: hidden;
    color: var(--text);
    font-family: var(--font-text);
    transform: none;
    transition: none;
}

/* Top bar: Close (X) at the right, Clear beside it */
.desktop-surface .rtcal-inline .rtcal-topbar {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: end;
    gap: 0.25rem;
    padding: 0.5rem 0.5rem 0;
}

.desktop-surface .rtcal-inline :is(.rtcal-close, .rtcal-clear) {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    min-height: 2.5rem;
    border-radius: var(--r-pill);
    cursor: pointer;
    transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}

.desktop-surface .rtcal-inline .rtcal-close {
    background: rgba(30, 40, 53, 0.06);
    color: var(--text-soft);
    font-size: 1.05rem;
}

.desktop-surface .rtcal-inline .rtcal-clear {
    padding: 0 0.85rem;
    background: transparent;
    color: var(--ink-purple);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
}

/* The readout: Start date to End date (one date in single mode) */
.desktop-surface .rtcal-inline .rtcal-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 0 1rem 0.75rem;
    border-bottom: 1px solid var(--line);
}

.desktop-surface .rtcal-inline .rtcal-date { min-width: 6rem; text-align: center; }

.desktop-surface .rtcal-inline .rtcal-date span {
    display: block;
    margin-bottom: 0.1rem;
    color: var(--text-soft);
    font-size: var(--type-meta);
}

.desktop-surface .rtcal-inline .rtcal-date div {
    color: var(--ink-purple);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
}

.desktop-surface .rtcal-inline .rtcal-arrow { color: var(--cal-lt); font-size: 1rem; }
.desktop-surface .rtcal-inline .rtcal-card.single :is(.rtcal-arrow, .rtcal-end) { display: none; }

/* The months: one scroll, two side by side when the card has the room */
.desktop-surface .rtcal-inline .rtcal-months {
    position: relative;   /* offsetParent for open()'s scroll to the selection */
    flex: 1 1 auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 17rem), 1fr));
    column-gap: 1.75rem;
    align-items: start;
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
    touch-action: pan-y;   /* rt-calendar.js lets only the months pan on a touch screen */
    padding: 0 0.75rem 0.5rem;
}

.desktop-surface .rtcal-inline .rtcal-month-name {
    padding: 1rem 0.4rem 0.4rem;
    color: var(--text);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
}

.desktop-surface .rtcal-inline :is(.rtcal-weekdays, .rtcal-grid) {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
}

.desktop-surface .rtcal-inline .rtcal-weekdays > div {
    padding: 0.2rem 0;
    color: var(--ink-purple);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    text-align: center;
}

/* A day: the number on a circle that fills like a pressed .k-day */
.desktop-surface .rtcal-inline .rtcal-day {
    position: relative;
    z-index: 1;   /* the circle and the range bar sit behind the number */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 2.6rem;
    color: var(--text);
    font-size: var(--type-body);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.desktop-surface .rtcal-inline .rtcal-day::before,
.desktop-surface .rtcal-inline .rtcal-day::after { content: none; }
.desktop-surface .rtcal-inline .rtcal-day.blank { cursor: auto; }
.desktop-surface .rtcal-inline .rtcal-day.inactive { color: #B9C0C9; pointer-events: none; }

.desktop-surface .rtcal-inline .rtcal-day.today:not(.selected)::after {
    content: "";
    position: absolute;
    inset: 50% auto auto 50%;
    z-index: -1;
    width: 2.35rem;
    height: 2.35rem;
    border: 2px solid var(--cal-ring);
    border-radius: 50%;
    opacity: 0.6;   /* today is a hint, never louder than a chosen day */
    transform: translate(-50%, -50%);
}

.desktop-surface .rtcal-inline .rtcal-day.range::before,
.desktop-surface .rtcal-inline .rtcal-day.bar-right::before,
.desktop-surface .rtcal-inline .rtcal-day.bar-left::before {
    content: "";
    position: absolute;
    inset: 0.2rem 0;
    z-index: -2;
    background: var(--cal-slt);
}

.desktop-surface .rtcal-inline .rtcal-day.bar-right::before { inset-inline-start: 50%; }
.desktop-surface .rtcal-inline .rtcal-day.bar-left::before { inset-inline-end: 50%; }

.desktop-surface .rtcal-inline .rtcal-day.selected {
    color: #fff;
    font-family: var(--font-head);
    font-weight: normal;
}

.desktop-surface .rtcal-inline .rtcal-day.selected::after {
    content: "";
    position: absolute;
    inset: 50% auto auto 50%;
    z-index: -1;
    width: 2.35rem;
    height: 2.35rem;
    border: 2px solid var(--cal-lt);
    border-radius: 50%;
    background: var(--fill-purple);
    box-shadow: 0 0.25rem 0.6rem var(--glow-purple);
    transform: translate(-50%, -50%);
}

/* A day's price line (future booking), under the number */
.desktop-surface .rtcal-inline .rtcal-day-meta {
    display: block;
    margin-top: 0.1rem;
    color: var(--text-soft);
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-meta);
    line-height: 1;
}

.desktop-surface .rtcal-inline .rtcal-day-meta.up { color: var(--rt-amber-ink); }
.desktop-surface .rtcal-inline .rtcal-card.has-meta .rtcal-day { min-height: 3.1rem; }
.desktop-surface .rtcal-inline .rtcal-day.selected .rtcal-day-meta { color: rgba(255, 255, 255, 0.92); }

/* Continue: the purple fill of a chosen day; quiet until there is a date */
.desktop-surface .rtcal-inline .rtcal-continue {
    margin: 0.5rem 0.75rem 0.75rem;
    padding: 0.7rem 1rem;
    border-radius: var(--r-pill);
    background: var(--fill-purple);
    box-shadow: 0 0.3rem 0.75rem var(--glow-purple);
    outline: 0;
    color: #fff;
    font-family: var(--font-head);
    font-weight: normal;
    font-size: var(--type-body);
    text-align: center;
    cursor: pointer;
    transition: transform var(--dur-base) var(--ease-spring);
}

.desktop-surface .rtcal-inline .rtcal-continue:active { transform: scale(0.98); transition-duration: var(--dur-press); }

.desktop-surface .rtcal-inline .rtcal-continue.locked {
    background: #E3E7EC;
    box-shadow: none;
    color: #566170;
    pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
    .desktop-surface .rtcal-inline .rtcal-day:not(.blank):not(.inactive):not(.selected):hover { color: var(--cal-dk); }
    /* A faint disc under a day the pointer is on; today keeps its ring and gains the disc */
    .desktop-surface .rtcal-inline .rtcal-day.today:not(.blank):not(.inactive):not(.selected):hover::after { background: var(--cal-slt); }
    .desktop-surface .rtcal-inline .rtcal-day:not(.blank):not(.inactive):not(.selected):not(.today):hover::after {
        content: "";
        position: absolute;
        inset: 50% auto auto 50%;
        z-index: -1;
        width: 2.5rem;
        height: 2.5rem;
        border-radius: 50%;
        background: var(--cal-slt);
        transform: translate(-50%, -50%);
    }
    .desktop-surface .rtcal-inline .rtcal-close:hover { background: var(--line); color: var(--text); }
    .desktop-surface .rtcal-inline .rtcal-clear:hover { background: var(--cal-slt); }
}

@media (prefers-reduced-motion: reduce) {
    .desktop-surface .rtcal-inline :is(.rtcal-close, .rtcal-clear, .rtcal-continue) { transition: none; }
}
