/* Base */
* {
  box-sizing: border-box
}

body,
html {
  height: 100%
}

body {
  margin: 0;
  font-family: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color: #1f2937;
  background:
    radial-gradient(1200px 600px at 10% -10%, #e8f5f3 0%, rgba(232, 245, 243, 0)60%),
    radial-gradient(900px 500px at 110% 10%, #f0f7ff 0%, rgba(240, 247, 255, 0)60%),
    #f7f7f8;
}

/* Layout */
.auth-wrapper {
  min-height: 100%;
  display: grid;
  place-items: center;
  padding: 24px
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, .06), 0 2px 8px rgba(0, 0, 0, .04);
  padding: 28px;
  border: 1px solid #eef1f5;
  animation: riseIn .28s ease-out both;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px
}

.logo {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, #0f766e, #0ea5a3)
}

.brand h1 {
  font-size: 18px;
  margin: 0;
  font-weight: 700;
  color: #0f766e
}

.auth-title {
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  margin: 10px 0 4px;
  color: #0b342f
}

.auth-subtitle {
  text-align: center;
  color: #6b7280;
  font-size: 14px;
  margin: 0 0 16px
}

/* Tabs */
.role-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  position: relative;
  background: #f3f4f6;
  padding: 6px;
  border-radius: 12px;
  margin: 10px auto 18px;
  width: max(220px, 60%);
  min-width: 220px
}

.role-tabs .slider {
  position: absolute;
  inset: 6px auto 6px 6px;
  width: calc(50% - 6px);
  border-radius: 10px;
  background: #0f766e;
  transition: transform .25s ease;
  z-index: 0
}

.role-tabs[data-active="peminjam"] .slider {
  transform: translateX(100%)
}

.role-tabs[data-active="donatur"] .slider {
  transform: translateX(0%)
}

.role-btn {
  appearance: none;
  border: 0;
  background: transparent;
  position: relative;
  z-index: 1;
  padding: 8px 14px;
  border-radius: 10px;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  color: #374151;
  transition: color .2s ease, transform .06s ease
}

.role-btn.active {
  color: #fff
}

/* Forms */
.form-group {
  margin-bottom: 14px
}

label {
  display: block;
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 8px;
  color: #374151
}

.input {
  width: 100%;
  padding: 12px;
  border: 1.2px solid #e5e7eb;
  border-radius: 12px;
  font-size: 14px
}

.input:focus {
  border-color: #0ea5a3;
  outline: none;
  box-shadow: 0 0 0 4px rgba(14, 165, 163, .12)
}

.input-wrap {
  position: relative
}

.toggle-pass {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  border: none;
  background: #004a97;      /* biru seperti contoh */
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;              /* warna icon */
  font-size: 17px;
}

.toggle-pass:hover {
  background: #003c7a;
}

/* icon berubah saat terlihat */
.toggle-pass.show i::before {
  content: "\f070"; /* fa-eye-slash */
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}

.message {
  font-size: 14px;
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0 0 14px;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca
}

/* Buttons */
.btn {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  border: 0;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .2s ease
}

.btn-primary {
  background: #0f766e;
  color: #fff;
  box-shadow: 0 4px 16px rgba(15, 118, 110, .18)
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(15, 118, 110, .25)
}

.register-link {
  text-align: center;
  margin-top: 10px;
  font-size: 14px;
  color: #4b5563
}

a {
  color: #0f766e;
  text-decoration: none
}

a:hover {
  text-decoration: underline
}

/* Animations */
@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(8px) scale(.98)
  }

  to {
    opacity: 1;
    transform: none
  }
}

@media(hover:hover) {
  .auth-card:hover {
    box-shadow: 0 10px 36px rgba(0, 0, 0, .10), 0 4px 14px rgba(0, 0, 0, .06);
    transform: translateY(-1px)
  }
}

/* === Password strength meter === */
.pw-meter {
  height: 8px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
  margin-top: 8px
}

.pw-meter>span {
  display: block;
  height: 100%;
  width: 0;
  transition: width .25s ease, background .25s ease;
  border-radius: 999px
}

.pw-hints {
  font-size: 12px;
  color: #6b7280;
  margin-top: 6px
}