/* ----- Base & Reset ----- */
*,
*::before,
*::after { box-sizing: border-box; }
body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  line-height: 1.6;
  color: #1d1d1d;
  background-color: #ffffff;
  scroll-behavior: smooth;
}
img { max-width: 100%; height: auto; display: block; }
a { color: #1c4ed8; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ----- Layout Helpers ----- */
.container { max-width: 1100px; margin: 0 auto; padding: 0 1rem; }
.section { padding: 4rem 0; }
.section--alt { background: #f7f9fc; }

h1, h2, h3 { line-height: 1.2; }
h1 { font-size: clamp(2.2rem,4vw,3rem); margin: 0 0 .5rem; }
h2 { font-size: clamp(1.75rem,3vw,2.25rem); margin-bottom: 1.5rem; }
h3 { font-size: 1.35rem; margin-bottom: .75rem; }

.btn {
  display: inline-block;
  padding: .75rem 1.5rem;
  border-radius: 4px;
  font-weight: 600;
}
.btn--primary {
  background: #1c4ed8;
  color: #fff;
  transition: background .2s ease-in-out;
}
.btn--primary:hover { background: #163fa9; }

/* ----- Hero ----- */
.hero {
  background: url('/assets/images/hero-opelika-courthouse.jpg') center/cover no-repeat;
  min-height: 75vh;
  display: flex;
  align-items: center;
  text-align: center;
  color: #fff;
}
.hero::after {                       /* overlay for readability */
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,35,.45);
}
.hero__content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  margin: 0 auto;
  padding: 0 1rem;
}
.tagline { font-size: 1.25rem; margin-bottom: 2rem; }

/* ----- Navigation ----- */
.nav {
  background: #ffffff;
  border-bottom: 1px solid #e5eaf4;
}
.nav ul {
  margin: 0;
  padding: .5rem 1rem;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}
.nav a { font-weight: 500; }

/* ----- Grid (About) ----- */
.grid {
  display: grid;
  gap: 2rem;
}
@media (min-width: 720px) {
  .grid { grid-template-columns: 300px 1fr; align-items: center; }
}

/* ----- Cards (Practice Areas) ----- */
.cards {
  display: grid;
  gap: 1.75rem;
}
@media (min-width: 640px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
}
.card {
  background: #ffffff;
  border: 1px solid #e5eaf4;
  border-radius: 6px;
  padding: 1.5rem;
  transition: transform .25s ease, box-shadow .25s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
}

/* ----- Testimonials ----- */
.testimonial {
  font-style: italic;
  margin-bottom: 2rem;
  border-left: 4px solid #1c4ed8;
  padding-left: 1rem;
}
.testimonial cite { display: block; margin-top: .75rem; font-style: normal; font-weight: 500; }

/* ----- Form ----- */
.form { margin-top: 2rem; max-width: 600px; }
.form__row { margin-bottom: 1rem; display: flex; flex-direction: column; }
label { margin-bottom: .25rem; font-weight: 500; }
input, textarea {
  border: 1px solid #ccd1e6;
  border-radius: 4px;
  padding: .65rem;
  font: inherit;
}
input:focus, textarea:focus { outline: 2px solid #1c4ed8; }

/* ----- Footer ----- */
.footer { background: #0d113d; color: #f2f6ff; padding: 2rem 0; }
.footer p { margin: 0 0 1rem; font-size: .9rem; }
.footer nav ul { display: flex; flex-wrap: wrap; gap: 1rem; list-style: none; padding: 0; margin: 0; }
.footer a { color: #c7d2ff; font-size: .9rem; }
.footer a:hover { color: #fff; }


/* --- Fix the hero overlay blocking clicks --- */
.hero {
  position: relative;          /* establish stacking context */
  overflow: hidden;            /* ensure the ::after can’t spill out */
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(0,0,35,.45);
  z-index: 0;                  /* sit beneath the content */
}

.hero__content {
  position: relative;
  z-index: 1;                  /* bring your text & button above the overlay */
}

/* --- Tablet (up to ~1024px) and Mobile (up to ~768px) tweaks --- */
@media (max-width: 1024px) {
  /* make your practice-area cards two-up on tablets */
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
  /* compress hero a bit */
  .hero {
    min-height: 60vh;
  }
}

@media (max-width: 768px) {
  /* stack the cards one-up on phones */
  .cards {
    grid-template-columns: 1fr;
  }
  /* tighten up your section spacing on small screens */
  .section {
    padding: 2rem 0;
  }
  /* smaller tagline & button for narrow viewports */
  .tagline {
    font-size: 1rem;
  }
  .btn {
    padding: .5rem 1rem;
    font-size: .9rem;
  }
  /* reduce container side-padding so content fills the screen */
  .container {
    padding: 0 .5rem;
  }
}
