* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #f5f7fa;
    color: #333;
}

.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

.user-switcher {
    position: relative;
    cursor: pointer;
}

.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 200px;
    display: none;
    z-index: 1000;
    margin-top: 8px;
}

.user-dropdown.show {
    display: block;
}

.user-option {
    padding: 12px 16px;
    border-bottom: 1px solid #e2e8f0;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.user-option:last-child {
    border-bottom: none;
}

.user-option:hover {
    background-color: #f7fafc;
}

.user-option.active {
    background-color: #ebf8ff;
}

.user-option-name {
    font-weight: 500;
    color: #2d3748;
}

.user-option-email {
    font-size: 0.75rem;
    color: #666;
    margin-top: 2px;
}

.user-option-role {
    font-size: 0.75rem;
    color: #667eea;
    margin-top: 2px;
}

/* Avatar styling for different users */
.user-avatar.professor {
    background: rgb(255 131 249 / 78%);
}


.container {
    max-width: 1300px;
    margin: 0 auto;
    padding: 2rem;
}

.assignment-header {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.assignment-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #2d3748;
}

.assignment-meta {
    display: flex;
    gap: 2rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: #666;
}

.due-date {
    background: #fef5e7;
    color: #d69e2e;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
}


.due-date.submitted {
    background: #c6f6d5;
    color: #38a169;
}

.due-date.upcoming {
    background: #c6f6d5;
    color: #38a169;
}

.main-content {
    display: block;
    position: relative;
    width: 100%;
}

.document-viewer {
    background: white;
    border-radius: 12px;
    overflow: visible;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    width: 100%;
    position: relative;
}

.viewer-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar {
    position: fixed;
    top: 0;
    right: -400px;
    width: 400px;
    height: 100vh;
    background: #f5f7fa;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 2rem 1.5rem;
    box-shadow: -4px 0 20px rgba(0,0,0,0.1);
    transition: right 0.3s ease;
    z-index: 1000;
    overflow-y: auto;
}

.sidebar.open {
    right: 0;
}

.sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.sidebar-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #2d3748;
}

.close-drawer-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.close-drawer-btn:hover {
    background: #e2e8f0;
    color: #2d3748;
}

.open-drawer-btn {
    position: fixed;
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
    background: #667eea;
    color: white;
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
    transition: all 0.2s ease;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.open-drawer-btn:hover {
    background: #5a67d8;
    transform: translateY(-50%) scale(1.05);
}

.open-drawer-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

.download-btn {
    background: #48bb78;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    display: none;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s ease;
}

.download-btn:hover {
    background: #38a169;
}

.download-btn.visible {
    display: flex;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.card-title {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #2d3748;
}

.upload-area {
    border: 2px dashed #cbd5e0;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.upload-area:hover {
    border-color: #667eea;
    background-color: #f7fafc;
}

.upload-area.dragover {
    border-color: #667eea;
    background-color: #ebf8ff;
}

.upload-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 1rem;
    background: #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-input {
    display: none;
}

.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    justify-content: center;
}

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

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

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

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


.btn-success {
    background: #48bb78;
    color: white;
}

.btn-success:hover {
    background: #38a169;
}

.version-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.version-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: #f7fafc;
    border-radius: 6px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.version-item:hover {
    background: #edf2f7;
}

.version-item.active {
    background: #ebf8ff;
    border: 1px solid #667eea;
}

.version-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.version-name {
    font-weight: 500;
    font-size: 0.875rem;
}

.version-date {
    font-size: 0.75rem;
    color: #666;
}

.version-author {
    font-size: 0.75rem;
    color: #667eea;
    font-style: italic;
}

.version-latest-label {
    background: #48bb78;
    color: white;
    font-size: 0.6rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    letter-spacing: 0.5px;
    margin-left: 0.5rem;
}

.version-download-btn {
    background: none;
    border: none;
    color: #667eea;
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    opacity: 0.7;
}

.version-download-btn:hover {
    background: #f0f4ff;
    color: #5a67d8;
    opacity: 1;
}

.version-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}


.empty-state {
    text-align: center;
    padding: 3rem;
    color: #666;
}

.empty-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 1rem;
    background: #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

#superdoc-toolbar {
    border-bottom: 1px solid #e2e8f0;
}

#superdoc {
    display: flex;
    justify-content: center;
    background-color: white;
    overflow: visible;
    min-height: 600px;
}

.submission-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 1rem;
    padding: 1rem;
    border-radius: 8px;
    font-weight: 500;
}

.status-pending {
    background: #fef5e7;
    color: #d69e2e;
}

.status-submitted {
    background: #c6f6d5;
    color: #38a169;
}

@media (max-width: 768px) {
    .assignment-meta {
        flex-direction: column;
        gap: 1rem;
    }
    
    .container {
        padding: 1rem;
    }
    
    .sidebar {
        width: 100vw;
        right: -100vw;
    }
    
    .open-drawer-btn {
        right: 15px;
        width: 45px;
        height: 45px;
    }
}

.superdoc__right-sidebar {
    background-color: transparent !important;
}

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