/* Admin Theme - Estilos específicos para Equipe Celmi */

/* Container principal em modo admin */
.admin-mode {
    background: linear-gradient(135deg, #f5f5f5 0%, #e3f2fd 100%);
    min-height: 100vh;
}

/* Sidebar em modo admin */
.admin-mode .layout-sidebar {
    background: linear-gradient(135deg, #1976d2 0%, #0d47a1 100%) !important; /* Gradiente via CSS */
    box-shadow: 2px 0 8px rgba(25, 118, 210, 0.3);
}

.admin-mode .nav-menu-container {
    background: transparent;
}

.admin-mode .nav-link {
    color: rgba(255, 255, 255, 0.9) !important;
    border-radius: 8px;
    margin: 2px 8px;
    transition: all 0.3s ease;
}

.admin-mode .nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white !important;
    transform: translateX(4px);
}

.admin-mode .nav-link.active {
    background: rgba(255, 255, 255, 0.2);
    color: white !important;
    box-shadow: 0 2px 8px rgba(255, 255, 255, 0.2);
}

.admin-mode .nav-section-label {
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 1px;
    padding: 16px 16px 8px 16px;
}

/* Header em modo admin */
.admin-mode .layout-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-bottom: 2px solid #1976d2;
    box-shadow: 0 2px 12px rgba(25, 118, 210, 0.15);
}

/* Main content em modo admin */
.admin-mode .layout-main {
    background: transparent;
}

.admin-mode .layout-body {
    background: transparent;
}

.admin-mode .content-wrapper {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 12px;
    margin: 16px;
    padding: 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

/* Cards e componentes em modo admin */
.admin-mode .mud-paper {
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(25, 118, 210, 0.15);
    border: 1px solid rgba(25, 118, 210, 0.2);
}

.admin-mode .mud-table {
    border-radius: 12px;
    overflow: hidden;
}

.admin-mode .mud-table-outlined {
    border: 2px solid rgba(25, 118, 210, 0.2);
}

/* Botões em modo admin */
.admin-mode .mud-button-filled-primary {
    background: linear-gradient(135deg, #1976d2, #1565c0);
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.3);
    transition: all 0.3s ease;
}

.admin-mode .mud-button-filled-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(25, 118, 210, 0.5);
}

.admin-mode .mud-button-outlined-primary {
    border-color: #1976d2;
    color: #1976d2;
    transition: all 0.3s ease;
}

.admin-mode .mud-button-outlined-primary:hover {
    background: rgba(25, 118, 210, 0.1);
    transform: translateY(-1px);
}

/* Chips e badges em modo admin */
.admin-mode .mud-chip {
    border-radius: 20px;
    font-weight: 600;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Admin Badge Styles */
.admin-badge-container {
    display: flex;
    align-items: center;
    gap: 8px;
}

.admin-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: linear-gradient(135deg, #1976d2, #1565c0);
    color: white;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.4);
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: default;
}

.admin-badge-compact {
    padding: 4px 8px;
    font-size: 10px;
    gap: 4px;
}

.admin-badge:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(25, 118, 210, 0.6);
}

.admin-badge-icon {
    font-size: 14px !important;
    animation: shield-glow 2s ease-in-out infinite;
}

.admin-badge-compact .admin-badge-icon {
    font-size: 12px !important;
}

.admin-badge-text {
    font-weight: 700;
    white-space: nowrap;
}

.admin-badge-pulse {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.3), transparent);
    animation: pulse 2s ease-in-out infinite;
}

.admin-details {
    display: flex;
    align-items: center;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.admin-details:hover {
    opacity: 1;
}

/* Quick Actions Styles */
.quick-actions-container {
    background: linear-gradient(135deg, #ffffff, #f8f9fa);
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 16px;
    margin: 16px 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.quick-actions-container:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.quick-actions-header {
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid #1976d2;
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}

.quick-action-btn {
    height: auto !important;
    padding: 12px 8px !important;
    border-radius: 8px !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    transition: all 0.3s ease;
    min-height: 80px;
}

.quick-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(25, 118, 210, 0.3);
}

.quick-action-text {
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
}

.quick-stats {
    padding-top: 12px;
    border-top: 1px solid #e0e0e0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-top: 8px;
}

.stat-item {
    text-align: center;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.stat-item:hover {
    background: #e3f2fd;
    transform: scale(1.05);
}

/* Header Admin Styles */
.admin-header {
    background: linear-gradient(135deg, #f8f9fa 0%, #e3f2fd 100%);
    border-bottom: 2px solid #1976d2;
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.15);
}

.admin-avatar {
    background: linear-gradient(135deg, #1976d2, #1565c0);
    border: 2px solid #1976d2;
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.4);
    animation: avatar-pulse 3s ease-in-out infinite;
}

/* Animações especiais admin */
@keyframes admin-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(25, 118, 210, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(25, 118, 210, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(25, 118, 210, 0);
    }
}

@keyframes admin-slide-in {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes admin-glow {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.2);
    }
}

@keyframes pulse {
    0% {
        opacity: 0;
        transform: scale(0.95);
    }
    50% {
        opacity: 0.3;
        transform: scale(1.05);
    }
    100% {
        opacity: 0;
        transform: scale(0.95);
    }
}

@keyframes shield-glow {
    0%, 100% {
        filter: brightness(1);
        transform: scale(1);
    }
    50% {
        filter: brightness(1.2);
        transform: scale(1.1);
    }
}

@keyframes avatar-pulse {
    0%, 100% {
        box-shadow: 0 2px 8px rgba(25, 118, 210, 0.4);
    }
    50% {
        box-shadow: 0 4px 16px rgba(25, 118, 210, 0.6);
    }
}

/* Elementos com animação admin */
.admin-mode .layout-header {
    animation: admin-slide-in 0.5s ease-out;
}

.admin-mode .admin-badge {
    animation: admin-pulse 2s infinite;
}

/* Indicadores visuais admin */
.admin-mode .mud-table-row:hover {
    background: rgba(25, 118, 210, 0.05);
}

.admin-mode .mud-table-row.selected {
    background: rgba(25, 118, 210, 0.1);
}

/* Tooltip admin */
.admin-mode .mud-tooltip {
    background: #1976d2;
    color: white;
    border-radius: 8px;
    font-weight: 500;
}

/* Snackbar admin */
.admin-mode .mud-snackbar {
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.admin-mode .mud-snackbar.success {
    background: linear-gradient(135deg, #4caf50, #45a049);
}

.admin-mode .mud-snackbar.info {
    background: linear-gradient(135deg, #2196f3, #1976d2);
}

.admin-mode .mud-snackbar.warning {
    background: linear-gradient(135deg, #ff9800, #f57c00);
}

.admin-mode .mud-snackbar.error {
    background: linear-gradient(135deg, #f44336, #d32f2f);
}

/* Dialog admin */
.admin-mode .mud-dialog {
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.admin-mode .mud-dialog-title {
    background: linear-gradient(135deg, #1976d2, #1565c0);
    color: white;
    border-radius: 12px 12px 0 0;
}

/* Formulários admin */
.admin-mode .mud-input-outlined {
    border-radius: 8px;
}

.admin-mode .mud-input-outlined:hover .mud-input-outlined-border {
    border-color: #1976d2;
}

.admin-mode .mud-input-outlined:focus .mud-input-outlined-border {
    border-color: #1976d2;
    box-shadow: 0 0 0 2px rgba(25, 118, 210, 0.2);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .admin-mode .content-wrapper {
        margin: 8px;
        padding: 16px;
        border-radius: 8px;
    }
    
    .admin-mode .quick-actions-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .admin-badge-text {
        display: none;
    }
    
    .admin-badge {
        padding: 6px 8px;
    }

    .quick-actions-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .quick-action-text {
        font-size: 10px;
    }

    .quick-action-btn {
        min-height: 70px;
        padding: 8px 4px !important;
    }
}

@media (max-width: 480px) {
    .admin-mode .content-wrapper {
        margin: 4px;
        padding: 12px;
    }
    
    .admin-mode .nav-link {
        margin: 1px 4px;
        font-size: 14px;
    }
    
    .admin-mode .nav-section-label {
        padding: 12px 12px 6px 12px;
        font-size: 10px;
    }

    .quick-actions-grid {
        grid-template-columns: 1fr;
    }

    .quick-action-btn {
        flex-direction: row;
        justify-content: flex-start;
        min-height: 50px;
        padding: 8px 12px !important;
    }
}

/* Dark mode support para admin */
@media (prefers-color-scheme: dark) {
    .admin-mode {
        background: linear-gradient(135deg, #121212 0%, #1e1e1e 100%);
    }
    
    .admin-mode .layout-header {
        background: linear-gradient(135deg, #1e1e1e 0%, #2d2d2d 100%);
        border-bottom-color: #1976d2;
    }
    
    .admin-mode .content-wrapper {
        background: rgba(30, 30, 30, 0.95);
        color: white;
    }
    
    .admin-mode .mud-paper {
        background: rgba(30, 30, 30, 0.9);
        color: white;
    }
}

/* Performance optimizations */
.admin-mode * {
    will-change: transform;
}

.admin-mode .mud-button,
.admin-mode .mud-chip,
.admin-mode .mud-icon-button {
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Accessibility improvements */
.admin-mode .nav-link:focus,
.admin-mode .mud-button:focus {
    outline: 2px solid #1976d2;
    outline-offset: 2px;
}

.admin-mode .mud-input-outlined:focus-within {
    outline: 2px solid #1976d2;
    outline-offset: 2px;
}

/* Print styles para admin */
@media print {
    .admin-mode .layout-sidebar,
    .admin-mode .layout-header {
        display: none;
    }
    
    .admin-mode .layout-main {
        margin: 0;
    }
    
    .admin-mode .content-wrapper {
        margin: 0;
        padding: 0;
        box-shadow: none;
        border-radius: 0;
    }
}
