/* =========================================================================
   SENDPK.COM — theme-popup.css (shared SweetAlert2 disclaimer/confirm popup)
   -------------------------------------------------------------------------
   Reusable "chrome" only (gradient header, icon badge, scrollable body,
   Agree/Cancel footer) for window.showThemeDisclaimer() in theme-popup.js.
   The body content itself differs per call site, but the common body-content
   patterns (alert box, checklist, divider, Urdu block) are still styled here
   so every caller can reuse the same classes instead of re-inventing them.

   Any page using this must ALSO load (self-hosted, no CDN):
     assets/css/sweetalert2.min.css + assets/js/sweetalert2.min.js
     assets/js/theme-popup.js
   Scoped entirely under .td- (theme-disclaimer) prefixed classes.
   ========================================================================= */

@keyframes td-pop { from { opacity: 0; transform: scale(.9) translateY(12px); } to { opacity: 1; transform: scale(1) translateY(0); } }

.td-card {
  position: relative; width: 100%; max-width: 640px; margin: 0 auto;
  background: var(--wa-surface); border-radius: 20px; overflow: hidden;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .45);
  animation: td-pop .4s cubic-bezier(.2, .9, .3, 1.2) both;
  text-align: left; font-family: var(--font-sans);
}

/* --- Header ------------------------------------------------------------- */
.td-header { position: relative; background: linear-gradient(135deg, var(--wa-teal), var(--wa-green)); padding: 30px 28px 26px; text-align: center; }
.td-header-blob { position: absolute; top: 0; right: 0; width: 180px; height: 180px; background: rgba(255, 255, 255, .08); border-radius: 50%; transform: translate(60px, -80px); }
.td-title { margin: 0; color: #fff; font-size: 1.45rem; font-weight: 700; letter-spacing: -.01em; }
.td-subtitle { margin: 6px 0 0; color: rgba(255, 255, 255, .9); font-size: .82rem; font-weight: 500; }

/* --- Scrollable body ------------------------------------------------------ */
.td-body { max-height: 46vh; overflow-y: auto; padding: 24px 28px 4px; }
.td-body::-webkit-scrollbar { width: 8px; }
.td-body::-webkit-scrollbar-track { background: transparent; }
.td-body::-webkit-scrollbar-thumb { background: #cfe9d6; border-radius: 999px; }
.td-body::-webkit-scrollbar-thumb:hover { background: #a8d8b6; }

/* --- Reusable body-content patterns --------------------------------------- */
.td-alert-box { background: #fff5f5; border: 1px solid #ffd9d9; border-radius: 12px; padding: 14px 16px; display: flex; gap: 12px; align-items: flex-start; margin-bottom: 20px; }
.td-alert-icon { flex-shrink: 0; width: 22px; height: 22px; border-radius: 50%; background: #ef4444; color: #fff; display: flex; align-items: center; justify-content: center; font-size: .78rem; margin-top: 1px; }
.td-alert-content { min-width: 0; }
.td-alert-text { margin: 0; font-size: .88rem; line-height: 1.55; color: #7f1d1d; font-weight: 600; }
.td-alert-link { display: inline-block; margin-top: 6px; font-size: .86rem; }

.td-rules-intro { margin: 0 0 12px; font-size: .88rem; line-height: 1.6; color: #334155; font-weight: 600; }
.td-rule-list { list-style: none; padding: 0; margin: 0 0 20px; display: flex; flex-direction: column; gap: 9px; }
.td-rule-item { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; line-height: 1.5; color: #475569; }
.td-rule-check { flex-shrink: 0; margin-top: 3px; color: var(--wa-green); font-size: .8rem; }
.td-rule-item strong { color: #0f172a; }

.td-footnote { margin: 0 0 20px; font-size: .84rem; line-height: 1.6; color: var(--wa-muted); }

.td-text { margin: 0 0 14px; font-size: .88rem; line-height: 1.6; color: #334155; }
.td-section-title { margin: 22px 0 10px; font-size: .95rem; font-weight: 700; color: #0f172a; }
.td-section-title:first-child { margin-top: 0; }

.td-yt-link { display: inline-flex; align-items: center; gap: 6px; margin: 0 0 18px; color: #FF0000; font-weight: 700; font-size: .85rem; }
.td-yt-link:hover { color: #CC0000; }
.td-yt-link i { color: #FF0000; }

.td-pay-list { display: flex; flex-direction: column; gap: 10px; margin: 0 0 20px; }
.td-pay-item { display: flex; gap: 12px; align-items: center; padding: 12px 14px; background: var(--wa-page); border: 1px solid var(--wa-line); border-radius: 12px; }
.td-pay-logo { flex-shrink: 0; width: 52px; height: 52px; object-fit: contain; border-radius: 8px; background: #fff; padding: 4px; }
.td-pay-details { flex: 1; min-width: 0; }
.td-pay-name { margin: 0 0 2px; font-size: .85rem; font-weight: 700; color: #0f172a; }
.td-pay-row { margin: 0; font-size: .78rem; color: var(--wa-muted); }
.td-pay-row strong { color: var(--wa-body); font-weight: 600; }
.td-pay-row code { padding: .05rem .35rem; border-radius: 4px; font-size: .76rem; color: var(--wa-teal-dark); }
.td-copy-btn {
  display: inline-flex; align-items: center; justify-content: center; vertical-align: middle;
  width: 22px; height: 22px; margin-left: 2px; padding: 0; border: none; border-radius: 6px;
  background: transparent; color: var(--wa-muted); cursor: pointer; font-size: .72rem;
  transition: background .15s ease, color .15s ease;
}
.td-copy-btn:hover { background: #fff; color: var(--wa-teal); }
.td-copy-btn.td-copied { color: var(--wa-green); }

.td-whatsapp-cta {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%;
  margin: 0 0 22px; padding: 13px 18px; border-radius: 12px; border: none; cursor: pointer;
  background: var(--wa-green); color: #fff; font-weight: 700; font-size: .9rem; text-decoration: none;
  box-shadow: 0 6px 16px rgba(34, 197, 94, .3); transition: transform .18s ease, box-shadow .18s ease;
}
.td-whatsapp-cta:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(34, 197, 94, .4); color: #fff; }

.td-divider { display: flex; align-items: center; gap: 12px; margin: 0 0 18px; }
.td-divider-line { flex: 1; height: 1px; background: var(--wa-line); }
.td-divider-label { font-family: "Noto Nastaliq Urdu", serif; font-size: .95rem; color: var(--wa-teal); font-weight: 700; }

.td-urdu-block { text-align: right; font-family: "Noto Nastaliq Urdu", serif; color: #475569; }
.td-urdu-block .td-urdu-title { margin: 0 0 16px; font-size: .95rem; font-weight: 700; color: #0f172a; line-height: 2.1; }
.td-urdu-block p { margin: 0 0 14px; font-size: .88rem; line-height: 2.2; }
.td-urdu-block ul { margin: 0 0 16px; padding: 0; list-style: none; text-align: right; }
.td-urdu-block li { font-size: .88rem; line-height: 2; margin-bottom: 6px; }
.td-urdu-bullet { color: var(--wa-green); }
.td-urdu-note { margin: 0 0 4px; font-size: .84rem; line-height: 2.2; color: var(--wa-muted); }

/* --- Footer / actions ----------------------------------------------------- */
.td-footer { padding: 18px 28px 24px; border-top: 1px solid var(--wa-page); display: flex; gap: 12px; }
.td-btn-agree {
  flex: 1 1 auto; display: flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 18px; border: none; border-radius: 12px; cursor: pointer;
  background: linear-gradient(135deg, var(--wa-green), var(--wa-teal)); color: #fff;
  font-family: var(--font-sans); font-size: .95rem; font-weight: 600;
  box-shadow: 0 8px 20px rgba(34, 197, 94, .35); transition: transform .18s ease, box-shadow .18s ease;
}
.td-btn-agree:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(34, 197, 94, .45); }
.td-btn-cancel {
  flex: 0 0 auto; padding: 14px 24px; border: 1.5px solid var(--wa-line); border-radius: 12px; cursor: pointer;
  background: #fff; color: var(--wa-muted); font-family: var(--font-sans); font-size: .95rem; font-weight: 600;
  transition: background .18s ease, border-color .18s ease, color .18s ease;
}
.td-btn-cancel:hover { background: var(--wa-page); border-color: #cbd5e1; color: #475569; }
/* When showThemeDisclaimer() is called with showAgreeButton:false, the sole
   remaining button should fill the row instead of sitting narrow and left-aligned. */
.td-footer-solo .td-btn-cancel { flex: 1 1 auto; }

/* --- Responsive ------------------------------------------------------------ */
@media (max-width: 575.98px) {
  .td-header { padding: 24px 20px 20px; }
  .td-body { padding: 20px 20px 4px; }
  .td-footer { padding: 16px 20px 20px; flex-direction: column; }
}
