/* Gate 180 — Optical Instrument & Specification Sheet (Self-Hosted Schibsted Grotesk + B612 Mono) */

@font-face {
  font-family: 'Schibsted Grotesk';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/schibsted-grotesk-400.woff2') format('woff2');
}

@font-face {
  font-family: 'Schibsted Grotesk';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/schibsted-grotesk-500.woff2') format('woff2');
}

@font-face {
  font-family: 'Schibsted Grotesk';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/schibsted-grotesk-600.woff2') format('woff2');
}

@font-face {
  font-family: 'Schibsted Grotesk';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/schibsted-grotesk-700.woff2') format('woff2');
}

@font-face {
  font-family: 'B612 Mono';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/b612-mono-400.woff2') format('woff2');
}

@font-face {
  font-family: 'B612 Mono';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/b612-mono-700.woff2') format('woff2');
}

:root {
  --bg: #10100e;
  --bg-subtle: #161613;
  --rule: #282723;
  --rule-strong: #3d3b35;
  --ink: #ece8df;
  --ink-muted: #9c978d;
  --ink-dim: #6b675f;
  --vermilion: #d83b28;
  --ochre: #c89b54;
  --font-sans: 'Schibsted Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'B612 Mono', monospace;
  --sheet-w: 1080px;
  --legal-w: 780px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  background-color: var(--bg);
  color: var(--ink);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 400;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--vermilion);
  color: #ffffff;
  padding: 0.5rem 0.9rem;
  z-index: 1000;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-decoration: none;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

/* Outer Ground-Glass Sheet Frame */
.sheet-shell {
  width: 100%;
  max-width: var(--sheet-w);
  margin: 0 auto;
  padding: 0 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

/* Top Margin Rule — Unboxed, Architectural */
.site-header {
  border-bottom: 1px solid var(--rule);
}

.header-inner {
  max-width: var(--sheet-w);
  margin: 0 auto;
  padding: 1.35rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.98rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand-mark {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transform: translateY(3px);
}

.brand-coord {
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--ink-dim);
  margin-left: 0.35rem;
}

@media (max-width: 640px) {
  .brand-coord {
    display: none;
  }
}

.nav-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 1.35rem;
}

.nav-bar a {
  color: var(--ink-muted);
  text-decoration: none;
  font-size: 0.84rem;
  padding: 0.15rem 0;
  border-bottom: 1px solid transparent;
  transition: color 0.14s ease, border-color 0.14s ease;
}

.nav-bar a:hover,
.nav-bar a:focus-visible {
  color: var(--ink);
  border-bottom-color: var(--ink-muted);
}

.nav-bar a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--vermilion);
  font-weight: 600;
}

.lang-switch {
  font-family: var(--font-mono);
  font-size: 0.74rem !important;
  color: var(--ink) !important;
  letter-spacing: 0.06em;
  margin-left: 0.25rem;
}

main {
  flex: 1;
  width: 100%;
}

/* ==========================================================================
   Landing Sheet — Asymmetric 12-Col Swiss Optical Grid (Zero Cards / Plates)
   ========================================================================== */

.optical-sheet {
  max-width: var(--sheet-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  border-bottom: 1px solid var(--rule);
  position: relative;
}

@media (min-width: 860px) {
  .hero-grid {
    grid-template-columns: 7fr 5fr;
  }
}

/* '+' Ground-Glass Crosshair Marks at Intersections */
.crosshair {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1;
  color: var(--rule-strong);
  user-select: none;
  pointer-events: none;
}

.ch-bl { bottom: -7px; left: -4px; }
.ch-br { bottom: -7px; right: -4px; }

.hero-copy {
  padding: 3.8rem 0 3.4rem;
}

@media (min-width: 860px) {
  .hero-copy {
    padding: 4.8rem 3.4rem 4.2rem 0;
    border-right: 1px solid var(--rule);
  }
}

.engraved-kicker {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.09em;
  color: var(--ochre);
  text-transform: uppercase;
  margin: 0 0 1.65rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.tally-mark {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--vermilion);
}

.hero-title {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: clamp(2.15rem, 4.1vw, 3.35rem);
  line-height: 1.09;
  letter-spacing: -0.028em;
  color: var(--ink);
  margin: 0 0 1.65rem;
  max-width: 18ch;
}

.hero-prose {
  max-width: 52ch;
  font-size: 1.04rem;
  line-height: 1.7;
  color: var(--ink-muted);
  margin: 0 0 1.15rem;
}

.hero-prose:last-of-type {
  margin-bottom: 0;
}

.hero-prose strong {
  color: var(--ink);
  font-weight: 600;
}

/* Right Column: Drafted Mechanical 180° Shutter Schematic */
.hero-diagram {
  padding: 2.6rem 0 3rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
}

@media (min-width: 860px) {
  .hero-diagram {
    padding: 3.6rem 0 3.2rem 3rem;
    align-items: flex-end;
  }
}

.schematic-svg {
  width: 100%;
  max-width: 310px;
  height: auto;
  display: block;
}

.diagram-caption {
  width: 100%;
  max-width: 310px;
  margin-top: 1.5rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.69rem;
  letter-spacing: 0.06em;
  color: var(--ink-dim);
}

/* Technical Specification Ledger (Pure Hairlines — Zero Plates) */
.ledger-section {
  display: grid;
  grid-template-columns: 1fr;
  padding: 2.8rem 0;
  border-bottom: 1px solid var(--rule);
  gap: 1.5rem;
}

@media (min-width: 860px) {
  .ledger-section {
    grid-template-columns: 3fr 9fr;
    gap: 3rem;
    padding: 3.2rem 0;
  }
}

.section-index {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin: 0;
  padding-top: 0.25rem;
}

.spec-ledger {
  margin: 0;
}

.spec-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.25rem;
  padding: 0.95rem 0;
  border-top: 1px solid var(--rule);
}

.spec-row:first-child {
  padding-top: 0;
  border-top: 0;
}

.spec-row:last-child {
  padding-bottom: 0;
}

@media (min-width: 640px) {
  .spec-row {
    grid-template-columns: 190px 1fr;
    gap: 1.75rem;
    align-items: baseline;
  }
}

.spec-row dt {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-transform: uppercase;
}

.spec-row dd {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ink-muted);
  line-height: 1.6;
}

/* Personal Maker's Note / Lab Dispatch */
.note-section {
  display: grid;
  grid-template-columns: 1fr;
  padding: 2.8rem 0 3.6rem;
  gap: 1.25rem;
}

@media (min-width: 860px) {
  .note-section {
    grid-template-columns: 3fr 9fr;
    gap: 3rem;
    padding: 3.1rem 0 4rem;
  }
}

.maker-note {
  max-width: 58ch;
}

.maker-note p {
  font-size: 0.98rem;
  color: var(--ink-muted);
  margin: 0 0 0.95rem;
}

.maker-signoff {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--ink);
  letter-spacing: 0.03em;
  margin-top: 1.15rem !important;
}

/* Hairline FAQ Section (Organic Search + Technical Clarity) */
.faq-section {
  display: grid;
  grid-template-columns: 1fr;
  padding: 2.8rem 0 3.6rem;
  border-top: 1px solid var(--rule);
  gap: 1.5rem;
}

@media (min-width: 860px) {
  .faq-section {
    grid-template-columns: 3fr 9fr;
    gap: 3rem;
    padding: 3.1rem 0 4rem;
  }
}

.faq-list {
  margin: 0;
}

.faq-item {
  padding: 1.1rem 0;
  border-top: 1px solid var(--rule);
}

.faq-item:first-child {
  padding-top: 0;
  border-top: 0;
}

.faq-item:last-child {
  padding-bottom: 0;
}

.faq-item h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--ink);
  margin: 0 0 0.45rem;
}

.faq-item p {
  font-size: 0.93rem;
  color: var(--ink-muted);
  margin: 0;
  line-height: 1.65;
}

/* ==========================================================================
   Legal Subpages Container
   ========================================================================== */

.legal-container {
  max-width: var(--legal-w);
  margin: 0 auto;
  padding: 3.2rem 1.5rem 4.5rem;
}

.legal-container h1,
.legal-container h2,
.legal-container h3,
.legal-container h4 {
  color: var(--ink);
  font-weight: 600;
  line-height: 1.26;
  letter-spacing: -0.018em;
}

.legal-container h1 {
  font-size: clamp(1.75rem, 3.2vw, 2.2rem);
  margin-top: 0;
  margin-bottom: 0.85rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid var(--rule-strong);
}

.legal-container h2 {
  font-size: 1.22rem;
  margin-top: 2.4rem;
  margin-bottom: 0.75rem;
  scroll-margin-top: 2rem;
}

.legal-container h3 {
  font-size: 1.03rem;
  margin-top: 1.55rem;
  margin-bottom: 0.45rem;
}

p, ul, ol, table, blockquote, pre {
  margin-top: 0;
  margin-bottom: 1.05rem;
}

ul, ol {
  padding-left: 1.35rem;
}

li {
  margin-bottom: 0.4rem;
  color: var(--ink-muted);
}

li strong {
  color: var(--ink);
}

.legal-container p {
  color: var(--ink-muted);
}

.legal-container p strong {
  color: var(--ink);
}

a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--rule-strong);
  text-underline-offset: 3px;
  transition: text-decoration-color 0.14s ease, color 0.14s ease;
}

a:hover,
a:focus-visible {
  color: #ffffff;
  text-decoration-color: var(--vermilion);
}

hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin: 2rem 0;
}

code {
  font-family: var(--font-mono);
  font-size: 0.82em;
  background-color: var(--bg-subtle);
  color: var(--ink);
  padding: 0.12rem 0.35rem;
  border: 1px solid var(--rule);
}

pre {
  background-color: var(--bg-subtle);
  border: 1px solid var(--rule);
  padding: 1rem 1.15rem;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.52;
  color: var(--ink-muted);
}

pre code {
  background: none;
  border: 0;
  padding: 0;
}

.callout {
  background-color: var(--bg-subtle);
  border-left: 2px solid var(--vermilion);
  border-top: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  padding: 1rem 1.2rem;
  margin: 1.45rem 0;
}

.callout p:last-child {
  margin-bottom: 0;
}

blockquote {
  border-left: 2px solid var(--rule-strong);
  margin-left: 0;
  padding: 0.35rem 0 0.35rem 1.15rem;
  color: var(--ink-muted);
}

.table-wrap {
  overflow-x: auto;
  margin: 1.25rem 0;
}

table {
  width: 100%;
  border-collapse: collapse;
  border-top: 1px solid var(--rule-strong);
  border-bottom: 1px solid var(--rule-strong);
  font-size: 0.89rem;
}

th, td {
  text-align: left;
  vertical-align: top;
  padding: 0.75rem 0.85rem;
  border-bottom: 1px solid var(--rule);
  color: var(--ink-muted);
}

th {
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 400;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background-color: var(--bg-subtle);
}

/* Global Mandatory 1-Click Legal Footer */
.site-footer {
  border-top: 1px solid var(--rule);
  padding: 1.85rem 1.5rem 2.4rem;
  font-size: 0.82rem;
  color: var(--ink-dim);
}

.footer-inner {
  max-width: var(--sheet-w);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.9rem 2rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1.35rem;
}

.footer-links a {
  color: var(--ink-muted);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--ink-dim);
}

@media print {
  :root {
    --bg: #ffffff;
    --bg-subtle: #f5f5f4;
    --rule: #d6d3d1;
    --rule-strong: #78716c;
    --ink: #111110;
    --ink-muted: #292524;
    --ink-dim: #57534e;
  }
  .nav-bar, .skip-link {
    display: none;
  }
  a {
    color: #000000;
    text-decoration: underline;
  }
}
