@import url("https://fonts.googleapis.com/css2?family=Fraunces:wght@500;600;700&family=Sora:wght@400;500;600;700&display=swap");

:root {
  color-scheme: light;
  --bg: #f2f5fa;
  --surface: #ffffff;
  --card: #ffffff;
  --text: #0f1b2d;
  --muted: #5b6d83;
  --border: #e4ecf5;
  --border-strong: #d5deea;
  --shadow-soft: 0 18px 42px rgba(15, 23, 42, 0.08);
  --shadow-mid: 0 12px 28px rgba(15, 23, 42, 0.12);
  --btn: #16a34a;
  --btn-strong: #15803d;
  --btn-glow: rgba(22, 163, 74, 0.28);
  --accent: #2f6fe1;
  --accent-soft: rgba(47, 111, 225, 0.12);
  --accent-strong: rgba(47, 111, 225, 0.22);
  --accent-orange: #f4b740;
  --accent-orange-soft: rgba(244, 183, 64, 0.2);
  --accent-ghost: rgba(47, 111, 225, 0.08);
  --highlight: rgba(255, 255, 255, 0.45);
  --danger: #b42318;
  --danger-soft: rgba(180, 35, 24, 0.12);
  --danger-border: rgba(180, 35, 24, 0.35);
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Sora", "Segoe UI", "Segoe UI Web", "Segoe UI Variable", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 16px;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background: none;
  pointer-events: none;
}

.card {
  width: 100%;
  max-width: 480px;
  background: var(--card);
  border-radius: var(--radius-xl);
  padding: 32px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-soft);
}

.card.compact {
  max-width: 440px;
}

.auth-logo {
  display: flex;
  justify-content: center;
  margin-bottom: 18px;
}

.auth-logo img {
  max-width: 220px;
  height: auto;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 16px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: #ffffff;
  box-shadow: 0 8px 16px rgba(15, 23, 42, 0.06);
  float: right;
}

.lang-link {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
}

.lang-link:hover {
  color: var(--text);
}

.lang-divider {
  color: var(--border-strong);
}

h1 {
  margin: 0 0 8px;
  font-size: 28px;
  font-weight: 600;
  font-family: "Fraunces", "Sora", "Segoe UI", "Segoe UI Web", Arial, sans-serif;
  letter-spacing: -0.01em;
}

p.subtitle {
  margin: 0 0 24px;
  color: var(--muted);
}

label {
  display: block;
  font-size: 14px;
  margin-bottom: 6px;
}

input {
  width: 100%;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font-size: 15px;
  outline: none;
  background: var(--surface);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-ghost);
}

input:focus-visible {
  outline: 2px solid var(--accent-strong);
  outline-offset: 2px;
}

label {
  transition: color 160ms ease;
}

input:focus + .validation,
input:focus-visible + .validation {
  border-color: var(--accent-strong);
}

input:focus ~ .validation,
input:focus-visible ~ .validation {
  border-color: var(--accent-strong);
}

.field {
  margin-bottom: 16px;
}

.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 10px 0 18px;
}

.remember {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 14px;
}

.remember input {
  width: 16px;
  height: 16px;
}

.btn {
  width: 100%;
  padding: 12px 16px;
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--btn);
  color: #fff;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 12px 24px var(--btn-glow);
  transition: transform 160ms ease, box-shadow 160ms ease, filter 160ms ease;
}

.btn:hover {
  filter: brightness(0.97);
  transform: translateY(-1px);
  background: var(--btn-strong);
  box-shadow: 0 14px 30px var(--btn-glow);
}

.secondary {
  display: block;
  text-align: center;
  margin-top: 14px;
  font-size: 14px;
}

.link {
  font-size: 14px;
  color: var(--accent);
  text-decoration: none;
}

.validation {
  color: var(--danger);
  font-size: 13px;
  margin-top: 6px;
  background: var(--danger-soft);
  border: 1px solid var(--danger-border);
  padding: 8px 10px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.validation:empty {
  display: none;
}

.validation::before {
  content: "!";
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--danger-soft);
  color: var(--danger);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 12px;
}

div.validation[role="alert"] {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
