:root {
  color-scheme: light;
  --ink: #20261f;
  --muted: #5e6658;
  --paper: #f7f2e6;
  --panel: #fffaf0;
  --line: #d9ccb0;
  --jade: #315d4a;
  --jade-deep: #234337;
  --seal: #9a4b33;
  --gold: #b58a42;
  --error-bg: #f8dfd7;
  --quiet-bg: #efe7d4;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 0, rgba(181, 138, 66, 0.18), transparent 360px),
    linear-gradient(180deg, rgba(154, 75, 51, 0.12), transparent 180px),
    var(--paper);
  color: var(--ink);
}

a {
  color: var(--jade);
}

.shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 16px;
}

.auth-panel {
  width: min(100%, 400px);
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 20px 50px rgba(55, 44, 23, 0.12);
}

.masthead {
  position: relative;
  padding-bottom: 20px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.hub-logo {
  width: 56px;
  height: 56px;
  margin-bottom: 16px;
  border-radius: 8px;
  object-fit: cover;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--seal);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 30px;
  line-height: 1.15;
}

.form-stack,
.password-box {
  display: grid;
  gap: 14px;
}

.login-page .shell {
  padding-block: 40px;
}

.login-panel {
  overflow: hidden;
}

.login-lead {
  margin: -4px 0 18px;
  color: var(--muted);
  line-height: 1.5;
}

.login-form-frame {
  border: 1px solid rgba(217, 204, 176, 0.92);
  border-radius: 8px;
  padding: 16px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(255, 250, 240, 0.64));
}

label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  padding: 10px 12px;
  font: inherit;
}

input:focus {
  outline: 2px solid rgba(49, 93, 74, 0.25);
  border-color: var(--jade);
}

button,
.button-link {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 6px;
  background: var(--jade);
  color: #fff;
  cursor: pointer;
  padding: 10px 14px;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
}

button:hover,
.button-link:hover {
  background: var(--jade-deep);
}

button.secondary {
  width: 100%;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--jade);
}

.support-links {
  display: grid;
  gap: 10px;
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
}

.login-support {
  padding-top: 16px;
  border-top: 1px solid rgba(217, 204, 176, 0.8);
}

.support-links p,
.helper,
.home-intro {
  margin: 0;
  color: var(--muted);
}

.helper {
  font-size: 13px;
  line-height: 1.45;
}

.message {
  margin: 0 0 16px;
  border-radius: 6px;
  padding: 11px 12px;
  line-height: 1.4;
}

.message.error {
  background: var(--error-bg);
  color: #6f271a;
}

.message.quiet {
  background: var(--quiet-bg);
}

.password-box label {
  color: var(--ink);
}

.password-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.password-row input {
  font-family: Consolas, "Courier New", monospace;
  font-size: 18px;
}

.copy-status {
  min-height: 20px;
  margin: 0;
  color: var(--seal);
  font-weight: 700;
}

.button-link {
  width: 100%;
  margin-top: 14px;
}

.disabled {
  opacity: 0.4;
  pointer-events: none;
}

.app-list {
  display: grid;
  gap: 10px;
  margin: 18px 0;
}

.app-link {
  display: grid;
  gap: 4px;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 12px;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
}

.app-link strong {
  color: var(--jade);
}

.app-link span {
  color: var(--muted);
  font-size: 13px;
}

.logout-form {
  margin-top: 18px;
}

@media (max-width: 440px) {
  .auth-panel {
    padding: 22px;
  }

  h1 {
    font-size: 26px;
  }

  .password-row {
    grid-template-columns: 1fr;
  }
}
