/**
 * AEO Services page-only extras.
 * Loaded only via seo.extra_css from AeoThemeHtmlSeeder.
 * Scoped to body.page-aeo / .aeo-theme-page — does not affect other pages.
 */
body.page-aeo .aeo-theme-page.theme-html-root {
  /* namespace hook */
}

body.page-aeo .aeo-theme-page .sec-paper,
body.page-aeo .aeo-theme-page .sec-mist,
body.page-aeo .aeo-theme-page .sec-ink,
body.page-aeo .aeo-theme-page .trust {
  position: relative;
}

/* Old Playbook band: photo sits under a dark wash so the copy stays readable. */
html body.page-aeo.page-service .aeo-theme-page.theme-html-root > section.sec-ink {
  isolation: isolate;
  overflow: hidden;
  background: #0a1a22;
}
html body.page-aeo.page-service .aeo-theme-page.theme-html-root > section.sec-ink::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: url("/media/services/aeo/embed-002-be4d144e92.webp");
  background-size: cover;
  background-position: center right;
  background-repeat: no-repeat;
}
html body.page-aeo.page-service .aeo-theme-page.theme-html-root > section.sec-ink::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(10, 26, 34, 0.9) 0%, rgba(10, 26, 34, 0.62) 48%, rgba(10, 26, 34, 0.34) 100%);
}
html body.page-aeo.page-service .aeo-theme-page.theme-html-root > section.sec-ink > .wrap {
  position: relative;
  z-index: 2;
}

/* Keep shared KodRank hero; no theme "AEO Services" eyebrow */
body.page-aeo .hero-eyebrow {
  display: none !important;
}

body.page-aeo .hero-badges.hero-trust,
body.page-aeo .hero-trust.hero-badges {
  margin-top: clamp(40px, 4.5vw, 64px) !important;
  margin-bottom: clamp(36px, 5vw, 64px) !important;
  padding-top: clamp(26px, 3vw, 36px) !important;
}

/* Stats strip under compare cards — a bit more space above */
html body.page-aeo.page-service .aeo-theme-page .stats,
html body.page-aeo.page-service .aeo-theme-page.webdev-ref .stats {
  margin-top: clamp(44px, 5vw, 64px) !important;
}

/* Match on-page: breadcrumb→H1 + CTA→badges gaps */
body.page-aeo.page-service .hero .breadcrumb,
body.page-aeo.page-service .hero .crumbs,
body.page-aeo.page-theme-html .hero .breadcrumb {
  margin: 0 0 clamp(36px, 4vw, 52px) !important;
  padding-bottom: 0 !important;
}
body.page-aeo.page-service .hero h1,
body.page-aeo.page-theme-html .hero h1 {
  margin-top: 0 !important;
  padding-top: 0 !important;
}
body.page-aeo.page-service .hero .hero-actions,
body.page-aeo.page-service .hero .hero-cta {
  margin: 0 0 clamp(28px, 3.5vw, 44px) !important;
}

/* Compare ticks — orange circle with visible check (beats shared orange-on-orange lock) */
body.page-aeo .aeo-theme-page .compare-list {
  list-style: none;
}
body.page-aeo .aeo-theme-page .compare-list li {
  position: relative;
  padding-left: 30px;
  line-height: 1.5;
}
body.page-aeo .aeo-theme-page .compare-list li .mark {
  position: absolute;
  left: 0;
  top: 2px;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1;
}
body.page-aeo .aeo-theme-page .compare-list li .mark.v {
  background: var(--signal, #f47a1f) !important;
  color: var(--signal-ink, #0a1a22) !important;
}
body.page-aeo .aeo-theme-page .compare-list li .mark.x {
  background: rgba(255, 80, 80, 0.12) !important;
  color: #ff7676 !important;
}

/* ── Carousel dots (same pattern as on-page / techseo) ── */
body.page-aeo .aeo-theme-page .testi-dots.thm-carousel-dots,
body.page-aeo .testi-dots.thm-carousel-dots {
  display: none;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  width: 100%;
  margin-top: 18px;
  padding: 4px 0;
  min-height: 18px;
}

body.page-aeo .aeo-theme-page .thm-carousel-dots .testi-dot,
body.page-aeo .thm-carousel-dots .testi-dot {
  width: 10px;
  height: 10px;
  min-width: 10px;
  min-height: 10px;
  border-radius: 50%;
  padding: 0;
  margin: 0;
  border: 2px solid transparent;
  background: #c5d4ce;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease;
  box-shadow: 0 0 0 8px transparent;
}

body.page-aeo .aeo-theme-page .thm-carousel-dots .testi-dot.is-active,
body.page-aeo .thm-carousel-dots .testi-dot.is-active {
  background: var(--signal, #f47a1f);
  border-color: rgba(244, 122, 31, 0.25);
  transform: scale(1.2);
  box-shadow: 0 0 0 6px rgba(244, 122, 31, 0.12);
}

body.page-aeo .thm-carousel-nav-wrap,
body.page-aeo .aeo-theme-page .thm-carousel-nav-wrap {
  display: none !important;
}

@media (max-width: 980px) {
  body.page-aeo .aeo-theme-page .testi-dots.thm-carousel-dots,
  body.page-aeo .testi-dots.thm-carousel-dots {
    display: flex !important;
  }

  body.page-aeo .aeo-theme-page section#services,
  body.page-aeo .aeo-theme-page section:has([data-thm-carousel]),
  body.page-aeo .aeo-theme-page section:has(.why-mobile-carousel) {
    overflow-x: clip !important;
    overflow-y: visible !important;
  }

  body.page-aeo .aeo-theme-page #services .why-mobile-carousel:has(> .carousel-track),
  body.page-aeo .aeo-theme-page #services .why-mobile-carousel:has(> #svcTrack),
  body.page-aeo .aeo-theme-page #services .carousel {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow: visible !important;
    touch-action: auto !important;
    scroll-snap-type: none !important;
  }

  /* Beat webdev-ref sticky-stack rules — keep horizontal swipe carousel */
  html body.page-aeo.page-service .aeo-theme-page.webdev-ref #services .carousel-track,
  html body.page-aeo.page-service .aeo-theme-page.webdev-ref #services #svcTrack,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track[data-thm-carousel],
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack[data-thm-carousel],
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track.thm-mobile-carousel,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack.thm-mobile-carousel,
  html body.page-aeo.page-service .aeo-theme-page #services .why-mobile-carousel > .carousel-track,
  html body.page-aeo.page-service .aeo-theme-page #services .why-mobile-carousel > #svcTrack {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: stretch !important;
    gap: 16px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    scroll-snap-type: x mandatory !important;
    overscroll-behavior-x: contain !important;
    grid-template-columns: none !important;
    grid-template-rows: none !important;
    scrollbar-width: none !important;
    touch-action: pan-x !important;
    position: relative !important;
    transform: none !important;
    filter: none !important;
    contain: none !important;
  }

  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track::-webkit-scrollbar,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack::-webkit-scrollbar {
    display: none !important;
  }

  /* One full-width card per swipe (card or leftover stack wrapper) */
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-stack-item,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-stack-item,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-slide,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-slide {
    flex: 0 0 100% !important;
    flex-shrink: 0 !important;
    width: 100% !important;
    min-width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    box-sizing: border-box !important;
    scroll-snap-align: start !important;
    scroll-snap-stop: always !important;
    position: relative !important;
    top: auto !important;
    transform: none !important;
    opacity: 1 !important;
    margin: 0 !important;
  }

  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-stack-item > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-stack-item > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-slide > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-slide > .svc-card {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    flex-basis: auto !important;
    transform: none !important;
    opacity: 1 !important;
    box-sizing: border-box !important;
  }

  /* Hide theme prev/next — dots only on mobile */
  body.page-aeo .aeo-theme-page #services .carousel-nav-wrap,
  body.page-aeo .aeo-theme-page #services .carousel-nav {
    display: none !important;
  }

  body.page-aeo .aeo-theme-page #services .wrap > .testi-dots.thm-carousel-dots,
  body.page-aeo .aeo-theme-page #services .carousel + .testi-dots.thm-carousel-dots,
  body.page-aeo .aeo-theme-page #services .why-mobile-carousel + .testi-dots.thm-carousel-dots {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    margin-top: 12px !important;
    width: 100% !important;
    justify-content: center !important;
    position: relative !important;
    z-index: 2 !important;
  }

  /* Pain cards — swipe-up sticky stack */
  body.page-aeo .aeo-theme-page section.sec-paper:has(.pain-grid[data-thm-stack]),
  body.page-aeo .aeo-theme-page section.sec-paper:has(.pain-grid.page-svc-stack),
  body.page-aeo .aeo-theme-page section.sec-paper.has-page-svc-stack {
    overflow-x: clip !important;
    overflow-y: visible !important;
  }
  body.page-aeo .aeo-theme-page .why-mobile-carousel:has(> .pain-grid[data-thm-stack]),
  body.page-aeo .aeo-theme-page .why-mobile-carousel:has(> .pain-grid.page-svc-stack) {
    display: contents !important;
  }
  body.page-aeo .aeo-theme-page .pain-grid.page-svc-stack,
  body.page-aeo .aeo-theme-page .pain-grid[data-thm-stack] {
    display: block !important;
    grid-template-columns: none !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    flex-direction: unset !important;
    flex-wrap: unset !important;
    scroll-snap-type: none !important;
    touch-action: auto !important;
  }
  body.page-aeo .aeo-theme-page .pain-grid.page-svc-stack > .svc-stack-item,
  body.page-aeo .aeo-theme-page .pain-grid[data-thm-stack] > .svc-stack-item {
    position: sticky !important;
    top: calc(var(--svc-stack-nav, 68px) + (var(--index0, 0) * var(--svc-stack-peek, 14px))) !important;
    z-index: calc(1 + var(--index0, 0)) !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 0 var(--svc-stack-gap, 18px) !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    transform: none !important;
  }
  body.page-aeo .aeo-theme-page .pain-grid.page-svc-stack > .svc-stack-item:last-child,
  body.page-aeo .aeo-theme-page .pain-grid[data-thm-stack] > .svc-stack-item:last-child {
    margin-bottom: 0 !important;
  }
  body.page-aeo .aeo-theme-page .pain-grid.page-svc-stack .pain-card,
  body.page-aeo .aeo-theme-page .pain-grid.page-svc-stack .svc-stack-item > .pain-card,
  body.page-aeo .aeo-theme-page .pain-grid[data-thm-stack] .pain-card,
  body.page-aeo .aeo-theme-page .pain-grid[data-thm-stack] .svc-stack-item > .pain-card {
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 160px !important;
    margin: 0 !important;
    box-sizing: border-box !important;
    opacity: 1 !important;
    transform: none !important;
    background: var(--paper, #fff) !important;
  }
  body.page-aeo .aeo-theme-page .sec-paper .thm-carousel-dots,
  body.page-aeo .aeo-theme-page section:has(.pain-grid[data-thm-stack]) > .wrap > .testi-dots {
    display: none !important;
  }
}

@media (min-width: 981px) {
  body.page-aeo .aeo-theme-page #services .why-mobile-carousel:has(> .carousel-track),
  body.page-aeo .aeo-theme-page #services .why-mobile-carousel:has(> #svcTrack),
  body.page-aeo .aeo-theme-page .why-mobile-carousel:has(> .pain-grid) {
    display: contents !important;
  }

  body.page-aeo .aeo-theme-page .testi-dots.thm-carousel-dots {
    display: none !important;
  }

  /* Desktop: static 3-col service grid — carousel is mobile-only */
  html body.page-aeo.page-service .aeo-theme-page #services .carousel,
  html body.page-aeo.page-service .aeo-theme-page.webdev-ref #services .carousel {
    overflow: visible !important;
  }
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack,
  html body.page-aeo.page-service .aeo-theme-page.webdev-ref #services .carousel-track,
  html body.page-aeo.page-service .aeo-theme-page.webdev-ref #services #svcTrack,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track[data-thm-carousel],
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack[data-thm-carousel],
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track.thm-mobile-carousel,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack.thm-mobile-carousel {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 20px !important;
    overflow: visible !important;
    overflow-x: visible !important;
    overflow-y: visible !important;
    flex-direction: unset !important;
    flex-wrap: unset !important;
    width: 100% !important;
    max-width: 100% !important;
    scroll-snap-type: none !important;
    touch-action: auto !important;
    transform: none !important;
    padding-bottom: 0 !important;
  }
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-card,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-stack-item,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-stack-item,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track > .svc-slide,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack > .svc-slide {
    flex: unset !important;
    flex-basis: auto !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    height: auto !important;
    scroll-snap-align: unset !important;
    margin: 0 !important;
  }
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-nav-wrap,
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-nav {
    display: none !important;
  }
}
@media (min-width: 981px) and (max-width: 1100px) {
  html body.page-aeo.page-service .aeo-theme-page #services .carousel-track,
  html body.page-aeo.page-service .aeo-theme-page #services #svcTrack {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}
