/* =========================================================
   HERO CAROUSEL
   Fully responsive, optimized for all screen sizes
========================================================= */
#heroCarousel {
  position: relative;
  overflow: hidden;
  height: 100vh;
  z-index: 0;
}

/* Slide item */
.carousel-item {
  position: relative;
  height: 100vh;
}

.carousel-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: brightness(60%);
  z-index: 1;
}

/* Caption (main text area) */
.carousel-caption {
  position: absolute;
  top: 35%;
  left: 8%;
  z-index: 3;
  max-width: 600px;
  color: #fff;
}

.carousel-caption h2 {
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1.3;
}

.carousel-caption a {
  color: var(--green);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s ease;
}

.carousel-caption a:hover {
  text-decoration: underline;
}

/* Overlay box (bottom right) */
.carousel-overlay-box {
  position: absolute;
  bottom: 5%;
  right: 5%;
  background: rgba(255, 255, 255, 0.9);
  padding: 1.2rem 1.5rem;
  border-radius: 0.5rem;
  width: 300px;
  z-index: 4;
  box-shadow: 0 3px 15px rgba(0, 0, 0, 0.2);
}

.carousel-overlay-box h6 {
  font-weight: 600;
  color: #222;
}

.carousel-overlay-box p {
  font-weight: 600;
  color: var(--green);
}

/* Carousel controls inside overlay */
.carousel-controls button {
  border: none;
  background: transparent;
  color: #333;
  transition: color 0.2s ease;
}

.carousel-controls button:hover {
  color: var(--green);
}

/* ---------- RESPONSIVENESS ---------- */
@media (max-width: 992px) {
  #heroCarousel {
    height: 90vh;
  }

  .carousel-caption {
    top: 28%;
    left: 5%;
    max-width: 90%;
  }

  .carousel-caption h2 {
    font-size: 2rem;
  }

  .carousel-overlay-box {
    width: 85%;
    left: 50%;
    transform: translateX(-50%);
    bottom: 8%;
  }
}

@media (max-width: 576px) {
  #heroCarousel {
    height: 70vh;
  }

  .carousel-caption {
    top: 25%;
    text-align: left;
  }

  .carousel-caption h2 {
    font-size: 1.4rem;
  }

  .carousel-caption a {
    font-size: 0.9rem;
  }

  .carousel-overlay-box {
    bottom: 5%;
    padding: 1rem;
    width: 90%;
    font-size: 0.9rem;
  }
}


/* =========================================================
   BRAND COLORS AND GLOBAL OVERRIDES
========================================================= */
:root {
  --green: #009739; /* Main brand green */
}

/* Convert Bootstrap “danger” styles to green */
.text-danger,
a.text-danger,
a.text-danger:hover {
  color: var(--green) !important;
  text-decoration: none;
}

.text-green {
  color: var(--green) !important;
}

.border-danger,
.border-green {
  border-color: var(--green) !important;
}

.btn-danger {
  background-color: var(--green) !important;
  border-color: var(--green) !important;
  color: #fff !important;
  transition: all 0.2s ease-in-out;
}

.btn-danger:hover,
.btn-danger:focus {
  background-color: #007c30 !important;
  border-color: #007c30 !important;
  color: #fff !important;
}

/* Active tab underline + hover */
.nav-link.active.border-green {
  border-bottom: 3px solid var(--green) !important;
  color: var(--green) !important;
}

.nav-link:hover {
  color: var(--green) !important;
}

/* =========================================================
   NEWS SECTION
========================================================= */
.news-section .nav-link {
  font-size: 0.95rem;
  letter-spacing: 0.5px;
}

.news-section .nav-link.active {
  color: var(--green) !important;
  border-bottom: 2px solid rgba(0, 128, 0, 0.1) !important;
}

.news-section .card-img-top {
  width: 100%;
  height: 250px;
  object-fit: cover;
  object-position: center;
  border-radius: none;
  transition: transform 0.3s ease;
}

.news-section .card:hover img {
  transform: scale(1.03);
}

.news-section .card-body h5 {
  line-height: 1.4;
}

.news-section a.btn-danger {
  border-radius: 0;
}

/* Responsive image height for smaller devices */
@media (max-width: 768px) {
  .news-section .card-img-top {
    height: 200px;
  }
}


/* =========================================================
   GET STARTED BUTTON (keeps red across all themes)
========================================================= */
.btn-get-started {
  background-color: #dc3545 !important; /* Bootstrap red */
  color: #fff !important;
  border: none !important;
  transition: background-color 0.3s ease;
}

.btn-get-started:hover {
  background-color: #b02a37 !important;
  color: #fff !important;
}


.newsletter-section {
  overflow: hidden;
}

/* Right-side background image */
.newsletter-image {
  background-image: url('automobile/MG/Right\ Front\ 45°.jpg'); /* Replace with your own image */
  background-size: cover;
  background-position: center;
  height: 100%;
  min-height: 400px;
  position: relative;
}

/* Gradient overlay to blend left and right */
.newsletter-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to left, rgba(255,255,255,0.9) 0%, rgba(255,255,255,0.6) 25%, transparent 60%);
}

/* Text styles */
.newsletter-section h6 {
  color: #000;
  letter-spacing: 0.5px;
}

.newsletter-section h2 {
  font-size: 1.6rem;
  line-height: 1.5;
  color: #000;
}

@media (min-width: 992px) {
  .newsletter-section h2 {
    font-size: 2rem;
  }
}

/* Red Sign Up button */
.newsletter-section .btn-danger {
  background-color: green !important;
  border: none !important;
  color: #fff !important;
  transition: background-color 0.3s ease;
}

.newsletter-section .btn-danger:hover {
  background-color: green !important;
}

/* Responsive adjustments */
@media (max-width: 991px) {
  .newsletter-image {
    min-height: 300px;
  }
  .newsletter-image::before {
    background: linear-gradient(to top, rgba(255,255,255,0.9) 0%, transparent 80%);
  }
}
