/* Tekgates — design tokens taken from the logo */
:root {
  --ink: #232A2F;          /* wordmark charcoal */
  --ink-soft: #4A555D;
  --signal: #5AA9F5;       /* upper trace blue */
  --circuit: #2F9FCB;      /* lower trace teal-blue */
  --circuit-deep: #1C7FA8; /* accessible text/link blue */
  --deep: #0E2233;         /* night navy for dark sections */
  --paper: #F4F8FB;        /* cool off-white */
  --white: #FFFFFF;
  --line: #D8E3EB;

  --font-display: "Sora", "Segoe UI", system-ui, sans-serif;
  --font-body: "Hanken Grotesk", "Segoe UI", system-ui, sans-serif;

  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(72px, 10vw, 128px);
  --radius: 10px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--circuit-deep); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--font-display); color: var(--ink); margin: 0 0 .5em; letter-spacing: -0.02em; }
h1 { font-size: clamp(2.3rem, 5.2vw, 3.9rem); line-height: 1.06; font-weight: 600; }
h2 { font-size: clamp(1.75rem, 3.2vw, 2.55rem); line-height: 1.15; font-weight: 600; }
h3 { font-size: 1.2rem; line-height: 1.3; font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--deep); color: #fff; padding: 10px 16px; z-index: 100; border-radius: 6px; }
.skip:focus { left: 8px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font: 600 1rem/1 var(--font-body);
  padding: 15px 24px; border-radius: 999px; text-decoration: none;
  border: 2px solid transparent; cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s;
}
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: var(--circuit-deep); color: #fff; }
.btn-ghost { border-color: var(--line); color: var(--ink); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn-sm { padding: 11px 18px; font-size: .95rem; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(244, 248, 251, .88);
  backdrop-filter: saturate(160%) blur(10px);
  -webkit-backdrop-filter: saturate(160%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}
.site-header.scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img:first-child { width: 44px; height: auto; }
.brand-word { width: 120px; height: auto; }
.site-nav { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 32px); }
.site-nav a:not(.btn) { color: var(--ink); text-decoration: none; font-weight: 500; }
.site-nav a:not(.btn):hover { color: var(--circuit-deep); }
.nav-toggle { display: none; }

/* Hero */
.hero { background: var(--paper); padding: clamp(40px, 7vw, 96px) 0 clamp(64px, 8vw, 112px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(24px, 4vw, 64px); align-items: center; }
.hero-kicker { font-weight: 600; color: var(--circuit-deep); margin-bottom: 18px; }
.hero h1 { max-width: 15ch; }
.lede { font-size: 1.2rem; color: var(--ink-soft); max-width: 34em; margin-bottom: 32px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-art { position: relative; }
.gate { width: 100%; max-width: 620px; margin-left: auto; overflow: visible; }

/* the single orchestrated motion: traces draw in, nodes light up, then data pulses travel */
.trace { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1.6s cubic-bezier(.6,.05,.25,1) forwards; }
#t-mid { animation-delay: .25s; }
#t-inner { animation-delay: .5s; }
.nodes circle { opacity: 0; transform-box: fill-box; transform-origin: center; animation: node .45s ease-out forwards; animation-delay: 1.3s; }
.nodes circle:nth-child(n+2) { animation-delay: 1.45s; }
.nodes circle:nth-child(n+6) { animation-delay: 1.6s; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes node { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .carousel-track { scroll-behavior: auto; }
  .trace { animation: none; stroke-dashoffset: 0; }
  .nodes circle { animation: none; opacity: 1; }
  .pulses { display: none; }
}

/* Section headings */
section { scroll-margin-top: 80px; }
.section-head { max-width: 640px; margin-bottom: clamp(40px, 6vw, 64px); }
.section-head p { color: var(--ink-soft); font-size: 1.125rem; }
.section-head.on-dark h2 { color: #fff; }
.section-head.on-dark p { color: #B5C6D3; }

/* Services: a ruled list, not a card grid */
.services { padding: var(--section) 0; background: var(--white); }
.service-list {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
}
.service {
  position: relative;
  padding: 36px 32px 40px 0;
  border-bottom: 1px solid var(--line);
}
.service:not(:nth-child(3n+1)) { padding-left: 32px; border-left: 1px solid var(--line); }
.service::before {
  /* circuit node sitting on the rule above each service */
  content: ""; position: absolute; top: -7px; width: 12px; height: 12px; border-radius: 50%;
  background: var(--white); border: 3px solid var(--circuit);
}
.service:not(:nth-child(3n+1))::before { left: 26px; }
.service p { color: var(--ink-soft); }
.service ul { list-style: none; margin: 18px 0 0; padding: 0; font-size: .97rem; }
.service li { padding: 5px 0 5px 20px; position: relative; line-height: 1.6; }
.service li::before { margin-top: 5px; }
.service li::before { content: ""; position: absolute; left: 0; top: calc(.8em - 4px); width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--circuit); background: transparent; box-sizing: border-box; }

/* Process: a real sequence, drawn as one circuit trace */
.process { padding: var(--section) 0; background: var(--white); color: var(--ink); }
.process h2, .process h3 { color: var(--ink); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; counter-reset: step; position: relative; }
.steps::before {
  content: ""; position: absolute; top: 15px; left: 15px; right: 15px; height: 3px;
  background: linear-gradient(90deg, var(--signal), var(--circuit));
  border-radius: 3px;
}
.steps li { position: relative; counter-increment: step; }
.step-node {
  position: relative; display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--white); border: 3px solid var(--signal);
  margin-bottom: 24px;
}
.step-node::after { content: counter(step); font: 600 .85rem/1 var(--font-display); color: var(--ink); }
.steps p { color: var(--ink-soft); margin: 0; }

/* Hero incident shortcut */
.hero-incident { display: flex; align-items: center; gap: 10px; margin: 28px 0 0; color: var(--ink-soft); }
.hero-incident a { font-weight: 600; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #D64545; flex: none; box-shadow: 0 0 0 4px rgba(214,69,69,.15); }

/* Solutions we resell */
.solutions { background: var(--paper); padding: clamp(56px, 7vw, 96px) 0 var(--section); border-top: 1px solid var(--line); }
.solutions-head { display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(28px, 5vw, 80px); align-items: end; margin-bottom: 40px; }
.solutions-head p { color: var(--ink-soft); font-size: 1.125rem; max-width: 36em; margin: 0; }
.resell-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; font-weight: 500; }
.resell-points li { display: flex; align-items: center; gap: 12px; }
.resell-points li::before { content: ""; width: 10px; height: 10px; border-radius: 50%; border: 2.5px solid var(--circuit); background: var(--paper); flex: none; }

.carousel { position: relative; }
.carousel-track {
  display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 48px) / 3);
  gap: 24px; overflow-x: auto;
  padding: 4px 2px 8px; scrollbar-width: none; overscroll-behavior-x: contain;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track:focus-visible { outline: 3px solid var(--signal); outline-offset: 4px; }
.slide {
  min-width: 0;
  background: var(--white); border: 1px solid var(--line); border-radius: 16px;
  padding: 32px 28px 28px; display: flex; flex-direction: column;
  position: relative; overflow: hidden;
}
.slide::before {
  /* a circuit trace across the top of each vendor card */
  content: ""; position: absolute; top: 0; left: 28px; right: 28px; height: 3px;
  background: linear-gradient(90deg, var(--signal), var(--circuit)); border-radius: 0 0 3px 3px;
}
.slide-name { font: 600 1.75rem/1.15 var(--font-display); letter-spacing: -0.025em; margin: 0 0 10px; }
.slide-what { color: var(--ink-soft); margin: 0 0 20px; min-height: 4.8em; }
.slide-name { min-height: 40px; display: flex; align-items: center; }
.slide-logo { display: none; height: 34px; width: auto; max-width: 170px; object-fit: contain; object-position: left center; }
.slide-name.has-logo .slide-logo { display: block; }
/* optical balance between wordmarks of different weight and shape */
.slide-logo[data-vendor="symantec"] { height: 40px; }
.slide-logo[data-vendor="sophos"] { height: 24px; }
.slide-logo[data-vendor="crowdstrike"] { height: 30px; }
.slide-logo[data-vendor="tenable"] { height: 34px; }
.slide-logo[data-vendor="rapid7"] { height: 26px; }
.slide-name.has-logo .slide-name-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.slide-products { list-style: none; margin: 0 0 24px; padding: 16px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; font-size: .97rem; }
.slide-products li { padding-left: 20px; position: relative; }
.slide-products li::before { content: ""; position: absolute; left: 0; top: calc(.8em - 4px); width: 8px; height: 8px; border-radius: 50%; border: 2px solid var(--circuit); background: transparent; box-sizing: border-box; }
.slide-cta { margin-top: auto; font-weight: 600; text-decoration: none; color: var(--circuit-deep); align-self: flex-start; border-bottom: 2px solid currentColor; padding-bottom: 2px; }
.slide-cta:hover { color: var(--ink); }

.carousel-controls { display: flex; align-items: center; justify-content: space-between; margin-top: 24px; gap: 16px; }
.carousel-pause {
  display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px 0 12px;
  border: 1.5px solid var(--line); border-radius: 999px; background: var(--white); color: var(--ink);
  font: 600 .95rem/1 var(--font-body); cursor: pointer;
}
.carousel-pause:hover { border-color: var(--ink); }
.pause-icon { width: 12px; height: 12px; position: relative; }
.pause-icon::before, .pause-icon::after { content: ""; position: absolute; top: 0; width: 4px; height: 12px; background: currentColor; border-radius: 1px; }
.pause-icon::before { left: 1px; }
.pause-icon::after { right: 1px; }
.carousel-pause.is-paused .pause-icon::before { left: 2px; width: 0; height: 0; background: none; border-radius: 0; border-left: 10px solid currentColor; border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.carousel-pause.is-paused .pause-icon::after { display: none; }
.carousel-arrows { display: flex; gap: 10px; }
.arrow {
  width: 48px; height: 48px; border-radius: 50%; border: 1.5px solid var(--line); background: var(--white);
  display: grid; place-items: center; cursor: pointer; color: var(--ink); transition: border-color .2s, background-color .2s;
}
.arrow svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.arrow:hover { border-color: var(--ink); }
.arrow:disabled { opacity: .35; cursor: default; border-color: var(--line); }

/* Services grouped */
.service-group { display: grid; grid-template-columns: 190px 1fr; gap: 32px; padding: 40px 0; border-top: 1px solid var(--ink); }
.service-group:last-child { padding-bottom: 0; }
.group-title { font-size: 1.35rem; margin-bottom: 8px; }
.group-head p { color: var(--ink-soft); font-size: .97rem; margin: 0; }
.service-group .service-list { border-top: 0; }
.service-group .service { border-bottom: 0; padding-top: 4px; padding-bottom: 8px; }
.service-group .service::before { display: none; }
.service-list.four { grid-template-columns: repeat(2, 1fr); row-gap: 28px; }
.service-list.four .service { padding-left: 0; padding-right: 32px; border-left: 0; }
.service-list.four .service:nth-child(2n) { padding-left: 32px; border-left: 1px solid var(--line); }

/* Active nav link */
.site-nav a.active:not(.btn) { color: var(--circuit-deep); }
.site-nav a.active:not(.btn)::after { content: ""; display: block; height: 2px; background: var(--circuit); margin-top: 2px; border-radius: 2px; }

/* Incident band */
.incident { background: var(--deep); color: #DCE6EE; padding: clamp(56px, 8vw, 96px) 0; }
.incident-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; }
.incident h2 { color: #fff; }
.incident-grid > div > p { color: #B5C6D3; font-size: 1.125rem; max-width: 34em; margin: 0; }
.incident-contact { border-left: 3px solid var(--signal); padding-left: 28px; }
.incident-label { color: #B5C6D3; margin: 0 0 4px; }
.incident-phone { display: block; width: 310px; max-width: 100%; height: auto; margin: 4px 0 14px; }
.call-btn {
  font: 600 .95rem/1 var(--font-body); cursor: pointer; border-radius: 999px;
  padding: 10px 18px; border: 1.5px solid var(--line); background: var(--white); color: var(--ink);
  transition: border-color .2s, background-color .2s, color .2s;
}
.call-btn:hover { border-color: var(--ink); }
.call-btn-dark { background: var(--signal); border-color: var(--signal); color: var(--deep); padding: 12px 22px; }
.call-btn-dark:hover { background: #fff; border-color: #fff; color: var(--deep); }
.phone-dd { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; }
.contact-phone { width: 137px; height: auto; margin-left: -2px; }
.incident-note { color: #8FA5B6; font-size: .95rem; margin: 16px 0 0; }

.nav-alert { position: relative; }
.site-nav a.nav-alert::before {
  content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%;
  background: #D64545; margin-right: 8px; vertical-align: 2px;
}
.field-hint { color: var(--ink-soft); font-size: .88rem; }

/* Sectors */
.sectors { padding: var(--section) 0; background: var(--paper); }
.sectors-grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.sectors-grid > div p { color: var(--ink-soft); font-size: 1.125rem; max-width: 30em; }
.sector-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 32px; }
.sector-list li { padding: 18px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 2px; }
.sector-list strong { font-family: var(--font-display); font-weight: 600; font-size: 1.05rem; }
.sector-list span { color: var(--ink-soft); font-size: .95rem; }

/* About */
.about { padding: var(--section) 0; }
.about-grid { display: grid; grid-template-columns: 300px 1fr; gap: clamp(32px, 6vw, 96px); align-items: center; max-width: 1000px; }
.about-mark { width: 100%; max-width: 260px; }
.about p { color: var(--ink-soft); font-size: 1.125rem; max-width: 36em; }

/* Contact */
.contact { padding: var(--section) 0; background: var(--paper); border-top: 1px solid var(--line); }
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.contact-info > p { color: var(--ink-soft); font-size: 1.125rem; max-width: 28em; }
.contact-info dl { margin: 32px 0 0; display: grid; gap: 16px; }
.contact-info dl div { display: grid; grid-template-columns: 90px 1fr; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.contact-info dt { color: var(--ink-soft); }
.contact-info dd { margin: 0; font-weight: 500; }

.contact-form {
  background: var(--white); border: 1px solid var(--line); border-radius: 16px;
  padding: clamp(24px, 4vw, 40px);
}
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { font-weight: 600; font-size: .95rem; }
.opt { font-weight: 400; color: var(--ink-soft); }
.field input, .field select, .field textarea {
  font: inherit; color: var(--ink);
  border: 1.5px solid var(--line); border-radius: var(--radius);
  padding: 12px 14px; background: var(--white); width: 100%;
  transition: border-color .15s;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--circuit); box-shadow: 0 0 0 3px rgba(90,169,245,.25); }
.field [aria-invalid="true"] { border-color: #C2362B; }
.field-error { color: #B3261E; font-size: .9rem; }
.hp { position: absolute; left: -9999px; }
.consent { font-size: .9rem; color: var(--ink-soft); }
.form-status { margin: 14px 0 0; font-weight: 500; min-height: 1.5em; }
.form-status.ok { color: #1E7A4C; }
.form-status.err { color: #B3261E; }
.contact-form button[disabled] { opacity: .6; cursor: progress; }

/* Footer */
.site-footer { background: var(--deep); color: #B5C6D3; padding: 64px 0 48px; }
.footer-grid { display: grid; grid-template-columns: 1fr auto 1fr; gap: 40px; align-items: start; }
.footer-logo { width: 180px; }
.site-footer nav { display: flex; flex-direction: column; gap: 10px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { color: var(--signal); }
.footer-meta { text-align: right; font-size: .95rem; }

/* Simple content pages */
.page { padding: clamp(48px, 8vw, 96px) 0; }
.page .wrap { max-width: 760px; }
.page h2 { font-size: 1.4rem; margin-top: 2em; }
.page p, .page li { color: var(--ink-soft); }

/* Responsive */
@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-art { order: -1; max-width: 420px; margin: 0 auto; }
  .service-list { grid-template-columns: 1fr 1fr; }
  .service, .service:not(:nth-child(3n+1)) { padding: 32px 24px 36px 0; border-left: 0; }
  .service:nth-child(2n) { padding-left: 24px; border-left: 1px solid var(--line); }
  .service:not(:nth-child(3n+1))::before { left: auto; }
  .service:nth-child(2n)::before { left: 18px; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 48px; }
  .steps::before { display: none; }
  .solutions-head { grid-template-columns: 1fr; align-items: start; }
  .carousel-track { grid-auto-columns: calc((100% - 24px) / 2); }
  .service-group { grid-template-columns: 1fr; gap: 20px; }
  .service-group .service-list { grid-template-columns: repeat(3, 1fr); }
  .service-group .service { padding: 4px 20px 8px 0; border-left: 0; }
  .service-group .service + .service { padding-left: 20px; border-left: 1px solid var(--line); }
  .service-group .service-list.four { grid-template-columns: repeat(2, 1fr); }
  .service-group .service-list.four .service:nth-child(odd) { padding-left: 0; border-left: 0; }
  .incident-grid { grid-template-columns: 1fr; }
  .sectors-grid, .contact-grid, .about-grid { grid-template-columns: 1fr; }
  .about-mark { max-width: 160px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-meta { grid-column: 1 / -1; text-align: left; }
}

@media (max-width: 760px) {
  .nav-toggle {
    display: grid; place-items: center; width: 44px; height: 44px;
    background: transparent; border: 0; cursor: pointer; border-radius: 8px;
  }
  .bars, .bars::before, .bars::after {
    display: block; width: 22px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; transition: transform .2s, background-color .2s;
  }
  .bars::before, .bars::after { content: ""; position: absolute; left: 0; }
  .bars::before { top: -7px; }
  .bars::after { top: 7px; }
  .nav-toggle[aria-expanded="true"] .bars { background: transparent; }
  .nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-7px) rotate(-45deg); }

  .site-nav {
    position: absolute; top: 76px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 8px var(--gutter) 20px;
    display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a:not(.btn) { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .site-nav .btn { margin-top: 16px; }

  .service-list { grid-template-columns: 1fr; }
  .service, .service:nth-child(2n) { padding: 28px 0 32px; border-left: 0; }
  .service::before, .service:nth-child(2n)::before { left: 0; }
  .steps { grid-template-columns: 1fr; row-gap: 36px; }
  .sector-list { grid-template-columns: 1fr; }
  .carousel-track { grid-auto-columns: 86%; gap: 16px; }
  .slide-what { min-height: 0; }
  .service-group .service-list { grid-template-columns: 1fr; }
  .service-group .service, .service-group .service + .service { padding: 20px 0; border-left: 0; border-top: 1px solid var(--line); }
  .service-group .service-list.four { grid-template-columns: 1fr; row-gap: 0; }
  .service-group .service-list.four .service:nth-child(n) { padding: 20px 0; border-left: 0; }
  .service-group .service-list.four .service:first-child { border-top: 0; padding-top: 0; }
  .service-group .service:first-child { border-top: 0; padding-top: 0; }
  .site-nav a.active:not(.btn)::after { display: none; }
  .incident-contact { padding-left: 20px; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .contact-info dl div { grid-template-columns: 80px 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .lede { font-size: 1.1rem; }
}
