/* Ruler ELD — shared styles */
:root {
  --orange: #FF9700;
  --orange-ink: #A95800;      /* orange that passes contrast as text on paper */
  --ink: #1B1B1B;
  --steel: #555C63;
  --paper: #F4F5F2;
  --sheet: #FFFFFF;
  --grid: #DADDD6;
  --grid-soft: #E8EAE5;
  --on-orange: #1B1B1B;
  --focus: #1B1B1B;

  --font: "Archivo", "Helvetica Neue", Arial, system-ui, sans-serif;
  --wrap: 1180px;
  --gutter: clamp(20px, 4vw, 40px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --orange-ink: #FFB24D;
    --ink: #EEEFEC;
    --steel: #A9AFB4;
    --paper: #161819;
    --sheet: #1F2224;
    --grid: #33383B;
    --grid-soft: #2A2E30;
    --focus: #FFB24D;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--paper);
}
.logsheet, .limit .value, .steps li::before { font-variant-numeric: tabular-nums; }
.nav-mobile { display: none; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 2px; }
.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(--sheet); padding: 8px 14px; z-index: 50; }
.skip:focus { left: 8px; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: saturate(140%) blur(8px);
  -webkit-backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--grid);
}
.site-header .wrap { display: flex; align-items: center; gap: 28px; height: 68px; }
.brand { display: block; flex-shrink: 0; }
.brand img { height: 30px; width: auto; }
.nav { display: flex; gap: 26px; margin-left: auto; }
.nav a { text-decoration: none; font-size: .95rem; color: var(--steel); }
.nav a:hover { color: var(--ink); }
.header-actions { display: flex; gap: 10px; align-items: center; }
.menu-btn { display: none; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 .95rem/1 var(--font);
  padding: 13px 20px; border-radius: 6px; text-decoration: none;
  border: 1.5px solid var(--ink); color: var(--ink); background: transparent;
  cursor: pointer; white-space: nowrap;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-primary { background: var(--orange); border-color: var(--orange); color: var(--on-orange); }
.btn-primary:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.btn-sm { padding: 10px 15px; font-size: .9rem; }

@media (max-width: 860px) {
  .nav { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0;
         background: var(--paper); border-bottom: 1px solid var(--grid); padding: 8px var(--gutter) 16px; }
  .nav.open { display: flex; }
  .nav .nav-mobile { display: block; color: var(--orange-ink); font-weight: 600; }
  .nav a { padding: 12px 0; font-size: 1.05rem; color: var(--ink); border-bottom: 1px solid var(--grid-soft); }
  .menu-btn { display: inline-flex; margin-left: auto; background: none; border: 1.5px solid var(--grid); border-radius: 6px;
              padding: 9px 12px; font: 600 .9rem var(--font); color: var(--ink); cursor: pointer; }
  .header-actions .btn-ghost-hide { display: none; }
}

/* ---------- Ruler edge: the brand’s tick-mark motif used as a divider ---------- */
.ruler-edge {
  height: 14px;
  background-image:
    repeating-linear-gradient(90deg, var(--ink) 0 1.5px, transparent 1.5px 60px),
    repeating-linear-gradient(90deg, var(--steel) 0 1px, transparent 1px 15px);
  background-size: 100% 14px, 100% 7px;
  background-repeat: no-repeat;
  opacity: .55;
}

/* ---------- Hero ---------- */
.hero { padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px); }
.hero h1 {
  font-stretch: 112%;
  font-weight: 750;
  font-size: clamp(2.4rem, 6.2vw, 4.75rem);
  line-height: 1.02;
  letter-spacing: -0.025em;
  margin: 0 0 22px;
  max-width: 13ch;
}
.hero .lede { font-size: clamp(1.08rem, 1.6vw, 1.25rem); color: var(--steel); max-width: 52ch; margin: 0 0 32px; }
.hero .ctas { display: flex; flex-wrap: wrap; gap: 12px; }

.logsheet {
  margin-left: 0; margin-right: 0; margin-bottom: 0;
  margin-top: clamp(40px, 6vw, 64px);
  background: var(--sheet);
  border: 1px solid var(--grid);
  border-radius: 10px;
  padding: 18px 18px 14px;
}
.logsheet-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 20px; padding: 0 6px 10px; font-size: .9rem; color: var(--steel); }
.logsheet-head strong { color: var(--ink); font-weight: 600; }
.logsheet-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.logsheet svg { display: block; width: 100%; min-width: 680px; height: auto; }
.logsheet .t-label { font: 600 13px var(--font); fill: var(--ink); }
.logsheet .t-hour { font: 500 11px var(--font); fill: var(--steel); }
.logsheet .t-total { font: 600 13px var(--font); fill: var(--ink); font-variant-numeric: tabular-nums; }
.logsheet .t-dim { font: 600 12px var(--font); fill: var(--orange-ink); }
.logsheet .row-line { stroke: var(--grid); stroke-width: 1; }
.logsheet .hr-line { stroke: var(--grid); stroke-width: 1; }
.logsheet .q-tick { stroke: var(--grid); stroke-width: 1; }
.logsheet .tick-major { stroke: var(--ink); stroke-width: 1.5; }
.logsheet .tick-minor { stroke: var(--steel); stroke-width: 1; }
.logsheet .dim { stroke: var(--orange-ink); stroke-width: 1.25; fill: none; }
.logsheet .duty {
  fill: none; stroke: var(--orange); stroke-width: 4; stroke-linejoin: round; stroke-linecap: round;
  stroke-dasharray: 2400; stroke-dashoffset: 2400;
  animation: draw 2.4s cubic-bezier(.45,.05,.3,1) .3s forwards;
}
@keyframes draw { to { stroke-dashoffset: 0; } }
@media (prefers-reduced-motion: reduce) { .logsheet .duty { animation: none; stroke-dashoffset: 0; } }
.logsheet-foot { padding: 10px 6px 0; font-size: .85rem; color: var(--steel); }

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 9vw, 112px) 0; }
.section + .section { border-top: 1px solid var(--grid); }
.section-head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; margin-bottom: clamp(32px, 5vw, 56px); max-width: 720px; }
.section h2 {
  font-stretch: 108%; font-weight: 700;
  font-size: clamp(1.9rem, 3.6vw, 2.75rem); line-height: 1.08; letter-spacing: -0.02em; margin: 0;
}
.section-head p { margin: 0; color: var(--steel); font-size: 1.1rem; max-width: 60ch; }

/* Spec sheet feature list */
.spec { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(32px, 5vw, 72px); }
.spec-item { padding: 24px 0 26px; border-top: 1.5px solid var(--ink); position: relative; }
.spec-item::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 8px;
  background: repeating-linear-gradient(90deg, var(--ink) 0 1px, transparent 1px 24px);
  opacity: .35;
}
.spec-item h3 { font-size: 1.2rem; font-weight: 650; margin: 6px 0 8px; letter-spacing: -0.01em; }
.spec-item p { margin: 0; color: var(--steel); max-width: 48ch; }
@media (max-width: 760px) { .spec { grid-template-columns: minmax(0, 1fr); } }

/* HOS limits scale */
.limits { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); border-left: 1.5px solid var(--ink); }
.limit { padding: 4px 20px 0; border-right: 1px solid var(--grid); }
.limit .value { font-stretch: 115%; font-weight: 750; font-size: clamp(2rem, 4vw, 3.1rem); line-height: 1; letter-spacing: -0.03em; }
.limit .value small { font-size: .45em; font-weight: 600; letter-spacing: 0; margin-left: 2px; color: var(--steel); }
.limit p { margin: 12px 0 0; color: var(--steel); font-size: .97rem; }
.limits-note { margin-top: 28px; font-size: .9rem; color: var(--steel); max-width: 70ch; }
@media (max-width: 960px) { .limits { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 32px; } }
@media (max-width: 520px) { .limits { grid-template-columns: minmax(0, 1fr); } .limit { border-right: 0; } }

/* Two-up: driver app / dashboard */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); }
.panel { background: var(--sheet); border: 1px solid var(--grid); border-radius: 10px; padding: clamp(24px, 3.5vw, 40px); }
.panel h3 { font-stretch: 108%; font-size: 1.5rem; margin: 0 0 10px; letter-spacing: -0.015em; }
.panel p { margin: 0 0 18px; color: var(--steel); }
.panel ul { margin: 0; padding: 0; list-style: none; }
.panel li { padding: 10px 0 10px 26px; border-top: 1px solid var(--grid-soft); position: relative; }
.panel li::before { content: ""; position: absolute; left: 0; top: 19px; width: 14px; height: 2px; background: var(--orange); }
.panel .panel-link { display: inline-block; margin-top: 22px; font-weight: 600; color: var(--orange-ink); }
@media (max-width: 860px) { .split { grid-template-columns: minmax(0, 1fr); } }

/* Steps (a real sequence) */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; counter-reset: step; }
.steps li { counter-increment: step; padding: 0 24px 0 0; position: relative; }
.steps li::before {
  content: counter(step); display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%; background: var(--orange); color: var(--on-orange);
  font-weight: 700; margin-bottom: 18px; position: relative; z-index: 1;
}
.steps li::after { content: ""; position: absolute; top: 20px; left: 40px; right: 0; height: 1.5px; background: var(--grid); }
.steps li:last-child::after { display: none; }
.steps h3 { margin: 0 0 6px; font-size: 1.1rem; font-weight: 650; }
.steps p { margin: 0; color: var(--steel); font-size: .98rem; max-width: 30ch; }
@media (max-width: 860px) {
  .steps { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .steps li { padding: 0 0 0 60px; }
  .steps li::before { position: absolute; left: 0; top: 0; margin: 0; }
  .steps li::after { top: 44px; bottom: -24px; left: 19px; right: auto; width: 1.5px; height: auto; }
}

/* FAQ */
.faq { max-width: 820px; }
.faq details { border-top: 1px solid var(--grid); }
.faq details:last-child { border-bottom: 1px solid var(--grid); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 44px 22px 0; position: relative;
  font-weight: 600; font-size: 1.12rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 6px; top: 50%; width: 14px; height: 14px; margin-top: -7px;
  background:
    linear-gradient(var(--ink), var(--ink)) center/14px 2px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center/2px 14px no-repeat;
  transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .answer { padding: 0 0 24px; color: var(--steel); max-width: 66ch; }
.faq .answer p { margin: 0 0 10px; }
@media (prefers-reduced-motion: reduce) { .faq summary::after { transition: none; } }

/* Contact band */
.contact { background: var(--orange); color: #1B1B1B; }
.contact .wrap { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 40px; align-items: end; padding-top: clamp(56px, 8vw, 96px); padding-bottom: clamp(56px, 8vw, 96px); }
.contact h2 { color: #1B1B1B; font-stretch: 108%; font-weight: 700; font-size: clamp(1.9rem, 3.6vw, 2.75rem); line-height: 1.08; letter-spacing: -0.02em; margin: 0; }
.contact p { margin: 16px 0 0; font-size: 1.12rem; max-width: 46ch; }
.contact .contact-lines { display: grid; gap: 14px; justify-items: start; }
.contact .mail { font-stretch: 108%; font-weight: 700; font-size: clamp(1.3rem, 2.6vw, 1.85rem); color: #1B1B1B; text-decoration-thickness: 2px; text-underline-offset: 5px; word-break: break-word; }
.contact .btn { border-color: #1B1B1B; color: #1B1B1B; }
.contact .btn:hover { background: #1B1B1B; color: #FF9700; }
.contact :focus-visible { outline-color: #1B1B1B; }
@media (max-width: 860px) { .contact .wrap { grid-template-columns: minmax(0, 1fr); align-items: start; } }

/* ---------- Footer ---------- */
.site-footer { padding: 56px 0 36px; font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr)); gap: 32px; }
.footer-grid img { height: 28px; width: auto; margin-bottom: 14px; }
.footer-grid p { margin: 0; color: var(--steel); max-width: 36ch; }
.footer-grid h4 { margin: 0 0 12px; font-size: .95rem; font-weight: 650; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-grid a { color: var(--steel); text-decoration: none; }
.footer-grid a:hover { color: var(--ink); text-decoration: underline; }
.footer-base { margin-top: 44px; padding-top: 20px; border-top: 1px solid var(--grid); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--steel); font-size: .88rem; }
.footer-base nav { display: flex; gap: 18px; }
.footer-base a { color: var(--steel); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* ---------- Legal pages ---------- */
.legal-hero { padding: clamp(44px, 7vw, 80px) 0 0; }
.legal-hero h1 { font-stretch: 110%; font-weight: 750; font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.05; letter-spacing: -0.025em; margin: 0 0 14px; }
.legal-hero p { margin: 0; color: var(--steel); font-size: 1.12rem; max-width: 60ch; }
.legal-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 32px 0 0; padding-bottom: 0; border-bottom: 1px solid var(--grid); }
.legal-tabs a {
  text-decoration: none; padding: 12px 16px; font-weight: 600; font-size: .95rem; color: var(--steel);
  border-bottom: 3px solid transparent; margin-bottom: -1px;
}
.legal-tabs a:hover { color: var(--ink); }
.legal-tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--orange); }

.legal-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); padding: 48px 0 96px; }
.legal-layout.no-toc { grid-template-columns: minmax(0, 1fr); }
.toc { position: sticky; top: 92px; align-self: start; font-size: .9rem; max-height: calc(100vh - 120px); overflow-y: auto; }
.toc h2 { font-size: .9rem; font-weight: 650; margin: 0 0 10px; }
.toc ol { list-style: none; margin: 0 0 20px; padding: 0 0 0 12px; border-left: 1.5px solid var(--grid); display: grid; gap: 6px; }
.toc a { text-decoration: none; color: var(--steel); }
.toc a:hover { color: var(--ink); }
@media (max-width: 900px) { .legal-layout { grid-template-columns: minmax(0, 1fr); } .toc { position: static; max-height: none; } }

.prose { max-width: 72ch; }
.prose .meta { display: inline-block; font-size: .9rem; color: var(--steel); background: var(--sheet); border: 1px solid var(--grid); border-radius: 6px; padding: 8px 12px; margin: 0 0 28px; }
.prose h2 { font-stretch: 108%; font-size: 1.85rem; line-height: 1.15; letter-spacing: -0.015em; margin: 56px 0 16px; padding-top: 18px; border-top: 1.5px solid var(--ink); scroll-margin-top: 90px; }
.prose h2:first-child, .prose .meta + h2 { margin-top: 0; }
.prose h3 { font-size: 1.2rem; font-weight: 650; margin: 34px 0 10px; scroll-margin-top: 90px; }
.prose h4 { font-size: 1.02rem; font-weight: 650; margin: 24px 0 6px; }
.prose p, .prose li { color: var(--ink); }
.prose p { margin: 0 0 14px; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 1.3em; }
.prose li { margin: 0 0 8px; }
.prose li::marker { color: var(--orange-ink); }
.prose a { color: var(--orange-ink); text-underline-offset: 3px; }
.prose dl { margin: 0 0 16px; }
.prose dt { font-weight: 650; margin-top: 16px; }
.prose dd { margin: 4px 0 0; color: var(--steel); }
.prose .address { background: var(--sheet); border: 1px solid var(--grid); border-left: 4px solid var(--orange); border-radius: 6px; padding: 14px 18px; margin: 0 0 16px; }
.prose .updated { margin-top: 40px; color: var(--steel); font-size: .92rem; }
