/**
 * SBNews Calendar Styles
 */

/* Container */
.sbnews-calendar-container {
    background: #1a1a1a;
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
    color: #ffffff;
}

/* Controls */
.calendar-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.view-switcher {
    display: flex;
    gap: 4px;
    background: #0A0A0B;
    padding: 4px;
    border-radius: 8px;
}

.view-btn {
    padding: 8px 16px;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.05);
}

.view-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #ffffff;
}

.calendar-filter select {
    padding: 8px 16px;
    background: #0A0A0B;
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
}

/* Month View */
.calendar-month-view {
    margin-top: 20px;
}

.month-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.month-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.prev-month,
.next-month {
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.prev-month:hover,
.next-month:hover {
    background: rgba(255, 255, 255, 0.1);
}

.month-grid {
    display: grid;
    gap: 8px;
}

.weekday-headers {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-bottom: 8px;
}

.weekday-header {
    text-align: center;
    padding: 8px;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
}

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

.day-cell {
    aspect-ratio: 1;
    padding: 8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    position: relative;
    cursor: pointer;
    transition: background 0.2s ease;
}

.day-cell:hover {
    background: rgba(255, 255, 255, 0.08);
}

.day-cell.has-event {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%);
}

.day-number {
    font-size: 14px;
    font-weight: 500;
}

.day-events {
    margin-top: 4px;
    font-size: 10px;
}

.event-dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 2px;
}

.event-dot.importance-low { background: #4ade80; }
.event-dot.importance-medium { background: #facc15; }
.event-dot.importance-high { background: #fb923c; }
.event-dot.importance-critical { background: #ef4444; }

/* List View */
.calendar-list-view {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.event-list-item {
    display: flex;
    gap: 16px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    border-left: 4px solid;
    transition: all 0.2s ease;
}

.event-list-item:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateX(4px);
}

.event-list-item.importance-low { border-left-color: #4ade80; }
.event-list-item.importance-medium { border-left-color: #facc15; }
.event-list-item.importance-high { border-left-color: #fb923c; }
.event-list-item.importance-critical { border-left-color: #ef4444; }

.event-date-block {
    flex-shrink: 0;
    text-align: center;
    min-width: 60px;
}

.event-day {
    font-size: 32px;
    font-weight: 700;
    line-height: 1;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.event-month {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    margin-top: 4px;
}

.event-time {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 4px;
}

.event-content {
    flex: 1;
}

.event-title {
    margin: 0 0 8px 0;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
}

.event-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.event-project {
    padding: 4px 10px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.event-type {
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
}

.event-importance {
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.importance-badge-low {
    background: rgba(74, 222, 128, 0.2);
    color: #4ade80;
}

.importance-badge-medium {
    background: rgba(250, 204, 21, 0.2);
    color: #facc15;
}

.importance-badge-high {
    background: rgba(251, 146, 60, 0.2);
    color: #fb923c;
}

.importance-badge-critical {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.event-description {
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 12px;
}

.event-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    color: #667eea;
    text-decoration: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.event-link:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(2px);
}

/* Widget */
.sbnews-calendar-widget {
    padding: 16px;
}

.calendar-event-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    margin-bottom: 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    border-left: 3px solid #667eea;
}

.calendar-event-item.importance-critical {
    border-left-color: #ef4444;
}

.calendar-event-item.importance-high {
    border-left-color: #fb923c;
}

.calendar-event-item .event-date {
    font-size: 14px;
    font-weight: 600;
    color: #667eea;
    white-space: nowrap;
}

.calendar-event-item .event-details h4 {
    margin: 0 0 4px 0;
    font-size: 14px;
    font-weight: 600;
}

.calendar-event-item .event-project {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

/* No Events State */
.no-events {
    text-align: center;
    padding: 40px 20px;
    color: rgba(255, 255, 255, 0.5);
}

.no-events p {
    font-size: 16px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .sbnews-calendar-container {
        padding: 16px;
    }

    .calendar-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .view-switcher {
        width: 100%;
        justify-content: space-between;
    }

    .view-btn {
        flex: 1;
        font-size: 13px;
    }

    .event-list-item {
        flex-direction: column;
        gap: 12px;
    }

    .event-date-block {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .event-day {
        font-size: 24px;
    }

    .event-title {
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .weekday-header {
        font-size: 10px;
    }

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