/* ============================================================
   GLORY KIDS — AUTH STYLES
   Login, Signup, Forgot Password, Dashboard nav user menu
   ============================================================ */

/* ─── AUTH PAGE LAYOUT ──────────────────────────────────────── */
.auth-page {
  display: flex;
  min-height: 100vh;
}

/* ─── LEFT PANEL ────────────────────────────────────────────── */
.auth-left {
  flex: 0 0 420px;
  background: linear-gradient(180deg, #17191c 0%, #26282e 100%);
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
@media (max-width: 900px) { .auth-left { display: none; } }
.auth-left::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 70% 20%, rgba(245,166,35,0.1) 0%, transparent 60%),
              radial-gradient(ellipse at 10% 90%, rgba(255,75,50,0.08) 0%, transparent 50%);
}

.auth-left__inner {
  position: relative;
  z-index: 2;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.auth-left__shapes {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.auth-shape {
  position: absolute;
  border-radius: 50%;
  opacity: 0.12;
  background: white;
}
.auth-shape--1 { width: 300px; height: 300px; bottom: -80px; right: -80px; background: var(--gold); animation: float 8s ease-in-out infinite; }
.auth-shape--2 { width: 180px; height: 180px; top: 60px; right: 40px; background: var(--coral); animation: float 6s ease-in-out infinite reverse; }
.auth-shape--3 { width: 100px; height: 100px; top: 200px; left: 20px; background: white; animation: float 10s ease-in-out infinite; }

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-18px); }
}

/* LOGO */
.auth-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  margin-bottom: 2.5rem;
}
.auth-logo__icon img {
  width: 100%; height: 100%;
  object-fit: contain;
  border-radius: inherit;
}
.auth-logo__icon {
  width: 40px; height: 40px;
  background: rgba(255,255,255,0.2);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: white;
  border: 1px solid rgba(255,255,255,0.3);
}
.auth-logo__name {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 0.95rem;
  color: white;
  line-height: 1.3;
}
.auth-logo__name span { color: var(--gold); }
.auth-logo__sub {
  font-size: 0.7rem;
  color: rgba(255,255,255,0.6);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.1rem;
}

/* Dark logo variant (for centered card) */
.auth-logo--dark .auth-logo__icon { background: var(--primary-light); color: var(--primary); border-color: var(--primary-lighter); }
.auth-logo--dark .auth-logo__name { color: var(--white); }

/* LEFT CONTENT */
.auth-left__content { flex: 1; display: flex; flex-direction: column; justify-content: center; }

.auth-left__badge {
  display: inline-flex; align-items: center;
  background: rgba(245,166,35,0.2);
  border: 1px solid rgba(245,166,35,0.4);
  color: var(--gold);
  font-family: var(--font-heading);
  font-size: 0.75rem; font-weight: 700;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  margin-bottom: 1.25rem;
  width: fit-content;
}

.auth-left__title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 900;
  color: white;
  line-height: 1.1;
  margin-bottom: 1rem;
}
.auth-left__accent { color: var(--gold); }

.auth-left__desc {
  color: rgba(255,255,255,0.75);
  font-size: 0.95rem;
  line-height: 1.65;
  margin-bottom: 2rem;
}

/* TESTIMONIAL */
.auth-testimonial {
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  backdrop-filter: blur(8px);
  margin-bottom: 1.75rem;
}
.auth-testimonial__stars { color: var(--gold); font-size: 0.9rem; margin-bottom: 0.5rem; letter-spacing: 2px; }
.auth-testimonial__text { color: rgba(255,255,255,0.9); font-size: 0.875rem; line-height: 1.6; font-style: italic; margin-bottom: 0.75rem; }
.auth-testimonial__author { display: flex; align-items: center; gap: 0.6rem; }
.auth-testimonial__avatar { font-size: 1.5rem; }
.auth-testimonial__author strong { display: block; color: white; font-size: 0.82rem; font-weight: 700; }
.auth-testimonial__author span  { font-size: 0.72rem; color: rgba(255,255,255,0.6); }

/* STATS */
.auth-left__stats {
  display: flex;
  gap: 1.5rem;
}
.auth-stat { text-align: center; }
.auth-stat__num   { display: block; font-family: var(--font-heading); font-weight: 900; font-size: 1.5rem; color: white; }
.auth-stat__label { font-size: 0.72rem; color: rgba(255,255,255,0.6); }

/* PERKS (signup) */
.auth-perks { display: flex; flex-direction: column; gap: 1rem; }
.auth-perk {
  display: flex; align-items: flex-start; gap: 0.85rem;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: var(--radius);
  padding: 0.9rem 1rem;
}
.auth-perk__icon { font-size: 1.25rem; flex-shrink: 0; line-height: 1; }
.auth-perk strong { display: block; color: white; font-size: 0.875rem; font-weight: 700; margin-bottom: 0.2rem; }
.auth-perk span   { color: rgba(255,255,255,0.65); font-size: 0.78rem; line-height: 1.4; }

/* ─── RIGHT PANEL ───────────────────────────────────────────── */
.auth-right {
  flex: 1;
  background: var(--color-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2rem;
  overflow-y: auto;
}

.auth-right__inner {
  width: 100%;
  max-width: 420px;
}

.auth-right__header { margin-bottom: 1.75rem; }
.auth-form-title {
  font-family: var(--font-heading);
  font-size: 1.625rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 0.35rem;
}
.auth-form-sub { font-size: 0.875rem; color: var(--gray-500); }

/* GOOGLE BUTTON */
.google-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  padding: 0.85rem 1.25rem;
  background: var(--color-card);
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-lg);
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--white);
  cursor: pointer;
  transition: var(--transition);
  box-shadow: var(--shadow-sm);
}
.google-btn:hover { border-color: var(--gray-300); box-shadow: var(--shadow); background: var(--color-card-hover); }

/* DIVIDER */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.25rem 0;
  color: var(--gray-400);
  font-size: 0.78rem;
}
.auth-divider::before,
.auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--gray-200); }

/* ERROR BOX */
.auth-error {
  background: var(--rose-light);
  border: 1px solid rgba(239,68,68,0.4);
  color: var(--rose);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 1rem;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}
.auth-error::before { content: '⚠️'; flex-shrink: 0; }

/* FORM FIELD */
.auth-field { margin-bottom: 1rem; }

.auth-label {
  display: block;
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--gray-700);
  margin-bottom: 0.4rem;
}
.auth-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.4rem;
}
.auth-label-row .auth-label { margin-bottom: 0; }

/* INPUT */
.auth-input-wrap { position: relative; }
.auth-input {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1.5px solid var(--gray-200);
  border-radius: var(--radius-lg);
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--white);
  background: var(--color-card);
  transition: var(--transition);
  outline: none;
  box-sizing: border-box;
}
.auth-input:focus { border-color: var(--primary); background: var(--color-card-hover); box-shadow: 0 0 0 3px rgba(123,94,167,0.1); }
.auth-input::placeholder { color: var(--gray-400); }
.auth-input-wrap .auth-input { padding-right: 3rem; }

.auth-pw-toggle {
  position: absolute;
  right: 0.85rem; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  cursor: pointer; font-size: 1rem; line-height: 1;
  padding: 0.25rem;
  color: var(--gray-400);
}

/* CHECKBOX */
.auth-checkbox-row { display: flex; align-items: center; margin-bottom: 1.25rem; }
.auth-checkbox-label {
  display: flex; align-items: center; gap: 0.6rem;
  font-size: 0.875rem; color: var(--gray-600);
  cursor: pointer; user-select: none;
}
.auth-checkbox { display: none; }
.auth-checkbox-custom {
  width: 18px; height: 18px; flex-shrink: 0;
  border: 1.5px solid var(--gray-300);
  border-radius: 4px;
  background: var(--color-card);
  transition: var(--transition);
  position: relative;
}
.auth-checkbox:checked + .auth-checkbox-custom {
  background: var(--primary);
  border-color: var(--primary);
}
.auth-checkbox:checked + .auth-checkbox-custom::after {
  content: '';
  position: absolute;
  left: 4px; top: 1px;
  width: 5px; height: 9px;
  border: 2px solid white;
  border-top: none; border-left: none;
  transform: rotate(45deg);
}

/* SUBMIT BUTTON */
.auth-submit-btn {
  width: 100%;
  padding: 0.95rem 1.5rem;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border: none;
  border-radius: var(--radius-lg);
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: var(--transition);
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
  box-shadow: 0 4px 14px rgba(249,115,22,0.35);
  margin-top: 0.5rem;
}
.auth-submit-btn:hover { transform: translateY(-2px) scale(1.01); box-shadow: 0 10px 26px rgba(249,115,22,0.5); filter: brightness(1.06); }
.auth-submit-btn:disabled { opacity: 0.7; cursor: not-allowed; transform: none; }

/* SPINNER */
.auth-spinner {
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.35);
  border-top-color: white;
  border-radius: 50%;
  display: inline-block;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* FOOTER */
.auth-right__footer {
  margin-top: 1.5rem;
  text-align: center;
  font-size: 0.85rem;
  color: var(--gray-500);
}
.auth-right__footer p { margin: 0.25rem 0; }

/* LINKS */
.auth-link { color: var(--primary); text-decoration: none; font-weight: 600; }
.auth-link:hover { text-decoration: underline; }
.auth-link--small { font-size: 0.78rem; }

.auth-member-nudge {
  margin-top: 0.75rem !important;
  padding: 0.75rem;
  background: var(--primary-lighter);
  border-radius: var(--radius);
  font-size: 0.8rem !important;
  color: var(--primary-dark) !important;
}

/* STRENGTH METER */
.strength-meter {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.5rem;
}
.strength-meter__bar {
  flex: 1;
  height: 4px;
  background: var(--gray-200);
  border-radius: var(--radius-full);
  overflow: hidden;
}
.strength-meter__fill {
  height: 100%;
  width: 0%;
  border-radius: var(--radius-full);
  transition: width 0.3s ease, background 0.3s ease;
}
.strength-meter__label {
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  min-width: 42px;
  text-align: right;
}

/* ─── CENTERED CARD VARIANT (forgot password) ───────────────── */
.auth-page--centered {
  align-items: center;
  justify-content: center;
  background: var(--gray-50);
  padding: 2rem;
}
.auth-centered-card {
  background: var(--color-card);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--gray-100);
  width: 100%;
  max-width: 460px;
}

/* ─── NAV USER MENU ─────────────────────────────────────────── */
.nav__user { position: relative; }

.nav__user-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.75rem 0.35rem 0.35rem;
  background: var(--primary-light);
  border: 1.5px solid var(--primary-lighter);
  border-radius: var(--radius-full);
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary-dark);
  transition: var(--transition);
}
.nav__user-btn:hover { background: var(--primary-lighter); border-color: var(--primary); }

.nav__user-photo {
  width: 30px; height: 30px;
  border-radius: 50%;
  object-fit: cover;
}
.nav__user-initials {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.75rem;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.nav__user-name { max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.nav__user-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  background: var(--color-card);
  border: 1px solid var(--gray-200);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  min-width: 220px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  z-index: 200;
}
.nav__user-dropdown.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav__user-info {
  padding: 0.85rem 1rem;
}
.nav__user-info-name  { font-family: var(--font-heading); font-weight: 700; font-size: 0.875rem; color: var(--white); }
.nav__user-info-email { font-size: 0.75rem; color: var(--gray-400); margin-top: 0.15rem; word-break: break-all; }

.nav__user-dropdown-divider { height: 1px; background: var(--gray-100); margin: 0; }

.nav__user-dropdown-item {
  display: flex; align-items: center; gap: 0.6rem;
  width: 100%;
  padding: 0.65rem 1rem;
  font-family: var(--font-heading);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--gray-700);
  text-decoration: none;
  background: none; border: none;
  cursor: pointer;
  transition: background 0.15s ease;
  text-align: left;
}
.nav__user-dropdown-item:hover { background: var(--gray-50); color: var(--white); }

.nav__user-dropdown-signout { color: var(--rose); }
.nav__user-dropdown-signout:hover { background: var(--rose-light); color: var(--rose); }

/* ─── HELPER COLOUR VARS (if not in main styles.css) ────────── */
:root {
  --rose: #ef4444;
  --rose-light: rgba(239,68,68,0.15);
}
