/* ==========================================================================
   BMW Group Digital Spec Stands: admin styles

   Written as plain CSS (custom properties, no Sass nesting or variables) so
   Web Compiler's output in wwwroot/css/site.css matches this file.

   Design tokens are taken from the Store Admin Figma screens (2026-10-15).
   They are approximations for the design lead to correct (plan G11).
   Compare against /Home/Styleguide in Development.

   Brand (2026-11-27): the BMW Group TN fonts, the BMW Group Canada logo and the
   BMW Group gradient, used as in the BMW Group Canada tools.
   ========================================================================== */

/* ---------- Fonts: BMW Group TN and BMW Group TN Condensed (wwwroot/fonts) ---------- */

@font-face {
    font-family: "BMW Group TN";
    src: url("../fonts/Normal%20OTF/BMWGroupTN-Thin.woff2") format("woff2"), url("../fonts/Normal%20OTF/BMWGroupTN-Thin.woff") format("woff");
    font-weight: 100;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN";
    src: url("../fonts/Normal%20OTF/BMWGroupTN-Light.woff2") format("woff2"), url("../fonts/Normal%20OTF/BMWGroupTN-Light.woff") format("woff");
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN";
    src: url("../fonts/Normal%20OTF/BMWGroupTN-Regular.woff2") format("woff2"), url("../fonts/Normal%20OTF/BMWGroupTN-Regular.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN";
    src: url("../fonts/Normal%20OTF/BMWGroupTN-Medium.woff2") format("woff2"), url("../fonts/Normal%20OTF/BMWGroupTN-Medium.woff") format("woff");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN";
    src: url("../fonts/Normal%20OTF/BMWGroupTN-Bold.woff2") format("woff2"), url("../fonts/Normal%20OTF/BMWGroupTN-Bold.woff") format("woff");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN Condensed";
    src: url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Thin.woff2") format("woff2"), url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Thin.woff") format("woff");
    font-weight: 100;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN Condensed";
    src: url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Light.woff2") format("woff2"), url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Light.woff") format("woff");
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN Condensed";
    src: url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Regular.woff2") format("woff2"), url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Regular.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN Condensed";
    src: url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Medium.woff2") format("woff2"), url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Medium.woff") format("woff");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "BMW Group TN Condensed";
    src: url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Bold.woff2") format("woff2"), url("../fonts/Condensed%20Pro%20OTF/BMWGroupTNCondensedPro-Bold.woff") format("woff");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* ---------- Tokens ---------- */

:root {
    /* Colour */
    --ds-color-bg: #ffffff;
    --ds-color-text: #262626;
    /* WCAG AA for text (Phase 5): muted 5.1:1 on the hatched unused rows; subtle was #8e8e8e (3.3:1), now 4.85:1 on surface. */
    --ds-color-text-muted: #636363;
    --ds-color-text-subtle: #6b6b6b;
    --ds-color-border: #e6e6e6;
    --ds-color-border-strong: #d4d4d4;
    --ds-color-surface: #f4f4f4;
    --ds-color-row-hover: #fafafa;
    --ds-color-hatch: #ededed;
    /* BMW Group's dark teal, where its gradient starts: 9.3:1 with white. */
    --ds-color-primary: #2e4b55;
    --ds-color-primary-hover: #1f353d;
    --ds-color-on-primary: #ffffff;
    /* Chosen options (role cards, ticked stores): the gradient's middle teal at 12% on white. */
    --ds-color-primary-surface: #eaf6f5;
    --ds-color-inverse: #262626;
    --ds-color-on-inverse: #ffffff;
    --ds-color-online: #2e9e55;
    --ds-color-online-surface: #c8efd3;
    --ds-color-online-text: #1d6b3a;
    --ds-color-offline: #b0b0b0;
    --ds-color-focus: #2e4b55;
    --ds-color-danger: #c62828;
    --ds-color-danger-hover: #a31f1f;
    --ds-color-danger-surface: #fdecec;
    --ds-color-danger-border: #f3c5c5;
    --ds-color-danger-text: #9f1d1d;
    --ds-color-warning-surface: #fff4d6;
    --ds-color-warning-border: #f2d58a;
    --ds-color-warning-text: #7a5600;
    --ds-color-info-surface: #eef4fc;
    --ds-color-info-border: #c9daf5;
    --ds-color-info-text: #1d4f91;
    --ds-color-success-border: #a6e3b8;

    /* BMW Group's gradient. Only for surfaces and accents: white text fails on its middle and end (2.5:1, 1.5:1). */
    --ds-gradient-brand: linear-gradient(to bottom right, #2e4b55, #51b4ad, #a1dad6);

    /* Type, as in the BMW Group Canada tools: BMW Group TN for text, the menu, labels and buttons (regular; bold and
       widely spaced capitals for overlines); BMW Group TN Condensed for titles and figures (regular; light capitals for
       the product's name). */
    --ds-font-family: "BMW Group TN", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --ds-font-family-condensed: "BMW Group TN Condensed", "BMW Group TN", "Arial Narrow", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --ds-font-size-xs: 0.6875rem;  /* 11px: overlines, table headings, buttons */
    --ds-font-size-sm: 0.8125rem;  /* 13px: table cells, secondary text */
    --ds-font-size-base: 0.875rem; /* 14px */
    --ds-font-size-lg: 1.25rem;    /* 20px: field values, vehicle names */
    --ds-font-size-xl: 1.5rem;     /* 24px: card and section titles */
    --ds-font-size-2xl: 1.75rem;   /* 28px: figures, the product's name */
    --ds-font-size-3xl: 2rem;      /* 32px: page titles */
    --ds-font-weight-light: 300;
    --ds-font-weight-regular: 400;
    --ds-font-weight-medium: 500;
    --ds-font-weight-bold: 700;
    --ds-letter-spacing-overline: 0.1em;
    --ds-letter-spacing-wide: 0.25em; /* Section overlines ("Last store sync"). */

    /* Space */
    --ds-space-1: 0.25rem;
    --ds-space-2: 0.5rem;
    --ds-space-3: 0.75rem;
    --ds-space-4: 1rem;
    --ds-space-5: 1.5rem;
    --ds-space-6: 2rem;
    --ds-space-7: 3rem;

    /* Shape and layout */
    --ds-radius-sm: 4px;
    --ds-radius-md: 6px;
    --ds-radius-lg: 12px;
    --ds-radius-pill: 999px;
    --ds-focus-ring: 0 0 0 3px rgba(46, 75, 85, 0.25);
    --ds-shadow-raised: 0 8px 24px rgba(0, 0, 0, 0.12);
    --ds-header-height: 5.5rem;
    --ds-container-max: 73.75rem;

    /* Bootstrap bridge, so Bootstrap components (forms) pick up the tokens */
    --bs-body-font-family: var(--ds-font-family);
    --bs-body-font-size: var(--ds-font-size-base);
    --bs-body-color: var(--ds-color-text);
    --bs-body-bg: var(--ds-color-bg);
    --bs-border-color: var(--ds-color-border);
}

/* ---------- Base ---------- */

html {
    position: relative;
    min-height: 100%;
    font-size: 16px;
}

body {
    margin: 0;
    font-family: var(--ds-font-family);
    font-size: var(--ds-font-size-base);
    color: var(--ds-color-text);
    background: var(--ds-color-bg);
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
    font-family: var(--ds-font-family-condensed);
    font-weight: var(--ds-font-weight-regular);
}

a {
    color: var(--ds-color-primary);
}

:focus-visible {
    outline: 2px solid var(--ds-color-focus);
    outline-offset: 2px;
}

.ds-visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}

.ds-skip-link {
    position: absolute;
    top: -100px;
    left: var(--ds-space-4);
    z-index: 10;
    padding: var(--ds-space-2) var(--ds-space-4);
    background: var(--ds-color-inverse);
    color: var(--ds-color-on-inverse);
    border-radius: var(--ds-radius-sm);
}

.ds-skip-link:focus {
    top: var(--ds-space-2);
}

/* ---------- Header ---------- */

.ds-header {
    background: var(--ds-color-bg);
}

/* BMW Group's gradient as a line under the header (and the Master Admin menu). */
.ds-header::after {
    content: "";
    display: block;
    height: 4px;
    background: var(--ds-gradient-brand);
}

.ds-header__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-5);
    min-height: var(--ds-header-height);
    padding: var(--ds-space-3) var(--ds-space-5);
}

/* The BMW Group Canada logo at the top left, then the product's name. */
.ds-brand {
    display: flex;
    align-items: center;
    gap: var(--ds-space-5);
    color: var(--ds-color-text);
    text-decoration: none;
}

.ds-brand:hover {
    color: var(--ds-color-text);
}

/* One file: BMW Group Canada, the BMW roundel and MINI. */
.ds-brand__logo {
    display: block;
    flex: none;
    width: auto;
    height: 3rem;
}

/* As the BMW Group Canada tools title their pages: condensed, light, in capitals. */
.ds-brand__product {
    padding-left: var(--ds-space-5);
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-2xl);
    font-weight: var(--ds-font-weight-light);
    line-height: 1;
    text-transform: uppercase;
    white-space: nowrap;
    border-left: 1px solid var(--ds-color-border-strong);
}

.ds-header__store {
    display: flex;
    align-items: center;
    min-height: 1.5rem;
    padding-left: var(--ds-space-5);
    border-left: 1px solid var(--ds-color-border-strong);
}

.ds-header__user {
    display: flex;
    align-items: center;
    gap: var(--ds-space-5);
    margin-left: auto;
    font-size: var(--ds-font-size-sm);
}

.ds-header__email {
    color: var(--ds-color-text-muted);
}

.ds-header__signout-form {
    margin: 0;
}

/* A button (sign-out is a POST) styled as the design's text link. */
.ds-header__signout {
    padding: 0;
    font: inherit;
    font-weight: var(--ds-font-weight-bold);
    color: var(--ds-color-text);
    text-decoration: none;
    background: none;
    border: 0;
    cursor: pointer;
}

.ds-header__signout:hover {
    text-decoration: underline;
}

.ds-lang-toggle {
    color: var(--ds-color-text);
    text-decoration: none;
}

.ds-lang-toggle:hover {
    text-decoration: underline;
}

/* Store switcher: the store name in the header opens a list of the admin's stores. */
.ds-header__store.ds-switcher {
    position: relative;
    display: block;
}

.ds-switcher summary {
    list-style: none;
    cursor: pointer;
}

.ds-switcher summary::-webkit-details-marker {
    display: none;
}

.ds-switcher summary::after {
    content: " \25BE";
    color: var(--ds-color-text-muted);
}

.ds-switcher__menu {
    position: absolute;
    top: 100%;
    left: var(--ds-space-3);
    z-index: 20;
    min-width: 16rem;
    margin: var(--ds-space-2) 0 0;
    padding: var(--ds-space-2) 0;
    list-style: none;
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.ds-switcher__menu a {
    display: block;
    padding: var(--ds-space-2) var(--ds-space-4);
    color: var(--ds-color-text);
    text-decoration: none;
}

.ds-switcher__menu a:hover,
.ds-switcher__menu a[aria-current="page"] {
    background: var(--ds-color-surface);
}

/* ---------- Master Admin navigation ---------- */

.ds-nav {
    border-top: 1px solid var(--ds-color-border);
}

.ds-nav__list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--ds-space-1);
    margin: 0;
    padding: var(--ds-space-2) var(--ds-space-4);
    list-style: none;
}

/* As the BMW Group Canada tools' menu: regular, slightly spaced; the current page in a box. */
.ds-nav__link {
    display: inline-block;
    padding: var(--ds-space-2) var(--ds-space-3);
    font-size: var(--ds-font-size-base);
    letter-spacing: 0.03em;
    color: var(--ds-color-text-muted);
    text-decoration: none;
    border-radius: var(--ds-radius-sm);
}

.ds-nav__link:hover {
    color: var(--ds-color-text);
    background: var(--ds-color-row-hover);
}

.ds-nav__link[aria-current="page"] {
    font-weight: var(--ds-font-weight-medium);
    color: var(--ds-color-text);
    background: var(--ds-color-surface);
}

/* ---------- Page ---------- */

.ds-main {
    padding: var(--ds-space-6) var(--ds-space-5) var(--ds-space-7);
}

.ds-container {
    max-width: var(--ds-container-max);
    margin: 0 auto;
}

.ds-page-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: var(--ds-space-4);
    margin-bottom: var(--ds-space-5);
}

.ds-page-title {
    margin: 0;
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-3xl);
    font-weight: var(--ds-font-weight-regular);
    line-height: 1.15;
}

.ds-page-subtitle {
    margin: var(--ds-space-1) 0 0;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

/* A title edited in place (the tablet's name): a pencil beside it, and a small form in its place while editing. */
.ds-title-edit {
    min-width: 0;
}

.ds-title-edit__view {
    display: flex;
    align-items: center;
    gap: var(--ds-space-2);
}

.ds-title-edit__view .ds-page-title {
    cursor: text;
}

.ds-title-edit__button {
    display: inline-flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    color: var(--ds-color-text-muted);
    border-radius: var(--ds-radius-sm);
}

.ds-title-edit__button:hover,
.ds-title-edit__button:focus-visible {
    color: var(--ds-color-text);
    background: var(--ds-color-surface);
}

.ds-title-edit__form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-2);
    margin: 0;
}

.ds-title-edit__form .ds-input {
    width: min(24rem, 100%);
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-xl);
}

.ds-title-edit__form .ds-help,
.ds-title-edit__form .ds-error {
    flex-basis: 100%;
    margin-top: 0;
}

.ds-title-edit__view[hidden],
.ds-title-edit__form[hidden] {
    display: none;
}

.ds-back {
    display: inline-block;
    margin-bottom: var(--ds-space-2);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
    text-decoration: none;
}

.ds-back:hover {
    color: var(--ds-color-text);
}

.ds-section-title {
    margin: var(--ds-space-7) 0 var(--ds-space-4);
    padding-bottom: var(--ds-space-2);
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-xl);
    font-weight: var(--ds-font-weight-regular);
    border-bottom: 1px solid var(--ds-color-border);
}

/* ---------- Licence meter ---------- */

.ds-meter {
    min-width: 13rem;
    padding: var(--ds-space-3) var(--ds-space-4);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-meter__label {
    margin-bottom: var(--ds-space-2);
    font-size: var(--ds-font-size-xs);
    color: var(--ds-color-text-muted);
}

.ds-meter__label strong {
    color: var(--ds-color-text);
}

/* A <progress> element, so no inline width style is needed (the CSP blocks inline styles). */
.ds-meter__bar {
    display: block;
    width: 100%;
    height: 4px;
    border: 0;
    border-radius: var(--ds-radius-pill);
    background: var(--ds-color-border);
    color: var(--ds-color-primary);
    -webkit-appearance: none;
    appearance: none;
    overflow: hidden;
}

.ds-meter__bar::-webkit-progress-bar {
    background: var(--ds-color-border);
    border-radius: var(--ds-radius-pill);
}

/* The used part in BMW Group's gradient. */
.ds-meter__bar::-webkit-progress-value {
    background: var(--ds-gradient-brand);
    border-radius: var(--ds-radius-pill);
}

.ds-meter__bar::-moz-progress-bar {
    background: var(--ds-gradient-brand);
    border-radius: var(--ds-radius-pill);
}

/* ---------- Filter chips ---------- */

.ds-chips {
    display: flex;
    flex-wrap: wrap;
    gap: var(--ds-space-2);
    margin: 0 0 var(--ds-space-4);
    padding: 0;
    list-style: none;
}

.ds-chip {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: var(--ds-space-1) var(--ds-space-4);
    font: inherit;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-pill);
    text-decoration: none;
    cursor: pointer;
}

.ds-chip:hover {
    border-color: var(--ds-color-text);
}

.ds-chip.is-active,
.ds-chip[aria-pressed="true"],
.ds-chip[aria-current="true"] {
    color: var(--ds-color-on-inverse);
    background: var(--ds-color-inverse);
    border-color: var(--ds-color-inverse);
}

/* ---------- Table ---------- */

.ds-table-wrap {
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
    overflow: hidden;
}

.ds-table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--ds-font-size-sm);
}

.ds-table th {
    padding: var(--ds-space-3) var(--ds-space-4);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-align: left;
    text-transform: uppercase;
    white-space: nowrap;
    color: var(--ds-color-text-muted);
    border-bottom: 1px solid var(--ds-color-border);
}

.ds-table td {
    padding: var(--ds-space-3) var(--ds-space-4);
    vertical-align: middle;
    border-bottom: 1px solid var(--ds-color-border);
}

.ds-table tbody tr:last-child td {
    border-bottom: 0;
}

.ds-table tbody tr.is-clickable {
    position: relative;
    cursor: pointer;
}

.ds-table tbody tr.is-clickable:hover td {
    background-color: var(--ds-color-row-hover);
}

/* The row's main link covers the whole row. */
.ds-stretched-link {
    color: inherit;
    text-decoration: none;
}

.ds-stretched-link::after {
    content: "";
    position: absolute;
    inset: 0;
}

.ds-table__id {
    font-weight: var(--ds-font-weight-bold);
    white-space: nowrap;
}

.ds-table__secondary {
    display: block;
    margin-top: 2px;
    font-size: var(--ds-font-size-xs);
    color: var(--ds-color-text-muted);
}

.ds-table__muted {
    color: var(--ds-color-text-subtle);
}

.ds-table__chevron {
    width: 2.5rem;
    text-align: right;
    color: var(--ds-color-text-subtle);
}

.ds-table__row--unused td {
    color: var(--ds-color-text-muted);
    background-image: repeating-linear-gradient(-45deg, var(--ds-color-hatch) 0, var(--ds-color-hatch) 1px, transparent 1px, transparent 8px);
}

/* Buttons in a clickable row sit above the row's stretched link. */
.ds-table td .ds-btn {
    position: relative;
    z-index: 1;
}

/* ---------- Status ---------- */

.ds-status {
    display: inline-flex;
    align-items: center;
    gap: var(--ds-space-2);
    white-space: nowrap;
}

.ds-status::before,
.ds-pill::before {
    content: "";
    flex: none;
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    background: var(--ds-color-offline);
}

.ds-status--online::before,
.ds-pill--online::before {
    background: var(--ds-color-online);
}

.ds-status--offline {
    color: var(--ds-color-text-subtle);
}

.ds-pill {
    display: inline-flex;
    align-items: center;
    gap: var(--ds-space-2);
    padding: var(--ds-space-2) var(--ds-space-4);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-pill);
}

.ds-pill--online {
    color: var(--ds-color-online-text);
    background: var(--ds-color-online-surface);
}

/* ---------- Cards and fields ---------- */

.ds-detail {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: var(--ds-space-4);
    align-items: start;
}

.ds-card {
    padding: var(--ds-space-5);
    background: var(--ds-color-surface);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-overline {
    margin: 0 0 var(--ds-space-2);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-wide);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

/* Buttons under a card's fields (Adjust screen fit). */
.ds-card__actions {
    margin-top: var(--ds-space-4);
}

.ds-card__title {
    margin: 0;
    padding-bottom: var(--ds-space-3);
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-xl);
    font-weight: var(--ds-font-weight-regular);
    border-bottom: 1px solid var(--ds-color-border-strong);
}

.ds-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: var(--ds-space-5);
    margin: 0;
}

.ds-field {
    padding: var(--ds-space-4) 0;
    border-bottom: 1px solid var(--ds-color-border-strong);
}

.ds-field:nth-last-child(-n+2) {
    border-bottom: 0;
}

.ds-field dt {
    margin: 0 0 var(--ds-space-1);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

.ds-field dd {
    margin: 0;
    font-size: var(--ds-font-size-lg);
}

/* ---------- Inputs ---------- */

.ds-input {
    display: block;
    width: 100%;
    padding: var(--ds-space-2) var(--ds-space-3);
    font: inherit;
    font-size: var(--ds-font-size-base);
    color: var(--ds-color-text);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-sm);
}

.ds-input:focus {
    border-color: var(--ds-color-focus);
}

.ds-input::placeholder {
    color: var(--ds-color-text-subtle);
}

/* The large search box on the tablet detail screen. */
.ds-input--lg {
    padding: var(--ds-space-3) var(--ds-space-4);
    font-size: var(--ds-font-size-lg);
}

.ds-input--code {
    max-width: 12rem;
    font-size: var(--ds-font-size-lg);
    letter-spacing: 0.2em;
}

.ds-input--number {
    max-width: 10rem;
}

/* ---------- Forms ---------- */

.ds-form {
    margin: 0;
}

.ds-form-group {
    min-width: 0;
    margin: 0 0 var(--ds-space-4);
    padding: 0;
    border: 0;
}

.ds-form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: var(--ds-space-4);
}

.ds-label {
    display: block;
    margin-bottom: var(--ds-space-1);
    padding: 0;
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

.ds-help {
    margin: var(--ds-space-1) 0 0;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

.ds-error {
    display: block;
    margin-top: var(--ds-space-1);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-danger-text);
}

.ds-error-summary ul {
    margin: 0 0 var(--ds-space-4);
    padding: var(--ds-space-3) var(--ds-space-4) var(--ds-space-3) var(--ds-space-6);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-danger-text);
    background: var(--ds-color-danger-surface);
    border: 1px solid var(--ds-color-danger-border);
    border-radius: var(--ds-radius-md);
}

/* ASP.NET renders an empty summary when there are no errors; hide it (its inline style is blocked by the CSP). */
.validation-summary-valid {
    display: none;
}

.ds-check {
    display: flex;
    align-items: flex-start;
    gap: var(--ds-space-2);
    margin-bottom: var(--ds-space-2);
    cursor: pointer;
}

.ds-check input {
    margin-top: 3px;
}

.ds-checklist {
    max-height: 16rem;
    padding: var(--ds-space-3);
    overflow-y: auto;
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-sm);
}

/* Choices as cards, one per row, each with what it means (the user's role). */
.ds-choices {
    display: grid;
    gap: var(--ds-space-2);
}

.ds-choice {
    display: flex;
    align-items: flex-start;
    gap: var(--ds-space-3);
    margin: 0;
    padding: var(--ds-space-3) var(--ds-space-4);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-md);
    cursor: pointer;
}

.ds-choice:hover {
    border-color: var(--ds-color-text);
}

.ds-choice:has(input:checked) {
    background: var(--ds-color-primary-surface);
    border-color: var(--ds-color-primary);
    box-shadow: inset 0 0 0 1px var(--ds-color-primary);
}

.ds-choice input {
    flex: none;
    width: 1rem;
    height: 1rem;
    margin: 2px 0 0;
    accent-color: var(--ds-color-primary);
}

.ds-choice__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.ds-choice__name {
    font-weight: var(--ds-font-weight-medium);
}

.ds-choice__help {
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

/* The store picker (user forms; site.js, [data-store-picker]): search, brand and "Selected" filters, Select all, then
   the stores, a row each. */
.ds-picker__box {
    margin-top: var(--ds-space-2);
    overflow: hidden;
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-md);
}

.ds-picker__tools {
    padding: var(--ds-space-3);
    background: var(--ds-color-surface);
}

.ds-picker__find {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-2) var(--ds-space-3);
}

.ds-picker__search {
    flex: 1 1 14rem;
    width: auto;
    min-width: 0;
}

.ds-picker__filters {
    flex: none;
    margin: 0;
}

.ds-picker__bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--ds-space-2) var(--ds-space-4);
    margin-top: var(--ds-space-3);
    font-size: var(--ds-font-size-sm);
}

.ds-picker__count {
    margin: 0;
    color: var(--ds-color-text-muted);
}

.ds-picker__actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--ds-space-4);
}

.ds-picker__action {
    padding: 0;
    font: inherit;
    font-weight: var(--ds-font-weight-medium);
    color: var(--ds-color-primary);
    background: none;
    border: 0;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}

.ds-picker__action:hover {
    color: var(--ds-color-primary-hover);
}

.ds-picker__action[aria-disabled="true"] {
    color: var(--ds-color-text-subtle);
    text-decoration: none;
    cursor: default;
}

.ds-picker__list {
    max-height: 22rem;
    margin: 0;
    padding: 0;
    overflow-y: auto;
    list-style: none;
}

.ds-picker__item {
    border-top: 1px solid var(--ds-color-border);
}

.ds-picker__tools[hidden] + .ds-picker__list > .ds-picker__item:first-child {
    border-top: 0;
}

.ds-picker__option {
    display: flex;
    align-items: center;
    gap: var(--ds-space-3);
    margin: 0;
    padding: var(--ds-space-2) var(--ds-space-3);
    cursor: pointer;
}

.ds-picker__option:hover {
    background: var(--ds-color-row-hover);
}

.ds-picker__option:has(input:checked) {
    background: var(--ds-color-primary-surface);
}

.ds-picker__option input {
    flex: none;
    width: 1rem;
    height: 1rem;
    margin: 0;
    accent-color: var(--ds-color-primary);
}

.ds-picker__text {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-width: 0;
}

.ds-picker__name {
    font-weight: var(--ds-font-weight-medium);
}

.ds-picker__meta {
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

.ds-picker__empty {
    margin: 0;
    padding: var(--ds-space-5) var(--ds-space-3);
    color: var(--ds-color-text-muted);
    text-align: center;
    border-top: 1px solid var(--ds-color-border);
}

.ds-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-3);
}

.ds-actions form {
    margin: 0;
}

.ds-link {
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-primary);
}

.ds-lead {
    max-width: 40rem;
    margin: var(--ds-space-2) 0 var(--ds-space-5);
    color: var(--ds-color-text-muted);
}

.ds-narrow {
    max-width: 40rem;
}

/* ---------- Sign-in pages ---------- */

/* The page on BMW Group's gradient, under the header; only the card on it holds text. A browser without :has() keeps
   the white page. */
body:has(.ds-auth) {
    background: var(--ds-gradient-brand);
}

/* A card: title and fields, then a full-width divider with the main button across the card and links under it. */
.ds-auth {
    max-width: 28rem;
    margin: var(--ds-space-6) auto;
    padding: var(--ds-space-6);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-lg);
    box-shadow: var(--ds-shadow-raised);
}

.ds-auth--wide {
    max-width: 36rem;
}

.ds-auth .ds-actions {
    flex-direction: column;
    align-items: stretch;
    margin: var(--ds-space-5) calc(-1 * var(--ds-space-6)) 0;
    padding: var(--ds-space-5) var(--ds-space-6) 0;
    text-align: center;
    border-top: 1px solid var(--ds-color-border);
}

.ds-auth__footer {
    margin: 0;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

/* "Lost access to your authenticator app?": a link-like toggle with the answer under it. */
.ds-disclosure {
    margin: 0;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

.ds-disclosure summary {
    display: inline-block;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
}

.ds-disclosure summary::-webkit-details-marker {
    display: none;
}

.ds-disclosure p {
    margin: var(--ds-space-2) 0 0;
}

/* ---------- Verification code boxes (site.js, input[data-otp]) ---------- */

.ds-otp {
    position: relative;
}

.ds-otp__slots {
    display: flex;
    align-items: center;
    gap: var(--ds-space-3);
}

.ds-otp__group {
    display: flex;
    flex: 1 1 0;
    min-width: 0;
}

.ds-otp__slot {
    position: relative;
    display: flex;
    flex: 1 1 0;
    align-items: center;
    justify-content: center;
    min-width: 0;
    height: 3.5rem;
    margin-left: -1px;
    font-size: var(--ds-font-size-xl);
    font-variant-numeric: tabular-nums;
    color: var(--ds-color-text);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
}

.ds-otp__slot:first-child {
    margin-left: 0;
    border-radius: var(--ds-radius-md) 0 0 var(--ds-radius-md);
}

.ds-otp__slot:last-child {
    border-radius: 0 var(--ds-radius-md) var(--ds-radius-md) 0;
}

.ds-otp__slot.is-active {
    z-index: 1;
    border-color: var(--ds-color-focus);
    box-shadow: var(--ds-focus-ring);
}

/* A blinking caret in the empty box being typed into. */
.ds-otp__slot.is-active:empty::after {
    content: "";
    width: 1px;
    height: 1.5rem;
    background: var(--ds-color-text);
    animation: ds-caret 1s step-end infinite;
}

.ds-otp__separator {
    flex: 0 0 auto;
    width: 0.75rem;
    height: 2px;
    background: var(--ds-color-text);
}

.ds-otp.is-invalid .ds-otp__slot {
    border-color: var(--ds-color-danger);
}

/* The real input lies over the boxes, invisible: it takes the typing, pasting and autofill. */
.ds-otp__input.ds-input {
    position: absolute;
    inset: 0;
    width: 100%;
    max-width: none;
    height: 100%;
    padding: 0;
    font-size: 16px; /* No zoom on iOS. */
    letter-spacing: 0;
    color: transparent;
    -webkit-text-fill-color: transparent;
    caret-color: transparent;
    background: transparent;
    border: 0;
    cursor: text;
}

.ds-otp__input:focus-visible {
    outline: none; /* The active box shows the focus. */
}

.ds-otp__input::selection {
    background: transparent;
}

@keyframes ds-caret {
    50% {
        opacity: 0;
    }
}

/* ---------- Password fields (site.js) ---------- */

.ds-password {
    position: relative;
}

.ds-password .ds-input {
    padding-right: 5rem;
}

.ds-password input::-ms-reveal {
    display: none;
}

.ds-password__toggle {
    position: absolute;
    top: 50%;
    right: var(--ds-space-1);
    padding: var(--ds-space-1) var(--ds-space-2);
    font: inherit;
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-primary);
    background: transparent;
    border: 0;
    border-radius: var(--ds-radius-sm);
    transform: translateY(-50%);
    cursor: pointer;
}

.ds-password__toggle:hover {
    background: var(--ds-color-surface);
}

/* The new-password rules; with script each one is ticked off as it's met. */
.ds-rules {
    margin-top: var(--ds-space-2);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

.ds-rules__label {
    margin: 0 0 var(--ds-space-1);
}

.ds-rules ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2px var(--ds-space-3);
    margin: 0;
    padding: 0;
    list-style: none;
}

.ds-rules li {
    position: relative;
    padding-left: 1.25rem;
}

.ds-rules li::before {
    content: "";
    position: absolute;
    top: 0.45em;
    left: 0.25rem;
    width: 0.4rem;
    height: 0.4rem;
    background: var(--ds-color-border-strong);
    border-radius: 50%;
}

.ds-rules.is-live li.is-met {
    color: var(--ds-color-online-text);
}

.ds-rules.is-live li.is-met::before {
    content: "\2713";
    top: 0;
    left: 0.1rem;
    width: auto;
    height: auto;
    font-weight: var(--ds-font-weight-bold);
    background: none;
    border-radius: 0;
}

.ds-mfa {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-5);
    margin-bottom: var(--ds-space-5);
}

.ds-qr {
    width: 200px;
    height: 200px;
    padding: var(--ds-space-2);
    background: #ffffff;
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-sm);
}

.ds-code {
    padding: 2px 6px;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text);
    background: var(--ds-color-surface);
    border-radius: 3px;
}

.ds-code--wrap {
    display: block;
    padding: var(--ds-space-2);
    word-break: break-all;
}

/* ---------- Tablet actions and pairing codes ---------- */

.ds-detail-actions {
    margin-bottom: var(--ds-space-4);
}

.ds-pairing {
    display: grid;
    gap: var(--ds-space-4);
    margin: 0 0 var(--ds-space-4);
}

.ds-pairing__item {
    padding: var(--ds-space-4) var(--ds-space-5);
    background: var(--ds-color-surface);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-pairing__item dt {
    margin-bottom: var(--ds-space-1);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

.ds-pairing__code {
    margin: 0;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: var(--ds-font-size-2xl);
    letter-spacing: 0.08em;
}

.ds-pairing__code--digits {
    letter-spacing: 0.2em;
}

.ds-pairing__expiry {
    margin: 0 0 var(--ds-space-5);
    font-weight: var(--ds-font-weight-bold);
}

.ds-pairing__copy {
    margin: var(--ds-space-2) 0 0;
}

/* "Waiting for the tablet to pair…" while site.js watches for it. */
.ds-pairing__watch {
    display: flex;
    align-items: center;
    gap: var(--ds-space-2);
    margin: calc(-1 * var(--ds-space-3)) 0 var(--ds-space-5);
    color: var(--ds-color-text-muted);
}

.ds-pairing__watch::before {
    content: "";
    flex: 0 0 auto;
    width: 0.875rem;
    height: 0.875rem;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: ds-spin 0.8s linear infinite;
}

/* ---------- Copy buttons (site.js, [data-copy]) ---------- */

.ds-copyable {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-2);
}

.ds-copy {
    padding: 2px var(--ds-space-2);
    font: inherit;
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-primary);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-sm);
    cursor: pointer;
}

.ds-copy:hover {
    border-color: var(--ds-color-primary);
}

.ds-copy.is-done {
    color: var(--ds-color-online-text);
    border-color: var(--ds-color-success-border);
}

/* Relative times ("5 min ago") show the exact time on hover. */
time[title] {
    text-decoration: underline dotted var(--ds-color-border-strong);
    text-underline-offset: 3px;
    cursor: help;
}

/* ---------- Search and toolbars ---------- */

.ds-search {
    max-width: 36rem;
    margin-bottom: var(--ds-space-4);
}

.ds-search__row {
    display: flex;
    gap: var(--ds-space-2);
}

.ds-search__row .ds-input {
    flex: 1 1 auto;
    min-width: 0;
}

/* The search inside a card (Change vehicle). */
.ds-search--flush {
    max-width: none;
}

/* A second row of cards under the first. */
.ds-detail--spaced {
    margin-top: var(--ds-space-4);
}

.ds-vehicle form {
    margin: 0;
}

/* A line of summary text with actions, under a section title. */
.ds-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--ds-space-3);
    margin-bottom: var(--ds-space-4);
}

.ds-toolbar p {
    margin: 0;
    color: var(--ds-color-text-muted);
}

/* ---------- Alerts ---------- */

.ds-alert {
    margin: 0 0 var(--ds-space-4);
    padding: var(--ds-space-3) var(--ds-space-4);
    font-size: var(--ds-font-size-sm);
    border: 1px solid transparent;
    border-radius: var(--ds-radius-md);
}

.ds-alert p:last-child {
    margin-bottom: 0;
}

.ds-alert--success {
    color: var(--ds-color-online-text);
    background: var(--ds-color-online-surface);
    border-color: var(--ds-color-success-border);
}

.ds-alert--error {
    color: var(--ds-color-danger-text);
    background: var(--ds-color-danger-surface);
    border-color: var(--ds-color-danger-border);
}

.ds-alert--warning {
    color: var(--ds-color-warning-text);
    background: var(--ds-color-warning-surface);
    border-color: var(--ds-color-warning-border);
}

.ds-alert--info {
    color: var(--ds-color-info-text);
    background: var(--ds-color-info-surface);
    border-color: var(--ds-color-info-border);
}

/* ---------- Badges ---------- */

.ds-badges {
    display: inline-flex;
    flex-wrap: wrap;
    gap: var(--ds-space-1);
}

.ds-badge {
    display: inline-block;
    padding: 2px var(--ds-space-2);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    white-space: nowrap;
    color: var(--ds-color-text-muted);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-pill);
}

.ds-badge--success {
    color: var(--ds-color-online-text);
    background: var(--ds-color-online-surface);
}

.ds-badge--warning {
    color: var(--ds-color-warning-text);
    background: var(--ds-color-warning-surface);
}

.ds-badge--danger {
    color: var(--ds-color-danger-text);
    background: var(--ds-color-danger-surface);
}

/* ---------- Overview stats and sync status ---------- */

.ds-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
    gap: var(--ds-space-4);
    margin: 0 0 var(--ds-space-5);
    padding: 0;
    list-style: none;
}

.ds-stat__link {
    display: block;
    padding: var(--ds-space-4) var(--ds-space-5);
    color: var(--ds-color-text);
    text-decoration: none;
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-stat__link:hover {
    color: var(--ds-color-text);
    border-color: var(--ds-color-text);
}

.ds-stat__value {
    display: block;
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-2xl);
    font-weight: var(--ds-font-weight-light);
}

.ds-stat__label {
    display: block;
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

/* Facts rather than links (the tablet detail's Tablet ID, last seen...): label first, a smaller value, no hover. */
.ds-stats--facts {
    grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
    gap: var(--ds-space-3);
}

.ds-stat__box {
    height: 100%;
    padding: var(--ds-space-3) var(--ds-space-4);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-stats--facts .ds-stat__value {
    margin-top: var(--ds-space-1);
    font-size: var(--ds-font-size-lg);
    font-weight: var(--ds-font-weight-regular);
}

/* Reports (C-026): the period and store in a row, the button at their foot; numbers right-aligned in tables. */
.ds-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: var(--ds-space-3);
    margin: 0 0 var(--ds-space-2);
}

.ds-filters .ds-form-group {
    margin: 0;
}

.ds-filters .ds-input {
    width: auto;
    min-width: 11rem;
}

.ds-report-note {
    margin: 0 0 var(--ds-space-4);
}

/* Eight figures in a row on a desktop screen. */
.ds-stats--report {
    grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr));
}

/* A table's totals row. */
.ds-table tfoot th,
.ds-table tfoot td {
    padding: var(--ds-space-3) var(--ds-space-4);
    font-weight: var(--ds-font-weight-bold);
    border-top: 1px solid var(--ds-color-border-strong);
}

/* A table wider than the page scrolls sideways instead of losing its last columns; its headings may wrap. */
.ds-table-wrap--scroll {
    overflow-x: auto;
}

.ds-table-wrap--scroll th {
    white-space: normal;
}

.ds-table th.ds-table__num,
.ds-table td.ds-table__num {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.ds-table td.ds-table__num {
    white-space: nowrap;
}

.ds-sync {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: var(--ds-space-4);
    margin-bottom: var(--ds-space-5);
}

.ds-sync form {
    margin: 0;
}

.ds-sync__result {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-2);
    margin: 0;
}

.ds-sync__when {
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
}

.ds-sync .ds-help {
    margin: var(--ds-space-2) 0 0;
}

/* ---------- Empty states and lists ---------- */

.ds-empty {
    padding: var(--ds-space-7) var(--ds-space-5);
    text-align: center;
    border: 1px dashed var(--ds-color-border-strong);
    border-radius: var(--ds-radius-md);
}

.ds-empty__title {
    margin: 0 0 var(--ds-space-2);
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-xl);
}

.ds-empty .ds-lead,
.ds-empty-text {
    margin-left: auto;
    margin-right: auto;
    color: var(--ds-color-text-muted);
}

.ds-plain-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.ds-plain-list li {
    padding: var(--ds-space-2) 0;
    border-bottom: 1px solid var(--ds-color-border);
}

.ds-pagination {
    display: flex;
    justify-content: space-between;
    gap: var(--ds-space-3);
    margin-top: var(--ds-space-4);
}

.ds-nowrap {
    white-space: nowrap;
}

.ds-audit-details {
    display: block;
    max-width: 32rem;
    font-family: ui-monospace, SFMono-Regular, Consolas, "Liberation Mono", monospace;
    font-size: var(--ds-font-size-xs);
    word-break: break-word;
    color: var(--ds-color-text-muted);
}

/* ---------- Vehicle list ---------- */

.ds-vehicle-list {
    margin: var(--ds-space-2) 0 0;
    padding: 0;
    list-style: none;
}

.ds-vehicle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--ds-space-4);
    padding: var(--ds-space-4) 0;
    border-bottom: 1px solid var(--ds-color-border-strong);
}

.ds-vehicle:last-child {
    border-bottom: 0;
}

.ds-vehicle__name {
    margin: 0;
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-xl);
    font-weight: var(--ds-font-weight-regular);
}

.ds-vehicle__meta {
    margin: var(--ds-space-1) 0 0;
    font-size: var(--ds-font-size-xs);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

.ds-vehicle__active {
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-subtle);
}

/* ---------- Buttons ---------- */

.ds-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--ds-space-2);
    min-height: 2.5rem;
    padding: var(--ds-space-2) var(--ds-space-4);
    font: inherit;
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    line-height: 1.2;
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    text-decoration: none;
    white-space: nowrap;
    border: 1px solid transparent;
    border-radius: var(--ds-radius-sm);
    cursor: pointer;
}

.ds-btn--primary {
    color: var(--ds-color-on-primary);
    background: var(--ds-color-primary);
}

.ds-btn--primary:hover {
    color: var(--ds-color-on-primary);
    background: var(--ds-color-primary-hover);
}

.ds-btn--secondary {
    color: var(--ds-color-text);
    background: var(--ds-color-bg);
    border-color: var(--ds-color-border-strong);
}

.ds-btn--secondary:hover {
    border-color: var(--ds-color-text);
}

.ds-btn--danger {
    color: #ffffff;
    background: var(--ds-color-danger);
}

.ds-btn--danger:hover {
    color: #ffffff;
    background: var(--ds-color-danger-hover);
}

.ds-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* The button that sent a form, while the next page loads (site.js). */
.ds-btn.is-busy,
.ds-btn.is-busy:disabled {
    opacity: 1;
    cursor: progress;
}

.ds-btn.is-busy::before {
    content: "";
    flex: 0 0 auto;
    width: 0.875rem;
    height: 0.875rem;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: ds-spin 0.7s linear infinite;
}

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

/* ---------- Toasts (site.js turns success messages into these) ---------- */

.ds-toasts {
    position: fixed;
    right: var(--ds-space-5);
    bottom: var(--ds-space-5);
    z-index: 1080;
    display: flex;
    flex-direction: column;
    gap: var(--ds-space-2);
    width: min(24rem, calc(100vw - 2 * var(--ds-space-4)));
    pointer-events: none;
}

.ds-toast.ds-alert {
    position: relative;
    margin: 0;
    padding-right: var(--ds-space-7);
    box-shadow: var(--ds-shadow-raised);
    pointer-events: auto;
    transition: opacity 0.2s, transform 0.2s;
    animation: ds-toast-in 0.2s ease-out;
}

.ds-toast.is-leaving {
    opacity: 0;
    transform: translateY(0.5rem);
}

.ds-toast__close {
    position: absolute;
    top: 50%;
    right: var(--ds-space-2);
    width: 1.75rem;
    height: 1.75rem;
    padding: 0;
    font-size: 1.25rem;
    line-height: 1;
    color: inherit;
    background: transparent;
    border: 0;
    border-radius: var(--ds-radius-sm);
    transform: translateY(-50%);
    cursor: pointer;
}

.ds-toast__close:hover {
    background: rgba(0, 0, 0, 0.06);
}

@keyframes ds-toast-in {
    from {
        opacity: 0;
        transform: translateY(0.5rem);
    }
}

@media (prefers-reduced-motion: reduce) {
    .ds-btn.is-busy::before,
    .ds-pairing__watch::before,
    .ds-otp__slot.is-active:empty::after {
        animation: none;
    }

    .ds-toast.ds-alert {
        transition: none;
        animation: none;
    }
}

/* ---------- Access requests (C-035) ---------- */

.ds-textarea {
    min-height: 7.5rem;
    resize: vertical;
}

/* The request form's trap for scripts: off screen and out of the way; people never see or reach it. */
.ds-trap {
    position: absolute;
    left: -10000px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

/* A number beside a title or a menu item (pending access requests). */
.ds-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.5rem;
    height: 1.5rem;
    padding: 0 var(--ds-space-2);
    font-family: var(--ds-font-family);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    line-height: 1;
    color: var(--ds-color-on-primary);
    background: var(--ds-color-primary);
    border-radius: var(--ds-radius-pill);
    vertical-align: middle;
}

.ds-nav__count {
    margin-left: var(--ds-space-2);
    min-width: 1.25rem;
    height: 1.25rem;
}

.ds-requests {
    margin-bottom: var(--ds-space-6);
    padding: var(--ds-space-5);
    background: var(--ds-color-primary-surface);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-requests__title {
    display: flex;
    align-items: center;
    gap: var(--ds-space-2);
    margin: 0;
    font-size: var(--ds-font-size-xl);
}

.ds-requests > .ds-help {
    max-width: 50rem;
    margin: var(--ds-space-2) 0 var(--ds-space-4);
}

.ds-requests__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

/* One request: who, what they asked for, and Invite / Dismiss. */
.ds-request {
    display: grid;
    grid-template-columns: minmax(0, 16rem) minmax(0, 1fr) auto;
    gap: var(--ds-space-5);
    align-items: start;
    padding: var(--ds-space-4);
    background: var(--ds-color-bg);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-request + .ds-request {
    margin-top: var(--ds-space-2);
}

.ds-request p {
    margin: 0;
}

.ds-request .ds-request__name {
    font-weight: var(--ds-font-weight-bold);
}

.ds-request .ds-request__meta {
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
    overflow-wrap: anywhere;
}

.ds-request__who .ds-badge {
    margin-top: var(--ds-space-2);
}

.ds-request .ds-overline {
    margin-bottom: var(--ds-space-1);
}

/* What they typed, as text: their line breaks kept, long words broken. */
.ds-request__text {
    white-space: pre-line;
    overflow-wrap: anywhere;
}

.ds-request__actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--ds-space-2);
    justify-content: flex-end;
}

.ds-request__actions form {
    margin: 0;
}

/* The invite page's reminder of the request it answers. */
.ds-request-note {
    margin-bottom: var(--ds-space-5);
}

.ds-request-note p {
    margin: 0;
}

.ds-request-note .ds-request-note__title {
    margin-bottom: var(--ds-space-1);
    font-weight: var(--ds-font-weight-bold);
}

@media (max-width: 991.98px) {
    .ds-request {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--ds-space-3);
    }

    .ds-request__actions {
        justify-content: flex-start;
    }
}

/* ---------- Guide (C-034) ---------- */

/* The header's link to the guide, on every page of a store, beside the language toggle. */
.ds-header__guide {
    display: inline-flex;
    align-items: center;
    gap: var(--ds-space-1);
    color: var(--ds-color-text);
    text-decoration: none;
}

.ds-header__guide:hover {
    text-decoration: underline;
}

.ds-header__guide[aria-current="page"] {
    font-weight: var(--ds-font-weight-bold);
}

/* The Pair page's link to the guide, just under its lead. */
.ds-guide-link {
    margin: calc(-1 * var(--ds-space-3)) 0 var(--ds-space-5);
}

.ds-guide__header {
    margin-bottom: var(--ds-space-6);
}

.ds-guide__header .ds-lead {
    max-width: 46rem;
    margin-bottom: 0;
}

/* The contents on the left, kept in view; the guide on the right at a reading width. */
.ds-guide__layout {
    display: grid;
    grid-template-columns: minmax(0, 15rem) minmax(0, 1fr);
    gap: var(--ds-space-7);
    align-items: start;
}

.ds-guide__toc {
    position: sticky;
    top: var(--ds-space-5);
    max-height: calc(100vh - 2 * var(--ds-space-5));
    overflow-y: auto;
    font-size: var(--ds-font-size-sm);
}

/* On a wide screen the contents is always open: its title is just a title. */
.ds-guide__toc-details > summary {
    list-style: none;
    pointer-events: none;
}

.ds-guide__toc-details > summary::-webkit-details-marker {
    display: none;
}

.ds-guide__toc-part {
    margin: var(--ds-space-4) 0 var(--ds-space-2);
    font-weight: var(--ds-font-weight-bold);
}

.ds-guide__toc-list {
    margin: 0;
    padding: 0;
    list-style: none;
    border-left: 1px solid var(--ds-color-border);
}

.ds-guide__toc-list a {
    display: block;
    margin-left: -1px;
    padding: var(--ds-space-1) var(--ds-space-3);
    color: var(--ds-color-text-muted);
    text-decoration: none;
    border-left: 2px solid transparent;
}

.ds-guide__toc-list a:hover {
    color: var(--ds-color-text);
}

/* The section being read (site.js). */
.ds-guide__toc-list a[aria-current="true"] {
    color: var(--ds-color-primary);
    font-weight: var(--ds-font-weight-medium);
    border-left-color: var(--ds-color-primary);
}

.ds-guide__content {
    max-width: 46rem;
    font-size: 0.9375rem;
    line-height: 1.6;
}

.ds-guide__section > p {
    margin: 0 0 var(--ds-space-4);
}

.ds-guide__content code {
    padding: 1px var(--ds-space-1);
    font-size: 0.9em;
    color: var(--ds-color-text);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-sm);
}

/* A part of the guide (set up, use): like the product's name in the header, under BMW Group's gradient. */
.ds-guide__part {
    margin: var(--ds-space-7) 0 var(--ds-space-5);
    padding-top: var(--ds-space-4);
    font-size: var(--ds-font-size-2xl);
    font-weight: var(--ds-font-weight-light);
    line-height: 1.15;
    text-transform: uppercase;
    border-top: 4px solid transparent;
    border-image: var(--ds-gradient-brand) 1;
}

.ds-guide__part:first-child {
    margin-top: 0;
}

.ds-guide__section {
    margin-bottom: var(--ds-space-7);
    scroll-margin-top: var(--ds-space-5);
}

.ds-guide__title {
    margin: 0 0 var(--ds-space-4);
    padding-bottom: var(--ds-space-2);
    font-size: var(--ds-font-size-xl);
    line-height: 1.2;
    border-bottom: 1px solid var(--ds-color-border);
}

.ds-guide__subtitle {
    margin: var(--ds-space-5) 0 var(--ds-space-3);
    font-family: var(--ds-font-family);
    font-size: 1rem;
    font-weight: var(--ds-font-weight-bold);
    scroll-margin-top: var(--ds-space-5);
}

/* Steps: numbered circles in the brand's teal. */
.ds-guide__steps {
    margin: 0 0 var(--ds-space-4);
    padding: 0;
    list-style: none;
    counter-reset: ds-guide-step;
}

.ds-guide__steps > li {
    position: relative;
    min-height: 1.75rem;
    margin-bottom: var(--ds-space-3);
    padding-left: 2.5rem;
    counter-increment: ds-guide-step;
}

.ds-guide__steps > li::before {
    content: counter(ds-guide-step);
    position: absolute;
    top: -0.125rem;
    left: 0;
    display: grid;
    place-items: center;
    width: 1.75rem;
    height: 1.75rem;
    font-size: var(--ds-font-size-sm);
    font-weight: var(--ds-font-weight-bold);
    line-height: 1;
    color: var(--ds-color-on-primary);
    background: var(--ds-color-primary);
    border-radius: 50%;
}

.ds-guide__list {
    margin: 0 0 var(--ds-space-4);
    padding-left: 1.25rem;
}

.ds-guide__list > li {
    margin-bottom: var(--ds-space-2);
}

/* What to have or check: each item with an empty box to tick off. */
.ds-guide__checklist {
    margin: 0 0 var(--ds-space-4);
    padding: 0;
    list-style: none;
}

.ds-guide__checklist > li {
    position: relative;
    margin-bottom: var(--ds-space-2);
    padding: var(--ds-space-3) var(--ds-space-4) var(--ds-space-3) 2.75rem;
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-md);
}

.ds-guide__checklist > li::before {
    content: "";
    position: absolute;
    top: calc(var(--ds-space-3) + 0.25rem);
    left: var(--ds-space-4);
    width: 1rem;
    height: 1rem;
    border: 2px solid var(--ds-color-primary);
    border-radius: var(--ds-radius-sm);
}

.ds-guide__note {
    margin: 0 0 var(--ds-space-4);
    font-size: inherit;
}

.ds-guide__note p {
    margin: 0;
}

/* The tablet app's address: its QR code (with the 4-module quiet zone it needs) and the address to copy. */
.ds-guide__app {
    display: flex;
    align-items: center;
    gap: var(--ds-space-5);
    margin-top: var(--ds-space-5);
}

.ds-guide__app-qr {
    flex: none;
    width: 160px;
    height: 160px;
    padding: 18px;
    background: #ffffff;
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-sm);
}

.ds-guide__app-text {
    min-width: 0;
}

.ds-guide__app-url {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--ds-space-2);
    margin: 0 0 var(--ds-space-2);
}

.ds-guide__content .ds-guide__app-url code {
    padding: 0;
    font-size: var(--ds-font-size-lg);
    word-break: break-all;
    background: none;
}

.ds-guide__app .ds-help {
    margin: 0;
}

.ds-guide__figure {
    margin: var(--ds-space-5) 0;
    padding: var(--ds-space-5);
    background: var(--ds-color-surface);
    border-radius: var(--ds-radius-md);
}

.ds-guide__figure figcaption {
    margin-top: var(--ds-space-4);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
    text-align: center;
}

.ds-guide__figure--fit {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ds-guide-fit {
    display: block;
    max-width: 100%;
    height: auto;
}

/* The pairing figure: the admin's two codes, an arrow, and the tablet's two fields, in the screens' own words. */
.ds-guide-pairing {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: var(--ds-space-4);
    line-height: 1.3;
}

.ds-guide-pairing p,
.ds-guide-pairing dl,
.ds-guide-pairing dd {
    margin: 0;
}

.ds-guide-pairing__screen {
    background: var(--ds-color-bg);
}

.ds-guide-pairing__screen--admin {
    width: 14rem;
    padding: var(--ds-space-4);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-md);
}

.ds-guide-pairing__screen--tablet {
    width: 11rem;
    padding: var(--ds-space-4) var(--ds-space-3);
    border: 8px solid var(--ds-color-inverse);
    border-radius: 18px;
}

.ds-guide-pairing .ds-guide-pairing__device {
    margin-bottom: var(--ds-space-2);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    letter-spacing: var(--ds-letter-spacing-overline);
    text-transform: uppercase;
    color: var(--ds-color-text-muted);
}

.ds-guide-pairing__codes dt {
    margin-top: var(--ds-space-3);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    color: var(--ds-color-text-muted);
}

.ds-guide-pairing__codes dd {
    font-family: var(--ds-font-family-condensed);
    font-size: var(--ds-font-size-lg);
    letter-spacing: 0.04em;
}

.ds-guide-pairing .ds-guide-pairing__digits {
    letter-spacing: 0.15em;
}

.ds-guide-pairing .ds-guide-pairing__title {
    margin-bottom: var(--ds-space-2);
    font-family: var(--ds-font-family-condensed);
    font-size: 1.0625rem;
}

.ds-guide-pairing .ds-guide-pairing__label {
    margin: var(--ds-space-2) 0 2px;
    font-size: 0.625rem;
    font-weight: var(--ds-font-weight-bold);
    color: var(--ds-color-text-muted);
}

.ds-guide-pairing__field {
    padding: 3px var(--ds-space-2);
    font-size: var(--ds-font-size-sm);
    border: 1px solid var(--ds-color-border-strong);
    border-radius: var(--ds-radius-sm);
}

.ds-guide-pairing .ds-guide-pairing__button {
    margin-top: var(--ds-space-3);
    padding: var(--ds-space-1);
    font-size: var(--ds-font-size-xs);
    font-weight: var(--ds-font-weight-bold);
    text-align: center;
    color: var(--ds-color-on-inverse);
    background: var(--ds-color-inverse);
    border-radius: var(--ds-radius-sm);
}

.ds-guide-pairing__arrow {
    color: var(--ds-color-primary);
}

.ds-guide-pairing__arrow svg {
    display: block;
}

/* A term and what it means: the Tablets page's columns and statuses. */
.ds-guide__terms {
    margin: 0 0 var(--ds-space-5);
    border-top: 1px solid var(--ds-color-border);
}

.ds-guide__terms > div {
    display: grid;
    grid-template-columns: 9rem minmax(0, 1fr);
    gap: var(--ds-space-4);
    padding: var(--ds-space-3) 0;
    border-bottom: 1px solid var(--ds-color-border);
}

.ds-guide__terms dt {
    font-weight: var(--ds-font-weight-bold);
}

.ds-guide__terms dd {
    margin: 0;
}

.ds-guide__terms--statuses > div {
    align-items: center;
}

.ds-guide__terms--statuses dt {
    font-weight: var(--ds-font-weight-regular);
}

/* An unused licence as its row looks on the Tablets page: muted text on the hatching. */
.ds-guide__unused {
    display: inline-block;
    padding: var(--ds-space-2) var(--ds-space-3);
    font-size: var(--ds-font-size-sm);
    color: var(--ds-color-text-muted);
    background-image: repeating-linear-gradient(-45deg, var(--ds-color-hatch) 0, var(--ds-color-hatch) 1px, transparent 1px, transparent 8px);
    border: 1px solid var(--ds-color-border);
    border-radius: var(--ds-radius-sm);
}

/* Problems and what to do: the first column is the row's heading, in the table's text style. */
.ds-guide__table {
    margin: 0 0 var(--ds-space-5);
}

.ds-guide__table .ds-table {
    font-size: var(--ds-font-size-sm);
    line-height: 1.5;
}

.ds-guide__table tbody th {
    width: 40%;
    font-size: inherit;
    font-weight: var(--ds-font-weight-medium);
    letter-spacing: normal;
    text-transform: none;
    white-space: normal;
    color: var(--ds-color-text);
    vertical-align: top;
}

.ds-guide__table tbody td {
    vertical-align: top;
}

.ds-guide__table tbody tr:last-child th {
    border-bottom: 0;
}

@media (max-width: 991.98px) {
    .ds-guide__layout {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--ds-space-5);
    }

    /* Above the guide: a card that opens and closes (folded at first by site.js). */
    .ds-guide__toc {
        position: static;
        max-height: none;
        padding: var(--ds-space-3) var(--ds-space-4);
        background: var(--ds-color-surface);
        border-radius: var(--ds-radius-md);
    }

    .ds-guide__toc-details > summary {
        margin: 0;
        padding: var(--ds-space-1) 0;
        pointer-events: auto;
        cursor: pointer;
    }

    .ds-guide__toc-details > summary::after {
        content: " \25BE";
        letter-spacing: 0;
    }

    .ds-guide__toc-details[open] > summary::after {
        content: " \25B4";
    }
}

@media (max-width: 767.98px) {
    .ds-guide__app {
        flex-direction: column;
        align-items: flex-start;
    }

    .ds-guide__terms > div {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--ds-space-1);
    }

    /* The admin above the tablet, the arrow pointing down between them. */
    .ds-guide-pairing {
        flex-direction: column;
    }

    .ds-guide-pairing__arrow {
        transform: rotate(90deg);
    }

    /* The tables stack like the admin's others; the row's heading too. */
    .ds-guide__table tbody th {
        display: block;
        width: 100%;
        padding: var(--ds-space-1) 0;
        border-bottom: 0;
    }

    .ds-guide__table tbody th[data-label]::before {
        content: attr(data-label);
        display: block;
        font-size: var(--ds-font-size-xs);
        font-weight: var(--ds-font-weight-bold);
        letter-spacing: var(--ds-letter-spacing-overline);
        text-transform: uppercase;
        color: var(--ds-color-text-muted);
    }
}

/* Printed, the guide alone: no header or contents, and the step numbers in colour. */
@media print {
    body:has(.ds-guide) .ds-header,
    body:has(.ds-guide) .ds-skip-link,
    .ds-guide__toc {
        display: none;
    }

    body:has(.ds-guide) .ds-main {
        padding: 0;
    }

    .ds-guide__layout {
        display: block;
    }

    .ds-guide__content {
        max-width: none;
    }

    .ds-guide__content a {
        color: inherit;
        text-decoration: none;
    }

    .ds-guide__steps > li::before,
    .ds-guide__part {
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .ds-guide__figure,
    .ds-guide__app,
    .ds-guide__table tr,
    .ds-guide__checklist > li,
    .ds-guide__steps > li {
        break-inside: avoid;
    }

    .ds-guide__title,
    .ds-guide__subtitle {
        break-after: avoid;
    }
}

/* ---------- Bootstrap form tweaks (from the template) ---------- */

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
    box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem var(--ds-color-focus);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}

/* ---------- Responsive ---------- */

/* The product's name only where the header has room for it beside the store and the user (one row): the logo alone
   below that. */
@media (max-width: 1199.98px) {
    .ds-brand__product {
        display: none;
    }
}

@media (max-width: 991.98px) {
    .ds-detail {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 767.98px) {
    :root {
        --ds-header-height: 4rem;
    }

    .ds-header__inner {
        gap: var(--ds-space-3);
        padding: var(--ds-space-2) var(--ds-space-4);
    }

    .ds-header__store {
        padding-left: var(--ds-space-3);
    }

    .ds-header__email {
        display: none;
    }

    .ds-brand__logo {
        height: 2.25rem;
    }

    .ds-nav__list {
        padding: var(--ds-space-2);
    }

    .ds-form-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .ds-main {
        padding: var(--ds-space-5) var(--ds-space-4) var(--ds-space-6);
    }

    .ds-meter {
        width: 100%;
    }

    .ds-auth {
        margin: 0 auto;
        padding: var(--ds-space-5);
    }

    .ds-auth .ds-actions {
        margin-right: calc(-1 * var(--ds-space-5));
        margin-left: calc(-1 * var(--ds-space-5));
        padding-right: var(--ds-space-5);
        padding-left: var(--ds-space-5);
    }

    .ds-otp__slots {
        gap: var(--ds-space-2);
    }

    .ds-otp__slot {
        height: 3rem;
    }

    .ds-rules ul {
        grid-template-columns: minmax(0, 1fr);
    }

    .ds-toasts {
        right: var(--ds-space-4);
        bottom: var(--ds-space-4);
        left: var(--ds-space-4);
        width: auto;
    }

    /* Tables become stacked cards; each cell shows its column name from data-label. */
    .ds-table thead {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        white-space: nowrap;
    }

    .ds-table, .ds-table tbody, .ds-table tr, .ds-table td {
        display: block;
        width: 100%;
    }

    .ds-table tbody tr {
        padding: var(--ds-space-3) var(--ds-space-4);
        border-bottom: 1px solid var(--ds-color-border);
    }

    .ds-table tbody tr:last-child {
        border-bottom: 0;
    }

    .ds-table td {
        padding: var(--ds-space-1) 0;
        border-bottom: 0;
    }

    .ds-table td[data-label]::before {
        content: attr(data-label);
        display: block;
        font-size: var(--ds-font-size-xs);
        font-weight: var(--ds-font-weight-bold);
        letter-spacing: var(--ds-letter-spacing-overline);
        text-transform: uppercase;
        color: var(--ds-color-text-muted);
    }

    .ds-table td.ds-table__chevron {
        display: none;
    }

    .ds-fields {
        grid-template-columns: minmax(0, 1fr);
    }

    .ds-field:nth-last-child(2) {
        border-bottom: 1px solid var(--ds-color-border-strong);
    }

    .ds-vehicle {
        flex-wrap: wrap;
    }
}
