:root {
  --navy: #1B2B45;
  --navy-2: #163056;
  --navy-soft: #29478D;
  --gold: #E0A100;
  --ivory: #F6F4EE;
  --ivory-2: #FBF9F4;
  --ink: #142033;
  --muted: #5b677a;
  --line: #e4ddd0;
  --card: #FFFEFA;
  --err: #b42318;
  --ok: #0f6b4c;
  --shadow: 0 18px 50px rgba(27, 43, 69, 0.10);
  --radius: 18px;
  font-family: "Segoe UI", "Aptos", "Liberation Sans", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; color: var(--ink); background: var(--ivory); }
body { position: relative; }

.bg {
  position: fixed; inset: 0; z-index: -1;
  background:
    radial-gradient(900px 420px at 8% -8%, rgba(27,43,69,.10), transparent 58%),
    radial-gradient(720px 360px at 100% 0%, rgba(224,161,0,.12), transparent 55%),
    linear-gradient(180deg, #F6F4EE 0%, #FBF9F4 48%, #F3EFE6 100%);
}

.shell {
  width: min(820px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 22px;
}
.brand { display: inline-flex; align-items: center; text-decoration: none; }
.logo {
  height: 52px; width: auto; display: block;
  background: transparent;
}
.top-meta { display: flex; gap: 12px; align-items: center; }
.pill {
  display: inline-flex; align-items: center;
  background: rgba(27,43,69,.08); color: var(--navy);
  border: 1px solid rgba(27,43,69,.12);
  border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 600;
}

.card {
  background: var(--card);
  border: 1px solid rgba(27,43,69,.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
  margin-bottom: 16px;
}
.card.muted {
  box-shadow: none;
  background: rgba(255, 254, 250, 0.72);
  border-color: rgba(228, 221, 208, 0.9);
}
.card-head {
  display: flex; justify-content: space-between; gap: 16px; align-items: flex-start;
  margin-bottom: 8px;
}
.badge {
  flex: 0 0 auto;
  background: var(--navy);
  color: white;
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .02em;
}

h1 { margin: 0 0 8px; font-size: 28px; letter-spacing: -0.02em; color: var(--navy); }
h2 { margin: 0 0 10px; font-size: 16px; color: var(--navy); }
.sub { margin: 0 0 18px; color: var(--muted); line-height: 1.5; }
.optional { font-weight: 500; color: var(--muted); font-size: 12px; }

.stack { display: grid; gap: 14px; }
.grid2 { display: grid; gap: 14px; grid-template-columns: 1fr 1fr; }
@media (max-width: 640px) {
  .grid2 { grid-template-columns: 1fr; }
  .card-head { flex-direction: column; }
}

label {
  display: grid; gap: 7px;
  font-size: 13px; font-weight: 600; color: var(--navy);
}
input[type="text"], input[type="password"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 16px;
  color: var(--ink);
  background: #FFFEFA;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input:focus {
  border-color: rgba(27,43,69,.45);
  box-shadow: 0 0 0 4px rgba(224,161,0,.18);
}
.check {
  display: flex; align-items: flex-start; gap: 10px;
  font-weight: 500; color: var(--ink);
}
.check input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--navy); }
.actions { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }

button.primary {
  appearance: none; border: 0; cursor: pointer;
  background: linear-gradient(180deg, #243A5C 0%, var(--navy) 100%);
  color: white; font-weight: 700; font-size: 15px;
  border-radius: 12px; padding: 13px 18px;
  box-shadow: 0 10px 24px rgba(27,43,69,.20);
}
button.primary:hover { filter: brightness(1.05); }
button.primary:disabled { opacity: .65; cursor: wait; }
button.linkish {
  border: 0; background: transparent; color: var(--muted);
  cursor: pointer; font-weight: 600; font-size: 13px;
}
button.linkish:hover { color: var(--navy); }

.error { color: var(--err); margin: 0; font-size: 14px; }
.status { color: var(--muted); font-size: 14px; }
.status.ok { color: var(--ok); font-weight: 600; }
.hidden { display: none !important; }

ul { margin: 0; padding-left: 18px; color: var(--muted); line-height: 1.55; }
code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px; background: #F0EBE1; padding: 2px 6px; border-radius: 6px;
  color: var(--navy);
}
footer {
  margin-top: 18px; color: var(--muted); font-size: 12px; text-align: center;
}
