/* ==========================================================================
   DoctorsHub24 — Scoped Pharmacy Live Tracker & Online Payment Stylesheet
   Zero conflict with public_header.php / dh24-landing.css
   ========================================================================== */

.dh-track-page,
.dh-pay-page {
  --pt-teal: #0d9488;
  --pt-teal-dark: #0f766e;
  --pt-teal-soft: #f0fdfa;
  --pt-navy: #0b2d5b;
  --pt-slate: #334155;
  --pt-muted: #64748b;
  --pt-border: #e2e8f0;
  --pt-bg: #f4f7fb;
  --pt-surface: #ffffff;
  --pt-radius: 16px;
  --pt-shadow: 0 6px 24px rgba(15, 23, 42, 0.06);
  background: var(--pt-bg);
  color: var(--pt-slate);
  min-height: 70vh;
  padding: 1.5rem 0 3.5rem;
}

.dh-pt-container {
  width: 100%;
  max-width: 1220px;
  margin: 0 auto;
  padding: 0 1.25rem;
  box-sizing: border-box;
}

/* Breadcrumb Bar */
.dh-pt-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.84rem;
  color: var(--pt-muted);
  margin: 0 0 1.25rem;
  padding: 0;
  list-style: none;
}
.dh-pt-breadcrumb a {
  color: var(--pt-teal-dark);
  text-decoration: none;
  font-weight: 600;
}
.dh-pt-breadcrumb a:hover {
  text-decoration: underline;
}
.dh-pt-breadcrumb-sep {
  color: #94a3b8;
  font-size: 0.78rem;
}
.dh-pt-breadcrumb-curr {
  color: var(--pt-navy);
  font-weight: 700;
}

/* Hero Lookup Panel */
.dh-pt-lookup-card {
  background: linear-gradient(135deg, #0b2d5b 0%, #0f766e 100%);
  color: #ffffff;
  border-radius: 20px;
  padding: 1.75rem 2rem;
  box-shadow: 0 12px 32px rgba(11, 45, 91, 0.18);
  margin-bottom: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.dh-pt-lookup-copy {
  flex: 1 1 340px;
}
.dh-pt-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  padding: 0.28rem 0.78rem;
  font-size: 0.76rem;
  font-weight: 700;
  margin-bottom: 0.65rem;
}
.dh-pt-lookup-title {
  margin: 0 0 0.35rem;
  font-size: 1.65rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.25;
}
.dh-pt-lookup-sub {
  margin: 0;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.88);
  line-height: 1.55;
}
.dh-pt-lookup-form {
  flex: 1 1 390px;
  max-width: 510px;
}
.dh-pt-search-box {
  display: flex;
  align-items: stretch;
  gap: 0.5rem;
  background: #ffffff;
  padding: 0.38rem;
  border-radius: 14px;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.15);
}
.dh-pt-search-input {
  flex: 1 1 auto;
  min-width: 0;
  border: none;
  background: transparent;
  padding: 0.65rem 0.85rem;
  font-size: 0.96rem;
  font-weight: 600;
  color: #0f172a;
  font-family: inherit;
}
.dh-pt-search-input:focus {
  outline: none;
}
.dh-pt-search-input::placeholder {
  color: #94a3b8;
  font-weight: 500;
}
.dh-pt-search-btn {
  border: none;
  border-radius: 10px;
  background: var(--pt-teal);
  color: #ffffff;
  padding: 0.68rem 1.25rem;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
  transition: background 0.18s ease, transform 0.12s ease;
}
.dh-pt-search-btn:hover {
  background: var(--pt-teal-dark);
}
.dh-pt-lookup-hint {
  margin-top: 0.5rem;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.82);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* Alerts & Banners */
.dh-pt-alert {
  border-radius: 14px;
  padding: 1rem 1.2rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.92rem;
  line-height: 1.5;
  box-sizing: border-box;
}
.dh-pt-alert-success {
  background: #ecfdf5;
  border: 1px solid #6ee7b7;
  color: #065f46;
}
.dh-pt-alert-warn {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
}
.dh-pt-alert-danger {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}
.dh-pt-alert-info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e40af;
}

/* Shared Cards */
.dh-pt-card {
  background: var(--pt-surface);
  border: 1px solid var(--pt-border);
  border-radius: var(--pt-radius);
  box-shadow: var(--pt-shadow);
  margin-bottom: 1.25rem;
  overflow: hidden;
}
.dh-pt-card-header {
  background: #f8fafc;
  border-bottom: 1px solid var(--pt-border);
  padding: 1rem 1.35rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}
.dh-pt-card-title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  color: var(--pt-navy);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.dh-pt-card-body {
  padding: 1.35rem;
}

/* Badges & Buttons */
.dh-pt-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.3rem 0.78rem;
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
}
.dh-pt-badge-teal {
  background: #ccfbf1;
  color: #0f766e;
}
.dh-pt-badge-success {
  background: #dcfce7;
  color: #15803d;
}
.dh-pt-badge-warn {
  background: #fef3c7;
  color: #92400e;
}
.dh-pt-badge-danger {
  background: #fee2e2;
  color: #b91c1c;
}
.dh-pt-badge-slate {
  background: #e2e8f0;
  color: #334155;
}
.dh-pt-badge-navy {
  background: #dbeafe;
  color: #0b2d5b;
}

.dh-pt-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 10px;
  padding: 0.62rem 1.1rem;
  font-size: 0.88rem;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.16s ease;
  min-height: 40px;
  box-sizing: border-box;
}
.dh-pt-btn-teal {
  background: var(--pt-teal);
  color: #ffffff;
}
.dh-pt-btn-teal:hover {
  background: var(--pt-teal-dark);
  color: #ffffff;
}
.dh-pt-btn-navy {
  background: var(--pt-navy);
  color: #ffffff;
}
.dh-pt-btn-navy:hover {
  background: #082246;
  color: #ffffff;
}
.dh-pt-btn-outline {
  background: #ffffff;
  color: var(--pt-teal-dark);
  border-color: var(--pt-teal);
}
.dh-pt-btn-outline:hover {
  background: var(--pt-teal-soft);
}
.dh-pt-btn-danger-outline {
  background: #ffffff;
  color: #b91c1c;
  border-color: #fca5a5;
}
.dh-pt-btn-danger-outline:hover {
  background: #fef2f2;
}
.dh-pt-btn-sm {
  padding: 0.42rem 0.85rem;
  font-size: 0.8rem;
  min-height: 34px;
}

/* Multiple Match / Recent Orders Grid */
.dh-pt-orders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 0.9rem;
}
.dh-pt-order-mini {
  background: #ffffff;
  border: 1px solid var(--pt-border);
  border-radius: 14px;
  padding: 1rem 1.1rem;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.14s ease;
}
.dh-pt-order-mini:hover {
  border-color: var(--pt-teal);
  box-shadow: 0 8px 20px rgba(13, 148, 136, 0.12);
  transform: translateY(-2px);
}
.dh-pt-order-mini-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}
.dh-pt-order-num {
  font-weight: 800;
  color: var(--pt-navy);
  font-size: 0.95rem;
}

/* Active Order Banner + Action Bar */
.dh-pt-header-card {
  padding: 1.35rem 1.5rem;
}
.dh-pt-order-top-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1.15rem;
  border-bottom: 1px solid var(--pt-border);
}
.dh-pt-order-code {
  font-size: 1.45rem;
  font-weight: 900;
  color: var(--pt-navy);
  margin: 0.15rem 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
}
.dh-pt-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #dcfce7;
  color: #15803d;
  border-radius: 999px;
  padding: 0.22rem 0.65rem;
  font-size: 0.72rem;
  font-weight: 800;
}
.dh-pt-live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #16a34a;
  animation: dhPtPulse 1.5s infinite ease-in-out;
}
@keyframes dhPtPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(1.25); }
}

.dh-pt-actions-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

/* 5-Step Progress Timeline */
.dh-pt-steps {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin: 1.5rem 0 0.5rem;
  gap: 0.5rem;
}
.dh-pt-steps::before {
  content: '';
  position: absolute;
  top: 23px;
  left: 8%;
  right: 8%;
  height: 4px;
  background: #e2e8f0;
  z-index: 1;
  border-radius: 999px;
}
.dh-pt-step {
  position: relative;
  z-index: 2;
  text-align: center;
  flex: 1 1 0;
  min-width: 0;
}
.dh-pt-step-node {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #ffffff;
  border: 3px solid #cbd5e1;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.55rem;
  font-size: 1.2rem;
  transition: all 0.25s ease;
}
.dh-pt-step.is-done .dh-pt-step-node {
  background: var(--pt-teal-dark);
  border-color: var(--pt-teal-dark);
  color: #ffffff;
}
.dh-pt-step.is-active .dh-pt-step-node {
  background: var(--pt-teal-soft);
  border-color: var(--pt-teal);
  color: var(--pt-teal-dark);
  box-shadow: 0 0 0 6px rgba(13, 148, 136, 0.18);
}
.dh-pt-step-title {
  font-size: 0.83rem;
  font-weight: 800;
  color: var(--pt-navy);
  line-height: 1.25;
}
.dh-pt-step-sub {
  font-size: 0.72rem;
  color: var(--pt-muted);
  margin-top: 0.15rem;
}

/* Main 2-Column Workspace */
.dh-pt-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 1.35rem;
  align-items: start;
}

/* Secret Delivery OTP Vault */
.dh-pt-otp-card {
  background: linear-gradient(135deg, #ecfdf5 0%, #f0fdfa 100%);
  border: 1.5px solid #5eead4;
  border-radius: var(--pt-radius);
  padding: 1.35rem;
  text-align: center;
  margin-bottom: 1.25rem;
}
.dh-pt-otp-code {
  font-size: 2.35rem;
  font-weight: 900;
  letter-spacing: 0.35rem;
  color: var(--pt-navy);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background: #ffffff;
  border: 1px dashed var(--pt-teal);
  border-radius: 12px;
  padding: 0.55rem 1.1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0.45rem 0 0.6rem;
}
.dh-pt-copy-btn {
  background: var(--pt-teal-soft);
  border: 1px solid #99f6e4;
  color: var(--pt-teal-dark);
  border-radius: 8px;
  padding: 0.3rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  letter-spacing: 0;
}
.dh-pt-copy-btn:hover {
  background: var(--pt-teal);
  color: #ffffff;
}

/* Key-Value Details Rows */
.dh-pt-kv-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  font-size: 0.88rem;
}
.dh-pt-kv-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px dashed #e2e8f0;
}
.dh-pt-kv-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}
.dh-pt-kv-k {
  color: var(--pt-muted);
  font-weight: 600;
}
.dh-pt-kv-v {
  color: #0f172a;
  font-weight: 700;
  text-align: end;
}

/* Rider Card */
.dh-pt-rider-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  background: #f8fafc;
  border: 1px solid var(--pt-border);
  border-radius: 12px;
  padding: 0.85rem 1rem;
}
.dh-pt-rider-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--pt-teal-soft);
  color: var(--pt-teal-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}

/* Live Chat Box */
.dh-pt-chat-box {
  height: 360px;
  overflow-y: auto;
  background: #f8fafc;
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.dh-pt-chat-msg {
  max-width: 82%;
  display: flex;
  flex-direction: column;
}
.dh-pt-chat-msg.is-customer {
  align-self: flex-end;
  align-items: flex-end;
}
.dh-pt-chat-msg.is-other {
  align-self: flex-start;
  align-items: flex-start;
}
.dh-pt-chat-meta {
  font-size: 0.72rem;
  color: var(--pt-muted);
  margin-bottom: 0.25rem;
}
.dh-pt-chat-bubble {
  border-radius: 14px;
  padding: 0.72rem 1rem;
  font-size: 0.89rem;
  line-height: 1.5;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.05);
}
.dh-pt-chat-msg.is-customer .dh-pt-chat-bubble {
  background: var(--pt-teal-dark);
  color: #ffffff;
  border-bottom-right-radius: 4px;
}
.dh-pt-chat-msg.is-other .dh-pt-chat-bubble {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid var(--pt-border);
  border-bottom-left-radius: 4px;
}
.dh-pt-chat-form {
  display: flex;
  gap: 0.6rem;
  padding: 0.9rem 1.15rem;
  background: #ffffff;
  border-top: 1px solid var(--pt-border);
}
.dh-pt-chat-input {
  flex: 1 1 auto;
  min-width: 0;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  padding: 0.6rem 0.9rem;
  font-size: 0.9rem;
  font-family: inherit;
}
.dh-pt-chat-input:focus {
  outline: none;
  border-color: var(--pt-teal);
  box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.14);
}

/* Items Breakdown Table */
.dh-pt-table-wrap {
  overflow-x: auto;
}
.dh-pt-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}
.dh-pt-table th {
  background: #f8fafc;
  color: var(--pt-navy);
  font-weight: 800;
  text-align: left;
  padding: 0.72rem 0.9rem;
  border-bottom: 2px solid var(--pt-border);
}
.dh-pt-table td {
  padding: 0.72rem 0.9rem;
  border-bottom: 1px solid #f1f5f9;
  vertical-align: middle;
}
.dh-pt-table th.is-num,
.dh-pt-table td.is-num {
  text-align: right;
  white-space: nowrap;
}
.dh-pt-table tfoot td {
  background: #fafcff;
  font-weight: 700;
}
.dh-pt-table tr.is-total td {
  background: #f0fdfa;
  color: var(--pt-teal-dark);
  font-size: 0.98rem;
  font-weight: 900;
}

/* Empty State */
.dh-pt-empty {
  text-align: center;
  padding: 3.25rem 1.5rem;
}
.dh-pt-empty-icon {
  width: 78px;
  height: 78px;
  border-radius: 50%;
  background: var(--pt-teal-soft);
  color: var(--pt-teal);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 2.35rem;
  margin-bottom: 1rem;
}

/* ==========================================================================
   Pharmacy Online Payment Gateway Page (.dh-pay-page)
   ========================================================================== */
.dh-pay-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 1.5rem;
  align-items: start;
}
.dh-pay-methods-list {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  margin: 1rem 0 1.25rem;
}
.dh-pay-method-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  border: 2px solid var(--pt-border);
  border-radius: 14px;
  background: #ffffff;
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}
.dh-pay-method-item:hover {
  border-color: var(--pt-teal);
  background: #f8fffe;
}
.dh-pay-method-item:has(input:checked) {
  border-color: var(--pt-teal);
  background: var(--pt-teal-soft);
  box-shadow: 0 0 0 1px var(--pt-teal);
}
.dh-pay-method-left {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}
.dh-pay-method-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 1.15rem;
  flex-shrink: 0;
}
.dh-pay-icon-bkash { background: #fce7f3; color: #be185d; }
.dh-pay-icon-nagad { background: #ffedd5; color: #c2410c; }
.dh-pay-icon-ssl { background: #dbeafe; color: #1d4ed8; }

.dh-pay-sandbox-box {
  background: #f8fafc;
  border: 1px dashed #94a3b8;
  border-radius: 14px;
  padding: 1.15rem 1.25rem;
  margin-bottom: 1.15rem;
}
.dh-pay-field-label {
  display: block;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--pt-navy);
  margin-bottom: 0.35rem;
}
.dh-pay-field-input {
  width: 100%;
  box-sizing: border-box;
  padding: 0.62rem 0.85rem;
  border: 1px solid #94a3b8;
  border-radius: 10px;
  font-size: 0.94rem;
  font-family: inherit;
  min-height: 44px;
}
.dh-pay-field-input:focus {
  outline: 2px solid var(--pt-teal);
  outline-offset: 1px;
  border-color: var(--pt-teal);
}
.dh-pay-field-input:user-invalid {
  border-color: #dc2626;
}

/* Cancel Modal Dialog */
dialog.dh-pt-dialog {
  border: 1px solid var(--pt-border);
  border-radius: 18px;
  padding: 0;
  max-width: 440px;
  width: calc(100% - 2rem);
  box-shadow: 0 24px 60px rgba(15, 23, 42, 0.28);
  margin: auto;
}
dialog.dh-pt-dialog:modal {
  overscroll-behavior: contain;
}
dialog.dh-pt-dialog::backdrop {
  background: rgba(15, 23, 42, 0.58);
  backdrop-filter: blur(4px);
  overflow: hidden;
  overscroll-behavior: contain;
}

/* RTL Support */
body.dh-rtl .dh-pt-kv-v { text-align: start; }
body.dh-rtl .dh-pt-table th,
body.dh-rtl .dh-pt-table td { text-align: right; }
body.dh-rtl .dh-pt-table th.is-num,
body.dh-rtl .dh-pt-table td.is-num { text-align: left; }

@media (max-width: 900px) {
  .dh-pt-grid,
  .dh-pay-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 640px) {
  .dh-pt-lookup-card {
    padding: 1.25rem 1.15rem;
  }
  .dh-pt-search-box {
    flex-direction: column;
  }
  .dh-pt-search-btn {
    justify-content: center;
  }
  .dh-pt-steps {
    flex-direction: column;
    gap: 1rem;
  }
  .dh-pt-steps::before {
    display: none;
  }
  .dh-pt-step {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    text-align: left;
  }
  .dh-pt-step-node {
    margin: 0;
    flex-shrink: 0;
  }
}
