.auth-section {
  min-height: calc(100vh - 160px);
  align-items: center;
  padding: clamp(28px, 5vw, 64px) 24px;
  background:
    radial-gradient(ellipse at 12% 10%, rgba(37, 99, 235, 0.09), transparent 36%),
    #f1f5f9;
  box-sizing: border-box;
}

.auth-container {
  width: min(1080px, 100%);
  min-height: 0;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 26px;
  box-shadow: 0 28px 75px rgba(15, 23, 42, 0.16);
}

.auth-branding {
  isolation: isolate;
  padding: clamp(34px, 5vw, 62px) clamp(28px, 4vw, 52px);
  background: url('/static/images/R+1d.jpg') center / cover no-repeat;
}

.auth-branding::before {
  z-index: -1;
  inset: 0;
  width: auto;
  height: auto;
  background: linear-gradient(145deg, rgba(9, 20, 43, 0.96), rgba(29, 78, 143, 0.84));
  animation: none;
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 42px;
}

.auth-logo-img {
  width: 68px;
  height: 68px;
  flex: 0 0 68px;
  margin: 0;
  padding: 7px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 17px;
  background: rgba(255, 255, 255, 0.12);
  object-fit: contain;
}

.auth-brand-name {
  margin: 0;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  line-height: 1.3;
}

.auth-tagline {
  margin: 0 0 14px;
  font-size: clamp(2rem, 4vw, 3rem);
  letter-spacing: -0.04em;
  line-height: 1.08;
}

.auth-description {
  max-width: 430px;
  margin: 0 0 27px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.97rem;
  line-height: 1.75;
}

.auth-features {
  gap: 10px;
}

.auth-feature-item {
  min-height: 54px;
  padding: 11px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.09);
  font-size: 0.9rem;
  font-weight: 600;
}

.auth-feature-item:hover {
  transform: translateX(3px);
}

.feature-icon {
  display: grid;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  place-items: center;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.13);
  font-size: 1.1rem;
}

.auth-form-container {
  padding: clamp(34px, 6vw, 72px);
}

.auth-form-box {
  max-width: 410px;
}

.auth-form-header {
  margin-bottom: 34px;
  text-align: left;
}

.auth-form-title {
  margin: 0 0 8px;
  color: #0f172a;
  font-size: clamp(1.8rem, 3vw, 2.2rem);
  letter-spacing: -0.04em;
}

.auth-form-subtitle {
  margin: 0;
  color: #64748b;
  font-size: 0.95rem;
}

.auth-input-group {
  margin-bottom: 21px;
}

.auth-label {
  margin-bottom: 9px;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 700;
}

.label-icon {
  font-size: 0.95rem;
}

.auth-input {
  min-height: 52px;
  padding: 13px 15px;
  border: 1px solid #cbd5e1;
  border-radius: 11px;
  color: #0f172a;
  background: #f8fafc;
  box-sizing: border-box;
}

.auth-input::placeholder {
  color: #94a3b8;
}

.auth-input:focus {
  border-color: #2563eb;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.12);
}

.password-input-wrapper .auth-input {
  padding-right: 52px;
}

.password-toggle {
  right: 8px;
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
}

.password-toggle:hover {
  color: #1d4ed8;
  background: #eff6ff;
}

.password-toggle:focus-visible,
.forgot-password:focus-visible,
.auth-submit-btn:focus-visible {
  outline: 3px solid rgba(37, 99, 235, 0.3);
  outline-offset: 3px;
}

.auth-options {
  gap: 12px;
  margin: 5px 0 25px;
  color: #475569;
  font-size: 0.85rem;
}

.remember-me {
  gap: 9px;
}

.remember-me input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: #2563eb;
}

.forgot-password {
  color: #1d4ed8;
  font-weight: 700;
}

.forgot-password:hover {
  color: #1e40af;
  text-decoration: underline;
}

.auth-submit-btn {
  min-height: 54px;
  padding: 14px 18px;
  border-radius: 11px;
  background: linear-gradient(110deg, #1d4ed8, #2563eb);
  font-size: 0.98rem;
  font-weight: 750;
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.22);
}

.auth-submit-btn:hover {
  background: linear-gradient(110deg, #1e40af, #1d4ed8);
  transform: translateY(-1px);
  box-shadow: 0 13px 26px rgba(37, 99, 235, 0.28);
}

.btn-icon {
  font-size: 1.2rem;
}

.auth-flash-messages {
  top: 18px;
  right: 18px;
  width: min(400px, calc(100% - 36px));
}

.auth-flash-messages .auth-alert {
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.16);
}

@media (max-width: 800px) {
  .auth-section {
    min-height: 0;
    padding: 28px 18px 42px;
  }

  .auth-container {
    max-width: 600px;
    grid-template-columns: 1fr;
  }

  .auth-branding {
    padding: 34px clamp(24px, 7vw, 44px);
  }

  .auth-logo {
    margin-bottom: 28px;
  }

  .auth-description {
    margin-bottom: 20px;
  }

  .auth-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(145px, 1fr));
  }

  .auth-feature-item {
    gap: 9px;
    padding: 10px;
    font-size: 0.78rem;
  }

  .auth-form-container {
    padding: clamp(30px, 7vw, 48px);
  }
}

@media (max-width: 420px) {
  .auth-section {
    padding: 16px 12px 28px;
  }

  .auth-container {
    border-radius: 18px;
  }

  .auth-logo {
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 24px;
  }

  .auth-logo-img {
    width: 54px;
    height: 54px;
    flex-basis: 54px;
  }

  .auth-brand-name {
    padding-top: 6px;
    font-size: 1.05rem;
  }

  .auth-tagline {
    font-size: 2rem;
  }

  .auth-options {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  .auth-container,
  .auth-feature-item,
  .auth-submit-btn {
    animation: none;
    transition: none;
  }
}
