/* Colour scheme: Revel (revelvapeco.com) — near-black violet surfaces with a pink → violet → cyan gradient. */
:root {
  --bg: #07060b;
  --bg-2: #0f0d17;
  --surface: #14121f;
  --surface-2: #1d1a2c;
  --text: #ece9f5;
  --muted: #9a95ad;
  --line: rgba(255, 255, 255, .08);
  --pink: #ff2e88;
  --violet: #8b5cf6;
  --cyan: #22d3ee;
  --grad: linear-gradient(135deg, #ff2e88 0%, #8b5cf6 55%, #22d3ee 100%);
  --brand: #8b5cf6;
  --brand-2: #22d3ee;
  --accent: #ff2e88;
  --accent-ink: #ffffff;
  --ok: #4ade80;
  --ok-bg: rgba(74, 222, 128, .12);
  --warn: #fbbf24;
  --warn-bg: rgba(251, 191, 36, .12);
  --info: #22d3ee;
  --info-bg: rgba(34, 211, 238, .12);
  --wa: #25d366;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .35);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, .55), 0 0 0 1px rgba(139, 92, 246, .15);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 15px/1.5 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  padding-bottom: env(safe-area-inset-bottom);
}
a { color: var(--brand-2); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(1.6rem, 4vw, 2.4rem); font-weight: 800; }
h2 { font-size: 1.35rem; font-weight: 700; }
h3 { font-size: 1.05rem; font-weight: 700; }
p { margin: 0 0 1em; }
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 16px; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.loading { padding: 80px 16px; text-align: center; color: var(--muted); }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--brand-2); outline-offset: 2px; border-radius: 6px; }

/* ---------- top bar ---------- */
.topbar { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar-inner { display: flex; align-items: center; gap: 20px; height: 62px; }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 1.25rem; color: var(--text); letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand b { color: var(--accent); }
.mainnav { display: flex; gap: 4px; margin-right: auto; }
.mainnav a { color: var(--text); padding: 8px 12px; border-radius: 8px; font-weight: 500; }
.mainnav a:hover, .mainnav a.active { background: var(--surface-2); text-decoration: none; }
.topbar-actions { display: flex; align-items: center; gap: 8px; }
#currency { border: 1px solid var(--line); background: var(--surface); color: var(--text); border-radius: 8px; padding: 6px 8px; font: inherit; font-size: .85rem; }
.iconbtn { position: relative; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; color: var(--text); }
.iconbtn:hover { background: var(--surface-2); }
.badge { position: absolute; top: 2px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; display: grid; place-items: center; }

/* ---------- buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid transparent; border-radius: 10px; padding: 10px 18px; font: inherit; font-weight: 600; cursor: pointer; background: var(--brand); color: #fff; text-decoration: none !important; white-space: nowrap; transition: transform .05s, filter .15s; }
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-wa { background: var(--wa); color: #fff; }
.btn-danger { background: transparent; color: var(--accent); border-color: color-mix(in srgb, var(--accent) 40%, transparent); }
.btn-sm { padding: 6px 12px; font-size: .85rem; border-radius: 8px; }
.btn-block { width: 100%; }

label { display: block; font-weight: 600; font-size: .85rem; margin-bottom: 4px; }
.field { margin-bottom: 14px; }
.hint { font-size: .8rem; color: var(--muted); margin-top: 4px; font-weight: 400; }
input, select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line);
  border-radius: 10px; padding: 10px 12px; min-height: 44px;
}
textarea { min-height: 110px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand-2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand-2) 22%, transparent); }
input[type=checkbox] { width: 18px; height: 18px; min-height: 0; accent-color: var(--brand); vertical-align: middle; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; cursor: pointer; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0 14px; }
@media (max-width: 640px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
.error { background: color-mix(in srgb, var(--accent) 12%, var(--surface)); color: var(--accent); padding: 10px 12px; border-radius: 10px; margin-bottom: 14px; font-weight: 500; }

/* ---------- hero ---------- */
.hero { background: radial-gradient(700px 360px at 85% 0%, rgba(255,46,136,.28), transparent 60%), radial-gradient(700px 400px at 10% 110%, rgba(34,211,238,.18), transparent 60%), linear-gradient(120deg, #1a0f2e, #2a0f25 60%, #0d1f2b); color: #fff; padding: 56px 0 72px; position: relative; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto -10% -60px auto; width: 520px; height: 220px; background: linear-gradient(90deg, transparent, rgba(139,92,246,.25)); transform: skewX(-25deg); }
.hero h1 { max-width: 760px; color: #fff; }
.hero p.lead { font-size: 1.1rem; opacity: .85; max-width: 640px; }
.searchbox { position: relative; z-index: 2; background: var(--surface); color: var(--text); border-radius: 18px; box-shadow: var(--shadow-lg); padding: 14px; margin-top: 24px; max-width: 980px; }
.searchtabs { display: flex; gap: 6px; margin-bottom: 12px; }
.searchtabs button { border: 0; background: var(--surface-2); color: var(--text); padding: 8px 16px; border-radius: 999px; font: inherit; font-weight: 600; cursor: pointer; }
.searchtabs button.on { background: var(--brand); color: #fff; }
.searchrow { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr auto; gap: 10px; }
@media (max-width: 860px) { .searchrow { grid-template-columns: 1fr 1fr; } .searchrow .q { grid-column: 1 / -1; } .searchrow .btn { grid-column: 1 / -1; } }
.hero-stats { display: flex; gap: 28px; margin-top: 26px; flex-wrap: wrap; }
.hero-stats b { display: block; font-size: 1.5rem; }
.hero-stats span { opacity: .75; font-size: .85rem; }

/* ---------- sections ---------- */
.section { padding-block: 36px; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.section-head h2 { margin: 0; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--text); font-weight: 500; font-size: .9rem; cursor: pointer; }
.chip:hover { border-color: var(--brand-2); text-decoration: none; }
.chip.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.chip .n { color: var(--muted); font-size: .8rem; }
.chip.on .n { color: #fffc; }

.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; color: var(--text); display: flex; flex-direction: column; gap: 6px; }
.tile:hover { border-color: var(--brand-2); text-decoration: none; box-shadow: var(--shadow); }
.tile .ico { font-size: 1.6rem; }
.tile b { font-size: .95rem; }

/* ---------- cards ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; color: var(--text); position: relative; transition: box-shadow .15s, transform .15s; }
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); text-decoration: none; }
.card .ph { aspect-ratio: 16 / 10; background: var(--surface-2); position: relative; overflow: hidden; }
.card .ph img { width: 100%; height: 100%; object-fit: cover; }
.card .ph .count { position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.6); color: #fff; font-size: .75rem; padding: 2px 8px; border-radius: 6px; }
.card .tags { position: absolute; left: 8px; top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.card .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card .title { font-weight: 700; font-size: 1rem; line-height: 1.3; }
.card .specs { color: var(--muted); font-size: .85rem; }
.card .price { font-size: 1.2rem; font-weight: 800; margin-top: auto; padding-top: 6px; }
.card .price s { color: var(--muted); font-weight: 500; font-size: .85rem; margin-left: 6px; }
.card .dealer { font-size: .8rem; color: var(--muted); display: flex; align-items: center; gap: 4px; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 8px; }
.fav { position: absolute; right: 8px; top: 8px; z-index: 2; width: 36px; height: 36px; border-radius: 50%; border: 0; background: rgba(7,6,11,.7); backdrop-filter: blur(6px); display: grid; place-items: center; cursor: pointer; color: #fff; }
.fav.on { color: var(--accent); }
.fav svg { width: 20px; height: 20px; }

.tag { display: inline-flex; align-items: center; gap: 4px; font-size: .72rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; text-transform: uppercase; letter-spacing: .03em; }
.tag-sale { background: var(--accent); color: #fff; }
.tag-transit { background: var(--info-bg); color: var(--info); }
.tag-featured { background: var(--grad); color: #fff; }
.tag-sold { background: #2a2738; color: #fff; }
.tag-ok { background: var(--ok-bg); color: var(--ok); }
.tag-warn { background: var(--warn-bg); color: var(--warn); }
.verified { color: var(--ok); display: inline-flex; align-items: center; gap: 3px; font-weight: 600; }
.verified svg { width: 15px; height: 15px; }

/* ---------- search page ---------- */
.searchlayout { display: grid; grid-template-columns: 280px 1fr; gap: 24px; padding-block: 24px 40px; align-items: start; }
.filters { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; position: sticky; top: 78px; max-height: calc(100vh - 96px); overflow: auto; }
.filters h3 { display: flex; justify-content: space-between; align-items: center; }
.filters .field { margin-bottom: 12px; }
.resultsbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.resultsbar select { width: auto; }
.filterbtn { display: none; }
@media (max-width: 900px) {
  .searchlayout { grid-template-columns: 1fr; }
  .filters { position: fixed; inset: 0 0 0 auto; width: min(360px, 92vw); max-height: none; z-index: 60; border-radius: 0; transform: translateX(105%); transition: transform .2s; top: 0; }
  .filters.open { transform: none; box-shadow: var(--shadow-lg); }
  .filterbtn { display: inline-flex; }
}
.scrim { position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 55; }
.pager { display: flex; justify-content: center; gap: 8px; margin-top: 24px; }
.empty { text-align: center; padding: 60px 16px; color: var(--muted); background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); }

/* ---------- listing page ---------- */
.crumbs { font-size: .85rem; color: var(--muted); padding: 16px 0 8px; }
.listing { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 24px; padding-bottom: 110px; align-items: start; }
@media (max-width: 960px) { .listing { grid-template-columns: 1fr; } }
.gallery { background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
.gallery .main { aspect-ratio: 16 / 10; background: #0d1218; position: relative; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.gallery .main::-webkit-scrollbar { display: none; }
.gallery .main img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: contain; scroll-snap-align: start; }
.gallery .nav { position: absolute; top: 50%; transform: translateY(-50%); width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(255,255,255,.9); cursor: pointer; font-size: 20px; z-index: 2; }
.gallery .prev { left: 10px; } .gallery .next { right: 10px; }
.gallery .thumbs { display: flex; gap: 6px; padding: 8px; overflow-x: auto; }
.gallery .thumbs img { width: 84px; height: 56px; object-fit: cover; border-radius: 6px; cursor: pointer; opacity: .6; border: 2px solid transparent; flex: none; }
.gallery .thumbs img.on { opacity: 1; border-color: var(--brand-2); }
.gallery-wrap { position: relative; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 16px; }
.sticky { position: sticky; top: 78px; }
.bigprice { font-size: 2rem; font-weight: 800; letter-spacing: -.02em; }
.bigprice s { font-size: 1rem; color: var(--muted); font-weight: 500; margin-left: 8px; }
.offer { background: var(--warn-bg); color: var(--warn); padding: 8px 12px; border-radius: 10px; font-weight: 600; font-size: .9rem; margin: 8px 0; }
.spec-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.spec-grid div { background: var(--surface); padding: 10px 12px; }
.spec-grid span { display: block; font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.spec-grid b { font-weight: 600; }
.actions { display: grid; gap: 8px; margin-top: 14px; }
.actions .row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.dealercard { display: flex; gap: 12px; align-items: center; }
.logo { width: 56px; height: 56px; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; font-weight: 800; color: var(--brand); flex: none; overflow: hidden; font-size: 1.2rem; }
.logo img { width: 100%; height: 100%; object-fit: cover; }
.logo.lg { width: 96px; height: 96px; font-size: 2rem; border-radius: 18px; }
.calc output { font-size: 1.4rem; font-weight: 800; display: block; }
.desc { white-space: pre-line; }
.mobile-cta { display: none; }
@media (max-width: 960px) {
  .sticky { position: static; }
  .mobile-cta { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; position: fixed; left: 0; right: 0; bottom: calc(60px + env(safe-area-inset-bottom)); padding: 10px 16px; background: var(--surface); border-top: 1px solid var(--line); z-index: 35; }
}

/* ---------- dealer pages ---------- */
.storehead { background: linear-gradient(120deg, #1a0f2e, #2a0f25 60%, #0d1f2b); border-bottom: 1px solid var(--line); color: #fff; padding: 32px 0; }
.storehead .wrap { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.storehead .logo { background: #fff; }
.storehead a { color: #fff; }
.dealerlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.dealeritem { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; gap: 14px; color: var(--text); }
.dealeritem:hover { border-color: var(--brand-2); text-decoration: none; box-shadow: var(--shadow); }

/* ---------- dashboard ---------- */
.dash { display: grid; grid-template-columns: 220px 1fr; gap: 24px; padding-block: 24px 48px; align-items: start; }
.dashnav { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; position: sticky; top: 78px; }
.dashnav a { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; border-radius: 8px; color: var(--text); font-weight: 500; }
.dashnav a.on, .dashnav a:hover { background: var(--surface-2); text-decoration: none; }
@media (max-width: 860px) {
  .dash { grid-template-columns: 1fr; }
  .dashnav { position: static; display: flex; overflow-x: auto; gap: 4px; }
  .dashnav a { white-space: nowrap; }
}
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin-bottom: 20px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.stat span { font-size: .8rem; color: var(--muted); }
.stat b { display: block; font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; }
.banner { border-radius: var(--radius); padding: 14px 16px; margin-bottom: 18px; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.banner-warn { background: var(--warn-bg); color: var(--warn); }
.banner-bad { background: color-mix(in srgb, var(--accent) 14%, var(--surface)); color: var(--accent); }
.banner-ok { background: var(--ok-bg); color: var(--ok); }
.banner-info { background: var(--info-bg); color: var(--info); }
.table { width: 100%; border-collapse: collapse; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.table th, .table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; font-size: .9rem; }
.table th { background: var(--surface-2); font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.table tr:last-child td { border-bottom: 0; }
.table .thumb { width: 72px; height: 48px; object-fit: cover; border-radius: 6px; background: var(--surface-2); }
.tablewrap { overflow-x: auto; border-radius: var(--radius); }
.mylist { display: grid; gap: 10px; }
.myitem { display: grid; grid-template-columns: 96px 1fr auto; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; }
.myitem img, .myitem .noimg { width: 96px; height: 64px; object-fit: cover; border-radius: 8px; background: var(--surface-2); }
.myitem .btns { display: flex; gap: 6px; flex-wrap: wrap; justify-content: end; }
@media (max-width: 640px) { .myitem { grid-template-columns: 72px 1fr; } .myitem img, .myitem .noimg { width: 72px; height: 50px; } .myitem .btns { grid-column: 1 / -1; justify-content: start; } }
.photogrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 10px; margin-bottom: 12px; }
.photogrid .p { position: relative; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--surface-2); border: 2px solid transparent; cursor: grab; }
.photogrid .p:first-child { border-color: var(--brand-2); }
.photogrid .p:first-child::after { content: "Cover"; position: absolute; left: 6px; bottom: 6px; background: var(--brand); color: #fff; font-size: .7rem; padding: 1px 6px; border-radius: 4px; font-weight: 700; }
.photogrid .p img { width: 100%; height: 100%; object-fit: cover; }
.photogrid .p button { position: absolute; top: 4px; right: 4px; border: 0; width: 26px; height: 26px; border-radius: 50%; background: rgba(0,0,0,.65); color: #fff; cursor: pointer; }
.photogrid .p.dragging { opacity: .4; }
.dropzone { border: 2px dashed var(--line); border-radius: var(--radius); padding: 22px; text-align: center; cursor: pointer; color: var(--muted); }
.dropzone.over, .dropzone:hover { border-color: var(--brand-2); color: var(--brand-2); }
.kindswitch { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 18px; }
.kindswitch label { border: 2px solid var(--line); border-radius: 12px; padding: 14px; cursor: pointer; font-size: 1rem; text-align: center; margin: 0; }
.kindswitch input { display: none; }
.kindswitch input:checked + span { color: var(--brand-2); }
.kindswitch label:has(input:checked) { border-color: var(--brand-2); background: color-mix(in srgb, var(--brand-2) 8%, var(--surface)); }
.lead { border-left: 4px solid transparent; }
.lead.unread { border-left-color: var(--accent); }
.bars { display: flex; align-items: end; gap: 3px; height: 90px; padding-top: 6px; }
.bars div { flex: 1; background: var(--brand-2); border-radius: 3px 3px 0 0; min-height: 2px; opacity: .85; }
.plans { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin: 12px 0; }
.plans label { border: 2px solid var(--line); border-radius: 12px; padding: 14px; cursor: pointer; margin: 0; font-weight: 500; }
.plans label:has(input:checked) { border-color: var(--brand-2); }
.plans input { display: none; }
.plans b { display: block; font-size: 1.3rem; }

/* ---------- pricing / sell ---------- */
.pricecard { background: var(--surface); border: 2px solid var(--brand-2); border-radius: 20px; padding: 28px; max-width: 460px; box-shadow: var(--shadow-lg); }
.pricecard .amt { font-size: 3rem; font-weight: 800; letter-spacing: -.03em; }
.ticks { list-style: none; padding: 0; margin: 16px 0; }
.ticks li { padding: 6px 0 6px 28px; position: relative; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 800; }
.compare { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: var(--radius); overflow: hidden; }
.compare th, .compare td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: center; font-size: .9rem; }
.compare th:first-child, .compare td:first-child { text-align: left; }
.compare .yes { color: var(--ok); font-weight: 800; }
.compare .no { color: var(--muted); }
.features { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.feature .ico { font-size: 1.6rem; margin-bottom: 6px; }
.authbox { max-width: 460px; margin: 40px auto; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 28px; box-shadow: var(--shadow); }
.authbox.wide { max-width: 720px; }

/* ---------- footer, tabbar, toast ---------- */
.footer { background: var(--surface); border-top: 1px solid var(--line); margin-top: 40px; padding: 32px 0 90px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 24px; }
.footer-grid a { display: block; color: var(--muted); padding: 3px 0; }
.footer h4 { font-size: .85rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.footer-base { margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 761px) { .footer { padding-bottom: 32px; } }
.tabbar { display: none; }
@media (max-width: 760px) {
  .mainnav, #currency { display: none; }
  .topbar-inner { gap: 10px; }
  .topbar-actions { margin-left: auto; }
  .tabbar { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; bottom: 0; left: 0; right: 0; z-index: 45; background: var(--surface); border-top: 1px solid var(--line); padding-bottom: env(safe-area-inset-bottom); }
  .tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0; font-size: .7rem; color: var(--muted); font-weight: 600; }
  .tabbar a.active { color: var(--brand-2); }
  .tabbar svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
  .tabbar a:hover { text-decoration: none; }
}
#toast { position: fixed; left: 50%; bottom: 90px; transform: translateX(-50%) translateY(20px); background: #1d1a2c; border: 1px solid rgba(139,92,246,.4); color: #fff; padding: 12px 18px; border-radius: 12px; opacity: 0; pointer-events: none; transition: .2s; z-index: 100; max-width: 92vw; font-weight: 500; }
#toast.show { opacity: 1; transform: translateX(-50%); }
dialog { border: 0; border-radius: 18px; padding: 0; max-width: 520px; width: calc(100% - 32px); background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg); }
dialog::backdrop { background: rgba(0,0,0,.45); }
dialog .dlg { padding: 22px; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.stack > * + * { margin-top: 12px; }
.prose { max-width: 760px; }
.prose li { margin-bottom: 6px; }
.gallery .nav { color: #121a24; }
@media (max-width: 960px) {
  /* phones: photos, then price + contact, then specs */
  .listing { display: flex; flex-direction: column; gap: 0; }
  .listing > div:first-child { display: contents; }
  .listing .gallery { order: 0; margin-bottom: 16px; }
  .listing > aside { order: 1; }
  .listing > div > .panel { order: 2; margin-top: 0 !important; }
}

/* ---------- Revel accents ---------- */
body { background: radial-gradient(900px 500px at 100% -10%, rgba(139,92,246,.10), transparent 60%), var(--bg); background-attachment: fixed; }
h1, h2, h3, .brand, .bigprice, .stat b, .pricecard .amt { font-family: "Space Grotesk", Inter, system-ui, sans-serif; }
.brand b { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.topbar { background: rgba(7,6,11,.85); }
.btn { background: var(--violet); color: #fff; }
.btn-accent { background: var(--grad); color: #fff; box-shadow: 0 6px 24px rgba(255,46,136,.25); }
.btn-ghost { background: rgba(255,255,255,.03); color: var(--text); }
.btn-danger { background: transparent; color: var(--pink); }
.btn-wa { background: var(--wa); color: #04140a; }
.searchbox { background: linear-gradient(180deg, #13111d, #0d0b15); border: 1px solid var(--line); }
.searchtabs button.on, .chip.on { background: var(--grad); border-color: transparent; color: #fff; }
.card, .panel, .tile, .stat, .dealeritem, .filters, .dashnav, .feature, .authbox, .myitem, .table, .compare, .empty { background: linear-gradient(180deg, #13111d, #0d0b15); }
.card:hover, .tile:hover, .dealeritem:hover { border-color: rgba(139,92,246,.5); }
.card .price, .bigprice { color: #fff; }
.tag-sale { background: var(--pink); }
.pricecard { background: linear-gradient(180deg, #13111d, #0d0b15); border: 1px solid transparent; background-clip: padding-box; position: relative; }
.pricecard::before { content: ""; position: absolute; inset: -2px; z-index: -1; border-radius: 22px; background: var(--grad); }
.pricecard .amt { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.logo { color: var(--violet); }
.bars div { background: var(--grad); }
.footer { background: #05040a; }
.photogrid .p:first-child::after, .badge { background: var(--pink); }
.dashnav a.on { background: rgba(139,92,246,.15); color: #fff; }
.mainnav a.active { background: rgba(139,92,246,.15); }
.tabbar { background: rgba(5,4,10,.94); }
.tabbar a.active { color: var(--pink); }
.kindswitch label:has(input:checked), .plans label:has(input:checked) { border-color: var(--violet); background: rgba(139,92,246,.12); }
.calc output { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; display: inline-block; }
input:focus, select:focus, textarea:focus { border-color: var(--violet); box-shadow: 0 0 0 3px rgba(139,92,246,.25); }
input, select, textarea { background: #0c0a14; }
