:root{
  --bg:#0b1020;
  --panel:#101a33;
  --muted:#9fb0d0;
  --text:#eef3ff;
  --line:rgba(255,255,255,.10);
  --brand:#35b7ff;
  --brand2:#7c4dff;
  --shadow:0 18px 60px rgba(0,0,0,.45);
  --r:18px;
}

*{
  box-sizing:border-box;
}

html,body{
  height:100%;
}

body{
  margin:0;
  font-family:system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background:
    radial-gradient(900px 520px at 20% 10%, rgba(53,183,255,.14), transparent 60%),
    radial-gradient(900px 520px at 80% 20%, rgba(124,77,255,.12), transparent 60%),
    var(--bg);
  color:var(--text);
}

.container{
  max-width:1100px;
  margin:0 auto;
  padding:0 16px;
}

.topbar{
  position:sticky;
  top:0;
  z-index:100;
  background:rgba(11,16,32,.72);
  backdrop-filter:blur(10px);
  border-bottom:1px solid var(--line);
}

.topbar__inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:14px 0;
}

.brand{
  display:flex;
  align-items:center;
  text-decoration:none;
  color:var(--text);
  flex-shrink:0;
}

.brand__logo-wrap{
  width:220px;
  height:auto;
  display:flex;
  align-items:center;
}

.brand__logo{
  width:100%;
  height:auto;
  display:block;
  object-fit:contain;
  transform:none;
  border-radius:10px;
}

/* navegación */
.nav{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}

.nav__link{
  text-decoration:none;
  color:var(--muted);
  font-weight:700;
  font-size:14px;
  transition:color .2s ease;
}

.nav__link:hover{
  color:var(--text);
}

/* botones */
.btn{
  border:1px solid rgba(255,255,255,.12);
  cursor:pointer;
  color:var(--text);
  padding:10px 14px;
  border-radius:14px;
  font-weight:800;
  text-decoration:none;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  transition:all .2s ease;
}

.btn:hover{
  transform:translateY(-1px);
}

.btn--primary{
  background:linear-gradient(135deg, rgba(53,183,255,.95), rgba(124,77,255,.90));
  box-shadow:0 16px 40px rgba(53,183,255,.18);
}

.btn--secondary{
  background:rgba(255,255,255,.06);
}

.btn--ghost{
  background:transparent;
}

.btn--full{
  width:100%;
}

/* hero */
.hero{
  padding:34px 0 12px;
}

.hero__grid{
  display:grid;
  grid-template-columns:1.2fr .8fr;
  gap:18px;
  align-items:start;
}

.badge{
  display:inline-block;
  padding:8px 12px;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.10);
  color:var(--muted);
  font-weight:800;
  font-size:13px;
}

.hero__title{
  margin:12px 0 8px;
  font-size:44px;
  line-height:1.05;
}

.hero__subtitle{
  margin:0 0 14px;
  color:var(--muted);
  font-size:16px;
  max-width:52ch;
}

.hero__actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-bottom:14px;
}

.hero__stats{
  display:flex;
  gap:14px;
  flex-wrap:wrap;
}

.stat{
  padding:12px 14px;
  border-radius:16px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.10);
  min-width:120px;
}

.stat__num{
  font-weight:900;
  font-size:18px;
}

.stat__label{
  color:var(--muted);
  font-size:12px;
  font-weight:700;
}

.hero__card{
  background:rgba(16,26,51,.70);
  border:1px solid rgba(255,255,255,.10);
  border-radius:var(--r);
  box-shadow:var(--shadow);
  padding:16px;
  backdrop-filter:blur(10px);
}

.card__title{
  margin:0 0 12px;
  font-size:16px;
}

.card__hint{
  margin:10px 0 0;
  color:var(--muted);
  font-size:12px;
  line-height:1.5;
}

.filters{
  display:grid;
  gap:10px;
}

/* campos */
.field{
  display:grid;
  gap:6px;
}

.field__label{
  font-size:12px;
  font-weight:800;
  color:var(--muted);
}

.field__control{
  padding:10px 12px;
  border-radius:14px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(0,0,0,.18);
  color:var(--text);
  outline:none;
  width:100%;
}

.field__control:focus{
  border-color:rgba(53,183,255,.55);
}

/* secciones */
.section{
  padding:26px 0;
}

.section--muted{
  background:rgba(255,255,255,.03);
  border-top:1px solid var(--line);
  border-bottom:1px solid var(--line);
}

.section__head{
  display:flex;
  align-items:end;
  justify-content:space-between;
  gap:12px;
  flex-wrap:wrap;
}

.section__title{
  margin:0 0 6px;
  font-size:26px;
}

.section__subtitle{
  margin:0;
  color:var(--muted);
}

/* búsqueda */
.search{
  display:flex;
  align-items:center;
  gap:8px;
  border-radius:16px;
  padding:10px 12px;
  border:1px solid rgba(255,255,255,.12);
  background:rgba(0,0,0,.16);
  width:min(100%, 360px);
}

.search__icon{
  opacity:.8;
}

.search__input{
  border:0;
  outline:none;
  background:transparent;
  color:var(--text);
  width:100%;
}

/* grid de coches */
.grid{
  margin-top:16px;
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:14px;
}

.card{
  background:rgba(16,26,51,.65);
  border:1px solid rgba(255,255,255,.10);
  border-radius:var(--r);
  box-shadow:var(--shadow);
  overflow:hidden;
  transition:transform .18s ease, border-color .18s ease;
}

.card:hover{
  transform:translateY(-2px);
  border-color:rgba(53,183,255,.25);
}

.card__img{
  height:180px;
  background:
    radial-gradient(240px 120px at 30% 30%, rgba(53,183,255,.22), transparent 60%),
    radial-gradient(240px 120px at 70% 60%, rgba(124,77,255,.18), transparent 60%),
    linear-gradient(135deg, rgba(255,255,255,.06), rgba(255,255,255,0));
  border-bottom:1px solid rgba(255,255,255,.08);
}

.card__body{
  padding:12px;
}

.card__h{
  margin:0 0 4px;
  font-weight:900;
  font-size:18px;
}

.card__p{
  margin:0;
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}

.card__meta{
  margin-top:10px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:8px;
  color:var(--muted);
  font-size:12px;
  font-weight:800;
  flex-wrap:wrap;
}

/* servicios */
.features{
  display:grid;
  grid-template-columns:repeat(3, 1fr);
  gap:14px;
  margin-top:14px;
}

.feature{
  padding:14px;
  border-radius:var(--r);
  background:rgba(16,26,51,.55);
  border:1px solid rgba(255,255,255,.10);
}

.feature__title{
  margin:0 0 6px;
}

.feature__text{
  margin:0;
  color:var(--muted);
  line-height:1.6;
}

/* contacto */
.contact{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:14px;
  align-items:start;
}

.contact__cards{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:10px;
}

.mini{
  padding:12px 14px;
  border-radius:16px;
  background:rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.10);
}

.mini__title{
  font-weight:900;
}

.mini__text{
  color:var(--muted);
  font-size:12px;
  font-weight:800;
}

.contactForm{
  background:rgba(16,26,51,.65);
  border:1px solid rgba(255,255,255,.10);
  border-radius:var(--r);
  box-shadow:var(--shadow);
  padding:14px;
}

/* footer */
.footer{
  border-top:1px solid var(--line);
  padding:16px 0;
  color:var(--muted);
}

.footer__inner{
  display:flex;
  justify-content:space-between;
  gap:10px;
  flex-wrap:wrap;
}

.footer__muted{
  opacity:.9;
}

/* tema claro */
body.light{
  --bg:#eef4ff;
  --panel:#ffffff;
  --muted:#4d5f83;
  --text:#14213d;
  --line:rgba(20,33,61,.10);
  background:
    radial-gradient(900px 520px at 20% 10%, rgba(53,183,255,.12), transparent 60%),
    radial-gradient(900px 520px at 80% 20%, rgba(124,77,255,.10), transparent 60%),
    var(--bg);
}

body.light .topbar{
  background:rgba(255,255,255,.78);
}

body.light .hero__card,
body.light .card,
body.light .feature,
body.light .contactForm,
body.light .mini,
body.light .stat{
  background:rgba(255,255,255,.82);
}

body.light .field__control,
body.light .search{
  background:rgba(255,255,255,.82);
}

/* tablet */
@media (max-width: 920px){
  .hero__grid{
    grid-template-columns:1fr;
  }

  .grid{
    grid-template-columns:repeat(2, 1fr);
  }

  .features{
    grid-template-columns:1fr;
  }

  .contact{
    grid-template-columns:1fr;
  }

  .hero__title{
    font-size:38px;
  }

  .brand__logo-wrap{
    width:180px;
  }
}

/* móvil */
@media (max-width: 640px){
  .topbar__inner{
    flex-direction:column;
    align-items:flex-start;
  }

  .nav{
    width:100%;
    justify-content:space-between;
    gap:10px;
  }

  .hero{
    padding:24px 0 10px;
  }

  .hero__title{
    font-size:32px;
  }

  .hero__subtitle{
    font-size:15px;
  }

  .hero__actions{
    flex-direction:column;
    align-items:stretch;
  }

  .hero__stats{
    flex-direction:column;
  }

  .stat{
    width:100%;
  }

  .grid{
    grid-template-columns:1fr;
  }

  .brand__logo-wrap{
    width:150px;
  }

  .brand__logo{
    transform:none;
  }

  .search{
    width:100%;
  }

  .footer__inner{
    flex-direction:column;
    align-items:flex-start;
  }
}
/* =========================
   TARJETAS DINÁMICAS COCHES
========================= */

.vcard{
  background:rgba(16,26,51,.65);
  border:1px solid rgba(255,255,255,.10);
  border-radius:var(--r);
  box-shadow:var(--shadow);
  overflow:hidden;
  transition:transform .18s ease, border-color .18s ease;
}

.vcard:hover{
  transform:translateY(-2px);
  border-color:rgba(53,183,255,.25);
}

.vcard__media{
  position:relative;
}

.vcard__img{
  width:100%;
  height:220px;
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
  border-bottom:1px solid rgba(255,255,255,.08);
}

.vcard__badge{
  position:absolute;
  top:12px;
  left:12px;
  background:#e53935;
  color:#fff;
  padding:6px 10px;
  border-radius:999px;
  font-size:12px;
  font-weight:800;
  z-index:2;
}

.vcard__nav{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding:0 10px;
  pointer-events:none;
}

.vcard__nav button{
  pointer-events:auto;
  width:34px;
  height:34px;
  border-radius:50%;
  border:1px solid rgba(255,255,255,.18);
  background:rgba(0,0,0,.35);
  color:#fff;
  cursor:pointer;
  font-size:18px;
  font-weight:900;
  backdrop-filter:blur(6px);
}

.vcard__body{
  padding:12px;
}

.vcard__title{
  margin:0 0 6px;
  font-weight:900;
  font-size:18px;
}

.vcard__meta{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  color:var(--muted);
  font-size:12px;
  font-weight:800;
}

.vcard__price{
  margin-top:10px;
  font-size:22px;
  font-weight:900;
}

.vcard__chips{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  margin-top:12px;
}

.chip{
  padding:6px 10px;
  border-radius:999px;
  background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.10);
  color:var(--muted);
  font-size:12px;
  font-weight:700;
}

.vcard__desc{
  margin-top:12px;
  color:var(--muted);
  font-size:13px;
  line-height:1.5;
}

.vcard__actions{
  margin-top:14px;
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}

.vcard__thumbs{
  display:flex;
  gap:8px;
  padding:12px;
  flex-wrap:wrap;
}

.vthumb{
  width:58px;
  height:58px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.10);
  background-size:cover;
  background-position:center;
  background-repeat:no-repeat;
  cursor:pointer;
  opacity:.75;
}

.vthumb.active{
  opacity:1;
  border-color:rgba(53,183,255,.55);
}

@media (max-width: 640px){
  .topbar__inner{
    flex-direction:column;
    align-items:flex-start;
  }

  .nav{
    width:100%;
    justify-content:space-between;
    gap:10px;
  }

  .hero{
    padding:24px 0 10px;
  }

  .hero__title{
    font-size:32px;
  }

  .hero__subtitle{
    font-size:15px;
  }

  .hero__actions{
    flex-direction:column;
    align-items:stretch;
  }

  .hero__stats{
    flex-direction:column;
  }

  .stat{
    width:100%;
  }

  .grid{
    grid-template-columns:1fr;
  }

  .brand__logo-wrap{
    width:150px;
  }

  .brand__logo{
    transform:none;
  }

  .search{
    width:100%;
  }

  .footer__inner{
    flex-direction:column;
    align-items:flex-start;
  }

  .vcard__img{
    height:280px;
  }

  .vthumb{
    width:58px;
    height:58px;
  }

  .back-to-top{
    right:16px;
    bottom:16px;
  }
}

html{
  scroll-behavior:smooth;
}

.back-to-top{
  position:fixed;
  right:20px;
  bottom:20px;
  width:46px;
  height:46px;
  border:none;
  border-radius:50%;
  background:linear-gradient(135deg, rgba(53,183,255,.95), rgba(124,77,255,.90));
  color:#fff;
  font-size:20px;
  font-weight:900;
  cursor:pointer;
  box-shadow:0 12px 30px rgba(0,0,0,.35);
  display:none;
  align-items:center;
  justify-content:center;
  z-index:200;
}

.back-to-top.show{
  display:flex;
}

.back-to-top:hover{
  transform:translateY(-2px);
}
.image-modal{
  position:fixed;
  inset:0;
  background:rgba(0,0,0,.88);
  display:none;
  align-items:center;
  justify-content:center;
  padding:20px;
  z-index:1200;
}

.image-modal.show{
  display:flex;
}

.image-modal__img{
  max-width:100%;
  max-height:90vh;
  width:auto;
  height:auto;
  border-radius:16px;
  box-shadow:0 20px 50px rgba(0,0,0,.45);
}

.image-modal__close{
  position:absolute;
  top:18px;
  right:18px;
  width:42px;
  height:42px;
  border:none;
  border-radius:50%;
  background:rgba(255,255,255,.14);
  color:#fff;
  font-size:28px;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
}