/**
 * Estilos para iCalendar Dashboard y Feeds
 */

/* ========== DASHBOARD STATS ========== */
.icalendar-dashboard {
    margin-bottom: 30px;
}

.stat-card {
    background: #fff;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 15px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 12px;
}

.stat-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.stat-icon {
    font-size: 20px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 22px;
    font-weight: bold;
    line-height: 1;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 12px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Colores de las tarjetas */
.stat-primary .stat-icon {
    background: #e3f2fd;
    color: #1976d2;
}

.stat-primary .stat-value {
    color: #1976d2;
}

.stat-success .stat-icon {
    background: #e8f5e9;
    color: #388e3c;
}

.stat-success .stat-value {
    color: #388e3c;
}

.stat-info .stat-icon {
    background: #e1f5fe;
    color: #0288d1;
}

.stat-info .stat-value {
    color: #0288d1;
}

.stat-warning .stat-icon {
    background: #fff3e0;
    color: #f57c00;
}

.stat-warning .stat-value {
    color: #f57c00;
}

.stat-danger .stat-icon {
    background: #ffebee;
    color: #d32f2f;
}

.stat-danger .stat-value {
    color: #d32f2f;
}

.stat-purple .stat-icon {
    background: #f3e5f5;
    color: #7b1fa2;
}

.stat-purple .stat-value {
    color: #7b1fa2;
}

/* ========== GUÍA DE AYUDA ========== */
.icalendar-help-guide {
    margin-bottom: 30px;
}

.help-button-container {
    text-align: center;
    margin-bottom: 20px;
}

.help-content {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 30px;
    margin-top: 20px;
}

.intro-section {
    margin-bottom: 30px;
}

.intro-section h3 {
    color: #333;
    margin-bottom: 15px;
}

.intro-section .alert {
    border-left: 4px solid #17a2b8;
}

.intro-section ul {
    list-style: none;
    padding-left: 0;
}

.intro-section ul li {
    padding: 5px 0;
}

.guide-section {
    background: #fff;
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 20px;
    border: 1px solid #dee2e6;
}

.guide-section h4 {
    color: #495057;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e9ecef;
}

.step-card {
    background: #f8f9fa;
    border-left: 4px solid #007bff;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 4px;
}

.step-card h5 {
    color: #007bff;
    margin-bottom: 10px;
}

.mockup-container {
    background: #fff;
    border: 2px dashed #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin: 15px 0;
    text-align: center;
}

.mockup-image {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
}

.platform-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 15px;
}

.progress-tracker {
    display: flex;
    justify-content: space-between;
    margin: 30px 0;
    position: relative;
}

.progress-tracker::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    height: 2px;
    background: #dee2e6;
    z-index: 0;
}

.progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 1;
}

.progress-step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid #dee2e6;
    margin: 0 auto 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #6c757d;
}

.progress-step.active .progress-step-circle {
    border-color: #007bff;
    background: #007bff;
    color: #fff;
}

.progress-step.completed .progress-step-circle {
    border-color: #28a745;
    background: #28a745;
    color: #fff;
}

.progress-step-label {
    font-size: 12px;
    color: #6c757d;
}

.tips-section {
    background: #fff3cd;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin: 20px 0;
    border-radius: 4px;
}

.tips-section h5 {
    color: #856404;
    margin-bottom: 10px;
}

.tips-section ul {
    margin-bottom: 0;
}

/* ========== FEED CARDS ========== */
.feed-card {
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.feed-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.feed-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.feed-card-title {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin: 0;
}

.feed-card-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.feed-card-badge.active {
    background: #d4edda;
    color: #155724;
}

.feed-card-badge.inactive {
    background: #f8d7da;
    color: #721c24;
}

.feed-card-body {
    margin-bottom: 15px;
}

.feed-info-row {
    display: flex;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
}

.feed-info-row:last-child {
    border-bottom: none;
}

.feed-info-label {
    font-weight: 600;
    color: #666;
    min-width: 120px;
}

.feed-info-value {
    color: #333;
    flex: 1;
}

.feed-url-display {
    background: #f8f9fa;
    padding: 8px 12px;
    border-radius: 4px;
    font-family: monospace;
    font-size: 12px;
    word-break: break-all;
}

/* ========== MODALES ========== */
.test-result-modal .modal-body {
    padding: 30px;
}

.test-result-success {
    text-align: center;
    padding: 20px;
}

.test-result-success i {
    font-size: 64px;
    color: #28a745;
    margin-bottom: 20px;
}

.test-result-error {
    text-align: center;
    padding: 20px;
}

.test-result-error i {
    font-size: 64px;
    color: #dc3545;
    margin-bottom: 20px;
}

.validation-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.validation-list li {
    padding: 10px;
    margin-bottom: 8px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.validation-list li.success {
    background: #d4edda;
    color: #155724;
}

.validation-list li.error {
    background: #f8d7da;
    color: #721c24;
}

.validation-list li.warning {
    background: #fff3cd;
    color: #856404;
}

.feed-info-box {
    background: #f8f9fa;
    border-radius: 4px;
    padding: 15px;
    margin: 15px 0;
}

.feed-info-box h5 {
    margin-top: 0;
    margin-bottom: 10px;
    color: #495057;
}

.feed-info-box p {
    margin: 5px 0;
    font-size: 14px;
}

/* ========== LOGS MODAL ========== */
.logs-filters {
    margin-bottom: 20px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.log-entry {
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 10px;
}

.log-entry.success {
    border-left: 4px solid #28a745;
}

.log-entry.error {
    border-left: 4px solid #dc3545;
}

.log-entry.warning {
    border-left: 4px solid #ffc107;
}

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

.log-action {
    font-weight: 600;
    color: #333;
}

.log-time {
    font-size: 12px;
    color: #6c757d;
}

.log-message {
    color: #495057;
    margin-bottom: 10px;
}

.log-stats {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: #6c757d;
}

.log-stats span {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* ========== QR CODE ========== */
.qr-container {
    text-align: center;
    padding: 20px;
}

.qr-code-display {
    display: inline-block;
    padding: 20px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    margin: 20px 0;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    .stat-card {
        margin-bottom: 15px;
    }
    
    .feed-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .platform-links {
        flex-direction: column;
    }
    
    .progress-tracker {
        flex-direction: column;
        gap: 20px;
    }
    
    .progress-tracker::before {
        display: none;
    }
}

/* ========== ANIMACIONES ========== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-card,
.feed-card,
.guide-section {
    animation: fadeIn 0.3s ease;
}

/* ========== UTILIDADES ========== */
.text-monospace {
    font-family: 'Courier New', Courier, monospace;
}

.cursor-pointer {
    cursor: pointer;
}

.word-break-all {
    word-break: break-all;
}
