:root {
  --purple-900: #2D085D;
  --purple-700: #440C8C;
  --purple-600: #5B11BA;
  --purple-500: #6613D0;
  --purple-400: #8E44ED;
  --purple-200: #C6A1F6;
  --purple-100: #E2D0FA;
  --orange:     #FE8F1C;
  --orange-dark:#CB6700;
  --gray-900:   #0b0d19;
  --gray-700:   #34353f;
  --gray-500:   #3d3f48;
  --gray-300:   #c0c1c9;
  --gray-100:   #f5f6fc;
  --white:      #ffffff;
}

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

body {
  font-family: 'Poppins', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(145deg, var(--purple-900) 0%, var(--purple-600) 55%, var(--purple-400) 100%);
}

header {
  padding: 0 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.header-brand svg {
  height: 30px;
  width: auto;
}

.lang-switcher {
  display: flex;
  align-items: center;
  gap: .375rem;
  background: rgba(255,255,255,.1);
  border-radius: 24px;
  padding: .25rem .375rem;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: .35rem;
  padding: .3rem .6rem;
  border: none;
  border-radius: 18px;
  background: transparent;
  color: rgba(255,255,255,.65);
  font-family: 'Poppins', sans-serif;
  font-size: .72rem;
  font-weight: 500;
  cursor: pointer;
  transition: background .18s, color .18s;
  white-space: nowrap;
}

.lang-btn .flag {
  width: 22px;
  height: 15px;
  border-radius: 2px;
  flex-shrink: 0;
  display: block;
  overflow: hidden;
}

.lang-btn:hover {
  background: rgba(255,255,255,.15);
  color: #ffffff;
}

.lang-btn.active {
  background: rgba(255,255,255,.22);
  color: #ffffff;
  font-weight: 600;
}

main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.login-card {
  background: var(--white);
  border-radius: 16px;
  box-shadow: 0 24px 60px rgba(0,0,0,.35);
  padding: 2.5rem 2.25rem;
  width: 100%;
  max-width: 400px;
  text-align: center;
}

.login-logo {
  margin-bottom: 1.75rem;
}

.login-logo svg {
  height: 72px;
  width: auto;
}

.login-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--gray-900);
  margin-bottom: .4rem;
}

.login-subtitle {
  font-size: .82rem;
  color: var(--gray-500);
  margin-bottom: 2rem;
  line-height: 1.5;
}

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .75rem;
  width: 100%;
  padding: .85rem 1.25rem;
  border: 1.5px solid #e0e0e0;
  border-radius: 10px;
  background: var(--white);
  font-family: 'Poppins', sans-serif;
  font-size: .9rem;
  font-weight: 600;
  color: var(--gray-700);
  cursor: pointer;
  text-decoration: none;
  transition: background .2s, border-color .2s, box-shadow .2s;
}

.btn-google:hover {
  background: var(--gray-100);
  border-color: #bdbdbd;
  box-shadow: 0 2px 8px rgba(0,0,0,.1);
}

.btn-google svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.login-divider {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin: 1.5rem 0;
  color: var(--gray-300);
  font-size: .75rem;
}

.login-divider::before,
.login-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--gray-100);
}

.login-info {
  background: var(--purple-100);
  border-radius: 8px;
  padding: .85rem 1rem;
  font-size: .75rem;
  color: var(--purple-700);
  line-height: 1.5;
}

.login-info strong {
  display: block;
  font-weight: 600;
  margin-bottom: .2rem;
}

footer {
  text-align: center;
  padding: 1.25rem;
  font-size: .7rem;
  color: rgba(255,255,255,.45);
}

.login-error {
  display: none;
  background: #fff0f0;
  border: 1px solid #fca5a5;
  border-radius: 8px;
  padding: .75rem 1rem;
  font-size: .78rem;
  color: #b91c1c;
  margin-bottom: 1rem;
  text-align: left;
}

.login-error.visible { display: block; }

.login-banner {
  display: none;
  border-radius: 8px;
  padding: .75rem 1rem;
  font-size: .78rem;
  margin-bottom: 1rem;
  text-align: left;
}

.login-banner.visible { display: block; }

.login-banner-warning {
  background: #fffbeb;
  border: 1px solid #fcd34d;
  color: #92400e;
}

.login-banner-success {
  background: #f0fdf4;
  border: 1px solid #86efac;
  color: #166534;
}

.btn-google.loading {
  pointer-events: none;
  opacity: .65;
}

@media (max-width: 480px) {
  .login-card {
    padding: 2rem 1.5rem;
  }
  .lang-btn span.label {
    display: none;
  }
}
