/* Centres page only. Uses tokens and components from style.css. */

/* ---------- Hero ---------- */
.centres-hero .hero-image-wrap { animation: centre-hero-in 900ms cubic-bezier(0.16, 1, 0.3, 1) both; }
.centres-hero .hero-image-wrap img { height: 420px; }
@keyframes centre-hero-in {
  from { opacity: 0; clip-path: inset(0 0 100% 0 round 22px); transform: translateY(14px); }
  to   { opacity: 1; clip-path: inset(0 0 0 0 round 22px);   transform: none; }
}
.centres-hero .btn-group { margin-top: 28px; }

/* ---------- Cards ---------- */
.location-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}
.location-card {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 300ms cubic-bezier(0.16, 1, 0.3, 1), box-shadow 300ms ease, opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}
.location-card.is-visible:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.location-card-media { aspect-ratio: 4 / 3; overflow: hidden; background: var(--surface-soft); }
.location-card-media img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}
.location-card:hover .location-card-media img { transform: scale(1.05); }
.location-card-body { display: flex; flex-direction: column; flex: 1; padding: 22px 22px 24px; }
.location-card h3 { font-size: 1.2rem; line-height: 1.25; margin-bottom: 8px; color: var(--navy); }
.centre-loc { display: flex; align-items: center; gap: 6px; color: var(--royal-blue); font-weight: 600; font-size: 0.92rem; margin-bottom: 12px; }
.centre-loc svg { flex: none; color: var(--gold); }
.centre-desc { color: var(--ink-muted); font-size: 0.95rem; line-height: 1.6; margin-bottom: 20px; }
.location-card-actions { margin-top: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.centre-link {
  color: var(--royal-blue); font-weight: 700; font-size: 0.92rem; text-decoration: none;
  border-bottom: 1.5px solid transparent; padding: 6px 0; transition: border-color 200ms ease, color 200ms ease;
}
.centre-link:hover { color: var(--royal-blue-dark); border-bottom-color: var(--gold); }

/* ---------- Neighbourhood tabs + map ---------- */
.centre-tabs {
  display: inline-flex; gap: 6px; padding: 5px; margin-bottom: 28px;
  background: var(--surface-soft); border: 1px solid var(--border); border-radius: var(--radius-full);
}
.centre-tab {
  font: 700 0.95rem var(--font-body); color: var(--ink-secondary);
  padding: 11px 22px; min-height: 44px; border: 0; border-radius: var(--radius-full);
  background: transparent; cursor: pointer; transition: background 220ms ease, color 220ms ease, box-shadow 220ms ease;
}
.centre-tab:hover { color: var(--royal-blue); }
.centre-tab[aria-selected="true"] { background: var(--royal-blue); color: var(--white); box-shadow: var(--shadow-blue); }
.centre-tab:focus-visible, .centre-link:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.tabs-wrap { text-align: center; }

.centre-panel {
  display: grid; grid-template-columns: 0.9fr 1.1fr;
  background: var(--white); border: 1px solid var(--border-light); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md); overflow: hidden; min-height: 420px;
  transition: opacity 180ms ease, transform 180ms ease;
}
.centre-panel.is-swapping { opacity: 0; transform: translateY(8px); }
.panel-info { padding: 36px 36px 32px; display: flex; flex-direction: column; }
.panel-info h3 { font-size: 1.6rem; color: var(--navy); margin-bottom: 8px; }
.panel-desc { color: var(--ink-secondary); margin: 4px 0 22px; line-height: 1.65; }
.panel-facts { margin-bottom: 26px; border-top: 1px solid var(--border-light); }
.panel-facts > div { display: grid; grid-template-columns: 96px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--border-light); font-size: 0.95rem; }
.panel-facts dt { color: var(--ink-muted); font-weight: 600; }
.panel-facts dd { color: var(--ink-primary); }
.panel-facts a { color: var(--royal-blue); font-weight: 600; text-decoration: none; }
.panel-actions { margin-top: auto; display: flex; flex-wrap: wrap; gap: 12px; }
.panel-map { min-height: 320px; background: var(--surface-soft); }
.panel-map iframe { width: 100%; height: 100%; min-height: 320px; border: 0; display: block; }

/* ---------- Trust ---------- */
.trust-layout { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: 64px; align-items: start; }
.trust-copy h2 { margin-bottom: 18px; }
.trust-copy p { color: var(--ink-secondary); font-size: 1.05rem; line-height: 1.75; max-width: 46ch; }
.benefit-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0 40px; }
.benefit { padding: 26px 0; border-top: 2px solid var(--border); }
.benefit:nth-child(-n+2) { border-top-color: var(--gold-border); }
.benefit-icon {
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  display: grid; place-items: center; background: var(--blue-soft); color: var(--royal-blue); margin-bottom: 14px;
}
.benefit h3 { font-size: 1.1rem; color: var(--navy); margin-bottom: 6px; }
.benefit p { color: var(--ink-muted); font-size: 0.97rem; line-height: 1.6; }

.centres-cta .btn-group { justify-content: center; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) { .location-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) {
  .centre-panel { grid-template-columns: 1fr; }
  .panel-map, .panel-map iframe { min-height: 280px; }
  .trust-layout { grid-template-columns: 1fr; gap: 32px; }
  .centres-hero .hero-image-wrap img { height: 320px; }
}
@media (max-width: 640px) {
  .location-grid { grid-template-columns: 1fr; gap: 20px; }
  .location-card h3 { font-size: 1.35rem; }
  .location-card-actions .btn { flex: 1 1 auto; justify-content: center; min-height: 46px; }
  .centre-tabs { display: grid; grid-template-columns: 1fr 1fr; border-radius: var(--radius-lg); width: 100%; }
  .centre-tab { padding: 11px 10px; }
  .panel-info { padding: 26px 20px; }
  .panel-facts > div { grid-template-columns: 1fr; gap: 2px; }
  .panel-actions .btn { width: 100%; justify-content: center; }
  .benefit-list { grid-template-columns: 1fr; }
  .benefit:nth-child(2) { border-top-color: var(--border); }
  .centres-cta .btn-group .btn { width: 100%; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .centres-hero .hero-image-wrap { animation: none; }
  .location-card:hover, .location-card:hover .location-card-media img { transform: none; }
}
