/*
 * Shared site components (homepage and service pages). Load after type-system.css.
 * Header, layout primitives, section headings, buttons, trust grid, How It Works, FAQ.
 */
/* Homepage components. Loaded only on index.html, after type-system.css.
   Typography and spacing come from the tokens in type-system.css. */
.ccx { --ccx-navy: #0E2A4F; --ccx-navy-dark: #0A1F3B; --ccx-ink: #0F1B2D; --ccx-muted: #4A5568; --ccx-line: #E3E8EF; --ccx-tint: #F3F6FA; --ccx-soft: #C9D5E6; --ccx-pale: #E6ECF5; --ccx-yellow: #FFC72C; --ccx-blue: #1F5FD1; color: var(--ccx-ink); }
.ccx *, .ccx *::before, .ccx *::after { box-sizing: border-box; }
.ccx a { color: var(--ccx-blue); }
.ccx a:hover { color: var(--ccx-navy); }
.ccx ul, .ccx ol { margin: 0; padding: 0; list-style: none; }
.ccx img { display: block; max-width: 100%; }
.ccx a:focus-visible, .ccx button:focus-visible, .ccx summary:focus-visible, .ccx select:focus-visible, .ccx input:focus-visible { outline: 3px solid var(--ccx-blue); outline-offset: 2px; }

/* Layout primitives */
.ccx-wrap { max-width: 1280px; margin: 0 auto; padding: 0 var(--space-lg); }
.ccx-wrap--narrow { max-width: 820px; }
.ccx-stack { display: flex; flex-direction: column; gap: var(--space-head); }
.ccx-center { text-align: center; }
.ccx-section { padding: var(--space-section) 0; background: #fff; }
.ccx-section--tint { background: var(--ccx-tint); }
.ccx-section--compact { padding: var(--space-section-sm) 0; }

/* Section heading block: eyebrow → heading → intro */
.ccx-head { display: flex; flex-direction: column; gap: var(--space-sm); }
.ccx-head.ccx-center { max-width: 680px; margin: 0 auto; align-items: center; }
.ccx-head--split { flex-direction: row; flex-wrap: wrap; gap: var(--space-md) var(--space-2xl); justify-content: space-between; align-items: flex-end; }
.ccx-head--split > div { display: flex; flex-direction: column; gap: var(--space-sm); max-width: 640px; }
.ccx-eyebrow { margin: 0; font-size: var(--fs-eyebrow); font-weight: var(--fw-semibold); letter-spacing: var(--ls-eyebrow); line-height: 1.4; text-transform: uppercase; color: var(--ccx-blue); }
.ccx-eyebrow--yellow { color: var(--ccx-yellow); }
.ccx-h2 { font-size: var(--fs-h2); color: inherit; }
.ccx-intro { font-size: var(--fs-body); color: var(--ccx-muted); max-width: var(--measure); }
.ccx-yellow { color: var(--ccx-yellow); }
.ccx-muted { color: var(--ccx-muted); font-size: var(--fs-small); }
.ccx-muted a { font-weight: var(--fw-semibold); }
.ccx-textlink { font-weight: var(--fw-semibold); font-size: var(--fs-small); }

/* Buttons */
.ccx-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-xs); min-height: 46px; padding: 12px 22px; border-radius: 10px; font-size: var(--fs-btn); font-weight: var(--fw-semibold); line-height: 1.2; text-decoration: none !important; text-align: center; }
.ccx a.ccx-btn--yellow { background: var(--ccx-yellow); color: var(--ccx-navy-dark); font-weight: var(--fw-semibold); }
.ccx a.ccx-btn--yellow:hover { background: #f2b800; color: var(--ccx-navy-dark); }
.ccx a.ccx-btn--ghost { color: #fff; border: 1px solid rgba(255, 255, 255, .35); }
.ccx a.ccx-btn--ghost:hover { color: #fff; border-color: #fff; }

/* Mobile drawer (shared navigation; outside .ccx, so it is set here instead of inheriting the legacy theme font) */
.mobile-drawer, .mobile-drawer button { font-family: Inter, system-ui, -apple-system, 'Segoe UI', sans-serif; }
.mobile-drawer .mobile-section-title, .mobile-drawer .mobile-link, .mobile-drawer .mobile-accordion, .mobile-drawer .mobile-sublink, .mobile-drawer .mobile-subheading, .mobile-drawer .mobile-cta { font-weight: 600; }

/* Header */
.ccx-header { position: relative; z-index: 50; }
.ccx-utility { background: var(--ccx-navy-dark); color: var(--ccx-pale); font-size: var(--fs-xs); }
.ccx-utility__inner { display: flex; flex-wrap: wrap; gap: var(--space-xs) var(--space-lg); justify-content: space-between; align-items: center; padding-top: 9px; padding-bottom: 9px; }
.ccx-utility__item { display: flex; align-items: center; gap: var(--space-xs); }
.ccx-utility__contact { flex-wrap: wrap; gap: var(--space-xs) var(--space-lg); }
.ccx .ccx-utility a { color: #fff; font-weight: var(--fw-semibold); text-decoration: none; }
.ccx-bar { background: #fff; border-bottom: 1px solid var(--ccx-line); }
.ccx-bar__inner { display: flex; gap: var(--space-md) var(--space-xl); align-items: center; justify-content: space-between; padding-top: 14px; padding-bottom: 14px; }
.ccx-logo img { width: auto; height: 44px; }
.ccx-nav { display: flex; flex-wrap: wrap; gap: var(--space-2xs) 26px; font-size: var(--fs-nav); font-weight: var(--fw-medium); }
.ccx .ccx-nav a { color: var(--ccx-ink); text-decoration: none; padding: 10px 0; }
.ccx .ccx-nav a:hover { color: var(--ccx-blue); }
/* Nav dropdowns: hover opens a menu on devices with a mouse; the chevron button toggles it
   (.is-open) for keyboard and touch. The script lives with the mobile menu script in index.html. */
.ccx-nav { align-items: center; }
.ccx-nav__item { position: relative; display: flex; align-items: center; gap: 2px; }
.ccx .ccx-nav a[aria-current="page"] { color: var(--ccx-blue); }
.ccx .ccx-nav__toggle { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 30px; padding: 0; border: 0; border-radius: 6px; background: none; color: var(--ccx-muted); cursor: pointer; }
.ccx-nav__toggle svg { transition: transform .15s ease; }
.ccx-nav__item.is-open .ccx-nav__toggle svg { transform: rotate(180deg); }
.ccx .ccx-nav__toggle:focus-visible { outline: 2px solid var(--ccx-blue); outline-offset: 1px; }
.ccx-nav__menu { display: none; position: absolute; top: calc(100% + 8px); left: -14px; z-index: 60; min-width: 250px; padding: 8px; border: 1px solid var(--ccx-line); border-radius: 14px; background: #fff; box-shadow: 0 18px 40px -18px rgba(14, 42, 79, .35); }
.ccx-nav__menu::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; } /* hover bridge */
.ccx-nav__item.is-open > .ccx-nav__menu { display: block; }
@media (hover: hover) {
  .ccx-nav__item:hover > .ccx-nav__menu { display: block; }
  .ccx-nav__item:hover .ccx-nav__toggle svg { transform: rotate(180deg); }
}
.ccx .ccx-nav__menu a { display: block; padding: 9px 12px; border-radius: 8px; font-size: var(--fs-small); line-height: 1.35; white-space: nowrap; color: var(--ccx-ink); }
.ccx .ccx-nav__menu a:hover { background: var(--ccx-tint); color: var(--ccx-blue); }
.ccx .ccx-nav__menu .ccx-nav__all { margin-top: 6px; border-top: 1px solid var(--ccx-line); border-radius: 0 0 8px 8px; padding-top: 11px; font-weight: var(--fw-semibold); color: var(--ccx-blue); }
@media (prefers-reduced-motion: reduce) { .ccx-nav__toggle svg { transition: none; } }
.ccx-menu-btn { display: none; flex-direction: column; justify-content: center; gap: 5px; width: 46px; height: 46px; padding: 11px; border: 1px solid var(--ccx-line); border-radius: 10px; background: #fff; cursor: pointer; }
.ccx-menu-btn span { display: block; height: 2px; border-radius: 2px; background: var(--ccx-navy); }

/* Why choose us: six commitments, 3 x 2 grid with hairline dividers */
.ccx-underline { position: relative; display: inline-block; white-space: nowrap; }
.ccx-underline svg { position: absolute; left: 0; right: 0; bottom: -0.2em; width: 100%; height: 0.32em; overflow: visible; }
.ccx-why { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ccx-why li { position: relative; display: flex; align-items: flex-start; gap: 18px; padding: 24px 28px; }
.ccx-why li:nth-child(n+4) { border-top: 1px solid var(--ccx-line); }
.ccx-why li:not(:nth-child(3n+1))::before { content: ""; position: absolute; left: 0; top: 24px; bottom: 24px; width: 1px; background: var(--ccx-line); }
.ccx-why li:nth-child(3n+1) { padding-left: 0; }
.ccx-why__icon { width: 56px; height: 56px; flex-shrink: 0; border-radius: 14px; background: #EEF3FA; display: flex; align-items: center; justify-content: center; }
.ccx-why li > div { display: flex; flex-direction: column; gap: 6px; padding-top: 4px; }
.ccx .ccx-why h3 { font-size: var(--fs-card); line-height: var(--lh-snug); letter-spacing: 0; color: var(--ccx-ink); }
.ccx-why p { font-size: var(--fs-small); color: var(--ccx-muted); max-width: 32ch; }

/* Steps */
.ccx-visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.ccx-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px; }
.ccx-steps li { position: relative; display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 28px 28px 30px; border-radius: 20px; background: #fff; border: 1px solid var(--ccx-line); }
.ccx-steps li:not(:last-child)::after { content: ""; position: absolute; top: 50%; right: -33px; width: 26px; height: 26px; margin-top: -13px; border-radius: 999px; background: #E3ECFA url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231F5FD1' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E") center / 14px no-repeat; }
.ccx-step__top { display: flex; align-items: center; gap: var(--space-md); margin-bottom: var(--space-sm); }
.ccx-step__num { width: 52px; height: 52px; flex-shrink: 0; border-radius: 999px; background: var(--ccx-navy); color: #fff; font-family: var(--font-display); font-weight: var(--fw-display); font-size: var(--fs-h3); display: flex; align-items: center; justify-content: center; }
.ccx-step__num--yellow { background: var(--ccx-yellow); color: var(--ccx-navy-dark); }
.ccx-step__icon { width: 52px; height: 52px; border-radius: 14px; background: #EEF3FA; display: flex; align-items: center; justify-content: center; }
.ccx .ccx-steps h3 { font-size: var(--fs-card); line-height: var(--lh-snug); letter-spacing: 0; }
.ccx-steps p { color: var(--ccx-muted); font-size: var(--fs-small); }

/* FAQ */
.ccx-faq { display: flex; flex-direction: column; gap: 10px; }
.ccx-faq details { background: #fff; border-radius: 14px; border: 1px solid var(--ccx-line); }
.ccx-faq summary { padding: 18px 22px; font-size: var(--fs-body); font-weight: var(--fw-semibold); line-height: var(--lh-snug); cursor: pointer; }
.ccx-faq details p { padding: 0 22px 20px; font-size: var(--fs-small); color: var(--ccx-muted); max-width: var(--measure); }
/* Narrow desktops: a slightly smaller logo and tighter links keep the nav on one line. */
@media (max-width: 1279.98px) {
  .ccx-nav { gap: var(--space-2xs) 20px; }
  .ccx-logo img { height: 40px; }
}
/* Below 1200px the header uses the menu button and drawer (the dropdown nav no longer fits). */
@media (max-width: 1199.98px) {
  .ccx-nav, .ccx-bar__cta { display: none; }
  .ccx-menu-btn { display: flex; }
}
@media (max-width: 991.98px) {
  .ccx :is(.ccx-checks, .svc-hero__trust) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 420px;
    gap: var(--space-sm);
    align-items: start;
    font-size: var(--fs-xs);
    line-height: var(--lh-snug);
  }

  .ccx :is(.ccx-checks, .svc-hero__trust) > li { align-items: flex-start; gap: 6px; }
  .ccx :is(.ccx-checks, .svc-hero__trust) svg { flex-shrink: 0; }
  .ccx :is(.ccx-checks, .svc-hero__trust) > li:nth-child(n + 3) { display: none; }

  .ccx-steps { grid-template-columns: minmax(0, 1fr); max-width: 640px; margin: 0 auto; width: 100%; }

  .ccx-steps { gap: var(--space-md); }

  .ccx-steps li:not(:last-child)::after { content: none; }

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

  .ccx-why li, .ccx-why li:nth-child(3n+1) { padding: 22px 24px; }

  .ccx-why li:nth-child(odd) { padding-left: 0; }

  .ccx-why li:nth-child(n+4) { border-top: 0; }

  .ccx-why li:nth-child(n+3) { border-top: 1px solid var(--ccx-line); }

  .ccx-why li:not(:nth-child(3n+1))::before { content: none; }

  .ccx-why li:nth-child(even)::before { content: ""; position: absolute; left: 0; top: 22px; bottom: 22px; width: 1px; background: var(--ccx-line); }

}
@media (max-width: 767.98px) {
  .ccx-wrap { padding: 0 var(--space-md); }

  .ccx :is(.ccx-hero__title, .svc-hero__title) { text-wrap: balance; overflow-wrap: anywhere; }

  .ccx :is(.ccx-hero__lead, .svc-hero__lead) { line-height: 1.5; }

  .ccx-utility__inner { justify-content: center; text-align: center; }

  .ccx-utility__item:first-child { display: none; }

  .ccx-logo img { height: 38px; }

  .ccx-why { grid-template-columns: minmax(0, 1fr); }

  .ccx-why li, .ccx-why li:nth-child(odd), .ccx-why li:nth-child(3n+1) { padding: 18px 0; }

  .ccx-why li:nth-child(n+2) { border-top: 1px solid var(--ccx-line); }

  .ccx-why li:nth-child(even)::before { content: none; }

  .ccx-why__icon { width: 48px; height: 48px; }

  .ccx-why p { max-width: none; }

  .ccx-steps li { padding: 22px 20px; }

  .ccx-step__num, .ccx-step__icon { width: 46px; height: 46px; }

}
