body, html {
    margin: 0;
    padding: 0;
    height: 100vh;
    width: 100vw;
    overflow: hidden !important;
}

.app-workspace {
    display: flex;
    height: calc(100vh - 72px); 
    overflow: hidden;
}

.curriculum-sidebar {
    width: 380px;
    background-color: #242b3d;
    border-right: 1px solid #334155;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    height: 100%; 
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #334155;
}

.sidebar-header h2 {
    font-size: 15px;
    color: #60a5fa;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tree-menu {
    padding: 15px 10px;
    overflow-y: auto;
    flex: 1;
}

.chapter-node {
    margin-bottom: 15px;
}

.chapter-node > summary {
    font-size: 15px;
    font-weight: 700;
    color: #ffffff;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 6px;
    list-style: none;
}

.chapter-node > summary:hover {
    background-color: #1e2538;
}

.section-node {
    margin-left: 15px;
    margin-top: 6px;
}

.section-node > summary {
    font-size: 14px;
    font-weight: 600;
    color: #cbd5e1;
    cursor: pointer;
    padding: 6px 8px;
    list-style: none;
}

.lesson-nodes-list {
    list-style: none;
    margin-left: 25px;
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lesson-link {
    display: flex;
    align-items: center;
    gap: 18px; 
    width: 100%;
    text-align: left;
    background: none;
    border: none;
    padding: 10px 12px; 
    font-size: 14px;
    color: #94a3b8;
    cursor: pointer;
    border-radius: 6px;
}

.lesson-link:hover {
    color: #ffffff;
    background-color: #1e2538;
}

.lesson-link.active {
    color: #ffffff;
    background-color: #2b61ff;
    font-weight: 600;
}

.locked-node {
    opacity: 0.4;
    cursor: not-allowed;
}

.sidebar-placeholder-text {
    padding: 10px 15px;
    font-size: 12.5px;
    color: #64748b;
    font-style: italic;
}

.content-runner-body {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
    background-color: #1a1f2c;
    max-height: calc(100vh - 72px);
    display: flex;
    flex-direction: column;
    align-items: center;
}

#lesson-ajax-target {
    width: 100%;
    max-width: 800px;
    display: flex;
    flex-direction: column;
}

.breadcrumb {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    margin-bottom: 12px;
}

.lesson-header-meta {
    margin-bottom: 25px;
}

.lesson-article-text p {
    font-size: 16.5px;
    color: #cbd5e1;
    margin-bottom: 20px;
    line-height: 1.65;
}

.image-wrapper img {
    object-fit: cover;
}

@media (max-width: 768px) {
    .app-workspace {
        flex-direction: column;
    }
    .curriculum-sidebar {
        width: 100%;
        max-height: 240px;
        border-right: none;
        border-bottom: 1px solid #334155;
    }
    .content-runner-body {
        max-height: none;
        padding: 24px;
    }
}

.lesson-gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    margin: 35px 0;
    width: 100% !important;     
}

.lesson-gallery-grid .image-wrapper {
    margin: 0 !important;
    width: 100% !important;     
    display: flex !important;
    flex-direction: column;
    background-color: #242b3d;
    border: 1px solid #334155;
    border-radius: 12px;
    overflow: hidden;
}

.lesson-gallery-grid .image-wrapper img {
    width: 100% !important;
    object-fit: cover !important;
    display: block;
}

.lesson-gallery-grid .media-caption {
    padding: 16px;
    font-size: 14px;
    color: #94a3b8;
    background-color: #242b3d;
    border-top: 1px solid #334155;
    flex-grow: 1;
}

@media (min-width: 768px) {
    .lesson-gallery-grid {
        grid-template-columns: repeat(2, 1fr) !important; 
    }
}

.card-inner-title {
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    margin-bottom: 12px;
    text-align: center;
    width: 100%;
    letter-spacing: -0.3px;
}

.lesson-gallery-grid .media-caption p {
    font-size: 13.5px;
    line-height: 1.5;
    color: #94a3b8;
    margin: 0;
}

.lesson-link.completed-lesson {
    color: #34d399 !important;
}

.lesson-link.completed-lesson .format-icon {
    color: #34d399 !important; 
}

.lesson-link.completed-lesson.active {
    background-color: rgba(52, 211, 153, 0.12) !important;
    font-weight: 600;
}

.pincat-quiz-container {
    width: 100%;
    max-width: 850px;
    background-color: #1a233a;
    border: 1px solid #2b61ff;
    border-radius: 12px;
    padding: 28px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    margin: 20px auto;
    box-sizing: border-box;
}

.pincat-quiz-container .quiz-group {
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    margin: 0 !important;
}