/*
 * NOTE: main.css - everything shared by every page:
 *   1. Tokens   2. Reset & base   3. Layout   4. Buttons   5. Header & mega menu
 *   6. Footer   7. Demo dialog & forms   8. Generic page   9. Responsive   10. Reduced motion
 */

/* ---------------------------------------------------------------
 * 1. Tokens
 * ------------------------------------------------------------ */
:root {
  --blue: #1668ff;
  --blue-dark: #0b4ed1;
  --blue-soft: #e8f1ff;
  --sky-1: #bfdcff;
  --sky-2: #e3f0ff;
  --ink: #0d1526;
  --ink-2: #1b2536;
  --muted: #5c6779;
  --muted-2: #8791a3;
  --line: #e6eaf1;
  --bg: #fff;
  --bg-soft: #f5f7fb;

  --r-sm: 10px;
  --r: 16px;
  --r-lg: 24px;
  --r-xl: 34px;
  --r-pill: 999px;

  --shadow-sm: 0 2px 10px rgba(13, 21, 38, 0.05);
  --shadow: 0 12px 34px rgba(13, 21, 38, 0.08);
  --shadow-lg: 0 30px 70px rgba(13, 21, 38, 0.14);

  /* NOTE: CTA palette lifted from the Esferasoft logo - gold accents with the logo's red and black. */
  --gold: #ffc21f;
  --gold-light: #ffe27a;
  --gold-deep: #f59e0b;
  --brand-red: #e03020;
  --cta-grad: linear-gradient(135deg, #ffe27a 0%, #ffc21f 48%, #f59e0b 100%);
  --cta-ink: #14100a;
  --cta-glow: 0 12px 30px rgba(245, 158, 11, 0.38);

  --container: 1600px;
  --gutter: 80px;
  /* NOTE: one family site-wide (Plus Jakarta Sans); --font-display is kept as an alias so older rules still resolve. */
  --font: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-display: var(--font);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------------------------------------------------------------
 * 2. Reset & base
 * ------------------------------------------------------------ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

html:has(dialog[open]) {
  overflow: hidden;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: clamp(15px, 0.35vw + 14px, 16.5px);
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img,
svg {
  max-width: 100%;
}

img {
  height: auto;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: -0.02em;
  font-weight: 800;
}

p {
  margin: 0 0 1em;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
  font-family: var(--font);
}

svg text {
  font-family: var(--font);
}

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 6px;
}

section[id] {
  scroll-margin-top: 96px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 999;
  padding: 12px 18px;
  background: var(--ink);
  color: #fff;
  border-radius: 0 0 var(--r-sm) 0;
}

.skip-link:focus {
  left: 0;
}

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

/* NOTE: line breaks that only apply when there is room for the designed wrap. */
.br-lg {
  display: none;
}

@media (min-width: 993px) {
  .br-lg {
    display: inline;
  }
}

/* ---------------------------------------------------------------
 * 3. Layout
 * ------------------------------------------------------------ */
.container {
  width: 100%;
  margin-inline: auto;
}

.container.mw-16 {
  max-width: var(--container);
  padding-inline: var(--gutter);
}

.rf-container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 24px;
}

/* ---------------------------------------------------------------
 * 4. Pill button (.btn-strategy)
 * NOTE: the label and the round arrow swap sides on hover.
 * ------------------------------------------------------------ */
.btn-strategy {
  position: relative;
  display: inline-flex;
  align-items: center;
  padding: 14px 65px 14px 30px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: var(--r-pill);
  background-color: var(--gold);
  background-image: var(--cta-grad);
  color: var(--cta-ink);
  font-family: var(--font);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  box-shadow: var(--cta-glow), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: all 0.4s ease;
}

.icon-circle {
  position: absolute;
  top: 50%;
  right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: var(--cta-ink);
  color: var(--gold);
  transform: translateY(-50%);
  transition: all 0.4s ease;
}

.icon-circle svg {
  width: 16px;
  height: 16px;
}

/* NOTE: on hover the label and arrow swap sides and the button flips to the logo's black with a gold label. */
.btn-strategy:hover,
.btn-strategy:focus-visible {
  padding: 14px 30px 14px 65px;
  border-color: var(--cta-ink);
  background-color: var(--cta-ink);
  background-image: none;
  color: var(--gold-light);
  box-shadow: 0 10px 26px rgba(20, 16, 10, 0.34);
}

.btn-strategy:hover .icon-circle,
.btn-strategy:focus-visible .icon-circle {
  right: calc(100% - 55px);
  background: var(--cta-grad);
  color: var(--cta-ink);
}

/* ---------------------------------------------------------------
 * 5. Header
 * NOTE: fixed, so the floating pill sits over the hero without reserving layout height.
 * ------------------------------------------------------------ */
.site-header {
  position: fixed;
  top: 14px;
  left: 0;
  right: 0;
  z-index: 100;
}

/* NOTE: clears the WordPress admin bar (32px) for logged-in editors. */
.admin-bar .site-header {
  top: 46px;
}

.nav-header {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 10px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.7);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 34px rgba(13, 21, 38, 0.08), inset 0 0 0 1.5px rgba(255, 255, 255, 0.9);
}

.nav-logo-link {
  display: inline-flex;
  flex: none;
}

.nav-logo {
  width: auto;
  height: 38px;
  margin-left: 8px;
  object-fit: contain;
}

.nav-chip {
  display: inline-flex;
  flex: none;
  align-items: center;
}

.nav-chip img {
  display: block;
  width: auto;
  height: 44px;
}

.nav-panel {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(12px, 1.5vw, 28px);
}

.nav-links {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  gap: clamp(14px, 2vw, 40px);
}

.nav-links > li {
  position: static;
}

.nav-links > li > a {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 500;
  color: #000;
  white-space: nowrap;
}

.nav-links > li > a svg {
  display: none;
  width: 13px;
  height: 13px;
  transition: transform 0.28s ease;
}

.nav-links > li > a:hover {
  color: var(--blue);
}

/* NOTE: only the mega item shows a caret. */
.nav-mega {
  position: relative;
}

.nav-mega > a svg {
  display: block;
}

.nav-mega:hover > a svg,
.nav-mega:focus-within > a svg,
.nav-mega.open > a svg {
  transform: rotate(180deg);
}

/* NOTE: invisible bridge so the menu does not close while the pointer travels down to it. */
.nav-mega > a {
  position: relative;
}

.nav-mega > a::after {
  content: "";
  position: absolute;
  top: 100%;
  left: -22px;
  right: -22px;
  height: 40px;
}

.mega {
  position: absolute;
  z-index: 2;
  top: calc(100% + 8px);
  left: 50%;
  width: min(1004px, calc(100vw - 32px));
  max-height: calc(100vh - 140px);
  padding: 26px 24px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 26px 60px rgba(13, 21, 38, 0.16), 0 2px 8px rgba(13, 21, 38, 0.05);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, -8px);
  transition: opacity 0.28s ease, transform 0.28s var(--ease), visibility 0.28s;
}

.nav-mega:hover .mega,
.nav-mega:focus-within .mega {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.mega-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.mega-item {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 14px;
  transition: background 0.24s ease;
}

.mega-item:hover {
  background: #f6f8fd;
}

.mega-ico {
  display: grid;
  flex: none;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--tone-bg);
  color: var(--tone);
  box-shadow: 0 3px 12px var(--tone-shadow);
}

.mega-ico svg {
  display: block;
  width: 24px;
  height: 24px;
}

.mega-txt {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.mega-txt strong {
  font-size: 16px;
  font-weight: 600;
  line-height: 1.25;
  color: #111318;
}

.mega-txt span {
  font-size: 13px;
  line-height: 1.45;
  color: #737da1;
}

/* --- AI SEO Expert badge dropdown: same tiles, centred under the pill --- */
.nav-chip-mega {
  position: static;
}

.nav-chip-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--blue);
  cursor: pointer;
}

.nav-chip-btn > svg {
  width: 13px;
  height: 13px;
  margin-left: 2px;
  transition: transform 0.28s ease;
}

/* NOTE: invisible bridge so the dropdown stays open while the pointer travels down to it. */
.nav-chip-btn::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: 36px;
}

.nav-chip-mega:hover .mega,
.nav-chip-mega:focus-within .mega,
.nav-chip-mega.open .mega {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.nav-chip-mega:hover .nav-chip-btn > svg,
.nav-chip-mega:focus-within .nav-chip-btn > svg,
.nav-chip-mega.open .nav-chip-btn > svg {
  transform: rotate(180deg);
}

/* NOTE: per-item tones for the mega menu icon tiles. */
.c-blue { --tone: #2563eb; --tone-bg: #e9f0ff; --tone-shadow: rgba(37, 99, 235, 0.16); }
.c-violet { --tone: #7c3aed; --tone-bg: #f2ecff; --tone-shadow: rgba(124, 58, 237, 0.16); }
.c-indigo { --tone: #4f46e5; --tone-bg: #ecebfe; --tone-shadow: rgba(79, 70, 229, 0.16); }
.c-orange { --tone: #f97316; --tone-bg: #fff0e4; --tone-shadow: rgba(249, 115, 22, 0.16); }
.c-pink { --tone: #ec4899; --tone-bg: #ffeaf4; --tone-shadow: rgba(236, 72, 153, 0.16); }
.c-teal { --tone: #0d9488; --tone-bg: #e2f7f4; --tone-shadow: rgba(13, 148, 136, 0.16); }
.c-amber { --tone: #f59e0b; --tone-bg: #fff5e1; --tone-shadow: rgba(245, 158, 11, 0.16); }
.c-purple { --tone: #9333ea; --tone-bg: #f7ecff; --tone-shadow: rgba(147, 51, 234, 0.16); }
.c-red { --tone: #ef4444; --tone-bg: #ffeaea; --tone-shadow: rgba(239, 68, 68, 0.16); }
.c-green { --tone: #16a34a; --tone-bg: #e6f7ec; --tone-shadow: rgba(22, 163, 74, 0.16); }
.c-gold { --tone: #e0a11a; --tone-bg: #fdf4e0; --tone-shadow: rgba(224, 161, 26, 0.18); }

.nav-demo {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 76px;
  background: var(--cta-grad);
  color: var(--cta-ink);
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(245, 158, 11, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: background 0.3s ease, color 0.3s ease, box-shadow 0.3s ease;
}

.nav-demo svg {
  width: 14px;
  height: 14px;
  transition: transform 0.3s ease;
}

.nav-demo:hover,
.nav-demo:focus-visible {
  background: var(--cta-ink);
  color: var(--gold-light);
  box-shadow: 0 8px 20px rgba(20, 16, 10, 0.3);
}

.nav-demo:hover svg {
  transform: translate(3px, -3px);
}

.nav-burger {
  display: none;
  flex: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 46px;
  height: 46px;
  margin-left: auto;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--ink);
  cursor: pointer;
}

.nav-burger span {
  width: 19px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  pointer-events: none;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-burger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-burger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.nav-burger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ---------------------------------------------------------------
 * 6. Footer
 * NOTE: centred and symmetric: service ticker, closing CTA, offices, links, scam notice, legal bar.
 * ------------------------------------------------------------ */
.site-footer {
  --ft-accent: var(--blue);
  --ft-grad: var(--cta-grad);
  position: relative;
  isolation: isolate;
  /* NOTE: clip (not hidden) so the sticky newsletter card inside can still stick to the viewport. */
  overflow: clip;
  background: var(--bg);
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

.ft-aura {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(58% 42% at 50% 6%, rgba(22, 104, 255, 0.09) 0%, transparent 72%),
    radial-gradient(80% 46% at 50% 98%, rgba(22, 104, 255, 0.05) 0%, transparent 74%);
}

/* --- service ticker --- */
.ft-ticker {
  display: flex;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.ft-ticker-track {
  display: flex;
  flex: none;
  animation: ft-marquee 38s linear infinite;
}

.ft-ticker:hover .ft-ticker-track {
  animation-play-state: paused;
}

.ft-ticker-run {
  display: flex;
  flex: none;
  align-items: center;
}

.ft-ticker-run li {
  display: flex;
  align-items: center;
  gap: 34px;
  padding: 13px 17px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.ft-ticker-run li::after {
  content: "";
  flex: none;
  width: 5px;
  height: 5px;
  background: var(--ft-accent);
  transform: rotate(45deg);
}

@keyframes ft-marquee {
  to {
    transform: translateX(-50%);
  }
}

/* --- closing CTA --- */
/* NOTE: a deep-blue banner with glass contact tiles and a gold button - the one dark moment before the light footer. */
.ft-hero {
  position: relative;
  padding-block: clamp(36px, 4.4vw, 72px) clamp(28px, 3.2vw, 48px);
}

.ft-cta {
  position: relative;
  isolation: isolate;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  align-items: center;
  gap: clamp(28px, 4vw, 72px);
  padding: clamp(34px, 4.6vw, 80px) clamp(24px, 4.6vw, 84px);
  overflow: hidden;
  border-radius: clamp(24px, 2.6vw, 40px);
  background:
    radial-gradient(60% 90% at 100% 0%, rgba(34, 211, 238, 0.35) 0%, transparent 62%),
    radial-gradient(50% 80% at 0% 100%, rgba(255, 194, 31, 0.16) 0%, transparent 60%),
    linear-gradient(125deg, #07184f 0%, #0b3bb8 52%, #1668ff 100%);
  box-shadow: 0 40px 80px -34px rgba(11, 59, 184, 0.7);
  color: #fff;
  text-align: left;
}

/* NOTE: concentric rings and a dotted field add depth without any image. */
.ft-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(rgba(255, 255, 255, 0.16) 1px, transparent 1.4px) 0 0 / 22px 22px;
  -webkit-mask-image: linear-gradient(100deg, transparent 30%, #000 100%);
  mask-image: linear-gradient(100deg, transparent 30%, #000 100%);
}

.ft-cta-rings {
  position: absolute;
  top: 50%;
  right: -12%;
  z-index: -1;
  width: clamp(360px, 46vw, 760px);
  aspect-ratio: 1;
  border-radius: 50%;
  box-shadow:
    inset 0 0 0 1.5px rgba(255, 255, 255, 0.14),
    0 0 0 clamp(40px, 5vw, 84px) rgba(255, 255, 255, 0.035),
    0 0 0 clamp(41px, 5vw, 85px) rgba(255, 255, 255, 0.1),
    0 0 0 clamp(90px, 10vw, 170px) rgba(255, 255, 255, 0.025);
  transform: translateY(-50%);
  pointer-events: none;
}

.ft-wordmark {
  position: absolute;
  inset-inline: 0;
  bottom: -0.2em;
  z-index: -1;
  margin: 0;
  font-size: clamp(64px, 14vw, 260px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.06em;
  text-align: center;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.06);
  user-select: none;
  pointer-events: none;
}

.ft-cta-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.ft-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  padding: 8px 18px 8px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #fff;
}

.ft-eyebrow::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cta-grad);
  box-shadow: 0 0 0 4px rgba(255, 194, 31, 0.25);
}

.ft-cta-title {
  max-width: 21ch;
  margin-bottom: 20px;
  font-size: clamp(32px, 4.2vw, 68px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.035em;
  color: #fff;
  text-wrap: balance;
}

.ft-cta-title em {
  font-style: normal;
  background: var(--cta-grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: var(--gold);
}

.ft-cta-sub {
  max-width: 54ch;
  margin: 0 0 34px;
  font-size: clamp(15px, 1.1vw, 17.5px);
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.82);
}

.ft-quick {
  display: grid;
  gap: 14px;
  margin: 0;
}

.ft-quick li {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.09);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  transition: transform 0.35s var(--ease), background 0.35s ease, border-color 0.35s ease;
}

.ft-quick li:hover {
  transform: translateX(-6px);
  border-color: rgba(255, 226, 122, 0.55);
  background: rgba(255, 255, 255, 0.14);
}

.ft-quick-ico {
  display: grid;
  flex: none;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--cta-grad);
  color: var(--cta-ink);
  box-shadow: 0 8px 18px rgba(245, 158, 11, 0.35);
}

.ft-quick-ico svg {
  width: 22px;
  height: 22px;
}

.ft-quick-txt {
  display: flex;
  flex-direction: column;
  min-width: 0;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  text-align: left;
  overflow-wrap: anywhere;
}

.ft-quick-txt small {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.62);
}

.ft-quick-txt a {
  color: #fff;
  transition: color 0.26s ease;
}

.ft-quick-txt a:hover {
  color: var(--gold-light);
}

/* --- offices --- */
.ft-offices {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(16px, 1.8vw, 26px);
  padding-top: clamp(34px, 4vw, 58px);
}

.ft-office {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 28px 24px 26px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}

.ft-office:hover {
  border-color: #d5deec;
  box-shadow: var(--shadow-sm);
  transform: translateY(-4px);
}

.ft-flag {
  display: block;
  width: 44px;
  height: 30px;
  overflow: hidden;
  border-radius: 5px;
  box-shadow: 0 0 0 1px rgba(13, 21, 38, 0.1);
}

.ft-flag svg {
  display: block;
  width: 100%;
  height: 100%;
}

.ft-office h3 {
  margin: 4px 0 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.ft-office-addr {
  margin: 0;
  font-size: 14.5px;
  line-height: 1.6;
}

.ft-office-tel {
  margin-top: auto;
  padding-top: 2px;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--ink);
  transition: color 0.26s ease;
}

.ft-office-tel:hover,
.ft-office-tel:focus-visible {
  color: var(--ft-accent);
}

/* --- link grid --- */
.ft-grid {
  display: grid;
  grid-template-columns: minmax(0, 2.15fr) minmax(300px, 1fr);
  align-items: stretch;
  gap: clamp(18px, 2vw, 30px);
  padding-block: clamp(44px, 5vw, 76px);
  text-align: left;
}

/* NOTE: full-bleed black band behind the link boxes. */
.ft-band {
  position: relative;
  width: 100%;
  /* NOTE: spacing above keeps the black band from touching the offices row. */
  margin-top: clamp(28px, 3.4vw, 56px);
  /* NOTE: same blue as the closing CTA banner (.ft-cta) so the footer reads as one piece. */
  background:#fff;
  color: rgba(255, 255, 255, 0.78);
}

/* NOTE: the newsletter card follows the viewport while the long link boxes scroll past on the left. */
.ft-side {
  display: grid;
  gap: clamp(18px, 2vw, 30px);
}

.ft-band .ft-side {
  position: sticky;
  top: 112px;
  align-self: start;
}

.admin-bar .ft-band .ft-side {
  top: 144px;
}

/* NOTE: neutral shadow on the dark band instead of the blue glow. */
.ft-band .ft-news {
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow: 0 22px 48px -26px rgba(0, 0, 0, 0.9);
}

/* --- contact card (fills the space under the newsletter card) --- */
.ft-reach ul {
  display: grid;
  gap: 16px;
}

.ft-reach li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 0;
}

.ft-reach-ico {
  display: grid;
  flex: none;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--gold-light), var(--gold));
  color: #1a1204;
}

.ft-reach-txt {
  display: grid;
  min-width: 0;
  gap: 2px;
  color: #fff;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.ft-reach-txt small {
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
}

.ft-reach a::before {
  display: none;
}

.ft-reach a {
  color: #fff;
}

/* NOTE: Services, Company and Resources sit in soft cards. Services runs full width with its links in 3 columns; Company, Resources and the newsletter share the row below. */
.ft-col:not(.ft-news) {
  padding: clamp(22px, 2.4vw, 34px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 22px;
  background: #000;
  box-shadow: 0 22px 48px -26px rgba(7, 24, 79, 0.65), 0 0 0 1px rgba(22, 104, 255, 0.04) inset;
  transition: box-shadow 0.35s ease, transform 0.35s ease, border-color 0.35s ease;
}

.ft-col:not(.ft-news):hover {
  transform: translateY(-3px);
  border-color: rgba(255, 190, 40, 0.4);
  box-shadow: 0 26px 52px -26px rgba(0, 0, 0, 0.95), 0 6px 22px -8px rgba(255, 190, 40, 0.22);
}

/* NOTE: light-on-black text for the link boxes; the newsletter card keeps its own light design. */
.ft-col:not(.ft-news) h3 {
  border-bottom-color: rgba(255, 255, 255, 0.14);
  color: #fff;
}

.ft-col:not(.ft-news) h3::before {
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(255, 190, 40, 0.18);
}

.ft-col:not(.ft-news) a {
  color: rgba(255, 255, 255, 0.72);
}

.ft-col:not(.ft-news) a::before {
  background: var(--gold);
}

.ft-col:not(.ft-news) a:hover,
.ft-col:not(.ft-news) a:focus-visible {
  color: var(--gold-light);
}

/* NOTE: left stack - the two boxes share one column so their widths always match. */
.ft-links {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto 1fr;
  gap: clamp(18px, 2vw, 30px);
}

.ft-col-footer-services ul,
.ft-merge {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: clamp(20px, 3vw, 48px);
}

/* NOTE: both menu lists dissolve so every link becomes a cell of the same 3-column grid. */
.ft-merge ul {
  display: contents;
}

.ft-col h3 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  font-size: 15.5px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.ft-col h3::before {
  content: "";
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 4px rgba(22, 104, 255, 0.14);
}

.ft-col li {
  padding: 0 0 12px;
  font-size: 15.5px;
  break-inside: avoid;
}

.ft-col a {
  display: inline-flex;
  align-items: center;
  color: var(--muted);
  transition: color 0.28s ease, gap 0.28s ease;
}

/* NOTE: a chevron that slides in from nothing on hover. */
.ft-col a::before {
  content: "";
  flex: none;
  width: 0;
  height: 8px;
  background: var(--ft-accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 12'%3E%3Cpath d='M1.5 1.5 6 6l-4.5 4.5' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 0 50% / 6px 8px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 12'%3E%3Cpath d='M1.5 1.5 6 6l-4.5 4.5' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 0 50% / 6px 8px no-repeat;
  transition: width 0.28s ease;
}

.ft-col a:hover,
.ft-col a:focus-visible {
  gap: 8px;
  color: var(--ft-accent);
}

.ft-col a:hover::before,
.ft-col a:focus-visible::before {
  width: 6px;
}

/* --- newsletter card --- */
.ft-news {
  align-self: start;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: clamp(24px, 2.4vw, 32px);
  border: 1px solid rgba(22, 104, 255, 0.16);
  border-radius: 22px;
  background: linear-gradient(160deg, #eef4ff 0%, #f6f9ff 45%, #fff 100%);
  box-shadow: 0 20px 44px -26px rgba(22, 104, 255, 0.3);
}

.ft-news::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -90px;
  right: -90px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.2), transparent 70%);
}

.ft-news h3 {
  display: block;
  margin-bottom: 16px;
  padding-bottom: 0;
  border-bottom: 0;
  font-size: clamp(18px, 1.5vw, 21px);
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.ft-news h3::before {
  display: none;
}

.ft-subscribe {
  position: relative;
  display: flex;
  align-items: center;
}

.ft-subscribe input[type="email"] {
  width: 100%;
  padding: 14px 58px 14px 20px;
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  background: #fff;
  font-size: 14px;
  color: var(--ink);
  transition: border-color 0.28s ease, box-shadow 0.28s ease;
}

.ft-subscribe input::placeholder {
  color: var(--muted-2);
}

.ft-subscribe input:focus {
  outline: none;
  border-color: var(--ft-accent);
  box-shadow: 0 0 0 3px rgba(22, 104, 255, 0.14);
}

.ft-subscribe button {
  position: absolute;
  right: 5px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--ft-grad);
  color: var(--cta-ink);
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(245, 158, 11, 0.35);
  transition: filter 0.28s ease, transform 0.28s ease;
}

.ft-subscribe button svg {
  width: 16px;
  height: 16px;
}

.ft-subscribe button:hover {
  filter: brightness(1.08);
  transform: translate(2px, -2px);
}

.ft-subscribe-note {
  margin: 12px 0 0;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--muted-2);
}

.ft-social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 0;
  padding: 20px 0 0;
  border-top: 1px solid rgba(22, 104, 255, 0.14);
}

.ft-social li {
  padding: 0;
}

.ft-social a {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--ink);
  transition: border-color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease;
}

.ft-social a::before {
  display: none;
}

.ft-social a svg {
  width: 16px;
  height: 16px;
}

.ft-social .s-fb a { color: #1877f2; }
.ft-social .s-li a { color: #0a66c2; }
.ft-social .s-ig a { color: #e4405f; }
.ft-social .s-yt a { color: #f00; }
.ft-social .s-x a,
.ft-social .s-tt a { color: #0f0f0f; }

.ft-social a:hover {
  border-color: currentColor;
  box-shadow: var(--shadow-sm);
  transform: translateY(-3px);
}

/* --- scam alert ticker --- */
.ft-scam {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-block: 18px;
  border-top: 1px solid var(--line);
  text-align: left;
}

.ft-scam-label {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink);
}

.ft-scam-label svg {
  color: var(--ft-accent);
}

.ft-scam-marquee {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--r-pill);
  background: #e53935;
  box-shadow: 0 8px 22px rgba(229, 57, 53, 0.25);
}

.ft-scam-track {
  display: flex;
  width: max-content;
  animation: ft-marquee 60s linear infinite;
}

.ft-scam-marquee:hover .ft-scam-track,
.ft-scam-marquee:focus-within .ft-scam-track {
  animation-play-state: paused;
}

.ft-scam-text {
  flex: none;
  margin: 0;
  padding: 8px 48px 8px 20px;
  font-size: 13.5px;
  line-height: 1.4;
  color: #fff;
  white-space: nowrap;
}

.ft-scam-text a {
  font-weight: 700;
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* --- legal bar --- */
.ft-legal {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 22px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  text-align: left;
}

.ft-logo {
  display: inline-flex;
  flex: none;
}

.ft-logo img {
  width: auto;
  height: 34px;
}

.ft-legal p {
  flex: 1;
  min-width: 220px;
  margin: 0;
}

.ft-legal ul {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.ft-legal a {
  transition: color 0.24s ease;
}

.ft-legal a:hover {
  color: var(--ft-accent);
}

/* ---------------------------------------------------------------
 * 7. Demo dialog & forms
 * ------------------------------------------------------------ */
.demo-modal {
  width: min(1000px, calc(100vw - 32px));
  max-width: none;
  max-height: calc(100dvh - 32px);
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--r-lg);
  background: #fff;
  color: var(--ink);
  box-shadow: var(--shadow-lg);
}

.demo-modal::backdrop {
  background: rgba(13, 21, 38, 0.55);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.demo-modal[open] {
  animation: dm-in 0.35s var(--ease);
}

@keyframes dm-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
}

.dm-content {
  position: relative;
}

.dm-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1fr);
  max-height: calc(100dvh - 32px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.dm-close {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(13, 21, 38, 0.06);
  color: var(--ink-2);
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}

.dm-close:hover {
  background: var(--ink);
  color: #fff;
}

.dm-close svg {
  width: 18px;
  height: 18px;
}

/* --- left pitch --- */
.dm-pitch {
  padding: 28px 26px;
  background:
    radial-gradient(120% 80% at 15% 0%, #fff 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(170deg, var(--sky-2) 0%, var(--sky-1) 48%, var(--blue-soft) 100%);
}

.dm-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 16px;
  padding: 7px 15px;
  border-radius: var(--r-pill);
  background: #fff;
  box-shadow: var(--shadow-sm);
  font-size: 14px;
  font-weight: 700;
}

.dm-badge svg {
  width: 15px;
  height: 15px;
  color: var(--blue);
}

.dm-headline {
  margin-bottom: 18px;
  font-size: clamp(23px, 2.1vw, 30px);
  line-height: 1.2;
}

.dm-accent {
  color: var(--blue);
}

.dm-lede {
  margin-bottom: 20px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ink-2);
}

.dm-features {
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
}

.dm-feature {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.dm-feature-icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
}

.dm-feature-icon svg {
  width: 15px;
  height: 15px;
}

.dm-feature-text {
  display: grid;
  gap: 2px;
}

.dm-feature-text strong {
  font-size: 14.5px;
  font-weight: 700;
}

.dm-feature-text span {
  font-size: 12.5px;
  color: var(--muted);
}

.dm-trust {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
  padding: 12px 14px;
  border-radius: var(--r);
  background: rgba(255, 255, 255, 0.75);
}

.dm-avatars {
  display: flex;
}

.dm-avatars span {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin-left: -8px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
}

.dm-avatars span:first-child {
  margin-left: 0;
}

.dm-avatars span:nth-child(2) {
  background: #7c3aed;
}

.dm-avatars span:nth-child(3) {
  background: #0d9488;
}

.dm-trust-text {
  display: grid;
  font-size: 12.5px;
}

.dm-trust-text strong {
  font-size: 13px;
}

.dm-stars {
  letter-spacing: 1px;
  color: #f5b301;
}

.dm-ratings {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  overflow: hidden;
  border-radius: var(--r);
  background: rgba(255, 255, 255, 0.75);
}

.dm-rating {
  display: grid;
  justify-items: center;
  gap: 2px;
  padding: 12px 6px;
  font-size: 12px;
  text-align: center;
}

.dm-rating + .dm-rating {
  border-left: 1px solid rgba(13, 21, 38, 0.08);
}

.dm-rating-name {
  font-weight: 700;
}

.dm-rating-score {
  font-weight: 700;
  color: var(--ink-2);
}

/* --- right form --- */
.dm-form-panel {
  padding: 28px 26px;
  background: #fff;
}

.dm-form-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 18px;
  padding-right: 44px;
}

.dm-form-icon {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
}

.dm-form-icon svg {
  width: 21px;
  height: 21px;
}

.dm-title {
  margin-bottom: 4px;
  font-size: clamp(19px, 1.7vw, 23px);
  line-height: 1.2;
}

.dm-subtitle {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

.dm-form {
  display: grid;
  gap: 12px;
}

.dm-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.dm-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.dm-field > label {
  font-size: 13px;
  font-weight: 700;
}

.dm-req {
  color: #e5484d;
}

.dm-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.dm-input-icon {
  position: absolute;
  left: 14px;
  display: inline-flex;
  color: var(--muted-2);
  pointer-events: none;
}

.dm-input-icon svg {
  width: 18px;
  height: 18px;
}

.dm-input-wrap input,
.dm-input-wrap select,
.dm-input-wrap textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: #fff;
  font-size: 14px;
  color: var(--ink);
  -webkit-appearance: none;
  appearance: none;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.dm-input-icon ~ input {
  padding-left: 40px;
}

.dm-input-wrap input::placeholder,
.dm-input-wrap textarea::placeholder {
  color: var(--muted-2);
}

.dm-input-wrap input:hover,
.dm-input-wrap select:hover,
.dm-input-wrap textarea:hover {
  border-color: var(--sky-1);
}

.dm-input-wrap input:focus,
.dm-input-wrap select:focus,
.dm-input-wrap textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-soft);
}

.dm-field.is-invalid input,
.dm-field.is-invalid select,
.dm-field.is-invalid textarea {
  border-color: #e5484d;
}

.dm-error {
  min-height: 0;
  font-size: 12px;
  color: #e5484d;
}

.dm-error:empty {
  display: none;
}

.dm-phone-wrap {
  gap: 0;
}

.dm-input-wrap select.dm-dial {
  flex: 0 0 76px;
  width: 76px;
  min-width: 0;
  padding-inline: 8px;
  border-right: 0;
  border-radius: var(--r-sm) 0 0 var(--r-sm);
  background: var(--bg-soft);
  font-size: 13.5px;
  font-weight: 600;
  text-overflow: ellipsis;
}

.dm-phone-wrap input[type="tel"] {
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
}

.dm-select-wrap select {
  padding-right: 44px;
  cursor: pointer;
}

.dm-select-chev {
  position: absolute;
  right: 14px;
  display: inline-flex;
  color: var(--muted);
  pointer-events: none;
}

.dm-select-chev svg {
  width: 18px;
  height: 18px;
}

.dm-textarea-wrap textarea {
  min-height: 96px;
  padding-bottom: 30px;
  line-height: 1.55;
  resize: vertical;
}

.dm-count {
  position: absolute;
  right: 12px;
  bottom: 10px;
  font-size: 12px;
  color: var(--muted-2);
  pointer-events: none;
}

.dm-secure {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 11px 14px;
  border-radius: var(--r-sm);
  background: var(--blue-soft);
  font-size: 14px;
  font-weight: 600;
  color: var(--blue-dark);
}

.dm-secure svg {
  flex: none;
  width: 18px;
  height: 18px;
  color: var(--blue);
}

.dm-submit {
  width: 100%;
  padding: 15px 22px;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--cta-grad);
  color: var(--cta-ink);
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: var(--cta-glow), inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transition: background 0.3s ease, color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.dm-submit:hover,
.dm-submit:focus-visible {
  background: var(--cta-ink);
  color: var(--gold-light);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(20, 16, 10, 0.32);
}

.dm-submit:disabled {
  opacity: 0.7;
  cursor: progress;
  transform: none;
  box-shadow: none;
}

.dm-response {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin: 0;
  font-size: 12.5px;
  color: var(--muted);
}

.dm-response svg {
  width: 16px;
  height: 16px;
}

/* NOTE: shared success / error line for both forms (filled in by main.js). */
.form-status {
  margin: 0;
  padding: 10px 14px;
  border-radius: var(--r-sm);
  font-size: 13.5px;
  font-weight: 600;
}

.form-status.is-success {
  background: #e6f7ec;
  color: #137a3c;
}

.form-status.is-error {
  background: #ffeaea;
  color: #b42318;
}

.ft-subscribe-status {
  margin-top: 12px;
}

.form-toast {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 300;
  margin: 0;
  padding: 14px 20px;
  border-radius: var(--r-sm);
  background: var(--ink);
  color: #fff;
  font-weight: 600;
  box-shadow: var(--shadow-lg);
}

/* ---------------------------------------------------------------
 * 8. Generic page (index.php fallback)
 * ------------------------------------------------------------ */
.page-main {
  padding: 150px 0 80px;
}

.page-wrap {
  max-width: 880px;
  padding-inline: 24px;
}

.page-title,
.entry-title {
  margin-bottom: 20px;
  font-size: clamp(28px, 4vw, 44px);
}

.entry {
  margin-bottom: 48px;
}

.entry-content {
  line-height: 1.75;
  color: var(--muted);
}

/* ---------------------------------------------------------------
 * 9. Responsive
 * ------------------------------------------------------------ */
@media (max-width: 1100px) {
  .ft-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  /* NOTE: single column - nothing to stay beside, so the card scrolls normally. */
  .ft-band .ft-side,
  .admin-bar .ft-band .ft-side {
    position: relative;
    top: auto;
  }
}

/* NOTE: <= 992px - the pill collapses into a burger menu. */
@media (max-width: 992px) {
  :root {
    --gutter: 32px;
  }

  .nav-header {
    gap: 8px;
    padding: 8px 12px;
  }

  .nav-burger {
    display: flex;
  }

  .nav-chip img {
    height: 38px;
  }

  /* NOTE: on tablets and phones the burger panel already holds the full services list, so the badge stays a plain label. */
  .nav-chip-mega .mega,
  .nav-chip-btn > svg {
    display: none;
  }

  .nav-chip-btn {
    cursor: default;
    pointer-events: none;
  }

  .nav-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    right: 0;
    z-index: 1000;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    max-height: calc(85vh - 70px);
    padding: 16px;
    overflow-y: auto;
    border: 1px solid var(--line);
    border-radius: var(--r-lg);
    background: #fff;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  }

  .nav-panel.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav-links {
    flex: none;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
  }

  .nav-links > li > a {
    justify-content: space-between;
    padding: 12px 14px;
  }

  /* NOTE: the mega menu becomes a collapsible two-column list inside the burger panel. */
  .mega {
    position: static;
    display: none;
    width: auto;
    max-height: none;
    padding: 8px 0;
    overflow: visible;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav-mega:hover .mega,
  .nav-mega:focus-within .mega {
    transform: none;
  }

  .nav-mega.open .mega {
    display: block;
  }

  .mega-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px;
  }

  .mega-item {
    align-items: center;
    gap: 8px;
    padding: 7px 8px;
    border-radius: 8px;
    background: #f4f7fc;
  }

  .mega-ico {
    width: 28px;
    height: 28px;
    border-radius: 7px;
  }

  .mega-ico svg {
    width: 15px;
    height: 15px;
  }

  .mega-txt {
    gap: 0;
  }

  .mega-txt strong {
    font-size: 12px;
  }

  .mega-txt span {
    display: none;
  }

  .nav-demo {
    justify-content: center;
    padding: 14px 24px;
  }

  .ft-offices {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ft-cta {
    grid-template-columns: minmax(0, 1fr);
  }

  .ft-quick li:hover {
    transform: none;
  }
}

@media (max-width: 768px) {
  :root {
    --gutter: 24px;
  }

  .btn-strategy {
    font-size: 15px;
  }
}

@media (max-width: 767.98px) {
  .ft-scam {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  .ft-scam-marquee {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .ft-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .ft-col-footer-services ul,
  .ft-merge {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dm-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .dm-pitch {
    padding-bottom: 20px;
  }
}

@media (max-width: 480px) {
  .ft-col-footer-services ul,
  .ft-merge {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 560px) {
  .ft-offices {
    grid-template-columns: minmax(0, 1fr);
  }

  .ft-quick li {
    gap: 12px;
    padding: 13px 14px;
  }

  .ft-quick-ico {
    width: 42px;
    height: 42px;
  }

  .ft-cta-copy .btn-strategy {
    font-size: 14px;
  }

  .ft-legal {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  .dm-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .ft-wordmark {
    -webkit-text-stroke-width: 0.75px;
  }
}

/* ---------------------------------------------------------------
 * 10. Reduced motion
 * ------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .ft-ticker-track {
    animation: none;
  }

  .ft-scam-track {
    width: auto;
    animation: none;
  }

  .ft-scam-marquee {
    border-radius: var(--r);
  }

  .ft-scam-text {
    padding-right: 20px;
    white-space: normal;
  }

  .ft-scam-text[aria-hidden="true"] {
    display: none;
  }

  .ft-office:hover,
  .ft-social a:hover,
  .ft-subscribe button:hover {
    transform: none;
  }

  .demo-modal[open] {
    animation: none;
  }
}

/* NOTE: phones - the wide Esferasoft logo takes the room the small "SEO expert" chip needs, so the chip is dropped. */
@media (max-width: 560px) {
  .nav-chip {
    display: none;
  }

  .nav-logo {
    height: 34px;
  }

  .nav-header {
    justify-content: space-between;
  }
}
