:root {
  --color-primary: #4f46e5;
  --color-primary-hover: #4338ca;
  --color-bg: #f8fafc;
  --color-surface: #ffffff;
  --color-text: #111827;
  --color-muted: #6b7280;
  --color-border: #e5e7eb;
  --color-error: #ef4444;
  --radius: 0.75rem;
  --shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  position: relative;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: #0b1221;
  color: var(--color-text);
  min-height: 100vh;
  display: block;
}

body.auth-center {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.auth-page {
  width: 100%;
  max-width: 440px;
  padding: 1.5rem;
}

.language-selector {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  color: var(--color-muted);
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.auth-card {
  background: var(--color-surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2.5rem;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.brand-logo {
  color: var(--color-primary);
  width: 48px;
  height: 48px;
}

.brand h1 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text);
}

.auth-title {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
  text-align: center;
}

.auth-subtitle {
  margin: 0.5rem 0 1.5rem;
  color: var(--color-muted);
  text-align: center;
  font-size: 0.9375rem;
}

.auth-subtitle.auth-success {
  color: var(--color-success, #10b981);
}

.auth-subtitle.auth-error {
  color: var(--color-danger, #ef4444);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 0.875rem;
  color: var(--color-muted);
  pointer-events: none;
}

.input-suffix {
  position: absolute;
  right: 0.875rem;
  color: var(--color-muted);
  display: flex;
  align-items: center;
}

.input-wrapper input {
  width: 100%;
  padding: 0.75rem 2.75rem;
  border: 1px solid var(--color-border);
  border-radius: 0.5rem;
  font-size: 0.9375rem;
  color: var(--color-text);
  background: var(--color-surface);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.input-wrapper input:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.input-wrapper input::placeholder {
  color: #9ca3af;
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.875rem;
}

.remember {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--color-text);
  cursor: pointer;
}

.remember input[type="checkbox"] {
  width: 1rem;
  height: 1rem;
  accent-color: var(--color-primary);
}

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

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.875rem 1.25rem;
  border: none;
  border-radius: 0.5rem;
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.15s;
}

.btn-primary {
  background: var(--color-primary);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--color-primary-hover);
}

.auth-footer {
  margin: 1.5rem 0 0;
  text-align: center;
  font-size: 0.875rem;
  color: var(--color-muted);
}

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

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

.split-auth {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

.split-left {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: linear-gradient(160deg, #0f172a 0%, #1e3a8a 100%);
  color: #ffffff;
  padding: 3rem;
  overflow-y: auto;
}

.split-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: var(--color-bg);
  padding: 1.5rem;
}

.left-top {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.left-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  text-align: center;
}

.left-brand h1 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 700;
}

.left-logo {
  width: 80px;
  height: 80px;
}

img.left-logo {
  height: 80px;
  width: auto;
  object-fit: contain;
}

.brand-logo {
  color: #4f46e5;
  width: 48px;
  height: 48px;
}

img.brand-logo {
  height: 48px;
  width: auto;
  object-fit: contain;
}

.left-tagline {
  margin: 0;
  font-size: 1.125rem;
  color: #cbd5e1;
  max-width: 420px;
}

.preview-card {
  background: #f8fafc;
  color: #111827;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 20px 50px -15px rgba(0, 0, 0, 0.3);
  max-width: 480px;
}

.preview-card h2 {
  margin: 0 0 1rem;
  font-size: 1.125rem;
  font-weight: 700;
}

.stats-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.stat-box {
  flex: 1;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 0.75rem;
}

.stat-label {
  display: block;
  font-size: 0.6875rem;
  color: #6b7280;
  margin-bottom: 0.25rem;
}

.stat-value {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  color: #111827;
}

.mini-chart {
  height: 80px;
  margin-bottom: 1.25rem;
}

.mini-chart svg {
  width: 100%;
  height: 100%;
}

.mini-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mini-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e5e7eb;
}

.mini-row:last-child {
  border-bottom: none;
}

.mini-product {
  color: #374151;
}

.mini-number {
  font-weight: 600;
  color: #111827;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.feature-card {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.feature-icon-wrap {
  width: 2.75rem;
  height: 2.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(79, 70, 229, 0.18);
  border-radius: 0.5rem;
}

.feature-icon {
  color: #ffffff;
  width: 24px;
  height: 24px;
}

.feature-card h3 {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
}

.feature-card p {
  margin: 0;
  font-size: 0.8125rem;
  color: #94a3b8;
  line-height: 1.4;
}

.globe-icon {
  width: 16px;
  height: 16px;
}

@media (max-width: 900px) {
  .split-auth {
    flex-direction: column;
  }

  .split-left {
    display: none;
  }

  .split-right {
    min-height: 100vh;
  }
}

@media (max-width: 480px) {
  .auth-page {
    max-width: 100%;
    padding: 0.5rem;
  }

  .auth-card {
    padding: 1.25rem;
  }
}
