/* =========================================================
   HERO SECTION
========================================================= */
.hero {
  position: relative;
  height: 100vh; /* default to viewport height for predictable behavior */
  overflow: hidden;
  top: 0;
}

.slides img.slide {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.slides img.slide.active {
  opacity: 1;
}

.overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1;
}

.hero-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--light);
  text-align: center;
  z-index: 2;
  width: 92%;
  max-width: 900px;
  padding: 0 1rem;
  -webkit-font-smoothing: antialiased;
}

.hero-content h1 {
  font-size: 2.4rem;
  margin-bottom: 0.6rem;
  line-height: 1.05;
}

.hero-content p {
  font-size: 1.05rem;
  margin-bottom: 1.2rem;
}

/* Tablet and up */
@media (min-width: 640px) {
  .hero {
    height: 90vh;
  }
  .hero-content h1 {
    font-size: 3rem;
  }
  .hero-content p {
    font-size: 1.15rem;
  }
  .track-form input {
    width: 320px;
  }
}

/* Desktop */
@media (min-width: 1024px) {
  .hero {
    height: 95vh;
  }
  .hero-content {
    max-width: 1100px;
  }
  .hero-content h1 {
    font-size: 3.6rem;
  }
  .hero-content p {
    font-size: 1.25rem;
  }
  .track-form input {
    width: 420px;
  }
}

/* Large desktops */
@media (min-width: 1440px) {
  .hero-content h1 {
    font-size: 4.2rem;
  }
  .hero-content p {
    font-size: 1.35rem;
  }
}

/* Mobile adjustments */
@media (max-width: 639px) {
  .hero {
    height: 88vh;
  }
  .hero-content h1 {
    font-size: 1.9rem;
  }
  .hero-content p {
    font-size: 1rem;
  }
  .hero-content {
    width: 95%;
  }
  .track-form {
    gap: 0.4rem;
    flex-direction: column;
    align-items: center;
  }
  .track-form input {
    width: 100%;
    max-width: 320px;
  }
  .track-form button {
    width: auto;
    padding: 0.7rem 1rem;
  }
}
/* Tracking Form */
.track-form {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.track-form input {
  padding: 0.8rem 1rem;
  border: none;
  border-radius: 4px;
  width: 250px;
  max-width: 80%;
}

.track-form button {
  background: var(--primary);
  border: none;
  color: var(--light);
  padding: 0.8rem 1.2rem;
  border-radius: 4px;
  cursor: pointer;
  transition: 0.3s ease;
  text-decoration: none;
}

.track-form button:hover {
  background: #900;
}

/* =========================================================
   ABOUT SECTION
========================================================= */
.about {
  padding: 5rem 0;
  text-align: center;
  background: var(--accent);
}

.about h2 {
  color: var(--primary);
  margin-bottom: 1rem;
}

.about p {
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.05rem;
  color: #444;
}

/* =========================================================
   SERVICES SECTION
========================================================= */
.services {
  padding: 5rem 0;
  text-align: center;
}

.services h2 {
  color: var(--primary);
  margin-bottom: 2rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.card {
  background: var(--light);
  border-radius: 8px;
  filter: drop-shadow(4px 8px 15px red);
  padding: 2rem 1.5rem;
  text-align: left;
  transition: var(--transition);
}

.card h3 {
  color: var(--primary);
  margin-bottom: 0.7rem;
}

.card:hover {
  transform: translateY(-6px);
}
/* ===== MAIN GRID ===== */
.services-grid {
  padding: 5rem 0;
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit,minmax(280px,1fr));
  gap: 2rem;
}
.service-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  height: 90vh;
  box-shadow: 0 6px 18px rgba(0,0,0,0.1);
  transition: transform .3s ease, box-shadow .3s ease;
}
.service-card img {
  width: 100%;
  height: 460px;
  object-fit: cover;
}
.service-card .content {
  padding: 1.5rem;
}
.service-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 25px rgba(0,0,0,0.15);
}
.service-card h3 {
  color: var(--primary);
  margin-bottom: .5rem;
}
.service-card p {
  color: #444;
  line-height: 1.6;
}
.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

@media (max-width: 768px) {
  .hero {
    height: 100vh;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
  .track-form input {
    width: 100%;
  }
  .service-card{
    height: auto;
  }
  .service-card img{
    height: 450px;
  }
}
/* =========================================================
   Dark Mode
==========================================================*/
html.dark-mode .hero-content {
  color: #fff;
  filter: drop-shadow(2px 4px 6px red);
}
html.dark-mode .text h2 {
  color: #fff;
  filter: drop-shadow(2px 4px 6px red);
}
html.dark-mode .text p {
  color: #ddd;
}
