@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@200;300;400;500;700;800;900&family=Share+Tech&family=Chakra+Petch:wght@300;400;500;600;700&display=swap');

/* RESET */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base */
body {
    font-family: 'Tajawal', sans-serif;
    color: #1a1a1a;
    line-height: 1.6;
    background-size: auto, 200px 200px, 150px 150px, auto;
    background-image: linear-gradient(134deg, rgba(1, 1, 1,0.02) 0%, rgba(1, 1, 1,0.02) 16%,transparent 16%, transparent 76%,rgba(58, 58, 58,0.02) 76%, rgba(58, 58, 58,0.02) 100%),linear-gradient(215deg, rgba(166, 166, 166,0.02) 0%, rgba(166, 166, 166,0.02) 33%,transparent 33%, transparent 79%,rgba(111, 111, 111,0.02) 79%, rgba(111, 111, 111,0.02) 100%),linear-gradient(303deg, rgba(215, 215, 215,0.02) 0%, rgba(215, 215, 215,0.02) 7%,transparent 7%, transparent 90%,rgba(192, 192, 192,0.02) 90%, rgba(192, 192, 192,0.02) 100%),linear-gradient(302deg, rgba(113, 113, 113,0.02) 0%, rgba(113, 113, 113,0.02) 34%,transparent 34%, transparent 73%,rgba(65, 65, 65,0.02) 73%, rgba(65, 65, 65,0.02) 100%),linear-gradient(90deg, rgb(255,255,255),rgb(255,255,255));
}

#contenedor_sitio {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0;
}

/* Banner / portada */
.contenedor_banner {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    color: #fff;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
}

.texto_banner, .subtitulo-portada {
    padding: 0 15%;
    font-family: 'Share Tech', sans-serif;
    text-align: center;
}

.texto_banner {
  font-size: 2.4rem;
  font-weight: 600;
  color: #023c65;
  line-height: 58px;
}

.texto_banner-2 {
  font-size: 19px;
  font-weight: 600;
  color: #023c65;
  line-height: 24px;
  background: #f7f7f7;
  margin: 12px;
  border-radius: 10px;
}

.subtitulo-portada {
  font-size: 21px;
  font-weight: 400;
  color: #023153;
  padding-top: 48px;
  line-height: 28px;
}

.botones-portada {
  padding: 11px 0 7px;
}

.buscar-ahora,
.cotizar-unidad {
  width: 120px;
  padding: 13px;
  font-size: 18px;
  border-radius: 8px;
  margin: 0 10px;
  font-family: 'Tajawal', sans-serif;
}

.buscar-ahora {
  background: #085185;
}

.cotizar-unidad {
  background: #eb3b27;
}

/* Header principal + nav */
.main-header {
  border-bottom: none;
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 1000;
}

/* Header flex “viejo” (si lo seguís usando) */
.flex-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  padding: 16px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Logo compartido */
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: bold;
  font-size: 18px;
  color: #222;
}

.logo b {
  font-size: 1.2rem;
  color: #232323;
}

.logo .color-acento {
  color: #eb3c26;
}

.logo small {
  font-size: .75rem;
  color: #888;
}

/* Nav principal (flex-header) */
.nav-main {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.nav-main a,
.nav-main button {
  font-size: 1rem;
  font-weight: 600;
  padding: 6px 10px;
  background: none;
  border: none;
  border-radius: 6px;
  color: #454545;
  transition: color .15s;
}

/* Dropdown genérico */
.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  min-width: 160px;
  z-index: 10;
}

.dropdown:hover .dropdown-content {
  display: block;
}

.dropdown-content a {
  display: block;
  padding: 10px 16px;
  color: #232323;
}

.dropdown-content a:hover {
  background: #f4f4f4;
}

/* Acciones usuario (banderas, botones) */
.user-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.user-actions .flag {
  width: 26px;
  height: 20px;
}




/* Header “nuevo” con top-header + menú */
.top-header {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2px 20px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    background: #f7f7f7;
    border-bottom: 2px solid #cccccc0f;
}

.top-header ul {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin: 0;
  padding: 0;
}

.top-header li,
.top-header li a {
  font-family: system-ui, sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #222;
  text-decoration: none;
  transition: color .3s;
}

.top-header li a:hover {
  color: #ffc20b;
}

/* Menú desktop principal (#menu) */
#menu ul {
  list-style: none;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 30px;
  margin: 0;
  padding: 0;
}

#menu li a {
    background: #ebebeb;
    color: #1c3053;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    padding: 9px 12px;
    cursor: pointer;
    transition: background .2s;
    font-family: 'Tajawal', sans-serif;
    text-transform: uppercase;
    flex: 0 0 auto;
    letter-spacing: .3px;
}

#menu li a:hover {
  color: #ffc20b;
}

/* Hamburguesa */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 3px;
  background: #222;
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}

/* Animación a “X” */
.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.active span:nth-child(2) {
  opacity: 0;
}
.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* Hero / buscador */
.hero,
.search-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  position: relative;
}

.hero {
  min-height: 360px;
  justify-content: center;
  background: #222;
  text-align: center;
  padding: 40px 20px;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background: url('https://images.pexels.com/photos/164634/pexels-photo-164634.jpeg') center/cover no-repeat;
  filter: brightness(0.5);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 600px;
  color: #fff;
  text-align: center;
}

.hero-content h1 {
  font-size: 2.2rem;
  margin-bottom: 16px;
}

.hero-content h2 {
  font-size: 1.3rem;
  margin-bottom: 24px;
  font-weight: 400;
  line-height: 1.4;
}

.search-hero input {
  width: 100%;
  max-width: 400px;
  padding: 12px 18px;
  font-size: 1rem;
  border-radius: 24px;
  border: none;
}

.search-buttons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

.btn-primary,
.btn-tertiary {
  font-weight: 600;
  font-size: 1rem;
  padding: 10px 24px;
  border: none;
  border-radius: 24px;
  transition: all .15s;
  cursor: pointer;
}

.btn-primary {
  background: #eb3c26;
  color: #fff;
}

.btn-primary:hover {
  background: #b92111;
}

.btn-tertiary {
  background: #e4e4e4;
  color: #232323;
}

.btn-tertiary:hover {
  background: #d2d2d2;
}

/* Bloques de vendedores y autos destacados */
.vendedores-destacados,
.destacados-autos-home {
  max-width: 1200px;
  margin: 48px auto 0;
  padding: 0 16px;
}

.vendedores-destacados h3 {
  font-size: 1.3rem;
  font-weight: 700;
  color: #222;
  margin-bottom: 16px;
}

.vendedores-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: flex-start;
}

/* Card vendedor */
.card-vendedor {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
  flex: 1 1 260px;
  min-width: 240px;
  font-size: .95rem;
  color: #6b7280;
}

.vendedor-logo {
  width: 54px;
  height: 54px;
  object-fit: contain;
  border-radius: 10px;
  background: #fafbfc;
  border: 1px solid #ececec;
}

.card-vendedor b {
  font-size: 1.1rem;
  color: #222;
}

.card-vendedor small {
  display: block;
  color: #888;
  margin-top: 4px;
}

/* Listado autos destacados */
.destacados-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.btn-ver-mas {
  background: #e7f0fa;
  color: #1767c8;
  font-weight: 600;
  border-radius: 8px;
  padding: 7px 14px;
  transition: background .15s, color .15s;
}

.btn-ver-mas:hover {
  background: #1767c8;
  color: #fff;
}

.destacado-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(35,41,74,0.07);
  padding: 15px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  max-width: 270px;
  position: relative;
  transition: box-shadow .2s;
}

.destacado-card:hover {
  box-shadow: 0 4px 18px rgba(35,41,74,0.15);
}

.card-foto {
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: 12px;
  object-fit: cover;
  background: #eaf1fa;
  margin-bottom: 10px;
}

.card-info {
  font-size: 1rem;
  margin-bottom: 4px;
}

.card-precio {
  color: #eb3c26;
  font-weight: 700;
  font-size: 1.13rem;
  margin-bottom: 2px;
}

/* Badge destacado (versión unificada pill con estrella) */
.badge-destacado {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #ffc107;
  color: #fff;
  font-weight: bold;
  padding: 4px 8px;
  border-radius: 20px;
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.badge-destacado::before {
  content: "★";
  font-size: 14px;
}

/* Card vehículo hover / estado */
.vehiculo-card {
  animation: fadeInUp .6s ease;
  transition: box-shadow .2s, transform .2s;
  border: 2px solid transparent;
  position: relative;
}

.vehiculo-card:hover {
  box-shadow: 0 7px 32px rgba(103,58,183,0.15);
  border: 2px solid #b39ddb;
  transform: scale(1.035);
  z-index: 3;
}

.vehiculo-card .fa-star {
  color: #dfbb28;
  opacity: .68;
  margin-left: 4px;
  transition: color .2s, transform .2s;
}

.vehiculo-card:hover .fa-star {
  color: #ffd700;
  opacity: 1;
  transform: scale(1.18) rotate(-8deg);
}

/* Badge “nuevo” */
.badge-nuevo {
  background: linear-gradient(90deg,#eb3b27 80%,#ffba00 100%);
  color: #fff;
  font-weight: 800;
  font-size: .89rem;
  border-radius: 8px;
  padding: 2px 12px;
  position: absolute;
  top: 12px;
  right: 12px;
  box-shadow: 0 1.5px 6px rgba(235,59,39,0.2);
  animation: badgePop .95s ease;
}

@keyframes badgePop {
  0% {
    transform: scale(.8) rotate(-16deg);
    opacity: 0;
  }
  60% {
    transform: scale(1.18) rotate(5deg);
  }
  100% {
    transform: scale(1) rotate(0);
    opacity: 1;
  }
}

/* Micro footer */
.micro-footer {
  border-top: 1px solid #eef0f3;
  background: #fafbfd;
  padding: 10px 14px;
}

.micro-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
  font: 600 13.5px 'Tajawal', 'Inter', system-ui, -apple-system, sans-serif;
  color: #0f2742;
  letter-spacing: .2px;
}

.micro-footer .brand {
  text-transform: uppercase;
}

.micro-footer .sep {
  margin: 0 8px;
  opacity: .45;
}

.micro-footer a {
  color: #0f2742;
  text-decoration: none;
  border-bottom: 1px dotted rgba(15,39,66,.35);
}

.micro-footer a:hover {
  border-bottom-color: transparent;
}

/* CTA central */
.centered-cta {
  text-align: center;
  margin: 18px 0 26px;
}

.btn-cta {
  display: inline-block;
  background: #0b0f14;
  color: #fff;
  padding: 12px 18px;
  border-radius: 7px;
  font: 600 16px 'Tajawal', sans-serif;
  text-transform: uppercase;
  text-decoration: none;
  transition: background .2s;
}

.btn-cta:hover {
  background: #6b2fb4;
}

/* MEDIA QUERIES */
@media (min-width: 600px) {
  .flex-header {
    flex-wrap: nowrap;
    justify-content: space-between;
  }
  .search-buttons,
  .promo-cards {
    flex-direction: row;
  }
}

@media (min-width: 768px) {
  .hero-content h1 {
    font-size: 3rem;
  }
  .hero-content h2 {
    font-size: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .flex-header {
    padding: 16px 32px;
  }
  .nav-main {
    gap: 24px;
  }
  .btn-outline {
    padding: 8px 20px;
  }
}

/* Responsive micro-footer */
@media (max-width: 600px) {
  .micro-footer__inner {
    font-size: 12.5px;
    line-height: 1.6;
  }
  .micro-footer .sep {
    display: none;
  }
  .micro-footer .rights::after {
    content: " ·";
    opacity: .45;
    padding: 0 6px;
  }
  .contenedor_banner {
      display: none;
  }
  .main-header {
    background: #fafbfc;
    border-bottom: none;
    width: 100%;
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 83px;
}
}

/* Responsive barra busqueda */
@media (max-width: 600px) {
       .contenedor_buscador {
    background: #ffffff;
    padding: unset;
    border-radius: 5px;
    margin: 9px 8px 8px 8px;
}
}


/* Responsive top-header + menú hamburguesa */
@media (max-width: 768px) {
  .top-header ul {
    flex-direction: column;
    gap: 15px;
  }

  .hamburger {
    display: flex;
  }

  #menu {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: #fff;
    display: none;
    padding: 20px;
    border-top: 1px solid #eee;
  }

  #menu.active {
    display: block;
  }

  #menu ul {
    flex-direction: row-reverse;
    gap: 20px;
  }
}
