/* Ad detail — 1:1 oglas_details.png */

.detail-page {
  background: var(--canvas);
  padding: 1.35rem 0 3.25rem;
}

.detail-layout {
  max-width: var(--site-max);
  margin: 0 auto;
  padding: 0 var(--site-gutter);
  display: grid;
  gap: 1.35rem;
}

@media (min-width: 980px) {
  .detail-layout {
    grid-template-columns: minmax(0, 1.7fr) minmax(280px, 0.82fr);
    gap: 1.5rem;
    align-items: start;
  }
}

.detail-main {
  min-width: 0;
  display: grid;
  gap: 1.1rem;
}

.detail-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.25rem 1.35rem;
  box-shadow: var(--shadow-sm);
}

.detail-card > h2 {
  margin: 0 0 0.95rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid var(--border);
  font-size: 1.4rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--ink-2);
}

/* Gallery */
.gallery-main {
  border-radius: 14px;
  overflow: hidden;
  background: #eceef2;
  aspect-ratio: 16 / 10;
  position: relative;
}

.gallery-main .m-back {
  display: none;
}

.gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.5rem;
  margin-top: 0.65rem;
}

.gallery-thumbs button {
  position: relative;
  border: 2px solid transparent;
  padding: 0;
  border-radius: 10px;
  overflow: hidden;
  aspect-ratio: 16 / 11;
  background: #eceef2;
  cursor: pointer;
}

.gallery-thumbs button.on {
  border-color: var(--accent);
}

.gallery-thumbs img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.gallery-thumbs .more {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 14, 0.55);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.78rem;
  text-align: center;
  padding: 0.25rem;
}

.gallery-counter {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 2;
  padding: 0.28rem 0.55rem;
  border-radius: 8px;
  background: rgba(10, 10, 14, 0.55);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1;
  pointer-events: none;
  backdrop-filter: blur(6px);
}

.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 40px;
  height: 56px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  opacity: 0.88;
  transition: opacity 0.18s ease, transform 0.18s ease;
  padding: 0;
  box-shadow: none;
}

.gallery-main:hover .gallery-nav,
.gallery-nav:focus-visible {
  opacity: 1;
}

.gallery-nav:hover {
  background: transparent;
  opacity: 1;
  transform: translateY(-50%) scale(1.08);
}

.gallery-nav:focus-visible {
  outline: none;
}

.gallery-nav svg {
  stroke: #fff;
  color: #fff;
  stroke-width: 1.75;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.55)) drop-shadow(0 0 8px rgba(0, 0, 0, 0.25));
}

.gallery-nav.prev {
  left: 0.2rem;
}

.gallery-nav.next {
  right: 0.2rem;
}

@media (max-width: 899px) {
  .gallery-nav {
    opacity: 0.9;
  }
}

@media (max-width: 700px) {
  .gallery-thumbs {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Title / price head */
.ad-head {
  display: grid;
  gap: 1.1rem;
}

.ad-head-top {
  display: flex;
  justify-content: space-between;
  gap: 1.25rem;
  align-items: flex-start;
}

.ad-type {
  margin: 0 0 0.35rem;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--muted);
}

.ad-head h1 {
  margin: 0;
  font-size: clamp(1.35rem, 2.1vw, 1.75rem);
  font-weight: 750;
  letter-spacing: -0.03em;
  line-height: 1.2;
  color: var(--ink-2);
}

.ad-meta {
  margin-top: 0.45rem;
  font-size: 0.8125rem;
  color: var(--muted);
  font-weight: 500;
}

.ad-price-block {
  text-align: right;
  flex: 0 0 auto;
}

.ad-price-block .now {
  display: block;
  font-size: clamp(1.45rem, 2.2vw, 1.85rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--ink-2);
  line-height: 1.1;
}

.ad-price-block.has-discount .now {
  color: #ef4444;
}

.ad-price-block .was {
  display: block;
  margin-top: 0.2rem;
  color: var(--muted);
  text-decoration: line-through;
  font-size: 0.95rem;
  font-weight: 500;
}

.ad-price-block .save {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: #ef4444;
}

.price-plus-reg {
  margin-top: 0.2rem;
  font-size: 0.8rem;
  font-weight: 650;
  color: var(--muted);
  letter-spacing: -0.01em;
}

.ad-social-proof {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-top: -0.25rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  background: #f3f4f6;
  color: #4b5563;
  font-size: 0.78rem;
  font-weight: 600;
  width: fit-content;
}

.ad-social-proof[hidden] {
  display: none !important;
}

.ad-social-proof svg {
  flex-shrink: 0;
  color: #6b7280;
}

.ad-social-proof strong {
  font-weight: 800;
  color: var(--ink-2);
}

.ad-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
  flex-shrink: 0;
  animation: ad-live-pulse 1.6s ease-in-out infinite;
}

@keyframes ad-live-pulse {
  0%,
  100% {
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.18);
  }
  50% {
    box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.08);
  }
}

.price-fixed {
  margin-top: 0.4rem;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: #15803d;
}

.price-fixed .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #22c55e;
}

.quick-specs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.55rem;
}

@media (min-width: 560px) {
  .quick-specs {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 820px) {
  .quick-specs {
    grid-template-columns: repeat(4, 1fr);
  }
}

.quick-spec {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.75rem 0.85rem;
  border-radius: 12px;
  background: #f4f5f7;
  min-width: 0;
}

.quick-spec .qs-ico {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.quick-spec .qs-text {
  min-width: 0;
}

.quick-spec .k {
  font-size: 0.7rem;
  color: var(--muted);
  font-weight: 500;
  margin-bottom: 0.1rem;
}

.quick-spec .v {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Spec sections (Polovni-style cards) */
.detail-card.spec-block {
  padding: 0;
  overflow: hidden;
}

.detail-card.spec-block > h2 {
  margin: 0;
  padding: 0.8rem 1.2rem;
  background: #f4f5f7;
  border-bottom: 1px solid var(--border);
  font-size: 1.05rem;
  font-weight: 750;
  letter-spacing: -0.02em;
}

.detail-card.spec-block .spec-body {
  padding: 0.55rem 1.15rem 1rem;
}

.tech-grid {
  column-count: 1;
  column-gap: 2rem;
}

@media (min-width: 640px) {
  .tech-grid {
    column-count: 2;
  }
}

.tech-cell {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: baseline;
  padding: 0.38rem 0;
  border-bottom: 1px solid #eef0f3;
  line-height: 1.25;
  break-inside: avoid;
}

.tech-cell .k {
  font-size: 0.8125rem;
  color: var(--muted-2);
  font-weight: 500;
}

.tech-cell .v {
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--ink-2);
  text-align: right;
}

.spec-checks {
  column-count: 1;
  column-gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

@media (min-width: 640px) {
  .spec-checks {
    column-count: 2;
  }
}

.spec-checks li {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.84rem;
  font-weight: 550;
  color: var(--ink-2);
  line-height: 1.35;
  padding: 0.22rem 0;
  break-inside: avoid;
}

.spec-check {
  color: var(--primary, #553fae);
  flex: 0 0 auto;
  margin-top: 0.08rem;
  display: grid;
  place-items: center;
}

/* Equipment tags */
.equip-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.equip-tag {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.8rem;
  border-radius: 10px;
  background: #f3f4f6;
  color: #374151;
  font-size: 0.8125rem;
  font-weight: 550;
  line-height: 1.2;
}

/* Description */
.ad-desc {
  color: var(--text-2);
  line-height: 1.65;
  white-space: pre-wrap;
  font-size: 0.95rem;
  margin: 0;
}

.ad-desc.clamped {
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.more-link {
  margin-top: 0.7rem;
  color: var(--accent);
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
}

/* Location */
.loc-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: stretch;
}

@media (min-width: 560px) {
  .loc-row {
    grid-template-columns: minmax(160px, 220px) 1fr;
    gap: 1.25rem;
  }
}

.loc-map {
  height: 150px;
  border-radius: 12px;
  overflow: hidden;
  background: #e9eaee;
}

.loc-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  padding-top: 0.15rem;
}

.loc-city {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink-2);
}

.loc-region {
  margin-top: 0.2rem;
  font-size: 0.875rem;
  color: var(--muted);
  font-weight: 500;
}

.loc-note {
  margin-top: 0.85rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8125rem;
  color: var(--muted);
  font-weight: 500;
}

.loc-note .ico {
  color: var(--muted);
  flex: 0 0 auto;
}

.side-stack .loc-row {
  grid-template-columns: 1fr;
  gap: 0.85rem;
}

.side-stack .loc-map {
  height: 140px;
}

.side-stack .detail-loc > h2 {
  font-size: 1.05rem;
  margin-bottom: 0.75rem;
  padding-bottom: 0.65rem;
}

/* Sidebar */
.side-stack {
  display: grid;
  gap: 1rem;
}

@media (min-width: 980px) {
  .side-stack {
    position: sticky;
    top: 88px;
  }
}

.side-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.2rem 1.25rem;
  box-shadow: var(--shadow-sm);
}

.side-card > h3 {
  margin: 0 0 0.95rem;
  font-size: 1.4rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--ink-2);
}

.seller-top {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.05rem;
}

.seller-top .av {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #111;
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  overflow: hidden;
}

.seller-top .av img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.seller-top .name {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--ink-2);
}

.seller-top .role {
  margin-top: 0.15rem;
  font-size: 0.78rem;
  color: var(--muted);
  font-weight: 500;
}

.seller-top .profile-link {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  margin-top: 0.35rem;
  padding: 0.35rem 0;
  color: var(--accent);
  font-weight: 650;
  font-size: 0.8125rem;
  text-decoration: none;
  position: relative;
  z-index: 3;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.seller-top .profile-link:hover {
  text-decoration: underline;
}

.seller-top .profile-link:active {
  opacity: 0.85;
}

.seller-info {
  min-width: 0;
}

.side-actions {
  display: grid;
  gap: 0.55rem;
}

.side-actions .btn-primary,
.side-actions .btn-outline {
  width: 100%;
  height: 46px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}

.side-actions .btn-primary,
.side-actions #btn-msg {
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.side-actions .btn-primary {
  background: var(--accent);
  color: #fff;
}

.side-actions .btn-primary:hover {
  background: var(--accent-strong);
}

.side-actions .btn-outline {
  background: #fff;
  border: 1.5px solid var(--border-strong);
  color: var(--ink-2);
}

.side-actions .btn-outline:hover {
  border-color: #c4c7d0;
  background: #fafafa;
}

.side-actions .btn-outline.on {
  color: var(--danger);
  border-color: #fecaca;
  background: #fef2f2;
}

.ad-tools {
  padding: 0.65rem 0.55rem 0.6rem;
}

.ad-tools .ad-share {
  margin-top: 0;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.28rem;
  align-items: stretch;
}

.ad-tools .ad-share-btn {
  min-height: 0;
  padding: 0.1rem 0;
  border: 0;
  background: transparent;
  gap: 0;
  justify-content: center;
}

.ad-tools .ad-share-btn:hover {
  background: transparent;
  border-color: transparent;
}

.ad-tools .ad-share-btn > span:not(.ad-share-ico) {
  display: none;
}

.ad-tools .ad-tool-report {
  grid-column: 1 / -1;
  display: none;
}

.ad-tools .ad-share-ico {
  width: min(54px, 100%);
  height: auto;
  min-height: 0;
  flex: 0 0 auto;
  aspect-ratio: 1;
  border-radius: 14px;
  overflow: hidden;
}

.ad-tools .ad-share-ico img {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

.ad-tools .ad-share-btn.is-viber .ad-share-ico,
.ad-tools .ad-share-btn.is-wa .ad-share-ico,
.ad-tools .ad-share-btn.is-fb .ad-share-ico {
  background: transparent;
}

.ad-tools .ad-tool-cmp .ad-share-ico {
  background: #ece6fd;
  border-radius: 14px;
  overflow: hidden;
}

.ad-tools .ad-tool-save .ad-share-ico {
  background: var(--dark);
  color: #fff;
}

.ad-tools .ad-tool-save svg {
  fill: #fff;
  stroke: #fff;
}

.ad-tools .ad-tool-save:hover .ad-share-ico {
  filter: brightness(1.12);
}

.ad-tools .ad-tool-save.on .ad-share-ico {
  background: var(--dark);
  color: var(--primary);
}

.ad-tools .ad-tool-save.on svg {
  fill: var(--primary);
  stroke: var(--primary);
}

.ad-contract-dl {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  margin-top: 0.55rem;
  padding: 0.72rem 0.85rem;
  border: 1.5px solid var(--primary);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  font-size: 0.78rem;
  font-weight: 750;
  letter-spacing: 0.01em;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  box-sizing: border-box;
}

.ad-contract-dl:hover {
  background: #f6f3ff;
  color: var(--ink);
}

.ad-contract-dl-ico {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  color: var(--primary);
}

.fav-heart-wrap {
  position: relative;
  display: inline-grid;
  place-items: center;
}

.fav-heart-wrap .fav-count,
.m-cta-fav .fav-count {
  position: absolute;
  left: 50%;
  top: 50%;
  inset: auto;
  z-index: 1;
  display: grid;
  place-items: center;
  min-width: 1.15em;
  height: 1.15em;
  padding: 0 0.18em;
  border-radius: 999px;
  background: #fff;
  color: #111827;
  font-size: 0.7rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.03em;
  box-shadow: 0 0 0 1.5px rgba(17, 24, 39, 0.2);
  pointer-events: none;
  transform: translate(-50%, -46%);
}

.fav-heart-wrap .fav-count[hidden],
.m-cta-fav .fav-count[hidden] {
  display: none !important;
}

.ad-tools .ad-tool-save.on .fav-count {
  background: #fff;
  color: #dc2626;
  text-shadow: none;
}

.m-cta-fav {
  position: relative;
}

.m-cta-fav .fav-count {
  min-width: 1.25em;
  height: 1.25em;
  font-size: 0.78rem;
  color: #111827;
  background: #fff;
  text-shadow: none;
}

.m-cta-fav.on .fav-count {
  color: #111827;
  background: #fff;
  text-shadow: none;
}

.ad-share {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.3rem;
  margin-top: 0.55rem;
}

.ad-share-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 0.28rem;
  padding: 0.35rem 0.1rem 0.3rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: #fff;
  color: var(--ink-2);
  font: inherit;
  font-size: 0.68rem;
  font-weight: 650;
  line-height: 1.15;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

a.ad-share-btn {
  color: inherit;
}

.ad-share-btn:hover {
  background: #fafafa;
  border-color: var(--border-strong);
}

.ad-share-ico {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  color: #fff;
  flex: 0 0 auto;
  overflow: visible;
}

.ad-share-ico svg {
  display: block;
  overflow: visible;
}

.ad-share-btn.is-viber .ad-share-ico,
.ad-share-btn.is-wa .ad-share-ico,
.ad-share-btn.is-fb .ad-share-ico {
  background: transparent;
  overflow: hidden;
  padding: 0;
}

.ad-share-btn.is-viber .ad-share-ico img,
.ad-share-btn.is-wa .ad-share-ico img,
.ad-share-btn.is-fb .ad-share-ico img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ad-share-btn.is-sys .ad-share-ico {
  background: var(--primary);
}

/* Sticky header on scroll */
.ad-sticky {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: calc(var(--z-header) + 8);
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transform: translateY(-110%);
  transition: transform 0.22s var(--ease);
  padding-top: var(--safe-t, 0px);
  pointer-events: none;
}

.ad-sticky.is-on {
  transform: none;
  pointer-events: auto;
}

.ad-sticky-inner {
  max-width: var(--site-max);
  margin: 0 auto;
  padding: 0.4rem var(--site-gutter);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 56px;
}

.ad-sticky-logo {
  flex: 0 0 auto;
  display: none;
  line-height: 0;
}

.ad-sticky-logo img {
  height: 26px;
  width: auto;
  display: block;
}

.ad-sticky-info {
  min-width: 0;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 0.08rem;
}

.ad-sticky-info strong {
  display: block;
  font-size: 0.9rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--ink-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ad-sticky-info span {
  display: block;
  margin: 0;
  font-size: 0.74rem;
  font-weight: 600;
  line-height: 1.25;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ad-sticky-price {
  flex: 0 0 auto;
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.15;
  color: var(--ink-2);
  white-space: nowrap;
}

.ad-sticky-actions {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  flex: 0 0 auto;
  min-width: 0;
}

.ad-sticky .ad-share {
  margin: 0;
  display: flex;
  gap: 0.25rem;
  grid-template-columns: none;
}

.ad-sticky .ad-share-btn {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 9px;
  justify-content: center;
}

.ad-sticky .ad-share-btn > span:last-child {
  display: none;
}

.ad-sticky .ad-share-ico {
  width: 100%;
  height: 100%;
  border-radius: 9px;
}

.ad-sticky-report {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  height: 34px;
  padding: 0 0.65rem;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink-2);
  font: inherit;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.ad-sticky-report:hover {
  background: #fafafa;
  border-color: var(--border-strong);
}

@media (min-width: 980px) {
  .ad-sticky-logo {
    display: inline-flex;
  }
}

.trust-list {
  margin: 1rem 0 0;
  padding: 0.9rem 0 0;
  border-top: 1px solid var(--border);
  list-style: none;
  display: grid;
  gap: 0.55rem;
}

.trust-list li {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 0.78rem;
  color: var(--text-2);
  font-weight: 500;
}

.trust-list .ico {
  color: var(--accent);
  flex: 0 0 auto;
}

/* Safety tips */
.tips-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tips-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid #eef0f3;
  font-size: 0.85rem;
  line-height: 1.4;
  color: var(--ink-2);
  font-weight: 500;
}

.tips-list li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.tips-list li:first-child {
  padding-top: 0;
}

.tips-list .tip-check {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #ecfdf5;
  color: #16a34a;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  margin-top: 0.1rem;
}

/* Related ads at bottom of detail page */
.ad-more {
  max-width: var(--site-max);
  margin: 1.5rem auto 0;
  padding: 0 var(--site-gutter);
  display: grid;
  gap: 1.75rem;
}

.ad-more-section[hidden] {
  display: none;
}

.ad-more-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.9rem;
}

.ad-more-head h2 {
  margin: 0;
  font-size: 1.2rem;
  font-weight: 750;
  letter-spacing: -0.03em;
  color: var(--ink-2);
}

.ad-more-head a {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--primary, #553fae);
  text-decoration: none;
  white-space: nowrap;
}

.ad-more-head a:hover {
  text-decoration: underline;
}

.ad-more-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.ad-more-grid .ad-card.v2 .media {
  aspect-ratio: 4 / 3;
  height: auto;
  min-height: 0;
}

@media (max-width: 979px) {
  .ad-more-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
  }
}

/* Mobile sticky CTA — base; mobile.css extends on ≤899px */
.detail-page .mobile-cta {
  display: none;
}

@media (max-width: 899px) {
  .detail-page .mobile-cta {
    position: fixed;
    left: var(--dock-pad);
    right: var(--dock-pad);
    bottom: calc(var(--dock-pad) + var(--safe-b));
    z-index: var(--z-cta);
    display: grid;
    background: #fff;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    border: 1px solid var(--border);
  }
}

@media (min-width: 900px) {
  .detail-page .mobile-cta {
    display: none !important;
  }
}

.gallery-main.clickable {
  cursor: zoom-in;
}

/* Inquiry sheet (existing) */
.sheet-backdrop {
  position: fixed;
  inset: 0;
  z-index: var(--z-sheet);
  background: rgba(18, 18, 22, 0.45);
  display: grid;
  place-items: end center;
  padding: 0;
}

.sheet:not(.sheet-car-adv) {
  width: min(520px, 100%);
  background: #fff;
  border-radius: 18px 18px 0 0;
  padding: 1.1rem 1.15rem calc(1.15rem + var(--safe-b));
  box-shadow: var(--shadow-lg);
}

.sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.sheet-head h3 {
  margin: 0;
  font-size: 1.05rem;
}

.sheet-foot {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 1rem;
}

.icon-round {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #fff;
  display: grid;
  place-items: center;
  color: #6b7280;
  cursor: pointer;
}

@media (min-width: 700px) {
  .sheet-backdrop:not(.adv-backdrop):not(:has(.sheet-car-adv)) {
    place-items: center;
    padding: 1rem;
  }
  .sheet:not(.sheet-car-adv) {
    border-radius: 16px;
    padding-bottom: 1.15rem;
  }
}

#ad-report-sheet .ad-report {
  max-width: 440px;
  padding: 0.85rem 1rem calc(1rem + var(--safe-b));
}

#ad-report-sheet .sheet-head {
  align-items: flex-start;
  gap: 0.6rem;
  margin-bottom: 0.85rem;
}

#ad-report-sheet .ad-report-heading {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  min-width: 0;
}

#ad-report-sheet .ad-report-flag {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--dark);
  color: #fff;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
}

#ad-report-sheet .ad-report-heading h3 {
  margin: 0;
  font-size: 1rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

#ad-report-sheet .ad-report-heading p {
  margin: 0.18rem 0 0;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.3;
}

#ad-report-sheet .ad-report-reasons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.4rem;
  margin: 0 0 0.85rem;
}

#ad-report-sheet .ad-report-reason {
  min-height: 40px;
  padding: 0.45rem 0.6rem;
  border-radius: 11px;
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink-2);
  font: inherit;
  font-size: 0.8rem;
  font-weight: 650;
  line-height: 1.2;
  text-align: left;
  cursor: pointer;
}

#ad-report-sheet .ad-report-reason:hover {
  border-color: var(--border-strong);
  background: #fafafa;
}

#ad-report-sheet .ad-report-reason.is-on {
  border-color: var(--primary);
  background: var(--primary-soft, #f0ecfa);
  color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

#ad-report-sheet .ad-report-note {
  display: grid;
  gap: 0.35rem;
}

#ad-report-sheet .ad-report-note span {
  font-size: 0.75rem;
  font-weight: 650;
  color: var(--ink-2);
}

#ad-report-sheet .ad-report-note em {
  font-style: normal;
  font-weight: 600;
  color: var(--muted);
}

#ad-report-sheet .ad-report-note textarea {
  width: 100%;
  min-height: 72px;
  resize: vertical;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.65rem 0.75rem;
  font: inherit;
  font-size: 16px;
  line-height: 1.4;
  color: var(--ink-2);
  background: #fff;
}

#ad-report-sheet .ad-report-note textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.18);
}

#ad-report-sheet .sheet-foot {
  margin-top: 0.85rem;
}

#ad-report-sheet .sheet-foot .btn {
  min-height: 44px;
  font-size: 0.88rem;
}

/* ——— Lightbox gallery ——— */
body.lb-open {
  overflow: hidden;
  touch-action: none;
}

.lb-overlay {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100%;
  height: 100dvh;
  z-index: var(--z-lightbox);
  background: rgba(8, 8, 12, 0.94);
  display: block;
  opacity: 0;
  transition: opacity 0.18s ease;
  user-select: none;
  -webkit-user-select: none;
  overflow: hidden;
}

.lb-overlay.on {
  opacity: 1;
}

.lb-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem 1rem;
  padding-top: calc(0.85rem + env(safe-area-inset-top, 0px));
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.55), transparent);
  pointer-events: none;
}

.lb-top .lb-actions,
.lb-top .lb-counter {
  pointer-events: auto;
}

.lb-counter {
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}

.lb-actions {
  display: flex;
  gap: 0.4rem;
}

.lb-btn {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  display: grid;
  place-items: center;
  backdrop-filter: blur(8px);
  cursor: pointer;
}

.lb-btn:hover {
  background: rgba(255, 255, 255, 0.22);
}

.lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.lb-nav:hover {
  background: rgba(255, 255, 255, 0.22);
}

.lb-prev {
  left: 0.75rem;
}

.lb-next {
  right: 0.75rem;
}

.lb-stage {
  position: absolute;
  inset: 0;
  overflow: hidden;
  touch-action: none;
  cursor: grab;
  padding: 0;
}

.lb-stage.zoomed {
  cursor: grab;
}

.lb-stage:active {
  cursor: grabbing;
}

.lb-track {
  display: flex;
  height: 100%;
  width: 300%;
  will-change: transform;
  touch-action: none;
}

.lb-slide {
  flex: 0 0 33.333%;
  width: 33.333%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4.75rem 0.65rem 5.75rem;
  box-sizing: border-box;
}

.lb-img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transform-origin: center center;
  will-change: transform;
  pointer-events: none;
  border-radius: 4px;
  margin: 0;
  flex: 0 0 auto;
  background: rgba(255, 255, 255, 0.03);
}

.lb-film {
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(2.15rem + env(safe-area-inset-bottom, 0px));
  z-index: 3;
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  padding: 0 1rem;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  pointer-events: auto;
}

.lb-film::-webkit-scrollbar {
  display: none;
}

.lb-thumb {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
  opacity: 0.55;
}

.lb-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.lb-thumb.is-on {
  opacity: 1;
  border-color: #fff;
}

.lb-hint {
  position: absolute;
  bottom: calc(0.55rem + env(safe-area-inset-bottom, 0px));
  left: 0;
  right: 0;
  text-align: center;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.8rem;
  font-weight: 500;
  pointer-events: none;
  z-index: 2;
}

@media (max-width: 900px) {
  .lb-slide {
    padding: 4.4rem 0.4rem 6.4rem;
  }

  .lb-nav {
    width: 44px;
    height: 72px;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.28);
    opacity: 0.92;
  }

  .lb-prev {
    left: 0.2rem;
  }

  .lb-next {
    right: 0.2rem;
  }

  .lb-film {
    bottom: calc(2.05rem + env(safe-area-inset-bottom, 0px));
    justify-content: flex-start;
  }

  .lb-hint {
    font-size: 0.72rem;
  }
}

.gallery-main.clickable {
  cursor: zoom-in;
}

/* —— AI chat (ad detail) —— */
body.ai-chat-open {
  overflow: hidden;
  touch-action: none;
}

#ai-chat-root {
  position: fixed;
  inset: 0;
  z-index: var(--z-sheet, 300);
  pointer-events: none;
}

#ai-chat-root > * {
  pointer-events: auto;
}

.ai-chat-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(18, 18, 22, 0.42);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity 0.22s ease;
}

#ai-chat-root.is-open .ai-chat-backdrop {
  opacity: 1;
}

.ai-chat-fab {
  position: absolute;
  right: max(1rem, env(safe-area-inset-right, 0px));
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  border: 0;
  cursor: pointer;
  padding: 0.72rem 1.05rem 0.72rem 0.78rem;
  border-radius: 999px;
  background: var(--primary, #553fae);
  color: #fff;
  font: inherit;
  font-weight: 650;
  font-size: 0.92rem;
  box-shadow: 0 12px 28px rgba(85, 63, 174, 0.32);
  transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.ai-chat-fab:hover {
  background: var(--primary-hover, #4a36a0);
  transform: translateY(-1px);
}

.ai-chat-fab:active {
  transform: scale(0.98);
}

.ai-chat-fab.is-open {
  background: #1f1d27;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.ai-chat-fab.is-disabled:not(.is-open) {
  opacity: 0.78;
}

.ai-chat-fab-ico,
.ai-chat-fab-close {
  width: 1.55rem;
  height: 1.55rem;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
}

.ai-chat-fab-close {
  display: none;
}

.ai-chat-fab.is-open .ai-chat-fab-ico,
.ai-chat-fab.is-open .ai-chat-fab-label {
  display: none;
}

.ai-chat-fab.is-open .ai-chat-fab-close {
  display: grid;
  background: transparent;
  width: auto;
  height: auto;
}

.ai-chat-fab.is-open {
  padding: 0.85rem;
  border-radius: 50%;
}

.ai-chat-panel {
  position: absolute;
  z-index: 3;
  display: flex;
  flex-direction: column;
  background: #fff;
  color: var(--ink, #1c1a24);
  overflow: hidden;
  box-shadow: 0 22px 55px rgba(18, 18, 22, 0.22);
  transform: translateY(12px) scale(0.98);
  opacity: 0;
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s ease;
}

#ai-chat-root.is-open .ai-chat-panel {
  transform: none;
  opacity: 1;
}

.ai-chat-grab {
  display: none;
  justify-content: center;
  padding: 0.55rem 0 0.15rem;
  cursor: grab;
  touch-action: none;
}

.ai-chat-grab span {
  width: 2.4rem;
  height: 0.28rem;
  border-radius: 99px;
  background: #d4d0dc;
}

.ai-chat-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border, #e8e6ef);
  background: #fff;
}

.ai-chat-head-text {
  min-width: 0;
}

.ai-chat-head strong {
  display: block;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.ai-chat-head p {
  margin: 0.15rem 0 0;
  font-size: 0.78rem;
  color: var(--muted, #6b7280);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ai-chat-icon-btn {
  width: 2.35rem;
  height: 2.35rem;
  border: 1px solid var(--border, #e8e6ef);
  border-radius: 12px;
  background: #f4f3f8;
  color: #4b5563;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}

.ai-chat-icon-btn:hover {
  background: #eceaf3;
  color: var(--ink, #1c1a24);
}

.ai-chat-msgs {
  flex: 1;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  padding: 0.9rem 0.9rem 0.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  background: #f7f6fa;
}

.ai-chat-bubble {
  max-width: 88%;
  padding: 0.7rem 0.85rem;
  border-radius: 16px;
  font-size: 0.9rem;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.ai-chat-user {
  align-self: flex-end;
  background: var(--primary, #553fae);
  color: #fff;
  border-bottom-right-radius: 6px;
}

.ai-chat-assistant {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--border, #e8e6ef);
  color: var(--ink, #1c1a24);
  border-bottom-left-radius: 6px;
}

.ai-chat-assistant.is-error {
  border-color: #f0b4b4;
  background: #fff5f5;
}

.ai-chat-dots {
  display: inline-flex;
  gap: 0.28rem;
  padding: 0.2rem 0.1rem;
}

.ai-chat-dots i {
  width: 0.38rem;
  height: 0.38rem;
  border-radius: 50%;
  background: #9b95ad;
  animation: ai-dot 1s infinite ease-in-out;
}

.ai-chat-dots i:nth-child(2) {
  animation-delay: 0.15s;
}
.ai-chat-dots i:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes ai-dot {
  0%,
  80%,
  100% {
    opacity: 0.35;
    transform: translateY(0);
  }
  40% {
    opacity: 1;
    transform: translateY(-2px);
  }
}

.ai-chat-suggest {
  display: flex;
  gap: 0.4rem;
  padding: 0.55rem 0.85rem 0.65rem;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  background: #f7f6fa;
  border-bottom: 1px solid transparent;
}

.ai-chat-suggest::-webkit-scrollbar {
  display: none;
}

.ai-chat-suggest[hidden] {
  display: none !important;
}

.ai-chat-chip {
  flex: 0 0 auto;
  border: 1px solid var(--border, #e8e6ef);
  background: #fff;
  color: var(--ink, #1c1a24);
  border-radius: 999px;
  padding: 0.42rem 0.75rem;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 550;
  cursor: pointer;
  white-space: nowrap;
}

.ai-chat-chip:active,
.ai-chat-chip:hover {
  border-color: var(--primary, #553fae);
  color: var(--primary, #553fae);
  background: var(--primary-soft, #f0ecfa);
}

.ai-chat-form {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.7rem 0.8rem calc(0.7rem + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--border, #e8e6ef);
  background: #fff;
}

.ai-chat-form input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--border, #e8e6ef);
  border-radius: 999px;
  padding: 0.72rem 0.95rem;
  font: inherit;
  font-size: 16px;
  background: #faf9fc;
  color: var(--ink, #1c1a24);
}

.ai-chat-form input:focus {
  outline: 2px solid rgba(85, 63, 174, 0.22);
  border-color: var(--primary, #553fae);
}

.ai-chat-send {
  width: 2.6rem;
  height: 2.6rem;
  border: 0;
  border-radius: 50%;
  background: var(--primary, #553fae);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
}

.ai-chat-send:hover:not(:disabled) {
  background: var(--primary-hover, #4a36a0);
}

.ai-chat-send:disabled {
  opacity: 0.4;
  cursor: default;
}

/* Desktop: compact popover above FAB */
@media (min-width: 900px) {
  .ai-chat-panel {
    right: max(1rem, env(safe-area-inset-right, 0px));
    bottom: calc(4.1rem + env(safe-area-inset-bottom, 0px));
    width: min(380px, calc(100vw - 2rem));
    height: min(520px, calc(100dvh - 7rem));
    border: 1px solid var(--border, #e8e6ef);
    border-radius: 18px;
  }

  .ai-chat-backdrop {
    background: transparent;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  body.ai-chat-open {
    overflow: auto;
    touch-action: auto;
  }

  /* FAB becomes a clear close control while panel is open */
  .ai-chat-fab.is-open {
    padding: 0.85rem;
    border-radius: 50%;
  }

  .ai-chat-fab.is-open .ai-chat-fab-label,
  .ai-chat-fab.is-open .ai-chat-fab-ico {
    display: none;
  }

  .ai-chat-fab.is-open .ai-chat-fab-close {
    display: grid;
    width: auto;
    height: auto;
    background: transparent;
  }
}

/* Mobile / tablet: bottom sheet above sticky CTA */
@media (max-width: 899px) {
  .ai-chat-fab {
    right: max(0.85rem, env(safe-area-inset-right, 0px));
    bottom: calc(5.85rem + env(safe-area-inset-bottom, 0px) + var(--dock-pad, 0px));
    padding: 0.9rem;
    border-radius: 50%;
  }

  .ai-chat-fab-label {
    display: none;
  }

  .ai-chat-fab.is-open {
    /* Hide FAB while sheet is open — close via X / backdrop / swipe */
    opacity: 0;
    pointer-events: none;
    transform: scale(0.9);
  }

  .ai-chat-grab {
    display: flex;
  }

  .ai-chat-panel {
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: min(78dvh, 640px);
    max-height: calc(100dvh - 2.5rem);
    border-radius: 20px 20px 0 0;
    border: 0;
    transform: translateY(110%);
    opacity: 1;
  }

  #ai-chat-root.is-open .ai-chat-panel {
    transform: translateY(0);
  }

  .ai-chat-form {
    padding-bottom: calc(0.75rem + env(safe-area-inset-bottom, 0px));
  }
}

/* ——— Car details v2 (frontend/Car details v2.png) ——— */
.detail-page {
  padding-top: 0;
}

.ad-toolbar {
  position: sticky;
  top: var(--header-h, 72px);
  z-index: calc(var(--z-sticky) + 2);
  background: #fff;
  border-bottom: 1px solid #ececf1;
  margin-bottom: 1.2rem;
}

.ad-toolbar-inner {
  max-width: var(--site-max);
  margin: 0 auto;
  padding: 0.65rem var(--site-gutter);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.ad-toolbar-info {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.35rem 0.7rem;
  min-width: 0;
  font-size: 0.9rem;
  color: #6b7280;
  font-weight: 500;
}

.ad-toolbar-info strong {
  color: #111827;
  font-size: 0.98rem;
  font-weight: 750;
}

.ad-toolbar-price {
  color: #111827;
  font-weight: 800;
}

.ad-toolbar-share {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex: 0 0 auto;
}

.ad-toolbar-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 0;
  display: grid;
  place-items: center;
  background: #f3f4f6;
  color: #374151;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
}

.ad-toolbar-dot img,
.ad-toolbar-dot svg {
  display: block;
}

.ad-toolbar-dot.is-wa,
.ad-toolbar-dot.is-viber,
.ad-toolbar-dot.is-fb,
.ad-toolbar-dot.is-cmp {
  background: transparent;
  overflow: hidden;
  padding: 0;
}

.ad-toolbar-dot.is-wa img,
.ad-toolbar-dot.is-viber img,
.ad-toolbar-dot.is-fb img,
.ad-toolbar-dot.is-cmp img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none;
}

.ad-toolbar-dot.is-cmp.on {
  box-shadow: 0 0 0 2px var(--accent, #553fae);
}

.ad-toolbar-report {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  height: 34px;
  padding: 0 0.75rem;
  border-radius: 8px;
  border: 1px solid #fecaca;
  background: #fff;
  color: #dc2626;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
  font-family: inherit;
}

.ad-toolbar-report:hover {
  background: #fef2f2;
}

@media (max-width: 899px) {
  .detail-page .ad-toolbar-inner {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    flex-wrap: nowrap;
    gap: 0.6rem;
  }

  .detail-page .ad-toolbar-share {
    width: 100%;
    flex: none;
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .detail-page .ad-toolbar-info strong {
    flex: 1 0 100%;
    white-space: normal;
  }

  .detail-page .ad-toolbar-report span {
    display: none;
  }
}

@media (min-width: 900px) {
  .gallery-nav {
    display: none;
  }
}

.gallery-main {
  border-radius: 12px;
  box-shadow: none;
}

.gallery-thumbs button {
  border-radius: 8px;
  aspect-ratio: 4 / 3;
}

.gallery-thumbs button.on {
  border-color: var(--accent, #6d46e8);
}

.ad-head {
  gap: 1.25rem;
}

.ad-type {
  font-size: 0.78rem;
  font-weight: 500;
  color: #9ca3af;
  letter-spacing: 0.01em;
}

.ad-head h1 {
  font-size: clamp(1.35rem, 2vw, 1.7rem);
  font-weight: 800;
}

.ad-price-block .now {
  font-weight: 800;
  color: #111827;
}

.ad-price-block.has-discount .now {
  color: #ef4444;
}

.quick-specs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  margin-top: 0.15rem;
  padding: 0.95rem 0 0.1rem;
  border: 0;
  border-top: 1px solid #ececf1;
  border-radius: 0;
  overflow: visible;
  background: transparent;
}

.quick-spec {
  display: block;
  padding: 0 1.15rem;
  border-radius: 0;
  background: transparent;
  border: 0;
  position: relative;
}

.quick-spec:first-child {
  padding-left: 0;
}

.quick-spec:last-child {
  padding-right: 0;
}

.quick-spec:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 0.28rem;
  bottom: 0.28rem;
  right: 0;
  width: 1px;
  background: #ececf1;
  pointer-events: none;
}

.quick-spec .k {
  font-size: 0.75rem;
  color: #9ca3af;
  font-weight: 500;
  margin-bottom: 0.2rem;
}

.quick-spec .v {
  font-size: 0.95rem;
  font-weight: 750;
  color: #111827;
}

.detail-card.spec-block > h2,
.side-card > h3 {
  margin: 0;
  padding: 1rem 1.2rem 0.85rem;
  background: #fff;
  border-bottom: 1px solid #ececf1;
  font-size: 1.12rem;
  font-weight: 750;
  letter-spacing: -0.02em;
  color: #111827;
}

.detail-card.spec-block .spec-body {
  padding: 0.35rem 1.2rem 1.05rem;
}

.tech-grid {
  column-count: 2;
  column-gap: 2.5rem;
}

.tech-cell .k {
  color: #9ca3af;
}

.tech-cell .v {
  color: #111827;
}

.spec-checks {
  column-count: 4;
  column-gap: 1.5rem;
}

.spec-checks li {
  display: block;
  padding: 0.28rem 0;
  font-size: 0.86rem;
  font-weight: 500;
  color: #374151;
}

.side-actions .btn-contact,
.side-actions .btn-msg {
  width: 100%;
  height: 46px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
  text-transform: none;
  letter-spacing: 0;
}

.side-actions .btn-contact {
  background: #111827;
  color: #fff;
  border: 0;
}

.side-actions .btn-contact:hover {
  background: #000;
}

.side-actions .btn-msg {
  background: #fff;
  color: #111827;
  border: 1.5px solid #e5e7eb;
}

.side-actions .btn-msg:hover {
  background: #fafafa;
}

.side-save {
  padding: 0.85rem 1rem;
}

.btn-save {
  width: 100%;
  height: 46px;
  border-radius: 10px;
  border: 1.5px solid #e5e7eb;
  background: #fff;
  color: #111827;
  font-weight: 650;
  font-size: 0.92rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  cursor: pointer;
  font-family: inherit;
}

.btn-save svg {
  color: #6b7280;
}

.btn-save .fav-heart-wrap {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
}

.btn-save .fav-count {
  color: var(--accent, #6d46e8);
  background: none;
}

.btn-save.on {
  border-color: #fecaca;
  color: #dc2626;
  background: #fef2f2;
}

.btn-save.on svg {
  fill: currentColor;
  color: #dc2626;
}

.btn-save.on .fav-count {
  color: #fff;
  background: none;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.45);
}
  text-shadow: none;
}

.side-share {
  padding: 0 0 1rem;
}

.side-share > h3 {
  padding: 1rem 1.15rem 0.75rem;
}

.ad-share-row {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.35rem;
  padding: 0 0.75rem;
}

.ad-share-dot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  background: none;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  color: #6b7280;
  font-size: 0.72rem;
  font-weight: 600;
  font-family: inherit;
  padding: 0.15rem;
}

.ad-share-dot-ico {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: #e5e7eb;
  color: #374151;
}

.ad-share-dot-ico img,
.ad-share-dot-ico svg {
  display: block;
}

.ad-share-dot.is-viber .ad-share-dot-ico,
.ad-share-dot.is-wa .ad-share-dot-ico,
.ad-share-dot.is-fb .ad-share-dot-ico,
.ad-share-dot.is-cmp .ad-share-dot-ico {
  background: transparent;
  overflow: hidden;
  padding: 0;
}

.ad-share-dot.is-viber .ad-share-dot-ico img,
.ad-share-dot.is-wa .ad-share-dot-ico img,
.ad-share-dot.is-fb .ad-share-dot-ico img,
.ad-share-dot.is-cmp .ad-share-dot-ico img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: none;
}

.ad-share-dot.is-cmp.on .ad-share-dot-ico {
  box-shadow: 0 0 0 2px var(--accent, #553fae);
}

.side-stack .detail-loc {
  padding: 0;
  overflow: hidden;
}

.side-stack .detail-loc > h2 {
  display: none;
}

.side-stack .loc-map {
  height: 160px;
  border-radius: 12px 12px 0 0;
}

.side-stack .loc-info {
  padding: 0.9rem 1.05rem 1rem;
}

.side-stack .loc-row {
  display: block;
}

.side-tips {
  padding: 0 1.05rem 0.85rem;
}

.side-tips > h3 {
  padding: 1rem 0 0.75rem;
  margin: 0;
  font-size: 1.05rem;
}

.side-stack {
  top: calc(var(--header-h, 72px) + 56px);
}

.ad-more {
  margin-top: 2.25rem;
}

.rel-card {
  display: block;
  background: #fff;
  border: 1px solid #ececf1;
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.rel-media {
  position: relative;
  aspect-ratio: 4 / 3;
  background: #eceef2;
}

.rel-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.rel-media .media-photos {
  position: absolute;
  right: 0.55rem;
  bottom: 0.55rem;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  height: 26px;
  padding: 0 0.5rem;
  border-radius: 7px;
  background: rgba(17, 24, 39, 0.72);
  color: #fff;
  font-size: 0.74rem;
  font-weight: 650;
  backdrop-filter: blur(6px);
  pointer-events: none;
}

.rel-media .media-photos svg {
  width: 14px;
  height: 14px;
  flex: 0 0 auto;
}

.rel-media .cmp-btn {
  position: absolute;
  left: 0.55rem;
  bottom: 0.55rem;
  top: auto;
  right: auto;
  z-index: 2;
  display: block;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  box-shadow: 0 4px 12px rgba(17, 24, 39, 0.18);
  cursor: pointer;
  padding: 0;
  overflow: hidden;
  line-height: 0;
}

.rel-media .cmp-btn:hover,
.rel-media .cmp-btn:focus-visible {
  outline: none;
}

@media (hover: hover) and (pointer: fine) {
  .rel-media .cmp-btn:hover,
  .rel-media .cmp-btn:focus-visible {
    transform: scale(1.06);
  }
}

.rel-media .cmp-btn.on {
  box-shadow: 0 0 0 2px var(--accent, #553fae), 0 4px 12px rgba(17, 24, 39, 0.18);
}

.rel-media .cmp-btn .cmp-ico {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  pointer-events: none;
  border-radius: 50%;
  transform: scale(1.08);
}

.rel-media .badges {
  position: absolute;
  top: 0.55rem;
  left: 0.55rem;
  display: flex;
  gap: 0.3rem;
  z-index: 1;
}

.rel-media .pill {
  padding: 0.18rem 0.45rem;
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 750;
  color: #fff;
}

.rel-media .pill.blue {
  background: var(--accent, #6d46e8);
}

.rel-media .pill.red {
  background: #ef4444;
}

.rel-media .fav {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 8px;
  background: var(--accent, #6d46e8);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  z-index: 2;
  padding: 0;
}

.rel-media .fav svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.rel-media .fav.on svg {
  fill: currentColor;
}

.rel-body {
  padding: 0.7rem 0.75rem 0.85rem;
}

.rel-kicker {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.4rem;
  font-size: 0.72rem;
  color: #9ca3af;
  font-weight: 500;
}

.rel-title {
  margin-top: 0;
  font-size: 0.92rem;
  font-weight: 750;
  color: #111827;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rel-price {
  margin-top: 0.2rem;
  font-size: 1.05rem;
  font-weight: 800;
  color: #111827;
}

.rel-price.has-discount strong {
  color: #ef4444;
}

.rel-price s {
  margin-left: 0.35rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: #9ca3af;
}

.rel-specs {
  margin-top: 0.28rem;
  font-size: 0.75rem;
  color: #9ca3af;
  font-weight: 500;
}

@media (max-width: 819px) {
  .quick-specs {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .quick-spec:nth-child(even)::after {
    display: none;
  }

  .quick-spec:nth-child(odd) {
    border-bottom: 0;
  }

  .quick-spec:nth-child(-n + 2) {
    padding-bottom: 0.75rem;
  }

  .quick-spec:nth-child(n + 3) {
    padding-top: 0.75rem;
  }

  .quick-spec:nth-child(2) {
    border-right: 0;
  }

  .tech-grid,
  .spec-checks {
    column-count: 1;
  }
}

@media (min-width: 820px) and (max-width: 1099px) {
  .spec-checks {
    column-count: 2;
  }
}
