/* =============================================
   GOMIB — Login Page Styles
   Colors: Indigo #1E1B4B | Bronze Gold #B8860B | Cream #F5F3FF
   ============================================= */

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

:root {
  --indigo-deep:   #0F0E2A;
  --indigo-main:   #1E1B4B;
  --indigo-mid:    #312E81;
  --indigo-light:  #4338CA;
  --indigo-soft:   #6366F1;
  --bronze-dark:   #7C5A0A;
  --bronze-main:   #B8860B;
  --bronze-light:  #D4A017;
  --bronze-glow:   #E8C46A;
  --bronze-pale:   #F5E6B8;
  --cream:         #F8F7FF;
  --cream-dark:    #EDE9FE;
  --white:         #FFFFFF;
  --text-dark:     #0F0E2A;
  --text-mid:      #312E81;
  --text-muted:    #6D6BAA;
  --error:         #DC2626;
  --success:       #059669;
  --radius:        12px;
  --transition:    0.25s ease;
  --shadow-lg:     0 24px 64px rgba(15,14,42,0.3);
  --shadow-md:     0 8px 24px rgba(15,14,42,0.18);
}

html, body { height: 100%; font-family: 'Inter', sans-serif; background: var(--cream); }

/* ---- Layout ---- */
.login-wrapper { display: flex; min-height: 100vh; }

/* ---- Left Panel ---- */
.login-left {
  flex: 1.2;
  position: relative;
  background: linear-gradient(150deg, var(--indigo-deep) 0%, var(--indigo-main) 55%, var(--indigo-mid) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 48px;
  overflow: hidden;
}

/* Radial gold glow accents */
.login-left::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 25% 75%, rgba(184,134,11,0.22) 0%, transparent 55%),
    radial-gradient(ellipse at 75% 20%, rgba(184,134,11,0.14) 0%, transparent 45%),
    radial-gradient(ellipse at 50% 50%, rgba(99,102,241,0.15) 0%, transparent 70%);
}

/* Subtle geometric texture */
.left-overlay {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23B8860B' stroke-opacity='0.06' stroke-width='1'%3E%3Cpath d='M40 0 L80 40 L40 80 L0 40 Z'/%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.left-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 440px;
}

.seal-decoration { margin-bottom: 28px; }

.seal-img {
  width: 190px;
  height: 190px;
  object-fit: contain;
  border-radius: 50%;
  filter: drop-shadow(0 0 30px rgba(184,134,11,0.4)) drop-shadow(0 8px 20px rgba(0,0,0,0.5));
  animation: float 7s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  33% { transform: translateY(-8px) rotate(0.5deg); }
  66% { transform: translateY(-4px) rotate(-0.5deg); }
}

.left-title {
  font-family: 'Cinzel', serif;
  font-size: clamp(1.15rem, 2vw, 1.6rem);
  font-weight: 700;
  color: var(--bronze-pale);
  line-height: 1.45;
  letter-spacing: 0.04em;
  margin-bottom: 14px;
  text-shadow: 0 2px 12px rgba(0,0,0,0.5);
}

.left-subtitle {
  color: rgba(232,196,106,0.65);
  font-size: 0.9rem;
  line-height: 1.7;
  margin-bottom: 40px;
  letter-spacing: 0.02em;
}

/* Pillars */
.left-pillars { display: flex; gap: 28px; justify-content: center; }

.pillar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(184,134,11,0.7);
  font-family: 'Cinzel', serif;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.pillar-icon {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(184,134,11,0.35);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bronze-main);
  font-size: 1rem;
  background: rgba(184,134,11,0.06);
  transition: all var(--transition);
}

.pillar:hover .pillar-icon {
  background: rgba(184,134,11,0.15);
  border-color: var(--bronze-main);
  box-shadow: 0 0 12px rgba(184,134,11,0.25);
}

.pillar-icon::before { content: '✦'; }

/* ---- Right Panel ---- */
.login-right {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 32px;
  background: var(--cream);
  min-height: 100vh;
}

.login-box { width: 100%; max-width: 420px; }

/* Logo on right */
.login-logo { text-align: center; margin-bottom: 6px; }
.login-logo img {
  width: 108px;
  height: 108px;
  object-fit: contain;
  border-radius: 50%;
  filter: drop-shadow(0 4px 12px rgba(15,14,42,0.15));
}

.login-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 30px;
  font-style: italic;
  letter-spacing: 0.01em;
}

/* ---- Form Fields ---- */
.field-group { margin-bottom: 20px; }

.field-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--indigo-main);
  margin-bottom: 6px;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.input-wrapper { position: relative; display: flex; align-items: center; }

.input-icon {
  position: absolute;
  left: 14px;
  width: 16px;
  height: 16px;
  color: var(--text-muted);
  pointer-events: none;
  flex-shrink: 0;
}

.input-wrapper input {
  width: 100%;
  padding: 13px 44px 13px 42px;
  border: 1.5px solid var(--cream-dark);
  border-radius: var(--radius);
  background: var(--white);
  color: var(--text-dark);
  font-size: 0.92rem;
  font-family: 'Inter', sans-serif;
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}

.input-wrapper input:focus {
  border-color: var(--bronze-main);
  box-shadow: 0 0 0 3px rgba(184,134,11,0.12);
}

.input-wrapper input::placeholder { color: #B0AED0; }

.toggle-pass {
  position: absolute;
  right: 12px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 4px;
  display: flex;
  align-items: center;
  transition: color var(--transition);
}

.toggle-pass:hover { color: var(--bronze-dark); }
.toggle-pass svg { width: 18px; height: 18px; }

/* ---- Login Button ---- */
.btn-login {
  width: 100%;
  padding: 14px;
  background: linear-gradient(135deg, var(--indigo-main) 0%, var(--indigo-mid) 60%, var(--indigo-light) 100%);
  color: var(--bronze-pale);
  border: none;
  border-radius: var(--radius);
  font-family: 'Cinzel', serif;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
  margin-top: 8px;
}

/* Gold shimmer on hover */
.btn-login::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(184,134,11,0.2), transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
}

.btn-login:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-login:hover::before { opacity: 1; }
.btn-login:active { transform: translateY(0); }
.btn-login:disabled { opacity: 0.65; cursor: not-allowed; transform: none; }

.btn-secondary {
  padding: 12px 24px;
  background: transparent;
  border: 1.5px solid var(--cream-dark);
  border-radius: var(--radius);
  color: var(--text-mid);
  font-family: 'Inter', sans-serif;
  font-size: 0.88rem;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-secondary:hover { border-color: var(--bronze-main); color: var(--bronze-dark); }

/* ---- Spinner ---- */
.spinner-svg { width: 18px; height: 18px; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---- Alerts ---- */
.alert-error {
  background: #FEF2F2;
  border: 1px solid #FECACA;
  color: var(--error);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 0.88rem;
  margin-bottom: 16px;
}

.alert-success {
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  color: var(--success);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 0.88rem;
  margin-top: 12px;
}

/* ---- Links ---- */
.login-links { display: flex; justify-content: space-between; margin-top: 20px; }

.login-links a {
  font-size: 0.85rem;
  color: var(--bronze-dark);
  text-decoration: none;
  transition: color var(--transition);
}

.login-links a:hover { color: var(--indigo-main); text-decoration: underline; }

.login-footer {
  text-align: center;
  margin-top: 48px;
  padding-top: 18px;
  border-top: 1px solid var(--cream-dark);
}

.login-footer p { font-size: 0.74rem; color: var(--text-muted); line-height: 1.5; }

/* ---- Modal ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15,14,42,0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  backdrop-filter: blur(5px);
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.modal-box {
  background: var(--white);
  border-radius: 16px;
  padding: 36px;
  max-width: 440px;
  width: 90%;
  box-shadow: var(--shadow-lg);
  animation: slideUp 0.25s ease;
}

@keyframes slideUp { from { transform: translateY(20px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

.modal-box h3 {
  font-family: 'Cinzel', serif;
  font-size: 1.15rem;
  color: var(--indigo-main);
  margin-bottom: 10px;
}

.modal-box p { font-size: 0.88rem; color: var(--text-muted); margin-bottom: 24px; line-height: 1.6; }

.modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 20px; }
.modal-actions .btn-login { width: auto; padding: 12px 28px; }

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .login-left { display: none; }
  .login-right { padding: 24px 20px; }
  .login-box { max-width: 100%; }
}
