/* Main stylesheet for the Parking Management System */

body {
    font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background: linear-gradient(to right, #ece9e6, #ffffff); /* Subtle gradient background */
    color: #343a40; /* Darker text color */
    min-height: 100vh; /* Ensure body takes full viewport height */
    display: flex;
    flex-direction: column;
}

/* Custom styles for header */
header {
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

header h1 {
    font-weight: 700;
    color: #ffffff;
}

header a.btn {
    font-weight: 500;
    transition: all 0.3s ease-in-out;
}

header a.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

/* Custom styles for footer */
footer {
    background-color: #343a40 !important; /* Dark background for footer */
    color: #ffffff;
    box-shadow: 0 -2px 4px rgba(0,0,0,.1);
    margin-top: auto; /* Push footer to the bottom */
}

/* Custom styles for cards in dashboard */
.card {
    border-radius: 0.75rem;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,.15) !important;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid rgba(0,0,0,.125);
    font-weight: 600;
}

.card-title {
    color: #007bff; /* Primary color for titles */
}

.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
}

.btn-primary:hover {
    background-color: #0056b3;
    border-color: #0056b3;
}

.btn-success {
    background-color: #28a745;
    border-color: #28a745;
    font-size: 1.25rem; /* Larger button */
    padding: 0.75rem 1.5rem; /* More padding */
    border-radius: 0.5rem; /* Rounded corners */
}

.btn-success:hover {
    background-color: #1e7e34;
    border-color: #1e7e34;
}

/* Dark Mode Styles */
body.dark-mode {
    background: linear-gradient(to right, #2c3e50, #34495e); /* Darker gradient */
    color: #ecf0f1;
}

body.dark-mode header {
    background-color: #2c3e50 !important;
    box-shadow: 0 2px 4px rgba(0,0,0,.3);
}

body.dark-mode header h1 {
    color: #ecf0f1;
}

body.dark-mode footer {
    background-color: #2c3e50 !important;
    box-shadow: 0 -2px 4px rgba(0,0,0,.3);
}

body.dark-mode .card {
    background-color: #34495e;
    color: #ecf0f1;
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,.3) !important;
}

body.dark-mode .card-header {
    background-color: #2c3e50;
    border-bottom-color: rgba(255,255,255,.125);
    color: #ecf0f1;
}

body.dark-mode .card-title {
    color: #3498db; /* A lighter blue for dark mode titles */
}

body.dark-mode .card .text-dark {
    color: #ecf0f1 !important;
}

body.dark-mode .card .text-muted {
    color: #bdc3c7 !important;
}

body.dark-mode .text-primary {
    color: #5dade2 !important; /* A lighter shade of blue for dark mode */
}

body.dark-mode .form-control,
body.dark-mode .form-select {
    background-color: #4a627a;
    color: #ecf0f1;
    border-color: #5a7a9a;
}

body.dark-mode .form-control::placeholder,
body.dark-mode .form-select::placeholder {
    color: #bdc3c7;
}

body.dark-mode .form-control:focus,
body.dark-mode .form-select:focus {
    background-color: #4a627a;
    color: #ecf0f1;
    border-color: #3498db;
    box-shadow: 0 0 0 0.25rem rgba(52, 152, 219, 0.25);
}

.dark-mode-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    background-color: #343a40;
    color: #ffffff;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,.2);
    transition: background-color 0.3s, transform 0.3s;
}

.dark-mode-toggle:hover {
    transform: scale(1.1);
    background-color: #495057;
}

body.dark-mode .dark-mode-toggle {
    background-color: #ecf0f1;
    color: #343a40;
}

body.dark-mode .dark-mode-toggle:hover {
    background-color: #bdc3c7;
}

/* Print Styles */
@media print {
    body {
        background: none !important;
        color: #000 !important;
    }
    header, footer, .dark-mode-toggle, .btn, .alert, .card-header, .card-footer, .mb-4.text-center {
        display: none !important;
    }
    .container {
        width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    .card {
        border: none !important;
        box-shadow: none !important;
        border-radius: 0 !important;
    }
    .table {
        width: 100% !important;
        margin-bottom: 1rem;
        color: #212529;
        border-collapse: collapse;
    }
    .table th, .table td {
        padding: 0.75rem;
        vertical-align: top;
        border-top: 1px solid #dee2e6;
    }
    .table thead th {
        vertical-align: bottom;
        border-bottom: 2px solid #dee2e6;
    }
    .table-striped tbody tr:nth-of-type(odd) {
        background-color: rgba(0, 0, 0, 0.05);
    }
    h2, h3, h5 {
        color: #000 !important;
        text-align: center;
        margin-bottom: 1rem;
    }
    .display-4 {
        font-size: 2.5rem;
        font-weight: 300;
        line-height: 1.2;
    }
    .row.text-center.mb-4 .col-md-6 {
        flex: 0 0 auto;
        width: 50%;
        max-width: 50%;
    }
}
