/* ==========================================================================
   Service — Capabilities, Variant 1
   Same component as the Real Estate App Development page's own Capabilities
   section (assets/css/real-estate-app-development.css, `.reapp-cap-*`) —
   every rule below is that block, renamed to `.svc-cap-*`, minus the
   original's right-side orbiting mockup (fixed decorative content with no
   generic per-service equivalent) — replaced with a plain ACF image, same
   `.has-image` optional-second-column idiom as template-parts/services/
   about.php's `.service-about-grid`.
   ========================================================================== */

.svc-cap {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 80px 0;
  background: #ffffff;
}

/* ---- Layout ---- */

.svc-cap-inner {
  position: relative;
  z-index: 2;
  display: grid;
  align-items: center;
  gap: 64px;
}

.svc-cap-inner.has-image {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.svc-cap-content {
  max-width: 620px;
}

.svc-cap-inner:not(.has-image) .svc-cap-content {
  max-width: 720px;
}

.svc-cap-title {
  font-size: 42px;
  line-height: 56px;
  font-weight: 700;
  margin-bottom: 16px;
  color: #04070d;
}

@media (max-width: 1550px) {
  .svc-cap-title { font-size: 38px; line-height: 48px; }
}

@media (max-width: 1440px) {
  .svc-cap-title { font-size: 36px; }
}

@media (max-width: 1200px) {
  .svc-cap-title { font-size: 40px; }
}

@media (max-width: 1024px) {
  .svc-cap-title { font-size: 36px; }
}

@media (max-width: 912px) {
  .svc-cap-title { font-size: 32px; }
}

@media (max-width: 820px) {
  .svc-cap-title { font-size: 30px; line-height: 1.4; }
}

@media (max-width: 767px) {
  .svc-cap-title { font-size: 40px; }
}

@media (max-width: 650px) {
  .svc-cap-title { font-size: 22px; font-weight: 500; line-height: 40px; }
}

.svc-cap-intro {
  max-width: 560px;
  font-size: clamp(1rem, 1.15vw, 1.0625rem);
  line-height: 1.75;
  color: rgba(4, 7, 13, 0.68);
}

/* ---- Capability checklist ---- */

.svc-cap-list {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 36px;
  padding: 0;
  list-style: none;
}

.svc-cap-item {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 14px 14px 16px;
  border-radius: 14px;
  border: 1px solid transparent;
  transition: background-color 220ms ease, border-color 220ms ease, transform 220ms ease;
}

/* Interactive: a left accent bar draws in on hover/focus, the icon tile
   lifts to solid cyan, and the row nudges right — cheap, GPU-only affordances
   that need no JS. */
.svc-cap-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10%;
  bottom: 10%;
  width: 2px;
  border-radius: 2px;
  background: #00c2ff;
  transform: scaleY(0);
  transform-origin: 50% 50%;
  transition: transform 260ms ease;
}

.svc-cap-item:hover,
.svc-cap-item:focus-within {
  background: rgba(0, 194, 255, 0.07);
  border-color: rgba(0, 194, 255, 0.18);
  transform: translateX(4px);
}

.svc-cap-item:hover::before,
.svc-cap-item:focus-within::before {
  transform: scaleY(1);
}

.svc-cap-item-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  margin-top: 2px;
  border-radius: 9px;
  background: rgba(0, 194, 255, 0.12);
  border: 1px solid rgba(0, 194, 255, 0.2);
  color: #0284c7;
  transition: background-color 220ms ease, border-color 220ms ease, color 220ms ease, transform 220ms ease;
}

.svc-cap-item:hover .svc-cap-item-icon,
.svc-cap-item:focus-within .svc-cap-item-icon {
  background: #00c2ff;
  color: #04070d;
  transform: scale(1.08);
}

.svc-cap-item-icon svg {
  width: 15px;
  height: 15px;
}

.svc-cap-item-text {
  font-size: 14.5px;
  line-height: 1.65;
  color: rgba(4, 7, 13, 0.66);
}

.svc-cap-item-text strong {
  display: inline;
  color: #04070d;
  font-weight: 700;
}

/* ---- Right-side stat mosaic ----
   Fixed gradient colors per card position (violet main card, pink + blue
   metric cards, dark footer card) so the mosaic always reads correctly —
   only icon/title/description/metric text comes from ACF
   (`capabilities_stat_panel`, a group field). */

.svc-cap-stats {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.svc-cap-stat-card {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
}

.svc-cap-stat-card--main {
  padding: 28px;
  background: linear-gradient(135deg, #7c4de0 0%, #9a5ce8 100%);
  box-shadow: 0 24px 50px -20px rgba(124, 77, 224, 0.55);
}

.svc-cap-stat-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.18);
  color: #ffffff;
}

.svc-cap-stat-icon svg {
  width: 22px;
  height: 22px;
}

.svc-cap-stat-badge {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: rgba(255, 255, 255, 0.22);
}

.svc-cap-stat-title {
  margin: 0 0 8px;
  font-size: 19px;
  font-weight: 700;
  color: #ffffff;
}

.svc-cap-stat-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

.svc-cap-metric-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.svc-cap-stat-card--metric {
  display: flex;
  flex-direction: column;
  padding: 22px;
}

.svc-cap-stat-card--metric .svc-cap-stat-icon {
  width: 32px;
  height: 32px;
  margin-bottom: 14px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.2);
}

.svc-cap-stat-card--metric .svc-cap-stat-icon svg {
  width: 16px;
  height: 16px;
}

.svc-cap-stat-card--pink {
  background: linear-gradient(150deg, #e31c5f 0%, #f0507e 100%);
  box-shadow: 0 20px 44px -18px rgba(227, 28, 95, 0.5);
}

.svc-cap-stat-card--blue {
  background: linear-gradient(150deg, #2f7cf6 0%, #4fb3f3 100%);
  box-shadow: 0 20px 44px -18px rgba(47, 124, 246, 0.5);
}

.svc-cap-metric-value {
  font-size: 30px;
  font-weight: 800;
  line-height: 1.15;
  color: #ffffff;
}

.svc-cap-metric-label {
  margin-top: 4px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.82);
}

.svc-cap-stat-card--footer {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  background: #0d0d13;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.svc-cap-avatar-stack {
  display: flex;
  flex: 0 0 auto;
}

.svc-cap-avatar {
  width: 34px;
  height: 34px;
  margin-left: -10px;
  border-radius: 50%;
  border: 2px solid #0d0d13;
  background: linear-gradient(135deg, #9a5ce8 0%, #7c4de0 100%);
}

.svc-cap-avatar:first-child {
  margin-left: 0;
}

.svc-cap-avatar--plus {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1c1c24;
  color: rgba(255, 255, 255, 0.85);
  font-size: 13px;
  font-weight: 700;
}

.svc-cap-footer-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.svc-cap-footer-text strong {
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
}

.svc-cap-footer-text em {
  font-style: normal;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.55);
}

/* ---- Responsive ---- */

@media (max-width: 1024px) {
  .svc-cap {
    padding: 96px 0 110px;
  }

  .svc-cap-inner.has-image {
    grid-template-columns: 1fr;
    gap: 56px;
    text-align: center;
  }

  .svc-cap-inner.has-image .svc-cap-content {
    max-width: none;
    margin: 0 auto;
  }

  .svc-cap-inner.has-image .svc-cap-intro {
    margin-left: auto;
    margin-right: auto;
  }

  .svc-cap-inner.has-image .svc-cap-item {
    text-align: left;
  }
}

@media (max-width: 640px) {
  .svc-cap-title {
    font-size: clamp(28px, 8vw, 34px);
  }

  .svc-cap-item-text {
    font-size: 14px;
  }
}
