/* ==========================================================================
   Services page redesign — hero, colorful service card grid (same palette
   as the Knowledge Hub's category cards), a detail modal that reveals each
   service's full copy, and a restyled FAQ accordion.
   Self-contained: only depends on the site-wide tokens/components in
   landing_redesign.css (CSS vars, .rd-container, .rd-btn) — does not use or
   modify services_redesign.css (now unused by this page, left in place).
   ========================================================================== */

/* Beats the site-wide "underline every link" rule in Shared/Layout.html —
   same fix needed for the Knowledge Hub and Products redesigns. */
#svc-hero a,
#svc-explore a,
#svc-faq a,
#svc-cta a {
  text-decoration: none !important;
}

/* --- Hero --- */
.svc-hero {
  background: linear-gradient(135deg, var(--color-purple-bg) 0%, #eef2ff 45%, var(--color-orange-bg) 100%);
  padding: 70px 20px 60px;
  overflow-x: hidden;
}

.svc-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 50px;
  align-items: center;
}

.svc-hero-text {
  min-width: 0;
}

.svc-hero-eyebrow {
  color: var(--color-orange);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.svc-hero-title {
  font-family: var(--font-heading);
  color: var(--color-purple-dark);
  font-size: 2.7rem;
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 16px;
}

.svc-hero-subtitle {
  color: var(--color-text-body);
  font-size: 1.05rem;
  line-height: 1.6;
  max-width: 560px;
  margin: 0 0 28px;
}

.svc-hero-ctas {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 14px;
  margin-bottom: 30px;
}

.svc-hero-ctas .rd-btn {
  text-decoration: none !important;
  cursor: pointer;
  box-sizing: border-box;
  max-width: 100%;
}

.svc-trust-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 18px 26px;
}

.svc-trust-row span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-weight: 600;
}

.svc-trust-row i {
  color: var(--color-purple);
}

.svc-hero-visual {
  min-width: 0;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 22px;
  min-height: 340px;
}

.svc-hero-glow {
  position: absolute;
  top: 2%;
  left: 4%;
  right: 4%;
  bottom: 10%;
  background: radial-gradient(ellipse at 50% 45%, rgba(255, 255, 255, 0.65) 0%, rgba(255, 255, 255, 0) 68%);
  filter: blur(20px);
  z-index: 0;
  pointer-events: none;
}

.svc-laptop {
  position: relative;
  z-index: 1;
  width: 400px;
  max-width: 100%;
  min-width: 0;
  flex-shrink: 1;
  margin-top: 0;
}

.svc-hero-note {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  max-width: 160px;
  font-family: 'Caveat', cursive;
  font-size: 1.4rem;
  color: var(--color-purple-dark);
  text-align: right;
  line-height: 1.2;
  transform: rotate(4deg);
  margin-top: 0;
  align-self: center;
}

.svc-hero-note-underline {
  display: block;
  width: 68px;
  height: 10px;
  margin: 4px 0 0 auto;
  border-bottom: 3px solid var(--color-orange);
  border-radius: 50%;
  transform: rotate(3deg);
}

.svc-laptop-screen {
  background: #262b3d;
  border-radius: 14px 14px 3px 3px;
  padding: 9px 9px 12px;
  box-shadow: var(--shadow-lg);
}

.svc-mock-window {
  width: 100%;
  background: var(--color-white);
  border-radius: 6px;
  overflow: hidden;
}

.svc-laptop-base {
  height: 13px;
  margin: 0 -16px;
  background: linear-gradient(180deg, #dfe2ea 0%, #b9bfcc 100%);
  border-radius: 0 0 9px 9px;
  position: relative;
}

.svc-laptop-base::after {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  width: 56px;
  height: 5px;
  background: #9aa0b0;
  border-radius: 0 0 7px 7px;
  transform: translateX(-50%);
}

.svc-mock-topbar {
  display: flex;
  gap: 6px;
  padding: 10px 14px;
  background: var(--color-bg-light);
  border-bottom: 1px solid var(--color-border);
}

.svc-mock-topbar span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-border);
}

.svc-mock-topbar span:nth-child(1) { background: #ff6b6b; }
.svc-mock-topbar span:nth-child(2) { background: #ffc857; }
.svc-mock-topbar span:nth-child(3) { background: #4fc98f; }

.svc-mock-layout {
  display: flex;
  min-height: 220px;
}

.svc-mock-sidebar {
  flex-shrink: 0;
  width: 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 13px;
  padding: 14px 0;
  background: var(--color-bg-light);
}

.svc-mock-logo {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  background: linear-gradient(135deg, var(--color-purple), #8d7cf0);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,0.75);
}

.svc-mock-navdot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(121, 128, 160, 0.35);
}

.svc-mock-navdot.active {
  background: var(--color-purple);
  box-shadow: 0 0 0 4px rgba(119, 99, 217, 0.12);
}

.svc-mock-body {
  flex: 1;
  background: linear-gradient(180deg, #fefeff 0%, #f4f3ff 100%);
  padding: 18px 16px 14px;
}

.svc-mock-greeting {
  color: var(--color-purple-dark);
  font-size: 0.8rem;
  font-weight: 800;
  margin-bottom: 16px;
}

.svc-mock-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.svc-mock-stat {
  background: #fff;
  border: 1px solid rgba(127, 126, 165, 0.18);
  border-radius: 12px;
  padding: 10px 8px;
  box-shadow: 0 10px 18px rgba(39, 36, 77, 0.05);
}

.svc-mock-stat strong {
  display: block;
  color: var(--color-purple-dark);
  font-size: 0.9rem;
  margin-bottom: 3px;
}

.svc-mock-stat span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--color-text-muted);
  font-size: 0.62rem;
}

.svc-mock-bars {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  height: 76px;
}

.svc-mock-bars div {
  border-radius: 8px 8px 4px 4px;
  background: linear-gradient(180deg, rgba(138, 120, 234, 0.9), rgba(255, 153, 77, 0.9));
}

.svc-mock-bars div:nth-child(1) { height: 48%; }
.svc-mock-bars div:nth-child(2) { height: 72%; }
.svc-mock-bars div:nth-child(3) { height: 56%; }

.svc-hero-float-card {
  position: absolute;
  right: 14px;
  bottom: 20px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.96);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(127, 126, 165, 0.15);
}

.svc-hero-float-card i {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--color-purple), #8d7cf0);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1rem;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,0.65);
}

.svc-hero-float-card strong,
.svc-hero-float-card span {
  display: block;
}

.svc-hero-float-card strong {
  font-size: 0.8rem;
  color: var(--color-purple-dark);
}

.svc-hero-float-card span {
  font-size: 0.68rem;
  color: var(--color-text-muted);
}

/* --- Explore section --- */
.svc-explore {
  padding: 60px 20px 64px;
  background: var(--color-white);
}

.svc-section-title {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
  text-align: center;
  max-width: 640px;
  margin: 0 auto 36px;
}

.svc-eyebrow {
  color: var(--color-orange);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.svc-section-title h2 {
  font-family: var(--font-heading);
  color: var(--color-purple-dark);
  font-size: 1.9rem;
  font-weight: 800;
  margin: 0;
}

.svc-section-title p {
  color: var(--color-text-muted);
  margin: 4px 0 0;
}

.svc-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.svc-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-lg);
  padding: 28px 26px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  min-width: 0;
}

.svc-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.svc-card-icon {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  color: #fff;
  margin-bottom: 18px;
}

.svc-card-media {
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 18px;
  border: 1px solid rgba(72, 85, 148, 0.12);
  background: #ffffff;
  box-shadow: 0 10px 20px rgba(21, 25, 55, 0.05);
}

.svc-card-media img {
  width: 100%;
  max-width: none;
  height: 180px;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.svc-card:hover .svc-card-media img {
  transform: scale(1.03);
}

.svc-card h3 {
  overflow-wrap: anywhere;
  font-family: var(--font-heading);
  color: var(--color-purple-dark);
  font-size: 1.12rem;
  font-weight: 700;
  margin: 0 0 8px;
}

.svc-card-subtitle {
  color: var(--color-text-muted);
  font-size: 0.8rem;
  font-style: italic;
  margin: 0 0 12px;
}

.svc-card-features {
  list-style: none;
  margin: 0 0 20px;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.svc-card-features li {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.85rem;
  color: var(--color-text-body);
}

.svc-card-features i {
  font-size: 0.75rem;
}

.svc-card-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none !important;
  margin-top: auto;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  font-family: var(--font-body);
}

.svc-card-link i {
  font-size: 0.78rem;
  transition: transform 0.2s ease;
}

.svc-card-link:hover i {
  transform: translateX(3px);
}

/* Card color variants — same palette as the Knowledge Hub category cards */
.svc-card-1 { background: var(--color-purple-bg); }
.svc-card-1 .svc-card-icon { background: var(--color-purple); }
.svc-card-1 .svc-card-link { color: var(--color-purple); }
.svc-card-1 .svc-card-features i { color: var(--color-purple); }

.svc-card-2 { background: var(--color-orange-bg); }
.svc-card-2 .svc-card-icon { background: var(--color-orange); }
.svc-card-2 .svc-card-link { color: var(--color-orange); }
.svc-card-2 .svc-card-features i { color: var(--color-orange); }

.svc-card-3 { background: #e5f6ee; }
.svc-card-3 .svc-card-icon { background: #1f8a5f; }
.svc-card-3 .svc-card-link { color: #1f8a5f; }
.svc-card-3 .svc-card-features i { color: #1f8a5f; }

.svc-card-4 { background: #e8f0fe; }
.svc-card-4 .svc-card-icon { background: #2f6fed; }
.svc-card-4 .svc-card-link { color: #2f6fed; }
.svc-card-4 .svc-card-features i { color: #2f6fed; }

.svc-card-5 { background: #fde9ee; }
.svc-card-5 .svc-card-icon { background: #e6416a; }
.svc-card-5 .svc-card-link { color: #e6416a; }
.svc-card-5 .svc-card-features i { color: #e6416a; }

.svc-card-6 { background: #f1eafd; }
.svc-card-6 .svc-card-icon { background: #7c4fd1; }
.svc-card-6 .svc-card-link { color: #7c4fd1; }
.svc-card-6 .svc-card-features i { color: #7c4fd1; }

.svc-card-full { display: none; }

/* --- Service detail modal (reveals the full original copy on "Learn More") --- */
.svc-detail-overlay {
  position: fixed;
  inset: 0;
  background: rgba(26,20,56,0.55);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.svc-detail-card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  max-width: 720px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
}

.svc-detail-header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 26px 30px;
  background: linear-gradient(135deg, var(--color-purple-bg) 0%, #eef2ff 45%, var(--color-orange-bg) 100%);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.svc-detail-icon {
  width: 52px;
  height: 52px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--color-purple);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

.svc-detail-title-group {
  flex: 1;
  min-width: 0;
}

.svc-detail-title-group h3 {
  font-family: var(--font-heading);
  color: var(--color-purple-dark);
  font-size: 1.25rem;
  font-weight: 800;
  margin: 0 0 4px;
}

.svc-detail-title-group span {
  color: var(--color-text-muted);
  font-size: 0.85rem;
  font-style: italic;
}

.svc-detail-close {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--color-white);
  color: var(--color-purple-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
}

.svc-detail-close:hover {
  background: var(--color-orange);
  color: #fff;
}

.svc-detail-body {
  padding: 24px 30px 30px;
}

.svc-detail-body p {
  color: var(--color-text-body);
  font-size: 0.95rem;
  line-height: 1.7;
  margin: 0 0 14px;
}

.svc-detail-pills-title {
  font-family: var(--font-heading);
  color: var(--color-orange);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 18px 0 10px;
}

.svc-detail-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.svc-detail-pill {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--color-bg-light);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 0.82rem;
  color: var(--color-text-body);
}

.svc-detail-pill i {
  color: #1f8a5f;
  font-size: 0.78rem;
}

/* --- FAQ --- */
.svc-faq {
  padding: 60px 20px;
  background: var(--color-bg-light);
}

.svc-faq-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.svc-faq-item {
  background: var(--color-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  padding: 4px 22px;
}

.svc-faq-item summary {
  padding: 16px 0;
  font-family: var(--font-heading);
  color: var(--color-purple-dark);
  font-weight: 700;
  font-size: 0.98rem;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.svc-faq-item summary::-webkit-details-marker {
  display: none;
}

.svc-faq-item summary::after {
  content: '\002B';
  flex-shrink: 0;
  color: var(--color-orange);
  font-size: 1.2rem;
  font-weight: 700;
  transition: transform 0.2s ease;
}

.svc-faq-item[open] summary::after {
  content: '\2212';
}

.svc-faq-answer {
  overflow-wrap: anywhere;
  color: var(--color-text-body);
  font-size: 0.9rem;
  line-height: 1.7;
  padding: 0 0 18px;
}

.svc-faq-more {
  text-align: center;
  margin-top: 30px;
}

/* --- CTA banner --- */
.svc-cta {
  padding: 60px 20px;
  background: var(--color-white);
}

.svc-cta-inner {
  background: linear-gradient(120deg, var(--color-purple) 0%, var(--color-purple-light) 55%, var(--color-orange) 130%);
  border-radius: var(--radius-lg);
  padding: 50px 48px;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.svc-cta-eyebrow {
  color: #ffe0c2;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.svc-cta-inner h2 {
  font-family: var(--font-heading);
  color: #fff;
  font-size: 1.9rem;
  font-weight: 800;
  margin: 8px 0 10px;
}

.svc-cta-inner p {
  color: rgba(255,255,255,0.88);
  font-size: 0.95rem;
  max-width: 520px;
  margin: 0 auto 26px;
}

.svc-cta-btn {
  background: #fff !important;
  color: var(--color-purple-dark) !important;
  border: none !important;
  text-decoration: none !important;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}

.svc-cta-btn:hover {
  background: var(--color-orange-bg) !important;
}

/* --- Responsive --- */
.svc-faq-answer img { max-width: 100%; height: auto; }
.svc-faq-answer table { display: block; max-width: 100%; overflow-x: auto; }

@media (max-width: 992px) {
  .svc-hero { padding: 56px 20px 48px; }

  .svc-hero-inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
    text-align: center;
  }

  .svc-hero-text { text-align: center; }

  .svc-hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .svc-hero-ctas,
  .svc-trust-row {
    justify-content: center;
  }

  .svc-hero-visual {
    margin-top: 10px;
    min-height: 0;
    max-width: 560px;
    width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

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

@media (max-width: 768px) {
  .svc-hero-title { font-size: 2.2rem; }
  .svc-hero-subtitle { font-size: 1rem; }

  .svc-explore, .svc-faq, .svc-cta { padding-top: 48px; padding-bottom: 48px; }
  .svc-section-title { margin-bottom: 28px; }
  .svc-section-title h2,
  .svc-cta-inner h2 { font-size: 1.6rem; }
  .svc-cta-inner { padding: 40px 28px; }
}

@media (max-width: 600px) {
  .svc-hero { padding: 40px 16px 36px; }
  .svc-explore, .svc-faq, .svc-cta { padding-left: 16px; padding-right: 16px; }

  .svc-hero-title { font-size: 1.85rem; }
  .svc-hero-subtitle { font-size: 0.95rem; margin-bottom: 22px; }

  /* Buttons: full width, easy to tap */
  .svc-hero-ctas { flex-direction: column; align-items: stretch; gap: 12px; margin-bottom: 24px; }
  .svc-hero-ctas .rd-btn { width: 100%; box-sizing: border-box; display: inline-flex; justify-content: center; align-items: center; gap: 8px; text-align: center; }

  .svc-trust-row { gap: 10px 16px; }
  .svc-trust-row span { font-size: 0.76rem; }

  /* Hero visual: stack, scale to the screen, no overlapping decorations */
  .svc-hero-visual { flex-direction: column; gap: 14px; }
  .svc-laptop { width: 100%; max-width: 360px; }
  .svc-laptop-base { margin: 0 -8px; }
  .svc-hero-note { display: none; }
  .svc-hero-float-card {
    position: static;
    align-self: center;
    max-width: 100%;
  }
  .svc-mock-layout { min-height: 170px; }
  .svc-mock-body { padding: 12px 10px; }
  .svc-mock-greeting { margin-bottom: 10px; }
  .svc-mock-stats { gap: 6px; margin-bottom: 12px; }
  .svc-mock-stat { padding: 8px 6px; }
  .svc-mock-stat span { font-size: 0.54rem; }
  .svc-mock-bars { height: 56px; gap: 6px; }

  /* Cards + images */
  .svc-card-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .svc-card { padding: 22px 18px; }
  .svc-card-media img {
    height: auto;
    aspect-ratio: 16 / 9;
  }
  .svc-card-icon {
    width: 46px;
    height: 46px;
    font-size: 1.1rem;
  }
  .svc-card-link { padding: 6px 0; }

  /* Detail modal becomes a bottom sheet */
  .svc-detail-overlay { padding: 0; align-items: flex-end; }
  .svc-detail-card {
    max-width: 100%;
    max-height: 90vh;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  }
  .svc-detail-header { padding: 18px 16px; gap: 12px; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .svc-detail-icon { width: 42px; height: 42px; font-size: 1.05rem; }
  .svc-detail-title-group h3 { font-size: 1.05rem; }
  .svc-detail-body { padding: 18px 16px 24px; }
  .svc-detail-pills { flex-direction: column; gap: 8px; }
  .svc-detail-pill { width: 100%; border-radius: 14px; }

  /* FAQ */
  .svc-faq-item { padding: 2px 16px; }
  .svc-faq-item summary { font-size: 0.92rem; padding: 14px 0; }

  /* CTA */
  .svc-cta-inner { padding: 34px 20px; }
  .svc-cta-inner h2 { font-size: 1.4rem; }
  .svc-cta-btn { width: 100%; justify-content: center; }
}

@media (max-width: 380px) {
  .svc-hero-title { font-size: 1.6rem; }
  .svc-card { padding: 18px 14px; }
  .svc-card-features li { font-size: 0.82rem; }
}