:root {
  --paper: #eceef2;
  --ink: #111318;
  --quiet: #5c5f68;
  --line: #d5d7de;
  --fill: #ffffff;
  --mist: #e4e6ec;
  --graphite: #111318;
  --bezel: #1a1b20;
  --term: #111318;
  --lime: #d6ff3c;
  --scratch: #e11d2e;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  width: 100%;
}

body {
  font-family: Inter, sans-serif;
  background: var(--paper);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
}

.wash {
  position: fixed;
  inset: -2rem 0 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  font-family: Poppins, Inter, sans-serif;
  font-style: normal;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.05em;
  color: #111318;
  opacity: 0.05;
  -webkit-mask-image: radial-gradient(ellipse 68% 58% at 50% 38%, transparent 8%, #000 72%);
  mask-image: radial-gradient(ellipse 68% 58% at 50% 38%, transparent 8%, #000 72%);
}

.wash-row {
  display: flex;
  flex-shrink: 0;
  width: max-content;
  gap: 1.15rem;
  line-height: 1;
  white-space: nowrap;
}

.wash span {
  position: static;
  flex: 0 0 auto;
  min-width: 5.1ch;
  text-align: center;
  font-size: clamp(1.35rem, 2.4vw, 2.15rem);
}

.wash-row:nth-child(odd) {
  transform: translateX(-1.6rem);
}

.wash-row:nth-child(even) {
  transform: translateX(2.4rem);
}

.page {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 980px;
  margin: 0 auto;
  padding: 20px 24px 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.nav,
.hero,
.stage {
  width: 100%;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 6px 6px 6px 18px;
  background: var(--fill);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: 0 8px 24px rgba(17, 19, 24, 0.05);
}

.wordmark {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.04em;
}

.nav-links {
  display: flex;
  gap: 4px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: transparent;
  border: 0;
  text-decoration: none;
}

.icon-btn:hover {
  background: var(--mist);
}

.icon-btn:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.icon-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 52px 0 32px;
}

.hero::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: min(42rem, 140%);
  height: 100%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at 50% 42%, var(--paper) 0%, var(--paper) 46%, transparent 74%);
  z-index: -1;
  pointer-events: none;
}

.hero h1 {
  margin: 0;
  max-width: 100%;
  font-family: Poppins, Inter, sans-serif;
  font-style: normal;
  font-weight: 800;
  font-size: clamp(1.55rem, 4.4vw + 0.55rem, 3.6rem);
  letter-spacing: -0.045em;
  line-height: 1.12;
}

.hero h1 .h1-line {
  display: block;
  white-space: nowrap;
}

.mark {
  position: relative;
  display: inline-block;
}

.scratch {
  position: absolute;
  left: -6%;
  top: 6%;
  width: 112%;
  height: 92%;
  overflow: visible;
  pointer-events: none;
}

.scratch path {
  fill: none;
  stroke: var(--scratch);
  stroke-width: 5.4;
  stroke-linecap: round;
}

.scratch .scratch-thin {
  stroke-width: 2.1;
  opacity: 0.45;
}

.hero p[data-description] {
  margin: 18px 0 0;
  max-width: 32em;
  font-size: 16px;
  line-height: 1.5;
  color: var(--quiet);
}

.command {
  margin-top: 24px;
  width: max-content;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 5px 5px 5px 16px;
  background: var(--fill);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.command code {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 13px;
  font-weight: 500;
}

.command .prompt {
  color: var(--quiet);
  margin-right: 6px;
}

.copy {
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  background: var(--graphite);
  color: var(--lime);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  padding: 9px 14px;
  cursor: pointer;
}

.copy:hover {
  background: #000;
}

.copy:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

.stage {
  display: flex;
  justify-content: center;
}

.mac {
  width: min(740px, 100%);
  margin: 0 auto;
  border-radius: 24px;
  background: linear-gradient(#f3f3f6, #cfd1d8);
  border: 1px solid #c4c6cd;
  padding: 11px 11px 0;
  box-shadow:
    0 30px 70px rgba(17, 19, 24, 0.18),
    0 0 0 1px rgba(255, 255, 255, 0.4) inset;
  animation: rise 700ms ease both;
}

.lid {
  position: relative;
  background: var(--bezel);
  border-radius: 16px;
  padding: 16px 11px 11px;
}

.notch {
  position: absolute;
  top: 6px;
  left: 50%;
  width: 8px;
  height: 8px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: #0b0b0d;
  box-shadow: 0 0 0 1px #2a2a30;
}

.screen {
  background: var(--term);
  border-radius: 12px;
  overflow: hidden;
  color: #ececf1;
}

.bar {
  display: flex;
  align-items: center;
  padding: 11px 14px 9px;
  background: #1c1d24;
}

.traffic {
  display: flex;
  gap: 6px;
}

.traffic i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: block;
}

.traffic .r { background: #ff5f57; }
.traffic .y { background: #febc2e; }
.traffic .g { background: #28c840; }

.bar span {
  flex: 1;
  text-align: center;
  font-size: 12px;
  font-weight: 500;
  color: #8b8d97;
  margin-right: 48px;
}

.term {
  padding: 18px 18px 16px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 13px;
  line-height: 1.55;
}

.typed {
  color: #9ea1ab;
  margin-bottom: 16px;
}

.caret {
  display: inline-block;
  width: 8px;
  height: 1em;
  margin-left: 3px;
  background: var(--lime);
  vertical-align: text-bottom;
  animation: blink 1s steps(1) infinite;
}

.term .cols,
.term .row {
  display: grid;
  grid-template-columns: 70px 1.4fr 80px 70px;
  gap: 10px;
  align-items: center;
}

.term .cols {
  color: #7d808a;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0 12px 8px;
}

.term .row {
  padding: 9px 12px;
  border-radius: 10px;
  color: #d8dae1;
}

.term .row.is-on {
  background: var(--lime);
  color: #111318;
}

.term .row.is-on .stop {
  color: inherit;
}

.stop-ok {
  color: #d6ff3c;
}

.stop-risky {
  color: #e8b84a;
}

.stop-no {
  color: #e11d2e;
}

.dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lime);
  margin-right: 8px;
  vertical-align: middle;
}

.keys {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.key {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 9px 6px 7px;
  border-radius: 9px;
  background: #1c1d24;
  color: #c6c8d0;
  font-family: Inter, sans-serif;
  font-size: 11px;
  font-weight: 500;
}

.key svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.key svg rect {
  fill: currentColor;
  stroke: none;
}

.chin {
  height: 18px;
  position: relative;
}

.nub {
  position: absolute;
  left: 50%;
  top: 6px;
  width: 88px;
  height: 5px;
  transform: translateX(-50%);
  border-radius: 0 0 8px 8px;
  background: #b0b2ba;
}

@keyframes blink {
  50% { opacity: 0; }
}

@keyframes rise {
  from {
    transform: translateY(14px) scale(0.985);
  }
  to {
    transform: translateY(0) scale(1);
  }
}

@media (max-width: 640px) {
  .hero {
    padding: 32px 0 24px;
    text-align: center;
  }

  .page {
    padding: 16px 16px 40px;
    align-items: center;
  }

  .hero h1,
  .hero p[data-description],
  .command,
  .stage,
  .mac {
    margin-left: auto;
    margin-right: auto;
  }

  .hero h1 {
    width: 100%;
    font-size: clamp(1.45rem, 8vw, 2.15rem);
    text-align: center;
  }

  .hero p[data-description] {
    width: 100%;
    max-width: 22em;
    text-align: center;
  }

  .stage,
  .mac {
    width: 100%;
  }

  .keys {
    justify-content: center;
    gap: 6px;
  }

  .key {
    padding: 5px 7px 5px 6px;
    font-size: 10px;
  }

  .term {
    font-size: 12px;
    padding: 14px;
  }

  .term .cols,
  .term .row {
    grid-template-columns: 52px 1.3fr 64px 56px;
    gap: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mac,
  .caret {
    animation: none;
  }
}
