:root {
  --bg: #ffffff;
  --surface: #f4f6f8;
  --border: #e2e6ec;
  --text: #12151a;
  --text-muted: #5a6573;
  --accent: #2563eb;
  --accent-weak: #e8effc;
  --success: #16a34a;
  --danger: #dc2626;
  --plate-ink: #111;
  --plate-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3);
  --plate-face: linear-gradient(180deg, #ffffff 0%, #dfdfdf 100%);
  --shadow: 0 10px 28px rgba(18, 21, 26, 0.07);
  --shadow-soft: 0 4px 14px rgba(18, 21, 26, 0.05);
  --radius: 10px;
  --radius-sm: 6px;
  --container: 1120px;
  --font: "Manrope", "Segoe UI", sans-serif;
  --font-plate: "Motor", "Arial Narrow", Arial, sans-serif;
  --ease: 160ms ease;
  --focus-ring: 0 0 0 3px rgba(37, 99, 235, 0.22);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(900px 420px at 8% -10%, rgba(37, 99, 235, 0.08), transparent 55%),
    radial-gradient(700px 360px at 96% 4%, rgba(15, 23, 42, 0.05), transparent 50%),
    linear-gradient(180deg, #eef2f7 0%, #f7f8fa 38%, #ffffff 100%);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  display: block;
}

button,
input,
select {
  font: inherit;
}

:focus {
  outline: none;
}

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

.container {
  width: min(100% - 32px, var(--container));
  margin-inline: auto;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, 0.88);
  border-bottom: 1px solid var(--border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 56px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
}

.brand:hover {
  text-decoration: none;
}

.brand:focus-visible {
  border-radius: var(--radius);
}

.brand__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.brand__plate {
  display: inline-flex;
  align-items: stretch;
  height: 28px;
  border: 1.5px solid #111;
  border-radius: 3px;
  overflow: hidden;
  background: var(--plate-face);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12);
  color: #111;
  font-family: var(--font-plate);
  line-height: 1;
}

.brand__plate-left {
  display: flex;
  align-items: flex-end;
  padding: 2px 5px 3px;
  font-size: 13px;
  letter-spacing: 0.02em;
  border-right: 1.5px solid #111;
}

.brand__plate-right {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  width: 22px;
  padding: 2px 2px 1px;
  font-size: 9px;
}

.brand__plate-right span:last-child {
  font-family: var(--font);
  font-size: 6px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.brand__text {
  display: flex;
  flex-direction: column;
  gap: 0;
  line-height: 1.05;
}

.brand__name {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.035em;
}

.brand__tag {
  font-size: 10px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 0.02em;
  text-transform: lowercase;
}

.site-nav {
  display: flex;
  gap: 4px;
  margin-left: 8px;
}

.site-nav__link {
  padding: 8px 12px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  transition: background var(--ease), color var(--ease);
}

.site-nav__link:hover,
.site-nav__link.is-active {
  background: var(--accent-weak);
  color: var(--accent);
  text-decoration: none;
}

.site-header__fav {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  text-decoration: none;
}

.site-header__fav:hover {
  color: var(--accent);
  text-decoration: none;
}

.site-header__fav-count {
  color: var(--text-muted);
  font-weight: 600;
}

.site-header__search {
  margin-left: 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
}

.site-main {
  padding-bottom: 64px;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.72);
  padding: 32px 0 40px;
}

.site-footer__inner {
  display: grid;
  gap: 12px;
}

.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand__plate--footer {
  height: 22px;
}

.brand__plate--footer .brand__plate-left {
  font-size: 11px;
  padding: 1px 4px 2px;
}

.brand__plate--footer .brand__plate-right {
  width: 18px;
  font-size: 8px;
}

.brand__plate--footer .brand__plate-right span:last-child {
  font-size: 5px;
}

.site-footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 14px;
}

.site-footer__note {
  margin: 0;
  color: var(--text-muted);
  font-size: 13px;
  max-width: 52ch;
}

.hero-filter {
  padding: 28px 0 8px;
}

.hero-filter__brand {
  margin-bottom: 18px;
  max-width: 40rem;
}

.hero-filter__eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-filter__title {
  margin: 0;
  font-size: clamp(44px, 8vw, 68px);
  line-height: 0.92;
  letter-spacing: -0.05em;
  font-weight: 800;
  color: var(--text);
}

.hero-filter__lead {
  margin: 10px 0 0;
  color: var(--text-muted);
  font-size: 16px;
  max-width: 38ch;
  line-height: 1.45;
}

.filter-panel {
  position: sticky;
  top: 56px;
  z-index: 30;
  padding: 14px 16px 16px;
  border: 1px solid rgba(226, 230, 236, 0.95);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(12px);
}

.segment {
  display: inline-flex;
  padding: 4px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--border);
  margin-bottom: 12px;
}

.segment__item {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transition: background var(--ease), color var(--ease), transform var(--ease);
}

.segment__item:hover {
  text-decoration: none;
  color: var(--text);
}

.segment__item.is-active {
  background: var(--bg);
  color: var(--accent);
  box-shadow: 0 1px 2px rgba(20, 22, 26, 0.06);
}

.segment__item:focus-visible {
  outline-offset: 1px;
}

.plate-filter {
  overflow-x: auto;
  padding: 2px 0 4px;
  -webkit-overflow-scrolling: touch;
}

.plate-wrap {
  --plate-h: 92px;
  display: inline-flex;
  align-items: stretch;
  width: min(100%, 430px);
  height: var(--plate-h);
  border: 3.5px solid #111;
  border-radius: 5px;
  background: var(--plate-face);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.55) inset,
    0 -1px 0 rgba(0, 0, 0, 0.06) inset,
    0 6px 18px rgba(15, 23, 42, 0.08);
  color: #111;
  overflow: hidden;
}

.plate-wrap__body {
  display: flex;
  align-items: flex-end;
  flex: 1 1 auto;
  gap: 2px;
  padding: 0 10px 8px 14px;
  position: relative;
}

.plate-wrap__body::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  border-right: 3.5px solid #111;
}

.plate-wrap__region {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  width: 92px;
  flex: 0 0 92px;
  padding: 4px 4px 6px;
}

.plate-slot {
  display: block;
  position: relative;
  flex: 1 1 0;
  min-width: 0;
}

.plate-slot--letter {
  flex: 0.92 1 0;
}

.plate-slot--digit {
  flex: 1.05 1 0;
}

.plate-slot__select {
  appearance: none;
  -webkit-appearance: none;
  width: 100%;
  height: calc(var(--plate-h) - 18px);
  margin: 0;
  padding: 0;
  border: 0;
  border-bottom: 2px solid #222;
  border-radius: 0;
  background: transparent;
  color: #111;
  font-family: var(--font-plate);
  font-size: 58px;
  font-weight: 400;
  line-height: 1;
  text-align: center;
  text-shadow: 2px 1px 2px rgb(150, 150, 150);
  cursor: pointer;
}

.plate-slot--letter .plate-slot__select {
  font-size: 44px;
  padding-top: 18px;
  height: calc(var(--plate-h) - 20px);
}

.plate-slot__select--reg {
  width: 100%;
  height: 48px;
  font-size: 36px;
  padding-top: 2px;
  border-bottom-width: 2px;
}

.plate-slot__select:hover {
  background: rgba(255, 255, 255, 0.35);
}

.plate-slot__select:focus {
  outline: none;
}

.plate-slot__select:focus-visible {
  background: rgba(37, 99, 235, 0.08);
  box-shadow: inset 0 -2px 0 var(--accent);
}

.plate-slot__select:has(option[value=""]:checked) {
  opacity: 0.38;
}

.plate-slot__select option {
  font-family: var(--font);
  font-size: 16px;
  text-shadow: none;
}

.plate-wrap__flag {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  margin-top: 4px;
}

.plate-wrap__rus {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1;
}

.plate-wrap__stripes {
  display: flex;
  flex-direction: column;
  width: 22px;
  height: 15px;
  border: 1px solid #111;
  overflow: hidden;
}

.plate-wrap__stripes i {
  display: block;
  flex: 1 1 0;
  margin: 0;
}

.plate-wrap__stripes .is-white {
  background: #fff;
}

.plate-wrap__stripes .is-blue {
  background: #0039a6;
}

.plate-wrap__stripes .is-red {
  background: #d52b1e;
}

.plate-wrap--moto {
  width: min(100%, 220px);
  height: 118px;
  flex-direction: column;
}

.plate-wrap--moto .plate-wrap__body {
  flex-wrap: wrap;
  padding: 8px 10px 4px;
  gap: 0 4px;
  justify-content: center;
}

.plate-wrap--moto .plate-wrap__body::after {
  display: none;
}

.plate-wrap--moto .plate-slot:nth-child(-n+4) {
  flex: 0 0 22%;
}

.plate-wrap--moto .plate-slot:nth-child(n+5) {
  flex: 0 0 18%;
}

.plate-wrap--moto .plate-wrap__region {
  width: 100%;
  flex: 0 0 auto;
  flex-direction: row;
  justify-content: center;
  gap: 10px;
  border-top: 2px solid #111;
  padding-top: 4px;
}

.plate-wrap--moto .plate-slot__select,
.plate-wrap--moto .plate-slot--letter .plate-slot__select {
  font-size: 34px;
  height: 42px;
  padding-top: 0;
}

.filter-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin-top: 12px;
}

.pattern-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}

.fav-link:hover {
  color: var(--accent);
  text-decoration: none;
}

.fav-link__icon {
  width: 16px;
  height: 16px;
  background: #f59e0b;
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  flex-shrink: 0;
}

.fav-link__count {
  color: var(--text-muted);
  font-weight: 600;
}

.chip {
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  border-radius: var(--radius);
  padding: 8px 12px;
  min-height: 36px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease);
}

.chip:hover {
  border-color: #c9d3ea;
  background: var(--accent-weak);
}

.chip:active {
  transform: scale(0.97);
}

.chip.is-active {
  border-color: var(--accent);
  background: var(--accent-weak);
  color: var(--accent);
}

.chip:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.chip.is-active:active {
  transform: scale(0.96);
}

.advanced {
  margin-top: 12px;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

.advanced__summary {
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
  color: var(--text-muted);
  list-style: none;
  padding: 4px 0;
}

.advanced__summary::-webkit-details-marker {
  display: none;
}

.advanced__summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.advanced__body {
  padding-top: 12px;
}

.advanced__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.advanced__checks {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  margin-top: 12px;
}

.field {
  display: grid;
  gap: 6px;
}

.field--inline {
  min-width: 200px;
}

.field__label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
}

.field__input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg);
  padding: 10px 12px;
  color: var(--text);
  min-height: 42px;
  transition: border-color var(--ease), box-shadow var(--ease);
}

.field__input:hover {
  border-color: #d0d5de;
}

.field__input:focus {
  outline: none;
}

.field__input:focus-visible {
  border-color: var(--accent);
  box-shadow: var(--focus-ring);
}

select.field__input {
  color: var(--text);
  background-color: var(--bg);
}

select.field__input option {
  color: var(--text);
  background: var(--bg);
}

.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  min-height: 40px;
}

.check input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.catalog {
  padding-top: 20px;
}

.catalog__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.catalog__count {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

.catalog__count strong {
  color: var(--text);
  font-size: 16px;
}

.catalog__results {
  position: relative;
  min-height: 240px;
}

.catalog__results.is-loading {
  pointer-events: none;
}

.catalog__results.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: 12px;
  background: color-mix(in srgb, var(--bg) 55%, transparent);
  backdrop-filter: blur(1px);
}

.catalog__results.is-updating {
  /* keep results in place — no opacity/translate jump */
}

.catalog__results.is-updating .plate-card {
  animation: none;
}

@keyframes results-fade {
  from {
    opacity: 0.4;
  }
  to {
    opacity: 1;
  }
}

@keyframes card-stagger {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: stretch;
}

.plate-card {
  display: flex;
  flex-direction: column;
  gap: 14px;
  height: 100%;
  min-height: 100%;
  padding: 18px 16px 16px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: none;
  transition: box-shadow var(--ease), border-color var(--ease), background var(--ease);
}

.plate-card:hover {
  box-shadow: var(--shadow-soft);
  border-color: #e2e6ec;
  background: #fff;
}

.plate-card__top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.plate-card__plate {
  text-decoration: none;
  color: inherit;
  display: inline-block;
}

.plate-card__plate:hover {
  text-decoration: none;
}

.plate-card__plate:focus-visible {
  border-radius: var(--radius-sm);
}

.plate-card__meta {
  display: grid;
  gap: 8px;
}

.plate-card__price-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.plate-card__price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.plate-card__from {
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 600;
}

.plate-card__amount {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text);
}

.plate-card__freshness {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 13px;
  min-height: 1.4em;
}

.plate-card__sep {
  opacity: 0.45;
}

.plate-card__more {
  color: var(--accent);
  font-weight: 700;
  text-underline-offset: 2px;
}

.plate-card__more:hover {
  text-decoration: underline;
}

.plate-card__seller {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.01em;
  min-height: 1.25em;
}

.plate-card__seller:empty::before {
  content: "\00a0";
}

.plate-card__contact {
  display: grid;
  gap: 8px;
  margin-top: auto;
  min-height: 48px;
  align-content: end;
}

.plate-card[data-has-phone] .plate-card__contact {
  min-height: 112px;
}

.plate-card__contact .btn--primary {
  width: 100%;
  justify-content: center;
  min-height: 44px;
}

.plate-card__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  min-height: 36px;
}

.plate-card__detail {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-muted);
  text-decoration: none;
}

.plate-card__detail:hover {
  color: var(--accent);
  text-decoration: none;
}

.plate-card__offers {
  border-top: 1px solid var(--border);
  padding-top: 12px;
}

.contact-block {
  display: grid;
  gap: 10px;
}

.contact-block__seller {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px 10px;
}

.contact-block__seller-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.contact-block__seller-name {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.contact-block__platform {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none;
  width: fit-content;
}

.contact-block__platform:hover {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.phone-reveal {
  display: grid;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid #d7deea;
  border-radius: 12px;
  background:
    linear-gradient(180deg, #ffffff 0%, #f3f6fb 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.phone-reveal--compact {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.phone-reveal--sticky {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.phone-reveal__masked,
.phone-reveal__number {
  font-family: var(--font-plate);
  font-size: 22px;
  line-height: 1.1;
  letter-spacing: 0.02em;
  color: var(--text);
  text-decoration: none;
}

.phone-reveal__number:hover {
  color: var(--accent);
  text-decoration: none;
}

.phone-reveal__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.phone-reveal__btn,
.phone-reveal__call {
  min-height: 42px;
}

.phone-reveal--compact .phone-reveal__btn,
.phone-reveal--compact .phone-reveal__call,
.phone-reveal--sticky .phone-reveal__btn,
.phone-reveal--sticky .phone-reveal__call {
  min-height: 38px;
}

.contact-block--lg .phone-reveal {
  padding: 16px 18px;
}

.contact-block--lg .phone-reveal__masked,
.contact-block--lg .phone-reveal__number {
  font-size: 28px;
}

.plate-detail__contact {
  margin: 16px 0 4px;
}

.text-muted {
  color: var(--text-muted);
  font-size: 13px;
}

.sticky-call {
  display: none;
}

@media (max-width: 767px) {
  .sticky-call {
    display: block;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 50;
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, 0.96);
    border-top: 1px solid var(--border);
    backdrop-filter: blur(10px);
    box-shadow: 0 -8px 24px rgba(18, 21, 26, 0.08);
  }

  .sticky-call__inner {
    width: min(100%, var(--container));
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

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

  .sticky-call__label {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
  }

  .sticky-call__price strong {
    font-size: 16px;
    letter-spacing: -0.02em;
  }

  .sticky-call .btn {
    flex: 0 0 auto;
    min-width: 150px;
  }

  .plate-detail {
    padding-bottom: 88px;
  }
}

.plate-card__offers-loading {
  margin: 0;
  color: var(--text-muted);
  font-size: 13px;
}

.offers-mini {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.offers-mini__item {
  display: grid;
  gap: 10px;
  font-size: 13px;
  padding: 12px;
  border-radius: 10px;
  background: var(--surface);
}

.offers-mini__main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.offers-mini__seller {
  font-weight: 700;
  color: var(--text);
}

.offers-mini__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.offers-mini__go {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.platform-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  background: transparent;
  border: 1px solid transparent;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
}

.platform-badge img {
  width: 14px;
  height: 14px;
  border-radius: 3px;
  opacity: 0.9;
}

.fresh-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #b8bfca;
  display: inline-block;
  flex-shrink: 0;
}

.fresh-dot.is-fresh {
  background: var(--success);
  box-shadow: 0 0 0 3px rgba(22, 163, 74, 0.14);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 10px 14px;
  min-height: 40px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--ease), border-color var(--ease), color var(--ease), transform var(--ease);
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--primary:hover {
  background: #1d4ed8;
}

.btn--ghost {
  background: var(--bg);
  border-color: var(--border);
  color: var(--text);
}

.btn--ghost:hover {
  background: var(--surface);
}

.btn--sm {
  padding: 7px 10px;
  min-height: 34px;
  font-size: 13px;
}

.linkish {
  border: 0;
  background: none;
  padding: 0;
  color: var(--accent);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.linkish:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

.chevron::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: 4px;
}

.fav-btn {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: inline-grid;
  place-items: center;
  position: relative;
  color: #94a3b8;
  transition: color var(--ease), transform var(--ease), background var(--ease);
}

.fav-btn:hover {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.08);
}

.fav-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.fav-btn.is-active {
  color: #f59e0b;
}

.fav-btn__icon {
  width: 18px;
  height: 18px;
  background: currentColor;
  clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
  opacity: 0.45;
  transition: opacity var(--ease), transform var(--ease);
}

.fav-btn:hover .fav-btn__icon,
.fav-btn.is-active .fav-btn__icon {
  opacity: 1;
}

.fav-btn.is-active .fav-btn__icon {
  transform: scale(1.08);
}

.fav-btn__hint {
  display: none;
}

.fav-btn--lg {
  width: auto;
  height: 42px;
  padding: 0 14px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg);
  grid-auto-flow: column;
  gap: 8px;
  color: var(--text-muted);
}

.fav-btn--lg .fav-btn__hint--add {
  display: inline;
  font-size: 14px;
  font-weight: 700;
}

.fav-btn--lg .fav-btn__hint--remove {
  display: none;
  font-size: 14px;
  font-weight: 700;
}

.fav-btn--lg.is-active {
  background: #fff7ed;
  border-color: #fdba74;
  color: #b45309;
}

.fav-btn--lg.is-active .fav-btn__hint--add {
  display: none;
}

.fav-btn--lg.is-active .fav-btn__hint--remove {
  display: inline;
}

.fav-btn--lg .fav-btn__icon {
  opacity: 0.7;
}

.favourites-page {
  padding: 28px 0 8px;
}

.favourites-page__head {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: 20px;
}

.favourites-page__eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.favourites-page__title {
  margin: 0;
  font-size: clamp(32px, 5vw, 44px);
  letter-spacing: -0.04em;
  line-height: 1;
}

.favourites-page__lead {
  margin: 8px 0 0;
  color: var(--text-muted);
  max-width: 42ch;
  font-size: 15px;
}

.favourites-page__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
}

.number-plate {
  --np-size: 22px;
  color: #222;
  border: 2px solid #111;
  letter-spacing: 0;
  display: inline-flex;
  align-items: stretch;
  justify-content: space-between;
  border-radius: 0.2em;
  font-size: var(--np-size);
  font-weight: 400;
  background: var(--plate-face);
  box-shadow:
    1px 1px 1px rgb(255 255 255 / 30%),
    -1px -1px 1px rgb(255 255 255 / 30%),
    0 2px 6px rgba(15, 23, 42, 0.08);
  vertical-align: middle;
}

.number-plate--sm {
  --np-size: 14px;
}

.number-plate--lg {
  --np-size: 36px;
  border-width: 3px;
}

.number-plate__left {
  display: flex;
  position: relative;
  align-items: flex-end;
  flex: 1 1 auto;
  padding: 0.28em 0.32em 0.22em;
  height: 1.65em;
}

.number-plate__left::before {
  content: "";
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  border-right: 2px solid #111;
}

.number-plate--lg .number-plate__left::before {
  border-right-width: 3px;
}

.number-plate__right {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  width: 2.05em;
  height: 1.65em;
}

.number-plate__right > * {
  height: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.number-plate__region {
  font-size: 1.05em;
  font-family: var(--font-plate);
  padding-top: 0.22em;
  text-shadow: var(--plate-shadow);
  gap: 0;
}

.number-plate__region span {
  display: inline-block;
  min-width: 0.45em;
  text-align: center;
}

.number-plate__country {
  display: flex;
  align-items: center;
  text-transform: uppercase;
  font-weight: 800;
  font-size: 0.48em;
  padding-top: 0.2em;
  gap: 0.15em;
  font-family: var(--font);
}

.number-plate__country > span {
  position: relative;
  top: 1px;
}

.number-plate__num {
  font-family: var(--font-plate);
  font-size: 1.7em;
  line-height: 0.7;
  position: relative;
  bottom: -1px;
  width: 0.52em;
  text-align: center;
  text-shadow: var(--plate-shadow);
}

.number-plate__letter {
  position: relative;
  bottom: -1.5px;
  text-shadow: var(--plate-shadow);
  font-family: var(--font-plate);
  font-size: 1.3em;
  line-height: 0.7;
  width: 0.72em;
  text-align: center;
}

.number-plate__flag {
  width: 14px;
  border: 1px solid #111;
  height: 9px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: 0.15em;
  flex-shrink: 0;
}

.number-plate--lg .number-plate__flag {
  width: 18px;
  height: 12px;
}

.number-plate__flag span {
  background: #3474a8;
  height: 100%;
  width: 100%;
  display: block;
}

.number-plate__flag::before {
  content: "";
  height: 2px;
  left: 0;
  right: 0;
  bottom: 0;
  position: absolute;
  background: #d52b1e;
}

.number-plate__flag::after {
  content: "";
  height: 2px;
  left: 0;
  right: 0;
  top: 0;
  position: absolute;
  background: #fff;
}

.number-moto {
  color: #000;
  width: 97px;
  height: 80px;
  border: 1.5px solid #111;
  letter-spacing: 0;
  display: inline-flex;
  flex-direction: column;
  border-radius: 0.2em;
  font-size: 20px;
  background: var(--plate-face);
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
  vertical-align: middle;
}

.number-plate--lg.number-moto,
.number-moto.number-plate--lg {
  width: 150px;
  height: 124px;
  font-size: 30px;
  border-width: 2.5px;
}

.number-moto__top {
  font-family: var(--font-plate);
  font-size: 1.7em;
  text-align: center;
  line-height: 0.6;
  padding: 0.25em 0.3em 0.45em;
  height: 51%;
  text-shadow: var(--plate-shadow);
}

.number-moto__bottom {
  display: flex;
  font-size: 1.46em;
  font-family: var(--font-plate);
  line-height: 0.7;
  height: 49%;
  text-shadow: var(--plate-shadow);
}

.number-moto__bottom > * {
  width: 50%;
  text-align: center;
  padding: 0.4em 0.2em 0.2em;
  position: relative;
}

.number-moto__letters {
  text-align: right;
}

.number-moto__letters::before {
  content: "";
  border-right: 1.5px solid #111;
  height: 75%;
  position: absolute;
  bottom: 0;
  right: -1px;
}

.number-moto__numbers {
  text-align: left;
  padding-left: 0.35em;
}

.empty-state {
  text-align: center;
  padding: 48px 24px;
  border: 1px dashed #d5dae3;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.78);
}

.empty-state__icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 16px;
  border-radius: var(--radius);
  background:
    linear-gradient(145deg, var(--accent-weak), #fff),
    var(--surface);
  border: 1px solid var(--border);
  position: relative;
}

.empty-state__icon::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 2px solid var(--accent);
  border-radius: 3px;
  opacity: 0.45;
}

.empty-state__title {
  margin: 0 0 8px;
  font-size: 22px;
  letter-spacing: -0.02em;
}

.empty-state__text {
  margin: 0 auto 20px;
  max-width: 40ch;
  color: var(--text-muted);
  font-size: 15px;
}

.empty-state__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.skeleton-grid {
  display: grid;
  gap: 16px;
}

.skeleton-card {
  height: 168px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: linear-gradient(90deg, #f3f4f6 0%, #eef1f6 40%, #f3f4f6 80%);
  background-size: 200% 100%;
  animation: skeleton 1.1s ease infinite;
}

@keyframes skeleton {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

.page {
  padding: 36px 0 16px;
}

.page__title {
  margin: 0 0 10px;
  font-size: clamp(28px, 4vw, 40px);
  letter-spacing: -0.03em;
}

.page__lead {
  margin: 0 0 28px;
  color: var(--text-muted);
  max-width: 58ch;
  font-size: 16px;
}

.prose {
  display: grid;
  gap: 16px;
  max-width: 68ch;
  color: var(--text);
}

.prose p {
  margin: 0;
}

.about-points {
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  display: grid;
  gap: 12px;
  max-width: 720px;
}

.about-points__item {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.88);
}

.about-points__item h2 {
  margin: 0 0 6px;
  font-size: 16px;
  letter-spacing: -0.01em;
}

.about-points__item p {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

.platform-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.platform-list__item {
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  transition: border-color var(--ease), box-shadow var(--ease), transform var(--ease);
}

.platform-list__item:hover {
  border-color: #d5dbe7;
  box-shadow: var(--shadow-soft);
  transform: translateY(-1px);
}

.platform-list__head {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.platform-list__logo {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.platform-list__name {
  margin: 0;
  font-size: 18px;
}

.platform-list__code {
  margin: 2px 0 0;
  color: var(--text-muted);
  font-size: 13px;
  font-family: var(--font-plate);
}

.platform-list__fresh {
  margin: 0;
  color: var(--text-muted);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.platform-list__status {
  margin-left: auto;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  background: var(--surface);
  border: 1px solid var(--border);
}

.platform-list__status.is-fresh {
  color: var(--success);
  background: #f0fdf4;
  border-color: #bbf7d0;
}

.plate-detail {
  padding: 28px 0 8px;
}

.back-link {
  display: inline-block;
  margin-bottom: 20px;
  font-weight: 700;
  font-size: 14px;
}

.plate-detail__hero {
  display: grid;
  gap: 24px;
  margin-bottom: 32px;
  padding: 22px 20px;
  border: 1px solid transparent;
  border-radius: 14px;
  background:
    radial-gradient(500px 180px at 0% 0%, rgba(37, 99, 235, 0.06), transparent 60%),
    rgba(255, 255, 255, 0.88);
}

.plate-detail__title {
  margin: 0;
  font-size: clamp(28px, 5vw, 40px);
  letter-spacing: -0.03em;
}

.plate-detail__reg {
  color: var(--text-muted);
  font-family: var(--font);
  font-weight: 700;
}

.plate-detail__region {
  margin: 6px 0 0;
  color: var(--text-muted);
}

.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0;
}

.stats dt {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 700;
}

.stats dd {
  margin: 4px 0 0;
  font-size: 18px;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 8px;
}

.plate-detail__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.plate-detail__share {
  display: flex;
  gap: 8px;
  align-items: center;
}

.section-title {
  margin: 0 0 12px;
  font-size: 20px;
  letter-spacing: -0.02em;
}

.offers-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.94);
  margin-bottom: 28px;
}

.offers-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.offers-table th,
.offers-table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.offers-table th {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 700;
  background: var(--surface);
}

.offers-table tr.is-primary {
  background: linear-gradient(90deg, var(--accent-weak) 0%, rgba(234, 240, 255, 0.35) 100%);
}

.offers-table tr.is-primary td:first-child {
  box-shadow: inset 3px 0 0 var(--accent);
}

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

.offers-table__price {
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.tag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: var(--radius-sm);
  background: #fff;
  border: 1px solid #bfdbfe;
  color: var(--accent);
  font-size: 11px;
  font-weight: 800;
}

.price-history {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
  max-width: 420px;
}

.price-history li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  font-size: 14px;
}

.toast-stack {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 80;
  display: grid;
  gap: 8px;
  width: min(320px, calc(100vw - 32px));
}

.toast {
  padding: 12px 14px;
  border-radius: var(--radius);
  background: #111827;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  box-shadow: var(--shadow);
  animation: toast-in 150ms ease;
}

.toast--error {
  background: var(--danger);
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.geo-bar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
  margin: 0 0 14px;
}

.geo-bar__region,
.geo-bar__city {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: color-mix(in srgb, var(--surface) 92%, var(--bg));
  text-align: left;
  cursor: pointer;
  color: inherit;
  font: inherit;
}

.geo-bar__city {
  cursor: default;
}

.geo-bar__city.is-hidden {
  visibility: hidden;
  pointer-events: none;
}

.geo-bar__label {
  font-size: 11px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.geo-bar__value {
  font-size: 15px;
  font-weight: 600;
}

.geo-bar__select {
  border: 0;
  background: transparent;
  padding: 0;
  margin: 0;
  font: inherit;
  font-weight: 600;
  color: inherit;
  width: 100%;
}

.modal {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0;
  width: min(420px, calc(100vw - 32px));
  box-shadow: var(--shadow);
}

.modal--regions {
  width: min(720px, calc(100vw - 24px));
  max-height: min(80vh, 720px);
}

.modal--regions .modal__form {
  max-height: min(80vh, 720px);
  overflow: auto;
}

.region-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
}

.region-grid__item {
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: inherit;
  font: inherit;
  font-size: 13px;
  text-align: left;
  padding: 10px 12px;
  cursor: pointer;
}

.region-grid__item:hover,
.region-grid__item.is-active {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--border));
  background: color-mix(in srgb, var(--accent) 10%, var(--surface));
}

.modal::backdrop {
  background: rgba(15, 23, 42, 0.35);
}

.modal__form {
  padding: 20px;
  display: grid;
  gap: 12px;
}

.modal__form h2 {
  margin: 0;
  font-size: 20px;
}

.modal__text {
  margin: 0;
  color: var(--text-muted);
  font-size: 14px;
}

.modal__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 4px;
}

.catalog__more {
  display: flex;
  justify-content: center;
  margin-top: 20px;
}

.empty-inline {
  color: var(--text-muted);
  padding: 20px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.7);
}

@media (min-width: 640px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .plate-detail__hero {
    grid-template-columns: auto 1fr;
    align-items: start;
  }

  .stats {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .skeleton-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .advanced__grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .site-header__inner {
    min-height: 60px;
  }

  .filter-panel {
    top: 60px;
  }
}

@media (max-width: 639px) {
  .site-nav {
    margin-left: 0;
  }

  .site-header__search {
    display: none;
  }

  .site-header__fav {
    margin-left: auto;
  }

  .filter-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .favourites-page__actions {
    width: 100%;
  }

  .favourites-page__actions .btn {
    flex: 1 1 auto;
  }

  .hero-filter {
    padding-top: 12px;
  }

  .hero-filter__brand {
    margin-bottom: 12px;
  }

  .hero-filter__lead {
    font-size: 14px;
  }

  .filter-panel {
    top: 56px;
    padding: 8px 10px 10px;
    border-radius: var(--radius);
  }

  .segment {
    margin-bottom: 8px;
    width: 100%;
  }

  .segment__item {
    flex: 1;
    text-align: center;
    padding: 8px 10px;
  }

  .plate-wrap {
    --plate-h: 68px;
    width: 100%;
    max-width: 360px;
    border-width: 2.5px;
    border-radius: 4px;
  }

  .plate-wrap__body {
    padding: 0 6px 6px 10px;
    gap: 1px;
  }

  .plate-wrap__body::after {
    border-right-width: 2.5px;
  }

  .plate-wrap__region {
    width: 72px;
    flex-basis: 72px;
  }

  .plate-slot__select {
    font-size: 40px;
    height: calc(var(--plate-h) - 14px);
    text-shadow: 1px 1px 1px rgb(150, 150, 150);
  }

  .plate-slot--letter .plate-slot__select {
    font-size: 30px;
    padding-top: 12px;
    height: calc(var(--plate-h) - 14px);
  }

  .plate-slot__select--reg {
    font-size: 26px;
    height: 36px;
  }

  .plate-wrap__rus {
    font-size: 11px;
  }

  .plate-wrap__stripes {
    width: 16px;
    height: 11px;
  }

  .plate-wrap--moto {
    height: 104px;
    max-width: 200px;
  }

  .pattern-chips {
    margin-top: 8px;
    gap: 6px;
  }

  .chip {
    padding: 8px 10px;
    font-size: 12px;
  }

  .advanced__grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .advanced__checks {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .field--inline {
    min-width: 0;
  }

  .plate-card__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .plate-card__actions .btn {
    width: 100%;
  }

  .phone-reveal__btn,
  .phone-reveal__call {
    width: 100%;
  }

  .contact-block--lg .phone-reveal__masked,
  .contact-block--lg .phone-reveal__number {
    font-size: 24px;
  }

  .number-plate--lg {
    --np-size: 26px;
  }

  .number-moto.number-plate--lg {
    width: 120px;
    height: 100px;
    font-size: 24px;
  }

  .plate-detail__hero {
    padding: 14px;
  }

  .plate-detail__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .plate-detail__actions .btn {
    width: 100%;
  }

  .offers-mini__item {
    grid-template-columns: 1fr;
    gap: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
