* {
  box-sizing: border-box;
}
html, body {
  padding: 0;
  margin: 0;
  min-width: 320px;
}
body {
  background: #f1f5f9;
  font-family: "Inter", "Open Sans", "Helvetica Neue", sans-serif;
  font-size: 16px;
  line-height: 26px;
  color: #111;
}
a {
  color: #6366f1;
  text-decoration-color: #c7d2fe;
}
a:hover {
  color: #4338ca;
}
label {
  cursor: pointer;
  color: #374151;
  font-size: 0.875em;
  font-weight: 500;
}
h1,
h2,
h3,
h4 {
  font-weight: 600;
}
.section {
  margin-bottom: 45px;
}

input[type="text"], input[type="email"], input[type="password"], select {
  padding: 10px 14px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  width: 100%;
  font-size: 1em;
  background: #fff;
  color: #111;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}
input:focus, select:focus {
  border-color: #6366f1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

input:focus::placeholder {
  color: transparent;
}

input[disabled] {
  opacity: 0.5;
}

.center {
  text-align: center;
}
.right {
  text-align: right;
}
.small {
  font-size: 0.875em;
}
.error {
  color: #dc2626;
}
.button {
  background: #6366f1;
  padding: 11px 24px;
  border-radius: 8px;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 150px;
  font-size: 0.975em;
  font-weight: 500;
  text-align: center;
  transition: background 0.15s, box-shadow 0.15s;
}
.button:hover {
  background: #4f46e5;
  color: #fff;
}
.button:active {
  background: #4338ca;
}
.button.button-outline {
  background: #fff;
  border: 1px solid #d1d5db;
  color: #374151;
}
.button.button-outline:hover {
  border-color: #6366f1;
  color: #6366f1;
  background: #eef2ff;
}

.container {
  margin: 60px auto 15px auto;
  max-width: 460px;
}

.wrap {
  background: #fff;
  padding: 40px;
  box-shadow: 0 1px 3px rgba(0,0,0,.08), 0 4px 16px rgba(0,0,0,.06);
  border-radius: 16px;
}

.header {
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 20px;
  margin-bottom: 28px;
}
.header .logo img {
  width: auto;
  max-width: 140px;
}

/* ── Login page ─────────────────────────────────────── */
.login h2 {
  margin: 0 0 6px 0;
  font-size: 1.35em;
  color: #111827;
}

.login-subtitle {
  margin: 0 0 24px 0;
  color: #6b7280;
  font-size: 0.9em;
  line-height: 1.5;
}

.login .field {
  margin-bottom: 18px;
}
.login .field label {
  display: block;
  margin-bottom: 6px;
}

/* password with reveal toggle */
.password-wrap {
  position: relative;
}
.password-wrap input {
  padding-right: 44px;
}
.password-toggle {
  position: absolute;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: 8px 10px;
  cursor: pointer;
  color: #9ca3af;
  display: flex;
  align-items: center;
  border-radius: 6px;
  transition: color 0.15s;
}
.password-toggle:hover {
  color: #6366f1;
}
.eye-icon {
  width: 18px;
  height: 18px;
  display: block;
}

.login .submit {
  margin-top: 24px;
}
.login .submit .button {
  width: 100%;
  padding: 12px;
}
.login button img {
  max-width: 20px;
}
.login input[name=totp_code] {
  font-size: 2em;
  letter-spacing: 5px;
  text-align: center;
}

.form-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.875em;
  margin: 12px 0 0 0;
}

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: #9ca3af;
  font-size: 0.8em;
}
.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e5e7eb;
}

.forgot-link {
  margin-top: 20px;
  color: #9ca3af;
}
.forgot-link a {
  color: #6366f1;
}

/* ── Other public pages ─────────────────────────────── */
.unsub-all {
  margin-top: 30px;
  padding-top: 30px;
  border-top: 1px solid #e5e7eb;
}

.row {
  margin-bottom: 20px;
}
.lists {
  list-style-type: none;
  padding: 0;
}
  .lists li {
    margin: 0 0 5px 0;
  }
  .lists .description {
    margin: 0 0 15px 0;
    font-size: 0.875em;
    line-height: 1.3rem;
    color: #888;
    margin-left: 25px;
  }
  .form .nonce {
    display: none;
  }
  .form .captcha {
    margin-top: 30px;
  }

.archive {
  list-style-type: none;
  margin: 25px 0 0 0;
  padding: 0;
}
  .archive .date {
    display: block;
    color: #666;
    font-size: 0.875em;
  }
  .archive li {
    margin-bottom: 15px;
  }
  .feed {
    margin-right: 15px;
  }

.home-options {
  margin-top: 30px;
}
  .home-options a {
    margin: 0 7px;
  }

.pagination {
  margin-top: 30px;
  text-align: center;
}
  .pg-page {
    display: inline-block;
    padding: 0 10px;
    text-decoration: none;
  }
  .pg-page.pg-selected {
    text-decoration: underline;
    font-weight: bold;
  }

footer.container {
  text-align: center;
  color: #9ca3af;
  font-size: 0.775em;
  margin-top: 20px;
  margin-bottom: 30px;
}
  footer a {
    color: #9ca3af;
    text-decoration: none;
  }
  footer a:hover {
    color: #6366f1;
  }

@media screen and (max-width: 520px) {
  .container {
    margin: 0 auto;
    max-width: 100%;
  }
  .wrap {
    border-radius: 0;
    padding: 28px 24px;
    box-shadow: none;
  }
}
