.pc-item.active > .pc-link {
    background: #eef6ff;
    border-radius: 8px;
    font-weight: 600;
    color: #1d4ed8 !important;
}

.pc-item.active > .pc-link .pc-micon i {
    color: #1d4ed8;
}

.pc-subtitle {
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: .05em;
    color: #94a3b8;
    padding: 12px 16px;
    text-transform: uppercase;
}

.pc-micon i {
    font-size: 18px;
    opacity: 0.8;
}

.pc-link:hover i {
    opacity: 1;
    transform: translateX(2px);
    transition: 0.15s ease;
}

.pc-link:hover {
    background-color: #f8fafc;
    border-radius: 8px;
}

.navbar-content {
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    padding-bottom: 16px;
}

.sidebar-collapsed .pc-sidebar {
    width: 70px;
}

.sidebar-collapsed .pc-mtext {
    display: none;
}

.sidebar-collapsed .b-brand span {
    display: none;
}

.swal-custom-popup {
    border-radius: 20px !important;
    border: 1px solid #f1f5f9 !important;
    box-shadow: 0 8px 32px rgba(15, 23, 42, 0.15) !important;
}

.ref-chip {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .45rem .9rem;
    border-radius: 999px;
    background: #f1f5ff;
    color: #334155;
    font-weight: 700;
    font-size: 1rem;
}

/* 1) center the text inside chip */
.ref-chip-center {
    min-width: 200px;              /* adjust until it looks right */
    justify-content: center;
}

/* 2) make disabled resend look clearly disabled */
.btn-resend:disabled {
    background: #eef2f7 !important;
    border-color: #d7deea !important;
    color: #94a3b8 !important;
    cursor: not-allowed;
    opacity: 1;                    /* keep it readable but clearly disabled */
}

/* optional: keep height consistent */
.btn-resend {
    padding: 0.7rem;
    font-weight: 600;
    font-size: 1.05rem;
    border-radius: 0.55rem;
}

#countdown {
    font-variant-numeric: tabular-nums;
}

.money {
    font-variant-numeric: tabular-nums;
}

.trx-desc {
    max-width: 520px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--bs-font-monospace);
}

.dataTables_wrapper .dataTables_filter input {
    border-radius: 10px;
    padding: .35rem .6rem;
}

.dataTables_wrapper .dataTables_length select {
    border-radius: 10px;
    padding: .25rem .5rem;
}

table.dataTable thead th {
    font-weight: 600;
}

/* Transaction summary cards */
.trx-sum-card, .settlement-report-sum-card {
    border: 1px solid rgba(0,0,0,.06);
    border-radius: 14px;
    box-shadow: 0 6px 18px rgba(0,0,0,.04);
}

.trx-sum-label, .settlement-report-sum-label {
    font-size: 12px;
    letter-spacing: .02em;
    color: #6c757d;
    margin-bottom: 6px;
}

.trx-sum-value, .settlement-report-sum-value {
    font-size: 22px;
    font-weight: 700;
    line-height: 1.1;
    color: #111827;
    font-variant-numeric: tabular-nums;
}

.trx-sum-icon, .settlement-report-sum-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(13,110,253,.08);
    color: #0d6efd;
    font-size: 22px;
}

/* Small tweak so cards don’t feel too tall */
#trxSummary .card-body, #settlement-report-sum-card .card-body {
    padding: 14px 16px;
}

.metric-card {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 16px 18px;
    height: 100%;
}

.metric-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.metric-value {
    margin-top: 6px;
    font-size: 2rem;
    font-weight: 700;
    color: #212529;
    line-height: 1.2;
}

.metric-success {
    background: linear-gradient(135deg, #e6fff5, #f3fffa);
}

.metric-success .metric-value {
    color: #0f5132;
}

.chart-wrap{
    position: relative;
    height: 320px;       /* adjust: 280~360 */
    width: 100%;
}

/* keeps the contribution block centered consistently in the column */
.contrib-wrap{
    width: 160px;                 /* fixed width makes all rows line up */
    margin: 0 auto;               /* center inside td */
    display: grid;
    grid-template-columns: 1fr 56px; /* bar + label */
    align-items: center;
    gap: 10px;
}

.contrib-progress{
    height: 10px;
    border-radius: 999px;
    background: rgba(13,110,253,.12);
    overflow: hidden;
}

.contrib-progress .progress-bar{
    border-radius: 999px;
    background: #0d6efd;
}

.contrib-label{
    text-align: right;
    font-size: 15px;
    font-weight: 700;
    color: #344054;
}

/* --- header row layout --- */
.product-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 14px;
}

.product-stats {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

/* --- section header --- */
.product-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 18px 0 10px;
}

.product-section-head h5 {
    margin: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.product-section-sub {
    color: #6b7280;
    font-size: 13px;
    white-space: nowrap;
}

/* --- grid layout --- */
.product-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

@media (max-width: 1200px) {
    .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 768px) {
    .product-grid { grid-template-columns: 1fr; }
}

/* --- card --- */
.product-card {
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 14px;
    background: #fff;
    display: flex;
    flex-direction: column;
    min-height: 140px; /* keeps heights consistent */
}

.product-card.offline {
    border-color: rgba(239,68,68,.35);
    background: rgba(239,68,68,.03);
}

.product-card .top {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.product-img {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    object-fit: cover;
    border: 1px solid #e5e7eb;
    flex: 0 0 auto;
}

.product-title {
    font-weight: 700;
    font-size: 16px;
    line-height: 1.2;
    margin: 0;
}

.product-code {
    color: #6b7280;
    font-size: 12px;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin-top: 2px;
}

/* badges row */
.badge-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: auto; /* pushes badges to bottom */
    padding-top: 10px;
}

/* badge base */
.pbadge {
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    color: #111827;
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* status badges */
.pbadge.available {
    background: rgba(16,185,129,.12);
    border-color: rgba(16,185,129,.25);
    color: #059669;
}
.pbadge.offline {
    background: rgba(239,68,68,.10);
    border-color: rgba(239,68,68,.25);
    color: #ef4444;
}

/* type badge */
.pbadge.type {
    background: rgba(13,110,253,.08);
    border-color: rgba(13,110,253,.20);
    color: #0d6efd;
}

/* card base */
.pcard{
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 14px;
    background: #fff;
}
.pcard.offline{
    border-color: rgba(239,68,68,.35);
    background: rgba(239,68,68,.04);
}

/* row spacing */
.status-row{ margin-bottom: 10px; }
.info-row{
    display: flex;
    gap: 12px;
    align-items: center;
}
.type-row{
    margin-top: 10px;
}

/* image */
.product-img{
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    border: 1px solid #e5e7eb;
}

/* product info */
.info-main{ min-width:0; }
.product-title{
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    line-height: 1.2;
}
.product-code{
    font-size: 12px;
    color: #6b7280;
    margin-top: 2px;
}

/* status */
.status-pill{
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}
.status-pill .dot{
    width: 8px;
    height: 8px;
    border-radius: 999px;
}
.status-pill.is-available{
    color:#047857;
    background:rgba(16,185,129,.12);
}
.status-pill.is-available .dot{ background:#10b981; }

.status-pill.is-offline{
    color:#b42318;
    background:rgba(239,68,68,.12);
}
.status-pill.is-offline .dot{ background:#ef4444; }

/* type */
.type-pill{
    display:inline-block;
    padding:4px 10px;
    font-size:12px;
    font-weight:600;
    color:#1d4ed8;
    background:rgba(59,130,246,.1);
    border:1px solid rgba(59,130,246,.25);
    border-radius:999px;
}

.type-chip {
    border: 1px solid #4aa3ff;
    color: #4aa3ff;
    background: #fff;
    border-radius: 10px;
    padding: 8px 14px;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: .3px;
    cursor: pointer;
    user-select: none;
    transition: all .15s ease;
}
.type-chip:hover {
    transform: translateY(-1px);
}

.type-chip.active {
    background: #4aa3ff;
    color: #fff;
}

.dashboard-card-main{
    min-width: 0;          /* ✅ critical inside flex */
    flex: 1 1 auto;        /* allow shrink */
}

.dashboard-card-amount{
    display: block;
    width: 100%;
    min-width: 0;          /* ✅ also helpful */
    font-weight: 700;
    line-height: 1.1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;

    font-size: clamp(18px, 2.2vw, 34px); /* tweak if needed */
}

.dashboard-card-main{
    min-width: 0;          /* ✅ critical inside flex */
    flex: 1 1 auto;        /* allow shrink */
}

.dashboard-metric-main{
    flex: 1 1 0;
    min-width: 0;
}

.dashboard-metric-value{
    display: block;
    width: 100%;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
}

/* Ensure DataTables cell itself is vertically centered */
table.dataTable tbody td.align-middle {
    vertical-align: middle !important;
}

/* API Code cell layout */
.api-code-cell{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    white-space: nowrap;
}

/* The code itself looks like a “chip” */
.api-code-badge{
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 12px;
    line-height: 1;
    padding: 6px 10px;
    border: 1px solid #E5E7EB;
    border-radius: 999px;
    background: #F9FAFB;
    color: #111827;
}

/* Copy button with nicer style */
.btn-copy{
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;

    border-radius: 10px;
    border: 1px solid #D1D5DB;
    background: #FFFFFF;
    color: #374151;

    cursor: pointer;
    transition: transform .08s ease, box-shadow .12s ease, background .12s ease, border-color .12s ease;
}

.btn-copy:hover{
    background: #F3F4F6;
    border-color: #9CA3AF;
    box-shadow: 0 4px 14px rgba(0,0,0,.08);
}

.btn-copy:active{
    transform: translateY(1px);
}

.btn-copy:focus{
    outline: none;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, .25);
}

/* Bigger badge + icon for the Cycle column */
.cycle-badge{
    padding: 0.45rem 0.65rem;  /* bigger pill */
    border-radius: 0.6rem;
}

.cycle-icon{
    font-size: 1.15rem;       /* bigger icon */
    line-height: 1;
    vertical-align: middle;
}

/* Optional: make it feel clickable */
.cycle-badge{
    cursor: help;
}