.lat-locations-section {
  padding: 72px 20px;
  background: #ffffff;
  content-visibility: auto;
  contain-intrinsic-size: 0 820px;
  contain: layout style;
}

.lat-locations-inner {
  max-width: 1300px;
  margin: 0 auto;
}

.lat-locations-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 40px;
}

.lat-locations-eyebrow {
  font-size: 11px;
  letter-spacing: 2px;
  font-weight: 800;
  color: #1e88c9;
  text-transform: uppercase;
  margin: 0 0 10px;
}

.lat-locations-heading {
  font-size: clamp(28px, 3.5vw, 38px);
  font-weight: 900;
  color: #111111;
  margin: 0 0 14px;
  line-height: 1.15;
}

.lat-locations-subtext {
  color: #555555;
  line-height: 1.65;
  font-size: 15px;
  margin: 0;
}

/* ── STATE GROUPS: label rail on the left, cards on the right ── */
.lat-state-group {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 28px;
  align-items: start;
}

.lat-state-group + .lat-state-group {
  margin-top: 26px;
  padding-top: 26px;
  border-top: 1px solid #eef2f6;
}

.lat-state-rail {
  padding-left: 13px;
  border-left: 4px solid #ffc72c;
  padding-top: 2px;
}

.lat-state-name {
  font-size: 16px;
  font-weight: 800;
  color: #111111;
  margin: 0 0 4px;
  line-height: 1.25;
}

.lat-state-count {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #8a949e;
}

.lat-state-cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

/* ── CARDS: horizontal on desktop ────────────────────────── */
.lat-location-card {
  display: flex;
  flex-direction: row;
  min-height: 156px;
  background: #ffffff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.05);
  border: 1px solid #eef2f6;
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.lat-location-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(30,136,201,0.1);
}

.lat-map-thumb {
  position: relative;
  width: 190px;
  flex-shrink: 0;
  background: #e8edf3;
  border-right: 3px solid #ffc72c;
  overflow: hidden;
  cursor: pointer;
}

.lat-map-static {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: filter 0.2s ease;
}

.lat-map-thumb:hover .lat-map-static,
.lat-map-thumb:focus .lat-map-static {
  filter: brightness(0.82);
}

.lat-map-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255,255,255,0.92);
  border-radius: 999px;
  padding: 6px 13px;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #1e88c9;
  pointer-events: none;
  transition: opacity 0.2s ease;
  white-space: nowrap;
}

.lat-map-play i {
  font-size: 13px;
  color: #ffc72c;
}

.lat-map-thumb:hover .lat-map-play {
  opacity: 0.85;
}

.lat-map-thumb.is-loaded .lat-map-static,
.lat-map-thumb.is-loaded .lat-map-play {
  display: none;
}

.lat-map-thumb.is-loaded {
  cursor: default;
}

.lat-map-thumb iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.lat-location-info {
  padding: 18px 20px;
  text-align: left;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  flex-grow: 1;
  min-width: 0;
}

.lat-location-name {
  font-size: 16px;
  font-weight: 800;
  margin: 0 0 7px;
  color: #111111;
  line-height: 1.25;
}

/* Injected by script on suburb pages only — no manual upkeep */
.lat-nearest-tag {
  display: inline-block;
  margin: 0 0 7px;
  padding: 3px 10px;
  border-radius: 999px;
  background: #eaf4fb;
  color: #1571ab;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2px;
}

.lat-location-address {
  font-style: normal;
  font-size: 13px;
  color: #666666;
  line-height: 1.5;
  margin: 0 0 14px;
}

.lat-location-address i {
  color: #ffc72c;
  margin-right: 5px;
}

.lat-loc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 9px 20px;
  background: transparent;
  border: 2px solid #1e88c9;
  color: #1e88c9;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  min-height: 40px;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  outline: 2px solid transparent;
  outline-offset: 3px;
  white-space: nowrap;
}

.lat-loc-btn:hover {
  background: #1e88c9;
  color: #ffffff;
}

.lat-loc-btn:focus-visible {
  outline-color: #111111;
}

@media (prefers-reduced-motion: reduce) {
  .lat-location-card { transition: none; }
  .lat-location-card:hover { transform: none; }
  .lat-map-static { transition: none; }
  .lat-map-play { transition: none; }
  .lat-loc-btn { transition: none; }
}

@media (max-width: 1150px) {
  .lat-state-group { grid-template-columns: 130px 1fr; gap: 22px; }
  .lat-map-thumb { width: 160px; }
}

/* Rail moves above the cards */
@media (max-width: 980px) {
  .lat-state-group { grid-template-columns: 1fr; gap: 14px; }
  .lat-state-rail {
    display: flex;
    align-items: baseline;
    gap: 10px;
    padding-left: 12px;
  }
  .lat-state-name { margin: 0; }
}

@media (max-width: 860px) {
  .lat-state-cards { grid-template-columns: 1fr; }
}

/* Cards flip back to vertical on small screens */
@media (max-width: 620px) {
  .lat-locations-section { padding: 50px 20px; }
  .lat-locations-header { margin-bottom: 30px; }
  .lat-location-card { flex-direction: column; min-height: 0; }
  .lat-map-thumb {
    width: 100%;
    height: 150px;
    border-right: none;
    border-bottom: 3px solid #ffc72c;
  }
  .lat-location-info { justify-content: flex-start; }
}

@media (max-width: 380px) {
  .lat-locations-heading { font-size: 26px; }
}
