/* General Reset */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Responsive Design */
@media (min-width: 1920px) {
    .container {
        max-width: 1920px !important;
    }
}

main {
    max-height: 250px; /* Reduce as needed */
    overflow: hidden;
    padding-top: 20px 0;
}
.container {
        max-width: 100%;
        margin-left: 0;
    }

/* Avoid content overlap */
.container {
    max-width: calc(100% - 220px); /* Adjust the container width to prevent overlap */
    margin-left: 220px;
}
/* Logo Adjustments */
.img-logo {
    width: 45%;
    height: 100px;
    border: 0;
}

/* mainbar */
.mainbar {
    /* width: 220px;
    height: 100%; */
    /* position: fixed; */
    background-color: #2c3e50;
    padding: 20px 10px;
    color: white;
    flex-shrink: 0; /* Prevent mainbar from shrinking */
}

/* mainbar content */
.mainbar h2 {
    color: white;
    text-align: center;
    margin-bottom: 30px;
}

.mainbar a {
    /* display: block; */
    color: white;
    padding: 12px 20px;
    text-decoration: none;
    font-size: 16px;
}

.mainbar a:hover {
    background-color: #608ada;
}

/* Main content */
.main-content {
    flex: 1; /* Take up remaining width */
    padding-left: 10px;
    padding-right: 10px;
}

/* Responsive behavior */
@media (max-width: 768px) {
    .containerwithsidebar {
        flex-direction: column;
    }

    .main-content {
        width: 100%;
    }
}

.success {
        background-color: #e0f7e9;
        color: #2e7d32;
        padding: 10px;
        border: 1px solid #b2dfdb;
        margin-bottom: 10px;
        border-radius: 5px;
    }

    .error {
        background-color: #fdecea;
        color: #c62828;
        padding: 10px;
        border: 1px solid #f5c6cb;
        margin-bottom: 10px;
        border-radius: 5px;
    }
    
    /* Style for the tab buttons */
    .tab-buttons {
        margin-bottom: 20px;
    }
    .tab-buttons button {
        padding: 10px 20px;
        cursor: pointer;
        border: none;
        background-color: #f1f1f1;
        color: #282c34;
        margin-right: 5px;
    }
    .tab-buttons button.active {
        background-color: #007bff;
        color: white;
    }

    /* Hide tab content by default */
    .tab-content {
        display: none;
    }

    .tab-content.active {
        display: block;
    }

 .tablediv {
    padding-left: 10px;
    padding-right: 10px;
 }
/* Table Styling */
table {
    border-collapse: collapse;
    width: 100%;
    margin-top: 30px;
}

th, td {
    text-align: center;
    padding: 8px;
    border: 1px solid #ddd;
}

table th {
    background-color: #f4f4f4;
}

/* Hover effect for table rows */
tr:nth-child(even) {
    background-color: #f2f2f2;
}

.clickable {
    cursor: pointer;
}

.table thead th {
    border-right: 3px solid white;
}

.hidden-column {
        display: none;
    }

/* Images */
.icon {
    width: 30%;
}

.thumbnail {
    cursor: pointer;
    transition: 0.3s;
}

.thumbnail:hover {
    opacity: 0.7;
}

/* Modal Styling */
.modal-dialog {
    max-width: min-content;
}

/* Links Styling */
.info-a {
    text-decoration: none;
    display: inline-block;
    background-color: #f1f1f1;
    color: black;
}

.required-label::after {
    content: "*";
    color: red;
    margin-left: 0.5em;
    font-weight: bold;
}

/* Login Page Styling */
.div-center {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 65vh;
}

.content {
    background-color: #282c34;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    max-width: 400px;
    width: 100%;
}

.heading {
    font-size: 2rem;
    color: aliceblue;
    margin-bottom: 20px;
}

/* Form Group Styling */

.form-control {
    width: 100%;
    padding: 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

.form-control:focus {
    border-color: #007bff;
    outline: none;
}

/* Button Styling */
.btn-primary {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    width: 100%;
}

.btn-primary:hover {
    background-color: #0056b3;
}

/* General Body Styling */
body {
    margin: 0;
    font-family: Arial, sans-serif;
}


/* Dashboard Box */
.dashboard-title {
    font-size: 24px;
    margin-bottom: 20px;
}

.box-container {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    padding-left: 225px;
}

.box {
    flex: 1;
    min-width: 250px;
    background-color: white;
    padding: 20px;
    border-left: 5px solid #3498db;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.box h3 {
    margin: 0 0 10px;
    font-size: 18px;
    color: #555;
}

.box .count {
    font-size: 32px;
    font-weight: bold;
    color: #2c3e50;
}

/* Greeting Section */
.greeting {
    text-align: right;
    margin-bottom: 20px;
}

.greeting h2 {
    margin: 0;
    color: #2c3e50;
}

/* Action Links */
.action-links a {
    color: #3498db;
    text-decoration: none;
}

.action-links a:hover {
    text-decoration: underline;
}

/* add visitor form style */
/* Flex layout for form fields */
.form-container {
    max-width: 100%;
    padding: 30px 25px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

/* Flexbox for form fields */
.form-row {
    display: flex;
    justify-content: space-between;
    gap: 20px; /* Add space between the two fields */
}

/* Additional margin for each div inside form-row */
.form-row div {
    flex: 1;
    margin-right: 20px; /* Add space between child divs */
}

.form-row div:last-child {
    margin-right: 0; /* Remove margin from the last child */
}

/* Form field styling for both fields in a row */
.form-row label,
.form-row input {
    width: 100%;  /* Ensures inputs fill the container */
}

/* Ensure all input fields are full-width in individual form sections */
.form-container input[type="text"],
.form-container input[type="email"],
.form-container input[type="password"],
.form-container input[type="date"],
.form-container input[type="number"],
.form-container input[type="file"],
.form-container textarea,
.form-container select {
    width: 100%;
    padding: 5px 0px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
    box-sizing: border-box;
}

.form-container label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
    color: #333;
}

/* Center button and set normal size */
.form-container button {
    width: auto; /* Set to normal size */
    padding: 10px 20px; /* Normal padding for better spacing */
    font-size: 16px; /* Normal font size */
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    display: block; /* Make the button a block element */
    margin: 20px auto; /* Center the button */
    text-align: center; /* Align text inside the button */
}

.form-container button:hover {
    background-color: #0056b3;
}

/* Handle specific input styles */
input[type="datetime-local"] {
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 100%;
    box-sizing: border-box;
    background-color: #f9f9f9;
}

input[type="datetime-local"]:focus {
    border-color: #4c8bf5;
    outline: none;
    background-color: #fff;
}


     /* Modal styles */
     .modal {
        display: none;
        position: fixed;
        z-index: 1;
        left: 0;
        top: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0,0,0,0.4);
    }

    .modal-content {
        background-color: #fefefe;
        margin: 15% auto;
        padding: 20px;
        border: 1px solid #888;
        width: 370px !important; /* Fixed width */
        height: 320px; /* Equal height to width (Square shape) */
        position: relative; /* Positioning relative for absolute elements inside */
    }

    .close {
        position: absolute;
        top: 10px;
        right: 10px;
        color: #aaa;
        font-size: 28px;
        font-weight: bold;
        cursor: pointer;
    }

    .close:hover,
    .close:focus {
        color: black;
        text-decoration: none;
    }

    /* Optional: Styling for the video and capture button */
    #video {
        width: 100%; 
        height: 100%;
    }

    #capture {
        margin-top: 10px;
    }

    /* update_out_time css */
    .main-content-outtime {
    max-width: 800px;
    margin: 50px auto;
    padding: 30px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

form {
    display: flex;
    flex-direction: column;
    gap: 0px;
}

p {
    font-size: 16px;
    color: #555;
}

label {
    font-size: 16px;
    font-weight: bold;
    color: #333;
}
input[type="datetime-local"] {
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 100%;
    box-sizing: border-box;
    background-color: #f9f9f9;
}

input[type="datetime-local"]:focus {
    border-color: #4c8bf5;
    outline: none;
    background-color: #fff;
}
button {
    padding: 12px 20px;
    font-size: 16px;
    background-color: #4c8bf5;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #3578e5;
}

a {
    text-align: center;
    display: inline-block;
    margin-top: 10px;
    font-size: 16px;
    color: #4c8bf5;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 4px;
    background-color: #f4f7fc;
    transition: background-color 0.3s ease;
}

a:hover {
    background-color: #e0e9f7;
}

a:focus, button:focus {
    outline: none;
}

/* add css for datatable  */
.main-content {
    padding: 20px;
    background: #f8f9fa;
}

.table-tabs {
    margin-bottom: 20px;
}

.nav-tabs {
    border-bottom: 2px solid #dee2e6;
}

.nav-tabs .nav-link {
    border: none;
    color: #495057;
    padding: 10px 20px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-tabs .nav-link.active {
    color: #007bff;
    border-bottom: 2px solid #007bff;
    background: none;
}

.card {
    border: none;
    box-shadow: 0 0 15px rgba(0,0,0,0.1);
    border-radius: 8px;
}

.card-body {
    padding: 20px;
}

.table {
    width: 100%;
    margin-bottom: 0;
}

.visitor-details {
    display: block;
    width: 100%;
    white-space: normal;
}

.visitor-photo {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    object-fit: cover;
}

.visitor-info {
    font-size: 0.9rem;
}

.badge {
    padding: 5px 10px;
    border-radius: 4px;
}

.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
}

.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

/* DataTables Custom Styling */
.dataTables_wrapper .dataTables_filter input {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 5px 10px;
}

.dataTables_wrapper .dataTables_length select {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 5px 10px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
    padding: 5px 10px;
    margin: 0 2px;
    border-radius: 4px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: #007bff;
    color: white !important;
    border: none;
}

/* @font-face {
    font-family: 'FontAwesome';
    src: url('../fa-solid-900.woff2') format('woff2'),
         url('../fa-solid-900.woff') format('woff');
    font-weight: normal;
    font-style: normal;
} */