/* UniAssist Dashboard Styles */

.dash-hero {
    padding: 8rem 4rem 4rem;
    text-align: center;
    background: linear-gradient(180deg, var(--dark) 0%, var(--dark-light) 100%);
}

.dash-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.dash-hero p {
    color: var(--text-muted);
    font-size: 1.2rem;
}

/* Dashboard Container */
.dashboard-container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 2rem 4rem;
}

/* Tabs */
.dash-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    justify-content: center;
}

.dash-tab {
    background: var(--dark-light);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 0.75rem 1.25rem;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s;
}

.dash-tab:hover {
    border-color: var(--primary);
    color: var(--text);
}

.dash-tab.active {
    background: var(--gradient);
    border-color: transparent;
    color: white;
}

.dash-tab.future {
    border-style: dashed;
}

/* Content */
.dash-content {
    display: none;
}

.dash-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dash-header {
    margin-bottom: 2rem;
}

.dash-header h2 {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
}

.dash-header p {
    color: var(--text-muted);
}

/* Preview Grid */
.preview-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.full-width {
    grid-column: span 4;
}

/* Stat Cards */
.stat-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stat-card.large {
    grid-column: span 1;
}

.stat-card.highlight {
    border-color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
}

.stat-icon {
    font-size: 2.5rem;
    background: var(--dark);
    padding: 1rem;
    border-radius: 12px;
}

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
}

.stat-label {
    color: var(--text-muted);
    font-size: 0.875rem;
}

.stat-change {
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.stat-change.positive {
    color: var(--success);
}

/* Chart Cards */
.chart-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
}

.chart-card h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
}

.card-hint {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 1rem;
    margin-top: -0.5rem;
}

/* Bar Chart */
.bar-chart {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.bar-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.bar-label {
    width: 150px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.bar-track {
    flex: 1;
    height: 12px;
    background: var(--dark);
    border-radius: 6px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    background: var(--gradient);
    border-radius: 6px;
    transition: width 0.5s;
}

.bar-value {
    width: 50px;
    text-align: right;
    font-weight: 600;
    color: var(--primary-light);
}

/* Alert Cards */
.alert-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.alert-card.warning {
    border-color: var(--warning);
    background: rgba(245, 158, 11, 0.1);
}

.alert-card.danger {
    border-color: var(--danger);
    background: rgba(239, 68, 68, 0.1);
}

.alert-icon {
    font-size: 2rem;
}

.alert-content h4 {
    margin-bottom: 0.5rem;
}

.alert-content p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.alert-action {
    margin-top: 0.75rem;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.85rem;
}

/* Metric Card */
.metric-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    text-align: center;
}

.metric-card.success {
    border-color: var(--success);
    background: rgba(16, 185, 129, 0.1);
}

.metric-card h4 {
    margin-bottom: 0.5rem;
    color: var(--text-muted);
}

.big-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--success);
    margin-bottom: 0.5rem;
}

.metric-card p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Department Grid */
.dept-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.dept-card {
    background: var(--dark);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    position: relative;
}

.dept-card.alert {
    border-color: var(--warning);
}

.dept-card h4 {
    margin-bottom: 0.75rem;
    font-size: 0.95rem;
}

.dept-stats {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.dept-stat {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.dept-alert {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    background: var(--warning);
    color: var(--dark);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 600;
}

/* Topic List */
.topic-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.topic-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: var(--dark);
    border-radius: 8px;
    border-left: 3px solid var(--border);
}

.topic-item.danger {
    border-left-color: var(--danger);
}

.topic-item.warning {
    border-left-color: var(--warning);
}

.topic-name {
    font-size: 0.9rem;
}

.topic-count {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Data Table */
.table-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    overflow-x: auto;
}

.table-card h3 {
    margin-bottom: 1rem;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.data-table th {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
}

.data-table td {
    font-size: 0.9rem;
}

.data-table tr:last-child td {
    border-bottom: none;
}

.highlight-row {
    background: rgba(245, 158, 11, 0.1);
}

.badge {
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge.success {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
}

.badge.warning {
    background: rgba(245, 158, 11, 0.2);
    color: var(--warning);
}

.badge.danger {
    background: rgba(239, 68, 68, 0.2);
    color: var(--danger);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
    margin-right: 0.5rem;
}

.status-dot.green {
    background: var(--success);
}

.status-dot.yellow {
    background: var(--warning);
}

.status-dot.red {
    background: var(--danger);
}

/* Professor Grid */
.prof-grid {
    grid-template-columns: repeat(4, 1fr);
}

.prof-grid .chart-card {
    grid-column: span 2;
}

/* Heatmap */
.heatmap {
    margin-top: 1rem;
}

.heatmap-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.heatmap-label {
    width: 40px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.heatmap-cells {
    display: flex;
    gap: 0.25rem;
    flex: 1;
}

.cell {
    flex: 1;
    height: 25px;
    border-radius: 4px;
}

.cell.low {
    background: rgba(99, 102, 241, 0.1);
}

.cell.medium {
    background: rgba(99, 102, 241, 0.3);
}

.cell.high {
    background: rgba(99, 102, 241, 0.6);
}

.cell.very-high {
    background: var(--primary);
}

.heatmap-legend {
    display: flex;
    justify-content: space-between;
    margin-top: 0.5rem;
    margin-left: 50px;
}

.heatmap-legend span {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.insight {
    margin-top: 1rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.insight strong {
    color: var(--primary-light);
}

/* Student Chips */
.student-chips {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
    flex-wrap: wrap;
}

.student-chip {
    background: var(--dark);
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Student Dashboard */
.student-grid {
    grid-template-columns: repeat(2, 1fr);
}

.student-hero {
    grid-column: span 2;
    background: var(--gradient);
    border-radius: 16px;
    padding: 2rem;
    display: flex;
    align-items: center;
    gap: 3rem;
}

.cgpa-circle {
    background: white;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.cgpa-value {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary);
}

.cgpa-label {
    font-size: 0.75rem;
    color: var(--dark);
}

.student-stats {
    display: flex;
    gap: 3rem;
}

.student-stat {
    text-align: center;
}

.student-stat-value {
    display: block;
    font-size: 2rem;
    font-weight: 700;
}

.student-stat-label {
    font-size: 0.85rem;
    opacity: 0.9;
}

/* Course Progress */
.course-progress-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.course-progress-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--dark);
    border-radius: 10px;
}

.course-progress-item.warning {
    border: 1px solid var(--warning);
}

.course-info {
    width: 180px;
    display: flex;
    flex-direction: column;
}

.course-info .course-name {
    font-weight: 500;
}

.course-info .course-grade {
    font-size: 0.8rem;
    color: var(--primary-light);
}

.mastery-bar {
    flex: 1;
    height: 10px;
    background: var(--dark-lighter);
    border-radius: 5px;
    overflow: hidden;
}

.mastery-bar.warning .mastery-fill {
    background: var(--warning);
}

.mastery-fill {
    height: 100%;
    background: var(--gradient);
    border-radius: 5px;
}

.mastery-value {
    width: 100px;
    font-size: 0.85rem;
    color: var(--text-muted);
    text-align: right;
}

/* Skills Grid */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: var(--dark);
    border-radius: 8px;
    font-size: 0.85rem;
}

.skill-item.acquired {
    border-left: 3px solid var(--success);
}

.skill-item.in-progress {
    border-left: 3px solid var(--warning);
}

.skill-item.missing {
    border-left: 3px solid var(--danger);
}

/* Recommendation Card */
.recommendation-card {
    background: var(--dark-light);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
}

.recommendation-card h3 {
    margin-bottom: 1rem;
}

.rec-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.rec-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: var(--dark);
    border-radius: 10px;
}

.rec-icon {
    font-size: 1.5rem;
}

.rec-content {
    display: flex;
    flex-direction: column;
}

.rec-title {
    font-weight: 500;
    margin-bottom: 0.25rem;
}

.rec-reason {
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* Future Grid */
.future-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.future-card {
    background: var(--dark-light);
    border: 1px dashed var(--border);
    border-radius: 16px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s;
}

.future-card:hover {
    border-color: var(--primary);
    border-style: solid;
}

.future-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.future-card h3 {
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.future-card p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 1000px) {
    .preview-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .full-width {
        grid-column: span 2;
    }

    .prof-grid .chart-card {
        grid-column: span 2;
    }

    .student-hero {
        flex-direction: column;
        text-align: center;
    }

    .student-stats {
        gap: 2rem;
    }
}

@media (max-width: 600px) {
    .preview-grid {
        grid-template-columns: 1fr;
    }

    .full-width,
    .prof-grid .chart-card {
        grid-column: span 1;
    }

    .dept-grid {
        grid-template-columns: 1fr;
    }

    .dash-tabs {
        justify-content: flex-start;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.5rem;
    }

    .dash-hero {
        padding: 7rem 1.5rem 2rem;
    }

    .dash-hero h1 {
        font-size: 2rem;
    }
}