*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #0a0a12;
  color: #e8e6f0;
  line-height: 1.65;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

:root {
  --ink: #e8e6f0;
  --muted: #8b8799;
  --void: #0a0a12;
  --panel: #12121c;
  --panel-2: #1a1a28;
  --cyan: #7ee0ff;
  --violet: #c4a8ff;
  --line: rgba(232,230,240,0.08);
  --mono: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
}

/* ——— TERMINAL / CLI NAV (unique) ——— */
.term {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #0d0d16;
  border-bottom: 1px solid var(--line);
  padding: 0;
}
.term .chrome {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: #151520;
  border-bottom: 1px solid var(--line);
}
.term .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.term .dot.r { background: #ff5f57; }
.term .dot.y { background: #febc2e; }
.term .dot.g { background: #28c840; }
.term .title {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--muted);
  margin-left: 8px;
  letter-spacing: 0.04em;
}
.term .title span { color: var(--cyan); }

.cli {
  padding: 12px 20px 16px;
  font-family: var(--mono);
  font-size: 0.85rem;
}
.cli .prompt-line {
  color: var(--muted);
  margin-bottom: 10px;
  font-size: 0.78rem;
}
.cli .prompt-line .user { color: var(--violet); }
.cli .prompt-line .path { color: var(--cyan); }

.cli nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
}
.cli nav a {
  color: var(--muted);
  transition: color 0.15s;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.cli nav a .cmd {
  color: var(--violet);
}
.cli nav a .arg {
  color: var(--muted);
}
.cli nav a:hover .arg { color: var(--ink); }
.cli nav a.active .arg {
  color: var(--cyan);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.cli nav a.active .cmd { color: var(--cyan); }

.cli .cursor {
  display: inline-block;
  width: 8px;
  height: 1em;
  background: var(--cyan);
  margin-left: 4px;
  animation: blink 1s step-end infinite;
  vertical-align: text-bottom;
}
@keyframes blink {
  50% { opacity: 0; }
}

.mob {
  display: none;
  background: var(--cyan);
  color: var(--void);
  border: none;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 6px 12px;
  cursor: pointer;
  margin-left: auto;
}

/* ——— BOOT HERO ——— */
.boot {
  max-width: 1100px;
  margin: 0 auto;
  padding: 48px 28px 40px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 36px;
  align-items: center;
}
.boot .tag {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--cyan);
  margin-bottom: 12px;
  letter-spacing: 0.04em;
}
.boot h1 {
  font-size: clamp(2rem, 4.2vw, 3rem);
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1.1;
  margin-bottom: 16px;
}
.boot h1 em {
  font-style: normal;
  color: var(--violet);
}
.boot p {
  color: var(--muted);
  max-width: 420px;
  margin-bottom: 28px;
  font-size: 1.05rem;
}
.boot .crystal {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--panel);
}
.boot .crystal img {
  width: 100%;
  height: 360px;
  object-fit: cover;
}
.boot .crystal .scan {
  position: absolute;
  top: 12px;
  right: 12px;
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--cyan);
  background: rgba(10,10,18,0.85);
  border: 1px solid rgba(126,224,255,0.3);
  padding: 6px 10px;
  border-radius: 4px;
}

.btn {
  display: inline-flex;
  align-items: center;
  font-family: var(--mono);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 12px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-cyan {
  background: var(--cyan);
  color: var(--void);
}
.btn-cyan:hover { filter: brightness(1.1); }
.btn-violet {
  background: var(--violet);
  color: var(--void);
}
.btn-violet:hover { filter: brightness(1.08); }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--cyan); color: var(--cyan); }

/* ——— LOG ——— */
.log {
  max-width: 1100px;
  margin: 0 auto 36px;
  padding: 0 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.log article {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 18px;
  font-family: var(--mono);
  font-size: 0.8rem;
}
.log .key {
  color: var(--violet);
  margin-bottom: 6px;
  font-size: 0.7rem;
}
.log h3 {
  font-family: 'Segoe UI', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--ink);
}
.log p {
  font-family: 'Segoe UI', sans-serif;
  color: var(--muted);
  font-size: 0.88rem;
}

/* ——— FACET ——— */
.section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 28px 28px 56px;
}
.section .tag {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--cyan);
  margin-bottom: 8px;
}
.section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 28px;
}

.facet-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}
.facet-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.2s;
}
.facet-card:hover { border-color: rgba(126,224,255,0.35); }
.facet-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}
.facet-card .body { padding: 20px; }
.facet-card .sku {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--violet);
  margin-bottom: 6px;
}
.facet-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 6px;
}
.facet-card p {
  font-size: 0.9rem;
  color: var(--muted);
}

/* ——— LATTICE ——— */
.lattice-top {
  max-width: 640px;
  margin: 0 auto;
  padding: 40px 28px 24px;
  text-align: center;
}
.lattice-top .tag {
  font-family: var(--mono);
  font-size: 0.72rem;
  color: var(--cyan);
  margin-bottom: 10px;
}
.lattice-top h1 {
  font-size: clamp(1.8rem, 3.8vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.6px;
  margin-bottom: 12px;
}
.lattice-top p {
  color: var(--muted);
  font-size: 1.05rem;
}
.lattice-img {
  max-width: 900px;
  margin: 0 auto 28px;
  padding: 0 28px;
}
.lattice-img img {
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.lattice-prose {
  max-width: 600px;
  margin: 0 auto;
  padding: 0 28px 56px;
}
.lattice-prose p {
  color: var(--muted);
  margin-bottom: 14px;
}

/* ——— PING ——— */
.ping-wrap {
  max-width: 1100px;
  margin: 28px auto 60px;
  padding: 0 28px;
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 12px;
}
.ping-side {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 36px;
  font-family: var(--mono);
  font-size: 0.85rem;
}
.ping-side h2 {
  font-family: 'Segoe UI', sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 22px;
  color: var(--ink);
}
.pr { margin-bottom: 16px; }
.pr .lbl {
  color: var(--cyan);
  font-size: 0.7rem;
  margin-bottom: 4px;
}
.pr p, .pr a {
  color: var(--muted);
  font-family: 'Segoe UI', sans-serif;
  font-size: 0.95rem;
}
.pr a:hover { color: var(--cyan); }

.ping-form {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 32px;
}
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 5px;
}
.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 12px 14px;
  background: var(--void);
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--ink);
  font-size: 0.95rem;
  font-family: var(--mono);
}
.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--cyan);
}
.form-group textarea { min-height: 110px; resize: vertical; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.ft {
  border-top: 1px solid var(--line);
  padding: 28px;
  text-align: center;
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--muted);
}
.ft strong { color: var(--ink); }

@media (max-width: 860px) {
  .cli nav {
    display: none;
    flex-direction: column;
    gap: 8px;
  }
  .cli nav.open { display: flex; }
  .mob { display: inline-block; }
  .boot { grid-template-columns: 1fr; }
  .boot .crystal img { height: 240px; }
  .log { grid-template-columns: 1fr; }
  .facet-grid { grid-template-columns: 1fr; }
  .ping-wrap { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .lattice-img img { height: 220px; }
}
