/* ==============================================
   SERVICES SECTION — COMPLETE RESTYLE v2
   Layout inspired by modern clinic/product showcases
   ============================================== */

/* ---- Section wrapper ---- */
.services-section {
  padding: 5rem 0 7rem;
  background: #f0f4f8;
  position: relative;
  overflow: hidden;
}

.services-section::before {
  content: '';
  position: absolute;
  top: -200px; left: -200px;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(59,130,246,0.10) 0%, transparent 70%);
  pointer-events: none;
}
.services-section::after {
  content: '';
  position: absolute;
  bottom: -150px; right: -150px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(30,58,138,0.08) 0%, transparent 70%);
  pointer-events: none;
}

/* Heading */
.services-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}
.services-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: #1e3a8a;
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.services-title {
  font-size: clamp(2rem, 4vw, 3.5rem);
  font-weight: 900;
  color: #0f172a;
  letter-spacing: -0.04em;
  margin: 0.25rem 0 0;
  line-height: 1.05;
}
.services-subtitle {
  color: #64748b;
  font-size: 1rem;
  max-width: 50ch;
  line-height: 1.6;
  margin: 0.5rem 0 0;
  font-weight: 400;
}

/* ---- Category nav tabs ---- */
.services-nav-wrapper {
  display: flex;
  justify-content: center;
  margin: 0 0 2.5rem;
  padding: 0 1rem;
}
.services-category-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.35rem;
  background: #ffffff;
  padding: 0.45rem;
  border-radius: 9999px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}
.cat-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.65rem 1.4rem;
  border-radius: 9999px;
  border: none;
  background: transparent;
  color: #64748b;
  font-weight: 700;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4,0,0.2,1);
  white-space: nowrap;
}
.cat-btn .cat-icon {
  width: 18px; height: 18px;
  flex-shrink: 0;
  opacity: 0.65;
  transition: opacity 0.3s;
}
.cat-btn:hover {
  color: #1e3a8a;
  background: #f1f5f9;
}
.cat-btn:hover .cat-icon { opacity: 1; }
.cat-btn.active {
  background: #1e3a8a;
  color: #ffffff;
  box-shadow: 0 8px 20px rgba(30,58,138,0.35);
}
.cat-btn.active .cat-icon { opacity: 1; filter: brightness(10); }

/* ---- Main panel ---- */
.svc-panel-wrap {
  position: relative;
}
.svc-panel {
  display: none;
  animation: panelFadeIn 0.55s cubic-bezier(0.4,0,0.2,1) forwards;
}
.svc-panel.active {
  display: grid;
}
@keyframes panelFadeIn {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Single-service panels (POS) */
.svc-panel.layout-hero {
  grid-template-columns: 1fr 1.1fr 1fr;
  gap: 2.5rem;
  align-items: center;
  background: #fff;
  border-radius: 2rem;
  padding: 3rem 2.5rem;
  box-shadow: 0 20px 60px rgba(0,0,0,0.06);
  border: 1px solid #e8eef6;
}

/* Multi-service panels */
.svc-panel.layout-grid {
  grid-template-columns: 1fr;
  gap: 0;
  background: #fff;
  border-radius: 2rem;
  box-shadow: 0 20px 60px rgba(0,0,0,0.06);
  border: 1px solid #e8eef6;
  overflow: hidden;
}

/* ---- Hero panel left: small preview ---- */
.svc-hero-left {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.svc-small-img {
  border-radius: 1.25rem;
  overflow: hidden;
  aspect-ratio: 4/3;
  background: #f0f4f8;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.svc-small-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}
.svc-small-img:hover img { transform: scale(1.05); }

/* ---- Hero panel center: text ---- */
.svc-hero-center {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.svc-category-label {
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #1e3a8a;
}
.svc-headline {
  font-size: clamp(1.6rem, 3vw, 2.6rem);
  font-weight: 900;
  color: #0f172a;
  line-height: 1.1;
  letter-spacing: -0.03em;
  margin: 0;
}
.svc-features {
  list-style: none;
  padding: 0; margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.svc-features li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-size: 0.97rem;
  color: #334155;
  font-weight: 500;
}
.svc-features li::before {
  content: '';
  display: inline-flex;
  width: 22px; height: 22px;
  flex-shrink: 0;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 22'%3E%3Ccircle cx='11' cy='11' r='11' fill='%231e3a8a'/%3E%3Cpath d='M6 11l4 4 6-6' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round' fill='none'/%3E%3C/svg%3E") center/contain no-repeat;
}
.svc-cta-row {
  display: flex;
  gap: 0.85rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.8rem;
  background: #1e3a8a;
  color: #fff;
  border: none;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(30,58,138,0.3);
  text-decoration: none;
}
.btn-primary:hover {
  background: #1e40af;
  box-shadow: 0 12px 28px rgba(30,58,138,0.4);
  transform: translateY(-2px);
}
.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.85rem 1.8rem;
  background: transparent;
  color: #1e3a8a;
  border: 2px solid #1e3a8a;
  border-radius: 9999px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}
.btn-secondary:hover {
  background: #f0f4ff;
  transform: translateY(-2px);
}

/* ---- Hero panel right: big image ---- */
.svc-hero-right {
  position: relative;
}
.svc-big-img {
  border-radius: 1.5rem;
  overflow: hidden;
  aspect-ratio: 4/3;
  box-shadow: 0 20px 50px rgba(0,0,0,0.12);
  background: #e2e8f0;
  position: relative;
}
.svc-big-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.svc-img-badge {
  position: absolute;
  bottom: 1.25rem; left: 1.25rem;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-radius: 0.85rem;
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: #0f172a;
  border: 1px solid rgba(255,255,255,0.7);
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}
.svc-img-badge-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #22c55e;
  animation: pulse-dot 2s infinite;
}
@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0.5); }
  50% { box-shadow: 0 0 0 6px rgba(34,197,94,0); }
}

/* ---- Multi-service grid panel layout ---- */
/* Top row with large featured */
.svc-grid-top {
  display: grid;
  grid-template-columns: 1fr 1.1fr 1fr;
  gap: 0;
  border-bottom: 1px solid #e8eef6;
}

/* Sub-service ROWS (horizontal cards) */
.svc-grid-cards {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 2rem;
  background: #f8fafc;
  border-radius: 0 0 2rem 2rem;
}

.svc-sub-card {
  display: grid;
  grid-template-columns: 240px 1fr auto;
  gap: 1.5rem;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 1.25rem;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
  transition: all 0.3s ease;
  cursor: pointer;
  text-decoration: none;
  min-height: 140px;
  overflow: hidden;
  padding: 0.75rem;
}
.svc-sub-card:hover {
  background: #ffffff;
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(30,58,138,0.08);
  border-color: #cbd5e1;
}

/* Image column */
.svc-sub-card-img {
  width: 100%;
  height: 100%;
  min-height: 140px;
  border-radius: 0.85rem;
  overflow: hidden;
  background: #f0f4f8;
  flex-shrink: 0;
}
.svc-sub-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.svc-sub-card:hover .svc-sub-card-img img { transform: scale(1.06); }

/* Content column */
.svc-sub-card-content {
  padding: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  justify-content: center;
}
.svc-sub-card h4 {
  font-size: 1.35rem;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
  line-height: 1.2;
  letter-spacing: -0.02em;
}

/* Bullet list */
.svc-sub-points {
  list-style: none;
  padding: 0; margin: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem 2rem;
}
.svc-sub-points li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.95rem;
  color: #475569;
  font-weight: 500;
  line-height: 1.4;
}
.svc-sub-points li::before {
  content: '';
  display: inline-flex;
  width: 18px; height: 18px;
  margin-top: 2px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%232563eb'%3E%3Cpath fill-rule='evenodd' d='M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z' clip-rule='evenodd'/%3E%3C/svg%3E") no-repeat center;
  background-size: contain;
  flex-shrink: 0;
}

/* Arrow CTA column */
.svc-sub-card-cta {
  display: flex;
  align-items: center;
  padding: 0 1.5rem;
  border-left: 1px solid #e2e8f0;
  flex-shrink: 0;
  height: 80%;
}
.svc-sub-card-arrow {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: #1e3a8a;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  transition: transform 0.2s;
  white-space: nowrap;
}
.svc-sub-card-arrow svg {
  width: 28px; height: 28px;
  background: #eef2ff;
  border-radius: 50%;
  padding: 6px;
  transition: background 0.3s, transform 0.3s;
}
.svc-sub-card:hover .svc-sub-card-arrow svg {
  background: #1e3a8a;
  color: #fff;
  transform: translateX(4px);
}
.svc-sub-card:hover .svc-sub-card-arrow svg path,
.svc-sub-card:hover .svc-sub-card-arrow svg polyline {
  stroke: #fff;
}

/* Progress bar for auto-rotation */
.svc-autoplay-bar {
  height: 3px;
  background: #e2e8f0;
  border-radius: 0 0 2rem 2rem;
  overflow: hidden;
  position: relative;
}
.svc-autoplay-progress {
  height: 100%;
  background: linear-gradient(90deg, #3b82f6, #1e3a8a);
  width: 0%;
  transition: width linear;
  border-radius: 0 0 2rem 2rem;
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .svc-panel.layout-hero {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 2rem;
  }
  .svc-hero-left { display: none; }
  .svc-grid-top {
    grid-template-columns: 1fr 1fr;
  }
  .svc-grid-cards { padding: 1.5rem; }
  .svc-sub-card {
    grid-template-columns: 200px 1fr auto;
    padding: 0.75rem;
    gap: 1rem;
  }
  .svc-sub-card-img { min-height: 120px; }
  .svc-sub-points { grid-template-columns: 1fr; }
}
@media (max-width: 768px) {
  .svc-panel.layout-hero {
    grid-template-columns: 1fr;
    padding: 1.5rem;
  }
  .svc-hero-right { display: none; }
  .services-category-nav {
    border-radius: 1.5rem;
    padding: 0.5rem;
  }
  .cat-btn { padding: 0.5rem 1rem; font-size: 0.8rem; }
  .svc-grid-top { grid-template-columns: 1fr; }
  .svc-grid-cards { padding: 1rem; gap: 1rem; }
  .svc-sub-card {
    grid-template-columns: 100px 1fr;
    gap: 1rem;
    padding: 0.75rem;
  }
  .svc-sub-card-img { min-height: 100px; }
  .svc-sub-card-cta { display: none; }
  .svc-sub-card-content { padding: 0.5rem 0; }
  .svc-sub-points { grid-template-columns: 1fr; gap: 0.3rem; }
}
@media (max-width: 480px) {
  .svc-sub-card {
    grid-template-columns: 80px 1fr;
    gap: 0.75rem;
    padding: 0.5rem;
  }
  .svc-sub-card-img { min-height: 80px; }
  .svc-sub-card h4 { font-size: 0.95rem; }
  .svc-sub-points li { font-size: 0.8rem; }
}

/* Remove old styles that conflict */
.services-mask, .services-wrapper, .services-grid,
.modern-mask, .modern-grid, .modern-card, .card-hidden, .card-visible,
#journey-svg-wrap, .services-sticky-container,
#services-pin-track { all: unset; display: contents; }
