/* BBC Calendar Plugin Styles */
/* Scoped under .bbc-calendar-root to avoid conflicts with WP themes */

.bbc-calendar-root,
.bbc-calendar-root *,
.bbc-calendar-root *::before,
.bbc-calendar-root *::after {
    box-sizing: border-box;
}

.bbc-calendar-root {
    --bg-color: #1a1a1a;
    --calendar-bg: #fff;
    --text-main: #333;
    --border-color: #ddd;
    --gold: #d4af37;
    --dark-green: #144d32;
    --dark-red: #7a2e2e;
    --blue: #21426e;
    --bronze: #996e38;
    --orange: #d9994c;

    font-family: 'Montserrat', sans-serif;
    max-width: 100%;
    /* Changed from 1100px to allow flex down, will control wrapper instead */
    margin: 0 auto;
    padding: 20px 0;
}

.bbc-calendar-root .calendar-wrapper {
    max-width: 1100px;
    margin: 0 auto;
    background: #1e1e1e;
    padding: 12px;
    border-radius: 8px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(212, 175, 55, 0.4);
    position: relative;
}

.bbc-calendar-root .calendar-container {
    background-color: var(--calendar-bg);
    width: 100%;
    position: relative;
    border-radius: 4px;
    overflow: hidden;
}

.bbc-calendar-root .calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: #1e1e1e;
    color: white;
    position: relative;
    z-index: 2;
    border-bottom: 2px solid rgba(212, 175, 55, 0.6);
}

.bbc-calendar-root .logo-area {
    display: flex;
    align-items: center;
    margin: 0 !important;
    padding: 0 !important;
}

/* Filters */
.bbc-calendar-root .calendar-filters-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px 40px;
    background: #1a1a1a;
    border-bottom: 2px solid rgba(212, 175, 55, 0.6);
    flex-wrap: wrap;
}

.bbc-calendar-root .filter-label {
    font-weight: 700;
    font-size: 14px;
    color: #eee;
    margin-right: 5px;
}

.bbc-calendar-root .filter-btn {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    color: #ddd !important;
    padding: 6px 15px !important;
    border-radius: 20px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    cursor: pointer;
    transition: all 0.2s;
    margin: 0 !important;
    box-shadow: none !important;
    text-shadow: none !important;
}

.bbc-calendar-root .filter-btn:hover {
    border-color: var(--gold) !important;
    color: var(--gold) !important;
}

.bbc-calendar-root .filter-btn.active {
    background: var(--gold) !important;
    border-color: var(--gold) !important;
    color: #111 !important;
}

.bbc-calendar-root .main-logo {
    height: 85px;
    width: auto;
    object-fit: contain;
    margin: 0 !important;
    padding: 0 !important;
}

.bbc-calendar-root .month-selector {
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 8px 30px;
    border-radius: 4px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    background: transparent;
}

.bbc-calendar-root .month-selector:hover {
    background: rgba(212, 175, 55, 0.05);
    border: 1px solid rgba(212, 175, 55, 0.6);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.1);
}

.bbc-calendar-root .month-selector h1 {
    font-weight: 300;
    letter-spacing: 5px;
    margin: 0;
    font-size: 38px;
    color: var(--gold);
    text-transform: uppercase;
    text-shadow: none;
}

.bbc-calendar-root .dropdown-icon {
    color: var(--gold);
    font-size: 16px;
    opacity: 0.8;
}

.bbc-calendar-root .weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    background: #deb64c;
    text-align: center;
    text-transform: uppercase;
    font-weight: 700;
    color: #111;
    padding: 12px 0;
    border-bottom: 2px solid #000;
    font-size: 14px;
    letter-spacing: 1px;
}

.bbc-calendar-root .calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    /* Force equal flexible columns */
    grid-auto-rows: minmax(135px, auto);
    border-top: 1px solid #111;
    border-left: 1px solid #111;
    width: 100%;
    overflow: hidden;
}

.bbc-calendar-root .day {
    padding: 10px 12px;
    position: relative;
    cursor: pointer;
    background-color: #fff;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-right: 1px solid #222;
    border-bottom: 1px solid #222;
    transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    min-height: 135px;
    display: flex;
    flex-direction: column;
    opacity: 0;
    animation: bbcFadeInDay 0.6s ease-out forwards;
}

@keyframes bbcFadeInDay {
    0% {
        opacity: 0;
        transform: translateY(10px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.bbc-calendar-root .day:hover {
    z-index: 20;
    box-shadow: inset 0 0 0 3px var(--gold);
}

.bbc-calendar-root .day.empty {
    background-color: #f9f9f9;
    cursor: default;
}

.bbc-calendar-root .day.empty:hover {
    box-shadow: none;
    z-index: 1;
}

/* Removed redundant header layout that broke cell heights */

.bbc-calendar-root .day-number {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 26px;
    font-style: italic;
    font-weight: 700;
    align-self: flex-end;
    margin-bottom: 4px;
    z-index: 2;
    position: relative;
    color: #111;
    line-height: 1;
}

.bbc-calendar-root .day-content {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    line-height: 1.35;
    flex-grow: 1;
    word-break: normal;
    overflow-wrap: anywhere;
    -webkit-hyphens: auto;
    hyphens: auto;
    white-space: pre-wrap;
    z-index: 2;
    position: relative;
    font-weight: 500;
}

.bbc-calendar-root .day-title-display {
    font-weight: 800;
    font-size: 1.05em;
    margin-bottom: 3px;
    line-height: 1.2;
}

.bbc-calendar-root .day-text-display {
    font-weight: 500;
}

.bbc-calendar-root .day.has-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.7) 100%);
    z-index: 1;
}

.bbc-calendar-root .day.has-image .day-number,
.bbc-calendar-root .day.has-image .day-content {
    color: #fff !important;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.9);
}

/* Bottom Area (Quote & Photo) */
.bbc-calendar-root .bottom-area {
    display: flex;
    min-height: 180px;
    background: #111;
    color: #eee;
    cursor: pointer;
    transition: all 0.3s ease;
    border-top: 3px solid #000;
}

.bbc-calendar-root .bottom-area:hover {
    box-shadow: inset 0 0 25px rgba(212, 175, 55, 0.15);
}

.bbc-calendar-root .quote-section {
    flex: 6;
    padding: 30px 40px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid #000;
    background: #111;
}

.bbc-calendar-root .quote-mark {
    position: absolute;
    top: -15px;
    left: 20px;
    font-family: 'Playfair Display', serif;
    font-size: 140px;
    color: rgba(212, 175, 55, 0.15);
    line-height: 1;
}

.bbc-calendar-root .quote-content {
    position: relative;
    z-index: 2;
    padding-left: 20px;
}

.bbc-calendar-root .quote-text {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 24px;
    font-style: italic;
    font-weight: 700;
    line-height: 1.4;
    color: #fff;
    margin-bottom: 20px;
    letter-spacing: 0.5px;
}

.bbc-calendar-root .quote-author {
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 3px;
    text-align: right;
    font-weight: 500;
    opacity: 0.9;
}

.bbc-calendar-root .photo-section {
    flex: 4;
    background-color: #1a1a1a;
    background-size: cover;
    background-position: center;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.bbc-calendar-root .photo-placeholder {
    color: #888;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-align: center;
    padding: 20px;
    font-weight: 500;
}

.bbc-calendar-root .photo-section.has-image .photo-placeholder {
    display: none;
}

/* Modal Styling */
.bbc-modal {
    display: none;
    position: fixed;
    z-index: 100000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.bbc-modal.show {
    display: flex;
    opacity: 1;
}

.bbc-modal-content {
    background-color: #fff;
    padding: 30px 40px;
    border-radius: 12px;
    width: 450px;
    max-width: 90%;
    position: relative;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    border-top: 5px solid var(--gold);
}

.bbc-calendar-root .bbc-modal {
    padding: 24px 12px;
    overflow-y: auto;
    align-items: flex-start;
}

.bbc-calendar-root .bbc-modal-content {
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.bbc-calendar-root .bbc-modal-content .modal-actions {
    position: sticky;
    bottom: -30px;
    z-index: 5;
    margin-left: -40px;
    margin-right: -40px;
    margin-bottom: -30px;
    padding: 16px 40px 30px;
    background: linear-gradient(to bottom, rgba(255,255,255,0.9), #fff 24px);
    border-top: 1px solid rgba(0,0,0,0.06);
}

.bbc-modal.show .bbc-modal-content {
    transform: translateY(0);
}

.bbc-calendar-root .close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    cursor: pointer;
    color: #999;
    transition: color 0.2s;
    background: none;
    border: none;
}

.bbc-calendar-root .close-btn:hover {
    color: #111;
}

.bbc-modal-content h3 {
    margin-top: 0;
    margin-bottom: 25px;
    color: #111;
    font-weight: 600;
    font-size: 22px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

/* Modal Forms */
.bbc-calendar-root .form-group {
    margin-bottom: 20px;
}

.bbc-calendar-root .form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #444;
    font-size: 14px;
}

.bbc-calendar-root .form-group input[type="text"],
.bbc-calendar-root .form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
    font-size: 14px;
    transition: border-color 0.2s;
}

.bbc-calendar-root .form-group input[type="text"]:focus,
.bbc-calendar-root .form-group textarea:focus {
    outline: none;
    border-color: var(--gold);
}

.bbc-calendar-root .form-group textarea {
    resize: vertical;
}

/* Swatches */
.bbc-calendar-root .preset-colors {
    display: flex;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.bbc-calendar-root .color-swatch {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.bbc-calendar-root .color-swatch:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.bbc-calendar-root .color-swatch.active {
    border-color: #333;
    transform: scale(1.1);
}

.bbc-calendar-root .text-color-swatch.active {
    border-color: var(--gold) !important;
    border-width: 3px !important;
}

.bbc-calendar-root .color-picker-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bbc-calendar-root input[type="color"] {
    -webkit-appearance: none;
    appearance: none;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 6px;
    cursor: pointer;
    padding: 0;
    background: none;
}

.bbc-calendar-root input[type="color"]::-webkit-color-swatch-wrapper {
    padding: 0;
}

.bbc-calendar-root input[type="color"]::-webkit-color-swatch {
    border: 1px solid #ccc;
    border-radius: 6px;
}

/* Modal Actions */
.bbc-calendar-root .modal-actions {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.bbc-calendar-root .btn-primary,
.bbc-calendar-root .btn-danger {
    padding: 12px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    font-family: 'Montserrat', sans-serif;
    font-size: 15px;
    flex: 1;
    transition: all 0.2s;
}

.bbc-calendar-root .btn-primary {
    background-color: var(--gold);
    color: #111;
}

.bbc-calendar-root .btn-primary:hover {
    background-color: #c09e32;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(212, 175, 55, 0.4);
}

.bbc-calendar-root .btn-danger {
    background-color: #f1f1f1;
    color: #d32f2f;
    border: 1px solid #ddd;
}

.bbc-calendar-root .btn-danger:hover {
    background-color: #ffebee;
    border-color: #ffcdd2;
    transform: translateY(-2px);
}

/* Month Picker */
.bbc-calendar-root .month-picker-content {
    width: 420px;
}

.bbc-calendar-root .year-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    font-size: 30px;
    font-weight: 600;
    color: #111;
}

.bbc-calendar-root .nav-btn {
    background: transparent;
    border: 1px solid #ccc;
    color: #333;
    font-size: 20px;
    cursor: pointer;
    width: 44px;
    height: 44px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.bbc-calendar-root .nav-btn:hover {
    background: var(--gold);
    color: #fff;
    border-color: var(--gold);
    transform: scale(1.05);
}

.bbc-calendar-root .months-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.bbc-calendar-root .month-btn {
    background: #fdfdfd;
    border: 1px solid #e0e0e0;
    padding: 15px 5px;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 13px;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #444;
}

.bbc-calendar-root .month-btn:hover {
    background: #f6eed1;
    color: #111;
    border-color: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.bbc-calendar-root .month-btn.active {
    background: var(--gold);
    color: #111;
    border-color: var(--gold);
    box-shadow: inset 0 0 0 2px #fff;
}

/* Admin-only / Visitor visual cue */
.bbc-calendar-root.is-visitor .day {
    cursor: default;
    pointer-events: none !important;
}

.bbc-calendar-root.is-visitor .day:hover {
    box-shadow: none;
}

.bbc-calendar-root.is-visitor .day.has-link {
    cursor: pointer !important;
    pointer-events: auto !important;
    touch-action: manipulation;
    position: relative;
    z-index: 50;
}

.bbc-calendar-root.is-visitor .day.has-link:hover {
    box-shadow: inset 0 0 0 3px var(--gold);
}

.bbc-calendar-root.is-visitor .bottom-area {
    cursor: default;
}

.bbc-calendar-root.is-visitor .bottom-area:hover {
    box-shadow: none;
}

.bbc-calendar-root.is-visitor .month-selector {
    cursor: pointer;
}

/* month selection still allowed */

/* ===== RESPONSIVENESS ===== */
@media (max-width: 900px) {
    .bbc-calendar-root {
        padding: 10px 5px;
    }

    .bbc-calendar-root .calendar-wrapper {
        padding: 8px;
    }

    .bbc-calendar-root .calendar-header {
        flex-direction: column;
        gap: 15px;
        padding: 15px 10px;
    }

    .bbc-calendar-root .month-selector {
        padding: 8px 15px;
    }

    .bbc-calendar-root .month-selector h1 {
        font-size: 28px;
    }

    .bbc-calendar-root .calendar-grid {
        grid-auto-rows: minmax(100px, auto);
    }

    .bbc-calendar-root .day-number {
        font-size: 22px;
    }

    .bbc-calendar-root .day-content {
        font-size: 13px;
    }
}

@media (max-width: 768px) {
    .bbc-calendar-root .bottom-area {
        flex-direction: column;
    }

    .bbc-calendar-root .quote-section {
        border-right: none;
        border-bottom: 1px solid #000;
        padding: 30px 20px;
        text-align: center;
    }

    .bbc-calendar-root .quote-text {
        font-size: 20px;
    }

    .bbc-calendar-root .photo-section {
        min-height: 200px;
    }

    .bbc-calendar-root .quote-mark {
        left: 5px;
        font-size: 100px;
    }

    .bbc-calendar-root .weekdays {
        font-size: 12px;
        padding: 8px 0;
    }

    .bbc-calendar-root .calendar-grid {
        grid-auto-rows: minmax(80px, auto);
    }

    .bbc-calendar-root .day {
        padding: 6px 8px;
    }

    .bbc-calendar-root .day-number {
        font-size: 18px;
    }

    .bbc-calendar-root .day-content {
        font-size: 11px;
    }

    .bbc-modal-content {
        padding: 20px;
    }

    .bbc-calendar-root .bbc-modal {
        padding: 12px 8px;
    }

    .bbc-calendar-root .bbc-modal-content {
        max-height: calc(100vh - 24px);
    }

    .bbc-calendar-root .bbc-modal-content .modal-actions {
        bottom: -20px;
        margin-left: -20px;
        margin-right: -20px;
        margin-bottom: -20px;
        padding: 14px 20px 22px;
    }

    .bbc-calendar-root .months-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }

    .bbc-calendar-root .month-btn {
        padding: 10px 5px;
        font-size: 11px;
    }

    .bbc-calendar-root .main-logo {
        height: 60px;
    }

    /* Hide status icons on mobile to save space */
    .bbc-calendar-root .day-members-indicator,
    .bbc-calendar-root .day-recur-indicator,
    .bbc-calendar-root .day-group-indicator,
    .bbc-calendar-root .day-events-nav,
    .bbc-calendar-root .calendar-legend {
        display: none !important;
    }

    .bbc-calendar-root .event-dot {
        width: 15px;
        height: 15px;
        font-size: 10px;
        border: 1px solid rgba(255,255,255,0.4);
    }
}

@media (max-width: 480px) {
    .bbc-calendar-root {
        padding: 5px;
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }

    .bbc-calendar-root .calendar-wrapper {
        padding: 4px;
        border-radius: 4px;
        width: 100%;
    }

    .bbc-calendar-root .months-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .bbc-calendar-root .calendar-grid {
        grid-auto-rows: minmax(50px, auto);
        width: 100%;
    }

    .bbc-calendar-root .day-content {
        font-size: 8px;
        /* Even smaller for very narrow screens */
        line-height: 1.1;
        margin-top: 1px;
        word-break: normal;
        overflow-wrap: anywhere;
        -webkit-hyphens: auto;
        hyphens: auto;
    }

    .bbc-calendar-root .day.has-image::before {
        background: linear-gradient(to bottom, rgba(0, 0, 0, 0.4) 0%, rgba(0, 0, 0, 0.4) 100%);
    }

    .bbc-calendar-root .month-picker-content {
        width: 95vw;
        padding: 15px;
    }

    .bbc-calendar-root .day {
        padding: 2px 1px;
        /* Minimal padding for very tight screens */
        min-height: 50px;
        width: 100%;
    }

    .bbc-calendar-root .day-header-top {
        top: 2px;
        left: 2px;
        right: 2px;
    }
    
    .bbc-calendar-root .event-dot {
        width: 14px;
        height: 14px;
        font-size: 9px;
        border: 1px solid rgba(255,255,255,0.4);
    }
    
    .bbc-calendar-root .day-members-indicator,
    .bbc-calendar-root .day-recur-indicator,
    .bbc-calendar-root .day-group-indicator,
    .bbc-calendar-root .day-events-nav {
        display: none !important;
    }

    .bbc-calendar-root .day-number {
        font-size: 11px;
        margin-bottom: 2px;
    }

    .bbc-calendar-root .weekdays {
        font-size: 8px;
        padding: 4px 0;
        letter-spacing: 0;
    }

    .bbc-calendar-root .quote-text {
        font-size: 16px;
    }

    .bbc-calendar-root .main-logo {
        height: 50px;
    }

    .bbc-calendar-root .month-selector h1 {
        font-size: 20px;
        letter-spacing: 2px;
    }
}

/* ===== NEW STYLES (Multi-event, Legend, Visitor Modal) ===== */

/* Admin Navigation */
.bbc-calendar-root .admin-event-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f7f7f7;
    padding: 10px;
    border-radius: 6px;
    margin-bottom: 20px;
    border: 1px solid #ddd;
}
.bbc-calendar-root .nav-btn.small {
    width: 30px;
    height: 30px;
    font-size: 16px;
}

/* Legend */
.bbc-calendar-root .calendar-legend {
    background: #111;
    color: #eee;
    padding: 15px 40px;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    border-top: 1px solid #333;
}
.bbc-calendar-root .legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}
.bbc-calendar-root .legend-icon {
    font-size: 16px;
}

/* Day cell indicators */
.bbc-calendar-root .day-header-top {
    position: absolute;
    top: 5px;
    left: 5px;
    right: 5px;
    display: flex;
    justify-content: space-between;
    z-index: 3;
}
.bbc-calendar-root .day-members-indicator,
.bbc-calendar-root .day-recur-indicator,
.bbc-calendar-root .day-group-indicator {
    font-size: 14px;
    color: #fdfdfd;
    background: rgba(0,0,0,0.6);
    border-radius: 4px;
    padding: 2px 5px;
    display: flex;
    justify-content: center;
    align-items: center;
}
.bbc-calendar-root .day-events-nav {
    display: flex;
    gap: 4px;
    position: absolute;
    bottom: 5px;
    right: 5px;
    z-index: 10;
}
.bbc-calendar-root .event-dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #444;
    color: #fff;
    font-size: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
    transition: all 0.2s;
    pointer-events: auto;
    border: 1px solid rgba(255,255,255,0.4);
}
.bbc-calendar-root .event-dot:hover {
    background: #fff;
    transform: scale(1.1);
}
.bbc-calendar-root .event-dot.active {
    background: var(--gold);
    color: #111;
    border: 2px solid #fff;
}

/* Visitor Modal */
.bbc-calendar-root .visitor-content {
    border-top: 5px solid var(--gold);
}
.bbc-calendar-root .visitor-event-header {
    margin-bottom: 5px;
}
.bbc-calendar-root .members-badge {
    display: inline-block;
    background: #144d32;
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 15px;
}
.bbc-calendar-root .btn-secondary {
    background: transparent;
    border: 2px solid var(--gold);
    color: #111;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    flex: 1;
    transition: all 0.2s;
}
.bbc-calendar-root .calendar-header .btn-secondary {
    color: #fff;
}
.bbc-calendar-root .btn-secondary:hover {
    background: rgba(212, 175, 55, 0.2);
}
.bbc-calendar-root .modal-actions.visitor-actions {
    flex-wrap: wrap;
}

/* Recurring Events */
.bbc-calendar-root.is-visitor .admin-only-btn {
    display: none !important;
}
.bbc-calendar-root .recurring-rule-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.bbc-calendar-root .recurring-rule-item:last-child {
    border-bottom: none;
}
.bbc-calendar-root .btn-danger.small {
    padding: 4px 8px;
    font-size: 12px;
}

/* Keep multi-event selectors visible in narrow layouts and beside the side menu. */
.bbc-calendar-root .day-events-nav {
    display: flex !important;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: nowrap;
    gap: 4px;
    position: absolute;
    right: 5px;
    bottom: 5px;
    z-index: 30;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

.bbc-calendar-root .day-events-nav:empty {
    display: none !important;
}

.bbc-calendar-root .day-events-nav .event-dot {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 22px;
    min-width: 22px;
    height: 22px;
    min-height: 22px;
    padding: 0;
    margin: 0;
    border-radius: 999px;
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    text-indent: 0;
    white-space: nowrap;
    pointer-events: auto !important;
}

.bbc-calendar-root .day-events-nav .event-dot.active {
    color: #111;
}

@media (max-width: 900px) {
    .bbc-calendar-root .day-events-nav {
        right: 4px;
        bottom: 4px;
        gap: 3px;
    }

    .bbc-calendar-root .day-events-nav .event-dot {
        width: 18px;
        min-width: 18px;
        height: 18px;
        min-height: 18px;
        font-size: 10px;
    }
}

@media (max-width: 480px) {
    .bbc-calendar-root .day-events-nav {
        right: 2px;
        bottom: 2px;
        gap: 2px;
    }

    .bbc-calendar-root .day-events-nav .event-dot {
        width: 14px;
        min-width: 14px;
        height: 14px;
        min-height: 14px;
        font-size: 9px;
        border-width: 1px;
    }
}
