/* ── Generic site modals (_SiteModals.cshtml) ── */
.site-modal .modal-content {
  border: none;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(15, 23, 42, .18);
}

.site-modal .modal-header {
  border-bottom: none;
  padding: 1.15rem 1.5rem .35rem;
}

.site-modal .modal-title {
  font-size: 1.05rem;
  font-weight: 900;
  color: #0f172a;
  line-height: 1.45;
}

.site-modal .modal-body {
  padding: 0 1.5rem 1.35rem;
  color: #475569;
  font-size: .88rem;
  line-height: 1.85;
}

.site-modal .modal-body .btn-primary,
.site-modal .modal-action-link {
  border: none;
  border-radius: 14px;
  padding: .75rem 1.25rem;
  font-weight: 800;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  box-shadow: 0 8px 22px rgba(37, 99, 235, .22);
}

.site-modal .modal-body img {
  max-width: 100%;
  border-radius: 12px;
}

/* ── Loan AI read sheet (صفحه وام) ── */
.loan-ai-sheet .modal-content {
  border: none;
  overflow: hidden;
  background: #fff;
}

.loan-ai-sheet.bottomsheet .modal-dialog {
  margin: 0 !important;
  position: fixed !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  top: auto !important;
  max-width: 100% !important;
  width: 100% !important;
  transform: translateY(105%) !important;
  transition: transform .38s cubic-bezier(.22, .61, .36, 1) !important;
  pointer-events: none;
}

.loan-ai-sheet.bottomsheet.show .modal-dialog {
  transform: translateY(0) !important;
  pointer-events: auto;
}

.loan-ai-sheet.bottomsheet .modal-content {
  border-radius: 28px 28px 0 0;
  box-shadow: 0 -14px 48px rgba(15, 23, 42, .14);
}

.loan-ai-sheet:not(.bottomsheet) .modal-dialog {
  max-width: 440px;
}

.loan-ai-sheet:not(.bottomsheet) .modal-content {
  border-radius: 24px;
  box-shadow: 0 28px 64px rgba(15, 23, 42, .16);
}

.loan-ai-sheet__top {
  position: relative;
  padding: 12px 18px 0;
  min-height: 28px;
}

.loan-ai-sheet__grabber {
  display: none;
  width: 44px;
  height: 5px;
  border-radius: 999px;
  background: #d1d5db;
  margin: 2px auto 0;
}

.loan-ai-sheet.bottomsheet .loan-ai-sheet__grabber {
  display: block;
}

.loan-ai-sheet__close {
  position: absolute;
  top: 8px;
  left: 16px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border: none;
  border-radius: 999px;
  background: #f3f4f6;
  color: #64748b;
  display: grid;
  place-items: center;
}

.loan-ai-sheet__body {
  padding: .35rem 1.35rem 1.5rem;
  text-align: center;
}

.loan-ai-sheet__hero {
  margin-bottom: 1.1rem;
}

.loan-ai-sheet__lottie {
  width: 88px;
  height: 88px;
  margin: 0 auto .5rem;
}

.loan-ai-sheet__kicker {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  margin: 0 0 .65rem;
  padding: .28rem .65rem;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(37, 99, 235, .08), rgba(139, 92, 246, .08));
  color: #4338ca;
  font-size: .72rem;
  font-weight: 800;
}

.loan-ai-sheet__kicker i {
  font-size: .85rem;
}

.loan-ai-sheet__title {
  margin: 0 0 .55rem;
  font-size: 1.12rem;
  font-weight: 900;
  line-height: 1.55;
  color: #0f172a;
}

.loan-ai-sheet__lead {
  margin: 0;
  font-size: .84rem;
  line-height: 1.85;
  color: #64748b;
}

.loan-ai-sheet__cta {
  display: block;
  text-decoration: none;
  margin-bottom: .85rem;
}

.loan-ai-sheet__cta-glow {
  display: block;
  border-radius: 16px;
  padding: 2px;
  background: linear-gradient(135deg, #6366f1, #2563eb, #8b5cf6);
  box-shadow: 0 10px 28px rgba(99, 102, 241, .28);
}

.loan-ai-sheet__cta-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .45rem;
  width: 100%;
  padding: .82rem 1rem;
  border-radius: 14px;
  background: linear-gradient(135deg, #1e293b, #0f172a);
  color: #fff !important;
  font-weight: 800;
  font-size: .84rem;
  line-height: 1.45;
}

.loan-ai-sheet__cta-text {
  flex: 1;
  text-align: center;
}

.loan-ai-sheet__cta-arrow {
  opacity: .85;
  font-size: .95rem;
}

.loan-ai-sheet__privacy {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: .4rem;
  margin: 0;
  font-size: .72rem;
  line-height: 1.7;
  color: #94a3b8;
  text-align: start;
}

.loan-ai-sheet__privacy i {
  margin-top: .15rem;
  color: #64748b;
}

body.loan-ai-sheet-open .support-fab,
body.loan-ai-sheet-open .support-panel {
  z-index: 1040 !important;
  pointer-events: none;
}

#loanAiSheet.show {
  z-index: 1060;
}

/* Admin preview wrappers */
#modalPreview.loan-ai-sheet-preview .modal-header,
#modalPreview.sheet-preview .modal-header,
#modalPreview.smart-search-preview .modal-header {
  display: none;
}

#modalPreview.loan-ai-sheet-preview .modal-body,
#modalPreview.sheet-preview .modal-body,
#modalPreview.smart-search-preview .modal-body {
  padding: 0 !important;
}

#modalPreview.loan-ai-sheet-preview .modal-content,
#modalPreview.sheet-preview .modal-content {
  border: none;
  overflow: hidden;
  border-radius: 24px;
}

#modalPreview.bottomsheet-preview.loan-ai-sheet-preview .modal-content,
#modalPreview.bottomsheet-preview.sheet-preview .modal-content {
  border-radius: 28px 28px 0 0;
}

#modalPreview.smart-search-preview .modal-content {
  border-radius: 0 0 22px 22px;
}

#modalPreview.smart-search-preview .smart-cover {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  background: #e2e8f0;
}

#modalPreview.smart-search-preview .smart-body {
  padding: 1rem 1.15rem 1.2rem;
}

#modalPreview.smart-search-preview .smart-title {
  font-size: 1.05rem;
  font-weight: 900;
  margin-bottom: .45rem;
  color: #0f172a;
}

#modalPreview.smart-search-preview .smart-text {
  color: #475569;
  font-size: .9rem;
  line-height: 1.95;
  margin-bottom: .95rem;
}

#modalPreview.smart-search-preview .smart-cta {
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  font-weight: 800;
  display: block;
  text-align: center;
  padding: .75rem 1rem;
  text-decoration: none;
}

#modalPreview.sheet-preview .loan-otp-sheet__note {
  margin: .65rem 0 0;
  font-size: .72rem;
  line-height: 1.7;
  color: #94a3b8;
}

#modalPreview.sheet-preview .loan-otp-sheet__cta {
  width: 100%;
  margin-top: 1rem;
  border: none;
  border-radius: 14px;
  padding: .78rem 1rem;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #4338ca);
}
