/* ── Comsys Prompt Generator – Auth Pages ── */
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@600;700;800&family=DM+Sans:wght@400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #080C14;
  --surface:   #0D1220;
  --surface2:  #111827;
  --border:    #1E2D45;
  --border2:   #253654;
  --cyan:      #00E5FF;
  --cyan-dim:  rgba(0,229,255,.12);
  --violet:    #8B5CF6;
  --violet-dim:rgba(139,92,246,.12);
  --green:     #10B981;
  --red:       #EF4444;
  --text:      #E2E8F0;
  --text-dim:  #94A3B8;
  --text-faint:#475569;
  --radius:    12px;
  --glow:      0 0 30px rgba(0,229,255,.15);
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: 15px;
  line-height: 1.6;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px 16px;
  background-image:
    radial-gradient(ellipse 60% 40% at 50% 0%, rgba(0,229,255,.06) 0%, transparent 70%),
    radial-gradient(ellipse 40% 30% at 80% 80%, rgba(139,92,246,.05) 0%, transparent 60%);
}

/* ── Brand header ── */
.brand {
  text-align: center;
  margin-bottom: 32px;
}
.brand-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--cyan) 0%, var(--violet) 100%);
  margin-bottom: 14px;
  box-shadow: 0 0 24px rgba(0,229,255,.3);
}
.brand-logo svg { width: 28px; height: 28px; fill: #fff; }
.brand h1 {
  font-family: 'Syne', sans-serif;
  font-size: 1.65rem;
  font-weight: 800;
  background: linear-gradient(90deg, var(--cyan) 0%, var(--violet) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.02em;
}
.brand p {
  color: var(--text-dim);
  font-size: .875rem;
  margin-top: 4px;
}

/* ── Card ── */
.card {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  box-shadow: var(--glow), 0 24px 64px rgba(0,0,0,.5);
}
.card h2 {
  font-family: 'Syne', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 24px;
}

/* ── Form elements ── */
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: .8rem;
  font-weight: 600;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: 7px;
}
.field input[type="text"],
.field input[type="email"],
.field input[type="password"] {
  width: 100%;
  background: var(--surface2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: .95rem;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.field input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(0,229,255,.12);
}
.field input::placeholder { color: var(--text-faint); }

/* ── Remember me / extras row ── */
.field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  font-size: .875rem;
}
.field-row label { display: flex; align-items: center; gap: 7px; color: var(--text-dim); cursor: pointer; }
.field-row input[type="checkbox"] { accent-color: var(--cyan); width: 15px; height: 15px; }
.field-row a { color: var(--cyan); text-decoration: none; font-size: .8rem; }
.field-row a:hover { text-decoration: underline; }

/* ── Buttons ── */
.btn {
  display: block;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 8px;
  font-family: 'DM Sans', sans-serif;
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .2s, transform .1s;
}
.btn:active { transform: scale(.98); }
.btn-primary {
  background: linear-gradient(90deg, var(--cyan) 0%, #00B4CC 100%);
  color: #080C14;
}
.btn-primary:hover { opacity: .9; }

/* ── Messages ── */
.msg {
  margin-bottom: 16px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: .875rem;
  display: none;
}
.msg.error   { display: block; background: rgba(239,68,68,.12); border: 1px solid rgba(239,68,68,.3); color: #FCA5A5; }
.msg.success { display: block; background: rgba(16,185,129,.12); border: 1px solid rgba(16,185,129,.3); color: #6EE7B7; }
.msg a { color: inherit; font-weight: 600; }

/* ── Footer link ── */
.card-footer {
  margin-top: 20px;
  text-align: center;
  font-size: .875rem;
  color: var(--text-dim);
}
.card-footer a { color: var(--cyan); text-decoration: none; font-weight: 600; }
.card-footer a:hover { text-decoration: underline; }

/* ── Password field with eye toggle ── */
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 42px; }
.pw-eye {
  position: absolute;
  right: 12px; top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--text-faint);
  display: flex;
  align-items: center;
  transition: color .2s;
}
.pw-eye:hover { color: var(--cyan); }
.pw-eye svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.pw-eye .eye-off { display: none; }
.pw-eye.active .eye-on  { display: none; }
.pw-eye.active .eye-off { display: block; }

/* ── Page title (forgot pw, etc.) ── */
.page-title {
  font-family: 'Syne', sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 8px;
}
.page-desc { color: var(--text-dim); font-size: .875rem; margin-bottom: 24px; }

/* ── Generator nav bar (logged-in strip) ── */
.gen-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 48px;
  background: rgba(8,12,20,.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  z-index: 9999;
}
.gen-nav-brand {
  font-family: 'Syne', sans-serif;
  font-size: .85rem;
  font-weight: 700;
  background: linear-gradient(90deg, var(--cyan), var(--violet));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.gen-nav-right { display: flex; align-items: center; gap: 16px; font-size: .8rem; color: var(--text-dim); }
.gen-nav-right span { font-family: 'JetBrains Mono', monospace; color: var(--cyan); }
.gen-nav-logout {
  padding: 5px 14px;
  border-radius: 6px;
  background: var(--surface2);
  border: 1px solid var(--border2);
  color: var(--text-dim);
  text-decoration: none;
  font-size: .8rem;
  font-weight: 600;
  transition: border-color .2s, color .2s;
}
.gen-nav-logout:hover { border-color: var(--red); color: #FCA5A5; }

@media (max-width: 480px) {
  .card { padding: 24px 20px; }
}
