/* ================================================
   URAD Login Page — Modern Split-Panel Design
   ================================================ */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
  background: #f0f2f5;
  overflow: hidden;
}

/* ---------- Layout: two-panel split ---------- */
.login-wrapper {
  display: flex;
  height: 100vh;
  width: 100%;
}

/* --- Left panel (branding / hero) --- */
.login-hero {
  flex: 1 1 50%;
  background: linear-gradient(135deg, #7c2023 0%, #a82d31 40%, #d12b30 100%);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: relative;
  overflow: hidden;
  padding: 3rem;
  color: #fff;
}

/* Decorative abstract shapes — SVG circles/arcs evoking care & shelter */
.login-hero::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  border: 60px solid rgba(255,255,255,0.04);
  top: -180px;
  right: -120px;
}

.login-hero::after {
  content: '';
  position: absolute;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  border: 40px solid rgba(255,255,255,0.04);
  bottom: -100px;
  left: -80px;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 420px;
}

.hero-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  background: rgba(255,255,255,0.15);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.hero-icon svg {
  width: 40px;
  height: 40px;
  stroke: #fff;
  fill: none;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero-content h1 {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}

.hero-content p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: rgba(255,255,255,0.8);
  margin-bottom: 2rem;
}

/* Feature pills */
.hero-features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.hero-features span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(255,255,255,0.13);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 100px;
  padding: 0.4rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 500;
  color: rgba(255,255,255,0.92);
  letter-spacing: 0.01em;
}

.hero-features span svg {
  width: 14px;
  height: 14px;
  stroke: rgba(255,255,255,0.8);
  fill: none;
  stroke-width: 2;
}

/* --- Right panel (form) --- */
.login-form-panel {
  flex: 1 1 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  background: #fff;
  position: relative;
  overflow-y: auto;
}

.login-form-container {
  width: 100%;
  max-width: 400px;
}

/* Logo */
.login-logo {
  display: block;
  width: 220px;
  margin: 0 auto 0.5rem;
}

.login-subtitle {
  text-align: center;
  font-size: 0.85rem;
  color: #6e6e6e;
  margin-bottom: 2rem;
  font-weight: 400;
}

/* ---------- Microsoft login button ---------- */
.ms-login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  width: 100%;
  padding: 0.7rem 1rem;
  background: #fff;
  color: #3c4043;
  border: 1.5px solid #dadce0;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
  text-decoration: none;
  font-family: inherit;
}

.ms-login-btn:hover {
  background: #f8f9fa;
  border-color: #c0c3c7;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08);
  text-decoration: none;
  color: #3c4043;
}

.ms-login-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* ---------- Divider ---------- */
.login-divider {
  display: flex;
  align-items: center;
  margin: 1.5rem 0;
  gap: 0.75rem;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e0e0e0;
}

.login-divider span {
  font-size: 0.75rem;
  color: #9e9e9e;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ---------- Form fields ---------- */
.login-form-group {
  margin-bottom: 1rem;
}

.login-form-group label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #374151;
  margin-bottom: 0.35rem;
}

.login-form-group input[type="text"],
.login-form-group input[type="password"] {
  width: 100%;
  padding: 0.6rem 0.75rem;
  font-size: 0.875rem;
  font-family: inherit;
  border: 1.5px solid #d1d5db;
  border-radius: 8px;
  background: #f9fafb;
  color: #1f2937;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
  outline: none;
}

.login-form-group input:focus {
  border-color: #d12b30;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(209,43,48,0.1);
}

.login-form-group input::placeholder {
  color: #9ca3af;
}

/* ---------- Error message ---------- */
.login-error-msg {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  background: #fef2f2;
  border: 1px solid #fecaca;
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  margin-bottom: 1rem;
  color: #991b1b;
  font-size: 0.8rem;
  line-height: 1.4;
}

.login-error-msg svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 1px;
  stroke: #dc2626;
  fill: none;
  stroke-width: 2;
}

/* ---------- Submit button ---------- */
.login-submit-btn {
  width: 100%;
  padding: 0.7rem 1rem;
  background: linear-gradient(135deg, #d12b30, #a82d31);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: opacity 0.15s, box-shadow 0.15s, transform 0.1s;
  letter-spacing: 0.01em;
}

.login-submit-btn:hover {
  opacity: 0.92;
  box-shadow: 0 4px 12px rgba(209,43,48,0.3);
}

.login-submit-btn:active {
  transform: scale(0.99);
}

/* ---------- Help link ---------- */
.login-help {
  text-align: center;
  margin-top: 1.25rem;
  font-size: 0.78rem;
  color: #6b7280;
}

.login-help a {
  color: #d12b30;
  text-decoration: none;
  font-weight: 500;
}

.login-help a:hover {
  text-decoration: underline;
}

/* ---------- Footer ---------- */
.login-footer {
  position: absolute;
  bottom: 1.25rem;
  left: 0;
  right: 0;
  text-align: center;
  font-size: 0.7rem;
  color: #9ca3af;
}

/* ================================================
   Responsive
   ================================================ */

/* Tablet */
@media screen and (max-width: 960px) {
  .login-wrapper { flex-direction: column; }

  .login-hero {
    flex: 0 0 auto;
    min-height: 260px;
    padding: 2rem 1.5rem;
  }

  .hero-content h1 { font-size: 1.4rem; }
  .hero-content p { font-size: 0.85rem; margin-bottom: 1rem; }
  .hero-icon { width: 60px; height: 60px; margin-bottom: 1rem; }
  .hero-icon svg { width: 30px; height: 30px; }
  .hero-features span { font-size: 0.72rem; padding: 0.3rem 0.7rem; }

  .login-form-panel {
    flex: 1 1 auto;
    justify-content: flex-start;
    padding: 1.5rem 1.5rem;
  }

  .login-logo { width: 180px; }
  body { overflow-y: auto; }
}

/* Mobile */
@media screen and (max-width: 600px) {
  .login-hero { min-height: 220px; padding: 1.5rem 1rem; }
  .hero-content h1 { font-size: 1.2rem; }
  .hero-features { gap: 0.35rem; }
  .hero-features span { font-size: 0.68rem; padding: 0.25rem 0.6rem; }

  .login-form-panel { padding: 1.25rem 1rem; }
  .login-form-container { max-width: 100%; }
  .login-logo { width: 160px; }
  .login-footer { position: static; margin-top: 1.5rem; }
}

/* Very small */
@media screen and (max-width: 380px) {
  .login-hero { min-height: 180px; padding: 1.25rem 0.75rem; }
  .hero-content p { display: none; }
  .hero-icon { width: 48px; height: 48px; border-radius: 14px; }
  .hero-icon svg { width: 24px; height: 24px; }
}
