/* Relay — login / signup page styles. Uses vars from styles.css */

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

body.auth.dark {
  background: linear-gradient(135deg, #0f1115 0%, #16181c 100%);
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.04);
}

body.dark .auth-card {
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.auth-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 6px;
}

.auth-brand .logo {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--brand);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 20px;
  position: relative;
}

.auth-brand .logo .dot {
  position: absolute;
  right: 6px;
  bottom: 6px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: white;
  opacity: 0.9;
}

.auth-brand .wordmark {
  font-size: 22px;
  font-weight: 700;
  color: var(--brand);
  letter-spacing: -0.3px;
}

.auth-title {
  font-size: 20px;
  font-weight: 600;
  text-align: center;
  margin: 14px 0 4px;
  color: var(--ink);
}

.auth-sub {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 20px;
}

.auth-card form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.auth-field label {
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-2);
}

.inp {
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0 12px;
  font-size: 16px;
  background: var(--panel);
  color: var(--ink);
  width: 100%;
  box-sizing: border-box;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  font-family: inherit;
}

.inp:focus {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}

.inp::placeholder {
  color: var(--muted-2);
}

.auth-btn {
  width: 100%;
  height: 44px;
  background: var(--brand);
  color: white;
  border: none;
  border-radius: 10px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: filter 0.15s, transform 0.05s;
  margin-top: 4px;
  font-family: inherit;
}

.auth-btn:hover { filter: brightness(1.05); }
.auth-btn:active { transform: translateY(1px); }
.auth-btn:disabled { opacity: 0.55; cursor: not-allowed; }

.auth-link {
  color: var(--brand);
  text-decoration: none;
  font-weight: 500;
}
.auth-link:hover { text-decoration: underline; }

.auth-foot {
  margin-top: 16px;
  text-align: center;
  font-size: 13px;
  color: var(--muted);
}

.auth-error {
  background: #fdecea;
  color: #c7453a;
  border: 1px solid #f5c6c0;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 4px;
}
body.dark .auth-error {
  background: #3a1d1b;
  border-color: #5a2a27;
  color: #ff8a80;
}

.auth-success {
  background: #e6f4ea;
  color: #1e7c3a;
  border: 1px solid #b7dfc2;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: 13px;
  margin-bottom: 4px;
}
body.dark .auth-success {
  background: #142b1d;
  border-color: #264a33;
  color: #8ed9a6;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0 6px;
  color: var(--muted);
  font-size: 12px;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

/* mobile */
@media (max-width: 480px) {
  body.auth { padding: 16px; }
  .auth-card { padding: 20px; border-radius: 14px; }
  .auth-title { font-size: 18px; }
}
