/* ============================================================
   RSC RIVERSIDE — VARIANT C "THE PRECISION"
   Construction-document design system. Steel surfaces,
   blueprint navy, hairline grid, mono metadata, titleblock
   footer. Safety orange as a 1% micro-accent.
   Type: IBM Plex Sans / IBM Plex Mono.
   ============================================================ */

:root {
  --steel: #e9ebee;
  --panel: #f4f5f7;
  --ink: #14181d;
  --navy: #12294b;
  --navy-2: #0d1f3a;
  --grid: rgba(18, 41, 75, 0.10);
  --rule: rgba(18, 41, 75, 0.22);
  --gray: #5a6472;
  --orange: #e8641b;
  --sans: "IBM Plex Sans", "Helvetica Neue", sans-serif;
  --mono: "IBM Plex Mono", "Menlo", monospace;
  --pad: clamp(1.25rem, 4vw, 4rem);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    var(--steel);
  background-size: 48px 48px, 48px 48px, auto;
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

::selection { background: var(--navy); color: var(--steel); }

/* ---------- type ---------- */

h1, h2, h3 { font-weight: 600; line-height: 1.08; letter-spacing: -0.015em; color: var(--navy); }

.tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
  margin-bottom: 1.2rem;
}

.tag::before { content: "// "; color: var(--orange); }

.lede { color: var(--gray); max-width: 42rem; font-size: 1.08rem; }

/* ---------- registration marks ---------- */

.regmark {
  position: relative;
}

.regmark::before, .regmark::after {
  content: "+";
  position: absolute;
  font-family: var(--mono);
  font-size: 0.8rem;
  color: var(--rule);
}

.regmark::before { top: 0.6rem; left: 0.8rem; }
.regmark::after { bottom: 0.6rem; right: 0.8rem; }

/* ---------- header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--panel);
  border-bottom: 2px solid var(--navy);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.85rem var(--pad);
}

.brand { display: flex; align-items: center; gap: 1rem; }

.brand img { height: 40px; width: auto; }

.brand .brand-meta {
  font-family: var(--mono);
  font-size: 0.62rem;
  line-height: 1.5;
  color: var(--gray);
  border-left: 1px solid var(--rule);
  padding-left: 1rem;
  text-transform: uppercase;
}

.site-nav { display: flex; align-items: center; gap: 1.6rem; }

.site-nav a {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray);
  transition: color 0.2s;
}

.site-nav a:hover { color: var(--navy); }

.site-nav a.active { color: var(--navy); border-bottom: 2px solid var(--orange); }

.site-nav a.nav-cta {
  background: var(--navy);
  color: var(--steel);
  padding: 0.65rem 1.2rem;
  transition: background 0.2s;
}

.site-nav a.nav-cta:hover { background: var(--orange); color: #fff; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--rule);
  color: var(--navy);
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.55rem 1rem;
  cursor: pointer;
}

/* ---------- hero ---------- */

.hero {
  background: var(--navy);
  color: var(--steel);
  border-bottom: 2px solid var(--navy);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(17rem, 3fr);
  min-height: 78vh;
}

.hero-main {
  padding: clamp(4rem, 12vh, 8rem) var(--pad);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.hero-main .tag { color: rgba(233, 235, 238, 0.65); }

.hero h1 {
  color: #fff;
  font-size: clamp(2.5rem, 6.5vw, 5.4rem);
  font-weight: 650;
  max-width: 16ch;
}

.hero h1 .u { border-bottom: 4px solid var(--orange); }

.hero .lede { color: rgba(233, 235, 238, 0.72); margin-top: 1.8rem; }

.hero-actions { margin-top: 2.6rem; display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-side {
  border-left: 1px solid rgba(233, 235, 238, 0.2);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.hero-side .datum {
  padding: 1.4rem 1.8rem;
  border-top: 1px solid rgba(233, 235, 238, 0.2);
  font-family: var(--mono);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(233, 235, 238, 0.65);
}

.hero-side .datum b {
  display: block;
  font-family: var(--sans);
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: 0;
  color: #fff;
  text-transform: none;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.95rem 1.9rem;
  border: 1px solid var(--steel);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.btn-solid { background: var(--orange); border-color: var(--orange); color: #fff; }
.btn-solid:hover { background: #fff; color: var(--navy); border-color: #fff; }

.btn-ghost { color: var(--steel); }
.btn-ghost:hover { background: var(--steel); color: var(--navy); }

.on-light .btn-ghost, .btn-ghost.dark { color: var(--navy); border-color: var(--navy); }
.on-light .btn-ghost:hover, .btn-ghost.dark:hover { background: var(--navy); color: var(--steel); }

/* ---------- sections ---------- */

.section { padding: clamp(4rem, 9vh, 7rem) var(--pad); }

.section.boxed .inner {
  background: var(--panel);
  border: 1px solid var(--rule);
  padding: clamp(2rem, 5vw, 4rem);
}

.sec-head { margin-bottom: 3rem; max-width: 62rem; }

.sec-head h2 { font-size: clamp(1.7rem, 3.6vw, 2.8rem); }

.sec-head .lede { margin-top: 1rem; }

/* ---------- spec sheet cards ---------- */

.sheet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(21rem, 1fr));
  gap: 1.5rem;
}

.sheet {
  background: var(--panel);
  border: 1px solid var(--navy);
  display: flex;
  flex-direction: column;
}

.sheet.hidden { display: none; }

.sheet .sheet-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.55rem 0.9rem;
  border-bottom: 1px solid var(--navy);
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray);
}

.sheet .sheet-head .no { color: var(--orange); }

.sheet .frame { border-bottom: 1px solid var(--navy); }

.sheet .frame img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }

.sheet .body { padding: 1.25rem 1.4rem 1.5rem; flex: 1; }

.sheet h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }

.sheet p { color: var(--gray); font-size: 0.92rem; }

.sheet .specs {
  border-top: 1px solid var(--rule);
  margin-top: 1rem;
  padding-top: 0.8rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--gray);
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.25rem 1.25rem;
}

.sheet .specs dt { color: var(--navy); font-weight: 500; }

/* ---------- service schedule (table) ---------- */

.schedule { border: 1px solid var(--navy); background: var(--panel); }

.schedule-row {
  display: grid;
  grid-template-columns: 7rem minmax(14rem, 1.4fr) 2.5fr;
  border-bottom: 1px solid var(--rule);
}

.schedule-row:last-child { border-bottom: none; }

.schedule-row > * { padding: 1.35rem 1.5rem; }

.schedule-row .code {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--gray);
  border-right: 1px solid var(--rule);
  text-transform: uppercase;
}

.schedule-row h3 { font-size: 1.08rem; }

.schedule-row p { color: var(--gray); font-size: 0.93rem; }

div.schedule-row:hover { background: rgba(18, 41, 75, 0.04); }

/* ---------- stats board ---------- */

.board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--navy);
  background: var(--navy);
  gap: 1px;
}

.board .cell {
  background: var(--panel);
  padding: 2.2rem 1.8rem;
}

.board .cell .num {
  font-size: clamp(2.2rem, 4.5vw, 3.6rem);
  font-weight: 300;
  color: var(--navy);
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}

.board .cell .num sup { font-size: 0.45em; color: var(--orange); }

.board .cell .label {
  margin-top: 0.7rem;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gray);
}

/* ---------- split ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
}

.split .frame { border: 1px solid var(--navy); background: var(--panel); padding: 0.6rem; }

.split .frame img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }

.split .frame .cap {
  font-family: var(--mono);
  font-size: 0.66rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--gray);
  padding: 0.6rem 0.2rem 0.1rem;
}

.split h2 { font-size: clamp(1.6rem, 3.2vw, 2.5rem); margin-bottom: 1.2rem; }

.split p { color: var(--gray); }

.split p + p { margin-top: 1rem; }

/* ---------- client manifest ---------- */

.manifest { border: 1px solid var(--navy); background: var(--panel); }

.manifest-row {
  display: grid;
  grid-template-columns: 4rem minmax(12rem, 1.5fr) 2fr 7rem;
  align-items: center;
  border-bottom: 1px solid var(--rule);
}

.manifest-row:last-child { border-bottom: none; }

.manifest-row > * { padding: 1.1rem 1.4rem; }

.manifest-row .idx {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--gray);
  border-right: 1px solid var(--rule);
}

.manifest-row .client { font-weight: 600; color: var(--navy); font-size: 1.05rem; }

.manifest-row .scope { color: var(--gray); font-size: 0.9rem; }

.manifest-row .sector {
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--orange);
  text-align: right;
}

/* ---------- team roster ---------- */

.roster-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: 1.25rem;
}

.roster-grid.owners { grid-template-columns: repeat(3, minmax(0, 1fr)); max-width: 56rem; margin-bottom: 3rem; }

.crew {
  background: var(--panel);
  border: 1px solid var(--navy);
}

.crew img { width: 100%; aspect-ratio: 1; object-fit: cover; border-bottom: 1px solid var(--navy); }

.crew .body { padding: 0.85rem 1rem 1rem; }

.crew .name { font-weight: 600; color: var(--navy); font-size: 0.98rem; }

.crew .role {
  font-family: var(--mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray);
  margin-top: 0.3rem;
}

.crew .role::before { content: "▸ "; color: var(--orange); }

/* ---------- controls (pillars) ---------- */

.controls {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.control {
  background: var(--panel);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--navy);
  padding: 1.6rem 1.6rem 1.8rem;
}

.control .code {
  font-family: var(--mono);
  font-size: 0.64rem;
  color: var(--orange);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.control h3 { font-size: 1.05rem; margin: 0.5rem 0 0.5rem; }

.control p { color: var(--gray); font-size: 0.9rem; }

/* ---------- filters ---------- */

.filters { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2.5rem; }

.filters button {
  background: var(--panel);
  border: 1px solid var(--rule);
  color: var(--gray);
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.6rem 1.1rem;
  cursor: pointer;
  transition: all 0.2s;
}

.filters button:hover { border-color: var(--navy); color: var(--navy); }

.filters button.active { background: var(--navy); border-color: var(--navy); color: var(--steel); }

/* ---------- CTA band ---------- */

.cta-band {
  background: var(--navy);
  color: var(--steel);
  padding: clamp(4.5rem, 12vh, 8rem) var(--pad);
  text-align: center;
  position: relative;
}

.cta-band h2 { color: #fff; font-size: clamp(1.9rem, 4.6vw, 3.6rem); max-width: 24ch; margin: 0 auto 1.4rem; }

.cta-band p { color: rgba(233, 235, 238, 0.72); max-width: 36rem; margin: 0 auto 2.4rem; }

.cta-band .tag { color: rgba(233, 235, 238, 0.6); }

/* ---------- page hero (interior) ---------- */

.page-hero {
  background: var(--navy);
  color: var(--steel);
  padding: clamp(3.5rem, 9vh, 6rem) var(--pad);
  position: relative;
}

.page-hero .tag { color: rgba(233, 235, 238, 0.65); }

.page-hero h1 { color: #fff; font-size: clamp(2.1rem, 5.2vw, 4rem); max-width: 20ch; }

.page-hero .lede { color: rgba(233, 235, 238, 0.72); margin-top: 1.4rem; }

/* ---------- contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: 5fr 3fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

form.inquiry {
  background: var(--panel);
  border: 1px solid var(--navy);
  padding: clamp(1.5rem, 4vw, 2.8rem);
}

.field { margin-bottom: 1.4rem; }

.field label {
  display: block;
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--navy);
  margin-bottom: 0.45rem;
}

.field input, .field select, .field textarea {
  width: 100%;
  background: #fff;
  border: 1px solid var(--rule);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 0.97rem;
  padding: 0.8rem 0.9rem;
}

.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--orange);
  outline-offset: -1px;
}

.field textarea { min-height: 8rem; resize: vertical; }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }

.form-note { font-size: 0.85rem; color: var(--gray); margin-top: 1.2rem; }

.form-thanks {
  font-family: var(--mono);
  font-size: 0.95rem;
  color: var(--navy);
  border: 1px dashed var(--navy);
  padding: 1.8rem;
}

.contact-info {
  background: var(--panel);
  border: 1px solid var(--rule);
  padding: 1.8rem;
}

.contact-info h3 {
  font-family: var(--mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--orange);
  margin: 1.4rem 0 0.2rem;
}

.contact-info h3:first-child { margin-top: 0; }

.contact-info p { color: var(--gray); }

.contact-info a { color: var(--navy); border-bottom: 1px solid var(--rule); }

.contact-info a:hover { color: var(--orange); }

/* ---------- titleblock footer ---------- */

.titleblock {
  margin: 0 var(--pad) 2.5rem;
  border: 2px solid var(--navy);
  background: var(--panel);
}

.tb-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  border-bottom: 1px solid var(--navy);
}

.tb-cell {
  padding: 1rem 1.25rem;
  border-right: 1px solid var(--navy);
}

.tb-cell:last-child { border-right: none; }

.tb-cell .k {
  font-family: var(--mono);
  font-size: 0.6rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray);
  display: block;
  margin-bottom: 0.3rem;
}

.tb-cell .v { font-weight: 600; color: var(--navy); font-size: 0.95rem; }

.tb-cell img { height: 34px; width: auto; }

.tb-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.8rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--navy);
}

.tb-nav a {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray);
}

.tb-nav a:hover { color: var(--orange); }

.tb-base {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  padding: 0.8rem 1.25rem;
  font-family: var(--mono);
  font-size: 0.64rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--gray);
}

.site-footer { padding-top: 3rem; }

/* ---------- reveal ---------- */

.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s ease, transform 0.6s ease; }

.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

a:focus-visible, button:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }

/* ---------- responsive ---------- */

@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-side { flex-direction: row; flex-wrap: wrap; border-left: none; border-top: 1px solid rgba(233,235,238,0.2); }
  .hero-side .datum { flex: 1 1 10rem; border-top: none; border-right: 1px solid rgba(233,235,238,0.2); }
  .board { grid-template-columns: repeat(2, 1fr); }
  .split, .contact-grid { grid-template-columns: 1fr; }
  .controls { grid-template-columns: repeat(2, 1fr); }
  .schedule-row { grid-template-columns: 5.5rem 1fr; }
  .schedule-row p { grid-column: 2; padding-top: 0; }
  .manifest-row { grid-template-columns: 3rem 1fr auto; }
  .manifest-row .scope { display: none; }
  .roster-grid.owners { grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); }
  .tb-top { grid-template-columns: 1fr 1fr; }
  .tb-cell:nth-child(2) { border-right: none; }
}

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  .brand .brand-meta { display: none; }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: var(--panel);
    border-bottom: 2px solid var(--navy);
    padding: 0.5rem var(--pad) 1.25rem;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 0.8rem 0; width: 100%; border-bottom: 1px solid var(--rule); }
  .site-nav a.nav-cta { margin-top: 0.8rem; text-align: center; }
  .controls { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .board { grid-template-columns: 1fr 1fr; }
}
