/* Mondial Auto design system — shared by occasion / voiture / garage / admin.
   Themes: body.theme-light (public portal) and body.theme-dark (garage space + CRM). Any element can carry a theme class.
   Live reference of every component: /styleguide.html */
@import url("https://fonts.googleapis.com/css2?family=Barlow+Condensed:ital,wght@0,700;1,800&family=Barlow:wght@400;500;600&family=Rubik:ital,wght@0,400;0,500;0,600;0,700;0,800;1,700;1,800&display=swap");
/* Barlow's ₪ is drawn below x-height and turns into a blob at body sizes: borrow it from a system sans (Barlow Condensed's is fine). */
@font-face { font-family: "MA Shekel"; unicode-range: U+20AA; font-weight: 100 549;
  src: local("Arial"), local("ArialMT"), local("Roboto"), local("Roboto-Regular"), local("Segoe UI"), local("SegoeUI"); }
@font-face { font-family: "MA Shekel"; unicode-range: U+20AA; font-weight: 550 1000;
  src: local("Arial Bold"), local("Arial-BoldMT"), local("Roboto Medium"), local("Roboto-Medium"), local("Segoe UI Semibold"), local("SegoeUI-Semibold"); }

/* ---------- tokens ---------- */
:root {
  --red: #E3141B; --red-600: #c40f15; --red-50: rgba(227,20,27,.08); --ink: #141011; --bg: #0d0a0b; --surface: #151112; --surface-2: #1d1718;
  --line: rgba(255,255,255,.09); --text: #f6f2f1; --muted: #a89e9e; --ok: #1fb86a; --warn: #f0a020; --radius: 14px;

  --info: #3b82f6;
  --radius-sm: 10px; --radius-lg: 22px;
  --font-display: "Barlow Condensed", "Rubik", "Arial Narrow", sans-serif;
  --font-body: "MA Shekel", "Barlow", "Rubik", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(.2,.8,.2,1);
  --gutter: clamp(16px, 3vw, 32px);
  --header-h: 72px;
}
:root, .theme-dark {
  --bg: #0d0a0b; --surface: #151112; --surface-2: #1d1718; --line: rgba(255,255,255,.09); --text: #f6f2f1; --muted: #a89e9e;
  --line-strong: rgba(255,255,255,.17); --field: #100c0d; --hover: rgba(255,255,255,.04); --btn-dark: #2c2425; --btn-dark-hover: #3a3031;
  --red-fg: #ff545a; --ok-fg: #4fd892; --warn-fg: #f7b84b; --info-fg: #86b4ff;
  --tint-red: rgba(227,20,27,.17); --tint-ok: rgba(31,184,106,.15); --tint-warn: rgba(240,160,32,.15); --tint-info: rgba(59,130,246,.18);
  --chip-on-bg: var(--red); --chip-on-fg: #fff;
  --shimmer: rgba(255,255,255,.06);
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow: 0 18px 44px -22px rgba(0,0,0,.8);
  --shadow-lg: 0 30px 80px -28px rgba(0,0,0,.95), 0 0 0 1px rgba(255,255,255,.04);
  color-scheme: dark;
}
.theme-light {
  --bg: #f6f4f3; --surface: #fff; --surface-2: #f1edec; --line: rgba(20,16,17,.09); --text: #141011; --muted: #675e5f;
  --line-strong: rgba(20,16,17,.19); --field: #fff; --hover: rgba(20,16,17,.035); --btn-dark: #141011; --btn-dark-hover: #000;
  --red-fg: #c40f15; --ok-fg: #0b7a43; --warn-fg: #8f5400; --info-fg: #1d5fd0;
  --tint-red: rgba(227,20,27,.08); --tint-ok: rgba(31,184,106,.12); --tint-warn: rgba(240,160,32,.17); --tint-info: rgba(59,130,246,.1);
  --chip-on-bg: var(--ink); --chip-on-fg: #fff;
  --shimmer: rgba(255,255,255,.7);
  --shadow-sm: 0 1px 2px rgba(20,16,17,.05), 0 4px 14px -8px rgba(20,16,17,.12);
  --shadow: 0 2px 4px rgba(20,16,17,.04), 0 16px 36px -18px rgba(20,16,17,.22);
  --shadow-lg: 0 4px 10px rgba(20,16,17,.05), 0 30px 64px -24px rgba(20,16,17,.34);
  color-scheme: light;
}
.theme-light, .theme-dark { background: var(--bg); color: var(--text); }

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; font: 400 1rem/1.55 var(--font-body); background: var(--bg); color: var(--text);
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
img, video { max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
button, input, select, textarea { font: inherit; color: inherit; }
b, strong { font-weight: 600; }
::selection { background: var(--red); color: #fff; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
html:has(dialog[open]), html.menu-open { overflow: hidden; }
.theme-dark, .app-shell { scrollbar-color: #3a3132 transparent; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; } }

/* ---------- typography ---------- */
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.02; margin: 0 0 .45em; letter-spacing: .005em; }
h1, .h1 { font-weight: 800; font-style: italic; text-transform: uppercase; font-size: clamp(2.1rem, 4.4vw, 3.4rem); line-height: .95; }
h2, .h2 { font-weight: 800; font-style: italic; text-transform: uppercase; font-size: clamp(1.65rem, 3vw, 2.35rem); line-height: .98; }
h3, .h3 { font-weight: 700; text-transform: uppercase; font-size: 1.3rem; letter-spacing: .02em; }
h4, .h4 { font-weight: 700; text-transform: uppercase; font-size: 1rem; letter-spacing: .06em; }
.display { font: italic 800 clamp(2.7rem, 7vw, 5.6rem)/.9 var(--font-display); text-transform: uppercase; letter-spacing: -.005em; margin: 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font: 700 .8rem/1 var(--font-display); letter-spacing: .2em;
  text-transform: uppercase; color: var(--red-fg); }
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; }
.lead { font-size: clamp(1.05rem, 1.4vw, 1.2rem); line-height: 1.6; color: var(--muted); max-width: 62ch; }
.price { font: italic 800 1.8rem/1 var(--font-display); white-space: nowrap; font-variant-numeric: tabular-nums; }
.price--xl { font-size: clamp(2.4rem, 5vw, 3.4rem); }
.muted { color: var(--muted); }
.text-red { color: var(--red-fg); }
.small { font-size: .875rem; }
.num { font-variant-numeric: tabular-nums; }
.link { color: var(--red-fg); font-weight: 600; text-decoration: none; }
.link:hover { text-decoration: underline; }

/* ---------- layout utilities ---------- */
.container { width: 100%; max-width: 1320px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(40px, 7vw, 88px); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.stack { display: grid; gap: 16px; align-content: start; }
.spacer { flex: 1 1 auto; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.page-head > :first-child { margin: 0; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
@media (max-width: 640px) { .hide-sm { display: none !important; } }
@media (min-width: 641px) { .show-sm { display: none !important; } }
.i { width: 1.25em; height: 1.25em; flex: none; display: inline-block; vertical-align: -.25em; }

/* ---------- buttons ---------- */
.btn { --b-bg: var(--surface); --b-fg: var(--text); --b-bd: var(--line-strong);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: .55em; min-height: 46px; padding: 0 1.35rem;
  border: 1px solid var(--b-bd); border-radius: 999px; background: var(--b-bg); color: var(--b-fg);
  font: 600 .95rem/1.1 var(--font-body); letter-spacing: .01em; text-decoration: none; white-space: nowrap; cursor: pointer; user-select: none;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .18s, border-color .18s, color .18s, box-shadow .2s, transform .18s var(--ease); }
.btn:hover { --b-bd: color-mix(in srgb, var(--text) 45%, transparent); --b-bg: color-mix(in srgb, var(--surface) 92%, var(--text)); }
.btn:active { transform: translateY(1px) scale(.985); }
.btn:focus-visible { outline: 3px solid color-mix(in srgb, var(--red) 55%, transparent); outline-offset: 2px; }
.btn--red { --b-bg: var(--red); --b-fg: #fff; --b-bd: var(--red); box-shadow: 0 8px 22px -12px rgba(227,20,27,.9); }
.btn--red:hover { --b-bg: var(--red-600); --b-bd: var(--red-600); box-shadow: 0 12px 28px -12px rgba(227,20,27,.95); transform: translateY(-1px); }
.btn--ghost { --b-bg: transparent; }
.btn--ghost:hover { --b-bg: var(--hover); }
.btn--dark { --b-bg: var(--btn-dark); --b-fg: #fff; --b-bd: var(--btn-dark); }
.btn--dark:hover { --b-bg: var(--btn-dark-hover); --b-bd: var(--btn-dark-hover); }
.btn--white { --b-bg: #fff; --b-fg: var(--ink); --b-bd: #fff; }
.btn--white:hover { --b-bg: #f1edec; --b-bd: #f1edec; }
.btn--danger { --b-bg: transparent; --b-fg: var(--red-fg); --b-bd: color-mix(in srgb, var(--red) 40%, transparent); }
.btn--danger:hover { --b-bg: var(--tint-red); --b-bd: var(--red); }
.btn--sm { min-height: 36px; padding: 0 .95rem; font-size: .86rem; }
.btn--lg { min-height: 56px; padding: 0 1.9rem; font-size: 1.04rem; }
.btn--block { display: flex; width: 100%; }
.btn--icon { width: 46px; padding: 0; }
.btn--icon.btn--sm { width: 36px; }
@media (pointer: coarse) { .btn--sm { min-height: 44px; } .btn--icon.btn--sm { width: 44px; } }
.btn .i { width: 1.2em; height: 1.2em; }
.btn:disabled, .btn[aria-disabled="true"], .btn.is-disabled { opacity: .42; cursor: not-allowed; pointer-events: none; box-shadow: none; }
.btn.is-loading { color: transparent !important; pointer-events: none; }
.btn.is-loading::after { content: ""; position: absolute; width: 1.15em; height: 1.15em; border-radius: 50%;
  border: 2px solid var(--b-fg); border-right-color: transparent; animation: ma-spin .7s linear infinite; }
.btn-group { display: flex; flex-wrap: wrap; gap: 10px; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--line-strong); border-top-color: var(--red); animation: ma-spin .7s linear infinite; display: inline-block; }
@keyframes ma-spin { to { transform: rotate(360deg); } }

/* ---------- forms ---------- */
.field { display: grid; gap: 7px; align-content: start; min-width: 0; }
.label { font: 600 .85rem/1.2 var(--font-body); color: var(--text); letter-spacing: .01em; }
.label .req { color: var(--red-fg); margin-left: 2px; }
.field__hint { font-size: .82rem; color: var(--muted); }
.field__error { font-size: .82rem; color: var(--red-fg); font-weight: 500; }
.input, .select, .textarea { width: 100%; min-height: 48px; padding: .75rem 1rem; border: 1px solid var(--line-strong); border-radius: 12px;
  background: var(--field); color: var(--text); font: 400 1rem/1.3 var(--font-body); appearance: none; -webkit-appearance: none;
  transition: border-color .15s, box-shadow .15s, background-color .15s; }
.input::placeholder, .textarea::placeholder { color: var(--muted); opacity: .75; }
.input:hover, .select:hover, .textarea:hover { border-color: color-mix(in srgb, var(--text) 38%, transparent); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--red); box-shadow: 0 0 0 4px var(--tint-red); }
.input:disabled, .select:disabled, .textarea:disabled { background: var(--surface-2); opacity: .6; cursor: not-allowed; }
.input[readonly] { background: var(--surface-2); }
.input[type="number"] { font-variant-numeric: tabular-nums; }
.select { padding-right: 2.75rem; cursor: pointer; background-repeat: no-repeat; background-position: right 1rem center; background-size: 14px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23948a8b' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); }
.select option { background: var(--surface); color: var(--text); }
.textarea { min-height: 128px; resize: vertical; line-height: 1.5; }
.input--sm, .select--sm { min-height: 38px; padding-block: .45rem; font-size: .92rem; border-radius: 10px; }
.field.is-invalid .input, .field.is-invalid .select, .field.is-invalid .textarea,
.input.is-invalid, .select.is-invalid, .textarea.is-invalid,
.input[aria-invalid="true"], .select[aria-invalid="true"], .textarea[aria-invalid="true"] { border-color: var(--red); background-color: color-mix(in srgb, var(--field) 94%, var(--red)); }
.input-icon { position: relative; display: block; }
.input-icon > .i { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.input-icon > .input { padding-left: 46px; }
.form-grid { display: grid; gap: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form-grid .span-2, .form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }
.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: .95rem; user-select: none; }
.check input { width: 19px; height: 19px; margin: 0; accent-color: var(--red); cursor: pointer; flex: none; }
.switch { display: inline-flex; align-items: center; gap: 12px; cursor: pointer; font-size: .95rem; user-select: none; }
.switch input { appearance: none; -webkit-appearance: none; position: relative; width: 44px; height: 26px; margin: 0; flex: none; border-radius: 999px;
  background: var(--line-strong); cursor: pointer; transition: background-color .2s; }
.switch input::before { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.35); transition: transform .22s var(--ease); }
.switch input:checked { background: var(--red); }
.switch input:checked::before { transform: translateX(18px); }
.switch input:focus-visible { outline: 3px solid color-mix(in srgb, var(--red) 55%, transparent); outline-offset: 2px; }
.switch input:disabled { opacity: .45; cursor: not-allowed; }

/* ---------- card / alert / avatar ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(16px, 2.2vw, 24px); box-shadow: var(--shadow-sm); min-width: 0; }
.card--flush { padding: 0; overflow: hidden; }
.card--hover { transition: transform .25s var(--ease), box-shadow .25s; }
.card--hover:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.card__title { font: 700 1.15rem/1.1 var(--font-display); text-transform: uppercase; letter-spacing: .03em; margin: 0; }
.card--flush > .card__head { padding: 18px 20px 0; }
.card__foot { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }

.alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface-2); font-size: .95rem; line-height: 1.5; }
.alert > .i { margin-top: 1px; }
.alert--red { background: var(--tint-red); border-color: color-mix(in srgb, var(--red) 35%, transparent); }
.alert--red > .i { color: var(--red-fg); }
.alert--ok { background: var(--tint-ok); border-color: color-mix(in srgb, var(--ok) 35%, transparent); }
.alert--ok > .i { color: var(--ok-fg); }
.alert--warn { background: var(--tint-warn); border-color: color-mix(in srgb, var(--warn) 40%, transparent); }
.alert--warn > .i { color: var(--warn-fg); }
.alert--info { background: var(--tint-info); border-color: color-mix(in srgb, var(--info) 35%, transparent); }
.alert--info > .i { color: var(--info-fg); }

.avatar { --s: 38px; width: var(--s); height: var(--s); flex: none; display: inline-grid; place-items: center; border-radius: 50%; overflow: hidden;
  background: #fff; color: var(--ink); font: 700 calc(var(--s) * .4)/1 var(--font-display); text-transform: uppercase;
  box-shadow: 0 0 0 1px var(--line); }
.avatar img { width: 82%; height: 82%; object-fit: contain; }
.avatar--sm { --s: 26px; }
.avatar--lg { --s: 56px; }

/* ---------- badges / chips ---------- */
.badge { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 999px; white-space: nowrap;
  font: 600 .72rem/1 var(--font-body); letter-spacing: .07em; text-transform: uppercase;
  background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); }
.badge--ok, .badge--warn, .badge--red, .badge--info { border-color: transparent; }
.badge--ok::before, .badge--warn::before, .badge--red::before, .badge--info::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--ok { background: var(--tint-ok); color: var(--ok-fg); }
.badge--warn { background: var(--tint-warn); color: var(--warn-fg); }
.badge--red { background: var(--tint-red); color: var(--red-fg); }
.badge--info { background: var(--tint-info); color: var(--info-fg); }
.badge--muted { background: var(--surface-2); color: var(--muted); }
.badge--dark { background: var(--ink); color: #fff; border-color: var(--ink); }
.badge--solid { background: var(--red); color: #fff; border-color: var(--red); }
.badge--solid::before { display: none; }

.chip { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 0 15px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--text); font: 500 .92rem/1 var(--font-body); white-space: nowrap;
  text-decoration: none; transition: background-color .15s, border-color .15s, color .15s; -webkit-tap-highlight-color: transparent; }
.chip:hover { border-color: color-mix(in srgb, var(--text) 50%, transparent); }
.chip.is-active, .chip.active, .chip[aria-pressed="true"], .chip[aria-selected="true"] { background: var(--chip-on-bg); color: var(--chip-on-fg); border-color: var(--chip-on-bg); }
.chip .count { font-size: .78rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.chip.is-active .count, .chip[aria-pressed="true"] .count { color: inherit; opacity: .7; }
.chip__x { display: inline-grid; place-items: center; width: 20px; height: 20px; margin-right: -6px; padding: 0; border: 0; border-radius: 50%;
  background: var(--hover); color: inherit; cursor: pointer; font-size: 14px; line-height: 1; }
.chip__x:hover { background: var(--red); color: #fff; }
.chip:disabled { opacity: .45; cursor: not-allowed; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs > a, .tabs > button, .tab { position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 13px 14px 14px; margin: 0;
  border: 0; background: none; color: var(--muted); font: 600 .95rem/1 var(--font-body); white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: color .15s; }
.tabs > a::after, .tabs > button::after, .tab::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px;
  border-radius: 2px; background: var(--red); transform: scaleX(0); transition: transform .25s var(--ease); }
.tabs > a:hover, .tabs > button:hover, .tab:hover { color: var(--text); }
.tabs .is-active, .tabs .active, .tabs [aria-selected="true"], .tabs [aria-current="page"] { color: var(--text); }
.tabs .is-active::after, .tabs .active::after, .tabs [aria-selected="true"]::after, .tabs [aria-current="page"]::after { transform: scaleX(1); }
.tabs .badge, .tabs .count { height: 20px; padding: 0 7px; font-size: .7rem; }
.tabs--pill { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2); max-width: 100%; }
.tabs--pill > a, .tabs--pill > button, .tabs--pill .tab { padding: 9px 16px; border-radius: 999px; }
.tabs--pill > a::after, .tabs--pill > button::after, .tabs--pill .tab::after { display: none; }
.tabs--pill .is-active, .tabs--pill .active, .tabs--pill [aria-selected="true"], .tabs--pill [aria-current="page"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }

/* ---------- table ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .94rem; }
.table th { padding: 12px 16px; text-align: left; white-space: nowrap; border-bottom: 1px solid var(--line); background: var(--surface-2);
  font: 600 .72rem/1.2 var(--font-body); letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.table td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr { transition: background-color .12s; }
.table tbody tr:hover { background: var(--hover); }
.table tbody tr:last-child td { border-bottom: 0; }
.table tr.is-clickable, .table tr[data-href] { cursor: pointer; }
.table .num, .table th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table .actions { text-align: right; white-space: nowrap; }
.table .actions .btn + .btn { margin-left: 6px; }
.table__thumb { width: 72px; height: 54px; max-width: none; flex: none; border-radius: 8px; object-fit: cover; background: var(--surface-2); display: block; }
.table__main { font-weight: 600; white-space: nowrap; }
.table__sub { display: block; color: var(--muted); font-size: .84rem; white-space: nowrap; }
.table-wrap > .table th:first-child { border-top-left-radius: var(--radius); }
.table-wrap > .table th:last-child { border-top-right-radius: var(--radius); }
@media (max-width: 720px) {
  .table:not(.table--stack) { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .table--stack thead { display: none; }
  .table--stack, .table--stack tbody, .table--stack tr, .table--stack td { display: block; width: 100%; }
  .table--stack tr { padding: 10px 14px; border-bottom: 1px solid var(--line); }
  .table--stack tbody tr:last-child { border-bottom: 0; }
  .table--stack td { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 7px 0; border: 0; text-align: right; }
  .table--stack td::before { content: attr(data-label); color: var(--muted); font-size: .72rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; text-align: left; }
  .table--stack td:not([data-label])::before { display: none; }
  .table--stack td.actions { justify-content: flex-end; }
}

/* ---------- pagination ---------- */
.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; }
.pagination a, .pagination button, .pagination span { display: inline-grid; place-items: center; min-width: 42px; height: 42px; padding: 0 10px;
  border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); color: var(--text); font: 600 .95rem/1 var(--font-body);
  text-decoration: none; cursor: pointer; transition: border-color .15s, background-color .15s; }
.pagination span { border-color: transparent; background: none; cursor: default; color: var(--muted); }
.pagination a:hover, .pagination button:hover { border-color: var(--text); }
.pagination .is-active, .pagination [aria-current="page"] { background: var(--chip-on-bg); border-color: var(--chip-on-bg); color: var(--chip-on-fg); }
.pagination :disabled { opacity: .4; cursor: not-allowed; }

/* ---------- skeleton / empty / progress / dropzone ---------- */
.skeleton { position: relative; overflow: hidden; display: block; background: var(--surface-2); border-radius: 8px; min-height: 1em; color: transparent !important; }
.skeleton::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, var(--shimmer), transparent); animation: ma-shimmer 1.35s ease-in-out infinite; }
.skeleton--text { height: .85em; margin: .4em 0; border-radius: 5px; }
.skeleton--title { height: 1.4em; width: 70%; border-radius: 6px; }
.skeleton--short { width: 50%; }
@keyframes ma-shimmer { to { transform: translateX(100%); } }

.empty { display: grid; justify-items: center; gap: 10px; text-align: center; padding: clamp(40px, 8vw, 80px) 20px;
  border: 1px dashed var(--line-strong); border-radius: var(--radius); background: var(--surface); }
.empty__icon, .empty > .i { width: 68px; height: 68px; display: grid; place-items: center; border-radius: 50%; background: var(--tint-red); color: var(--red-fg); margin-bottom: 6px; }
.empty > .i { padding: 18px; }
.empty__icon .i { width: 30px; height: 30px; }
.empty h3, .empty__title { margin: 0; font: 700 1.35rem/1.1 var(--font-display); text-transform: uppercase; }
.empty p { margin: 0; color: var(--muted); max-width: 46ch; }
.empty .btn, .empty .btn-group { margin-top: 10px; }

progress.progress { appearance: none; -webkit-appearance: none; display: block; width: 100%; height: 6px; border: 0; border-radius: 99px; overflow: hidden; background: var(--surface-2); }
progress.progress::-webkit-progress-bar { background: var(--surface-2); border-radius: 99px; }
progress.progress::-webkit-progress-value { background: var(--red); border-radius: 99px; transition: width .2s; }
progress.progress::-moz-progress-bar { background: var(--red); border-radius: 99px; }

.dropzone { display: grid; place-items: center; gap: 8px; text-align: center; padding: 30px 20px; cursor: pointer;
  border: 1.5px dashed var(--line-strong); border-radius: var(--radius); background: var(--surface-2); color: var(--muted);
  transition: border-color .15s, background-color .15s, color .15s; }
.dropzone .i { width: 34px; height: 34px; color: var(--red-fg); }
.dropzone strong { color: var(--text); }
.dropzone:hover, .dropzone.is-over, .dropzone:focus-within { border-color: var(--red); background: var(--tint-red); color: var(--text); }
.dropzone input[type="file"] { position: absolute; width: 1px; height: 1px; opacity: 0; }

/* ---------- toasts ---------- */
.toasts { position: fixed; inset: auto 20px 20px auto; z-index: 1000; width: min(390px, calc(100vw - 32px)); height: auto; margin: 0; padding: 0;
  border: 0; background: none; color: inherit; overflow: visible; display: flex; flex-direction: column; gap: 10px; pointer-events: none; }
.toast { position: relative; overflow: hidden; pointer-events: auto; display: flex; align-items: flex-start; gap: 12px; padding: 14px 12px 14px 14px;
  border-radius: 14px; background: #1b1516; color: #f6f2f1; border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 22px 50px -14px rgba(0,0,0,.6); font: 500 .95rem/1.4 var(--font-body); animation: ma-toast-in .38s var(--ease); }
.toast__icon { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: rgba(31,184,106,.18); color: #4fd892; }
.toast__icon .i { width: 16px; height: 16px; }
.toast--error .toast__icon { background: rgba(227,20,27,.22); color: #ff6a6f; }
.toast--warn .toast__icon { background: rgba(240,160,32,.2); color: #f7b84b; }
.toast--info .toast__icon { background: rgba(59,130,246,.2); color: #86b4ff; }
.toast__msg { flex: 1; padding-top: 4px; }
.toast__x { flex: none; width: 28px; height: 28px; display: grid; place-items: center; border: 0; border-radius: 8px; background: none; color: #a89e9e; cursor: pointer; }
.toast__x:hover { background: rgba(255,255,255,.08); color: #fff; }
.toast::after { content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: currentColor; opacity: .25; transform-origin: left;
  animation: ma-toast-timer var(--t, 4s) linear forwards; }
.toast.is-leaving { animation: ma-toast-out .26s var(--ease) forwards; }
@keyframes ma-toast-in { from { opacity: 0; transform: translateY(14px) scale(.97); } }
@keyframes ma-toast-out { to { opacity: 0; transform: translateX(24px); } }
@keyframes ma-toast-timer { to { transform: scaleX(0); } }
@media (max-width: 560px) { .toasts { inset: auto 16px calc(16px + env(safe-area-inset-bottom)) 16px; width: auto; } }

/* ---------- modal / drawer (native <dialog>) ---------- */
.modal, .drawer { padding: 0; border: 0; background: var(--surface); color: var(--text); box-shadow: 0 40px 120px -20px rgba(0,0,0,.6), 0 0 0 1px var(--line);
  max-height: calc(100dvh - 32px); overflow: hidden; }
.modal { width: min(560px, calc(100vw - 32px)); border-radius: 22px; }
.modal--sm { width: min(440px, calc(100vw - 32px)); }
.modal--lg { width: min(860px, calc(100vw - 32px)); }
.modal[open], .drawer[open] { display: flex; flex-direction: column; animation: ma-pop .32s var(--ease); }
.modal::backdrop, .drawer::backdrop { background: rgba(10,7,8,.6); backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); animation: ma-fade .25s ease; }
.modal.is-closing { animation: ma-pop-out .18s ease forwards; }
.modal__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 24px 0; }
.modal__title { margin: 0; font: italic 800 1.65rem/1 var(--font-display); text-transform: uppercase; padding-top: 6px; }
.modal__close { flex: none; width: 38px; height: 38px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%;
  background: var(--surface-2); color: var(--text); cursor: pointer; transition: background-color .15s, transform .2s var(--ease); }
.modal__close:hover { background: var(--red); border-color: var(--red); color: #fff; transform: rotate(90deg); }
.modal__body { flex: 1 1 auto; padding: 16px 24px 8px; overflow-y: auto; overscroll-behavior: contain; }
.modal__body > p:first-child { margin-top: 0; }
.modal__body > p { color: var(--muted); }
.modal__foot { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; padding: 16px 24px 22px; }
.drawer { width: min(540px, 100vw); height: 100dvh; max-height: 100dvh; max-width: 100vw; margin: 0 0 0 auto; border-radius: 22px 0 0 22px; }
.drawer[open] { animation: ma-slide .36s var(--ease); }
.drawer.is-closing { animation: ma-slide-out .2s ease forwards; }
.drawer .modal__head { padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.drawer .modal__body { padding-top: 20px; }
.drawer .modal__foot { border-top: 1px solid var(--line); padding-top: 16px; background: var(--surface); }
@keyframes ma-pop { from { opacity: 0; transform: translateY(16px) scale(.97); } }
@keyframes ma-pop-out { to { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes ma-fade { from { opacity: 0; } }
@keyframes ma-slide { from { transform: translateX(100%); } }
@keyframes ma-slide-out { to { transform: translateX(100%); } }
@media (max-width: 560px) {
  .modal, .modal--sm, .modal--lg { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 22px 22px 0 0; max-height: 92dvh; padding-bottom: env(safe-area-inset-bottom); }
  .modal[open] { animation-name: ma-sheet; }
  .modal__head { padding: 20px 16px 0; }
  .modal__body { padding: 14px 16px 6px; }
  .modal__foot { padding: 14px 16px 18px; }
  .modal__foot .btn { flex: 1 1 0; }
  .drawer { border-radius: 0; }
}
@keyframes ma-sheet { from { transform: translateY(100%); } }

/* ---------- car cards ---------- */
.grid-cars { display: grid; gap: clamp(14px, 2vw, 24px); grid-template-columns: repeat(auto-fill, minmax(min(100%, 272px), 1fr)); }
.car-card { position: relative; isolation: isolate; display: flex; flex-direction: column; min-width: 0; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .35s; }
.car-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.car-card:has(.car-card__title a:focus-visible) { outline: 3px solid var(--red); outline-offset: 3px; }
.car-card__title a:focus-visible { outline: none; }
.car-card__media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #1b1516; }
.car-card__media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.car-card:hover .car-card__media img { transform: scale(1.05); }
.car-card__media::after { content: ""; position: absolute; inset: auto 0 0; height: 38%; pointer-events: none;
  background: linear-gradient(transparent, rgba(10,7,8,.45)); }
.car-card__badges { position: absolute; top: 12px; left: 12px; right: 12px; z-index: 2; display: flex; flex-wrap: wrap; gap: 6px; }
.car-card__badges .badge { height: 26px; border: 0; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.car-card__badges .badge::before { display: none; }
.car-card__badges .badge--red { background: var(--red); color: #fff; }
.car-card__badges .badge--warn { background: var(--warn); color: var(--ink); }
.car-card__badges .badge--dark, .car-card__badges .badge--muted { background: rgba(14,10,11,.82); color: #fff; backdrop-filter: blur(6px); }
.car-card__count { position: absolute; right: 10px; bottom: 10px; z-index: 2; display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px;
  border-radius: 999px; background: rgba(14,10,11,.62); color: #fff; font: 600 .76rem/1.2 var(--font-body); backdrop-filter: blur(6px); }
.car-card__count .i { width: 14px; height: 14px; }
.car-card__ph { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px;
  background: radial-gradient(80% 70% at 70% 20%, rgba(227,20,27,.28), transparent 70%), repeating-linear-gradient(115deg, transparent 0 22px, rgba(255,255,255,.025) 22px 23px), #171213;
  color: rgba(246,242,241,.55); font: 600 .78rem/1 var(--font-body); letter-spacing: .14em; text-transform: uppercase; }
.car-card__ph .i { width: 44px; height: 44px; color: rgba(246,242,241,.35); }
.car-card__body { display: flex; flex-direction: column; gap: 6px; flex: 1; padding: 16px 18px 18px; }
.car-card__title { margin: 0; font: 700 1.32rem/1.08 var(--font-display); text-transform: uppercase; letter-spacing: .015em; }
.car-card__title a { color: inherit; text-decoration: none; }
.car-card__title a::after { content: ""; position: absolute; inset: 0; z-index: 3; }
.car-card__title .brand-name { color: var(--muted); }
.car-card__version { margin: 0; color: var(--muted); font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.car-card__specs { list-style: none; margin: 6px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px 12px;
  color: var(--text); font: 500 .9rem/1.2 var(--font-body); font-variant-numeric: tabular-nums; }
.car-card__specs li { display: flex; align-items: center; gap: 7px; min-width: 0; white-space: nowrap; }
.car-card__specs .i { width: 16px; height: 16px; color: var(--muted); }
.car-card__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 12px; }
.car-card__go { width: 38px; height: 38px; flex: none; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text);
  transition: background-color .25s, border-color .25s, color .25s, transform .35s var(--ease); }
.car-card__go .i { width: 18px; height: 18px; }
.car-card:hover .car-card__go { background: var(--red); border-color: var(--red); color: #fff; transform: translateX(3px); }
.car-card__price { font: italic 800 1.7rem/1 var(--font-display); white-space: nowrap; font-variant-numeric: tabular-nums; letter-spacing: .005em; }
.car-card__garage { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 48px; padding: 0 18px; border-top: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface-2) 40%, var(--surface)); color: var(--muted); font: 500 .84rem/1.2 var(--font-body); }
.car-card__garage > .i { width: 16px; height: 16px; color: var(--red-fg); }
.car-card__garage span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.car-card__garage b { color: var(--text); font-weight: 600; }
.car-card--featured { border-color: color-mix(in srgb, var(--red) 40%, transparent); }
.car-card--featured::before { content: ""; position: absolute; inset: 0 0 auto; height: 3px; background: var(--red); z-index: 4; }
.car-card.is-sold .car-card__media img { filter: grayscale(1) brightness(.8); }
.car-card.is-skeleton { pointer-events: none; box-shadow: none; }
.skeleton--media { aspect-ratio: 4 / 3; border-radius: 0; }

/* ---------- public header ---------- */
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 100; padding: 10px 16px; border-radius: 10px; background: var(--red); color: #fff; font-weight: 600; text-decoration: none; transition: top .2s; }
.skip-link:focus { top: 12px; }
.site-header { position: sticky; top: 0; z-index: 60; color: #f6f2f1; font-family: var(--font-body);
  --text: #f6f2f1; --muted: #a89e9e; --line: rgba(255,255,255,.09); --line-strong: rgba(255,255,255,.17); --surface: #151112; --hover: rgba(255,255,255,.06); }
.site-header::after { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(13,10,11,.965);
  backdrop-filter: saturate(1.5) blur(16px); -webkit-backdrop-filter: saturate(1.5) blur(16px); border-bottom: 1px solid rgba(255,255,255,.07); }
.site-header::before { content: ""; position: absolute; top: 0; left: 0; width: min(30vw, 380px); height: 2px; background: linear-gradient(90deg, var(--red), transparent); }
.site-header__in { display: flex; align-items: center; gap: clamp(16px, 2.6vw, 40px); max-width: 1320px; height: var(--header-h); margin: 0 auto; padding: 0 var(--gutter); }
.brand { display: inline-flex; align-items: center; gap: 12px; flex: none; color: #fff; text-decoration: none; }
.brand__mark { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 50%; overflow: hidden; background: #fff;
  box-shadow: 0 0 0 1px rgba(255,255,255,.25), 0 6px 20px -4px rgba(227,20,27,.55); transition: transform .5s var(--ease); }
.brand__mark img { width: 84%; height: 84%; object-fit: contain; display: block; }
.brand:hover .brand__mark { transform: rotate(-18deg); }
.brand__text { display: grid; gap: 3px; }
.brand__name { font: italic 800 1.45rem/.9 var(--font-display); text-transform: uppercase; letter-spacing: .02em; }
.brand__tag { font: 600 .62rem/1 var(--font-body); letter-spacing: .26em; text-transform: uppercase; color: #a89e9e; }
.site-nav { display: flex; align-items: center; gap: 2px; }
.site-nav a { position: relative; padding: 10px 13px; border-radius: 8px; color: rgba(246,242,241,.72); font: 500 .96rem/1 var(--font-body);
  text-decoration: none; white-space: nowrap; transition: color .15s; }
.site-nav a:hover { color: #fff; }
.site-nav a.is-active { color: #fff; }
.site-nav a::after { content: ""; position: absolute; left: 13px; right: 13px; bottom: 2px; height: 2px; border-radius: 2px; background: var(--red);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease); }
.site-nav a:hover::after { transform: scaleX(.35); }
.site-nav a.is-active::after { transform: scaleX(1); }
.site-header__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.site-phone { display: inline-flex; align-items: center; gap: 10px; padding-right: 6px; color: #fff; text-decoration: none; }
.site-phone__ico { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; border: 1px solid rgba(255,255,255,.18); color: var(--red); transition: background-color .2s, color .2s; }
.site-phone:hover .site-phone__ico { background: var(--red); color: #fff; border-color: var(--red); }
.site-phone__ico .i { width: 17px; height: 17px; }
.site-phone small { display: block; font: 600 .62rem/1 var(--font-body); letter-spacing: .2em; text-transform: uppercase; color: #a89e9e; margin-bottom: 4px; }
.site-phone b { font: 700 1.12rem/1 var(--font-display); letter-spacing: .04em; }
.site-wa { color: #fff; }
.site-wa .i { width: 20px; height: 20px; }
.site-burger { display: none; width: 46px; height: 46px; place-items: center; border: 1px solid rgba(255,255,255,.18); border-radius: 50%; background: none; color: #fff; cursor: pointer; }
.site-burger .i { width: 22px; height: 22px; }
.site-burger[aria-expanded="true"] { background: var(--red); border-color: var(--red); }
.site-menu { position: fixed; inset: var(--header-h) 0 0; z-index: 59; overflow-y: auto; overscroll-behavior: contain;
  display: flex; flex-direction: column; gap: 28px; padding: 12px var(--gutter) calc(28px + env(safe-area-inset-bottom));
  background: radial-gradient(120% 60% at 100% 0%, rgba(227,20,27,.22), transparent 60%), #0d0a0b; color: #fff; animation: ma-menu .3s var(--ease); }
.site-menu[hidden] { display: none; }
.site-menu nav { display: grid; }
.site-menu nav a { display: flex; align-items: center; justify-content: space-between; padding: 17px 2px; border-bottom: 1px solid rgba(255,255,255,.08);
  color: #fff; text-decoration: none; font: italic 800 2rem/1 var(--font-display); text-transform: uppercase; }
.site-menu nav a .i { color: rgba(255,255,255,.35); width: 22px; height: 22px; }
.site-menu nav a.is-active { color: var(--red); }
.site-menu nav a.is-active .i { color: var(--red); }
.site-menu__cta { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.site-menu__cta .btn--red { grid-column: 1 / -1; }
.site-menu__info { color: #a89e9e; font-size: .92rem; line-height: 1.7; }
.site-menu__info a { color: #fff; text-decoration: none; }
@keyframes ma-menu { from { opacity: 0; transform: translateY(-8px); } }
@media (max-width: 1180px) { .site-phone { display: none; } }
@media (max-width: 1060px) {
  :root { --header-h: 64px; }
  .site-nav { display: none; }
  .site-burger { display: inline-grid; }
  .brand__mark { width: 40px; height: 40px; }
}
@media (max-width: 600px) {
  .site-header__garage { display: none; }
  .brand__name { font-size: 1.3rem; }
}

/* ---------- public footer ---------- */
.site-footer { position: relative; overflow: hidden; background: #0a0708; color: #b8aeae; font: 400 .95rem/1.6 var(--font-body);
  --text: #f6f2f1; --muted: #a89e9e; --line: rgba(255,255,255,.09); --line-strong: rgba(255,255,255,.17); --surface: #151112; --hover: rgba(255,255,255,.06); }
.site-footer a { color: inherit; text-decoration: none; transition: color .15s; }
.site-footer a:hover { color: #fff; }
.site-footer__cta { position: relative; border-top: 3px solid var(--red); border-bottom: 1px solid rgba(255,255,255,.07);
  background: radial-gradient(60% 120% at 85% 0%, rgba(227,20,27,.3), transparent 70%), repeating-linear-gradient(115deg, transparent 0 46px, rgba(227,20,27,.05) 46px 48px), #0d0a0b; }
.site-footer__cta .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 40px; padding-block: clamp(40px, 6vw, 72px); }
.site-footer__cta h2 { margin: 12px 0 0; color: #fff; font-size: clamp(2.2rem, 5.2vw, 4.2rem); line-height: .92; }
.site-footer__cta p { margin: 12px 0 0; max-width: 46ch; color: #cfc6c6; }
.site-footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.35fr; gap: 40px; padding-block: 56px 48px; }
.site-footer h3 { margin: 0 0 16px; color: #fff; font: 700 .9rem/1 var(--font-display); letter-spacing: .18em; text-transform: uppercase; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer__about p { margin: 18px 0 0; max-width: 36ch; }
.site-footer__social { display: flex; gap: 10px; margin-top: 22px; }
.site-footer__social a { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; border: 1px solid rgba(255,255,255,.14); color: #fff; transition: background-color .2s, border-color .2s, transform .2s var(--ease); }
.site-footer__social a:hover { background: var(--red); border-color: var(--red); transform: translateY(-2px); }
.site-footer__social .i { width: 18px; height: 18px; }
.site-footer__contact li { display: flex; gap: 12px; align-items: flex-start; }
.site-footer__contact .i { color: var(--red); width: 18px; height: 18px; margin-top: 3px; }
.site-footer__contact small { display: block; color: #8a8081; font-size: .78rem; letter-spacing: .04em; }
.site-footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding-block: 22px; border-top: 1px solid rgba(255,255,255,.08); font-size: .86rem; color: #8a8081; }
.site-footer__bottom i { color: #cfc6c6; }
.site-footer__word { position: absolute; left: 50%; bottom: -.36em; transform: translateX(-50%); z-index: 0; pointer-events: none; white-space: nowrap;
  font: italic 800 clamp(5rem, 17vw, 16rem)/1 var(--font-display); text-transform: uppercase; color: transparent; -webkit-text-stroke: 1px rgba(227,20,27,.12); }
.site-footer > .container, .site-footer__cta { position: relative; z-index: 1; }
@media (max-width: 960px) { .site-footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px 20px; padding-block: 44px 36px; } .site-footer__about, .site-footer__grid > :last-child { grid-column: 1 / -1; } .site-footer__cta .btn-group { width: 100%; } .site-footer__cta .btn { flex: 1 1 0; } }

/* ---------- app shell (garage space + CRM) ---------- */
.app-shell { --side-w: 268px; min-height: 100vh; min-height: 100dvh; padding-left: var(--side-w); background: var(--bg); color: var(--text); }
.app-sidebar { position: fixed; top: 0; bottom: 0; left: 0; z-index: 40; width: var(--side-w); display: flex; flex-direction: column; gap: 4px;
  padding: 18px 14px; overflow-y: auto; scrollbar-width: thin;
  background: radial-gradient(120% 40% at 0% 0%, rgba(227,20,27,.14), transparent 60%), linear-gradient(180deg, #120d0e, #0b0809);
  border-right: 1px solid var(--line); color: var(--text); }
.app-brand { display: flex; align-items: center; gap: 12px; padding: 4px 8px 18px; margin-bottom: 8px; border-bottom: 1px solid var(--line); color: #fff; text-decoration: none; }
.app-brand .brand__mark { width: 40px; height: 40px; }
.app-brand b, .app-brand strong { display: block; font: italic 800 1.3rem/.95 var(--font-display); text-transform: uppercase; letter-spacing: .02em; }
.app-brand small { display: block; margin-top: 4px; font: 600 .64rem/1 var(--font-body); letter-spacing: .22em; text-transform: uppercase; color: var(--red-fg); }
.app-nav { display: grid; gap: 2px; }
.app-nav__label { padding: 18px 12px 6px; font: 600 .68rem/1 var(--font-body); letter-spacing: .18em; text-transform: uppercase; color: color-mix(in srgb, var(--muted) 70%, transparent); }
.app-nav a, .app-nav button, .app-sidebar > a:not(.app-brand) { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 12px;
  border: 0; border-radius: 10px; background: none; color: var(--muted); font: 500 .96rem/1 var(--font-body); text-align: left; text-decoration: none; cursor: pointer;
  transition: color .15s, background-color .15s; }
.app-nav a .i, .app-nav button .i, .app-sidebar > a .i { width: 19px; height: 19px; }
.app-nav a:hover, .app-nav button:hover, .app-sidebar > a:not(.app-brand):hover { color: var(--text); background: var(--hover); }
.app-nav .is-active, .app-nav .active, .app-nav [aria-current="page"], .app-sidebar > a.is-active {
  color: #fff; background: linear-gradient(90deg, rgba(227,20,27,.2), rgba(227,20,27,.04)); box-shadow: inset 3px 0 0 var(--red); }
.app-nav .is-active .i, .app-nav [aria-current="page"] .i { color: var(--red-fg); }
.app-nav .count, .app-nav .badge { margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px; display: inline-grid; place-items: center; border-radius: 999px;
  background: var(--red); color: #fff; font: 700 .72rem/1 var(--font-body); letter-spacing: 0; border: 0; }
.app-nav .badge::before { display: none; }
.app-user { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 14px 8px 4px; border-top: 1px solid var(--line); min-width: 0; }
.app-user > div { min-width: 0; flex: 1; }
.app-user b, .app-user strong { display: block; font-size: .92rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-user small { display: block; color: var(--muted); font-size: .78rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.app-topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; flex-wrap: wrap; gap: 12px 14px; min-height: 70px;
  padding: 12px clamp(16px, 3vw, 32px); background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.app-topbar h1, .app-topbar h2, .app-title { margin: 0; font: italic 800 clamp(1.4rem, 2.4vw, 1.85rem)/1 var(--font-display); text-transform: uppercase; }
.app-topbar__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.app-main { padding: clamp(16px, 3vw, 32px); max-width: 1480px; }
.app-burger { display: none; width: 42px; height: 42px; place-items: center; flex: none; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); color: var(--text); cursor: pointer; }
.app-burger .i { width: 20px; height: 20px; }
@media (max-width: 960px) {
  .app-shell { padding-left: 0; }
  .app-sidebar { transform: translateX(-102%); transition: transform .3s var(--ease); z-index: 70; }
  .nav-open .app-sidebar { transform: none; box-shadow: 30px 0 80px rgba(0,0,0,.6); }
  .nav-open .app-shell::after { content: ""; position: fixed; inset: 0; z-index: 65; background: rgba(5,3,4,.6); backdrop-filter: blur(3px); animation: ma-fade .2s; }
  .app-burger { display: inline-grid; }
  .app-topbar { min-height: 62px; }
}

/* ---------- KPI ---------- */
.kpis, .kpi-grid { display: grid; gap: clamp(10px, 1.6vw, 16px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }
.kpi { position: relative; overflow: hidden; display: grid; gap: 8px; align-content: start; min-width: 0; padding: 20px;
  border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow-sm); }
.kpi::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 140px; height: 140px; border-radius: 50%;
  background: radial-gradient(var(--tint-red), transparent 70%); pointer-events: none; }
.kpi__label { padding-right: 48px; font: 600 .74rem/1.2 var(--font-body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.kpi__value { font: italic 800 2.6rem/1 var(--font-display); font-variant-numeric: tabular-nums; letter-spacing: .005em; }
.kpi__value small { font-size: .5em; font-style: normal; color: var(--muted); margin-left: 4px; }
.kpi__sub, .kpi__delta { font-size: .86rem; color: var(--muted); }
.kpi__delta.is-up { color: var(--ok-fg); }
.kpi__delta.is-down { color: var(--red-fg); }
.kpi__icon { position: absolute; top: 16px; right: 16px; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; background: var(--tint-red); color: var(--red-fg); }
.kpi__icon .i { width: 20px; height: 20px; }
.kpi--red { background: linear-gradient(140deg, #e3141b, #8d0a0f); border-color: transparent; color: #fff; box-shadow: 0 18px 40px -20px rgba(227,20,27,.8); }
.kpi--red .kpi__label, .kpi--red .kpi__sub, .kpi--red .kpi__delta { color: rgba(255,255,255,.8); }
.kpi--red .kpi__icon { background: rgba(255,255,255,.16); color: #fff; }
.kpi--red::after { background: repeating-linear-gradient(115deg, transparent 0 14px, rgba(255,255,255,.07) 14px 16px); border-radius: 0; width: 60%; height: 100%; right: 0; bottom: 0; }
@media (max-width: 560px) {
  .kpis, .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi { padding: 16px 14px; gap: 6px; }
  .kpi__value { font-size: 2rem; }
  .kpi__icon { top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 10px; }
  .kpi__icon .i { width: 16px; height: 16px; }
  .kpi__label { padding-right: 36px; font-size: .68rem; }
}
a.kpi { color: inherit; text-decoration: none; transition: transform .25s var(--ease), box-shadow .25s; }
a.kpi:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

/* ---------- partner band (CRM « Publicités » → Bande partenaires) ---------- */
.sponsors { position: relative; z-index: 1; display: flex; align-items: center; gap: 20px; padding: 8px 0 8px clamp(16px, 4vw, 48px);
  background: #fff; color: #6f6567; border-bottom: 1px solid #ece6e5; box-shadow: 0 6px 18px rgba(13, 10, 11, .06); }
.sponsors__label { flex: none; font: 700 .68rem/1 var(--font-display); letter-spacing: .2em; text-transform: uppercase; color: #8b8183; white-space: nowrap; }
.sponsors__vp { flex: 1; min-width: 0; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent); }
.sponsors__track { display: flex; width: max-content; animation: sponsors-run var(--sp-dur, 40s) linear infinite; }
.sponsors:hover .sponsors__track, .sponsors:focus-within .sponsors__track { animation-play-state: paused; }
.sponsors__set { display: flex; align-items: center; }
.sponsors__item { flex: none; display: grid; place-items: center; height: 56px; padding: 0 clamp(20px, 3vw, 44px); border-radius: 10px; }
.sponsors__item img { display: block; height: 42px; width: auto; max-width: 240px; object-fit: contain; }
a.sponsors__item:focus-visible { outline: 2px solid var(--red); outline-offset: -2px; }
@keyframes sponsors-run { to { transform: translateX(-50%); } }
@media (max-width: 640px) {
  .sponsors { padding-left: 0; }
  .sponsors__label { display: none; }
  .sponsors__item { height: 46px; padding: 0 18px; }
  .sponsors__item img { height: 32px; max-width: 170px; }
}
@media (prefers-reduced-motion: reduce) {
  .sponsors__track { animation: none; }
  .sponsors__vp { overflow-x: auto; scrollbar-width: none; }
  .sponsors__set[aria-hidden] { display: none; }
}

/* ---------- languages (lang.js) ---------- */
html.i18n-wait body { visibility: hidden; } /* until the page text is translated, so French never flashes */
.lang-select { position: relative; display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 999px; color: inherit; cursor: pointer; }
.lang-select > .i { width: 17px; height: 17px; flex: none; opacity: .8; }
.lang-select select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font-size: 16px; }
.lang-select__code { font: 700 .8rem/1 var(--font-body); letter-spacing: .06em; white-space: nowrap; }
.site-phone small, .site-phone b { white-space: nowrap; }
.lang-select select option { color: #141011; background: #fff; }
.lang-select:focus-within { outline: 2px solid var(--red); outline-offset: 2px; }
.site-header .lang-select { color: #fff; border-color: rgba(255, 255, 255, .18); }
@media (max-width: 1060px) { .site-lang { display: none; } }
.site-menu__lang { margin-top: 16px; }
.site-menu__lang .lang-select { width: 100%; height: 48px; justify-content: center; color: #fff; border-color: rgba(255, 255, 255, .18); }
.site-footer__langs { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.site-footer__langs a { color: inherit; opacity: .7; text-decoration: none; font-size: .86rem; }
.site-footer__langs a:hover, .site-footer__langs a[aria-current] { opacity: 1; color: var(--red-fg); }
.tr-toggle { display: flex; align-items: center; gap: 6px; margin: 8px 0 0; padding: 0; border: 0; background: none; color: var(--muted); font: 500 .8rem/1.35 var(--font-body); cursor: pointer; text-align: start; }
.tr-toggle span { text-decoration: underline; text-underline-offset: 3px; }
.tr-toggle .i { width: 15px; height: 15px; flex: none; }
.tr-toggle:hover { color: var(--text); }

/* ---------- right-to-left (Hebrew) ---------- */
[dir="rtl"] .i--dir { transform: scaleX(-1); }
[dir="rtl"] .label .req { margin-left: 0; margin-right: 2px; }
[dir="rtl"] .select { padding-right: 1rem; padding-left: 2.75rem; background-position: left 1rem center; }
[dir="rtl"] .input-icon > .i { left: auto; right: 15px; }
[dir="rtl"] .input-icon > .input { padding-left: 1rem; padding-right: 46px; }
[dir="rtl"] .switch input::before { left: auto; right: 3px; }
[dir="rtl"] .switch input:checked::before { transform: translateX(-18px); }
[dir="rtl"] .chip__x { margin-right: 0; margin-left: -6px; }
[dir="rtl"] .table th { text-align: right; }
[dir="rtl"] .table .num, [dir="rtl"] .table th.num, [dir="rtl"] .table .actions { text-align: left; }
[dir="rtl"] .table .actions .btn + .btn { margin-left: 0; margin-right: 6px; }
[dir="rtl"] .table-wrap > .table th:first-child { border-top-left-radius: 0; border-top-right-radius: var(--radius); }
[dir="rtl"] .table-wrap > .table th:last-child { border-top-right-radius: 0; border-top-left-radius: var(--radius); }
@media (max-width: 720px) { [dir="rtl"] .table--stack td { text-align: left; } [dir="rtl"] .table--stack td::before { text-align: right; } }
[dir="rtl"] .toasts { inset: auto auto 20px 20px; }
@media (max-width: 560px) { [dir="rtl"] .toasts { inset: auto 16px calc(16px + env(safe-area-inset-bottom)) 16px; } }
[dir="rtl"] .toast { padding: 14px 14px 14px 12px; }
[dir="rtl"] .toast::after { transform-origin: right; }
[dir="rtl"] .toast.is-leaving { animation-name: ma-toast-out-rtl; }
@keyframes ma-toast-out-rtl { to { opacity: 0; transform: translateX(-24px); } }
[dir="rtl"] .drawer { margin: 0 auto 0 0; border-radius: 0 22px 22px 0; }
[dir="rtl"] .drawer[open] { animation-name: ma-slide-rtl; }
[dir="rtl"] .drawer.is-closing { animation-name: ma-slide-out-rtl; }
@keyframes ma-slide-rtl { from { transform: translateX(-100%); } }
@keyframes ma-slide-out-rtl { to { transform: translateX(-100%); } }
[dir="rtl"] .car-card__count { right: auto; left: 10px; }
[dir="rtl"] .car-card:hover .car-card__go { transform: translateX(-3px); }
[dir="rtl"] .skip-link { left: auto; right: 16px; }
[dir="rtl"] .site-header::before { left: auto; right: 0; background: linear-gradient(270deg, var(--red), transparent); }
[dir="rtl"] .site-nav a::after { transform-origin: right; }
[dir="rtl"] .site-header__actions { margin-left: 0; margin-right: auto; }
[dir="rtl"] .site-phone { padding-right: 0; padding-left: 6px; }
[dir="rtl"] .app-shell { padding-left: 0; padding-right: var(--side-w); }
[dir="rtl"] .app-sidebar { left: auto; right: 0; border-right: 0; border-left: 1px solid var(--line); }
[dir="rtl"] .app-nav a, [dir="rtl"] .app-nav button { text-align: right; }
[dir="rtl"] .app-nav .count, [dir="rtl"] .app-nav .badge { margin-left: 0; margin-right: auto; }
[dir="rtl"] .app-topbar__actions { margin-left: 0; margin-right: auto; }
@media (max-width: 960px) {
  [dir="rtl"] .app-shell { padding-right: 0; }
  [dir="rtl"] .app-sidebar { transform: translateX(102%); }
  [dir="rtl"].nav-open .app-sidebar { transform: none; box-shadow: -30px 0 80px rgba(0, 0, 0, .6); }
}
[dir="rtl"] .kpi::after { right: auto; left: -40px; }
[dir="rtl"] .kpi--red::after { right: auto; left: 0; }
[dir="rtl"] .kpi__label { padding-right: 0; padding-left: 48px; }
[dir="rtl"] .kpi__value small { margin-left: 0; margin-right: 4px; }
[dir="rtl"] .kpi__icon { right: auto; left: 16px; }
[dir="rtl"] .sponsors { padding: 8px clamp(16px, 4vw, 48px) 8px 0; }
[dir="rtl"] .sponsors__track { animation-name: sponsors-run-rtl; }
@keyframes sponsors-run-rtl { to { transform: translateX(50%); } }
@media (max-width: 640px) { [dir="rtl"] .sponsors { padding-right: 0; } }
@media (max-width: 560px) { [dir="rtl"] .kpi__icon { left: 12px; } [dir="rtl"] .kpi__label { padding-left: 36px; } }
/* the header must fit with longer menus (Russian, English) and the language pill */
@media (max-width: 1400px) { .site-phone > span:not(.site-phone__ico) { display: none; } .site-phone { padding: 0; } }
@media (max-width: 1300px) { .site-nav a { padding-inline: 9px; } .site-nav a::after { left: 9px; right: 9px; } .site-header__in { gap: 18px; } }
@media (max-width: 1600px) { :root[lang="ru"] .site-phone > span:not(.site-phone__ico) { display: none; } :root[lang="ru"] .site-phone { padding: 0; } }
@media (max-width: 1200px) { :root[lang="ru"] .site-nav a { padding-inline: 7px; font-size: .92rem; } }

/* ---------- legal pages (accessibilite.html, confidentialite.html) ---------- */
.legal { max-width: 780px; margin: 0 auto; padding: clamp(36px, 6vw, 72px) var(--gutter) clamp(48px, 8vw, 96px); color: var(--text); line-height: 1.7; }
.legal h1 { margin: 10px 0 0; font: italic 800 clamp(2.2rem, 5vw, 3.4rem)/1 var(--font-display); text-transform: uppercase; }
.legal .lead { margin: 18px 0 8px; font-size: 1.12rem; }
.legal h2 { margin: 36px 0 10px; font: 700 1.35rem/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .02em; }
.legal ul { margin: 0; padding-inline-start: 1.3em; display: grid; gap: 6px; }
.legal a { color: var(--red-fg); }
.legal__contact { list-style: none; padding: 0 !important; }
.legal__date { margin-top: 32px; color: var(--muted); font-size: .9rem; }
.site-footer__legal { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.site-footer__legal a { color: inherit; opacity: .7; text-decoration: none; font-size: .86rem; }
.site-footer__legal a:hover { opacity: 1; color: var(--red-fg); }

/* Hebrew has no capitals: the wide letter-spacing of small labels only spreads the letters apart */
:lang(he) .eyebrow, :lang(he) .brand__tag, :lang(he) .site-phone small, :lang(he) .kpi__label, :lang(he) .sponsors__label, :lang(he) .label { letter-spacing: .02em; }
