

/* Profile Screen Styles */

#profile-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
margin-bottom: 0px;
    height: 100vh;
overflow: auto;

}

.profile-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
    height: auto;       /* limita a altura dentro da tela */

}

.profile-content {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    backdrop-filter: blur(10px);
    margin-top: 10px;
    margin-bottom: 100px;
    width: 100%;
    gap: 0px;
}

fieldset {
    padding: 10px;
    border-radius: 10px;
    border-bottom: 40px;
}
legend {
padding-left: 10px;
padding-right: 10px;
font-size: 18px;
}
.descricao {
    margin-bottom: 20px;
}

/* Profile Stats Section */
.profile-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
    
}

.stats-chart {
    display: flex;
    justify-content: center;
    align-items: center;
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    min-height: 300px;

}

.stats-chart canvas {
    max-width: 100%;
    max-height: 250px;
}

.stats-summary {
    display: flex;
    flex-direction: column;
    gap: 20px;
    justify-content: center;
    
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    

}

.summary-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

.summary-label {
    font-weight: 600;
    color: #333;
    font-size: 16px;
}

.summary-value {
    font-weight: 700;
    font-size: 18px;
    color: #4CAF50;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Profile Actions */
.profile-actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    
}

.profile-actions .btn-primary,
.profile-actions .btn-secondary3 {
    padding: 15px 20px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    border-radius: 12px;
    transition: all 0.3s ease;
    width: 100%;
    background-color: #d32f2f;

    
    
}




.profile-actions .btn-primary:disabled,
.profile-actions .btn-secondary3:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;


}

/* Review Modal Styles */
.review-content {
    min-height: 70vh;
    height: auto; 
     /* Impede rolagem interna */
     width: 800px;

}

.review-summary {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-weight: 600;
    color: #333;
    text-align: center;
    border-left: 4px solid #4CAF50;
    
    
}

.review-questions-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
       width: 100%;

}

.review-question {
    background: rgb(255, 255, 255);
    border: 2px solid #e1e5e9;
    border-radius: 12px;
    padding: 20px;
    width: 100%;
    cursor: pointer;
}

.review-question:hover {
    border-color: #4CAF50;
}

.review-question-text {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin-bottom: 15px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
}

.review-question-text strong {
    font-weight: 700;
    color: #502c2c;
}

.review-question-text em {
    font-style: italic;
    color: #7f8c8d;
}

.review-answer-info {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.user-answer,
.correct-answer {
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;

}

.user-answer.correct {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
    
}

.user-answer.wrong {
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: white;
}

.correct-answer {
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: white;
}

.review-comment {
    background: #e8f5e8;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
    font-size: 14px;
    line-height: 1.5;
    color: #333;
    
}

.review-comment strong {
    color: #2c3e50;
}

/* Empty State */
.empty-stats {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.empty-stats-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-stats h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #333;
}

.empty-stats p {
    font-size: 1rem;
    margin-bottom: 30px;
}

.empty-stats .btn-primary {
    padding: 15px 30px;
    font-size: 16px;
}

/* Achievement Badges (for future implementation) */
.achievements {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 2px solid #e1e5e9;
}

.achievements h3 {
    color: #333;
    font-size: 1.3rem;
    margin-bottom: 20px;
    font-weight: 600;
}

.achievement-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
}

.achievement-badge {
    background: white;
    border: 2px solid #e1e5e9;
    border-radius: 12px;
    padding: 15px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    
}

.achievement-badge:hover {
    border-color: #4CAF50;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.2);
}
.profile-header {
  grid-column: 1 / -1;
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 00px;
    width: 100%;
    margin-bottom: 20px;
}
.achievement-badge.earned {
    border-color: #4CAF50;
    background: linear-gradient(135deg, #e8f5e8, #f1f8e9);
}

.achievement-icon {
    font-size: 2rem;
    margin-bottom: 8px;
    display: block;
}

.achievement-badge.earned .achievement-icon {
    filter: none;
}

.achievement-badge:not(.earned) .achievement-icon {
    filter: grayscale(100%);
    opacity: 0.5;
}

.achievement-name {
    font-size: 12px;
    font-weight: 600;
    color: #333;
}

/* Progress Bars */
.progress-section {
    margin-top: 30px;
}

.progress-item {
    margin-bottom: 20px;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 14px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e1e5e9;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #4CAF50, #45a049);
    border-radius: 4px;
    transition: width 0.6s ease;
}
.alterarFotoPerfil {
    width: auto;
    background-color: #1976D2;
}

.profile-banner {
    height: 10px;
    position: relative;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    width: 100%;
}


.profile-info {
    padding: 0 40px 40px;
    position: relative;
    display: flex;
    align-items: flex-end;
    gap: 30px;
}

.profile-avatar-container {
    position: relative;
    margin-top: 10px;
    width: auto;
}


.profile-avatar-container {
    position: relative;
    margin-top: 10px;
    width: auto;
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 5px solid white;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    object-fit: cover;
}

.avatar-status {
    position: absolute;
    bottom: 10px;
    right: 10px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 3px solid white;
}

.avatar-status.online {
    background: #4CAF50;
}

.avatar-status.offline {
    background: #ccc;
}

.profile-details {
    flex: 1;
    padding-top: 20px;
    width: 100%;
    text-align: left;
}

.user-name {
    font-size: 2.2rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 5px;
}

.user-title {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 15px;
}

.user-meta {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
    color: #888;
}

 #userName {
        width: 100px;
        font-size: 18px;
    }




/* Responsive Design */
@media (max-width: 768px) {
    .profile-container {
        padding: 15px;
        margin-bottom: 100px;
    }
    
    .profile-content {
        padding: 20px;
    }
    
    .profile-stats {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .stats-chart {
        min-height: 250px;
        padding: 15px;
    }
    
    .stats-summary {
        gap: 15px;
    }
    
    .summary-item {
        padding: 15px;
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
    
    .profile-actions {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .review-answer-info {
        flex-direction: column;
        gap: 10px;
    }
    
    .achievement-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 10px;
    }
    

    .profile-info {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 0 20px 30px;
        gap: 0px;
    }
    

    .achievement-badge {
        padding: 12px;
    }
    
    .achievement-icon {
        font-size: 1.5rem;
    }
    .descricao {
        display: none;
    }
    #reviewCorrectBtn {
        display: none;
    }
    #reviewWrongBtn {
        display: none;
    }

    #userName {
        width: 50px;
        font-size: 18px;
    }

    
.profile-details {
    flex: 1;
    padding-top: 20px;
    width: 100%;
    text-align: center;
    justify-content: center;
    align-items: center;
}
.user-meta {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
    color: #888;
    text-align: center;
    justify-content: center;
    align-items: center;
}


}




/* Loading States */
.profile-content.loading {
    opacity: 0.7;
    pointer-events: none;
}

.profile-content.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4CAF50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Chart Loading State */
.stats-chart.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    color: #666;
    font-style: italic;
}

.stats-chart.loading::before {
    content: 'Carregando estatísticas...';
}
/* Adicione este estilo ao seu arquivo css/post-view.css */

.delete-post-btn {
    margin-left: auto; /* Alinha o botão à direita */
    background-color: #f44336; /* Cor vermelha para indicar perigo */
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: background-color 0.3s;
}

.delete-post-btn:hover {
    background-color: #d32f2f; /* Cor mais escura no hover */
}

.delete-post-btn .icon {
    font-size: 16px;
}

/* Print Styles */
@media print {
    .profile-actions,
    .btn-primary,
    .btn-secondary3 {
        display: none;
    }
    
    .profile-content {
        box-shadow: none;
        background: white;
    }
    
    .stats-chart {
        box-shadow: none;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .summary-item {
        border: 2px solid #333;
    }
    
    .review-question {
        border: 2px solid #333;
    }
    
    .achievement-badge {
        border: 2px solid #333;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .summary-item,
    .achievement-badge,
    .profile-actions .btn-primary,
    .profile-actions .btn-secondary3 {
        transition: none;
    }
    
    .progress-fill {
        transition: none;
    }
    
    .profile-content.loading::after {
        animation: none;
    }
}


/* --- Contêiner Principal --- */
.main-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* --- Estilo geral para cada bloco de conteúdo --- */
.content-section {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

/* --- Cabeçalho de cada seção (ex: "Desempenho Geral") --- */
.section-header {
    display: flex;
    justify-content: space-between; /* "between" foi corrigido de "between" */
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
    gap: 10px;
}

.section-header h2 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #333;
}

/* --- Contêiner para ações no cabeçalho (botões) --- */
.section-actions {
    display: flex;
    gap: 10px;
}

/* --- Botão de alternar tipo de gráfico --- */
.btn-chart-type {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.btn-chart-type:hover {
    background: #e9ecef;
}

/* --- Contêiner do Gráfico --- */
.chart-container {
    height: 250px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0px;
    margin: 0px;
}

.chart-container canvas {
    max-width: 100%;
    max-height: 100%;
}

/* --- Lista de Atividades Recentes --- */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* --- Contagem de Conquistas e Atividades --- */


/* --- Grade de Conquistas --- */
.achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
}

/* --- Estatísticas por Categoria --- */
.category-stats {
    display: flex;
    flex-direction: column;
    gap: 15px;
}



/* --- Contêiner da Sequência de Estudos --- */
.streak-calendar {
    display: flex;
    flex-direction: row;
    gap: 20px;
}

/* --- Grade do Calendário --- */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 5px;
    max-width: 350px;
}

/* --- Estatísticas da Sequência (Maior e Total) --- */
.streak-stats {
    display: flex;
    flex-direction: column;
    gap: 30px;
    background-color: #f4f2f2;
    align-items: center;
    justify-content: center;
    height: 100%;
    border-radius: 20px;
    padding: 50px;
}

.streak-stat {
    text-align: center;
    margin-bottom: 20px;
}

.streak-number {
    display: block;
    font-size: 1.8rem;
    font-weight: 700;
    color: #4CAF50;
}

.streak-label {
    font-size: 0.9rem;
    color: #666;
}

/* --- Informação da Sequência no Cabeçalho --- */

.carregando {
    color: white;
}
/* --- Media Queries (Ajustes para telas menores) --- */
@media (max-width: 768px) {
    .content-section {
        padding: 20px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .achievements-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .streak-calendar {
        flex-direction: column;
        width: 100%;
    }
}
