/* ========== PAGE SETTINGS  ========== */
:root {
  --bg-color: #f2f2f2; /* Background */
  --card-bg: #e5e5e5; /* Card backgrounds */
  --accent: #ffcc00; /* Yellow accent */
  --text-main: #111111; /* Black text */
  --text-sub: #555555; /* Subtext gray */
  --tras-bg: rgba(157, 157, 157, 0.3);
  --shadow: rgba(0, 0, 0, 0.8);
}

html,
body {
  width: 100%;
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg-color);
  color: var(--text-main);
  margin: 0;
  font-family: system-ui, Avenir, Helvetica, Arial, sans-serif;
}
/* ========== HERO SECTION ========== */
.hero {
  position: relative;
  height: 700px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.background-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  object-fit: cover;
}

.hero-content {
  position: absolute;
  text-align: center;
  top: 70%;
  left: 2%;
  right: 2%;
  padding: 20px;
  border-radius: 12px;
  z-index: 2;
}

.hero h1 {
  font-size: 1.5rem;
  margin-bottom: 10px;
  color: var(--accent);
}

.hero p {
  font-size: 1rem;
  color: var(--bg-color);
  margin-top: 5px;
  margin-bottom: 15px;
  padding: 0;
}

/* ========== BUTTON ========== */
/* Different types of Buttons */
.btn-yellow {
  background-color: var(--accent);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  padding: 12px 28px;
  border: none;
  border-radius: 5px;
}

.btn-white {
  background-color: var(--bg-color);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  padding: 12px 28px;
  border: none;
  border-radius: 5px;
}

button:hover {
  opacity: 0.9;
}

/* ========== FEATURED CARS ========== */
.featured {
  margin-top: 0px;
  padding-bottom: 50px;
  padding: 0px 0px 10px 10px;
}

.car-grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 20px;
  margin-top: 20px;
}

.car-grid::-webkit-scrollbar {
  display: none;
}

.car-card {
  position: relative;
}

.car-card img {
  width: 330px;
  height: 520px;
  border-radius: 15px;
  object-fit: cover;
}

.featured-text {
  position: absolute;
  bottom: 5%;
  padding: 0px 15px;
}

.featured-text h3 {
  color: var(--bg-color);
  font-size: 1.8rem;
  font-weight: 500;
  margin: 0;
}

.featured-text p {
  color: var(--bg-color);
  font-size: 1.1rem;
  font-weight: 200;
  margin: 10px 0;
}

.featured-text button {
  margin-right: 5px;
  width: 140px;
}

.made {
  position: absolute;
  top: 0%;
  left: 10px;
  color: #ffffff;
  font-size: 16px;
  font-weight: 200;
  padding: 5px 10px;
  border-radius: 5px;
}

/* ========== OFFERS ========== */
.offer-section {
  color: var(--text-main);
  text-align: start;
  padding: 30px 10px;
}

.offers-container {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  gap: 20px;
}

.promo {
  display: flex;
  flex-direction: column-reverse;
  background-color: rgb(232, 232, 232);
  padding: 0px 0px 20px 0px;
  border-radius: 10px;
}

.promo h1 {
  font-size: 26px;
  font-weight: 600;
  margin: 0;
  margin-top: 20px;
}

.promo p {
  font-size: 17px;
  color: #5c5e62;
  width: 318px;
  padding: 0;
  margin-top: 5px;
  margin-bottom: 10px;
}

.offer-text {
  margin-left: 20px;
}

.offer-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-top-right-radius: 10px;
  border-top-left-radius: 10px;
}

.offer-text button {
  padding: 4;
  width: 240px;
}

/* ========== SHOWROOM CARS ========== */

.showroom {
  display: block;
  padding: 0px 10px 0px 10px;
}

.showroom img {
  margin-bottom: 10px;
  filter: brightness(70%);
  border-radius: 10px;
  border-bottom-left-radius: 10px;
  object-fit: cover;
}

.showroom-text h1 {
  font-size: 1.4rem;
  margin: 0;
}

.showroom-text p {
  font-size: 1rem;
  margin-top: 0;
  margin-bottom: 10px;
}

/* text and buttons centered inside the image */
.banner {
  position: relative;
}

.garage img {
  width: 100%;
  height: 500px;
  object-fit: cover;
  border-radius: 10px;
}

.text-garage h1 {
  font-size: 1.4rem;
  margin: 0;
}

.text-garage p {
  font-size: 1rem;
  margin-top: 0;
  margin-bottom: 10px;
}

.center {
  position: absolute;
  top: 65%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  width: 400px;
}

.center h1 {
  color: var(--accent);
  font-size: 1.6rem;
  width: 300px;
  width: 100%;
}

.center p {
  font-weight: 200;
  width: 300px;
  color: var(--bg-color);
  width: 100%;
}

/* ========== CARS LOGOS ========== */

.brand-logos {
  text-align: center;
  margin-bottom: 30px;
}

.car-logo {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 20px;
  padding-bottom: 30px;
  padding-left: 20px;
}

.car-logo::-webkit-scrollbar {
  display: none;
}

.car-logo img {
  width: 95px;
}

/* ========== TABLET ========== */
@media (min-width: 800px) {
  /* Featured Cars */
  .car-grid {
    margin-top: 40px;
    padding-right: 30px;
    padding-left: 30px;
  }
  .car-card img {
    width: 600px;
    height: 520px;
  }

  .offer-section {
    padding: 30px 30px;
  }

  .featured {
    padding: 0px 0px 0px 0px;
  }

  .featured-text button {
    width: 260px;
  }

  /* Offer section */
  .offers-container {
    flex-direction: row;
    justify-content: space-between;
  }

  .promo {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 20px;
  }

  .offer-image {
    display: none;
  }

  .offer-text p {
    width: 400px;
  }

  /* Showroom */
  .showroom {
    padding: 0px 30px;
  }

  .garage {
    grid-column: span 2;
  }

  .showroom {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding-left: 30px;
    padding-right: 30px;
  }

  .showroom-text {
    width: 400px;
  }

  .showroom-text h1 {
    font-size: 1.4rem;
    margin: 0;
  }

  .showroom-text p {
    font-size: 1rem;
    margin-top: 0;
    margin-bottom: 10px;
  }

  .car-logo {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
  }
}

/* ========== DESKTOP========== */
@media (min-width: 1100px) {
  div.account {
    height: 24px;
    align-content: center;
  }

  .hero {
    height: 85vh;
  }

  .featured {
    margin-top: 0px;
  }

  .car-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    padding: 0px 30px;
  }

  .car-grid img {
    width: 960px;
    height: 580px;
  }

  /* Offers */
  .offer-section {
    color: var(--text-main);
    text-align: start;
    padding: 40px 30px;
  }

  .offers-container {
    flex-direction: row;
    justify-content: space-between;
  }

  .promo {
    flex-direction: row;
    padding: 0px 0px 0px 30px;
    align-items: center;
    justify-content: space-between;
  }

  .offer-image {
    display: inline;
    height: 220px;
  }

  .offer-image img {
    height: fit-content;
    border-top-right-radius: 10px;
    border-bottom-right-radius: 10px;
    filter: brightness(70%);
    height: 100%;
  }

  /* Showroom */
  .showroom img {
    padding-bottom: 0;
    position: relative;
  }

  /* Main image text centered bottom */
  .bottom {
    position: absolute;
    top: 80%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    width: 800px;
  }

  .bottom h1 {
    color: var(--accent);
    font-size: 2rem;
    width: 800px;
    margin: 0;
  }

  .bottom p {
    font-weight: 200;
    font-size: 1.4rem;
    width: 800px;
    color: var(--bg-color);
    margin: 0px 0px 10px 0px;
  }

  /* Buttons sizing desktop */
  .btn-yellow,
  .btn-white {
    padding: 12px 60px;
  }

  .garage img {
    height: 700px;
  }

  h2.section-title {
    color: var(--accent);
  }

  .car-logo img {
    width: 120px;
  }
}
