:root {
  --bg:         #0d0d0d;
  --bg-card:    #111111;
  --bg-input:   #080808;
  --text:       #00cc55;
  --text-bright:#00ff66;
  --text-dim:   #005528;
  --border:     #002211;
  --border-mid: #004422;
}

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

body {
  margin: 0;
  padding: 2rem 1rem;
  font-family: Hack, "DejaVu Sans Mono", Monaco, Consolas, "Ubuntu Mono", monospace;
  font-size: 1rem;
  line-height: 1.54;
  background: var(--bg);
  color: var(--text);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

main {
  max-width: 680px;
  margin: 0 auto;
}

h1, h2, h3 {
  font-family: inherit;
  font-weight: bold;
  line-height: 1.3;
  color: var(--text-bright);
  margin: 0 0 1rem;
}

h1 { font-size: 1.4rem; }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.2rem; }

p { margin: 0 0 1rem; }

a {
  color: var(--text-bright);
  text-decoration: underline;
  text-underline-offset: 3px;
}
a:hover { color: #33ff88; }

hr {
  border: none;
  height: 1px;
  background: var(--border-mid);
  margin: 2rem 0;
}

/* ── Login card ─────────────────────────────────────────── */

.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.login-card {
  width: 100%;
  max-width: 360px;
  background: var(--bg-card);
  border: 1px solid var(--border-mid);
  padding: 2rem;
}

.login-card h1 {
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.field {
  margin-bottom: 1rem;
}

.field label {
  display: block;
  font-size: 0.875rem;
  font-weight: bold;
  margin-bottom: 0.35rem;
  color: var(--text-dim);
}

.field input {
  width: 100%;
  padding: 0.5rem 0.75rem;
  font-size: 0.95rem;
  font-family: inherit;
  background: var(--bg-input);
  color: var(--text);
  border: 1px solid var(--border-mid);
  outline: none;
  transition: border-color 0.1s;
}

.field input:focus {
  border-color: var(--text);
}

button[type="submit"] {
  width: 100%;
  padding: 0.6rem 1rem;
  font-size: 0.95rem;
  font-family: inherit;
  font-weight: bold;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--text);
  cursor: pointer;
  margin-top: 0.5rem;
  transition: background 0.1s, color 0.1s;
}

button[type="submit"]:hover {
  background: var(--text);
  color: var(--bg);
}

p.error {
  font-size: 0.875rem;
  color: #ff4444;
  margin: 0 0 1rem;
  padding: 0.5rem 0.75rem;
  background: #1a0000;
  border-left: 3px solid #cc2200;
}

/* ── Logout form ─────────────────────────────────────────── */

.logout-form {
  margin-top: 2rem;
}

.logout-form button {
  padding: 0.4rem 0.9rem;
  font-size: 0.875rem;
  font-family: inherit;
  font-weight: bold;
  color: var(--text-dim);
  background: transparent;
  border: 1px solid var(--border-mid);
  cursor: pointer;
  transition: border-color 0.1s, color 0.1s;
}

.logout-form button:hover {
  background: transparent;
  border-color: var(--text);
  color: var(--text);
}

/* ── Restricted intro ───────────────────────────────────── */

.restricted-intro {
  font-size: 0.875rem;
}

/* ── Tabs ───────────────────────────────────────────────── */

.tabs {
  display: flex;
  border-bottom: 1px solid var(--border-mid);
  margin-bottom: 1rem;
}

.tab {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-dim);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: bold;
  padding: 0.5rem 1rem;
  cursor: pointer;
  margin-bottom: -1px;
  transition: color 0.1s, border-color 0.1s;
}

.tab:hover {
  color: var(--text);
}

.tab.active {
  color: var(--text-bright);
  border-bottom-color: var(--text);
}

.tab-panels {
  margin-bottom: 1.5rem;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

/* ── Access banner ───────────────────────────────────────── */

.access-banner {
  background: #001a0a;
  border-left: 3px solid var(--border-mid);
  padding: 0.75rem 1rem;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  color: var(--text-dim);
}

.access-banner p {
  margin: 0;
}

.access-banner.final {
  background: #1a0000;
  border-left-color: #cc2200;
  color: #ff4444;
}
