.login-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: transparent;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 280ms ease, visibility 280ms ease;
  pointer-events: none;
}

.login-modal-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

.login-modal-box {
  position: fixed;
  top: 88px;
  right: 24px;
  background: #fff;
  border-radius: 24px;
  padding: 36px 32px 32px;
  width: 100%;
  max-width: 440px;
  box-shadow: 0 24px 64px rgba(12, 38, 76, 0.22);
  transform: translateY(10px) scale(0.97);
  transition: transform 220ms ease;
  pointer-events: auto;
}

.login-modal-overlay.is-open .login-modal-box {
  transform: translateY(0) scale(1);
}

.login-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: #f1f5f9;
  color: #64748b;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  transition: background 200ms, color 200ms;
}

.login-modal-close:hover {
  background: var(--theme-color, #e07a2e);
  color: #fff;
}

.login-modal-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 6px;
}

.login-modal-title {
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 6px;
  font-family: var(--title-font, inherit);
}

.login-modal-desc {
  font-size: 13px;
  color: #64748b;
  margin-bottom: 20px;
  line-height: 1.6;
}

.login-modal-alert {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #dc2626;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
}

.login-modal-field {
  margin-bottom: 16px;
}

.login-modal-field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 6px;
}

.login-modal-field input {
  width: 100%;
  border: 1.5px solid #e2e8f0;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 14px;
  color: #0f172a;
  outline: none;
  transition: border-color 200ms, box-shadow 200ms;
  background: #f8fafc;
  box-sizing: border-box;
}

.login-modal-field input:focus {
  border-color: var(--theme-color, #e07a2e);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--theme-color, #e07a2e) 15%, transparent);
  background: #fff;
}

.login-modal-pw-wrap {
  position: relative;
}

.login-modal-pw-wrap input {
  padding-right: 44px;
}

#login-modal-toggle-pw {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  font-size: 15px;
  padding: 0;
  line-height: 1;
}

#login-modal-toggle-pw:hover {
  color: #475569;
}

.login-modal-submit {
  width: 100%;
  margin-top: 8px;
  justify-content: center;
}

.login-modal-submit:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

button.theme-btn {
  cursor: pointer;
  border: none;
}

@media only screen and (max-width: 767px) {
  .login-modal-box {
    left: 16px !important;
    right: 16px !important;
    top: auto !important;
    bottom: 16px;
    max-width: none;
    width: auto;
  }
}