/* Layout */

.fg-booking-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.fg-calendar-container {
    flex: 1 1 300px;
}

.fg-booking-panel {
    flex: 0 0 300px;
    max-width: 360px;
    border: 1px solid #eee;
    padding: 1rem;
    border-radius: 6px;
    background: #fafafa;
}

/* Month & calendar */

.fg-month {
    margin-bottom: 1.5rem;
}

.fg-calendar {
    width: 100%;
    border-collapse: collapse;
    text-align: center;
    font-size: 0.9rem;
}

.fg-calendar th,
.fg-calendar td {
    border: 1px solid #eee;
    padding: 0.4rem;
}

.fg-other-month {
    color: #ccc;
}

.fg-date-cell.fg-week-start {
    cursor: pointer;
}

/* Status colours */

.fg-status-available {
    background: #e6ffe6; /* light green */
}

.fg-status-booked {
    background: #ffd6d6; /* light red */
}

.fg-status-blocked {
    background: #e0e0e0; /* grey */
}

/* Selected weeks: highlight whole row */

.fg-selected-week {
    background: #cde8ff !important;
    position: relative;
}

.fg-selected-week::after {
    content: '';
    position: absolute;
    inset: 0;
    border: 2px solid #1976d2;
    pointer-events: none;
}

/* Legend */

.fg-calendar-legend {
    margin-top: 0.5rem;
    font-size: 0.9rem;
}

.fg-legend-box {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin-right: 4px;
    margin-left: 12px;
    vertical-align: middle;
    border-radius: 2px;
}

.fg-legend-available {
    background: #4caf50;
}

.fg-legend-booked {
    background: #f44336;
}

.fg-legend-blocked {
    background: #9e9e9e;
}

/* Booking form */

.fg-booking-summary p {
    margin: 0.2rem 0;
}

.fg-booking-form p {
    margin-bottom: 0.7rem;
}

.fg-booking-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.2rem;
}

.fg-booking-form input,
.fg-booking-form textarea {
    width: 100%;
    box-sizing: border-box;
}

.fg-booking-message {
    margin-top: 0.6rem;
    font-weight: 600;
    color: #333;
}

/* Toast container */
.fg-toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Toast style */
.fg-toast {
    background: #333;
    color: #fff;
    padding: 14px 18px;
    border-radius: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    font-size: 15px;
    opacity: 0;
    transform: translateY(20px);
    animation: fg-toast-in 0.35s ease forwards;
}

/* Toast exit */
.fg-toast.hide {
    animation: fg-toast-out 0.35s ease forwards;
}

/* Animations */
@keyframes fg-toast-in {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fg-toast-out {
    from { opacity: 1; transform: translateY(0); }
    to   { opacity: 0; transform: translateY(20px); }
}



/* =========================================
   ADMIN BOOKING PAGE OVERRIDES
========================================= */

.wp-admin .fg-admin-booking {
    background: #f6f7f7;
    padding: 20px;
}

.wp-admin .fg-admin-booking .fg-month h4 {
    font-size: 16px;
    margin-bottom: 10px;
}

.wp-admin .fg-admin-booking .fg-calendar {
    background: #fff;
    border-collapse: collapse;
}

.wp-admin .fg-admin-booking .fg-calendar th {
    background: #f1f5f9;
    font-weight: 600;
    padding: 8px;
}

.wp-admin .fg-admin-booking .fg-calendar td {
    height: 70px;
    padding: 6px;
    font-size: 13px;
}

.wp-admin .fg-admin-booking .fg-booking-panel {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 1px 4px rgba(0,0,0,.08);
}

.wp-admin .fg-admin-booking label {
    font-weight: 600;
}

.wp-admin .fg-admin-booking input,
.wp-admin .fg-admin-booking textarea {
    width: 100%;
    max-width: 100%;
}

.wp-admin .fg-admin-booking .fg-booking-wrapper {
    grid-template-columns: 1.2fr 1fr;
}


@media (max-width: 1200px) {
    .wp-admin .fg-admin-booking .fg-booking-wrapper {
        grid-template-columns: 1fr;
    }
}



/* Mobile */

@media (max-width: 768px) {
    .fg-booking-wrapper {
        flex-direction: column;
    }
}
