/* =========================================================
   Inner pages (About Us, Services, Pool Equipment, Contact)
   Same colours, fonts and shapes as the homepage.
   ========================================================= */

/* ---------- Page banner ---------- */
.page-banner {
  position: relative;
  min-height: 460px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--black);
}
.page-banner__bg { position: absolute; inset: 0; }
.page-banner__bg img { left: 0; top: 0; width: 100%; height: 100%; object-fit: cover; }
.page-banner__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(15, 22, 29, 0.78) 0%, rgba(15, 22, 29, 0.5) 50%, rgba(0, 165, 255, 0.08) 100%);
}
.page-banner__inner {
  position: relative;
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  padding: 150px var(--pad) 72px;
  color: var(--white);
}
.page-banner__crumbs { display: flex; gap: 8px; font: 400 14px/1.45 var(--sans); color: rgba(252, 252, 252, 0.75); }
.page-banner__crumbs a { color: inherit; text-decoration: none; }
.page-banner__crumbs a:hover { color: var(--white); text-decoration: underline; }
.page-banner__crumbs [aria-current] { color: var(--white); }
.page-banner__title { margin-top: 12px; font-size: 64px; line-height: 1.05; font-weight: 600; color: var(--white); }
.page-banner__sub { max-width: 560px; margin-top: 14px; font: 400 20px/1.45 var(--sans); color: rgba(252, 252, 252, 0.9); }

/* ---------- Page content (block editor) ---------- */
.entry { background: var(--white); font-family: var(--sans); color: var(--text-soft); }
.entry > :not(.sp-section):not(.sp-cta):not(.sp-full) {
  max-width: 1280px;
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
  box-sizing: content-box;
}
.entry > :not(.sp-section):not(.sp-cta):not(.sp-full):first-child { padding-top: 64px; }
.entry > :not(.sp-section):not(.sp-cta):not(.sp-full):last-child { padding-bottom: 64px; }
.entry [id] { scroll-margin-top: 120px; }
.entry p { font-size: 17px; line-height: 1.7; }
.entry p + p { margin-top: 14px; }
.entry h2, .entry h3, .entry h4 { font-family: var(--serif); color: var(--black); font-weight: 600; line-height: 1.15; }
.entry h2 { font-size: 44px; margin-bottom: 18px; }
.entry h3 { font-size: 28px; margin-bottom: 10px; }
.entry h4 { font-size: 22px; margin-bottom: 8px; }
.entry * + h2, .entry * + h3 { margin-top: 28px; }
.entry a:not(.wp-block-button__link) { color: var(--blue); }
.entry ul, .entry ol { padding-left: 1.3em; line-height: 1.7; }
.entry ul { list-style: disc; }
.entry img { max-width: 100%; height: auto; }
.entry figure { margin: 0; }
.entry .sp-eyebrow { font: 400 24px/1.45 var(--serif); color: var(--gold); margin: 0 0 4px; }
.entry .sp-eyebrow + h2, .entry .sp-eyebrow + h3 { margin-top: 0; }
.entry .sp-lead { max-width: 760px; margin-left: auto; margin-right: auto; }

/* Buttons */
.entry .wp-block-buttons { margin-top: 28px; gap: 16px; }
.entry .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  height: 48px;
  padding: 0 28px;
  border-radius: 28px;
  background: var(--blue);
  color: var(--white);
  font: 400 16px/1 var(--sans);
  text-decoration: none;
  transition: background-color .2s ease, transform .2s ease;
}
.entry .wp-block-button__link:hover { background: var(--blue-hover); }
.entry .is-style-outline .wp-block-button__link { background: transparent; border: 1px solid var(--blue); color: var(--blue); }

/* ---------- Sections ---------- */
.sp-section {
  padding: 80px max(var(--pad), calc((100% - 1280px) / 2));
  background: var(--white);
}
.sp-section--light { background: var(--bg); }
.sp-section > .wp-block-group__inner-container > :first-child,
.sp-section > :first-child { margin-top: 0; }

.sp-rounded img { border-radius: 20px; width: 100%; }

/* Intro: image + text */
.entry .sp-intro { gap: 80px; margin: 0; }
.sp-intro .sp-rounded img { aspect-ratio: 412 / 526; object-fit: cover; }

/* Cards */
.entry .sp-cards { gap: 24px; margin-top: 48px; margin-bottom: 0; }
.entry .sp-cards + .sp-cards { margin-top: 24px; }
.entry .sp-cards--3 { max-width: calc(75% - 6px); margin-left: auto; margin-right: auto; }
.sp-card {
  padding: 32px 28px;
  border: 1px solid rgba(15, 22, 29, 0.12);
  border-radius: 20px;
  background: var(--white);
  transition: border-color .2s ease, transform .3s ease, box-shadow .3s ease;
}
.sp-section--light .sp-card { background: var(--white); }
.sp-card:hover { border-color: var(--blue); transform: translateY(-4px); box-shadow: 0 14px 30px rgba(15, 22, 29, 0.06); }
.entry .sp-card h3 { font-size: 24px; margin-top: 8px; }
.entry .sp-card p { font-size: 15px; line-height: 1.6; }
.entry .sp-card__num { font: 600 40px/1 var(--serif); color: var(--gold); }

/* Product cards */
.sp-card--product { padding: 20px 20px 28px; }
.sp-product {
  display: flex !important;
  align-items: center;
  justify-content: center;
  height: 200px;
  margin-bottom: 18px !important;
  border-radius: 100px;
  background: var(--bg);
}
.sp-product img { width: auto; max-width: 70%; max-height: 150px; object-fit: contain; mix-blend-mode: multiply; } /* hides white photo backgrounds */

/* Service rows */
.entry .sp-rows { margin-top: 56px; }
.sp-row + .sp-row { margin-top: 72px; }
.entry .sp-row .wp-block-columns { gap: 64px; margin: 0; }
.sp-row .sp-rounded img { aspect-ratio: 4 / 3; object-fit: cover; }
.entry .sp-row h3 { font-size: 34px; margin-top: 0; }

/* Call to action band */
.sp-cta {
  padding: 96px max(var(--pad), calc((100% - 960px) / 2));
  text-align: center;
  background:
    linear-gradient(90deg, rgba(15, 22, 29, 0.85), rgba(0, 60, 112, 0.75)),
    url("../assets/contact-bg.png") center / cover no-repeat;
}
.entry .sp-cta h2 { color: var(--white); margin-top: 0; }
.entry .sp-cta p { color: rgba(252, 252, 252, 0.85); }
.entry .sp-cta .wp-block-buttons { justify-content: center; }

/* ---------- Map (Contact page) ---------- */
.map { line-height: 0; background: var(--bg); }
.map iframe { width: 100%; height: 440px; border: 0; }

/* ---------- Desktop-only layout tweaks ---------- */
@media (min-width: 782px) {
  .sp-row:nth-child(even) .wp-block-columns { flex-direction: row-reverse; }
}

/* ---------- Tablet ---------- */
@media (max-width: 1199px) {
  .entry .sp-cards--4 { flex-wrap: wrap !important; }
  .entry .sp-cards--4 > .wp-block-column { flex-basis: calc(50% - 12px) !important; flex-grow: 0; }
  .entry .sp-cards--3 { max-width: none; flex-wrap: wrap !important; }
  .entry .sp-cards--3 > .wp-block-column { flex-basis: calc(50% - 12px) !important; flex-grow: 0; }
  .entry .sp-intro { gap: 48px; }
}

/* ---------- Mobile ---------- */
@media (max-width: 767px) {
  .page-banner { min-height: 340px; }
  .page-banner__inner { padding: 110px 16px 48px; text-align: center; }
  .page-banner__crumbs { justify-content: center; }
  .page-banner__title { font-size: 38px; }
  .page-banner__sub { margin: 10px auto 0; font-size: 16px; }

  .sp-section { padding: 48px 16px; }
  .sp-cta { padding: 64px 16px; }
  .entry > :not(.sp-section):not(.sp-cta):not(.sp-full) { padding-left: 16px; padding-right: 16px; }
  .entry h2 { font-size: 30px; }
  .entry h3 { font-size: 24px; }
  .entry p { font-size: 15px; }
  .entry .sp-eyebrow { font-size: 18px; }
  .entry .sp-intro { gap: 24px; }
  .sp-intro .sp-rounded img { aspect-ratio: 4 / 3; }
  .entry .sp-intro .wp-block-column:last-child { text-align: center; }
  .entry .sp-intro .wp-block-buttons { justify-content: center; }

  .entry .sp-cards { gap: 16px; margin-top: 32px; }
  .entry .sp-cards + .sp-cards { margin-top: 16px; }
  .entry .sp-cards--4:not(:has(.sp-card--product)) > .wp-block-column { flex-basis: 100% !important; }
  .entry .sp-cards > .wp-block-column { flex-basis: calc(50% - 8px) !important; }
  .sp-card { padding: 24px 20px; }
  .sp-card--product { padding: 12px 12px 20px; }
  .sp-product { height: 130px; margin-bottom: 12px !important; }
  .sp-product img { max-height: 96px; }
  .entry .sp-card--product h3 { font-size: 19px; }
  .entry .sp-card--product p { font-size: 13px; }

  .entry .sp-rows { margin-top: 32px; }
  .sp-row + .sp-row { margin-top: 48px; }
  .entry .sp-row .wp-block-columns { gap: 20px; }
  .entry .sp-row h3 { font-size: 26px; }

  .map iframe { height: 320px; }
}
