body {
  background: #4a90d6;
}
.card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 100%;
  max-width: 920px;
  min-height: 520px;
  background: #ffffff;
  border-radius: 4px;
  overflow: hidden;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  box-shadow:
    0 16px 60px rgba(0, 32, 70, 0.18),
    0 2px 6px rgba(0, 32, 70, 0.06);
}

.hero {
  position: relative;
  /* background: linear-gradient(180deg, #1c1f25 0%, #2a2d33 100%); */
  overflow: hidden;
  background: url('../images/login-left.jpg') no-repeat center center;
  background-size: cover;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url('mqqrw1ny-image.png') center/cover no-repeat;
  opacity: 0.92;
}
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0.05) 30%, rgba(0, 0, 0, 0.05) 70%, rgba(0, 0, 0, 0.45) 100%);
}
.hero-label {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 24px;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  z-index: 1;
}

/* ===== right side ===== */
.auth {
  padding: 36px 44px 32px;
  display: flex;
  flex-direction: column;
}

.tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  margin-bottom: 24px;
}
.tab {
  flex: 1;
  padding: 14px 0;
  background: transparent;
  border: 0;
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  color: #6b7280;
  cursor: pointer;
  position: relative;
  transition: color 0.15s ease;
}
.tab.is-active {
  color: var(--accent);
}
.tab.is-active::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -1px;
  transform: translateX(-50%);
  width: 80%;
  height: 2px;
  background: var(--accent);
}
.tab:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 3px;
}

.panel {
  display: none;
  flex: 1;
}
.panel.is-active {
  display: block;
}

.field {
  margin-bottom: 16px;
  position: relative;
}
.field label {
  display: inline-block;
  font-size: 13px;
  font-weight: 500;
  color: #374151;
  margin-bottom: 6px;
}
.input {
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: 3px;
  background: #ffffff;
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.input:hover {
  border-color: #9ca3af;
}
.input:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(35, 90, 142, 0.12);
}
.input input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  font: inherit;
  font-size: 14px;
  padding: 11px 12px;
  height: 42px;
  color: #1c1b1a;
}
.input input::placeholder {
  color: #9ca3af;
}
.input .send-btn {
  flex-shrink: 0;
  height: 42px;
  padding: 0 16px;
  border: 0;
  border-left: 1px solid var(--border);
  background: #f8fafc;
  color: var(--accent);
  font: inherit;
  font-size: 13px;
  cursor: pointer;
  transition: background 0.15s ease;
  border-radius: 0;
}
.input .send-btn:hover:not(:disabled) {
  background: #eef4fb;
}
.input .send-btn:disabled {
  color: #9ca3af;
  cursor: not-allowed;
}

.agree {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  color: #4b5563;
  margin: 4px 0 18px;
  line-height: 1.5;
}
.agree input[type='radio'] {
  margin-top: 3px;
  accent-color: var(--accent);
}
.agree a {
  color: var(--accent);
}
.agree a:hover {
  text-decoration: underline;
}

.btn {
  width: 100%;
  padding: 12px 16px;
  border: 0;
  border-radius: 3px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background 0.15s ease;
}
.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.btn-primary {
  background: var(--accent);
  color: #ffffff;
}
.btn-primary:hover {
  background: var(--accent-hover);
}
.btn-ghost {
  background: #ffffff;
  color: #1c1b1a;
  border: 1px solid var(--border);
  margin-top: 12px;
  display: inline-block;
  text-align: center;
}
.btn-ghost:hover {
  background: #f3f7fb;
}

/* ===== formatters ===== */
.field-error {
  display: none;
  color: #dc2626;
  font-size: 12px;
  margin-top: 4px;
  position: absolute;
  left: 0;
  top: 100%;
  padding-top: 0px;
  text-align: right;
  right: 0;
}
.field.is-error label {
  color: #dc2626;
}
.field.is-error .input {
  border-color: #dc2626;
}
.field.is-error .field-error {
  display: block;
}

/* ===== toasts ===== */
.toast {
  position: fixed;
  top: 32px;
  left: 50%;
  transform: translateX(-50%);
  background: #1c1b1a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 6px;
  font-size: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  z-index: 999;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 0.18s ease,
    transform 0.18s ease;
}
.toast.is-show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}
.toast.is-error {
  background: #c8392b;
}
.toast.is-success {
  background: #2a7a3f;
}

/* ===== responsive ===== */
@media (max-width: 720px) {
  .card {
    grid-template-columns: 1fr;
    max-width: 460px;
    min-height: 0;
  }
  .hero {
    min-height: 180px;
  }
  .hero::before {
    background-position: center 25%;
  }
  .auth {
    padding: 28px 24px;
  }
}
@media (max-width: 420px) {
  body {
    padding: 0;
  }
  .card {
    border-radius: 0;
    min-height: 100vh;
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition: none !important;
  }
}
