﻿/* ===== TABLE STYLES (Desktop) ===== */
.desktop-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border-radius: 0.5rem;
    overflow: hidden;
}

    .desktop-table thead {
        background-color: #f8f9fa;
        border-bottom: 2px solid #dee2e6;
    }

    .desktop-table th {
        padding: 0.75rem 1rem;
        font-weight: 600;
        font-size: 0.875rem;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        color: #495057;
        text-align: left;
        border-bottom: 1px solid #dee2e6;
    }

    .desktop-table td {
        padding: 1rem;
        vertical-align: middle;
        border-bottom: 1px solid #e9ecef;
        font-size: 0.9rem;
        color: #212529;
    }

    .desktop-table tbody tr {
        transition: all 0.2s ease;
        cursor: pointer;
    }

        .desktop-table tbody tr:hover {
            background-color: rgba(0, 123, 255, 0.05);
            transform: translateY(-1px);
        }

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

/* Table responsive container */
.table-responsive-container {
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

/* ===== CARD STYLES (Mobile) ===== */
.mobile-cards-container {
    display: none;
}

.mobile-card {
    background: white;
    border-radius: 0.75rem;
    box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.1);
    margin-bottom: 1rem;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
}

    .mobile-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 0.25rem 1rem rgba(0, 0, 0, 0.15);
    }

.mobile-card-header {
    padding: 1rem 1.25rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-bottom: 1px solid #dee2e6;
}

.mobile-card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #212529;
    margin: 0 0 0.25rem 0;
}

.mobile-card-subtitle {
    font-size: 0.875rem;
    color: #6c757d;
    margin: 0;
}

.mobile-card-body {
    padding: 1.25rem;
}

.mobile-card-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f8f9fa;
}

    .mobile-card-row:last-child {
        border-bottom: none;
    }

.mobile-card-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #495057;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mobile-card-value {
    font-size: 0.9rem;
    font-weight: 600;
    color: #212529;
}

.mobile-card-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #f8f9fa;
}

.mobile-stat-item {
    text-align: center;
    padding: 0.5rem;
    background: #f8f9fa;
    border-radius: 0.375rem;
}

.mobile-stat-label {
    font-size: 0.75rem;
    color: #6c757d;
    margin-bottom: 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mobile-stat-value {
    font-size: 1rem;
    font-weight: 600;
    color: #212529;
}

.mobile-card-actions {
    padding: 1rem 1.25rem;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

/* ===== RESPONSIVE BREAKPOINTS ===== */
@media (max-width: 768px) {
    .desktop-table-container {
        display: none;
    }

    .mobile-cards-container {
        display: block;
    }
}

@media (min-width: 769px) {
    .desktop-table-container {
        display: block;
    }

    .mobile-cards-container {
        display: none;
    }
}

/* ===== SPECIFIC TABLE VARIANTS ===== */
/* Broadsheet table */
.broadsheet-table.desktop-table th {
    font-size: 0.75rem;
    white-space: nowrap;
    vertical-align: middle;
}

.broadsheet-table.desktop-table td {
    font-size: 0.8rem;
    vertical-align: middle;
}

/* Marks edit table */
.marks-edit-table.desktop-table .paper-score {
    width: 100%;
    min-width: 70px;
    padding: 0.35rem 0.5rem;
    text-align: center;
}

/* ===== UTILITY CLASSES ===== */
.text-nowrap {
    white-space: nowrap;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.fw-bold {
    font-weight: 600;
}

.fw-semibold {
    font-weight: 500;
}

.text-primary {
    color: #1b6ec2 !important;
}

.text-muted {
    color: #6c757d !important;
}

.bg-light {
    background-color: #f8f9fa !important;
}


/* ===== MINIMAL MOBILE ACCORDION STYLES ===== */
.mobile-accordion-container {
    display: none;
}

    .mobile-accordion-container .accordion-item {
        background: white;
        border-radius: 0.75rem;
        box-shadow: 0 0.125rem 0.5rem rgba(0, 0, 0, 0.08);
        margin-bottom: 1rem;
        border: 1px solid #e9ecef;
        overflow: hidden;
        transition: all 0.3s ease;
    }

        .mobile-accordion-container .accordion-item:hover {
            box-shadow: 0 0.25rem 0.75rem rgba(0, 0, 0, 0.12);
        }

    .mobile-accordion-container .accordion-button {
        background: #f8f9fa;
        border: none;
        padding: 1.25rem 1.5rem;
        transition: all 0.3s ease;
    }

        .mobile-accordion-container .accordion-button:not(.collapsed) {
            background: #f8f9fa;
            box-shadow: none;
            border-bottom: 1px solid #e9ecef;
        }

        .mobile-accordion-container .accordion-button::after {
            background-size: 0.8rem;
        }

    .mobile-accordion-container .accordion-body {
        padding: 0;
        background: white;
    }

/* Minimal stats grid */
.minimal-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    padding: 1.5rem;
}

.minimal-stat-item {
    text-align: center;
    padding: 1rem 0.5rem;
    background: #f8f9fa;
    border-radius: 0.5rem;
    border: 1px solid #e9ecef;
}

.minimal-stat-icon {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    display: block;
}

.minimal-stat-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: #212529;
    display: block;
    line-height: 1.2;
}

.minimal-stat-label {
    font-size: 0.75rem;
    color: #6c757d;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-top: 0.25rem;
}

/* Action button */
.minimal-action-btn {
    padding: 0.75rem 1.5rem;
    border-top: 1px solid #e9ecef;
    background: #f8f9fa;
}

/* Update responsive breakpoints */
@media (max-width: 768px) {
    .desktop-table-container {
        display: none;
    }

    .mobile-cards-container {
        display: none;
    }

    .mobile-accordion-container {
        display: block;
    }
}

@media (min-width: 769px) {
    .desktop-table-container {
        display: block;
    }

    .mobile-cards-container {
        display: none;
    }

    .mobile-accordion-container {
        display: none;
    }
}