.jj-login-drawer {
  position: fixed;
  inset: 0;
  z-index: 400;
  display: none;
  pointer-events: none;
}

.jj-login-drawer.is-open {
  display: block;
  pointer-events: auto;
}

.jj-login-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  opacity: 0;
  transition: opacity 0.32s ease;
}

.jj-login-drawer.is-open .jj-login-drawer__backdrop {
  opacity: 1;
}

.jj-login-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  width: min(100%, 520px);
  height: 100%;
  background: #fff;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.12);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  transform: translateX(100%);
  transition: transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
}

.jj-login-drawer.is-open .jj-login-drawer__panel {
  transform: translateX(0);
}

.jj-login-drawer__close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 2;
  border: none;
  background: transparent;
  color: #1a1a1a;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  padding: 4px;
}

.jj-login-drawer__body {
  padding: 56px 40px 48px;
}

.jj-login-drawer__note {
  margin: 0 0 8px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 12px;
  color: #6b6b6b;
}

.jj-login-drawer__title {
  margin: 0 0 32px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: #111;
}

.jj-login-drawer__section {
  margin-bottom: 28px;
}

.jj-login-drawer__section-title {
  margin: 0 0 20px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #111;
}

.jj-login-drawer__copy {
  margin: 0 0 20px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: #4a4a4a;
}

.jj-login-drawer__error {
  margin: 0 0 16px;
  padding: 12px 14px;
  background: #fff0f0;
  border: 1px solid #f5c2c2;
  color: #b00020;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 13px;
}

.jj-login-drawer__form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.jj-login-drawer__field label {
  display: block;
  margin-bottom: 8px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: #111;
}

.jj-login-drawer__field input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #cfcfcf;
  border-radius: 8px;
  background: #fff;
  font: inherit;
  font-size: 14px;
  color: #111;
  box-sizing: border-box;
}

.jj-login-drawer__field input:focus {
  outline: none;
  border-color: #111;
}

.jj-login-drawer__password-wrap {
  position: relative;
}

.jj-login-drawer__password-wrap input {
  padding-right: 72px;
}

.jj-login-drawer__password-toggle {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 12px;
  color: #111;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}

.jj-login-drawer__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  padding: 12px 24px;
  border-radius: 999px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  box-sizing: border-box;
  transition: background 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.jj-login-drawer__btn--primary {
  border: 1px solid #111;
  background: #111;
  color: #fff;
}

.jj-login-drawer__btn--primary:hover {
  background: #333;
  border-color: #333;
}

.jj-login-drawer__btn--outline {
  border: 1px solid #111;
  background: #fff;
  color: #111;
}

.jj-login-drawer__btn--outline:hover {
  background: #f7f7f7;
}

.jj-login-drawer__btn.is-loading,
.jj-login-drawer__social-btn.is-loading {
  opacity: 0.7;
  cursor: wait;
}

.jj-login-drawer__helper {
  margin: 14px 0 0;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 13px;
}

.jj-login-drawer__link {
  color: #111;
  text-decoration: underline;
}

.jj-login-drawer__divider {
  height: 1px;
  margin: 8px 0 28px;
  background: #e5e5e5;
}

.jj-login-drawer__or {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 8px 0 20px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 12px;
  color: #6b6b6b;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.jj-login-drawer__or::before,
.jj-login-drawer__or::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e5e5e5;
}

.jj-login-drawer__social {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.jj-login-drawer__social-btn {
  width: 100%;
  min-height: 46px;
  padding: 12px 16px;
  border-radius: 999px;
  font-family: Inter, system-ui, -apple-system, sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.jj-login-drawer__social-btn--google {
  border: 1px solid #dadce0;
  background: #fff;
  color: #111;
}

.jj-login-drawer__social-btn--apple {
  border: 1px solid #111;
  background: #111;
  color: #fff;
}

body.jj-login-drawer-open {
  overflow: hidden;
}

@media (max-width: 767px) {
  .jj-login-drawer__panel {
    width: 100%;
  }

  .jj-login-drawer__body {
    padding: 52px 24px 32px;
  }
}
