/* ============================================
   SPEECH EZ SKOOL — Auth Modal Styles
   ============================================ */

/* Overlay */
.auth-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(15, 30, 50, 0);
  backdrop-filter: blur(0px);
  transition: all 0.3s ease;
  padding: 1rem;
}

.auth-modal-overlay--active {
  background: rgba(15, 30, 50, 0.6);
  backdrop-filter: blur(8px);
}

.auth-modal-overlay--closing {
  background: rgba(15, 30, 50, 0) !important;
  backdrop-filter: blur(0px) !important;
}

.auth-modal-overlay--closing .auth-modal {
  transform: scale(0.95) translateY(10px);
  opacity: 0;
}

body.auth-modal-open {
  overflow: hidden;
}

/* Modal */
.auth-modal {
  background: white;
  border-radius: 20px;
  box-shadow: 0 25px 60px rgba(0,0,0,0.15), 0 0 0 1px rgba(0,0,0,0.05);
  width: 100%;
  max-width: 420px;
  transform: scale(0.95) translateY(10px);
  opacity: 0;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.auth-modal-overlay--active .auth-modal {
  transform: scale(1) translateY(0);
  opacity: 1;
}

/* Header */
.auth-modal__header {
  padding: 2rem 2rem 0;
  text-align: center;
}

.auth-modal__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.auth-modal__logo {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-primary-dark, #3a9d8f));
  color: white;
  font-weight: 800;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  letter-spacing: -0.5px;
}

.auth-modal__brand-name {
  font-family: var(--font-display, var(--font-body));
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--color-navy, #1a2e44);
  line-height: 1.2;
}

.auth-modal__brand-sub {
  font-size: 0.75rem;
  color: var(--color-text-muted, #8896a6);
  font-weight: 500;
}

/* Body */
.auth-modal__body {
  padding: 1.5rem 2rem 2rem;
}

.auth-modal__title {
  font-family: var(--font-display, var(--font-body));
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--color-navy, #1a2e44);
  margin: 0 0 0.25rem;
  text-align: center;
}

.auth-modal__subtitle {
  font-size: 0.9rem;
  color: var(--color-text-muted, #8896a6);
  margin: 0 0 1.5rem;
  text-align: center;
}

/* Form */
.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.auth-form__group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.auth-form__label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-text, #2d3748);
  letter-spacing: 0.01em;
}

.auth-form__input {
  padding: 12px 14px;
  border: 2px solid #e2e8f0;
  border-radius: 10px;
  font-size: 15px;
  font-family: var(--font-body, 'Inter', sans-serif);
  color: var(--color-text, #2d3748);
  background: #fafbfc;
  transition: all 0.2s ease;
  outline: none;
}

.auth-form__input:focus {
  border-color: var(--color-primary, #4bb5a5);
  background: white;
  box-shadow: 0 0 0 3px rgba(75, 181, 165, 0.12);
}

.auth-form__input::placeholder {
  color: #b0bcc8;
}

.auth-form__forgot {
  background: none;
  border: none;
  color: var(--color-primary, #4bb5a5);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  text-align: right;
  padding: 0;
  margin-top: -0.5rem;
}
.auth-form__forgot:hover {
  text-decoration: underline;
}

.auth-form__submit {
  padding: 13px;
  border: none;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--color-primary, #4bb5a5), var(--color-primary-dark, #3a9d8f));
  color: white;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-body, 'Inter', sans-serif);
  cursor: pointer;
  transition: all 0.2s ease;
  margin-top: 0.25rem;
}

.auth-form__submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(75, 181, 165, 0.35);
}

.auth-form__submit:active {
  transform: translateY(0);
}

.auth-form__submit:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.auth-form__error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.85rem;
  font-weight: 500;
  text-align: center;
}

.auth-form__success {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  color: #166534;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 0.85rem;
  font-weight: 500;
  text-align: center;
}

/* Footer */
.auth-modal__footer {
  text-align: center;
  padding-top: 1.25rem;
  border-top: 1px solid #f0f2f5;
  margin-top: 1.5rem;
  font-size: 0.85rem;
  color: var(--color-text-muted, #8896a6);
}

.auth-form__link {
  background: none;
  border: none;
  color: var(--color-primary, #4bb5a5);
  font-weight: 600;
  cursor: pointer;
  font-size: 0.85rem;
  padding: 0;
}
.auth-form__link:hover {
  text-decoration: underline;
}

/* Logout button in sidebar */
.sidebar__logout {
  background: none;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--color-text-muted, #8896a6);
  cursor: pointer;
  transition: all 0.15s ease;
  width: 100%;
  margin-top: 0.5rem;
  font-family: var(--font-body, 'Inter', sans-serif);
}

.sidebar__logout:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #b91c1c;
}

/* Responsive */
@media (max-width: 480px) {
  .auth-modal {
    max-width: 100%;
    border-radius: 16px;
  }

  .auth-modal__body {
    padding: 1.25rem 1.5rem 1.75rem;
  }
}
