:root {
  --bg: #07100c;
  --panel: #0b1711;
  --text: #d7f7df;
  --muted: #7da98a;
  --accent: #62e58a;
  --accent2: #b7ffca;
  --warn: #f4c96b;
  --error: #ff7777;
  --border: #183d25;
}

* { box-sizing: border-box; }
html, body { height: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(50,130,75,.13), transparent 38%),
    var(--bg);
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background: repeating-linear-gradient(
    0deg,
    rgba(255,255,255,.018),
    rgba(255,255,255,.018) 1px,
    transparent 1px,
    transparent 4px
  );
  opacity: .35;
}

.wrap {
  min-height: 100%;
  padding: 32px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.terminal {
  width: min(980px, 100%);
  min-height: 680px;
  background: rgba(11,23,17,.96);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 24px 80px rgba(0,0,0,.45), 0 0 40px rgba(45,170,85,.06);
  overflow: hidden;
}

.bar {
  height: 42px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border-bottom: 1px solid var(--border);
  background: #0d1c13;
}

.dot { width: 11px; height: 11px; border-radius: 50%; background: #294934; }
.title { margin-right: auto; color: var(--muted); font-size: 12px; }
.version { color: var(--muted); font-size: 11px; white-space: nowrap; }
.screen { padding: 24px; }
pre { margin: 0; white-space: pre-wrap; word-break: break-word; line-height: 1.55; font-size: 14px; }
.output {
  max-height: clamp(240px, calc(100dvh - 220px), 560px);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.prompt { color: var(--accent); }
.cmd { color: var(--accent2); }
.dim { color: var(--muted); }
.ok { color: var(--accent); }
.warn { color: var(--warn); }
.err { color: var(--error); }
a { color: var(--accent2); }

.input-row {
  display: flex;
  align-items: center;
  margin-top: 8px;
}
.input-row[hidden] { display: none; }

.input-row span { color: var(--accent); white-space: pre; }
#challengeHint { display: none; color: var(--muted); }
.input-row.challenge-mode #prompt { display: none !important; }
.input-row.challenge-mode #challengeHint { display: inline !important; }
.input-row.challenge-mode input { padding-left: 8px; }

input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: 0;
  outline: 0;
  color: var(--accent2);
  font: inherit;
  padding: 0 0 0 8px;
}

@media (max-width: 600px) {
  .wrap { padding: 0; }
  .terminal { min-height: 100vh; border-radius: 0; border-left: 0; border-right: 0; }
  .screen { padding: 16px; }
  pre { font-size: 12px; }
}


.dir { font-weight: 600; }
.file { }
.file-content { white-space: pre-wrap; }
#prompt { white-space: nowrap; }
#challengeHint { display: none; }

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(560px, 100%);
  margin: 8px 0 16px;
  white-space: normal;
}

.contact-form label { color: var(--muted); }
.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #07100c;
  color: var(--text);
  font: inherit;
}
.contact-form textarea { resize: vertical; }
.contact-form input:focus,
.contact-form textarea:focus { border-color: var(--accent); }
.contact-form button {
  align-self: flex-start;
  margin-top: 4px;
  padding: 8px 14px;
  border: 1px solid var(--accent);
  border-radius: 5px;
  background: transparent;
  color: var(--accent2);
  font: inherit;
  cursor: pointer;
}
.contact-form button:hover:not(:disabled) { background: rgba(98,229,138,.12); }
.contact-form button:disabled { opacity: .6; cursor: wait; }
.contact-status { min-height: 1.5em; white-space: normal; }
