/* My-Cars.Online — Carlo UI kit theme. Mobile-first, desktop-capable. */
:root {
  --purple: #6236ff;
  --purple-2: #7b5cff;
  --purple-soft: #efeaff;
  --purple-ink: #3d1fcc;
  --bg: #fafafa;
  --card: #ffffff;
  --ink: #111827;
  --muted: #6b7280;
  --line: #e8e8ee;
  --soft: #f3f4f6;
  --ok: #22c55e;
  --danger: #ef4444;
  --shadow: 0 1px 2px rgba(17, 24, 39, 0.04), 0 8px 24px rgba(17, 24, 39, 0.05);
  --shadow-lg: 0 12px 36px rgba(17, 24, 39, 0.08);
  --radius: 20px;
  --radius-sm: 14px;
  --radius-xs: 10px;
  --max: 1180px;
  --safe: env(safe-area-inset-bottom, 0px);
  --font: "Plus Jakarta Sans", Inter, "Source Sans 3", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 64px;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; }
button::-moz-focus-inner { border: 0; padding: 0; }
/* Focus / tap: kill square UA outline; ring follows control radius */
a, button, summary, input, select, textarea,
.btn, .chip, .share-btn, .icon-btn, .filter-btn, .btn-wa, .btn-viber,
.menu-item, .file-drop, .tabbar a, .cat, .sort-chips button, .car-gallery-nav,
.car-lightbox-close, .car-lightbox-nav, .line-item, .image-select-tile {
  -webkit-tap-highlight-color: transparent;
  outline: none !important;
}
.btn:focus, .btn:focus-visible,
.chip:focus, .chip:focus-visible,
.share-btn:focus, .share-btn:focus-visible,
.filter-btn:focus, .filter-btn:focus-visible,
.btn-wa:focus, .btn-wa:focus-visible,
.btn-viber:focus, .btn-viber:focus-visible,
.file-drop:focus, .file-drop:focus-visible,
.tabbar a:focus, .tabbar a:focus-visible,
.cat:focus, .cat:focus-visible,
.menu-item:focus, .menu-item:focus-visible,
.sort-chips button:focus, .sort-chips button:focus-visible {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.32);
}
.btn-primary:focus, .btn-primary:focus-visible {
  box-shadow: 0 6px 16px rgba(98, 54, 255, 0.22), 0 0 0 3px rgba(167, 139, 250, 0.55);
}
.icon-btn:focus, .icon-btn:focus-visible,
.share-btn:focus, .share-btn:focus-visible,
.car-lightbox-close:focus, .car-lightbox-close:focus-visible,
.car-lightbox-nav:focus, .car-lightbox-nav:focus-visible,
.car-gallery-nav:focus, .car-gallery-nav:focus-visible {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.4);
}
summary:focus, summary:focus-visible {
  outline: none !important;
  border-radius: 12px;
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.28);
}
input:focus, input:focus-visible,
select:focus, select:focus-visible,
textarea:focus, textarea:focus-visible {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.18);
}
textarea { resize: vertical; min-height: 110px; max-width: 100%; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}

/* —— Site chrome —— */
.site-header {
  position: sticky; top: 0; z-index: 90;
  background: rgba(255,255,255,0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.site-header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 10px 16px;
  display: flex; align-items: center; gap: 14px;
  min-height: var(--header-h);
}
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  flex-shrink: 0; min-width: 0;
}
.brand img {
  width: 40px; height: 40px; object-fit: contain; border-radius: 10px;
  background: transparent;
}
.brand img.brand-lockup {
  width: auto; height: 40px; max-width: 46vw;
  border-radius: 0; background: transparent;
}
@media (max-width: 767.98px) {
  .brand img.brand-lockup { height: 30px; max-width: 42vw; }
}
.dealer-strip {
  background: var(--card);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.dealer-strip-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 10px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.dealer-chip {
  display: inline-flex; align-items: center; gap: 10px;
  min-width: 0; color: inherit; flex: 1;
}
.dealer-chip-mark {
  width: 34px; height: 34px; border-radius: 12px; flex-shrink: 0;
  background: var(--purple-soft); color: var(--purple);
  display: inline-flex; align-items: center; justify-content: center;
}
.dealer-chip-mark svg {
  width: 18px; height: 18px; stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.dealer-chip strong {
  display: block; font-size: 14px; font-weight: 750; letter-spacing: -0.02em;
}
.dealer-chip small {
  display: block; color: var(--muted); font-size: 12px; font-weight: 600; margin-top: 1px;
}
.dealer-strip .share-btn {
  flex-shrink: 0;
  background: var(--purple-soft); color: var(--purple-ink);
}
@media (max-width: 767.98px) {
  .dealer-chip-mark { display: none; }
  .site-actions .icon-profile { display: none; }
}

.site-nav {
  display: none; align-items: center; gap: 4px; margin-left: 12px;
}
.site-nav a {
  padding: 8px 12px; border-radius: 999px;
  font-size: 13px; font-weight: 700; color: var(--muted);
}
.site-nav a:hover, .site-nav a.on { color: var(--purple); background: var(--purple-soft); }

.site-actions {
  margin-left: auto; display: flex; align-items: center; gap: 8px;
}
.site-actions .btn-search-desktop { display: none; }
.icon-btn {
  width: 40px; height: 40px; border-radius: 14px; background: var(--soft);
  display: inline-flex; align-items: center; justify-content: center; color: var(--ink);
}
.icon-btn svg, .back-link svg, .filter-btn svg, .site-nav svg, .tabbar svg, .menu-ico svg {
  width: 18px; height: 18px; stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  flex-shrink: 0;
}
.menu-toggle { display: inline-flex; }

.mobile-drawer {
  display: none; position: fixed; inset: 0; z-index: 100;
  background: rgba(15,15,20,0.42);
}
.mobile-drawer.open { display: block; }
.mobile-drawer-panel {
  margin-left: auto; width: min(320px, 88vw); height: 100%;
  background: var(--card); padding: 18px 16px; overflow: auto;
  box-shadow: var(--shadow-lg);
  animation: slideIn 0.22s var(--ease);
}
@keyframes slideIn {
  from { transform: translateX(16px); opacity: 0.6; }
  to { transform: none; opacity: 1; }
}
.drawer-links { display: grid; gap: 6px; margin-top: 12px; }
.drawer-links a {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 14px; font-weight: 700;
}
.drawer-links a:hover, .drawer-links a.on { background: var(--purple-soft); color: var(--purple-ink); }
.drawer-links .menu-ico {
  width: 36px; height: 36px; border-radius: 12px; background: var(--soft);
  display: inline-flex; align-items: center; justify-content: center; color: var(--purple);
}

.app-shell { width: 100%; min-height: calc(100vh - 100px); background: var(--bg); }
.app-main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px 22px calc(96px + var(--safe));
  min-width: 0;
  overflow-x: clip;
}

/* Mobile tab bar */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 80;
  display: grid; grid-template-columns: repeat(4, 1fr);
  padding: 6px 8px calc(8px + var(--safe));
  background: rgba(255,255,255,0.96);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.tabbar a {
  min-height: 52px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 2px;
  color: var(--muted); font-size: 10px; font-weight: 700;
  border-radius: 12px;
}
.tabbar a.on { color: var(--purple); }
.tabbar svg { width: 22px; height: 22px; }
.tabbar a.on svg[data-fill="1"] { fill: currentColor; stroke: none; }

/* Typography */
.h1 { margin: 0; font-size: clamp(22px, 5vw, 32px); font-weight: 800; letter-spacing: -0.04em; line-height: 1.15; overflow-wrap: anywhere; }
.h2 { margin: 0; font-size: clamp(18px, 3vw, 22px); font-weight: 800; letter-spacing: -0.03em; }
.h3 { margin: 0; font-size: 16px; font-weight: 700; letter-spacing: -0.02em; }
.muted { color: var(--muted); }
.section-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin: 22px 0 12px;
}
.section-head a { color: var(--purple); font-weight: 700; font-size: 13px; }

/* Hero */
.hero-banner {
  position: relative; overflow: hidden;
  border-radius: var(--radius); min-height: 168px;
  padding: 22px 20px; color: #fff;
  background: linear-gradient(135deg, #4b1fff 0%, #7b5cff 55%, #b39aff 120%);
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; justify-content: center;
}
.hero-banner::after {
  content: ""; position: absolute; right: -20px; bottom: -30px;
  width: 180px; height: 140px; border-radius: 40px;
  background: rgba(255,255,255,0.12); transform: rotate(18deg);
}
.hero-banner h1 {
  position: relative; z-index: 1; margin: 0 0 8px;
  font-size: clamp(24px, 4vw, 36px); font-weight: 800; max-width: 16ch; line-height: 1.1;
}
.hero-banner p {
  position: relative; z-index: 1; margin: 0 0 14px;
  color: rgba(255,255,255,0.88); font-size: 14px; max-width: 36ch;
}
.hero-banner .btn { position: relative; z-index: 1; align-self: flex-start; }

.cat-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px;
}
.cat {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; color: var(--ink); text-align: center;
}
.cat i {
  width: 56px; height: 56px; border-radius: 18px; background: var(--card);
  box-shadow: var(--shadow); display: inline-flex; align-items: center; justify-content: center;
  color: var(--purple); font-style: normal; font-size: 18px;
}

.search-bar {
  display: flex; align-items: center; gap: 10px;
  background: var(--card); border-radius: 18px; padding: 4px 4px 4px 14px;
  border: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(17, 24, 39, 0.04);
  margin: 8px 0 14px; min-width: 0;
}
.search-bar > svg {
  width: 20px; height: 20px; flex-shrink: 0;
  stroke: var(--muted); fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.search-bar input {
  flex: 1; border: 0; background: transparent; min-height: 44px; outline: none; min-width: 0;
}
.search-bar .filter-btn {
  width: 44px; height: 44px; border-radius: 14px; background: var(--purple); color: #fff;
  display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.search-bar .filter-btn svg {
  width: 18px; height: 18px; stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}

.car-rail {
  display: flex; gap: 14px; overflow-x: auto; padding: 2px 2px 6px;
  scroll-snap-type: x mandatory; scrollbar-width: none;
  background: transparent;
}
.car-rail::-webkit-scrollbar { display: none; }
.car-card {
  flex: 0 0 min(82%, 340px); scroll-snap-align: start;
  background: var(--card); border-radius: var(--radius); overflow: hidden;
  border: 1px solid rgba(17, 24, 39, 0.06);
  /* Carlo-like depth, kept lighter than the kit default */
  box-shadow: 0 2px 8px rgba(17, 24, 39, 0.045), 0 10px 28px rgba(40, 20, 90, 0.04);
  min-width: 0;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease), transform 0.15s var(--ease);
}
.car-card:hover {
  border-color: rgba(98, 54, 255, 0.18);
  box-shadow: 0 4px 14px rgba(17, 24, 39, 0.06), 0 14px 32px rgba(40, 20, 90, 0.07);
}
.car-card.grid { flex: none; width: 100%; }
.car-grid { display: grid; grid-template-columns: 1fr; gap: 18px; }
.car-card-media { position: relative; aspect-ratio: 16 / 10; background: var(--soft); }
.car-card-media img { width: 100%; height: 100%; object-fit: cover; }
.car-card-fav {
  position: absolute; top: 12px; right: 12px;
  width: 34px; height: 34px; border-radius: 999px; background: rgba(255,255,255,0.96);
  border: 1px solid rgba(0,0,0,0.04);
  display: inline-flex; align-items: center; justify-content: center; color: var(--muted);
}
.car-card-body { padding: 14px 16px 16px; }
.car-card-body h3 { margin: 0 0 4px; font-size: 16px; font-weight: 750; overflow-wrap: anywhere; }
.car-card-meta { margin: 0 0 12px; color: var(--muted); font-size: 12px; font-weight: 550; }
.car-card-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.car-card-price {
  margin: 0; font-size: 18px; font-weight: 800;
  font-variant-numeric: tabular-nums;
}

/* Similar cars — seamless white surface (no grey strip under cards) */
.related-block {
  margin: 8px -22px 0;
  padding: 12px 22px 8px;
  background: var(--card);
  border-top: 1px solid var(--line);
}
.related-block .section-head { margin-top: 4px; }
.related-block .car-rail {
  margin: 0 -22px;
  padding: 4px 22px 16px;
}
.related-block .car-card {
  /* one-sided soft depth (avoids square shadow halo) */
  box-shadow: 0 10px 22px -12px rgba(17, 24, 39, 0.28);
  border-color: rgba(17, 24, 39, 0.05);
}
.related-block .car-card:hover {
  box-shadow: 0 14px 26px -12px rgba(17, 24, 39, 0.34);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 18px; border-radius: 999px;
  font-weight: 750; font-size: 13px;
  transition: transform 0.15s var(--ease), background 0.15s var(--ease);
  white-space: nowrap;
}
.btn svg, .sticky-cta svg {
  width: 18px; height: 18px; flex-shrink: 0;
  stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.btn:active { transform: scale(0.98); }
.btn-primary { background: var(--purple); color: #fff; box-shadow: 0 6px 16px rgba(98, 54, 255, 0.22); }
.btn-primary:hover { background: var(--purple-ink); }
.btn-white { background: #fff; color: var(--purple-ink); }
.btn-soft { background: var(--purple-soft); color: var(--purple-ink); }
.btn-ghost { background: var(--soft); color: var(--ink); }
.btn-danger { background: #fee2e2; color: #b91c1c; }
.btn-block { width: 100%; min-height: 52px; font-size: 15px; }
.btn-row { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-row .btn { flex: 1; min-width: 120px; }

/* Search layout */
.search-layout { display: grid; gap: 16px; }
.search-filters { display: none; }
.search-filters-mobile { display: block; }

/* Detail + gallery */
.detail-layout { display: grid; gap: 0; min-width: 0; }
.detail-hero {
  position: relative; background: #1a1a22;
  border-radius: 20px; margin: 0 0 8px; min-width: 0; overflow: hidden;
}
.detail-top {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-bottom: 12px;
}
.detail-top .back-link { margin-bottom: 0; }
.share-btn {
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 0 12px; border-radius: 12px;
  background: var(--soft); color: var(--ink); font-weight: 700; font-size: 13px;
}
.share-btn svg {
  width: 16px; height: 16px; stroke: currentColor; fill: none;
  stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
}
.share-btn .share-label { display: none; }
@media (min-width: 768px) {
  .share-btn .share-label { display: inline; }
  .share-btn { padding: 0 14px; }
}
.car-gallery-stage { position: relative; }
.car-gallery-track {
  display: flex; width: 100%;
  overflow-x: auto; overflow-y: hidden;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  touch-action: pan-x pan-y;
  scrollbar-width: none;
  background: #1a1a22;
}
.car-gallery-track::-webkit-scrollbar { display: none; }
.car-gallery-slide {
  flex: 0 0 100%; width: 100%;
  height: min(72vw, 420px);
  object-fit: contain; scroll-snap-align: start;
  background: #1a1a22; cursor: zoom-in;
  user-select: none; -webkit-user-drag: none;
}
.car-gallery-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(255,255,255,0.94); color: var(--ink);
  box-shadow: 0 1px 6px rgba(0,0,0,0.18);
  display: none; align-items: center; justify-content: center;
}
.car-gallery-prev { left: 10px; }
.car-gallery-next { right: 10px; }
.car-gallery-count {
  margin: 8px 0 0; text-align: center; color: var(--muted); font-size: 13px; font-weight: 600;
}
.car-gallery-thumbs {
  display: flex; gap: 8px; overflow-x: auto; padding: 10px 12px 4px;
  -webkit-overflow-scrolling: touch; scrollbar-width: thin;
}
.car-gallery-thumbs .preview-image {
  width: 68px; height: 68px; flex: 0 0 auto; object-fit: cover;
  border-radius: 12px; cursor: pointer; border: 2px solid transparent;
}
.car-gallery-thumbs .preview-image.is-active { border-color: var(--purple); }

.detail-sheet {
  position: relative; z-index: 2;
  margin: 8px 0 0; background: var(--card);
  border-radius: 24px; padding: 24px 24px 14px;
  border: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(17, 24, 39, 0.04);
  min-width: 0;
}
.detail-handle {
  width: 42px; height: 4px; border-radius: 999px; background: #e4e4ec;
  margin: 0 auto 16px;
}
.rating {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  color: var(--muted); font-size: 13px; font-weight: 600; margin: 6px 0 14px;
}
.rating b { color: #f59e0b; }
.spec-pills {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 0 0 18px;
}
.spec-pill { background: var(--soft); border-radius: 16px; padding: 14px 16px; min-width: 0; }
.spec-pill small {
  display: block; color: var(--muted); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px;
}
.spec-pill b { font-size: 15px; font-weight: 800; overflow-wrap: anywhere; }
.about { margin: 0 0 18px; color: #3b3b4a; font-size: 14px; line-height: 1.55; overflow-wrap: anywhere; }
.sticky-cta {
  position: sticky; bottom: calc(70px + var(--safe));
  background: linear-gradient(transparent, #fff 30%);
  padding: 18px 0 8px; display: flex; gap: 10px; flex-wrap: wrap;
}
.more-block {
  margin: 8px 0 16px; background: #eef0f4; border-radius: 18px; padding: 4px 14px 14px;
  border: 1px solid #d9dbe3;
}
.more-block summary {
  list-style: none; cursor: pointer; font-weight: 800; color: var(--purple-ink);
  min-height: 48px; display: flex; align-items: center; justify-content: space-between;
}
.more-block summary::-webkit-details-marker { display: none; }
.more-block summary::after { content: "+"; color: var(--muted); font-size: 20px; }
.more-block[open] summary::after { content: "–"; }
/* Fields inside Περισσότερα: white on soft panel (must not match panel) */
.more-block input,
.more-block textarea,
.more-block .field input,
.more-block .field textarea {
  background: #ffffff !important;
  border: 1px solid #cfd2dc !important;
  color: var(--ink);
}
.more-block select,
.more-block .field select {
  background-color: #ffffff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 14px center !important;
  background-size: 16px 16px !important;
  border: 1px solid #cfd2dc !important;
  color: var(--ink);
  padding-right: 42px;
}
.more-block input:focus,
.more-block select:focus,
.more-block textarea:focus,
.more-block .field input:focus,
.more-block .field select:focus,
.more-block .field textarea:focus {
  border-color: rgba(98, 54, 255, 0.45) !important;
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.16);
}
.more-list { display: grid; gap: 10px; padding-bottom: 8px; }
.more-list p {
  margin: 0; display: flex; justify-content: space-between; gap: 12px;
  font-size: 14px; padding: 8px 0; border-bottom: 1px solid rgba(0,0,0,0.05);
}
.more-list p:last-child { border-bottom: 0; }
.more-list strong { font-weight: 700; color: var(--ink); }
.more-list span { color: var(--muted); font-weight: 600; text-align: right; overflow-wrap: anywhere; }

/* Lightbox */
.car-lightbox {
  display: none; position: fixed; inset: 0; z-index: 400;
  background: rgba(0,0,0,0.92);
  align-items: center; justify-content: center;
  padding: 64px 56px 48px;
  touch-action: pan-y;
}
.car-lightbox.is-open { display: flex; }
.car-lightbox-figure {
  margin: 0; max-width: 100%; max-height: 100%;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  touch-action: pan-y;
}
.car-lightbox-figure img {
  max-width: 100%; max-height: calc(100vh - 140px);
  width: auto; height: auto; object-fit: contain; border-radius: 4px;
  user-select: none; -webkit-user-drag: none; pointer-events: none;
}
.car-lightbox-count { color: #fff; font-size: 0.95rem; letter-spacing: 0.04em; }
.car-lightbox-close, .car-lightbox-nav {
  position: absolute; border: 0; background: rgba(255,255,255,0.18);
  color: #fff; cursor: pointer;
  width: 48px; height: 48px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0; margin: 0; box-shadow: none; line-height: 0;
}
.car-lightbox-close svg, .car-lightbox-nav svg {
  width: 22px; height: 22px; display: block;
  stroke: currentColor; fill: none;
  stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.car-lightbox-close:hover, .car-lightbox-nav:hover { background: rgba(255,255,255,0.32); }
.car-lightbox-close { top: 18px; right: 18px; }
.car-lightbox-nav { top: 50%; transform: translateY(-50%); }
.car-lightbox-prev { left: 14px; }
.car-lightbox-next { right: 14px; }

/* Forms / sheets */
.sheet {
  background: var(--card); border-radius: var(--radius); padding: 16px;
  border: 1px solid var(--line); box-shadow: none; margin-bottom: 12px; min-width: 0;
}
.sheet summary {
  list-style: none; cursor: pointer; min-height: 28px;
  display: flex; justify-content: space-between; align-items: center; font-weight: 800;
}
.sheet summary::-webkit-details-marker { display: none; }
.sheet summary::after { content: "+"; color: var(--purple); font-size: 20px; }
.sheet[open] summary::after { content: "–"; }
.field { display: flex; flex-direction: column; gap: 6px; margin-top: 12px; min-width: 0; }
.field span {
  font-size: 12px; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.field input, .field select, .field textarea,
.sheet input, .sheet select {
  width: 100%; max-width: 100%; min-height: 48px; border: 0; background: var(--soft);
  border-radius: 14px; padding: 12px 14px; outline: none;
}
/* Custom select chevron — native arrows sit flush on desktop Windows */
.field select,
.sheet select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: 42px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px 16px;
}
.field select:focus,
.sheet select:focus {
  background-color: var(--soft);
}
.field input:focus, .field select:focus, .field textarea:focus {
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.18);
}
.form-grid { display: grid; gap: 4px; min-width: 0; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.chip {
  padding: 8px 12px; border-radius: 999px; background: var(--soft);
  font-size: 12px; font-weight: 700; color: var(--muted);
}
.chip.on { background: var(--purple-soft); color: var(--purple-ink); }

.menu-list { display: grid; gap: 8px; }
.menu-item {
  display: flex; align-items: center; gap: 12px;
  background: var(--card); border-radius: 18px; padding: 14px 16px;
  border: 1px solid var(--line); box-shadow: none; font-weight: 700; min-width: 0;
}
.menu-item .menu-ico {
  width: 40px; height: 40px; border-radius: 14px; background: var(--purple-soft);
  color: var(--purple); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.menu-item span:not(.chev) { min-width: 0; }
.menu-item small { display: block; color: var(--muted); font-weight: 600; font-size: 12px; margin-top: 2px; }
.menu-item .chev { margin-left: auto; color: var(--muted); flex-shrink: 0; }

.line-item {
  display: grid; grid-template-columns: 88px 1fr; gap: 12px;
  background: var(--card); border-radius: 20px; padding: 12px;
  border: 1px solid var(--line); box-shadow: none; margin-bottom: 10px; min-width: 0;
}
.line-item img { width: 88px; height: 70px; border-radius: 14px; object-fit: cover; }
.line-item h3 { margin: 0 0 4px; font-size: 15px; font-weight: 800; overflow-wrap: anywhere; }
.line-item p { margin: 0; color: var(--muted); font-size: 12px; font-weight: 600; }
.line-item .price { margin-top: 6px; font-weight: 800; color: var(--ink); }

.auth-card {
  background: var(--card); border-radius: var(--radius); padding: 22px;
  border: 1px solid var(--line); box-shadow: none; margin-top: 10px; max-width: 520px; min-width: 0;
  overflow: hidden; width: 100%;
}
.auth-card.form-card { max-width: 720px; }
.auth-card .h1 { margin-bottom: 8px; }
.auth-card .muted { margin-bottom: 18px; display: block; overflow-wrap: anywhere; }
.centered-main {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: calc(100vh - 220px);
}
.centered-main > .back-link { align-self: flex-start; width: 100%; max-width: 720px; }
.centered-main > .auth-card { margin-left: auto; margin-right: auto; }

.file-field { margin-top: 14px; }
.file-label {
  display: block; font-size: 12px; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 8px;
}
.file-drop {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  min-height: 110px; border: 1.5px dashed #d4d4de; border-radius: 16px;
  background: var(--soft); cursor: pointer; text-align: center; padding: 16px;
}
.file-drop:hover { border-color: var(--purple); background: var(--purple-soft); }
.file-drop strong { font-size: 14px; font-weight: 750; color: var(--purple-ink); }
.file-drop small { color: var(--muted); font-size: 12px; font-weight: 600; }

.sort-chips {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px;
}
.search-filters-mobile { margin: 0 0 14px; }
@media (min-width: 768px) {
  .search-filters-mobile { display: none; }
}

.site-footer {
  font-weight: 400;
}
.site-footer strong { font-weight: 400; color: inherit; }

[hidden] { display: none !important; }

/* QR dashboard cards */
.qr-card { padding: 14px; }
.qr-card-grid {
  display: grid; gap: 14px; align-items: center;
  grid-template-columns: 1fr;
}
.qr-card-media {
  display: flex; align-items: center; justify-content: center;
  background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 12px;
  min-height: 160px;
}
.qr-thumb { width: min(140px, 42vw); height: auto; }
.qr-stats {
  background: var(--soft); border-radius: 14px; padding: 10px 12px;
}
.qr-stats p { margin: 0 0 4px; font-size: 13px; }
.qr-stats p:last-child { margin-bottom: 0; }
.qr-card-actions { display: grid; gap: 8px; }
@media (min-width: 768px) {
  .qr-card-grid {
    grid-template-columns: 160px 1fr 200px;
    gap: 18px;
  }
  .qr-card-media { min-height: 180px; }
}
.divider {
  display: flex; align-items: center; gap: 10px; color: var(--muted);
  font-size: 12px; font-weight: 700; margin: 16px 0;
}
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }

.toast {
  position: fixed; left: 50%; bottom: 110px; transform: translateX(-50%);
  z-index: 180; background: var(--ink); color: #fff; padding: 12px 16px;
  border-radius: 14px; font-size: 13px; font-weight: 600;
  max-width: min(360px, calc(100% - 24px));
}

.back-link {
  display: inline-flex; align-items: center; gap: 6px;
  min-height: 40px; font-weight: 700; color: var(--muted); margin-bottom: 14px;
}
.back-link svg { width: 18px; height: 18px; }

/* Dealer profile */
.dealer-hero {
  display: grid; gap: 16px; align-items: center;
  border-radius: var(--radius); min-height: 168px;
  padding: 22px 20px; color: #fff;
  background: linear-gradient(135deg, #4b1fff 0%, #7b5cff 55%, #b39aff 120%);
  box-shadow: 0 2px 10px rgba(17, 24, 39, 0.06);
  margin-bottom: 16px; position: relative; overflow: hidden;
}
.dealer-hero h1 { margin: 0 0 6px; font-size: clamp(24px, 4vw, 34px); font-weight: 800; max-width: 18ch; line-height: 1.1; }
.dealer-place { margin: 0 0 10px; color: rgba(255,255,255,0.9); font-size: 14px; font-weight: 650; }
.dealer-hero .about { margin: 0; color: rgba(255,255,255,0.88); font-size: 14px; max-width: 40ch; }
.dealer-hero .btn-white { align-self: start; box-shadow: none; }
.social-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 14px 0 8px; }
.btn-wa, .btn-viber {
  flex: 1; min-width: 140px; min-height: 52px; border-radius: 999px;
  font-weight: 750; box-shadow: none;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-wa:focus, .btn-wa:focus-visible,
.btn-viber:focus, .btn-viber:focus-visible {
  box-shadow: 0 0 0 3px rgba(98, 54, 255, 0.32);
}
.btn-wa { background: #25D366; color: #fff; }
.btn-wa:hover { background: #1ebe57; }
.btn-viber { background: #7360f2; color: #fff; }
.btn-viber:hover { background: #5f4de0; }

.site-footer {
  max-width: var(--max); margin: 0 auto;
  padding: 28px 22px calc(100px + var(--safe));
  color: var(--muted); font-size: 12px; line-height: 1.55;
  border-top: 1px solid var(--line); text-align: center; font-weight: 400;
}
.site-footer a { color: var(--purple); font-weight: 400; }
@media (min-width: 768px) {
  .site-footer {
    padding: 28px 28px 40px;
    text-align: left;
    display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  }
}

/* Photo manager (edit) */
.image-select-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px;
}
.image-select-tile {
  position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden;
  background: var(--soft); border: 2px solid transparent; cursor: pointer;
}
.image-select-tile img { width: 100%; height: 100%; object-fit: cover; }
.image-select-tile input {
  position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer;
}
.image-select-mark {
  position: absolute; top: 8px; right: 8px; width: 22px; height: 22px;
  border-radius: 999px; background: rgba(255,255,255,0.9); color: transparent;
  display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800;
}
.image-select-tile:has(input:checked) { border-color: var(--purple); }
.image-select-tile:has(input:checked) .image-select-mark {
  background: var(--purple); color: #fff;
}
.photo-toolbar {
  display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 14px;
}
#uploaded-images {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 10px; margin-top: 12px;
}
#uploaded-images .preview-tile {
  position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--soft);
}
#uploaded-images .preview-tile img { width: 100%; height: 100%; object-fit: cover; }
#uploaded-images .preview-tile button {
  position: absolute; top: 6px; right: 6px; width: 28px; height: 28px;
  border-radius: 999px; background: rgba(0,0,0,0.65); color: #fff; font-size: 16px;
}

/* —— Desktop / tablet —— */
@media (min-width: 768px) {
  .car-gallery-nav { display: inline-flex; }
  .car-gallery-slide { height: min(52vw, 480px); }
  .car-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .cat i { width: 64px; height: 64px; }
  .detail-hero {
    margin: 0; border-radius: var(--radius); overflow: hidden; background: #eef0f5;
  }
  .car-gallery-track, .car-gallery-slide { background: #eef0f5; border-radius: 0; }
  .detail-sheet {
    margin: 0; border-radius: var(--radius);
    border: 1px solid var(--line); box-shadow: none;
    padding: 28px;
  }
  .detail-handle { display: none; }
  .detail-layout { gap: 24px; }
  .sticky-cta { position: static; background: none; padding-top: 8px; }
  .app-main { padding: 24px 24px 48px; }
  .related-block {
    margin: 20px 0 0; padding: 20px 24px; border-radius: var(--radius);
    border: 1px solid var(--line);
  }
  .related-block .car-rail { margin: 0; padding: 4px 0 0; }
  .dealer-hero {
    grid-template-columns: 1fr auto; gap: 24px; padding: 32px 36px; min-height: 200px;
  }
  .dealer-hero .btn-white { align-self: center; }
  .tabbar { display: none; }
  .menu-toggle { display: none; }
  .site-nav { display: flex; }
  .site-actions .btn-search-desktop { display: inline-flex; }
  .mobile-drawer { display: none !important; }
  .search-layout {
    grid-template-columns: 260px 1fr; align-items: start; gap: 28px;
  }
  .search-filters { display: block; position: sticky; top: 120px; }
  .search-filters-mobile { display: none; }
  .hero-banner { min-height: 220px; padding: 36px 40px; }
  .sheet { border: 1px solid var(--line); box-shadow: none; }
}

@media (min-width: 1024px) {
  /* Catalogue: larger cards, max 3 per row */
  .car-grid { grid-template-columns: repeat(3, 1fr); gap: 22px; }
  .car-card { flex-basis: 300px; }
  .car-card-body { padding: 16px 18px 18px; }
  .car-card-body h3 { font-size: 17px; }
  .car-card-price { font-size: 20px; }
  .detail-layout {
    grid-template-columns: 1.15fr 0.85fr;
    gap: 28px; align-items: start;
  }
  .car-gallery-slide { height: 460px; }
  .site-header-inner,
  .dealer-strip-inner { padding-left: 28px; padding-right: 28px; }
  .app-main { padding-left: 28px; padding-right: 28px; }
  .home-featured {
    display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 20px; align-items: stretch;
  }
  .home-featured .hero-banner { min-height: 100%; }
}

@media (max-width: 767.98px) {
  .car-lightbox { padding: 72px 12px 40px; }
  .car-lightbox-close, .car-lightbox-nav { width: 44px; height: 44px; }
  .car-lightbox-prev { left: 8px; }
  .car-lightbox-next { right: 8px; }
  .car-gallery-slide { height: min(78vw, 420px); }
  .detail-top { margin-bottom: 16px; }
  .app-main:has(.detail-layout) { padding-top: 12px; }
}

/* ============================================================
   Live-site additions (Flask pages)
   ============================================================ */

/* Header: account menu + auth links */
.site-auth { display: none; align-items: center; gap: 8px; }
.site-auth .btn { min-height: 40px; }
@media (min-width: 768px) { .site-auth { display: inline-flex; } }
.account-menu { position: relative; }
.account-menu > summary {
  list-style: none; cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  min-height: 40px; padding: 0 12px 0 4px; border-radius: 999px; background: var(--soft);
  font-size: 13px; font-weight: 700;
}
.account-menu > summary::-webkit-details-marker { display: none; }
.account-menu > summary .avatar {
  width: 32px; height: 32px; border-radius: 999px; background: var(--purple-soft); color: var(--purple);
  display: inline-flex; align-items: center; justify-content: center;
}
.account-menu > summary .avatar svg {
  width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}
.account-menu-panel {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 95;
  min-width: 240px; background: var(--card); border: 1px solid var(--line);
  border-radius: 18px; box-shadow: var(--shadow-lg); padding: 8px;
}
.account-menu-panel header { padding: 10px 12px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.account-menu-panel header strong { display: block; font-size: 14px; }
.account-menu-panel header small { display: block; color: var(--muted); font-size: 12px; overflow-wrap: anywhere; }
.account-menu-panel a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px;
  font-size: 14px; font-weight: 650;
}
.account-menu-panel a:hover { background: var(--purple-soft); color: var(--purple-ink); }
@media (max-width: 767.98px) { .account-menu { display: none; } }
.drawer-links hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0; }
.drawer-user { padding: 4px 2px 10px; border-bottom: 1px solid var(--line); }
.drawer-user strong { display: block; }
.drawer-user small { color: var(--muted); overflow-wrap: anywhere; }

/* Dealer strip: phone link next to the share button */
.dealer-strip-actions { display: inline-flex; gap: 8px; flex-shrink: 0; }
.dealer-strip .phone-btn { background: var(--purple); color: #fff; }
.dealer-strip .phone-btn svg { stroke: currentColor; }

/* Copy-link label: hidden on phones, shown from tablet up */
.copy-link-label.d-none { display: none; }
@media (min-width: 768px) { .copy-link-label.d-md-inline { display: inline; } }
.share-btn.is-done { background: #dcfce7 !important; color: #166534 !important; }

/* Page head */
.page-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  margin: 4px 0 16px;
}
.page-head .muted { margin: 6px 0 0; font-size: 14px; }
.page-head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Flash messages → toast */
.flash-stack {
  position: fixed; left: 50%; top: 16px; transform: translateX(-50%); z-index: 500;
  display: grid; gap: 8px; width: min(440px, calc(100% - 24px));
}
.flash {
  background: var(--ink); color: #fff; border-radius: 14px; padding: 12px 16px;
  font-size: 14px; font-weight: 600; box-shadow: var(--shadow-lg);
  display: flex; gap: 10px; align-items: flex-start; justify-content: space-between;
  animation: flashIn 0.25s var(--ease);
}
.flash p { margin: 0; }
.flash button { color: inherit; opacity: 0.7; font-size: 18px; line-height: 1; padding: 0 2px; }
.flash-success { background: #166534; }
.flash-danger, .flash-error { background: #b91c1c; }
.flash-warning { background: #92400e; }
.flash-info { background: var(--purple-ink); }
@keyframes flashIn { from { transform: translateY(-8px); opacity: 0; } to { transform: none; opacity: 1; } }

/* Notices */
.notice {
  border-radius: 18px; padding: 14px 16px; margin: 0 0 16px;
  background: var(--purple-soft); color: var(--purple-ink); font-size: 14px; line-height: 1.5;
}
.notice p { margin: 0 0 8px; }
.notice p:last-child { margin-bottom: 0; }
.notice-warning { background: #fef3c7; color: #78350f; }
.notice-danger { background: #fee2e2; color: #991b1b; }
.notice .btn-row { margin-top: 12px; }
.notice ul { margin: 6px 0 0; padding-left: 18px; }

/* Badges */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 999px; font-size: 11px; font-weight: 800;
  background: var(--soft); color: var(--muted); vertical-align: middle;
}
.badge-draft { background: #fef3c7; color: #92400e; }
.badge-ok { background: #dcfce7; color: #166534; }
.badge-purple { background: var(--purple-soft); color: var(--purple-ink); }
.badge-danger { background: #fee2e2; color: #b91c1c; }

/* Car cards: badges over the photo, inline actions under it */
.car-card-badges { position: absolute; top: 12px; left: 12px; display: flex; gap: 6px; }
.car-card-actions {
  display: flex; gap: 8px; flex-wrap: wrap; padding: 0 16px 16px;
}
.car-card-actions form { margin: 0; display: contents; }
.car-card-actions .btn { min-height: 38px; padding: 0 14px; flex: 1; }
.car-card-link { display: block; color: inherit; }
.car-card.is-highest { border: 2px solid var(--purple); }
.car-card.has-bid { border: 2px solid #f59e0b; }
.car-card-bid { padding: 0 16px 16px; }
.car-card-bid .inline-form { margin: 0; }
.car-card-sub { margin: -6px 0 12px; font-size: 12px; color: var(--muted); font-weight: 600; }
.empty-state {
  text-align: center; padding: 36px 20px; background: var(--card);
  border: 1px dashed #d4d4de; border-radius: var(--radius);
}
.empty-state p { color: var(--muted); margin: 6px 0 16px; }

/* Line-item actions (my cars, favourites, bids) */
.line-item { align-items: center; }
.line-item-body { min-width: 0; }
.line-item-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.line-item-actions form { margin: 0; }
.line-item-actions .btn { min-height: 38px; padding: 0 14px; }
@media (min-width: 768px) {
  .line-item.has-actions { grid-template-columns: 88px 1fr auto; }
  .line-item.has-actions .line-item-actions { grid-column: auto; justify-content: flex-end; }
}

/* Car page: spec list (label: value rows) */
.spec-list { display: grid; gap: 0; margin: 0 0 14px; }
.spec-list p {
  margin: 0; display: flex; justify-content: space-between; gap: 12px;
  font-size: 14px; padding: 9px 0; border-bottom: 1px solid rgba(0,0,0,0.05);
  color: var(--muted); font-weight: 600; overflow-wrap: anywhere; text-align: right;
}
.spec-list p:last-child { border-bottom: 0; }
.spec-list strong { color: var(--ink); font-weight: 700; text-align: left; flex-shrink: 0; }
.more-list p { color: var(--muted); font-weight: 600; text-align: right; overflow-wrap: anywhere; }
.more-list strong { text-align: left; flex-shrink: 0; }
.seller-line {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  color: var(--muted); font-size: 13px; font-weight: 600; margin: 6px 0 16px;
}
.seller-line a { color: var(--purple); font-weight: 750; }
.detail-price-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.detail-price { font-size: clamp(24px, 4vw, 32px); font-weight: 800; margin: 0 0 4px; font-variant-numeric: tabular-nums; }
.offer-box {
  background: var(--purple-soft); border-radius: 20px; padding: 16px; margin: 6px 0 16px;
}
.offer-box h2 { margin: 0 0 4px; }
.offer-box .muted { font-size: 13px; margin: 0 0 6px; }
.offer-box .field input { background: #fff; }
.input-prefix { display: flex; align-items: stretch; gap: 0; }
.input-prefix > span {
  display: inline-flex; align-items: center; padding: 0 12px; border-radius: 14px 0 0 14px;
  background: #e5e7eb; color: var(--ink); font-size: 14px; font-weight: 700;
  text-transform: none; letter-spacing: 0;
}
.field .input-prefix input { border-radius: 0 14px 14px 0; }
.gallery-empty img { width: 100%; height: min(72vw, 420px); object-fit: contain; background: #eef0f5; }
.owner-bar { display: flex; gap: 10px; flex-wrap: wrap; margin: 4px 0 8px; }
.owner-bar .btn { flex: 1; min-width: 140px; }

/* Forms */
.form-grid.two { grid-template-columns: 1fr; column-gap: 14px; }
@media (min-width: 768px) {
  .form-grid.two { grid-template-columns: 1fr 1fr; }
  .form-grid.two > .span-2 { grid-column: 1 / -1; }
}
.field small.help { color: var(--muted); font-size: 12px; font-weight: 500; text-transform: none; letter-spacing: 0; }
.field-error, .field .field-error {
  color: #b91c1c; font-size: 12px; font-weight: 700; text-transform: none; letter-spacing: 0;
}
.field.has-error input, .field.has-error select, .field.has-error textarea {
  box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.5);
}
.check {
  display: flex; align-items: center; gap: 10px; margin-top: 14px;
  font-size: 14px; font-weight: 600; cursor: pointer;
}
.check input { width: 20px; height: 20px; accent-color: var(--purple); margin: 0; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.form-actions .btn { flex: 1; min-width: 140px; }
.form-actions .btn-block { flex-basis: 100%; }
.form-section-title { margin: 22px 0 2px; font-size: 13px; font-weight: 800; color: var(--purple-ink); text-transform: uppercase; letter-spacing: 0.05em; }
.auth-card .btn-block + .btn-block { margin-top: 10px; }
.auth-brand { display: block; margin: 0 0 16px; }
.auth-brand img { height: 34px; width: auto; }
.auth-links { margin: 14px 0 0; text-align: center; font-size: 14px; }
.auth-links a { color: var(--purple); font-weight: 700; }
.cf-turnstile { margin-top: 14px; }
.danger-zone {
  margin-top: 18px; padding: 16px; border-radius: 18px; border: 1px solid #fecaca; background: #fff5f5;
}
.danger-zone p { margin: 0 0 10px; font-size: 13px; color: #991b1b; }
.btn[disabled], .btn:disabled { opacity: 0.55; cursor: not-allowed; box-shadow: none; }
.btn.is-busy { opacity: 0.8; pointer-events: none; }

/* Steps (register) */
.steps { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 0 16px; }
.steps span {
  padding: 8px 10px; border-radius: 12px; background: var(--soft); color: var(--muted);
  font-size: 12px; font-weight: 750; text-align: center;
}
.steps span.active { background: var(--purple-soft); color: var(--purple-ink); }

/* Photo uploads */
.file-drop input[type="file"] {
  position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none;
}
.file-drop { position: relative; }
.file-drop.is-dragover { border-color: var(--purple); background: var(--purple-soft); }
.file-count { margin: 8px 0 0; font-size: 13px; color: var(--muted); font-weight: 600; }

/* QR dashboard */
.qr-card-media img { width: min(150px, 42vw); height: auto; }
.qr-card-actions form { margin: 0; }
.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin: 0 0 16px; }
.package-list { display: grid; gap: 12px; margin-top: 16px; }
.package-list .sheet { margin: 0; }
.package-list ul { margin: 8px 0 0; padding-left: 18px; color: var(--muted); font-size: 14px; line-height: 1.6; }

/* Notifications */
.filter-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0; }

/* Contact */
.contact-grid { display: grid; gap: 16px; width: 100%; max-width: 960px; }
@media (min-width: 900px) { .contact-grid { grid-template-columns: 0.8fr 1.2fr; align-items: start; } }
.contact-grid .auth-card { max-width: none; margin-top: 0; }
.contact-info { display: grid; gap: 10px; }

/* Dealer page */
.dealer-hero .dealer-contact { display: grid; gap: 6px; margin-top: 12px; font-size: 14px; }
.dealer-hero .dealer-contact a { color: #fff; font-weight: 650; }
.dealer-hero-actions { display: grid; gap: 10px; align-self: center; }

/* 404 */
.not-found { text-align: center; max-width: 480px; }
.not-found img { width: min(320px, 80%); margin: 0 auto 18px; }

/* Footer */
.site-footer nav { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }

/* Desktop tweaks for pages without a tab bar */
body.no-tabbar .app-main { padding-bottom: 48px; }
body.no-tabbar .site-footer { padding-bottom: 28px; }
body.no-tabbar .sticky-cta { bottom: calc(12px + var(--safe)); }

/* WTForms renders submit buttons as <input type="submit"> */
input.btn[type="submit"], input.btn[type="button"] {
  -webkit-appearance: none; appearance: none; border: 0; cursor: pointer; font: inherit;
  font-weight: 750; line-height: 1;
}
input.btn-block[type="submit"] { font-size: 15px; }

/* Default size for every inline icon (more specific rules above still win) */
.ico {
  width: 18px; height: 18px; flex-shrink: 0;
  stroke: currentColor; fill: none; stroke-width: 1.8;
  stroke-linecap: round; stroke-linejoin: round;
}
.account-menu-panel a .ico { color: var(--purple); }
.car-gallery-nav .ico { width: 20px; height: 20px; stroke-width: 2.2; }

/* Car page: price in its own block under the title */
.price-box {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--purple-soft); border-radius: 18px; padding: 12px 16px; margin: 0 0 16px;
}
.price-box > span {
  color: var(--purple-ink); font-size: 12px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.05em;
}
.price-box .detail-price { margin: 0; color: var(--purple-ink); }
.detail-sheet .h1 .badge { vertical-align: middle; font-size: 12px; }

/* "Περισσότερα": summary vertically centred, padding only when open */
.more-block { padding: 0 16px; }
.more-block[open] { padding-bottom: 14px; }
.more-block summary { min-height: 52px; padding: 0; line-height: 1.2; }
.more-block summary::after { line-height: 1; display: inline-flex; align-items: center; }

/* New-photo previews: × centred in its circle */
#uploaded-images .preview-tile button {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0 0 2px; line-height: 1; font-size: 18px;
}
