/* Layout Principal */
body {
    display: flex;
    min-height: 100vh;
    background-color: #f5f7fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Barra Lateral */
.sidebar {
    width: 280px;
    background-color: #2c3e50;
    color: white;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.sidebar-header {
    padding: 20px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-header img {
    width: 80px;
    margin-bottom: 10px;
}

.sidebar-header h3 {
    margin: 0;
    font-size: 1.2rem;
}

.sidebar-header p {
    margin: 5px 0 0;
    font-size: 0.8rem;
    color: #bdc3c7;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
    overflow-y: auto;
}

.user-profile {
    padding: 0 20px 20px;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 15px;
    border: 3px solid #3498db;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.user-info h4 {
    margin: 0;
    font-size: 1rem;
}

.user-info p {
    margin: 5px 0;
    font-size: 0.8rem;
    color: #bdc3c7;
}

.status {
    display: inline-block;
    padding: 3px 8px;
    font-size: 0.7rem;
    border-radius: 10px;
    margin-top: 5px;
}

.status.online {
    background-color: #27ae60;
}

.sidebar-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li {
    margin-bottom: 5px;
}

.sidebar-nav a {
    display: flex;
    align-items: center;
    padding: 12px 20px;
    color: #ecf0f1;
    text-decoration: none;
    transition: all 0.3s ease;
}

.sidebar-nav a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar-nav a.active {
    background-color: #3498db;
}

.sidebar-nav i {
    width: 24px;
    text-align: center;
    margin-right: 10px;
    font-size: 1rem;
}

.sidebar-nav .badge {
    margin-left: auto;
    background-color: #e74c3c;
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 10px;
}

.sidebar-footer {
    padding: 15px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.logout-btn {
    display: flex;
    align-items: center;
    color: #ecf0f1;
    text-decoration: none;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    color: #e74c3c;
}

.logout-btn i {
    margin-right: 10px;
}

/* Conteúdo Principal */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 25px;
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    z-index: 10;
}

.search-bar {
    position: relative;
    width: 300px;
}

.search-bar i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #7f8c8d;
}

.search-bar input {
    width: 100%;
    padding: 10px 15px 10px 40px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.search-bar input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.user-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.notifications {
    position: relative;
    cursor: pointer;
}

.notifications .badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: #e74c3c;
    color: white;
    font-size: 0.6rem;
    padding: 2px 5px;
    border-radius: 50%;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
}

.user-menu img {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    object-fit: cover;
}

.user-menu span {
    font-weight: 500;
}

/* Conteúdo do Painel */
.dashboard-content {
    flex: 1;
    padding: 25px;
    overflow-y: auto;
}

.welcome-banner {
    background: linear-gradient(135deg, #3498db, #2c3e50);
    color: white;
    padding: 30px;
    border-radius: 10px;
    margin-bottom: 30px;
    position: relative;
    overflow: hidden;
}

.welcome-banner h1 {
    margin: 0;
    font-size: 1.8rem;
}

.welcome-banner p {
    margin: 10px 0 20px;
    opacity: 0.9;
}

.quick-actions {
    display: flex;
    gap: 15px;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background-color: white;
    color: #3498db;
}

.btn-primary:hover {
    background-color: #f5f5f5;
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

/* Cards de Resumo */
.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 15px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.card-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.2rem;
}

.bg-primary {
    background-color: #3498db;
}

.bg-success {
    background-color: #27ae60;
}

.bg-warning {
    background-color: #f39c12;
}

.bg-info {
    background-color: #2980b9;
}

.bg-danger {
    background-color: #e74c3c;
}

.card-info h3 {
    margin: 0;
    font-size: 1rem;
    color: #7f8c8d;
    font-weight: 500;
}

.card-info p {
    margin: 5px 0 0;
    font-size: 1.3rem;
    font-weight: 600;
    color: #2c3e50;
}

/* Gráfico */
.chart-container {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.chart-header h2 {
    margin: 0;
    font-size: 1.2rem;
    color: #2c3e50;
}

.chart-header select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: white;
    font-size: 0.9rem;
}

/* Tabela de Notas */
.recent-grades {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    margin: 0;
    font-size: 1.2rem;
    color: #2c3e50;
}

.view-all {
    color: #3498db;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.view-all:hover {
    text-decoration: underline;
}

.grades-table {
    overflow-x: auto;
}

.grades-table table {
    width: 100%;
    border-collapse: collapse;
}

.grades-table th, .grades-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.grades-table th {
    background-color: #f8f9fa;
    color: #7f8c8d;
    font-weight: 500;
    font-size: 0.9rem;
}

.grades-table tr:hover {
    background-color: #f8f9fa;
}

.badge {
    display: inline-block;
    padding: 4px 8px;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 4px;
}

.badge-success {
    background-color: #d5f5e3;
    color: #27ae60;
}

.badge-warning {
    background-color: #fef9e7;
    color: #f39c12;
}

.badge-danger {
    background-color: #fadbd8;
    color: #e74c3c;
}

/* Avisos */
.recent-announcements {
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.announcement-list {
    display: grid;
    gap: 15px;
}

.announcement {
    display: flex;
    gap: 15px;
    padding: 15px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.announcement:hover {
    background-color: #f8f9fa;
}

.announcement-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #f1f1f1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
}

.text-danger {
    color: #e74c3c;
}

.text-info {
    color: #3498db;
}

.text-primary {
    color: #2c3e50;
}

.text-success {
    color: #27ae60;
}

.announcement-content h3 {
    margin: 0 0 5px;
    font-size: 1rem;
}

.announcement-content p {
    margin: 0;
    color: #7f8c8d;
    font-size: 0.9rem;
    line-height: 1.5;
}

.announcement-date {
    display: block;
    margin-top: 8px;
    font-size: 0.8rem;
    color: #bdc3c7;
}

/* Responsividade */
@media (max-width: 1200px) {
    .sidebar {
        width: 250px;
    }
}

@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
        position: fixed;
        z-index: 1000;
        height: 100vh;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
}

@media (max-width: 768px) {
    .welcome-banner h1 {
        font-size: 1.5rem;
    }
    
    .quick-actions {
        flex-direction: column;
    }
    
    .summary-cards {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 576px) {
    .top-bar {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .search-bar {
        width: 100%;
    }
    
    .summary-cards {
        grid-template-columns: 1fr;
    }
    
    .chart-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
}