/* Basic Styles */
body {
    font-family: 'Roboto', sans-serif;
    background-color: #f8f9fa;
    margin: 0;
    padding: 0;
}

h1 {
    font-weight: 700;
    color: #007bff;
    margin: 0;
    padding: 0;
}

#header-calendar-container {
    margin-right: 15px;
}

#header-calendar {
    font-weight: 500;
    padding: 10px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    width: 200px;
}

#calendar {
    width: 100%;
    margin: 20px auto;
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

/* Additional styles for Pikaday container */
#pikaday-container {
    display: inline-block;
    margin-right: 20px;
    margin-left: 60px; /* 5 cm to the right */
}

/* Ensuring that headers and times are centered */
.fc .fc-timegrid-slot-label-cushion, .fc .fc-timegrid-axis-cushion {
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Adjusting slot height for better visibility */
.fc .fc-timegrid-slot {
    height: 30px;
}

/* Centering text in header cells for better readability */
.fc c-timeline-slot.fc-col-header-cell {
    text-align: center;
}

/* Adjusting the resource area width */
.fc .fc-resource-area {
    width: 100px;
}

/* Styling the current time indicator */
.fc .fc-now-indicator {
    background-color: red;
}

/* Adding margin and padding between buttons */
.fc-button-group .fc-button {
    margin-right: 5px;
    padding: 5px 10px;
}

/* Tooltip styling */
.tooltip-inner {
    max-width: none;
    white-space: nowrap;
}

/* Styles for event dot and recurring event icon */
.fc-event-dot {
    position: absolute;
    top: 50%;
    left: -7px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: red; /* Võid muuta värvi vastavalt oma soovile */
    transform: translateY(-50%);
    z-index: 1;
}

.fc-recurring-event .fc-event-title::before {
    content: '🔄'; /* Ringikese või kordumise sümbol */
    margin-right: 5px;
}

/* Bold vertical lines for every 34th slot (each 17 hours) */
.fc-timeline-body .fc-timeline-slots td:nth-child(68n+1) {
    border-left: 2px solid black;
}


/* Ensure events are displayed above the background color */
.fc-timeline-event {
    position: relative;
    z-index: 1;
}

/* To ensure the first slot of each day retains horizontal lines */
.fc-timeline-body table tr td:nth-child(48n+1) {
    position: relative;
}

/* Styles for active and inactive buttons */
.fc-button-group .fc-button.fc-button-active {
    background-color: #007bff; /* Bootstrap blue */
    border-color: #007bff;
    color: white;
}

.fc-button-group .fc-button {
    background-color: #6c757d; /* Bootstrap grey */
    border-color: #6c757d;
    color: white;
}

.fc-button-group .fc-button:hover {
    background-color: #5a6268; /* Darker grey on hover */
    border-color: #545b62;
}

/* Ensure event height fills the cell */
.fc-timeline-event .fc-event-main-frame {
    height: 100%;
    display: flex;
    align-items: center;
}

/* Modal adjustments */
.modal-dialog {
    max-width: 35%;
}

.modal-content {
    padding: 10px;
}

/* Mobile Responsiveness */
@media (max-width: 767px) {
    h1 {
        font-size: 24px;
    }

    #header-calendar-container {
        margin-right: 0;
    }

    #header-calendar {
        width: 100%;
        margin-top: 10px;
    }

    #calendar {
        padding: 10px;
    }

    .modal-dialog {
        max-width: 20%;
    }
}

/* Ensure event text is black for all events */
.fc-event, .fc-event-dot, .fc-timeline-event .fc-event-main-frame {
    color: black !important;
}

/* Specifically target the yellow background for better readability */
.fc-event[style*="background-color: #FFD700"], 
.fc-event-dot[style*="background-color: #FFD700"], 
.fc-timeline-event .fc-event-main-frame[style*="background-color: #FFD700"] {
    color: black !important;
}

/* Darken the selected area in FullCalendar */
.fc .fc-highlight {
    background-color: rgba(0, 123, 255, 0.5); /* Darker blue */
}

/* Ensuring Pikaday is behind the modal */
#pikaday-container .pika-single {
    z-index: 1040;
}


/* Additional Mobile Adjustments */
@media (max-width: 576px) {
    .fc-header-toolbar {
        flex-wrap: wrap;
        justify-content: center;
    }

    .fc-button-group {
        display: flex;
        justify-content: center;
    }

    .fc-button-group .fc-button {
        margin: 2px;
        padding: 5px;
        font-size: 12px;
    }

    #pikaday-container {
        display: none;
    }

    #header-calendar-container {
        display: block;
    }
}



