/* ==========================================================================
   PACIFIC WAVE — COMPONENTS & DESIGN SYSTEM
   ========================================================================== */

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 32px;
  font-family: var(--font-body);
  font-size: var(--fs-body);
  font-weight: 600;
  border-radius: var(--radius-btn);
  transition: transform var(--dur-fast) var(--ease-standard),
              box-shadow var(--dur-fast) var(--ease-standard),
              background var(--dur-fast) var(--ease-standard),
              color var(--dur-fast) var(--ease-standard);
  white-space: nowrap;
  isolation: isolate;
  overflow: hidden;
}
.btn:active { transform: scale(0.97); }

/* Premium Ripple Hover Effect */
.btn::before {
  content: "";
  position: absolute;
  top: 50%; left: 50%;
  width: 140%; height: 0;
  padding-bottom: 140%;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(0);
  transition: transform 0.5s var(--ease-standard);
  z-index: -1;
}
.btn:hover::before { transform: translate(-50%, -50%) scale(1); }

.btn--primary {
  background: var(--color-brand);
  color: var(--color-white);
}
.btn--primary:hover {
  background: var(--color-brand-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-elevated);
}

.btn--secondary {
  background: var(--color-ocean);
  color: var(--color-white);
}
.btn--secondary:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-elevated);
}
.btn--secondary::before {
  background: rgba(41, 181, 232, 0.15);
}

.btn--ghost {
  background: transparent;
  color: var(--color-brand);
  border: 1.5px solid var(--color-brand);
}
.btn--ghost:hover {
  background: var(--color-brand);
  color: var(--color-white);
  transform: translateY(-3px);
  box-shadow: var(--shadow-soft);
}

.btn--on-dark.btn--ghost {
  color: var(--color-white);
  border-color: rgba(255, 255, 255, 0.4);
}
.btn--on-dark.btn--ghost:hover {
  background: var(--color-white);
  color: var(--color-ocean);
  border-color: var(--color-white);
}

/* Magnetic wrapper — JS adds transform via inline style */
.btn-magnetic {
  display: inline-block;
  transition: transform 0.25s var(--ease-standard);
}

/* ---------- Nav Header (Glassmorphism) ---------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h-mobile);
  z-index: 100;
  display: flex;
  align-items: center;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--dur-fast) ease, 
              border-color var(--dur-fast) ease, 
              box-shadow var(--dur-fast) ease, 
              height var(--dur-fast) ease;
}
@media (min-width: 900px) { .nav { height: var(--nav-h-desktop); } }

.nav.is-scrolled {
  background: var(--glass-bg-light);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border-bottom: 1px solid var(--glass-border-light);
  box-shadow: var(--shadow-card);
}

/* Dark layout pages override */
.nav-dark-override .nav {
  background: var(--glass-bg-dark);
  border-color: var(--glass-border-dark);
}

.nav__inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav__logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--color-ocean);
  transition: opacity 0.2s;
}
.nav__logo svg {
  height: 38px;
  width: auto;
}
.nav__logo:hover { opacity: 0.85; }

.nav__logo-img { width: auto; }
.nav__logo-img--dark { display: none; }
[data-theme="dark"] .nav__logo-img--light { display: none; }
[data-theme="dark"] .nav__logo-img--dark { display: block; }

/* Invert logo text on transparent dark hero */
.nav:not(.is-scrolled) .hero ~ .nav__logo { color: var(--color-white); }

.nav__links {
  display: none;
  align-items: center;
  gap: 40px;
}
@media (min-width: 900px) { .nav__links { display: flex; } }

.nav__link {
  position: relative;
  font-weight: 500;
  font-size: 0.98rem;
  color: var(--color-charcoal);
  padding: 6px 0;
  transition: color 0.3s;
}
.nav:not(.is-scrolled) .hero ~ .nav__inner .nav__link { color: var(--color-white); }

.nav__link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -2px;
  width: 0; height: 2px;
  background: var(--color-brand);
  transition: width var(--dur-fast) var(--ease-standard);
}
.nav__link:hover::after { width: 100%; }

.nav__dropdown { position: relative; }
.nav__dropdown-panel {
  position: absolute;
  top: 100%; left: 50%;
  transform: translate(-50%, 12px);
  background: var(--color-surface);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-elevated);
  padding: 12px;
  min-width: 240px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s var(--ease-standard), transform 0.25s var(--ease-standard);
  border: 1px solid var(--glass-border-light);
}
.nav__dropdown:hover .nav__dropdown-panel,
.nav__dropdown:focus-within .nav__dropdown-panel {
  opacity: 1;
  pointer-events: auto;
  transform: translate(-50%, 0);
}
.nav__dropdown-panel a {
  display: block;
  padding: 12px 16px;
  border-radius: 8px;
  color: var(--color-charcoal);
  font-size: 0.92rem;
  font-weight: 500;
  transition: background 0.2s, color 0.2s;
}
.nav__dropdown-panel a:hover {
  background: var(--color-blue-tint);
  color: var(--color-brand-hover);
}

.nav__cta { display: none; }
@media (min-width: 900px) { .nav__cta { display: inline-flex; } }

/* ---------- Theme Toggle ---------- */
.theme-toggle {
  position: relative;
  width: 52px; height: 28px;
  border-radius: var(--radius-pill);
  background: rgba(11, 30, 61, 0.08);
  border: 1px solid rgba(11, 30, 61, 0.1);
  display: flex; align-items: center;
  padding: 3px;
  flex-shrink: 0;
  transition: background 0.3s var(--ease-standard);
}
[data-theme="dark"] .theme-toggle { background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.15); }
.nav:not(.is-scrolled) .hero ~ .nav__inner .theme-toggle { background: rgba(255, 255, 255, 0.15); border-color: rgba(255, 255, 255, 0.25); }
.theme-toggle__thumb {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--color-white);
  display: flex; align-items: center; justify-content: center;
  color: var(--color-ocean);
  transform: translateX(0);
  transition: transform 0.35s var(--ease-standard);
  box-shadow: 0 2px 6px rgba(11, 30, 61, 0.25);
}
[data-theme="dark"] .theme-toggle__thumb { transform: translateX(24px); background: var(--color-ocean); color: var(--color-brand); }
.theme-toggle__thumb svg { width: 13px; height: 13px; }
.theme-toggle__thumb .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle__thumb .icon-sun { display: none; }
[data-theme="dark"] .theme-toggle__thumb .icon-moon { display: block; }

.nav__burger {
  display: flex;
  width: 44px; height: 44px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  transition: background 0.2s;
}
.nav__burger:hover { background: rgba(11, 30, 61, 0.05); }
.nav:not(.is-scrolled) .hero ~ .nav__inner .nav__burger:hover { background: rgba(255, 255, 255, 0.1); }
.nav:not(.is-scrolled) .hero ~ .nav__inner .nav__burger { color: var(--color-white); }

@media (min-width: 900px) { .nav__burger { display: none; } }

.nav__burger span {
  position: relative;
  width: 22px; height: 2px;
  background: currentColor;
  display: block;
}
.nav__burger span::before, .nav__burger span::after {
  content: "";
  position: absolute;
  left: 0; width: 22px; height: 2px;
  background: currentColor;
  transition: transform 0.25s ease;
}
.nav__burger span::before { top: -7px; }
.nav__burger span::after { top: 7px; }

/* Burger open state */
.nav__burger[aria-expanded="true"] span { background: transparent; }
.nav__burger[aria-expanded="true"] span::before { transform: translateY(7px) rotate(45deg); }
.nav__burger[aria-expanded="true"] span::after { transform: translateY(-7px) rotate(-45deg); }

.nav__mobile-overlay {
  position: fixed;
  inset: 0;
  background: var(--color-ocean);
  z-index: 99;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 28px;
  transform: translateY(-100%);
  transition: transform var(--dur-slow) var(--ease-standard);
  padding: 40px;
}
.nav__mobile-overlay.is-open { transform: translateY(0); }
.nav__mobile-overlay a {
  color: var(--color-white);
  font-size: 1.6rem;
  font-family: var(--font-display);
  font-weight: 700;
  transition: color 0.2s;
}
.nav__mobile-overlay a:hover { color: var(--color-brand); }

/* ---------- Trust Row ---------- */
.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: center;
}
.trust-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--color-white);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  backdrop-filter: blur(8px);
}
.trust-badge svg { width: 18px; height: 18px; color: var(--color-brand); flex-shrink: 0; }

/* Variant for use on light section backgrounds (not the dark hero) */
.trust-badge--on-light {
  color: var(--color-charcoal);
  background: var(--color-blue-tint);
  border: 1px solid var(--color-mist);
}

[data-social-placeholder] { opacity: 0.55; cursor: default; }
[data-social-placeholder]:hover { opacity: 0.85; }

/* ---------- Interactive Cards ---------- */
.card {
  position: relative;
  background: var(--color-surface);
  border: 1px solid rgba(11, 30, 61, 0.04);
  border-radius: var(--radius-card);
  padding: 40px 32px;
  box-shadow: var(--shadow-card);
  transition: transform 0.4s var(--ease-standard), 
              box-shadow 0.4s var(--ease-standard), 
              border-color 0.4s var(--ease-standard);
  isolation: isolate;
  overflow: hidden;
}
.card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-elevated);
  border-color: rgba(41, 181, 232, 0.2);
}
.card::after {
  content: "";
  position: absolute; inset: 0; border-radius: inherit;
  padding: 1.5px;
  background: conic-gradient(from var(--card-angle, 0deg), transparent 0%, var(--color-brand) 12%, transparent 24%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.4s var(--ease-standard);
  pointer-events: none; z-index: 1;
  animation: card-border-spin 3.5s linear infinite paused;
}
.card:hover::after { opacity: 1; animation-play-state: running; }
@property --card-angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
@keyframes card-border-spin { to { --card-angle: 360deg; } }

.icon-circle {
  width: 58px; height: 58px;
  border-radius: 50%;
  background: var(--color-blue-tint);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 24px;
  color: var(--color-brand);
  transition: background 0.3s, color 0.3s;
}
.icon-circle svg { width: 24px; height: 24px; }
.card:hover .icon-circle {
  background: var(--color-brand);
  color: var(--color-white);
}

/* ---------- Service cards (image + desc + CTA) ---------- */
.service-card { padding: 0; overflow: hidden; transition: transform 0.45s var(--ease-standard), box-shadow 0.45s var(--ease-standard); }
.service-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-elevated); }
.service-card__media { position: relative; width: 100%; height: 200px; overflow: hidden; }
.service-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease-standard); }
.service-card:hover .service-card__media img { transform: scale(1.08); }
.service-card__badge {
  position: absolute; bottom: -22px; left: 28px;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--color-surface); box-shadow: var(--shadow-card);
  display: flex; align-items: center; justify-content: center;
  color: var(--color-brand); z-index: 2;
}
.service-card__badge svg { width: 22px; height: 22px; }
.service-card__body { padding: 36px 28px 28px; }
.service-card__cta {
  display: flex; gap: 10px; margin-top: 20px; flex-wrap: wrap;
}
.service-card__cta a {
  font-size: 0.82rem; font-weight: 700; letter-spacing: 0.02em;
  padding: 9px 16px; border-radius: var(--radius-pill);
  text-decoration: none; transition: all 0.3s var(--ease-standard);
}
.service-card__cta a.is-primary { background: var(--color-ocean); color: var(--color-white); }
.service-card__cta a.is-primary:hover { background: var(--color-brand); }
.service-card__cta a.is-ghost { border: 1px solid var(--color-mist); color: var(--color-charcoal); }
.service-card__cta a.is-ghost:hover { border-color: var(--color-brand); color: var(--color-brand); }

/* ---------- Shape Hero (geometric floating shapes + gradient title) ---------- */
.shape-hero {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--color-ocean);
}
.shape-hero__media { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
.shape-hero__media video, .shape-hero__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
}
.shape-hero__media::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,30,61,0.55) 0%, rgba(11,30,61,0.32) 50%, rgba(11,30,61,0.68) 100%);
  z-index: 1;
}
.shape-hero--plain { min-height: 56vh; background: var(--color-ocean); }
.shape-hero--plain .shape-hero__title { font-size: clamp(2.6rem, 5.5vw, 4.2rem); }
.shape-hero--plain .shape-hero__content { padding-top: 90px; padding-bottom: 20px; }
.shape-hero__glow {
  position: absolute; inset: 0; z-index: 1;
  background: radial-gradient(circle at 30% 20%, rgba(41,181,232,0.10) 0%, transparent 55%),
              radial-gradient(circle at 75% 80%, rgba(201,168,76,0.08) 0%, transparent 55%);
  filter: blur(60px);
}
.shape-hero__shapes { position: absolute; inset: 0; overflow: hidden; z-index: 2; }
.shape-hero__shape {
  position: absolute;
  opacity: 0;
  animation: shape-enter 2.4s var(--ease-standard) forwards;
}
.shape-hero__shape-inner {
  position: relative;
  animation: shape-float 12s ease-in-out infinite;
}
.shape-hero__pill {
  position: absolute; inset: 0;
  border-radius: 50%;
  backdrop-filter: blur(2px);
  border: 2px solid rgba(255,255,255,0.15);
  box-shadow: 0 8px 32px rgba(255,255,255,0.08);
}
.shape-hero__pill::after {
  content: "";
  position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, rgba(255,255,255,0.18), transparent 70%);
}
@keyframes shape-enter {
  from { opacity: 0; transform: translateY(-150px) rotate(var(--rot-from, -15deg)); }
  to   { opacity: 1; transform: translateY(0) rotate(var(--rot-to, 0deg)); }
}
@keyframes shape-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(15px); }
}

.shape-hero__content { position: relative; z-index: 5; text-align: center; max-width: 780px; margin: 0 auto; padding: 0 var(--gutter-mobile); }
.shape-hero__badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 16px; border-radius: var(--radius-pill);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  font-size: 0.85rem; color: rgba(255,255,255,0.7); letter-spacing: 0.03em;
  margin-bottom: 28px; opacity: 0; animation: fade-up 0.9s var(--ease-standard) 0.1s forwards;
}
.shape-hero__badge-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--color-gold); flex-shrink: 0; }
.shape-hero__title {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 4.8rem);
  font-weight: 800; letter-spacing: -0.02em; line-height: 1.08;
  margin: 0;
}
.shape-hero__title .shape-hero__line { display: block; }
.shape-hero__title .shape-hero__line--1 .split-word {
  background: linear-gradient(180deg, #fff 0%, rgba(255,255,255,0.8) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.shape-hero__title .shape-hero__line--2 .split-word {
  background: linear-gradient(90deg, var(--color-brand) 0%, #fff 50%, var(--color-gold) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Word Rotator (cycling keyword in hero title) ---------- */
span.word-rotate {
  position: relative;
  display: inline-grid !important;
  vertical-align: bottom;
  text-align: left;
}
.word-rotate__item {
  grid-row: 1; grid-column: 1;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s var(--ease-standard), transform 0.5s var(--ease-standard);
  background: linear-gradient(90deg, var(--color-brand) 0%, #fff 50%, var(--color-gold) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.word-rotate__item.is-active { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .word-rotate__item { transition: opacity 0.3s ease; transform: none; }
}
.shape-hero__lead {
  font-size: clamp(1rem, 1.3vw, 1.2rem); color: rgba(255,255,255,0.55);
  font-weight: 300; letter-spacing: 0.01em; line-height: 1.6;
  max-width: 540px; margin: 24px auto 0;
  opacity: 0; animation: fade-up 0.9s var(--ease-standard) 0.7s forwards;
}
.shape-hero__cta-row {
  display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-top: 36px;
  opacity: 0; animation: fade-up 0.9s var(--ease-standard) 0.9s forwards;
}
@keyframes fade-up { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) {
  .shape-hero__shape, .shape-hero__badge, .shape-hero__lead, .shape-hero__cta-row { animation: none !important; opacity: 1 !important; }
}

/* ---------- Colorful Bento Grid (Why Pacific Wave) ---------- */
.bento-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(6, 1fr);
}
.bento-card {
  position: relative;
  grid-column: span 6 / span 6;
  border-radius: var(--radius-card);
  padding: 36px 30px;
  color: var(--color-white);
  overflow: hidden;
  isolation: isolate;
  box-shadow: var(--shadow-card);
  transition: transform 0.45s var(--ease-standard), box-shadow 0.45s var(--ease-standard);
}
.bento-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-elevated); }
.bento-card::before {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(circle at 20% 0%, rgba(255,255,255,0.22), transparent 55%);
}
.bento-card--lg { grid-column: span 6 / span 6; }
.bento-card--full { grid-column: span 6 / span 6; }
@media (min-width: 768px) {
  .bento-card--lg { grid-column: span 4 / span 4; }
  .bento-card--full { grid-column: span 6 / span 6 !important; }
  .bento-card:not(.bento-card--lg):not(.bento-card--full) { grid-column: span 2 / span 2; }
}
@media (max-width: 767px) { .bento-card { grid-column: span 6 / span 6; } }

.bento-card--blue   { background: linear-gradient(135deg, #29B5E8 0%, #1A96C4 100%); }
.bento-card--gold   { background: linear-gradient(135deg, #C9A84C 0%, #A28235 100%); }
.bento-card--ocean  { background: linear-gradient(135deg, #0B1E3D 0%, #16345E 100%); }
.bento-card--teal   { background: linear-gradient(135deg, #1A96C4 0%, #0E5D7C 100%); }
.bento-card--amber  { background: linear-gradient(135deg, #D9B868 0%, #C9A84C 100%); }
.bento-card--navy   { background: linear-gradient(135deg, #132A4E 0%, #0B1E3D 100%); }

.bento-card__icon {
  width: 52px; height: 52px; border-radius: 14px;
  background: rgba(255,255,255,0.18);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 22px;
}
.bento-card__icon svg { width: 24px; height: 24px; }
.bento-card h3 { color: var(--color-white); font-size: 1.2rem; }
.bento-card p { margin-top: 10px; font-size: 0.95rem; color: rgba(255,255,255,0.85); line-height: 1.55; }

/* ---------- Service Line Sections (count badge + chip grid) ---------- */
.service-line__count {
  display: inline-flex; align-items: baseline; gap: 8px;
  font-family: var(--font-display); font-weight: 800;
  color: var(--color-brand);
}
.service-line__count .num { font-size: 3rem; line-height: 1; }
.service-line__count .label { font-size: 0.95rem; color: var(--color-slate); font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }
.service-chip-grid { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.service-chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px; border-radius: var(--radius-pill);
  background: var(--color-surface); border: 1px solid var(--color-mist);
  font-size: 0.88rem; font-weight: 600; color: var(--color-charcoal);
  transition: transform 0.3s var(--ease-standard), border-color 0.3s, box-shadow 0.3s;
}
.service-chip:hover { transform: translateY(-3px); border-color: var(--color-brand); box-shadow: var(--shadow-card); }
.service-chip svg { width: 15px; height: 15px; color: var(--color-brand); flex-shrink: 0; }

/* ---------- Before / After Comparison Slider ---------- */
.ba-slider {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-card);
  overflow: hidden;
  cursor: ew-resize;
  user-select: none;
  -webkit-user-select: none;
  box-shadow: var(--shadow-card);
  container-type: inline-size;
}
.ba-slider__after, .ba-slider__before { position: absolute; inset: 0; }
.ba-slider__after img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ba-slider__before { width: var(--pos, 50%); overflow: hidden; border-right: 2px solid var(--color-white); }
.ba-slider__before img { position: absolute; inset: 0; width: 100cqw; height: 100%; object-fit: cover; display: block; }
.ba-slider__handle {
  position: absolute; top: 0; bottom: 0; left: var(--pos, 50%);
  width: 0; transform: translateX(-50%);
  display: flex; align-items: center; justify-content: center;
  pointer-events: none;
}
.ba-slider__handle::before { content: ""; position: absolute; top: 0; bottom: 0; width: 2px; background: var(--color-white); box-shadow: 0 0 0 1px rgba(0,0,0,0.1); }
.ba-slider__knob {
  position: relative; z-index: 2;
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--color-white); box-shadow: var(--shadow-elevated);
  display: flex; align-items: center; justify-content: center; gap: 2px;
  color: var(--color-ocean);
}
.ba-slider__knob svg { width: 13px; height: 13px; }
.ba-slider__tag {
  position: absolute; bottom: 14px; z-index: 3;
  padding: 6px 14px; border-radius: var(--radius-pill);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--color-white);
}
.ba-slider__tag--before { left: 14px; background: rgba(11,30,61,0.7); }
.ba-slider__tag--after { right: 14px; background: var(--color-brand); }
.ba-note { font-size: 0.82rem; color: var(--color-slate); text-align: center; margin-top: 18px; font-style: italic; }

/* ---------- Testimonial Marquee (two opposing rows) ---------- */
.marquee-wrap { overflow: hidden; width: 100%; }
.marquee-wrap + .marquee-wrap { margin-top: 24px; }
.marquee-row {
  display: flex; gap: 24px; width: max-content;
  animation: marquee-left 46s linear infinite;
}
.marquee-row--reverse { animation-name: marquee-right; }
.marquee-wrap:hover .marquee-row { animation-play-state: paused; }
@keyframes marquee-left { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes marquee-right { from { transform: translateX(-50%); } to { transform: translateX(0); } }
.marquee-row .testimonial-card { flex: 0 0 360px; scroll-snap-align: unset; }
@media (prefers-reduced-motion: reduce) { .marquee-row { animation: none; } }

/* ---------- Hover Slider (label list + crossfade image) ---------- */
.hover-slider { display: flex; flex-wrap: wrap-reverse; align-items: center; justify-content: space-between; gap: 40px; }
.hover-slider__labels { display: flex; flex-direction: column; gap: 6px; flex: 1 1 300px; }
.hover-slider__label {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 3vw, 2.2rem); font-weight: 800; letter-spacing: -0.02em;
  text-transform: uppercase; color: var(--color-mist);
  cursor: pointer; transition: color 0.35s var(--ease-standard), transform 0.35s var(--ease-standard);
  background: none; border: none; text-align: left; padding: 4px 0;
}
.hover-slider__label:hover, .hover-slider__label:focus-visible, .hover-slider__label.is-active {
  color: var(--color-charcoal); transform: translateX(8px);
}
.hover-slider__label.is-active { color: var(--color-brand); }
.hover-slider__media {
  position: relative; width: 340px; height: 400px; max-width: 100%;
  border-radius: var(--radius-card); overflow: hidden; flex-shrink: 0;
  box-shadow: var(--shadow-elevated);
}
.hover-slider__media img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transform: scale(1.05);
  transition: opacity 0.6s var(--ease-standard), transform 0.6s var(--ease-standard);
}
.hover-slider__media img.is-active { opacity: 1; transform: scale(1); }

/* ---------- Flip Card Service Showcase ---------- */
.flip-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 36px;
}
.flip-card { position: relative; aspect-ratio: 1 / 1; perspective: 1200px; cursor: pointer; }
.flip-card__inner {
  position: relative; width: 100%; height: 100%;
  transition: transform 0.6s var(--ease-standard);
  transform-style: preserve-3d;
  border-radius: var(--radius-card);
}
.flip-card:hover .flip-card__inner,
.flip-card:focus-within .flip-card__inner,
.flip-card.is-flipped .flip-card__inner { transform: rotateY(180deg); }
.flip-card__front, .flip-card__back {
  position: absolute; inset: 0;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border-radius: var(--radius-card); overflow: hidden;
  box-shadow: var(--shadow-card);
}
.flip-card__front img { width: 100%; height: 100%; object-fit: cover; display: block; }
.flip-card__front::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(11,30,61,0.82) 100%);
}
.flip-card__front-label {
  position: absolute; bottom: 12px; left: 12px; right: 12px; z-index: 2;
  color: var(--color-white); font-weight: 700; font-size: 0.86rem; line-height: 1.3;
}
.flip-card__back {
  transform: rotateY(180deg);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 16px; color: var(--color-white); gap: 6px;
}
.flip-card__back h4 { color: var(--color-white); font-size: 0.98rem; font-weight: 800; }
.flip-card__back p { font-size: 0.78rem; color: rgba(255,255,255,0.85); line-height: 1.4; }
.flip-card__back .btn-quote {
  margin-top: 8px; display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px; border-radius: var(--radius-pill);
  background: rgba(255,255,255,0.18); border: 1px solid rgba(255,255,255,0.45);
  font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em;
  color: var(--color-white); transition: background 0.3s, color 0.3s, transform 0.3s;
}
.flip-card__back .btn-quote:hover { background: var(--color-white); color: var(--color-ocean); transform: translateY(-2px); }
.flip-card__back--blue { background: var(--grad-primary); }
.flip-card__back--gold { background: var(--grad-gold); }
.flip-card__back--ocean { background: var(--grad-ocean); }
@media (max-width: 640px) { .flip-card-grid { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Wave divider (signature element) ---------- */
.wave-divider {
  width: 100%;
  height: 60px;
  display: block;
  overflow: hidden;
  margin-top: -2px; /* Prevent line seams */
}
.wave-divider path {
  stroke: var(--color-brand);
  stroke-width: 2.5;
  fill: none;
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
}
.wave-divider.is-drawn path {
  stroke-dashoffset: 0;
  transition: stroke-dashoffset 1.8s cubic-bezier(0.25, 1, 0.5, 1);
}

/* ---------- Service split cards ---------- */
.split-card {
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  height: 500px;
  display: flex;
  align-items: flex-end;
  isolation: isolate;
  border: 1px solid rgba(11, 30, 61, 0.05);
  box-shadow: var(--shadow-card);
  transition: transform 0.4s var(--ease-standard), box-shadow 0.4s var(--ease-standard);
}
.split-card img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.8s var(--ease-standard);
  z-index: -2;
}
.split-card::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,30,61,0) 20%, rgba(11,30,61,0.92) 100%);
  z-index: -1;
  transition: opacity 0.4s;
}
.split-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-elevated);
}
.split-card:hover img { transform: scale(1.08); }
.split-card__content { padding: 40px; color: var(--color-white); position: relative; z-index: 2; }
.split-card__content h3 { color: var(--color-white); font-size: var(--fs-h2); margin-bottom: 12px; }
.split-card__link {
  display: inline-flex; align-items: center; gap: 8px;
  margin-top: 20px; font-weight: 600;
  color: var(--color-brand);
  transition: gap var(--dur-fast) ease, color var(--dur-fast) ease;
}
.split-card__link:hover { gap: 14px; color: var(--color-white); }

/* ---------- Steps (How it works) ---------- */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  position: relative;
}
@media (min-width: 768px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { text-align: center; position: relative; z-index: 2; }
.step__num {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--color-brand);
  color: var(--color-white);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800;
  font-size: 1.15rem;
  margin: 0 auto 20px;
  box-shadow: 0 4px 12px rgba(41, 181, 232, 0.3);
  transition: transform 0.3s var(--ease-standard);
}
.step:hover .step__num { transform: scale(1.1); }
.steps__line {
  position: absolute;
  top: 26px; left: 12%; right: 12%;
  height: 2px;
  border-top: 2px dashed var(--color-mist);
  z-index: 1;
  display: none;
}
@media (min-width: 768px) { .steps__line { display: block; } }

/* ---------- Stats (Odometer / Counters) ---------- */
.stats { display: grid; grid-template-columns: 1fr; gap: 40px; text-align: center; }
@media (min-width: 768px) { .stats { grid-template-columns: repeat(3, 1fr); } }
.stat__num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(3rem, 6vw, 4.2rem);
  color: var(--color-brand);
}
.stat__label { color: rgba(255,255,255,0.78); font-size: 1rem; margin-top: 8px; font-weight: 500; }

/* ---------- Testimonials (Carousel) ---------- */
.testimonial-track {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 10px 0;
  scrollbar-width: none;
}
.testimonial-track::-webkit-scrollbar { display: none; }
.testimonial-card {
  scroll-snap-align: start;
  flex: 0 0 min(380px, 85vw);
  background: var(--color-surface);
  border-radius: var(--radius-card);
  padding: 36px;
  box-shadow: var(--shadow-card);
  border: 1px solid rgba(11, 30, 61, 0.03);
  transition: transform 0.45s var(--ease-standard), box-shadow 0.45s var(--ease-standard);
}
.testimonial-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-elevated); }
.testimonial-card__stars { color: var(--color-gold); letter-spacing: 2px; margin-bottom: 16px; font-size: 1.1rem; }
.testimonial-card__name { margin-top: 20px; font-weight: 700; color: var(--color-charcoal); }
.testimonial-card__city { font-size: 0.88rem; color: var(--color-slate); margin-top: 2px; }

/* ---------- CTA Band (full-bleed gradient section) ---------- */
.section--cta-gradient { background: var(--grad-primary); padding: 64px var(--gutter-mobile); box-shadow: 0 12px 36px rgba(41, 181, 232, 0.25); }
.cta-band {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  color: var(--color-white);
  max-width: 1100px;
  margin: 0 auto;
}
.cta-band h2 { color: var(--color-white); font-size: var(--fs-h2); font-weight: 800; max-width: 500px; }
.cta-band .btn--primary { background: var(--color-white); color: var(--color-brand); }
.cta-band .btn--primary:hover { background: var(--color-ocean); color: var(--color-white); }

/* ---------- FAQ Accordion (CSS Grid Transition) ---------- */
.accordion-item {
  border-bottom: 1px solid var(--color-mist);
}
.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 8px;
  text-align: left;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--color-charcoal);
  transition: color 0.25s ease;
}
.accordion-trigger:hover { color: var(--color-brand); }
.accordion-trigger[aria-expanded="true"] { color: var(--color-brand-hover); }
.accordion-trigger .chev { transition: transform 0.3s var(--ease-standard); flex-shrink: 0; color: var(--color-brand); }
.accordion-trigger[aria-expanded="true"] .chev { transform: rotate(180deg); }

/* Buttery smooth height animations utilizing Grid Template Rows collapse */
.accordion-panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s var(--ease-standard);
  overflow: hidden;
}
.accordion-trigger[aria-expanded="true"] + .accordion-panel {
  grid-template-rows: 1fr;
}
.accordion-panel__inner {
  min-height: 0; /* Required for collapse animations in CSS Grid */
  padding: 0 8px 24px;
  color: var(--color-slate);
  font-size: 1rem;
  line-height: 1.6;
}

/* ---------- Forms ---------- */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 500;
}
.form-input {
  padding: 14px 16px;
  border: 1px solid var(--color-mist);
  border-radius: var(--radius-input);
  background: var(--color-pearl);
  font-family: inherit;
  font-size: 1rem;
  color: var(--color-charcoal);
  transition: border-color var(--dur-fast) ease, box-shadow var(--dur-fast) ease, background var(--dur-fast) ease;
}
.form-input:focus {
  outline: none;
  border-color: var(--color-brand);
  background: var(--color-surface);
  box-shadow: 0 0 0 3px rgba(41, 181, 232, 0.15);
}

/* ---------- Footer ---------- */
.footer {
  background: var(--grad-ocean);
  color: rgba(255, 255, 255, 0.75);
  padding: 80px 0 32px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
}
@media (min-width: 768px) { .footer__grid { grid-template-columns: 2fr 1fr 1fr 1.2fr; } }
.footer h4 { color: var(--color-white); font-size: 1.05rem; margin-bottom: 20px; font-weight: 700; }
.footer a { color: rgba(255, 255, 255, 0.7); display: block; padding: 6px 0; font-size: 0.94rem; transition: color 0.2s; }
.footer a:hover { color: var(--color-brand); }
.footer__bottom {
  margin-top: 64px;
  padding-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex; flex-wrap: wrap; gap: 16px;
  justify-content: space-between;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}
.footer__socials { display: flex; gap: 16px; }
.footer__socials a { padding: 0; color: rgba(255,255,255,0.7); transition: color 0.2s; }
.footer__socials a:hover { color: var(--color-brand); }

/* ---------- Mobile float CTA ---------- */
.float-cta {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 90;
  display: flex;
  background: var(--color-surface);
  box-shadow: 0 -8px 30px rgba(11, 30, 61, 0.15);
  transform: translateY(100%);
  transition: transform var(--dur-fast) var(--ease-standard);
}
.float-cta.is-visible { transform: translateY(0); }
@media (min-width: 900px) { .float-cta { display: none; } }
.float-cta a {
  flex: 1;
  text-align: center;
  padding: 16px 0;
  font-weight: 700;
  font-size: 0.98rem;
  transition: background 0.2s;
}
.float-cta a:first-child { background: var(--color-ocean); color: var(--color-white); }
.float-cta a:last-child { background: var(--color-brand); color: var(--color-white); }


/* ==========================================================================
   PACIFIC WAVE — RESPONSIVE GRID LAYOUTS & HEIGHT ALIGNMENT
   ========================================================================== */

/* 1. Before & After comparison grid */
@media (min-width: 768px) {
  #before-after-grid > div {
    grid-column: span 4 / span 4 !important;
  }
}
#before-after-grid .ba-slider {
  width: 100%;
  aspect-ratio: auto;
  transition: transform 0.4s var(--ease-standard), box-shadow 0.4s var(--ease-standard);
}
#before-after-grid .hover-lift:hover .ba-slider {
  transform: translateY(-8px);
  box-shadow: var(--shadow-elevated);
}

/* 2. Core pillars grid (Services page) */
@media (min-width: 768px) {
  #services-pillars-grid > div {
    grid-column: span 4 / span 4 !important;
  }
}

/* 3. Residential Page checklist */
@media (min-width: 600px) {
  #residential-checklist-grid > .card {
    grid-column: span 6 / span 6 !important;
  }
}
@media (min-width: 1024px) {
  #residential-checklist-grid > .card {
    grid-column: span 4 / span 4 !important;
  }
}

/* 4. Commercial Page Industries */
@media (min-width: 600px) {
  #commercial-industries-grid > .card {
    grid-column: span 6 / span 6 !important;
  }
}
@media (min-width: 1024px) {
  #commercial-industries-grid > .card {
    grid-column: span 4 / span 4 !important;
  }
}

/* 5. Commercial Page Checklist */
@media (min-width: 600px) {
  #commercial-checklist-grid > .card {
    grid-column: span 6 / span 6 !important;
  }
}
@media (min-width: 1024px) {
  #commercial-checklist-grid > .card {
    grid-column: span 4 / span 4 !important;
  }
}

/* 6. About Page founders grid */
@media (min-width: 768px) {
  #about-founders-grid > .card {
    grid-column: span 6 / span 6 !important;
  }
}

/* 7. Contact Layout grid split */
@media (min-width: 900px) {
  #contact-layout-grid > div:first-child {
    grid-column: span 7 / span 7 !important;
  }
  #contact-layout-grid > div:last-child {
    grid-column: span 5 / span 5 !important;
  }
}

/* 8. Quality fits grid (2-column homepage split) */
@media (min-width: 900px) {
  #quality-fits-grid > div:first-child {
    grid-column: span 6 / span 6 !important;
  }
  #quality-fits-grid > div:last-child {
    grid-column: span 6 / span 6 !important;
  }
}
#quality-fits-grid .quality-img img {
  transition: transform 0.6s var(--ease-standard);
}
#quality-fits-grid .quality-img:hover img {
  transform: scale(1.06);
}

/* 9. Why clients stick grid (5/7 homepage split) */
@media (min-width: 900px) {
  #why-stick-grid > div:first-child {
    grid-column: span 5 / span 5 !important;
  }
  #why-stick-grid > div:last-child {
    grid-column: span 7 / span 7 !important;
  }
}
#why-stick-grid .why-stick-img img {
  transition: transform 0.6s var(--ease-standard);
}
#why-stick-grid .why-stick-img:hover img {
  transform: scale(1.05);
}

/* 10. Peace of mind grid (About page intro) */
@media (min-width: 768px) {
  #peace-grid {
    grid-template-columns: repeat(4, 1fr) !important;
  }
  #peace-grid .bento-card {
    grid-column: span 1 / span 1 !important;
  }
}

/* 11. B2B stats grid (Commercial page B2B statistics) */
@media (max-width: 900px) {
  #b2b-stats {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}
@media (max-width: 480px) {
  #b2b-stats {
    grid-template-columns: 1fr !important;
  }
}

/* 12. Grid 2col mobile helper */
@media (max-width: 600px) {
  .grid-2col-mobile {
    grid-template-columns: 1fr !important;
  }
}

/* ==========================================================================
   CARD STRETCHING & HEIGHT ALIGNMENT
   ========================================================================== */

/* Stretch all grid card wrappers to equal heights */
.grid > .card,
.grid > .reveal-up,
.grid-3-col > .card,
#residential-checklist-grid > .card,
#commercial-checklist-grid > .card,
#commercial-industries-grid > .card,
#about-founders-grid > .card {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
  justify-content: flex-start !important;
}

/* Stretch the service-card body content */
.service-card {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
}

.service-card__body {
  display: flex !important;
  flex-direction: column !important;
  flex-grow: 1 !important;
}

.service-card__cta {
  margin-top: auto !important;
  padding-top: 16px !important;
}

/* Defensive responsive container and grid settings to prevent GHL overflow clipping */
.container {
  width: 100% !important;
  max-width: var(--container-max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: var(--gutter-mobile) !important;
  padding-right: var(--gutter-mobile) !important;
  box-sizing: border-box !important;
}

@media (min-width: 768px) {
  .container {
    padding-left: var(--gutter-desktop) !important;
    padding-right: var(--gutter-desktop) !important;
  }
}

.grid {
  display: grid !important;
  grid-template-columns: repeat(12, 1fr) !important;
  gap: var(--gutter-mobile) !important;
}

@media (min-width: 768px) {
  .grid {
    gap: var(--gutter-desktop) !important;
  }
}

/* Fix mobile clipping on hover-slider or custom widgets */
@media (max-width: 480px) {
  .hover-slider__media {
    width: 100% !important;
    aspect-ratio: 4 / 5 !important;
    height: auto !important;
  }
}
