/* ============================================================
   AutoElite Motors — main.css  v4
   Aesthetic: Editorial Automotive — Clean white, carbon black,
   vermillion red accent. Bebas Neue display + DM Sans body.
   Asymmetric layouts, bold type, precision spacing.
   ============================================================ */

/* ── GOOGLE FONTS injected via @import ─────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,300&family=DM+Serif+Display:ital@0;1&display=swap');

/* ── DESIGN TOKENS — LIGHT MODE (default) ───────────────── */
:root {
  /* Colors */
  --white:       #ffffff;
  --off-white:   #f7f6f4;
  --bg:          #f4f3f0;
  --surface:     #ffffff;
  --surface-2:   #f0eeeb;
  --border:      #e2e0db;
  --border-2:    #ccc9c2;
  --carbon:      #141414;
  --carbon-2:    #1e1e1e;
  --carbon-3:    #2c2c2c;
  --text:        #141414;
  --text-2:      #5a5650;
  --text-3:      #9e9b94;
  --red:         #d93025;
  --red-dark:    #b02218;
  --red-light:   #fdf0ef;
  --success:     #1a7a4a;
  --success-bg:  #edf7f2;
  --error:       #d93025;
  --error-bg:    #fdf0ef;
  --info:        #1a56db;
  --info-bg:     #eff6ff;

  /* Typography */
  --font-display: 'Bebas Neue', sans-serif;
  --font-serif:   'DM Serif Display', serif;
  --font-body:    'DM Sans', sans-serif;

  /* Spacing */
  --nav-h:    64px;
  --radius:   4px;
  --radius-md:8px;
  --radius-lg:12px;

  /* Shadows */
  --shadow-sm:  0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
  --shadow-md:  0 4px 16px rgba(0,0,0,.08), 0 2px 6px rgba(0,0,0,.04);
  --shadow-lg:  0 12px 40px rgba(0,0,0,.1), 0 4px 12px rgba(0,0,0,.06);
  --shadow-red: 0 8px 24px rgba(217,48,37,.25);

  /* Transition */
  --t: .2s ease;
  --t-slow: .4s ease;
}

/* ── DARK MODE TOKENS ───────────────────────────────────── */
[data-theme="dark"] {
  --white:       #1a1a1f;
  --off-white:   #222228;
  --bg:          #13131a;
  --surface:     #1e1e26;
  --surface-2:   #26262f;
  --border:      #2e2e3a;
  --border-2:    #3a3a48;
  --carbon:      #f0ede8;
  --carbon-2:    #e0ddd8;
  --carbon-3:    #c8c4bc;
  --text:        #f0ede8;
  --text-2:      #a8a49c;
  --text-3:      #5a5750;
  --red-light:   rgba(217,48,37,.12);
  --success-bg:  #0d2b1a;
  --error-bg:    #2a0d0a;
  --info-bg:     #0a1528;
  --shadow-sm:  0 1px 3px rgba(0,0,0,.3), 0 1px 2px rgba(0,0,0,.2);
  --shadow-md:  0 4px 16px rgba(0,0,0,.35), 0 2px 6px rgba(0,0,0,.2);
  --shadow-lg:  0 12px 40px rgba(0,0,0,.5), 0 4px 12px rgba(0,0,0,.3);
}

/* System preference — applies if user hasn't set manual preference */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --white:       #1a1a1f;
    --off-white:   #222228;
    --bg:          #13131a;
    --surface:     #1e1e26;
    --surface-2:   #26262f;
    --border:      #2e2e3a;
    --border-2:    #3a3a48;
    --carbon:      #f0ede8;
    --carbon-2:    #e0ddd8;
    --carbon-3:    #c8c4bc;
    --text:        #f0ede8;
    --text-2:      #a8a49c;
    --text-3:      #5a5750;
    --red-light:   rgba(217,48,37,.12);
    --success-bg:  #0d2b1a;
    --error-bg:    #2a0d0a;
    --info-bg:     #0a1528;
    --shadow-sm:  0 1px 3px rgba(0,0,0,.3);
    --shadow-md:  0 4px 16px rgba(0,0,0,.35);
    --shadow-lg:  0 12px 40px rgba(0,0,0,.5);
  }
}

/* Dark mode specific overrides */
[data-theme="dark"] body,
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) body { } }

[data-theme="dark"] .navbar,
[data-theme="dark"] .nav-mobile {
  background: rgba(19,19,26,.95) !important;
  border-color: var(--border) !important;
}
[data-theme="dark"] .user-dropdown { background: var(--surface); }
[data-theme="dark"] .form-card { background: var(--surface); }
[data-theme="dark"] .form-card-header { background: var(--carbon-2); }
[data-theme="dark"] .vehicle-card { background: var(--surface); }
[data-theme="dark"] .vehicle-card-foot { background: var(--off-white); }
[data-theme="dark"] .data-table-wrap { background: var(--surface); }
[data-theme="dark"] .data-table tr:hover td { background: var(--surface-2); }
[data-theme="dark"] .settings-group { background: var(--surface); }
[data-theme="dark"] .kpi-card { background: var(--surface); }
[data-theme="dark"] .kpi-card:hover { background: var(--off-white); }
[data-theme="dark"] .modal { background: var(--surface); }
[data-theme="dark"] .contact-card { background: var(--surface); }
[data-theme="dark"] .filter-bar { background: var(--surface); }
[data-theme="dark"] .admin-sidebar { background: #0d0d12; }
[data-theme="dark"] .detail-sidebar { background: var(--surface); }
[data-theme="dark"] .wa-preview { background: #0d2b1a; color: #4ade80; border-color: #166534; }
[data-theme="dark"] select,
[data-theme="dark"] input,
[data-theme="dark"] textarea {
  background: var(--surface-2) !important;
  border-color: var(--border) !important;
  color: var(--text) !important;
}

/* Theme toggle button */
.theme-toggle {
  background: none; border: 1px solid var(--border);
  color: var(--text-2); cursor: pointer;
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius); font-size: 1rem;
  transition: background var(--t), border-color var(--t), color var(--t);
}
.theme-toggle:hover { background: var(--off-white); color: var(--text); border-color: var(--border-2); }

/* ── RESET ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
ul  { list-style: none; }
a   { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: inherit; }
input, select, textarea { font-family: inherit; }

/* ── TYPOGRAPHY ─────────────────────────────────────────── */
h1, h2, h3, h4 {
  line-height: 1.1;
  font-weight: 400;
}
/* Display headings use Bebas */
.display, .hero-title, .section-title {
  font-family: var(--font-display);
  letter-spacing: .03em;
  text-transform: uppercase;
}
/* Serif italic for subheadings */
.serif { font-family: var(--font-serif); font-style: italic; }

/* ── NAVBAR ─────────────────────────────────────────────── */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  height: var(--nav-h);
  background: rgba(255,255,255,.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--t);
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
.nav-inner {
  max-width: 1320px; margin: 0 auto; padding: 0 32px;
  height: 100%; display: flex; align-items: center; gap: 0;
}
.nav-brand {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-display);
  font-size: 1.5rem; letter-spacing: .08em;
  color: var(--carbon); white-space: nowrap;
  margin-right: auto;
}
.brand-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--red); display: inline-block;
  margin-bottom: 2px;
}
.brand-icon { display: none; }

.nav-links {
  display: flex; align-items: center; gap: 0;
}
.nav-links li a {
  display: flex; align-items: center;
  height: var(--nav-h);
  padding: 0 18px;
  font-size: .82rem; font-weight: 500;
  letter-spacing: .06em; text-transform: uppercase;
  color: var(--text-2);
  border-bottom: 2px solid transparent;
  transition: color var(--t), border-color var(--t);
}
.nav-links li a:hover { color: var(--carbon); }
.nav-links li a.active { color: var(--red); border-bottom-color: var(--red); }

.nav-cta {
  background: var(--carbon) !important;
  color: var(--white) !important;
  border-bottom: 2px solid transparent !important;
  padding: 0 24px !important;
  border-radius: 0 !important;
  transition: background var(--t) !important;
}
.nav-cta:hover { background: var(--red) !important; }

.lang-switch {
  display: flex; align-items: center; gap: 4px;
  padding: 0 16px;
  font-size: .76rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
  border-left: 1px solid var(--border);
}
.lang-switch a { color: var(--text-3); transition: color var(--t); }
.lang-switch a:hover, .lang-switch a.active { color: var(--red); }
.lang-switch span { color: var(--border-2); }

.nav-toggle {
  display: none; background: none; border: none;
  flex-direction: column; gap: 5px; padding: 6px; margin-left: 16px;
}
.nav-toggle span {
  display: block; width: 22px; height: 1.5px;
  background: var(--carbon); transition: var(--t);
}

/* ── FLASH MESSAGES ─────────────────────────────────────── */
.flash {
  position: fixed; top: calc(var(--nav-h) + 16px); right: 24px;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 18px; border-radius: var(--radius-md);
  font-size: .85rem; font-weight: 500;
  z-index: 500; max-width: 380px;
  box-shadow: var(--shadow-lg);
  animation: slideInRight .3s ease;
}
.flash-success { background: var(--success-bg); border: 1px solid #a7dbbe; color: var(--success); }
.flash-error   { background: var(--error-bg);   border: 1px solid #f5b8b4; color: var(--error);   }
.flash-info    { background: var(--info-bg);    border: 1px solid #bfdbfe; color: var(--info);    }
.flash button  { background: none; border: none; color: inherit; font-size: 1.1rem; margin-left: auto; opacity: .6; }
.flash button:hover { opacity: 1; }
@keyframes slideInRight {
  from { opacity: 0; transform: translateX(20px); }
}

/* ── LAYOUT ─────────────────────────────────────────────── */
.container  { max-width: 1320px; margin: 0 auto; padding: 0 32px; }
.page-body  { padding-top: calc(var(--nav-h) + 56px); padding-bottom: 96px; }

/* ── HERO ───────────────────────────────────────────────── */
.hero {
  min-height: 100vh;
  background: var(--carbon-2);
  display: flex; flex-direction: column; justify-content: flex-end;
  position: relative; overflow: hidden;
  padding-top: var(--nav-h);
}
/* Animated gradient mesh background — only when NO carousel */
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 70% 80% at 80% 20%, rgba(217,48,37,.18) 0%, transparent 60%),
    radial-gradient(ellipse 50% 60% at 10% 80%, rgba(255,255,255,.04) 0%, transparent 50%),
    linear-gradient(160deg, #1a1a1a 0%, #0d0d0d 100%);
  z-index: 0;
}
/* Disable ::before when carousel images exist — they provide their own bg */
.hero:has(.hero-carousel-bg)::before { display: none !important; }
/* Grid texture */
.hero::after {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.03) 1px, transparent 1px);
  background-size: 80px 80px;
  z-index: 0;
}
/* Disable grid texture when carousel exists */
.hero:has(.hero-carousel-bg)::after { display: none !important; }
.hero-content {
  position: relative; z-index: 1;
  padding: 80px 32px 96px;
  max-width: 1320px; margin: 0 auto; width: 100%;
}
.hero-label {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .72rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--red); margin-bottom: 24px;
}
.hero-label::before {
  content: ''; display: block;
  width: 32px; height: 1px; background: var(--red);
}
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(4rem, 10vw, 9rem);
  letter-spacing: .02em; text-transform: uppercase;
  color: var(--white); line-height: .95;
  margin-bottom: 32px;
}
.hero-title .line-red { color: var(--red); }
.hero-sub {
  font-size: 1rem; color: rgba(255,255,255,.55);
  max-width: 480px; margin-bottom: 48px;
  font-weight: 300; line-height: 1.7;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* Hero stats bar */
.hero-stats {
  position: relative; z-index: 1;
  background: rgba(255,255,255,.04);
  border-top: 1px solid rgba(255,255,255,.08);
}
.hero-stats-inner {
  max-width: 1320px; margin: 0 auto; padding: 0 32px;
  display: grid; grid-template-columns: repeat(4, 1fr);
}
.hero-stat {
  padding: 28px 32px;
  border-right: 1px solid rgba(255,255,255,.08);
}
.hero-stat:last-child { border-right: none; }
.hero-stat-num {
  font-family: var(--font-display);
  font-size: 2.8rem; color: var(--white);
  letter-spacing: .04em; line-height: 1;
}
.hero-stat-num span { color: var(--red); }
.hero-stat-label {
  font-size: .72rem; letter-spacing: .12em;
  text-transform: uppercase; color: rgba(255,255,255,.4);
  margin-top: 4px;
}

/* ── BUTTONS ────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 28px;
  font-family: var(--font-body);
  font-size: .82rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
  border: none; border-radius: var(--radius);
  transition: all var(--t); white-space: nowrap;
  cursor: pointer;
}
.btn-primary {
  background: var(--red); color: var(--white);
}
.btn-primary:hover {
  background: var(--red-dark); color: var(--white);
  transform: translateY(-1px); box-shadow: var(--shadow-red);
}
.btn-dark {
  background: var(--carbon); color: var(--white);
}
.btn-dark:hover {
  background: var(--carbon-3); color: var(--white);
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent; color: var(--carbon);
  border: 1.5px solid var(--carbon);
}
.btn-outline:hover { background: var(--carbon); color: var(--white); }
.btn-outline-white {
  background: transparent; color: var(--white);
  border: 1.5px solid rgba(255,255,255,.4);
}
.btn-outline-white:hover { border-color: var(--white); background: rgba(255,255,255,.08); }
.btn-ghost {
  background: var(--surface-2); color: var(--text-2);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--border); color: var(--text); }
.btn-danger { background: var(--red); color: var(--white); }
.btn-danger:hover { background: var(--red-dark); }
.btn-sm { padding: 8px 16px; font-size: .76rem; }
.btn-full { width: 100%; justify-content: center; }

/* ── SECTION HEADINGS ───────────────────────────────────── */
.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; margin-bottom: 48px; flex-wrap: wrap;
}
.section-label {
  font-size: .72rem; font-weight: 600; letter-spacing: .16em;
  text-transform: uppercase; color: var(--red);
  display: flex; align-items: center; gap: 8px; margin-bottom: 12px;
}
.section-label::before { content: ''; display:block; width:24px; height:1px; background:var(--red); }
.section-title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 4rem);
  letter-spacing: .04em; text-transform: uppercase;
  color: var(--carbon); line-height: 1;
}

/* ── VEHICLE GRID ───────────────────────────────────────── */
.vehicle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2px;
  background: var(--border);
  border: 1px solid var(--border);
}
.vehicle-card {
  background: var(--white);
  transition: transform var(--t-slow), box-shadow var(--t-slow);
  position: relative;
  overflow: hidden;
}
.vehicle-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); z-index: 1; }

.vehicle-card-img {
  position: relative; overflow: hidden;
  height: 220px; background: var(--surface-2);
}
.vehicle-card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .6s ease;
}
.vehicle-card:hover .vehicle-card-img img { transform: scale(1.04); }
.vehicle-card-img .img-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3rem; color: var(--text-3);
  background: linear-gradient(135deg, #f0eeeb, #e8e5e0);
}

/* Status ribbon */
.status-ribbon {
  position: absolute; top: 16px; left: 0;
  font-size: .68rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; padding: 5px 14px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}
.ribbon-disponible { background: #15803d;  color: #ffffff; }
.ribbon-vendido    { background: #dc2626;  color: #ffffff; }
.ribbon-reservado  { background: #d97706;  color: #ffffff; }

.vehicle-card-body { padding: 24px; }
.vehicle-card-brand {
  font-size: .72rem; font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; color: var(--text-3); margin-bottom: 4px;
}
.vehicle-card-name {
  font-family: var(--font-display);
  font-size: 1.5rem; letter-spacing: .04em; text-transform: uppercase;
  color: var(--carbon); line-height: 1.1; margin-bottom: 16px;
}
.vehicle-card-specs {
  display: flex; gap: 16px; flex-wrap: wrap;
  padding: 14px 0; border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border); margin-bottom: 16px;
}
.spec-pill {
  font-size: .76rem; color: var(--text-2);
  display: flex; align-items: center; gap: 5px;
}
.spec-pill::before { content: '—'; color: var(--border-2); font-size: .6rem; }
.vehicle-card-price {
  font-family: var(--font-display);
  font-size: 2rem; letter-spacing: .04em;
  color: var(--carbon);
}
.vehicle-card-price-label {
  font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-3); margin-bottom: 2px;
}
.vehicle-card-foot {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex; gap: 8px; flex-wrap: wrap;
  background: var(--off-white);
}

/* ── SEARCH / FILTER BAR ────────────────────────────────── */
.filter-bar {
  background: var(--white);
  border: 1px solid var(--border);
  padding: 20px 24px; margin-bottom: 40px;
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
  box-shadow: var(--shadow-sm);
}
.filter-bar input,
.filter-bar select {
  flex: 1; min-width: 180px;
  background: var(--off-white); border: 1px solid var(--border);
  color: var(--text); padding: 10px 14px; border-radius: var(--radius);
  font-size: .88rem; transition: border-color var(--t);
}
.filter-bar input:focus,
.filter-bar select:focus {
  outline: none; border-color: var(--carbon);
  background: var(--white);
}
.filter-bar label {
  font-size: .72rem; font-weight: 600; letter-spacing: .1em;
  text-transform: uppercase; color: var(--text-3);
}

/* ── FORMS ──────────────────────────────────────────────── */
.form-page {
  min-height: calc(100vh - var(--nav-h));
  background: var(--bg);
  display: flex; align-items: center; justify-content: center;
  padding: calc(var(--nav-h) + 40px) 24px 60px;
}
.form-card {
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  width: 100%; max-width: 480px;
  padding: 0; overflow: hidden;
}
.form-card-header {
  background: var(--carbon);
  padding: 32px 40px;
}
.form-card-header h2 {
  font-family: var(--font-display);
  font-size: 2.2rem; letter-spacing: .06em;
  text-transform: uppercase; color: var(--white);
}
.form-card-header p { color: rgba(255,255,255,.5); font-size: .88rem; margin-top: 6px; }
.form-card-body { padding: 36px 40px; }

.form-group { margin-bottom: 20px; }
.form-group label {
  display: block; font-size: .72rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-3); margin-bottom: 8px;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: var(--off-white); border: 1px solid var(--border);
  color: var(--text); padding: 11px 14px;
  border-radius: var(--radius); font-size: .95rem;
  transition: border-color var(--t), background var(--t), box-shadow var(--t);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none; border-color: var(--carbon);
  background: var(--white);
  box-shadow: 0 0 0 3px rgba(20,20,20,.06);
}
.form-group textarea { resize: vertical; min-height: 90px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-hint { font-size: .76rem; color: var(--text-3); margin-top: 5px; }
.form-divider {
  display: flex; align-items: center; gap: 14px;
  margin: 24px 0; color: var(--text-3); font-size: .8rem;
}
.form-divider::before, .form-divider::after {
  content: ''; flex: 1; height: 1px; background: var(--border);
}
.form-link {
  text-align: center; margin-top: 20px;
  font-size: .88rem; color: var(--text-2);
}
.form-link a { color: var(--carbon); font-weight: 600; border-bottom: 1px solid var(--border); }
.form-link a:hover { border-color: var(--carbon); }

/* ── VEHICLE DETAIL ─────────────────────────────────────── */
.detail-layout {
  display: grid; grid-template-columns: 1fr 420px;
  gap: 40px; align-items: start;
}
.detail-image-wrap { position: relative; }
.detail-image-wrap img {
  width: 100%; aspect-ratio: 16/10;
  object-fit: cover; border: 1px solid var(--border);
}
.detail-sidebar {
  background: var(--white); border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.detail-sidebar-header {
  background: var(--carbon); padding: 28px;
}
.detail-price-label {
  font-size: .68rem; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(255,255,255,.4); margin-bottom: 4px;
}
.detail-price {
  font-family: var(--font-display);
  font-size: 3.2rem; color: var(--white);
  letter-spacing: .04em; line-height: 1;
}
.detail-status { margin-top: 12px; }
.detail-sidebar-body { padding: 28px; }
.detail-specs-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1px; background: var(--border);
  border: 1px solid var(--border); margin-bottom: 24px;
}
.detail-spec {
  background: var(--white); padding: 14px 16px;
}
.detail-spec-label {
  font-size: .68rem; letter-spacing: .1em; text-transform: uppercase;
  color: var(--text-3); margin-bottom: 3px;
}
.detail-spec-val { font-weight: 600; font-size: .92rem; }
.detail-desc {
  font-size: .9rem; color: var(--text-2); line-height: 1.7;
  padding-top: 20px; border-top: 1px solid var(--border);
}

/* ── STATUS BADGES ──────────────────────────────────────── */
.badge {
  display: inline-block; padding: 4px 12px;
  font-size: .68rem; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase;
  border-radius: var(--radius);
}
.badge-disponible, .status-disponible { background: #dcfce7; color: #15803d; }
.badge-vendido,    .status-vendido    { background: #fee2e2; color: #dc2626; }
.badge-reservado,  .status-reservado  { background: #fef3c7; color: #b45309; }
.badge-admin    { background: var(--carbon); color: var(--white); }
.badge-vendedor { background: #eff6ff; color: var(--info); }
.badge-cliente  { background: var(--surface-2); color: var(--text-2); }

/* Vehicle status (for card) */
.vehicle-status { /* kept for compat */ }

/* ── ADMIN LAYOUT ───────────────────────────────────────── */
.admin-layout {
  display: flex;
  min-height: calc(100vh - var(--nav-h));
}
.admin-sidebar {
  width: 260px; flex-shrink: 0;
  background: var(--carbon-2);
  border-right: none;
  position: sticky; top: var(--nav-h);
  height: calc(100vh - var(--nav-h));
  overflow-y: auto;
}
.admin-sidebar .sidebar-title {
  font-size: .65rem; font-weight: 700;
  letter-spacing: .18em; text-transform: uppercase;
  color: rgba(255,255,255,.25);
  padding: 28px 24px 12px;
}
.sidebar-nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 24px;
  font-size: .82rem; font-weight: 500; letter-spacing: .04em;
  color: rgba(255,255,255,.45);
  border-left: 3px solid transparent;
  transition: all var(--t);
}
.sidebar-nav a:hover {
  color: rgba(255,255,255,.85);
  background: rgba(255,255,255,.04);
}
.sidebar-nav a.active {
  color: var(--white);
  background: rgba(255,255,255,.06);
  border-left-color: var(--red);
}
.sidebar-icon { font-size: .95rem; width: 18px; text-align: center; flex-shrink: 0; }
.sidebar-badge {
  margin-left: auto; background: var(--red); color: var(--white);
  border-radius: 100px; font-size: .65rem; padding: 1px 7px; font-weight: 700;
}

.admin-main {
  flex: 1; background: var(--bg);
  padding: 40px 48px 96px; min-width: 0;
  overflow-x: hidden;
}

/* Admin page title */
.admin-page-title { margin-bottom: 36px; }
.admin-page-title .label {
  font-size: .7rem; font-weight: 700; letter-spacing: .16em;
  text-transform: uppercase; color: var(--red); margin-bottom: 8px;
  display: flex; align-items: center; gap: 6px;
}
.admin-page-title .label::before { content:''; width:16px; height:1px; background:var(--red); }
.admin-page-title h1 {
  font-family: var(--font-display);
  font-size: 2.8rem; letter-spacing: .04em;
  text-transform: uppercase; color: var(--carbon);
}
.admin-page-title p { color: var(--text-2); margin-top: 6px; font-size: .9rem; }

/* KPI cards */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1px; background: var(--border);
  border: 1px solid var(--border);
  margin-bottom: 40px;
  box-shadow: var(--shadow-sm);
}
.kpi-card {
  background: var(--white); padding: 24px 28px;
  transition: background var(--t);
}
.kpi-card:hover { background: var(--off-white); }
.kpi-label {
  font-size: .68rem; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--text-3); margin-bottom: 10px;
}
.kpi-value {
  font-family: var(--font-display);
  font-size: 2.6rem; letter-spacing: .04em;
  color: var(--carbon); line-height: 1;
}
.kpi-sub { font-size: .78rem; color: var(--text-3); margin-top: 4px; }
.kpi-red  .kpi-value { color: var(--red); }
.kpi-green .kpi-value { color: var(--success); }

/* ── DATA TABLE ─────────────────────────────────────────── */
.data-table-wrap {
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
  background: var(--carbon);
  padding: 13px 18px; text-align: left;
  font-size: .68rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase;
  color: rgba(255,255,255,.6);
}
.data-table td {
  padding: 14px 18px; border-bottom: 1px solid var(--border);
  font-size: .88rem; vertical-align: middle;
}
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--off-white); }
.data-table img.thumb {
  width: 64px; height: 44px; object-fit: cover;
  border: 1px solid var(--border);
}
.actions-cell { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.text-right { text-align: right; }
.text-center { text-align: center; }

/* ── MODAL ──────────────────────────────────────────────── */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 600;
  background: rgba(20,20,20,.6);
  backdrop-filter: blur(6px);
  align-items: center; justify-content: center; padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--white);
  border: 1px solid var(--border);
  width: 100%; max-width: 640px;
  max-height: 92vh; overflow-y: auto;
  box-shadow: var(--shadow-lg);
  animation: modalIn .25s ease;
}
@keyframes modalIn {
  from { opacity: 0; transform: scale(.97) translateY(8px); }
}
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 28px; border-bottom: 1px solid var(--border);
  background: var(--carbon);
}
.modal-head h3 {
  font-family: var(--font-display); font-size: 1.4rem;
  letter-spacing: .06em; text-transform: uppercase; color: var(--white);
}
.modal-close {
  background: none; border: none; color: rgba(255,255,255,.5);
  font-size: 1.4rem; line-height: 1; transition: color var(--t);
}
.modal-close:hover { color: var(--white); }
.modal-body { padding: 28px; }
.modal-foot {
  padding: 16px 28px; border-top: 1px solid var(--border);
  display: flex; gap: 10px; justify-content: flex-end;
  background: var(--off-white);
}

/* ── IMAGE MANAGER ──────────────────────────────────────── */
.img-manager { margin-top: 4px; }
.img-current {
  display: flex; align-items: flex-start; gap: 16px;
  background: var(--off-white); border: 1px solid var(--border);
  padding: 16px; flex-wrap: wrap;
}
.img-thumb-large {
  width: 160px; height: 110px; object-fit: cover;
  border: 1px solid var(--border); flex-shrink: 0;
}
.img-current-info {
  display: flex; flex-direction: column; justify-content: center; min-width: 0;
}
.img-filename { font-size: .78rem; color: var(--text-2); word-break: break-all; }
.img-dropzone {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px;
  background: var(--off-white);
  border: 2px dashed var(--border-2);
  padding: 40px 20px; cursor: pointer; text-align: center;
  transition: border-color var(--t), background var(--t);
}
.img-dropzone:hover { border-color: var(--carbon); background: var(--white); }
.img-dropzone-icon  { font-size: 2rem; opacity: .35; }
.img-dropzone-text  { font-size: .88rem; color: var(--text-2); font-weight: 500; }
.img-dropzone-hint  { font-size: .74rem; color: var(--text-3); }
.img-preview-label  {
  font-size: .72rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--red); margin-bottom: 8px;
}
.img-new-preview { }

/* ── WHATSAPP ───────────────────────────────────────────── */
.btn-wa {
  background: #25D366; color: var(--white) !important;
  border: none; display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 20px; font-size: .82rem; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  cursor: pointer; white-space: nowrap; border-radius: var(--radius);
  transition: background var(--t), transform var(--t), box-shadow var(--t);
}
.btn-wa:hover {
  background: #1ebe59; color: var(--white) !important;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(37,211,102,.3);
}
.btn-wa.btn-sm { padding: 7px 14px; font-size: .76rem; }

.wa-vehicle-badge {
  display: flex; align-items: center; gap: 10px;
  background: #f0fdf4; border: 1px solid #86efac;
  padding: 10px 16px; margin-bottom: 20px;
  font-weight: 600; font-size: .9rem; color: #15803d;
}
.wa-vehicle-icon { font-size: 1.1rem; }
.wa-preview {
  display: none;
  background: #f0fdf4; border: 1px solid #86efac;
  padding: 14px 16px; margin-top: 16px;
  font-size: .8rem; line-height: 1.6;
  color: #166534; white-space: pre-wrap; word-break: break-word;
  font-family: 'Courier New', monospace;
  max-height: 130px; overflow-y: auto;
}
.wa-preview::before {
  content: 'Vista previa:';
  display: block; font-family: var(--font-body);
  font-size: .68rem; text-transform: uppercase; letter-spacing: .1em;
  color: #15803d; margin-bottom: 8px; font-weight: 700;
}
.appt-pendiente  { background: #fef9c3; color: #854d0e; }
.appt-confirmada { background: #dcfce7; color: #15803d; }
.appt-cancelada  { background: #fee2e2; color: #dc2626; }
.appt-completada { background: #dbeafe; color: #1d4ed8; }

/* Floating WhatsApp */
.wa-float {
  position: fixed; bottom: 28px; right: 28px; z-index: 300;
  width: 54px; height: 54px;
  background: #25D366; color: var(--white);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.4);
  transition: transform .2s, box-shadow .2s;
  text-decoration: none;
}
.wa-float:hover { transform: scale(1.08); box-shadow: 0 6px 28px rgba(37,211,102,.5); color: var(--white); }
.wa-float svg { width: 26px; height: 26px; }


/* ── FOOTER — see footer v2 section below ───────────────── */
/* (old single-column footer removed, replaced by footer-grid) */

/* ── UTILITY ────────────────────────────────────────────── */
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.fw-bold { font-weight: 600; }
.text-muted  { color: var(--text-2); }
.text-red    { color: var(--red); }
.text-carbon { color: var(--carbon); }
.divider { border: none; border-top: 1px solid var(--border); margin: 28px 0; }
.empty-state {
  text-align: center; padding: 80px 20px;
  color: var(--text-3); background: var(--white);
  border: 1px solid var(--border);
}
.empty-state .empty-icon { font-size: 2.8rem; margin-bottom: 16px; opacity: .3; }
.empty-state p { font-size: .9rem; }

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 1024px) {
  .detail-layout { grid-template-columns: 1fr; }
  .admin-main { padding: 32px 24px 80px; }
}
@media (max-width: 900px) {
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; height: auto; position: static; }
  .sidebar-nav { display: flex; flex-wrap: wrap; padding: 8px; gap: 4px; }
  .sidebar-nav a { border-left: none; border-bottom: 2px solid transparent; padding: 10px 14px; font-size: .78rem; }
  .sidebar-nav a.active { border-bottom-color: var(--red); border-left: none; }
  .hero-stats-inner { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 700px) {
  .nav-toggle { display: flex; }
  .nav-links {
    display: none; flex-direction: column;
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    background: var(--white); border-bottom: 1px solid var(--border);
    padding: 8px 0; box-shadow: var(--shadow-md);
  }
  .nav-links.open { display: flex; }
  .nav-links li a { height: 48px; border-bottom: none; border-left: 3px solid transparent; }
  .nav-links li a.active { border-left-color: var(--red); }
  .form-row { grid-template-columns: 1fr; }
  .hero-title { font-size: clamp(3rem, 14vw, 6rem); }
  .hero-stats-inner { grid-template-columns: 1fr 1fr; }
  .hero-stat { padding: 20px 16px; }
  .vehicle-grid { grid-template-columns: 1fr; gap: 1px; }
  .form-card-header, .form-card-body { padding: 24px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .data-table-wrap { overflow-x: auto; }
  .container { padding: 0 16px; }
}
@media (max-width: 480px) {
  .hero-stats-inner { grid-template-columns: 1fr 1fr; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
}

/* ── VEHICLE GALLERY CAROUSEL ───────────────────────────── */
.carousel {
  position: relative; overflow: hidden;
  background: var(--carbon);
  aspect-ratio: 16/9;
  user-select: none;
  cursor: zoom-in;
}
.carousel-track {
  display: flex; height: 100%;
  transition: transform .45s cubic-bezier(.4,0,.2,1);
}
.carousel-slide {
  flex: 0 0 100%; height: 100%;
  position: relative;
}
.carousel-slide img {
  width: 100%; height: 100%; object-fit: cover;
  display: block;
}
.carousel-slide .no-img {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 5rem; color: var(--text-3);
  background: var(--surface-2);
}

/* Arrow buttons */
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 10;
  width: 44px; height: 44px;
  background: rgba(255,255,255,.92);
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: var(--carbon);
  transition: background var(--t), transform var(--t);
  box-shadow: var(--shadow-md);
}
.carousel-btn:hover { background: var(--white); transform: translateY(-50%) scale(1.06); }
.carousel-btn-prev { left: 14px; }
.carousel-btn-next { right: 14px; }
.carousel-btn.hidden { display: none; }

/* Counter */
.carousel-counter {
  position: absolute; bottom: 14px; right: 14px;
  background: rgba(0,0,0,.55);
  color: var(--white); font-size: .72rem; font-weight: 600;
  padding: 4px 10px; letter-spacing: .06em;
}

/* Thumbnails */
.carousel-thumbs {
  display: flex; gap: 6px; margin-top: 8px;
  overflow-x: auto; padding-bottom: 4px;
}
.carousel-thumbs::-webkit-scrollbar { height: 3px; }
.carousel-thumbs::-webkit-scrollbar-thumb { background: var(--border-2); }
.carousel-thumb {
  flex: 0 0 72px; height: 50px;
  object-fit: cover; cursor: pointer;
  border: 2px solid transparent;
  transition: border-color var(--t), opacity var(--t);
  opacity: .55;
}
.carousel-thumb.active { border-color: var(--red); opacity: 1; }
.carousel-thumb:hover  { opacity: .85; }

/* ── GALLERY MANAGER (admin) ────────────────────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 6px; margin-bottom: 8px;
}
.gallery-item {
  position: relative; aspect-ratio: 4/3;
  overflow: hidden; background: var(--surface-2);
  border: 1px solid var(--border);
}
.gallery-item img {
  width: 100%; height: 100%; object-fit: cover;
  display: block; transition: transform .3s ease;
}
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.45);
  display: flex; align-items: center; justify-content: center; gap: 6px;
  opacity: 0; transition: opacity var(--t);
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gal-btn {
  width: 30px; height: 30px; border-radius: 50%;
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: .8rem; font-weight: 700;
  transition: transform var(--t);
}
.gal-btn:hover { transform: scale(1.1); }
.gal-btn-star { background: #f59e0b; color: var(--white); }
.gal-btn-del  { background: var(--red); color: var(--white); }
.gal-badge-main {
  background: #f59e0b; color: var(--white);
  font-size: .65rem; font-weight: 700;
  padding: 3px 8px; letter-spacing: .06em;
}
.gal-principal-bar {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: #f59e0b; color: var(--white);
  font-size: .65rem; font-weight: 700; text-align: center;
  padding: 3px; letter-spacing: .06em;
}
.gallery-add-slot {
  aspect-ratio: 4/3;
  border: 2px dashed var(--border-2);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 4px;
  cursor: pointer; transition: border-color var(--t), background var(--t);
  background: var(--off-white);
}
.gallery-add-slot:hover { border-color: var(--carbon); background: var(--white); }

/* Settings form */
.settings-group {
  background: var(--white); border: 1px solid var(--border);
  margin-bottom: 24px; overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.settings-group-header {
  background: var(--carbon); padding: 14px 20px;
  display: flex; align-items: center; gap: 10px;
}
.settings-group-header h3 {
  font-family: var(--font-display); font-size: 1.1rem;
  letter-spacing: .08em; text-transform: uppercase; color: var(--white);
}
.settings-group-body { padding: 20px; }
.settings-row {
  display: grid; grid-template-columns: 200px 1fr;
  gap: 16px; padding: 14px 0;
  border-bottom: 1px solid var(--border); align-items: start;
}
.settings-row:last-child { border-bottom: none; }
.settings-label {
  font-size: .78rem; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--text-2); padding-top: 10px;
}
.settings-label small { display: block; font-size: .7rem; color: var(--text-3); text-transform: none; letter-spacing: 0; margin-top: 2px; font-weight: 400; }
.settings-row input[type="text"],
.settings-row input[type="email"],
.settings-row input[type="tel"],
.settings-row input[type="url"],
.settings-row input[type="color"],
.settings-row textarea,
.settings-row select {
  width: 100%; background: var(--off-white); border: 1px solid var(--border);
  color: var(--text); padding: 9px 12px; border-radius: var(--radius);
  font-family: inherit; font-size: .9rem;
  transition: border-color var(--t), background var(--t);
}
.settings-row input:focus, .settings-row textarea:focus {
  outline: none; border-color: var(--carbon); background: var(--white);
}
.settings-row textarea { resize: vertical; min-height: 70px; }
.settings-row input[type="color"] {
  padding: 4px; height: 38px; cursor: pointer;
}

/* ── NAVBAR v2 — Dropdown user menu ────────────────────── */
.nav-main-links {
  display: flex; align-items: center; gap: 0;
  margin: 0 auto;
}
.nav-main-links li a {
  display: flex; align-items: center;
  height: var(--nav-h); padding: 0 20px;
  font-size: .8rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--text-2);
  border-bottom: 2px solid transparent;
  transition: color var(--t), border-color var(--t);
}
.nav-main-links li a:hover { color: var(--carbon); }
.nav-main-links li a.active { color: var(--red); border-bottom-color: var(--red); }

.nav-right {
  display: flex; align-items: center; gap: 12px;
  margin-left: auto;
}

/* User menu trigger */
.user-menu { position: relative; }
.user-menu-trigger {
  display: flex; align-items: center; gap: 8px;
  background: none; border: 1px solid var(--border);
  padding: 6px 12px 6px 6px; cursor: pointer;
  transition: background var(--t), border-color var(--t);
  border-radius: var(--radius);
}
.user-menu-trigger:hover { background: var(--off-white); border-color: var(--border-2); }
.user-menu-trigger[aria-expanded="true"] {
  background: var(--off-white); border-color: var(--carbon);
}
.user-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--carbon); color: var(--white);
  font-size: .75rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.user-name {
  font-size: .8rem; font-weight: 600; color: var(--text);
  max-width: 80px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.user-chevron {
  color: var(--text-3); flex-shrink: 0;
  transition: transform var(--t);
}
.user-menu-trigger[aria-expanded="true"] .user-chevron { transform: rotate(180deg); }

/* Dropdown panel */
.user-dropdown {
  display: none;
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  min-width: 240px; z-index: 400;
  animation: dropdownIn .15s ease;
}
.user-dropdown.open { display: block; }
@keyframes dropdownIn {
  from { opacity: 0; transform: translateY(-6px); }
}

.dropdown-header {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 16px; background: var(--off-white);
  border-bottom: 1px solid var(--border);
}
.dropdown-avatar {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--carbon); color: var(--white);
  font-size: .95rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.dropdown-name  { font-weight: 600; font-size: .9rem; }
.dropdown-email { font-size: .75rem; color: var(--text-3); margin-top: 1px; }

.dropdown-divider { height: 1px; background: var(--border); margin: 4px 0; }

.dropdown-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 16px;
  font-size: .85rem; font-weight: 500; color: var(--text-2);
  transition: background var(--t), color var(--t);
}
.dropdown-item:hover { background: var(--off-white); color: var(--carbon); }
.dropdown-item svg { flex-shrink: 0; color: var(--text-3); }
.dropdown-item:hover svg { color: var(--carbon); }
.dropdown-item-danger { color: var(--error); }
.dropdown-item-danger:hover { background: var(--error-bg); color: var(--error); }
.dropdown-item-danger svg { color: var(--error); }

/* Mobile nav */
.nav-mobile {
  display: none;
  flex-direction: column;
  background: var(--white);
  border-top: 1px solid var(--border);
  box-shadow: var(--shadow-md);
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  padding: 13px 24px;
  font-size: .85rem; font-weight: 500;
  letter-spacing: .04em; color: var(--text-2);
  border-bottom: 1px solid var(--border);
  transition: color var(--t), background var(--t);
}
.nav-mobile a:hover { color: var(--carbon); background: var(--off-white); }

/* ── CONTACT PAGE ───────────────────────────────────────── */
.contact-card {
  background: var(--white); border: 1px solid var(--border);
  padding: 24px; box-shadow: var(--shadow-sm);
  transition: box-shadow var(--t), border-color var(--t);
}
.contact-card:hover { box-shadow: var(--shadow-md); border-color: var(--border-2); }
.contact-card-icon { font-size: 1.6rem; margin-bottom: 10px; }
.contact-card-label {
  font-size: .68rem; font-weight: 700; letter-spacing: .12em;
  text-transform: uppercase; color: var(--text-3); margin-bottom: 4px;
}
.contact-card-value {
  font-weight: 600; font-size: .95rem; color: var(--carbon);
  transition: color var(--t);
}
a.contact-card-value:hover { color: var(--red); }
.contact-card-wa { border-left: 3px solid #25D366; }

/* Social buttons */
.social-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; border-radius: var(--radius);
  font-size: .82rem; font-weight: 600;
  transition: background var(--t), color var(--t), transform var(--t);
  border: 1px solid var(--border);
  background: var(--white); color: var(--text-2);
}
.social-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.social-btn-fb:hover { background: #1877f2; color: var(--white); border-color: #1877f2; }
.social-btn-ig:hover { background: #e1306c; color: var(--white); border-color: #e1306c; }
.social-btn-tw:hover { background: #1da1f2; color: var(--white); border-color: #1da1f2; }
.social-btn-yt:hover { background: #ff0000; color: var(--white); border-color: #ff0000; }

/* Responsive contact */
@media (max-width: 860px) {
  .contact-page-grid { grid-template-columns: 1fr !important; }
}

/* ── FOOTER v2 ──────────────────────────────────────────── */
.site-footer {
  background: var(--carbon-2);
  transition: background var(--t);
}

/* Light mode footer — dark background stays for contrast */
/* Dark mode footer — slightly different shade */
[data-theme="dark"] .site-footer { background: #0a0a10; }

/* Footer always shows white text since bg is always dark */
.footer-top {
  max-width: 1320px; margin: 0 auto;
  padding: 64px 32px 48px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1.5fr 1.5fr;
  gap: 48px;
}
.footer-col-brand .footer-brand {
  font-family: var(--font-display);
  font-size: 1.6rem; letter-spacing: .1em;
  color: #ffffff;
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 10px;
}
.footer-tagline {
  color: rgba(255,255,255,.35);
  font-size: .87rem; line-height: 1.6;
  margin-bottom: 20px;
}
.footer-col-title {
  font-size: .68rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase;
  color: rgba(255,255,255,.3);
  margin-bottom: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

/* Nav links */
.footer-nav { display: flex; flex-direction: column; gap: 10px; }
.footer-nav a {
  font-size: .85rem; color: rgba(255,255,255,.45);
  transition: color var(--t);
  display: flex; align-items: center; gap: 6px;
}
.footer-nav a::before {
  content: '—'; font-size: .6rem;
  color: rgba(255,255,255,.15);
}
.footer-nav a:hover { color: #ffffff; }

/* Contact list */
.footer-contact-list {
  display: flex; flex-direction: column; gap: 12px;
}
.footer-contact-list li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: .84rem; color: rgba(255,255,255,.45);
  line-height: 1.5;
}
.footer-contact-list a {
  color: rgba(255,255,255,.45);
  transition: color var(--t);
}
.footer-contact-list a:hover { color: #ffffff; }
.footer-contact-icon { font-size: .9rem; flex-shrink: 0; margin-top: 1px; }

/* Social icons */
.footer-socials { display: flex; gap: 8px; flex-wrap: wrap; }
.footer-social-btn {
  width: 34px; height: 34px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  color: rgba(255,255,255,.5);
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius);
  transition: background var(--t), color var(--t), border-color var(--t);
}
.footer-social-btn:hover {
  background: rgba(255,255,255,.15);
  border-color: rgba(255,255,255,.25);
  color: #ffffff;
}
.footer-social-wa:hover { background: #25D366; border-color: #25D366; color: #ffffff; }

/* WhatsApp CTA button */
.footer-wa-btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: #25D366; color: #ffffff;
  padding: 10px 18px; border-radius: var(--radius);
  font-size: .82rem; font-weight: 600;
  letter-spacing: .04em; transition: background var(--t), transform var(--t);
}
.footer-wa-btn:hover {
  background: #1ebe59; color: #ffffff;
  transform: translateY(-1px);
}

/* Bottom bar */
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.07);
}
.footer-bottom-inner {
  max-width: 1320px; margin: 0 auto;
  padding: 16px 32px;
  display: flex; align-items: center; gap: 12px;
  flex-wrap: wrap;
  font-size: .76rem; color: rgba(255,255,255,.2);
}
.footer-bottom-inner a {
  color: rgba(255,255,255,.3);
  transition: color var(--t);
}
.footer-bottom-inner a:hover { color: rgba(255,255,255,.7); }
.footer-bottom-sep { color: rgba(255,255,255,.1); }

/* Responsive footer */
@media (max-width: 1024px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
}
@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-top { padding: 40px 16px 32px; }
  .footer-bottom-inner { padding: 14px 16px; }
}

/* ── WHATSAPP GUEST BUTTON (not logged in) ──────────────── */
.btn-wa-guest {
  background: var(--surface-2);
  color: var(--text-2) !important;
  border: 1.5px dashed var(--border-2);
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; font-size: .82rem; font-weight: 600;
  letter-spacing: .04em; text-transform: uppercase;
  border-radius: var(--radius); white-space: nowrap;
  transition: background var(--t), border-color var(--t), color var(--t);
  text-decoration: none;
}
.btn-wa-guest:hover {
  background: var(--white);
  border-color: var(--carbon);
  color: var(--carbon) !important;
}
.btn-wa-guest.btn-sm { padding: 7px 12px; font-size: .76rem; }

/* ── WHATSAPP CARD BUTTON (in vehicle cards) ────────────── */
.vehicle-card-foot {
  flex-direction: column;
  gap: 8px !important;
  padding: 16px 20px;
}
.vehicle-card-foot > * { width: 100%; justify-content: center; }

/* Full-width WA card button */
.wa-card-btn {
  display: flex; align-items: center; gap: 10px;
  width: 100%; padding: 10px 16px;
  background: #25D366; color: #fff;
  border: none; cursor: pointer;
  font-family: var(--font-body);
  border-radius: var(--radius);
  transition: background var(--t), transform var(--t);
  text-decoration: none;
}
.wa-card-btn:hover {
  background: #1ebe59; color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(37,211,102,.3);
}
.wa-card-text {
  display: flex; flex-direction: column;
  align-items: flex-start; line-height: 1.2;
  text-align: left;
}
.wa-card-label {
  font-size: .82rem; font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
  color: #fff;
}
.wa-card-sub {
  font-size: .72rem; color: rgba(255,255,255,.75);
  font-weight: 400; text-transform: none; letter-spacing: 0;
}

/* Guest card button */
.wa-card-guest {
  background: var(--surface-2) !important;
  color: var(--text-2) !important;
  border: 1.5px dashed var(--border-2) !important;
  box-shadow: none !important;
}
.wa-card-guest:hover {
  background: var(--white) !important;
  border-color: var(--carbon) !important;
  color: var(--carbon) !important;
  transform: none !important;
}
.wa-card-guest span { color: var(--text-2); font-size: .82rem; font-weight: 600; }

/* ============================================================
   MOBILE RESPONSIVE — Complete overhaul
   Target: 320px – 768px phones
   ============================================================ */

@media (max-width: 768px) {

  /* ── Base ──────────────────────────────────────────────── */
  html { font-size: 15px; }
  body { overflow-x: hidden; }
  .container { padding: 0 16px; }
  .page-body { padding-top: calc(var(--nav-h) + 28px); padding-bottom: 60px; }

  /* ── Navbar ────────────────────────────────────────────── */
  .navbar { height: var(--nav-h); }
  .nav-inner { padding: 0 16px; gap: 0; }
  .nav-brand { font-size: 1.1rem; }
  .nav-main-links { display: none; } /* hidden on mobile, use hamburger */
  .nav-right { gap: 8px; }
  .lang-switch { padding: 0 8px; font-size: .72rem; }
  .user-name { display: none; } /* show only avatar on mobile */
  .user-menu-trigger { padding: 5px 8px 5px 5px; gap: 6px; }
  .user-chevron { display: none; }
  .btn.btn-ghost.btn-sm,
  .btn.btn-dark.btn-sm { padding: 6px 10px; font-size: .76rem; }
  .nav-toggle { display: flex; margin-left: 4px; }

  /* Mobile menu */
  .nav-mobile { position: absolute; top: var(--nav-h); left: 0; right: 0; z-index: 199; }
  .nav-mobile a { padding: 14px 20px; font-size: .92rem; }

  /* User dropdown */
  .user-dropdown { right: -8px; min-width: 200px; }

  /* ── Hero ──────────────────────────────────────────────── */
  .hero { min-height: 85vh; }
  .hero-content { padding: 60px 16px 0; }
  .hero-label { font-size: .68rem; margin-bottom: 16px; }
  .hero-title { font-size: clamp(2.8rem, 13vw, 5rem); margin-bottom: 20px; }
  .hero-sub { font-size: .9rem; margin-bottom: 28px; }
  .hero-actions { gap: 10px; }
  .hero-actions .btn { padding: 11px 20px; font-size: .8rem; }

  /* Hero stats — 2 columns */
  .hero-stats-inner {
    grid-template-columns: 1fr 1fr;
    padding: 0;
  }
  .hero-stat {
    padding: 18px 14px;
    border-right: 1px solid rgba(255,255,255,.08);
    border-bottom: 1px solid rgba(255,255,255,.08);
  }
  .hero-stat:nth-child(2n) { border-right: none; }
  .hero-stat:nth-child(3),
  .hero-stat:nth-child(4) { border-bottom: none; }
  .hero-stat-num { font-size: 2rem; }
  .hero-stat-label { font-size: .66rem; }

  /* ── Section headings ──────────────────────────────────── */
  .section-head { margin-bottom: 24px; }
  .section-title { font-size: clamp(1.8rem, 8vw, 2.8rem); }
  .section-head .btn { font-size: .76rem; padding: 8px 14px; }

  /* ── Filter bar ────────────────────────────────────────── */
  .filter-bar {
    flex-direction: column;
    padding: 14px 16px;
    gap: 10px;
    margin-bottom: 20px;
  }
  .filter-bar input,
  .filter-bar select { min-width: unset; width: 100%; }
  .filter-bar label { display: none; }

  /* ── Vehicle grid ──────────────────────────────────────── */
  .vehicle-grid { grid-template-columns: 1fr; gap: 1px; }
  .vehicle-card-img { height: 200px; }
  .vehicle-card-name { font-size: 1.2rem; }
  .vehicle-card-price { font-size: 1.6rem; }
  .vehicle-card-foot { padding: 12px 16px; gap: 8px; }
  .vehicle-card-body { padding: 16px; }
  .vehicle-card-specs { gap: 10px; }

  /* WA card button */
  .wa-card-btn { padding: 10px 14px; }
  .wa-card-label { font-size: .78rem; }

  /* ── Vehicle detail ────────────────────────────────────── */
  .detail-layout { grid-template-columns: 1fr; gap: 20px; }
  .detail-sidebar { position: static; }
  .detail-sidebar-header { padding: 20px; }
  .detail-price { font-size: 2.4rem; }
  .detail-sidebar-body { padding: 20px; }
  .detail-specs-grid { grid-template-columns: 1fr 1fr; }

  /* Financial summary grid in detail */
  .detail-layout > div > div[style*="grid-template-columns:repeat(4"] {
    grid-template-columns: 1fr 1fr !important;
  }

  /* ── Forms ─────────────────────────────────────────────── */
  .form-page { padding: calc(var(--nav-h) + 20px) 16px 40px; }
  .form-card { max-width: 100%; }
  .form-card-header { padding: 24px 20px; }
  .form-card-header h2 { font-size: 1.8rem; }
  .form-card-body { padding: 24px 20px; }
  .form-row { grid-template-columns: 1fr; gap: 0; }
  .btn-full { padding: 13px; }

  /* ── Admin layout ──────────────────────────────────────── */
  .admin-layout { flex-direction: column; }
  .admin-sidebar {
    width: 100%; height: auto;
    position: static;
    padding: 12px 0;
  }
  .sidebar-nav {
    display: flex; flex-wrap: wrap;
    padding: 0 8px; gap: 4px;
  }
  .sidebar-nav a {
    border-left: none;
    border-bottom: 2px solid transparent;
    padding: 8px 12px;
    font-size: .76rem;
    border-radius: var(--radius);
    background: rgba(255,255,255,.04);
  }
  .sidebar-nav a.active {
    border-bottom-color: var(--red);
    border-left: none;
    background: rgba(255,255,255,.08);
  }
  .sidebar-title { padding: 8px 16px 4px; font-size: .62rem; }
  .admin-main { padding: 20px 16px 60px; }
  .admin-page-title h1 { font-size: 1.8rem; }
  .admin-page-title { margin-bottom: 20px; }

  /* KPI grid — 2 cols on mobile */
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 1px; }
  .kpi-value { font-size: 1.8rem; }

  /* Data table scroll */
  .data-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .data-table { min-width: 560px; }
  .data-table th, .data-table td { padding: 10px 12px; font-size: .82rem; }

  /* ── Modals ────────────────────────────────────────────── */
  .modal-overlay { padding: 12px; align-items: flex-end; }
  .modal {
    max-height: 92vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
  .modal-head { padding: 16px 20px; }
  .modal-body { padding: 20px; }
  .modal-foot { padding: 14px 20px; }

  /* WA modal */
  .wa-vehicle-badge { font-size: .82rem; }
  .form-row.wa-row { grid-template-columns: 1fr; }

  /* ── Contact page ──────────────────────────────────────── */
  .contact-page-grid,
  div[style*="grid-template-columns:1fr 400px"] {
    grid-template-columns: 1fr !important;
  }
  .contact-card { padding: 18px; }

  /* ── Footer ────────────────────────────────────────────── */
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-top { padding: 32px 16px 24px; }
  .footer-brand { font-size: 1.3rem; }
  .footer-bottom-inner { padding: 14px 16px; flex-wrap: wrap; gap: 8px; }

  /* ── Settings ──────────────────────────────────────────── */
  .settings-row { grid-template-columns: 1fr; gap: 6px; }
  .settings-label { padding-top: 0; }
  .settings-group-body { padding: 14px; }

  /* ── Floating WA button ────────────────────────────────── */
  .wa-float { bottom: 16px; right: 16px; width: 48px; height: 48px; }
  .wa-float svg { width: 22px; height: 22px; }

  /* ── Reports financial grid ────────────────────────────── */
  div[style*="grid-template-columns:repeat(6"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
  div[style*="grid-template-columns:repeat(4"] {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

/* ── Very small screens (320px) ────────────────────────── */
@media (max-width: 380px) {
  .hero-title { font-size: clamp(2.2rem, 12vw, 3.5rem); }
  .nav-brand { font-size: 1rem; }
  .kpi-grid { grid-template-columns: 1fr; }
  .detail-specs-grid { grid-template-columns: 1fr; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
}

/* ── Tablet (768px – 1024px) ───────────────────────────── */
@media (min-width: 769px) and (max-width: 1024px) {
  .vehicle-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: clamp(3rem, 7vw, 6rem); }
  .admin-main { padding: 28px 24px 60px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .detail-layout { grid-template-columns: 1fr 340px; }
}

/* ── Hamburger animation ────────────────────────────────── */
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── Touch improvements ─────────────────────────────────── */
@media (hover: none) {
  .vehicle-card:hover { transform: none; box-shadow: none; }
  .btn:hover { transform: none; }
  .btn-primary:hover { box-shadow: none; }
  .btn-wa:hover { transform: none; box-shadow: none; }
}

/* Prevent horizontal scroll globally */
html, body { max-width: 100%; overflow-x: hidden; }

/* ── CAROUSEL FULLSCREEN / LIGHTBOX ─────────────────────── */
.carousel-slide img { cursor: zoom-in; }
.carousel-slide video { cursor: default; }

/* Lightbox overlay */
.lightbox {
  display: none;
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(0,0,0,.95);
  align-items: center; justify-content: center;
  cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 95vw; max-height: 95vh;
  object-fit: contain;
  box-shadow: 0 0 80px rgba(0,0,0,.8);
  animation: lightboxIn .2s ease;
}
@keyframes lightboxIn {
  from { opacity: 0; transform: scale(.95); }
}
.lightbox-close {
  position: absolute; top: 20px; right: 24px;
  background: none; border: none; color: #fff;
  font-size: 2rem; cursor: pointer; opacity: .7;
  transition: opacity .2s; line-height: 1;
}
.lightbox-close:hover { opacity: 1; }
.lightbox-prev,
.lightbox-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.12); border: none;
  color: #fff; font-size: 1.8rem; cursor: pointer;
  width: 50px; height: 50px;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s;
}
.lightbox-prev:hover,
.lightbox-next:hover { background: rgba(255,255,255,.25); }
.lightbox-prev { left: 16px; }
.lightbox-next { right: 16px; }
.lightbox-counter {
  position: absolute; bottom: 20px; left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,.5); font-size: .82rem;
  letter-spacing: .08em;
}

/* ── THEME TRANSITION smooth ────────────────────────────── */
body, .navbar, .site-footer, .vehicle-card,
.kpi-card, .data-table-wrap, .modal, .form-card,
.admin-sidebar, .admin-main, .settings-group,
.filter-bar, .contact-card, .detail-sidebar {
  transition: background var(--t), color var(--t), border-color var(--t);
}

/* Light mode admin sidebar fix */
:root:not([data-theme="dark"]) .admin-sidebar {
  background: #1e1e26;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .admin-sidebar { background: #1e1e26; }
}

/* ============================================================
   DARK MODE FIXES — Admin panel detail corrections
   ============================================================ */

/* ── Table header ───────────────────────────────────────── */
[data-theme="dark"] .data-table th {
  background: #0a0a10;
  color: rgba(255,255,255,.75);
  border-bottom: 1px solid #3a3a4a;
}
[data-theme="dark"] .data-table td {
  border-color: #2a2a35;
  color: var(--text);
}
[data-theme="dark"] .data-table-wrap {
  border-color: #2a2a35;
}

/* ── KPI cards ──────────────────────────────────────────── */
[data-theme="dark"] .kpi-grid {
  background: #2a2a35;
  border-color: #2a2a35;
}
[data-theme="dark"] .kpi-card {
  background: #1e1e28;
  border: none;
}
[data-theme="dark"] .kpi-card:hover { background: #252530; }
[data-theme="dark"] .kpi-label { color: #6a6a78; }

/* ── Buttons in dark mode ───────────────────────────────── */
[data-theme="dark"] .btn-ghost {
  background: #26262f;
  border-color: #3a3a48;
  color: #c0bdb5;
}
[data-theme="dark"] .btn-ghost:hover {
  background: #32323e;
  border-color: #4a4a5a;
  color: #f0ede8;
}
[data-theme="dark"] .btn-dark {
  background: #f0ede8;
  color: #141414;
}
[data-theme="dark"] .btn-dark:hover {
  background: #ffffff;
  color: #141414;
}
/* Edit vehicle button specifically */
[data-theme="dark"] .data-table .btn-ghost {
  background: #2e2e3e;
  border: 1px solid #4a4a5e;
  color: #d0cdc5;
  font-weight: 600;
}
[data-theme="dark"] .data-table .btn-ghost:hover {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* ── Admin sidebar active item ──────────────────────────── */
[data-theme="dark"] .sidebar-nav a {
  color: rgba(255,255,255,.5);
}
[data-theme="dark"] .sidebar-nav a:hover {
  background: rgba(255,255,255,.07);
  color: rgba(255,255,255,.9);
}
[data-theme="dark"] .sidebar-nav a.active {
  background: rgba(var(--red), .15);
  color: #fff;
  border-left-color: var(--red);
}

/* ── Admin main background ──────────────────────────────── */
[data-theme="dark"] .admin-main { background: #13131a; }
[data-theme="dark"] .admin-layout { background: #13131a; }

/* ── Page body ──────────────────────────────────────────── */
[data-theme="dark"] body { background: #13131a; }

/* ── Section labels ─────────────────────────────────────── */
[data-theme="dark"] .admin-page-title h1 { color: #f0ede8; }
[data-theme="dark"] .admin-page-title p  { color: #6a6a78; }

/* ── Data table rows ────────────────────────────────────── */
[data-theme="dark"] .data-table tbody tr:hover td {
  background: #22222c;
}

/* ── Vehicle card in dark mode ──────────────────────────── */
[data-theme="dark"] .vehicle-card {
  background: #1e1e28;
  border-color: #2a2a38;
}
[data-theme="dark"] .vehicle-card-foot {
  background: #171720;
  border-color: #2a2a38;
}
[data-theme="dark"] .vehicle-card:hover {
  border-color: var(--red);
}
[data-theme="dark"] .vehicle-card-name { color: #f0ede8; }
[data-theme="dark"] .vehicle-card-price { color: #f0ede8; }
[data-theme="dark"] .vehicle-grid {
  background: #2a2a35;
}

/* ── Filter bar ─────────────────────────────────────────── */
[data-theme="dark"] .filter-bar {
  background: #1e1e28;
  border-color: #2a2a38;
}

/* ── Navbar dark mode ───────────────────────────────────── */
[data-theme="dark"] .navbar {
  background: rgba(13,13,20,.96) !important;
  border-color: #2a2a38 !important;
}
[data-theme="dark"] .nav-main-links li a { color: rgba(255,255,255,.5); }
[data-theme="dark"] .nav-main-links li a:hover { color: rgba(255,255,255,.9); }
[data-theme="dark"] .user-menu-trigger {
  border-color: #3a3a48;
  background: #1e1e28;
}
[data-theme="dark"] .user-menu-trigger:hover { background: #26262f; }
[data-theme="dark"] .user-name { color: #d0cdc5; }
[data-theme="dark"] .user-dropdown {
  background: #1e1e28;
  border-color: #3a3a48;
}
[data-theme="dark"] .dropdown-header { background: #13131a; border-color: #2a2a38; }
[data-theme="dark"] .dropdown-item { color: rgba(255,255,255,.55); }
[data-theme="dark"] .dropdown-item:hover { background: #26262f; color: #fff; }
[data-theme="dark"] .dropdown-divider { background: #2a2a38; }

/* ── Forms dark mode ────────────────────────────────────── */
[data-theme="dark"] .form-card { background: #1e1e28; border-color: #2a2a38; }
[data-theme="dark"] .form-group label { color: #8a8780; }
[data-theme="dark"] .form-hint { color: #5a5760; }

/* ── Settings dark ──────────────────────────────────────── */
[data-theme="dark"] .settings-group { background: #1e1e28; border-color: #2a2a38; }
[data-theme="dark"] .settings-group-header { background: #0a0a10; }
[data-theme="dark"] .settings-row { border-color: #2a2a38; }

/* ── Badges bright in dark mode ─────────────────────────── */
[data-theme="dark"] .badge-disponible,
[data-theme="dark"] .status-disponible { background: #0d2b1a; color: #4ade80; }
[data-theme="dark"] .badge-vendido,
[data-theme="dark"] .status-vendido    { background: #2a0d0a; color: #f87171; }
[data-theme="dark"] .badge-reservado,
[data-theme="dark"] .status-reservado  { background: #2a1a00; color: #fbbf24; }
[data-theme="dark"] .ribbon-disponible { background: #15803d; }
[data-theme="dark"] .ribbon-vendido    { background: #dc2626; }
[data-theme="dark"] .ribbon-reservado  { background: #d97706; }

/* ── CONTACT PAGE DARK MODE FIXES ──────────────────────── */
:root { --contact-cta-bg: #141414; }
[data-theme="dark"] { --contact-cta-bg: #0a0a10; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --contact-cta-bg: #0a0a10; }
}

/* Contact cards dark mode */
[data-theme="dark"] .contact-card {
  background: #1e1e28;
  border-color: #2a2a38;
}
[data-theme="dark"] .contact-card:hover {
  border-color: #3a3a4a;
}
[data-theme="dark"] .contact-card-value { color: #f0ede8; }
[data-theme="dark"] a.contact-card-value:hover { color: var(--red); }
[data-theme="dark"] .contact-card-label { color: #5a5760; }
[data-theme="dark"] .contact-card-wa {
  border-left-color: #25D366;
}

/* Social buttons dark */
[data-theme="dark"] .social-btn {
  background: #1e1e28;
  border-color: #2a2a38;
  color: #a0a0a8;
}
[data-theme="dark"] .social-btn:hover { background: #26262f; }

/* Fix "Listo para empezar" color in contact CTA */
[data-theme="dark"] .contact-page-grid div[style*="contact-cta-bg"],
[data-theme="dark"] div[style*="contact-cta-bg"] {
  background: #0a0a10 !important;
}

/* ── CONTACT CTA CARD — matches other cards ─────────────── */
.contact-cta-card {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  padding: 32px;
  position: sticky;
  top: calc(var(--nav-h) + 24px);
}
[data-theme="dark"] .contact-cta-card {
  background: #1e1e28;
  border-color: #2a2a38;
}

/* ── ADMIN SIDEBAR THEME-AWARE ──────────────────────────── */

/* Dark mode sidebar */
[data-theme="dark"] .admin-sidebar {
  background: #0d0d12 !important;
  border-right: 1px solid #1e1e28 !important;
}
[data-theme="dark"] .sidebar-title { color: rgba(255,255,255,.2) !important; }
[data-theme="dark"] .sidebar-nav a { color: rgba(255,255,255,.45) !important; }
[data-theme="dark"] .sidebar-nav a:hover { color: rgba(255,255,255,.85) !important; background: rgba(255,255,255,.05) !important; }
[data-theme="dark"] .sidebar-nav a.active { color: #fff !important; border-left-color: var(--red) !important; background: rgba(255,255,255,.07) !important; }

/* Light mode sidebar — white like other cards */
[data-theme="light"] .admin-sidebar {
  background: var(--surface) !important;
  border-right: 1px solid var(--border) !important;
}
[data-theme="light"] .sidebar-title { color: var(--text-3) !important; }
[data-theme="light"] .sidebar-nav a { color: var(--text-2) !important; background: transparent !important; }
[data-theme="light"] .sidebar-nav a:hover { color: var(--carbon) !important; background: var(--off-white) !important; }
[data-theme="light"] .sidebar-nav a.active {
  color: var(--red) !important;
  background: #fdf0ef !important;
  border-left-color: var(--red) !important;
}
[data-theme="light"] .sidebar-badge { background: var(--red) !important; color: #fff !important; }

/* System preference fallback (before JS sets data-theme) */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .admin-sidebar {
    background: var(--surface) !important;
    border-right: 1px solid var(--border) !important;
  }
  :root:not([data-theme="dark"]) .sidebar-nav a { color: var(--text-2) !important; }
  :root:not([data-theme="dark"]) .sidebar-nav a.active { color: var(--red) !important; background: #fdf0ef !important; border-left-color: var(--red) !important; }
}

/* ── SIDEBAR TEXT CONTRAST — garantizado legible ────────── */

/* DARK MODE sidebar */
[data-theme="dark"] .admin-sidebar * { transition: color .2s, background .2s; }
[data-theme="dark"] .sidebar-title {
  color: rgba(255,255,255,.35) !important;
  letter-spacing: .18em;
}
[data-theme="dark"] .sidebar-nav a {
  color: rgba(255,255,255,.6) !important;
}
[data-theme="dark"] .sidebar-nav a:hover {
  color: #ffffff !important;
  background: rgba(255,255,255,.07) !important;
}
[data-theme="dark"] .sidebar-nav a.active {
  color: #ffffff !important;
  background: rgba(217,48,37,.15) !important;
  border-left-color: var(--red) !important;
}
[data-theme="dark"] .sidebar-icon { opacity: .85; }
[data-theme="dark"] .sidebar-badge {
  background: var(--red) !important;
  color: #ffffff !important;
}

/* LIGHT MODE sidebar */
[data-theme="light"] .admin-sidebar * { transition: color .2s, background .2s; }
[data-theme="light"] .sidebar-title {
  color: #9e9b94 !important;
}
[data-theme="light"] .sidebar-nav a {
  color: #5a5650 !important;
  border-left-color: transparent !important;
}
[data-theme="light"] .sidebar-nav a:hover {
  color: #141414 !important;
  background: #f0eeeb !important;
}
[data-theme="light"] .sidebar-nav a.active {
  color: var(--red) !important;
  background: #fdf0ef !important;
  border-left-color: var(--red) !important;
  font-weight: 600;
}
[data-theme="light"] .sidebar-icon { opacity: .7; }
[data-theme="light"] .sidebar-badge {
  background: var(--red) !important;
  color: #ffffff !important;
}

/* SYSTEM PREFERENCE fallback for light */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .sidebar-nav a {
    color: #5a5650 !important;
  }
  :root:not([data-theme="dark"]) .sidebar-nav a:hover {
    color: #141414 !important;
    background: #f0eeeb !important;
  }
  :root:not([data-theme="dark"]) .sidebar-nav a.active {
    color: var(--red) !important;
    background: #fdf0ef !important;
    border-left-color: var(--red) !important;
  }
}

/* ── SETTINGS PAGE DARK MODE FIXES ─────────────────────── */
[data-theme="dark"] .settings-group-header {
  background: #0a0a12 !important;
}
[data-theme="dark"] .settings-group-header h3 {
  color: #ffffff !important;
}
[data-theme="dark"] .settings-group-header span {
  opacity: 1 !important;
}
[data-theme="dark"] .settings-label {
  color: #c0bcb4 !important;
}
[data-theme="dark"] .settings-label small {
  color: #6a6770 !important;
}
[data-theme="dark"] .settings-row {
  border-color: #2a2a38 !important;
}
[data-theme="dark"] .settings-group-body {
  background: #1a1a24 !important;
}
[data-theme="dark"] .settings-group {
  border-color: #2a2a38 !important;
}
[data-theme="dark"] .settings-row input,
[data-theme="dark"] .settings-row textarea,
[data-theme="dark"] .settings-row select {
  background: #26262f !important;
  border-color: #3a3a48 !important;
  color: #f0ede8 !important;
}
[data-theme="dark"] .settings-row input:focus,
[data-theme="dark"] .settings-row textarea:focus {
  border-color: var(--red) !important;
  background: #2e2e3a !important;
}
[data-theme="dark"] .form-hint {
  color: #5a5770 !important;
}

/* ── FOOTER FULLY THEME-SYNCED ──────────────────────────── */

/* Light mode footer */
[data-theme="light"] .site-footer {
  background: #f0eeeb !important;
  border-top: 1px solid #e2e0db;
}
[data-theme="light"] .footer-col-brand .footer-brand { color: #141414 !important; }
[data-theme="light"] .footer-tagline { color: #5a5650 !important; }
[data-theme="light"] .footer-copy { color: #9e9b94 !important; }
[data-theme="light"] .footer-col-title {
  color: #9e9b94 !important;
  border-color: #e2e0db !important;
}
[data-theme="light"] .footer-nav a { color: #5a5650 !important; }
[data-theme="light"] .footer-nav a::before { color: #ccc9c2 !important; }
[data-theme="light"] .footer-nav a:hover { color: #141414 !important; }
[data-theme="light"] .footer-contact-list li { color: #5a5650 !important; }
[data-theme="light"] .footer-contact-list a { color: #5a5650 !important; }
[data-theme="light"] .footer-contact-list a:hover { color: #141414 !important; }
[data-theme="light"] .footer-social-btn {
  background: #e2e0db !important;
  border-color: #ccc9c2 !important;
  color: #5a5650 !important;
}
[data-theme="light"] .footer-social-btn:hover {
  background: #141414 !important;
  color: #fff !important;
  border-color: #141414 !important;
}
[data-theme="light"] .footer-bottom {
  border-color: #e2e0db !important;
  background: #e8e5e0;
}
[data-theme="light"] .footer-bottom-inner { color: #9e9b94 !important; }
[data-theme="light"] .footer-bottom-inner a { color: #5a5650 !important; }
[data-theme="light"] .footer-bottom-inner a:hover { color: #141414 !important; }
[data-theme="light"] .footer-bottom-sep { color: #ccc9c2 !important; }

/* Dark mode footer */
[data-theme="dark"] .site-footer {
  background: #0a0a12 !important;
  border-top: 1px solid #1e1e28;
}
[data-theme="dark"] .footer-bottom { background: #060608; border-color: #1e1e28 !important; }
[data-theme="dark"] .footer-bottom-inner { color: rgba(255,255,255,.2) !important; }
[data-theme="dark"] .footer-bottom-inner a { color: rgba(255,255,255,.35) !important; }
[data-theme="dark"] .footer-bottom-inner a:hover { color: rgba(255,255,255,.8) !important; }

/* System preference fallback */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .site-footer {
    background: #f0eeeb !important;
    border-top: 1px solid #e2e0db;
  }
  :root:not([data-theme="dark"]) .footer-col-brand .footer-brand { color: #141414 !important; }
  :root:not([data-theme="dark"]) .footer-tagline { color: #5a5650 !important; }
  :root:not([data-theme="dark"]) .footer-col-title { color: #9e9b94 !important; border-color: #e2e0db !important; }
  :root:not([data-theme="dark"]) .footer-nav a { color: #5a5650 !important; }
  :root:not([data-theme="dark"]) .footer-nav a:hover { color: #141414 !important; }
  :root:not([data-theme="dark"]) .footer-contact-list li,
  :root:not([data-theme="dark"]) .footer-contact-list a { color: #5a5650 !important; }
  :root:not([data-theme="dark"]) .footer-bottom { background: #e8e5e0; border-color: #e2e0db !important; }
  :root:not([data-theme="dark"]) .footer-bottom-inner { color: #9e9b94 !important; }
  :root:not([data-theme="dark"]) .footer-bottom-inner a { color: #5a5650 !important; }
}

/* ── FOOTER CONTACT ICONS LIGHT MODE ───────────────────── */
[data-theme="light"] .footer-contact-icon { opacity: 1 !important; }
[data-theme="light"] .footer-contact-list li svg { opacity: .7; }

/* Fix footer emoji icons visibility in light mode */
[data-theme="light"] .footer-contact-list .footer-contact-icon {
  filter: none !important;
}

/* ── HERO TITLE CONTRAST — dark mode ───────────────────── */
/* Make ENCUENTRA TU PRÓXIMO always visible regardless of bg image */
.hero-title {
  text-shadow: 0 2px 20px rgba(0,0,0,.8), 0 0 60px rgba(0,0,0,.6);
  position: relative;
  z-index: 2;
}
/* In dark mode with bg image, boost contrast even more */
[data-theme="dark"] .hero-title {
  color: #ffffff !important;
  text-shadow:
    2px 2px 0 rgba(0,0,0,.9),
    0 4px 30px rgba(0,0,0,.95),
    0 0 80px rgba(0,0,0,.8) !important;
}
[data-theme="dark"] .hero-title .line-red {
  color: var(--red) !important;
  text-shadow:
    0 0 30px rgba(217,48,37,.5),
    2px 2px 0 rgba(0,0,0,.9) !important;
}

/* Hero overlay stronger in dark mode */
[data-theme="dark"] .hero > div:first-child > div:last-child {
  background: linear-gradient(135deg,
    rgba(0,0,0,.92) 0%,
    rgba(0,0,0,.75) 50%,
    rgba(0,0,0,.5) 100%) !important;
}

/* Hero label and sub also need contrast */
[data-theme="dark"] .hero-label {
  color: rgba(255,255,255,.7) !important;
  text-shadow: 0 1px 8px rgba(0,0,0,.9);
}
[data-theme="dark"] .hero-sub {
  color: rgba(255,255,255,.75) !important;
  text-shadow: 0 1px 8px rgba(0,0,0,.9);
}

/* Light mode hero text also needs shadow when bg image is set */
.hero-label { text-shadow: 0 1px 8px rgba(0,0,0,.5); }
.hero-sub { text-shadow: 0 1px 8px rgba(0,0,0,.5); }

/* ── HERO TITLE — fuerza visibilidad total ──────────────── */
.hero-title,
.hero-title span,
.hero-title .line-red {
  position: relative;
  z-index: 3;
}
.hero-title {
  -webkit-text-stroke: 0 !important;
  paint-order: stroke fill;
}
/* Stroke negro detrás de cada letra */
[data-theme="dark"] .hero-title {
  color: #ffffff !important;
  -webkit-text-stroke: 2px rgba(0,0,0,.8);
  text-shadow:
    -1px -1px 0 rgba(0,0,0,.9),
     1px -1px 0 rgba(0,0,0,.9),
    -1px  1px 0 rgba(0,0,0,.9),
     1px  1px 0 rgba(0,0,0,.9),
     0    4px 20px rgba(0,0,0,1),
     0    0   60px rgba(0,0,0,.9) !important;
}
[data-theme="dark"] .hero-title .line-red {
  color: var(--red) !important;
  -webkit-text-stroke: 2px rgba(0,0,0,.7);
}
/* Forzar que "ENCUENTRA" también sea visible */
[data-theme="dark"] .hero-content h1 { color: #ffffff !important; }

/* Hero dark mode ::before — disabled when carousel exists */
[data-theme="dark"] .hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 0;
  pointer-events: none;
}
[data-theme="dark"] .hero:has(.hero-carousel-bg)::before { display: none !important; }

/* ── VER DETALLES botón dark mode ───────────────────────── */
[data-theme="dark"] .btn-dark {
  background: #f0ede8 !important;
  color: #141414 !important;
  border-color: #f0ede8 !important;
}
[data-theme="dark"] .btn-dark:hover {
  background: #ffffff !important;
  color: #141414 !important;
}
/* Específicamente en tarjetas de vehículos */
[data-theme="dark"] .vehicle-card-foot .btn-dark {
  background: #ffffff !important;
  color: #141414 !important;
  font-weight: 700;
}
[data-theme="dark"] .vehicle-card-foot .btn-dark:hover {
  background: #f0ede8 !important;
}

/* ── FOOTER iconos visibles en claro ────────────────────── */
[data-theme="light"] .footer-contact-icon,
[data-theme="light"] .footer-contact-list .footer-contact-icon {
  opacity: 1 !important;
  filter: none !important;
}

/* ── THEME TOGGLE button mejor estilo ──────────────────── */
.theme-toggle {
  background: var(--surface-2) !important;
  border: 1px solid var(--border) !important;
  color: var(--text-2) !important;
  width: 36px !important;
  height: 36px !important;
  border-radius: 50% !important;
  font-size: 1.1rem !important;
}
.theme-toggle:hover {
  background: var(--border) !important;
  transform: rotate(15deg);
  transition: transform .3s ease;
}

/* ── HERO STATS — siempre visibles ─────────────────────── */
.hero-stat-num {
  text-shadow: 0 2px 10px rgba(0,0,0,.8), 0 0 30px rgba(0,0,0,.6) !important;
  color: #ffffff !important;
}
.hero-stat-num span { color: inherit; }
.hero-stat-label {
  color: rgba(255,255,255,.75) !important;
  text-shadow: 0 1px 6px rgba(0,0,0,.8) !important;
}
.hero-stats {
  position: relative;
  z-index: 3;
}
.hero-stat {
  position: relative;
  background: rgba(0,0,0,.45) !important;
  backdrop-filter: blur(4px);
}
[data-theme="light"] .hero-stat {
  background: rgba(0,0,0,.5) !important;
}

/* ── FOOTER "Escríbenos..." texto en modo claro ─────────── */
[data-theme="light"] .footer-col p,
[data-theme="light"] .footer-col span,
[data-theme="light"] .footer-col div {
  color: #5a5650;
}
/* El texto específico de la columna CTA */
[data-theme="light"] .footer-col:last-child p {
  color: #5a5650 !important;
}
[data-theme="light"] .footer-col:last-child > p {
  color: #5a5650 !important;
}
/* Selector directo para el párrafo del footer CTA */
[data-theme="light"] .footer-grid .footer-col > p[style] {
  color: #5a5650 !important;
}

/* Footer CTA text adapts to theme */
.footer-cta-text { color: rgba(255,255,255,.45); }
[data-theme="light"] .footer-cta-text { color: #5a5650 !important; }
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) .footer-cta-text { color: #5a5650 !important; }
}

/* ── HERO BACKGROUND CAROUSEL ───────────────────────────── */
.hero-carousel-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  z-index: 0;
  transition: opacity 1.2s ease-in-out;
}
.hero-slide:first-child { opacity: 1; z-index: 1; }
.hero-slide.active      { opacity: 1; z-index: 1; }
.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 3; /* above slides */
  pointer-events: none;
  background: linear-gradient(
    135deg,
    rgba(0,0,0,.65) 0%,
    rgba(0,0,0,.45) 50%,
    rgba(0,0,0,.30) 100%
  );
}
/* Carousel dots */
.hero-dots {
  position: absolute;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 4;
}
.hero-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.35);
  border: none; cursor: pointer;
  transition: background .3s, transform .3s;
  padding: 0;
}
.hero-dot.active {
  background: #ffffff;
  transform: scale(1.3);
}

/* ── HERO DARK MODE — garantiza visibilidad ─────────────── */

/* Dark mode hero — only show dark bg when NO carousel image */
.hero-no-img[data-theme="dark"],
[data-theme="dark"] .hero.hero-no-img {
  background: linear-gradient(135deg, #0a0a14 0%, #141420 60%, #0d0d18 100%);
}

/* Dark mode overlay — slightly lighter so image shows through */
[data-theme="dark"] .hero-overlay {
  background: linear-gradient(
    135deg,
    rgba(0,0,0,.70) 0%,
    rgba(0,0,0,.50) 50%,
    rgba(0,0,0,.35) 100%
  ) !important;
}

/* Hero content always above overlay (overlay is z-index:3, so content needs 4+) */
.hero-content { z-index: 4 !important; }
.hero-stats   { z-index: 4 !important; }
.hero-dots    { z-index: 5 !important; }

/* Hero text always white when there's a bg image */
.hero-carousel-bg ~ * .hero-title,
.hero-carousel-bg ~ .hero-content .hero-title {
  color: #ffffff !important;
}

/* Dark mode default hero text */
[data-theme="dark"] .hero-title { color: #ffffff !important; }
[data-theme="dark"] .hero-label { color: rgba(255,255,255,.6) !important; }
[data-theme="dark"] .hero-sub   { color: rgba(255,255,255,.7) !important; }
[data-theme="dark"] .hero-actions .btn-outline-white {
  border-color: rgba(255,255,255,.5) !important;
  color: #ffffff !important;
}

/* ── HERO IMAGE VISIBILITY FIX ──────────────────────────── */
/* Ensure the carousel background container is always visible */
.hero-carousel-bg { z-index: 1 !important; }
.hero-slide { z-index: 1 !important; }
.hero-slide:first-child,
.hero-slide.active { z-index: 2 !important; opacity: 1 !important; }
.hero-overlay { z-index: 3 !important; pointer-events: none !important; }
.hero-content,
.hero-stats { z-index: 4 !important; }
.hero-dots { z-index: 5 !important; }

/* In dark mode, when there IS a bg image, don't override with dark gradient */
[data-theme="dark"] .hero:not(.hero-no-img) {
  background: #000 !important; /* neutral black behind image */
}
/* Only apply dark gradient bg when NO image */
[data-theme="dark"] .hero.hero-no-img {
  background: linear-gradient(135deg, #0a0a14 0%, #141420 60%, #0d0d18 100%) !important;
}

/* ============================================================
   ░░ NEON HUD SKIN ░░  — capa futurista (añadida al final)
   Re-pinta la UE sobre las variables existentes. No requiere
   cambiar clases. El glow usa --accent-rgb (color dinámico del
   panel admin), así el neón siempre combina con tu marca.
   ============================================================ */

:root {
  --accent-rgb: 217, 48, 37;          /* fallback; el header lo sobreescribe */
  --neon-2: #2de2e6;                  /* cyan secundario constante */
  --neon-2-rgb: 45, 226, 230;
  --glass-blur: blur(18px) saturate(140%);
}

/* ---- Paleta OSCURA "Cockpit" ---- */
:root:not([data-theme="light"]) {
  --bg:        #070a12;
  --off-white: #0c1018;
  --surface:   rgba(20, 28, 44, 0.55);
  --surface-2: rgba(28, 38, 58, 0.45);
  --border:    rgba(var(--accent-rgb), 0.18);
  --border-2:  rgba(var(--accent-rgb), 0.30);
  --text:      #e8eef7;
  --text-2:    #93a1b8;
  --text-3:    #5d6b84;
  --shadow-sm: 0 2px 10px rgba(0,0,0,.4);
  --shadow-md: 0 8px 30px rgba(0,0,0,.5);
  --shadow-lg: 0 24px 70px rgba(0,0,0,.6);
}

/* ---- Paleta CLARA "Showroom" ---- */
:root[data-theme="light"] {
  --bg:        #eef2f7;
  --off-white: #e6ecf3;
  --surface:   rgba(255, 255, 255, 0.68);
  --surface-2: rgba(255, 255, 255, 0.48);
  --border:    rgba(120, 140, 170, 0.25);
  --border-2:  rgba(var(--accent-rgb), 0.35);
  --text:      #0c1320;
  --text-2:    #54627a;
  --neon-2:    #0099b8;
  --neon-2-rgb: 0, 153, 184;
}

/* ---- Fondo aurora animado + rejilla HUD ---- */
body { position: relative; background: var(--bg); overflow-x: hidden; }
body::before {
  content: ''; position: fixed; inset: -30%; z-index: -2; pointer-events: none;
  background:
    radial-gradient(42% 50% at 16% 20%, rgba(var(--accent-rgb), 0.20), transparent 60%),
    radial-gradient(45% 45% at 84% 16%, rgba(var(--neon-2-rgb), 0.16), transparent 60%),
    radial-gradient(50% 55% at 72% 88%, rgba(var(--accent-rgb), 0.14), transparent 60%),
    radial-gradient(40% 40% at 24% 82%, rgba(var(--neon-2-rgb), 0.12), transparent 60%);
  filter: blur(24px);
  animation: hud-aurora 28s ease-in-out infinite alternate;
}
@keyframes hud-aurora {
  0%   { transform: translate3d(0,0,0) scale(1) rotate(0deg); }
  50%  { transform: translate3d(2%, -2%, 0) scale(1.08) rotate(2deg); }
  100% { transform: translate3d(-2%, 2%, 0) scale(1.04) rotate(-2deg); }
}
body::after {
  content: ''; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(var(--accent-rgb), 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--accent-rgb), 0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 38%, #000 38%, transparent 100%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 38%, #000 38%, transparent 100%);
}
:root[data-theme="light"] body::after {
  background-image:
    linear-gradient(rgba(120,140,170,0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(120,140,170,0.07) 1px, transparent 1px);
}

/* ---- Glassmorphism en superficies clave ---- */
.navbar, .nav-mobile, .vehicle-card, .form-card, .data-table-wrap,
.detail-sidebar, .detail-image-wrap, .modal, .user-dropdown, .contact-card,
.contact-cta-card, .admin-sidebar, .settings-group, .empty-state, .wa-card-btn,
.wa-card-guest, .filter-bar, .hero {
  -webkit-backdrop-filter: var(--glass-blur);
          backdrop-filter: var(--glass-blur);
}

/* ---- Navbar: vidrio + línea neón inferior ---- */
.navbar {
  background: var(--surface) !important;
  border-bottom: 1px solid var(--border) !important;
  position: sticky; top: 0;
}
.navbar::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), .7), rgba(var(--neon-2-rgb), .5), transparent);
}
.nav-brand span {
  background: linear-gradient(120deg, var(--text), var(--red));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.nav-main-links a.active,
.nav-main-links a:hover { color: var(--red); text-shadow: 0 0 14px rgba(var(--accent-rgb), .6); }
.nav-main-links a.active::after,
.nav-main-links a:hover::after {
  box-shadow: 0 0 10px rgba(var(--accent-rgb), .8);
}
.theme-toggle:hover, .nav-toggle:hover { box-shadow: 0 0 16px rgba(var(--accent-rgb), .4); }

/* ---- Tarjetas con glow al pasar el mouse ---- */
.vehicle-card, .form-card, .contact-card, .settings-group, .data-table-wrap {
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  transition: transform .25s cubic-bezier(.4,0,.2,1), box-shadow .25s, border-color .25s;
}
.vehicle-card:hover {
  transform: translateY(-6px);
  border-color: rgba(var(--accent-rgb), .45) !important;
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(var(--accent-rgb), .3), 0 0 40px rgba(var(--accent-rgb), .15);
}
.vehicle-card:hover .vehicle-card-img img { filter: saturate(1.15) contrast(1.03); }

/* ---- Precios y etiquetas con neón ---- */
.vehicle-card-price, .detail-price {
  color: var(--red);
  text-shadow: 0 0 22px rgba(var(--accent-rgb), .55);
  font-family: var(--font-display); letter-spacing: .02em;
}
.hero-label, .section-label, .vehicle-card-price-label, .detail-price-label {
  color: var(--red); letter-spacing: .22em;
}
.section-title, .hero-content h1 { letter-spacing: .01em; }

/* ---- Botones neón ---- */
.btn { position: relative; overflow: hidden; transition: transform .2s, box-shadow .2s, filter .2s; }
.btn::after {
  content: ''; position: absolute; top: 0; left: -120%; width: 100%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.22), transparent);
  transition: left .5s ease;
}
.btn:hover::after { left: 120%; }
.btn-primary, .btn-dark {
  background: linear-gradient(120deg, var(--red), var(--red-dark)) !important;
  color: #fff !important; border: none !important;
  box-shadow: 0 0 20px rgba(var(--accent-rgb), .45);
}
.btn-primary:hover, .btn-dark:hover {
  transform: translateY(-2px); filter: brightness(1.08);
  box-shadow: 0 0 30px rgba(var(--accent-rgb), .6);
}
.btn-outline, .btn-ghost {
  border: 1px solid rgba(var(--accent-rgb), .5) !important;
  color: var(--red) !important; background: transparent !important;
}
.btn-outline:hover, .btn-ghost:hover {
  background: rgba(var(--accent-rgb), .12) !important;
  box-shadow: 0 0 18px rgba(var(--accent-rgb), .35);
}
.btn-wa, .btn-wa-guest, .wa-float, .footer-wa-btn { box-shadow: 0 0 22px rgba(37, 211, 102, .45) !important; }

/* ---- Hero: overlay con gradiente neón + grid ---- */
.hero { border: 1px solid var(--border); border-radius: var(--radius-lg); overflow: hidden; }
.hero-overlay {
  background:
    linear-gradient(120deg, rgba(7,10,18,.78), rgba(7,10,18,.35) 55%, transparent),
    radial-gradient(60% 80% at 80% 30%, rgba(var(--accent-rgb), .18), transparent 60%) !important;
}
.hero-dot.active, .hero-dot:hover { box-shadow: 0 0 12px rgba(var(--accent-rgb), .8); }

/* ---- Inputs con foco neón ---- */
input, select, textarea {
  background: var(--surface-2) !important;
  border: 1px solid var(--border) !important;
  color: var(--text) !important;
  transition: border-color .2s, box-shadow .2s, background .2s;
}
input:focus, select:focus, textarea:focus {
  outline: none !important;
  border-color: var(--red) !important;
  box-shadow: 0 0 0 3px rgba(var(--accent-rgb), .18), 0 0 18px rgba(var(--accent-rgb), .35) !important;
  background: var(--surface) !important;
}

/* ---- Badges / ribbons con glow sutil ---- */
.badge, .spec-pill, .status-ribbon {
  border: 1px solid rgba(var(--accent-rgb), .25);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.badge-disponible, .ribbon-disponible { box-shadow: 0 0 14px rgba(42, 222, 142, .25); }
.badge-vendido, .ribbon-vendido { box-shadow: 0 0 14px rgba(var(--accent-rgb), .2); }

/* ---- Tablas admin ---- */
.data-table thead, .data-table th { background: rgba(var(--accent-rgb), .06); }
.data-table tbody tr:hover { background: rgba(var(--accent-rgb), .07); }

/* ---- Sidebar admin: vidrio + acento ---- */
.admin-sidebar { background: var(--surface) !important; border-right: 1px solid var(--border); }
.sidebar-nav a.active, .sidebar-nav a:hover {
  color: var(--red);
  box-shadow: inset 3px 0 0 var(--red), 0 0 18px rgba(var(--accent-rgb), .15);
}

/* ---- Flash translúcido ---- */
.flash { -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }

/* ---- Footer vidrio + línea superior neón ---- */
.site-footer { position: relative; -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); }
.site-footer::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(var(--accent-rgb), .6), transparent);
}

/* ---- Modales ---- */
.modal { background: var(--surface) !important; border: 1px solid var(--border-2) !important; box-shadow: var(--shadow-lg), 0 0 40px rgba(var(--accent-rgb), .15) !important; }
.modal-overlay { background: rgba(4, 6, 12, .6) !important; -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

/* ---- Entrada animada del contenido ---- */
.page-body, .hero, .container > .section-head { animation: hud-fade .6s ease both; }
@keyframes hud-fade { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* ---- Respeta reduce-motion ---- */
@media (prefers-reduced-motion: reduce) {
  body::before { animation: none; }
  .page-body, .hero, .container > .section-head { animation: none; }
}

/* ---- Fix contraste KPIs en reportes (modo oscuro y claro) ---- */
.kpi-card {
  background: var(--surface) !important;
  border: 1px solid var(--border) !important;
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  border-radius: var(--radius-lg);
}
.kpi-card:hover {
  background: var(--surface) !important;
  border-color: rgba(var(--accent-rgb), .35) !important;
  box-shadow: var(--shadow-md), 0 0 26px rgba(var(--accent-rgb), .12);
}
.kpi-label,
[data-theme="dark"] .kpi-label { color: var(--text-2) !important; }
.kpi-sub  { color: var(--text-2) !important; opacity: .82; }
.kpi-value { color: var(--text) !important; }
.kpi-red  .kpi-value { color: var(--red) !important; }
.kpi-green .kpi-value { color: var(--success) !important; }
