/* ==========================================================================
   PATH: /css/service-areas.css
   TYPE: stylesheet
   STATUS: shared
   USES: homepage service-area links, service-areas hub city-card family

   PURPOSE
   This file owns the reusable service-areas component system used for:
   - homepage service-area link grid
   - service-areas hub page city-card grid
   - future support pages reusing the same service-area module patterns

   KEEP IN THIS FILE
   - .areas-list
   - .areas-list a
   - .service-areas-heading
   - .city-grid
   - .city-card
   - .city-card-inner
   - .city-link
   - responsive behavior for service-area modules in this file

   DO NOT PUT IN THIS FILE
   - outer section shell layout like .areas-grid
   - intro-column spacing like .areas-intro
   - broad band spacing or section padding
   - page-only copy spacing tweaks
   - unrelated cards or layout shells from other components

   OWNERSHIP NOTES
   - If the selector styles the service-area module itself, it belongs here.
   - If the selector positions the intro column beside the module, it belongs
     in layout/bands.css.
   - If a page needs a one-off local presentation, use a modifier or page
     override instead of changing the base component here.
   ========================================================================== */

/* ==========================================================================
   HOMEPAGE AREA LINKS
   Reusable city-link grid used in the homepage service-areas section.
   ========================================================================== */

.areas-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  padding: 2rem 0 0;
  align-content: start;
}

.areas-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 1rem 1.1rem;
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid var(--line-dark);
  color: var(--text-dark);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.2;
  transition:
    background 180ms ease,
    border-color 180ms ease,
    color 180ms ease,
    transform 180ms ease;
}

.areas-list a::after {
  content: "→";
  color: var(--gold);
  font-size: 0.95rem;
  line-height: 1;
  margin-left: 0.75rem;
  flex-shrink: 0;
}

.areas-list a:hover,
.areas-list a:focus-visible {
  background: rgba(255, 255, 255, 0.68);
  border-color: rgba(198, 164, 109, 0.45);
  color: var(--text-dark);
  transform: translateY(-1px);
}

/* ==========================================================================
   SERVICE-AREAS HUB INTRO
   Shared heading block used above the city-card grid on the service-areas hub.
   ========================================================================== */

.service-areas-heading {
  max-width: 760px;
}

.service-areas-heading p {
  margin-top: 0.875rem;
}

/* ==========================================================================
   CITY CARD FAMILY
   Reusable card grid for the service-areas hub and future city-listing modules.
   ========================================================================== */

.city-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.city-card {
  display: block;
  min-height: 100%;
  color: inherit;
  text-decoration: none !important;
  background: rgba(255, 255, 255, 0.42);
  border: 1px solid var(--line-dark);
  overflow: hidden;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background 180ms ease;
}

.city-card:hover,
.city-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(34, 30, 25, 0.18);
  background: rgba(255, 255, 255, 0.68);
  text-decoration: none !important;
}

.city-card-inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.75rem;
  min-height: 100%;
}

.city-card h3,
.city-card p,
.city-card span {
  text-decoration: none !important;
}

.city-card h3 {
  margin: 0;
}

.city-card p {
  margin: 0;
  color: var(--muted-dark);
}

.city-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: auto;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-dark);
  letter-spacing: 0.01em;
}

.city-link::after {
  content: "→";
  font-size: 0.95em;
  line-height: 1;
  transition: transform 180ms ease;
}

.city-card:hover .city-link::after,
.city-card:focus-visible .city-link::after {
  transform: translateX(3px);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */

@media (max-width: 1080px) {
  .city-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 979px) {
  .areas-list {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .city-grid {
    grid-template-columns: 1fr;
  }

  .city-card-inner {
    padding: 1.375rem;
  }
}