:root {
  --bg: #0d1117;
  --fg: #e6edf3;
  --muted: #9aa4b2;
  --accent: #4f9cf9;
  --card: #161b22;
  --strip: rgba(79, 156, 249, 0.35);
}

* { box-sizing: border-box; }

body {
  margin: 0 auto;
  max-width: 860px;
  padding: 2rem 1.5rem 4rem;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.55;
}

header { text-align: center; margin-bottom: 2rem; }
h1 { font-size: 2.2rem; margin-bottom: 0.25rem; }
h2 { margin-top: 2.5rem; }
.tagline { font-size: 1.15rem; color: var(--muted); }
.meta { color: var(--muted); font-size: 0.9rem; }
a { color: var(--accent); }

.button {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  padding: 0.6rem 1.4rem;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  margin-top: 0.5rem;
}
.button.secondary {
  background: transparent;
  color: var(--accent);
  box-shadow: inset 0 0 0 1.5px var(--accent);
  margin-left: 0.5rem;
}

.grid4 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}
.grid4 > div {
  background: var(--card);
  border-radius: 10px;
  padding: 1rem;
}
.grid4 h3 { margin-top: 0; }

.demo-wrap { display: flex; gap: 1.5rem; flex-wrap: wrap; align-items: flex-start; }

.demo-pad {
  position: relative;
  width: 420px;
  max-width: 100%;
  height: 250px;
  background: #2a313c;
  border-radius: 18px;
  cursor: crosshair;
  touch-action: none;
  user-select: none;
  overflow: hidden;
}
.zone-hint { position: absolute; background: var(--strip); opacity: 0.45; }
.zone-hint.left { left: 0; top: 17%; bottom: 0; width: 10%; }
.zone-hint.right { right: 0; top: 17%; bottom: 0; width: 10%; }
.zone-hint.bottom { left: 0; right: 0; bottom: 0; height: 10%; }
.zone-hint.top-left { left: 0; top: 0; width: 20%; height: 17%; }
.zone-hint.top-right { right: 0; top: 0; width: 20%; height: 17%; }
.pad-label {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: #fff; opacity: 0.55; font-size: 0.85rem; pointer-events: none;
}

.demo-side { flex: 1; min-width: 220px; }
.readout {
  background: #05070a;
  border-radius: 8px;
  padding: 0.6rem;
  min-height: 130px;
  font-family: ui-monospace, Menlo, monospace;
  font-size: 0.85rem;
  margin-top: 0.75rem;
}
.readout div { padding: 0.12rem 0; }

.command {
  background: #05070a;
  border-radius: 8px;
  padding: 0.75rem;
  overflow-x: auto;
  font-family: ui-monospace, Menlo, monospace;
  font-size: 0.85rem;
}

table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 0.4rem 0.75rem; border-bottom: 1px solid #2a313c; }
th { color: var(--muted); font-weight: 600; }

dt { font-weight: 600; margin-top: 1rem; }
dd { margin-left: 0; color: var(--muted); }

input {
  background: #0a0d12;
  color: var(--fg);
  border: 1px solid #30363d;
  border-radius: 6px;
  padding: 0.5rem 0.6rem;
  font-family: ui-monospace, Menlo, monospace;
}
button {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 0.5rem 1rem;
  font-weight: 600;
  cursor: pointer;
}

footer { margin-top: 3rem; color: var(--muted); font-size: 0.9rem; text-align: center; }
