.page-entry-loader {
  position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 3200;
  display: flex; align-items: center; justify-content: center; padding: 1rem;
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(6px);
  transition: opacity 0.42s ease, visibility 0.42s ease;
}

.page-entry-loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.page-entry-loader-ring {
  width: 54px; height: 54px; border-radius: 50%;
  border: 4px solid rgba(17, 17, 17, 0.16);
  border-top-color: #111111; border-right-color: #111111;
  animation: entrySpinnerRotate 0.72s linear infinite;
}

.auth-modal-kicker {
  display: inline-block; margin-bottom: 0.8rem; padding: 0.25rem 0.65rem;
  border: 2px solid #111111; background: #111111; color: #fff4df;
  font-size: 0.72rem; font-weight: 800; letter-spacing: 0.18em;
}

#global-loading {
  top: 1rem !important; left: auto !important; right: 1rem !important;
  padding: 0 !important; background: transparent !important;
}

.loading-spinner {
  width: 28px; height: 28px; border-radius: 50%;
  border: 3px solid rgba(17, 17, 17, 0.18); border-top-color: #111111; border-right-color: #ff9556;
  background: rgba(255, 255, 255, 0.92); box-shadow: 0 6px 18px rgba(0, 0, 0, 0.16);
  animation: entrySpinnerRotate 0.72s linear infinite;
}

@keyframes entrySpinnerRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

#auth-modal.modal-overlay { background: rgba(10, 10, 10, 0.78); }

#auth-modal .auth-modal-panel {
  position: relative; max-width: 560px; overflow: hidden;
  border: 3px solid #111111; box-shadow: 14px 14px 0 rgba(0, 0, 0, 0.35);
  background: linear-gradient(180deg, #fff9f0 0, #ffffff 40%, #f7efe4 100%);
}

.auth-modal-close {
  position: absolute; top: 0.9rem; right: 0.9rem; z-index: 2;
  width: 42px; height: 42px; border: 2px solid #111111;
  background: rgba(255, 255, 255, 0.86); color: #111111;
  font-size: 1rem; font-weight: 900; cursor: pointer;
}

.auth-modal-close:hover { background: #111111; color: #ffffff; }

.auth-modal-hero {
  padding: 1.35rem 1.5rem 1rem; border-bottom: 3px solid #111111;
  background: linear-gradient(135deg, #f8dec3 0, #fff8ee 52%, #f2e7d7 100%);
}

.auth-modal-title { margin: 0; font-size: 1.85rem; line-height: 1.2; }
.auth-modal-subtitle { margin: 0.55rem 0 0; color: #4f4439; font-size: 0.92rem; line-height: 1.6; }

#auth-modal .tab-switch {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.75rem;
  padding: 1rem 1.5rem 0;
}

#auth-modal .tab-btn {
  border: 2px solid #111111; background: #f7efe5; color: #111111; font-weight: 800;
}

#auth-modal .tab-btn.active { background: #111111; color: #fff4df; box-shadow: 4px 4px 0 #efb274; }
#auth-modal .modal-body { padding: 1rem 1.5rem 1.5rem; }
.auth-tip-strip {
  margin-bottom: 1rem; padding: 0.9rem 1rem; border: 2px solid #111111;
  background: #fff2df; font-size: 0.84rem; font-weight: 700; line-height: 1.6;
}

.form-group-block { margin-bottom: 1rem; }

.form-label-block {
  display: block; margin-bottom: 0.45rem; color: #3c3128;
  font-size: 0.8rem; font-weight: 800; letter-spacing: 0.04em;
}

.form-input-block {
  width: 100%; box-sizing: border-box; padding: 0.95rem 1rem;
  border: 2px solid #111111; background: #ffffff; font-size: 0.96rem;
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.form-input-block:focus {
  border-color: #c96b2c; box-shadow: 5px 5px 0 rgba(17, 17, 17, 0.16); transform: translate(-1px, -1px);
}

.captcha-row { display: flex; gap: 0.75rem; margin-bottom: 0.75rem; }

.captcha-box-block {
  flex: 1; min-height: 64px; display: flex; align-items: center; justify-content: center;
  border: 2px solid #111111; background: #ffffff;
}

.captcha-refresh-btn { width: auto; min-width: 108px; padding: 0 1rem; white-space: nowrap; }

.agreement-card {
  padding: 0.95rem 1rem; border: 2px solid #111111; background: #fff7ea;
}

.agreement-check { display: flex; gap: 0.75rem; align-items: flex-start; cursor: pointer; }
.agreement-checkbox { width: 18px; height: 18px; margin-top: 0.15rem; }
.agreement-copy { font-size: 0.86rem; line-height: 1.6; }
.agreement-link { color: #7d3d12; font-weight: 800; }

#auth-modal .auth-feedback { margin-bottom: 1rem; font-weight: 700; }
.auth-submit-btn { margin-top: 0.2rem; }
.auth-footnote { margin: 0.85rem 0 0; color: #5f5244; font-size: 0.78rem; line-height: 1.6; }

@media (max-width: 768px) {
  .page-entry-loader-ring { width: 48px; height: 48px; }

  #auth-modal .auth-modal-panel { max-width: 100%; box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.28); }
  .auth-modal-hero, #auth-modal .modal-body, #auth-modal .tab-switch { padding-left: 1rem; padding-right: 1rem; }
  .auth-modal-title { font-size: 1.45rem; }
  .captcha-row { flex-direction: column; }
  .captcha-refresh-btn { width: 100%; min-width: 0; padding: 0.85rem 1rem; }
}
