/* Sec-Tec — refreshed stylesheet (replaces Drupal theme + Bootstrap 3) */
:root {
  --ink: #1d2124;
  --ink-soft: #4a5258;
  --muted: #6b7378;
  --line: #e3e6e8;
  --paper: #ffffff;
  --paper-2: #f5f6f4;
  --brand: #5fb336;        /* Sec-Tec green, from the old theme */
  --brand-ink: #3f8a1d;    /* darker green for text links on white (AA contrast) */
  --brand-bright: #8fd14f; /* green that reads on the dark header */
  --night: #221c1c;        /* matches the logo background exactly */
  --night-2: #2c2626;
  --night-line: #3d3535;
  --radius: 10px;
  --wrap: 1140px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--paper);
}
img { max-width: 100%; height: auto; }
a { color: var(--brand-ink); text-underline-offset: 2px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--brand); color: #fff; padding: 8px 14px; border-radius: 6px; }
.skip-link:focus { top: 12px; }

/* ---------- header & navigation ---------- */
.site-header { background: var(--night); color: #fff; position: sticky; top: 0; z-index: 50; box-shadow: 0 1px 0 var(--night-line); }
.header-inner { display: flex; align-items: center; gap: 24px; height: 76px; }
.brand { display: block; flex: none; line-height: 0; }
.brand img { height: 46px; width: auto; }
.site-nav { margin-left: auto; }
.site-nav ul { list-style: none; margin: 0; padding: 0; }
.menu { display: flex; align-items: center; gap: 4px; }
.menu > li { position: relative; display: flex; align-items: center; }
.menu a {
  display: block; color: #e9e6e6; text-decoration: none;
  font-size: 15px; font-weight: 500; letter-spacing: .01em;
  padding: 10px 12px; border-radius: 6px;
}
.menu a:hover, .menu a:focus-visible { color: #fff; background: var(--night-2); }
.menu > li.is-active > a, .menu a[aria-current="page"] { color: var(--brand-bright); }
.sub-toggle {
  border: 0; background: transparent; color: #cfcaca; cursor: pointer;
  width: 28px; height: 36px; margin-left: -8px; border-radius: 6px;
}
.sub-toggle::before { content: ""; display: inline-block; width: 7px; height: 7px; border: solid currentColor; border-width: 0 2px 2px 0; transform: translateY(-2px) rotate(45deg); }
.sub {
  position: absolute; top: 100%; left: 0; min-width: 280px;
  background: var(--night); border: 1px solid var(--night-line); border-radius: var(--radius);
  padding: 8px; box-shadow: 0 16px 40px rgba(0,0,0,.35);
  opacity: 0; visibility: hidden; transform: translateY(6px); transition: .15s ease;
}
.sub a { padding: 9px 12px; }
.has-sub:hover > .sub, .has-sub:focus-within > .sub, .has-sub.open > .sub { opacity: 1; visibility: visible; transform: none; }

.nav-toggle {
  display: none; margin-left: auto; align-items: center; gap: 10px;
  background: transparent; color: #fff; border: 1px solid var(--night-line);
  border-radius: 8px; padding: 9px 14px; font: inherit; font-size: 15px; cursor: pointer;
}
.bars, .bars::before, .bars::after { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; position: relative; }
.bars::before, .bars::after { content: ""; position: absolute; left: 0; }
.bars::before { top: -6px; } .bars::after { top: 6px; }

@media (max-width: 900px) {
  .brand img { height: 40px; }
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--night); border-top: 1px solid var(--night-line); padding: 8px 12px 16px; }
  .site-nav.open { display: block; }
  .menu { flex-direction: column; align-items: stretch; }
  .menu > li { flex-wrap: wrap; }
  .menu > li > a { flex: 1; }
  .sub-toggle { width: 44px; height: 44px; margin: 0; }
  .sub { position: static; display: none; width: 100%; min-width: 0; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; border-left: 2px solid var(--night-line); border-radius: 0; margin: 0 0 6px 12px; padding: 0 0 0 6px; }
  .has-sub:hover > .sub, .has-sub:focus-within > .sub { display: none; }
  .has-sub.open > .sub { display: block; }
}

/* ---------- hero (home) & page heading ---------- */
.hero {
  position: relative; overflow: hidden; isolation: isolate;
  color: #fff;
  background: url(hero-poster.jpg) center / cover no-repeat var(--night);
  padding: 96px 0 104px;
}
.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.hero::before { /* keeps the headline readable over the moving background */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(100deg, rgba(20,16,16,.92) 0%, rgba(20,16,16,.78) 40%, rgba(20,16,16,.25) 100%);
}
.hero .wrap > * { max-width: 720px; }
.video-toggle {
  position: absolute; right: 16px; bottom: 16px; z-index: 1;
  background: rgba(20,16,16,.6); color: #ddd8d8; border: 1px solid rgba(255,255,255,.2);
  border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 13px; cursor: pointer;
}
.video-toggle:hover { color: #fff; border-color: rgba(255,255,255,.5); }
.eyebrow { margin: 0 0 14px; color: var(--brand-bright); font-size: 14px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.hero h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.1; letter-spacing: -.02em; margin: 0 0 20px; font-weight: 700; }
.hero .lead { color: #ddd8d8; font-size: 19px; margin: 0 0 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 0; }

.page-head {
  color: #fff; padding: 44px 0 46px; border-top: 1px solid var(--night-line); position: relative; overflow: hidden;
  background: linear-gradient(100deg, rgba(20,16,16,.95), rgba(20,16,16,.82)), url(hero-poster.jpg) right center / cover no-repeat var(--night);
}
.page-head::after { content: ""; position: absolute; right: -80px; top: -120px; width: 360px; height: 360px; border-radius: 50%; border: 40px solid rgba(95,179,54,.12); }
.page-head h1 { position: relative; margin: 0; font-size: clamp(28px, 4vw, 40px); line-height: 1.15; letter-spacing: -.015em; max-width: 820px; }

/* The top banner stays put and the rest of the page slides up over it */
@media (min-height: 560px) {
  .hero, .page-head { position: sticky; top: 76px; z-index: 0; }
  main, .services, .site-footer { position: relative; z-index: 1; }
  main { background: var(--paper); box-shadow: 0 -18px 40px rgba(0,0,0,.35); }
}

/* ---------- buttons & links ---------- */
.btn, .prose .btn-success {
  display: inline-block; background: var(--brand); color: #fff; text-decoration: none;
  font-weight: 600; font-size: 16px; line-height: 1; border: 2px solid var(--brand);
  padding: 14px 22px; border-radius: 8px; cursor: pointer; transition: background .15s, border-color .15s;
}
.btn:hover, .prose .btn-success:hover { background: #4f9b2a; border-color: #4f9b2a; color: #fff; }
.btn-ghost { background: transparent; border-color: rgba(255,255,255,.5); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.08); border-color: #fff; }
.page .btn-ghost { color: var(--ink); border-color: var(--line); }
.page .btn-ghost:hover { background: var(--paper-2); color: var(--ink); }
.text-link { font-weight: 600; color: var(--brand-ink); text-decoration: none; }
.text-link::after { content: " \2192"; }

/* ---------- main content ---------- */
main { padding: 56px 0 72px; }
.home main { padding-top: 64px; }
.prose { max-width: 820px; }
.prose > :first-child { margin-top: 0; }
.prose h2, .prose h3 { font-size: 26px; line-height: 1.25; letter-spacing: -.01em; margin: 1.8em 0 .5em; }
.prose h4 { font-size: 19px; line-height: 1.35; margin: 1.6em 0 .4em; }
.prose h5 { font-size: 17px; margin: 1.4em 0 .3em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .3em 0; }
.prose code { background: var(--paper-2); border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; font-size: .9em; overflow-wrap: anywhere; word-break: break-word; }
.prose pre { overflow-x: auto; max-width: 100%; }
/* nothing in the content may force the page wider than the screen */
.prose, .prose * { max-width: 100%; }
.prose .row > [class*="col-"] { min-width: 0; overflow-wrap: anywhere; }
.prose img { border-radius: 6px; }
.prose img.webfig { display: block; margin: 22px auto; max-width: 100%; height: auto; border-radius: 0; box-shadow: none; }
figure.webfig-wrap { margin: 24px 0; }
.prose .center { text-align: center; }
.lead { font-size: 19px; color: var(--ink-soft); }
.prose table { width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: 16px; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--paper-2); }
.table-responsive { overflow-x: auto; }

/* Bootstrap-era content blocks ("panels" in page bodies) become a card grid */
.prose .row { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; margin: 28px 0; }
.prose .row > .clearfix { display: none; }
.prose .row.info-section { max-width: none; }
.prose .row > [class*="col-"] {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 24px; border-top: 4px solid var(--brand);
}
.prose .row h4.title, .prose .row h4 { margin-top: 0; }
.prose .panel-body, .prose .modal-body { padding: 0; }
.prose:has(.row) { max-width: none; }
.prose:has(.row) > p, .prose:has(.row) > h3, .prose:has(.row) > ul, .prose:has(.row) > ol, .prose:has(.row) > h4 { max-width: 820px; }

/* ---------- home ---------- */
.why h2 { font-size: 30px; letter-spacing: -.015em; margin: 0 0 28px; }
.why .feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.why .feature { position: relative; background: var(--paper-2); border-radius: var(--radius); padding: 26px 24px 24px 24px; color: var(--ink-soft); }
.why .feature::before { content: ""; display: block; width: 32px; height: 4px; border-radius: 2px; background: var(--brand); margin-bottom: 16px; }
.why .feature strong { display: block; color: var(--ink); font-size: 18px; line-height: 1.35; margin-bottom: 6px; }
.home .prose, .home main .wrap > .why { max-width: none; }

.services { background: var(--paper-2); padding: 72px 0 80px; border-top: 1px solid var(--line); }
.services h2 { font-size: 30px; letter-spacing: -.015em; margin: 0 0 28px; }
.service-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 24px; }
.service-card { position: relative; background: var(--paper); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); display: flex; flex-direction: column; transition: transform .15s ease, box-shadow .15s ease; }
.service-card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(29,33,36,.1); }
.service-img { aspect-ratio: 16 / 8; background-size: cover; background-position: center; filter: grayscale(.2); }
.service-body { padding: 22px 24px 24px; display: flex; flex-direction: column; flex: 1; }
.service-body h3 { margin: 0 0 8px; font-size: 21px; line-height: 1.3; }
.service-body h3 a { color: var(--ink); text-decoration: none; }
.service-body h3 a::after { content: ""; position: absolute; inset: 0; }
.service-body p { margin: 0 0 16px; color: var(--ink-soft); font-size: 16px; flex: 1; }

/* ---------- contact ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.card { background: var(--paper-2); border-radius: var(--radius); padding: 24px 26px; }
.card h2 { margin: 0 0 10px; font-size: 20px; }
.card p { margin: 0 0 12px; font-size: 16px; color: var(--ink-soft); }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; gap: 32px; } }

.contact-form { margin-top: 28px; }
.field { margin-bottom: 20px; }
.field label { display: block; font-weight: 600; margin-bottom: 6px; font-size: 16px; }
.req { color: #b23a2b; }
.field input[type=text], .field input[type=email], .field textarea {
  width: 100%; font: inherit; font-size: 16px; color: var(--ink);
  padding: 12px 14px; border: 1px solid #c9ced1; border-radius: 8px; background: #fff;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(95,179,54,.25); }
.field textarea { resize: vertical; min-height: 160px; }
.field.check { display: flex; gap: 10px; align-items: flex-start; }
.field.check input { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--brand); flex: none; }
.field.check label { font-weight: 400; color: var(--ink-soft); }
.field.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- testimonials ---------- */
.testimonial-list { display: grid; gap: 22px; max-width: 900px; }
.testimonial { margin: 0; background: var(--paper-2); border-radius: var(--radius); padding: 28px 30px; border-left: 4px solid var(--brand); }
.testimonial blockquote { margin: 0 0 12px; font-size: 18px; color: var(--ink); }
.testimonial blockquote p { margin: 0 0 .6em; }
.testimonial figcaption { font-weight: 600; color: var(--ink-soft); }
.testimonial figcaption a { color: inherit; text-decoration: none; }
.testimonial.single { max-width: 820px; }

/* ---------- footer ---------- */
.site-footer { background: var(--night); color: #c9c3c3; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px; padding-top: 56px; padding-bottom: 48px; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }
.site-footer h2 { color: #fff; font-size: 14px; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 16px; font-weight: 600; }
.site-footer h2:not(:first-child) { margin-top: 28px; }
.site-footer a { color: #e9e6e6; text-decoration: none; }
.site-footer a:hover { color: var(--brand-bright); text-decoration: underline; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.plain li { margin: 4px 0; }
.certs { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.certs img { border-radius: 6px; display: block; background: #fff; }
.certs .badge { display: inline-block; border: 1px solid var(--night-line); border-radius: 6px; padding: 8px 12px; font-weight: 600; font-size: 14px; }
.certs .badge:hover { border-color: var(--brand-bright); text-decoration: none; }
.certs img { width: 140px; }
.news li { padding: 10px 0; border-bottom: 1px solid var(--night-line); line-height: 1.45; }
.news li:first-child { padding-top: 0; }
.news-source { font-size: 13px; color: #8f8888; margin: 10px 0 0; }
.social li { margin: 0 0 10px; }
.social a { display: inline-flex; align-items: center; gap: 10px; }
.social img { width: 30px; height: 30px; border-radius: 6px; }
.quote { margin: 0 0 12px; }
.quote blockquote { margin: 0 0 10px; color: #e9e6e6; font-style: italic; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 6; -webkit-box-orient: vertical; overflow: hidden; }
.quote figcaption { font-size: 14px; }
.quote figcaption a { color: var(--brand-bright); }
.site-footer .text-link { color: var(--brand-bright); }
.footer-bar { border-top: 1px solid var(--night-line); padding: 18px 0; font-size: 14px; color: #9a9393; }
.footer-bar .wrap { display: flex; flex-wrap: wrap; gap: 4px 24px; justify-content: space-between; }
.footer-bar a { color: #c9c3c3; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  main { padding: 40px 0 56px; }
  .hero { padding: 56px 0 64px; }
  .page-head { padding: 32px 0 34px; }
  .prose .row { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
@media print {
  .site-header, .site-footer, .services, .hero-actions { display: none; }
  .hero, .page-head { background: none; color: #000; padding: 0 0 12px; }
}
