/* Reset default margins and padding */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Base styles */
body {
    font-family: Arial, sans-serif;
    font-size: 16px; /* Default for desktop */
    line-height: 1.6;
    padding: 20px;
    background-color: #f4f4f4;
    color: #333;
}
.container-att{
    width: 75%;
    margin: 1rem auto;
}
.container-att h1{
    font-size: 2.5rem;
    color: rgb(6, 6, 147);
    text-shadow: 2px 4px 10px rgba(0, 0, 0, 0.4);
}

#darkModeToggle{

    background-color: #3498db;
    color: white;
}

#darkModeToggle:hover{
    background-color: #2980b9;
}
h2 {
    font-size: 24px;
    margin-bottom: 15px;
}

.load-section, .dashboard, .report-section, .history-section {
    margin-bottom: 30px;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    width: 100%;
}

select, input, button {
    margin: 5px;
    padding: 10px;
    font-size: 16px; /* Default for desktop */
    border-radius: 5px;
    border: 1px solid #ccc;
}

/* Button styles */
.btn {
    color: white;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-load {
    background-color: #3498db;
}
.btn-load:hover {
    background-color: #2980b9;
}

.btn-message {
    background-color: #3498db;
}
.btn-message:hover {
    background-color: #2980b9;
}

.btn-upload {
    background-color: #9b59b6;
}
.btn-upload:hover {
    background-color: #8e44ad;
}

.btn-present {
    background-color: #2ecc71;
}
.btn-present:hover {
    background-color: #27ae60;
}

.btn-absent {
    background-color: #e74c3c;
}
.btn-absent:hover {
    background-color: #c0392b;
}

.btn-generate {
    background-color: #f1c40f;
    color: #333;
}
.btn-generate:hover {
    background-color: #d4ac0d;
}

/* Table styles */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: #3498db;
    color: white;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}

tr:hover {
    background-color: #f1f1f1;
}

/* Pagination */
.pagination {
    margin-top: 15px;
    text-align: center;
}

.pagination button {
    padding: 8px 16px;
    margin: 0 5px;
}

/* Dark mode */
.dark-mode {
    background-color: #333;
    color: #f4f4f4;
}

.dark-mode .load-section,
.dark-mode .dashboard,
.dark-mode .report-section,
.dark-mode .history-section,
.dark-mode .header-att h1 {
    background-color: #444;
    color: #f4f4f4;
}

.dark-mode th {
    background-color: #555;
}

.dark-mode tr:nth-child(even) {
    background-color: #3a3a3a;
}

.dark-mode tr:hover {
    background-color: #4a4a4a;
}

/* Mobile adjustments */
@media (max-width:800px) {
    body {
        font-size: 20px; /* Increased base font size for mobile */
        padding: 10px;
    }
    .container-att{
        width:95%;
    }
#darkModeToggle{
    width: 50%;
}
.header-att h1{
    text-align: center;
}
    h2 {
        font-size: 28px; /* Larger headings */
    }

    select, input, button {
        font-size: 18px; /* Larger inputs and buttons */
        padding: 12px; /* More padding for touch */
        width: 100%; /* Full width for easier tapping */
        margin: 8px 0; /* More vertical spacing */
    }

    .btn {
        padding: 12px 12px; /* Larger buttons */
    }

    table {
        font-size: 18px; /* Larger table text */
        display: block;
        overflow-x: auto; /* Horizontal scroll for tables */
        white-space: nowrap;
    }

    th, td {
        padding: 10px; /* Slightly reduced padding to fit more content */
        min-width: 100px; /* Ensure columns don’t collapse too much */
    }

    .load-section, .dashboard, .report-section, .history-section {
        padding: 15px; /* Slightly less padding */
    }

    canvas {
        max-width: 100%; /* Ensure chart fits screen */
        height: auto;
    }

    .pagination button {
        padding: 10px 20px; /* Larger pagination buttons */
        font-size: 18px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 18px; /* Slightly smaller for very small screens */
        width: 100%;
    }

    h2 {
        font-size: 24px;
    }

    select, input, button {
        font-size: 16px;
        padding: 10px;
    }

    th, td {
        font-size: 16px;
        padding: 8px;
    }

    .container-att{width: 100%;}
}

.header-att{
    width: 100%;
    display: flex;
    justify-content: space-around;
    flex-direction: row;
    /* padding: 1rem 4rem; */
}