/* Service page specific styles */
.services-page {
  max-width: 1200px;
  margin: 96px auto;
  padding: 0 24px;
}
.services-page__header .lead {
  color: var(--muted);
}
.svc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 28px;
}
.svc-card {
  background: transparent;
  color: var(--text);
  border: 2px solid #7a509a;
  border-radius: 20px;
  padding: 24px 24px 36px;
  position: relative;
  box-shadow: none;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
  min-height: 240px;
}

.svc-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 14px 30px rgba(0,0,0,0.16);
  border-color: #7a509a;
  /* show bottom accent bar */
}
.svc-card:hover::after{
  transform:scaleX(1);
}

.svc-card a,
.svc-card a:hover,
.svc-card a:focus {
  text-decoration: none;
}
.svc-icon {
  margin-bottom: 14px;
  color: #7a509a;
}

.svc-icon svg {
  width: 36px;
  height: 36px;
  stroke-width: 1.5;
}
.svc-title {
  margin: 0 0 8px;
  font-size: 1.2rem;
}
.svc-desc {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.svc-more {
  position: absolute;
  left: 16px;
  right: auto;
  bottom: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #7a509a;
  opacity: 0.9;
  text-decoration: none;
  border: 1px solid #7a509a;
  padding: 6px 12px;
  border-radius: 12px;
  background: transparent;
}

.svc-card:hover .svc-more {
  opacity: 1;
  background: rgba(122, 80, 154, 0.06);
}

@media (max-width: 600px) {
  .services-page {
    margin: 64px auto;
    padding: 0 16px;
  }
  .svc-grid{
    grid-template-columns: 1fr;
  }
}

@media (max-width: 992px){
  .svc-grid{
    grid-template-columns: repeat(2,1fr);
  }
}


/* Service Detail Page Layout (reuse from news.css) */
.post-layout {
  display: grid;
  grid-template-columns: 400px minmax(0, 1fr) 0px; /* left ~400px, main takes the rest to navbar edge */
  gap: 32px;
  max-width: 1400px;
  margin: 48px auto;
  padding: 0 16px; /* match navbar's horizontal padding */
  align-items: flex-start;
}

.post-main {
  width: 100%;
}

.post-sidebar-left, .post-sidebar-right {
  position: sticky;
  top: 96px;
  display: block;
}

.table-of-contents {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  min-height: 50px;
  margin-top: 16px;
}

.table-of-contents:empty {
  display: none;
}

.table-of-contents:not(:empty) {
  display: block !important;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 24px;
  transition: color 0.2s ease;
}

.back-link:hover {
  color: var(--primary);
}

.table-of-contents h3 {
  margin: 0 0 12px;
  font-size: 1rem;
  font-weight: 700;
}

.table-of-contents ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.table-of-contents a {
  display: block;
  padding: 10px 12px;
  color: var(--muted);
  border-left: 4px solid transparent;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  border-radius: 6px;
  margin: 2px 0;
  cursor: pointer;
}

.table-of-contents a:hover {
  background-color: rgba(122, 80, 154, 0.05);
  color: var(--text);
}

.table-of-contents a.active {
  color: var(--primary);
  font-weight: 700;
  border-left-color: var(--primary);
  background-color: var(--bg-soft);
  padding-left: 10px;
  transform: translateX(2px);
}

.other-posts-title {
  font-size: 1.1rem;
  margin: 0 0 12px;
}

.other-posts-list a {
  display: block;
  padding: 10px 0;
  font-weight: 500;
  border-bottom: 1px solid #eee;
  line-height: 1.4;
}

.other-posts-list a:hover {
  color: var(--primary);
}

.post-header h1 {
  margin: 0 0 10px;
}

.post-meta {
  color: var(--muted);
  margin: 0 0 18px;
}

.post-cover {
  width: 100%;
  border-radius: 16px;
  object-fit: cover;
  max-height: 420px;
}

.post-content {
  margin-top: 22px;
  line-height: 1.75;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
  margin-top: 32px;
  margin-bottom: 16px;
  font-weight: 700;
  line-height: 1.4;
  color: var(--text);
}

.post-content h2 {
  font-size: 1.75rem;
  border-bottom: 2px solid var(--primary);
  padding-bottom: 8px;
  margin-top: 40px;
}

.post-content h3 {
  font-size: 1.5rem;
  color: var(--primary);
  margin-top: 32px;
}

.post-content h4 {
  font-size: 1.25rem;
}

.post-content img, 
.post-content video {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
  margin: 24px 0;
  display: block;
}

.post-content img {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Sidebar widgets */
.widget { background: #f7f7fb; border: 1px solid #eceaf5; border-radius: 12px; padding: 18px; margin-bottom: 18px; }
.widget-title { margin: 0 0 12px; font-size: 1rem; font-weight: 700; }

/* Services list */
.svc-list { list-style: none; margin: 0; padding: 0; }
.svc-list li { margin: 8px 0; }
.svc-list a { display: flex; align-items: center; gap: 12px; color: var(--text); padding: 10px 12px; border-radius: 8px; text-decoration: none; border: 1px solid transparent; }
.svc-list a::after { content: "→"; margin-left: auto; color: var(--muted); transition: transform .2s ease, color .2s ease; }
.svc-list a:hover { background: #fff; border-color: #eceaf5; color: var(--primary); }
.svc-list a:hover::after { transform: translateX(2px); color: var(--primary); }
.svc-list a.active { background: #fff; border-color: #d9cef0; color: var(--primary); font-weight: 600; }

/* CTA card */
.widget-cta { background: linear-gradient(140deg, #7a509a, #3d1e55); color: #fff; display: flex; align-items: center; gap: 12px; }
.widget-cta .cta-icon { width: 44px; height: 44px; border-radius: 50%; background: rgba(255,255,255,0.12); display: flex; align-items: center; justify-content: center; font-size: 18px; }
.widget-cta .cta-title { margin: 0 0 6px; opacity: 0.9; font-size: 0.95rem; }
.widget-cta .cta-phone { color: #fff; font-weight: 700; text-decoration: none; }
.widget-cta .cta-phone:hover { text-decoration: underline; }

/* Search */
.widget-search .search-box { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.widget-search input[type="search"] { padding: 10px 12px; border: 1px solid #e4e0f0; border-radius: 8px; outline: none; }
.btn-search { padding: 8px 12px; border: 1px solid #7a509a; color: #7a509a; background: #fff; border-radius: 8px; font-weight: 600; cursor: pointer; }
.btn-search:hover { background: rgba(122,80,154,0.06); }

/* Quote */
.widget-quote { background: #fff; border: 1px dashed #e4e0f0; }
.widget-quote p { margin: 6px 0; color: var(--muted); font-size: 0.95rem; }

/* Profile */
.widget-profile { display: flex; align-items: center; gap: 12px; }
.profile-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: #fff; border: 1px solid #eceaf5; }
.profile-info .profile-name { font-weight: 700; }
.profile-info .profile-role { color: var(--muted); font-size: 0.9rem; }

/* Optional check-list style inside content */
.post-content ul.check-list { list-style: none; padding-left: 0; }
.post-content ul.check-list li { position: relative; padding-left: 26px; margin: 8px 0; }
.post-content ul.check-list li::before { content: "✓"; position: absolute; left: 0; top: 0; color: #7a509a; font-weight: 700; }

@media (max-width: 1200px) {
  .post-layout {
    grid-template-columns: 200px 1fr;
  }
  .post-sidebar-right {
    display: none;
  }
}

@media (max-width: 992px) {
  .post-layout {
    grid-template-columns: 1fr;
  }
  .post-sidebar-left {
    display: none !important;
  }
  .back-link {
    display: inline-flex;
    position: absolute;
    top: -40px;
  }
  .post-main {
    position: relative;
  }
}

@media (min-width: 993px) {
  .post-sidebar-left {
    display: block !important;
  }
}

