/**
*
*/

.card-info {
    margin: 3rem auto 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.dashboard-container {
    max-width: 100%;
}

.header-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
    gap: 16px;
    flex-wrap: wrap;
}

.header-text {
    flex: 1;
    min-width: 280px;
}

.header-title {
    font-size: 26px;
    font-weight: 700;
    color: #091322;
    letter-spacing: -0.02em;
    line-height: 1.25;
    margin-bottom: 6px;
}

.header-subtitle {
    font-size: 14.5px;
    color: #64748b;
    font-weight: 400;
    line-height: 1.4;
}

.action-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-refresh {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    color: #64748b;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: all 0.2s ease;
}

.btn-refresh:hover {
    background-color: #f1f5f9;
    color: #334155;
    border-color: #94a3b8;
}

.btn-refresh:active {
    transform: scale(0.96);
}

.btn-refresh svg {
    width: 18px;
    height: 18px;
    transition: transform 0.4s ease;
}

.btn-refresh:hover svg {
    transform: rotate(180deg);
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background-color: #0056f6;
    border: 1px solid transparent;
    border-radius: 10px;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 86, 246, 0.2);
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.btn-primary:hover {
    background-color: #0047d4;
}

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

.btn-primary svg {
    width: 17px;
    height: 17px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.stats-grid.grid-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 1200px) {
    .stats-grid.grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .stats-grid.grid-4 {
        grid-template-columns: 1fr;
    }
}

.stat-card {
    background-color: #ffffff;
    border-radius: 12px;
    padding: 18px 22px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 108px;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.stat-card:hover {
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.card-total {
    border: 2px solid #3b82f6;
}

.card-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.card-label {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-icon svg {
    width: 18px;
    height: 18px;
}

.card-body {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.card-number {
    font-size: 30px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}

.card-status-text {
    font-size: 14px;
    font-weight: 400;
}

/* 1. Total Orders */
.card-total .card-label {
    color: #475569;
}

.card-total .card-icon {
    color: #94a3b8;
}

.card-total .card-number {
    color: #0f172a;
}

.card-total .card-status-text {
    color: #64748b;
}

/* 2. Today's Orders */
.card-today {
    border: 2px solid #6366f1;
}

.card-today .card-label {
    color: #4338ca;
}

.card-today .card-icon {
    color: #6366f1;
}

.card-today .card-number {
    color: #312e81;
}

.card-today .card-status-text {
    color: #6366f1;
}

/* Breakdown badges (Unread & Read, Today's breakdown) */
.breakdown-badges,
.today-breakdown {
    min-width: 120px;
}

.breakdown-badges .badge-draft-today {
    background-color: #fffbeb;
    color: #b45309;
    border: 1px solid #fde68a;
    border-radius: 8px;
    font-size: 12px;
    padding: 3px 8px;
    font-weight: 600;
    transition: all 0.15s ease;
}

.breakdown-badges .badge-draft-today:hover {
    background-color: #fef3c7;
    border-color: #fcd34d;
}

.breakdown-badges .badge-publish-today {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    font-size: 12px;
    padding: 3px 8px;
    font-weight: 600;
    transition: all 0.15s ease;
}

.breakdown-badges .badge-publish-today:hover {
    background-color: #dcfce7;
    border-color: #86efac;
}

.breakdown-badges .badge-unread,
.today-breakdown .badge-unread {
    background-color: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
    border-radius: 8px;
    font-size: 12.5px;
    padding: 3px 8px;
    font-weight: 600;
    transition: all 0.15s ease;
}

.breakdown-badges .badge-unread:hover,
.today-breakdown .badge-unread:hover {
    background-color: #fee2e2;
    border-color: #fca5a5;
}

.breakdown-badges .badge-read,
.today-breakdown .badge-read {
    background-color: #f0fdf4;
    color: #16a34a;
    border: 1px solid #bbf7d0;
    border-radius: 8px;
    font-size: 12.5px;
    padding: 3px 8px;
    font-weight: 600;
    transition: all 0.15s ease;
}

.breakdown-badges .badge-read:hover,
.today-breakdown .badge-read:hover {
    background-color: #dcfce7;
    border-color: #86efac;
}

.breakdown-badges .status-dot,
.today-breakdown .status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.breakdown-badges .badge-count,
.today-breakdown .badge-count {
    font-size: 14px;
    font-weight: 700;
    margin-left: 8px;
    line-height: 1;
}

.card-draft .card-label {
    color: #b45309;
}

.card-draft .card-icon {
    color: #f59e0b;
}

.card-draft .card-number {
    color: #b45309;
}

.card-draft .card-status-text {
    color: #c2410c;
}

.card-posted .card-label {
    color: #047857;
}

.card-posted .card-icon {
    color: #10b981;
}

.card-posted .card-number {
    color: #065f46;
}

.card-posted .card-status-text {
    color: #059669;
}

.table-page-card .card-body,
.table-page-card .table-responsive,
.table-page-card .dataTables_wrapper {
    width: 100%;
}

.border-rd-12 {
    border-radius: 12px;
}

.card-box {
    border-radius: 12px;
}

.card .card-header {
    padding: 10px 16px;
    min-height: 0%;
}

#mySearchInput {
    width: 100%;
}

.filter-status {
    display: flex;
    flex-direction: row;
    gap: 10px;
    align-items: center;
}

.filter-actions {
    background: #f1f5f9;
    padding: 3px 6px;
    border-radius: 12px;
}

.filter-actions button {
    border: 0;
    border-radius: 10px;
    background: none;
    padding: 3px 6px;
    cursor: pointer;
}

.filter-actions button.active {
    font-weight: 600;
    background: #fff;
}

.flex-1 {
    flex: 1;
}

.table-row-dashed.dataTable thead th {
    text-transform: uppercase;
    color: #45556c;
    font-weight: 600;
    font-size: 13.5px;
}

.table-row-dashed.dataTable thead th,
.table-row-dashed.dataTable tbody td {
    border-bottom-style: solid;
}

.table-row-dashed.dataTable tbody td {
    font-size: 14px;
    font-weight: 300;
}

.table-row-dashed.dataTable tbody td.order-reference {
    color: #1447e6;
    font-weight: 600;
    font-size: 15px;
}

.table-row-dashed.dataTable tbody td.total-amount {
    font-weight: 600;
    font-size: 15px;
}

.table-row-dashed.dataTable tbody tr:hover {
    box-shadow: none;
    transform: none;
    background: #fafbfd;
}

td.status span.status {
    border: solid 1px #feeb9e;
    border-radius: 12px;
    font-size: 12px;
    padding: 3px 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    font-weight: 500;
    color: #a25019;
    width: auto;
}

td.status span.status svg {
    width: 17px;
    height: 17px;
    color: #feeb9e;
}

td.status span.status.posted-to-bc {
    border-color: #029b56;
    color: #036e3e;
}

td.status span.status.posted-to-bc svg {
    color: #029b56;
}

.app-container .table-page-card {
    min-height: 0% !important;
}

.btn-refresh {
    width: auto;
    display: flex;
    gap: 10px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    color: #1447e6;
    border: 1px solid #1447e6;
    border-radius: 12px;
    background-color: #fff;
}

.customer-name .name {
    font-size: 16px;
    font-weight: normal;
}

.customer-name .email {
    font-size: 14px;
    font-weight: 300;
}

.customer-name .line-items {
    font-size: 12px;
    font-weight: 300;
}

/* Original Email Content Box */
.accordion-body-email {
    background-color: #0c0d0ec7;
    border-radius: 0 0 12px 12px;
    overflow: hidden;
}

.email-content {
    white-space: pre-wrap;
    word-break: break-word;
    color: #fff;
    padding: 16px 20px;
    font-family: 'Courier New', monospace;
    font-size: 14.5px;
    line-height: 1.6;
    max-height: 600px;
    overflow-y: auto;
    overflow-x: hidden;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.05);
}

.email-content::-webkit-scrollbar {
    width: 8px;
}

.email-content::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.email-content::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 4px;
}

.email-content::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.4);
}