/* Campaign Calendar Modal Styles */

/* Modal Overlay */
.calendar-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 99998;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-modal-overlay.hidden {
    display: none;
}

/* Modal Container */
.calendar-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: #2b2d42;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    z-index: 99999;
    max-width: 1200px;
    width: 95vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.calendar-modal.hidden {
    display: none;
}

/* Modal Header */
.calendar-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 32px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.calendar-header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.calendar-modal-title {
    margin: 0;
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: -0.5px;
}

.calendar-close-btn {
    background: none;
    border: none;
    font-size: 32px;
    color: #8b8b8b;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s ease, transform 0.2s ease;
}

.calendar-close-btn:hover {
    color: #ffffff;
    transform: scale(1.1);
}

/* Modal Body */
.calendar-modal-body {
    display: flex;
    gap: 20px;
    padding: 16px 28px 20px;
    overflow: hidden;
    flex: 1;
}

/* Main Calendar Section */
.calendar-main-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Calendar Scope Toggle (Current Artist vs All Artists) - now in header */
.calendar-scope-toggle {
    display: flex;
    gap: 6px;
}

.scope-toggle-btn {
    padding: 6px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.05);
    color: rgba(255, 255, 255, 0.6);
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.scope-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
}

.scope-toggle-btn.active {
    background: linear-gradient(135deg, #8b7ff5 0%, #6366f1 100%);
    border-color: transparent;
    color: #ffffff !important;
}

/* Month Navigation - with legend inline */
.month-navigation {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.month-nav-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

.month-nav-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #ffffff;
    font-size: 20px;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.month-nav-btn:hover {
    background: rgba(139, 127, 245, 0.2);
    border-color: #8b7ff5;
    transform: scale(1.05);
}

.current-month-label {
    font-size: 20px;
    font-weight: 600;
    color: #ffffff;
    min-width: 180px;
    text-align: center;
    margin: 0;
}

/* Calendar Grid */
.calendar-grid-wrapper {
    flex: 1;
    overflow-y: auto;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 2px;
}

/* Weekday Headers */
.calendar-weekday {
    background: rgba(255, 255, 255, 0.03);
    padding: 8px 6px;
    text-align: center;
    font-size: 11px;
    font-weight: 600;
    color: #8b8b8b;
    letter-spacing: 0.5px;
}

/* Calendar Days */
.calendar-day {
    background: #1e1f2e;
    min-height: 80px;
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    position: relative;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.calendar-day.empty {
    background: rgba(255, 255, 255, 0.02);
    opacity: 0.3;
}

.calendar-day.today {
    background: rgba(139, 127, 245, 0.15);
    border: 2px solid #8b7ff5;
}

.calendar-day.has-events {
    background: #252736;
}

.calendar-day:hover:not(.empty) {
    background: #2d2f3f;
}

.calendar-day-number {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    line-height: 1;
}

.calendar-day.today .calendar-day-number {
    color: #8b7ff5;
}

.calendar-day-events {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

/* Campaign Event Pills */
.calendar-event-pill {
    background: #10b981;
    color: #ffffff;
    font-size: 11px;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s ease;
}

.calendar-event-pill:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.calendar-event-pill.live {
    background: #10b981;
}

.calendar-event-pill.live.start {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    font-weight: 600;
}

.calendar-event-pill.review {
    background: #8b7ff5;
}

.calendar-event-pill.queued {
    background: #f59e0b;
}

.calendar-event-pill.more {
    background: rgba(255, 255, 255, 0.1);
    color: #8b8b8b;
    text-align: center;
    font-size: 10px;
}

/* Calendar Legend - now inline with month nav */
.calendar-legend {
    display: flex;
    gap: 16px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 3px;
}

.legend-dot.live {
    background: #10b981;
}

.legend-dot.review {
    background: #8b7ff5;
}

.legend-dot.queued {
    background: #f59e0b;
}

.legend-label {
    font-size: 11px;
    font-weight: 500;
    color: #ffffff;
}

/* Timeline Sidebar */
.timeline-sidebar {
    width: 320px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.timeline-header {
    display: flex;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.timeline-title {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
}

/* Timeline Scroll Container */
.timeline-scroll-container {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
}

.timeline-scroll-container::-webkit-scrollbar {
    width: 6px;
}

.timeline-scroll-container::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 3px;
}

.timeline-scroll-container::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.timeline-scroll-container::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Timeline List */
.timeline-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Timeline Items */
.timeline-item {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 12px;
    border-left: 3px solid transparent;
    transition: all 0.2s ease;
}

.timeline-item:hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(4px);
}

/* Launch Date Inline Section */
.launch-date-inline {
    margin-top: 10px;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.ideal-launch-label {
    font-size: 10px;
    font-weight: 600;
    color: #8b7ff5;
    letter-spacing: 0.3px;
}

.ideal-launch-date-picker {
    width: auto;
}

/* Override default DatePickerSingle styles - compact inline */
.ideal-launch-date-picker .DateInput {
    width: 70px;
}

.ideal-launch-date-picker .DateInput_input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: #ffffff;
    font-size: 10px;
    padding: 4px 6px;
    line-height: 1.2;
    font-weight: 500;
    width: 70px;
}

.ideal-launch-date-picker .DateInput_input::placeholder {
    color: #666;
    font-size: 10px;
}

.ideal-launch-date-picker .DateInput_input:focus {
    outline: none;
    border-color: #8b7ff5;
    box-shadow: 0 0 0 2px rgba(139, 127, 245, 0.2);
}

.ideal-launch-date-picker .DateInput_fang {
    display: none;
}

.ideal-launch-date-picker .SingleDatePickerInput {
    background: transparent;
    border: none;
    padding-right: 0px;
}

.ideal-launch-date-picker .SingleDatePickerInput_calendarIcon {
    display: none;
}

/* Scheduled Launch - inline */
.scheduled-launch-label {
    font-size: 10px;
    font-weight: 600;
    color: #8b8b8b;
    letter-spacing: 0.3px;
    margin-left: 8px;
}

.scheduled-launch-value {
    font-size: 10px;
    font-weight: 600;
    color: #f59e0b;
}

.scheduled-launch-value.estimated {
    font-style: italic;
}

.timeline-date {
    font-size: 11px;
    font-weight: 600;
    color: #8b8b8b;
    margin-bottom: 6px;
    letter-spacing: 0.3px;
}

.timeline-campaign-name {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 6px;
    overflow: hidden;
}

.timeline-campaign-name-text {
    font-size: 14px;
    font-weight: 600;
    color: #ffffffe0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.timeline-artist-badge {
    font-size: 10px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    background: rgba(139, 127, 245, 0.2);
    color: #a5b4fc;
    white-space: nowrap;
    flex-shrink: 0;
}

.timeline-info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px;
}

.timeline-status-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    letter-spacing: 0.3px;
}

.timeline-status-badge.live {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.timeline-status-badge.review {
    background: rgba(139, 127, 245, 0.2);
    color: #8b7ff5;
}

.timeline-status-badge.queued {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.timeline-meta {
    font-size: 11px;
    color: #8b8b8b;
}

/* Timeline Stats Row */
.timeline-stats {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.timeline-duration {
    font-weight: 500;
}

.timeline-progress-text {
    color: rgba(255, 255, 255, 0.5);
}

/* Progress Bar for Live Campaigns */
.timeline-progress-bar {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    margin-top: 8px;
    overflow: hidden;
}

.timeline-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981 0%, #059669 100%);
    border-radius: 2px;
    transition: width 0.3s ease;
}

/* Timeline Item Status Border */
.timeline-item.live {
    border-left-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.timeline-item.queued {
    border-left-color: #f59e0b;
}

.timeline-item.review {
    border-left-color: #8b7ff5;
}

/* Queued Campaign Pill Start State */
.calendar-event-pill.queued.start {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    font-weight: 600;
}

/* Empty Timeline State */
.timeline-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
    height: 100%;
}

.timeline-empty-text {
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    margin-bottom: 8px;
}

.timeline-empty-subtext {
    font-size: 13px;
    color: #8b8b8b;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .calendar-modal-body {
        flex-direction: column;
    }

    .timeline-sidebar {
        width: 100%;
        max-height: 200px;
    }

    .calendar-day {
        min-height: 80px;
    }
}

@media (max-width: 768px) {
    .calendar-modal {
        width: 100vw;
        max-width: 100vw;
        height: 100vh;
        max-height: 100vh;
        border-radius: 0;
    }

    .calendar-modal-header {
        padding: 16px 20px;
    }

    .calendar-modal-title {
        font-size: 22px;
    }

    .calendar-grid {
        gap: 1px;
    }

    .calendar-day {
        min-height: 60px;
        padding: 4px;
    }

    .calendar-day-number {
        font-size: 12px;
    }

    .calendar-event-pill {
        font-size: 9px;
        padding: 3px 6px;
    }
}

.SingleDatePicker_picker__portal {
    z-index: 999999 !important;
}