@import url("https://fonts.googleapis.com/css2?family=Bebas+Neue&family=IBM+Plex+Mono:wght@400;500;600;700&display=swap");

@font-face {
  font-family: VCR_OSD;
  src: url("../fonts/VCR_OSD_MONO.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --font-display: "Bebas Neue", Impact, "Arial Narrow Bold", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  --bg-0: #000000;
  --bg-1: #030303;
  --surface: #080808;
  --line: #1c1c1c;

  --text: #d8d8d8;
  --text-muted: #9a9a9a;
  --text-soft: #666666;

  /* RGB reserved for highlights — not structural chrome */
  --rgb-r: 57;
  --rgb-g: 255;
  --rgb-b: 20;
  --accent-primary: rgb(var(--rgb-r) var(--rgb-g) var(--rgb-b));
  --accent-secondary: #6b8cff;
  --accent-alert: #ff3b4d;
  --accent-success: #5fd99a;

  --border: rgba(255, 255, 255, 0.12);
  --border-dim: rgba(255, 255, 255, 0.07);
  --border-window-active: rgba(255, 255, 255, 0.4);
  --glow-window-active: rgba(255, 255, 255, 0.12);
  --border-accent: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.38);
  --glow-accent: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.22);
  --glow-accent-soft: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.08);
  --scanline: rgba(255, 255, 255, 0.018);

  /* Lucid Obscura form tokens */
  --lo-field-text: #f7f7f7;
  --lo-field-bg: #000000;
  --lo-field-border: #ffffff;
  --lo-caret: #c3ff00;
  --lo-placeholder: rgba(247, 247, 247, 0.7);
  --lo-placeholder-focus: rgba(247, 247, 247, 0.3);
  --lo-btn-idle: #bbbbbb;
  --lo-btn-hover: #c3ff00;
  --lo-font-field: Consolas, "Courier New", var(--font-mono);
  --lo-font-placeholder: VCR_OSD, var(--font-mono);

  --terminal-light-dim: 0.22;

  --focus-ring: 0 0 0 2px rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.42);
  --shadow-soft: 0 8px 24px rgba(0, 0, 0, 0.5);

  --max-width: 1100px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --space-1: 0.5rem;
  --space-2: 0.75rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2rem;
  --space-6: 3rem;
  --space-7: 4rem;

  --mx: 50vw;
  --my: 35vh;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-mono);
  background: linear-gradient(180deg, var(--bg-1) 0%, var(--bg-0) 100%);
  color: var(--text);
  line-height: 1.62;
  letter-spacing: 0.02em;
  font-size: 0.92rem;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(280px circle at var(--mx) var(--my), var(--glow-accent-soft), transparent 68%),
    repeating-linear-gradient(
      0deg,
      var(--scanline) 0px,
      var(--scanline) 1px,
      transparent 1px,
      transparent 3px
    );
  pointer-events: none;
  z-index: -1;
}

a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover,
a:focus-visible {
  color: var(--accent-primary);
  text-decoration: none;
  text-shadow: 0 0 12px var(--glow-accent);
}

img {
  max-width: 100%;
  display: block;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: var(--radius-sm);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 120;
  background: var(--accent-primary);
  color: #051404;
  padding: 0.55rem 0.8rem;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 700;
}

.skip-link:focus {
  left: 0;
}

.container {
  width: min(100% - 2rem, var(--max-width));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 70;
  border-bottom: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(10px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  min-height: 72px;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  gap: 0.1rem;
}

.brand-with-logo {
  gap: 0.25rem;
}

.brand-logo {
  width: min(220px, 42vw);
  height: auto;
  image-rendering: auto;
}

.brand-logo--animated {
  display: block;
  flex: 0 0 auto;
  color: #f7f7f7;
  line-height: 0;
}

.brand-logo--animated svg {
  display: block;
  width: 100%;
  height: auto;
}

.brand-mark {
  font-family: var(--font-display);
  color: var(--accent-primary);
  font-size: 1.05rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-weight: 700;
}

.brand-sub {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.66rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.95);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-left: auto;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  color: var(--text-soft);
  font-family: var(--font-mono);
  font-size: 0.73rem;
  white-space: nowrap;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 0.42rem 0.65rem;
  border-radius: 2px;
  border: 1px solid transparent;
  transition: color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.nav-link.is-current,
.nav-link:hover,
.nav-link:focus-visible {
  color: var(--accent-primary);
  border-color: var(--border-accent);
  background: transparent;
  box-shadow: 0 0 14px var(--glow-accent-soft);
  text-decoration: none;
  text-shadow: 0 0 10px var(--glow-accent);
}

.header-cta {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 0.58rem 0.92rem;
  font-size: 0.74rem;
  font-weight: 600;
  font-family: var(--font-mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: border-color 0.15s ease, color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.button:hover {
  text-decoration: none;
}

.button.primary {
  border-color: var(--border-accent);
  background: transparent;
  color: var(--accent-primary);
  box-shadow: inset 0 0 0 1px var(--glow-accent-soft);
}

.button.primary:hover {
  background: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.1);
  box-shadow: 0 0 18px var(--glow-accent);
  text-shadow: 0 0 8px var(--glow-accent);
}

.button.secondary {
  border-color: var(--border);
  color: var(--text-muted);
  background: transparent;
}

.button.secondary:hover {
  border-color: var(--border-accent);
  color: var(--accent-primary);
}

.button.ghost {
  border-color: var(--border-dim);
  color: var(--text-soft);
  background: transparent;
}

.button.ghost:hover {
  border-color: var(--border);
  color: var(--text);
}

.signal-uplink {
  position: fixed;
  right: clamp(0.7rem, 1.6vw, 1.25rem);
  top: 50%;
  z-index: 69;
  display: grid;
  gap: 0.42rem;
  padding: 0.55rem 0.34rem;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.72);
  transform: translateY(-50%);
  backdrop-filter: blur(8px);
}

.signal-uplink::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0.8rem;
  bottom: 0.8rem;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--border), transparent);
  transform: translateX(-50%);
  pointer-events: none;
}

.uplink-label {
  position: absolute;
  right: calc(100% + 0.55rem);
  top: 50%;
  color: var(--text-soft);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: center right;
  white-space: nowrap;
}

.social-node {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--border);
  border-radius: 2px;
  color: var(--text-muted);
  background: #000;
  overflow: visible;
  text-decoration: none;
  isolation: isolate;
  animation: uplink-idle 2.8s ease-in-out infinite;
  transition: border-color 140ms ease, color 140ms ease, box-shadow 140ms ease;
}

.social-node:nth-of-type(2) {
  animation-delay: 0.2s;
}

.social-node:nth-of-type(3) {
  animation-delay: 0.4s;
}

.social-node:nth-of-type(4) {
  animation-delay: 0.6s;
}

.social-node:nth-of-type(5) {
  animation-delay: 0.8s;
}

.social-node::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background:
    linear-gradient(90deg, transparent 0 46%, rgba(57, 255, 20, 0.32) 46% 54%, transparent 54%),
    linear-gradient(rgba(255, 15, 34, 0.24), rgba(255, 15, 34, 0));
  opacity: 0;
  transform: translateY(-60%);
  transition: opacity 120ms ease, transform 180ms ease;
  pointer-events: none;
}

.social-node::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 0;
  height: 1px;
  background: rgba(57, 255, 20, 0.5);
  transition: width 160ms ease;
}

.social-node:hover,
.social-node:focus-visible {
  color: var(--accent-primary);
  background: transparent;
  border-color: var(--border-accent);
  box-shadow: 0 0 14px var(--glow-accent-soft);
  text-decoration: none;
  text-shadow: 0 0 8px var(--glow-accent);
}

.social-node:hover::before,
.social-node:focus-visible::before {
  opacity: 1;
  transform: translateY(60%);
}

.social-node:hover::after,
.social-node:focus-visible::after {
  width: 1.35rem;
}

.node-icon,
.node-code {
  grid-area: 1 / 1;
}

.node-icon {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  opacity: 0.95;
}

.node-icon svg {
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.node-code {
  opacity: 0;
  color: #000;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.node-label {
  position: absolute;
  right: calc(100% + 1rem);
  top: 50%;
  min-width: max-content;
  padding: 0.2rem 0.38rem;
  border: 1px solid rgba(57, 255, 20, 0.32);
  color: rgba(216, 255, 210, 0.9);
  background: rgba(0, 0, 0, 0.86);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0;
  transform: translate(8px, -50%);
  transition: opacity 120ms ease, transform 120ms ease;
  pointer-events: none;
}

.social-node:hover .node-icon,
.social-node:focus-visible .node-icon {
  opacity: 0;
}

.social-node:hover .node-code,
.social-node:focus-visible .node-code {
  opacity: 1;
}

.social-node:hover .node-label,
.social-node:focus-visible .node-label {
  opacity: 1;
  transform: translate(0, -50%);
}

@keyframes uplink-idle {
  0%,
  100% {
    box-shadow: 0 0 0 rgba(57, 255, 20, 0);
  }

  50% {
    box-shadow: 0 0 14px rgba(57, 255, 20, 0.22);
  }
}

.page-main {
  position: relative;
  z-index: 1;
  padding-bottom: var(--space-7);
}

.hero {
  padding: var(--space-7) 0 var(--space-6);
}

body[data-page="home"] .hero {
  min-height: calc(80vh - 72px);
  display: flex;
  align-items: center;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: clamp(1.2rem, 3vw, 2.2rem);
  align-items: start;
}

.hero-logo-lockup {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.6rem;
}

.hero-symbol {
  width: 22px;
  height: 22px;
  position: relative;
  display: inline-block;
  border: 1px solid rgba(57, 255, 20, 0.6);
  transform: rotate(45deg);
}

.hero-symbol::before,
.hero-symbol::after {
  content: "";
  position: absolute;
  background: var(--accent-primary);
}

.hero-symbol::before {
  left: 50%;
  top: -10%;
  width: 2px;
  height: 120%;
  transform: translateX(-50%);
}

.hero-symbol::after {
  top: 50%;
  left: -10%;
  width: 120%;
  height: 2px;
  transform: translateY(-50%);
}

.hero-wordmark {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #c8ffbf;
}

.hero-controls {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0 0 var(--space-3);
}

.scroll-cue {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border: 1px solid rgba(0, 0, 255, 0.62);
  border-radius: 999px;
  color: #e5e5ff;
  text-decoration: none;
  font-size: 0.75rem;
}

.scroll-cue:hover,
.scroll-cue:focus-visible {
  background: rgba(0, 0, 255, 0.16);
  border-color: rgba(0, 0, 255, 0.86);
  text-decoration: none;
}

.kicker {
  margin: 0 0 var(--space-2);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-soft);
  font-weight: 500;
  font-family: var(--font-mono);
}

.kicker::before {
  content: none;
}

h1,
h2,
h3 {
  margin: 0 0 var(--space-3);
  line-height: 1.13;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.8vw, 3.8rem);
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-wrap: balance;
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(1.45rem, 2.4vw, 2.1rem);
  font-weight: 400;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

h3 {
  font-family: var(--font-display);
  font-size: 1.04rem;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

p {
  margin: 0 0 var(--space-3);
  color: var(--text-muted);
}

.lead {
  font-size: clamp(1rem, 1.8vw, 1.16rem);
  color: #dcdcdc;
  max-width: 56ch;
}

.hero-panel {
  border: 1px solid rgba(0, 0, 255, 0.36);
  background: rgba(7, 7, 7, 0.88);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  box-shadow: var(--shadow-soft);
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-2);
}

.stat-card {
  border: 1px solid rgba(255, 15, 34, 0.48);
  border-radius: 10px;
  padding: 0.74rem;
  background: rgba(0, 0, 0, 0.75);
}

.stat-card strong {
  display: block;
  font-size: 1rem;
  color: var(--text);
}

.stat-card span {
  font-size: 0.72rem;
  color: var(--text-soft);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section {
  margin-top: var(--space-6);
  border-top: 1px solid rgba(0, 0, 255, 0.3);
  padding-top: var(--space-4);
}

.section-intro {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.section-intro p {
  margin-bottom: 0;
  max-width: 64ch;
}

.grid {
  display: grid;
  gap: var(--space-3);
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.bio-split {
  align-items: stretch;
}

.bio-stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  height: 100%;
  min-height: 0;
}

.bio-stack .card {
  flex: 0 0 auto;
}

.promo-shot {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  margin: 0;
  border: 1px solid rgba(57, 255, 20, 0.28);
  border-radius: var(--radius-md);
  background: #000;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(57, 255, 20, 0.08);
}

.promo-shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card {
  position: relative;
  border: 1px solid rgba(57, 255, 20, 0.24);
  border-radius: var(--radius-md);
  background: rgba(6, 6, 6, 0.88);
  padding: var(--space-4);
  box-shadow: var(--shadow-soft);
}

.card::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent-primary) 0%, var(--accent-secondary) 56%, var(--accent-alert) 100%);
}

.card p:last-child,
.card ul:last-child {
  margin-bottom: 0;
}

.meta-row {
  margin-top: var(--space-2);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(0, 0, 255, 0.45);
  border-radius: 999px;
  padding: 0.22rem 0.58rem;
  color: var(--text-soft);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.list {
  margin: 0;
  padding-left: 1.2rem;
  color: var(--text-muted);
}

.list li {
  margin-bottom: 0.45rem;
}

.table-wrap {
  border: 1px solid rgba(0, 0, 255, 0.4);
  border-radius: var(--radius-md);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  background: rgba(6, 6, 6, 0.92);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 520px;
}

th,
td {
  text-align: left;
  padding: 0.78rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

thead th {
  color: #ededff;
  background: rgba(0, 0, 255, 0.18);
  font-size: 0.76rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr:hover td {
  background: rgba(0, 0, 255, 0.08);
}

.faq {
  border: 1px solid rgba(255, 15, 34, 0.44);
  border-radius: var(--radius-md);
  background: rgba(6, 6, 6, 0.9);
  padding: var(--space-3) var(--space-4);
}

details {
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  padding: 0.78rem 0;
}

details:last-child {
  border-bottom: none;
}

summary {
  cursor: pointer;
  color: var(--text);
  font-weight: 600;
  letter-spacing: 0.02em;
}

summary + p {
  margin-top: 0.55rem;
}

.newsletter {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.58rem;
}

.input,
textarea {
  width: 100%;
  border: 1px solid rgba(0, 0, 255, 0.38);
  border-radius: var(--radius-sm);
  background: rgba(0, 0, 0, 0.88);
  color: var(--text);
  padding: 0.68rem 0.72rem;
}

.input:focus-visible,
textarea:focus-visible {
  border-color: rgba(57, 255, 20, 0.66);
}

.input::placeholder,
textarea::placeholder {
  color: #7f7f7f;
}

label {
  display: inline-block;
  margin-bottom: 0.36rem;
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  color: var(--text-soft);
}

.helper-text {
  font-size: 0.84rem;
  color: var(--text-soft);
}

.status-note {
  min-height: 1.2em;
  font-size: 0.88rem;
  margin-top: 0.4rem;
}

.status-note.error {
  color: var(--accent-alert);
}

.status-note.success {
  color: var(--accent-success);
}

.cta-cluster {
  display: flex;
  flex-wrap: wrap;
  gap: 0.62rem;
}

.resource-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-2);
}

.resource-item {
  border: 1px solid rgba(0, 0, 255, 0.4);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.85rem;
  background: rgba(5, 5, 5, 0.86);
  display: flex;
  justify-content: space-between;
  gap: var(--space-2);
  align-items: baseline;
  min-width: 0;
  flex-wrap: wrap;
}

.resource-item > div {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  flex: 1 1 auto;
}

.resource-item > strong {
  min-width: 0;
  flex: 1 1 auto;
}

.resource-item a,
.resource-item .pill {
  min-width: 0;
  flex: 0 0 auto;
  overflow-wrap: anywhere;
  text-align: right;
}

.resource-item strong {
  color: var(--text);
}

.resource-item span {
  color: var(--text-soft);
  font-size: 0.83rem;
}

.site-footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid rgba(0, 0, 255, 0.44);
  margin-top: var(--space-7);
  padding: var(--space-5) 0;
  background: rgba(0, 0, 0, 0.75);
}

.interactive-surface {
  position: relative;
  transform: perspective(960px) rotateX(calc(var(--tilt-y, 0) * 1deg))
    rotateY(calc(var(--tilt-x, 0) * -1deg));
  transition: transform 140ms ease, border-color 140ms ease;
}

.interactive-surface::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    220px circle at var(--glow-x, 50%) var(--glow-y, 50%),
    rgba(57, 255, 20, 0.12),
    rgba(0, 0, 255, 0.09) 30%,
    transparent 65%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 150ms ease;
}

.interactive-surface.is-hovered::after {
  opacity: 1;
}

.glitch-layer {
  position: fixed;
  inset: 0;
  z-index: 66;
  overflow: hidden;
  pointer-events: none;
  mix-blend-mode: screen;
}

.glitch-fragment {
  position: fixed;
  left: var(--gx);
  top: var(--gy);
  opacity: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  animation: glitch-fragment 560ms steps(2, end) forwards;
  will-change: transform, opacity;
}

.glitch-fragment.line {
  width: var(--gw);
  height: 1px;
  background: var(--accent-primary);
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.6), 18px 0 0 rgba(255, 15, 34, 0.46);
}

.glitch-fragment.block {
  width: var(--gw);
  height: var(--gh);
  border: 1px solid rgba(57, 255, 20, 0.48);
  background:
    linear-gradient(90deg, rgba(255, 15, 34, 0.28), transparent 42%),
    rgba(57, 255, 20, 0.07);
}

.glitch-fragment.label {
  padding: 0.15rem 0.35rem;
  border-left: 2px solid var(--accent-alert);
  color: rgba(216, 255, 210, 0.86);
  background: rgba(0, 0, 0, 0.78);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-shadow: 1px 0 rgba(0, 0, 255, 0.72), -1px 0 rgba(255, 15, 34, 0.62);
}

.is-system-glitch {
  animation: panel-glitch 260ms steps(2, end);
}

.text-glitch {
  position: relative;
  isolation: isolate;
}

.text-glitch::before,
.text-glitch::after {
  content: attr(data-glitch-text);
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0;
  overflow: hidden;
  color: currentColor;
  pointer-events: none;
  white-space: inherit;
}

.text-glitch.is-text-glitch {
  animation: text-glitch-base 360ms steps(2, end);
  text-shadow: 1px 0 rgba(0, 0, 255, 0.55), -1px 0 rgba(255, 15, 34, 0.48);
}

.text-glitch.is-text-glitch::before {
  z-index: 1;
  opacity: 0.82;
  color: var(--accent-secondary);
  animation: text-glitch-top 360ms steps(2, end);
  clip-path: inset(0 0 58% 0);
}

.text-glitch.is-text-glitch::after {
  z-index: 1;
  opacity: 0.72;
  color: var(--accent-alert);
  animation: text-glitch-bottom 360ms steps(2, end);
  clip-path: inset(46% 0 0 0);
}

@keyframes glitch-fragment {
  0% {
    opacity: 0;
    transform: translate3d(-14px, 0, 0) scaleX(0.34);
  }

  14% {
    opacity: 0.92;
    transform: translate3d(8px, -1px, 0) scaleX(1);
  }

  25% {
    opacity: 0.28;
    transform: translate3d(-5px, 2px, 0) scaleX(0.72);
  }

  42% {
    opacity: 0.86;
    transform: translate3d(2px, 0, 0) scaleX(1.08);
  }

  100% {
    opacity: 0;
    transform: translate3d(20px, 0, 0) scaleX(0.2);
  }
}

@keyframes text-glitch-base {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  18% {
    transform: translate3d(-1px, 0, 0);
  }

  34% {
    transform: translate3d(2px, -1px, 0);
  }

  52% {
    transform: translate3d(-2px, 1px, 0);
  }

  74% {
    transform: translate3d(1px, 0, 0);
  }
}

@keyframes text-glitch-top {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  20% {
    transform: translate3d(5px, -1px, 0);
  }

  44% {
    transform: translate3d(-4px, 1px, 0);
  }

  66% {
    transform: translate3d(3px, 0, 0);
  }
}

@keyframes text-glitch-bottom {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  16% {
    transform: translate3d(-5px, 1px, 0);
  }

  42% {
    transform: translate3d(4px, 0, 0);
  }

  70% {
    transform: translate3d(-2px, -1px, 0);
  }
}

@keyframes panel-glitch {
  0%,
  100% {
    filter: none;
    transform: translate3d(0, 0, 0);
  }

  22% {
    filter: drop-shadow(2px 0 0 rgba(0, 0, 255, 0.38)) drop-shadow(-2px 0 0 rgba(255, 15, 34, 0.32));
    transform: translate3d(-2px, 1px, 0);
  }

  48% {
    filter: drop-shadow(-1px 0 0 rgba(255, 15, 34, 0.42));
    transform: translate3d(2px, -1px, 0);
  }

  68% {
    filter: drop-shadow(1px 0 0 rgba(57, 255, 20, 0.44));
    transform: translate3d(0, 1px, 0);
  }
}

.reveal-on-scroll {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 240ms ease, transform 240ms ease;
}

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-3);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem 1rem;
}

.footer-links a {
  font-size: 0.88rem;
}

.eyebrow {
  margin: 0 0 0.4rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  color: var(--text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* One-of-one homepage: live terminal / computer interior */
body[data-page="home"] {
  background:
    radial-gradient(600px circle at var(--mx) var(--my), rgba(57, 255, 20, 0.16), transparent 58%),
    linear-gradient(180deg, #000 0%, #030303 100%);
}

body[data-page="home"]::before {
  background:
    linear-gradient(rgba(57, 255, 20, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 0, 255, 0.05) 1px, transparent 1px),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0, rgba(255, 255, 255, 0.035) 1px, transparent 1px, transparent 4px);
  background-size: 44px 44px, 44px 44px, 100% 6px;
  opacity: 0.55;
}

body[data-page="home"] .site-header {
  border-bottom-color: var(--border);
}

.system-hero {
  min-height: calc(100vh - 72px);
  padding: clamp(1rem, 3vw, 2rem) 0 var(--space-6);
}

.system-shell {
  position: relative;
  overflow: hidden;
  min-height: calc(100vh - 120px);
  border: 1px solid var(--border);
  border-radius: 4px;
  background:
    radial-gradient(420px circle at var(--mx) var(--my), var(--glow-accent-soft), transparent 60%),
    #030303;
  box-shadow:
    inset 0 0 0 1px rgba(255, 255, 255, 0.03),
    0 26px 80px rgba(0, 0, 0, 0.78);
}

.system-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent 0 64px, var(--scanline) 64px 65px);
  transform: translateX(calc((var(--mx) - 50vw) * 0.018));
  pointer-events: none;
}

.system-shell::after {
  content: "";
  position: absolute;
  right: clamp(-110px, -6vw, -40px);
  top: 72px;
  width: min(460px, 42vw);
  aspect-ratio: 1;
  background: url("../brand/sc-mark-green.png") center / contain no-repeat;
  opacity: 0.08;
  transform: translate(calc((var(--mx) - 50vw) * -0.018), calc((var(--my) - 50vh) * -0.012));
  pointer-events: none;
}

.system-topbar {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.75rem;
  min-height: 48px;
  padding: 0 1rem;
  border-bottom: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.72);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.terminal-lights {
  display: flex;
  align-items: center;
  width: 52px;
  height: 12px;
  line-height: 0;
  flex-shrink: 0;
}

.terminal-lights-svg {
  display: block;
  width: 52px;
  height: 12px;
}

.terminal-light {
  stroke: rgba(255, 255, 255, 0.14);
  stroke-width: 0.5;
}

.terminal-light-green {
  fill: var(--accent-primary);
}

.terminal-light-blue {
  fill: #444444;
}

.terminal-light-red {
  fill: #444444;
}

.terminal-light-overlay {
  fill: #000000;
  opacity: var(--terminal-light-dim);
  stroke: none;
}

.terminal-path {
  color: var(--text-muted);
}

.terminal-status {
  color: var(--text-muted);
  text-align: right;
}

.terminal-status [data-cursor-readout] {
  color: var(--accent-primary);
}

.system-grid {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(1rem, 3vw, 2rem);
  align-items: center;
  min-height: calc(100vh - 190px);
  padding: clamp(1.2rem, 4vw, 3.5rem);
}

.system-copy {
  max-width: 940px;
  margin: 0 auto;
  text-align: center;
}

.boot-line {
  width: fit-content;
  margin: 0 auto 1rem;
  padding: 0.42rem 0.65rem;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.6);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.boot-line.error-line {
  border-color: var(--border-accent);
  background: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.06);
  color: var(--accent-primary);
}

.system-title {
  position: relative;
  margin-bottom: 1rem;
  font-family: var(--font-display);
  color: var(--text);
  font-size: clamp(3.8rem, 11vw, 9.8rem);
  font-weight: 400;
  line-height: 0.78;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.logo-title {
  width: min(760px, 92vw);
  min-height: clamp(220px, 36vw, 390px);
  margin: 0 auto 1.2rem;
  transform: translateY(5%);
  font-size: 0;
  line-height: 0;
  letter-spacing: 0;
  text-shadow: none;
}

.logo-layer,
.logo-hero {
  display: block;
  width: 100%;
  height: auto;
  pointer-events: none;
  user-select: none;
}

.logo-layer-green {
  position: relative;
  z-index: 3;
}

.logo-layer-blue,
.logo-layer-red {
  position: absolute;
  inset: 0;
  opacity: 0.2;
  mix-blend-mode: screen;
}

.logo-layer-blue {
  z-index: 1;
  transform: translate(calc((var(--mx) - 50vw) * 0.01), calc((var(--my) - 50vh) * -0.006));
}

.logo-layer-red {
  z-index: 2;
  transform: translate(calc((var(--mx) - 50vw) * -0.012), calc((var(--my) - 50vh) * 0.007));
}

.system-title::after {
  content: attr(data-text);
  position: absolute;
  left: calc((var(--mx) - 50vw) * 0.01);
  top: calc((var(--my) - 50vh) * 0.006);
  color: transparent;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.18);
  text-shadow: none;
  pointer-events: none;
}

.system-subtitle {
  margin-left: auto;
  margin-right: auto;
  max-width: 58ch;
  color: #e6e6e6;
  font-size: clamp(1rem, 1.7vw, 1.24rem);
}

.command-dock {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  max-width: 780px;
  margin: 2rem auto 0;
}

.command-tile {
  position: relative;
  overflow: hidden;
  min-height: 96px;
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 0.9rem;
  background: rgba(0, 0, 0, 0.72);
  color: var(--text);
  text-decoration: none;
  transform: translateY(0);
  transition: transform 140ms ease, border-color 140ms ease, background 140ms ease, box-shadow 140ms ease;
}

.command-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(180px circle at var(--glow-x, 50%) var(--glow-y, 50%), var(--glow-accent-soft), transparent 62%);
  opacity: 0;
  transition: opacity 140ms ease;
}

.command-tile:hover,
.command-tile:focus-visible {
  transform: translateY(-2px);
  border-color: var(--border-accent);
  box-shadow: 0 0 16px var(--glow-accent-soft);
  text-decoration: none;
}

.command-tile:hover::after,
.command-tile:focus-visible::after {
  opacity: 1;
}

.command-tile span,
.command-tile strong {
  position: relative;
  z-index: 1;
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.command-tile span {
  color: var(--text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.command-tile strong {
  margin-top: 0.5rem;
  color: var(--text-muted);
  font-size: clamp(0.92rem, 1.5vw, 1.1rem);
  transition: color 140ms ease;
}

.command-tile:hover strong,
.command-tile:focus-visible strong {
  color: var(--accent-primary);
  text-shadow: 0 0 10px var(--glow-accent);
}

.command-tile.primary {
  border-color: var(--border);
}

.command-tile.primary:hover,
.command-tile.primary:focus-visible {
  border-color: var(--border-accent);
}

.command-tile.secondary,
.command-tile.alert {
  border-color: var(--border-dim);
}

.system-monitor {
  width: min(760px, 100%);
  margin: 0 auto;
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.78);
}

.monitor-mark {
  position: absolute;
  right: -34px;
  bottom: -72px;
  width: min(320px, 54%);
  opacity: 0.16;
  pointer-events: none;
}

.monitor-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0.9rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
}

.monitor-readout {
  display: grid;
  gap: 0;
  margin: 0;
}

.monitor-readout div {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 1rem;
  padding: 0.95rem 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.monitor-readout dt,
.monitor-readout dd {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.76rem;
}

.monitor-readout dt {
  color: var(--text-soft);
}

.monitor-readout dd {
  color: var(--text);
  text-align: right;
}

.monitor-readout dd:hover {
  color: var(--accent-primary);
}

.signal-stack {
  display: flex;
  align-items: end;
  gap: 0.45rem;
  height: 160px;
  padding: 1rem;
}

.signal-stack span {
  flex: 1;
  height: var(--level);
  min-height: 12%;
  background: var(--accent-primary);
  transform-origin: bottom;
  animation: signal-pulse 900ms ease-in-out infinite alternate;
  animation-delay: calc(var(--level) * -8ms);
}

.system-module {
  position: relative;
  margin-top: var(--space-6);
  padding: var(--space-5) 0;
  border-top: 1px solid var(--border);
}

.system-module::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -1px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-accent), transparent);
  opacity: 0.5;
}

.module-header {
  max-width: 760px;
  margin-bottom: var(--space-4);
}

.module-header h2,
.release-console h2,
.proof-console h2,
.handshake-console h2 {
  max-width: 760px;
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.process-node {
  position: relative;
  min-height: 160px;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.78);
  color: var(--text);
  padding: 1rem;
  overflow: hidden;
  cursor: pointer;
  transition: border-color 140ms ease, background 140ms ease;
}

.process-node::before {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 3px;
  background: var(--accent-primary);
  transform: scaleX(0.18);
  transform-origin: left;
  transition: transform 180ms ease, background 180ms ease;
}

.process-node:hover::before,
.process-node:focus-visible::before,
.process-node.is-active::before {
  transform: scaleX(1);
}

.process-node.is-active {
  border-color: var(--border-accent);
  background: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.04);
  box-shadow: inset 0 0 24px var(--glow-accent-soft);
}

.process-node:nth-child(2)::before {
  background: var(--accent-primary);
}

.process-node:nth-child(3)::before {
  background: var(--accent-primary);
}

.process-node:nth-child(4)::before {
  background: var(--accent-primary);
}

.node-id,
.process-node em,
.kernel-output span {
  display: block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-style: normal;
  text-transform: uppercase;
}

.node-id {
  color: var(--text-soft);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
}

.process-node strong {
  display: block;
  margin-top: 1.7rem;
  font-size: 1rem;
  text-transform: uppercase;
}

.process-node em {
  margin-top: 0.6rem;
  color: var(--text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
}

.kernel-output {
  margin-top: 0.85rem;
  border: 1px solid var(--border);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.78);
  padding: 1rem;
}

.kernel-output span {
  color: var(--text-soft);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
}

.kernel-output strong {
  display: block;
  margin-top: 0.35rem;
  color: var(--accent-primary);
  text-transform: uppercase;
  text-shadow: 0 0 12px var(--glow-accent-soft);
}

.kernel-output p {
  margin: 0.35rem 0 0;
}

.split-console,
.handshake-console {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 1rem;
  width: 100%;
  min-width: 0;
}

.release-console,
.routing-console,
.proof-console,
.handshake-console,
.terminal-form {
  border: 1px solid var(--border);
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.78);
  padding: clamp(1rem, 3vw, 1.5rem);
  min-width: 0;
  max-width: 100%;
}

.routing-console {
  border-color: var(--border);
}

.routing-kicker .typing-dots {
  display: inline-block;
  min-width: 1.1em;
}

.routing-kicker .dot {
  opacity: 0;
  animation-duration: 3s;
  animation-timing-function: steps(1, end);
  animation-iteration-count: infinite;
}

.routing-kicker .dot-1 {
  animation-name: routing-dot-1;
}

.routing-kicker .dot-2 {
  animation-name: routing-dot-2;
}

.routing-kicker .dot-3 {
  animation-name: routing-dot-3;
}

@keyframes routing-dot-1 {
  0%,
  12% {
    opacity: 0;
  }

  13%,
  88% {
    opacity: 1;
  }

  89%,
  100% {
    opacity: 0;
  }
}

@keyframes routing-dot-2 {
  0%,
  28% {
    opacity: 0;
  }

  29%,
  88% {
    opacity: 1;
  }

  89%,
  100% {
    opacity: 0;
  }
}

@keyframes routing-dot-3 {
  0%,
  44% {
    opacity: 0;
  }

  45%,
  54% {
    opacity: 1;
  }

  55%,
  58% {
    opacity: 0.2;
  }

  59%,
  62% {
    opacity: 1;
  }

  63%,
  66% {
    opacity: 0.2;
  }

  67%,
  70% {
    opacity: 1;
  }

  71%,
  74% {
    opacity: 0.2;
  }

  75%,
  78% {
    opacity: 1;
  }

  79%,
  82% {
    opacity: 0.2;
  }

  83%,
  86% {
    opacity: 1;
  }

  87%,
  88% {
    opacity: 0.2;
  }

  89%,
  100% {
    opacity: 0;
  }
}

.audio-visual {
  position: relative;
  height: 148px;
  margin: 1.4rem 0;
  padding: 0.45rem 0.65rem 0.55rem;
  border: 1px solid rgba(255, 15, 34, 0.46);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.82);
  overflow: hidden;
}

.audio-visual canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.audio-visual::after {
  content: "audio.spectrum.rgb_channels";
  position: absolute;
  left: 0.85rem;
  top: 0.55rem;
  color: rgba(255, 255, 255, 0.55);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  pointer-events: none;
  z-index: 2;
}

.audio-visual.is-playing::after {
  color: rgba(255, 255, 255, 0.82);
}

.soundcloud-player {
  position: relative;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
  margin: 1.2rem 0 0;
  border: 1px solid rgba(255, 15, 34, 0.5);
  border-radius: 14px;
  background: #000;
  isolation: isolate;
}

.soundcloud-player::before {
  content: "soundcloud.embed";
  position: absolute;
  z-index: 1;
  right: 0.75rem;
  top: 0.55rem;
  color: rgba(255, 15, 34, 0.75);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  pointer-events: none;
}

.soundcloud-player iframe {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  height: 166px;
  border: 0;
  filter: grayscale(1) contrast(1.12);
}

.route-line {
  display: grid;
  grid-template-columns: minmax(0, 7rem) minmax(0, 1fr) minmax(0, auto);
  gap: 0.75rem;
  align-items: center;
  min-width: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.85rem 0;
}

.route-line > * {
  min-width: 0;
}

.route-line strong {
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.route-line em,
.route-date,
.inline-command,
.terminal-output,
.terminal-form {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.route-date {
  color: var(--accent-primary);
  font-size: 0.76rem;
}

.route-line em {
  color: var(--text-soft);
  font-style: normal;
  font-size: 0.76rem;
  text-transform: uppercase;
  text-align: right;
  overflow-wrap: anywhere;
}

.routing-kicker {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.inline-command {
  display: inline-block;
  margin-top: 1rem;
  color: var(--accent-secondary);
  font-size: 0.82rem;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.proof-console {
  display: grid;
  grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.2fr);
  gap: 1rem;
}

.terminal-output {
  border: 1px solid rgba(0, 0, 255, 0.44);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.8);
  padding: 1rem;
  overflow: hidden;
}

.terminal-output p {
  margin: 0;
  padding: 0.55rem 0;
  color: #dcdcdc;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.terminal-output p:last-child {
  border-bottom: none;
}

.terminal-output span {
  color: var(--accent-alert);
}

.handshake-console {
  align-items: center;
}

.terminal-form {
  border-color: rgba(0, 0, 255, 0.46);
}

.system-visual {
  position: absolute;
  inset: 48px 0 0;
  overflow: hidden;
  z-index: 1;
  pointer-events: none;
}

.cursor-orb {
  position: absolute;
  left: var(--mx);
  top: var(--my);
  width: 220px;
  height: 220px;
  border: 1px solid var(--border-accent);
  border-radius: 999px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, var(--glow-accent-soft), transparent 70%);
  mix-blend-mode: screen;
  opacity: 0.5;
}

.core-cross {
  position: absolute;
  left: calc(50% + (var(--mx) - 50vw) * -0.055);
  top: calc(50% + (var(--my) - 50vh) * -0.045);
  width: min(36vw, 420px);
  transform: translate(-50%, -50%);
  mix-blend-mode: screen;
}

.core-cross-blue,
.core-cross-red {
  display: none;
}

.core-cross-green {
  opacity: 0.08;
}

.data-rain {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 1rem;
  padding: 1rem;
  opacity: 0.18;
}

.data-rain span {
  color: var(--text-soft);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  writing-mode: vertical-rl;
  transform: translateY(calc((var(--my) - 50vh) * 0.025));
}

@keyframes signal-pulse {
  from {
    transform: scaleY(0.66);
    opacity: 0.58;
  }

  to {
    transform: scaleY(1);
    opacity: 1;
  }
}

.tech-field {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100vw;
  height: 100vh;
  background: #000;
  pointer-events: none;
}

body[data-page="home"],
body[data-page="home"] .system-shell,
body[data-page="home"] .system-monitor,
body[data-page="home"] .release-console,
body[data-page="home"] .routing-console,
body[data-page="home"] .proof-console,
body[data-page="home"] .handshake-console,
body[data-page="home"] .terminal-form,
body[data-page="home"] .process-node,
body[data-page="home"] .kernel-output,
body[data-page="home"] .command-tile {
  background: #000;
}

body[data-page="home"]::before {
  background:
    linear-gradient(var(--scanline) 1px, transparent 1px),
    linear-gradient(90deg, var(--scanline) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.72;
}

body[data-page="home"] .system-shell {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.03);
}

body[data-page="home"] .system-shell::before {
  background: repeating-linear-gradient(90deg, transparent 0 84px, var(--scanline) 84px 85px);
}

body[data-page="home"] .system-title {
  color: var(--text);
  text-shadow: none;
}

body[data-page="home"] .system-title::after {
  display: none;
}

body[data-page="home"] .command-tile::after,
body[data-page="home"] .interactive-surface::after {
  background: transparent;
  border: 1px solid var(--border-dim);
}

body[data-page="home"] .command-tile:hover,
body[data-page="home"] .command-tile:focus-visible,
body[data-page="home"] .process-node:hover,
body[data-page="home"] .process-node:focus-visible {
  background: #050505;
}

body[data-page="home"] .signal-stack span {
  background: var(--text-soft);
}

body[data-page="home"] .signal-stack span:nth-child(3n + 2) {
  background: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.45);
}

body[data-page="home"] .signal-stack span:nth-child(3n) {
  background: var(--accent-primary);
}

body[data-page="home"] .system-module::before,
body[data-page="home"] .card::before,
body[data-page="home"] .process-node:nth-child(4)::before {
  background: var(--border-accent);
}

body[data-page="home"] .cursor-orb {
  background: radial-gradient(circle, var(--glow-accent-soft), transparent 70%);
  border-color: var(--border-accent);
}

body[data-page="home"] .data-rain {
  opacity: 0.14;
}

body:not([data-page="home"]) {
  background: #000;
}

body:not([data-page="home"])::before {
  background:
    linear-gradient(rgba(57, 255, 20, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.016) 1px, transparent 1px);
  background-size: 44px 44px;
  opacity: 0.74;
}

body:not([data-page="home"]) .page-main {
  padding-bottom: var(--space-6);
}

body:not([data-page="home"]) .hero {
  padding: clamp(2.5rem, 6vw, 4.8rem) 0 var(--space-5);
}

body:not([data-page="home"]) .hero .container {
  position: relative;
  overflow: hidden;
  min-height: clamp(280px, 42vw, 420px);
  padding: clamp(4.8rem, 8vw, 6rem) clamp(1.1rem, 4vw, 2rem) clamp(1.4rem, 4vw, 2.2rem);
  border: 1px solid rgba(57, 255, 20, 0.36);
  border-radius: 20px;
  background: #000;
  box-shadow: 0 0 0 1px rgba(57, 255, 20, 0.12), inset 0 0 34px rgba(57, 255, 20, 0.035);
}

body:not([data-page="home"]) .hero .container::before {
  content: "systems.critical/page.boot";
  position: absolute;
  inset: 0 0 auto;
  height: 2.85rem;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid rgba(57, 255, 20, 0.26);
  color: rgba(216, 255, 210, 0.82);
  background: #020202;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

body:not([data-page="home"]) .hero .container::after {
  content: "";
  position: absolute;
  right: clamp(-3.2rem, -4vw, -1.2rem);
  bottom: clamp(-4.4rem, -7vw, -2.2rem);
  width: min(310px, 46vw);
  aspect-ratio: 1;
  background: url("../brand/sc-mark-green.png") center / contain no-repeat;
  opacity: 0.16;
  pointer-events: none;
}

body:not([data-page="home"]) .hero .kicker,
body:not([data-page="home"]) .hero h1,
body:not([data-page="home"]) .hero .lead {
  position: relative;
  z-index: 1;
}

body:not([data-page="home"]) .hero h1 {
  max-width: 12ch;
  color: var(--accent-primary);
  text-shadow: 1px 0 0 rgba(0, 0, 255, 0.42), -1px 0 0 rgba(255, 15, 34, 0.28);
}

body:not([data-page="home"]) .hero .lead {
  max-width: 60ch;
}

body:not([data-page="home"]) .section {
  position: relative;
  margin-top: var(--space-5);
  border-top-color: rgba(57, 255, 20, 0.28);
}

body:not([data-page="home"]) .section::before {
  content: "";
  position: absolute;
  left: max(1rem, calc((100vw - var(--max-width)) / 2));
  top: -1px;
  width: min(220px, calc(100vw - 2rem));
  height: 1px;
  background: var(--accent-primary);
}

body:not([data-page="home"]) .section-intro {
  align-items: stretch;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(57, 255, 20, 0.24);
  border-radius: 14px;
  background: #000;
}

body:not([data-page="home"]) .card,
body:not([data-page="home"]) .faq {
  overflow: hidden;
  border-color: rgba(57, 255, 20, 0.28);
  background: #000;
  box-shadow: 0 0 0 1px rgba(57, 255, 20, 0.08);
}

body:not([data-page="home"]) .table-wrap {
  overflow-x: auto;
  overflow-y: hidden;
  max-width: 100%;
  border-color: rgba(57, 255, 20, 0.28);
  background: #000;
  box-shadow: 0 0 0 1px rgba(57, 255, 20, 0.08);
}

body:not([data-page="home"]) .card::before {
  height: 1px;
  background: var(--accent-primary);
}

body:not([data-page="home"]) .card h2,
body:not([data-page="home"]) .card h3 {
  color: #f7fff5;
}

body:not([data-page="home"]) .card .kicker::before,
body:not([data-page="home"]) .section-intro .kicker::before {
  color: var(--accent-primary);
}

body:not([data-page="home"]) .resource-item,
body:not([data-page="home"]) .stat-card {
  border-color: rgba(57, 255, 20, 0.26);
  background: #020202;
}

body:not([data-page="home"]) .resource-item:hover {
  border-color: rgba(57, 255, 20, 0.58);
  background: rgba(57, 255, 20, 0.045);
}

body:not([data-page="home"]) thead th {
  color: #d8ffd2;
  background: rgba(57, 255, 20, 0.08);
}

body:not([data-page="home"]) tbody tr:hover td {
  background: rgba(57, 255, 20, 0.045);
}

body:not([data-page="home"]) .input,
body:not([data-page="home"]) textarea,
body:not([data-page="home"]) select {
  border-color: rgba(57, 255, 20, 0.32);
  background: #020202;
}

body:not([data-page="home"]) .site-footer {
  border-top-color: rgba(57, 255, 20, 0.28);
  background: #000;
}

body:not([data-page="home"]) .interactive-surface::after {
  background: transparent;
  border: 1px solid rgba(57, 255, 20, 0.16);
}

@media (max-width: 980px) {
  .system-grid {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .system-monitor {
    max-width: 640px;
  }

  .command-dock {
    grid-template-columns: 1fr;
  }

  .process-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .split-console,
  .handshake-console,
  .proof-console {
    grid-template-columns: 1fr;
  }

  .route-line {
    grid-template-columns: minmax(0, 1fr) minmax(0, auto);
    grid-template-areas:
      "date status"
      "title title";
    gap: 0.3rem 0.75rem;
    align-items: center;
  }

  .route-date {
    grid-area: date;
  }

  .route-line strong {
    grid-area: title;
  }

  .route-line em {
    grid-area: status;
    justify-self: end;
    max-width: 100%;
  }
}

@media (max-width: 720px) {
  .table-wrap {
    overflow-x: visible;
  }

  .table-wrap table {
    min-width: 0;
    display: block;
  }

  .table-wrap thead {
    display: none;
  }

  .table-wrap tbody {
    display: block;
  }

  .table-wrap tbody tr {
    display: block;
    margin-bottom: 0.65rem;
    border: 1px solid rgba(57, 255, 20, 0.2);
    border-radius: 12px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.6);
  }

  .table-wrap tbody tr:last-child {
    margin-bottom: 0;
  }

  .table-wrap tbody td {
    display: grid;
    grid-template-columns: minmax(0, 6.5rem) minmax(0, 1fr);
    gap: 0.6rem;
    align-items: start;
    padding: 0.55rem 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  .table-wrap tbody tr td:last-child {
    border-bottom: none;
  }

  .table-wrap tbody td::before {
    content: attr(data-label);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--accent-primary);
  }

  .table-wrap tbody tr:hover td {
    background: transparent;
  }
}

@media (max-width: 520px) {
  .route-line {
    grid-template-columns: 1fr;
    grid-template-areas:
      "date"
      "title"
      "status";
    gap: 0.2rem;
  }

  .route-line em {
    text-align: left;
    justify-self: start;
  }
}

@media (max-width: 680px) {
  .system-shell {
    min-height: auto;
    border-radius: 16px;
  }

  .system-topbar {
    grid-template-columns: auto 1fr;
  }

  .terminal-status {
    display: none;
  }

  .system-grid {
    min-height: auto;
    padding: 1rem 0.75rem 1.25rem;
  }

  .boot-line {
    max-width: 100%;
    white-space: normal;
    text-align: center;
  }

  .system-title {
    font-size: clamp(3rem, 17vw, 5rem);
  }

  .logo-title {
    width: min(100%, 560px);
    min-height: auto;
    margin: 0.35rem auto 1.45rem;
    transform: translateY(3%);
  }

  .system-subtitle {
    max-width: 32ch;
    margin-left: auto;
    margin-right: auto;
  }

  .data-rain {
    grid-template-columns: repeat(4, 1fr);
  }

  .process-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  body[data-page="home"] .hero {
    min-height: auto;
  }

  .grid.three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  html {
    scroll-padding-bottom: 5rem;
  }

  body {
    padding-bottom: 4.4rem;
  }

  .header-inner {
    gap: 0.75rem;
    min-height: 68px;
  }

  .brand-logo {
    width: min(180px, 48vw);
  }

  .brand-sub {
    font-size: 0.58rem;
    letter-spacing: 0.1em;
  }

  .menu-toggle {
    display: inline-flex;
    flex: 0 0 auto;
    width: auto;
    min-width: 48px;
    height: 48px;
    padding: 0 0.5rem;
    font-size: 0.64rem;
    letter-spacing: 0.12em;
  }

  .nav-link {
    display: block;
    text-align: center;
    text-transform: uppercase;
  }

  .main-nav {
    gap: var(--space-2);
  }

  .nav-links {
    position: absolute;
    top: 72px;
    right: 1rem;
    width: min(312px, calc(100% - 2rem));
    padding: 0.86rem;
    border-radius: var(--radius-md);
    border: 1px solid rgba(0, 0, 255, 0.5);
    background: rgba(0, 0, 0, 0.95);
    box-shadow: var(--shadow-soft);
    flex-direction: column;
    align-items: stretch;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 140ms ease, transform 140ms ease, visibility 140ms ease;
  }

  .nav-links[data-open="true"] {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .header-cta {
    display: none;
  }

  .signal-uplink {
    left: 50%;
    right: auto;
    top: auto;
    bottom: 0.7rem;
    grid-auto-flow: column;
    grid-template-columns: repeat(5, auto);
    justify-content: center;
    width: min(245px, calc(100vw - 1.5rem));
    gap: 0.32rem;
    padding: 0.34rem 0.55rem;
    transform: translateX(-50%);
    box-sizing: border-box;
  }

  .signal-uplink::before {
    left: 0.8rem;
    right: 0.8rem;
    top: 50%;
    bottom: auto;
    width: auto;
    height: 1px;
    transform: translateY(-50%);
    background: linear-gradient(90deg, transparent, rgba(57, 255, 20, 0.42), transparent);
  }

  .uplink-label {
    display: none;
  }

  .social-node {
    width: 34px;
    height: 34px;
  }

  .node-label {
    right: auto;
    left: 50%;
    top: auto;
    bottom: calc(100% + 0.6rem);
    transform: translate(-50%, 8px);
  }

  .social-node::after {
    display: none;
  }

  .social-node:hover .node-label,
  .social-node:focus-visible .node-label {
    transform: translate(-50%, 0);
  }
}

@media (max-width: 680px) {
  .grid.two,
  .grid.three {
    grid-template-columns: 1fr;
  }

  .bio-split {
    align-items: start;
  }

  .bio-stack {
    height: auto;
  }

  .promo-shot {
    flex: none;
  }

  .promo-shot img {
    height: auto;
    object-fit: initial;
  }

  .resource-item {
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0.35rem;
  }

  .resource-item > div,
  .resource-item > strong {
    flex: 0 0 auto;
  }

  .resource-item a,
  .resource-item .pill {
    text-align: left;
  }

  .hero {
    padding-top: var(--space-6);
  }

  body:not([data-page="home"]) .hero {
    padding-top: var(--space-4);
  }

  body:not([data-page="home"]) .hero .container {
    min-height: auto;
    padding: 4.4rem 1rem 1.35rem;
  }

  body:not([data-page="home"]) .hero h1 {
    max-width: 10ch;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .newsletter {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero-logo-lockup {
    gap: 0.45rem;
  }

  .hero-symbol {
    width: 20px;
    height: 20px;
  }

  .hero-wordmark {
    font-size: 0.62rem;
    letter-spacing: 0.16em;
  }

  h1 {
    font-size: clamp(1.8rem, 9vw, 2.7rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    transition-duration: 0ms !important;
    animation-duration: 0ms !important;
  }

  .interactive-surface {
    transform: none !important;
  }

  .glitch-layer {
    display: none;
  }

  .is-system-glitch {
    animation: none !important;
  }

  .routing-kicker .dot {
    opacity: 1;
    animation: none !important;
  }
}

/* —— CMD terminal session (homepage) —— */

body[data-page="home"] {
  font-family: Consolas, "Courier New", var(--font-mono);
  font-size: 0.9rem;
  background: #0a0a0a;
}

body[data-page="home"] .tech-field,
body[data-page="home"] .signal-uplink:not(.signal-uplink--terminal) {
  display: none;
}

/* Terminal showcase — social uplink beside promo photo (top/left set in JS) */
body[data-terminal-shell] .signal-uplink--terminal {
  position: fixed;
  right: auto;
  z-index: 68;
  display: grid;
  gap: 0.38rem;
  padding: 0.5rem 0.32rem;
  border: 1px solid #333;
  border-radius: 2px;
  background: rgba(10, 10, 10, 0.88);
  backdrop-filter: blur(6px);
  pointer-events: auto;
  overflow: visible;
}

body[data-terminal-shell] .signal-uplink--terminal[hidden] {
  display: none !important;
}

body[data-terminal-shell] .signal-uplink--terminal::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0.75rem;
  bottom: 0.75rem;
  width: 1px;
  background: linear-gradient(180deg, transparent, #333, transparent);
  transform: translateX(-50%);
  pointer-events: none;
}

body[data-terminal-shell] .signal-uplink--terminal .uplink-label {
  right: calc(100% + 0.55rem);
  left: auto;
  color: #666;
  font-family: inherit;
  font-size: 0.56rem;
  letter-spacing: 0.14em;
  transform: translateY(-50%) rotate(-90deg);
  transform-origin: center right;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node {
  width: 34px;
  height: 34px;
  border-color: #333;
  background: #050505;
  animation: uplink-idle-terminal 3.2s ease-in-out infinite;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node:hover,
body[data-terminal-shell] .signal-uplink--terminal .social-node:focus-visible {
  color: #fff;
  border-color: var(--border-accent);
  box-shadow: 0 0 12px rgba(57, 255, 20, 0.18);
  text-shadow: none;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node:hover::before,
body[data-terminal-shell] .signal-uplink--terminal .social-node:focus-visible::before {
  opacity: 0;
  transform: none;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node:hover .node-icon,
body[data-terminal-shell] .signal-uplink--terminal .social-node:focus-visible .node-icon {
  color: #fff;
  opacity: 1;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node:hover .node-code,
body[data-terminal-shell] .signal-uplink--terminal .social-node:focus-visible .node-code {
  opacity: 0;
}

body[data-terminal-shell] .signal-uplink--terminal .node-label {
  left: calc(100% + 1rem);
  right: auto;
  border-color: #333;
  color: var(--text-soft);
  background: rgba(10, 10, 10, 0.94);
  font-family: inherit;
  opacity: 0;
  transform: translate(-8px, -50%);
  transition: opacity 120ms ease, transform 120ms ease;
}

body[data-terminal-shell] .signal-uplink--terminal .social-node:hover .node-label,
body[data-terminal-shell] .signal-uplink--terminal .social-node:focus-visible .node-label {
  opacity: 1;
  transform: translate(0, -50%);
}

body[data-terminal-shell] .signal-uplink--terminal .social-node::after {
  left: 50%;
  right: auto;
  top: 50%;
  bottom: auto;
  transform: translateY(-50%);
}

@keyframes uplink-idle-terminal {
  0%,
  100% {
    box-shadow: 0 0 0 rgba(57, 255, 20, 0);
  }

  50% {
    box-shadow: 0 0 10px rgba(57, 255, 20, 0.14);
  }
}

@media (max-width: 720px) {
  body[data-terminal-shell] .signal-uplink--terminal {
    display: none !important;
  }
}

body[data-page="home"]::before {
  opacity: 0.22;
}

body[data-page="home"] h1,
body[data-page="home"] h2,
body[data-page="home"] h3 {
  font-family: inherit;
  text-transform: none;
  letter-spacing: 0;
}

body[data-page="home"] .site-header {
  border-bottom-color: #333;
  background: #0a0a0a;
}

body[data-page="home"] .brand-logo {
  filter: grayscale(1) brightness(1.15);
}

body[data-page="home"] .brand-logo--animated {
  filter: none;
  color: #f7f7f7;
}

body[data-page="home"] .nav-link,
body[data-page="home"] .button {
  border-radius: 0;
  text-transform: lowercase;
  letter-spacing: 0;
  font-size: 0.8rem;
}

body[data-page="home"] .system-hero {
  min-height: auto;
  padding: 1.25rem 0 0.5rem;
}

body[data-page="home"] .system-module {
  margin-top: 0;
  padding: 1.25rem 0;
  border-top: 1px solid #1a1a1a;
}

body[data-page="home"] .system-module::before {
  display: none;
}

.cmd-session {
  max-width: 52rem;
  line-height: 1.5;
}

.cmd-banner {
  margin: 0 0 1rem;
  color: #999;
  font-size: 0.85rem;
}

.cmd-line {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem;
  margin: 0.65rem 0 0;
}

.cmd-prompt {
  color: #ccc;
  white-space: nowrap;
  flex-shrink: 0;
}

.cmd-input {
  color: #ccc;
}

.cmd-out {
  margin: 0.2rem 0 0;
  padding-left: 0;
  color: #ccc;
}

.cmd-out-block {
  margin-bottom: 0.35rem;
  max-width: 48ch;
}

.cmd-path {
  color: var(--accent-primary);
  margin-bottom: 0.15rem;
}

.cmd-art {
  margin: 0.75rem 0 0.25rem;
}

.cmd-art .logo-hero {
  display: block;
  width: min(420px, 88vw);
  height: auto;
  filter: grayscale(1) contrast(1.08);
  opacity: 0.92;
}

.cmd-dir {
  margin: 0.15rem 0 0.5rem;
  padding: 0;
  list-style: none;
}

.cmd-dir li {
  padding: 0.12rem 0;
}

.cmd-dir a,
.cmd-link {
  display: inline-flex;
  align-items: baseline;
  gap: 0;
  color: #ccc;
  text-decoration: none;
  font-family: inherit;
}

.cmd-dir a:hover,
.cmd-dir a:focus-visible,
.cmd-link:hover,
.cmd-link:focus-visible {
  color: var(--accent-primary);
  text-shadow: none;
}

.cmd-name {
  color: var(--accent-primary);
}

.cmd-ext {
  color: #999;
}

.cmd-sysinfo {
  display: grid;
  gap: 0.15rem;
  margin: 0.2rem 0 0.75rem;
}

.cmd-sysinfo div {
  display: grid;
  grid-template-columns: 9rem 1fr;
  gap: 0.5rem;
}

.cmd-sysinfo dt,
.cmd-sysinfo dd {
  margin: 0;
  font-size: inherit;
}

.cmd-sysinfo dt {
  color: #999;
}

.cmd-sysinfo dt::after {
  content: " ..........";
  color: #333;
  letter-spacing: 0.08em;
}

.cmd-sysinfo dd {
  color: #ccc;
}

.cmd-entries {
  display: grid;
  gap: 0;
  margin: 0.15rem 0 0.5rem;
}

.cmd-entry {
  display: grid;
  grid-template-columns: 1rem 2.2rem 11rem 1fr;
  gap: 0.35rem 0.5rem;
  align-items: baseline;
  width: 100%;
  margin: 0;
  padding: 0.2rem 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: #ccc;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
}

.cmd-entry-mark {
  color: var(--accent-primary);
}

.cmd-entry .node-id {
  color: #666;
}

.cmd-entry strong {
  margin: 0;
  font-weight: 400;
  color: #ccc;
  text-transform: none;
}

.cmd-entry em {
  margin: 0;
  color: #777;
  font-style: normal;
  font-size: 0.92em;
}

.cmd-entry:hover strong,
.cmd-entry.is-active strong {
  color: var(--accent-primary);
}

.cmd-entry.is-active em {
  color: #999;
}

.cmd-out-label {
  display: block;
  margin-bottom: 0.35rem;
  color: #666;
  font-size: 0.85em;
}

.kernel-output.cmd-out strong {
  display: block;
  color: var(--accent-primary);
  font-weight: 400;
  margin-bottom: 0.25rem;
}

.kernel-output.cmd-out p {
  margin: 0;
  color: #aaa;
}

.cmd-list {
  margin: 0.15rem 0 0.75rem;
  padding: 0;
  list-style: none;
}

.cmd-list li {
  display: grid;
  grid-template-columns: 10rem 1fr;
  gap: 0.75rem;
  padding: 0.15rem 0;
  border: none;
}

.cmd-list-key {
  color: var(--accent-primary);
}

.cmd-list-val {
  color: #999;
}

.cmd-note {
  display: block;
  margin-top: 0.35rem;
  color: #666;
  font-size: 0.85em;
}

.cmd-link {
  font-size: inherit;
}

.inline-command.cmd-link {
  margin-top: 0.25rem;
}

body[data-page="home"] .release-console,
body[data-page="home"] .routing-console,
body[data-page="home"] .handshake-console,
body[data-page="home"] .terminal-form,
body[data-page="home"] .faq,
body[data-page="home"] .faq details {
  border: none;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

body[data-page="home"] .soundcloud-player {
  margin: 0.5rem 0;
}

body[data-page="home"] .soundcloud-player iframe {
  filter: grayscale(1) contrast(1.05);
  opacity: 0.9;
}

body[data-page="home"] .audio-visual {
  margin: 0.35rem 0 0.5rem;
  opacity: 0.55;
}

body[data-page="home"] .faq details {
  border-bottom: 1px solid #1a1a1a;
  padding: 0.55rem 0;
}

body[data-page="home"] .faq summary {
  color: #ccc;
  font-weight: 400;
  font-size: inherit;
  list-style: none;
}

body[data-page="home"] .faq summary::-webkit-details-marker {
  display: none;
}

body[data-page="home"] .faq summary::before {
  content: "? ";
  color: #666;
}

body[data-page="home"] .faq details[open] summary {
  color: var(--accent-primary);
}

body[data-page="home"] .faq p {
  margin-top: 0.35rem;
  padding-left: 1.25rem;
  color: #999;
  font-size: 0.92em;
}

.cmd-form {
  margin-top: 0.35rem;
}

.cmd-form-line {
  margin-top: 0.25rem;
}

.cmd-input-field {
  flex: 1;
  min-width: 12rem;
  border: none;
  border-bottom: 1px solid #333;
  border-radius: 0;
  background: transparent;
  padding: 0.15rem 0;
  color: #ccc;
  font-family: inherit;
  font-size: inherit;
}

.cmd-input-field:focus {
  outline: none;
  border-bottom-color: var(--accent-primary);
  box-shadow: none;
}

.cmd-input-field::placeholder {
  color: #555;
}

.cmd-submit {
  margin-top: 0.65rem;
  padding: 0.35rem 0.75rem;
  font-size: 0.85rem;
}

.cmd-idle {
  margin-top: 0.75rem;
}

.cmd-cursor {
  display: inline-block;
  width: 0.55em;
  height: 1em;
  margin-left: 1px;
  background: #ccc;
  vertical-align: text-bottom;
  animation: cmd-blink 1s step-end infinite;
}

@keyframes cmd-blink {
  50% {
    opacity: 0;
  }
}

body[data-page="home"] .helper-text,
body[data-page="home"] .status-note {
  color: #666;
  font-size: 0.85em;
}

body[data-page="home"] .split-console {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 2rem;
  align-items: start;
}

body[data-page="home"] .handshake-console {
  display: block;
}

body[data-page="home"] .site-footer {
  border-top: 1px solid #1a1a1a;
  margin-top: 1rem;
}

@media (max-width: 720px) {
  .cmd-entry {
    grid-template-columns: 1rem 2rem 1fr;
  }

  .cmd-entry em {
    grid-column: 2 / -1;
    padding-left: 2.35rem;
  }

  .cmd-sysinfo div {
    grid-template-columns: 1fr;
    gap: 0.1rem;
  }

  .cmd-sysinfo dt::after {
    content: none;
  }

  .cmd-list li {
    grid-template-columns: 1fr;
    gap: 0.1rem;
  }

  body[data-page="home"] .split-console {
    grid-template-columns: 1fr;
  }
}

/* —— Filesystem terminal shell —— */

body[data-terminal-shell] {
  font-family: Consolas, "Courier New", var(--font-mono);
  font-size: 0.9rem;
  background: #0a0a0a;
  color: var(--text);
  overflow: hidden;
  height: 100dvh;
  padding-left: env(safe-area-inset-left);
  padding-right: env(safe-area-inset-right);
  --term-tree-line: rgba(255, 255, 255, 0.2);
  --glow-secondary: rgba(107, 140, 255, 0.28);
}

body[data-terminal-shell]::before {
  display: none;
}

body[data-terminal-shell] .site-header--terminal {
  border-bottom: 1px solid #222;
  background: #0a0a0a;
}

body[data-terminal-shell] .site-header--terminal .header-inner {
  min-height: 52px;
  justify-content: space-between;
}

body[data-terminal-shell] .brand-logo {
  width: min(180px, 46vw);
  filter: grayscale(1) brightness(1.1);
}

body[data-terminal-shell] .brand-sub {
  display: none;
}

body[data-terminal-shell] .terminal-path-readout {
  margin: 0;
  color: #666;
  font-family: inherit;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  flex-shrink: 0;
}

body.showcase-landing {
  --showcase-gutter-x: 2%;
}

body.showcase-landing .site-header--terminal .header-inner {
  width: 100%;
  max-width: none;
  margin: 0;
  min-height: 38px;
  padding: 0.2rem var(--showcase-gutter-x) 0.22rem;
  padding-right: clamp(0.65rem, 2vw, 1.25rem);
  gap: 0.35rem;
}

body.showcase-landing .site-header--terminal .brand-logo {
  width: min(148px, 40vw);
}

body.showcase-landing .terminal-app .os-taskbar {
  display: none;
}

.header-leading {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
  min-width: 0;
}

.header-sc-os {
  font-family: inherit;
  font-size: 0.62rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-primary);
  background: rgba(57, 255, 20, 0.06);
  border: 1px solid var(--border-accent);
  border-radius: 2px;
  padding: 0.24rem 0.5rem;
  cursor: pointer;
  white-space: nowrap;
}

.header-sc-os:hover {
  background: rgba(57, 255, 20, 0.12);
}

.header-trailing {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  flex-shrink: 0;
  min-width: 0;
}

.header-tagline {
  flex: 1;
  margin: 0;
  padding: 0 0.5rem;
  text-align: center;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-trailing {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem;
  flex-shrink: 0;
  min-width: 0;
}

.header-classic-links {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: lowercase;
}

.header-classic-links a {
  color: var(--text-soft);
  text-decoration: none;
}

.header-classic-links a:hover {
  color: var(--text);
}

.header-classic-sep {
  color: #444;
  user-select: none;
}

body.showcase-landing .terminal-path-readout {
  display: none;
}

.terminal-app-main {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  padding: 0;
  margin: 0;
  overflow: hidden;
}

.terminal-app {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: 0;
  outline: none;
}

.os-workspace {
  position: relative;
  flex: 1;
  min-height: 0;
  overflow: hidden;
  background: #050505;
  border-bottom: 1px solid #1a1a1a;
}

.os-desktop {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.ascii-logo-source {
  display: none;
}

.os-ascii-logo {
  margin: 0;
  padding: 0;
  font-size: var(--ascii-char-w, 7px);
  line-height: 1;
  letter-spacing: 0;
  font-family: Consolas, "Courier New", monospace;
  white-space: pre;
  text-align: left;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
}

.os-stacked-wave-logo {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(42vw, 34rem);
  max-width: calc(100% - 4rem);
  color: #f7f7f7;
  line-height: 0;
  opacity: 0.82;
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.os-stacked-wave-logo svg {
  display: block;
  width: 100%;
  height: auto;
}

.stacked-square-wave-ascii-row {
  fill: currentColor;
  font-family: VCR_OSD, var(--font-mono);
  font-size: 24px;
  font-weight: 400;
  letter-spacing: 1.5px;
}

.stacked-square-wave-ascii-cursor {
  fill: currentColor;
  font-family: VCR_OSD, var(--font-mono);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: 0;
  white-space: pre;
}

.os-ascii-logo .ascii-hi {
  color: var(--accent-primary);
  text-shadow: 0 0 8px rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.45);
}

.os-ascii-logo .ascii-mid {
  color: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.72);
}

.os-ascii-logo .ascii-dim {
  color: #444;
}

.os-landing-tag {
  margin: 0 0 0.5rem;
  color: var(--accent-primary);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.85;
}

.terminal-app.showcase-active .os-landing-tag {
  display: none;
}

.terminal-app:not(.showcase-active) .os-landing-tag {
  display: none;
}

.os-desktop-hint {
  margin: 0.75rem 0 0;
  color: #444;
  font-size: 0.72rem;
  text-align: center;
  max-width: 22rem;
  line-height: 1.45;
}

.os-desktop-hint--touch {
  display: none;
}

.os-windows {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.os-windows--showcase {
  overflow: hidden;
}

.os-windows--showcase .os-window--showcase {
  position: absolute;
}

.showcase-active .os-window--showcase[data-showcase-kind="info"] .os-window-body {
  padding: 0.28rem 0.4rem 0.32rem;
  overflow: visible;
}

.fs-epk-carousel {
  border: 1px solid #333;
  background: rgba(0, 0, 0, 0.35);
}

.fs-info-panel {
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
}

.fs-info-summary {
  margin: 0;
  padding: 0 0.05rem;
}

.fs-epk-carousel__head {
  margin: 0;
  padding: 0.36rem 0.48rem 0.28rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
  border-bottom: 1px solid #222;
  background: rgba(0, 0, 0, 0.28);
}

.fs-epk-carousel__stage {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 0.22rem;
  padding: 0.32rem 0.38rem;
}

.fs-epk-carousel__nav {
  flex-shrink: 0;
  padding: 0.18rem 0.32rem;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.45);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.95rem;
  line-height: 1;
  cursor: pointer;
}

.fs-epk-carousel__nav:hover {
  color: var(--accent-primary);
  border-color: var(--border-accent);
}

.fs-epk-carousel__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.16rem;
  min-width: 0;
  text-align: center;
}

.fs-epk-carousel__thumb {
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 4.25rem;
}

.fs-epk-carousel__thumb img {
  display: block;
  max-height: 4.25rem;
  max-width: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
}

.fs-epk-carousel__name {
  font-size: 0.66rem;
  color: var(--text);
  line-height: 1.25;
}

.fs-epk-carousel__note {
  font-size: 0.58rem;
  color: var(--text-soft);
  letter-spacing: 0.03em;
}

.fs-epk-carousel__link {
  font-size: 0.6rem;
  color: var(--accent-primary);
  text-decoration: none;
  text-transform: lowercase;
  letter-spacing: 0.04em;
}

.fs-epk-carousel__link:hover {
  text-decoration: underline;
}

.fs-epk-carousel__meta {
  margin: 0;
  padding: 0 0.48rem 0.34rem;
  font-size: 0.56rem;
  color: var(--text-soft);
  text-align: center;
  letter-spacing: 0.03em;
}

.terminal-app.showcase-compact .fs-viz.audio-visual--terminal {
  height: 56px;
  margin: 0.12rem 0 0;
}

.terminal-app.showcase-compact .fs-book-panel__hint {
  padding-bottom: 0.06rem;
  font-size: 0.6rem;
}

.terminal-app.showcase-compact .fs-book-panel .lo-form.fs-form {
  gap: 0.28rem;
  padding: 0.22rem 0.5rem 0.34rem;
}

.terminal-app.showcase-compact .fs-book-panel .lo-form textarea {
  min-height: 2.15rem;
}

.terminal-app.showcase-compact .fs-book-panel .lo-form input:not([type="submit"]):not([type="button"]),
.terminal-app.showcase-compact .fs-book-panel .lo-form textarea {
  padding: 0.34rem 0.46rem;
  min-height: 1.85rem;
}

.terminal-app.showcase-compact .os-window--play .os-window-body,
.terminal-app.showcase-compact .os-window--form .os-window-body {
  padding-top: 0.28rem;
  padding-bottom: 0.32rem;
}

.showcase-active .os-window--showcase[data-showcase-kind="info"] .fs-pre {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.3;
  color: var(--text-muted);
}

.showcase-active .os-window--showcase[data-showcase-kind="platforms"] .os-window-body {
  padding: 0.35rem 0.45rem 0.4rem;
  overflow: auto;
}

.fs-platforms__head {
  margin: 0 0 0.45rem;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.fs-platforms__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.28rem;
}

.fs-platforms__item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.28rem 0.35rem;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.68rem;
  line-height: 1.25;
}

.fs-platforms__name {
  color: var(--text);
  min-width: 0;
}

.fs-platforms__link {
  color: var(--accent-primary);
  text-decoration: none;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  flex-shrink: 0;
}

.fs-platforms__link:hover {
  text-decoration: underline;
}

.fs-platforms__pill {
  color: var(--text-muted);
  font-size: 0.6rem;
  letter-spacing: 0.05em;
  text-transform: lowercase;
  flex-shrink: 0;
}

.fs-inbox-map,
.fs-epk-assets {
  border: 1px solid #333;
  background: rgba(0, 0, 0, 0.35);
}

.fs-inbox-map__head,
.fs-epk-assets__head {
  margin: 0;
  padding: 0.42rem 0.55rem 0.34rem;
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-soft);
  border-bottom: 1px solid #222;
  background: rgba(0, 0, 0, 0.28);
}

.fs-inbox-map__list,
.fs-epk-assets__list {
  list-style: none;
  margin: 0;
  padding: 0.35rem 0.55rem 0.42rem;
  display: grid;
  gap: 0.28rem;
}

.fs-inbox-map__item,
.fs-epk-assets__item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.45rem;
  padding: 0.3rem 0.38rem;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.68rem;
  line-height: 1.3;
}

.fs-inbox-map__main {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
}

.fs-epk-assets__main {
  display: flex;
  flex-direction: column;
  gap: 0.12rem;
  min-width: 0;
  flex: 1;
}

.fs-inbox-map__role,
.fs-epk-assets__name {
  color: var(--text);
}

.fs-inbox-map__note,
.fs-epk-assets__note {
  color: var(--text-soft);
  font-size: 0.6rem;
  letter-spacing: 0.03em;
}

.fs-inbox-map__link,
.fs-epk-assets__link {
  color: var(--accent-primary);
  text-decoration: none;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  text-align: right;
  word-break: break-all;
}

.fs-inbox-map__link:hover,
.fs-epk-assets__link:hover {
  text-decoration: underline;
}

.fs-inbox-map__sla {
  margin: 0;
  padding: 0 0.55rem 0.42rem;
  font-size: 0.6rem;
  color: var(--text-soft);
  letter-spacing: 0.03em;
}

.fs-book-expand {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-expand {
  margin: 0.35rem 0.55rem 0.45rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-inbox-map {
  border-color: rgba(57, 255, 20, 0.14);
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel {
  margin: 0;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-epk-assets {
  margin: 0.35rem 0.55rem 0.45rem;
  border-color: rgba(57, 255, 20, 0.14);
}

.showcase-active .os-window--showcase.os-window--image {
  display: block;
  overflow: visible;
  height: auto;
  max-height: none;
}

.showcase-active .os-window--showcase.os-window--image .os-window-body {
  padding: 0.35rem;
  overflow: visible;
  display: block;
  flex: none;
}

.showcase-active .os-window--showcase.os-window--image .fs-image {
  width: 100%;
}

.showcase-active .os-window--showcase.os-window--image .fs-image img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: var(--showcase-photo-max, min(36vh, 13rem));
  height: auto;
  margin: 0 auto;
  object-fit: contain;
}

.terminal-app.showcase-console-hidden .terminal-chrome {
  display: none;
}

.os-taskbar-now-playing {
  flex: 1;
  min-width: 0;
  padding: 0 0.35rem;
  text-align: center;
  font-size: 0.62rem;
  letter-spacing: 0.04em;
  color: var(--accent-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}

.os-taskbar-now-playing:hover {
  filter: brightness(1.1);
}

.terminal-app.showcase-flow .os-task-items {
  display: none;
}

.os-taskbar-hint {
  flex: 1;
  min-width: 0;
  padding: 0 0.35rem;
  color: var(--text-soft);
  font-size: 0.62rem;
  letter-spacing: 0.03em;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.terminal-app.showcase-console-hidden .os-taskbar {
  border-top-color: #1a1a1a;
}

.terminal-app.showcase-mobile .os-workspace {
  display: flex;
  flex-direction: column;
}

.terminal-app.showcase-mobile .os-windows {
  position: relative;
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.os-windows--showcase-mobile {
  overflow: hidden;
  padding: 0;
}

.os-showcase-tabs {
  position: relative;
  z-index: 4;
  display: flex;
  gap: 0.3rem;
  padding: 0.35rem 0.4rem 0;
  pointer-events: auto;
  flex-shrink: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.os-showcase-tabs::-webkit-scrollbar {
  display: none;
}

.os-showcase-tab {
  flex: 1 0 auto;
  min-width: 3rem;
  min-height: 2rem;
  padding: 0.35rem 0.25rem;
  border: 1px solid var(--border-dim);
  background: #0a0a0a;
  color: var(--text-soft);
  font-family: inherit;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  cursor: pointer;
}

.os-showcase-tab.is-active {
  border-color: var(--border-accent);
  color: var(--accent-primary);
}

.os-windows--showcase-mobile .os-window--showcase {
  position: relative;
  top: auto !important;
  left: 0.4rem !important;
  right: 0.4rem !important;
  bottom: auto !important;
  width: auto !important;
  max-height: none !important;
  transform: none !important;
  flex: 1;
  min-height: 0;
  margin: 0.35rem 0.4rem 0.4rem;
}

.os-windows--showcase-mobile .os-window--showcase:not(.is-active) {
  display: none !important;
}

.os-windows--showcase-mobile .os-window--showcase.is-active {
  display: flex;
}

.os-windows--showcase-mobile .os-window-body {
  flex: 1;
  min-height: 0;
}

.showcase-mobile .os-desktop {
  display: none;
}

.showcase-mobile .os-tour {
  top: 2.6rem;
  right: 0.4rem;
  bottom: auto;
  width: min(14rem, 72vw);
}

.os-windows--showcase .os-window--showcase .os-window-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
}

.showcase-active .fs-play-blurb,
.showcase-active .fs-play-link {
  display: none;
}

.showcase-active .fs-viz.audio-visual--terminal {
  height: 72px;
  margin: 0.2rem 0 0;
}

.showcase-active .os-window--play .os-window-body {
  padding: 0.4rem 0.5rem 0.45rem;
}

.fs-play-stack {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: 0.15rem;
  border: 1px solid #333;
  background: rgba(0, 0, 0, 0.35);
}

.fs-play-stack--catalog .fs-catalog__head--now {
  border-bottom: 1px solid #222;
}

.fs-play-stack--catalog .fs-catalog--more {
  border-top: 1px solid #2a2a2a;
}

.fs-catalog__head--now {
  color: var(--accent-primary);
}

.fs-catalog__empty {
  margin: 0;
  padding: 0.55rem 0.6rem 0.65rem;
  font-size: 0.68rem;
  color: var(--text-soft);
}

.fs-catalog__head {
  margin: 0;
  padding: 0.45rem 0.55rem 0.35rem;
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-soft);
  border-bottom: 1px solid #222;
  background: rgba(0, 0, 0, 0.28);
}

.fs-catalog__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.fs-catalog__pick {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.48rem 0.55rem;
  border: 0;
  border-bottom: 1px solid #1e1e1e;
  background: transparent;
  color: var(--text-soft);
  font-family: inherit;
  font-size: 0.76rem;
  text-align: left;
  cursor: pointer;
  transition: background 140ms ease, color 140ms ease;
}

.fs-catalog__item:last-child .fs-catalog__pick {
  border-bottom: 0;
}

.fs-catalog__pick:hover {
  background: rgba(57, 255, 20, 0.05);
  color: var(--text);
}

.fs-catalog__item.is-active .fs-catalog__pick {
  color: var(--accent-primary);
  background: rgba(57, 255, 20, 0.08);
  box-shadow: inset 2px 0 0 var(--accent-primary);
}

.fs-catalog__index {
  flex: 0 0 auto;
  min-width: 1.35rem;
  color: var(--text-soft);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
}

.fs-catalog__item.is-active .fs-catalog__index {
  color: var(--accent-primary);
}

.fs-catalog__name {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fs-catalog__now {
  flex: 0 0 auto;
  font-size: 0.56rem;
  letter-spacing: 0.1em;
  text-transform: lowercase;
  color: var(--accent-primary);
  opacity: 0.85;
}

.terminal-app.showcase-expanded .fs-play-blurb,
.terminal-app.showcase-expanded .fs-play-link {
  display: block !important;
  margin: 0.45rem 0.55rem 0;
  font-size: 0.72rem;
  line-height: 1.4;
  color: var(--text-soft);
}

.terminal-app.showcase-expanded .fs-play-stack {
  margin: 0.35rem 0.55rem 0.45rem;
  border-color: #333;
  background: rgba(0, 0, 0, 0.35);
}

.terminal-app.showcase-expanded .os-window--catalog.is-showcase-expanded .os-window-body {
  overflow: auto;
  padding: 0.15rem 0.05rem 0.35rem;
}

.showcase-active .os-window--text .os-window-body {
  padding: 0.32rem 0.45rem 0.38rem;
}

.showcase-active:not(.showcase-flow) .os-window--text .os-window-body,
.showcase-active:not(.showcase-flow) .os-window--showcase[data-showcase-kind="info"] .os-window-body,
.showcase-active:not(.showcase-flow) .os-window--showcase[data-showcase-kind="platforms"] .os-window-body,
.showcase-active:not(.showcase-flow) .os-window--form .os-window-body {
  overflow: auto;
}

.showcase-active .os-window--text .fs-text {
  font-size: 0.73rem;
  line-height: 1.34;
  letter-spacing: 0;
}

.showcase-active .os-window--text .fs-para {
  margin: 0;
  max-width: none;
}

.showcase-active .os-window--text .fs-pre {
  margin: 0;
  font-size: 0.7rem;
  line-height: 1.32;
}

.showcase-active .os-window--text .fs-scroll-hint {
  display: block;
  font-size: 0.58rem;
  color: var(--text-soft);
  margin: 0.2rem 0 0;
}

.terminal-app.showcase-mobile .os-window--text .os-window-body,
.terminal-app.showcase-mobile .os-window--form .os-window-body {
  overflow: auto;
}

.terminal-app.showcase-mobile .os-window--text .fs-text {
  font-size: 0.76rem;
  line-height: 1.38;
}

.terminal-app.showcase-mobile .fs-viz.audio-visual--terminal {
  height: 80px;
}

.showcase-active .os-window--form .os-window-body {
  padding: 0.35rem 0.45rem 0.45rem;
  font-size: 0.78rem;
  overflow: auto;
}

.fs-book-panel {
  border: 1px solid #333;
  background: rgba(0, 0, 0, 0.35);
}

.fs-book-panel__hint {
  margin: 0;
  padding: 0.38rem 0.55rem 0.12rem;
  font-size: 0.64rem;
  line-height: 1.35;
  color: var(--text-soft);
}

.fs-book-panel .lo-form.fs-form {
  padding: 0.28rem 0.55rem 0.42rem;
  gap: 0.38rem;
  margin: 0;
}

.fs-book-panel .lo-field {
  width: 100%;
  max-width: none;
}

.fs-book-panel .lo-mirror {
  font-size: 0.74rem;
  padding: 0.42rem 0.52rem;
  line-height: 1.35;
}

.fs-book-panel .lo-form input:not([type="submit"]):not([type="button"]),
.fs-book-panel .lo-form textarea {
  display: block;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  box-sizing: border-box;
  font-size: 0.74rem;
  padding: 0.42rem 0.52rem;
  line-height: 1.35;
  min-height: 2rem;
  color: var(--text);
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid #333;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.fs-book-panel .lo-form input:not([type="submit"]):not([type="button"]):focus,
.fs-book-panel .lo-form textarea:focus {
  border-color: var(--border-accent);
  box-shadow: 0 0 0 1px rgba(57, 255, 20, 0.14);
  caret-color: var(--accent-primary);
  outline: none;
}

.fs-book-panel .lo-form input::placeholder,
.fs-book-panel .lo-form textarea::placeholder {
  font-size: 0.74rem;
  font-family: inherit;
  color: var(--text-soft);
  letter-spacing: 0.04em;
}

.fs-book-panel .lo-form textarea {
  min-height: 2.65rem;
  max-height: 5rem;
  resize: vertical;
}

.fs-book-panel .lo-form button[type="submit"] {
  width: 100%;
  margin: 0.12rem 0 0;
  padding: 0.42rem 0.55rem;
  border: 1px solid #333;
  background: rgba(5, 5, 5, 0.92);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: lowercase;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease, box-shadow 140ms ease;
}

.fs-book-panel .lo-form button[type="submit"]:hover {
  color: var(--accent-primary);
  border-color: var(--border-accent);
  box-shadow: 0 0 12px rgba(57, 255, 20, 0.14);
  text-shadow: none;
}

.fs-book-panel .lo-form-status {
  margin: 0;
  min-height: 1rem;
  font-size: 0.64rem;
  line-height: 1.35;
  color: var(--text-soft);
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel__hint {
  font-size: 0.72rem;
  padding-bottom: 0.35rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form.fs-form {
  padding: 0.45rem 0.65rem 0.6rem;
  gap: 0.52rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form input:not([type="submit"]):not([type="button"]),
.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form textarea {
  font-size: 0.8rem;
  padding: 0.48rem 0.58rem;
  min-height: 2.15rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form textarea {
  min-height: 5.5rem;
  max-height: 11rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form button[type="submit"] {
  font-size: 0.76rem;
  padding: 0.48rem 0.6rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .fs-book-panel .lo-form-status {
  font-size: 0.68rem;
}

.showcase-active .os-window--form[data-showcase-slot="2"] .os-window-body {
  overflow: auto;
}

@keyframes os-window-enter {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.os-window--enter {
  animation: os-window-enter 0.44s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--win-enter, 0) * 95ms);
}

@media (prefers-reduced-motion: reduce) {
  .os-window--enter {
    animation: none;
  }
}

.terminal-app.showcase-active .os-workspace {
  background: #050505;
}

.terminal-app.showcase-active .os-workspace::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    var(--scanline) 2px,
    var(--scanline) 4px
  );
  opacity: 0.28;
}

.terminal-app.showcase-active .os-desktop {
  justify-content: center;
  padding-top: 0;
}

.terminal-app.showcase-active .os-desktop-hint,
.terminal-app.showcase-active .os-desktop-shortcut {
  display: none;
}

.terminal-app.showcase-active .os-ascii-logo,
.terminal-app.showcase-active .os-stacked-wave-logo {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  opacity: 0.72;
}

.sc-icon-anim-host {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
  pointer-events: none;
}

.sc-icon-anim {
  position: relative;
  width: min(22vh, 9.5rem);
  aspect-ratio: 1;
  opacity: 0.82;
  filter: drop-shadow(0 0 18px rgba(57, 255, 20, 0.22));
  --beat-t: 0;
  --snap: 0;
}

.sc-icon-anim__layer {
  position: absolute;
  inset: 0;
  background: url("../brand/sc-mark-green.png") center / contain no-repeat;
  will-change: transform, opacity, filter;
}

/* Upper + lower stems = "!" */
.sc-icon-anim__layer--stem-up {
  clip-path: polygon(41% 4%, 56% 4%, 56% 52%, 41% 52%);
  transform-origin: 50% 8%;
}

.sc-icon-anim__layer--stem-down {
  clip-path: polygon(43% 72%, 55% 72%, 56% 96%, 42% 96%);
  transform-origin: 50% 96%;
  opacity: 0;
  transform: translateY(-22%) scale(0.15);
}

/* Cross — split at center so each beat snaps one direction */
.sc-icon-anim__layer--arm-left {
  clip-path: polygon(5% 46%, 50% 50%, 50% 58%, 36% 70%, 22% 76%, 14% 64%, 8% 54%);
  transform-origin: 100% 56%;
  opacity: 0;
  transform: scaleX(0.04);
}

.sc-icon-anim__layer--arm-right {
  clip-path: polygon(50% 50%, 93% 46%, 96% 72%, 50% 76%);
  transform-origin: 0% 58%;
  opacity: 0;
  transform: scaleX(0.04);
}

/* Beat 1 — upper stem draws down */
.sc-icon-anim[data-frame="0"] .sc-icon-anim__layer--stem-up {
  opacity: calc(0.35 + 0.65 * var(--beat-t));
  transform: scaleY(calc(0.12 + 0.88 * var(--beat-t)));
}

.sc-icon-anim[data-frame="0"] .sc-icon-anim__layer--stem-down {
  opacity: 0;
  transform: translateY(-22%) scale(0.1);
}

/* Beat 2 — dot slams in, full ! flashes */
.sc-icon-anim[data-frame="1"] .sc-icon-anim__layer--stem-up {
  opacity: 1;
  transform: scaleY(1);
  filter: drop-shadow(
    0 0 calc(6px + 16px * min(1, var(--beat-t) * 2.5)) rgba(57, 255, 20, 0.55)
  );
}

.sc-icon-anim[data-frame="1"] .sc-icon-anim__layer--stem-down {
  opacity: clamp(0, calc((var(--beat-t) - 0.04) / 0.22), 1);
  transform: translateY(calc((1 - min(1, var(--beat-t) / 0.28)) * -28%))
    scale(calc(0.2 + 0.8 * min(1, var(--beat-t) / 0.28)));
  filter: drop-shadow(
    0 0 calc(10px * min(1, var(--beat-t) / 0.28)) rgba(57, 255, 20, 0.65)
  );
}

.sc-icon-anim[data-frame="1"] {
  filter: drop-shadow(
    0 0 calc(12px + 14px * min(1, var(--beat-t) * 1.8)) rgba(57, 255, 20, 0.28)
  );
}

/* Beat 3 — left arm + hook whip out from center */
.sc-icon-anim[data-frame="2"] {
  --snap: min(1, var(--beat-t) / 0.34);
}

.sc-icon-anim[data-frame="2"] .sc-icon-anim__layer--stem-up,
.sc-icon-anim[data-frame="2"] .sc-icon-anim__layer--stem-down {
  opacity: 1;
  transform: scale(calc(1 - 0.035 * var(--snap)));
  filter: drop-shadow(0 0 calc(4px * var(--snap)) rgba(57, 255, 20, 0.35));
}

.sc-icon-anim[data-frame="2"] .sc-icon-anim__layer--arm-left {
  opacity: clamp(0, calc((var(--snap) - 0.06) / 0.2), 1);
  transform: scaleX(calc(0.04 + 0.96 * var(--snap)));
  filter: drop-shadow(0 0 calc(12px * var(--snap)) rgba(57, 255, 20, 0.5));
}

/* Beat 4 — right arm completes cross, mark locks */
.sc-icon-anim[data-frame="3"] {
  --snap: min(1, var(--beat-t) / 0.34);
}

.sc-icon-anim[data-frame="3"] .sc-icon-anim__layer--stem-up,
.sc-icon-anim[data-frame="3"] .sc-icon-anim__layer--stem-down {
  opacity: 1;
  transform: none;
  filter: none;
}

.sc-icon-anim[data-frame="3"] .sc-icon-anim__layer--arm-left {
  opacity: 1;
  transform: scaleX(1);
  filter: none;
}

.sc-icon-anim[data-frame="3"] .sc-icon-anim__layer--arm-right {
  opacity: clamp(0, calc((var(--snap) - 0.06) / 0.2), 1);
  transform: scaleX(calc(0.04 + 0.96 * var(--snap)));
  filter: drop-shadow(0 0 calc(14px * var(--snap)) rgba(57, 255, 20, 0.55));
}

.sc-icon-anim[data-frame="3"] {
  filter: drop-shadow(
    0 0 calc(16px + 12px * var(--snap)) rgba(57, 255, 20, 0.34)
  );
}

.terminal-app.showcase-active .sc-icon-anim-host {
  display: block;
}

.terminal-app:not(.showcase-active) .sc-icon-anim-host {
  display: none;
}

.terminal-app.showcase-flow:not(.showcase-flow-ready) .os-windows--showcase {
  visibility: hidden;
}

.terminal-app.showcase-flow .os-window--showcase,
.terminal-app.showcase-flow .os-window--showcase:not(.os-window--image) {
  display: block;
  height: auto;
  max-height: none;
  overflow: visible;
}

.terminal-app.showcase-flow .os-window--showcase .os-window-body {
  flex: none;
  overflow: visible;
}

.terminal-app.showcase-flow .os-window--showcase.os-window--image .os-window-body {
  overflow: visible;
}

.terminal-app.showcase-flow .fs-scroll-hint {
  display: none !important;
}

.showcase-active:not(.showcase-flow) .os-window--showcase:not(.os-window--image) {
  --os-win-alpha: 0.94;
  opacity: 1;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42);
  display: flex;
  flex-direction: column;
  max-height: calc(var(--showcase-h, 40%) + 2.15rem);
  overflow: hidden;
}

.showcase-active:not(.showcase-flow) .os-window--showcase:not(.os-window--image) .os-window-titlebar {
  flex: 0 0 auto;
}

.showcase-active.showcase-flow .os-window--showcase:not(.os-window--image) {
  --os-win-alpha: 0.94;
  opacity: 1;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42);
}

.showcase-active .os-window--showcase.os-window--image {
  --os-win-alpha: 0.94;
  opacity: 1;
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.42);
}

.showcase-active .os-window--showcase:not(.is-active) {
  --os-win-alpha: 0.9;
  opacity: 1;
  border-color: var(--border);
}

.showcase-active .os-window--showcase.is-active {
  border-color: var(--border-window-active);
  box-shadow: 0 10px 36px rgba(0, 0, 0, 0.48);
}

.showcase-active .os-window--showcase .os-window-titlebar {
  background: rgba(255, 255, 255, 0.03);
  min-height: 1.4rem;
  padding: 0.1rem 0.38rem 0.1rem 0.52rem;
}

.showcase-active .os-window--showcase .os-window-title {
  font-size: 0.72rem;
}

.showcase-active .os-window--showcase .os-win-close {
  font-size: 0.95rem;
  min-width: 1.35rem;
  min-height: 1.35rem;
}

.showcase-active .os-window--showcase.is-active .os-window-titlebar {
  background: rgba(255, 255, 255, 0.05);
  border-bottom-color: var(--border);
}

.showcase-active .os-window--showcase.is-active .os-window-title {
  color: var(--accent-primary);
}

@media (hover: hover) {
  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase {
    cursor: pointer;
    transition:
      border-color 160ms ease,
      box-shadow 180ms ease,
      transform 180ms ease;
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase .os-window-titlebar {
    cursor: pointer;
    position: relative;
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase:hover {
    border-color: var(--border-window-active);
    box-shadow:
      0 0 0 1px var(--glow-window-active),
      0 14px 36px rgba(0, 0, 0, 0.46);
    transform: translateY(-3px);
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase:hover .os-window-titlebar {
    background: rgba(57, 255, 20, 0.06);
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase:hover .os-window-title {
    color: var(--accent-primary);
    text-shadow: 0 0 10px rgba(57, 255, 20, 0.22);
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase .os-window-titlebar::after {
    content: "expand";
    position: absolute;
    right: 1.55rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.56rem;
    letter-spacing: 0.12em;
    text-transform: lowercase;
    color: var(--text-soft);
    opacity: 0;
    pointer-events: none;
    transition: opacity 140ms ease, color 140ms ease;
  }

  .terminal-app.showcase-active:not(.showcase-expanded) .os-window--showcase:hover .os-window-titlebar::after {
    opacity: 0.7;
    color: var(--accent-primary);
  }
}

.terminal-app.showcase-mobile:not(.showcase-expanded) .os-window--showcase.is-active:active {
  border-color: var(--border-window-active);
  box-shadow: 0 0 0 1px var(--glow-window-active);
}

/* Showcase expand — centered detail panel over ASCII logo */
.os-showcase-expand-backdrop {
  position: absolute;
  inset: 0;
  z-index: 8;
  margin: 0;
  padding: 0;
  border: 0;
  background: rgba(5, 5, 5, 0.14);
  cursor: pointer;
  pointer-events: auto;
}

.terminal-app.showcase-expanded .os-windows {
  z-index: 16;
  pointer-events: none;
}

.terminal-app.showcase-expanded .os-desktop {
  z-index: 1;
}

.terminal-app.showcase-expanded .os-ascii-logo,
.terminal-app.showcase-expanded .os-stacked-wave-logo {
  opacity: 0.95;
}

.terminal-app.showcase-expanded .sc-icon-anim {
  opacity: 0.95;
}

.terminal-app.showcase-expanded.showcase-mobile .os-desktop {
  display: flex;
}

.terminal-app.showcase-expanded.showcase-mobile .os-windows {
  position: absolute;
  inset: 0;
  display: block;
}

.terminal-app.showcase-expanded .os-window--showcase:not(.is-showcase-expanded) {
  opacity: 0.22;
  pointer-events: none;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded {
  position: absolute;
  top: 0.6rem !important;
  bottom: 0.6rem !important;
  left: 50% !important;
  right: auto !important;
  width: min(58rem, calc(100% - 1.25rem)) !important;
  max-height: none !important;
  height: auto !important;
  transform: translateX(-50%) !important;
  z-index: 100 !important;
  --os-win-alpha: 0.75;
  background: rgba(0, 0, 0, var(--os-win-alpha));
  box-shadow:
    0 0 0 1px var(--glow-window-active),
    0 24px 64px rgba(0, 0, 0, 0.45);
  border-color: var(--border-window-active);
  display: flex !important;
  flex-direction: column;
  overflow: hidden;
  opacity: 1;
  filter: none;
  pointer-events: auto;
  animation: showcase-expand-in 200ms ease-out;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded.os-window--image {
  width: min(44rem, calc(100% - 1.25rem)) !important;
}

body[data-terminal-shell] .brand-logo--animated {
  filter: none;
  color: #f7f7f7;
}

.terminal-app:not(.showcase-expanded) .fs-platforms__item--coming-soon {
  display: none;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded.os-window--image .os-window-body {
  display: flex;
  overflow: hidden;
  padding: 0.35rem;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded.os-window--image .fs-image {
  display: flex;
  flex: 1;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded.os-window--image .fs-image img {
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  margin: 0;
  object-fit: contain;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .os-window-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  max-height: none;
  padding: 0.15rem 0.05rem 0.35rem;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded {
  width: min(36rem, calc(100% - 1.25rem)) !important;
}

.terminal-app.showcase-expanded .os-window--form.is-showcase-expanded .os-window-body {
  padding: 0.15rem 0.05rem 0.35rem;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text {
  font-size: 0.92rem;
  line-height: 1.68;
  padding: 0.2rem 0.35rem 0.45rem;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-para {
  margin: 0 0 0.95rem;
  color: rgba(232, 244, 228, 0.94);
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-prose-head {
  margin: 1.2rem 0 0.5rem;
  padding: 0;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-primary);
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-prose-head:first-child {
  margin-top: 0.15rem;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-pre {
  margin: 0.2rem 0 0.9rem;
  padding: 0.35rem 0.5rem;
  font-size: 0.8rem;
  line-height: 1.58;
  color: var(--text-soft);
  border-left: 2px solid rgba(57, 255, 20, 0.22);
  background: rgba(0, 0, 0, 0.22);
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .os-window-titlebar {
  background: rgba(0, 0, 0, 0.35);
  flex: 0 0 auto;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-scroll-hint {
  display: block !important;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text.is-streaming .fs-prose-head:last-child::after,
.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text.is-streaming .fs-para:last-child::after,
.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text.is-streaming .fs-pre:last-child::after {
  content: "▋";
  margin-left: 0.12rem;
  color: #f2f2f2;
  text-shadow:
    -1px 0 rgba(255, 36, 48, 0.7),
    1px 0 rgba(72, 124, 255, 0.75),
    0 0 7px rgba(57, 255, 20, 0.35);
  animation: fs-cursor-blink 0.72s step-end infinite;
}

@keyframes fs-cursor-blink {
  0%,
  100% {
    opacity: 1;
  }

  50% {
    opacity: 0;
  }
}

.terminal-app.showcase-expanded .os-showcase-tabs {
  opacity: 0.35;
  pointer-events: none;
}

body.showcase-panel-expanded .signal-uplink--terminal {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

@keyframes showcase-expand-in {
  from {
    opacity: 0;
    transform: translateX(-50%) scale(0.98);
  }

  to {
    opacity: 1;
    transform: translateX(-50%) scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded {
    animation: none;
  }
}

.terminal-app.has-windows .os-desktop {
  opacity: 1;
}

.os-window {
  --os-win-alpha: 0.52;
  position: absolute;
  top: calc(6% + var(--win-offset, 0) * 2.5%);
  left: calc(4% + var(--win-offset, 0) * 3%);
  width: min(92%, 34rem);
  max-height: min(72%, 26rem);
  display: flex;
  flex-direction: column;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, var(--os-win-alpha));
  pointer-events: auto;
  font-family: "Roboto Mono", Consolas, "Courier New", monospace;
  font-size: 0.85rem;
  line-height: 1.5;
}

.os-window.is-active {
  border-color: var(--border-window-active);
}

.os-window:not(.is-active) {
  --os-win-alpha: 0.38;
  border-color: var(--border-dim);
  opacity: 0.84;
}

.os-window.is-active {
  opacity: 1;
}

.os-window--max {
  top: 0.5rem !important;
  left: 0.5rem !important;
  right: 0.5rem !important;
  width: auto !important;
  max-height: min(92dvh, 44rem) !important;
}

.os-window--max .os-window-body {
  max-height: none;
}

.os-desktop-shortcut {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  width: 4.5rem;
  padding: 0.35rem 0.25rem;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.62rem;
  cursor: default;
  user-select: none;
}

.os-desktop-shortcut:hover,
.os-desktop-shortcut:focus-visible {
  border-color: var(--border-dim);
  background: rgba(0, 0, 0, 0.35);
  color: var(--accent-primary);
}

.os-desktop-shortcut__icon {
  font-size: 1.1rem;
  line-height: 1;
}

.os-tour {
  position: absolute;
  right: 0.65rem;
  bottom: 0.55rem;
  z-index: 12;
  width: min(19rem, 88vw);
  padding: 0;
  background: transparent;
  pointer-events: none;
}

.os-tour[hidden] {
  display: none;
}

.os-tour__card {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border-accent);
  background: rgba(0, 0, 0, 0.88);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  pointer-events: auto;
}

.os-tour__step {
  margin: 0 0 0.25rem;
  font-size: 0.62rem;
  color: var(--accent-primary);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.os-tour__text {
  margin: 0 0 0.65rem;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-muted);
}

.os-tour__actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.os-tour__skip,
.os-tour__next {
  padding: 0.25rem 0.55rem;
  border: 1px solid var(--border-dim);
  background: #000;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.72rem;
  cursor: pointer;
}

.os-tour__next {
  color: var(--accent-primary);
  border-color: var(--border-accent);
}

@media (max-width: 720px) {
  .os-tour {
    top: 0.35rem;
    right: 0.4rem;
    bottom: auto;
    width: min(15rem, 70vw);
  }
}

.site-footer--terminal .footer-classic-link {
  margin-left: 0.35rem;
  color: var(--text-soft);
  font-size: 0.78rem;
}

.site-footer--terminal .footer-classic-link:hover {
  color: var(--accent-secondary);
}

.os-window-titlebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-height: 1.75rem;
  padding: 0.2rem 0.45rem 0.2rem 0.65rem;
  background: rgba(0, 0, 0, 0.72);
  border-bottom: 1px solid var(--border);
  cursor: default;
  user-select: none;
}

.os-window.is-active .os-window-titlebar {
  border-bottom-color: #b4b4b4;
}

.os-window-title {
  flex: 1;
  font-size: 0.82rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.os-window.is-active .os-window-title {
  color: var(--accent-primary);
}

.os-win-close {
  flex-shrink: 0;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}

.os-win-close:hover {
  color: var(--accent-alert);
}

.os-window-body {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 0.65rem 0.85rem 0.85rem;
  background: transparent;
  scrollbar-width: none;
}

.os-window-body::-webkit-scrollbar {
  display: none;
}

.os-window--text {
  width: min(92%, 36rem);
  max-height: min(85dvh, 36rem);
}

.os-window--text .os-window-body {
  position: relative;
  padding: 0.85rem 1rem 1rem;
}

.os-window--text .fs-text {
  font-family: inherit;
  font-size: 0.88rem;
  line-height: 1.72;
  letter-spacing: 0.01em;
}

.fs-text-wrap {
  position: relative;
}

.fs-para {
  margin: 0 0 0.95rem;
  max-width: 58ch;
  color: var(--text-muted);
}

.fs-para:last-child {
  margin-bottom: 0;
}

.fs-text--prose {
  width: min(100%, 66ch);
  margin-inline: auto;
  text-align: left;
}

.fs-text--prose .fs-prose-head {
  margin: 1.35rem 0 0.48rem;
  padding: 0.65rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  line-height: 1.35;
}

.fs-text--prose .fs-prose-head:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.fs-text--prose .fs-para {
  max-width: none;
  margin: 0 0 1.05rem;
  line-height: 1.72;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text--prose {
  width: min(100%, 66ch);
  margin-inline: auto;
  padding: 0.8rem 1rem 1.35rem;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text--prose .fs-prose-head {
  margin: 1.4rem 0 0.5rem;
  padding: 0.7rem 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text--prose .fs-prose-head:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.terminal-app.showcase-expanded .os-window--showcase.is-showcase-expanded .fs-text--prose .fs-para {
  max-width: none;
  margin: 0 0 1.05rem;
  line-height: 1.72;
}

.fs-pre {
  margin: 0 0 0.95rem;
  font-family: inherit;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text-soft);
  white-space: pre-wrap;
}

.fs-pre:last-child {
  margin-bottom: 0;
}

.fs-text.is-streaming > :last-child::after {
  content: "▋";
  display: inline-block;
  margin-left: 0.08rem;
  font-family: var(--font-mono);
  color: #f2f2f2;
  text-shadow:
    -1px 0 rgba(255, 36, 48, 0.7),
    1px 0 rgba(72, 124, 255, 0.75),
    0 0 7px rgba(57, 255, 20, 0.35);
  animation: fs-type-cursor 0.72s step-end infinite;
}

@keyframes fs-type-cursor {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

.os-window--play {
  width: min(92%, 32rem);
  max-height: min(78dvh, 28rem);
}

.os-window--image {
  width: min(92%, 38rem);
  max-height: none;
  height: auto;
}

.os-window--image .os-window-body {
  flex: 0 1 auto;
  overflow: hidden;
  padding: 0.45rem 0.55rem 0.55rem;
}

.os-window--play .os-window-body {
  padding: 0.5rem 0.65rem 0.65rem;
}

.fs-player {
  position: relative;
  margin: 0;
  border: 0;
  border-top: 1px solid #2a2a2a;
  background: rgba(0, 0, 0, 0.32);
  overflow: hidden;
}

.fs-play-stack > .fs-player:first-child {
  border-top: 0;
}

.fs-player__iframe {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
  width: 100%;
  height: 166px;
  border: 0;
  opacity: 0.01;
  pointer-events: none;
}

.fs-player__chrome {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: auto auto 1fr;
  grid-template-rows: auto auto;
  gap: 0.5rem 0.7rem;
  padding: 0.6rem 0.7rem 0.65rem;
  background: rgba(0, 0, 0, 0.38);
}

.fs-player__art {
  grid-column: 1;
  grid-row: 1 / span 2;
  align-self: start;
  width: 3.5rem;
  height: 3.5rem;
  object-fit: cover;
  border: 1px solid var(--border-dim);
  background: #0a0a0a;
}

.fs-player__art[hidden] {
  display: none;
}

.fs-player__chrome:not(:has(.fs-player__art:not([hidden]))) {
  grid-template-columns: auto 1fr;
}

.fs-player__chrome:not(:has(.fs-player__art:not([hidden]))) .fs-player__toggle {
  grid-column: 1;
}

.fs-player__chrome:not(:has(.fs-player__art:not([hidden]))) .fs-player__meta,
.fs-player__chrome:not(:has(.fs-player__art:not([hidden]))) .fs-player__transport {
  grid-column: 2;
}

.fs-player__toggle {
  grid-column: 2;
  grid-row: 1;
  align-self: start;
  min-width: 3.35rem;
  padding: 0.38rem 0.5rem;
  border: 1px solid #333;
  background: rgba(5, 5, 5, 0.92);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: lowercase;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease, box-shadow 140ms ease;
}

.fs-player__toggle:disabled {
  opacity: 0.45;
  cursor: wait;
}

.fs-player__toggle:hover:not(:disabled) {
  color: var(--accent-primary);
  border-color: var(--border-accent);
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.12);
}

.fs-player.is-playing .fs-player__toggle {
  color: var(--accent-primary);
  border-color: var(--border-accent);
  box-shadow: 0 0 12px rgba(57, 255, 20, 0.16);
}

.fs-player__meta {
  grid-column: 3;
  min-width: 0;
}

.fs-player__title {
  margin: 0;
  color: var(--text);
  font-size: 0.82rem;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fs-player__user {
  margin: 0.12rem 0 0;
  color: var(--text-soft);
  font-size: 0.68rem;
  line-height: 1.3;
}

.fs-player__transport {
  grid-column: 3;
}

.fs-player__seek {
  --seek-fill: 0%;
  display: block;
  width: 100%;
  height: 0.45rem;
  margin: 0;
  padding: 0;
  cursor: pointer;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
}

.fs-player__seek:focus {
  outline: none;
}

.fs-player__seek:focus-visible::-webkit-slider-thumb {
  box-shadow: 0 0 0 2px rgba(57, 255, 20, 0.35);
}

.fs-player__seek::-webkit-slider-runnable-track {
  height: 0.28rem;
  border: 1px solid #333;
  background:
    linear-gradient(
      90deg,
      rgba(57, 255, 20, 0.82) 0%,
      rgba(57, 255, 20, 0.55) var(--seek-fill),
      rgba(255, 255, 255, 0.06) var(--seek-fill),
      rgba(255, 255, 255, 0.06) 100%
    );
}

.fs-player__seek::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 0.5rem;
  height: 0.5rem;
  margin-top: -0.14rem;
  border: 1px solid var(--accent-primary);
  border-radius: 1px;
  background: #080808;
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.28);
  transition: box-shadow 140ms ease, border-color 140ms ease;
}

.fs-player__seek:hover::-webkit-slider-thumb {
  border-color: #9dff8a;
  box-shadow: 0 0 12px rgba(57, 255, 20, 0.45);
}

.fs-player__seek::-moz-range-track {
  height: 0.28rem;
  border: 1px solid #333;
  background: rgba(255, 255, 255, 0.06);
}

.fs-player__seek::-moz-range-progress {
  height: 0.28rem;
  background: linear-gradient(90deg, rgba(57, 255, 20, 0.82), rgba(57, 255, 20, 0.55));
  border: 1px solid #333;
  border-right: 0;
}

.fs-player__seek::-moz-range-thumb {
  width: 0.5rem;
  height: 0.5rem;
  border: 1px solid var(--accent-primary);
  border-radius: 1px;
  background: #080808;
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.28);
}

.fs-player.is-playing .fs-player__seek::-webkit-slider-runnable-track {
  border-color: rgba(57, 255, 20, 0.28);
}

.fs-player.is-playing .fs-player__seek::-moz-range-track {
  border-color: rgba(57, 255, 20, 0.28);
}

.fs-player__times {
  display: flex;
  justify-content: space-between;
  margin-top: 0.28rem;
  color: var(--text-soft);
  font-size: 0.64rem;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}

.fs-player.is-playing {
  background: rgba(57, 255, 20, 0.03);
}

.fs-viz.audio-visual--terminal {
  height: 88px;
  margin: 0;
  padding: 0.35rem 0.45rem 0.4rem;
  border: 0;
  border-top: 1px solid #2a2a2a;
  border-radius: 0;
  background: rgba(0, 0, 0, 0.42);
}

.fs-play-link {
  margin: 0;
  padding: 0.4rem 0.55rem 0.5rem;
  border-top: 1px solid #222;
  font-size: 0.68rem;
}

.fs-play-link .fs-link {
  color: var(--text-soft);
}

.fs-play-link .fs-link:hover {
  color: var(--accent-primary);
}

.fs-viz.audio-visual--terminal.is-playing {
  border-color: var(--border-accent);
}

.fs-viz.audio-visual--terminal::after {
  content: none;
}

.fs-viz.audio-visual--terminal.is-playing::after {
  color: rgba(255, 255, 255, 0.78);
}

.terminal-app.showcase-expanded .fs-viz.audio-visual--terminal {
  height: 124px;
}

.fs-viz.audio-visual--terminal canvas {
  height: 100%;
}

.fs-viz--live {
  display: grid;
  place-items: center;
  min-height: 88px;
  border-top: 1px solid #2a2a2a;
  color: var(--text-soft);
  background: rgba(0, 0, 0, 0.42);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.fs-player.is-playing + .fs-viz--live {
  border-color: var(--border-accent);
  color: var(--accent-primary);
}

.os-taskbar {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2rem;
  padding: 0.2rem 0.5rem;
  background: #000;
  border-top: 1px solid #333;
}

.os-start {
  padding: 0.2rem 0.55rem;
  border: 1px solid var(--border-dim);
  background: #000;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  cursor: pointer;
}

.os-start:hover {
  color: var(--accent-primary);
  border-color: var(--border-accent);
}

.os-start-wrap {
  position: relative;
}

.os-start-menu {
  position: absolute;
  bottom: calc(100% + 0.35rem);
  left: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  min-width: 8.5rem;
  padding: 0.25rem;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.94);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55);
}

.os-start-menu[hidden] {
  display: none;
}

.os-start-pin {
  padding: 0.4rem 0.55rem;
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.72rem;
  text-align: left;
  cursor: pointer;
}

.os-start-pin:hover {
  color: var(--accent-secondary);
  background: rgba(255, 255, 255, 0.04);
}

.fs-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.15rem;
  margin: 0 0 0.45rem;
  font-size: 0.72rem;
}

.fs-crumb-seg {
  padding: 0;
  border: none;
  background: transparent;
  color: var(--text-soft);
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
}

.fs-crumb-seg:hover {
  color: var(--accent-secondary);
}

.fs-crumb-sep {
  color: var(--text-soft);
  user-select: none;
}

.fs-open-hint {
  display: none;
  margin-left: auto;
  font-size: 0.68rem;
  color: var(--accent-secondary);
  letter-spacing: 0.04em;
}

.terminal-app.is-touch .fs-item.is-selected .fs-open-hint {
  display: inline;
}

.terminal-app.is-touch .fs-item.is-selected.is-armed {
  animation: fs-tap-arm 1.1s ease-in-out infinite;
}

@keyframes fs-tap-arm {
  0%,
  100% {
    background: rgba(107, 140, 255, 0.06);
  }
  50% {
    background: rgba(107, 140, 255, 0.14);
  }
}

.os-task-items {
  display: flex;
  flex: 1;
  gap: 0.25rem;
  min-width: 0;
  overflow-x: auto;
}

.os-task-btn {
  max-width: 10rem;
  padding: 0.15rem 0.45rem;
  border: 1px solid var(--border-dim);
  background: #000;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 0.68rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  cursor: pointer;
}

.os-task-btn.is-active {
  border-color: var(--border-accent);
  color: var(--accent-primary);
}

.os-task-btn:hover {
  color: var(--accent-secondary);
}

.os-task-btn.is-minimized {
  opacity: 0.55;
}

.os-clock {
  flex-shrink: 0;
  color: #666;
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
}

.terminal-chrome {
  flex-shrink: 0;
  padding: 0.35rem 0.75rem calc(0.5rem + env(safe-area-inset-bottom));
  border-top: 1px solid #1a1a1a;
  max-width: 52rem;
  width: 100%;
  margin: 0 auto;
  cursor: text;
}

.terminal-input-row {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
  min-height: 1.4em;
  position: relative;
}

.terminal-typed {
  color: var(--text);
  word-break: break-all;
}

.terminal-status {
  margin: 0.2rem 0 0;
  color: var(--text-soft);
  font-size: 0.75rem;
}

.site-footer--terminal {
  flex-shrink: 0;
  border-top: 1px solid #1a1a1a;
  padding: 0.32rem 0 calc(0.32rem + env(safe-area-inset-bottom));
  margin: 0;
}

.site-footer-copy {
  margin: 0;
  text-align: center;
  color: #555;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}

body.showcase-landing .site-footer--terminal {
  padding: 0.22rem 0 calc(0.22rem + env(safe-area-inset-bottom));
}

body.showcase-landing .site-footer-copy {
  font-size: 0.58rem;
  letter-spacing: 0.1em;
}

.site-footer--terminal .helper-text {
  margin: 0;
  text-align: center;
  color: #555;
  font-size: 0.72rem;
}

.site-footer--terminal a {
  color: #888;
}

.fs-banner,
.fs-line,
.fs-count {
  margin: 0 0 0.35rem;
  line-height: 1.5;
}

.fs-root {
  color: var(--text);
}

.fs-dim {
  color: var(--text-soft);
}

.fs-prompt {
  color: var(--accent-primary);
}

.fs-prefix {
  color: inherit;
}

.fs-list {
  margin: 0.15rem 0 0.5rem;
  padding: 0 0 0 0.35rem;
  list-style: none;
}

.ld-tree .fs-item {
  position: relative;
  padding: 0.2rem 0 0.2rem 0.95rem;
  cursor: pointer;
  box-sizing: border-box;
}

.ld-tree .fs-item::before {
  position: absolute;
  top: 0.95rem;
  left: 0;
  width: 0.65rem;
  height: 1px;
  content: "";
  background-color: var(--term-tree-line);
}

.ld-tree .fs-item::after {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 1px;
  content: "";
  background-color: var(--term-tree-line);
}

.ld-tree .fs-item:last-child::after {
  height: 0.95rem;
  bottom: auto;
}

.fs-item.is-dir .fs-prefix,
.fs-item.is-dir .fs-name {
  color: var(--text-muted);
}

.fs-item.is-file .fs-prefix,
.fs-item.is-file .fs-name {
  color: var(--text-soft);
}

.fs-item.is-dir.is-selected .fs-prefix,
.fs-item.is-dir.is-selected .fs-name,
.fs-item.is-dir:hover .fs-prefix,
.fs-item.is-dir:hover .fs-name {
  color: var(--accent-primary);
  text-shadow: 0 0 10px var(--glow-accent);
}

.fs-item.is-file.is-selected .fs-prefix,
.fs-item.is-file.is-selected .fs-name,
.fs-item.is-file:hover .fs-prefix,
.fs-item.is-file:hover .fs-name {
  color: var(--accent-secondary);
  text-shadow: 0 0 10px var(--glow-secondary);
}

.fs-name {
  margin-left: 0.2rem;
}

.fs-count {
  color: var(--text-soft);
  font-size: 0.85em;
}

.fs-scroll-hint {
  position: sticky;
  bottom: 0;
  margin: 0.5rem 0 0;
  padding: 0.35rem 0.5rem 0.15rem;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: lowercase;
  color: var(--accent-secondary);
  text-align: center;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88) 55%, transparent);
  pointer-events: none;
  animation: fs-scroll-nudge 1.6s ease-in-out infinite;
}

.fs-scroll-hint[hidden] {
  display: none;
}

@keyframes fs-scroll-nudge {
  0%,
  100% {
    opacity: 0.55;
    transform: translateY(0);
  }
  50% {
    opacity: 1;
    transform: translateY(2px);
  }
}

.fs-image {
  margin: 0;
  line-height: 0;
}

.fs-image img {
  display: block;
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border-dim);
}

.os-window--image .fs-image img {
  max-height: min(76dvh, 36rem);
  width: auto;
  margin: 0 auto;
  object-fit: contain;
}


.fs-link {
  color: var(--text-muted);
  text-decoration: none;
}

.fs-link:hover {
  color: var(--accent-secondary);
  text-shadow: 0 0 10px var(--glow-secondary);
}

.fs-form {
  margin: 0.35rem 0;
}

.fs-form.lo-form {
  --lo-field-text: var(--text);
  --lo-field-bg: #050505;
  --lo-field-border: var(--border-dim);
  --lo-caret: var(--accent-primary);
  --lo-placeholder: var(--text-soft);
  --lo-placeholder-focus: rgba(var(--rgb-r), var(--rgb-g), var(--rgb-b), 0.42);
  --lo-btn-idle: var(--text-muted);
  --lo-btn-hover: var(--accent-primary);
  --lo-font-field: inherit;
  --lo-font-placeholder: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
  width: 100%;
  max-width: none;
  margin: 0.15rem 0 0;
}

.fs-form-trap {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  pointer-events: none !important;
}

.fs-form.lo-form .lo-field {
  width: 100%;
  max-width: none;
}

.fs-form.lo-form .lo-mirror {
  font-size: 0.76rem;
  padding: 0.42rem 0.5rem;
  line-height: 1.35;
}

.fs-form.lo-form input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]),
.fs-form.lo-form textarea {
  display: block;
  width: 100%;
  max-width: none;
  min-width: 0;
  box-sizing: border-box;
  font-size: 0.76rem;
  padding: 0.42rem 0.5rem;
  line-height: 1.35;
  min-height: 2rem;
  border-color: var(--border-dim);
}

.fs-form.lo-form input:not([type="submit"]):not([type="button"]):focus,
.fs-form.lo-form textarea:focus {
  border-color: var(--border-accent);
  caret-color: var(--accent-primary);
}

.fs-form.lo-form input:not([type="submit"]):not([type="button"])::placeholder,
.fs-form.lo-form textarea::placeholder {
  font-size: 0.76rem;
  font-family: inherit;
  color: var(--text-soft);
}

.fs-form.lo-form input:not([type="submit"]):not([type="button"]):focus::placeholder,
.fs-form.lo-form textarea:focus::placeholder {
  color: var(--lo-placeholder-focus);
}

.fs-form.lo-form textarea {
  min-height: 2.5rem;
  max-height: 3.5rem;
}

.fs-form.lo-form button[type="submit"] {
  margin: 0.15rem 0 0;
  font-size: 0.76rem;
  line-height: 1.55;
  letter-spacing: 0.18em;
  color: var(--text-muted);
}

.fs-form.lo-form button[type="submit"]:hover {
  color: var(--accent-primary);
  text-shadow: 0 0 10px var(--glow-accent);
}

.fs-form.lo-form .lo-form-status {
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.35;
  color: var(--text-soft);
}

.fs-form-row {
  display: contents;
}

/* —— Terminal shell: responsive / touch —— */

.terminal-input-mobile {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  overflow: hidden;
  white-space: nowrap;
}

.terminal-app.is-touch .terminal-chrome {
  cursor: pointer;
}

.terminal-app.is-touch .terminal-input-mobile:focus {
  position: static;
  width: 100%;
  height: auto;
  margin: 0.35rem 0 0;
  padding: 0.45rem 0.5rem;
  clip: auto;
  clip-path: none;
  overflow: visible;
  background: #000;
  border: 1px solid var(--border);
  color: var(--text);
  font: inherit;
  border-radius: 0;
}

.os-start,
.os-task-btn,
.os-win-close,
.fs-item {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

@media (max-width: 1024px) {
  .os-window {
    width: min(94%, 30rem);
    max-height: min(65dvh, 24rem);
  }

  .os-window--play {
    max-height: min(72dvh, 26rem);
  }

  .os-window--text {
    max-height: min(80dvh, 32rem);
  }
}

@media (max-width: 960px) {
  .header-classic-links {
    display: none;
  }
}

@media (max-width: 720px) {
  body[data-terminal-shell] .site-header--terminal .header-inner {
    min-height: 44px;
  }

  .header-tagline,
  .header-classic-links {
    display: none;
  }

  body[data-terminal-shell] .brand-logo {
    width: min(140px, 42vw);
  }

  .os-stacked-wave-logo {
    width: min(68vw, 24rem);
    max-width: calc(100% - 2rem);
  }

  .terminal-path-readout {
    font-size: 0.68rem;
    max-width: 42vw;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .os-desktop-hint--keys {
    display: none;
  }

  .os-desktop-hint--touch {
    display: block;
    font-size: 0.68rem;
    padding: 0 0.5rem;
  }

  .terminal-app.is-narrow .os-window {
    --os-win-alpha: 0.72;
    top: calc(0.35rem + var(--win-stack, 0) * 1.1rem) !important;
    left: 0.35rem !important;
    right: 0.35rem !important;
    width: auto !important;
    max-height: min(52dvh, 20rem);
  }

  .terminal-app.is-narrow .os-window--explorer {
    max-height: min(58dvh, 22rem);
  }

  .terminal-app.is-narrow .os-window--play {
    max-height: min(62dvh, 24rem);
  }

  .terminal-app.is-narrow .os-window--image {
    max-height: none;
  }

  .terminal-app.is-narrow .os-window--image .fs-image img {
    max-height: min(58dvh, 28rem);
  }

  .terminal-app.is-narrow .os-window--text {
    max-height: min(72dvh, 30rem);
  }

  .terminal-app.is-narrow .fs-viz.audio-visual--terminal {
    height: 84px;
  }

  .terminal-chrome {
    max-width: none;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
  }

  .site-footer--terminal {
    padding: 0.22rem 0 calc(0.22rem + env(safe-area-inset-bottom));
  }

  .site-footer-copy {
    font-size: 0.58rem;
  }

  .os-taskbar {
    padding-bottom: env(safe-area-inset-bottom);
  }

  .os-start,
  .os-task-btn {
    min-height: 2rem;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }

  .os-win-close {
    min-width: 2.25rem;
    min-height: 2.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .ld-tree .fs-item {
    padding: 0.45rem 0 0.45rem 0.95rem;
    min-height: 2.35rem;
  }

  .fs-name {
    overflow-wrap: anywhere;
  }
}

@media (pointer: coarse) {
  .os-desktop-hint--keys {
    display: none;
  }

  .os-desktop-hint--touch {
    display: block;
  }

  .ld-tree .fs-item {
    padding: 0.4rem 0 0.4rem 0.95rem;
    min-height: 2.25rem;
  }

  .os-win-close {
    min-width: 2.25rem;
    min-height: 2.25rem;
  }
}

body[data-terminal-shell] {
  display: flex;
  flex-direction: column;
}

.fs-form.lo-form button[type="submit"]:disabled {
  cursor: wait;
  opacity: 0.55;
}

body[data-terminal-shell] #root {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
}

/* —— Lucid Obscura forms —— */

.lo-form {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.95rem;
  width: 100%;
  max-width: 36rem;
  margin: 0.35rem 0 0;
}

.lo-field {
  position: relative;
  width: fit-content;
  max-width: min(92vw, 30rem);
  text-align: left;
}

.lo-mirror {
  position: absolute;
  visibility: hidden;
  white-space: pre-wrap;
  font-size: 14pt;
  font-family: var(--lo-font-field);
  padding: 15px;
  pointer-events: none;
}

.lo-form input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]),
.lo-form textarea {
  color: var(--lo-field-text);
  background-color: var(--lo-field-bg);
  font-size: 14pt;
  font-family: var(--lo-font-field);
  padding: 15px;
  border: 1px solid var(--lo-field-border);
  outline: none;
  width: auto;
  min-width: 2ch;
  max-width: min(92vw, 30rem);
  overflow-wrap: break-word;
  word-wrap: break-word;
  text-align: left;
  white-space: normal;
  resize: none;
  border-radius: 0;
  box-shadow: none;
}

.lo-form textarea {
  min-height: 50px;
  height: auto;
  max-width: min(92vw, 36rem);
  display: block;
}

.lo-form input:not([type="submit"]):not([type="button"]) {
  padding-right: 5px;
}

.lo-form input:not([type="submit"]):not([type="button"]):focus,
.lo-form textarea:focus {
  caret-color: var(--lo-caret);
  border-color: var(--lo-field-border);
}

.lo-form input:not([type="submit"]):not([type="button"])::placeholder,
.lo-form textarea::placeholder {
  color: var(--lo-placeholder);
  transition: color 0.3s ease;
  font-family: var(--lo-font-placeholder);
  font-size: 16px;
}

.lo-form input:not([type="submit"]):not([type="button"]):focus::placeholder,
.lo-form textarea:focus::placeholder {
  color: var(--lo-placeholder-focus);
}

.lo-form input:not([type="submit"]):not([type="button"]):not(:placeholder-shown)::placeholder,
.lo-form textarea:not(:placeholder-shown)::placeholder {
  color: transparent;
}

.lo-form button[type="submit"],
.lo-form .lo-submit {
  margin: 0.15rem 0 0;
  padding: 0;
  font-family: var(--lo-font-placeholder);
  letter-spacing: 0.4em;
  line-height: 2em;
  font-size: 1rem;
  text-transform: lowercase;
  color: var(--lo-btn-idle);
  background: transparent;
  border: none;
  cursor: pointer;
}

.lo-form button[type="submit"]:hover,
.lo-form .lo-submit:hover {
  color: var(--lo-btn-hover);
}

.lo-form .helper-text,
.lo-form .status-note,
.lo-form .lo-form-status {
  margin: 0;
  color: #666;
  font-size: 0.85rem;
  font-family: var(--lo-font-field);
}
