body {
    font-family: sans-serif;
    margin: 20px;
}

h1,
h2 {
    text-align: center;
}

.navigation {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

#calendar-container {
    overflow-x: auto;
    overflow-y: hidden;
    max-width: 100%;
    border: 1px solid #ccc;
}

.calendar-grid {
    display: grid;
}

.calendar-header,
.calendar-day,
.house-name {
    padding: 10px;
    border-right: 1px solid #ccc;
    border-bottom: 1px solid #ccc;
    text-align: center;
}

.house-name {
    position: sticky;
    left: 0;
    background-color: #f2f2f2;
    font-weight: bold;
    z-index: 1;
    border-right: 2px solid #000;
}

.calendar-header {
    background-color: #f2f2f2;
    font-weight: bold;
    position: sticky;
    top: 0;
}

.calendar-day {
    min-height: 40px;
    position: relative;
}

.calendar-day .bookings {
    list-style: none;
    padding: 0;
    margin: 0;
    font-size: 0.9em;
    text-align: left;
}

.calendar-day .bookings li {
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.booking-form,
.form-column {
    max-width: 100%;
    /* margin: 30px auto; */
    /* padding: 15px; */
    /* border: 1px solid #ccc; */
    /* border-radius: 5px; */
}

.booking-form label,
.form-column label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.booking-form input,
.booking-form select,
.booking-form textarea,
.booking-form button,
.form-column input,
.form-column select,
.form-column textarea,
.form-column button {
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    box-sizing: border-box;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.form-column button {
    background-color: #333;
    color: white;
    cursor: pointer;
    border: none;
}

.form-column button:hover {
    background-color: #555;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 10;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 500px;
    border-radius: 5px;
}

.close-button {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.info-icon,
.edit-icon,
.delete-icon {
    cursor: pointer;
    font-size: 0.8em;
    margin-left: 5px;
    color: #007bff;
}

.delete-icon {
    color: #dc3545;
}

.bookings-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: grid;
    pointer-events: none;
    /* Allow clicks to pass through to the grid */
    display: grid;
    grid-auto-rows: 60px;
    margin-top: 40px;
}

.booking {
    background-color: #3577d1;
    pointer-events: auto;
    /* Re-enable pointer events for bookings */
    color: white;
    padding: 5px;
    border-radius: 5px;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    z-index: 5;
    height: 30px;
    line-height: 20px;
    border: 1px solid #0056b3;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
    position: relative;
    top: 50%;
    transform: translateY(-50%);


}

.month-container {
    border: 1px solid #ddd;
    padding: 10px;
    background: #fff;
}

.month-title {
    text-align: center;
    font-weight: bold;
    margin-bottom: 10px;
}

.month-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}

.day-cell {
    text-align: center;
    padding: 5px;
    font-size: 0.9em;
    background-color: #f0f0f0;
}

.day-header {
    font-weight: bold;
    background-color: #e0e0e0;
}

.day-cell.free {
    background-color: #b8e6b8;
    /* Light green */
}

.day-cell.full {
    background-color: #ff9999;
    /* Light red */
}

.day-cell.empty {
    background-color: transparent;
}

/* Navbar Styles */
.navbar {
    background-color: #333;
    overflow: hidden;
    margin-bottom: 20px;
    border-radius: 4px;
}

.navbar a {
    float: left;
    display: block;
    color: #f2f2f2;
    text-align: center;
    padding: 14px 16px;
    text-decoration: none;
}

.navbar a:hover {
    background-color: #ddd;
    color: black;
}

.booking.offer {
    background-color: #28a745;
    /* Green */
    border-color: #1e7e34;
}

.booking.reserved {
    background-color: orange;
    border-color: darkorange;
}

.booking.unpaid {
    border: 2px solid orange !important;
}

.calendar-header.weekend,
.calendar-day.weekend {
    background-color: #d4edda;
}

.calendar-header.today-column,
.calendar-day.today-column {
    border-left: 2px solid red;
    border-right: 2px solid red;
}

.calendar-header.today-column {
    border-top: 2px solid red;
}

/* Availability Calendar Overview Styles */
.year-calendar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 10px;
    padding: 0;
}

.forms-container {
    display: flex;
    gap: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.form-column {
    flex: 1;
    min-width: 300px;
    background: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.form-column h2 {
    margin-top: 0;
}