@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&display=swap');

#editorial-stats-dashboard {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    font-size: 14px !important;
    font-family: 'Roboto';

}

#editorial-stats .dashboard-header {
    text-align: center;
    margin-bottom: 40px;
    color: #475569;
}

#editorial-stats .dashboard-subtitle {
    font-size: 14px;
    font-weight: 400;
    font-family: 'Roboto';
    color: #64748b;
}

#editorial-stats .collapsible-tabs-v4 {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(25px);
    border-radius: 2px;
    overflow: hidden;
    border: 1px solid rgba(226,232,240,0.6);
    /* Removido hover y transition */
}

#editorial-stats .tabs-container-v4 {
    background-color: #f6f6f5;
    background-size: 400% 400%;
    position: relative;
    overflow: hidden;
}

#editorial-stats .tabs-container-v4::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    z-index: 1;
}


#editorial-stats .primary-tabs-v4 {
    display: flex;
    position: relative;
    z-index: 2;
}

#editorial-stats .primary-tab-v4 {
    flex: 1;
    background: transparent;
    border: none;
    padding: 18px 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 700;
    font-size: 14px;
    font-family: 'Roboto';
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

#editorial-stats .primary-tab-v4::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 4px;
    background: linear-gradient(90deg, #008ad4);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
    border-radius: 2px 2px 0 0;
}

#editorial-stats .primary-tab-v4::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255,255,255,0.15) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Hover más sutil sin elevación ni sombras */
#editorial-stats .primary-tab-v4:hover {
    background: #009bee4b;
    color: white;
    /* Removido: transform: translateY(-2px); */
}

#editorial-stats .primary-tab-v4:hover::after {
    opacity: 1;
}

#editorial-stats .primary-tab-v4.active {
    background: #0099ee;
    color: white;
    font-weight: 700;

}

#editorial-stats .primary-tab-v4.active::before {
    width: 80%;
    height: 5px;
    box-shadow: 0 2px 10px rgba(255,255,255,0.5);
}

#editorial-stats .expand-all-v4 {
    background: rgba(255,255,255,0.1);
    border: none;
    color: rgb(44, 44, 44);
    padding: 18px 25px;
    cursor: pointer;
    font-weight: 700;
    font-size: 15px;
    font-family: 'Roboto';
    transition: all 0.3s ease;
    border-left: 2px solid rgba(255,255,255,0.2);
    position: relative;
    overflow: hidden;
    min-width: 140px;
}

#editorial-stats .expand-all-v4::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}

/* Hover más sutil */
#editorial-stats .expand-all-v4:hover {
    background: rgba(255,255,255,0.2);
    color: #52bef8;

    /* Removido: transform: translateY(-2px); */
    /* Removido: box-shadow: 0 6px 20px rgba(0,0,0,0.15); */
}

#editorial-stats .expand-all-v4:hover::before {
    left: 100%;
}

#editorial-stats .expand-all-v4:active {
    transform: translateY(0);
    
}

#editorial-stats .accordion-section-v4 {
    background: linear-gradient(180deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0.05) 100%);
    
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 1px solid rgba(255,255,255,0.1);
}

#editorial-stats .accordion-section-v4.expanded {
    max-height: 250px;
}

#editorial-stats .accordion-content-v4 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    gap: 12px;
    padding: 25px;
    animation: slideInAccordion 0.5s ease;
}

@keyframes slideInAccordion {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#editorial-stats .accordion-tab-v4 {
    background: rgba(255,255,255,0.95);
    color: #333;
    border: none;
    padding: 12px 8px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 700;
    font-size: 15px;
    font-weight: 'Roboto';
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
}

#editorial-stats .accordion-tab-v4::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 30%, rgba(233,30,99,0.1) 50%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

#editorial-stats .accordion-tab-v4:hover {
    background: #52bef8;
    color: #ffffff;

}

#editorial-stats .accordion-tab-v4.active {
    background: linear-gradient(135deg, rgba(255,255,255,1) 0%, rgba(249,250,251,1) 100%);
    color: #52bef8;
    font-weight: 700;
}

/* Responsive para acordeón */
@media (max-width: 768px) {
    .primary-tabs-v4 {
        flex-wrap: wrap;
    }
    
    .primary-tab-v4 {
        min-width: 90px;
        flex: none;
        padding: 15px 18px;
        font-size: 1rem;
    }

    .expand-all-v4 {
        min-width: 120px;
        padding: 15px 18px;
    }

    .accordion-content-v4 {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 10px;
        padding: 20px;
    }

    .accordion-tab-v4 {
        padding: 10px 6px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .primary-tab-v4 {
        min-width: 80px;
        padding: 12px 15px;
        font-size: 0.95rem;
    }

    .expand-all-v4 {
        min-width: 100px;
        padding: 12px 15px;
        font-size: 0.9rem;
    }

    .accordion-content-v4 {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 8px;
        padding: 15px;
    }
}

#editorial-stats .tab-content {
    padding: 50px;
    padding-top: 10px;
    padding-bottom: 30px;
    min-height: 300px;
    background-color: white;
    /* Agregando franja inferior */
    position: relative;
}

#editorial-stats .tab-content::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 5px;
    background-size: 300% 100%;
    animation: stats-gradientShift 3s ease infinite;
}

#editorial-stats .tab-panel {
    display: none;
    animation: slideInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

#editorial-stats .tab-panel.active {
    display: block;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#editorial-stats .year-header {
    text-align: center;
    margin-bottom: 20px;
}

#editorial-stats .year-title {
    font-size: 50px;
    font-weight: 900;
    background: #ce0374;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 10px;
}

#editorial-stats .year-status {
    display: inline-block;
    padding: 8px 20px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#editorial-stats .status-current {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    color: white;
    box-shadow: 0 8px 20px rgba(139,92,246,0.3);
}

#editorial-stats .status-past {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    box-shadow: 0 8px 20px rgba(99,102,241,0.25);
}

#editorial-stats .stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 30px;
    margin-bottom: 40px;
}

/* MODIFICACIÓN: Cards principales con estilo minimalist clean */
#editorial-stats .stat-card {
    background: #fcfcfc;
    border-radius: 2px;
    padding: 30px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 0.1px groove #ce0374; /* Borde magenta */
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#editorial-stats .stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #ce0374, #e01c88, #e93799, #f147a5);
    background-size: 300% 100%;
    animation: stats-gradientShift 3s ease infinite;
}

#editorial-stats .stat-card.rejection-highlight {
    grid-column: 1 / -1;
    grid-row: 2;
}

#editorial-stats .stat-card.rejection-highlight::before {
    background: linear-gradient(90deg, #ce0374, #e01c88, #e93799, #f147a5);
    background-size: 300% 100%;
    height: 6px;
    animation: stats-gradientShift 3s ease infinite;
}

@keyframes stats-gradientShift {
    0%, 100% { 
        background-position: 0% 50%; 
    }
    50% { 
        background-position: 100% 50%; 
    }
}

#editorial-stats .stat-card.rejection-highlight {
    background: #fcfcfc;
    border: 0.1px groove #ce0374; /* Borde magenta */
    transform: scale(1.02);
}

#editorial-stats .stat-value {
    font-size: 14px;
    font-weight: 900;
    font-family: 'Roboto';
    color: #272727;
    text-transform: uppercase;
    margin-bottom: 8px;
    line-height: 1;
}

#editorial-stats .stat-card.rejection-highlight .stat-value {
    font-size: 15px;
    font-weight: 900;
    color: #272727;
    margin-bottom: 8px;
    line-height: 1;
}

#editorial-stats .stat-label {
    font-size: 13px;
    color: #272727;
    font-weight: 600;
    font-family: 'Roboto';
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#editorial-stats .progress-section {
    background: #fcfcfc;
    padding: 35px;
    border-radius: 2px;
    margin-top: 30px;
    border: 0.1px groove #ce0374; /* Borde magenta */
    position: relative;
    overflow: hidden;
}

/* Agregando franja superior al contenedor de análisis de tasas */
#editorial-stats .progress-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #ce0374, #e01c88, #e93799, #f147a5);
    background-size: 300% 100%;
    animation: stats-gradientShift 3s ease infinite;
}

#editorial-stats .progress-title {
    font-size: 18px;
    font-family: 'Roboto';
    font-weight: 700;
    color: #272727;
    margin-bottom: 25px;
    text-align: center;
}

#editorial-stats .progress-item {
    margin-bottom: 25px;
}

#editorial-stats .progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

#editorial-stats .progress-label {
    font-size: 13px;
    font-family: 'Roboto';
    font-weight: 600;
    text-transform: uppercase;
    color: #1e1820;
}

/* MODIFICACIÓN: Porcentajes con estilo minimalist clean */
#editorial-stats .progress-percentage {
    font-size: 15px;
    font-family: 'Roboto';
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 4px;
    background: #fcfcfc; /* Background claro */
    color: #ce0374; /* Texto magenta */
    border: 1px solid #ce0374; /* Borde magenta */
}

#editorial-stats .acceptance-percentage {
    background: #fcfcfc; /* Background claro */
    color: #ce0374; /* Texto magenta */
    border: 1px solid #ce0374; /* Borde magenta */
}

#editorial-stats .rejection-percentage {
    background: #fcfcfc; /* Background claro */
    color: #ce0374; /* Texto magenta */
    border: 1px solid #ce0374; /* Borde magenta */
    font-size: 1.3rem;
    padding: 6px 16px;
}

#editorial-stats .progress-bar-container {
    background: #ffffff;
    height: 12px;
    border-radius: 8px;
    border: 1px solid rgba(226,232,240,0.8);
    overflow: hidden;
    position: relative;
}

#editorial-stats .progress-bar {
    height: 100%;
    border-radius: 8px;
    transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

#editorial-stats .rejection-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: shimmer 2s infinite;
}

#editorial-stats .summary-card:last-child::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

#editorial-stats .acceptance-bar {
    background: linear-gradient(135deg, #e7467c, #da648b);
}

#editorial-stats .rejection-bar {
    background: linear-gradient(135deg, #c43665, #e01357);
    height: 16px;
    box-shadow: 0 4px 12px rgba(231,76,60,0.3);
}

#editorial-stats .rejection-bar-container {
    height: 16px;
}

#editorial-stats .summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

/* ESTAS SE MANTIENEN CON BACKGROUND MAGENTA */
#editorial-stats .summary-card {
    color: white;
    padding: 25px;
    border-radius: 2px;
    text-align: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

#editorial-stats .summary-card:first-child {
    background: #fcfcfc;
    border: 2px solid #ce0374;
}

#editorial-stats .summary-card:last-child {
    background: #fcfcfc;
    border: 2px solid #ce0374;
    position: relative;
    overflow: hidden;
}

#editorial-stats .summary-number {
    font-size: 2.2rem;
    font-weight: 900;
    margin-bottom: 8px;
    color: #fff;
}

#editorial-stats .summary-label {
    font-size: 0.9rem;
    font-weight: 500;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

#editorial-stats .no-data {
    text-align: center;
    padding: 80px 20px;
    color: #94a3b8;
}

#editorial-stats .no-data-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

#editorial-stats .no-data-text {
    font-size: 1.2rem;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    #editorial-stats .dashboard-title {
        font-size: 2.5rem;
    }
    
    #editorial-stats .tab-content {
        padding: 30px 20px;
    }
    
    #editorial-stats .stats-grid {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto;
    }

    #editorial-stats .stat-card.rejection-highlight {
        grid-column: 1;
        grid-row: 3;
        order: 3;
    }

    #editorial-stats .stat-card:nth-child(1) {
        order: 1;
    }

    #editorial-stats .stat-card:nth-child(2) {
        order: 2;
    }
    
    #editorial-stats .year-title {
        font-size: 40px;
    }
}