/* auth.html — Bootstrap base + design-specific overrides */

.auth-page {
  --auth-primary: #74a1d3;
  --auth-primary-hover: #6392c4;
  --auth-label: #2b2b2b;
  --auth-muted: #9a9a9a;
  --auth-placeholder: #b5b5b5;
  --auth-border: #e3e3e3;
  --auth-link: #74a1d3;
  --auth-radius-lg: 3rem;
  --auth-radius: 0.75rem;
  --auth-transition: 0.22s ease;
  --bs-body-bg: #ffffff;
  height: 100dvh;
  overflow: hidden;
  background: #ffffff;
}

.auth-shell,
.auth-shell__row {
  height: 100dvh;
  min-height: 0;
}

@media (max-width: 991.98px) {
  .auth-shell__row {
    flex-direction: column;
    flex-wrap: nowrap;
  }
}

@media (min-width: 992px) {
  .auth-shell__row > [class*="col-"] {
    height: 100%;
    min-height: 0;
  }
}

.auth-page .btn-primary {
  --bs-btn-bg: var(--auth-primary);
  --bs-btn-border-color: var(--auth-primary);
  --bs-btn-hover-bg: var(--auth-primary-hover);
  --bs-btn-hover-border-color: var(--auth-primary-hover);
  --bs-btn-active-bg: var(--auth-primary-hover);
  --bs-btn-active-border-color: var(--auth-primary-hover);
  --bs-btn-focus-shadow-rgb: 116, 161, 211;
}

/* —— Left visual —— */

.auth-visual {
  position: relative;
  min-height: 0;
  overflow: hidden;
}

@media (min-width: 992px) {
  .auth-visual {
    height: 100%;
  }
}

@media (max-width: 991.98px) {
  .auth-visual {
    flex: 0 0 auto;
    height: clamp(9rem, 24vh, 12rem);
  }
}

.auth-visual__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.auth-visual__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.42) 0%, rgba(0, 0, 0, 0.1) 55%, transparent 100%);
}

.auth-visual__card {
  position: absolute;
  left: clamp(1rem, 3vw, 2rem);
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1rem, 3vw, 2rem);
  padding: 1.1rem 1.25rem 1rem;
  border-radius: 12px;
  background: rgba(196, 170, 140, 0.58);
  backdrop-filter: blur(6px);
  color: #fff;
}

.auth-visual__title {
  margin: 0 0 0.3rem;
  font-family: var(--font-heading, "Titillium Web", sans-serif);
  font-size: clamp(1.05rem, 2vw, 1.35rem);
  font-weight: 600;
  line-height: 1.3;
}

.auth-visual__subtitle {
  margin: 0 0 0.85rem;
  font-size: 0.8125rem;
  line-height: 1.4;
}

.auth-visual__dots {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.auth-visual__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
}

.auth-visual__dot--active {
  width: 8px;
  height: 8px;
  background: transparent;
  box-shadow: 0 0 0 2px #fff;
}

/* —— Form card —— */

.auth-stage {
  background: #ffffff;
  padding: 0;
  min-height: 0;
}

@media (min-width: 992px) {
  .auth-stage {
    height: 100%;
    overflow: hidden;
  }
}

@media (max-width: 991.98px) {
  .auth-stage {
    flex: 1 1 auto;
    min-height: 0;
    overflow-y: auto;
  }
}

.auth-card {
  width: 100%;
  margin-inline: 0;
  padding: clamp(1.25rem, 3vh, 2rem) clamp(1.5rem, 4vw, 2.5rem);
  background: #ffffff;
  border-radius: 0;
  box-shadow: none;
}

@media (min-width: 992px) {
  .auth-card {
    height: 100%;
    padding: clamp(1.25rem, 2.5vh, 2rem) clamp(2rem, 4vw, 3rem);
    border-top-left-radius: var(--auth-radius-lg);
    border-bottom-left-radius: var(--auth-radius-lg);
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
  }
}

.auth-card__inner {
  width: 100%;
  max-width: 420px;
  margin-inline: auto;
  flex: 0 1 auto;
  min-height: 0;
}

@media (max-width: 991.98px) {
  .auth-card {
    border-top-left-radius: var(--auth-radius-lg);
    border-top-right-radius: var(--auth-radius-lg);
  }
}

.auth-brand img {
  width: min(100%, 210px);
  height: auto;
}

/* —— Bootstrap form overrides —— */

.auth-heading {
  font-family: var(--font-heading, "Titillium Web", sans-serif);
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--auth-label);
}

.auth-page .form-label {
  margin-bottom: 0.35rem;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--auth-label);
}

.auth-page .form-control {
  height: 2.875rem;
  padding: 0.5rem 0.9rem;
  font-size: 0.875rem;
  color: var(--auth-label);
  border: 1px solid var(--auth-border);
  border-radius: 8px;
}

.auth-page .form-control::placeholder {
  color: var(--auth-placeholder);
  opacity: 1;
}

.auth-page .form-control:focus {
  border-color: var(--auth-primary);
  box-shadow: 0 0 0 0.2rem rgba(116, 161, 211, 0.22);
}

.auth-password-wrap .form-control {
  padding-right: 2.75rem;
}

.auth-password-wrap {
  position: relative;
}

.auth-toggle-pw {
  position: absolute;
  top: 50%;
  right: 0.7rem;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  padding: 0;
  border: 0;
  background: transparent;
  color: #b0b0b0;
  line-height: 1;
}

.auth-toggle-pw:hover {
  color: var(--auth-muted);
}

.auth-toggle-pw svg {
  width: 1.125rem;
  height: 1.125rem;
}

.auth-forgot-link {
  font-size: 0.8125rem;
  color: var(--auth-muted) !important;
  text-decoration: none;
}

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

.auth-btn {
  height: 2.875rem;
  font-size: 0.9375rem;
  font-weight: 700;
  border-radius: 8px;
}

.auth-divider-text {
  font-size: 0.8125rem;
  color: var(--auth-muted);
}

.auth-google {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  padding: 0;
  border: 0;
  background: transparent;
  border-radius: 50%;
  cursor: pointer;
}

.auth-google:hover {
  background: #f3f3f3;
}

.auth-google svg {
  width: 1.25rem;
  height: 1.25rem;
}

.auth-footer-text {
  font-size: 0.8125rem;
  color: var(--auth-muted);
  margin-bottom: 0;
}

.auth-form .mb-3 {
  margin-bottom: 0.75rem !important;
}

.auth-form .mb-4 {
  margin-bottom: 1rem !important;
}

.auth-footer-text a {
  color: var(--auth-link);
  font-weight: 500;
  text-decoration: none;
}

.auth-footer-text a:hover {
  text-decoration: underline;
}

/* —— Panel transitions —— */

.auth-panels-viewport {
  display: grid;
  position: relative;
  min-height: 0;
  overflow: hidden;
}

.auth-panel {
  grid-area: 1 / 1;
  align-self: start;
  width: 100%;
  visibility: hidden;
  opacity: 0;
  transform: translateY(4px);
  pointer-events: none;
  transition:
    opacity 0.16s ease,
    transform 0.16s ease,
    visibility 0.16s ease;
}

.auth-panel--active {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
  transition:
    opacity 0.22s ease,
    transform 0.22s ease,
    visibility 0s;
}

@media (prefers-reduced-motion: reduce) {
  .auth-panel {
    transition: none;
  }
}
