/* Palette and type come from tokens.css + design-system.css aliases. */

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

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  color: var(--text);
  background-color: var(--background);
  -webkit-font-smoothing: antialiased;
}

.auth-layout {
  display: flex;
  width: 100vw;
  height: 100vh;
}

.auth-brand-panel {
  position: relative;
  overflow: hidden;
  flex: 1;
  background-color: #f4f6f8;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 64px 80px;
}

.auth-brand-panel > *:not(.finish) {
  position: relative;
  z-index: 1;
}

.auth-brand-panel .logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-heading);
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.5px;
}

.auth-layout-brand .logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-brand-panel .logo img,
.auth-layout-brand .logo img {
  width: 40px;
  height: 40px;
  border-radius: 8px;
}

.auth-brand-panel .logo img.logo-lockup {
  width: auto;
  height: 40px;
  border-radius: 0;
}

.auth-brand-panel .brand-content {
  margin: auto 0;
  max-width: 520px;
}

.auth-brand-panel .hero-text {
  font-family: var(--font-heading);
  font-size: 56px;
  font-weight: 700;
  line-height: 1.1;
  color: var(--text);
  margin: 0 0 24px 0;
  letter-spacing: -2px;
  max-width: 480px;
}

.auth-brand-panel .sub-text {
  font-size: 18px;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 0;
  max-width: 420px;
}

.auth-form-panel {
  position: relative;
  overflow: hidden;
  flex: 1;
  background-color: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
}

.finish {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.finish img {
  position: absolute;
  width: 112px;
  height: 112px;
  object-fit: contain;
  opacity: 0.22;
}

.auth-brand-panel .mark-ai {
  top: 36px;
  right: 40px;
}

.auth-brand-panel .mark-growth {
  left: 40px;
  bottom: 36px;
}

.auth-form-panel .mark-code {
  top: 36px;
  right: 40px;
}

.auth-form-panel .mark-chip {
  left: 40px;
  bottom: 40px;
}

.auth-form-panel > *:not(.finish) {
  position: relative;
  z-index: 1;
}

.login-form {
  width: 480px;
  display: flex;
  flex-direction: column;
}

.form-header {
  margin-bottom: 40px;
}

.form-header h2 {
  font-family: var(--font-heading);
  font-size: 32px;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: var(--text);
  letter-spacing: -1px;
}

.form-header p {
  font-size: 16px;
  color: var(--text-muted);
  margin: 0;
}

.form-group {
  display: flex;
  flex-direction: column;
  margin-bottom: 24px;
}

.form-group label {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 8px;
}

.label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}

.label-row label {
  margin-bottom: 0;
}

.forgot-link {
  font-size: 13px;
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

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

input[type="email"],
input[type="password"] {
  width: 100%;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0 12px;
  font-family: inherit;
  font-size: 14px;
  color: var(--text);
  background-color: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
}

input[type="email"]:focus,
input[type="password"]:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

input::placeholder {
  color: #9CA3AF;
}

button[type="submit"] {
  width: 100%;
  height: var(--rv-button-height);
  background-color: var(--primary);
  color: var(--surface);
  border: none;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color var(--rv-motion-fast);
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

button[type="submit"]:hover {
  background-color: var(--primary-hover);
}

.form-footer {
  margin-top: 32px;
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
}

.form-footer a {
  color: var(--primary);
  text-decoration: none;
  font-weight: 500;
}

.form-footer a:hover {
  text-decoration: underline;
}
