*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'DM Sans', sans-serif;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #202C40 0%, #103DA8 48%, #2857B8 100%);
  padding: 20px;
  position: relative;
}

html[data-theme="dark"] body {
  background: linear-gradient(145deg, #121820 0%, #202C40 50%, #103DA8 100%) !important;
}

.login-theme-btn {
  position: fixed;
  top: 18px;
  right: 18px;
  background: rgba(255,255,255,0.14);
  color: #fff;
  border: 1px solid rgba(201,154,53,0.5);
  border-radius: 10px;
  padding: 8px 14px;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 12px;
  cursor: pointer;
}
.login-theme-btn:hover { background: #C99A35; color: #202C40; }

.card {
  background: #FFFFFF;
  border-radius: 20px;
  padding: 40px 40px 36px;
  width: 100%;
  max-width: 540px;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 24px 64px rgba(16,61,168,0.28);
  border-top: 4px solid #C99A35;
}

html[data-theme="dark"] .card {
  background: #202C40 !important;
  color: #E1EBFB;
}

.logo-wrap {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: #E1EBFB;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
}
.logo-wrap svg { width: 36px; height: 36px; }

h1 {
  font-size: 1.55rem;
  font-weight: 700;
  color: #202C40;
  letter-spacing: -0.3px;
  margin-bottom: 8px;
  text-align: center;
}
html[data-theme="dark"] h1 { color: #E1EBFB !important; }
.subtitle {
  font-size: 0.92rem;
  color: #5E6877;
  margin-bottom: 26px;
  text-align: center;
}

.input-group {
  width: 100%;
  margin-bottom: 16px;
  position: relative;
}
.input-group .icon-left {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: #5E6877;
  display: flex;
}
.input-group input {
  width: 100%;
  padding: 15px 44px 15px 44px;
  border: 1.5px solid #E1EBFB;
  border-radius: 12px;
  background: #F4F8FF;
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  color: #202C40;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.input-group input::placeholder { color: #5E6877; }
.input-group input:focus {
  border-color: #103DA8;
  box-shadow: 0 0 0 3px rgba(16,61,168,0.12);
  background: #fff;
}
.toggle-pw {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  color: #5E6877;
  background: none;
  border: none;
  display: flex;
  padding: 0;
}

.forgot-row {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  margin: 6px 0 22px;
}
.forgot-row a {
  font-size: 0.93rem;
  color: #103DA8;
  text-decoration: none;
  font-weight: 500;
}
.forgot-row a:hover { text-decoration: underline; color: #C99A35; }

.btn-signin {
  width: 100%;
  padding: 16px;
  background: #103DA8;
  color: #fff;
  border: none;
  border-radius: 12px;
  font-family: 'DM Sans', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  margin-bottom: 22px;
  letter-spacing: 0.2px;
}
.btn-signin:hover { background: #2857B8; }
.btn-signin:active { transform: scale(0.985); }

.quick-login {
  width: 100%;
  margin-bottom: 20px;
}
.quick-login-label {
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #5E6877;
  margin-bottom: 10px;
  text-align: center;
}
.quick-login-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}
.quick-role-btn {
  text-align: left;
  border: 1.5px solid #E1EBFB;
  background: #F4F8FF;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  font-family: 'DM Sans', sans-serif;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.quick-role-btn:hover {
  border-color: #103DA8;
  box-shadow: 0 0 0 3px rgba(16,61,168,0.1);
}
.quick-role-name {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: #103DA8;
}
.quick-role-mail {
  display: block;
  font-size: 0.68rem;
  color: #5E6877;
  margin-top: 2px;
}

.footer-row {
  font-size: 0.95rem;
  color: #5E6877;
}
.footer-row a {
  color: #103DA8;
  font-weight: 600;
  text-decoration: none;
  margin-left: 4px;
}
.footer-row a:hover { text-decoration: underline; color: #C99A35; }

@media (max-width: 480px) {
  .card { padding: 32px 18px 28px; }
  h1 { font-size: 1.28rem; }
  .quick-login-grid { grid-template-columns: 1fr; }
}
