*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0d0f14;
  --bg-2: #13161e;
  --bg-3: #1a1d27;
  --bg-4: #22263a;
  --border: rgba(255,255,255,.07);
  --border-2: rgba(255,255,255,.13);
  --text: #e8eaf0;
  --text-2: #9296a8;
  --text-3: #5a5f72;
  --accent: #e05535;
  --accent-d: #b8401e;
  --green: #2ec06a;
  --green-bg: rgba(46,192,106,.12);
  --red: #e05535;
  --red-bg: rgba(224,85,53,.12);
  --radius: 10px;
  --radius-lg: 18px;
  --mono: 'JetBrains Mono', monospace;
}

html, body {
  min-height: 100%;
}

body {
  font-family: 'DM Sans', sans-serif;
  background:
    radial-gradient(circle at top left, rgba(224,85,53,.12), transparent 30%),
    radial-gradient(circle at bottom right, rgba(74,158,255,.08), transparent 25%),
    var(--bg);
  color: var(--text);
}

.login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

.login-shell {
  width: 100%;
  max-width: 520px;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: .85rem;
  margin-bottom: 1rem;
}

.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: .75rem;
  color: #fff;
  box-shadow: 0 12px 24px rgba(224,85,53,.18);
}

.brand-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
}

.brand-sub {
  font-size: .78rem;
  color: var(--text-3);
  margin-top: .1rem;
}

.login-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.6rem;
  box-shadow: 0 20px 40px rgba(0,0,0,.28);
}

.login-card-head {
  margin-bottom: 1.25rem;
}

.login-kicker {
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: .45rem;
}

.login-title {
  font-family: 'Syne', sans-serif;
  font-weight: 800;
  font-size: 1.55rem;
  line-height: 1.05;
  color: var(--text);
  margin-bottom: .55rem;
}

.login-sub {
  font-size: .88rem;
  color: var(--text-3);
  line-height: 1.6;
}

.flash-banner {
  display: flex;
  gap: .75rem;
  align-items: flex-start;
  border-radius: var(--radius);
  padding: .85rem 1rem;
  font-size: .83rem;
  line-height: 1.55;
  margin-bottom: 1rem;
}

.flash-icon {
  flex-shrink: 0;
  font-size: 1rem;
  margin-top: .05rem;
}

.flash-error {
  background: var(--red-bg);
  border: 1px solid rgba(224,85,53,.2);
  color: var(--red);
}

.flash-ok {
  background: var(--green-bg);
  border: 1px solid rgba(46,192,106,.2);
  color: var(--green);
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: .38rem;
}

.form-label {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--text-3);
}

.form-input {
  width: 100%;
  height: 44px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-3);
  color: var(--text);
  padding: 0 .95rem;
  outline: none;
  font-size: .88rem;
  transition: border-color .15s, box-shadow .15s, background .15s;
}

.form-input::placeholder {
  color: var(--text-3);
}

.form-input:focus {
  border-color: var(--border-2);
  background: var(--bg-4);
  box-shadow: 0 0 0 3px rgba(255,255,255,.04);
}

.form-actions {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  margin-top: .25rem;
}

.btn {
  height: 44px;
  padding: 0 1.25rem;
  border-radius: var(--radius);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  font-size: .88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  border: none;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  font-family: 'Syne', sans-serif;
}

.btn-primary:hover {
  background: var(--accent-d);
  transform: translateY(-1px);
}

.btn-secondary {
  background: transparent;
  color: var(--text-2);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--bg-3);
  color: var(--text);
  border-color: var(--border-2);
}

.login-footnote {
  margin-top: 1rem;
  padding-top: .95rem;
  border-top: 1px solid var(--border);
  font-size: .74rem;
  color: var(--text-3);
  line-height: 1.5;
}

@media (max-width: 560px) {
  .login-card {
    padding: 1.2rem;
  }

  .login-title {
    font-size: 1.35rem;
  }

  .form-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}