:root {
  --navy: #161950;
  --blue: #465fff;
  --blue-dark: #3641f5;
  --text: #1d2939;
  --muted: #667085;
  --border: #d0d5dd;
  --field: #f2f4f7;
  --error: #d92d20;
  --ok: #027a48;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Outfit", system-ui, sans-serif;
  color: var(--text);
  background: #fff;
}

.split { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; }

.form-side { display: flex; align-items: center; justify-content: center; padding: 32px 24px; }
.form-wrap { width: 100%; max-width: 448px; }

h1 { margin: 0 0 8px; font-size: 36px; font-weight: 600; }
.subtitle { margin: 0 0 32px; color: var(--muted); font-size: 14px; }

label { display: block; margin: 20px 0 8px; font-size: 14px; font-weight: 500; }
.req { color: var(--error); margin-left: 2px; }

input[type="email"], input[type="password"], input[type="text"] {
  width: 100%;
  height: 44px;
  padding: 0 16px;
  font: inherit;
  font-size: 14px;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input:focus { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(70, 95, 255, .12); }

.pw { position: relative; }
.pw input { padding-right: 48px; }
.pw button {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; display: grid; place-items: center;
  color: var(--muted); background: none; border: 0; border-radius: 6px; cursor: pointer;
}
.pw button:hover { color: var(--text); }

.row { display: flex; align-items: center; justify-content: space-between; margin: 20px 0 24px; font-size: 14px; }
.row a, .switch a { color: var(--blue); text-decoration: none; }
.row a:hover, .switch a:hover { text-decoration: underline; }
.check { display: flex; align-items: center; gap: 10px; margin: 0; font-weight: 400; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--blue); }

.msg { margin: 0 0 16px; padding: 10px 14px; font-size: 14px; border-radius: 8px; background: #fef3f2; color: var(--error); }
.msg.ok { background: #ecfdf3; color: var(--ok); }

.primary {
  width: 100%; height: 44px;
  font: inherit; font-size: 14px; font-weight: 600; color: #fff;
  background: var(--blue); border: 0; border-radius: 8px; cursor: pointer;
  transition: background .15s;
}
.primary:hover { background: var(--blue-dark); }
.primary:disabled { opacity: .6; cursor: default; }

.switch { margin: 24px 0 0; font-size: 14px; }

.brand-side {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 32px; color: #fff; background: var(--navy);
}
.brand-side::before, .brand-side::after {
  content: ""; position: absolute; width: 520px; height: 260px;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(135deg, #000, transparent 70%);
  -webkit-mask-image: linear-gradient(135deg, #000, transparent 70%);
}
.brand-side::before { top: 0; right: 0; }
.brand-side::after { bottom: 0; left: 0; transform: rotate(180deg); }

.brand { position: relative; display: flex; align-items: center; gap: 16px; }
.logo { display: grid; place-items: center; width: 48px; height: 48px; background: var(--blue); border-radius: 12px; }
.brand-name { font-size: 36px; font-weight: 600; }
.tagline { position: relative; max-width: 320px; margin: 16px 0 0; text-align: center; color: #98a2b3; font-size: 16px; }

@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; }
  .brand-side { display: none; }
}
