/* ==========================================================================
   A.A. Mudanya & Co. Advocates — stylesheet
   Palette:  --navy (deep brand navy) / --blue (accent, CTAs, links)
             --gold (understated highlight) / --ink (body text) / --paper (bg)
   Type:     Source Serif 4 for headings, Inter for UI/body
   ========================================================================== */

:root {
  --navy: #0c2340;
  --navy-2: #102b4e;
  --blue: #1e5aa8;
  --blue-dark: #164680;
  --gold: #b98a3d;
  --ink: #232a33;
  --ink-soft: #5b6472;
  --paper: #ffffff;
  --paper-2: #f5f7fa;
  --line: #e3e8ee;

  --font-display: "Source Serif 4", Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --container: 1180px;
  --radius: 6px;
  --shadow: 0 10px 30px rgba(12, 35, 64, 0.08);
}

* { box-sizing: border-box; }

/* ---------- contact popover (Call / WhatsApp) ---------- */
.contact-popover {
  position: fixed;
  z-index: 200;
  width: min(280px, calc(100vw - 24px));
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 20px 45px rgba(12,35,64,.25);
  padding: 14px;
  opacity: 0;
  transform: translateY(-6px);
  pointer-events: none;
  transition: opacity .15s ease, transform .15s ease;
}
.contact-popover.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}
.contact-popover-label {
  font-size: .74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink-soft);
  margin-bottom: 10px;
}
.contact-popover-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: 10px;
  font-weight: 600;
  font-size: .92rem;
  color: var(--ink);
  border: 1px solid var(--line);
  margin-bottom: 8px;
  transition: background .15s ease, border-color .15s ease;
}
.contact-popover-option:last-child { margin-bottom: 0; }
.contact-popover-option svg { flex-shrink: 0; }
.contact-popover-call { color: var(--navy); }
.contact-popover-call:hover { background: var(--paper-2); border-color: var(--blue); }
.contact-popover-whatsapp { color: #fff; background: #25d366; border-color: #25d366; }
.contact-popover-whatsapp:hover { background: #1ebe5a; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; color: var(--navy); margin: 0 0 .5em; line-height: 1.2; }
p { margin: 0 0 1em; color: var(--ink-soft); }
.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

/* ---------- buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: .92rem;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .12s ease;
  white-space: nowrap;
  overflow: hidden;
}
.btn::after {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.35), transparent);
  transform: skewX(-20deg);
  transition: left .55s ease;
  pointer-events: none;
}
.btn:hover::after { left: 130%; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); }
.btn-outline { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-outline:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.btn-outline-dark { background: transparent; color: var(--blue); border-color: var(--blue); }
.btn-outline-dark:hover { background: var(--blue); color: #fff; }
.btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.6); }
.btn-outline-light:hover { background: #fff; color: var(--navy); }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: var(--paper-2); }
.btn-sm { padding: 9px 18px; font-size: .82rem; }

/* ---------- pulse effect for CTAs ---------- */
@keyframes ctaPulse {
  0% { box-shadow: 0 0 0 0 rgba(30,90,168,.45); }
  70% { box-shadow: 0 0 0 14px rgba(30,90,168,0); }
  100% { box-shadow: 0 0 0 0 rgba(30,90,168,0); }
}
.cta-pulse { animation: ctaPulse 2.2s ease-out infinite; }
.cta-pulse:hover { animation-play-state: paused; }

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-size: .78rem;
  font-weight: 700;
  color: var(--blue);
  margin: 0 0 .6em;
}
.section-tag::before {
  content: "";
  width: 26px;
  height: 2px;
  background: var(--gold);
  display: inline-block;
}
.section-tag-light { color: #9fc0e8; }

/* ---------- scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .55s ease, transform .55s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }
.practice-grid .reveal:nth-child(2) { transition-delay: .05s; }
.practice-grid .reveal:nth-child(3) { transition-delay: .1s; }
.practice-grid .reveal:nth-child(5) { transition-delay: .05s; }
.practice-grid .reveal:nth-child(6) { transition-delay: .1s; }
.practice-grid .reveal:nth-child(8) { transition-delay: .05s; }
.practice-grid .reveal:nth-child(9) { transition-delay: .1s; }
.why-grid .reveal:nth-child(2) { transition-delay: .06s; }
.why-grid .reveal:nth-child(3) { transition-delay: .12s; }
.why-grid .reveal:nth-child(4) { transition-delay: .18s; }
.why-grid .reveal:nth-child(5) { transition-delay: .24s; }
.testimonial-grid .reveal:nth-child(2) { transition-delay: .08s; }
.testimonial-grid .reveal:nth-child(3) { transition-delay: .16s; }
.team-grid .reveal:nth-child(2) { transition-delay: .06s; }
.team-grid .reveal:nth-child(3) { transition-delay: .12s; }
.team-grid .reveal:nth-child(4) { transition-delay: .18s; }
.insights-grid .reveal:nth-child(2) { transition-delay: .08s; }
.insights-grid .reveal:nth-child(3) { transition-delay: .16s; }

/* ================= UTILITY BAR ================= */
.utility-bar { background: var(--navy); color: #b9c8dd; font-size: .8rem; }
.utility-inner { display: flex; justify-content: space-between; align-items: center; padding: 9px 24px; gap: 20px; flex-wrap: wrap; }
.utility-contact { display: flex; gap: 24px; flex-wrap: wrap; }
.utility-contact a { display: inline-flex; align-items: center; gap: 6px; color: #b9c8dd; transition: color .15s ease; }
.utility-contact a:hover { color: #fff; }
.utility-social { display: flex; align-items: center; gap: 14px; }
.utility-social a { color: #b9c8dd; display: flex; }
.utility-social a:hover { color: var(--gold); }
.utility-divider { width: 1px; height: 14px; background: rgba(255,255,255,.2); }

/* ================= HEADER ================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(12,35,64,.08);
  transition: box-shadow .2s ease, border-color .2s ease;
}
.site-header.scrolled { box-shadow: 0 8px 24px rgba(12,35,64,.08); }
.header-inner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-top: 12px;
  padding-bottom: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--navy); margin-right: auto; margin-left: 0; }
.brand-logo-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0;
  margin-left: 0;
  flex-shrink: 0;
}
.brand-logo-mark {
  width: 165px;
  max-width: 100%;
  height: auto;
  display: block;
  flex-shrink: 0;
  object-fit: contain;
}
.brand-logo-mark-footer {
  width: 150px;
}

@media (max-width: 760px) {
  .brand-logo-mark { width: 140px; }
  .brand-logo-mark-footer { width: 120px; }
}

.main-nav { display: flex; align-items: center; gap: 12px; }
.main-nav > a {
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--navy);
  padding: 8px 0;
  border-bottom: 2px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.main-nav > a:hover,
.main-nav > a.active { color: var(--blue); border-color: var(--blue); }

.nav-dropdown { position: relative; }
.nav-dropdown-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  font: inherit;
  font-size: .93rem;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  padding: 6px 2px;
}
.nav-dropdown-toggle:hover { color: var(--blue); }
.nav-dropdown-toggle svg { transition: transform .15s ease; }
.nav-dropdown.open .nav-dropdown-toggle svg { transform: rotate(180deg); }
.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 14px);
  left: 50%;
  transform: translateX(-50%);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  min-width: 260px;
  padding: 8px;
  display: none;
  flex-direction: column;
}
.nav-dropdown.open .nav-dropdown-menu { display: flex; }
.nav-dropdown-menu a {
  padding: 9px 12px;
  font-size: .87rem;
  border-radius: 4px;
  color: var(--ink);
}
.nav-dropdown-menu a:hover { background: var(--paper-2); color: var(--blue); }

.btn-nav { flex-shrink: 0; }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 34px;
  height: 34px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}
.nav-toggle span { display: block; height: 2px; width: 100%; background: var(--navy); transition: transform .2s ease, opacity .2s ease; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ================= HERO ================= */
.hero {
  position: relative;
  min-height: 88vh;
  display: flex;
  flex-direction: column;
  color: #fff;
  overflow: hidden;
  background: linear-gradient(120deg, var(--navy) 0%, var(--blue-dark) 55%, var(--blue) 100%);
}

/* ---------- slideshow ---------- */
.hero-slideshow {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  background: var(--navy);
}
.hero-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.1);
  animation: heroSlideCycle 24s infinite;
}
.hero-slide:nth-child(1) { animation-delay: 0s; }
.hero-slide:nth-child(2) { animation-delay: 6s; }
.hero-slide:nth-child(3) { animation-delay: 12s; }
.hero-slide:nth-child(4) { animation-delay: 18s; }
@keyframes heroSlideCycle {
  0%      { opacity: 0; transform: scale(1.1); }
  3%      { opacity: 1; }
  22%     { opacity: 1; transform: scale(1.18); }
  26%     { opacity: 0; transform: scale(1.18); }
  100%    { opacity: 0; }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    linear-gradient(100deg, rgba(6,16,32,.92) 15%, rgba(9,24,46,.72) 45%, rgba(9,24,46,.42) 75%),
    radial-gradient(ellipse 700px 500px at 90% 10%, rgba(185,138,61,.2), transparent 60%),
    radial-gradient(ellipse 800px 600px at 60% 100%, rgba(30,90,168,.35), transparent 60%);
}
.hero-scales {
  position: absolute;
  right: 5%;
  top: 50%;
  transform: translateY(-58%);
  width: min(300px, 26vw);
  height: auto;
  color: rgba(207,224,245,.12);
  z-index: 0;
}
.hero-inner {
  position: relative;
  z-index: 2;
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  padding-top: 60px;
  padding-bottom: 56px;
}
.hero-copy-block { max-width: 700px; }

/* staggered fade-up entrance for hero copy */
.hero-anim {
  opacity: 0;
  transform: translateY(22px);
  animation: heroFadeUp .75s ease forwards;
}
.hero-anim-1 { animation-delay: .05s; }
.hero-anim-2 { animation-delay: .18s; }
.hero-anim-3 { animation-delay: .32s; }
.hero-anim-4 { animation-delay: .46s; }
.hero-anim-5 { animation-delay: .6s; }
@keyframes heroFadeUp {
  to { opacity: 1; transform: translateY(0); }
}

.hero .eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: .72rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 18px;
}
.hero .eyebrow::before { content: ""; width: 32px; height: 1.5px; background: var(--gold); display: inline-block; }
.hero h1 {
  color: #fff;
  font-size: clamp(2.6rem, 5vw, 4.4rem);
  margin-bottom: 18px;
  letter-spacing: -.05em;
  line-height: .96;
  font-weight: 600;
  max-width: 700px;
  text-shadow: 0 4px 24px rgba(0,0,0,.25);
}
.hero h1 span { color: #dfeaf7; }
.hero-copy {
  color: rgba(255,255,255,.88);
  font-size: 1.08rem;
  max-width: 590px;
  margin-bottom: 32px;
  line-height: 1.8;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 34px; }

/* ---------- badge (formerly hero-visual-badge) ---------- */
.hero-badge {
  display: inline-flex;
  flex-direction: column;
  background: rgba(255,255,255,.94);
  color: var(--navy);
  border-radius: 14px;
  padding: 14px 20px;
  box-shadow: 0 16px 30px rgba(6,18,34,.3);
  animation: heroFadeUp .75s ease forwards, heroBadgeFloat 3.4s ease-in-out .9s infinite;
}
.hero-badge strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--navy);
  line-height: 1.1;
}
.hero-badge span {
  display: block;
  font-size: .76rem;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: 4px;
}
@keyframes heroBadgeFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* ---------- slide indicator dots ----------
   Positioned relative to `.hero-inner` (not the whole `.hero` section) so
   they always sit a fixed distance above the copy block regardless of how
   tall the stats bar underneath ends up being — this is what keeps them
   from drifting onto/behind the stats bar on shorter screens. */
.hero-slide-dots {
  position: absolute;
  z-index: 2;
  right: 28px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.hero-slide-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,.35);
  animation: heroDotPulse 24s infinite;
}
.hero-slide-dots span:nth-child(1) { animation-delay: 0s; }
.hero-slide-dots span:nth-child(2) { animation-delay: 6s; }
.hero-slide-dots span:nth-child(3) { animation-delay: 12s; }
.hero-slide-dots span:nth-child(4) { animation-delay: 18s; }
@keyframes heroDotPulse {
  0%, 22% { background: var(--gold); box-shadow: 0 0 0 3px rgba(185,138,61,.3); }
  26%, 100% { background: rgba(255,255,255,.35); box-shadow: none; }
}

/* ---------- scroll cue ----------
   Also anchored to `.hero-inner` (see note on `.hero-slide-dots` above) so
   it always floats just under the hero copy, never on top of the stats
   bar/badge below it. */
.hero-scroll-cue {
  position: absolute;
  z-index: 2;
  left: 50%;
  bottom: -8px;
  transform: translateX(-50%);
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.4);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: heroScrollBounce 2s ease-in-out infinite;
  transition: background .18s ease, border-color .18s ease;
}
.hero-scroll-cue:hover { background: rgba(255,255,255,.14); border-color: #fff; }
@keyframes heroScrollBounce {
  0%, 100% { transform: translate(-50%, 0); }
  50% { transform: translate(-50%, 6px); }
}
@media (max-width: 760px) {
  .hero-slide-dots { display: none; }
}

.hero-stats {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  background: rgba(6,18,34,.55);
  border-top: 1px solid rgba(255,255,255,.1);
  backdrop-filter: blur(2px);
}
.hero-stats-inner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 26px 24px;
}
.stat { text-align: center; border-right: 1px solid rgba(255,255,255,.12); padding: 0 12px; }
.stat:last-child { border-right: none; }
.stat-value { display: block; font-family: var(--font-display); font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-weight: 700; color: var(--gold); line-height: 1; margin-bottom: 6px; }
.stat-label { display: block; font-size: .78rem; letter-spacing: .03em; color: #b9c8dd; }

/* ================= MARQUEE ================= */
.marquee-strip {
  overflow: hidden;
  background: var(--navy);
  padding: 15px 0;
  white-space: nowrap;
  border-top: 1px solid rgba(255,255,255,.08);
}
.marquee-track {
  display: inline-flex;
  align-items: center;
  gap: 22px;
  animation: marqueeScroll 26s linear infinite;
  will-change: transform;
}
.marquee-strip:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: .02em;
  font-size: .95rem;
  color: #fff;
}
.marquee-track .dot { color: var(--gold); font-weight: 700; }
@keyframes marqueeScroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- trusted-by client strip (light variant) ---------- */
.clients-strip { background: var(--paper-2); padding: 34px 0 0; border-top: 1px solid var(--line); }
.clients-strip-label {
  text-align: center;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-size: .74rem;
  font-weight: 700;
  color: var(--ink-soft);
  margin-bottom: 18px;
}
.marquee-strip-light {
  background: transparent;
  border-top: none;
  padding: 0 0 34px;
}
.marquee-strip-light .marquee-track span { color: var(--navy); font-weight: 600; }
.marquee-strip-light .marquee-track .dot { color: var(--blue); }

/* ---------- trusted-by client logos ---------- */
.marquee-track-logos { gap: 0; }
.client-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 22px;
}
.client-item img {
  height: 34px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
}
.client-item-text { font-family: var(--font-display); }
@media (max-width: 560px) {
  .client-item img { height: 28px; }
  .client-item { padding: 0 14px; gap: 8px; }
}

/* ================= ABOUT ================= */
.about { padding: 90px 0; }
.about-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: 60px; align-items: center; }
.about-media img { border-radius: var(--radius); box-shadow: var(--shadow); }
.about-copy h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.about-copy p { max-width: 54ch; }

/* ================= PRACTICE AREAS ================= */
.practice-areas { padding: 90px 0; background: var(--paper-2); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: 44px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin: 0; }
.section-sub { max-width: 320px; margin: 0; text-align: right; }
@media (max-width: 700px) { .section-sub { text-align: left; } }

.practice-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.practice-card {
  position: relative;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: box-shadow .25s ease, border-color .25s ease, transform .25s ease;
}
.practice-card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), var(--gold));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .3s ease;
}
.practice-card:hover {
  box-shadow: var(--shadow);
  border-color: transparent;
  transform: translateY(-4px);
}
.practice-card:hover::before { transform: scaleX(1); }
.practice-card-visual {
  position: relative;
  height: 164px;
  overflow: hidden;
  background: var(--paper-2);
}
.practice-card-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.82) contrast(1.04);
}
.practice-card-body {
  padding: 24px 24px 26px;
  position: relative;
}
.practice-index {
  position: absolute;
  top: 20px;
  right: 24px;
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  color: var(--line);
  z-index: 1;
}
.practice-icon {
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #cfe0f5;
  border-radius: 10px;
  margin-bottom: 18px;
}
.practice-card h3 { font-size: 1.08rem; margin-bottom: 10px; padding-right: 30px; }
.practice-card p { font-size: .92rem; margin-bottom: 16px; }
.learn-more { display: inline-flex; align-items: center; gap: 6px; color: var(--blue); font-weight: 600; font-size: .88rem; background: transparent; border: none; padding: 0; cursor: pointer; font-family: inherit; }
.learn-more svg { transition: transform .15s ease; }
.learn-more:hover svg { transform: translateX(3px); }

.practice-detail-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 28px;
}
.practice-detail-stat {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  padding: 18px 18px 16px;
}
.practice-detail-stat span {
  display: block;
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #cfe0f5;
  margin-bottom: 10px;
}
.practice-detail-stat strong {
  display: block;
  font-size: .95rem;
  line-height: 1.5;
  color: #fff;
  font-weight: 600;
}

.practice-detail-page {
  display: none;
  background: #f7f9fc;
  padding: 40px 0 90px;
}
.practice-detail-page.active { display: block; }
.practice-detail-wrap { padding-top: 10px; }
.practice-detail-back {
  margin-bottom: 18px;
}
.practice-detail-back a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--blue);
  font-weight: 600;
}
.practice-detail-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 32px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 30px;
  box-shadow: var(--shadow);
}
.practice-detail-copy h2 {
  font-size: clamp(2rem, 3vw, 2.8rem);
  margin-bottom: 14px;
}
.practice-detail-summary,
.practice-detail-focus {
  font-size: 1rem;
  color: var(--ink);
}
.practice-detail-focus {
  color: var(--blue);
  font-weight: 600;
}
.practice-detail-list {
  list-style: none;
  padding: 0;
  margin: 20px 0 0;
  display: grid;
  gap: 10px;
}
.practice-detail-list li {
  position: relative;
  padding-left: 22px;
  color: var(--ink-soft);
}
.practice-detail-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
}
.practice-detail-actions {
  margin-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.practice-detail-visual {
  overflow: hidden;
  border-radius: 16px;
  min-height: 100%;
  background: linear-gradient(150deg, #dfeaf7, #edf4ff);
}
.practice-detail-visual img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}
.practice-detail-gallery {
  margin-top: 24px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 300px));
  justify-content: center;
  gap: 18px;
}
.practice-detail-gallery-item {
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  min-height: 200px;
  box-shadow: 0 10px 24px rgba(12,35,64,.08);
  transition: transform .25s ease, box-shadow .25s ease;
}
.practice-detail-gallery-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(12,35,64,.14);
}
.practice-detail-gallery-item img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.practice-detail-panel {
  margin-top: 24px;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #fff;
  border-radius: 16px;
  padding: 28px 30px;
}
.practice-detail-panel h3 {
  color: #fff;
  margin-bottom: 10px;
}
.metrics-swipe-hint {
  display: none;
  font-size: .7rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: normal;
  color: #cfe0f5;
  background: rgba(255,255,255,.12);
  border-radius: 999px;
  padding: 3px 10px;
  margin-left: 8px;
  vertical-align: middle;
  animation: swipeHintNudge 1.8s ease-in-out infinite;
}
@keyframes swipeHintNudge {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}
.practice-detail-panel p {
  color: #dfeaf7;
  margin: 0;
}
.insight-related-list { display: flex; flex-direction: column; gap: 12px; }

/* ================= WHY CHOOSE US ================= */
.why-us {
  position: relative;
  background: var(--navy);
  color: #fff;
  padding: 90px 0;
  overflow: hidden;
}
.why-us::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 900px 500px at 12% 100%, rgba(30,90,168,.35), transparent 60%);
  pointer-events: none;
}
.why-us .container { position: relative; }
.why-us h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.1rem); max-width: 640px; margin-bottom: 44px; }
.why-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; }
.why-card {
  text-align: center;
  padding: 26px 14px;
  border-radius: var(--radius);
  background: rgba(255,255,255,.04);
  border: 1px solid rgba(255,255,255,.08);
  transition: background .2s ease, transform .2s ease;
}
.why-card:hover { background: rgba(255,255,255,.08); transform: translateY(-3px); }
.why-icon {
  width: 60px; height: 60px;
  margin: 0 auto 18px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(150deg, var(--gold), #8a6529);
  border-radius: 50%;
  color: #12202f;
}
.why-card h3 { color: #fff; font-size: 1rem; margin-bottom: 8px; }
.why-card p { color: #b9c8dd; font-size: .87rem; margin: 0; }

/* ================= TESTIMONIALS ================= */
.testimonials { padding: 90px 0; }
.testimonials h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin-bottom: 44px; }
.testimonial-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.testimonial-card {
  margin: 0;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: var(--radius);
  padding: 30px 26px;
}
.quote-mark { color: var(--blue); opacity: .35; margin-bottom: 14px; }
.testimonial-card blockquote { margin: 0 0 20px; font-size: .96rem; color: var(--ink); font-style: italic; }
.testimonial-card figcaption { display: flex; flex-direction: column; gap: 2px; }
.testimonial-card figcaption strong { font-size: .9rem; color: var(--navy); }
.testimonial-card figcaption span { font-size: .82rem; color: var(--ink-soft); }

/* ================= TEAM ================= */
.team { padding: 90px 0; background: var(--paper-2); }
.team-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.team-card {
  /* `.team-card` is now a <button> (so it's keyboard- and screen-reader-
     accessible as an interactive element) — reset native button styling
     back to how the card looked as a plain div. */
  display: flex;
  flex-direction: column;
  width: 100%;
  font: inherit;
  color: inherit;
  cursor: pointer;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
  text-align: center;
  transition: box-shadow .2s ease, transform .2s ease;
}
.team-card:hover, .team-card:focus-visible { box-shadow: var(--shadow); transform: translateY(-3px); }
.team-card:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.team-avatar {
  width: 100%;
  aspect-ratio: 3 / 4;
  margin: 0;
  display: flex; align-items: center; justify-content: center;
  border-radius: 0;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #cfe0f5;
  font-family: var(--font-display);
  font-size: 3.4rem;
  font-weight: 600;
  overflow: hidden;
}
.team-avatar img { width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.team-card-body { padding: 26px 22px 30px; }
.team-card h3 { font-size: 1.15rem; margin-bottom: 4px; }
.team-role { color: var(--blue); font-size: .88rem; font-weight: 600; margin-bottom: 10px; }
.team-focus { font-size: .88rem; margin: 0; }
.team-view-more {
  display: inline-block;
  margin-top: 16px;
  font-size: .78rem;
  font-weight: 600;
  color: var(--blue);
  border-top: 1px solid var(--line);
  padding-top: 14px;
  width: 100%;
}

/* ---------- team profile modal ---------- */
.modal-content.team-modal-content { width: min(620px, 94%); max-height: 84vh; overflow-y: auto; text-align: left; }
.team-modal-header { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; padding-right: 24px; }
.team-modal-avatar {
  flex-shrink: 0;
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #cfe0f5;
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  overflow: hidden;
}
.team-modal-avatar img { width: 100%; height: 100%; object-fit: cover; }
.team-modal-header h3 { font-size: 1.2rem; margin-bottom: 4px; }
.team-modal-credentials { color: var(--blue); font-size: .86rem; font-weight: 600; margin: 0; }
.team-modal-section { margin-bottom: 18px; }
.team-modal-section:last-child { margin-bottom: 0; }
.team-modal-section h4 {
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.team-modal-section p { font-size: .92rem; line-height: 1.7; margin-bottom: 10px; }
.team-modal-section p:last-child { margin-bottom: 0; }
.team-modal-section ul { margin: 0; padding-left: 18px; font-size: .9rem; line-height: 1.6; }
.team-modal-section li { margin-bottom: 4px; }
.team-modal-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.team-modal-tags span {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: .78rem;
  color: var(--navy);
  font-weight: 600;
}
.team-modal-areas { display: flex; flex-direction: column; gap: 14px; }
.team-modal-area {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 16px;
}
.team-modal-area h5 {
  font-size: .92rem;
  color: var(--navy);
  margin: 0 0 6px;
}
.team-modal-area p { font-size: .86rem; line-height: 1.6; margin: 0; color: var(--ink-soft); }
.team-modal-quote {
  border-left: 3px solid var(--blue);
  padding: 4px 0 4px 16px;
}
.team-modal-quote blockquote {
  margin: 0;
  font-size: .96rem;
  font-style: italic;
  line-height: 1.7;
  color: var(--navy);
}
.team-modal-values span { color: var(--blue); }
@media (max-width: 560px) {
  .team-modal-header { flex-direction: column; align-items: flex-start; }
}

/* ================= INSIGHTS ================= */
.insights { padding: 90px 0; }
.insights-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.insight-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s ease, transform .2s ease;
}
.insight-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.insight-card-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--paper-2);
}
.insight-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.insight-card:hover .insight-card-media img { transform: scale(1.07); }
.insight-card-body { padding: 22px 22px 24px; display: flex; flex-direction: column; flex: 1; }
.insight-meta {
  font-size: .72rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 8px;
}
.insight-card h3 { font-size: 1.05rem; margin-bottom: 10px; }
.insight-card h3 a { color: var(--navy); transition: color .15s ease; }
.insight-card h3 a:hover { color: var(--blue); }
.insight-card p { font-size: .9rem; margin-bottom: 16px; flex: 1; }
.insight-tag {
  display: inline-block;
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #fff;
  background: rgba(9,24,46,.85);
  padding: 5px 11px;
  border-radius: 20px;
}
.insight-card-media .insight-tag {
  position: absolute;
  left: 14px;
  bottom: 14px;
}

/* ---------- insight article page ---------- */
.insight-page { padding: 0 0 90px; }
.insight-hero {
  position: relative;
  min-height: 46vh;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
  color: #fff;
  overflow: hidden;
}
.insight-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, rgba(6,16,32,.92) 5%, rgba(6,16,32,.55) 55%, rgba(6,16,32,.3) 100%);
}
.insight-hero-inner {
  position: relative;
  z-index: 1;
  padding: 60px 24px 40px;
  max-width: 860px;
}
.insight-hero-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #dfeaf7;
  font-weight: 600;
  font-size: .85rem;
  margin-bottom: 22px;
  transition: color .15s ease;
}
.insight-hero-back:hover { color: #fff; }
.insight-tag-hero { margin-bottom: 16px; background: rgba(185,138,61,.85); }
.insight-hero h1 {
  color: #fff;
  font-size: clamp(1.9rem, 3.4vw, 2.9rem);
  line-height: 1.12;
  margin-bottom: 16px;
  max-width: 780px;
}
.insight-hero-meta { display: flex; align-items: center; gap: 10px; font-size: .84rem; color: #cfe0f5; }
.insight-hero-meta .dot { opacity: .6; }

.insight-body-wrap { padding-top: 48px; }
.insight-body-grid {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 40px;
  align-items: start;
}
.insight-article { font-size: 1rem; }
.insight-article p { color: var(--ink); line-height: 1.85; margin-bottom: 1.2em; }
.insight-article .practice-detail-summary {
  font-size: 1.12rem;
  font-family: var(--font-display);
  color: var(--navy);
  line-height: 1.6;
  margin-bottom: 1.4em;
}
.insight-share {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 30px 0;
  padding: 16px 18px;
  background: var(--paper-2);
  border-radius: 12px;
  font-size: .82rem;
  font-weight: 600;
  color: var(--ink-soft);
}
.insight-share a {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.insight-share a:hover { background: var(--blue); color: #fff; border-color: var(--blue); }

.insight-sidebar { display: flex; flex-direction: column; gap: 24px; position: sticky; top: 100px; }
.insight-cta-panel p { margin-bottom: 16px; }
.insight-related h3 { font-size: 1rem; margin-bottom: 14px; color: var(--navy); }
.insight-related-card {
  display: flex;
  gap: 12px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px;
  background: #fff;
  transition: box-shadow .15s ease, transform .15s ease;
}
.insight-related-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.insight-related-card img {
  width: 68px;
  height: 68px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}
.insight-related-card h4 {
  margin: 3px 0 0;
  font-size: .87rem;
  font-family: var(--font-body);
  font-weight: 600;
  color: var(--navy);
  line-height: 1.35;
}
.insight-tag-sm {
  display: inline-block;
  font-size: .64rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .03em;
  color: var(--blue);
}

@media (max-width: 900px) {
  .insight-body-grid { grid-template-columns: 1fr; }
  .insight-sidebar { position: static; }
}
@media (max-width: 760px) {
  .insight-hero-inner { padding: 44px 20px 30px; }
}

/* ================= OFFICES ================= */
.offices { padding: 90px 0; }
.offices-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 30px; align-items: stretch; }
.offices-list { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.office-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.office-card h3 { display: flex; align-items: center; gap: 8px; font-size: 1.05rem; margin-bottom: 14px; color: var(--navy); }
.office-card h3 svg { color: var(--blue); flex-shrink: 0; }
.office-address { font-size: .9rem; margin-bottom: 14px; }
.office-phones { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.office-phones a { display: inline-flex; align-items: center; gap: 8px; font-size: .9rem; color: var(--ink); font-weight: 500; }
.office-phones a:hover { color: var(--blue); }
.office-phones svg { color: var(--blue); flex-shrink: 0; }

.assist-card {
  background: linear-gradient(150deg, var(--blue-dark), var(--navy));
  color: #fff;
  border-radius: var(--radius);
  padding: 40px 34px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.assist-copy { color: #d6e0ee; font-size: 1.02rem; margin-bottom: 26px; }
.assist-actions { display: flex; flex-wrap: wrap; gap: 14px; }

/* ================= CONTACT FORM ================= */
.contact-form-section { background: var(--paper-2); padding: 90px 0; }
.contact-form-section h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin-bottom: 34px; }
.contact-form { max-width: 720px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.form-field { margin-bottom: 20px; }
.form-field label { display: block; font-size: .87rem; font-weight: 600; margin-bottom: 7px; color: var(--navy); }
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  font: inherit;
  font-size: .95rem;
  background: #fff;
  color: var(--ink);
  transition: border-color .15s ease;
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus { border-color: var(--blue); outline: none; }
.form-field textarea { resize: vertical; }
.form-error { display: block; min-height: 1.2em; color: #b3261e; font-size: .8rem; margin-top: 5px; }
.form-status { margin-top: 16px; font-size: .92rem; font-weight: 600; min-height: 1.2em; }
.form-status.success { color: #1b7a3d; }

/* ================= CHATBOT ================= */
.chatbot-widget {
  position: fixed;
  right: 24px;
  bottom: 96px;
  z-index: 55;
}
.chatbot-fab {
  position: relative;
  width: 58px;
  height: 58px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 28px rgba(12,35,64,.28);
  cursor: pointer;
  transition: transform .15s ease;
}
.chatbot-fab:hover { transform: translateY(-2px); }
.chatbot-fab-ping {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid var(--blue);
  animation: ctaPulse 2.4s ease-out infinite;
  pointer-events: none;
}

.chatbot-banner {
  position: absolute;
  right: 70px;
  bottom: 12px;
  white-space: nowrap;
  background: var(--navy);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 10px 18px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: .86rem;
  cursor: pointer;
  box-shadow: 0 12px 24px rgba(12,35,64,.25);
  animation: bannerFloat 2.6s ease-in-out infinite;
  transition: opacity .2s ease, transform .2s ease;
}
.chatbot-banner::after {
  content: "";
  position: absolute;
  right: -6px;
  top: 50%;
  transform: translateY(-50%);
  border-width: 6px 0 6px 6px;
  border-style: solid;
  border-color: transparent transparent transparent var(--navy);
}
.chatbot-banner.is-hidden {
  opacity: 0;
  transform: translateX(10px);
  pointer-events: none;
}
@keyframes bannerFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}
@media (max-width: 560px) {
  .chatbot-banner { display: none; }
}
.chatbot-panel {
  position: absolute;
  right: 0;
  bottom: 72px;
  width: min(360px, calc(100vw - 32px));
  /* Fallback cap; JS (positionChatbotPanel) sets a precise inline value
     so the panel never rises above the header. */
  max-height: min(480px, calc(100vh - var(--header-offset, 190px) - 190px));
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(12,35,64,.18);
  overflow: hidden;
}
/* `.chatbot-panel` sets display:flex above, which (being an author
   stylesheet rule) otherwise beats the browser's default [hidden]
   { display:none } rule at equal specificity — silently keeping the
   panel visible even when the JS sets the hidden attribute. This
   more-specific rule restores hidden as the source of truth. */
.chatbot-panel[hidden] { display: none; }
.chatbot-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 14px 14px 14px 16px;
  background: linear-gradient(150deg, var(--navy), var(--blue-dark));
  color: #fff;
  flex-shrink: 0;
  overflow: visible; /* prevent close button clipping */
}
.chatbot-header > div {
  min-width: 0;
  flex: 1 1 auto;
}
.chatbot-header strong {
  display: block;
  font-size: .9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chatbot-header span {
  display: block;
  font-size: .7rem;
  opacity: .8;
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.chatbot-header button {
  width: 32px;
  height: 32px;
  min-width: 32px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.32);
  background: rgba(255,255,255,.12);
  color: #fff;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease;
  margin-right: 2px; /* ensure button is never clipped by panel edge */
  position: relative;
  z-index: 2;
}
.chatbot-header button:hover { background: rgba(255,255,255,.25); }
.chatbot-messages {
  flex: 1 1 auto;
  min-height: 120px;
  max-height: none;
  overflow-y: auto;
  background: #f7f9fc;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ---------- pre-chat email gate ---------- */
.chatbot-gate {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px 16px 20px;
  background: #fff;
  /* Safety net: if the visible area is ever too short to fit the whole
     gate, this scrolls internally instead of letting the panel's
     overflow:hidden clip the Start Chat button. */
  overflow-y: auto;
  min-height: 0;
}
.chatbot-panel.email-captured .chatbot-gate { display: none; }
.chatbot-panel:not(.email-captured) .chatbot-body { display: none; }
.chatbot-gate-lead {
  margin: 0;
  font-size: .87rem;
  color: var(--ink);
  line-height: 1.55;
}
.chatbot-gate-form { display: flex; flex-direction: column; gap: 8px; }
.chatbot-gate-form label {
  font-size: .74rem;
  font-weight: 600;
  color: var(--ink-soft);
}
.chatbot-gate-form input {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
  font-size: .88rem;
}
.chatbot-gate-form input:invalid.touched { border-color: #c0392b; }
.chatbot-gate-form .btn { margin-top: 4px; align-self: flex-start; }
.chatbot-gate-note {
  margin: 2px 0 0;
  font-size: .72rem;
  color: var(--ink-soft);
}
.chatbot-gate #chatbotGateError {
  min-height: 1em;
}

/* ---------- chat body (post email-capture) ---------- */
.chatbot-body {
  display: flex;
  flex-direction: column;
  min-height: 0;
  flex: 1 1 auto;
}
.chatbot-sync-status {
  display: inline-block;
  font-size: .68rem;
  color: #bcd4f2;
  margin-top: 2px;
  opacity: 0;
  transition: opacity .3s ease;
}
.chatbot-sync-status.is-visible { opacity: 1; }
.chatbot-message {
  max-width: 78%;
  padding: 10px 12px;
  border-radius: 14px;
  font-size: .87rem;
  line-height: 1.5;
}
.chatbot-message.bot {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}
.chatbot-message.user {
  align-self: flex-end;
  background: var(--blue);
  color: #fff;
}
.chatbot-message.typing {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 12px 14px;
}
.chatbot-message.typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ink-soft, #7c8aa0);
  opacity: .5;
  animation: chatbotTypingDot 1.1s infinite ease-in-out;
}
.chatbot-message.typing span:nth-child(2) { animation-delay: .15s; }
.chatbot-message.typing span:nth-child(3) { animation-delay: .3s; }
@keyframes chatbotTypingDot {
  0%, 60%, 100% { opacity: .35; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-3px); }
}
.chatbot-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 12px 0;
  background: #fff;
  flex-shrink: 0;
}
.chatbot-chip {
  border: 1px solid var(--line);
  background: #f4f7fb;
  color: var(--navy);
  border-radius: 999px;
  padding: 7px 10px;
  font-size: .75rem;
  cursor: pointer;
}
.chatbot-form {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px;
  background: #fff;
  border-top: 1px solid var(--line);
  flex-shrink: 0;
  box-sizing: border-box;
}
.chatbot-form input {
  flex: 1 1 auto;
  min-width: 0;
  width: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 14px;
  font: inherit;
  font-size: .85rem;
  box-sizing: border-box;
}
.chatbot-form button {
  flex-shrink: 0;
  white-space: nowrap;
  border: none;
  background: var(--blue);
  color: #fff;
  border-radius: 999px;
  padding: 10px 18px;
  font: inherit;
  font-weight: 600;
  font-size: .85rem;
  cursor: pointer;
  transition: background .15s ease;
}
.chatbot-form button:hover { background: var(--blue-dark); }

/* ================= WHATSAPP FAB ================= */
.whatsapp-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px rgba(0,0,0,.25);
  z-index: 50;
  transition: transform .15s ease;
}
.whatsapp-fab:hover { transform: scale(1.06); }

/* ================= BACK TO TOP ================= */
.back-to-top {
  position: fixed;
  right: 24px;
  bottom: 90px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity .2s ease, transform .2s ease;
  z-index: 50;
}
.back-to-top.visible { opacity: 1; pointer-events: auto; transform: translateY(0); }

/* ================= FOOTER ================= */
.site-footer { background: #081627; color: #b9c8dd; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr .9fr 1.2fr 1.1fr 1.2fr;
  gap: 34px;
  padding: 70px 0 50px;
}
.footer-brand p { color: #93a6bf; font-size: .9rem; }
.brand-footer { color: #fff; margin-bottom: 14px; }
.brand-footer .brand-logo-text { color: #dfeaf7; }
.social-links { display: flex; gap: 12px; margin-top: 18px; }
.social-links a {
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 50%;
  color: #cfe0f5;
  transition: background .15s ease, border-color .15s ease;
}
.social-links a:hover { background: var(--blue); border-color: var(--blue); }

.footer-col h4 { color: #fff; font-family: var(--font-body); font-size: .92rem; text-transform: uppercase; letter-spacing: .05em; margin-bottom: 18px; }
.footer-col ul { display: flex; flex-direction: column; gap: 11px; }
.footer-col a { font-size: .9rem; color: #a9bad2; transition: color .15s ease; }
.footer-col a:hover { color: #fff; }
.footer-contact li { line-height: 1.5; }

.footer-newsletter p { color: #93a6bf; font-size: .87rem; margin-bottom: 16px; }
.newsletter-form { display: flex; gap: 0; border: 1px solid rgba(255,255,255,.2); border-radius: var(--radius); overflow: hidden; }
.newsletter-form input {
  flex: 1;
  border: none;
  background: rgba(255,255,255,.06);
  color: #fff;
  padding: 12px 14px;
  font: inherit;
  font-size: .87rem;
}
.newsletter-form input::placeholder { color: #7c8fab; }
.newsletter-form input:focus { outline: none; background: rgba(255,255,255,.1); }
.newsletter-form button {
  background: var(--blue);
  color: #fff;
  border: none;
  padding: 0 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease;
}
.newsletter-form button:hover { background: var(--blue-dark); }
.footer-newsletter .form-status { font-size: .8rem; margin-top: 10px; color: #9fc0e8; }
.footer-newsletter .form-status.success { color: #6fd694; }

.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); }
.footer-bottom-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  padding: 20px 0;
  font-size: .82rem;
  color: #7c8fab;
}
.footer-bottom-inner a:hover { color: #fff; }

/* ================= RESPONSIVE ================= */
@media (max-width: 980px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-media { order: -1; }
  .practice-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: repeat(3, 1fr); }
  .offices-grid { grid-template-columns: 1fr; }
  .offices-list { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .testimonial-grid { grid-template-columns: repeat(2, 1fr); }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .insights-grid { grid-template-columns: 1fr 1fr; }
  .hero-stats-inner { grid-template-columns: repeat(2, 1fr); row-gap: 20px; }
  .stat:nth-child(2) { border-right: none; }
  .hero-scales { display: none; }
  .utility-contact a:nth-child(2) { display: none; }
}

/* Nav collapses to the hamburger menu on tablets too (1024px and down) so the
   full link row + CTA never overflows the header on iPad-width screens. */
@media (max-width: 1024px) {
  .utility-bar { display: none; }
  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 14px 24px 20px;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    display: none;
    max-height: calc(100vh - 100%);
    overflow-y: auto;
  }
  .main-nav.open { display: flex; }
  .main-nav > a, .nav-dropdown-toggle { width: 100%; padding: 10px 0; }
  .nav-dropdown-menu { position: static; transform: none; box-shadow: none; border: none; width: 100%; padding: 0 0 0 12px; }
  .btn-nav { display: none; }
  .nav-toggle { display: flex; }
}

@media (max-width: 760px) {
  .practice-grid { grid-template-columns: 1fr; }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .offices-list { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; padding-bottom: 30px; }
  .footer-bottom-inner { flex-direction: column; text-align: center; }
  .testimonial-grid { grid-template-columns: 1fr; }
  .insights-grid { grid-template-columns: 1fr; }
  .hero-stats-inner { grid-template-columns: 1fr 1fr; }
  .practice-detail-grid { grid-template-columns: 1fr; gap: 22px; padding: 20px; }
  .practice-detail-visual { min-height: 0; }
  .practice-detail-visual img { min-height: 220px; }
  .practice-detail-gallery { grid-template-columns: repeat(2, minmax(0, 220px)); justify-content: center; }
  .practice-detail-gallery-item img { height: 160px; }
  .practice-detail-panel { padding: 22px 18px; }
  .practice-detail-metrics {
    display: flex;
    grid-template-columns: none;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 10px;
    margin-left: -20px;
    margin-right: -20px;
    padding-left: 20px;
    padding-right: 20px;
    -webkit-overflow-scrolling: touch;
  }
  .practice-detail-metrics::-webkit-scrollbar { height: 5px; }
  .practice-detail-metrics::-webkit-scrollbar-thumb { background: rgba(255,255,255,.35); border-radius: 10px; }
  .practice-detail-stat {
    flex: 0 0 78%;
    scroll-snap-align: start;
  }
  .metrics-swipe-hint { display: inline-block; }

  /* ---- Team: bento-style grid on mobile only (desktop untouched) ----
     Card 1 (Lead Lawyer) runs full width and taller; the rest sit two
     per row as compact tiles. This cuts vertical scroll roughly in
     half vs. one full-width card per row. */
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
  .team-card { text-align: left; }
  .team-card:nth-child(1) {
    grid-column: 1 / -1;
    flex-direction: row;
  }
  .team-card:nth-child(1) .team-avatar {
    width: 132px;
    aspect-ratio: 3 / 4;
    flex-shrink: 0;
    font-size: 2.1rem;
  }
  .team-card:nth-child(1) .team-card-body {
    padding: 16px 16px 16px 14px;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }
  .team-card:nth-child(1) h3 { font-size: 1.05rem; }
  .team-card:nth-child(1) .team-view-more { border-top: none; padding-top: 8px; margin-top: 4px; }

  .team-card:nth-child(n+2) .team-avatar {
    aspect-ratio: 1 / 1;
    font-size: 1.8rem;
  }
  .team-card:nth-child(n+2) .team-card-body {
    padding: 14px 12px 16px;
  }
  .team-card:nth-child(n+2) h3 {
    font-size: .92rem;
    line-height: 1.25;
  }
  .team-card:nth-child(n+2) .team-role { font-size: .76rem; margin-bottom: 6px; }
  .team-card:nth-child(n+2) .team-focus {
    font-size: .76rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .team-card:nth-child(n+2) .team-view-more {
    font-size: .72rem;
    margin-top: 10px;
    padding-top: 10px;
  }
}

/* ================= APPOINTMENT MODAL ================= */
.modal { position: fixed; inset: 0; display: none; align-items: center; justify-content: center; z-index: 120; }
.modal[aria-hidden="false"] { display: flex; }
.modal-overlay { position: absolute; inset: 0; background: rgba(2,6,23,0.6); }
.modal-content { position: relative; background: #fff; border-radius: 12px; padding: 22px; width: min(640px, 94%); box-shadow: 0 30px 60px rgba(6,18,34,0.4); z-index: 2; }
.modal-close { position: absolute; right: 12px; top: 10px; border: none; background: transparent; font-size: 22px; cursor: pointer; }
.appointment-form .form-field { margin-bottom: 12px; }
.appointment-form label { font-weight: 600; display: block; margin-bottom: 6px; color: var(--navy); }
.appointment-form input, .appointment-form textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px; }
.appointment-form textarea { min-height: 90px; }

@media (max-width: 480px) {
  .modal-content { padding: 14px; }
  .practice-detail-gallery { grid-template-columns: minmax(0, 260px); justify-content: center; }
}
