
:root {
  --bg:#071522;
  --surface:#102538;
  --line:#29465c;
  --blue:#40a9ef;
  --muted:#a6bbca;
  --white:#f5f9fd}
* {
  box-sizing:border-box}
html {
  scroll-behavior:smooth}
body {
  margin:0;
  background:var(--bg);
  color:var(--white);
  font-family:Arial,Helvetica,sans-serif}
a {
  color:inherit;
  text-decoration:none}
button,input,select {
  font:inherit}
.wrap {
  width:min(1250px,calc(100% - 36px));
  margin:auto}
header {
  position:sticky;
  top:0;
  z-index:20;
  background:#071522f2;
  border-bottom:1px solid var(--line);
  backdrop-filter:blur(14px)}
.nav {
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:17px 0}
.brand {
  font-size:21px;
  font-weight:900;
  letter-spacing:.03em}
.brand small {
  display:block;
  font-size:10px;
  letter-spacing:.19em;
  color:#7bcaff;
  margin-top:4px}
.navlinks {
  display:flex;
  align-items:center;
  gap:18px;
  font-size:14px}
.btn {
  background:var(--blue);
  color:#061b2c;
  border:1px solid var(--blue);
  padding:13px 17px;
  border-radius:9px;
  font-weight:800;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
  text-align:center;
  gap:6px}
.btn:hover {
  background:#79c9ff}
.btn.secondary {
  background:transparent;
  color:white;
  border-color:#55758b}
.hero {
  padding:75px 0 65px;
  background:radial-gradient(ellipse at 80% 10%,#135381 0,transparent 48%),linear-gradient(140deg,#091522,#10293c)}
.eyebrow {
  color:#77caff;
  letter-spacing:.16em;
  text-transform:uppercase;
  font-size:12px;
  font-weight:800}
.hero h1 {
  font-size:clamp(37px,6vw,75px);
  letter-spacing:-.045em;
  line-height:1.05;
  margin:16px 0}
.hero h1 span {
  color:#64c0ff}
.lead {
  color:#c2d2df;
  font-size:19px;
  line-height:1.6;
  max-width:750px}
.hero-actions {
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin:27px 0}
.stats {
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin-top:35px}
.stat {
  background:#ffffff0b;
  border:1px solid #406078;
  border-radius:10px;
  padding:15px 23px}
.stat b {
  display:block;
  font-size:26px}
.stat span {
  color:#c0d0dc;
  font-size:13px}
.section {
  padding:62px 0}
.section h2 {
  font-size:clamp(27px,3.5vw,42px);
  margin:10px 0 15px}
.sub {
  color:var(--muted);
  line-height:1.65}
.toolbar {
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin:25px 0}
.toolbar input,.toolbar select,input[type=number] {
  background:#10283a;
  color:white;
  border:1px solid #446177;
  border-radius:9px;
  padding:13px 15px;
  min-width:190px}
.toolbar input {
  flex:1}
.grid {
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:20px}
.card {
  border:1px solid var(--line);
  background:var(--surface);
  border-radius:15px;
  overflow:hidden;
  display:flex;
  flex-direction:column}
.cover {
  height:225px;
  background:linear-gradient(145deg,#1a3a51,#0c1c2b);
  display:flex;
  align-items:center;
  justify-content:center;
  position:relative;
  overflow:hidden}
.cover img {
  width:100%;
  height:100%;
  object-fit:cover}
.placeholder {
  color:#9cb6c9;
  text-align:center;
  padding:20px;
  font-size:14px}
.tag {
  position:absolute;
  top:12px;
  left:12px;
  background:#d2a84b;
  color:#12202a;
  padding:7px 10px;
  border-radius:6px;
  font-size:12px;
  font-weight:800}
.card-body {
  padding:20px;
  display:flex;
  flex-direction:column;
  flex:1}
.card h3 {
  font-size:21px;
  margin:0 0 9px}
.meta {
  color:var(--muted);
  font-size:14px;
  line-height:1.55}
.price {
  font-size:28px;
  font-weight:900;
  margin:16px 0 6px}
.card .desc {
  font-size:13px;
  color:#bdcdda;
  line-height:1.55;
  min-height:40px}
.card-actions {
  display:flex;
  gap:9px;
  margin-top:auto;
  padding-top:18px}
.card-actions .btn {
  flex:1;
  font-size:13px;
  padding:11px 8px}
.panel {
  background:#102538;
  border:1px solid var(--line);
  border-radius:16px;
  padding:25px}
.calc {
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:24px}
.field {
  margin-bottom:23px}
.field label {
  display:flex;
  justify-content:space-between;
  gap:10px;
  margin-bottom:11px;
  font-weight:700}
.field output {
  color:#8dd2ff}
.field input[type=range] {
  width:100%;
  accent-color:var(--blue)}
.result {
  background:#0a3a5d;
  border-radius:13px;
  padding:23px}
.result strong {
  font-size:38px;
  display:block;
  margin:10px 0 20px}
.result-line {
  border-top:1px solid #47708d;
  display:flex;
  justify-content:space-between;
  padding:14px 0;
  gap:10px}
.fine {
  font-size:12px;
  color:#a9c1d2;
  line-height:1.6}
.detail {
  display:grid;
  grid-template-columns:minmax(0,1.3fr) minmax(300px,.7fr);
  gap:28px;
  align-items:start}
.mainphoto {
  aspect-ratio:4/3;
  background:#112c41;
  border:1px solid var(--line);
  border-radius:14px;
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center}
.mainphoto img {
  width:100%;
  height:100%;
  object-fit:contain;
  cursor:zoom-in}
.thumbs {
  display:flex;
  gap:9px;
  overflow-x:auto;
  margin-top:12px;
  padding-bottom:8px}
.thumbs button {
  border:2px solid transparent;
  border-radius:8px;
  padding:0;
  flex:0 0 86px;
  width:86px;
  height:65px;
  overflow:hidden;
  background:#19364b;
  cursor:pointer}
.thumbs button.active {
  border-color:var(--blue)}
.thumbs img {
  width:100%;
  height:100%;
  object-fit:cover}
.detail h1 {
  font-size:clamp(28px,4vw,44px);
  margin:8px 0}
.detail .price {
  font-size:38px}
.detail .btn {
  width:100%;
  margin:5px 0}
.spec {
  display:flex;
  justify-content:space-between;
  border-bottom:1px solid var(--line);
  padding:13px 0;
  gap:20px}
.spec span:first-child {
  color:var(--muted)}
.lightbox {
  position:fixed;
  inset:0;
  background:#02070cf5;
  z-index:50;
  display:none;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  padding:55px 20px 20px}
.lightbox.open {
  display:flex}
.lightbox img {
  max-width:100%;
  max-height:calc(100vh - 130px);
  object-fit:contain}
.lightbox-controls {
  display:flex;
  gap:12px;
  align-items:center;
  justify-content:center;
  margin-top:14px}
.lightbox button,.lightbox a {
  border:1px solid #7594ab;
  background:#142e43;
  color:white;
  padding:10px 14px;
  border-radius:8px;
  cursor:pointer}
.lightbox .close {
  position:absolute;
  right:20px;
  top:15px}
.notice {
  border-left:3px solid var(--blue);
  padding:13px 16px;
  background:#11314a;
  color:#c6d7e4;
  line-height:1.6}
.footer {
  padding:30px 0;
  border-top:1px solid var(--line);
  color:var(--muted);
  font-size:13px}
.footer .wrap {
  display:flex;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:15px}
@media(max-width:1000px) {
  .grid {
  grid-template-columns:repeat(2,minmax(0,1fr))}
.detail {
  grid-template-columns:1fr}
}
@media(max-width:640px) {
  .grid,.calc {
  grid-template-columns:1fr}
.navlinks a:not(.btn) {
  display:none}
.hero {
  padding:55px 0}
.cover {
  height:240px}
.panel {
  padding:17px}
.card-actions {
  flex-wrap:wrap}
.detail .price {
  font-size:31px}
}



/* Карточка: прежняя общая высота, увеличенная область фотографии. */
.card {
  height: 485px;
}
.card .cover {
  height: 310px;
  flex: 0 0 310px;
}
.card-body {
  min-height: 0;
  padding: 10px 14px 12px;
  overflow: hidden;
}
.card h3 {
  font-size: 17px;
  line-height: 1.15;
  margin-bottom: 4px;
}
.card .meta {
  font-size: 12px;
  line-height: 1.25;
}
.card .price {
  font-size: 22px;
  margin: 7px 0 2px;
}
.card .desc {
  font-size: 11px;
  line-height: 1.25;
  min-height: 0;
  margin: 2px 0;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}
.card-actions {
  padding-top: 7px;
  gap: 7px;
}
.card-actions .btn {
  font-size: 12px;
  padding: 8px 5px;
}
/* Каталог: фотография заполняет всю область без пустых боковых полей.
   При несовпадении пропорций края могут немного обрезаться.
   Оригинал целиком доступен на странице мотоцикла. */
.card .cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
@media (max-width: 640px) {
  .card { height: 485px; }
  .card .cover { height: 310px; flex-basis: 310px; }
}


/* Mobile-first gallery and overflow fixes */
html, body { max-width: 100%; overflow-x: clip; }
.wrap, .detail, .detail > *, .detail-gallery-column, .panel { min-width: 0; }
.card-image-link { display: block; min-width: 0; }
.cover, .product-gallery { touch-action: pan-y; user-select: none; }
.cover img, .product-gallery img { pointer-events: none; }
.cover { position: relative; }
.product-gallery {
  position: relative;
  aspect-ratio: 4 / 3;
  width: 100%;
  min-width: 0;
  background: #112c41;
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
.product-gallery img { width: 100%; height: 100%; object-fit: contain; }
.photo-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  border: 0;
  border-radius: 50%;
  background: #061b2ccf;
  color: white;
  width: 38px;
  height: 38px;
  font-size: 30px;
  cursor: pointer;
}
.photo-prev { left: 8px; }
.photo-next { right: 8px; }
.photo-count {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 2;
  background: #061b2cce;
  padding: 5px 10px;
  border-radius: 20px;
  color: white;
  font-size: 12px;
}
.detail { grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); }
.detail .panel, .detail-info { overflow-wrap: anywhere; }
.spec b { text-align: right; }
.lightbox { touch-action: pan-y; }
.lightbox img { max-width: 100%; max-height: min(75dvh, calc(100vh - 145px)); }
@media (max-width: 1000px) {
  .detail { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .wrap { width: calc(100% - 24px); }
  .nav { padding: 12px 0; }
  .brand { font-size: clamp(13px, 4vw, 19px); }
  .navlinks { gap: 6px; }
  .navlinks .btn { padding: 9px 10px; font-size: 12px; }
  .detail { display: flex; flex-direction: column; gap: 14px; width: 100%; }
  .detail-gallery-column, .detail-info { width: 100%; min-width: 0; }
  .detail .panel { padding: 16px; }
  .detail h1 { font-size: clamp(24px, 7vw, 34px); line-height: 1.16; }
  .detail .price { font-size: 29px; }
  .product-gallery { aspect-ratio: 4 / 3; border-radius: 10px; }
  .thumbs { max-width: 100%; overscroll-behavior-x: contain; }
  .spec { gap: 12px; font-size: 14px; }
  .lightbox { padding: 60px 8px 16px; }
  .lightbox-controls { flex-wrap: wrap; gap: 8px; }
  .lightbox .close { top: 10px; right: 10px; }
  .photo-arrow { width: 34px; height: 34px; }
}

/* Каталог: цена напротив названия, пробег на прежнем месте цены. */
.card-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}
.card-heading h3 {
  min-width: 0;
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}
.card-heading-price {
  flex: 0 0 auto;
  font-weight: 900;
  font-size: 17px;
  white-space: nowrap;
}
.card-mileage {
  font-size: 22px;
  font-weight: 900;
  margin: 7px 0 2px;
}
@media (max-width: 400px) {
  .card-heading-price { font-size: 15px; }
  .card-mileage { font-size: 19px; }
}
