/* Design system mirrored from car74.ru (Mantine blue + Inter) */
:root {
  --blue: #228be6;
  --blue-hover: #1c7ed6;
  --blue-light: #e7f5ff;
  --blue-text: #1864ab;
  --text: #1a1a2e;
  --text-muted: #868e96;
  --border: #e9ecef;
  --bg: #ffffff;
  --bg-soft: #f8f9fa;
  --green: #40c057;
  --green-bg: #ebfbee;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 4px 12px rgba(0,0,0,.04);
  --font: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --header-h: 72px;
  --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }

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

/* Header */
.header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: #fff;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  width: min(100% - 32px, var(--max)); margin-inline: auto;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-logo {
  height: 56px; width: auto; max-width: 240px; object-fit: contain;
  border-radius: 6px; background: #fff;
}
.brand-logo-footer { height: 88px; max-width: 140px; margin-bottom: 8px; object-fit: contain; }
.brand-text strong { display: block; font-size: 17px; line-height: 1.15; font-weight: 700; }
.brand-text span { font-size: 12px; color: var(--text-muted); }
@media (max-width: 520px) {
  .brand-logo { height: 48px; max-width: 200px; }
}
.header-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.header-actions .btn-sm {
  height: 40px; padding: 0 14px; font-size: 14px; line-height: 14px;
}
@media (max-width: 420px) {
  .header-actions .btn-sm { padding: 0 10px; font-size: 13px; }
}

/* Burger — as car74: compact blue icon button */
.btn-icon {
  width: 34px; height: 34px; padding: 0; border: 0; border-radius: 4px;
  background: transparent; color: var(--blue);
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
}
.btn-icon span {
  display: block; height: 2px; width: 18px; margin-inline: auto;
  background: currentColor; border-radius: 1px;
}

/* Buttons — measured from car74.ru: h=50, radius=8, primary 18/700, outline 18/600 border #2e2e2e */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: 50px; padding: 0 26px; border-radius: 8px;
  border: 1px solid transparent; font-size: 18px; line-height: 18px;
  text-decoration: none; transition: background .15s ease, border-color .15s ease, color .15s ease;
  box-shadow: none; white-space: nowrap;
}
.btn-primary {
  background: var(--blue); color: #fff; font-weight: 700; border-color: transparent;
}
.btn-primary:hover { background: var(--blue-hover); color: #fff; }
.btn-outline {
  background: transparent; color: #2e2e2e; font-weight: 600;
  border: 1px solid #2e2e2e;
}
.btn-outline:hover { background: var(--bg-soft); color: #2e2e2e; }
.btn-arrow { display: inline-block; font-weight: 700; }
.btn-block { width: 100%; }
.btn-sm {
  height: 36px; padding: 0 14px; font-size: 14px; border-radius: 4px;
}

/* Badges */
.badge {
  display: inline-flex; align-items: center;
  padding: 4px 10px; border-radius: 999px;
  font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  background: var(--blue-light); color: var(--blue-text);
}
.badge-green { background: var(--green-bg); color: #2b8a3e; }
.badge-muted { background: rgba(255,255,255,.9); color: var(--text); }

/* Hero */
.hero {
  padding: 28px 0 40px;
  background:
    radial-gradient(900px 320px at 80% -10%, rgba(34,139,230,.12), transparent 60%),
    linear-gradient(180deg, #fff 0%, var(--bg-soft) 100%);
}
.mode-toggle {
  display: inline-flex; background: #f1f3f5; border-radius: 4px; padding: 4px; margin-bottom: 18px;
}
.mode-toggle button {
  border: 0; background: transparent; padding: 10px 14px; border-radius: 4px;
  font-weight: 500; font-size: 14px; color: #495057;
}
.mode-toggle button.active {
  background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.08); color: var(--text); font-weight: 600;
}
.mode-toggle button:disabled { opacity: .55; cursor: default; }
.hero h1 {
  margin: 12px 0 12px; font-size: clamp(28px, 5vw, 42px);
  line-height: 1.15; letter-spacing: -.02em; font-weight: 700;
}
.hero-lead { color: #495057; font-size: 16px; max-width: 560px; margin: 0 0 22px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.hero-search {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  margin-bottom: 14px;
  max-width: 640px;
}
.hero-search input[type="search"] {
  width: 100%;
  height: 56px;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0 18px;
  font: inherit;
  font-size: 17px;
  background: #fff;
  box-shadow: var(--shadow);
}
.hero-search input[type="search"]:focus {
  outline: 2px solid rgba(34, 139, 230, .35);
  border-color: var(--blue);
}
.hero-search .btn { height: 56px; padding: 0 22px; font-size: 17px; }
.hero-cta-sub {
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-bottom: 22px;
}
.hero-cta-sub .btn { height: 44px; font-size: 15px; padding: 0 18px; }
.link-muted { color: var(--blue); font-weight: 600; font-size: 14px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.search-status {
  margin: 0 0 14px; font-size: 14px; color: var(--text-muted);
}
@media (max-width: 560px) {
  .hero-search { grid-template-columns: 1fr; }
  .hero-search .btn { width: 100%; }
}
.hero-facts {
  display: flex; flex-wrap: wrap; gap: 14px 18px; color: #495057; font-size: 14px;
}
.hero-facts strong { color: var(--text); }
.hero-grid {
  display: grid; gap: 16px;
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: 1.1fr .9fr; align-items: center; }
}
.hero-card {
  display: block; background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden;
}
.hero-card img { width: 100%; height: 260px; object-fit: cover; background: #dee2e6; }
.hero-card-body { padding: 14px 16px 16px; }
.hero-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.hero-card-body strong { font-size: 16px; }
.hero-card-body p { margin: 4px 0 0; color: var(--text-muted); font-size: 13px; }

/* Sections */
.section { padding: 48px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { margin-bottom: 20px; }
.section-head h2 {
  margin: 10px 0 8px; font-size: clamp(24px, 3.5vw, 32px); letter-spacing: -.02em;
}
.section-head p { margin: 0; color: #495057; max-width: 640px; }

/* Filters */
.filters { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.filter-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.filter-label { font-size: 13px; color: var(--text-muted); min-width: 70px; }
.chip {
  border: 1px solid var(--border); background: #fff; color: var(--text);
  border-radius: 4px; padding: 10px 16px; font-size: 14px; font-weight: 600;
}
.chip.active { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Catalog cards — like car74 */
.catalog {
  display: grid; gap: 14px;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) { .catalog { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1000px) { .catalog { grid-template-columns: 1fr 1fr 1fr; } }

.card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column;
}
a.card-link, a.hero-card {
  color: inherit; text-decoration: none; transition: box-shadow .15s ease, transform .15s ease;
}
a.card-link:hover, a.hero-card:hover {
  box-shadow: 0 10px 28px rgba(15, 23, 42, .12);
  transform: translateY(-1px);
}
.card-media {
  position: relative; aspect-ratio: 16/10; background: #e9ecef;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; }
.card-media .tag-tl, .card-media .tag-tr, .card-media .tag-br {
  position: absolute; padding: 4px 8px; border-radius: 999px; font-size: 11px; font-weight: 700;
}
.tag-tl { top: 10px; left: 10px; background: rgba(255,255,255,.92); }
.tag-tr { top: 10px; right: 10px; background: rgba(33,37,41,.7); color: #fff; }
.tag-br { bottom: 10px; right: 10px; background: var(--green-bg); color: #2b8a3e; }
.tag-br.demand { background: #fff3bf; color: #e67700; }
.card-body { padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-body h3 { margin: 0; font-size: 17px; }
.card-sub { margin: 0; color: var(--text-muted); font-size: 13px; }
.card-foot {
  margin-top: auto; padding-top: 10px;
  display: flex; align-items: flex-end; justify-content: space-between; gap: 8px;
}
.price { color: var(--blue); font-weight: 800; font-size: 22px; line-height: 1; }
.price small { display: block; color: var(--text-muted); font-size: 12px; font-weight: 500; margin-top: 4px; }
.link-card {
  color: var(--blue); font-weight: 600; font-size: 14px; white-space: nowrap;
  background: none; border: 0; padding: 0; cursor: pointer;
}
.link-card:hover { text-decoration: underline; }

/* Steps */
.steps {
  display: grid; gap: 12px;
  grid-template-columns: 1fr;
}
@media (min-width: 800px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 16px; box-shadow: var(--shadow);
}
.step-num {
  width: 28px; height: 28px; border-radius: 8px; background: var(--blue-light); color: var(--blue);
  display: grid; place-items: center; font-weight: 800; font-size: 13px; margin-bottom: 10px;
}
.step h3 { margin: 0 0 6px; font-size: 16px; }
.step p { margin: 0; color: var(--text-muted); font-size: 14px; }

/* Benefits */
.benefits {
  display: grid; gap: 12px;
  grid-template-columns: 1fr;
}
@media (min-width: 800px) { .benefits { grid-template-columns: 1fr 1fr; } }
.benefit {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; box-shadow: var(--shadow);
}
.benefit h3 { margin: 0 0 6px; font-size: 17px; }
.benefit p { margin: 0; color: #495057; font-size: 14px; }

/* FAQ */
.faq { display: grid; gap: 8px; }
.faq details {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0 14px;
}
.faq summary {
  list-style: none; cursor: pointer; padding: 14px 0; font-weight: 650; font-size: 15px;
  display: flex; justify-content: space-between; gap: 12px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue); font-weight: 700; }
.faq details[open] summary::after { content: "–"; }
.faq-body { color: #495057; font-size: 14px; padding: 0 0 14px; }

/* Contacts / CTA */
.cta-box {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 22px; display: grid; gap: 16px;
}
@media (min-width: 800px) {
  .cta-box { grid-template-columns: 1.2fr .8fr; align-items: center; }
}
.cta-box h2 { margin: 0 0 8px; font-size: 26px; }
.cta-box p { margin: 0; color: #495057; }
.contact-list { display: grid; gap: 10px; font-size: 14px; }
.contact-list strong { display: block; font-size: 12px; color: var(--text-muted); font-weight: 600; }

/* Footer */
.footer {
  border-top: 1px solid var(--border); background: #fff; padding: 28px 0 40px;
  color: #495057; font-size: 13px;
}
.footer-grid {
  display: grid; gap: 18px;
  grid-template-columns: 1fr;
}
@media (min-width: 800px) { .footer-grid { grid-template-columns: 1.2fr 1fr 1fr; } }
.footer a { color: var(--blue); }
.footer h4 { margin: 0 0 8px; color: var(--text); font-size: 14px; }

.form { display: grid; gap: 10px; }
.form input, .form select, .form textarea {
  width: 100%; border: 1px solid var(--border); border-radius: 8px;
  padding: 12px 12px; font: inherit; background: #fff;
}
.form textarea { min-height: 72px; resize: vertical; }
.form-row { display: grid; gap: 10px; grid-template-columns: 1fr 1fr; }
.form-hint { font-size: 12px; color: var(--text-muted); }

.empty {
  padding: 28px; text-align: center; color: var(--text-muted);
  border: 1px dashed var(--border); border-radius: var(--radius); background: #fff;
}

/* Product page */
.btn-sm {
  height: 40px; padding: 0 14px; font-size: 14px; display: inline-flex; align-items: center;
}
.product-page { padding: 24px 0 48px; }
.crumbs {
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  font-size: 13px; color: var(--text-muted); margin-bottom: 18px;
}
.crumbs a { color: var(--blue); text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }
.product-layout {
  display: grid; gap: 20px;
  grid-template-columns: 1fr;
  margin-bottom: 40px;
}
@media (min-width: 900px) {
  .product-layout { grid-template-columns: 1.1fr .9fr; align-items: start; }
}
.product-gallery {
  position: relative; background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
.product-gallery img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover; display: block; background: #e9ecef;
}
.product-gallery .no-photo {
  aspect-ratio: 4/3; display: grid; place-items: center; color: var(--text-muted); background: #e9ecef;
}
.product-badges {
  position: absolute; top: 12px; left: 12px; display: flex; flex-wrap: wrap; gap: 6px;
}
.badge-orange { background: #fff3bf; color: #e67700; }
.product-info h1 { margin: 0 0 8px; font-size: clamp(24px, 4vw, 32px); line-height: 1.2; }
.product-meta { margin: 0 0 14px; color: var(--text-muted); font-size: 15px; }
.product-price {
  color: var(--blue); font-size: 34px; font-weight: 800; line-height: 1; margin-bottom: 14px;
}
.product-price small {
  display: inline; margin-left: 8px; font-size: 14px; font-weight: 500; color: var(--text-muted);
}
.product-tariffs {
  list-style: none; margin: 0 0 14px; padding: 0;
  display: grid; gap: 8px;
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.product-tariffs li {
  display: flex; justify-content: space-between; gap: 12px; font-size: 14px;
}
.product-tariffs span { color: var(--text-muted); }
.product-attrs {
  list-style: none; margin: 0 0 14px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px;
}
.product-attrs li {
  background: var(--blue-light); color: var(--blue); font-size: 13px; font-weight: 600;
  padding: 6px 10px; border-radius: 999px;
}
.product-note { margin: 0 0 16px; color: #495057; font-size: 14px; }
.product-cta-desktop { display: none; grid-gap: 10px; }
@media (min-width: 900px) {
  .product-cta-desktop { display: grid; }
}
.quote-box {
  background: var(--blue-light); border-radius: 8px; padding: 12px 14px;
  display: grid; gap: 4px; font-size: 13px; color: #495057;
}
.quote-box strong { color: var(--blue); font-size: 18px; }
.related { padding-top: 8px; }
.related .section-head { margin-bottom: 16px; }

/* Floating mobile order bar */
.float-order {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 80;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,.96);
  border-top: 1px solid var(--border);
  box-shadow: 0 -8px 24px rgba(15,23,42,.08);
}
.float-order-inner {
  width: min(100%, var(--max)); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.float-order-price {
  color: var(--blue); font-weight: 800; font-size: 22px; line-height: 1;
}
.float-order-price small {
  display: block; margin-top: 2px; color: var(--text-muted); font-size: 12px; font-weight: 500;
}
.float-order .btn { min-width: 140px; height: 48px; font-size: 16px; }
@media (max-width: 899px) {
  .float-order { display: block; }
  .product-page, .order-page { padding-bottom: 96px; }
}

/* Order page */
.order-body { background: var(--bg-soft); }
.order-page { padding: 20px 0 40px; }
.order-wrap { max-width: 640px; }
.order-card {
  background: #fff; border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px; display: grid; gap: 18px;
}
.order-product {
  display: grid; grid-template-columns: 96px 1fr; gap: 12px; align-items: center;
}
.order-product img {
  width: 96px; height: 96px; object-fit: cover; border-radius: 10px; background: #e9ecef;
}
.order-product h1 { margin: 6px 0 4px; font-size: 20px; line-height: 1.25; }
.order-product .product-price { font-size: 24px; margin: 6px 0 0; }
.order-section {
  display: grid; gap: 10px; padding-top: 14px; border-top: 1px solid var(--border);
}
.order-section h2 { margin: 0; font-size: 16px; }
.order-hint { margin: 0; font-size: 13px; color: var(--text-muted); }
.field { display: grid; gap: 6px; font-size: 13px; color: var(--text-muted); }
.field input, .field textarea { color: var(--text); }
.days-pill {
  display: inline-flex; align-items: center; width: fit-content;
  background: var(--blue-light); color: var(--blue); font-weight: 700; font-size: 13px;
  padding: 6px 10px; border-radius: 999px;
}
.toggle {
  display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; color: #343a40;
}
.toggle input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-ui {
  width: 44px; height: 26px; border-radius: 999px; background: #ced4da; position: relative; flex: 0 0 auto;
  transition: background .15s ease;
}
.toggle-ui::after {
  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,.2);
  transition: transform .15s ease;
}
.toggle input:checked + .toggle-ui { background: var(--blue); }
.toggle input:checked + .toggle-ui::after { transform: translateX(18px); }
.delivery-box { display: grid; gap: 8px; }
.pay-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgba(255,255,255,.97);
  border-top: 1px solid var(--border);
  box-shadow: 0 -8px 28px rgba(15,23,42,.1);
}
.pay-bar-inner {
  width: min(100%, 640px); margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.pay-bar-sum small { display: block; color: var(--text-muted); font-size: 12px; }
.pay-bar-sum strong { color: var(--blue); font-size: 22px; font-weight: 800; }
.pay-bar .btn { min-width: 140px; height: 48px; }
