/*
Theme Name:   First Environment
Theme URI:    https://github.com/understrap/understrap-child
Description:  Child theme of the Understrap parent theme, scaffolded from the official understrap/understrap-child. All custom development for the first-environment site lives here.
Author:       s7media
Author URI:   https://s7media.co.uk
Template:     understrap
Version:      1.0.0
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  first-environment
Tags:         understrap, bootstrap, child-theme, translation-ready
*/

/* ------------------------------------------------------------------------
 * Add your custom CSS below. This file is enqueued after the Understrap
 * parent stylesheet, so anything here overrides the parent.
 * ---------------------------------------------------------------------- */

/* ============================================================
 * Homepage design styles (migrated from the static concept).
 * Self-contained: all custom properties are defined in :root below.
 * ============================================================ */

    :root {
      --fe-blue: #004b9b;
      --fe-blue-dark: #001c5a;
      --fe-blue-soft: #edf4fc;
      --fe-text: #17324a;
      --fe-muted: #5d7184;
      --fe-border: #d9e5f0;
      --fe-bg: #f5f8fc;
      --fe-white: #ffffff;
      --fe-shadow: 0 18px 48px rgba(0, 28, 90, 0.08);
      --fe-radius: 22px;
    }

    html { scroll-behavior: smooth; }

    body {
      font-family: 'Libre Franklin', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
      color: var(--fe-text);
      background: var(--fe-white);
      line-height: 1.65;
    }

    h1, h2, h3, h4, h5, h6, .display-6, .navbar-brand {
      font-family: /*'Archivo', */'Libre Franklin', Arial, sans-serif;
      letter-spacing: -0.03em;
    }

    a {
      color: inherit;
      text-decoration: none;
    }

    .text-muted-custom { color: var(--fe-muted); }
    .section-space { padding: 5rem 0; }

    .eyebrow {
      display: inline-flex;
      align-items: center;
      gap: .55rem;
      padding: .5rem .85rem;
      border-radius: 999px;
      background: rgba(255,255,255,.12);
      border: 1px solid rgba(255,255,255,.18);
      color: rgba(255,255,255,.94);
      font-size: .82rem;
      letter-spacing: .04em;
      text-transform: uppercase;
      font-weight: 700;
    }

    .section-kicker {
      display: inline-flex;
      align-items: center;
      gap: .5rem;
      padding: .45rem .8rem;
      border-radius: 999px;
      background: var(--fe-blue-soft);
      color: var(--fe-blue);
      font-size: .8rem;
      letter-spacing: .04em;
      text-transform: uppercase;
      font-weight: 700;
      margin-bottom: 1rem;
    }

    .site-header {
      position: sticky;
      top: 0;
      z-index: 1100;
      background: rgba(255,255,255,.94);
      backdrop-filter: blur(14px);
      border-bottom: 1px solid rgba(217, 229, 240, .9);
      transition: box-shadow .25s ease;
    }

    .site-header.scrolled {
      box-shadow: 0 18px 38px rgba(0, 28, 90, .08);
    }

    .navbar-brand {
      font-weight: 800;
      color: var(--fe-blue-dark);
      line-height: 1.1;
    }

    .navbar-brand small {
      font-family: 'Libre Franklin', sans-serif;
      letter-spacing: 0;
    }

    .navbar-brand img {
      height:80px;
      width:auto;
    }

    .brand-mark {
      width: 2.5rem;
      height: 2.5rem;
      border-radius: 14px;
      display: inline-grid;
      place-items: center;
      background: linear-gradient(145deg, var(--fe-blue), var(--fe-blue-dark));
      color: #fff;
      box-shadow: 0 10px 24px rgba(0, 75, 155, .2);
    }

    .nav-link {
      font-weight: 600;
      color: var(--fe-text);
      padding: .9rem 1rem !important;
      position: relative;
      cursor: pointer;
    }

    .nav-link::after {
      content: '';
      position: absolute;
      left: 1rem;
      right: 1rem;
      bottom: .5rem;
      height: 2px;
      border-radius: 999px;
      background: var(--fe-blue);
      transform: scaleX(0);
      transform-origin: left center;
      transition: transform .2s ease;
    }

    .nav-item.mega-open > .mega-menu-anchor > .nav-link::after,
    .nav-link:hover::after,
    .nav-link:focus::after {
      transform: scaleX(1);
    }

    .btn-fe-primary {
      background: var(--fe-blue);
      border-color: var(--fe-blue);
      color: #fff;
      border-radius: 999px;
      padding: .9rem 1.2rem;
      font-weight: 700;
      box-shadow: 0 12px 28px rgba(0, 75, 155, .16);
    }

    .btn-fe-primary:hover,
    .btn-fe-primary:focus {
      background: var(--fe-blue-dark);
      border-color: var(--fe-blue-dark);
      color: #fff;
    }

    .btn-fe-secondary {
      background: var(--fe-blue-dark);
      border-color: var(--fe-blue-dark);
      color: #fff;
      border-radius: 999px;
      padding: .9rem 1.2rem;
      font-weight: 700;
      box-shadow: 0 12px 28px rgba(0, 75, 155, .16);
    }

    .btn-fe-secondary:hover,
    .btn-fe-secondary:focus {
      background: var(--fe-blue);
      border-color: var(--fe-blue);
      color: #fff;
    }

    .btn-fe-outline {
      border: 1px solid rgba(255,255,255,.24);
      color: #fff;
      border-radius: 999px;
      padding: .9rem 1.2rem;
      font-weight: 700;
      background: rgba(255,255,255,.08);
    }

    .btn-fe-outline:hover,
    .btn-fe-outline:focus {
      background: #fff;
      border-color: #fff;
      color: var(--fe-blue-dark);
    }

    .nav-utility {
      border-left: 1px solid var(--fe-border);
      margin-left: 1rem;
      padding-left: 1rem;
    }

    .mega-menu-anchor {
      position: relative;
    }

    .mega-menu {
      position: absolute;
      left: 50%;
      top: calc(100% + 10px);
      transform: translateX(-50%) translateY(8px);
      width: min(1080px, calc(100vw - 2rem));
      background: #fff;
      border: 1px solid var(--fe-border);
      border-radius: 24px;
      box-shadow: 0 28px 50px rgba(0, 28, 90, .14);
      padding: 1rem;
      opacity: 0;
      visibility: hidden;
      pointer-events: none;
      transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
      z-index: 1300;
    }

    .mega-menu.mega-menu-narrow {
      width: min(900px, calc(100vw - 2rem));
    }

    .nav-item.mega-open > .mega-menu-anchor > .mega-menu {
      opacity: 1;
      visibility: visible;
      pointer-events: auto;
      transform: translateX(-50%) translateY(0);
    }

    .dropdown-header {
      color: var(--fe-blue-dark);
      font-size: .78rem;
      font-weight: 800;
      letter-spacing: .08em;
      text-transform: uppercase;
      padding: .2rem 0 .8rem;
    }

    .mega-menu-card {
      display: block;
      height: 100%;
      border: 1px solid var(--fe-border);
      border-radius: 18px;
      padding: 1rem;
      background: linear-gradient(180deg, #fff 0%, #f9fbfe 100%);
      transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
    }

    .mega-menu-card:hover,
    .mega-menu-card:focus {
      transform: translateY(-4px);
      border-color: rgba(0, 75, 155, .35);
      box-shadow: 0 18px 34px rgba(0, 28, 90, .08);
    }

    .mega-menu-card h6 {
      margin: 0 0 .4rem;
      font-weight: 700;
      color: var(--fe-blue-dark);
      font-family: 'Archivo', sans-serif;
    }

    .mega-menu-card p {
      margin: 0;
      color: var(--fe-muted);
      font-size: .92rem;
      line-height: 1.5;
    }

    .offcanvas.offcanvas-end {
      width: min(92vw, 420px);
      z-index: 2000;
    }

    .mobile-subnav {
      padding-left: 1rem;
      border-left: 2px solid var(--fe-border);
      margin: .4rem 0 1rem 1rem;
    }

    .mobile-subnav a {
      display: block;
      padding: .45rem 0;
      color: var(--fe-muted);
      font-weight: 600;
    }

    .hero {
      position: relative;
      overflow: hidden;
      background:
        radial-gradient(circle at top left, rgba(255,255,255,.18), transparent 28%),
        radial-gradient(circle at bottom right, rgba(255,255,255,.08), transparent 30%),
        linear-gradient(135deg, #00286b 0%, #004b9b 55%, #0f62c2 100%);
      color: #fff;
      padding: 5rem 0 4rem;
    }

    .hero-copy,
    .hero-visual {
      position: relative;
      z-index: 2;
    }

    .hero h1 {
      font-size: clamp(2.6rem, 5vw, 4.2rem);
      line-height: .98;
      margin-bottom: 1.25rem;
      font-weight: 700;
    }

    .hero p.lead {
      font-size: 1.14rem;
      color: rgba(255,255,255,.88);
      max-width: 40rem;
      margin-bottom: 1.75rem;
    }

    .hero-panel {
      background: rgba(255,255,255,.96);
      color: var(--fe-text);
      border-radius: 28px;
      padding: 1.4rem;
      box-shadow: 0 28px 56px rgba(0, 18, 56, .2);
      max-width: 31rem;
      margin-left: auto;
    }

    .hero-panel-main {
      padding: 1.35rem;
    }

    .hero-checklist {
      display: grid;
      gap: .75rem;
      margin: 1rem 0 0;
      padding: 0;
    }

    .hero-checklist li {
      display: flex;
      align-items: flex-start;
      gap: .7rem;
      color: var(--fe-muted);
    }

    .hero-checklist i { color: var(--fe-blue); margin-top: .15rem; }

    .info-chip {
      display: inline-flex;
      align-items: center;
      gap: .45rem;
      padding: .45rem .7rem;
      border-radius: 999px;
      background: var(--fe-blue-soft);
      color: var(--fe-blue);
      font-weight: 700;
      font-size: .84rem;
      margin-bottom: .85rem;
    }

    .services-overlap {
      margin-top: -2.2rem;
      position: relative;
      z-index: 5;
    }

    .service-card {
      height: 100%;
      background: #fff;
      border: 1px solid var(--fe-border);
      border-radius: var(--fe-radius);
      padding: 1.4rem;
      box-shadow: var(--fe-shadow);
      transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
    }

    .service-card:hover {
      transform: translateY(-5px);
      border-color: rgba(0, 75, 155, .34);
      box-shadow: 0 24px 42px rgba(0, 28, 90, .1);
    }

    .service-icon {
      width: 3.15rem;
      height: 3.15rem;
      display: inline-grid;
      place-items: center;
      border-radius: 18px;
      background: linear-gradient(145deg, var(--fe-blue-soft), #fff);
      border: 1px solid var(--fe-border);
      color: var(--fe-blue);
      font-size: 1.2rem;
      margin-bottom: 1rem;
    }

    .service-card h3 {
      font-size: 1.08rem;
      margin-bottom: .65rem;
      font-weight: 700;
    }

    .service-card p {
      color: var(--fe-muted);
      margin-bottom: 1rem;
    }

    .card-link {
      font-weight: 700;
      color: var(--fe-blue);
      display: inline-flex;
      align-items: center;
      gap: .4rem;
    }

    .trust-strip {
      background: var(--fe-bg);
      border-top: 1px solid var(--fe-border);
      border-bottom: 1px solid var(--fe-border);
    }

    .trust-item {
      padding: 1.1rem 1rem;
      border-radius: 18px;
      background: #fff;
      border: 1px solid var(--fe-border);
      text-align: center;
      height: 100%;
    }

    .trust-item strong {
      display: block;
      font-size: 1rem;
      color: var(--fe-blue-dark);
      margin-bottom: .35rem;
      font-family: 'Archivo', sans-serif;
    }

    .trust-item span {
      color: var(--fe-muted);
      font-weight: 600;
      font-size: .95rem;
    }

    .split-card {
      height: 100%;
      background: #fff;
      border: 1px solid var(--fe-border);
      border-radius: 28px;
      overflow: hidden;
      box-shadow: var(--fe-shadow);
    }

    .sector-row { min-height: 360px; }

    .split-media {
      min-height: 100%;
      height: 100%;
      background-size: cover;
      background-position: center;
      position: relative;
    }

    .split-media::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(180deg, transparent 0%, rgba(0, 28, 90, .14) 100%);
    }

    .split-copy { padding: 2rem; }

    .badge-soft {
      display: inline-flex;
      align-items: center;
      gap: .45rem;
      padding: .45rem .7rem;
      border-radius: 999px;
      background: #eef5ff;
      color: var(--fe-blue);
      font-weight: 700;
      font-size: .82rem;
      margin-bottom: 1rem;
    }

    .sector-tags {
      display: flex;
      flex-wrap: wrap;
      gap: .55rem;
      margin-top: 1rem;
    }

    .sector-tags span {
      background: var(--fe-bg);
      border: 1px solid var(--fe-border);
      color: var(--fe-muted);
      border-radius: 999px;
      padding: .35rem .6rem;
      font-size: .75rem;
      font-weight: 600;
    }

    .feature-grid {
      display: grid;
      grid-template-columns: repeat(2, minmax(0, 1fr));
      gap: 1rem;
    }

    .feature-box {
      background: #fff;
      border: 1px solid var(--fe-border);
      border-radius: 20px;
      padding: 1.2rem;
      height: 100%;
    }

    .feature-box i {
      color: var(--fe-blue);
      font-size: 1.2rem;
      margin-bottom: .75rem;
      display: inline-block;
    }

    .feature-box h4 {
      font-size: 1rem;
      font-weight: 700;
      margin-bottom: .4rem;
    }

    .feature-box p {
      color: var(--fe-muted);
      margin: 0;
      font-size: .95rem;
    }

    .news-card {
      height: 100%;
      background: #fff;
      border: 1px solid var(--fe-border);
      border-radius: 22px;
      overflow: hidden;
      box-shadow: var(--fe-shadow);
    }

    .news-card .thumb {
      aspect-ratio: 16/10;
      background: linear-gradient(135deg, rgba(0,75,155,.18), rgba(0,28,90,.4)), center / cover no-repeat;
    }

    .news-card .body { padding: 1.35rem; }

    .news-card small {
      color: var(--fe-muted);
      font-weight: 700;
      text-transform: uppercase;
      letter-spacing: .05em;
    }

    .cta-panel {
      background: linear-gradient(135deg, #003d88 0%, #001c5a 100%);
      border-radius: 30px;
      padding: 2.25rem;
      color: #fff;
      position: relative;
      overflow: hidden;
    }

    .site-footer {
      padding: 2rem 0 3rem;
      border-top: 1px solid var(--fe-border);
      background: #fff;
    }

    .footer-card {
      border: 1px solid var(--fe-border);
      border-radius: 22px;
      padding: 1.4rem;
      background: var(--fe-bg);
      height: 100%;
    }

    @media (max-width: 1199.98px) {
      .mega-menu,
      .mega-menu.mega-menu-narrow {
        display: none !important;
      }
    }

    @media (max-width: 991.98px) {
      .hero { padding-top: 3.8rem; }
      .hero-panel { margin: 2rem 0 0; max-width: none; }
      .nav-utility { border-left: 0; margin-left: 0; padding-left: 0; }
      .sector-row { min-height: 0; }
      .split-media { min-height: 280px; }
    }

    @media (max-width: 767.98px) {
      .section-space { padding: 4rem 0; }
      .services-overlap { margin-top: -1.25rem; }
      .feature-grid { grid-template-columns: 1fr; }
      .split-copy, .cta-panel { padding: 1.5rem; }
    }


    .hero .row {
      align-items: stretch !important;
    }

    .hero .col-lg-7,
    .hero .col-lg-5 {
      display: flex;
    }

    .hero-copy {
      display: flex;
      flex-direction: column;
      justify-content: center;
      width: 100%;
    }

    .hero-visual {
      position: relative;
      overflow: hidden;
      width: 100%;
      min-height: 100%;
      height: auto;
      border-radius: 28px;
      background-size: cover;
      background-position: center;
      background-repeat: no-repeat;
      box-shadow: 0 28px 56px rgba(0, 18, 56, .2);
    }

    .hero-visual::before {
      content: "";
      position: absolute;
      inset: 0;
      border-radius: 28px;
      background: linear-gradient(180deg, rgba(0, 28, 90, .08), rgba(0, 28, 90, .22));
    }

    .search-trigger {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 46px;
      height: 46px;
      border: 1px solid var(--fe-border);
      border-radius: 999px;
      background: #fff;
      color: var(--fe-blue-dark);
      transition: all .2s ease;
    }

    .search-trigger:hover,
    .search-trigger:focus {
      background: var(--fe-blue-soft);
      border-color: rgba(0, 75, 155, .35);
      color: var(--fe-blue);
    }

    .nav-search {
      margin-left: .75rem;
      margin-right: .25rem;
    }

    .search-modal .modal-content {
      border: 0;
      border-radius: 24px;
      overflow: hidden;
      box-shadow: 0 24px 60px rgba(0, 28, 90, .18);
    }

    .search-modal .modal-body {
      padding: 2rem;
    }

    .search-modal .form-control {
      min-height: 58px;
      border-radius: 16px;
      border: 1px solid var(--fe-border);
      padding-left: 1rem;
      padding-right: 1rem;
      font-size: 1.05rem;
    }

    .search-modal .form-control:focus {
      border-color: rgba(0, 75, 155, .4);
      box-shadow: 0 0 0 .25rem rgba(0, 75, 155, .12);
    }

    .mobile-search {
      padding-bottom: 1rem;
      margin-bottom: 1rem;
      border-bottom: 1px solid var(--fe-border);
    }

    .mobile-search .form-control {
      min-height: 48px;
      border-radius: 14px;
    }

    .mobile-search .btn {
      border-radius: 14px;
    }

    @media (min-width: 992px) {
      .hero-visual {
        min-height: 100%;
      }
    }

    @media (max-width: 991.98px) {
      .hero .col-lg-7,
      .hero .col-lg-5 {
        display: block;
      }

      .hero-visual {
        min-height: 320px;
        margin-top: 1.5rem;
      }
    }

    /* Accreditations strip: designed to become an ACF gallery loop */
    .accreditations-strip {
      position: relative;
      z-index: 6;
      background: #fff;
      border-bottom: 1px solid var(--fe-border);
      box-shadow: 0 16px 38px rgba(0, 28, 90, .06);
    }

    .accreditations-panel {
      background: #fff;
      border-radius: 24px;
      padding: 1.15rem;
      margin-top: -2rem;
    }

    .accreditations-title {
      color: var(--fe-blue-dark);
      font-weight: 800;
      font-size: .82rem;
      letter-spacing: .08em;
      text-transform: uppercase;
      margin-bottom: .9rem;
    }

    .accreditation-logo-grid {
      display: flex;
      flex-wrap: wrap;
      justify-content: center;
      align-items: stretch;
      gap: .5rem;
    }

    .accreditation-logo {
      flex: 1 1 130px;
      max-width: 180px;
      min-height: 92px;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: .9rem 1rem;
      border-radius: 18px;
      background: #fff;
    }

    /* Every logo is capped to the same height and centred, so logos of very
       different shapes still line up cleanly against their neighbours. */
    .accreditation-logo img {
      display: block;
      width: auto;
      height: auto;
      max-width: 100%;
      max-height: 52px;
      object-fit: contain;
    }

    .services-overlap {
      margin-top: 0;
    }

    /* Softer colourways to break up white/blue without reverting to the old palette */
    .section-bg-mist {
      background:
        radial-gradient(circle at top right, rgba(0, 75, 155, .08), transparent 34%),
        linear-gradient(180deg, #f7fbff 0%, #edf4fc 100%);
      border-top: 1px solid var(--fe-border);
      border-bottom: 1px solid var(--fe-border);
    }

    .section-bg-soft-blue {
      background:
        linear-gradient(135deg, rgba(0, 75, 155, .08) 0%, rgba(0, 28, 90, .03) 100%),
        #f5f8fc;
      border-top: 1px solid var(--fe-border);
      border-bottom: 1px solid var(--fe-border);
    }

    .site-footer-blue {
      background:
        radial-gradient(circle at top left, rgba(255,255,255,.09), transparent 32%),
        linear-gradient(135deg, #002b68 0%, #001c5a 100%);
    }

    .site-footer-blue a {
      color: rgba(255,255,255,.72);
    }

    .site-footer-blue a:hover,
    .site-footer-blue a:focus {
      color: #fff;
    }

    @media (max-width: 767.98px) {
      .accreditations-panel {
        margin-top: 0;
      }

      .accreditation-logo {
        flex-basis: 90px;
        max-width: 130px;
        min-height: 76px;
      }

      .accreditation-logo img {
        max-height: 44px;
      }
    }

    footer ul {
      padding:0;
      margin:0;
      list-style:none;
    }

    footer ul li a {
      color: rgba(255,255,255,.72);
    }

    .small {
      font-size:90%;
    }

    .footer-social {
      display: flex;
      flex-wrap: wrap;
      gap: .5rem;
      margin-top: 1rem;
    }

    .footer-social a {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 2.25rem;
      height: 2.25rem;
      border-radius: 50%;
      border: 1px solid rgba(255,255,255,.2);
      color: rgba(255,255,255,.8) !important;
      font-size: 1.05rem;
      transition: background-color .2s ease, color .2s ease, border-color .2s ease;
    }

    .footer-social a:hover,
    .footer-social a:focus {
      background: #fff;
      border-color: #fff;
      color: var(--fe-blue-dark) !important;
    }

    .footer-legal {
      display: flex;
      flex-wrap: wrap;
      gap: .35rem 1.1rem;
      padding: 0;
      margin: 0;
      list-style: none;
    }

    @media (min-width: 768px) {
      .footer-legal {
        justify-content: flex-end;
      }
    }

/* ============================================================
 * Service / Sector page template (page-templates/service-sector.php)
 * ============================================================ */

.page-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  padding: 5rem 0 4rem;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, .14), transparent 30%),
    linear-gradient(135deg, #00286b 0%, #004b9b 55%, #0f62c2 100%);
}

.page-hero.has-image {
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.page-hero.has-image::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 28, 90, .62), rgba(0, 28, 90, .82));
}

.page-hero .container {
  position: relative;
  z-index: 2;
}

.page-hero h1 {
  font-size: clamp(2.2rem, 4.2vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.05;
  margin-bottom: .85rem;
}

.page-hero .page-hero-sub {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, .9);
  max-width: 44rem;
  margin: 0;
}

.page-content {
  padding: 4rem 0 5rem;
}

.page-content .lead {
  font-size: 1.2rem;
  color: var(--fe-text);
  margin-bottom: 1.5rem;
}

.page-content-body {
  color: var(--fe-muted);
}

.page-content-body h2,
.page-content-body h3,
.page-content-body h4 {
  color: var(--fe-text);
  margin-top: 2rem;
  margin-bottom: .75rem;
}

.page-content-body img {
  border-radius: 16px;
  height: auto;
}

@media (max-width: 767.98px) {
  .page-hero {
    padding: 3.5rem 0 3rem;
  }

  .page-content {
    padding: 3rem 0 3.5rem;
  }
}

/* ============================================================
 * Homepage hero carousel (front-page.php, "Slideshow" mode)
 * ============================================================ */

.hero-carousel {
  padding: 0;
}

.hero-carousel .carousel-item {
  min-height: min(78vh, 620px);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  position: relative;
}

.hero-carousel .carousel-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(0, 28, 90, .84) 0%, rgba(0, 40, 107, .55) 55%, rgba(0, 40, 107, .28) 100%);
}

.hero-carousel .container {
  position: relative;
  z-index: 2;
}

.hero-slide-copy {
  max-width: 42rem;
  color: #fff;
  padding: 3rem 0;
}

.hero-slide-copy h1 {
  font-size: clamp(2.2rem, 4.6vw, 3.8rem);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.03;
  margin-bottom: 1rem;
}

.hero-slide-copy .lead {
  font-size: 1.15rem;
  color: rgba(255, 255, 255, .9);
  max-width: 40rem;
  margin-bottom: 1.6rem;
}

.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next {
  width: 6%;
  opacity: .75;
}

.hero-carousel .carousel-control-prev:hover,
.hero-carousel .carousel-control-next:hover {
  opacity: 1;
}

.hero-carousel .carousel-indicators {
  margin-bottom: 1.4rem;
}

@media (max-width: 767.98px) {
  .hero-carousel .carousel-item {
    min-height: 74vh;
  }

  .hero-slide-copy {
    padding: 2rem 0;
  }
}

/* Slideshow constrained to the hero-visual column ("Beside the text" layout) */

.hero-visual-carousel {
  width: 100%;
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 28px 56px rgba(0, 18, 56, .2);
}

/* Desktop: the hero column is a flex box, so the carousel is stretched to the
   text column's height and this chain lets the image fill it. Mobile: the
   column is block, height:100% collapses to auto and the carousel shrink-wraps
   to the slide's min-height (no empty strip under the rounded corners). */
.hero-visual-carousel,
.hero-visual-carousel .carousel-inner,
.hero-visual-carousel .carousel-item {
  height: 100%;
}

.hero-visual-carousel .carousel-item {
  position: relative;
  min-height: 400px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-visual-carousel .carousel-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 28, 90, .08), rgba(0, 28, 90, .22));
}

@media (max-width: 991.98px) {
  .hero-visual-carousel .carousel-item {
    min-height: 320px;
  }
}

/* ============================================================
 * Case Studies (CPT: archive-case_study.php / single-case_study.php)
 * ============================================================ */

.cs-meta {
  margin: 2rem 0 0;
  font-weight: 600;
  font-size: .95rem;
}

.cs-meta-sep {
  margin: 0 .6rem;
  opacity: .5;
}

.cs-stats {
  margin: 2rem 0 1rem;
  text-align: center;
}

.cs-stats strong {
  display: block;
  font-size: clamp(1.8rem, 3.4vw, 2.6rem);
  font-weight: 800;
  color: var(--fe-blue-dark);
  line-height: 1.05;
}

.cs-stats span {
  display: block;
  margin-top: .35rem;
  color: var(--fe-muted);
  font-size: .9rem;
}

.fe-gallery {
  margin: 2.5rem 0;
}

.fe-gallery > a {
  display: block;
}

.cs-quote {
  margin: 2.5rem 0;
  padding: 1.75rem 2rem;
  border-left: 4px solid var(--fe-blue);
  background: var(--fe-blue-soft);
  border-radius: 0 18px 18px 0;
}

.cs-quote p {
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--fe-text);
  margin: 0 0 .75rem;
}

.cs-quote cite {
  font-style: normal;
  font-weight: 700;
  color: var(--fe-blue-dark);
  font-size: .95rem;
}

.cs-related {
  margin: 2.5rem 0;
}

.cs-related .service-card h3 {
  margin-bottom: 0;
}

/* ============================================================
 * News index & post archives (home.php / archive.php)
 * ============================================================ */

.news-filter {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.news-filter-pill {
  display: inline-block;
  padding: .5rem .95rem;
  border-radius: 999px;
  border: 1px solid var(--fe-border);
  background: #fff;
  color: var(--fe-muted);
  font-weight: 600;
  font-size: .85rem;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.news-filter-pill:hover,
.news-filter-pill:focus,
.news-filter-pill.is-active {
  background: var(--fe-blue);
  border-color: var(--fe-blue);
  color: #fff;
}

.news-card-dot {
  margin: 0 .4rem;
  opacity: .5;
}

.news-card .body h2 a {
  color: var(--fe-blue-dark);
}

.news-card .body h2 a:hover,
.news-card .body h2 a:focus {
  color: var(--fe-blue);
}

/* Understrap pagination inside our archives */
#main .pagination {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  justify-content: center;
  margin: 3.5rem 0 0;
  padding: 0;
  list-style: none;
}

#main .pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.6rem;
  height: 2.6rem;
  padding: 0 .6rem;
  border-radius: 12px;
  border: 1px solid var(--fe-border);
  background: #fff;
  color: var(--fe-text);
  font-weight: 700;
}

#main .pagination .page-numbers.current,
#main .pagination .page-numbers:hover,
#main .pagination .page-numbers:focus {
  background: var(--fe-blue);
  border-color: var(--fe-blue);
  color: #fff;
}

/* ============================================================
 * Single blog post (single.php)
 * ============================================================ */

.post-hero-meta {
  color: rgba(255, 255, 255, .82);
  font-weight: 600;
  font-size: .95rem;
  margin: 1rem 0 0;
}

.page-hero .eyebrow a {
  color: inherit !important;
}

/* Article typography inside .page-content-body */
.page-content-body {
  font-size: 1.05rem;
  line-height: 1.75;
}

.page-content-body > *:first-child {
  margin-top: 0;
}

.page-content-body p {
  margin: 0 0 1.35rem;
}

.page-content-body h2 {
  font-size: 1.6rem;
  font-weight: 700;
}

.page-content-body h3 {
  font-size: 1.3rem;
  font-weight: 700;
}

.page-content-body ul,
.page-content-body ol {
  margin: 0 0 1.35rem;
  padding-left: 1.4rem;
}

.page-content-body li {
  margin-bottom: .5rem;
}

.page-content-body a {
  color: var(--fe-blue);
  text-decoration: underline;
  text-underline-offset: .15em;
}

.page-content-body a:hover,
.page-content-body a:focus {
  color: var(--fe-blue-dark);
}

.page-content-body blockquote {
  margin: 1.75rem 0;
  padding: 1.25rem 1.5rem;
  border-left: 4px solid var(--fe-blue);
  background: var(--fe-blue-soft);
  border-radius: 0 16px 16px 0;
  font-size: 1.15rem;
  color: var(--fe-text);
}

.page-content-body blockquote p:last-child {
  margin-bottom: 0;
}

.page-content-body figure {
  margin: 1.75rem 0;
}

.page-content-body figcaption {
  margin-top: .5rem;
  font-size: .875rem;
  color: var(--fe-muted);
  text-align: center;
}

.page-content-body hr {
  margin: 2.5rem 0;
  border: 0;
  border-top: 1px solid var(--fe-border);
}

.post-tags {
  margin-top: 2rem;
  font-size: .9rem;
  color: var(--fe-muted);
}

.post-tags-label {
  font-weight: 700;
  color: var(--fe-text);
}

.post-tags a {
  display: inline-block;
  margin: 0 .35rem .35rem 0;
  padding: .3rem .7rem;
  border-radius: 999px;
  background: var(--fe-bg);
  border: 1px solid var(--fe-border);
  color: var(--fe-muted);
  font-weight: 600;
}

.post-tags a:hover,
.post-tags a:focus {
  border-color: var(--fe-blue);
  color: var(--fe-blue);
}

.post-author {
  display: flex;
  gap: 1.1rem;
  margin-top: 2.5rem;
  padding: 1.5rem;
  border: 1px solid var(--fe-border);
  border-radius: var(--fe-radius);
  background: var(--fe-bg);
}

.post-author-avatar {
  border-radius: 50%;
  flex-shrink: 0;
  width: 64px;
  height: 64px;
}

.post-author strong {
  display: block;
  color: var(--fe-blue-dark);
  margin-bottom: .25rem;
}

.post-author p {
  margin: 0;
  color: var(--fe-muted);
  font-size: .95rem;
}

.post-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 2.5rem;
}

.post-nav-link {
  display: block;
  padding: 1.1rem 1.3rem;
  border: 1px solid var(--fe-border);
  border-radius: 18px;
  background: #fff;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.post-nav-link:hover,
.post-nav-link:focus {
  border-color: rgba(0, 75, 155, .35);
  box-shadow: var(--fe-shadow);
  transform: translateY(-2px);
}

.post-nav-next {
  text-align: right;
}

.post-nav-dir {
  display: block;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--fe-blue);
  margin-bottom: .3rem;
}

.post-nav-title {
  display: block;
  font-weight: 700;
  color: var(--fe-blue-dark);
  line-height: 1.35;
}

.post-related {
  border-top: 1px solid var(--fe-border);
  margin-top: 3.5rem;
  padding-top: 3rem;
}

@media (max-width: 575.98px) {
  .post-nav {
    grid-template-columns: 1fr;
  }

  .post-nav-next {
    text-align: left;
  }
}

/* ============================================================
 * Service / Sector — "In this section" & "Related work"
 * ============================================================ */

.related-pages {
  border-top: 1px solid var(--fe-border);
  margin-top: 3.5rem;
  padding-top: 3rem;
}

.related-pages + .related-pages {
  margin-top: 3rem;
}

.related-pages .service-card h3 {
  margin-bottom: .5rem;
}

/* ============================================================
 * Contact page (page-templates/contact.php)
 * ============================================================ */

.contact-card {
  background: var(--fe-bg);
  border: 1px solid var(--fe-border);
  border-radius: var(--fe-radius);
  padding: 2rem;
}

.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.contact-list li {
  display: flex;
  gap: .85rem;
  padding: .9rem 0;
  border-bottom: 1px solid var(--fe-border);
  color: var(--fe-text);
}

.contact-list li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.contact-list li:first-child {
  padding-top: 0;
}

.contact-list i {
  color: var(--fe-blue);
  font-size: 1.15rem;
  flex-shrink: 0;
  margin-top: .1rem;
}

.contact-list a {
  color: var(--fe-blue-dark);
  font-weight: 600;
}

.contact-list a:hover,
.contact-list a:focus {
  color: var(--fe-blue);
}

.contact-map {
  height: 440px;
  width: 100%;
  background: var(--fe-bg);
  z-index: 0;
}

.leaflet-container {
  font-family: inherit;
}

@media (max-width: 767.98px) {
  .contact-map {
    height: 340px;
  }
}

/* Contact Form 7 — match the theme */
.contact-form .wpcf7-form p {
  margin-bottom: 1rem;
}

.contact-form label {
  display: block;
  font-weight: 600;
  color: var(--fe-text);
  margin-bottom: .35rem;
}

.contact-form .wpcf7-form-control:not(.wpcf7-submit):not([type="checkbox"]):not([type="radio"]) {
  width: 100%;
  min-height: 48px;
  padding: .65rem .9rem;
  border: 1px solid var(--fe-border);
  border-radius: 12px;
  background: #fff;
  color: var(--fe-text);
  font: inherit;
}

.contact-form textarea.wpcf7-form-control {
  min-height: 150px;
}

.contact-form .wpcf7-form-control:focus {
  outline: none;
  border-color: rgba(0, 75, 155, .4);
  box-shadow: 0 0 0 .2rem rgba(0, 75, 155, .12);
}

.contact-form .wpcf7-submit {
  background: var(--fe-blue);
  border: 1px solid var(--fe-blue);
  color: #fff;
  border-radius: 999px;
  padding: .85rem 1.6rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 12px 28px rgba(0, 75, 155, .16);
  transition: background-color .2s ease, border-color .2s ease;
}

.contact-form .wpcf7-submit:hover,
.contact-form .wpcf7-submit:focus {
  background: var(--fe-blue-dark);
  border-color: var(--fe-blue-dark);
}

.contact-form .wpcf7-not-valid-tip {
  color: #c0392b;
  font-size: .85rem;
  font-weight: 600;
  margin-top: .3rem;
}

.contact-form .wpcf7-response-output {
  margin: 1.25rem 0 0;
  padding: .85rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--fe-border);
  font-size: .95rem;
}

.contact-form .wpcf7-form.sent .wpcf7-response-output {
  border-color: #1e7e34;
  background: #eafaf0;
  color: #1e7e34;
}

.contact-form .wpcf7-form.invalid .wpcf7-response-output,
.contact-form .wpcf7-form.failed .wpcf7-response-output {
  border-color: #c0392b;
  background: #fdecea;
  color: #c0392b;
}

.contact-form .wpcf7-spinner {
  margin-left: .5rem;
}

/* ============================================================
 * Reusable page hero (template-parts/page-hero.php)
 * Styles: plain / image / slider / split · sizes: standard / large / full
 * Builds on the base .page-hero rules further up.
 * ============================================================ */

.page-hero .eyebrow {
  background: rgba(255, 255, 255, .16);
  color: #fff;
}

.page-hero.is-align-center {
  text-align: center;
}

.page-hero.is-align-center .page-hero-sub {
  margin-left: auto;
  margin-right: auto;
}

.page-hero.is-align-center .d-flex {
  justify-content: center;
}

/* Sizes ---------------------------------------------------- */

.page-hero--large {
  padding: 6.5rem 0 5.5rem;
}

.page-hero--full {
  min-height: 88vh;
  display: flex;
  align-items: center;
}

.page-hero--full > .container {
  width: 100%;
}

/* Plain — light variant ----------------------------------- */

.page-hero--plain.is-theme-light {
  color: var(--fe-text);
  background: var(--fe-blue-soft);
}

.page-hero--plain.is-theme-light::before {
  display: none;
}

.page-hero--plain.is-theme-light .page-hero-sub {
  color: var(--fe-muted);
}

.page-hero--plain.is-theme-light .eyebrow {
  background: #fff;
  color: var(--fe-blue);
}

.page-hero--plain.is-theme-light .btn-fe-outline {
  border-color: var(--fe-blue);
  color: var(--fe-blue);
  background: transparent;
}

/* Slider -------------------------------------------------- */

.page-hero--slider {
  position: relative;
  padding: 0;
}

.page-hero--slider .carousel,
.page-hero--slider .carousel-inner,
.page-hero--slider .carousel-item {
  height: 100%;
}

.page-hero--slider .carousel-item {
  min-height: 460px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
}

.page-hero--slider.page-hero--large .carousel-item {
  min-height: 600px;
}

.page-hero--slider.page-hero--full .carousel-item {
  min-height: 88vh;
}

.page-hero--slider .carousel-item::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(0, 28, 90, .84) 0%, rgba(0, 40, 107, .55) 55%, rgba(0, 40, 107, .28) 100%);
}

.page-hero__caption {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  padding: .4rem .9rem;
  font-size: .78rem;
  letter-spacing: .04em;
  color: rgba(255, 255, 255, .82);
  background: rgba(0, 20, 64, .5);
}

.page-hero__copy {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  pointer-events: none;
}

.page-hero__copy a,
.page-hero__copy button {
  pointer-events: auto;
}

.page-hero--slider .carousel-control-prev,
.page-hero--slider .carousel-control-next {
  width: 6%;
  z-index: 4;
  opacity: .75;
}

.page-hero--slider .carousel-control-prev:hover,
.page-hero--slider .carousel-control-next:hover {
  opacity: 1;
}

/* Split -------------------------------------------------- */

.page-hero--split {
  padding: 4.5rem 0;
}

.page-hero--split.page-hero--large {
  padding: 6rem 0;
}

.page-hero__media {
  width: 100%;
  min-height: 340px;
  border-radius: 28px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  box-shadow: 0 28px 56px rgba(0, 18, 56, .2);
}

@media (max-width: 991.98px) {
  .page-hero--split {
    padding: 3rem 0;
  }

  .page-hero__media {
    min-height: 240px;
  }

  .page-hero--slider .carousel-item {
    min-height: 380px;
  }
}

/* ============================================================
 * "On this page" contents list (page-templates/standard.php)
 * ============================================================ */

.page-toc {
  border: 1px solid var(--fe-border);
  border-radius: 16px;
  background: var(--fe-bg);
  padding: 1.25rem 1.5rem;
  margin-bottom: 2.5rem;
}

.page-toc__title {
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--fe-blue-dark);
  margin: 0 0 .6rem;
}

.page-toc ol {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--fe-muted);
}

.page-toc li {
  margin: .3rem 0;
}

.page-toc a {
  color: var(--fe-text);
  text-decoration: none;
}

.page-toc a:hover,
.page-toc a:focus {
  color: var(--fe-blue);
  text-decoration: underline;
}
