/* ============================================================
   SERVICE.CSS — services/index.blade.php + services/show.blade.php
   Merged from style.css + responsive.css (only rules these two
   pages actually use). Self-contained: includes tokens, base and
   shared bits, so style.css / responsive.css links are no longer
   needed on these pages. Same design tokens as home.css/about.css.
   ============================================================ */

:root {
  --primary: #0b2544;
  --primary-dark: #071a33;
  --accent: #1455d9;
  --ivory: #faf9f5;
  --surface: #f6f8fb;
  --text: #1a2233;
  --text-soft: #3d4759;
  --muted: #6b7585;
  --border: #e6e9ef;
  --white: #ffffff;
  --bronze: #b08a4e;
  --success: #16825d;
  --shadow-sm: 0 4px 14px rgba(15,30,55,.05);
  --shadow-md: 0 10px 28px rgba(15,30,55,.08);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --container: 1200px;
  --header-height: 80px;
  --transition: 180ms ease;
}

/* ---------- Base / reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--text);
  background: var(--white);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
h1,h2,h3,h4,p { margin-top: 0; }
h1,h2,h3,h4 {
  color: var(--primary-dark);
  font-family: Inter, sans-serif;
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2.3rem, 4.6vw, 3.6rem); font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: clamp(1.7rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.1rem, 1.6vw, 1.3rem); }

.container { width: min(calc(100% - 40px), var(--container)); margin-inline: auto; }
.section { padding: clamp(56px, 7vw, 96px) 0; }
.section-sm { padding: clamp(36px, 5vw, 64px) 0; }

.sr-only {
  position:absolute !important;
  width:1px !important; height:1px !important;
  padding:0 !important; margin:-1px !important;
  overflow:hidden !important; clip:rect(0,0,0,0) !important;
  white-space:nowrap !important; border:0 !important;
}

/* ---------- Shared UI bits ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--accent); font-size: .74rem; line-height: 1;
  font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
}
.eyebrow::before { content:""; width: 20px; height: 1px; background: currentColor; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 46px; padding: 0 18px; border: 1px solid transparent;
  border-radius: var(--radius-sm); font-weight: 600; font-size: .95rem;
  transition: var(--transition);
}
.btn-primary { background: var(--accent); color: var(--white); }
.btn-primary:hover { background: #0d48be; }
.btn-secondary { border-color: var(--border); color: var(--primary); background: var(--white); }
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }
.text-link { display:inline-flex; align-items:center; gap:6px; color: var(--accent); font-weight: 600; font-size: .95rem; }
.text-link span { transition: transform var(--transition); }
.text-link:hover span { transform: translateX(3px); }
.hero-actions { display:flex; flex-wrap:wrap; gap:10px; margin-top:26px; }

/* ---------- Breadcrumb + page header (services index) ---------- */
.breadcrumb { display:flex; flex-wrap:wrap; gap:6px; color:var(--muted); font-size:.84rem; }
.breadcrumb a:hover { color:var(--accent); }

/* top padding includes the fixed site header height so the breadcrumb is not hidden behind it */
.page-hero { position:relative; overflow:hidden; padding:calc(var(--header-height) + 40px) 0 56px; background:var(--ivory); }
.page-hero::after {
  content:""; position:absolute; right:-80px; top:-160px; width:360px; height:360px;
  border:1px solid rgba(20,85,217,.10); border-radius:50%;
}
.page-hero h1 { max-width:900px; margin:16px 0 14px; }
.page-hero p { max-width:700px; color:var(--muted); font-size:1.02rem; }

/* ---------- Services index: search + filters ---------- */
.service-toolbar { display:grid; gap:16px; }
.service-search input {
  width:100%; min-height:50px; padding:0 16px;
  border:1px solid var(--border); border-radius:var(--radius-md);
  background:var(--white); color:var(--text); outline:none; transition:var(--transition);
}
.service-search input:focus { border-color:rgba(20,85,217,.5); box-shadow:0 0 0 3px rgba(20,85,217,.08); }

.service-filters { display:flex; flex-wrap:wrap; gap:8px; }
.filter-chip {
  min-height:38px; padding:0 14px; border:1px solid var(--border);
  border-radius:var(--radius-sm); background:var(--white);
  color:var(--text-soft); font-weight:600; font-size:.9rem; cursor:pointer; transition:var(--transition);
}
.filter-chip:hover,
.filter-chip.is-active { border-color:var(--accent); color:var(--accent); background:#f6f9ff; }

/* ---------- Services index: directory grid ---------- */
.service-directory-section { padding-top:32px; }
.service-directory-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; }
.service-list-card {
  position:relative; min-height:240px; display:flex; flex-direction:column;
  padding:24px; border:1px solid var(--border); border-radius:var(--radius-md);
  background:var(--white); transition:transform var(--transition), border-color var(--transition);
}
.service-list-card:hover { transform:translateY(-3px); border-color:var(--accent); }
.service-list-card[hidden] { display:none !important; }
.service-list-kicker,
.content-kicker,
.service-feature-kicker {
  display:block; color:var(--accent); font-size:.72rem; line-height:1.2;
  font-weight:700; letter-spacing:.1em; text-transform:uppercase;
}
.service-list-card h2 { margin:14px 0 10px; font-size:1.15rem; }
.service-list-card p { margin-bottom:22px; color:var(--muted); font-size:.92rem; }
.service-list-card .text-link { margin-top:auto; }

.empty-state {
  margin:32px 0 0; padding:22px; border:1px dashed var(--border);
  border-radius:var(--radius-md); text-align:center; color:var(--muted); background:var(--surface);
}

/* ---------- Service detail: hero ---------- */
.service-detail-hero { padding:calc(var(--header-height) + 32px) 0 52px; background:var(--ivory); }
.service-detail-hero-grid {
  display:grid; grid-template-columns:1.15fr .85fr; gap:48px;
  align-items:center; margin-top:28px;
}
.service-detail-hero h1 { margin:12px 0 14px; font-size:clamp(2rem,4vw,3rem); }
.service-detail-hero p { max-width:700px; color:var(--muted); font-size:1.02rem; }
.service-feature-panel {
  padding:26px; border:1px solid var(--border); border-radius:var(--radius-lg);
  background:var(--white); box-shadow:var(--shadow-sm);
}
.service-feature-panel ul { list-style:none; padding:0; margin:18px 0 0; display:grid; gap:12px; }
.service-feature-panel li { position:relative; padding-left:24px; color:var(--text-soft); }
.service-feature-panel li::before { content:"✓"; position:absolute; left:0; color:var(--success); font-weight:800; }

/* ---------- Service detail: layout + sidebar ---------- */
.service-detail-layout { display:grid; grid-template-columns:240px minmax(0,1fr); gap:56px; }
.service-sidebar-inner { position:sticky; top:calc(var(--header-height) + 24px); }
.service-sidebar-title {
  display:block; margin-bottom:12px; color:var(--primary-dark);
  font-size:.78rem; font-weight:700; letter-spacing:.06em; text-transform:uppercase;
}
.service-anchor-nav { display:grid; border-left:1px solid var(--border); }
.service-anchor-nav a {
  padding:8px 0 8px 16px; color:var(--muted); font-size:.9rem; font-weight:600;
  border-left:2px solid transparent; margin-left:-1px; transition:var(--transition);
}
.service-anchor-nav a:hover,
.service-anchor-nav a.is-active { color:var(--accent); border-left-color:var(--accent); }
.service-sidebar-cta { width:100%; margin-top:20px; }

/* ---------- Service detail: content sections ---------- */
.service-section {
  scroll-margin-top:calc(var(--header-height) + 24px);
  padding:0 0 56px; margin-bottom:56px; border-bottom:1px solid var(--border);
}
.service-section:last-of-type { border-bottom:0; }
.service-section h2 { margin:10px 0 18px; font-size:clamp(1.5rem,2.6vw,2.1rem); }

.rich-copy { color:var(--text-soft); }
.rich-copy p,
.rich-copy li { color:var(--muted); }
.rich-copy > * + * { margin-top:16px; }
/* extra safety for rich text coming from the database */
.rich-copy > ul:not(.document-list),
.rich-copy > ol { padding-left:22px; }
.rich-copy h2,
.rich-copy h3 { color:var(--primary-dark); }
.rich-copy a { color:var(--accent); font-weight:600; }

.requirement-grid { display:grid; grid-template-columns:repeat(2,1fr); gap:14px; }
.requirement-card {
  padding:22px; border:1px solid var(--border);
  border-radius:var(--radius-md); background:var(--surface);
}
.requirement-card strong { display:block; color:var(--bronze); margin-bottom:18px; font-size:.78rem; }
.requirement-card h3 { margin-bottom:8px; font-size:1.05rem; }
.requirement-card p { margin:0; color:var(--muted); font-size:.9rem; }

.document-list { display:grid; gap:10px; padding:0; list-style:none; }
.document-list li {
  position:relative; padding:14px 14px 14px 40px;
  border:1px solid var(--border); border-radius:var(--radius-sm); background:var(--white);
}
.document-list li::before {
  content:""; position:absolute; left:16px; top:22px;
  width:9px; height:9px; border-radius:3px; background:var(--accent);
}

.vertical-process { display:grid; }
.vertical-process article {
  position:relative; display:grid; grid-template-columns:56px 1fr; gap:16px; padding-bottom:24px;
}
.vertical-process article::before {
  content:""; position:absolute; left:22px; top:46px; bottom:0; width:1px; background:var(--border);
}
.vertical-process article:last-child::before { display:none; }
.vertical-process article > span {
  width:46px; height:46px; display:grid; place-items:center; border-radius:50%;
  color:var(--accent); background:#eef4ff; font-size:.78rem; font-weight:700;
}
.vertical-process h3 { margin:2px 0 6px; font-size:1.08rem; }
.vertical-process p { margin:0; color:var(--muted); font-size:.92rem; }

.service-callout {
  padding:22px; border-left:4px solid var(--accent);
  border-radius:0 var(--radius-md) var(--radius-md) 0; background:#f6f9ff;
}
.service-callout p { margin:0; color:var(--text-soft); }

.why-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:14px; }
.why-card { padding:24px; border:1px solid var(--border); border-radius:var(--radius-md); background:var(--white); }
.why-card strong { display:block; margin-bottom:6px; color:var(--primary-dark); font-size:1rem; }
.why-card p { margin:0; color:var(--muted); font-size:.9rem; }

.faq-list { display:grid; gap:10px; }
.faq-item { border:1px solid var(--border); border-radius:var(--radius-md); overflow:hidden; background:var(--white); }
.faq-item h3 { margin:0; font-size:1rem; }
.faq-item button {
  width:100%; display:flex; justify-content:space-between; align-items:center;
  padding:16px 18px; border:0; background:none; text-align:left; font-weight:600; cursor:pointer;
}
.faq-answer { padding:0 18px 18px; }
.faq-answer p { margin:0; color:var(--muted); }

.service-final-cta {
  display:grid; grid-template-columns:1fr auto; gap:20px; align-items:center;
  padding:30px; border-radius:var(--radius-lg); background:var(--ivory);
}
.service-final-cta h2 { margin:10px 0; font-size:clamp(1.5rem,2.8vw,2.1rem); }
.service-final-cta p { margin:0; color:var(--muted); }

/* ---------- Related programs (show page) ---------- */
.cert-section--gray { background:var(--surface); }

/* ---------- CTA panel (index page) ---------- */
.cta-panel {
  display:grid; grid-template-columns:1fr auto; align-items:center; gap:24px;
  padding:clamp(28px,5vw,52px); border-radius:var(--radius-lg); color:var(--white);
  background:var(--primary-dark);
}
.cta-panel h2 { color:var(--white); margin:8px 0; max-width:720px; }
.cta-panel p { margin:0; color:rgba(255,255,255,.68); }

/* ---------- Focus / reduced motion ---------- */
:focus-visible { outline:2px solid rgba(20,85,217,.4); outline-offset:2px; }

@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { scroll-behavior:auto !important; animation-duration:.01ms !important; transition-duration:.01ms !important; }
}

/* ============================================================
   Responsive — only rules that touch classes used above
   ============================================================ */

@media (max-width: 1080px) {
  .service-directory-grid { grid-template-columns:repeat(2,1fr); }
  .service-detail-layout { grid-template-columns:1fr; gap:32px; }
  .service-sidebar-inner { position:static; }
  .service-anchor-nav {
    display:flex; overflow-x:auto; border-left:0;
    border-bottom:1px solid var(--border); gap:4px; padding-bottom:8px;
  }
  .service-anchor-nav a {
    white-space:nowrap; border-left:0; border-bottom:2px solid transparent; padding:9px 10px;
  }
  .service-anchor-nav a:hover,
  .service-anchor-nav a.is-active { border-left-color:transparent; border-bottom-color:var(--accent); }
  .service-sidebar-cta { width:auto; }
}

@media (max-width: 920px) {
  :root { --header-height:74px; }
  .why-grid { grid-template-columns:repeat(2,1fr); }
  .cta-panel { grid-template-columns:1fr; }
}

@media (max-width: 820px) {
  .service-detail-hero-grid { grid-template-columns:1fr; gap:30px; }
  .service-feature-panel { max-width:680px; }
  .service-final-cta { grid-template-columns:1fr; }
  .requirement-grid { grid-template-columns:1fr; }
}

@media (max-width: 640px) {
  .container { width:min(calc(100% - 28px), var(--container)); }
  .section { padding:56px 0; }
  .service-directory-section { padding-top:32px; }
  h1 { font-size:clamp(2.1rem,10vw,3rem); }
  h2 { font-size:clamp(1.6rem,8vw,2.1rem); }

  .hero-actions { display:grid; grid-template-columns:1fr; }
  .hero-actions .btn { width:100%; }
  .page-hero { padding:calc(var(--header-height) + 28px) 0 40px; }

  .service-directory-grid { grid-template-columns:1fr; }
  .service-list-card { min-height:unset; }
  .service-detail-hero { padding:calc(var(--header-height) + 24px) 0 40px; }
  .service-detail-main { padding-top:40px; }
  .service-section { padding-bottom:40px; margin-bottom:40px; }
  .why-grid { grid-template-columns:1fr; }
}