@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #f4f6f8;
}

.wrapper {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: 250px;
    background: #1b0163; 
    color: white;
    padding: 30px 20px;
}

.sidebar h2 {
    font-size: 22px;
    margin-bottom: 30px;
    color: #fff;
}

.sidebar ul {
    list-style: none;
}

.sidebar ul li {
    margin-bottom: 5px;
}

.sidebar ul li a {
    text-decoration: none;
    color: white;
    font-size: 16px;
    display: block;
    padding: 8px 15px;
    border-radius: 6px;
    transition: background 0.3s;
}

.sidebar ul li a:hover {
    background: rgba(255, 255, 255, 0.1);
}

.sidebar ul li ul {
    margin-left: 10px;
}

.content {
    flex: 1;
    padding: 30px;
}

.card {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    max-width: 800px;
    margin: auto;
}

.card h2 {
    font-size: 24px;
    margin-bottom: 20px;
}

form input[type="text"],
form input[type="number"],
form input[type="date"],
form select,
form textarea {
    width: 100%;
    padding: 10px 14px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 15px;
}

form textarea {
    resize: vertical;
}

form button {
    background: #1b0163;
    color: white;
    padding: 10px 18px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    transition: background 0.3s;
}

form button:hover {
    background: #4821b6;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 14px;
}

table th, table td {
    padding: 10px 8px;
    border: 1px solid #ddd;
    text-align: left;
}

table th {
    background-color: #f7f7f7;
    font-weight: 600;
}

table input[type="text"] {
    width: 100%;
    padding: 6px;
    font-size: 14px;
}

.btn {
    padding: 6px 14px;
    border: none;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    display: inline-block;
}

.btn-update {
    background-color: #1b0163;
    color: white;
    margin-right: 8px;
}

.btn-print {
    background-color: #1b0163;
    color: white;
    margin-right: 8px;
}

.btn-update:hover {
    background-color: #4722bd;
}

.btn-delete {
    background-color: #ff4d4f;
    color: white;
}

.btn-delete:hover {
    background-color: #d9363e;
}

form .flex-group {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

form .flex-group > div {
    flex: 1;
    min-width: 200px;
    margin-bottom: 15px; /* Add bottom margin to create space between dropdowns */
}

/* --- Select2 Dropdown Styles --- */

/* For the Select2 dropdown button (for both customer and product) */
.select2-container--default .select2-selection--single {
    height: 40px !important; /* Adjust height to match the input fields */
    padding: 8px 10px !important; /* Ensure padding is consistent */
    border-radius: 6px !important; /* Match border-radius of other input fields */
    font-size: 14px !important; /* Match font size of input fields */
    border: 1px solid #ccc !important; /* Same border as other inputs */
}



/* When the dropdown is active or selected */
.select2-container .select2-selection--single .select2-selection__rendered {
    line-height: 30px !important; /* Vertically align the text */
}

/* Style for the arrow icon inside the dropdown */
.select2-container .select2-selection--single .select2-selection__arrow {
    height: 30px !important; /* Match the height of the arrow */
    width: 20px !important; /* Adjust the width of the arrow */
}

/* Hover effect on the Select2 dropdown (same as input hover effect) */
.select2-container--default .select2-results__option--highlighted {
    background-color: #1b0163 !important; /* Highlight color */
    color: white !important; /* Text color when hovered */
}

/* Match focus state with other form inputs */
.select2-container--default .select2-selection--single:focus {
    border-color: #1b0163 !important; /* Highlight the focus border */
    box-shadow: 0 0 0 2px rgba(243, 156, 18, 0.2) !important; /* Add focus shadow */
}

/* Ensure consistency with other form elements */
input[type="text"], input[type="date"], input[type="number"], select {
    font-size: 14px;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid #ccc;
    width: 100%;
}

/* Date Picker */
input[type="date"] {
    padding: 10px;
    font-size: 14px;
}
