:root {
  --container: 1200px;
  --space: 24px;
  --accent: #2ECC71;
}

/* === Base Typography & Colors === */
body {
  margin: 0;
  font: 16px/1.5 system-ui, Inter, Arial;
  color: #111;
  background: #fff;
  overflow-x: hidden;
}

.wrap {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--space);
}

/* === Header & Navigation === */
.header {
  background: #111;
  color: #fff;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  flex-wrap: wrap; /* allow wrapping on small screens */
  padding: 0 var(--space);
}

.nav a {
  color: #fff;
  text-decoration: none;
  margin-left: 16px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav a:hover {
  color: var(--accent);
}

/* === Buttons === */
.btn {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 2px solid transparent;
  font-weight: 600;
  transition: all 0.2s ease;
}

.btn.primary {
  background: var(--accent);
  color: #fff;
}

.btn.ghost {
  border-color: #fff;
  color: #fff;
}

.btn:hover {
  opacity: 0.9;
}

/* === Hero Section === */
.hero {
  position: relative;
  min-height: 520px;
  background-size: cover;
  background-position: center;
  color: #fff;
  display: grid;
  place-items: center;
  text-align: center;
  overflow: hidden;
}

.hero .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.1));
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  padding: 0 1rem;
}

/* === Footer === */
.footer {
  background: #111;
  color: #fff;
  padding: 24px 0;
  margin-top: 48px;
  text-align: center;
}

/* === Headings === */
h2 {
  font-size: 2rem;
  margin: 32px 0 24px;
  text-align: center;
}

/* === 3-card Grid (Homepage services) === */
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-bottom: 32px;
}

.card {
  border: 1px solid #e6e6e6;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  display: grid;
  grid-template-rows: auto 1fr;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.08);
}

.card .thumb {
  display: grid;
  place-items: center;
  background: #fafafa;
}

.card .thumb img {
  width: 88px;
  height: 88px;
  object-fit: contain;
}

.card .body {
  padding: 16px;
  text-align: center;
}

.title {
  font-weight: 600;
}

.kicker {
  color: #666;
  font-size: 0.9rem;
}

/* === Hero Slideshow Transitions === */
.hero .slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 800ms ease-in-out;
  z-index: 1;
}

.hero .slide.active {
  opacity: 1;
}

.hero .overlay { z-index: 2; }
.hero .hero-content { z-index: 3; }

/* =========================================================
   📱 RESPONSIVE DESIGN
   ========================================================= */

/* === Large Tablets (≤ 1024px) === */
@media (max-width: 1024px) {
  .wrap {
    padding: 0 16px;
  }

  .nav {
    flex-wrap: wrap;
    height: auto;
    justify-content: center;
    gap: 12px;
  }

  .nav a {
    margin-left: 0;
  }

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

  .hero {
    min-height: 400px;
  }
}

/* === Small Tablets & Large Phones (≤ 768px) === */
@media (max-width: 768px) {
  body {
    font-size: 15px;
  }

  .nav {
    flex-direction: column;
    align-items: center;
    height: auto;
    gap: 8px;
  }

  .nav a {
    margin: 6px 0;
    font-size: 1rem;
  }

  .hero {
    min-height: 360px;
    padding: 40px 0;
  }

  .hero-content {
    font-size: 1rem;
    line-height: 1.4;
  }

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

  .card {
    max-width: 400px;
    margin: 0 auto;
  }
}

/* === Mobile (≤ 480px) === */
@media (max-width: 480px) {
  .nav {
    gap: 4px;
  }

  .hero {
    min-height: 300px;
    background-position: top center;
  }

  .hero-content {
    padding: 0 12px;
  }

  h2 {
    font-size: 1.5rem;
  }

  .footer {
    padding: 16px 0;
    font-size: 0.9rem;
  }

  .btn {
    width: 100%;
    display: inline-block;
  }
}

