/* =========================================
   Shared CSS File - Used Across All Pages
   This file contains global styles for layout,
   typography, header, footer, and responsive design.
========================================= */

/* ===============================
   General Reset & Base Styles
================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background-color: white;
    color: black;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
}

header {
    background-color: #1E2A38;
    color: #fff;
    padding: 1.25rem;
    height: 18vh;
    text-align: center;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 1vh;
}

header nav > ul {
    list-style: none;
    padding: 0;
}

header nav > ul > li {
    display: inline;
    margin: 0 3vh;
}

header nav > ul li a {
    color: white;
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    padding-bottom: 5px;
    border-bottom: 3px solid transparent;
}

header nav > ul li a:hover,
header nav > ul li a.active {
    color: yellowgreen;
    border-bottom: 3px solid yellowgreen;
}

footer {
    background-color: #1E2A38;
    color: white;
    text-align: center;
    padding: 5px 10px;
    font-size: 0.85rem;
}

button {
    padding: 10px;
    margin: 5px 0;
    border: 1px solid gray;
    border-radius: 4px;
    background-color: green;
    color: white;
    cursor: pointer;
    font-size: 1rem;
}

button:hover {
    background-color: darkgreen;
}

@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    nav ul li {
        display: block;
        margin: 10px 0;
    }

    nav ul li a {
        font-size: 1.1rem;
    }
}


.content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background-color: #ffffff;
    padding: 25px;
}

.toolbar {
    margin-bottom: 25px;
}

.table-container {
    flex: 1;
    overflow-y: auto;
    border: 1px solid #dee2e6;
    border-radius: 8px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    background-color: #f8f9fa;
    position: sticky;
    top: 0;
    z-index: 10;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #dee2e6;
}

th, td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid #ecf0f1;
}

.searchBar {
    width: 100%;
    padding: 15px;
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    font-size: 18px;
    outline: none;
    transition: border-color 0.2s;
}

.searchBar:focus {
    border-color: #3498db;
}

.searchable {
    display: none;
}

.searchable.active-group {
    display: table-row;
}

tr.searchable:hover {
    background-color: #f1f7fd;
}


/* Modal Styles */
.modal {
    display: none;
    /* Hidden by default */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(0, 0, 0, 0.6);
    /* Darker overlay */
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-in-out;
}

.modal.show {
    display: flex;
    opacity: 1;
    pointer-events: all;
}

.modal-content {
    background-color: #fff;
    margin: 0 auto;
    padding: 30px;
    border-radius: 10px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 2px 10px rgb(0, 0, 0, 0.1);
    transition: transform 0.3s ease-out;
    transform: scale(0.9);
}

.modal.show .modal-content {
    transform: scale(1);
}