/* ============================================================
   COMPONENT: Map / Office Location (Home)
   FILE: assets/css/map-location.css
   Depends on: map-location.html, surfaces.css, buttons.css.
   Loaded after newsletter.css (Phase 1.0 §6, in build order).

   Section background is white, continuing the rhythm: ... Blog
   Preview (white) -> Newsletter (navy) -> Map/Office Location
   (white).

   Global Card System: `.surface--solid` (surfaces.css) supplies
   both panels' white background, hairline border, radius and
   resting shadow, matching every other card-based Home section.
   Only panel-specific layout is added here, scoped under
   .map-location__* — nothing here redefines the surface system.

   Map panel: pure CSS/SVG, no background-image request, no map
   library — kept intentionally lightweight per the roadmap's
   Performance requirement. The grid-line pattern and pin are
   inline SVG using existing brand tokens (navy/gold) so it reads
   as an on-brand placeholder rather than a generic empty box.

   Buttons: reuse the existing global .btn / .btn--secondary /
   .btn--sm classes from buttons.css untouched — no new button
   variant is introduced.

   RTL readiness (Stage 5.13 scope only): logical properties
   (text-align: start, margin-inline / padding-inline) are used
   instead of physical left/right, matching the rest of the
   project's convention — no separate RTL stylesheet or
   breakpoint system is introduced.
   ============================================================ */

.map-location {
  background-color: var(--color-white);
  padding-block: var(--space-10);
}

.map-location__inner {
  text-align: center;
}

.map-location__heading {
  margin: 0 0 var(--space-2);
  color: var(--color-navy);
  font-size: var(--text-h3);
}

.map-location__subheading {
  max-width: 640px;
  margin-inline: auto;
  margin-block: 0 var(--space-6);
  color: var(--color-dark-gray);
  font-size: var(--text-body);
}

/* ------------------------------------------------------------
   GRID
   Single column, map panel stacking below info on mobile/
   tablet; side-by-side from desktop up.
------------------------------------------------------------ */
.map-location__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
  text-align: start;
}

.map-location__panel {
  padding: var(--space-4);
}

/* ------------------------------------------------------------
   INFO PANEL
------------------------------------------------------------ */
.map-location__info {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.map-location__address,
.map-location__hours {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: var(--space-2);
  row-gap: 2px;
  font-style: normal;
}

.map-location__icon {
  grid-row: 1 / 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-lg);
  background-color: rgba(var(--color-navy-rgb), 0.06);
  color: var(--color-navy);
}

.map-location__icon svg {
  width: 20px;
  height: 20px;
}

.map-location__label {
  align-self: end;
  color: var(--color-navy);
  font-size: var(--text-small);
  font-weight: 600;
}

.map-location__value {
  color: var(--color-dark-gray);
  font-size: var(--text-body);
  line-height: var(--line-height-body);
}

.map-location__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  padding-block-start: var(--space-2);
  border-block-start: var(--border-hairline);
}

.map-location__action {
  gap: var(--space-1);
}

.map-location__action-icon {
  display: inline-flex;
}

/* ------------------------------------------------------------
   MAP PANEL
------------------------------------------------------------ */
.map-location__map {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3);
  overflow: hidden;
}

.map-location__map-frame {
  position: relative;
  width: 100%;
  min-height: 320px;
  overflow: hidden;
  border-radius: var(--radius-btn);
  background: var(--color-light-gray);
}

.map-location__map-frame iframe {
  display: block;
  width: 100%;
  height: 320px;
  border: 0;
  pointer-events: none;
}

.map-location__map-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: block;
  cursor: pointer;
}

.map-location__map-caption {
  margin: 0;
  text-align: center;
  color: var(--color-dark-gray);
  font-size: var(--text-small);
}

/* ------------------------------------------------------------
   RESPONSIVE
   Breakpoint values copied from tokens.css's documented
   reference values, same convention every other Home section
   uses.
------------------------------------------------------------ */

/* Desktop and up: info + map side by side */
@media (min-width: 1024px) {
  .map-location {
    padding-block: var(--space-12);
  }

  .map-location__grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: var(--space-5);
    align-items: stretch;
  }

  .map-location__panel {
    padding: var(--space-5);
  }
}

/* Small mobile: tighten spacing, keep panels compact, no overflow */
@media (max-width: 479px) {
  .map-location {
    padding-block: var(--space-8);
  }

  .map-location__grid {
    gap: var(--space-3);
  }

  .map-location__panel {
    padding: var(--space-3);
  }

  .map-location__actions {
    flex-direction: column;
    align-items: stretch;
  }
}
