@import url("https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap");

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: "Poppins", sans-serif;
  background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 100%);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.auth-container {
  width: 100%;
  padding: 20px;
  display: flex;
  justify-content: center;
}

.auth-card {
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  padding: 2rem 2rem;
  border-radius: 24px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
  position: relative;
  animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.back-home {
  position: absolute;
  top: 20px;
  left: 20px;
  text-decoration: none;
  color: #94a3b8;
  font-size: 0.85rem;
  font-weight: 500;
  transition: 0.3s;
}

.back-home:hover {
  color: #1e3a8a;
}

.auth-header {
  text-align: center;
  margin-bottom: 1.2rem;
  margin-top: 0.5rem;
}

.auth-logo-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  text-decoration: none;
}

.logo img {
  height: 45px;
  width: auto;
  object-fit: contain;
}

.logo-text {
  border-left: 2px solid #cbd5e1;
  padding-left: 0.8rem;
  color: #1e3a8a;
  font-weight: 800;
  font-size: 0.95rem;
  line-height: 1.2;
  text-align: left;
}

.logo-text span {
  display: block;
  font-size: 0.7rem;
  font-weight: 500;
  color: #64748b;
}

.auth-header h2 {
  color: #1e3a8a;
  margin: 0 0 0.3rem 0;
  font-size: 1.5rem;
  font-weight: 700;
}

.auth-header p {
  color: #64748b;
  font-size: 0.85rem;
  margin: 0;
}

.input-group {
  margin-bottom: 1rem;
}

.input-group label {
  display: block;
  font-weight: 600;
  font-size: 0.85rem;
  color: #334155;
  margin-bottom: 0.3rem;
}

.input-icon {
  position: relative;
}

.input-icon i {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 1.1rem;
}

.input-icon input {
  width: 100%;
  padding: 0.75rem 0.9rem 0.75rem 2.8rem;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: 0.3s;
  background-color: #f8fafc;
}

.input-icon input:focus {
  border-color: #facc15;
  background-color: #ffffff;
  box-shadow: 0 0 0 4px rgba(250, 204, 21, 0.15);
}

.btn-auth {
  width: 100%;
  background-color: #1e3a8a;
  color: white;
  padding: 0.9rem;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: 0.3s;
  margin-top: 0.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
}

.btn-auth:hover {
  background-color: #facc15;
  color: #1e3a8a;
  transform: translateY(-3px);
  box-shadow: 0 10px 15px -3px rgba(250, 204, 21, 0.4);
}

.error-text,
.success-text {
  font-size: 0.85rem;
  text-align: center;
  font-weight: 500;
  margin-bottom: 0.8rem;
  display: none;
  padding: 0.5rem;
  border-radius: 8px;
}

.error-text {
  background-color: #fef2f2;
  color: #ef4444;
  border: 1px solid #fecaca;
}
.success-text {
  background-color: #f0fdf4;
  color: #10b981;
  border: 1px solid #a7f3d0;
}

.auth-switch {
  text-align: center;
  margin-top: 1.2rem;
  font-size: 0.85rem;
  color: #64748b;
}

.auth-switch a {
  color: #1e3a8a;
  font-weight: 600;
  text-decoration: none;
  transition: 0.3s;
}

.auth-switch a:hover {
  color: #facc15;
}

.auth-tabs {
  display: flex;
  background-color: #f1f5f9;
  border-radius: 12px;
  padding: 5px;
  margin-bottom: 1.2rem;
  position: relative;
}

.tab-btn {
  flex: 1;
  padding: 0.7rem;
  border: none;
  background: transparent;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  z-index: 1;
}

.tab-btn.active {
  background-color: #ffffff;
  color: #1e3a8a;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  transform: scale(1.02);
}

.tab-btn:hover:not(.active) {
  color: #1e3a8a;
}

.btn-google {
  width: 100%;
  background-color: #ffffff;
  color: #334155;
  padding: 0.9rem;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: 0.3s;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 1.2rem;
}

.btn-google:hover {
  background-color: #f8fafc;
  border-color: #94a3b8;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.btn-google img {
  width: 20px;
  height: 20px;
}

.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin-bottom: 1.2rem;
  color: #94a3b8;
  font-size: 0.85rem;
  font-weight: 500;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  border-bottom: 1px solid #e2e8f0;
}

.auth-divider:not(:empty)::before {
  margin-right: 1rem;
}
.auth-divider:not(:empty)::after {
  margin-left: 1rem;
}

@media (max-height: 800px) {
  .auth-card {
    transform: scale(0.9);
    transform-origin: center;
    margin: auto 0;
  }
}
@media (max-height: 650px) {
  .auth-card {
    transform: scale(0.8);
  }
}
