/* css/calendario.css */
.flex-col {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.calendar-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    background: var(--card-bg);
    padding: 0.5rem 1rem;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05);
}

.calendar-controls h2 {
    font-size: 1.1rem;
    font-weight: 700;
    font-family: 'Outfit', sans-serif;
    color: white;
    min-width: 150px;
    text-align: center;
    margin: 0;
}

.btn-cal {
    background: rgba(255,255,255,0.05);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.btn-cal:hover {
    background: var(--secondary-color);
}

.btn-cal.ms-3 {
    margin-left: 10px;
    width: auto;
    padding: 0 15px;
    font-weight: 600;
}

.calendar-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 1.5rem;
}

.calendar-main-card {
    background: var(--card-bg);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    backdrop-filter: blur(12px);
}

.calendar-grid-header {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.calendar-grid-days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    grid-template-rows: repeat(5, minmax(100px, auto));
    gap: 8px;
}

.cal-day {
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(255,255,255,0.02);
    border-radius: 8px;
    padding: 0.5rem;
    min-height: 100px;
    transition: var(--transition);
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.cal-day:hover {
    background: rgba(255,255,255,0.05);
    border-color: rgba(6, 182, 212, 0.2);
}

.cal-day.empty {
    background: transparent;
    border: none;
    cursor: default;
}

.cal-date {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 5px;
    text-align: right;
}

.cal-day.today {
    background: rgba(6, 182, 212, 0.05);
    border-color: var(--secondary-color);
}

.cal-day.today .cal-date {
    color: var(--secondary-color);
    font-weight: 800;
}

/* Event badges inside dates */
.cal-event-badge {
    font-size: 0.7rem;
    padding: 3px 6px;
    border-radius: 4px;
    margin-bottom: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.bg-pro { background: rgba(34, 197, 94, 0.2); color: #22C55E; border: 1px solid rgba(34, 197, 94, 0.3); }
.bg-nut { background: rgba(168, 85, 247, 0.2); color: #A855F7; border: 1px solid rgba(168, 85, 247, 0.3); }
.bg-fin { background: rgba(245, 158, 11, 0.2); color: #F59E0B; border: 1px solid rgba(245, 158, 11, 0.3); }

/* Side Panel */
.calendar-side-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.upcoming-events-card {
    background: var(--card-bg);
    border: 1px solid rgba(255,255,255,0.05);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
}

.upcoming-events-card h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    padding-bottom: 0.5rem;
}

.events-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.event-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: rgba(255,255,255,0.02);
    border-radius: 8px;
    border-left: 3px solid transparent;
}

.event-item.type-fin { border-left-color: #F59E0B; }
.event-item.type-pro { border-left-color: #22C55E; }
.event-item.type-nut { border-left-color: #A855F7; }

.event-icon {
    width: 35px;
    height: 35px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.05);
}

.type-fin .event-icon { color: #F59E0B; }
.type-pro .event-icon { color: #22C55E; }
.type-nut .event-icon { color: #A855F7; }

.event-details h4 {
    font-size: 0.9rem;
    margin: 0 0 2px 0;
}

.event-details span {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.sync-card {
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.1), var(--card-bg));
    border: 1px solid rgba(37, 99, 235, 0.3);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    text-align: center;
}

.sync-card i {
    font-size: 2rem;
    color: #3B82F6;
    margin-bottom: 10px;
}

.sync-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.btn-outline-small {
    display: inline-block;
    padding: 6px 15px;
    border: 1px solid #3B82F6;
    color: #3B82F6;
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: var(--transition);
}

.btn-outline-small:hover {
    background: #3B82F6;
    color: white;
}

@media (max-width: 900px) {
    .calendar-layout {
        grid-template-columns: 1fr;
    }
}
