*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --purple: #5b4ef8;
  --purple-dark: #4338e0;
  --purple-bg: #eeeefe;
  --gray-light: #f3f4f8;
  --gray-text: #6b7280;
  --border: #e5e7eb;
  --dark: #111827;
  --white: #fff;
}

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--gray-light);
  color: var(--dark);
  min-height: 100vh;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  font-family: inherit;
  cursor: pointer;
}

/* ── NAV ─────────────────────────────────── */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 0, 0, .07);
  height: 64px;
  display: flex;
  align-items: center;
  padding: 0 40px;
}

.nav-inner {
  width: 100%;
  max-width: 1280px;
  margin: auto;
  display: flex;
  align-items: center;
  gap: 40px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 1.1rem;
  cursor: pointer;
}

.logo-icon {
  width: 34px;
  height: 34px;
  background: var(--purple);
  border-radius: 8px;
  display: grid;
  place-items: center;
}

.nav-links {
  display: flex;
  gap: 28px;
  list-style: none;
  font-size: .9rem;
  color: #444;
  margin-left: 20px;
}

.nav-links a {
  transition: color .15s;
}

.nav-links a:hover {
  color: var(--purple);
}

.nav-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-ghost {
  background: none;
  border: none;
  font-size: .9rem;
  color: var(--purple);
  font-weight: 600;
  padding: 8px 14px;
}

.btn-purple {
  background: var(--purple);
  color: white;
  border: none;
  border-radius: 10px;
  padding: 9px 20px;
  font-size: .9rem;
  font-weight: 600;
  transition: background .2s;
}

.btn-purple:hover {
  background: var(--purple-dark);
}

/* ── SPLIT LAYOUT ────────────────────────── */
.signin-layout {
  padding-top: 64px;
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

/* ── LEFT PANEL ──────────────────────────── */
.left-panel {
  background: linear-gradient(160deg, #5b4ef8 0%, #3730b8 55%, #4f6ef7 100%);
  padding: 70px 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: calc(100vh - 64px);
  position: relative;
  overflow: hidden;
}

.left-panel::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -80px;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(255, 255, 255, .08) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.left-panel::after {
  content: '';
  position: absolute;
  bottom: -60px;
  left: -60px;
  width: 280px;
  height: 280px;
  background: radial-gradient(circle, rgba(255, 255, 255, .06) 0%, transparent 70%);
  border-radius: 50%;
  pointer-events: none;
}

.lp-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 56px;
}

.lp-brand-icon {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, .18);
  border-radius: 11px;
  display: grid;
  place-items: center;
}

.lp-brand-icon svg {
  width: 22px;
  height: 22px;
  color: white;
}

.lp-brand span {
  font-size: 1.3rem;
  font-weight: 800;
  color: white;
}

.lp-heading {
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 800;
  color: white;
  line-height: 1.2;
  margin-bottom: 18px;
}

.lp-sub {
  color: rgba(255, 255, 255, .8);
  font-size: .97rem;
  line-height: 1.7;
  max-width: 380px;
  margin-bottom: 44px;
}

.lp-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.lp-features li {
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(255, 255, 255, .88);
  font-size: .95rem;
}

.lp-features li .dot {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  background: rgba(255, 255, 255, .6);
  border-radius: 50%;
}

/* ── RIGHT PANEL ─────────────────────────── */
.right-panel {
  background: var(--gray-light);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 40px;
}

.signin-box {
  width: 100%;
  max-width: 520px;
}

.signin-box h1 {
  font-size: 1.9rem;
  font-weight: 800;
  margin-bottom: 6px;
}

.signin-box>p {
  font-size: .9rem;
  color: var(--gray-text);
  margin-bottom: 28px;
}

/* Form */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-size: .875rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.form-group input {
  width: 100%;
  height: 50px;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 0 16px;
  font-family: inherit;
  font-size: .9rem;
  color: var(--dark);
  background: white;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}

.form-group input:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(91, 78, 248, .1);
}

.form-group input::placeholder {
  color: #adb5bd;
}

.form-group input.error {
  border-color: #ef4444;
}

.password-wrap {
  position: relative;
}

.password-wrap input {
  padding-right: 50px;
}

.toggle-pw {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #9ca3af;
  display: grid;
  place-items: center;
  transition: color .2s;
}

.toggle-pw:hover {
  color: var(--purple);
}

.toggle-pw svg {
  width: 18px;
  height: 18px;
}

.err-msg {
  font-size: .78rem;
  color: #ef4444;
  margin-top: 5px;
  display: none;
}

.has-error .err-msg {
  display: block;
}

.forgot-row {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  margin-top: -10px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.forgot-row span {
  font-size: .82rem;
  color: var(--gray-text);
}

.forgot-row a {
  font-size: .82rem;
  color: var(--purple);
  font-weight: 600;
}

.forgot-row a:hover {
  text-decoration: underline;
}

.forgot-row-secondary {
  margin-top: -12px;
}

.btn-signin {
  width: 100%;
  height: 52px;
  background: var(--purple);
  color: white;
  border: none;
  border-radius: 11px;
  font-size: 1rem;
  font-weight: 700;
  transition: background .2s, transform .15s;
  margin-bottom: 20px;
}

.btn-signin:hover {
  background: var(--purple-dark);
  transform: translateY(-1px);
}

.register-prompt {
  text-align: center;
  font-size: .875rem;
  color: var(--gray-text);
}

.register-prompt a {
  color: var(--purple);
  font-weight: 700;
}
