/* General Reset */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f4f6f9;
    margin: 0;
    padding: 0;
    color: #333;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: auto;
    padding: 20px;
    text-align: center;
}

/* Headings */
h1 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 32px;
}
h2 {
    color: #34495e;
    margin: 30px 0 15px;
}

/* Forms */
form {
    margin-bottom: 25px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    background: #ffffff;
    padding: 15px;
    border-radius: 10px;
    box-shadow: 0px 2px 6px rgba(0,0,0,0.08);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

form label {
    font-weight: bold;
    margin-bottom: 5px;
    color: #2c3e50;
}

form input[type="month"],
form input[type="text"],
form input[type="number"],
form select,
form textarea {
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    width: 100%;
    font-size: 14px;
    transition: border 0.2s;
}

form input:focus,
form select:focus,
form textarea:focus {
    border-color: #2980b9;
    outline: none;
}

form button {
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    background: #2980b9;
    color: white;
    cursor: pointer;
    transition: 0.3s;
    align-self: flex-start;
}

form button:hover {
    background: #1c5985;
}

/* Mobile Form Responsiveness */
@media (max-width: 600px) {
    form {
        padding: 12px;
        gap: 8px;
    }
    form input,
    form select,
    form textarea,
    form button {
        font-size: 14px;
    }
    form button {
        width: 100%;
        text-align: center;
        align-self: stretch;
    }
}

/* Summary cards */
.summary {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 20px 0;
}
.card {
    flex: 1;
    min-width: 200px;
    padding: 20px;
    border-radius: 12px;
    color: white;
    font-size: 18px;
    box-shadow: 0px 4px 6px rgba(0,0,0,0.1);
    transition: transform .2s;
}
.card:hover {
    transform: translateY(-5px);
}
.card h3 {
    margin: 0 0 10px;
    font-size: 20px;
}
.card.green { background: #27ae60; }
.card.red { background: #e74c3c; }
.card.blue { background: #3498db; }
.card.orange { background: #f39c12; }

/* Table styling */
/* Table Wrapper */
.table-wrapper {
    width: 100%;
    max-width: 100%;
    overflow-x: auto;   /* ✅ Horizontal scroll on small screens */
    overflow-y: auto;   /* ✅ Vertical scroll if too many rows */
    display: flex;

}

/* Center table inside wrapper */
.table-wrapper table {
    margin: 0 auto;
    min-width: 100%;   /* force horizontal scroll if smaller screen */
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0px 2px 5px rgba(0,0,0,0.1);
    min-width: 100%; /* force scroll on small screens */
}
table th, table td {
    padding: 12px;
    border-bottom: 1px solid #ddd;
    text-align: left;
}
table th {
    background: #2c3e50;
    color: white;
}
table tr:nth-child(even) {
    background: #f9f9f9;
}
table tr:hover {
    background: #f1f1f1;
}

/* Status badges */
.badge {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    color: white;
}
.badge.green { background: #27ae60; }
.badge.red { background: #e74c3c; }

/* Navigation Links */
.nav-links {
    margin-top: 30px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}
.nav-links a {
    text-decoration: none;
    padding: 10px 16px;
    border-radius: 8px;
    background: #2980b9;
    color: white;
    transition: 0.3s;
    font-size: 15px;
    display: inline-block;
}
.nav-links a:hover {
    background: #1c5985;
}
@media (max-width: 600px) {
    .nav-links {
        flex-direction: column;
        align-items: stretch;
    }
    .nav-links a {
        width: 90%;
        text-align: center;
    }
    form input[type="month"], form input[type="text"], form input[type="number"], form select, form textarea{
        width: 90% !important;
    }
}

.bg-2c3e50 {
    background: #2c3e50;
}
