/* Portal theme — tobawy-platform · store-customer (the `public` area).
 * NATIVE, no manifest row.
 *
 * WRITTEN FRESH, not forked from the console's. `manage`'s theme.css is 651
 * lines, and almost all of it dresses things this area does not have: an
 * icon-led sidebar rail, sortable column headers, pagers, permission trees,
 * stat cards. Copying it to reach the four rules the portal actually needs
 * would be 600 lines of dead CSS that a reader has to eliminate by hand before
 * believing any of it is unused — and every one of them a line a future edit
 * could accidentally make load-bearing.
 *
 * It consumes ONLY the custom properties the PHP token set generates, exactly
 * as the shared layer does: no literal colour, size or font appears below.
 *
 * RTL comes from `dir` alone — every rule here uses LOGICAL properties
 * (inline-start/end, block-start/end), never left/right. The app's test suite
 * fails on a physical one.
 *
 * ⓘ Selectors are scoped `body.theme-default` to match the shared convention:
 * an area may declare several themes (`theme.areas.public.available`), and an
 * unscoped rule would leak into all of them.
 */

/* ------------------------------------------------------------------ shell */

body.theme-default .app-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    background: var(--color-surface);
    border-block-end: var(--border-width) solid var(--color-border);
}

body.theme-default .app-brand {
    font-weight: var(--font-weight-bold);
    color: var(--color-primary);
}

/* The language switch and the sign-out button sit at the far end of the header.
   `margin-inline-start: auto` rather than a float, so the flip is free in RTL. */
body.theme-default .lang-switch {
    margin-inline-start: auto;
    display: flex;
    gap: var(--space-2);
}

body.theme-default .app-logout {
    display: flex;
}

body.theme-default .app-main {
    max-inline-size: var(--layout-max-width);
    margin: 0 auto;
    padding: var(--space-4);
}

/* ------------------------------------------------------------ the account */

/* ONE CARD PER INSTALLATION. The overview repeats a single shape — product and
   tenant, the licence line, the slot table, the device table — so the card is
   what tells a customer with four installations where one ends and the next
   begins. `.card` itself (surface, radius, shadow) comes from the shared layer;
   only the spacing between stacked cards is this area's. */
body.theme-default .app-main > .stack > .card + .card {
    margin-block-start: var(--space-4);
}

/* The sign-in page is the one screen that is meant to be narrow: a lone form on
   an otherwise empty page reads as a mistake when it is stretched across a
   desktop width. */
body.theme-default .auth-card {
    max-inline-size: 24rem;
    margin: var(--space-4) auto;
}

/* ----------------------------------------------------------------- tables */

/* A BARE `<table>`, no class — the convention this app already follows (the
   console's theme records the same, having confirmed it across every view).
   Both portal tables are small and fixed-width by nature: a slot table has one
   row per device class sold, a device table one row per slot filled. */
body.theme-default table {
    inline-size: 100%;
    border-collapse: collapse;
    background: var(--color-surface);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
}

body.theme-default thead th {
    background: var(--color-primary);
    color: var(--color-primary-fg);
    text-align: start;
    font-weight: var(--font-weight-bold);
    padding: var(--space-2) var(--space-3);
}

body.theme-default tbody td {
    padding: var(--space-2) var(--space-3);
    border-block-start: var(--border-width) solid var(--color-border);
    vertical-align: middle;
}

/* TICKET BODIES (R0.10.0) — the same rule the console carries, and for the same
   reason: the view escapes with View::e() as the OUTERMOST call (View::scan()
   requires it), so newlines arrive as literal characters and `pre-wrap` is what
   makes them visible. `overflow-wrap` because a customer pasting a licence key
   or a log line has nothing to break at. */
body.theme-default .ticket-body {
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

/* ------------------------------------------------------------ SHOP (V2) */

/* The two halves of the shop and the basket link, as one bar. The basket sits at the far end. */
body.theme-default .shop-sections {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
}
body.theme-default .shop-sections a {
    display: inline-flex;
    align-items: center;
    min-block-size: var(--layout-field-height);
    padding-inline: var(--space-3);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    text-decoration: none;
}
body.theme-default .shop-sections a.is-active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-primary-fg);
}
body.theme-default .shop-sections .shop-basket {
    margin-inline-start: auto;
}

body.theme-default .shop-search {
    display: flex;
    flex-wrap: wrap;
    align-items: end;
    gap: var(--space-3);
}

/* Category pills: a link each, the current one filled. */
body.theme-default .shop-cats,
body.theme-default .shop-pages {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
}
body.theme-default .shop-cats a,
body.theme-default .shop-pages a,
body.theme-default .shop-pages span {
    display: inline-flex;
    align-items: center;
    min-block-size: var(--layout-field-height);
    min-inline-size: var(--layout-field-height);
    justify-content: center;
    padding-inline: var(--space-3);
    border: var(--border-width) solid var(--color-border);
    border-radius: 999px;
    background: var(--color-surface);
    text-decoration: none;
}
body.theme-default .shop-cats a.is-active,
body.theme-default .shop-pages .is-active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: var(--color-primary-fg);
}

/* The grid: as many cards as fit, no fixed column count, so a phone gets one or two without a media query. */
body.theme-default .shop-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(calc(var(--space-5) * 5.5), 1fr));
    gap: var(--space-4);
}
body.theme-default .shop-card {
    display: flex;
    flex-direction: column;
    padding: 0;
    overflow: hidden;
}
body.theme-default .shop-card__pic,
body.theme-default .shop-item__pic {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: color-mix(in srgb, var(--color-primary) 8%, var(--color-surface));
    color: var(--color-primary);
}
body.theme-default .shop-card__pic {
    block-size: calc(var(--space-5) * 4);
}
body.theme-default .shop-card__pic img {
    max-inline-size: 100%;
    max-block-size: 100%;
    object-fit: contain;
}
body.theme-default .shop-card__body {
    flex: 1;
    padding: var(--space-3);
}
body.theme-default .shop-card__name {
    margin: 0;
    font-size: var(--font-size);
}
body.theme-default .shop-card__price strong,
body.theme-default .shop-price strong {
    font-size: calc(var(--font-size) * 1.25);
}
body.theme-default .shop-card__action {
    margin-block-start: auto;
}

/* The item page: picture beside the facts, stacking when there is no room. */
body.theme-default .shop-item {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4);
    align-items: flex-start;
}
body.theme-default .shop-item__pic {
    flex: 1 1 calc(var(--space-5) * 6);
    max-inline-size: calc(var(--space-5) * 9);
    min-block-size: calc(var(--space-5) * 6);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--space-3);
}
body.theme-default .shop-item__pic img {
    max-inline-size: 100%;
    block-size: auto;
    object-fit: contain;
}
body.theme-default .shop-item__main {
    flex: 999 1 calc(var(--space-5) * 8);
    min-inline-size: 0;
}
body.theme-default .shop-variants {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
    border: 0;
    padding: 0;
}
body.theme-default .shop-variants legend {
    padding: 0;
    margin-block-end: var(--space-2);
    font-weight: var(--font-weight-bold);
}
body.theme-default .shop-variants a {
    display: flex;
    flex-direction: column;
    min-inline-size: calc(var(--space-5) * 3);
    padding: var(--space-2) var(--space-3);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    text-decoration: none;
}
body.theme-default .shop-variants a.is-active {
    border: calc(var(--border-width) * 2) solid var(--color-primary);
}
body.theme-default .shop-crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-2);
}

/* A status chip: colour AND a word, never colour alone (the word is the label). */
body.theme-default .chip {
    display: inline-block;
    padding: 0 var(--space-2);
    border: var(--border-width) solid currentColor;
    border-radius: 999px;
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-bold);
    white-space: nowrap;
}
body.theme-default .chip--ok { color: var(--color-success); }
body.theme-default .chip--low { color: var(--color-warning); }
body.theme-default .chip--out { color: var(--color-danger); }
body.theme-default .chip--kit { color: var(--color-muted); }

/* A basket line that stopped being buyable: struck out, still readable, remove still works. */
body.theme-default tr.is-unavailable td:first-child {
    text-decoration: line-through;
    color: var(--color-muted);
}

/* ------------------------------------------------------------ EDITIONS (V2 editions slice 4) */

/* The comparison of a product's editions: one card per edition, side by side on a wide screen and stacked on a phone. */
body.theme-default .edition-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(calc(var(--space-5) * 9), 1fr));
    gap: var(--space-4);
}

/* ------------------------------------------------------------ CHECKOUT, ADDRESSES, TRACKING (V2 step 3) */

/* The address book: cards that fill the row and wrap, the default one marked by its border as well as its chip. */
body.theme-default .address-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(calc(var(--space-5) * 9), 1fr));
    gap: var(--space-4);
}
body.theme-default .address-card {
    padding: var(--space-4);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
}
body.theme-default .address-card--default {
    border-color: var(--color-primary);
}
body.theme-default .address-card__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
}
body.theme-default .address-card__head h2 {
    margin: 0;
    font-size: var(--font-size);
}
body.theme-default .address-card__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2) var(--space-3);
}
body.theme-default .address-card__actions form {
    display: inline;
}
body.theme-default .address-form {
    padding: var(--space-4);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    max-inline-size: calc(var(--space-5) * 24);
}
body.theme-default .form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(calc(var(--space-5) * 8), 1fr));
    gap: var(--space-3);
}

/* The checkout's choices: whole-card radios. The chosen one is marked by a thicker border, not by colour alone (the radio is also ticked). */
body.theme-default .choice-group {
    margin: 0;
    padding: var(--space-4);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
}
body.theme-default .choice-group > legend {
    padding-inline: var(--space-2);
    font-weight: var(--font-weight-bold);
}
body.theme-default .choice-grid {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
}
body.theme-default .choice-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}
body.theme-default .choice {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    cursor: pointer;
}
body.theme-default .choice-grid .choice {
    flex: 1 1 calc(var(--space-5) * 8);
}
body.theme-default .choice:has(input:checked) {
    border-color: var(--color-primary);
    border-width: calc(var(--border-width) * 2);
}
body.theme-default .choice input[type="radio"] {
    flex: none;
    inline-size: var(--space-4);
    block-size: var(--space-4);
    margin-block-start: var(--space-1);
}

/* The order's stages: a row of steps on a wide screen that turns into a vertical list on a phone. */
body.theme-default .stages {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(calc(var(--space-5) * 3.5), 1fr));
    gap: var(--space-3);
}
body.theme-default .stage {
    display: flex;
    flex-direction: column;
    gap: var(--space-1);
    padding-block-start: var(--space-2);
    border-block-start: calc(var(--border-width) * 3) solid var(--color-border);
    color: var(--color-muted);
}
body.theme-default .stage--done {
    border-block-start-color: var(--color-primary);
    color: inherit;
}
body.theme-default .stage--current strong {
    color: var(--color-primary);
}
@media (max-width: 40rem) {
    body.theme-default .stages {
        grid-template-columns: 1fr;
    }
    body.theme-default .stage {
        border-block-start: 0;
        border-inline-start: calc(var(--border-width) * 3) solid var(--color-border);
        padding-block-start: 0;
        padding-inline-start: var(--space-3);
    }
    body.theme-default .stage--done {
        border-inline-start-color: var(--color-primary);
    }
}

/* ------------------------------------------------------------ PRINT REQUESTS (V2 step 5) */

/* The small page furniture the print pages share with the order page and the address book. They had no rule of their own, so a
   heading and its "back" link, a facts list and a help line all fell back to the browser's defaults. Logical properties and tokens only. */
body.theme-default .row-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: var(--space-3);
}
body.theme-default .hint {
    color: var(--color-muted);
}
body.theme-default dl.detail-rows {
    display: grid;
    grid-template-columns: minmax(8rem, max-content) 1fr;
    gap: var(--space-2) var(--space-3);
    margin: 0;
}
body.theme-default dl.detail-rows dt {
    color: var(--color-muted);
    font-weight: var(--font-weight-bold);
}
body.theme-default dl.detail-rows dd {
    margin: 0;
}
body.theme-default .actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-3);
}
body.theme-default .table-scroll {
    overflow-x: auto;
}
body.theme-default .plain-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: var(--space-2);
}
@media (max-width: 40rem) {
    body.theme-default dl.detail-rows {
        grid-template-columns: 1fr;
        gap: 0;
    }
    body.theme-default dl.detail-rows dd {
        margin-block-end: var(--space-2);
    }
}

/* ===================================================== SHOP IDENTITY (V2 step 6, slice 2) */

/* THE PALETTE LIVES IN TWO PLACES, and this is the second one. The tokens `ServiceTheme` knows (`color.bg`, `color.primary`, …) are
   set in `theme.json` for the light page; a token the theme does not define cannot be added there (an unknown key fails closed), so
   the colours the shop needs beyond them are custom properties here, and the DARK page re-declares both sets under
   `prefers-color-scheme`. Every other rule in this file (and every later block) uses a variable, never a literal colour.
   Measured contrast of each pair is in `store-customer/screens/home/DESIGN.md`; none is below 4.5:1. */
body.theme-default {
    --brand-strong: #4a26c9;
    --brand-tint: #ece8ff;
    --accent-green: #21d19f;
    --accent-blue: #6ccff6;
    --accent-yellow: #f0e100;
    --ink: #00272b;
    --footer-bg: #00272b;
    --footer-fg: #e8f1f1;
    --footer-muted: #b9cccd;
    --footer-line: #2c4146;
}

@media (prefers-color-scheme: dark) {
    body.theme-default {
        --color-bg: #0b1517;
        --color-surface: #112023;
        --color-fg: #e8f1f1;
        --color-muted: #b9cccd;
        --color-border: #2c4146;
        --color-primary: #a99bff;
        --color-primary-fg: #00272b;
        --color-focus: #c4baff;
        --color-danger: #ff8a8f;
        --color-danger-fg: #00272b;
        --color-success: #5fd39a;
        --color-warning: #f0c24a;
        --brand-strong: #c4baff;
        --brand-tint: #1a2a33;
        --footer-bg: #071012;
    }
}

body.theme-default .app-brand {
    display: inline-flex;
    align-items: center;
}

body.theme-default .brand-full img {
    display: block;
    block-size: 3rem;
    inline-size: auto;
}

body.theme-default .brand-mark {
    display: none;
    block-size: 2.75rem;
    inline-size: 2.75rem;
}

body.theme-default .app-nav {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-1);
    flex: 1 1 auto;
}

body.theme-default .app-nav a,
body.theme-default .tool {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    min-block-size: var(--layout-field-height);
    padding-inline: var(--space-3);
    border-radius: var(--radius-md);
    box-sizing: border-box;
    text-decoration: none;
    font-weight: var(--font-weight-bold);
    color: var(--color-fg);
}

body.theme-default .app-nav a:hover,
body.theme-default .tool:hover {
    background: var(--brand-tint);
    color: var(--brand-strong);
}

body.theme-default .tool-main {
    background: var(--color-primary);
    color: var(--color-primary-fg);
}

body.theme-default .tool-main:hover {
    background: var(--brand-strong);
    color: var(--color-primary-fg);
}

body.theme-default .app-tools {
    margin-inline-start: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
}

body.theme-default .app-tools .lang-switch {
    margin-inline-start: 0;
}

/* The count is a number on a green disc with ink on it (8.06:1); the basket link's own label says what it is. */
body.theme-default .cart-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-inline-size: 1.4rem;
    block-size: 1.4rem;
    padding-inline: var(--space-1);
    box-sizing: border-box;
    border-radius: 999px;
    background: var(--accent-green);
    color: var(--ink);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-bold);
}

body.theme-default .app-footer {
    margin-block-start: var(--space-5);
    background: var(--footer-bg);
    color: var(--footer-fg);
}

body.theme-default .footer-grid {
    max-inline-size: var(--layout-max-width);
    margin-inline: auto;
    padding: var(--space-5) var(--space-4);
    display: grid;
    grid-template-columns: 1.4fr repeat(3, minmax(0, 1fr));
    gap: var(--space-4);
}

body.theme-default .app-footer img {
    display: block;
    block-size: 3.25rem;
    inline-size: auto;
}

body.theme-default .app-footer h2 {
    margin: 0 0 var(--space-2);
    font-size: 1.05rem;
    font-weight: var(--font-weight-bold);
    color: var(--footer-fg);
}

body.theme-default .app-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

body.theme-default .app-footer a {
    display: inline-block;
    padding-block: var(--space-1);
    color: var(--footer-fg);
    text-decoration: none;
}

body.theme-default .app-footer a:hover {
    text-decoration: underline;
}

body.theme-default .footer-copy {
    max-inline-size: var(--layout-max-width);
    margin: 0 auto;
    padding: var(--space-3) var(--space-4);
    border-block-start: var(--border-width) solid var(--footer-line);
    color: var(--footer-muted);
    font-size: var(--font-size-sm);
    box-sizing: border-box;
}

@media (max-width: 1000px) {
    body.theme-default .footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* Phone width: the round mark replaces the horizontal logo, and the links drop to their own row. */
@media (max-width: 700px) {
    body.theme-default .brand-full {
        display: none;
    }

    body.theme-default .brand-mark {
        display: block;
    }

    body.theme-default .app-nav {
        order: 3;
        flex-basis: 100%;
    }

    body.theme-default .footer-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ======================================================= HOME PAGE (V2 step 6, slice 3) */

body.theme-default .home-hero {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: var(--space-4);
    align-items: center;
    padding-block: var(--space-4);
}

body.theme-default .home-hero h1 {
    margin: 0;
    font-size: 2.6rem;
    line-height: 1.25;
}

body.theme-default .home-hero p {
    margin: var(--space-3) 0 0;
    max-inline-size: 36rem;
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--color-muted);
}

body.theme-default .home-hero__art {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-4);
    border-radius: var(--radius-md);
    background: var(--brand-tint);
}

body.theme-default .home-hero__art img {
    block-size: 12rem;
    inline-size: auto;
}

body.theme-default .home-cats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-3);
}

body.theme-default .home-cat {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    padding: var(--space-4);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    color: var(--color-fg);
    text-decoration: none;
}

body.theme-default .home-cat:hover {
    border-color: var(--color-primary);
}

body.theme-default .home-cat h2 {
    margin: 0;
    font-size: 1.5rem;
}

body.theme-default .home-cat__ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    inline-size: 3.25rem;
    block-size: 3.25rem;
    border-radius: var(--radius-md);
    background: var(--brand-tint);
    color: var(--color-primary);
}

body.theme-default .home-cat__go {
    margin-block-start: auto;
    font-weight: var(--font-weight-bold);
    color: var(--brand-strong);
}

body.theme-default .home-sec {
    margin-block-start: var(--space-5);
}

body.theme-default .home-sec h2 {
    margin: 0;
    font-size: 1.75rem;
}

/* The heading row sits a step above its grid (found by walking the page: they touched). */
body.theme-default .home-sec .row-between {
    margin-block-end: var(--space-3);
}

body.theme-default .home-pic {
    position: relative;
}

/* A badge is a word on a coloured pill with ink on it (8.06:1 on green, 8.98:1 on blue), never colour alone. */
body.theme-default .home-badge {
    position: absolute;
    inset-block-start: var(--space-2);
    inset-inline-start: var(--space-2);
    padding: var(--space-1) var(--space-3);
    border-radius: 999px;
    color: var(--ink);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-bold);
}

body.theme-default .home-badge--new {
    background: var(--accent-blue);
}

body.theme-default .home-badge--restock {
    background: var(--accent-green);
}

@media (max-width: 1000px) {
    body.theme-default .home-hero {
        grid-template-columns: minmax(0, 1fr);
    }

    body.theme-default .home-cats {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 700px) {
    body.theme-default .home-hero h1 {
        font-size: 2rem;
    }

    body.theme-default .home-hero__art img {
        block-size: 8rem;
    }
}

/* ======================================================= SIGN-UP FORM (V2 step 6, slice 5) */

/* The hidden field a person never fills: out of sight, out of the tab order and the reading order (visibility: hidden), still a real input that is submitted. */
body.theme-default .trap {
    visibility: hidden;
    position: absolute;
    inset-inline-start: -10000px;
    inline-size: 1px;
    block-size: 1px;
    overflow: hidden;
}

/* ======================================================= PRODUCTS MENU AND SEARCH (header-search) */

/* Text for a screen reader only (the search box's label). */
body.theme-default .visually-hidden {
    position: absolute;
    inline-size: 1px;
    block-size: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
}

/* «Products»: a native disclosure. The panel opens under the item and never leaves the screen (it is as wide as its content, capped). */
body.theme-default .menu-products {
    position: relative;
}
body.theme-default .menu-products summary {
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    min-block-size: var(--layout-field-height);
    padding-inline: var(--space-3);
    border-radius: var(--radius-md);
    box-sizing: border-box;
    cursor: pointer;
    font-weight: var(--font-weight-bold);
    list-style: none;
}
body.theme-default .menu-products summary::-webkit-details-marker {
    display: none;
}
body.theme-default .menu-products summary::after {
    content: "";
    inline-size: 0.5em;
    block-size: 0.5em;
    border-inline-end: 2px solid currentColor;
    border-block-end: 2px solid currentColor;
    transform: rotate(45deg) translateY(-25%);
}
body.theme-default .menu-products[open] summary::after {
    transform: rotate(-135deg);
}
body.theme-default .menu-products summary:hover,
body.theme-default .menu-products[open] summary {
    background: var(--brand-tint);
    color: var(--brand-strong);
}
body.theme-default .menu-panel {
    position: absolute;
    inset-block-start: 100%;
    inset-inline-start: 0;
    z-index: 20;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
    gap: var(--space-4);
    inline-size: max-content;
    max-inline-size: min(40rem, 92vw);
    padding: var(--space-4);
    background: var(--color-surface);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
}
body.theme-default .menu-group h2 {
    margin: 0 0 var(--space-2);
    font-size: var(--font-size);
    color: var(--color-muted);
}
body.theme-default .menu-group ul {
    margin: 0;
    padding: 0;
    list-style: none;
}
body.theme-default .menu-group a {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--space-2);
    min-block-size: var(--layout-field-height);
    padding-inline: var(--space-2);
    border-radius: var(--radius-md);
    box-sizing: border-box;
    text-decoration: none;
    font-weight: normal;
}
body.theme-default .menu-group a[aria-current="true"] {
    background: var(--brand-tint);
    color: var(--brand-strong);
    font-weight: var(--font-weight-bold);
}
body.theme-default .menu-here {
    font-size: 0.85em;
}

/* The header's search: one field and a button; it takes the spare width of the line. */
body.theme-default .app-search {
    display: flex;
    flex: 1 1 14rem;
    gap: var(--space-2);
    align-items: center;
    max-inline-size: 28rem;
}
body.theme-default .app-search input[type="search"] {
    flex: 1 1 auto;
    min-inline-size: 0;
    min-block-size: var(--layout-field-height);
    box-sizing: border-box;
    padding-inline: var(--space-3);
    border: var(--border-width) solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-surface);
    color: var(--color-fg);
}

/* The results: ONE column of rows at every width - picture, name and kind, price and availability, action. */
body.theme-default .search-list {
    display: grid;
    gap: var(--space-3);
    margin: 0;
    padding: 0;
    list-style: none;
}
body.theme-default .search-row {
    display: grid;
    grid-template-columns: 4.5rem minmax(0, 1fr) auto auto;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-3);
}
body.theme-default .search-row__pic {
    inline-size: 4.5rem;
    block-size: 4.5rem;
    border-radius: var(--radius-md);
    overflow: hidden;
}
body.theme-default .search-row__price {
    display: grid;
    gap: var(--space-1);
    justify-items: end;
}
body.theme-default .chip--kind {
    color: var(--color-muted);
}
body.theme-default .search-pages {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: var(--space-3);
}

@media (max-width: 700px) {
    /* the search sits on its own full-width row under the logo line; «Products» is a row that unfolds in the page flow */
    body.theme-default .app-search {
        order: 4;
        flex-basis: 100%;
        max-inline-size: none;
    }
    body.theme-default .menu-products,
    body.theme-default .menu-products summary {
        inline-size: 100%;
    }
    body.theme-default .menu-panel {
        position: static;
        inline-size: auto;
        max-inline-size: none;
        grid-template-columns: minmax(0, 1fr);
    }
    body.theme-default .search-row {
        grid-template-columns: 4.5rem minmax(0, 1fr);
    }
    body.theme-default .search-row__price,
    body.theme-default .search-row__action {
        grid-column: 1 / -1;
        justify-items: start;
    }
}
