/* Quantum State Industries — SpaceX-dark design system */
:root {
  --bg: #000000;
  --bg-elevated: #0a0a0a;
  --bg-card: #111111;
  --bg-card-hover: #161616;
  --bg-muted: #141414;
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #ffffff;
  --text-secondary: #b3b3b3;
  --text-muted: #8a8a8a;
  --copper: #b87333;
  --copper-bright: #d4894a;
  --gold: #c9a227;
  --gold-bright: #e0b83a;
  --accent: var(--copper);
  --accent-hover: var(--copper-bright);
  --radius: 10px;
  --radius-lg: 16px;
  --shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --max: 1160px;
  --header-h: 96px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .hero-video { display: none !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--copper-bright); text-decoration: none; transition: color 0.2s var(--ease); }
a:hover { color: var(--gold-bright); }
ul { padding-left: 1.15rem; }
p { color: var(--text-secondary); margin: 0 0 1rem; }
h1, h2, h3, h4 {
  color: var(--text);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  font-weight: 600;
}
h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
h3 { font-size: 1.25rem; }
.lead { font-size: 1.125rem; color: var(--text-secondary); max-width: 40rem; }
.eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 0.85rem;
}

.container {
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
}
.section { padding: clamp(4rem, 8vw, 6.5rem) 0; }
.section-tight { padding: clamp(3rem, 6vw, 4.5rem) 0; }
.section-dark { background: var(--bg); }
.section-elevated { background: var(--bg-elevated); }
.section-card-bg { background: linear-gradient(180deg, #0a0a0a 0%, #000 100%); }

/* Header */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 1000;
  height: var(--header-h);
  display: flex;
  align-items: center;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease), backdrop-filter 0.3s var(--ease);
  border-bottom: 1px solid transparent;
  background: transparent;
}
.site-header.is-solid {
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--border);
}
.site-header .nav-inner {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}
.brand:hover { color: var(--text); }
.brand {
  gap: 0;
}
/* Full logo lockup — never crop with a circle (wordmark must stay intact) */
.brand img {
  width: auto;
  height: 72px;
  max-width: min(280px, 42vw);
  object-fit: contain;
  object-position: left center;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  filter: drop-shadow(0 0 12px rgba(184, 115, 51, 0.45));
  flex-shrink: 0;
}
/* Wordmark lives inside the logo file — hide duplicate text */
.brand-text {
  display: none;
}
.brand-text strong {
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  font-weight: 700;
}
.brand-text span {
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--copper-bright);
  text-transform: uppercase;
}

/* Homepage hero — full square lockup, no circular clip */
.hero-logo {
  display: block;
  width: clamp(200px, 34vw, 320px);
  height: auto;
  max-width: 100%;
  margin: 0 0 1.75rem;
  border-radius: 0;
  object-fit: contain;
  background: transparent;
  padding: 0;
  box-shadow: none;
  filter: drop-shadow(0 8px 28px rgba(0, 0, 0, 0.65)) drop-shadow(0 0 32px rgba(184, 115, 51, 0.4));
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.5rem 0.7rem;
  border-radius: 6px;
}
.nav-links a:hover,
.nav-links a[aria-current="page"] {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border-strong);
  color: var(--text);
  width: 42px;
  height: 42px;
  border-radius: 8px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  position: relative;
}
.nav-toggle span::before,
.nav-toggle span::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: var(--text);
}
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.35rem;
  font-size: 0.92rem;
  font-weight: 600;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary {
  background: linear-gradient(135deg, var(--copper) 0%, var(--gold) 100%);
  color: #000 !important;
  border-color: transparent;
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--copper-bright) 0%, var(--gold-bright) 100%);
  color: #000 !important;
}
.btn-secondary {
  background: transparent;
  color: var(--text) !important;
  border-color: var(--border-strong);
}
.btn-secondary:hover {
  border-color: var(--copper);
  color: var(--text) !important;
  background: rgba(184, 115, 51, 0.08);
}
.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text) !important;
  border-color: var(--border);
}
.btn-sm { padding: 0.5rem 1rem; font-size: 0.82rem; }
.btn-login {
  background: transparent;
  color: var(--text) !important;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  font-size: 0.82rem;
  font-weight: 600;
}
.btn-login:hover {
  border-color: var(--copper);
  color: var(--copper-bright) !important;
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: flex-end;
  padding: calc(var(--header-h) + 2rem) 0 5rem;
  overflow: hidden;
  background: #000;
}
.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero-video,
.hero-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0,0,0,0.62) 0%, rgba(0,0,0,0.42) 38%, rgba(0,0,0,0.9) 100%),
    linear-gradient(90deg, rgba(0,0,0,0.82) 0%, rgba(0,0,0,0.35) 50%, rgba(0,0,0,0.5) 100%);
  z-index: 1;
}
.hero-content {
  position: relative;
  z-index: 2;
  width: min(100% - 2.5rem, var(--max));
  margin-inline: auto;
  max-width: 720px;
}
.hero h1 { margin-bottom: 1rem; }
.hero .lead { margin-bottom: 1.75rem; color: #d6d6d6; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.hero-meta {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.hero-meta strong { color: var(--text-secondary); font-weight: 600; }

/* Page hero (inner pages) */
.page-hero {
  padding: calc(var(--header-h) + 3.5rem) 0 3rem;
  background:
    radial-gradient(ellipse 80% 60% at 70% 0%, rgba(184, 115, 51, 0.12), transparent 55%),
    #000;
  border-bottom: 1px solid var(--border);
}
.page-hero .lead { margin-bottom: 0; }

/* Grid / cards */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}
.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.grid-5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), transform 0.2s var(--ease);
}
.card:hover {
  border-color: rgba(184, 115, 51, 0.35);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
}
.card-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  background: rgba(184, 115, 51, 0.12);
  border: 1px solid rgba(184, 115, 51, 0.25);
  margin-bottom: 1rem;
  color: var(--copper-bright);
}
.card-icon svg { width: 22px; height: 22px; }
.card h3 { margin-bottom: 0.5rem; }
.card p:last-child { margin-bottom: 0; }
.card a.card-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 1rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--copper-bright);
}

.split {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.split-reverse { direction: rtl; }
.split-reverse > * { direction: ltr; }

.panel {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 3vw, 2.25rem);
}
.panel-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.panel-list li {
  display: flex;
  gap: 0.75rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.panel-list li:last-child { border-bottom: none; }
.panel-list .tick {
  color: var(--gold);
  flex-shrink: 0;
  font-weight: 700;
}

/* Industries strip */
.industries-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.1rem;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: var(--bg-card);
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 500;
}
.chip svg { width: 16px; height: 16px; color: var(--copper); }

/* CTA band */
.cta-band {
  background:
    radial-gradient(ellipse 70% 80% at 50% 120%, rgba(184, 115, 51, 0.22), transparent 55%),
    #0a0a0a;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
}
.cta-band .lead { margin-inline: auto; margin-bottom: 1.5rem; }
.cta-band .hero-ctas { justify-content: center; }

/* Forms */
.form-grid {
  display: grid;
  gap: 1rem;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
}
input, select, textarea {
  width: 100%;
  background: #0a0a0a;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  color: var(--text);
  padding: 0.8rem 0.95rem;
  font: inherit;
  transition: border-color 0.2s var(--ease);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--copper);
  box-shadow: 0 0 0 3px rgba(184, 115, 51, 0.15);
}
textarea { min-height: 140px; resize: vertical; }
.contact-details {
  display: grid;
  gap: 1rem;
}
.contact-item {
  display: flex;
  gap: 0.9rem;
  align-items: flex-start;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
}
.contact-item strong {
  display: block;
  color: var(--text);
  font-size: 0.95rem;
}
.contact-item span, .contact-item a {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* Accordion / expandable */
.expandable {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
  overflow: hidden;
}
.expandable summary {
  cursor: pointer;
  padding: 1.1rem 1.25rem;
  font-weight: 600;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.expandable summary::-webkit-details-marker { display: none; }
.expandable summary::after {
  content: "+";
  color: var(--copper);
  font-size: 1.25rem;
  font-weight: 400;
}
.expandable[open] summary::after { content: "–"; }
.expandable .expand-body {
  padding: 0 1.25rem 1.25rem;
  color: var(--text-secondary);
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}

/* Role tags */
.role-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}
.role-tag {
  font-size: 0.82rem;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  color: var(--text-secondary);
}

/* Footer */
.site-footer {
  background: #000;
  border-top: 1px solid var(--border);
  padding: 3.5rem 0 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2.5rem;
}
.footer-brand img {
  width: auto;
  height: 88px;
  max-width: 200px;
  object-fit: contain;
  border-radius: 0;
  background: transparent;
  margin-bottom: 0.85rem;
  filter: drop-shadow(0 0 10px rgba(184, 115, 51, 0.35));
}
.footer-brand p { font-size: 0.9rem; max-width: 22rem; }
.footer-col h4 {
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 1rem;
}
.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.footer-col li { margin-bottom: 0.55rem; }
.footer-col a {
  color: var(--text-secondary);
  font-size: 0.92rem;
}
.footer-col a:hover { color: var(--text); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 0.82rem;
}

/* Portal */
.portal-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 2rem;
  background:
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(184, 115, 51, 0.15), transparent 50%),
    #000;
  text-align: center;
}
.portal-card {
  max-width: 420px;
  width: 100%;
  padding: 2.5rem 2rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
}
.portal-card img {
  width: min(220px, 70%);
  height: auto;
  object-fit: contain;
  margin: 0 auto 1.25rem;
  border-radius: 0;
  background: transparent;
  filter: drop-shadow(0 0 16px rgba(184, 115, 51, 0.4));
}
.portal-badge {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid rgba(201, 162, 39, 0.35);
  padding: 0.3rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}

/* Utilities */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  border: 0;
}
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.stack > * + * { margin-top: 1rem; }
.divider {
  height: 1px;
  background: var(--border);
  border: 0;
  margin: 2rem 0;
}
.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}
.stat {
  padding: 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-elevated);
  text-align: center;
}
.stat .label {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--copper);
  margin-bottom: 0.35rem;
}
.stat .value {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
}

@media (max-width: 960px) {
  .grid-4, .grid-5 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .split, .split-reverse { grid-template-columns: 1fr; direction: ltr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .nav-toggle { display: inline-flex; }
  .brand-text { display: none; }
}

@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4, .grid-5, .form-row, .stat-row, .footer-grid {
    grid-template-columns: 1fr;
  }
  .hero { align-items: center; padding-bottom: 3.5rem; }
  .hero-ctas .btn { width: 100%; }
}

.mobile-only { display: none !important; }
@media (max-width: 960px) {
  .desktop-only { display: none !important; }
  .mobile-only { display: flex !important; }
  .nav-panel {
    display: none;
    position: absolute;
    top: var(--header-h);
    left: 0; right: 0;
    background: rgba(0, 0, 0, 0.96);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem 1.25rem 1.5rem;
    gap: 0.35rem;
  }
  .site-header.is-open .nav-panel { display: flex; }
  .nav-panel .nav-links { display: flex; flex-direction: column; width: 100%; }
  .nav-panel .nav-actions { width: 100%; flex-direction: column; }
  .nav-panel .btn { width: 100%; }
}
@media (min-width: 961px) {
  .nav-panel {
    display: flex !important;
    position: static;
    background: transparent;
    border: 0;
    padding: 0;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    flex: 1;
    justify-content: flex-end;
  }
}
