/* Basic Styles */
/* --- General Styles --- */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: #f8f9fa;
    color: #212529;
    line-height: 1.6;
    margin: 0;
    padding: 0;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: auto;
    padding: 20px;
}

/* --- Navigation Bar --- */
nav {
    background: #343a40;
    color: #fff;
    padding: 15px 0;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-left: 5%;
    padding-right: 5%;
}

nav .logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
    text-decoration: none;
}

nav ul {
    padding: 0;
    margin: 0;
    list-style: none;
    display: flex;
}

nav li {
    padding: 0 15px;
}

nav a {
    color: #fff;
    text-decoration: none;
    transition: color 0.3s;
}

nav a:hover {
    color: #adb5bd;
}

/* --- Mobile Navigation --- */
.menu-toggle {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.menu-toggle .bar {
    height: 3px;
    width: 25px;
    background-color: #fff;
    margin: 4px 0;
    transition: 0.4s;
}

/* --- Forms --- */
.form-container {
    width: 100%;
    max-width: 500px;
    margin: 20px auto;
    padding: 25px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group input[type='text'],
.form-group input[type='email'],
.form-group input[type='password'],
.form-group select,
.form-group input[type='number'],
.form-group input[type='date'] {
    width: 100%;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #ced4da;
    box-sizing: border-box;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    background: #007bff;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.3s;
}

.btn:hover {
    background: #0056b3;
}

/* --- Tables --- */
table {
    width: 100%;
    margin-top: 20px;
    border-collapse: collapse;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

table thead {
    background: #e9ecef;
}

table th, table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #dee2e6;
}

/* --- Status Indicators --- */
.status-paid, .status-unpaid, .status-pending, .status-active, .status-approved {
    padding: 5px 10px;
    border-radius: 15px;
    font-weight: bold;
    color: #fff;
    display: inline-block;
    font-size: 0.9em;
}

.status-paid, .status-approved, .status-active {
    background-color: #28a745;
}

.status-unpaid {
    background-color: #dc3545;
}

.status-pending {
    background-color: #ffc107;
    color: #212529;
}

/* --- Bottom Navigation for Mobile */
.bottom-nav {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #fff;
    border-top: 1px solid #ddd;
    box-shadow: 0 -2px 5px rgba(0,0,0,0.1);
    z-index: 1000;
}

.bottom-nav ul {
    display: flex;
    justify-content: space-around;
    list-style: none;
    margin: 0;
    padding: 0;
}

.bottom-nav ul li {
    flex-grow: 1;
}

.bottom-nav ul li a {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px 0;
    text-decoration: none;
    color: #333;
    font-size: 12px;
}

.bottom-nav ul li a i {
    font-size: 20px;
    margin-bottom: 4px;
}

.bottom-nav ul li a.active {
    color: #007bff;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    nav {
        display: none;
    }
    .bottom-nav {
        display: block;
    }
    nav ul {
        display: none;
        flex-direction: column;
        width: 100%;
        background-color: #343a40;
        position: absolute;
        top: 60px; /* Adjust based on nav height */
        left: 0;
        text-align: center;
        padding: 0;
        margin: 0;
    }

    nav ul.active {
        display: flex;
    }

    nav li {
        padding: 15px 0;
        width: 100%;
    }

    .menu-toggle {
        display: flex;
    }

    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .report-container {
        flex-direction: column;
    }

    .summary-box {
        width: 100%;
        margin-bottom: 15px;
    }

    .chart-container {
        width: 100%;
    }

    nav a {
        color: #fff;
        text-decoration: none;
    }

    nav a:hover {
        text-decoration: underline;
    }
}
