/* CSS Variables for consistent theming */
:root {
  --primary-color: #1a5d3a;
  --primary-hover: #124028;
  --text-main: #222222;
  --text-muted: #555555;
  --bg-light: #f9fbf9;
  --bg-white: #ffffff;
  --border-radius: 12px;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
}

/* Base & Mobile-First Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family:
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    'Segoe UI',
    Roboto,
    sans-serif;
  line-height: 1.6;
  color: var(--text-main);
  background-color: var(--bg-light);
}

h1,
h2,
h3,
h4 {
  line-height: 1.3;
  margin-bottom: var(--spacing-sm);
  color: var(--text-main);
}

p {
  margin-bottom: var(--spacing-sm);
  color: var(--text-muted);
}

/* Container for padding and max-width */
.container {
  width: 90%;
  max-width: 1100px;
  margin: 0 auto;
}

/* Reusable Components */
section {
  padding: var(--spacing-md) 0;
  border-bottom: 1px solid #eaeaea;
}

.btn {
  display: inline-block;
  background-color: var(--primary-color);
  color: var(--bg-white);
  padding: 1rem 1.5rem;
  text-align: center;
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  border-radius: 8px;
  width: 100%; /* Full width for mobile by default */
  transition: background-color 0.3s ease;
  margin-top: var(--spacing-sm);
}

.btn:hover {
  background-color: var(--primary-hover);
}

/* Grids (Mobile Default: 1 column) */
.grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-top: var(--spacing-md);
}

.card {
  background-color: var(--bg-white);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.card h3 {
  color: var(--primary-color);
  font-size: 1.25rem;
}

/* Specific Sections */
.hero {
  padding: var(--spacing-lg) 0;
  text-align: center;
  background-color: var(--bg-white);
}

.hero h1 {
  font-size: 2rem;
  color: var(--primary-color);
}

.hero-subtitle {
  font-size: 1.1rem;
  font-weight: 500;
}

.expert-tag {
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 1px;
  color: var(--primary-color);
  font-weight: bold;
}

/* Prominent WhatsApp CTA */
.whatsapp-link {
  display: inline-block;
  background: var(--primary-color);
  color: var(--bg-white);
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 700;
  margin-left: 0.5rem;
  box-shadow: 0 4px 10px rgba(26, 93, 58, 0.12);
}
.whatsapp-link:hover {
  background: var(--primary-hover);
}

.testimonial {
  border-left: 4px solid var(--primary-color);
  background-color: #f0f7f3;
  font-style: italic;
}

.steps {
  list-style: none;
  counter-reset: step-counter;
}

.steps li {
  position: relative;
  padding-left: 3rem;
  margin-bottom: 1.5rem;
}

.steps li::before {
  counter-increment: step-counter;
  content: counter(step-counter);
  position: absolute;
  left: 0;
  top: 0;
  width: 35px;
  height: 35px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
}

/* Desktop & Tablet Media Queries */
@media (min-width: 768px) {
  .btn {
    width: auto;
    padding: 1rem 2.5rem;
  }

  section {
    padding: var(--spacing-lg) 0;
  }

  .hero h1 {
    font-size: 3rem;
  }

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

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

/* Hero layout with image + content */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  align-items: start;
}

/* Mobile ordering: show only header (title + WhatsApp) before image, body after */
.hero-header {
  order: 1;
}
.hero-media {
  order: 2;
}
.hero-body {
  order: 3;
}

.hero-media {
  display: flex;
  justify-content: center;
}

.hero-image {
  width: 100%;
  max-width: 420px;
  height: auto;
  border-radius: var(--border-radius);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08);
  display: block;
}

.hero-content {
  text-align: left;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1rem;
  flex-wrap: wrap;
}

.btn-secondary {
  background: transparent;
  color: var(--primary-color);
  border: 2px solid rgba(26, 93, 58, 0.12);
  padding: 0.9rem 1.4rem;
  font-weight: 600;
  border-radius: 8px;
}

@media (min-width: 768px) {
  .hero-grid {
    grid-template-columns: 420px 1fr;
  }
  /* Desktop: place media in left column spanning both rows; header and body in right column */
  .hero-media {
    grid-column: 1;
    grid-row: 1 / span 2;
    order: initial;
  }
  .hero-header,
  .hero-body {
    grid-column: 2;
    order: initial;
  }
  .hero-header {
    padding-left: 1.5rem;
  }
  .hero-body {
    padding-left: 1.5rem;
  }
}

/* Make before/after stack on small screens and sit side-by-side on desktop */
.before-after-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 768px) {
  .before-after-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Testimonials: before/after layout */
.testimonial-grid {
  display: grid;
  gap: 2rem;
  margin-top: 1.25rem;
}
.person h4 {
  margin-bottom: 0.5rem;
  color: var(--text-main);
}
.before-after-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  align-items: start;
  margin-top: 0.5rem;
}
.before-after-item h5 {
  margin: 0 0 0.5rem 0;
  font-size: 0.9rem;
  color: var(--text-main);
}
.testimonial-img {
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.06);
  display: block;
}
.img-placeholder {
  min-height: 180px;
  background-color: #eee;
}
.testimonial-quote {
  margin-top: 0.75rem;
  font-style: italic;
  color: #444;
}

@media (min-width: 768px) {
  .testimonial-img {
    max-height: 420px;
  }
  .img-placeholder {
    min-height: 220px;
  }
}
