/* Revise Page - Material Design */
page[data-hash="revise"] {
    .revise-page {
        background: #f5f5f5;
        min-height: 100vh;
    }
    
    /* Action Bar */
    .action-bar {
        background: white;
        padding: 1.5rem;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    .revise-indicator {
        width: 56px;
        height: 56px;
        border-radius: 50%;
        background: linear-gradient(135deg, #7b1fa2 0%, #6a1b9a 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 1.5rem;
        color: white;
    }
    
    .btn-elevated {
        background: white;
        border: 1px solid #e0e0e0;
        padding: 0.5rem 1rem;
        border-radius: 4px;
        font-weight: 500;
        transition: all 0.3s ease;
        color: #424242;
        cursor: pointer;
    }
    
    .btn-elevated:hover {
        background: #f5f5f5;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }
    
    /* Subject Tabs */
    .subject-tabs {
        background: white;
        padding: 0.75rem;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        display: flex;
        gap: 0.5rem;
        overflow-x: auto;
    }
    
    .subject-tab {
        padding: 0.75rem 1.5rem;
        border: none;
        background: transparent;
        border-radius: 6px;
        font-weight: 500;
        color: #757575;
        cursor: pointer;
        transition: all 0.3s ease;
        display: flex;
        align-items: center;
        gap: 0.5rem;
        white-space: nowrap;
    }
    
    .subject-tab:hover {
        background: #f5f5f5;
    }
    
    .subject-tab.active {
        background: linear-gradient(135deg, #5e35b1 0%, #7b1fa2 100%);
        color: white;
    }
    
    /* Subject Content */
    .subject-content {
        display: none;
    }
    
    .subject-content.active {
        display: block;
    }
    
    /* Material Card */
    .material-card {
        background: white;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        overflow: hidden;
    }
    
    .card-header-material {
        padding: 1.25rem 1.5rem;
        border-bottom: 1px solid #e0e0e0;
        font-weight: 600;
        font-size: 1rem;
        color: #212121;
    }
    
    .card-body-material {
        padding: 1.5rem;
    }
    
    /* Subject Header Card */
    .subject-header-card {
        padding: 2rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        flex-wrap: wrap;
        gap: 1.5rem;
    }
    
    .subject-header-left {
        display: flex;
        align-items: center;
        gap: 1.5rem;
    }
    
    .subject-icon-large {
        width: 64px;
        height: 64px;
        border-radius: 16px;
        background: linear-gradient(135deg, #00897b 0%, #00796b 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 2rem;
        color: white;
    }
    
    .subject-title {
        font-size: 1.75rem;
        font-weight: 600;
        color: #212121;
        margin-bottom: 0.5rem;
    }
    
    .subject-meta {
        display: flex;
        align-items: center;
        gap: 0.75rem;
        color: #757575;
        font-size: 0.875rem;
    }
    
    .meta-item {
        display: flex;
        align-items: center;
        gap: 0.375rem;
    }
    
    .meta-separator {
        color: #bdbdbd;
    }
    
    .mastery-badge {
        text-align: right;
    }
    
    .mastery-percent {
        font-size: 3rem;
        font-weight: bold;
        background: linear-gradient(135deg, #7b1fa2 0%, #5e35b1 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        line-height: 1;
        margin-bottom: 0.25rem;
    }
    
    .mastery-label {
        font-size: 0.875rem;
        font-weight: 600;
        color: #757575;
        letter-spacing: 1px;
    }
    
    /* Progress Timeline */
    .progress-timeline {
        padding: 0 2rem 2rem 2rem;
    }
    
    .timeline-bar {
        position: relative;
        height: 8px;
        background: #e0e0e0;
        border-radius: 4px;
        overflow: visible;
    }
    
    .timeline-progress {
        height: 100%;
        background: linear-gradient(90deg, #5e35b1 0%, #7b1fa2 100%);
        border-radius: 4px;
        transition: width 0.5s ease;
    }
    
    .timeline-marker {
        position: absolute;
        top: 50%;
        transform: translate(-50%, -50%);
    }
    
    .marker-dot {
        width: 16px;
        height: 16px;
        border-radius: 50%;
        background: white;
        border: 3px solid #e0e0e0;
        transition: all 0.3s ease;
    }
    
    .marker-dot.active {
        border-color: #7b1fa2;
        background: #7b1fa2;
    }
    
    .marker-label {
        position: absolute;
        top: 24px;
        left: 50%;
        transform: translateX(-50%);
        font-size: 0.75rem;
        color: #757575;
        white-space: nowrap;
    }
    
    /* Mastery Circle */
    .mastery-circle {
        position: relative;
        width: 200px;
        height: 200px;
        margin: 0 auto;
    }
    
    .mastery-circle svg {
        width: 100%;
        height: 100%;
    }
    
    .mastery-content {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        text-align: center;
    }
    
    .mastery-value {
        font-size: 2.5rem;
        font-weight: bold;
        color: #212121;
        line-height: 1;
    }
    
    .mastery-text {
        font-size: 0.875rem;
        color: #757575;
        font-weight: 500;
        margin-top: 0.25rem;
    }
    
    .mastery-total {
        font-size: 0.75rem;
        color: #9e9e9e;
        margin-top: 0.25rem;
    }
    
    /* Mastery Legend */
    .mastery-legend {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }
    
    .legend-row {
        display: flex;
        align-items: center;
        gap: 1rem;
    }
    
    .legend-indicator {
        width: 24px;
        height: 24px;
        border-radius: 50%;
    }
    
    .legend-indicator.learned {
        background: #4caf50;
    }
    
    .legend-indicator.revising {
        background: #ff9800;
    }
    
    .legend-indicator.need-help {
        background: #f44336;
    }
    
    .legend-indicator.todo {
        background: #e0e0e0;
    }
    
    .legend-label {
        flex: 1;
        font-weight: 500;
        color: #424242;
    }
    
    .legend-value {
        font-weight: 600;
        color: #212121;
    }
    
    /* Section Header */
    .section-header {
        margin-bottom: 1rem;
    }
    
    .section-header h5 {
        font-size: 1.125rem;
        font-weight: 600;
        color: #212121;
        margin: 0;
    }
    
    /* Unit Card */
    .unit-card {
        background: white;
        border-radius: 8px;
        border: 1px solid #e0e0e0;
        padding: 1.25rem;
        transition: all 0.3s ease;
    }
    
    .unit-card:hover {
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        transform: translateY(-2px);
    }
    
    .unit-card-header {
        display: flex;
        justify-content: space-between;
        align-items: flex-start;
        margin-bottom: 1rem;
    }
    
    .unit-name {
        font-weight: 600;
        color: #212121;
        flex: 1;
        line-height: 1.4;
        font-size: 0.9375rem;
    }
    
    .unit-percent {
        padding: 0.25rem 0.75rem;
        border-radius: 12px;
        font-weight: 600;
        font-size: 0.875rem;
        margin-left: 0.75rem;
    }
    
    .unit-percent.learned {
        background: #e8f5e9;
        color: #2e7d32;
    }
    
    .unit-percent.not-started {
        background: #f5f5f5;
        color: #757575;
    }
    
    .unit-progress-bar {
        height: 8px;
        background: #f5f5f5;
        border-radius: 4px;
        overflow: hidden;
        display: flex;
        margin-bottom: 1rem;
    }
    
    .unit-progress-segment {
        height: 100%;
        transition: width 0.3s ease;
    }
    
    .unit-progress-segment.learned {
        background: #4caf50;
    }
    
    .unit-progress-segment.revising {
        background: #ff9800;
    }
    
    .unit-progress-segment.need-help {
        background: #f44336;
    }
    
    .unit-progress-segment.todo {
        background: #e0e0e0;
    }
    
    .unit-stats {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        margin-bottom: 1rem;
    }
    
    .stat-row {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-size: 0.8125rem;
        color: #424242;
    }
    
    .stat-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
    }
    
    .stat-dot.learned {
        background: #4caf50;
    }
    
    .stat-dot.revising {
        background: #ff9800;
    }
    
    .stat-dot.need-help {
        background: #f44336;
    }
    
    .stat-dot.todo {
        background: #e0e0e0;
    }
    
    .stat-label {
        color: #757575;
    }
    
    .btn-unit-focus {
        width: 100%;
        padding: 0.625rem 1rem;
        border: 2px solid #1976d2;
        background: white;
        color: #1976d2;
        border-radius: 4px;
        font-weight: 600;
        cursor: pointer;
        transition: all 0.3s ease;
    }
    
    .btn-unit-focus:hover {
        background: #1976d2;
        color: white;
    }
    
    /* Units Tabs */
    .units-tabs-container {
        background: white;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        padding: 0.75rem;
    }
    
    .units-tabs {
        display: flex;
        gap: 0.5rem;
        overflow-x: auto;
    }
    
    .unit-tab {
        padding: 0.875rem 1.5rem;
        border: none;
        background: transparent;
        border-radius: 6px;
        font-weight: 500;
        color: #757575;
        cursor: pointer;
        transition: all 0.3s ease;
        white-space: nowrap;
    }
    
    .unit-tab:hover {
        background: #f5f5f5;
    }
    
    .unit-tab.active {
        background: linear-gradient(135deg, #5e35b1 0%, #7b1fa2 100%);
        color: white;
    }
    
    /* Unit Content */
    .unit-content {
        display: none;
    }
    
    .unit-content.active {
        display: block;
    }
    
    /* Topic Card */
    .topic-card {
        background: white;
        border-radius: 8px;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
        margin-bottom: 1rem;
        overflow: hidden;
    }
    
    .topic-header {
        padding: 1.25rem 1.5rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        cursor: pointer;
        transition: background 0.2s ease;
    }
    
    .topic-header:hover {
        background: #fafafa;
    }
    
    .topic-left {
        display: flex;
        align-items: center;
        gap: 1rem;
        flex: 1;
    }
    
    .topic-drag-handle {
        color: #bdbdbd;
        cursor: grab;
        font-size: 1.125rem;
    }
    
    .topic-title {
        font-weight: 600;
        color: #212121;
        font-size: 1rem;
    }
    
    .topic-right {
        display: flex;
        align-items: center;
        gap: 1rem;
    }
    
    .topic-badge {
        padding: 0.375rem 0.875rem;
        background: linear-gradient(135deg, #5e35b1 0%, #7b1fa2 100%);
        color: white;
        border-radius: 20px;
        font-size: 0.8125rem;
        font-weight: 600;
    }
    
    .topic-toggle {
        color: #757575;
        transition: transform 0.3s ease;
    }
    
    .topic-card.expanded .topic-toggle {
        transform: rotate(180deg);
    }
    
    /* Topic Content */
    .topic-content {
        padding: 0 1.5rem 1.5rem 1.5rem;
    }
    
    /* Learning Objective */
    .learning-objective {
        display: flex;
        align-items: flex-start;
        gap: 1rem;
        padding: 1rem;
        border-radius: 6px;
        margin-bottom: 0.75rem;
        transition: all 0.2s ease;
    }
    
    .learning-objective:hover {
        background: #f5f5f5;
    }
    
    .learning-objective.learned {
        background: #e8f5e9;
    }
    
    .learning-objective.learned:hover {
        background: #c8e6c9;
    }
    
    .learning-objective.revising {
        background: #fff3e0;
    }
    
    .learning-objective.revising:hover {
        background: #ffe0b2;
    }
    
    .learning-objective.need-help {
        background: #ffebee;
    }
    
    .learning-objective.need-help:hover {
        background: #ffcdd2;
    }
    
    .objective-checkbox {
        flex-shrink: 0;
        font-size: 1.25rem;
    }
    
    .learning-objective.learned .objective-checkbox {
        color: #4caf50;
    }
    
    .learning-objective.revising .objective-checkbox {
        color: #ff9800;
    }
    
    .learning-objective.need-help .objective-checkbox {
        color: #f44336;
    }
    
    .learning-objective.todo .objective-checkbox {
        color: #e0e0e0;
    }
    
    .objective-text {
        flex: 1;
        color: #212121;
        line-height: 1.6;
    }
    
    .learning-objective.learned .objective-text {
        text-decoration: line-through;
        color: #2e7d32;
    }
    
    .objective-status {
        flex-shrink: 0;
    }
    
    .status-dropdown {
        padding: 0.375rem 0.75rem;
        border: 1px solid #e0e0e0;
        border-radius: 4px;
        background: white;
        font-size: 0.8125rem;
        font-weight: 500;
        cursor: pointer;
        transition: all 0.2s ease;
    }
    
    .status-dropdown.learned {
        border-color: #4caf50;
        color: #2e7d32;
    }
    
    .status-dropdown.revising {
        border-color: #ff9800;
        color: #e65100;
    }
    
    .status-dropdown.need-help {
        border-color: #f44336;
        color: #c62828;
    }
    
    .status-dropdown.todo {
        border-color: #e0e0e0;
        color: #757575;
    }
    
    .status-dropdown:focus {
        outline: none;
        box-shadow: 0 0 0 3px rgba(25, 118, 210, 0.1);
    }
    
    /* Responsive */
    @media (max-width: 991px) {
        .action-bar {
            flex-direction: column;
            align-items: flex-start;
        }
        
        .subject-header-card {
            flex-direction: column;
            align-items: flex-start;
        }
        
        .mastery-badge {
            text-align: left;
        }
    }
    
    @media (max-width: 576px) {
        .subject-tabs {
            flex-direction: column;
        }
        
        .subject-tab {
            justify-content: center;
        }
        
        .units-tabs {
            flex-direction: column;
        }
        
        .topic-left {
            flex-direction: column;
            align-items: flex-start;
            gap: 0.5rem;
        }
        
        .topic-right {
            flex-direction: column;
            gap: 0.5rem;
        }
        
        .learning-objective {
            flex-direction: column;
            gap: 0.75rem;
        }
    }
}
