/* ── Auth pages (login / register / reset) ──────────────────────────────────
   Standalone styling for the public auth screens. Reuses the same color tokens
   and gradient language as styles.css so the app feels continuous. */
:root {
  --primary-color: #ff0000;
  --primary-dark: #cc0000;
  --bg-light: #f9f9f9;
  --text-dark: #030303;
  --text-gray: #606060;
  --border-color: #ddd;
  --success-color: #2ecc71;
  --error-color: #e74c3c;
}

* { box-sizing: border-box; }

body.auth-body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
  color: var(--text-dark);
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  padding: 36px 32px;
}

.auth-brand {
  text-align: center;
  margin-bottom: 8px;
}
.auth-brand h1 {
  margin: 0;
  font-size: 1.6rem;
}
.auth-brand .tagline {
  margin: 4px 0 0;
  color: var(--text-gray);
  font-size: 0.9rem;
}

.auth-card h2 {
  margin: 24px 0 4px;
  font-size: 1.25rem;
}
.auth-sub {
  margin: 0 0 20px;
  color: var(--text-gray);
  font-size: 0.92rem;
}

.auth-field { margin-bottom: 16px; }
.auth-field label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 0.9rem;
}
.auth-field input[type="email"],
.auth-field input[type="password"] {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  font-size: 1rem;
  font-family: inherit;
}
.auth-field input:focus {
  outline: none;
  border-color: var(--primary-color);
}

.auth-eula {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 4px 0 18px;
  font-size: 0.88rem;
  color: var(--text-gray);
}
.auth-eula input { margin-top: 3px; }
.auth-eula a { color: var(--primary-color); }

.btn-primary,
.btn-oauth {
  display: block;
  width: 100%;
  padding: 13px 16px;
  border: none;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.btn-primary {
  color: #fff;
  background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
}
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-gray);
  font-size: 0.82rem;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

.oauth-buttons { display: flex; flex-direction: column; gap: 10px; }
.btn-oauth {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: #fff;
  border: 2px solid var(--border-color);
  color: var(--text-dark);
}
.btn-oauth:hover { background: var(--bg-light); }
.btn-oauth.google { border-color: #4285f4; }
.btn-oauth.facebook { border-color: #1877f2; }
.btn-oauth .icon { font-weight: 700; }

.auth-links {
  margin-top: 18px;
  text-align: center;
  font-size: 0.9rem;
}
.auth-links a { color: var(--primary-color); text-decoration: none; }
.auth-links a:hover { text-decoration: underline; }
.auth-links .sep { color: var(--border-color); margin: 0 8px; }

.auth-msg {
  margin: 0 0 16px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 0.9rem;
  display: none;
}
.auth-msg.show { display: block; }
.auth-msg.error { background: #fdecea; color: var(--error-color); border: 1px solid #f5c6cb; }
.auth-msg.success { background: #eafaf1; color: #1e8449; border: 1px solid #abebc6; }

/* Self-hosted image captcha */
.captcha-holder { margin: 4px 0 18px; }
.captcha-box {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}
.captcha-img {
  flex: 1;
  height: 60px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  background: #f4f6f8;
  -webkit-user-select: none;
  user-select: none;
}
.captcha-refresh {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  font-size: 1.3rem;
  line-height: 1;
  color: var(--text-gray);
}
.captcha-refresh:hover { background: var(--bg-light); color: var(--text-dark); }
.captcha-input {
  width: 100%;
  padding: 12px 14px;
  border: 2px solid var(--border-color);
  border-radius: 10px;
  font-size: 1rem;
  font-family: inherit;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.captcha-input:focus { outline: none; border-color: var(--primary-color); }

.auth-hint {
  margin-top: 14px;
  font-size: 0.8rem;
  color: var(--text-gray);
  text-align: center;
}
