/* Calendario Litúrgico 2026 - Estilos React */
/* Versión: 2.0.0 */

.calendario-liturgico-app {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f3ff 0%, #eff6ff 100%);
    padding-bottom: 40px;
}

/* === LOADING === */
.cal-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    color: #6b7280;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e5e7eb;
    border-top-color: #7c3aed;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.cal-error {
    padding: 40px;
    text-align: center;
    color: #dc2626;
}

/* === HEADER === */
.cal-header {
    background: linear-gradient(135deg, #7c3aed 0%, #5b21b6 100%);
    color: white;
    padding: 40px 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.cal-header-content {
    max-width: 1200px;
    margin: 0 auto;
}

.cal-title-section {
    margin-bottom: 30px;
}

.cal-title {
    font-size: 36px;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.2);
}

.cal-subtitle {
    font-size: 18px;
    margin: 0;
    opacity: 0.9;
}

.cal-controls {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* === BOTONES === */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-active {
    background: white;
    color: #7c3aed;
}

.btn:not(.btn-active) {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.btn-success {
    background: #10b981 !important;
    color: white !important;
}

.btn-primary {
    background: #3b82f6 !important;
    color: white !important;
}

/* === FILTROS === */
.cal-filtros {
    max-width: 1200px;
    margin: -20px auto 30px;
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.filtro-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 15px;
}

.filtro-item label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #374151;
    font-size: 14px;
}

.filtro-input,
.filtro-select {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.filtro-input:focus,
.filtro-select:focus {
    outline: none;
    border-color: #7c3aed;
}

.mes-navegacion {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-nav {
    padding: 8px 12px;
    border: 2px solid #e5e7eb;
    background: white;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 16px;
}

.btn-nav:hover {
    background: #f3f4f6;
    border-color: #7c3aed;
}

.mes-actual {
    flex: 1;
    text-align: center;
    font-weight: 600;
    color: #374151;
}

.filtro-resultados {
    text-align: center;
    color: #6b7280;
    font-size: 14px;
    padding-top: 15px;
    border-top: 1px solid #e5e7eb;
}

/* === VISTA TABLA === */
.cal-tabla-container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.cal-tabla {
    width: 100%;
    border-collapse: collapse;
}

.cal-tabla thead {
    background: linear-gradient(135deg, #7c3aed 0%, #5b21b6 100%);
    color: white;
}

.cal-tabla th {
    padding: 16px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cal-tabla td {
    padding: 14px 16px;
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
}

.cal-tabla tbody tr {
    transition: background-color 0.2s;
}

.cal-tabla tbody tr:hover {
    background-color: #f9fafb;
}

.fecha-cell {
    font-weight: 600;
    color: #374151;
    white-space: nowrap;
}

.link-articulo {
    color: #7c3aed;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.link-articulo:hover {
    color: #5b21b6;
    text-decoration: underline;
}

.link-ver-mas {
    color: #3b82f6;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
}

.link-ver-mas:hover {
    text-decoration: underline;
}

/* === BADGES === */
.badge {
    display: inline-block;
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

/* Tipos */
.badge-solemnidad {
    background: #9333ea;
    color: white;
}

.badge-fiesta {
    background: #3b82f6;
    color: white;
}

.badge-memoria {
    background: #10b981;
    color: white;
}

.badge-feria {
    background: #6b7280;
    color: white;
}

/* Colores litúrgicos */
.badge-blanco {
    background: #f3f4f6;
    color: #1f2937;
    border: 2px solid #d1d5db;
}

.badge-verde {
    background: #d1fae5;
    color: #065f46;
    border: 2px solid #6ee7b7;
}

.badge-morado {
    background: #ede9fe;
    color: #5b21b6;
    border: 2px solid #c4b5fd;
}

.badge-rojo {
    background: #fee2e2;
    color: #991b1b;
    border: 2px solid #fca5a5;
}

/* === VISTA CALENDARIO === */
.cal-calendario-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.mes-titulo {
    text-align: center;
    font-size: 32px;
    font-weight: 700;
    color: #7c3aed;
    margin-bottom: 30px;
}

.calendario-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.calendario-card {
    background: white;
    border-left: 4px solid #7c3aed;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.calendario-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 16px rgba(124, 58, 237, 0.2);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.dia-numero {
    font-size: 36px;
    font-weight: 700;
    color: #7c3aed;
}

.card-titulo {
    font-size: 16px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 12px;
    line-height: 1.4;
}

.card-titulo a {
    color: #7c3aed;
    text-decoration: none;
}

.card-titulo a:hover {
    text-decoration: underline;
}

.card-footer {
    margin-top: 12px;
}

/* === FOOTER === */
.cal-footer {
    text-align: center;
    padding: 40px 20px;
    color: #6b7280;
    max-width: 1200px;
    margin: 40px auto 0;
}

.cal-footer p {
    margin: 5px 0;
}

.footer-small {
    font-size: 14px;
}

/* === IMPRESIÓN === */
@media print {
    .no-print,
    .cal-header,
    .cal-filtros,
    .cal-footer {
        display: none !important;
    }
    
    .calendario-liturgico-app {
        background: white;
    }
    
    .cal-tabla-container {
        box-shadow: none;
    }
    
    .cal-tabla tbody tr:nth-child(even) {
        background-color: #f9fafb;
    }
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .cal-title {
        font-size: 24px;
    }
    
    .cal-controls {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .filtro-grid {
        grid-template-columns: 1fr;
    }
    
    .cal-tabla {
        font-size: 12px;
    }
    
    .cal-tabla th,
    .cal-tabla td {
        padding: 10px 8px;
    }
    
    .calendario-grid {
        grid-template-columns: 1fr;
    }
}

/* === ANIMACIONES === */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fila-evento,
.calendario-card {
    animation: fadeIn 0.3s ease-out;
}