/**
 * Educational System & Stats Dashboard Styles
 */

/* ==================== Tutorial System ==================== */

.tutorial-prompt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    animation: fadeIn 0.3s ease;
}

.tutorial-prompt {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 40px;
    border-radius: 16px;
    max-width: 500px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUpBounce 0.5s ease;
}

.tutorial-prompt h2 {
    color: white;
    font-size: 28px;
    margin-bottom: 15px;
    font-weight: 700;
}

.tutorial-prompt p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 30px;
}

.tutorial-prompt-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

.tutorial-prompt button {
    padding: 12px 30px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tutorial-prompt .btn-start {
    background: white;
    color: #667eea;
}

.tutorial-prompt .btn-start:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 255, 255, 0.3);
}

.tutorial-prompt .btn-skip {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.tutorial-prompt .btn-skip:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
}

/* Tutorial Box */
.tutorial-box {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    max-width: 400px;
    z-index: 9998;
    animation: slideInRight 0.4s ease;
}

.tutorial-box h3 {
    color: #2d3748;
    font-size: 20px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.tutorial-box p {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
}

.tutorial-tip {
    background: #fef3c7;
    border-left: 4px solid #f59e0b;
    padding: 10px 15px;
    margin: 15px 0;
    border-radius: 4px;
    font-size: 13px;
    color: #78350f;
}

.tutorial-controls {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.tutorial-controls button {
    flex: 1;
    padding: 10px;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-tutorial-next {
    background: #667eea;
    color: white;
}

.btn-tutorial-next:hover {
    background: #5a67d8;
}

.btn-tutorial-prev {
    background: #e2e8f0;
    color: #4a5568;
}

.btn-tutorial-prev:hover {
    background: #cbd5e0;
}

.btn-tutorial-close {
    background: transparent;
    color: #a0aec0;
    border: 1px solid #e2e8f0;
}

.btn-tutorial-close:hover {
    background: #f7fafc;
    color: #718096;
}

/* Tutorial Progress Bar */
.tutorial-progress {
    height: 4px;
    background: #e2e8f0;
    border-radius: 2px;
    margin: 15px 0;
    overflow: hidden;
}

.tutorial-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

/* Tutorial Highlight */
.tutorial-highlight {
    position: fixed;
    border: 3px solid #667eea;
    border-radius: 8px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5);
    pointer-events: none;
    z-index: 9997;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5), 0 0 0 0 rgba(102, 126, 234, 0.7);
    }
    50% {
        box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5), 0 0 0 15px rgba(102, 126, 234, 0);
    }
}

/* ==================== Tooltips ==================== */

.custom-tooltip {
    position: fixed;
    background: #1a202c;
    color: white;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 13px;
    max-width: 250px;
    z-index: 10000;
    pointer-events: none;
    animation: fadeInTooltip 0.2s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.custom-tooltip::before {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #1a202c;
}

.tooltip-title {
    font-weight: 700;
    margin-bottom: 5px;
    color: #667eea;
}

.tooltip-content {
    line-height: 1.5;
}

/* ==================== Help Panel ==================== */

.help-button {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    font-size: 28px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.help-button:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(102, 126, 234, 0.6);
}

.help-panel {
    position: fixed;
    top: 0;
    right: -450px;
    width: 450px;
    height: 100vh;
    background: white;
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    overflow-y: auto;
    transition: right 0.3s ease;
}

.help-panel.open {
    right: 0;
}

.help-panel-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 10;
}

.help-panel-header h2 {
    margin: 0;
    font-size: 22px;
}

.help-close {
    background: transparent;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s ease;
}

.help-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.help-tabs {
    display: flex;
    background: #f7fafc;
    border-bottom: 2px solid #e2e8f0;
    position: sticky;
    top: 64px;
    z-index: 9;
}

.help-tab {
    flex: 1;
    padding: 12px 10px;
    background: transparent;
    border: none;
    color: #718096;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 13px;
}

.help-tab.active {
    color: #667eea;
    background: white;
    border-bottom: 3px solid #667eea;
}

.help-tab:hover:not(.active) {
    background: #edf2f7;
}

.help-content {
    padding: 20px;
}

.help-tab-content {
    display: none;
}

.help-tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

/* FAQ Styles */
.faq-item {
    margin-bottom: 15px;
}

.faq-item summary {
    background: #f7fafc;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    color: #2d3748;
    transition: background 0.2s ease;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '▼';
    color: #667eea;
    font-size: 12px;
    transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
    transform: rotate(180deg);
}

.faq-item summary:hover {
    background: #edf2f7;
}

.faq-answer {
    padding: 15px;
    color: #4a5568;
    line-height: 1.6;
}

.faq-category-title {
    color: #667eea;
    font-weight: 700;
    font-size: 18px;
    margin: 25px 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #e2e8f0;
}

/* Glossary Styles */
.glossary-search {
    margin-bottom: 20px;
}

.glossary-search input {
    width: 100%;
    padding: 12px 40px 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.glossary-search input:focus {
    outline: none;
    border-color: #667eea;
}

.glossary-term {
    padding: 15px;
    background: #f7fafc;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 4px solid #667eea;
}

.glossary-term h4 {
    color: #2d3748;
    margin: 0 0 8px 0;
    font-size: 16px;
}

.glossary-term-category {
    display: inline-block;
    background: #667eea;
    color: white;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    margin-bottom: 8px;
}

.glossary-term p {
    color: #4a5568;
    line-height: 1.5;
    margin: 8px 0;
    font-size: 14px;
}

.glossary-term-example {
    color: #718096;
    font-style: italic;
    font-size: 13px;
    margin-top: 8px;
}

/* Case Studies Styles */
.case-study {
    background: #f7fafc;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    border-left: 4px solid #f59e0b;
}

.case-study h4 {
    color: #2d3748;
    margin: 0 0 10px 0;
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.case-year {
    color: #667eea;
    font-size: 14px;
    font-weight: 600;
}

.case-impact {
    background: #fef3c7;
    padding: 10px;
    border-radius: 6px;
    margin: 10px 0;
}

.case-impact-label {
    font-weight: 700;
    color: #78350f;
    font-size: 13px;
}

.case-impact-value {
    color: #92400e;
    font-size: 14px;
}

.case-lessons {
    margin-top: 12px;
}

.case-lessons h5 {
    color: #2d3748;
    font-size: 14px;
    margin-bottom: 8px;
}

.case-lessons ul {
    margin: 0;
    padding-left: 20px;
    color: #4a5568;
    font-size: 13px;
    line-height: 1.6;
}

.case-mitre {
    margin-top: 10px;
    font-size: 13px;
    color: #718096;
}

.case-mitre strong {
    color: #667eea;
}

/* Best Practices Styles */
.practices-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
}

.practice-card {
    background: linear-gradient(135deg, #f7fafc 0%, #edf2f7 100%);
    padding: 20px;
    border-radius: 12px;
    border-left: 4px solid #10b981;
}

.practice-card h4 {
    color: #2d3748;
    margin: 0 0 10px 0;
    font-size: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.practice-card p {
    color: #4a5568;
    line-height: 1.5;
    margin: 0;
    font-size: 14px;
}

/* Useful Links Styles */
.useful-links {
    list-style: none;
    padding: 0;
}

.useful-links li {
    margin-bottom: 12px;
}

.useful-links a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #f7fafc;
    border-radius: 8px;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.useful-links a:hover {
    background: #edf2f7;
    transform: translateX(5px);
}

.link-icon {
    font-size: 20px;
}

/* ==================== Notifications ==================== */

.notification {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    padding: 15px 25px;
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
    z-index: 10001;
    display: flex;
    align-items: center;
    gap: 15px;
    min-width: 300px;
    transition: bottom 0.3s ease;
}

.notification.notification-show {
    bottom: 30px;
}

.notification.success {
    border-left: 4px solid #10b981;
}

.notification.error {
    border-left: 4px solid #ef4444;
}

.notification.info {
    border-left: 4px solid #3b82f6;
}

.notification-icon {
    font-size: 24px;
}

.notification-message {
    flex: 1;
    color: #2d3748;
    font-weight: 500;
}

/* ==================== Stats Dashboard ==================== */

.stats-dashboard-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    overflow-y: auto;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.stats-dashboard {
    background: white;
    border-radius: 16px;
    max-width: 1200px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.stats-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 16px 16px 0 0;
}

.stats-header h1 {
    margin: 0;
    font-size: 32px;
}

.close-stats {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.close-stats:hover {
    background: rgba(255, 255, 255, 0.3);
}

.stats-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 30px;
    background: #f7fafc;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 8px;
}

.stat-label {
    color: #718096;
    font-size: 14px;
    font-weight: 600;
}

.stats-section {
    padding: 30px;
    border-bottom: 1px solid #e2e8f0;
}

.stats-section h2 {
    color: #2d3748;
    font-size: 24px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
}

.stat-block {
    background: #f7fafc;
    padding: 20px;
    border-radius: 12px;
}

.stat-block h3 {
    color: #2d3748;
    font-size: 18px;
    margin-bottom: 15px;
}

/* Decision Analysis */
.decision-breakdown {
    margin-top: 15px;
}

.decision-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.decision-category {
    min-width: 120px;
    font-weight: 600;
    color: #4a5568;
    font-size: 14px;
}

.progress-bar {
    flex: 1;
    height: 20px;
    background: #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.decision-count {
    min-width: 80px;
    text-align: right;
    font-size: 13px;
    color: #718096;
}

.top-decisions {
    margin: 15px 0;
    padding-left: 20px;
    color: #4a5568;
}

.top-decisions li {
    margin-bottom: 8px;
    font-size: 14px;
}

/* Spending Breakdown */
.spending-chart {
    margin-top: 15px;
}

.spending-item {
    display: flex;
    justify-content: space-between;
    padding: 10px;
    background: white;
    border-radius: 6px;
    margin-bottom: 8px;
    font-size: 14px;
}

.budget-stats {
    margin-top: 15px;
    font-size: 14px;
    color: #4a5568;
}

.budget-stats > div {
    padding: 8px 0;
    border-bottom: 1px solid #e2e8f0;
}

.budget-stats .positive {
    color: #10b981;
    font-weight: 700;
}

.budget-stats .negative {
    color: #ef4444;
    font-weight: 700;
}

/* Performance Metrics */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.metric-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 2px solid #e2e8f0;
}

.metric-card.metric-warning {
    border-color: #fbbf24;
    background: #fef3c7;
}

.metric-icon {
    font-size: 32px;
    margin-bottom: 10px;
}

.metric-value {
    font-size: 28px;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 5px;
}

.metric-label {
    font-size: 13px;
    color: #718096;
    font-weight: 600;
}

.metric-sublabel, .metric-range {
    font-size: 11px;
    color: #a0aec0;
    margin-top: 5px;
}

/* Event Timeline */
.event-timeline {
    margin-top: 20px;
}

.timeline-event {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #e2e8f0;
}

.timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #667eea;
    margin-top: 5px;
    flex-shrink: 0;
}

.timeline-event.severity-high .timeline-dot {
    background: #ef4444;
}

.timeline-event.severity-medium .timeline-dot {
    background: #f59e0b;
}

.timeline-event.severity-low .timeline-dot {
    background: #10b981;
}

.timeline-content {
    flex: 1;
}

.timeline-turn {
    font-size: 12px;
    color: #a0aec0;
    font-weight: 600;
}

.timeline-name {
    color: #2d3748;
    font-weight: 600;
    margin: 3px 0;
}

.timeline-meta {
    font-size: 12px;
    color: #718096;
}

/* Efficiency Section */
.efficiency-section {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
}

.efficiency-meter {
    display: flex;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
}

.efficiency-bar {
    flex: 1;
    height: 30px;
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.efficiency-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981 0%, #059669 100%);
    transition: width 0.5s ease;
}

.efficiency-value {
    font-size: 32px;
    font-weight: 700;
    color: #78350f;
}

.efficiency-breakdown {
    background: white;
    padding: 20px;
    border-radius: 12px;
    margin: 20px 0;
}

.efficiency-item {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #e2e8f0;
}

.efficiency-score {
    font-weight: 700;
    color: #667eea;
}

.efficiency-grade {
    text-align: center;
    font-size: 18px;
    color: #78350f;
    margin-top: 15px;
}

/* Recommendations Section */
.recommendations-section {
    background: #f7fafc;
}

.recommendations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.recommendation-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    border-left: 4px solid #3b82f6;
}

.recommendation-card.high {
    border-left-color: #ef4444;
}

.recommendation-card.medium {
    border-left-color: #f59e0b;
}

.recommendation-card.low {
    border-left-color: #10b981;
}

.rec-icon {
    font-size: 32px;
    margin-bottom: 10px;
}

.recommendation-card h4 {
    color: #2d3748;
    margin: 10px 0;
    font-size: 16px;
}

.recommendation-card p {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

/* Stats Actions */
.stats-actions {
    padding: 30px;
    display: flex;
    gap: 15px;
    justify-content: center;
    background: #f7fafc;
    border-radius: 0 0 16px 16px;
}

.btn-primary, .btn-secondary {
    padding: 15px 40px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.btn-secondary:hover {
    background: #f7fafc;
}

/* ==================== Animations ==================== */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeInTooltip {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideUpBounce {
    0% {
        transform: translateY(100px);
        opacity: 0;
    }
    60% {
        transform: translateY(-10px);
    }
    80% {
        transform: translateY(5px);
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(100px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* ==================== Responsive Design ==================== */

@media (max-width: 768px) {
    .help-panel {
        width: 100%;
        right: -100%;
    }
    
    .stats-dashboard {
        margin: 0;
        border-radius: 0;
        max-height: 100vh;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .metrics-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .tutorial-box {
        left: 20px;
        right: 20px;
        bottom: 20px;
        max-width: none;
    }
    
    .recommendations-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================== Scrollbar Styling ==================== */

.help-panel::-webkit-scrollbar,
.stats-dashboard::-webkit-scrollbar {
    width: 8px;
}

.help-panel::-webkit-scrollbar-track,
.stats-dashboard::-webkit-scrollbar-track {
    background: #f7fafc;
}

.help-panel::-webkit-scrollbar-thumb,
.stats-dashboard::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 4px;
}

.help-panel::-webkit-scrollbar-thumb:hover,
.stats-dashboard::-webkit-scrollbar-thumb:hover {
    background: #a0aec0;
}

/* ==================== Educational Content System ==================== */

/* Floating Menu */
.edu-floating-menu {
    position: fixed;
    bottom: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1000;
}

.edu-menu-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.edu-menu-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* Panel Overlays */
.edu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}

.edu-panel {
    background: white;
    border-radius: 16px;
    max-width: 900px;
    width: 90%;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.4s ease;
}

.edu-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.edu-header h2 {
    margin: 0;
    font-size: 24px;
}

.edu-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    transition: background 0.3s;
}

.edu-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

.edu-tabs {
    display: flex;
    gap: 5px;
    padding: 10px 20px;
    background: #f7fafc;
    border-bottom: 2px solid #e2e8f0;
    overflow-x: auto;
}

.edu-tab {
    padding: 10px 20px;
    border: none;
    background: transparent;
    color: #4a5568;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s;
    white-space: nowrap;
}

.edu-tab:hover {
    background: #e2e8f0;
}

.edu-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.edu-content {
    padding: 30px;
    overflow-y: auto;
    flex: 1;
}

/* ==================== Frameworks Panel ==================== */

.framework-info {
    margin-bottom: 30px;
    padding: 20px;
    background: #f7fafc;
    border-radius: 12px;
    border-left: 4px solid #667eea;
}

.framework-info h3 {
    margin: 0 0 10px 0;
    color: #2d3748;
    font-size: 20px;
}

.framework-info p {
    color: #4a5568;
    line-height: 1.6;
    margin: 0 0 15px 0;
}

.framework-link {
    display: inline-block;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.framework-link:hover {
    color: #764ba2;
}

/* MITRE */
.techniques-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
}

.technique-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px;
    transition: all 0.3s;
}

.technique-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.technique-id {
    display: inline-block;
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.technique-card h5 {
    margin: 8px 0;
    color: #2d3748;
    font-size: 16px;
}

.technique-tactic {
    color: #718096;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
}

.technique-card p {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

/* CIS Controls */
.controls-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.control-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px;
    transition: all 0.3s;
}

.control-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.control-num {
    display: inline-block;
    background: #48bb78;
    color: white;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.control-card h5 {
    margin: 8px 0;
    color: #2d3748;
}

.control-card p {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.5;
    margin: 0;
}

/* NIST Functions */
.functions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.function-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
}

.function-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
    transform: translateY(-2px);
}

.function-card h5 {
    color: #2d3748;
    margin: 0 0 10px 0;
}

.function-card p {
    color: #4a5568;
    font-size: 14px;
    margin: 0 0 15px 0;
}

.categories {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    justify-content: center;
}

.category-tag {
    background: #edf2f7;
    color: #4a5568;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
}

/* ISO */
.iso-control {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 10px;
    font-size: 14px;
}

.iso-control strong {
    color: #667eea;
    margin-right: 8px;
}

/* Kill Chain */
.killchain-phases {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.phase-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-left: 5px solid #667eea;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
}

.phase-card:hover {
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
    transform: translateX(4px);
}

.phase-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    font-weight: 700;
    margin-bottom: 10px;
}

.phase-card h5 {
    color: #2d3748;
    margin: 0 0 10px 0;
}

.phase-card p {
    color: #4a5568;
    font-size: 14px;
    margin: 0 0 10px 0;
}

.phase-example {
    background: #f7fafc;
    padding: 10px;
    border-radius: 8px;
    font-size: 13px;
    color: #4a5568;
}

/* OWASP */
.owasp-risks {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.risk-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
}

.risk-card:hover {
    border-color: #f56565;
    box-shadow: 0 4px 12px rgba(245, 101, 101, 0.15);
}

.risk-rank {
    display: inline-block;
    background: #f56565;
    color: white;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.risk-card h5 {
    color: #2d3748;
    margin: 8px 0;
}

.risk-card p {
    color: #4a5568;
    font-size: 14px;
    margin: 0 0 10px 0;
}

.risk-example {
    background: #fff5f5;
    padding: 10px;
    border-radius: 8px;
    font-size: 13px;
    color: #c53030;
}

/* Certifications */
.certs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.cert-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
}

.cert-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
    transform: translateY(-4px);
}

.cert-card h4 {
    color: #2d3748;
    margin: 0 0 5px 0;
    font-size: 18px;
}

.cert-fullname {
    color: #718096;
    font-size: 13px;
    margin-bottom: 15px;
}

.cert-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.cert-level {
    background: #9f7aea;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.cert-cost {
    background: #48bb78;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.cert-card p {
    color: #4a5568;
    font-size: 14px;
    line-height: 1.6;
    margin: 0 0 15px 0;
}

.cert-details {
    background: #f7fafc;
    padding: 12px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 15px;
}

.cert-details div {
    margin-bottom: 6px;
    color: #4a5568;
}

.cert-link {
    display: inline-block;
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
}

.cert-link:hover {
    color: #764ba2;
}

/* ==================== Quiz System ==================== */

.quiz-progress {
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
}

.quiz-question {
    background: white;
    border-radius: 12px;
    padding: 30px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.quiz-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.quiz-category {
    background: #667eea;
    color: white;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.quiz-difficulty {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.difficulty-easy {
    background: #48bb78;
    color: white;
}

.difficulty-medium {
    background: #ed8936;
    color: white;
}

.difficulty-hard {
    background: #f56565;
    color: white;
}

.quiz-question h3 {
    color: #2d3748;
    margin: 0 0 25px 0;
    font-size: 20px;
    line-height: 1.5;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quiz-option {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px 20px;
    text-align: left;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s;
    color: #2d3748;
}

.quiz-option:hover {
    border-color: #667eea;
    background: #f7fafc;
    transform: translateX(4px);
}

.quiz-feedback {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    text-align: center;
}

.quiz-feedback.correct {
    border-left: 5px solid #48bb78;
}

.quiz-feedback.incorrect {
    border-left: 5px solid #f56565;
}

.quiz-feedback h3 {
    font-size: 28px;
    margin: 0 0 20px 0;
}

.quiz-feedback.correct h3 {
    color: #48bb78;
}

.quiz-feedback.incorrect h3 {
    color: #f56565;
}

.quiz-feedback p {
    color: #4a5568;
    font-size: 15px;
    line-height: 1.6;
    margin: 0 0 15px 0;
}

.quiz-explanation {
    background: #f7fafc;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: left;
}

.btn-next-question {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
}

.btn-next-question:hover {
    transform: scale(1.05);
}

.quiz-results {
    background: white;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
}

.quiz-results h2 {
    color: #2d3748;
    margin: 0 0 30px 0;
}

.quiz-score-display {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    margin: 30px 0;
}

.quiz-grade {
    font-size: 72px;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.quiz-percentage {
    font-size: 48px;
    font-weight: 700;
    color: #2d3748;
}

.quiz-stats {
    background: #f7fafc;
    padding: 20px;
    border-radius: 12px;
    margin: 20px 0;
    display: flex;
    justify-content: center;
    gap: 40px;
}

.quiz-stats div {
    color: #4a5568;
    font-size: 16px;
    font-weight: 600;
}

.quiz-message {
    font-size: 18px;
    color: #4a5568;
    margin: 20px 0;
}

.quiz-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.btn-primary, .btn-secondary {
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: transform 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-secondary {
    background: #e2e8f0;
    color: #4a5568;
}

.btn-primary:hover, .btn-secondary:hover {
    transform: scale(1.05);
}

/* ==================== Flashcards ==================== */

.deck-selector {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
}

.flashcard-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.flashcard-progress {
    background: #f7fafc;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #4a5568;
    text-align: center;
}

.flashcard {
    width: 100%;
    max-width: 600px;
    height: 350px;
    position: relative;
    perspective: 1000px;
    cursor: pointer;
}

.flashcard.flipped .flashcard-front {
    transform: rotateY(180deg);
}

.flashcard.flipped .flashcard-back {
    transform: rotateY(0deg);
}

.flashcard-front,
.flashcard-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transition: transform 0.6s;
}

.flashcard-front {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: rotateY(0deg);
}

.flashcard-back {
    background: white;
    color: #2d3748;
    border: 3px solid #667eea;
    transform: rotateY(-180deg);
}

.flashcard-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
    opacity: 0.7;
}

.flashcard-text {
    font-size: 22px;
    line-height: 1.6;
    text-align: center;
    font-weight: 600;
}

.flashcard-hint {
    margin-top: 30px;
    font-size: 14px;
    opacity: 0.7;
}

.flashcard-controls {
    display: flex;
    gap: 15px;
}

.btn-flashcard {
    background: white;
    border: 2px solid #e2e8f0;
    color: #4a5568;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-flashcard:hover:not(:disabled) {
    border-color: #667eea;
    background: #f7fafc;
}

.btn-flashcard:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-master {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
}

.btn-master:hover {
    transform: scale(1.05);
}

/* ==================== Career Path ==================== */

.roles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.role-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s;
}

.role-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.2);
    transform: translateY(-4px);
}

.role-card h3 {
    color: #2d3748;
    margin: 0 0 10px 0;
    font-size: 20px;
}

.role-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.role-level {
    background: #9f7aea;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.role-exp {
    background: #4299e1;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.role-salary {
    background: #f7fafc;
    padding: 12px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 15px;
}

.role-salary div {
    margin-bottom: 4px;
    color: #4a5568;
}

.role-card h5 {
    color: #2d3748;
    margin: 15px 0 10px 0;
    font-size: 14px;
}

.role-card ul {
    margin: 0;
    padding-left: 20px;
    color: #4a5568;
    font-size: 14px;
}

.role-card li {
    margin-bottom: 6px;
}

.role-skills, .role-certs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 15px;
}

.skill-tag {
    background: #edf2f7;
    color: #4a5568;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.cert-badge {
    background: #9f7aea;
    color: white;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.role-next {
    background: #e6fffa;
    border-left: 3px solid #48bb78;
    padding: 10px;
    border-radius: 6px;
    font-size: 13px;
    color: #2c7a7b;
}

/* Career Paths */
.career-paths {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.path-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 30px;
}

.path-card h3 {
    color: #2d3748;
    margin: 0 0 25px 0;
    text-align: center;
    font-size: 22px;
}

.path-stages {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
}

.path-stage {
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 15px 25px;
    text-align: center;
    min-width: 250px;
}

.stage-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #667eea;
    color: white;
    border-radius: 50%;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 8px;
}

.stage-name {
    color: #2d3748;
    font-weight: 600;
    font-size: 15px;
}

.stage-arrow {
    color: #667eea;
    font-size: 24px;
    font-weight: 700;
}

/* Skill Development */
.skill-development {
    display: flex;
    flex-direction: column;
    gap: 25px;
}

.skill-level-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 25px;
}

.skill-level-card h3 {
    color: #2d3748;
    margin: 0 0 20px 0;
    font-size: 20px;
    border-bottom: 2px solid #667eea;
    padding-bottom: 10px;
}

.skill-level-card h4 {
    color: #4a5568;
    margin: 15px 0 10px 0;
    font-size: 16px;
}

.skills-list, .certs-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 15px;
}

.skill-level-card ul {
    margin: 0;
    padding-left: 20px;
    color: #4a5568;
    font-size: 14px;
}

.skill-level-card li {
    margin-bottom: 8px;
}

/* Industry Stats */
.industry-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.stat-card {
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s;
}

.stat-card:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.stat-card h3 {
    color: #4a5568;
    font-size: 16px;
    margin: 0 0 15px 0;
}

.stat-value {
    color: #2d3748;
    font-size: 28px;
    font-weight: 700;
}

.stat-full {
    grid-column: span 2;
}

.demanding-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 15px;
}

/* ==================== Responsive Design ==================== */

@media (max-width: 768px) {
    .edu-panel {
        width: 95%;
        max-height: 90vh;
    }
    
    .edu-header {
        padding: 15px;
    }
    
    .edu-header h2 {
        font-size: 18px;
    }
    
    .edu-content {
        padding: 20px;
    }
    
    .edu-tabs {
        overflow-x: auto;
    }
    
    .techniques-grid,
    .functions-grid,
    .certs-grid,
    .roles-grid {
        grid-template-columns: 1fr;
    }
    
    .flashcard {
        height: 300px;
    }
    
    .quiz-score-display {
        flex-direction: column;
        gap: 15px;
    }
    
    .quiz-grade {
        font-size: 56px;
    }
    
    .quiz-percentage {
        font-size: 36px;
    }
    
    .stat-full {
        grid-column: span 1;
    }
}
