/* ===== Dashboard Admin Panel ===== */

.dashboard-wrap {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 100px 24px 80px;
}

/* Tab navigation */
.dashboard-tabs {
    display: flex;
    gap: 4px;
    background: #f0f2f7;
    border-radius: 14px;
    padding: 4px;
    margin-bottom: 28px;
}

.dashboard-tab {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #5a6a7e;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, box-shadow 0.2s;
    white-space: nowrap;
}

.dashboard-tab:hover {
    color: #12294B;
    text-decoration: none;
}

.dashboard-tab--active {
    background: #ffffff;
    color: #12294B;
    box-shadow: 0 1px 4px rgba(18, 41, 75, 0.1);
}

.dashboard-tab svg {
    flex-shrink: 0;
    opacity: 0.5;
}

.dashboard-tab--active svg {
    opacity: 1;
}

/* Main card */
.dashboard-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px 36px;
    box-shadow: 0 2px 12px rgba(18, 41, 75, 0.06);
    border: 1px solid rgba(18, 41, 75, 0.06);
}

.dashboard-card-title {
    font-size: 20px;
    font-weight: 700;
    color: #12294B;
    margin: 0 0 24px;
}

/* Form elements */
.dashboard-form {
    max-width: 560px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.dashboard-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dashboard-label {
    font-size: 13px;
    font-weight: 600;
    color: #5a6a7e;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.dashboard-input,
.dashboard-select,
.dashboard-textarea {
    padding: 10px 14px;
    border: 1px solid #e0e6ee;
    border-radius: 10px;
    font-size: 14px;
    color: #12294B;
    background: #f8f9fb;
    transition: border-color 0.2s, box-shadow 0.2s;
    width: 100%;
    box-sizing: border-box;
}

.dashboard-input:focus,
.dashboard-select:focus,
.dashboard-textarea:focus {
    outline: none;
    border-color: var(--color-blue-dark, #3657CD);
    box-shadow: 0 0 0 3px rgba(54, 87, 205, 0.1);
    background: #ffffff;
}

.dashboard-textarea {
    min-height: 120px;
    resize: vertical;
}

.dashboard-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 24px;
    background: linear-gradient(135deg, #3657CD 0%, #12294B 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.2s;
    width: fit-content;
}

.dashboard-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.dashboard-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none;
}

.dashboard-btn--secondary {
    background: #f0f2f7;
    color: #12294B;
}

.dashboard-btn--secondary:hover {
    background: #e4e8f0;
}

/* Radio / Checkbox */
.dashboard-radio-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.dashboard-radio {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: #3a4a5e;
    cursor: pointer;
}

.dashboard-radio input[type="radio"],
.dashboard-radio input[type="checkbox"] {
    accent-color: var(--color-blue-dark, #12294B);
    width: 18px;
    height: 18px;
}

/* Search box */
.dashboard-search-box {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 24px;
    padding: 20px 24px;
    background: #f8f9fb;
    border-radius: 14px;
}

.dashboard-search-box .dashboard-input {
    flex: 1;
    min-width: 160px;
    background: #ffffff;
}

.dashboard-search-box .dashboard-btn {
    flex-shrink: 0;
}

/* Table */
.dashboard-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 14px;
}

.dashboard-table thead th {
    background: #f5f7fa;
    padding: 12px 16px;
    font-weight: 600;
    color: #12294B;
    text-align: left;
    border-bottom: 2px solid #e0e6ee;
    white-space: nowrap;
}

.dashboard-table thead th:first-child {
    border-radius: 10px 0 0 0;
}

.dashboard-table thead th:last-child {
    border-radius: 0 10px 0 0;
}

.dashboard-table thead th.sortable {
    cursor: pointer;
    user-select: none;
    transition: color 0.2s;
}

.dashboard-table thead th.sortable:hover {
    color: var(--color-blue-dark, #3657CD);
}

.dashboard-table tbody td {
    padding: 12px 16px;
    border-bottom: 1px solid #f0f2f7;
    color: #3a4a5e;
}

.dashboard-table tbody tr:hover {
    background: #f8f9fb;
}

.dashboard-table tbody tr:last-child td {
    border-bottom: none;
}

.dashboard-table-total td {
    font-weight: 700;
    color: #12294B;
    background: #f5f7fa !important;
}

.dashboard-table-total td:first-child {
    border-radius: 0 0 0 10px;
}

.dashboard-table-total td:last-child {
    border-radius: 0 0 10px 0;
}

/* Stats line */
.dashboard-stat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    background: #f0f4ff;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #12294B;
    margin-top: 20px;
}

/* Divider */
.dashboard-divider {
    height: 1px;
    background: #f0f2f7;
    margin: 32px 0;
    border: none;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .dashboard-wrap {
        padding: 90px 16px 48px;
    }

    .dashboard-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .dashboard-card {
        padding: 24px 20px;
        border-radius: 16px;
    }

    .dashboard-search-box {
        flex-direction: column;
    }

    .dashboard-table {
        font-size: 13px;
    }

    .dashboard-table thead th,
    .dashboard-table tbody td {
        padding: 10px 12px;
    }
}

/* Toast */
#dashboard-toast {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: #12294B;
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    padding: 10px 24px;
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(18, 41, 75, 0.2);
    opacity: 0;
    transition: opacity 0.25s, transform 0.25s;
    z-index: 10000;
    pointer-events: none;
    white-space: nowrap;
}
#dashboard-toast.visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
#dashboard-toast.toast--success { background: #2e7d32; }
#dashboard-toast.toast--danger { background: #d32f2f; }
