/* ==========================================================
   sshsrv.com — main stylesheet
   Change the colours here and the whole site follows.
   ========================================================== */
:root {
  --bg:          #0c0d0d;
  --bg-raised:   #121414;
  --fg:          #e8e6e3;
  --title:       #dde8d8;
  --muted:       #9d978d;
  --dim:         #847e75;   /* 4.7:1 on --bg, the lowest grey allowed for text */
  --line:        rgba(232, 230, 227, 0.10);
  --line-strong: rgba(232, 230, 227, 0.22);
  --accent:      #5ef2a0;   /* phosphor green */
  --accent-soft: rgba(94, 242, 160, 0.12);
  --amber:       #f2c35e;
  --danger:      #ff8a7a;   /* form errors, 7:1 on --bg */

  --sans: "Space Grotesk", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "Cascadia Code", Consolas, monospace;

  --wrap: 1180px;
  --gutter: clamp(20px, 5vw, 48px);
}

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

/* scroll-padding keeps anchor jumps and keyboard focus clear of the sticky top bar */
html { scroll-behavior: smooth; scroll-padding-top: 84px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
::selection { background: var(--accent); color: var(--bg); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--wrap) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.accent { color: var(--accent); }
.muted  { color: var(--muted); }

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* keyboard users can jump past the header */
.skip {
  position: fixed;
  top: 12px; left: 12px;
  z-index: 100;
  padding: 12px 16px;
  background: var(--accent);
  color: var(--bg);
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transform: translateY(-160%);
  transition: transform 0.2s ease-out;
}
.skip:focus { transform: translateY(0); }

main, .footer { position: relative; z-index: 1; }

/* ---------- small mono labels ---------- */
.label,
.group,
.topbar__nav a,
.status,
.scroll,
.card__desc,
.card__tag,
.stat__label,
.panel__head,
.contact__spelled,
.panel__title,
.footer {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.label { color: var(--muted); margin: 0 0 56px; font-weight: 400; line-height: 1.6; }
.label--center { text-align: center; margin-bottom: 40px; }

/* ---------- top bar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 18px var(--gutter);
  background: rgba(12, 13, 13, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}
.topbar.is-scrolled { border-bottom-color: var(--line); }

.topbar__brand {
  font-weight: 600;
  font-size: 18px;
  letter-spacing: -0.03em;
}
.topbar__brand .dot { color: var(--accent); }

.topbar__nav { display: flex; gap: 12px; margin-left: auto; }
.topbar__nav a {
  position: relative;
  padding: 10px 6px;          /* 38px tall tap target */
  color: var(--muted);
  transition: color 0.2s;
}
.topbar__nav a:hover { color: var(--accent); }
.topbar__nav a[aria-current] { color: var(--fg); }
.topbar__nav a[aria-current]::after {
  content: "";
  position: absolute;
  left: 6px; right: 6px; bottom: 4px;
  height: 1px;
  background: var(--accent);
}

.status { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); }
.status__led {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 var(--accent);
  animation: ping 2.4s infinite;
}
.status.is-down .status__led { background: var(--amber); animation: none; }

@keyframes ping {
  0%   { box-shadow: 0 0 0 0 rgba(94, 242, 160, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(94, 242, 160, 0); }
  100% { box-shadow: 0 0 0 0 rgba(94, 242, 160, 0); }
}

/* ---------- hero ---------- */
.hero {
  min-height: calc(100vh - 64px);
  min-height: calc(100svh - 64px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  padding-bottom: 96px;
}

/* still, faint grid behind the hero that fades out toward the bottom */
.hero::before {
  content: "";
  position: absolute;
  top: -64px;
  bottom: 0;
  left: 50%;
  width: 100vw;
  transform: translateX(-50%);
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(232, 230, 227, 0.045) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(232, 230, 227, 0.045) 1px, transparent 1px);
  background-size: 112px 112px;
  background-position: center top;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
}

.hero__title {
  margin: 0;
  font-weight: 600;
  font-size: clamp(5.5rem, 19vw, 15rem);
  line-height: 0.86;
  letter-spacing: -0.075em;
  color: var(--title);
  display: flex;
  align-items: baseline;
}

.hero__dot {
  display: inline-block;
  width: 0.15em;
  height: 0.15em;
  margin-left: 0.04em;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 24px rgba(94, 242, 160, 0.30);
  animation: breathe 3.2s ease-in-out 3;   /* breathes a few times on load, then rests */
  flex: none;
}

@keyframes breathe {
  0%, 100% { box-shadow: 0 0 24px rgba(94, 242, 160, 0.30); }
  50%      { box-shadow: 0 0 56px rgba(94, 242, 160, 0.60); }
}

.hero__prompt {
  margin: 36px 0 0;
  font-family: var(--mono);
  font-size: clamp(1rem, 2.2vw, 1.4rem);
  letter-spacing: -0.02em;
  min-height: 1.6em;
}

.caret {
  display: inline-block;
  width: 0.6em;
  height: 1.1em;
  margin-left: 2px;
  vertical-align: -0.18em;
  background: var(--accent);
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

.hero__sub {
  margin: 10px 0 0;
  font-family: var(--mono);
  font-size: clamp(0.85rem, 1.6vw, 1rem);
  color: var(--muted);
}

.scroll {
  position: absolute;
  left: var(--gutter);
  bottom: 40px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
}
.scroll__btn {
  display: grid;
  place-items: center;
  width: 26px; height: 26px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--accent);
  font-size: 13px;
  transition: transform 0.25s, border-color 0.25s;
}
.scroll:hover .scroll__btn { transform: translateY(3px); border-color: var(--accent); }

/* ---------- sections ---------- */
.section {
  padding-top: 120px;
  padding-bottom: 40px;
}
#running { border-top: 1px solid var(--line-strong); padding-top: 64px; }

.group {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--accent);
  margin: 0 0 20px;
}
.group + .cards { margin-bottom: 72px; }

.pip { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.pip--soon { background: var(--amber); }
.group:has(.pip--soon) { color: var(--amber); }

/* ---------- cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 200px;
  padding: 22px;
  border: 1px solid var(--line-strong);
  background: rgba(12, 13, 13, 0.6);
  transition: border-color 0.25s, background 0.25s, transform 0.25s;
}
.card:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.card:active { transform: scale(0.99); transition-duration: 0.08s; }

.card__arrow {
  position: absolute;
  top: 18px; right: 20px;
  color: var(--accent);
  font-size: 16px;
  transition: transform 0.25s;
}
.card:hover .card__arrow { transform: translate(3px, -3px); }

.card__tag {
  position: absolute;
  top: 18px; right: 20px;
  color: var(--amber);
  border: 1px solid rgba(242, 195, 94, 0.4);
  padding: 3px 8px;
  font-size: 12px;
  line-height: 1.4;
}

.card__name {
  text-wrap: balance;
  margin: 0 0 14px;
  font-weight: 500;
  font-size: clamp(1.6rem, 2.6vw, 2rem);
  letter-spacing: -0.04em;
  line-height: 1.1;
  color: var(--title);
}
.card__desc {
  margin: 0;
  max-width: 32ch;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.65;
}

.card--soon { border-style: dashed; }
.card--soon:hover { border-color: var(--amber); background: rgba(242, 195, 94, 0.07); }

/* ---------- stats panel ---------- */
.panel { border: 1px solid var(--line-strong); background: rgba(12, 13, 13, 0.6); }

.panel__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 14px 22px;
  border-bottom: 1px solid var(--line-strong);
  color: var(--muted);
}
.panel__title { margin: 0; font-weight: 400; color: inherit; }

.panel__grid { display: grid; grid-template-columns: repeat(3, 1fr); }

.stat { padding: 26px 22px 24px; }
.stat + .stat { border-left: 1px solid var(--line-strong); }

.stat__value {
  font-weight: 500;
  font-size: clamp(2.2rem, 4vw, 3rem);
  letter-spacing: -0.06em;
  line-height: 1;
  color: var(--title);
  font-variant-numeric: tabular-nums;
}
.stat__label { margin-top: 14px; color: var(--muted); }

/* ---------- get in touch (contact form) ---------- */
.waitlist {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: 48px;
  padding: 40px;
  border: 1px solid var(--line-strong);
  background: rgba(12, 13, 13, 0.6);
}
.waitlist .label { margin-bottom: 20px; color: var(--accent); }
.waitlist__title {
  margin: 0 0 14px;
  font-weight: 500;
  font-size: clamp(1.8rem, 3.6vw, 2.8rem);
  letter-spacing: -0.05em;
  line-height: 1.05;
  color: var(--title);
  text-wrap: balance;
}
.waitlist__text { margin: 0; max-width: 48ch; color: var(--muted); }

.btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: var(--accent);
  color: var(--bg);
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border: 0;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(94, 242, 160, 0.25); }
.btn:active { transform: translateY(0) scale(0.98); box-shadow: none; transition-duration: 0.08s; }
.btn:disabled { opacity: 0.5; cursor: progress; transform: none; box-shadow: none; }

.signup { display: grid; gap: 18px; }
.signup__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.signup__field { display: grid; gap: 8px; }
.signup__label {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.signup__optional { color: var(--dim); text-transform: none; letter-spacing: 0; }

.signup input,
.signup textarea {
  width: 100%;
  padding: 12px 14px;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: 0;
  color: var(--fg);
  font: 16px/1.5 var(--sans);   /* 16px stops iOS zooming in on focus */
  transition: border-color 0.2s;
}
.signup textarea { resize: vertical; min-height: 96px; }
.signup input:hover,
.signup textarea:hover { border-color: rgba(232, 230, 227, 0.35); }
.signup input:focus,
.signup textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.signup [aria-invalid="true"] { border-color: var(--danger); }

.signup__error { margin: 0; color: var(--danger); font-size: 13px; }

.signup__trap { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.signup__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 20px; }
.signup__status { margin: 0; font-family: var(--mono); font-size: 12px; letter-spacing: 0.04em; color: var(--muted); }
.signup__status[data-kind="ok"] { color: var(--accent); }
.signup__status[data-kind="error"] { color: var(--danger); }

/* ---------- contact ---------- */
.contact { padding-top: 150px; padding-bottom: 110px; text-align: center; }
.contact__rule {
  width: min(850px, 100%);
  height: 1px;
  margin: 0 auto 34px;
  background: var(--line);
}
.contact .label--center { margin-bottom: 16px; }

.contact__link { display: inline-block; position: relative; max-width: 100%; vertical-align: top; }
/* the canvas only shows once the script has drawn it; until then (or with no JS) the text address shows */
#dotmatrix { display: none; max-width: 100%; cursor: crosshair; touch-action: pan-y pinch-zoom; }
.js-dots #dotmatrix { display: block; }
.contact__fallback {
  font-family: var(--mono);
  font-size: clamp(1.4rem, 5vw, 3.4rem);
  color: var(--accent);
}
.js-dots .contact__fallback {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0);
}

.contact__spelled { margin: 16px 0 0; color: var(--muted); }

/* ---------- footer ---------- */
.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-top: 20px;
  padding-bottom: 28px;
  color: var(--muted);
  border-top: 1px solid var(--line-strong);
  background: var(--bg);
}
.footer a { display: inline-block; padding: 8px 0; margin: -8px 0; }  /* bigger tap area, same layout */
.footer a:hover { color: var(--accent); }

/* ---------- simple text pages (privacy, 404) ---------- */
.page { max-width: 720px; padding-top: 80px; padding-bottom: 120px; }
.page h1 {
  font-weight: 600;
  font-size: clamp(3rem, 10vw, 6rem);
  letter-spacing: -0.07em;
  line-height: 0.9;
  margin: 0 0 40px;
  color: var(--title);
}
.page h2 { font-weight: 500; letter-spacing: -0.03em; margin: 40px 0 10px; color: var(--title); }
.page p, .page li { color: var(--muted); }
.page a { color: var(--accent); }
.page code { font-family: var(--mono); color: var(--fg); font-size: 0.9em; }

/* ---------- privacy page: big two-line title, text in a narrow column on the right ---------- */
.privacy {
  max-width: calc(850px + var(--gutter) * 2);
  min-height: 100svh;
  padding-top: 40px;
  padding-bottom: 80px;
}
.privacy__back {
  display: inline-block;
  padding: 6px 0;             /* bigger tap area, same layout */
  margin: -6px 0;
  font: 500 12px/1.2 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
  transition: color 0.2s;
}
.privacy__back:hover { color: var(--accent); }
.privacy__kicker { margin: 18vh 0 16px; font-size: 16px; color: var(--fg); }
.privacy__title {
  margin: 0;
  font-weight: 600;
  font-size: clamp(4rem, 10vw, 8rem);
  line-height: 0.8;
  letter-spacing: -0.075em;
  color: var(--title);
}
.privacy__copy {
  max-width: 560px;
  margin: 70px 0 0 auto;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.7;
}
.privacy__copy p { margin: 0; }
.privacy__copy h2 {
  margin: 48px 0 12px;
  font: 500 15px/1.4 var(--mono);
  letter-spacing: -0.04em;
  color: var(--fg);
}
.privacy__copy a { color: var(--accent); }
.privacy__copy a:hover { text-decoration: underline; text-underline-offset: 3px; }
.privacy__copy .privacy__updated {
  margin-top: 65px;
  font: 500 12px/1.4 var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--dim);
}

/* ---------- responsive ---------- */
@media (max-width: 700px) {
  .privacy { padding-top: 24px; padding-bottom: 60px; }
  .privacy__copy { margin-top: 55px; }
}

@media (max-width: 820px) {
  .topbar__nav { display: none; }
  .status { margin-left: auto; }

  .panel__grid { grid-template-columns: 1fr; }
  .stat + .stat { border-left: 0; border-top: 1px solid var(--line-strong); }

  .waitlist { grid-template-columns: 1fr; gap: 28px; padding: 28px; }
  .signup__row { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Windows high-contrast themes: show the plain text address in system colours instead of the dot sign */
@media (forced-colors: active) {
  .js-dots #dotmatrix { display: none; }
  .js-dots .contact__fallback {
    position: static;
    width: auto; height: auto;
    overflow: visible;
    clip: auto;
  }
}
