:root {
    --primary: #1e88e5;
    --primary-dark: #1565c0;
    --secondary: #ff6d00;
    --light: #f5f7fa;
    --dark: #263238;
    --gray: #78909c;
    --success: #43a047;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI',Tahoma,Geneva,Verdana,sans-serif;
}

body {
    background-color: #f9f9f9;
    color: #333;
    line-height: 1.6;
    display: flex;
    min-height: 100vh;
    flex-direction: column;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 60px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    position: relative;
}

    .section-title h2 {
        font-size: 2.2rem;
        color: var(--dark);
        margin-bottom: 15px;
    }

    .section-title p {
        color: var(--gray);
        max-width: 700px;
        margin: 0 auto;
        font-size: 1.1rem;
    }

    .section-title::after {
        content: '';
        position: absolute;
        bottom: -15px;
        left: 50%;
        transform: translateX(-50%);
        width: 70px;
        height: 4px;
        background: var(--primary);
        border-radius: 2px;
    }

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary);
    color: white;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

    .btn:hover {
        background: var(--primary-dark);
        transform: translateY(-3px);
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }

.btn-secondary {
    background: var(--secondary);
}

    .btn-secondary:hover {
        background: #e65100;
    }

header {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo {
    display: flex;
    align-items: center;
}

    .logo img {
        height: 40px;
        margin-right: 10px;
    }

    .logo h1 {
        font-size: 1.5rem;
        color: var(--primary);
        font-weight: 700;
    }

.nav-links {
    display: flex;
    list-style: none;
}

    .nav-links li {
        margin-left: 30px;
    }

    .nav-links a {
        text-decoration: none;
        color: var(--dark);
        font-weight: 500;
        font-size: 1.05rem;
        transition: color 0.3s;
        position: relative;
    }

        .nav-links a:hover {
            color: var(--primary);
        }

        .nav-links a::after {
            content: '';
            position: absolute;
            bottom: -5px;
            left: 0;
            width: 0;
            height: 2px;
            background: var(--primary);
            transition: width 0.3s;
        }

        .nav-links a:hover::after {
            width: 100%;
        }

footer {
    background: var(--dark);
    color: white;
    padding: 60px 0 30px;
    margin-top: auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h3 {
    font-size: 1.3rem;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 10px;
}

    .footer-col h3::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 50px;
        height: 2px;
        background: var(--primary);
    }

.footer-links {
    list-style: none;
}

    .footer-links li {
        margin-bottom: 15px;
    }

    .footer-links a {
        color: #b0bec5;
        text-decoration: none;
        transition: color 0.3s;
    }

        .footer-links a:hover {
            color: white;
        }

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

    .social-links a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        background: rgba(255,255,255,0.1);
        border-radius: 50%;
        color: white;
        transition: all 0.3s;
    }

        .social-links a:hover {
            background: var(--primary);
            transform: translateY(-3px);
        }

.copyright {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: #b0bec5;
    font-size: 0.9rem;
}

@media (max-width:768px) {
    .nav-links {
        display: none;
    }

    .section-title h2 {
        font-size: 1.8rem;
    }
}

.week-header-integrated {
    background: linear-gradient(135deg,rgba(30,136,229,0.9) 0%,rgba(33,150,243,0.9) 100%),url('https://images.unsplash.com/photo-1542831371-29b0f74f9713?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1200&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 10px 0 10px;
    text-align: center;
}

.breadcrumb {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 1rem;
}

    .breadcrumb a {
        color: rgba(255,255,255,0.8);
        text-decoration: none;
        transition: color 0.3s;
    }

        .breadcrumb a:hover {
            color: white;
        }

    .breadcrumb span {
        margin: 0 10px;
        color: rgba(255,255,255,0.6);
    }

.week-header h1 {
    font-size: 2.8rem;
    margin-bottom: 15px;
    font-weight: 800;
}

.week-header p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 30px;
    opacity: 0.9;
}

.side-nav {
    width: 280px;
    background: white;
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
    padding: 20px 0;
/*    position: fixed;*/
    position:absolute;
    height: 100vh;
/*    overflow-y: auto;*/
    z-index: 900;
}

.nav-header {
    padding: 20px 25px;
    border-bottom: 1px solid #eee;
}

    .nav-header h2 {
        color: var(--primary);
        font-size: 1.5rem;
        margin-bottom: 10px;
    }

    .nav-header p {
        color: var(--gray);
        font-size: 0.9rem;
    }

.day-links {
    list-style: none;
    padding: 15px 0;
}

    .day-links li {
        margin: 5px 0;
    }

    .day-links a {
        display: block;
        padding: 12px 25px;
        text-decoration: none;
        color: var(--dark);
        transition: all 0.3s;
        border-left: 4px solid transparent;
    }

        .day-links a:hover {
            background: rgba(30,136,229,0.05);
            color: var(--primary);
        }

        .day-links a.active {
            background: rgba(30,136,229,0.1);
            color: var(--primary);
            border-left: 4px solid var(--primary);
            font-weight: 600;
        }

.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: white;
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border-radius: 8px;
    z-index: 1;
    top: 100%;
    left: 0;
    padding: 10px 0;
}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown-content a {
    display: block;
    padding: 10px 20px;
    color: var(--dark);
    text-decoration: none;
    transition: all 0.2s;
}

    .dropdown-content a:hover {
        background: rgba(74,110,224,0.05);
        color: var(--primary);
    }

.main-content {
    flex: 1;
    margin-left: 280px;
    padding: 30px 40px;
    background: #f9f9f9;
}

.day-section {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    padding: 40px;
    margin-bottom: 40px;
    transition: all 0.3s;
}

    .day-section:hover {
        box-shadow: 0 8px 30px rgba(0,0,0,0.12);
    }

.day-header {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

    .day-header h2 {
        font-size: 1.8rem;
        color: var(--primary);
        margin-bottom: 10px;
        display: flex;
        align-items: center;
    }

        .day-header h2 i {
            margin-right: 15px;
        }

    .day-header p {
        color: var(--gray);
        font-size: 1.1rem;
        max-width: 800px;
    }

.learning-goal {
    background: rgba(30,136,229,0.05);
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 30px;
    border-left: 4px solid var(--primary);
}

    .learning-goal h3 {
        color: var(--primary);
        margin-bottom: 15px;
        display: flex;
        align-items: center;
    }

        .learning-goal h3 i {
            margin-right: 10px;
        }

.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.content-card {
    background: rgba(30,136,229,0.03);
    border-radius: 10px;
    padding: 25px;
    border: 1px solid #e0e0e0;
    transition: all 0.3s;
}

    .content-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 20px rgba(0,0,0,0.1);
        border-color: var(--primary);
    }

    .content-card h3 {
        color: var(--primary);
        margin-bottom: 15px;
        display: flex;
        align-items: center;
    }

        .content-card h3 i {
            margin-right: 10px;
        }

.resource-list {
    list-style: none;
    padding-left: 0;
}

    .resource-list li {
        margin-bottom: 12px;
        padding-left: 25px;
        position: relative;
    }

        .resource-list li::before {
            content: '•';
            position: absolute;
            left: 10px;
            color: var(--primary);
            font-weight: bold;
        }

.practice-card {
    background: rgba(255,109,0,0.05);
    border-radius: 10px;
    padding: 25px;
    border-left: 4px solid var(--secondary);
    margin-top: 30px;
}

    .practice-card h3 {
        color: var(--secondary);
        margin-bottom: 15px;
        display: flex;
        align-items: center;
    }

        .practice-card h3 i {
            margin-right: 10px;
        }

.tip-box {
    background: rgba(67,160,71,0.05);
    border-radius: 10px;
    padding: 20px;
    margin-top: 30px;
    border-left: 4px solid var(--success);
}

    .tip-box h3 {
        color: var(--success);
        margin-bottom: 10px;
        display: flex;
        align-items: center;
    }

        .tip-box h3 i {
            margin-right: 10px;
        }

@media (max-width:992px) {
    .side-nav {
        width: 220px;
    }

    .main-content {
        margin-left: 220px;
        padding: 20px;
    }

    .day-section {
        padding: 30px;
    }
}

@media (max-width:768px) {
    body {
        flex-direction: column;
    }

    .side-nav {
        position: static;
        width: 100%;
        height: auto;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }

    .main-content {
        margin-left: 0;
        padding: 20px 15px;
    }

    .day-section {
        padding: 20px;
    }
}

.content-container {
    display: flex;
    min-height: calc(100vh - 200px);
}

.step-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.step {
    flex: 1;
    min-width: 300px;
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 3px 15px rgba(0,0,0,0.1);
    transition: all 0.3s;
}

    .step:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    }

.step-number {
    display: inline-block;
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    font-weight: bold;
    margin-bottom: 15px;
}

.step-title {
    font-size: 1.3rem;
    color: var(--primary);
    margin-bottom: 15px;
}

.code-block {
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
    font-family: 'Courier New',monospace;
    font-size: 0.95rem;
    overflow-x: auto;
}

.screenshot {
    width: 100%;
    border-radius: 8px;
    border: 1px solid #eee;
    margin: 15px 0;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
}

.note-box {
    background: #fff8e1;
    border-left: 4px solid #ffc107;
    padding: 15px;
    margin: 15px 0;
    border-radius: 0 8px 8px 0;
}

.warning-box {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 15px 0;
    border-radius: 0 8px 8px 0;
}

.key-point {
    color: var(--primary);
    font-weight: bold;
}

.hero {
    background: linear-gradient(135deg,rgba(33,150,243,0.9) 0%,rgba(30,136,229,0.9) 100%);
    color: white;
    padding: 80px 0 60px;
    text-align: center;
    margin-bottom: 40px;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 20px;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.hero p {
    font-size: 1.3rem;
    opacity: 0.9;
    margin-bottom: 30px;
}

.program-container {
    display: flex;
    gap: 30px;
    margin-bottom: 50px;
}

.code-explanation {
    flex: 1;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    padding: 30px;
}

.code-block {
    flex: 1;
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 15px;
    padding: 25px;
    font-family: 'Courier New',monospace;
    font-size: 1.1rem;
    line-height: 1.8;
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    position: relative;
}

.code-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    color: #f8f8f2;
}

.code-line {
    display: flex;
    margin-bottom: 12px;
}

.line-number {
    color: #75715e;
    min-width: 40px;
    text-align: right;
    padding-right: 15px;
    user-select: none;
}

.code-keyword {
    color: #f92672;
}

.code-class {
    color: #a6e22e;
}

.code-method {
    color: #66d9ef;
}

.code-string {
    color: #e6db74;
}

.code-comment {
    color: #75715e;
}

.highlight {
    background: rgba(255,215,0,0.15);
    border-left: 3px solid gold;
    padding: 3px 0 3px 10px;
    margin: 3px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
    position: relative;
}

    .section-title h2 {
        font-size: 2.2rem;
        color: var(--primary);
        margin-bottom: 15px;
    }

    .section-title p {
        color: var(--gray);
        max-width: 700px;
        margin: 0 auto;
        font-size: 1.1rem;
    }

    .section-title::after {
        content: '';
        position: absolute;
        bottom: -15px;
        left: 50%;
        transform: translateX(-50%);
        width: 70px;
        height: 4px;
        background: var(--primary);
        border-radius: 2px;
    }

.step-container {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    margin-bottom: 40px;
}

.step {
    flex: 1;
    min-width: 300px;
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s;
    border-top: 4px solid var(--primary);
}

    .step:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    }

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    font-weight: bold;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.step-title {
    font-size: 1.4rem;
    color: var(--dark);
    margin-bottom: 15px;
}

.tip-box {
    background: rgba(67,160,71,0.05);
    border-radius: 10px;
    padding: 20px;
    margin: 30px 0;
    border-left: 4px solid var(--success);
}

.warning-box {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0;
}

.practice-card {
    background: rgba(255,109,0,0.05);
    border-radius: 10px;
    padding: 25px;
    border-left: 4px solid var(--secondary);
    margin: 40px 0;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 30px;
    margin: 40px 0;
}

.content-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: all 0.3s;
    border-top: 3px solid var(--primary);
}

    .content-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    }

.resource-list {
    list-style: none;
    padding-left: 0;
}

    .resource-list li {
        margin-bottom: 12px;
        padding-left: 25px;
        position: relative;
    }

        .resource-list li::before {
            content: '•';
            position: absolute;
            left: 10px;
            color: var(--primary);
            font-weight: bold;
        }

.btn {
    display: inline-block;
    padding: 12px 30px;
    background: var(--primary);
    color: white;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    margin: 10px 5px;
}

    .btn:hover {
        background: var(--primary-dark);
        transform: translateY(-3px);
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    }

.btn-secondary {
    background: var(--secondary);
}

    .btn-secondary:hover {
        background: #e65100;
    }

.output-window {
    background: #1e1e1e;
    color: #d4d4d4;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

.console-prompt {
    color: #4EC9B0;
}

.console-output {
    color: #DCDCAA;
}

.screenshot {
    width: 100%;
    border-radius: 8px;
    border: 1px solid #eee;
    margin: 20px 0;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

@media (max-width:768px) {
    .program-container {
        flex-direction: column;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .section-title h2 {
        font-size: 1.8rem;
    }
}

.operator-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(320px,1fr));
    gap: 25px;
    margin: 30px 0;
}

.operator-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary);
}

    .operator-card:hover {
        transform: translateY(-7px);
        box-shadow: 0 12px 30px rgba(0,0,0,0.15);
    }

.operator-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.operator-icon {
    width: 50px;
    height: 50px;
    background: rgba(30,136,229,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--primary);
    font-size: 1.5rem;
}

.operator-examples {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
    border-left: 3px solid var(--primary);
}

.conversion-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

    .conversion-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left;
    }

    .conversion-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
    }

    .conversion-table tr:nth-child(even) {
        background: #f9f9f9;
    }

    .conversion-table tr:hover {
        background: rgba(30,136,229,0.05);
    }

.conversion-arrow {
    text-align: center;
    font-size: 1.5rem;
    color: var(--primary);
}

.interactive-box {
    background: linear-gradient(135deg,#f5f7fa 0%,#e4e8f0 100%);
    border-radius: 15px;
    padding: 30px;
    margin: 40px 0;
    text-align: center;
    border: 1px dashed var(--primary);
}

.input-group {
    display: flex;
    max-width: 600px;
    margin: 20px auto;
    gap: 10px;
}

    .input-group input {
        flex: 1;
        padding: 12px 15px;
        border: 1px solid #ddd;
        border-radius: 8px;
        font-size: 1rem;
    }

.output-panel {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
    min-height: 100px;
    text-align: left;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.05);
}

.priority-list {
    list-style-type: none;
    counter-reset: priority-counter;
    padding-left: 0;
}

    .priority-list li {
        margin-bottom: 15px;
        padding: 15px;
        background: white;
        border-radius: 8px;
        box-shadow: 0 3px 10px rgba(0,0,0,0.05);
        position: relative;
        padding-left: 60px;
    }

        .priority-list li:before {
            counter-increment: priority-counter;
            content: counter(priority-counter);
            position: absolute;
            left: 15px;
            top: 50%;
            transform: translateY(-50%);
            width: 36px;
            height: 36px;
            background: var(--primary);
            color: white;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            font-weight: bold;
            font-size: 1.1rem;
        }

.type-conversion-diagram {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin: 30px 0;
}

.type-box {
    padding: 15px 25px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    font-weight: bold;
    position: relative;
}

    .type-box.primary {
        background: var(--primary);
        color: white;
    }

.arrow {
    font-size: 1.5rem;
    color: var(--primary);
}

.method-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

    .method-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left;
    }

    .method-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
    }

    .method-table tr:nth-child(even) {
        background: #f9f9f9;
    }

    .method-table tr:hover {
        background: rgba(30,136,229,0.05);
    }

.type-example {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-top: 15px;
    border-left: 3px solid var(--primary);
}

.interactive-demo {
    background: linear-gradient(135deg,#f5f7fa 0,#e4e8f0 100%);
    border-radius: 15px;
    padding: 30px;
    margin: 40px 0;
    text-align: center;
    border: 1px dashed var(--primary);
}

.input-group {
    display: flex;
    max-width: 600px;
    margin: 20px auto;
    gap: 10px;
}

    .input-group input {
        flex: 1;
        padding: 12px 15px;
        border: 1px solid #ddd;
        border-radius: 8px;
        font-size: 1rem;
    }

.output-panel {
    background: white;
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
    min-height: 100px;
    text-align: left;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.05);
}

.input-output-flow {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin: 30px 0;
}

.flow-box {
    padding: 15px 25px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    font-weight: bold;
    position: relative;
}

    .flow-box.primary {
        background: var(--primary);
        color: white;
    }

.arrow {
    font-size: 1.5rem;
    color: var(--primary);
}

.icon-large {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--primary);
}

.scanner-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 20px;
    margin: 30px 0;
}

.method-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    border-top: 3px solid var(--primary);
}

    .method-card h4 {
        color: var(--primary);
        margin-bottom: 10px;
    }

.method-signature {
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 6px;
    padding: 10px;
    font-family: 'Courier New',monospace;
    margin: 10px 0;
    font-size: 0.9rem;
}

.quiz-section {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.quiz-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.quiz-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    margin-right: 15px;
}

.quiz-question {
    font-size: 1.2rem;
    margin-bottom: 20px;
    line-height: 1.6;
}

.quiz-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.quiz-option {
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    padding-left: 50px;
}

    .quiz-option:hover {
        border-color: var(--primary);
        background: rgba(30,136,229,0.05);
    }

    .quiz-option.selected {
        border-color: var(--primary);
        background: rgba(30,136,229,0.1);
    }

    .quiz-option input {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        width: 20px;
        height: 20px;
    }

    .quiz-option label {
        cursor: pointer;
        display: block;
    }

.quiz-feedback {
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.feedback-correct {
    background: rgba(67,160,71,0.1);
    border-left: 4px solid var(--success);
}

.feedback-incorrect {
    background: rgba(244,67,54,0.1);
    border-left: 4px solid #f44336;
}

.bmi-calculator {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    margin: 30px 0;
}

.bmi-inputs {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.input-group {
    display: flex;
    flex-direction: column;
}

    .input-group label {
        margin-bottom: 8px;
        font-weight: 600;
        color: var(--dark);
    }

    .input-group input {
        padding: 12px 15px;
        border: 1px solid #ddd;
        border-radius: 8px;
        font-size: 1rem;
    }

.bmi-result {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin-top: 20px;
}

.result-category {
    font-weight: bold;
    margin-top: 10px;
    padding: 8px 15px;
    border-radius: 20px;
    display: inline-block;
}

.underweight {
    background: #bbdefb;
    color: #0d47a1;
}

.normal {
    background: #c8e6c9;
    color: #1b5e20;
}

.overweight {
    background: #fff9c4;
    color: #f57f17;
}

.obese {
    background: #ffccbc;
    color: #bf360c;
}

.code-fill {
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    position: relative;
}

.fill-blank {
    display: inline-block;
    min-width: 100px;
    border-bottom: 2px dashed #f92672;
    margin: 0 5px;
    position: relative;
}

.fill-input {
    background: transparent;
    border: none;
    border-bottom: 2px solid #66d9ef;
    color: #f8f8f2;
    width: 100px;
    text-align: center;
    font-family: 'Courier New',monospace;
    font-size: 1rem;
}

.score-panel {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    text-align: center;
    margin: 30px 0;
}

.score-value {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary);
    margin: 20px 0;
}

.quiz-timer {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.timer-icon {
    margin-right: 10px;
    color: var(--primary);
}

.tab-container {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 2px solid #eee;
}

.tab-btn {
    padding: 12px 25px;
    background: #f5f7fa;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    transition: all 0.3s;
}

    .tab-btn.active {
        background: var(--primary);
        color: white;
        border-bottom: 3px solid var(--primary-dark);
    }

.tab-content.active {
    display: block;
}

.dark-code-block {
    background: #1e1e1e;
    color: #f8f8f2;
    border-radius: 8px;
    padding: 20px;
    margin: 15px 0;
    font-family: 'Courier New',monospace;
    font-size: 1rem;
    line-height: 1.6;
    overflow-x: auto;
}

.keyword {
    color: #f92672;
    font-weight: bold;
}

.string {
    color: #e6db74;
}

.comment {
    color: #75715e;
    font-style: italic;
}

.number {
    color: #ae81ff;
}

.method {
    color: #66d9ef;
}

.class {
    color: #a6e22e;
}

.inheritance-diagram {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.class-box {
    background: white;
    border: 2px solid var(--primary);
    border-radius: 8px;
    padding: 15px;
    margin: 10px;
    width: 250px;
    text-align: center;
    font-weight: bold;
}

.extends-arrow {
    font-size: 24px;
    color: var(--primary);
    margin: 10px 0;
}

.interface-box {
    background: white;
    border: 2px dashed var(--success);
    border-radius: 8px;
    padding: 15px;
    margin: 10px;
    width: 250px;
    text-align: center;
    font-weight: bold;
}

.implements-arrow {
    font-size: 24px;
    color: var(--success);
    margin: 10px 0;
}

.enum-example {
    background: rgba(255,193,7,0.1);
    border-left: 4px solid var(--warning);
    padding: 15px;
    margin: 15px 0;
    border-radius: 0 8px 8px 0;
}

.exception-flow {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.exception-box {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 12px;
    min-width: 120px;
    text-align: center;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

.exception-arrow {
    font-size: 20px;
    color: var(--error);
}

.project-diagram {
    display: flex;
    justify-content: center;
    margin: 30px 0;
}

.uml-diagram {
    max-width: 100%;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.knowledge-map {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(280px,1fr));
    gap: 20px;
    margin: 30px 0;
}

.knowledge-card {
    background: linear-gradient(135deg,#f5f7fa 0,#e4e8f0 100%);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #e0e0e0;
}

    .knowledge-card h4 {
        color: var(--primary);
        margin-bottom: 15px;
        border-bottom: 2px solid var(--primary);
        padding-bottom: 5px;
    }

.code-tabs {
    display: flex;
    background: #2d2d2d;
    border-radius: 8px 8px 0 0;
    overflow: hidden;
}

.code-tab {
    padding: 10px 20px;
    background: #3e3e3e;
    color: #ccc;
    cursor: pointer;
    border: none;
    font-size: 0.9rem;
}

    .code-tab.active {
        background: #2d2d2d;
        color: white;
    }

.type-boundary {
    background: rgba(67,160,71,0.1);
    border-left: 4px solid var(--success);
    padding: 20px;
    margin: 25px 0;
    border-radius: 8px
}

.wildcard-example {
    background: rgba(255,109,0,0.1);
    border-left: 4px solid var(--secondary);
    padding: 20px;
    margin: 25px 0;
    border-radius: 8px
}

.generics-comparison {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin: 25px 0
}

.comparison-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1)
}

.comparison-header {
    text-align: center;
    padding-bottom: 15px;
    border-bottom: 2px solid #eee;
    margin-bottom: 20px
}

.wildcard-diagram {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
    position: relative;
    overflow: hidden
}

.wildcard-header {
    margin-bottom: 20px;
    text-align: center;
    color: #1e88e5
}

.wildcard-types {
    display: grid;
    grid-template-columns: repeat(3,1fr);
    gap: 20px;
    margin-top: 20px
}

.wildcard-card {
    background: #f9f9f9;
    border-radius: 10px;
    padding: 20px;
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease
}

    .wildcard-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 20px rgba(0,0,0,0.1)
    }

    .wildcard-card.unbounded {
        border-top: 4px solid #78909c
    }

    .wildcard-card.upper-bounded {
        border-top: 4px solid #43a047
    }

    .wildcard-card.lower-bounded {
        border-top: 4px solid #ff6d00
    }

.wildcard-title {
    margin-top: 0;
    text-align: center
}

.wildcard-symbol {
    font-size: 1.8rem;
    font-weight: bold;
    text-align: center;
    margin: 10px 0
}

.erasure-explanation {
    background: rgba(67,160,71,0.08);
    border-left: 4px solid #1e88e5;
    padding: 25px;
    margin: 30px 0;
    border-radius: 8px
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08)
}

    .comparison-table th {
        background-color: #1e88e5;
        color: white;
        text-align: left;
        padding: 15px
    }

    .comparison-table td {
        padding: 15px;
        border-bottom: 1px solid #e0e0e0
    }

    .comparison-table tr:last-child td {
        border-bottom: none
    }

    .comparison-table tr:hover {
        background-color: #f5f9ff
    }

.iterator-methods {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 20px;
    margin: 30px 0
}

.method-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    border-top: 3px solid var(--primary)
}

    .method-card h4 {
        color: var(--primary);
        margin-bottom: 10px
    }

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05)
}

    .comparison-table th, .comparison-table td {
        padding: 15px;
        text-align: left;
        border-bottom: 1px solid #eee
    }

    .comparison-table th {
        background: var(--primary);
        color: white
    }

    .comparison-table tr:nth-child(even) {
        background: #f9f9f9
    }

    .comparison-table tr:hover {
        background: rgba(30,136,229,0.05)
    }

.code-fill {
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    position: relative
}

.fill-blank {
    display: inline-block;
    min-width: 100px;
    border-bottom: 2px dashed #f92672;
    margin: 0 5px;
    position: relative
}

.fill-input {
    background: transparent;
    border: none;
    border-bottom: 2px solid #66d9ef;
    color: #f8f8f2;
    width: 100px;
    text-align: center;
    font-family: 'Courier New',monospace;
    font-size: 1rem
}

.collection-diagram {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
    margin: 40px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px
}

.collection-box {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    min-width: 200px
}

    .collection-box h4 {
        color: var(--primary);
        margin-bottom: 15px
    }

    .collection-box ul {
        list-style: none;
        padding-left: 0
    }

    .collection-box li {
        padding: 8px;
        border-bottom: 1px dashed #eee
    }

.flow-diagram {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 30px 0
}

.flow-step {
    background: white;
    padding: 15px 25px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    margin: 10px 0;
    min-width: 300px;
    text-align: center;
    position: relative
}

    .flow-step:not(:last-child):after {
        content: '↓';
        position: absolute;
        bottom: -25px;
        font-size: 24px;
        color: var(--primary)
    }

.common-error {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 20px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

    .common-error h4 {
        color: #f44336;
        margin-bottom: 10px
    }

.best-practice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 25px;
    margin: 30px 0
}

.practice-card {
    display: flex;
    flex-direction: column;
    height: 100%
}

.practice-icon {
    font-size: 2.5rem;
    color: var(--success);
    margin-bottom: 15px;
    text-align: center
}

.quiz-container {
    background: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-bottom: 30px
}

.quiz-question {
    font-size: 1.2rem;
    margin-bottom: 20px;
    font-weight: 500
}

.quiz-options {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 15px;
    margin-bottom: 20px
}

.quiz-option {
    background: #f5f7fa;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease
}

    .quiz-option:hover {
        background: #e3f2fd;
        transform: translateY(-3px)
    }

    .quiz-option.selected {
        background: #bbdefb;
        border-left: 4px solid var(--primary)
    }

    .quiz-option input[type="radio"] {
        margin-right: 10px
    }

.quiz-feedback {
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    display: none
}

    .quiz-feedback.correct {
        background: #e8f5e9;
        border-left: 4px solid var(--success);
        display: block
    }

    .quiz-feedback.incorrect {
        background: #ffebee;
        border-left: 4px solid var(--error);
        display: block
    }

    .quiz-feedback h4 {
        margin-bottom: 10px;
        display: flex;
        align-items: center
    }

        .quiz-feedback h4 i {
            margin-right: 10px
        }

    .quiz-feedback.correct h4 {
        color: var(--success)
    }

    .quiz-feedback.incorrect h4 {
        color: var(--error)
    }

.quiz-submit {
    background: var(--primary);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1rem;
    transition: background 0.3s
}

    .quiz-submit:hover {
        background: var(--primary-dark)
    }

.quiz-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px
}

.quiz-number {
    background: var(--primary);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: bold;
    margin-right: 15px
}

.quiz-title {
    font-size: 1.5rem;
    color: var(--dark)
}

.quiz-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 30px;
    padding: 10px;
    background: #f5f7fa;
    border-radius: 5px
}

.progress-item {
    flex: 1;
    text-align: center;
    padding: 10px;
    cursor: pointer;
    transition: all 0.3s
}

    .progress-item.active {
        background: var(--primary);
        color: white;
        border-radius: 5px
    }

.quiz-result {
    text-align: center;
    padding: 30px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    display: none
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 20px
}

    .result-icon.success {
        color: var(--success)
    }

    .result-icon.warning {
        color: var(--warning)
    }

.result-score {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 20px
}

.result-message {
    font-size: 1.2rem;
    margin-bottom: 30px
}

.result-details {
    text-align: left;
    margin-top: 30px
}

    .result-details h3 {
        margin-bottom: 15px;
        color: var(--dark)
    }

.detail-item {
    margin-bottom: 10px;
    padding: 10px;
    background: #f5f7fa;
    border-radius: 5px
}

    .detail-item.correct {
        border-left: 4px solid var(--success)
    }

    .detail-item.incorrect {
        border-left: 4px solid var(--error)
    }

.quiz-restart {
    background: var(--primary);
    color: white;
    border: none;
    padding: 12px 30px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1rem;
    transition: background 0.3s;
    margin-top: 20px
}

    .quiz-restart:hover {
        background: var(--primary-dark)
    }

.map-comparison {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 25px;
    margin: 40px 0
}

.map-card {
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    border-top: 4px solid var(--primary);
    transition: transform 0.3s ease
}

    .map-card:hover {
        transform: translateY(-5px)
    }

    .map-card h3 {
        color: var(--primary);
        margin-bottom: 15px;
        display: flex;
        align-items: center
    }

        .map-card h3 i {
            margin-right: 10px;
            font-size: 1.5rem
        }

.map-structure {
    display: flex;
    justify-content: center;
    margin: 20px 0
}

.map-node {
    background: #e3f2fd;
    padding: 10px 15px;
    border-radius: 8px;
    margin: 0 5px;
    position: relative;
    min-width: 100px;
    text-align: center
}

    .map-node:not(:last-child)::after {
        content: '→';
        position: absolute;
        right: -15px;
        top: 50%;
        transform: translateY(-50%);
        color: var(--primary)
    }

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 40px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05)
}

    .comparison-table th, .comparison-table td {
        padding: 15px;
        text-align: left;
        border-bottom: 1px solid #eee
    }

    .comparison-table th {
        background: var(--primary);
        color: white
    }

    .comparison-table tr:nth-child(even) {
        background: #f9f9f9
    }

    .comparison-table tr:hover {
        background: rgba(30,136,229,0.05)
    }

.common-error {
    background: #ffebee;
    border-left: 4px solid #f44336;
    padding: 20px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

    .common-error h4 {
        color: #f44336;
        margin-bottom: 10px
    }

.best-practice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 25px;
    margin: 40px 0
}

.practice-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05)
}

.practice-icon {
    font-size: 2.5rem;
    color: var(--success);
    margin-bottom: 15px;
    text-align: center
}

.code-block {
    background: #2d2d2d;
    color: #f8f8f2;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    position: relative;
    overflow-x: auto
}

    .code-block pre {
        margin: 0
    }

    .code-block code {
        font-family: 'Courier New',monospace;
        font-size: 1rem;
        line-height: 1.5
    }

    .code-block .comment {
        color: #75715e
    }

    .code-block .keyword {
        color: #f92672
    }

    .code-block .string {
        color: #a6e22e
    }

    .code-block .class {
        color: #66d9ef
    }

    .code-block .method {
        color: #e6db74
    }

.map-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px
}

.map-box {
    background: white;
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    min-width: 200px;
    text-align: center
}

    .map-box h4 {
        color: var(--primary);
        margin-bottom: 10px
    }

    .map-box ul {
        list-style: none;
        padding-left: 0
    }

    .map-box li {
        padding: 8px;
        border-bottom: 1px dashed #eee
    }

.io-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05)
}

    .io-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left
    }

    .io-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee
    }

    .io-table tr:nth-child(even) {
        background: #f9f9f9
    }

    .io-table tr:hover {
        background: rgba(30,136,229,0.05)
    }

.stream-category {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 30px 0
}

.stream-card {
    flex: 1;
    min-width: 300px;
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border-top: 4px solid var(--primary)
}

    .stream-card:hover {
        transform: translateY(-7px);
        box-shadow: 0 12px 30px rgba(0,0,0,0.15)
    }

    .stream-card h3 {
        color: var(--primary);
        margin-bottom: 15px;
        padding-bottom: 10px;
        border-bottom: 1px solid #f0f0f0
    }

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0
}

    .comparison-table th, .comparison-table td {
        padding: 12px 15px;
        border: 1px solid #eee;
        text-align: left
    }

    .comparison-table th {
        background: var(--primary);
        color: white
    }

    .comparison-table tr:nth-child(even) {
        background: #f9f9f9
    }

.exception-box {
    background: rgba(244,67,54,0.1);
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

.hierarchy-diagram {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin: 30px 0;
    font-family: 'Courier New',monospace
}

.stream-diagram {
    background-color: #f9f9ff;
    border-radius: 10px;
    padding: 20px;
    margin: 25px 0;
    border-left: 4px solid #1e88e5;
    font-family: 'Courier New',monospace;
    line-height: 1.8
}

    .stream-diagram .keyword {
        color: #d73a49;
        font-weight: bold
    }

    .stream-diagram .class-name {
        color: #6f42c1;
        font-weight: bold
    }

.comparison-card {
    display: flex;
    gap: 25px;
    margin: 30px 0;
    flex-wrap: wrap
}

.card {
    flex: 1;
    min-width: 300px;
    background: white;
    border-radius: 10px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border-top: 4px solid
}

.card-buffered {
    border-top-color: #1e88e5
}

.card-conversion {
    border-top-color: #43a047
}

.card-print {
    border-top-color: #f44336
}

.card:hover {
    transform: translateY(-7px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15)
}

.card h3 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0f0
}

.card ul {
    padding-left: 20px
}

.card li {
    margin-bottom: 8px
}

.use-case {
    background: rgba(30,136,229,0.05);
    padding: 20px;
    border-radius: 10px;
    margin: 25px 0
}

.method-list {
    list-style: none;
    padding: 0
}

    .method-list li {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
        position: relative;
        padding-left: 35px
    }

        .method-list li:before {
            content: "→";
            position: absolute;
            left: 15px;
            color: #1e88e5
        }

.warning-box {
    background: rgba(244,67,54,0.08);
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

.serialization-diagram {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 20px;
    margin: 25px 0;
    font-family: 'Courier New',monospace;
    line-height: 1.8
}

    .serialization-diagram .keyword {
        color: #d73a49;
        font-weight: bold
    }

    .serialization-diagram .class-name {
        color: #6f42c1;
        font-weight: bold
    }

.serialization-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05)
}

    .serialization-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left
    }

    .serialization-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee
    }

    .serialization-table tr:nth-child(even) {
        background: #f9f9f9
    }

.warning-box {
    background: rgba(244,67,54,0.08);
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

.best-practice-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    margin: 20px 0;
    border-top: 4px solid var(--primary)
}

.review-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin: 30px 0;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    border-top: 4px solid var(--primary)
}

    .review-section h2 {
        color: var(--primary);
        padding-bottom: 15px;
        border-bottom: 1px solid #f0f0f0
    }

.concept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 20px;
    margin: 25px 0
}

.concept-card {
    background: #f9f9ff;
    border-radius: 10px;
    padding: 20px;
    border-left: 4px solid #1e88e5
}

.comparison-table {
    width: 100%;
    border-collapse: collapse;
    margin: 30px 0
}

    .comparison-table th, .comparison-table td {
        padding: 12px 15px;
        border: 1px solid #eee;
        text-align: left
    }

    .comparison-table th {
        background: var(--primary);
        color: white
    }

    .comparison-table tr:nth-child(even) {
        background: #f9f9f9
    }

.error-box {
    background: rgba(244,67,54,0.1);
    border-left: 4px solid #f44336;
    padding: 15px;
    margin: 20px 0;
    border-radius: 0 8px 8px 0
}

.test-question {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    margin: 25px 0;
    position: relative
}

    .test-question:before {
        content: "Q";
        position: absolute;
        left: 15px;
        top: 15px;
        width: 30px;
        height: 30px;
        background: var(--primary);
        color: white;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: bold
    }

.test-question-content {
    margin-left: 45px
}

.thread-state-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    gap: 20px;
    margin: 25px 0;
}

.state-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border-top: 4px solid var(--primary);
    transition: all 0.3s;
}

    .state-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

.state-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.state-icon {
    width: 40px;
    height: 40px;
    background: rgba(30,136,229,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--primary);
    font-size: 1.2rem;
}

.lifecycle-diagram {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.lifecycle-state {
    padding: 15px 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    min-width: 150px;
    text-align: center;
    font-weight: bold;
    position: relative;
}

    .lifecycle-state.new {
        border: 2px solid #9e9e9e;
    }

    .lifecycle-state.runnable {
        border: 2px solid #4caf50;
    }

    .lifecycle-state.blocked {
        border: 2px solid #ff9800;
    }

    .lifecycle-state.waiting {
        border: 2px solid #2196f3;
    }

    .lifecycle-state.timed-waiting {
        border: 2px solid #673ab7;
    }

    .lifecycle-state.terminated {
        border: 2px solid #f44336;
    }

.transition-arrow {
    font-size: 1.5rem;
    color: var(--primary);
}

.method-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

    .method-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left;
    }

    .method-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
    }

    .method-table tr:nth-child(even) {
        background: #f9f9f9;
    }

    .method-table tr:hover {
        background: rgba(30,136,229,0.05);
    }

.concurrency-compare {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(280px,1fr));
    gap: 20px;
    margin: 30px 0;
}

.compare-card {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    border-top: 4px solid var(--primary);
    transition: all 0.3s ease;
}

    .compare-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

.example-output {
    background: #1e1e1e;
    color: #d4d4d4;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

.console-output {
    color: #DCDCAA;
}

.thread-visualization {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 30px 0;
}

.thread-bar {
    height: 40px;
    background: #e3f2fd;
    border-radius: 20px;
    margin: 10px 0;
    display: flex;
    align-items: center;
    padding: 0 20px;
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

    .thread-bar::before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        height: 100%;
        width: 0%;
        background: linear-gradient(90deg,rgba(30,136,229,0.6),rgba(33,150,243,0.8));
        animation: progress 2s infinite linear;
    }

@keyframes progress {
    0% {
        width: 0%;
    }

    50% {
        width: 100%;
    }

    100% {
        width: 100%;
    }
}

.thread-name {
    position: relative;
    z-index: 1;
    font-weight: bold;
    color: #333;
}

.quiz-section {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.quiz-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.quiz-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    margin-right: 15px;
}

.quiz-question {
    font-size: 1.2rem;
    margin-bottom: 20px;
    line-height: 1.6;
}

.quiz-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.quiz-option {
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    padding-left: 50px;
}

    .quiz-option:hover {
        border-color: var(--primary);
        background: rgba(30,136,229,0.05);
    }

    .quiz-option.selected {
        border-color: var(--primary);
        background: rgba(30,136,229,0.1);
    }

    .quiz-option input {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        width: 20px;
        height: 20px;
    }

    .quiz-option label {
        cursor: pointer;
        display: block;
    }

.quiz-feedback {
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.feedback-correct {
    background: rgba(67,160,71,0.1);
    border-left: 4px solid var(--success);
}

.feedback-incorrect {
    background: rgba(244,67,54,0.1);
    border-left: 4px solid #f44336;
}

.thread-state-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
    gap: 20px;
    margin: 25px 0;
}

.state-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border-top: 4px solid var(--primary);
    transition: all 0.3s;
}

    .state-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

.state-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.state-icon {
    width: 40px;
    height: 40px;
    background: rgba(30,136,229,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--primary);
    font-size: 1.2rem;
}

.lifecycle-diagram {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.lifecycle-state {
    padding: 15px 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    min-width: 150px;
    text-align: center;
    font-weight: bold;
    position: relative;
}

    .lifecycle-state.new {
        border: 2px solid #9e9e9e;
    }

    .lifecycle-state.runnable {
        border: 2px solid #4caf50;
    }

    .lifecycle-state.blocked {
        border: 2px solid #ff9800;
    }

    .lifecycle-state.waiting {
        border: 2px solid #2196f3;
    }

    .lifecycle-state.timed-waiting {
        border: 2px solid #673ab7;
    }

    .lifecycle-state.terminated {
        border: 2px solid #f44336;
    }

.transition-arrow {
    font-size: 1.5rem;
    color: var(--primary);
}

.method-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

    .method-table th {
        background: var(--primary);
        color: white;
        padding: 15px;
        text-align: left;
    }

    .method-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
    }

    .method-table tr:nth-child(even) {
        background: #f9f9f9;
    }

    .method-table tr:hover {
        background: rgba(30,136,229,0.05);
    }

.concurrency-compare {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(280px,1fr));
    gap: 20px;
    margin: 30px 0;
}

.compare-card {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    border-top: 4px solid var(--primary);
    transition: all 0.3s ease;
}

    .compare-card:hover {
        transform: translateY(-5px);
        box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    }

.example-output {
    background: #1e1e1e;
    color: #d4d4d4;
    border-radius: 8px;
    padding: 20px;
    font-family: 'Courier New',monospace;
    margin: 20px 0;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.5);
}

.console-output {
    color: #DCDCAA;
}

.thread-visualization {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 30px 0;
}

.thread-bar {
    height: 40px;
    background: #e3f2fd;
    border-radius: 20px;
    margin: 10px 0;
    display: flex;
    align-items: center;
    padding: 0 20px;
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

    .thread-bar::before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        height: 100%;
        width: 0%;
        background: linear-gradient(90deg,rgba(30,136,229,0.6),rgba(33,150,243,0.8));
        animation: progress 2s infinite linear;
    }

@keyframes progress {
    0% {
        width: 0%;
    }

    50% {
        width: 100%;
    }

    100% {
        width: 100%;
    }
}

.thread-name {
    position: relative;
    z-index: 1;
    font-weight: bold;
    color: #333;
}

.quiz-section {
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.08);
    padding: 30px;
    margin-bottom: 30px;
}

.quiz-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.quiz-number {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 1.2rem;
    margin-right: 15px;
}

.quiz-question {
    font-size: 1.2rem;
    margin-bottom: 20px;
    line-height: 1.6;
}

.quiz-options {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin-bottom: 20px;
}

.quiz-option {
    padding: 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    padding-left: 50px;
}

    .quiz-option:hover {
        border-color: var(--primary);
        background: rgba(30,136,229,0.05);
    }

    .quiz-option.selected {
        border-color: var(--primary);
        background: rgba(30,136,229,0.1);
    }

    .quiz-option input {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        width: 20px;
        height: 20px;
    }

    .quiz-option label {
        cursor: pointer;
        display: block;
    }

.quiz-feedback {
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
}

.feedback-correct {
    background: rgba(67,160,71,0.1);
    border-left: 4px solid var(--success);
}

.feedback-incorrect {
    background: rgba(244,67,54,0.1);
    border-left: 4px solid #f44336;
}

.communication-flow {
    display: flex;
    justify-content: space-around;
    align-items: center;
    flex-wrap: wrap;
    margin: 30px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
}

.server-box, .client-box {
    text-align: center;
    padding: 20px;
    border-radius: 8px;
    background: white;
    box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    min-width: 200px;
}

.server-box {
    border-top: 4px solid var(--primary);
}

.client-box {
    border-top: 4px solid var(--secondary);
}

.arrow-container {
    font-size: 2rem;
    color: var(--gray);
    padding: 0 20px;
}

.method-sequence {
    margin: 25px 0;
    padding: 15px;
    background: rgba(30,136,229,0.05);
    border-radius: 8px;
    border-left: 4px solid var(--primary);
}

.sequence-step {
    margin-bottom: 15px;
    padding-left: 30px;
    position: relative;
}

    .sequence-step::before {
        content: counter(step);
        counter-increment: step;
        position: absolute;
        left: 0;
        top: 0;
        width: 24px;
        height: 24px;
        background: var(--primary);
        color: white;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        font-size: 0.9rem;
    }

.exception-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

    .exception-table th {
        background: var(--error);
        color: white;
        padding: 15px;
        text-align: left;
    }

    .exception-table td {
        padding: 12px 15px;
        border-bottom: 1px solid #eee;
    }

    .exception-table tr:nth-child(even) {
        background: #f9f9f9;
    }

    .exception-table tr:hover {
        background: rgba(244,67,54,0.05);
    }

.chat-simulation {
    background: #2d2d2d;
    border-radius: 10px;
    padding: 20px;
    margin: 25px 0;
    color: #f8f8f2;
    font-family: 'Courier New',monospace;
    max-height: 300px;
    overflow-y: auto;
}

.chat-message {
    margin-bottom: 10px;
}

.server-message {
    color: #4EC9B0;
}

.client-message {
    color: #DCDCAA;
}

.connection-diagram {
    display: flex;
    justify-content: center;
    margin: 30px 0;
}

.diagram-container {
    position: relative;
    width: 100%;
    max-width: 800px;
    height: 300px;
    background: #f5f7fa;
    border-radius: 8px;
    padding: 20px;
}

.server-node, .client-node {
    position: absolute;
    width: 120px;
    height: 80px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-weight: bold;
}

.server-node {
    left: 50px;
    top: 50%;
    transform: translateY(-50%);
    background: #e3f2fd;
    border: 2px solid var(--primary);
}

.client-node {
    right: 50px;
    top: 50%;
    transform: translateY(-50%);
    background: #ffecb3;
    border: 2px solid var(--secondary);
}

.connection-line {
    position: absolute;
    top: 50%;
    left: 180px;
    right: 180px;
    height: 2px;
    background: linear-gradient(to right,var(--primary),var(--secondary));
}

    .connection-line::before, .connection-line::after {
        content: '';
        position: absolute;
        top: -5px;
        width: 0;
        height: 0;
        border-style: solid;
    }

    .connection-line::before {
        left: 0;
        border-width: 6px 10px 6px 0;
        border-color: transparent var(--primary) transparent transparent;
    }

    .connection-line::after {
        right: 0;
        border-width: 6px 0 6px 10px;
        border-color: transparent transparent transparent var(--secondary);
    }

.code-block {
    background: #1e1e1e;
    color: #d4d4d4;
    font-family: 'Consolas','Courier New',monospace;
    font-size: 15px;
    line-height: 1.5;
    padding: 20px;
    border-radius: 4px;
    overflow-x: auto;
    tab-size: 4;
}

.code-keyword {
    color: #569cd6;
    font-weight: bold;
}

.code-comment {
    color: #6a9955;
    font-style: italic;
}

.code-string {
    color: #ce9178;
}

.code-class {
    color: #4ec9b0;
}

.code-method {
    color: #dcdcaa;
}

.code-number {
    color: #b5cea8;
}

.code-annotation {
    color: #c586c0;
}
