/* Auth pages — layout chrome only; colors come from site.css tokens */

body.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: var(--bg);
  color: var(--t1);
  font-family: var(--ff);
}

.auth-container {
  background: var(--bg2);
  border: 1px solid var(--b1);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  width: 100%;
  max-width: 1000px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 600px;
}

.auth-container.auth-register {
  min-height: 700px;
}

.auth-left {
  background: var(--bg3);
  border-right: 1px solid var(--b1);
  padding: 60px 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: var(--t1);
  position: relative;
  overflow: hidden;
}

.auth-left::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 20%, var(--agl), transparent 55%),
    radial-gradient(ellipse 70% 50% at 90% 80%, var(--abl), transparent 50%);
  pointer-events: none;
}

.auth-left-content {
  position: relative;
  z-index: 1;
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 40px;
}

.auth-brand a {
  display: flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.auth-logo-icon {
  width: 48px;
  height: 48px;
  background: var(--acc);
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.auth-logo-icon svg {
  width: 24px;
  height: 24px;
  color: #fff;
}

.auth-brand-name {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.5px;
  color: var(--t1);
}

.auth-brand-name span {
  color: var(--acc);
}

.auth-left h1 {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 20px;
  letter-spacing: -0.03em;
  color: var(--t1);
}

.auth-left > .auth-left-content > p,
.auth-left-content > p {
  font-size: 16px;
  line-height: 1.6;
  color: var(--t2);
  margin-bottom: 40px;
}

.auth-features {
  list-style: none;
  margin: 0;
  padding: 0;
}

.auth-features li {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 15px;
  color: var(--t1);
}

.auth-check {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  background: var(--agl);
  border: 1px solid var(--abl);
  color: var(--acc);
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 13px;
  font-weight: 700;
}

.auth-right {
  padding: 60px 50px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--bg2);
}

.auth-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--t3);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 24px;
  transition: color 0.15s ease;
  width: fit-content;
}

.auth-back:hover {
  color: var(--acc);
}

.auth-header {
  margin-bottom: 28px;
}

.auth-header h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--t1);
  margin-bottom: 8px;
}

.auth-header p {
  color: var(--t2);
  font-size: 15px;
}

.auth-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.auth-form-group {
  margin-bottom: 20px;
}

.auth-label {
  display: block;
  font-size: 14px;
  font-weight: 500;
  color: var(--t1);
  margin-bottom: 8px;
}

.auth-input {
  width: 100%;
  padding: 14px 16px;
  border: 1.5px solid var(--b1);
  border-radius: var(--r);
  font-size: 15px;
  font-family: inherit;
  background: var(--bg);
  color: var(--t1);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.auth-input::placeholder {
  color: var(--t3);
}

.auth-input:focus {
  outline: none;
  border-color: var(--acc);
  box-shadow: 0 0 0 3px var(--agl);
}

.auth-input.input-invalid {
  border-color: var(--red) !important;
}

.auth-field-error {
  color: var(--red);
  font-size: 13px;
  margin-top: 4px;
  display: block;
}

.auth-form-options {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.auth-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--t2);
  cursor: pointer;
}

.auth-checkbox input {
  width: 18px;
  height: 18px;
  accent-color: var(--acc);
  cursor: pointer;
}

.auth-link {
  color: var(--acc);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
}

.auth-link:hover {
  text-decoration: underline;
}

.auth-btn-primary {
  width: 100%;
  padding: 14px 16px;
  background: var(--acc);
  color: #fff;
  border: 1px solid var(--acc);
  border-radius: var(--r);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.auth-btn-primary:hover {
  background: var(--acc-dark);
  border-color: var(--acc-dark);
}

.auth-btn-primary:focus-visible {
  outline: 2px solid var(--acc);
  outline-offset: 2px;
}

.auth-divider {
  display: flex;
  align-items: center;
  margin: 28px 0;
  color: var(--t3);
  font-size: 14px;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--b1);
}

.auth-divider span {
  padding: 0 16px;
}

.auth-btn-google {
  width: 100%;
  padding: 14px;
  background: var(--bg2);
  color: var(--t1);
  border: 1.5px solid var(--b1);
  border-radius: var(--r);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.auth-btn-google:hover {
  background: var(--bg3);
  border-color: var(--b2);
}

.auth-google-icon {
  width: 20px;
  height: 20px;
}

.auth-footer {
  text-align: center;
  margin-top: 28px;
  color: var(--t2);
  font-size: 15px;
}

.auth-footer a {
  color: var(--acc);
  text-decoration: none;
  font-weight: 600;
}

.auth-footer a:hover {
  text-decoration: underline;
}

.auth-validation {
  background: var(--red2);
  border: 1px solid var(--red);
  color: var(--red);
  padding: 14px 16px;
  border-radius: var(--r);
  margin-bottom: 20px;
  font-size: 14px;
  line-height: 1.5;
}

.auth-validation ul {
  margin: 0;
  padding-left: 1.1rem;
}

.auth-hint {
  background: var(--agl);
  border: 1px solid var(--abl);
  color: var(--t1);
  padding: 14px 16px;
  border-radius: var(--r);
  margin-bottom: 20px;
  font-size: 14px;
  line-height: 1.55;
}

.auth-hint a,
.auth-hint strong {
  color: var(--acc);
  font-weight: 600;
  text-decoration: none;
}

.auth-hint a:hover {
  text-decoration: underline;
}

.auth-hint--success {
  background: var(--grn2);
  border-color: var(--grn);
}

.auth-hint--success,
.auth-hint--success a,
.auth-hint--success strong {
  color: var(--grn);
}

.auth-email-status {
  font-size: 13px;
  margin-top: 6px;
  min-height: 1.25em;
}

.auth-email-status.ok {
  color: var(--grn);
}

.auth-email-status.taken {
  color: var(--red);
}

.auth-email-status.checking {
  color: var(--t3);
}

.auth-terms {
  font-size: 13px;
  color: var(--t3);
  line-height: 1.6;
  margin-top: 12px;
  margin-bottom: 4px;
}

.auth-terms a {
  color: var(--acc);
  text-decoration: none;
}

.auth-terms a:hover {
  text-decoration: underline;
}

.auth-theme-bar {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
}

.auth-theme-toggle {
  box-sizing: border-box;
  height: 36px;
  border-radius: 8px;
  border: 1px solid var(--b1);
  background: var(--bg2);
  color: var(--t2);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 11px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1;
  cursor: pointer;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}

.auth-theme-toggle:hover {
  background: var(--bg3);
  color: var(--t1);
  border-color: var(--b2);
}

@media (max-width: 768px) {
  body.auth-page {
    padding: 12px;
    align-items: flex-start;
  }

  .auth-container,
  .auth-container.auth-register {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .auth-left {
    display: none;
  }

  .auth-right {
    padding: 28px 20px;
  }

  .auth-form-row {
    grid-template-columns: 1fr;
  }

  .auth-header {
    margin-bottom: 20px;
  }

  .auth-theme-bar {
    position: fixed;
    top: 12px;
    right: 12px;
  }
}

@media (max-width: 375px) {
  body.auth-page {
    padding: 8px;
  }

  .auth-right {
    padding: 24px 16px;
  }

  .auth-input,
  .auth-btn-primary,
  .auth-btn-google {
    padding: 12px 14px;
  }
}
