:root {
  --ink: #d8d0b8;
  --dim: #7a8172;
  --amber: #c9a15a;
  --moss: #7fb060;
  --night: #05070a;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  background: var(--night);
  color: var(--ink);
  font-family: "Cascadia Mono", "Consolas", "SFMono-Regular", "DejaVu Sans Mono", ui-monospace, monospace;
  overflow: hidden;
}

#game {
  display: block;
  position: fixed;
  inset: 0;
  image-rendering: pixelated;
  cursor: crosshair;
}

/* ---- start screen ------------------------------------------------------ */
.boot {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 50% 40%, rgba(8, 14, 12, 0.35), rgba(3, 4, 7, 0.92) 65%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.014) 0 1px, transparent 1px 3px);
  backdrop-filter: blur(1.5px);
  z-index: 10;
  transition: opacity 0.5s ease, visibility 0.5s;
  overflow: auto;
  padding: 24px;
}

.boot.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.frame {
  width: min(760px, 100%);
  border: 1px solid #2a2f28;
  background: linear-gradient(180deg, rgba(9, 13, 11, 0.86), rgba(4, 6, 8, 0.94));
  box-shadow: 0 0 0 1px #0b0e0a inset, 0 30px 80px rgba(0, 0, 0, 0.7);
  padding: 26px 30px 22px;
  position: relative;
}

.frame::before, .frame::after {
  content: "";
  position: absolute;
  width: 10px; height: 10px;
  border: 1px solid var(--amber);
  opacity: 0.55;
}
.frame::before { top: 7px; left: 7px; border-right: 0; border-bottom: 0; }
.frame::after { bottom: 7px; right: 7px; border-left: 0; border-top: 0; }

.banner {
  margin: 0 0 10px;
  color: #4f7a3f;
  font-size: 10px;
  line-height: 1.15;
  letter-spacing: 0;
  text-shadow: 0 0 18px rgba(90, 150, 90, 0.25);
  white-space: pre;
  overflow: hidden;
}

h1 {
  margin: 4px 0 6px;
  font-size: clamp(20px, 4vw, 30px);
  font-weight: 500;
  letter-spacing: 0.42em;
  color: #e8dcbc;
  text-shadow: 0 0 26px rgba(201, 161, 90, 0.28);
}

.lede {
  margin: 0 0 20px;
  color: #8b9484;
  font-size: 12.5px;
  line-height: 1.7;
  max-width: 60ch;
}

.row { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.row label { color: var(--dim); font-size: 12px; letter-spacing: 0.18em; text-transform: uppercase; }

input#name {
  flex: 1;
  background: #070a08;
  border: 1px solid #2b3329;
  color: #e8dcbc;
  font: inherit;
  font-size: 14px;
  padding: 9px 11px;
  outline: none;
  letter-spacing: 0.06em;
}
input#name:focus { border-color: #5c7a4a; box-shadow: 0 0 0 3px rgba(90, 130, 70, 0.12); }

.classes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 20px; }
@media (max-width: 620px) { .classes { grid-template-columns: 1fr; } }

.cls {
  text-align: left;
  background: #080b09;
  border: 1px solid #232a23;
  color: #a9b09c;
  font: inherit;
  padding: 12px;
  cursor: pointer;
  display: grid;
  gap: 3px;
  transition: border-color 0.15s, background 0.15s, transform 0.15s;
}
.cls:hover { border-color: #4a5c3e; transform: translateY(-1px); }
.cls.active { border-color: var(--amber); background: #0d1109; box-shadow: 0 0 0 1px rgba(201, 161, 90, 0.18) inset; }
.cls .glyph { font-size: 20px; line-height: 1; }
.cls b { color: #e6dcc0; font-weight: 600; letter-spacing: 0.08em; font-size: 13px; }
.cls em { font-style: normal; color: #7f8a72; font-size: 11px; }
.cls small { color: #5f6a58; font-size: 10.5px; line-height: 1.5; }

.enter {
  width: 100%;
  background: #101409;
  border: 1px solid #6a7a44;
  color: #dfe6bb;
  font: inherit;
  font-size: 14px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  padding: 14px;
  cursor: pointer;
  transition: background 0.16s, color 0.16s, box-shadow 0.16s;
}
.enter:hover { background: #1a2110; color: #fff6cf; box-shadow: 0 0 30px rgba(160, 180, 90, 0.14); }

.status { margin: 12px 0 0; font-size: 11.5px; color: #6b7565; letter-spacing: 0.05em; min-height: 1.2em; }
.status.online { color: #7fb060; }
.status.offline { color: #b07a5a; }

.keys { margin: 14px 0 0; font-size: 10.5px; color: #4b544a; line-height: 1.8; }

@media (max-height: 720px) {
  .banner { display: none; }
  h1 { font-size: 20px; }
  .lede { display: none; }
}
