/**
 * Estilos Core del Panel de Productores
 * Versión: 2.0.0
 */

/* Estilos generales del panel */
.panel-core-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

/* Botón QR flotante */
.panel-qr-button {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.3);
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    outline: none;
}

.panel-qr-button:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(99, 102, 241, 0.4);
}

.panel-qr-button:active {
    transform: scale(0.95);
}

.panel-qr-button svg {
    width: 28px;
    height: 28px;
    color: white;
}

/* Estado offline */
.panel-offline-mode {
    position: fixed;
    top: 32px;
    left: 50%;
    transform: translateX(-50%);
    background: #f59e0b;
    color: white;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
}

/* Indicador de sincronización */
.panel-sync-indicator {
    position: fixed;
    top: 32px;
    right: 20px;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 12px;
    color: #6b7280;
    z-index: 998;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.panel-sync-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #9ca3af;
}

.panel-sync-dot.synced {
    background: #10b981;
}

.panel-sync-dot.syncing {
    background: #f59e0b;
    animation: pulse 2s infinite;
}

.panel-sync-dot.error {
    background: #ef4444;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Tabla de registros */
.panel-tickets-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.panel-tickets-table th {
    background: #f9fafb;
    padding: 16px;
    text-align: left;
    font-weight: 600;
    color: #374151;
    font-size: 14px;
    border-bottom: 1px solid #e5e7eb;
}

.panel-tickets-table td {
    padding: 16px;
    border-bottom: 1px solid #f3f4f6;
    color: #6b7280;
}

.panel-tickets-table tr:hover {
    background: #f9fafb;
}

/* Estados de tickets */
.panel-ticket-status {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.panel-ticket-status.registrado {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.panel-ticket-status.no-registrado {
    background: rgba(107, 114, 128, 0.1);
    color: #6b7280;
}

.panel-ticket-status.cancelado {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

/* Controles de búsqueda y filtros */
.panel-controls {
    display: flex;
    gap: 16px;
    margin-bottom: 24px;
    flex-wrap: wrap;
    align-items: center;
}

.panel-search-box {
    flex: 1;
    min-width: 200px;
    position: relative;
}

.panel-search-input {
    width: 100%;
    padding: 12px 16px 12px 40px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    transition: all 0.2s;
}

.panel-search-input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.panel-search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: #9ca3af;
}

.panel-filter-select {
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background: white;
    color: #374151;
    font-size: 14px;
    min-width: 120px;
}

/* Estadísticas del evento */
.panel-event-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.panel-stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    text-align: center;
}

.panel-stat-number {
    font-size: 28px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 4px;
}

.panel-stat-label {
    font-size: 14px;
    color: #6b7280;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .panel-core-container {
        padding: 16px;
    }
    
    .panel-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .panel-search-box {
        min-width: auto;
    }
    
    .panel-event-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .panel-qr-button {
        width: 50px;
        height: 50px;
        bottom: 16px;
        right: 16px;
    }
    
    .panel-qr-button svg {
        width: 24px;
        height: 24px;
    }
}

@media (max-width: 480px) {
    .panel-event-stats {
        grid-template-columns: 1fr;
    }
    
    .panel-tickets-table th,
    .panel-tickets-table td {
        padding: 12px 8px;
        font-size: 12px;
    }
}