:root {
  --auth-bg-0: #f6f8fc;
  --auth-bg-1: #eef2ff;
  --auth-card: #ffffff;
  --auth-border: #e5e7eb;
  --auth-text: #111827;
  --auth-muted: #6b7280;
  --auth-primary: #4f46e5;
  --auth-primary-hover: #4338ca;
  --auth-danger-bg: #fef2f2;
  --auth-danger-text: #991b1b;
  --auth-shadow: 0 20px 40px rgba(15, 23, 42, 0.08);
}

main {
  min-height: calc(100vh - 72px);
}

.auth-page {
  min-height: calc(100vh - 72px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 96px 16px 40px;
  background:
    radial-gradient(circle at 10% 10%, #dbeafe 0%, transparent 35%),
    radial-gradient(circle at 90% 90%, #e0e7ff 0%, transparent 35%),
    linear-gradient(180deg, var(--auth-bg-1), var(--auth-bg-0));
}

.auth-wrap {
  width: 100%;
  max-width: 460px;
}

.auth-card {
  background: var(--auth-card);
  border: 1px solid var(--auth-border);
  border-radius: 20px;
  box-shadow: var(--auth-shadow);
  padding: 28px;
}

.auth-title {
  margin: 0 0 8px;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--auth-text);
  letter-spacing: -0.02em;
}

.auth-subtitle {
  margin: 0 0 20px;
  font-size: 0.95rem;
  color: var(--auth-muted);
  line-height: 1.6;
}

.auth-form {
  display: grid;
  gap: 12px;
}

.auth-form .form-control,
.auth-form input[type="password"],
.auth-form input[type="email"],
.auth-form input[type="text"] {
  width: 100%;
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--auth-border);
  padding: 10px 12px;
  font-size: 0.95rem;
  color: var(--auth-text);
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.auth-form .form-control:focus,
.auth-form input:focus {
  outline: 0;
  border-color: var(--auth-primary);
  box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.12);
}

.auth-form textarea.form-control {
  min-height: 100px;
}

.auth-form .invalid-feedback {
  display: block;
  margin-top: 6px;
  font-size: 0.82rem;
}

.auth-inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 4px 0 6px;
}

.auth-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--auth-muted);
  font-size: 0.88rem;
}

.auth-btn {
  width: 100%;
  border: 0;
  border-radius: 12px;
  background: var(--auth-primary);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 12px 14px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.05s ease;
}

.auth-btn:hover {
  background: var(--auth-primary-hover);
}

.auth-btn:active {
  transform: translateY(1px);
}

.auth-links {
  margin-top: 14px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.auth-links a,
.auth-help a {
  color: var(--auth-primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
}

.auth-links a:hover,
.auth-help a:hover {
  text-decoration: underline;
}

.auth-help {
  margin-top: 16px;
  text-align: center;
  color: var(--auth-muted);
  font-size: 0.9rem;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 0;
  color: #9ca3af;
  font-size: 0.82rem;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--auth-border);
}

.social-grid {
  display: grid;
  gap: 10px;
}

.social-btn {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--auth-border);
  background: #fff;
  color: #111827;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.92rem;
  font-weight: 600;
  min-height: 44px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.social-btn:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
}

.social-btn.kakao {
  background: #fee500;
  border-color: #f4df00;
  color: #191919;
}

.social-btn.kakao:hover {
  background: #f9df00;
}

.auth-alert {
  border: 1px solid #fecaca;
  background: var(--auth-danger-bg);
  color: var(--auth-danger-text);
  border-radius: 12px;
  padding: 10px 12px;
  margin-bottom: 12px;
  font-size: 0.88rem;
}

.auth-note {
  border: 1px solid #dbeafe;
  background: #eff6ff;
  color: #1e3a8a;
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 14px;
  font-size: 0.9rem;
  line-height: 1.6;
}

@media (max-width: 576px) {
  .auth-page {
    padding-top: 84px;
  }

  .auth-card {
    border-radius: 16px;
    padding: 22px 18px;
  }

  .auth-title {
    font-size: 1.35rem;
  }
}
