/* ========================================================
   MODERN TOAST & CONFIRMATION MODAL SYSTEM
   ফন্ট: সোলায়মান লিপি (SolaimanLipi)
======================================================== */

/* ১. টোস্ট কন্টেইনার (টপবারের ঠিক নিচে ডানপাশে) */
.toast-container {
  position: fixed;
  top: 80px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
  max-width: 420px;
  width: 90%;
}

/* টোস্ট আইটেম */
.custom-toast {
  pointer-events: auto;
  background: #ffffff;
  border-radius: var(--radius-md, 12px);
  padding: 16px 18px;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15), 0 1px 3px rgba(0, 0, 0, 0.05);
  border: 1px solid #e2e8f0;
  position: relative;
  overflow: hidden;
  transform: translateX(120%);
  opacity: 0;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  font-family: var(--font-main, 'SolaimanLipi', sans-serif);
}

.custom-toast.show {
  transform: translateX(0);
  opacity: 1;
}

.custom-toast.hide {
  transform: translateX(120%);
  opacity: 0;
}

/* টোস্ট টাইপ কালার ও আইকন */
.toast-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 18px;
}

.custom-toast.success {
  border-left: 5px solid #10b981;
}
.custom-toast.success .toast-icon-wrap {
  background: #ecfdf5;
  color: #10b981;
}

.custom-toast.error {
  border-left: 5px solid #ef4444;
}
.custom-toast.error .toast-icon-wrap {
  background: #fef2f2;
  color: #ef4444;
}

.custom-toast.warning {
  border-left: 5px solid #f59e0b;
}
.custom-toast.warning .toast-icon-wrap {
  background: #fffbeb;
  color: #f59e0b;
}

.custom-toast.info {
  border-left: 5px solid #3b82f6;
}
.custom-toast.info .toast-icon-wrap {
  background: #eff6ff;
  color: #3b82f6;
}

/* টোস্ট টেক্সট */
.toast-content {
  flex: 1;
  min-width: 0;
}

.toast-title {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 2px;
  line-height: 1.3;
}

.toast-message {
  font-size: 13.5px;
  color: #475569;
  line-height: 1.5;
}

/* ক্লোজ বাটন */
.toast-close-btn {
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 2px 4px;
  font-size: 18px;
  line-height: 1;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.toast-close-btn:hover {
  color: #0f172a;
  background: #f1f5f9;
}

/* প্রগ্রেস বার */
.toast-progress {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 100%;
  background: rgba(0, 0, 0, 0.05);
}

.toast-progress-bar {
  height: 100%;
  width: 100%;
  transform-origin: left;
}

.custom-toast.success .toast-progress-bar { background: #10b981; }
.custom-toast.error .toast-progress-bar { background: #ef4444; }
.custom-toast.warning .toast-progress-bar { background: #f59e0b; }
.custom-toast.info .toast-progress-bar { background: #3b82f6; }


/* ========================================================
   ২. প্রিমিয়াম কনফার্মেশন ডায়ালগ (CUSTOM CONFIRM MODAL)
======================================================== */
.confirm-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.confirm-modal-overlay.show {
  display: flex;
  opacity: 1;
}

.confirm-card {
  background: #ffffff;
  border-radius: var(--radius-lg, 16px);
  width: 100%;
  max-width: min(94vw, 490px);
  padding: 26px 22px;
  text-align: center;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
  transform: scale(0.92) translateY(10px);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  font-family: var(--font-main, 'SolaimanLipi', sans-serif);
}

.confirm-modal-overlay.show .confirm-card {
  transform: scale(1) translateY(0);
}

.confirm-icon-wrap {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  margin: 0 auto 16px auto;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
}

.confirm-icon-wrap.danger {
  background: #fee2e2;
  color: #ef4444;
  box-shadow: 0 0 0 8px #fef2f2;
}

.confirm-icon-wrap.warning {
  background: #fef3c7;
  color: #f59e0b;
  box-shadow: 0 0 0 8px #fffbeb;
}

.confirm-icon-wrap.info {
  background: #dbeafe;
  color: #2563eb;
  box-shadow: 0 0 0 8px #eff6ff;
}

.confirm-icon-wrap.sms {
  background: #e0f2fe;
  color: #0284c7;
  box-shadow: 0 0 0 8px #f0f9ff;
}

.confirm-icon-wrap.success {
  background: #dcfce7;
  color: #16a34a;
  box-shadow: 0 0 0 8px #f0fdf4;
}

.confirm-title {
  font-size: 19px;
  font-weight: 800;
  color: #0f172a;
  margin-bottom: 8px;
  line-height: 1.35;
}

.confirm-message {
  font-size: 14.5px;
  color: #64748b;
  line-height: 1.6;
  margin-bottom: 20px;
}

/* স্ট্রাকচার্ড মেটা গ্রিড (পপআপের ভেতরের তথ্যবক্স) */
.confirm-meta-grid {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px 16px;
  margin: 12px 0 16px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

.confirm-meta-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
  color: #334155;
}

.confirm-meta-item.highlight-due {
  padding-top: 8px;
  border-top: 1px dashed #cbd5e1;
}

.c-meta-lbl {
  color: #64748b;
  font-weight: 600;
}

.c-meta-val {
  color: #0f172a;
  font-weight: 700;
}

.c-meta-val.text-danger {
  color: #dc2626 !important;
}

.c-meta-val.text-primary {
  color: #2563eb !important;
}

/* ডায়ালগে এসএমএস বার্তা প্রিভিউ ও লাইভ এডিটর বক্স */
.confirm-sms-editor-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 12px 14px;
  margin: 12px 0 16px 0;
  text-align: left;
}

.confirm-sms-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
  gap: 8px;
}

.c-sms-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.c-sms-counter-badge {
  font-size: 11.5px;
  font-weight: 700;
  background: #e0f2fe;
  color: #0284c7;
  border: 1px solid #bae6fd;
  padding: 2px 8px;
  border-radius: 6px;
  font-family: inherit;
}

.confirm-sms-textarea {
  width: 100%;
  border: 1.5px solid #cbd5e1;
  border-radius: 8px;
  padding: 9px 11px;
  font-family: inherit;
  font-size: 13.5px;
  line-height: 1.5;
  color: #0f172a;
  background: #ffffff;
  resize: vertical;
  min-height: 76px;
  outline: none;
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.confirm-sms-textarea:focus {
  border-color: #0284c7;
  box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

.confirm-sms-tpl-check {
  margin-top: 8px;
  padding-top: 7px;
  border-top: 1px dashed #e2e8f0;
}

.c-sms-check-lbl {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: #475569;
  cursor: pointer;
  user-select: none;
}

.c-sms-checkbox {
  width: 15px;
  height: 15px;
  cursor: pointer;
  accent-color: #0284c7;
}

.confirm-sub-prompt {
  font-size: 13.5px;
  color: #475569;
  line-height: 1.55;
  margin: 0 0 20px 0;
}

.confirm-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.confirm-btn {
  padding: 10px 22px;
  font-size: 14.5px;
  font-weight: 700;
  border-radius: var(--radius-md, 12px);
  cursor: pointer;
  border: none;
  font-family: inherit;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
}

.confirm-btn:active {
  transform: scale(0.98);
}

.confirm-btn-cancel {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #cbd5e1;
}

.confirm-btn-cancel:hover {
  background: #e2e8f0;
  color: #0f172a;
  border-color: #94a3b8;
}

.confirm-btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.35);
}

.confirm-btn-danger:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(239, 68, 68, 0.45);
}

.confirm-btn-primary {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
}

.confirm-btn-primary:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.45);
}

.confirm-btn-sms {
  background: linear-gradient(135deg, #0284c7, #0369a1);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.35);
}

.confirm-btn-sms:hover {
  background: linear-gradient(135deg, #0369a1, #075985);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(2, 132, 199, 0.45);
}

.confirm-btn-success {
  background: linear-gradient(135deg, #16a34a, #15803d);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(22, 163, 74, 0.35);
}

.confirm-btn-success:hover {
  background: linear-gradient(135deg, #15803d, #166534);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(22, 163, 74, 0.45);
}

@media (max-width: 640px) {
  .toast-container {
    top: 16px;
    right: 5%;
    left: 5%;
    width: 90%;
    max-width: 100%;
  }
}
