/* StyrOps — visual identity
 * Primary dark marine #0F172A · Graphite #1F2937
 * Technical blue #2563EB · Precision turquoise #14B8A6
 * Steel gray #94A3B8 · Light bg #F8FAFC · Warning amber #F59E0B
 */

:root {
  --c-bg: #0F172A;
  --c-bg-2: #0B1220;
  --c-bg-3: #1E293B;
  --c-graphite: #1F2937;
  --c-line: #243144;
  --c-line-soft: #182234;
  --c-blue: #2563EB;
  --c-blue-soft: #3B82F6;
  --c-turq: #14B8A6;
  --c-steel: #94A3B8;
  --c-steel-2: #CBD5E1;
  --c-light: #F8FAFC;
  --c-amber: #F59E0B;

  --font-sans: "Inter", "Suisse Int'l", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --gutter: clamp(20px, 4vw, 56px);
  --max: 1200px;
}

@supports (font-variation-settings: normal) {
  :root { --font-sans: "Inter var", "Suisse Int'l", ui-sans-serif, -apple-system, sans-serif; }
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--c-bg);
  color: var(--c-steel-2);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.55;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--c-blue-soft); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--c-turq); }
img { display: block; max-width: 100%; height: auto; }
h1, h2, h3 { color: var(--c-light); font-weight: 500; letter-spacing: -0.01em; margin: 0; }

/* --- Top bar --- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: rgba(11, 18, 32, 0.78);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--c-line-soft);
}
.topbar__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px var(--gutter);
  display: flex; align-items: center; justify-content: space-between;
}
.topbar__brand img { height: 44px; }
.topbar__nav { display: flex; gap: 28px; }
.topbar__nav a {
  color: var(--c-steel);
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
}
.topbar__nav a:hover { color: var(--c-light); }
@media (max-width: 640px) { .topbar__nav { display: none; } }

/* --- Hero --- */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--c-line-soft);
}
.hero__grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--c-line-soft) 1px, transparent 1px),
    linear-gradient(90deg, var(--c-line-soft) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: -1px -1px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 35%, #000 40%, transparent 100%);
  opacity: 0.55;
  pointer-events: none;
}
.hero__inner {
  position: relative;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(20px, 2.6vw, 36px) var(--gutter) clamp(20px, 2.6vw, 32px);
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 40px);
}
.hero__logo {
  height: clamp(96px, 13vw, 160px);
  width: auto;
  margin: 0;
  display: block;
  flex-shrink: 0;
}
.hero__text { flex: 1; min-width: 0; }
@media (max-width: 640px) {
  .hero__inner { flex-direction: column; align-items: flex-start; }
}
.hero__title {
  font-size: clamp(28px, 4.4vw, 48px);
  line-height: 1.05;
  font-weight: 300;
  letter-spacing: -0.025em;
  color: var(--c-light);
  margin: 0 0 10px;
  max-width: 16ch;
}
.hero__lede {
  font-size: clamp(15px, 1.3vw, 18px);
  color: var(--c-steel-2);
  max-width: 60ch;
  line-height: 1.5;
  margin: 0;
}

/* --- Section base --- */
.section {
  padding: clamp(20px, 2.4vw, 36px) 0;
  border-bottom: 1px solid var(--c-line-soft);
}
.section--alt { background: var(--c-bg-2); }
.section--cta {
  text-align: center;
  background:
    radial-gradient(ellipse 80% 50% at 50% 100%, rgba(37, 99, 235, 0.16), transparent 70%),
    var(--c-bg);
}
.section__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.section__head {
  display: flex; align-items: baseline; gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--c-line);
}
.section__head h2 { font-size: clamp(22px, 2.8vw, 30px); }
.section__num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--c-blue-soft);
  letter-spacing: 0.16em;
}
.section__head h2 {
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 500;
  letter-spacing: -0.02em;
}
.two-col {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 56px;
}
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; gap: 28px; } }
.lede {
  font-size: clamp(18px, 1.7vw, 22px);
  line-height: 1.5;
  color: var(--c-light);
  font-weight: 400;
}
.muted { color: var(--c-steel); }
.small { font-size: 13.5px; }

/* --- Use cases --- */
.cases {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--c-line);
  border: 1px solid var(--c-line);
}
@media (max-width: 1080px) { .cases { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px)  { .cases { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .cases { grid-template-columns: 1fr; } }
.case {
  background: var(--c-bg-2);
  padding: 16px 18px 18px;
  display: flex; flex-direction: column; gap: 6px;
  transition: background .2s ease;
}
.case__tag { margin-bottom: 4px; }
.case h3 { font-size: 17px; }
.case p { font-size: 14.5px; }
.case:hover { background: var(--c-bg-3); }
.case__tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-turq);
  display: inline-block;
  margin-bottom: 14px;
}
.case h3 {
  font-size: 20px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--c-light);
}
.case p {
  color: var(--c-steel-2);
  font-size: 15.5px;
  line-height: 1.55;
  margin: 0;
}

/* --- Matrix / amplified table --- */
.matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  color: var(--c-steel-2);
}
.matrix th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-turq);
  font-weight: 500;
  padding: 12px 18px;
  border-bottom: 1px solid var(--c-line);
}
.matrix td {
  padding: 22px 18px;
  border-bottom: 1px solid var(--c-line-soft);
  vertical-align: top;
  line-height: 1.5;
}
.matrix td:first-child {
  color: var(--c-light);
  font-weight: 500;
  width: 14%;
  white-space: nowrap;
}
.matrix td:nth-child(2) {
  color: var(--c-steel);
  width: 36%;
}
.matrix tbody tr:last-child td { border-bottom: none; }
@media (max-width: 760px) {
  .matrix, .matrix thead, .matrix tbody, .matrix tr, .matrix td, .matrix th { display: block; }
  .matrix thead { display: none; }
  .matrix td { padding: 8px 0; border: none; width: auto !important; white-space: normal !important; }
  .matrix tr { padding: 20px 0; border-bottom: 1px solid var(--c-line-soft); }
  .matrix td:first-child {
    font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.14em;
    text-transform: uppercase; color: var(--c-turq); font-weight: 500;
    margin-bottom: 6px;
  }
}

.max-60 { max-width: 60ch; margin-bottom: 48px; }
em { font-style: italic; color: var(--c-light); }

/* --- Stack figure (SVG architecture diagram) --- */
.stack-fig {
  margin: 0;
  padding: 20px;
  background: var(--c-bg);
  border: 1px solid var(--c-line-soft);
}
.stack-fig svg {
  width: 100%;
  height: auto;
  display: block;
}
.stack-fig svg .layer-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  fill: var(--c-steel);
}
.stack-fig svg .layer-title {
  font-family: var(--font-sans);
  font-size: 16px;
  font-weight: 500;
  fill: var(--c-light);
}
.stack-fig svg .layer-meta {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  fill: var(--c-steel);
}
.stack-fig svg .chip-t {
  font-family: var(--font-sans);
  font-size: 11px;
  fill: var(--c-steel-2);
}
.stack-fig svg .chip-t--hi {
  fill: var(--c-light);
  font-weight: 500;
}
.stack-fig figcaption {
  margin-top: 20px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-steel);
  text-align: center;
}

/* --- (legacy) Stack list layers — kept for compat --- */
.stack {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--c-line);
  background: var(--c-bg);
}
.stack__layer {
  display: grid;
  grid-template-columns: 180px 1fr;
  align-items: center;
  padding: 22px 28px;
  border-bottom: 1px solid var(--c-line-soft);
  position: relative;
  transition: background .2s ease;
}
.stack__layer:last-child { border-bottom: none; }
.stack__layer::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--c-line);
  transition: background .2s ease;
}
.stack__layer:hover { background: var(--c-bg-3); }
.stack__layer:hover::before { background: var(--c-blue); }

.stack__layer--users::before    { background: var(--c-turq); }
.stack__layer--agents::before   { background: var(--c-blue); }
.stack__layer--meta::before     { background: var(--c-blue-soft); }
.stack__layer--infra::before    { background: var(--c-steel); }
.stack__layer--sensing::before  { background: var(--c-graphite); }

.stack__label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-steel);
}
.stack__body {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.stack__body strong {
  color: var(--c-light);
  font-weight: 500;
  font-size: 17px;
}
.stack__body span:not(.chip) {
  color: var(--c-steel-2);
  font-size: 14.5px;
}
.stack__body--chips {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 8px;
}
.chip {
  display: inline-block;
  padding: 6px 12px;
  background: var(--c-bg-3);
  border: 1px solid var(--c-line);
  color: var(--c-steel-2);
  font-size: 13px;
  border-radius: 2px;
  letter-spacing: 0.005em;
}
.chip--accent {
  background: rgba(37, 99, 235, 0.12);
  border-color: rgba(37, 99, 235, 0.45);
  color: var(--c-light);
  font-weight: 500;
}
.stack__note {
  margin-top: 28px;
  max-width: 80ch;
  line-height: 1.55;
}
.stack__note strong { color: var(--c-light); }

@media (max-width: 640px) {
  .stack__layer { grid-template-columns: 1fr; gap: 10px; padding: 18px 20px 18px 22px; }
  .stack__label { margin-bottom: 2px; }
}

/* --- Features --- */
.features {
  list-style: none;
  padding: 0; margin: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--c-line);
  border: 1px solid var(--c-line);
}
@media (max-width: 900px) { .features { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .features { grid-template-columns: 1fr; } }
.features li {
  background: var(--c-bg);
  padding: 14px 18px 16px;
  position: relative;
}
.features h3 { margin-bottom: 6px; font-size: 15px; }
.features p { font-size: 13.5px; }
.features li::before {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 32px; height: 2px;
  background: var(--c-blue);
}
.features h3 {
  font-size: 17px;
  font-weight: 500;
  color: var(--c-light);
  margin: 0 0 12px;
  letter-spacing: -0.005em;
}
.features p {
  margin: 0;
  color: var(--c-steel);
  font-size: 14.5px;
  line-height: 1.55;
}

/* --- CTA --- */
.section--cta h2 {
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 400;
  letter-spacing: -0.02em;
  margin-bottom: 18px;
}
.section--cta .lede {
  max-width: 50ch;
  margin: 0 auto 36px;
}
.cta {
  display: inline-block;
  padding: 14px 32px;
  background: var(--c-blue);
  color: var(--c-light);
  font-weight: 500;
  border-radius: 2px;
  font-size: 15.5px;
  letter-spacing: 0.01em;
  transition: background .15s ease;
}
.cta:hover { background: var(--c-blue-soft); color: var(--c-light); }

/* --- Footer --- */
.footer {
  background: var(--c-bg-2);
  border-top: 1px solid var(--c-line-soft);
  color: var(--c-steel);
}
.footer__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px var(--gutter) 16px;
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 20px;
  align-items: center;
}
@media (max-width: 760px) { .footer__inner { grid-template-columns: 1fr; gap: 28px; } }
.footer__col { display: flex; flex-direction: column; gap: 14px; }
.footer__col--right { align-items: flex-end; text-align: right; }
.footer__col--right .footer__partner { align-self: flex-end; }
@media (max-width: 760px) {
  .footer__col--right { align-items: flex-start; text-align: left; }
  .footer__col--right .footer__partner { align-self: flex-start; }
}
.footer__email { font-size: 14px; }
.footer__logo,
.footer__partner {
  display: block;
  height: 96px;
  width: auto;
  max-width: none;
  object-fit: contain;
  align-self: flex-start;
}
.footer__partner { opacity: 0.95; transition: opacity .15s ease; }
.footer__partner:hover { opacity: 1; }
.label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-steel);
}
.footer__bottom {
  max-width: var(--max);
  margin: 0 auto;
  padding: 10px var(--gutter) 12px;
  border-top: 1px solid var(--c-line-soft);
  display: flex; justify-content: space-between; gap: 18px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--c-steel);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
