/*
 * Public login polish only.
 * Keep the signed-in app on its established theme so app pages cannot
 * accidentally inherit styling meant for authentication.
 */

#auth-screen {
  background:
    radial-gradient(circle at 10% 10%, rgba(124, 106, 247, 0.22), transparent 32%),
    radial-gradient(circle at 90% 85%, rgba(86, 180, 255, 0.14), transparent 30%),
    #0a0a0f !important;
  overflow-y: auto;
  overscroll-behavior-y: contain;
}

#auth-screen .auth-bg { opacity: 0.72; }

#auth-screen .auth-container {
  position: relative;
  z-index: 1;
  width: min(100%, 1120px) !important;
  max-width: 1120px !important;
  min-height: 100dvh;
  max-height: none !important;
  margin: 0 auto !important;
  padding: clamp(20px, 4vw, 48px) 20px calc(28px + var(--safe-bottom)) !important;
  display: flex;
  justify-content: center;
  overflow: visible !important;
}

#auth-screen .auth-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(340px, 430px);
  gap: clamp(20px, 3vw, 34px);
  width: 100%;
  align-items: stretch;
}

#auth-screen .auth-hero,
#auth-screen .auth-panel-shell {
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 26px;
  background: rgba(17, 17, 24, 0.82);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

#auth-screen .auth-hero {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
  padding: clamp(28px, 4vw, 46px);
}

#auth-screen .auth-logo {
  padding: 0;
  text-align: left;
}

#auth-screen .auth-logo .logo-icon {
  width: 58px;
  height: 58px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  border-radius: 18px;
  background: var(--accent-dim);
  border: 1px solid var(--border-light);
}

#auth-screen .auth-logo h1 {
  color: var(--text) !important;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1;
}

#auth-screen .auth-logo p,
#auth-screen .auth-copy p,
#auth-screen .auth-form-head p,
#auth-screen .auth-status { color: var(--text-2) !important; }

#auth-screen .auth-copy {
  display: grid;
  gap: 13px;
}

#auth-screen .auth-kicker,
#auth-screen .auth-panel-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  padding: 8px 12px;
  border-radius: 999px;
  background: var(--accent-dim);
  border: 1px solid rgba(157, 143, 255, 0.28);
  color: #e6e1ff;
  font-size: 12px;
  font-weight: 700;
}

#auth-screen .auth-copy h2 {
  max-width: 14ch;
  color: var(--text);
  font-family: var(--font-display);
  font-size: clamp(30px, 5vw, 54px);
  line-height: 1.04;
}

#auth-screen .auth-highlights {
  display: grid;
  gap: 12px;
}

#auth-screen .auth-highlight-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.035);
}

#auth-screen .auth-highlight-emoji {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border-radius: 14px;
  background: var(--accent-dim);
  font-size: 20px;
}

#auth-screen .auth-highlight-card strong { color: var(--text); }

#auth-screen .auth-highlight-card span:last-child {
  display: block;
  margin-top: 2px;
  color: var(--text-2);
  font-size: 13px;
}

#auth-screen .auth-panel { display: flex; }

#auth-screen .auth-panel-shell {
  width: 100%;
  padding: clamp(20px, 3vw, 30px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
}

#auth-screen .auth-panel-head {
  display: grid;
  gap: 10px;
}

#auth-screen .auth-status {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.035);
  font-size: 13px;
}

#auth-screen .auth-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  padding: clamp(20px, 3vw, 28px);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  background: rgba(10, 10, 15, 0.72);
}

#auth-screen .auth-form-head {
  display: grid;
  gap: 6px;
}

#auth-screen .auth-form-head h2 {
  color: var(--text);
  font-size: 26px;
}

#auth-screen .form-group input,
#auth-screen .form-group select,
#auth-screen #reg-department-other {
  min-height: 52px;
  border: 1px solid var(--border-light);
  border-radius: 14px;
  background: var(--bg-3);
  color: var(--text);
}

#auth-screen .form-group input:focus,
#auth-screen .form-group select:focus,
#auth-screen #reg-department-other:focus {
  border-color: var(--accent-light);
  box-shadow: 0 0 0 3px var(--accent-dim);
}

#auth-screen .btn-primary {
  min-height: 52px;
  border-radius: 14px;
  background: var(--accent);
  box-shadow: 0 12px 28px var(--accent-glow);
}

#auth-screen .auth-inline-link,
#auth-screen .auth-switch a {
  color: var(--accent-light) !important;
  font-weight: 700;
}

#auth-screen .auth-form-tip,
#auth-screen .auth-switch { text-align: center; }

@media (max-width: 820px) {
  #auth-screen .auth-container {
    padding: 16px 14px calc(24px + var(--safe-bottom)) !important;
  }

  #auth-screen .auth-shell { grid-template-columns: 1fr; }
  #auth-screen .auth-hero { gap: 22px; }
  #auth-screen .auth-copy h2 { max-width: none; }
}

@media (max-width: 520px) {
  #auth-screen .auth-container {
    min-height: 100dvh;
  }

  #auth-screen .auth-hero { padding: 24px 20px; }
  #auth-screen .auth-panel-shell { padding: 16px; }
  #auth-screen .auth-copy h2 { font-size: clamp(28px, 9vw, 38px); }
  #auth-screen .auth-highlight-card { padding: 12px; }
}

