/* Optio Electrical Specialists — shared styles
   Mobile first. One accent color (copper), used for buttons, line highlights and diagram paths.
   Colors were checked against WCAG AA: text uses --copper-deep, graphics use --copper. */

:root {
  --navy: #0E1B2C;
  --navy-2: #1A2D45;
  --slate: #3A4656;
  --muted: #5B6978;
  --line: #D5DAE0;
  --bg: #FFFFFF;
  --bg-alt: #F4F5F7;
  --copper: #C27A3A;
  --copper-deep: #9A5A22;
  --copper-dark: #7F4917;
  --copper-tint: #F7EEE4;
  --on-dark: #FFFFFF;
  --on-dark-muted: #B8C2CC;
  --font: "IBM Plex Sans", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 5px;
  --measure: 66ch;
  --container: 1160px;
  --gap: 1.5rem;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--slate);
  font-family: var(--font);
  font-size: 1.0625rem; /* 17px */
  line-height: 1.6;
}

img, svg { max-width: 100%; height: auto; }
svg text { font-family: var(--font); }

a { color: var(--navy); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--copper-deep); }
:focus-visible { outline: 3px solid var(--copper-deep); outline-offset: 3px; }

h1, h2, h3, h4 { color: var(--navy); font-weight: 600; line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .75rem; }
h1 { font-size: clamp(2rem, 1.3rem + 3vw, 3.25rem); max-width: 20ch; }
h2 { font-size: clamp(1.5rem, 1.15rem + 1.6vw, 2.125rem); max-width: 28ch; }
h3 { font-size: 1.2rem; }
p, ul, ol { margin: 0 0 1rem; }
p { max-width: var(--measure); }
.lead { font-size: 1.2rem; max-width: 56ch; }
.eyebrow {
  display: block;
  color: var(--copper-deep);
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.note { color: var(--muted); font-size: .95rem; }
.text-link { font-weight: 600; text-decoration: none; border-bottom: 1px solid currentColor; }

/* Layout */
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 1.25rem; }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gap); }
.grid > * { grid-column: span 12; }
.section { padding: 3.5rem 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { margin-bottom: 2rem; }
.section-head p { margin-bottom: 0; }

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 100;
  background: var(--navy);
  color: var(--on-dark);
  padding: .6rem 1rem;
  border-radius: var(--radius);
  text-decoration: none;
}
.skip-link:focus { top: 1rem; }

/* Header */
.site-header { background: var(--bg); border-bottom: 1px solid var(--line); position: relative; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4.5rem; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; color: var(--navy); font-weight: 600; font-size: 1.05rem; line-height: 1.2; }
.brand:hover { color: var(--navy); }
.brand-mark { width: 2.1rem; height: 2.1rem; flex: none; }
.nav-toggle {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font: inherit;
  font-weight: 600;
  color: var(--navy);
  background: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: .45rem .8rem;
  cursor: pointer;
}
.nav-toggle svg { width: 1.2rem; height: 1.2rem; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-open { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }
.site-nav { display: none; width: 100%; padding: .5rem 0 1rem; }
.site-nav.is-open { display: block; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .25rem; }
.site-nav a:not(.button) { display: block; padding: .55rem 0; text-decoration: none; font-weight: 500; border-bottom: 1px solid var(--line); }
.site-nav a[aria-current="page"]:not(.button) { color: var(--copper-deep); }
.site-nav .button { margin-top: .75rem; }

@media (min-width: 800px) {
  .header-inner { flex-wrap: nowrap; }
  .nav-toggle { display: none; }
  .site-nav { display: block; width: auto; padding: 0; }
  .site-nav ul { flex-direction: row; align-items: center; gap: 1.6rem; }
  .site-nav a:not(.button) { padding: .25rem 0; border-bottom: 2px solid transparent; }
  .site-nav a[aria-current="page"]:not(.button) { border-bottom-color: var(--copper); }
  .site-nav .button { margin: 0 0 0 .4rem; }
}

/* Buttons */
.button {
  display: inline-block;
  font-weight: 600;
  font-size: .98rem;
  line-height: 1.25;
  padding: .75rem 1.25rem;
  border-radius: var(--radius);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  font-family: inherit;
}
.button-primary { background: var(--copper-deep); color: var(--on-dark); border-color: var(--copper-deep); }
.button-primary:hover { background: var(--copper-dark); border-color: var(--copper-dark); color: var(--on-dark); }
.button-secondary { background: transparent; color: var(--navy); border-color: var(--navy); }
.button-secondary:hover { background: var(--navy); color: var(--on-dark); }
.button:disabled { opacity: .6; cursor: default; }
.actions { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; margin-top: 1.5rem; }

/* Hero */
.hero { padding: 3rem 0 3.5rem; background: var(--bg); }
.hero .lead { color: var(--slate); }
.hero-visual { margin-top: 2rem; }
.route-h { display: none; }
.route-v { display: block; max-width: 22rem; }
@media (min-width: 640px) {
  .route-h { display: block; }
  .route-v { display: none; }
}
@media (min-width: 1024px) {
  .hero { padding: 4.5rem 0 4rem; }
  .hero .hero-copy { grid-column: span 8; }
  .hero .hero-visual { grid-column: span 12; margin-top: 2.5rem; }
}
.route-path { stroke: var(--copper); stroke-width: 2.5; fill: none; }
.route-guide { stroke: var(--line); stroke-width: 1; fill: none; }
.route-node { fill: var(--bg); stroke: var(--navy); stroke-width: 1.5; }
.route-node-end { fill: var(--navy); stroke: var(--navy); }
.route-label { fill: var(--navy); font-size: 15px; font-weight: 500; }
.route-label-end { font-weight: 600; }
.route-sub { fill: var(--muted); font-size: 12px; }
.js .route-path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw-route 1.8s ease-out .3s forwards; }
@keyframes draw-route { to { stroke-dashoffset: 0; } }

/* Cards */
.cards { display: grid; gap: var(--gap); grid-template-columns: repeat(12, minmax(0, 1fr)); }
.card {
  grid-column: span 12;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.card-icon { width: 2.25rem; height: 2.25rem; color: var(--copper-deep); margin-bottom: 1rem; }
.card h3 { margin-bottom: .5rem; }
.card p { margin: 0; }
@media (min-width: 640px) { .card { grid-column: span 6; } }
@media (min-width: 1024px) { .card { grid-column: span 3; } }

/* Process diagram: five steps on one line, a vertical list on small screens */
.process { list-style: none; margin: 0; padding: 0; position: relative; counter-reset: step; display: grid; gap: 1.5rem; }
.process li { position: relative; padding-left: 3.5rem; }
.process li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--navy);
  color: var(--on-dark);
  font-weight: 600;
  display: grid;
  place-items: center;
}
.process li::after {
  content: "";
  position: absolute;
  left: 1.2rem;
  top: 2.6rem;
  bottom: -1.6rem;
  width: 1px;
  background: var(--copper);
}
.process li:last-child::after { display: none; }
.process h3 { font-size: 1.05rem; margin-bottom: .3rem; }
.process p { margin: 0; font-size: .95rem; }
@media (min-width: 900px) {
  .process { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; }
  .process li { padding-left: 0; padding-top: 3.5rem; }
  .process li::after { left: 2.6rem; right: -1.6rem; top: 1.2rem; bottom: auto; width: auto; height: 1px; }
}
.process-note { margin-top: 1.75rem; }

/* Segment tiles */
.tiles { display: grid; gap: 1rem; grid-template-columns: repeat(2, minmax(0, 1fr)); list-style: none; margin: 0; padding: 0; }
.tile {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.25rem .9rem 1.1rem;
  min-height: 9rem;
  display: flex;
  flex-direction: column;
  gap: .9rem;
  font-weight: 500;
  font-size: .95rem;
  color: var(--navy);
  line-height: 1.35;
  overflow-wrap: break-word;
  hyphens: auto;
}
.tile svg { width: 2.25rem; height: 2.25rem; color: var(--copper-deep); flex: none; }
.tile span { margin-top: auto; }
@media (min-width: 640px) { .tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tiles-note { margin-top: 1.5rem; margin-bottom: 0; }

/* Principles and plain definition lists */
.principles { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.principles li { display: grid; gap: .25rem; padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.principles strong { color: var(--navy); font-weight: 600; }
.principles span { max-width: var(--measure); }
@media (min-width: 760px) { .principles li { grid-template-columns: minmax(0, 16rem) minmax(0, 1fr); gap: 2rem; } }

/* Check lists and responsibilities */
.check-list { list-style: none; margin: 0 0 1rem; padding: 0; }
.check-list li { position: relative; padding-left: 1.9rem; margin-bottom: .6rem; max-width: var(--measure); }
.check-list li::before,
.check-list li::after { content: ""; position: absolute; }
.check-list li::before { left: 0; top: .3rem; width: 1.1rem; height: 1.1rem; border: 1.5px solid var(--copper); border-radius: 50%; }
.check-list li::after { left: .33rem; top: .5rem; width: .28rem; height: .55rem; border: solid var(--copper-deep); border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); }
.resp { display: grid; gap: var(--gap); }
.resp > div { background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.resp h3 { padding-bottom: .6rem; border-bottom: 1px solid var(--line); margin-bottom: 1rem; }
.resp .check-list { margin-bottom: 0; }
@media (min-width: 760px) { .resp { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Readiness card (example layout) */
.readiness { margin: 0; background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.readiness figcaption { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; padding: .9rem 1.25rem; background: var(--navy); color: var(--on-dark); font-weight: 600; }
.tag { display: inline-block; font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--copper); border: 1px solid var(--copper); border-radius: 3px; padding: .15rem .5rem; }
.readiness-rows { list-style: none; margin: 0; padding: 0 1.25rem; }
.readiness-rows li { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.readiness-rows li:last-child { border-bottom: 0; }
.readiness-rows .row-label { color: var(--navy); font-weight: 500; }
.status { display: inline-flex; align-items: center; gap: .5rem; font-size: .92rem; white-space: nowrap; }
.status svg { width: 1.1rem; height: 1.1rem; flex: none; }
.status-in { color: var(--navy); }
.status-partly { color: var(--copper-deep); }
.status-missing { color: var(--muted); }
.readiness-legend { display: flex; flex-wrap: wrap; gap: 1rem 1.5rem; padding: .9rem 1.25rem; background: var(--bg-alt); border-top: 1px solid var(--line); font-size: .9rem; }
.readiness-legend .status { font-size: inherit; }

/* Generic two-column content blocks */
.two-col { display: grid; gap: var(--gap); }
@media (min-width: 900px) {
  .two-col { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 3rem; }
  .two-col > :first-child h2 { margin-bottom: .5rem; }
}
.plain-list { padding-left: 1.2rem; }
.plain-list li { margin-bottom: .5rem; max-width: var(--measure); }

/* Call to action band */
.cta-band { background: var(--navy); color: var(--on-dark); padding: 3.5rem 0; }
.cta-band h2 { color: var(--on-dark); }
.cta-band p { color: var(--on-dark-muted); }
.cta-band .button-primary { margin-top: .5rem; }

/* Forms */
.form { max-width: 38rem; }
.field { margin-bottom: 1.25rem; }
.field label { display: block; font-weight: 600; color: var(--navy); margin-bottom: .35rem; }
.field .req { color: var(--copper-deep); }
.field input, .field select, .field textarea {
  display: block;
  width: 100%;
  font: inherit;
  color: var(--slate);
  background: var(--bg);
  border: 1px solid #7A8794;
  border-radius: var(--radius);
  padding: .65rem .8rem;
}
.field textarea { min-height: 9rem; resize: vertical; }
.visually-hidden { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin-top: 1.25rem; padding: .9rem 1rem; border-left: 3px solid var(--navy); background: var(--bg-alt); color: var(--navy); }
.form-status.is-error { border-left-color: var(--copper-deep); color: var(--copper-deep); }
.form-status:empty { display: none; }
.form-alt { margin-top: 2rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }

/* Footer */
.site-footer { background: var(--navy); color: var(--on-dark-muted); padding: 3rem 0 2rem; font-size: .95rem; }
.site-footer a { color: var(--on-dark); }
.site-footer a:hover { color: var(--copper); }
.footer-grid { display: grid; gap: 2rem; }
.footer-name { color: var(--on-dark); font-weight: 600; font-size: 1.05rem; margin-bottom: .4rem; }
.footer-tagline { max-width: 40ch; }
.site-footer nav ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; }
.site-footer nav a { text-decoration: none; }
.footer-bottom { margin-top: 2.5rem; padding-top: 1.25rem; border-top: 1px solid rgba(255, 255, 255, .14); }
.footer-bottom p { margin: 0; }
@media (min-width: 760px) {
  .footer-grid { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
  .site-footer nav ul { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Scroll fade-in. Content stays visible without JavaScript. */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  .js .route-path { animation: none; stroke-dashoffset: 0; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media print {
  .site-header, .site-footer, .cta-band, .nav-toggle, .skip-link { display: none; }
}
