.auth-container {
  display: flex;
  min-height: 100vh;
  width: 100%;
  background-color: var(--bg-cream);
  overflow-y: auto;
}

.auth-sidebar {
  display: none;
  width: 45%;
  background-color: var(--navy-dark);
  color: var(--white);
  padding: 4rem;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

@media (min-width: 900px) {
  .auth-sidebar {
    display: flex;
  }
}

.auth-sidebar::before {
  content: '';
  position: absolute;
  top: -10%;
  right: -10%;
  width: 400px;
  height: 400px;
  background-color: rgba(246, 145, 118, 0.15);
  border-radius: 50%;
  filter: blur(80px);
}

.auth-sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  position: absolute;
  top: 4rem;
  left: 4rem;
}

.auth-sidebar-logo h1 {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--white);
}

.auth-sidebar-content {
  max-width: 420px;
}

.auth-sidebar-content h2 {
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: var(--white);
}

.auth-sidebar-content p {
  font-size: 1.1rem;
  opacity: 0.8;
  line-height: 1.6;
}

.auth-form-panel {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6rem;
}

.auth-form-panel-compact {
    align-items: flex-start;
    padding-top: 10rem;
}

.auth-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 420px;
  padding: 3rem 2.5rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-light);
}

.auth-header {
  margin-bottom: 2rem;
}

.auth-header h3 {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--navy-dark);
  margin-bottom: 6px;
}

.auth-header p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-group label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.input-wrapper {
  position: relative;
}

.form-input {
  width: 100%;
  background-color: var(--bg-cream);
  border: 1px solid rgba(34, 62, 91, 0.05);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  color: var(--navy-dark);
  transition: var(--transition-smooth);
}

.form-input:focus {
  outline: none;
  border-color: var(--coral-accent);
  background-color: var(--white);
  box-shadow: 0 0 0 4px rgba(246, 145, 118, 0.1);
}

.auth-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

.remember-me {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}

.remember-me input {
  cursor: pointer;
}

.forgot-link {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--coral-accent);
  text-decoration: none;
}

.forgot-link:hover {
  color: var(--coral-hover);
  text-decoration: underline;
}

.btn-submit {
  width: 100%;
  padding: 14px;
  font-size: 0.9rem;
}

.auth-footer {
  margin-top: 2rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.auth-footer a {
  color: var(--navy-dark);
  font-weight: 700;
  text-decoration: none;
}

.auth-footer a:hover {
  text-decoration: underline;
  color: var(--coral-accent);
}

.alert {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 10px;
}

.alert-error {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fca5a5;
}

.alert-success {
  background-color: var(--teal-light);
  color: var(--teal-dark);
  border: 1px solid rgba(27, 77, 62, 0.1);
}

/* =========================================
   AUTH PAGE OVERRIDES
   Prevent global layout styles from
   affecting login/register pages
========================================= */

body:has(.auth-container) {
    display: block;
    overflow: auto;
    background-color: var(--bg-cream);
}

.auth-container {
    width: 100%;
    min-height: 100vh;
    height: 100vh;

    display: flex;
    flex-direction: row;

    background-color: var(--bg-cream);
    overflow: hidden;
}

.auth-sidebar {
    flex: 0 0 45%;
    width: 45%;
    min-height: 100vh;
}

.auth-form-panel {
    flex: 1;
    min-width: 0;
    min-height: 100vh;
    overflow-y: auto;
}

/* Reset the global header styles from style.css */
.auth-header {
    display: block;
    height: auto;
    padding: 0;
    margin-bottom: 2rem;

    background-color: transparent;
    border: none;
}

/* Keep the heading and description stacked */
.auth-header h3,
.auth-header p {
    display: block;
    width: 100%;
}

.auth-header h3 {
    margin-bottom: 6px;
}

/* Prevent the logo from being compressed */
.auth-sidebar-logo {
    width: auto;
}

/* Responsive auth layout */
@media (max-width: 899px) {
    .auth-container {
        height: auto;
        min-height: 100vh;
        flex-direction: column;
        overflow-y: auto;
    }

    .auth-sidebar {
        display: none;
    }

    .auth-form-panel {
        width: 100%;
        min-height: 100vh;
        padding: 2rem 1rem;
    }

    .auth-card {
        padding: 2.25rem 1.5rem;
    }
}

.auth-sidebar-logo .brand-icon {
    flex-shrink: 0;
}

.auth-sidebar-logo h1 {
    margin: 0;
    line-height: 1;
    white-space: nowrap;
}