:root {
  --bg-1: #eef3ff;
  --bg-2: #f8fbff;
  --ink: #152033;
  --muted: #68758a;
  --line: #dde5f1;
  --card: rgba(255, 255, 255, 0.94);
  --brand: #163b73;
  --brand-2: #2a62b8;
  --shadow: 0 20px 50px rgba(15, 32, 65, 0.14);
  --radius-xl: 24px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { min-height: 100%; }

body {
  margin: 0;
  font-family: 'Cairo', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(42, 98, 184, 0.14), transparent 30%),
    radial-gradient(circle at bottom left, rgba(22, 59, 115, 0.08), transparent 26%),
    linear-gradient(180deg, var(--bg-1) 0%, var(--bg-2) 100%);
  overflow-x: hidden;
}

.login-page {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
}

.login-shell {
  width: min(100%, 430px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.brand-mark {
  width: 76px;
  height: 76px;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 16px 34px rgba(22, 59, 115, 0.28);
  display: grid;
  place-items: center;
}

.brand-badge {
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: 1px;
}

.brand-copy { text-align: center; }
.brand-copy h1 {
  margin: 0;
  font-size: clamp(28px, 5vw, 34px);
  line-height: 1;
  letter-spacing: 1px;
  font-weight: 800;
  color: var(--brand);
}
.brand-copy p {
  margin: 8px 0 0;
  font-size: 14px;
  color: var(--muted);
}

.login-box {
  width: 100%;
  background: var(--card);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(221, 229, 241, 0.9);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  padding: 24px;
}

.panel-top {
  text-align: center;
  margin-bottom: 18px;
}
.panel-kicker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(22, 59, 115, 0.08);
  color: var(--brand);
  font-size: 12px;
  font-weight: 700;
}
.panel-top h2 {
  margin: 12px 0 6px;
  font-size: 28px;
  line-height: 1.15;
}
.panel-top p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
}

form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
label {
  font-size: 14px;
  color: #334155;
  font-weight: 700;
}
input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
  padding: 14px 16px;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  outline: none;
  transition: border-color .18s ease, box-shadow .18s ease;
}
input:focus {
  border-color: rgba(42, 98, 184, 0.85);
  box-shadow: 0 0 0 4px rgba(42, 98, 184, 0.12);
}
button {
  width: 100%;
  border: 0;
  border-radius: 16px;
  padding: 14px 18px;
  font: inherit;
  font-size: 16px;
  font-weight: 800;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  box-shadow: 0 14px 28px rgba(22, 59, 115, 0.22);
  transition: transform .18s ease, box-shadow .18s ease, filter .18s ease;
}
button:hover { filter: brightness(1.02); }
button:active { transform: translateY(1px); }
.error {
  margin-bottom: 14px;
  border: 1px solid rgba(220, 38, 38, 0.16);
  background: rgba(254, 242, 242, 0.95);
  color: #b91c1c;
  border-radius: 14px;
  padding: 12px 14px;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
}

@media (max-width: 640px) {
  .login-page { padding: 18px 14px; }
  .login-shell { width: min(100%, 380px); gap: 14px; }
  .brand-mark { width: 68px; height: 68px; border-radius: 22px; }
  .brand-badge { font-size: 24px; }
  .brand-copy h1 { font-size: 28px; }
  .brand-copy p, .panel-top p { font-size: 13px; }
  .login-box { padding: 20px 16px; border-radius: 20px; }
  .panel-top h2 { font-size: 24px; }
  input, button { min-height: 50px; }
}

@media (max-width: 380px) {
  .login-page { padding-inline: 12px; }
  .login-box { padding: 18px 14px; }
  .panel-top h2 { font-size: 22px; }
}
