/* Shared styles for the auth pages (signup, account, reset, verify).
   Dark palette mirrors public_login/styles/main.css so the user lands on
   visually consistent pages from one to the next. */

:root {
  --bg: #1a1a2e;
  --bg-raised: #16213e;
  --bg-input: #222;
  --bg-card: #1f1f2e;
  --border: #2a2a45;
  --border-strong: #3a3a4a;
  --text: #ccc;
  --text-dim: #777;
  --text-bright: #fff;
  --accent: #007BFF;
  --accent-hover: #0069d9;
  --danger: #ff6b6b;
  --warn: #d4a017;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  background-image: radial-gradient(ellipse at top, var(--bg-raised) 0%, var(--bg) 70%);
  line-height: 1.4;
  min-height: 100vh;
}

#authShell {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#authBox, .done-box, .auth-box {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 32px 36px 28px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2), 0 16px 48px rgba(0,0,0,0.4);
  position: relative;
}

#authBack {
  position: absolute;
  top: 14px;
  left: 16px;
  font-size: 18px;
  text-decoration: none;
  color: var(--text-dim);
  width: 28px; height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
}
#authBack:hover { background: var(--bg-input); color: var(--text-bright); }

#authLogo {
  display: block;
  margin: 4px auto 12px;
  width: 56px;
  height: 56px;
  object-fit: contain;
}
h1 {
  font-size: 22px;
  margin: 0 0 4px;
  text-align: center;
  letter-spacing: -0.005em;
  color: var(--text-bright);
  font-weight: 600;
}
h2 {
  font-size: 20px;
  margin: 0 0 12px;
  text-align: center;
  color: var(--text-bright);
  font-weight: 600;
}
.subline {
  text-align: center;
  color: var(--text-dim);
  font-size: 13px;
  margin: 0 0 24px;
}

label {
  display: block;
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  margin-bottom: 14px;
}
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

input[type=text], input[type=email], input[type=password] {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 9px 12px;
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-bright);
  background: #2a2a3a;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
input::placeholder { color: var(--text-dim); }
input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(0,123,255,0.2);
}

.hint {
  display: block;
  font-size: 12px;
  color: var(--text-dim);
  margin-top: 4px;
  font-weight: normal;
}

label.check {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  font-weight: normal;
  margin-bottom: 18px;
  color: var(--text);
}
label.check input { margin-top: 2px; flex-shrink: 0; }
label.check a { color: var(--accent); }

button[type=submit], .btn {
  display: block;
  width: 100%;
  padding: 10px 14px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.12s ease;
}
button[type=submit]:hover, .btn:hover { background: var(--accent-hover); }
button[type=submit]:disabled { opacity: 0.5; cursor: wait; }

.error {
  min-height: 20px;
  font-size: 13px;
  color: var(--danger);
  margin-top: 12px;
  text-align: center;
}

.footnote {
  margin: 18px 0 0;
  font-size: 13px;
  text-align: center;
  color: var(--text-dim);
}
.footnote a { color: var(--accent); text-decoration: none; }
.footnote a:hover { text-decoration: underline; }
.footnote.error { color: var(--danger); }

.done-box {
  text-align: center;
}
.done-box h2 { margin-top: 0; }
.done-box .dim { color: var(--text-dim); font-size: 13px; }
.done-box #doneEmail { font-weight: 600; color: var(--text-bright); }
.btn-link {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border-strong);
  border-radius: 6px;
  color: var(--text);
  text-decoration: none;
  font-size: 13px;
}
.btn-link:hover { background: #2a2a3a; color: var(--text-bright); }

/* Sign-up-with-Google button + the "or" divider beneath it. Mirrors
   the login-page styling so the auth flow looks consistent. */
.signupGoogle {
  display: flex; align-items: center; justify-content: center;
  gap: 10px;
  padding: 10px 14px;
  background: #fff;
  color: #1f1f1f;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  font-family: inherit;
  cursor: pointer;
  margin-bottom: 4px;
  transition: background 0.12s ease;
}
.signupGoogle:hover { background: #f4f4f4; }
.signupGoogle svg { display: block; }
.signupOrSep {
  display: flex; align-items: center; gap: 8px;
  margin: 14px 0 18px;
  color: var(--text-dim); font-size: 11px;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.signupOrSep::before,
.signupOrSep::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--border-strong);
  height: 0;
}

@media (max-width: 540px) {
  #authBox, .done-box, .auth-box { padding: 24px 20px; }
  .row { grid-template-columns: 1fr; }
}
