﻿:root {
    --primary: #006838;
    --secondary: #316911;
    --success: #4cc9f0;
    --warning: #f72585;
    --info: #4895ef;
    --dark: #1e1e2f;
    --light: #f8f9fa;
}

.dashboard-wrapper {
    padding: 2rem;
    background: linear-gradient(135deg, #f5f7fa 0%, #e9ecef 100%);
    min-height: 100vh;
}

/* Header con bienvenida */
.welcome-header {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 30px;
    padding: 2.5rem;
    margin-bottom: 2rem;
    color: white;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 40px #316911;
}

    .welcome-header::before {
        content: '';
        position: absolute;
        top: -50%;
        right: -50%;
        width: 200%;
        height: 200%;
        background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
        animation: rotate 20s linear infinite;
    }

@keyframes rotate { /* NOTA: DOBLE @ */
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeInUp { /* NOTA: DOBLE @ */
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float { /* NOTA: DOBLE @ */
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }

    50% {
        transform: translateY(-20px) rotate(10deg);
    }
}

.welcome-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    position: relative;
}

.welcome-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    position: relative;
}

.date-badge {
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(10px);
    padding: 0.75rem 1.5rem;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: 1px solid rgba(255,255,255,0.3);
    position: relative;
}

/* Tarjetas de métricas - 3D */
.metric-card {
    background: white;
    border-radius: 24px;
    padding: 1.8rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
    border: none;
    height: 100%;
}

    .metric-card:hover {
        transform: translateY(-10px) scale(1.02);
        box-shadow: 0 30px 60px rgba(67, 97, 238, 0.2);
    }

    .metric-card::after {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 5px;
        background: linear-gradient(90deg, var(--primary), var(--secondary));
    }

.metric-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    transform: rotate(-5deg);
    transition: transform 0.3s ease;
}

.metric-card:hover .metric-icon {
    transform: rotate(0deg);
}

.metric-label {
    color: #6c757d;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.metric-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--dark);
    line-height: 1;
    margin-bottom: 0.5rem;
}

.metric-trend {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
}

.trend-up {
    background: rgba(76, 201, 240, 0.1);
    color: #4cc9f0;
}

.trend-down {
    background: rgba(247, 37, 133, 0.1);
    color: #f72585;
}

/* Gráfico */
.chart-card {
    background: white;
    border-radius: 24px;
    padding: 1.8rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    height: 100%;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.chart-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--dark);
    margin: 0;
}

.chart-period {
    background: var(--light);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--dark);
}

/* Tabla de documentos */
.table-documentos {
    background: white;
    border-radius: 24px;
    padding: 1.8rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.table {
    margin-bottom: 0;
}

    .table thead th {
        border-bottom: 2px solid var(--primary);
        color: var(--dark);
        font-weight: 700;
        font-size: 0.85rem;
        text-transform: uppercase;
        letter-spacing: 1px;
        padding: 1rem;
    }

    .table tbody td {
        padding: 1rem;
        vertical-align: middle;
        border-bottom: 1px solid #e9ecef;
    }

.status-badge {
    padding: 0.35rem 0.75rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.status-aprobado {
    background: rgba(76, 201, 240, 0.1);
    color: #4cc9f0;
}

.status-pendiente {
    background: rgba(255, 193, 7, 0.1);
    color: #ffc107;
}

.status-rechazado {
    background: rgba(247, 37, 133, 0.1);
    color: #f72585;
}

.btn-action {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--dark);
    background: var(--light);
    transition: all 0.3s ease;
    margin: 0 2px;
}

    .btn-action:hover {
        background: var(--primary);
        color: white;
        transform: scale(1.1);
    }

/* Actividad reciente */
.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #e9ecef;
}

.activity-icon {
    width: 45px;
    height: 45px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.activity-content {
    flex: 1;
}

.activity-title {
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.25rem;
}

.activity-time {
    font-size: 0.8rem;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

/* Responsive */
@media (max-width: 768px) {
    .dashboard-wrapper {
        padding: 1rem;
    }

    .welcome-title {
        font-size: 1.8rem;
    }

    .metric-value {
        font-size: 1.8rem;
    }
}

/* ✅ AGREGAR a dashboard.css */
.avatar-sm {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.avatar-title {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}
