:root {
  --bg: #f3f4f6;
  --card: #ffffff;
  --ink: #14151c;
  --muted: #6b7280;
  --placeholder: #9aa0ac;
  --brand: #3b3f9e;
  --brand-strong: #33377f;
  --brand-tint: #ecedfa;
  --border: #d9dbe1;
  --ring: rgba(59, 63, 158, 0.18);
  --ok: #1e7d3c;
  --err: #b3261e;
  --radius: 12px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial,
    sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

.page {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: clamp(1.5rem, 4vw, 4rem) 1.5rem;
}

.layout {
  width: 100%;
  max-width: 1080px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem);
  align-items: start;
}

/* ---------- Left: intro ---------- */
.intro {
  padding-top: 1rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--brand-tint);
  color: var(--brand);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
}

.pill-icon {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

h1 {
  margin: 1.5rem 0 1rem;
  font-size: clamp(2.2rem, 4.5vw, 3.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.05;
}

.lead {
  margin: 0 0 2rem;
  max-width: 30rem;
  color: var(--muted);
  font-size: 1.05rem;
  line-height: 1.55;
}

.features {
  list-style: none;
  margin: 0 0 2rem;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.features li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 1.02rem;
  line-height: 1.4;
  color: #2b2f3a;
}

.check {
  flex: 0 0 auto;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  fill: none;
  stroke: var(--brand);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.signin-card {
  max-width: 30rem;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: #fff;
  padding: 1.25rem 1.35rem;
}

.signin-q {
  margin: 0 0 0.35rem;
  color: var(--muted);
  font-size: 0.98rem;
}

.signin-link {
  color: var(--brand);
  font-weight: 700;
  text-decoration: none;
  font-size: 1rem;
}

.signin-link:hover {
  text-decoration: underline;
}

/* ---------- Right: form card ---------- */
.form-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: clamp(1.5rem, 3vw, 2.5rem);
  box-shadow: 0 12px 40px rgba(16, 24, 40, 0.05);
}

h2 {
  margin: 0 0 0.35rem;
  font-size: 1.6rem;
  font-weight: 700;
}

.sub {
  margin: 0 0 1.75rem;
  color: var(--muted);
  font-size: 1rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
select {
  width: 100%;
  height: 56px;
  padding: 0 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  font-size: 1rem;
  font-family: inherit;
}

input::placeholder {
  color: var(--placeholder);
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 4px var(--ring);
}

/* password reveal */
.input-wrap {
  position: relative;
}

.input-wrap input {
  padding-right: 3rem;
}

.reveal {
  position: absolute;
  top: 50%;
  right: 0.6rem;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 8px;
}

.reveal:hover {
  color: var(--ink);
}

.reveal svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* select chevron */
.select-wrap {
  position: relative;
}

.select-wrap select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 2.75rem;
  cursor: pointer;
}

.chevron {
  position: absolute;
  top: 50%;
  right: 1rem;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  pointer-events: none;
  fill: none;
  stroke: var(--muted);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

small {
  color: var(--muted);
  font-size: 0.85rem;
  padding-left: 0.1rem;
}

/* checkbox */
.check-row {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.95rem;
  line-height: 1.45;
  color: #2b2f3a;
  margin-top: 0.25rem;
}

.check-row input {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin-top: 1px;
  accent-color: var(--brand);
}

/* primary button */
.primary {
  margin-top: 0.5rem;
  height: 54px;
  border: 0;
  border-radius: var(--radius);
  background: var(--brand);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.primary:hover {
  background: var(--brand-strong);
}

.primary:disabled {
  opacity: 0.6;
  cursor: default;
}

.terms {
  margin: 0.25rem 0 0;
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
}

.message {
  margin: 0.25rem 0 0;
  font-size: 0.95rem;
  min-height: 1.2em;
}

.message.error {
  color: var(--err);
}

.message.success {
  color: var(--ok);
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .layout {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    max-width: 32rem;
  }

  .intro {
    padding-top: 0;
  }
}
