/* Cyfork Solutions – public site styles */
:root {
  --ink: #141B3A;          /* deep navy */
  --ink-soft: #3D4566;
  --stone: #5B6280;
  --paper: #F5F6FB;
  --white: #FFFFFF;
  --line: #DEE2EE;
  --blue: #2350D8;         /* primary */
  --blue-dark: #1A3BA6;
  --purple: #7C3AED;       /* accent */
  --purple-dark: #6427D0;
  --purple-light: #B9A2FF; /* accent on dark backgrounds */
  --tint: #ECEEFD;         /* soft blue-lilac background */
  --radius-lg: 18px;
  --radius-sm: 8px;
  --display: 'Bricolage Grotesque', 'Segoe UI', system-ui, sans-serif;
  --body: 'Figtree', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --receipt: 'Courier New', ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }

body {
  margin: 0;
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
a:hover { color: var(--blue-dark); }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--display); line-height: 1.08; letter-spacing: -0.02em; margin: 0; }
h1 { font-size: clamp(2.4rem, 5.4vw, 4.25rem); font-weight: 800; }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.75rem); font-weight: 700; }
h3 { font-size: 1.3rem; font-weight: 700; letter-spacing: -0.01em; }
p { margin: 0; }

.wrap { width: min(1180px, 100% - 48px); margin-inline: auto; }
.prose { max-width: 66ch; }
.lead { font-size: 1.2rem; color: var(--ink-soft); max-width: 60ch; }
.muted { color: var(--stone); }

.skip-link { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 10px 16px; z-index: 100; border-radius: var(--radius-sm); }
.skip-link:focus { left: 8px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 12px 22px; border-radius: var(--radius-sm);
  font: 600 1rem/1.2 var(--body); text-decoration: none; cursor: pointer;
  border: 2px solid transparent; transition: background-color .15s, color .15s;
}
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-dark); color: #fff; }
.btn-outline { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); color: #fff; }
.btn-accent { background: var(--purple); color: #fff; }
.btn-accent:hover { background: var(--purple-dark); color: #fff; }
.btn-small { min-height: 42px; padding: 9px 16px; font-size: .95rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Header */
.site-header { background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; align-self: stretch; justify-content: space-between; gap: 16px; min-height: 76px; }
.brand { white-space: nowrap; display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-family: var(--display); font-weight: 800; font-size: 1.35rem; letter-spacing: -0.02em; }
.brand em { font-style: normal; font-weight: 600; color: var(--stone); }
.brand-mark { width: 38px; height: 38px; }
.site-nav { display: flex; align-items: center; }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 8px; }
.nav-link, .menu-btn {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 12px;
  color: var(--ink-soft); text-decoration: none; font: 500 1rem var(--body);
  background: none; border: 0; cursor: pointer; border-bottom: 3px solid transparent;
}
.menu-btn::after { content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform .15s; }
.menu-btn[aria-expanded="true"]::after { transform: rotate(-135deg) translateY(-1px); }
.nav-link:hover, .menu-btn:hover, .nav-link[aria-current="page"], .is-current > .menu-btn, .menu-btn[aria-expanded="true"] { color: var(--ink); border-bottom-color: var(--purple); }
.nav-cta { margin-left: 12px; }
.nav-toggle { display: none; font: 600 1rem var(--body); background: none; border: 2px solid var(--ink); color: var(--ink); border-radius: var(--radius-sm); min-height: 44px; padding: 0 16px; cursor: pointer; }

/* Mega menu panels */
.mega { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); box-shadow: 0 24px 40px -24px rgba(20,27,58,.35); }
.has-menu.is-open > .mega { display: block; }
.mega-inner { display: grid; grid-template-columns: 1fr 340px; gap: 48px; padding-block: 32px 36px; }
.mega-title { font-family: var(--display); font-weight: 700; font-size: 1.3rem; margin-bottom: 14px; }
.mega-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 32px; }
.mega-links a { display: block; padding: 9px 0; color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line); }
.mega-links a:hover, .mega-links a[aria-current="page"] { color: var(--blue); }
.mega-all { display: inline-block; margin-top: 18px; font-weight: 600; }
.mega-feature { background: var(--ink); color: #C7CCE6; border-radius: var(--radius-lg); padding: 26px; display: grid; gap: 10px; align-content: start; }
.mega-kicker { color: var(--purple-light); font-weight: 600; font-size: .92rem; }
.mega-feature-title { color: #fff; font-family: var(--display); font-weight: 700; font-size: 1.35rem; line-height: 1.15; }
.mega-feature .btn { justify-self: start; margin-top: 6px; }
@media (min-width: 1001px) {
  /* Menu items fill the header height so the pointer can travel to the panel without it closing */
  .site-nav, .nav-list, .nav-list > li { align-self: stretch; }
  .nav-list > li { display: flex; align-items: center; }
  .nav-link, .menu-btn { height: 100%; }
}
@media (hover: hover) and (min-width: 1001px) {
  .has-menu:hover > .mega { display: block; }
}

@media (max-width: 420px) { .brand { font-size: 1.15rem; } }
@media (max-width: 1000px) {
  .nav-toggle { display: inline-flex; align-items: center; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--white); border-bottom: 1px solid var(--line); padding: 8px 24px 24px; max-height: calc(100vh - 76px); overflow-y: auto; }
  .site-nav.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-link, .menu-btn { width: 100%; justify-content: space-between; padding: 14px 0; border-bottom: 1px solid var(--line); min-height: 52px; }
  .nav-link:hover, .menu-btn:hover, .nav-link[aria-current="page"], .is-current > .menu-btn, .menu-btn[aria-expanded="true"] { border-bottom-color: var(--line); }
  .mega { position: static; box-shadow: none; border: 0; }
  .mega-inner { grid-template-columns: 1fr; padding: 4px 0 12px; width: 100%; }
  .mega-feature { display: none; }
  .mega-title { font-family: var(--body); font-size: .85rem; font-weight: 600; color: var(--stone); margin: 14px 0 0 14px; }
  .mega-links { grid-template-columns: 1fr; }
  .mega-links a { padding: 12px 0 12px 14px; }
  .nav-cta { margin: 18px 0 0; }
  .nav-cta .btn { width: 100%; }
}

/* Breadcrumbs */
.breadcrumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; font-size: .95rem; color: var(--stone); }
.breadcrumbs li + li::before { content: "/"; margin-right: 6px; color: #A3A9C4; }
.breadcrumbs a { color: var(--stone); }
.breadcrumbs a:hover { color: var(--blue); }
.breadcrumbs [aria-current] { color: var(--ink); font-weight: 500; }

/* Sticky in-page navigation on service pages */
.subnav { position: sticky; top: 76px; z-index: 40; background: var(--ink); color: #fff; }
.subnav-inner { display: flex; align-items: center; gap: 24px; min-height: 64px; }
.subnav-title { font-family: var(--display); font-weight: 700; font-size: 1.15rem; white-space: nowrap; margin-right: auto; }
.subnav-links { position: relative; list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.subnav-links::-webkit-scrollbar { display: none; }
.subnav-links a { display: block; white-space: nowrap; color: #C7CCE6; text-decoration: none; padding: 20px 12px; border-bottom: 3px solid transparent; }
.subnav-links a:hover, .subnav-links a[aria-current="true"] { color: #fff; border-bottom-color: var(--purple-light); }
.subnav-cta { white-space: nowrap; background: var(--purple); color: #fff; text-decoration: none; font-weight: 600; padding: 10px 18px; border-radius: 999px; min-height: 44px; display: inline-flex; align-items: center; }
.subnav-cta:hover { background: var(--purple-dark); color: #fff; }
[id] { scroll-margin-top: 150px; }
@media (max-width: 1000px) {
  .subnav-title { display: none; }
  .subnav-inner { gap: 12px; min-height: 56px; }
  .subnav-links { flex: 1; }
  .subnav-links a { padding: 16px 10px; }
}

/* Capabilities grid */
.capability-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.capability-grid li { background: var(--paper); border-radius: var(--radius-sm); padding: 20px 20px 20px 50px; position: relative; font-weight: 500; }
.capability-grid li::before { content: ""; position: absolute; left: 22px; top: 1.55em; width: 12px; height: 7px; border-left: 2.5px solid var(--blue); border-bottom: 2.5px solid var(--blue); transform: rotate(-45deg); }

/* Link grid (services listing and "more services") */
.link-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 0; border-top: 1px solid var(--line); }
.link-grid a { display: grid; gap: 6px; padding: 22px 4px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); height: 100%; }
.link-grid li:nth-child(odd) a { padding-right: 28px; }
.link-grid strong { font-family: var(--display); font-size: 1.2rem; }
.link-grid span { color: var(--ink-soft); }
.link-grid a:hover strong { color: var(--blue); text-decoration: underline; text-underline-offset: 4px; }
.link-grid-large { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); column-gap: 40px; }
.link-grid-large strong { font-size: 1.45rem; }
.system-link { text-decoration: none; color: var(--ink); }
.system-link:hover { border-color: var(--blue); color: var(--ink); }
.system-link:hover h3 { color: var(--blue); }

/* Footer action cards */
.action-cards { background: var(--paper); border-top: 1px solid var(--line); padding-block: 56px; }
.action-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.action-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; display: grid; gap: 14px; align-content: start; }
.action-card h2 { font-size: 1.45rem; }
.action-card p { color: var(--ink-soft); }
.action-card .btn { justify-self: start; }
.action-card-primary { background: linear-gradient(135deg, var(--blue) 0%, var(--purple) 100%); border-color: transparent; }
.action-card-primary h2 { color: #fff; }
.action-card-primary p { color: #DCE3FF; }
.subscribe-form { display: flex; flex-wrap: wrap; gap: 10px; }
.subscribe-form input[type=email] { flex: 1 1 180px; font: inherit; min-height: 44px; padding: 10px 12px; border: 1.5px solid #C3C8DA; border-radius: var(--radius-sm); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Sections */
.section { padding-block: clamp(64px, 9vw, 112px); }
.section-white { background: var(--white); }
.section-ink { background: var(--ink); color: #fff; }
.section-mist { background: var(--tint); }
.section-head { display: grid; gap: 14px; margin-bottom: 44px; max-width: 760px; }
.section-ink .lead { color: #C7CCE6; }

/* Hero */
.hero { background: var(--white); padding-block: clamp(56px, 8vw, 104px); border-bottom: 1px solid var(--line); }
.hero-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.hero-copy { display: grid; gap: 26px; }
.hero-place { font-weight: 600; color: var(--blue); }
.hero-proof { font-size: .95rem; color: var(--stone); }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

/* The receipt: the one signature element */
.receipt-stage { display: flex; justify-content: center; }
.receipt {
  width: min(340px, 100%);
  background: #FFFEFA;
  font-family: var(--receipt);
  font-size: .9rem;
  line-height: 1.5;
  color: #2a2a2a;
  padding: 26px 24px 30px;
  box-shadow: 0 1px 0 #e6e3da, 0 22px 40px -18px rgba(20, 27, 58, .35);
  transform: rotate(1.5deg);
  position: relative;
  -webkit-mask: radial-gradient(circle 7px at 50% 100%, transparent 6.5px, #000 7px) 0 0 / 18px 100% repeat-x;
          mask: radial-gradient(circle 7px at 50% 100%, transparent 6.5px, #000 7px) 0 0 / 18px 100% repeat-x;
  padding-bottom: 38px;
}
.receipt-title { text-align: center; font-weight: 700; font-size: 1rem; }
.receipt-sub { text-align: center; color: #666; margin-bottom: 14px; }
.receipt-row { display: flex; justify-content: space-between; gap: 12px; }
.receipt-rule { border: 0; border-top: 1.5px dashed #b9b6ad; margin: 12px 0; }
.receipt-total { font-weight: 700; font-size: 1.05rem; }
.receipt-ok { color: #1A7A4C; font-weight: 700; }
.receipt-foot { text-align: center; margin-top: 14px; color: #666; font-size: .82rem; }
@media (prefers-reduced-motion: no-preference) {
  .receipt { animation: print .9s cubic-bezier(.2,.7,.2,1) both; }
  @keyframes print { from { clip-path: inset(0 0 100% 0); } to { clip-path: inset(0 0 0 0); } }
}

/* Service list */
.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.service-item { padding: 30px 28px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--white); display: grid; gap: 10px; align-content: start; }
.service-item p { color: var(--ink-soft); }
.service-item a { font-weight: 600; }

/* Detail blocks (services page) */
.detail { display: grid; grid-template-columns: 1fr 1.4fr; gap: clamp(24px, 5vw, 64px); padding-block: 48px; border-top: 1px solid var(--line); }
.detail:first-child { border-top: 0; padding-top: 0; }
.detail-body { display: grid; gap: 18px; }
.tick-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.tick-list li { padding-left: 28px; position: relative; }
.tick-list li::before { content: ""; position: absolute; left: 2px; top: .45em; width: 12px; height: 7px; border-left: 2.5px solid var(--blue); border-bottom: 2.5px solid var(--blue); transform: rotate(-45deg); }
.section-ink .tick-list li::before { border-color: var(--purple-light); }
@media (max-width: 760px) { .detail { grid-template-columns: 1fr; } }

/* Compliance band */
.split { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.panel-dark { background: #1F2850; border-radius: var(--radius-lg); padding: 28px; display: grid; gap: 18px; }
.panel-dark h3 { color: #fff; font-size: 1.15rem; }
.panel-dark p { color: #B8BEDC; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

/* Systems */
.system-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 22px; }
.system { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 30px; display: grid; gap: 14px; align-content: start; }
.system-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.status { display: inline-block; font-size: .85rem; font-weight: 600; padding: 4px 12px; border-radius: 999px; background: var(--tint); color: var(--blue-dark); }
.status-available { background: var(--blue); color: #fff; }
.status-pilot { background: #EDE4FF; color: #5221B0; }
.system .audience { font-size: .95rem; color: var(--stone); }

/* Steps (a real sequence, so numbered) */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 28px; counter-reset: step; list-style: none; padding: 0; margin: 0; }
.steps li { display: grid; gap: 10px; counter-increment: step; }
.steps li::before { content: counter(step); font-family: var(--display); font-weight: 800; font-size: 2.6rem; line-height: 1; color: var(--purple); }
.steps p { color: var(--ink-soft); }

/* Sectors */
.sectors { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 0; margin: 28px 0 0; }
.sectors li { background: var(--white); border: 1px solid var(--line); border-radius: 999px; padding: 8px 16px; font-size: .97rem; }

/* People */
.people { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 22px; }
.person { background: var(--white); border-radius: var(--radius-lg); padding: 28px; display: grid; gap: 8px; }
.person .role { color: var(--blue); font-weight: 600; }

/* Facts table */
.facts { width: 100%; border-collapse: collapse; background: var(--white); border-radius: var(--radius-lg); overflow: hidden; }
.facts th, .facts td { text-align: left; padding: 14px 20px; border-bottom: 1px solid var(--line); vertical-align: top; }
.facts th { width: 40%; color: var(--stone); font-weight: 500; }
.facts tr:last-child th, .facts tr:last-child td { border-bottom: 0; }

/* CTA band */
.cta-band { background: var(--blue); color: #fff; }
.cta-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-block: 56px; }
.cta-inner p { color: #DCE3FF; margin-top: 8px; }

/* Forms */
.contact-grid { display: grid; grid-template-columns: 1fr 1.5fr; gap: clamp(32px, 6vw, 72px); align-items: start; }
.contact-list { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 20px; }
.contact-list span { display: block; font-size: .9rem; color: var(--stone); }
.contact-list a, .contact-list strong { font-weight: 600; font-size: 1.1rem; }
.form-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(22px, 4vw, 36px); display: grid; gap: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label { font-weight: 600; font-size: .97rem; }
.field .hint { font-size: .88rem; color: var(--stone); }
.field input, .field select, .field textarea {
  font: inherit; color: var(--ink); background: #fff;
  border: 1.5px solid #C3C8DA; border-radius: var(--radius-sm);
  padding: 11px 14px; min-height: 48px; width: 100%;
}
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); outline: 3px solid rgba(35,80,216,.18); outline-offset: 0; }
.field-error input, .field-error select, .field-error textarea { border-color: #B3261E; }
.error-text { color: #B3261E; font-size: .9rem; }
.hp { position: absolute; left: -5000px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }

.alert { padding: 16px 20px; border-radius: var(--radius-sm); font-weight: 500; }
.alert-success { background: var(--tint); color: var(--blue-dark); border: 1px solid #C5CEF7; }
.alert-error { background: #FCE8E6; color: #8C1D18; border: 1px solid #f2c4bf; }

/* Footer */
.site-footer { background: var(--ink); color: #B8BEDC; padding-top: 64px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 40px; }
.footer-brand { font-family: var(--display); font-weight: 800; font-size: 1.35rem; color: #fff; margin-bottom: 10px; }
.footer-heading { color: #fff; font-weight: 600; margin-bottom: 12px; }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a { color: #E3E6F5; text-decoration: none; }
.site-footer a:hover { color: var(--purple-light); }
.footer-legal { border-top: 1px solid #2A3363; padding-block: 22px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: .9rem; color: #8D93B3; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* Page header for inner pages */
.page-head { background: var(--white); border-bottom: 1px solid var(--line); padding-block: clamp(48px, 7vw, 88px); }
.page-head .wrap { display: grid; gap: 18px; }
.action-card-primary .btn-accent { background: #fff; color: var(--blue-dark); }
.action-card-primary .btn-accent:hover { background: var(--tint); color: var(--blue-dark); }

/* Logo */
.brand-logo { height: 60px; width: auto; }
@media (max-width: 420px) { .brand-logo { height: 50px; } }
.footer-brand img { height: 66px; width: auto; }
.service-group + .service-group { margin-top: 64px; }
.service-group h2 { margin-bottom: 18px; }
.mega-links + .mega-title { margin-top: 22px; }
.mega-title { font-size: 1.05rem; }
