﻿
:root { --primary: #0f172a; --accent: #0d9488; --accent-dark: #0f766e; }
html, body { min-height: 100dvh; margin: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }
body { 
  font-family: system-ui, -apple-system, BlinkMacSystemFont, " Segoe UI\, Roboto, sans-serif; 
  background: #0a1628;
}
.login-wrapper { 
  min-height: 100dvh; 
  display: flex; 
  align-items: center; 
  justify-content: center; 
  padding: 1rem; 
  box-sizing: border-box; 
  position: relative;
  /* background-image di-set secara dinamis via inline style dari DB (pengaturan.background) atau fallback gedung */
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
.login-wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(3, 6, 12, 0.82); /* even stronger dark to closely match Image #2's moody, almost silhouette building with heavy dark overlay */
  z-index: 0;
}
@media (max-width: 767.98px) { .form-group { margin-bottom: 1rem; } .input-group { border-radius: 10px; } .btn-login, .btn-primary { border-radius: 10px; } }
.login-container, .reset-container, .forgot-container { 
  width: 100%; 
  max-width: 980px; 
  background: rgba(255,255,255,0.95); 
  border-radius: 22px; 
  box-shadow: 0 30px 70px -15px rgba(0,0,0,0.65), 0 15px 35px -10px rgba(0,0,0,0.35); 
  overflow: hidden; 
  display: flex; 
  flex-direction: row; 
  backdrop-filter: blur(6px); 
  border: 1px solid rgba(255,255,255,0.3); 
}
.login-brand { background: #0a1628; color: #fff; padding: 3rem 2.5rem; display: flex; flex-direction: column; justify-content: center; position: relative; flex: 0 0 45%; min-width: 320px; }
.login-brand::after { content: \\; position: absolute; top: 0; right: 0; bottom: 0; left: 0; background: radial-gradient(circle at 30% 20%, rgba(13,148,136,0.06) 0%, transparent 50%), radial-gradient(circle at 70% 80%, rgba(13,148,136,0.04) 0%, transparent 50%); pointer-events: none; }
.brand-content { position: relative; z-index: 1; }
.brand-logo { width: 118px; height: 118px; background: rgba(255,255,255,0.08); border: 1px solid rgba(255,255,255,0.12); border-radius: 24px; display: flex; align-items: center; justify-content: center; margin-bottom: 1.5rem; padding: 8px; backdrop-filter: blur(10px); }
.brand-logo img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand-logo i { font-size: 2.1rem; color: #14b8a6; }
.brand-title { font-size: 2.1rem; font-weight: 800; letter-spacing: -0.04em; margin-bottom: 0.1rem; color: #fff; }
.brand-fullname { color: #94a3b8; font-size: 0.82rem; font-weight: 500; line-height: 1.25; margin-bottom: 0.55rem; letter-spacing: 0.005em; }
.brand-subtitle { color: #94a3b8; font-size: 1rem; line-height: 1.4; margin-bottom: 2rem; }
.brand-features { margin-top: auto; }
.brand-feature { display: flex; align-items: center; gap: 0.65rem; margin-bottom: 0.85rem; color: #cbd5e1; font-size: 0.925rem; }
.brand-feature i { color: #14b8a6; width: 18px; }
.login-form-panel, .reset-body, .forgot-body { flex: 1; padding: 3rem 2.75rem; display: flex; flex-direction: column; justify-content: center; background: rgba(255, 255, 255, 0.92); }
.form-header { margin-bottom: 2rem; }
.form-header h2 { font-size: 1.65rem; font-weight: 700; color: #0f172a; margin-bottom: 0.35rem; letter-spacing: -0.025em; }
.form-header p { color: #64748b; font-size: 0.95rem; margin-bottom: 0; }
.form-group { margin-bottom: 1.25rem; }
.form-group label { font-weight: 600; color: #334155; font-size: 0.875rem; margin-bottom: 0.4rem; display: block; }
.input-group { border-radius: 12px; overflow: hidden; box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08); border: 1px solid #e2e8f0; }
.input-group:focus-within { border-color: #14b8a6; box-shadow: 0 0 0 4px rgba(20, 184, 166, 0.12); }
.input-group .form-control { border: none; padding: 0.85rem 1rem 0.85rem 0.55rem; font-size: 1rem; height: auto; box-shadow: none; background: #fff; }
.input-group .form-control:focus { box-shadow: none; outline: none; }
.input-group-text { background: #f8fafc; border: none; color: #64748b; padding: 0 0.85rem; display: flex; align-items: center; min-width: 42px; justify-content: center; }
.input-group-text i { font-size: 1rem; }
.input-group { background: #fff; }
.password-toggle { cursor: pointer; padding-right: 1rem; color: #64748b; transition: color 0.2s; }
.password-toggle:hover { color: #0d9488; }
.btn-login, .btn-primary { background: #0d9488; border: none; color: white; font-weight: 600; font-size: 1rem; padding: 0.9rem 1.5rem; border-radius: 12px; width: 100%; transition: all 0.2s ease; margin-top: 0.5rem; }
.btn-login:hover, .btn-primary:hover { background: #0f766e; transform: translateY(-1px); box-shadow: 0 10px 15px -3px rgb(13 148 136 / 0.3); }
.btn-login:active, .btn-primary:active { transform: translateY(0); }
.btn-login .spinner { display: none; width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; border-radius: 50%; animation: spin 0.8s linear infinite; vertical-align: middle; }
.alert-custom, .alert { border-radius: 12px; border: none; padding: 0.85rem 1rem; font-size: 0.925rem; margin-bottom: 1.25rem; }
.hint-box { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 10px; padding: 0.85rem 1rem; font-size: 0.8rem; color: #64748b; }
@media (max-width: 767.98px) { .login-wrapper { min-height: 100dvh; padding: 1rem; padding-top: max(1rem, env(safe-area-inset-top, 1rem)); padding-bottom: max(1.25rem, env(safe-area-inset-bottom, 1rem)); align-items: flex-start; justify-content: flex-start; box-sizing: border-box; } .login-container, .reset-container, .forgot-container { flex-direction: column; width: 100%; max-width: 380px; margin: 0 auto; border-radius: 18px; box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.25); } .login-brand { flex: none; min-width: auto; padding: 1.75rem 1.25rem; text-align: center; border-radius: 18px 18px 0 0; } .brand-content { max-width: 100%; margin: 0 auto; } .brand-logo { width: 78px; height: 78px; margin: 0 auto 0.8rem; } .brand-title { font-size: 1.45rem; } .brand-fullname { font-size: 0.72rem; margin-bottom: 0.35rem; } .brand-subtitle { font-size: 0.82rem; margin-bottom: 0.6rem; } .brand-features { display: none; } .login-form-panel, .reset-body, .forgot-body { padding: 1.6rem 1.25rem; border-radius: 0 0 18px 18px; } .form-header h2 { font-size: 1.3rem; margin-bottom: 0.2rem; } .form-header p { font-size: 0.8rem; margin-bottom: 0.9rem; } .form-group { margin-bottom: 0.9rem; } .form-group label { font-size: 0.78rem; } .input-group .form-control { font-size: 0.92rem; padding: 0.7rem 0.75rem; } .input-group-text { padding: 0 0.6rem; } .btn-login, .btn-primary { font-size: 0.92rem; padding: 0.8rem 1.1rem; min-height: 46px; margin-top: 0.3rem; } .input-group-text, .password-toggle { min-width: 40px; } .login-form-panel .mt-4 { margin-top: 0.6rem !important; font-size: 0.62rem; } }
@media (max-width: 480px) { .login-wrapper, body.reset, body.forgot { padding: 0.65rem; padding-top: max(0.65rem, env(safe-area-inset-top, 0.65rem)); padding-bottom: max(0.9rem, env(safe-area-inset-bottom, 0.9rem)); } .login-container, .reset-container, .forgot-container { max-width: 90%; border-radius: 16px; } .login-brand, .reset-header, .forgot-header { padding: 1.3rem 0.9rem; } .login-form-panel, .reset-body, .forgot-body { padding: 1.2rem 0.9rem; } .brand-title { font-size: 1.32rem; } .brand-fullname { font-size: 0.68rem; margin-bottom: 0.3rem; } .form-header h2 { font-size: 1.15rem; } }
.login-container, .reset-container, .forgot-container { animation: fadeInUp 0.4s ease forwards; }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
.form-control::placeholder { color: #94a3b8; }

/* Overlay gelap untuk background login (dinamis) - pastikan gelap seperti request user */
.login-wrapper::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(3, 6, 12, 0.82);
  z-index: 0;
}


