/* ==========================================================================
   03-layout.css — container, section rhythm, grid helpers
   ========================================================================== */

/* Duda pattern: the row carries 15px side padding and wraps a 1200px inner
   wrapper, so the *content box* is 1200px — not 1200px minus padding. */
.container {
  width: 100%;
  max-width: calc(var(--container) + (var(--gutter) * 2));
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Full-bleed section wrapper. Backgrounds span the viewport; content is
   constrained by .container inside. Mirrors Duda's .dmRespRow behaviour. */
.section {
  position: relative;
  width: 100%;
  padding-block: var(--section-pad-y);
}

.section--flush {
  padding-block: 0;
}

.section--black {
  background-color: var(--c-black);
}

.section--panel {
  background-color: var(--c-panel);
}

/* Sections that carry a photographic background plus a darkening overlay */
.section--bg {
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.section--overlay::before {
  content: '';
  position: absolute;
  inset: 0;
  background-color: var(--c-overlay);
  pointer-events: none;
}

.section--overlay > * {
  position: relative;
  z-index: 1;
}

/* Two-column split used by the attorney and civil-rights blocks */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.split__media {
  position: relative;
  min-height: 100%;
}

.split__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.split__body {
  padding: var(--section-pad-y) var(--section-pad-x);
}

@media (max-width: 767px) {
  .split {
    grid-template-columns: 1fr;
  }

  .split__body {
    padding-inline: var(--gutter);
  }
}

/* Generic responsive grid */
.grid {
  display: grid;
  gap: 30px;
}

.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 767px) {
  .grid--2,
  .grid--3,
  .grid--4 { grid-template-columns: 1fr; }
}

.text-center { text-align: center; }
