/* Optimus Industries — base styles */
:root {
  --navy-900: #070c18;
  --navy-800: #0b1322;
  --navy-700: #111b2e;
  --navy-600: #17223a;
  --navy-500: #1f2d49;
  --line: rgba(201, 162, 74, 0.18);
  --line-strong: rgba(201, 162, 74, 0.35);
  --gold: #c9a24a;
  --gold-bright: #e0b85c;
  --gold-deep: #9e7d34;
  --ivory: #f4ecd8;
  --ink-dim: rgba(244, 236, 216, 0.55);
  --ink-faint: rgba(244, 236, 216, 0.35);
  --ink: #e8e2d0;

  --display: 'Cormorant Garamond', 'EB Garamond', serif;
  --body: 'Inter', system-ui, sans-serif;
  --mono: 'JetBrains Mono', 'IBM Plex Mono', ui-monospace, monospace;
}

[data-type='classic'] {
  --display: 'Cormorant Garamond', serif;
  --body: 'Inter', system-ui, sans-serif;
}
[data-type='editorial'] {
  --display: 'Playfair Display', serif;
  --body: 'Lora', Georgia, serif;
}
[data-type='modern'] {
  --display: 'Fraunces', serif;
  --body: 'Manrope', system-ui, sans-serif;
}
[data-type='sans'] {
  --display: 'Instrument Serif', serif;
  --body: 'DM Sans', system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--navy-900);
  color: var(--ink);
  font-family: var(--body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.eyebrow {
  font-family: var(--body);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}
.eyebrow-dim { color: var(--ink-faint); }

.display {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.02;
}

.hairline {
  height: 1px;
  background: var(--line);
  width: 100%;
}
.hairline-gold {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold) 20%, var(--gold) 80%, transparent);
  opacity: 0.5;
}

.container {
  max-width: 1360px;
  margin: 0 auto;
  padding: 0 48px;
}
.container-narrow { max-width: 960px; margin: 0 auto; padding: 0 48px; }

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 1.2s cubic-bezier(.2,.7,.2,1), transform 1.2s cubic-bezier(.2,.7,.2,1);
}
.reveal.in {
  opacity: 1;
  transform: none;
}

/* Nav */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 18px 0;
  transition: background 0.4s ease, border-color 0.4s, backdrop-filter 0.4s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(7, 12, 24, 0.82);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 32px;
}
.nav-brand {
  display: flex; align-items: center; gap: 12px;
  text-decoration: none; color: var(--ink);
}
.nav-brand img { width: 36px; height: 36px; display: block; }
.nav-brand-text {
  font-family: var(--display);
  font-size: 20px;
  letter-spacing: 0.18em;
  color: var(--gold);
}
.nav-brand-sub {
  font-size: 9px;
  letter-spacing: 0.32em;
  color: var(--ink-faint);
  text-transform: uppercase;
  margin-top: 2px;
}
.nav-links {
  display: flex; gap: 36px; align-items: center;
}
.nav-link {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  text-decoration: none;
  transition: color 0.2s;
  position: relative;
  padding: 8px 0;
}
.nav-link:hover { color: var(--gold); }
.nav-cta {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--navy-900);
  background: var(--gold);
  padding: 12px 22px;
  border: 1px solid var(--gold);
  text-decoration: none;
  transition: all 0.25s;
}
.nav-cta:hover { background: var(--gold-bright); }

.scroll-progress {
  position: fixed; top: 0; left: 0;
  height: 2px; background: var(--gold);
  z-index: 60; width: 0%;
  transition: width 0.1s linear;
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 28px;
  font-size: 11px; letter-spacing: 0.28em;
  text-transform: uppercase; font-weight: 500;
  text-decoration: none;
  border: 1px solid var(--gold);
  cursor: pointer; background: transparent;
  transition: all 0.3s;
}
.btn-primary {
  background: var(--gold); color: var(--navy-900);
}
.btn-primary:hover { background: var(--gold-bright); border-color: var(--gold-bright); }
.btn-ghost { color: var(--gold); }
.btn-ghost:hover { background: var(--gold); color: var(--navy-900); }
.btn .arrow { transition: transform 0.3s; }
.btn:hover .arrow { transform: translateX(6px); }

/* Section scaffolding */
section {
  position: relative;
  padding: 140px 0;
}
.section-label {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 40px;
}
.section-label .dot {
  width: 6px; height: 6px; background: var(--gold);
  transform: rotate(45deg);
}
.section-num {
  font-family: var(--mono);
  font-size: 11px; color: var(--gold);
  letter-spacing: 0.18em;
}

.section-title {
  font-family: var(--display);
  font-size: clamp(40px, 5.5vw, 72px);
  line-height: 1.05;
  color: var(--ink);
  font-weight: 400;
  max-width: 900px;
  margin-bottom: 24px;
}
.section-title em {
  color: var(--gold);
  font-style: italic;
}
.section-lede {
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink-dim);
  max-width: 640px;
}

/* Placeholder imagery */
.placeholder {
  background:
    repeating-linear-gradient(
      45deg,
      rgba(201, 162, 74, 0.04) 0 12px,
      rgba(201, 162, 74, 0.08) 12px 13px
    ),
    var(--navy-700);
  border: 1px solid var(--line);
  position: relative;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-faint);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  overflow: hidden;
}
.placeholder::before, .placeholder::after {
  content: ''; position: absolute;
  width: 14px; height: 14px;
  border: 1px solid var(--gold);
  opacity: 0.5;
}
.placeholder::before { top: 10px; left: 10px; border-right: none; border-bottom: none; }
.placeholder::after { bottom: 10px; right: 10px; border-left: none; border-top: none; }

/* Subtle gold corner frame */
.frame {
  position: relative;
  padding: 28px;
  border: 1px solid var(--line);
}
.frame-inner {
  position: absolute; inset: 10px;
  border: 1px solid var(--line);
  pointer-events: none;
}

/* Gold diamond glyph */
.diamond {
  display: inline-block;
  width: 8px; height: 8px;
  background: var(--gold);
  transform: rotate(45deg);
  vertical-align: middle;
}

/* Utility */
.grid { display: grid; gap: 24px; }
.flex { display: flex; }
.mono { font-family: var(--mono); letter-spacing: 0.1em; }

/* Footer */
.footer {
  padding: 80px 0 48px;
  border-top: 1px solid var(--line);
  background: var(--navy-900);
}

/* Tweak chip visible only when panel open; the panel is injected by starter */

/* Smoothing the background with layered radial */
.page-bg {
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(201, 162, 74, 0.06), transparent 60%),
    radial-gradient(ellipse 60% 50% at 90% 80%, rgba(201, 162, 74, 0.04), transparent 60%),
    var(--navy-900);
}

/* Grain */
.grain {
  position: fixed; inset: 0; z-index: -1;
  opacity: 0.035; pointer-events: none; mix-blend-mode: screen;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* Responsive */
@media (max-width: 1024px) {
  .nav-links { gap: 20px; }
  .nav-links .nav-link { display: none; }
  .nav-links .nav-cta { display: inline-flex; }
}
@media (max-width: 900px) {
  .container, .container-narrow { padding: 0 24px; }
  section { padding: 96px 0; }
  .nav-links { display: flex; }
}
