/* ESTILOS PARA LA AGENDA */

.agenda-card {
    position: relative;
    background: rgba(15, 23, 42, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    padding: 18px 20px;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 18px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.agenda-card:hover {
    background: rgba(30, 41, 59, 0.6);
    border-color: rgba(255, 255, 255, 0.12);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.agenda-card.is-completed {
    opacity: 0.5;
}

.agenda-card.is-completed .agenda-title {
    text-decoration: line-through;
}

.agenda-checkbox-btn {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid #64748b;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: transparent;
    transition: all 0.2s;
    flex-shrink: 0;
}

.agenda-checkbox-btn:hover {
    border-color: #38bdf8;
}

.agenda-card.is-completed .agenda-checkbox-btn {
    background: #10b981;
    border-color: #10b981;
    color: #fff;
}

.agenda-content {
    flex-grow: 1;
    min-width: 0;
}

.agenda-title {
    color: #f8fafc;
    font-size: 15px;
    font-weight: 600;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.agenda-meta {
    width: 100%;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    color: #94a3b8;
}

.agenda-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.agenda-status-pill {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-today {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-urgent {
    background: rgba(249, 115, 22, 0.15);
    color: #f97316;
    border: 1px solid rgba(249, 115, 22, 0.3);
}

.status-warning {
    background: rgba(250, 204, 21, 0.15);
    color: #facc15;
    border: 1px solid rgba(250, 204, 21, 0.3);
}

.status-safe {
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.status-overdue {
    background: rgba(239, 68, 68, 0.25);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.5);
    animation: pulse-red 2s infinite;
}

.agenda-actions {
    display: flex;
    gap: 8px;
}

.agenda-btn-icon {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s;
}

.agenda-btn-icon:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #f8fafc;
}

.agenda-btn-icon.delete:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4); }
    70% { box-shadow: 0 0 0 6px rgba(239, 68, 68, 0); }
    100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}


/* =========================================
   GIANT GRID CALENDAR
   ========================================= */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    width: 100%;
}

.cal-weekday {
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    padding-bottom: 8px;
}

.cal-day {
    aspect-ratio: 1;
    background: rgba(15, 23, 42, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px;
    box-sizing: border-box;
    cursor: pointer;
    position: relative;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    color: #e2e8f0;
    font-weight: 700;
    font-size: 17px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.cal-day:hover {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.2);
}

.cal-day.empty {
    background: transparent;
    border-color: transparent;
    cursor: default;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
}
.cal-day.empty:hover {
    transform: none;
    box-shadow: none;
}

.cal-day.today {
    color: #38bdf8;
    border-color: rgba(56, 189, 248, 0.5);
    background: rgba(56, 189, 248, 0.08);
}

.cal-dots-container {
    display: flex;
    align-items: center;
    gap: 3px;
    position: absolute;
    top: 5px;
    left: 5px;
}

.cal-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}
.cal-dot-multi {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #0f172a;
    font-size: 7.5px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 0 8px rgba(255,255,255,0.4);
}
.cal-dot.solemne { background: #ef4444; box-shadow: 0 0 8px #ef4444; }
.cal-dot.control { background: #f59e0b; box-shadow: 0 0 8px #f59e0b; }
.cal-dot.trabajo { background: #8b5cf6; box-shadow: 0 0 8px #8b5cf6; }
.cal-dot.presentacion { background: #3b82f6; box-shadow: 0 0 8px #3b82f6; }

.cal-nav-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 8px;
    transition: all 0.2s;
}
.cal-nav-btn:hover {
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.1);
}

/* Responsive Dots Logic */
.desktop-dots {
    display: none;
    gap: 4px;
}
.mobile-dots {
    display: flex;
}

@media (min-width: 600px) {
    .cal-dot, .cal-dot-multi {
        width: 15px !important;
        height: 15px !important;
    }
    .cal-dot-multi {
        font-size: 10.5px !important;
    }
    
    #cal-month-year {
        font-size: 24px !important;
    }
    .cal-nav-btn svg {
        width: 28px !important;
        height: 28px !important;
    }
    .cal-day {
        font-size: 28px;
    }
    .cal-dots-container {
        top: 7px;
        left: 7px;
    }
    .calendar-grid {
        gap: 8px;
    }
    .desktop-dots {
        display: flex;
    }
    .mobile-dots {
        display: none;
    }
    
}

@media (max-width: 600px) {
    .cal-dots-container .cal-dot {
        width: 8px !important;
        height: 8px !important;
    }
    .cal-dots-container .cal-dot-multi {
        width: 8px !important;
        height: 8px !important;
        font-size: 6.5px !important;
    }
    .agenda-card {
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-areas: 
            "check content"
            "check actions";
        column-gap: 12px;
        row-gap: 6px;
        align-items: center;
        padding: 16px;
        position: relative;
    }
    .desktop-agenda-date { display: none !important; }
    .mobile-agenda-date { display: flex !important; }
    
    .agenda-check-wrapper { 
        grid-area: check; 
        align-self: center; 
        margin-top: 0 !important; 
    }

    .agenda-content {
        grid-area: content;
    }
    .agenda-meta {
    width: 100%;
    min-width: 0;
        flex-wrap: wrap;
        gap: 8px;
    }
    .agenda-card-right {
        grid-area: actions;
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        margin-top: 2px;
        padding-top: 0px;
        width: 100%;
    }
}

.mobile-agenda-dot {
    position: absolute;
    top: 14px;
    left: 14px;
}
.mobile-agenda-dot .cal-dot {
    width: 10px !important;
    height: 10px !important;
}
