/* ==========================================================================
   LSE Consulting Engineers Website
   Stylesheet: assets/css/styles.css
   Structure:
   1) Reset/Base
   2) CSS Variables
   3) Typography
   4) Layout & Utilities
   5) Components
   6) Page Sections
   7) Forms
   8) Animations
   9) Media Queries
   ========================================================================== */

/* 1) Reset/Base */
*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Open Sans", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text-dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  opacity: 0;
  transition: opacity 240ms ease;
}

body.is-ready { opacity: 1; }

img { max-width: 100%; height: auto; display: block; }

/* V4: blur-up lazy image pattern */
img.blur-up { filter: blur(18px); transform: scale(1.01); transition: filter 260ms ease, transform 260ms ease; }
img.blur-up.is-loaded { filter: blur(0); transform: none; }

/* V4: skeleton blocks (used while media/content loads) */
.skeleton {
  position: relative;
  overflow: hidden;
  background: rgba(15, 23, 42, 0.08);
  border-radius: 12px;
}
.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg,
    rgba(255,255,255,0) 0%,
    rgba(255,255,255,0.55) 50%,
    rgba(255,255,255,0) 100%
  );
  animation: shimmer 1.2s infinite;
}
@keyframes shimmer { to { transform: translateX(100%); } }

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

button, input, select, textarea { font: inherit; }
button { cursor: pointer; }

:focus-visible {
  outline: 3px solid rgba(255, 107, 53, 0.55);
  outline-offset: 2px;
  border-radius: 8px;
}

::selection { background: rgba(0, 86, 179, 0.2); }

/* 2) CSS Variables */
:root {
  --primary-blue: #0056B3;
  --accent-orange: #FF6B35;
  --white: #FFFFFF;
  --navy: #1A365D;
  --light-gray: #F8F9FA;
  --medium-gray: #E2E8F0;
  --text-dark: #2D3748;
  --text-light: #718096;

  --container: 1180px;

  --radius: 16px;
  --radius-sm: 12px;

  --shadow-sm: 0 6px 18px rgba(26, 54, 93, 0.10);
  --shadow-md: 0 10px 30px rgba(26, 54, 93, 0.14);

  --border: 1px solid rgba(226, 232, 240, 1);

  --header-height: 78px;

  /* ✅ hero dot progress matches 5s carousel */
  --hero-interval: 5s;
}

/* 3) Typography */
h1, h2, h3, h4 {
  font-family: "Montserrat", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--primary-blue);
  line-height: 1.15;
  margin: 0 0 12px;
}

h1 { font-size: clamp(2rem, 3.2vw, 3.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 2.2vw, 2.25rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 14px; color: var(--text-dark); }
small, .muted { color: var(--text-light); }

.kicker {
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(0, 86, 179, 0.75);
}

/* 4) Layout & Utilities */
.container {
  width: min(var(--container), calc(100% - 2rem));
  margin-inline: auto;
}

.section { padding: 72px 0; }
.section.alt { background: var(--light-gray); }

.grid { display: grid; gap: 22px; }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.stack { display: flex; flex-direction: column; gap: 14px; }

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  padding: 8px 12px;
  background: rgba(0, 86, 179, 0.08);
  border: 1px solid rgba(0, 86, 179, 0.12);
  border-radius: 999px;
  color: var(--navy);
}

.hr {
  height: 1px;
  width: 100%;
  background: rgba(226, 232, 240, 0.9);
  margin: 26px 0;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* 5) Components */

/* Header / Nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  backdrop-filter: blur(10px);
}

.navbar {
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.logo {
  display: grid;
  line-height: 1.05;
  font-family: "Montserrat", sans-serif;
}

.logo .line1,
.logo .line2,
.logo .line3 {
  font-weight: 800;
  color: var(--primary-blue);
  font-size: 0.95rem;
  letter-spacing: 0.02em;
}
.logo .line2 { font-weight: 700; }
.logo .line3 { display: flex; gap: 8px; align-items: baseline; }
.logo .amp { color: var(--accent-orange); font-weight: 800; }
.logo .tagline {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--primary-blue);
  opacity: 0.9;
  margin-top: 2px;
}

.logo-img{
  height: 150px; /* adjust if needed */
  width: auto;
  display: block;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
}

.nav-links a {
  font-family: "Montserrat", sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--navy);
  padding: 8px 10px;
  border-radius: 10px;
}

.nav-links a[aria-current="page"],
.nav-links a:hover {
  background: rgba(0, 86, 179, 0.08);
  color: var(--primary-blue);
}

.header-actions { display: flex; align-items: center; gap: 10px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid transparent;
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease, border-color 140ms ease, color 140ms ease;
  user-select: none;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: var(--accent-orange);
  color: var(--white);
  box-shadow: 0 10px 22px rgba(255, 107, 53, 0.25);
}
.btn-primary:hover { box-shadow: 0 14px 28px rgba(255, 107, 53, 0.32); }

.btn-outline {
  background: transparent;
  border-color: rgba(0, 86, 179, 0.55);
  color: var(--primary-blue);
}
.btn-outline:hover { background: rgba(0, 86, 179, 0.08); border-color: rgba(0, 86, 179, 0.7); }

.btn-ghost {
  background: transparent;
  border-color: rgba(226, 232, 240, 0.9);
  color: var(--navy);
}
.btn-ghost:hover { background: rgba(26, 54, 93, 0.05); }

.hamburger {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: var(--white);
  align-items: center;
  justify-content: center;
}

.hamburger span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--navy);
  position: relative;
}
.hamburger span::before,
.hamburger span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--navy);
}
.hamburger span::before { top: -6px; }
.hamburger span::after { top: 6px; }

/* Mobile Drawer */
.drawer-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26, 54, 93, 0.55);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease;
  z-index: 60;
}

.drawer {
  position: fixed;
  top: 0;
  right: -380px;
  width: min(92vw, 360px);
  height: 100%;
  background: var(--white);
  box-shadow: -18px 0 40px rgba(26, 54, 93, 0.22);
  z-index: 70;
  transition: right 220ms ease;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.drawer nav { display: flex; flex-direction: column; gap: 6px; padding-top: 10px; }
.drawer nav a {
  padding: 12px 12px;
  border-radius: 12px;
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  color: var(--navy);
}
.drawer nav a:hover { background: rgba(0, 86, 179, 0.08); color: var(--primary-blue); }

.drawer-actions { margin-top: auto; display: grid; gap: 10px; }

.drawer-open .drawer-backdrop { opacity: 1; pointer-events: auto; }
.drawer-open .drawer { right: 0; }

/* ==============================
   V4 Interaction Design Toolkit
   - Micro-interactions, feedback
   - Loaders, toasts, reveals
   ============================== */

/* Consistent motion (keep subtle) */
:root { --motion-fast: 180ms; --motion: 260ms; --motion-slow: 420ms; }

/* Buttons + cards: subtle hover lift */
.btn,
.card,
.chip,
.nav-links a {
  transition: transform var(--motion) ease, box-shadow var(--motion) ease, background var(--motion) ease, color var(--motion) ease, border-color var(--motion) ease;
}
.btn:hover { transform: translateY(-1px); }
.card:hover { transform: translateY(-2px); }
.chip:hover { transform: translateY(-1px); }

/* Ripple effect (JS adds .has-ripple + sets --rx/--ry) */
.has-ripple { position: relative; overflow: hidden; }
.has-ripple::after {
  content: "";
  position: absolute;
  left: var(--rx, 50%);
  top: var(--ry, 50%);
  width: 10px;
  height: 10px;
  border-radius: 999px;
  transform: translate(-50%, -50%) scale(0);
  background: rgba(255,255,255,0.55);
  opacity: 0;
  pointer-events: none;
}
.has-ripple.is-rippling::after {
  opacity: 1;
  transform: translate(-50%, -50%) scale(20);
  transition: transform 520ms ease, opacity 720ms ease;
}

/* Inline field errors */
.field { position: relative; }
.field .error-text {
  display: none;
  margin-top: 6px;
  font-size: 0.9rem;
  color: #b42318;
}
.field.is-error .error-text { display: block; }
.field.is-error input,
.field.is-error textarea,
.field.is-error select { border-color: rgba(180, 35, 24, 0.55); box-shadow: 0 0 0 4px rgba(180, 35, 24, 0.12); }

/* Character counter */
.char-counter { display:flex; justify-content:flex-end; font-size: 0.85rem; margin-top: 6px; color: rgba(15, 23, 42, 0.60); }
.char-counter.is-near { color: rgba(245, 158, 11, 0.9); }
.char-counter.is-over { color: #b42318; }

/* Loading spinner (used in buttons + async states) */
.spinner {
  width: 18px;
  height: 18px;
  border: 2px solid rgba(255,255,255,0.45);
  border-top-color: rgba(255,255,255,0.95);
  border-radius: 999px;
  animation: spin 800ms linear infinite;
  display: inline-block;
  vertical-align: middle;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Toast notifications */
.toast-wrap {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 9999;
  display: grid;
  gap: 10px;
}
.toast {
  min-width: 260px;
  max-width: 360px;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(2, 6, 23, 0.92);
  color: rgba(255,255,255,0.96);
  box-shadow: 0 18px 40px rgba(0,0,0,0.20);
  transform: translateY(8px);
  opacity: 0;
  transition: opacity var(--motion) ease, transform var(--motion) ease;
}
.toast.is-show { opacity: 1; transform: translateY(0); }
.toast .toast-title { font-weight: 700; margin: 0 0 2px; font-family: "Montserrat", sans-serif; }
.toast .toast-msg { margin: 0; opacity: 0.92; }
.toast.toast--success { background: rgba(3, 58, 121, 0.94); }
.toast.toast--error { background: rgba(180, 35, 24, 0.94); }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(10px); }
.reveal.is-in { opacity: 1; transform: none; transition: opacity var(--motion-slow) ease, transform var(--motion-slow) ease; }

/* Back to top */
.back-to-top {
  position: fixed;
  right: 16px;
  bottom: 86px;
  z-index: 9998;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgba(2, 6, 23, 0.68);
  color: rgba(255,255,255,0.96);
  display: grid;
  place-items: center;
  box-shadow: 0 14px 30px rgba(0,0,0,0.18);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity var(--motion) ease, transform var(--motion) ease;
}
.back-to-top.is-show { opacity: 1; pointer-events: auto; transform: none; }

/* Mobile swipe hint for carousels */
.swipe-hint {
  position: absolute;
  left: 50%;
  bottom: 52px;
  transform: translateX(-50%);
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(2, 6, 23, 0.55);
  color: rgba(255,255,255,0.92);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 1;
  transition: opacity var(--motion) ease;
}
.swipe-hint.is-hide { opacity: 0; }


/* Hero */
.hero {
  position: relative;
  min-height: calc(78vh - var(--header-height));
  display: grid;
  place-items: center;
  overflow: hidden;
  color: var(--white);
}

.hero .bg {
  position: absolute;
  inset: 0;
  background-position: center;
  /*
    HERO IMAGE FIT (V4)
    - Full-bleed (fills hero)
    - No transform zoom/pan
    - No distortion (keeps aspect ratio)
    - Cropping may occur at extreme aspect ratios
  */
  background-size: cover;
  background-repeat: no-repeat;
  background-color: rgba(2, 6, 23, 0.65);
  /* ✅ remove scaling to avoid softness */
  transform: none;
}

.hero .overlay {
  position: absolute;
  inset: 0;
  /*
    HERO OVERLAY (V4)
    - Keep text readable
    - Let photography show through (more transparency)
  */
  background: rgba(3, 58, 121, 0.42); /* default for inner pages */
}

/* Glass feel styling */
.hero.hero--photo .hero-copy {
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 18px;
  padding: 18px 18px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.16);
}

/* Photo hero (full-bleed real projects) */
.hero.hero--photo .bg { display: none; }

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  transform: translateZ(0); /* optional: helps GPU compositing */
}

.hero-bg-track {
  position: absolute;
  inset: 0;
}

/* ✅ FIX: no zoom / no scale (prevents quality loss) */
.hero-bg-slide {
  position: absolute;
  inset: 0;
  /*
    HERO CAROUSEL IMAGE FIT (V4)
    - Full-bleed (fills hero)
    - No transform zoom/pan
    - No distortion (keeps aspect ratio)
    - Cropping may occur at extreme aspect ratios
  */
  background-size: cover;
  background-repeat: no-repeat;
  background-color: rgba(2, 6, 23, 0.65);
  background-position: center;
  opacity: 0;
  transform: none;                 /* ✅ no zoom */
  transition: opacity 720ms ease;  /* ✅ fade only */
  cursor: default;
  will-change: opacity;
}

.hero-bg-slide.is-active { opacity: 1; }

/* keep class safe even if JS adds it */
.hero-bg-slide.is-zooming { transform: none; }

/* ✅ FIXED: Home (index) hero overlay now BLUE like Services */
.hero.hero--photo .overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(1200px 600px at 20% 25%, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.00) 60%),
    linear-gradient(90deg,
      rgba(0, 86, 179, 0.56) 0%,
      rgba(0, 86, 179, 0.38) 55%,
      rgba(0, 86, 179, 0.24) 100%
    ),
    linear-gradient(180deg, rgba(0,0,0,0.04) 0%, rgba(0,0,0,0.18) 100%);
  /* Reduce blur so the home hero photo stays crisp */
  backdrop-filter: blur(1.5px);
  -webkit-backdrop-filter: blur(1.5px);
}

.hero.hero--photo .content { z-index: 2; }

.hero-dots--overlay {
  position: absolute;
  left: 50%;
  bottom: 18px;
  transform: translateX(-50%);
  z-index: 3;
}

.hero .content {
  position: relative;
  padding: 72px 0;
}

/* Hero layout */
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 28px;
  align-items: center;
}

.hero-copy { max-width: 62ch; }

/* (Legacy hero gallery — kept in case you reuse it) */
.hero-gallery {
  --hero-interval: var(--hero-interval);
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
}

.hero-gallery-track {
  display: flex;
  transition: transform 520ms ease;
  will-change: transform;
}

.hero-shot {
  width: 100%;
  flex: 0 0 100%;
  margin: 0;
  position: relative;
}

.hero-shot img {
  width: 100%;
  height: 360px;
  /* V4: never crop photography */
  object-fit: contain;
  background: rgba(2, 6, 23, 0.65);
  display: block;
}

.hero-shot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.00) 42%, rgba(0,0,0,0.45) 100%);
  pointer-events: none;
}

.hero-shot figcaption {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 12px;
  font-family: "Montserrat", sans-serif;
  font-weight: 800;
  letter-spacing: 0.2px;
  color: rgba(255, 255, 255, 0.96);
  text-shadow: 0 10px 24px rgba(0,0,0,0.35);
  z-index: 1;
}

/* Hero dots */
.hero-dots {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 8px;
  align-items: center;
  z-index: 2;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.18);
  padding: 0;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.hero-dot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.92);
  transform: translateX(-100%);
}

.hero-dot.is-active {
  width: 22px;
  background: rgba(255,255,255,0.22);
}

.hero-dot.is-active::after {
  animation: heroDotProgress var(--hero-interval) linear forwards;
}

@keyframes heroDotProgress {
  from { transform: translateX(-100%); }
  to { transform: translateX(0%); }
}

.hero h1, .hero p { color: var(--white); }
.hero p { font-size: 1.1rem; opacity: 0.95; max-width: 58ch; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }

/* Cards */
.card {
  background: var(--white);
  border: var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: rgba(0, 86, 179, 0.35);
}

.card-body { padding: 18px; }
.card-title { font-family: "Montserrat", sans-serif; font-weight: 800; color: var(--navy); margin: 0 0 6px; }
.card-meta { font-size: 0.92rem; color: var(--text-light); margin-bottom: 10px; }

.icon {
  width: 22px;
  height: 22px;
  display: inline-block;
  color: var(--primary-blue);
}

.service-card .icon-wrap {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: rgba(0, 86, 179, 0.10);
  border: 1px solid rgba(0, 86, 179, 0.14);
  margin-bottom: 10px;
}

/* Feature list */
.feature-list { display: grid; gap: 10px; }
.feature-item {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.check {
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: rgba(255, 107, 53, 0.15);
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 107, 53, 0.35);
}
.check svg { width: 14px; height: 14px; color: var(--accent-orange); }

/* Carousel */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.carousel-track {
  display: flex;
  transition: transform 320ms ease;
  will-change: transform;
}

.carousel-slide { min-width: 100%; padding: 0; }

.carousel-controls {
  position: absolute;
  inset: auto 14px 14px auto;
  display: inline-flex;
  gap: 8px;
  z-index: 2;
}

.carousel-controls .btn { padding: 10px 12px; border-radius: 12px; }

/* Filter bar */
.filterbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.chip {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(0, 86, 179, 0.35);
  background: rgba(0, 86, 179, 0.06);
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  color: var(--primary-blue);
}
.chip[aria-pressed="true"] {
  background: var(--primary-blue);
  color: var(--white);
  border-color: var(--primary-blue);
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26, 54, 93, 0.64);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
  z-index: 80;
  padding: 18px;
  display: grid;
  place-items: center;
}

.modal {
  width: min(980px, 100%);
  max-height: 86vh;
  overflow: auto;
  background: var(--white);
  border-radius: 18px;
  box-shadow: 0 28px 80px rgba(0,0,0,0.35);
  border: 1px solid rgba(226, 232, 240, 0.9);
  transform: translateY(8px);
  transition: transform 160ms ease;
}

.modal-header {
  position: sticky;
  top: 0;
  background: var(--white);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.modal-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 900;
  color: var(--navy);
  margin: 0;
  font-size: 1.15rem;
}

.modal-body { padding: 16px; }

.modal-open .modal-backdrop { opacity: 1; pointer-events: auto; }
.modal-open .modal { transform: translateY(0); }

.modal-gallery img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

/* Click-to-zoom (Projects gallery) */
.zoom-thumb {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  display: block;
  width: 100%;
}
.zoom-thumb:focus-visible {
  outline: 3px solid rgba(0, 86, 179, 0.45);
  outline-offset: 3px;
  border-radius: 16px;
}

/* Lightbox overlay */
.lightbox-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(6, 13, 26, 0.78);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
  z-index: 90;
  padding: 18px;
  display: grid;
  place-items: center;
}

.lightbox {
  width: min(1100px, 100%);
  max-height: 90vh;
  overflow: hidden;
  background: var(--white);
  border-radius: 18px;
  box-shadow: 0 28px 90px rgba(0,0,0,0.45);
  border: 1px solid rgba(226, 232, 240, 0.9);
  transform: translateY(8px);
  transition: transform 160ms ease;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.lightbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

.lightbox-title {
  margin: 0;
  font-family: "Montserrat", sans-serif;
  font-weight: 900;
  color: var(--navy);
  font-size: 1.05rem;
}

.lightbox-media {
  position: relative;
  background: #0b1220;
  display: grid;
  place-items: center;
}

.lightbox-media img {
  width: 100%;
  height: 100%;
  max-height: 72vh;
  object-fit: contain;
  transform: scale(1.02);
  transition: transform 220ms ease;
}

.lightbox-media img.is-zoomed { transform: scale(1.12); }

.lightbox-footer {
  padding: 12px 14px;
  border-top: 1px solid rgba(226, 232, 240, 0.9);
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  align-items: center;
}

.lightbox-footer .meta {
  display: inline-flex;
  gap: 6px;
  align-items: baseline;
  color: var(--navy);
  font-size: 0.95rem;
}

.lightbox-open .lightbox-backdrop { opacity: 1; pointer-events: auto; }
.lightbox-open .lightbox { transform: translateY(0); }

/* Footer */
.site-footer {
  background: var(--navy);
  color: rgba(255,255,255,0.92);
  padding: 52px 0 22px;
}
.site-footer h3 { color: var(--white); margin-bottom: 8px; }
.site-footer p, .site-footer a { color: rgba(255,255,255,0.85); }
.site-footer a:hover { color: var(--white); text-decoration: underline; }

.footer-bottom {
  margin-top: 24px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,0.12);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.92rem;
}

/* 6) Page Sections */
.section-title-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.section-title-row p { margin: 0; max-width: 70ch; }

.project-card img { aspect-ratio: 16 / 9; object-fit: cover; background: var(--light-gray); }

.tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.78rem;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 107, 53, 0.12);
  border: 1px solid rgba(255, 107, 53, 0.25);
  color: var(--navy);
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
}

/* Accordion */
.accordion { display: grid; gap: 12px; }
.accordion-item {
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.accordion-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  cursor: pointer;
  align-items: center;
}
.accordion-header h3 { margin: 0; color: var(--navy); font-size: 1.05rem; }
.accordion-chevron {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(0, 86, 179, 0.07);
  border: 1px solid rgba(0, 86, 179, 0.12);
}
.accordion-content { padding: 0 16px 16px; display: none; }
.accordion-item[data-open="true"] .accordion-content { display: block; }
.accordion-item[data-open="true"] .accordion-chevron svg { transform: rotate(180deg); }
.accordion-content ul { margin: 0; padding-left: 18px; color: var(--text-dark); }
.accordion-content li { margin: 8px 0; }

/* Team */
.team-card img { aspect-ratio: 1/1; object-fit: cover; background: var(--light-gray); }
.team-role { font-family: "Montserrat"; font-weight: 700; color: var(--primary-blue); font-size: 0.92rem; margin-bottom: 8px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.pill {
  font-size: 0.78rem;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: rgba(248, 249, 250, 1);
  color: var(--navy);
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
}

/* Contact */
.contact-grid { align-items: start; }
.contact-card { padding: 18px; }

.map-embed {
  width: 100%;
  height: 320px;
  border: 0;
  border-radius: 14px;
  background: var(--light-gray);
}

/* 7) Forms */
.field { display: grid; gap: 6px; }

label {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  color: var(--navy);
  font-size: 0.92rem;
}

input, select, textarea {
  border: 1px solid rgba(226, 232, 240, 1);
  border-radius: 12px;
  padding: 12px 12px;
  background: var(--white);
  color: var(--text-dark);
  transition: border-color 140ms ease, box-shadow 140ms ease;
}
textarea { min-height: 140px; resize: vertical; }

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: rgba(0, 86, 179, 0.55);
  box-shadow: 0 0 0 4px rgba(0, 86, 179, 0.12);
}

.form-note { font-size: 0.9rem; color: var(--text-light); }

.form-status {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(226, 232, 240, 0.9);
  background: var(--light-gray);
  display: none;
}
.form-status[data-show="true"] { display: block; }
.form-status.success { border-color: rgba(0, 165, 81, 0.35); background: rgba(0, 165, 81, 0.10); }
.form-status.error { border-color: rgba(204, 0, 0, 0.35); background: rgba(204, 0, 0, 0.10); }

.map-container {
  width: 100%;
  position: relative;
  margin-top: 20px;
}

.map-embed {
  width: 100%;
  height: 420px;
  border: 0;
  border-radius: 12px;
}

/* Button Overlay */
.map-actions {
  position: absolute;
  bottom: 15px;
  right: 15px;
}

.directions-btn {
  background: #0a3d91;
  color: white;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 4px 10px rgba(0,0,0,0.25);
  transition: 0.25s;
}

.directions-btn:hover { background: #082c6b; }

/* 8) Animations */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; scroll-behavior: auto !important; }
}

/* 9) Media Queries */
@media (max-width: 980px) {
  .grid.cols-3 { grid-template-columns: 1fr; }
  .grid.cols-2 { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
  .hero { min-height: auto; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero .content { padding: 54px 0; }
  .hero-shot img { height: 320px; }
  .section-title-row { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .hamburger { display: inline-flex; }
}
