.section-detail-prodi {
    margin-bottom: 0;

    /* Ukuran font inline dari CKEditor dibuat responsif oleh script footer. */
    [style*="font-size"] {
        font-size: clamp(var(--ckeditor-font-min, 1rem),
                calc(var(--ckeditor-font-min, 1rem) + 2.5vw),
                var(--ckeditor-font-max, 3rem)) !important;
    }

    .bagian-header {
        position: relative;
        border-radius: 20px;
        width: 100%;

        .overlay {
            padding: 62px 50px;
            border-radius: 20px;
            color: #F9DA00;

            background: linear-gradient(to left, rgba(27, 94, 32, 0), rgba(27, 94, 32, 1));


            .breadcrumbb {
                font-size: 14px;
                color: #F9DA00;
                font-weight: 300;
                text-align: left;
                margin-bottom: 12px;
                max-width: 542px;

                a {
                    color: inherit;
                    text-decoration: none;
                }

                a:hover {
                    text-decoration: underline;
                }
            }

            .nama {
                font-size: var(--text-h6);
                font-weight: 500;
                text-transform: uppercase;
                margin-bottom: 12px;
                max-width: 542px;
            }

            .tagline {
                font-size: var(--text-h2);
                font-weight: bold;
                line-height: 120%;
                margin-bottom: 12px;
                max-width: 542px;
            }

            .desc {
                color: var(--text-inverse);
                max-width: 542px;
                margin-bottom: 0;

                p {
                    margin-bottom: 0;
                }
            }
        }
    }

    .bagian-breadcrumb {
        padding: 20px;
        font-size: 14px;
        color: #94A3B8;

        a {
            color: inherit;
            text-decoration: none;
        }

        a:hover {
            text-decoration: underline;
        }
    }

    .bagian-tujuan {
        background-color: white;
        padding: 50px 40px;

        .title {
            font-size: var(--text-h5);
            color: var(--color-yellow-700);
            font-weight: 700;
            text-transform: uppercase;
            text-align: center;
            margin-bottom: 12px;
        }
    }

    .bagian-visi {
        border-radius: 15px;
        position: relative;
        height: 746px;

        .overlay {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: linear-gradient(to bottom, rgba(156, 74, 14, 0), rgba(120, 58, 10, 1));
            border-radius: 15px;

            .content {
                padding: 60px 40px;
                position: absolute;
                bottom: 0;
                left: 0;

                .title {
                    font-size: var(--text-h5);
                    color: var(--color-yellow-700);
                    font-weight: bold;
                    margin-bottom: 10px;
                    text-transform: uppercase;
                }

                .desc {
                    font-size: var(--text-h3);
                    color: var(--text-inverse);
                    font-weight: bold;
                    line-height: 120%;
                }
            }
        }
    }

    .bagian-misi {
        .title {
            font-size: var(--text-h5);
            color: var(--color-yellow-700);
            font-weight: 700;
            text-transform: uppercase;
            text-align: left;
            margin-bottom: 12px;

        }

        .carddd {
            padding: 20px 40px;
            border-radius: 15px;
            box-shadow: 0 4px 25px 0 rgba(0, 90, 145, 0.12);
            background-color: white;
            margin-bottom: 18px;

            .title {
                font-size: var(--text-h6);
                color: #783A0A;
                font-weight: 700;
                line-height: 140%;
                text-align: left;
                display: flex;
                align-items: center;
                gap: 12px;
                text-transform: none;

                p {
                    margin-bottom: 0;
                }

                small {
                    text-wrap: nowrap;
                }
            }

            .desc {
                color: var(--text-secondary);
                line-height: 150%;
            }
        }
    }

    .bagian-dosen {
        .wrapper {
            background: rgba(120, 58, 10, .6);
            padding-top: 50px;
            padding-bottom: 50px;

            .title {
                font-size: var(--text-h5);
                color: var(--color-yellow-700);
                line-height: 130%;
                font-weight: bold;
                text-transform: uppercase;
                margin-bottom: 12px;
            }

            .desc {
                font-size: 19px;
                line-height: 140%;
                color: var(--text-inverse);
            }

            .more {
                text-align: right;
                display: block;
                color: var(--text-inverse);
                transform: translateX(-10px);

                &:hover {
                    color: var(--text-link);

                    .ikon {
                        transform: translateX(5px);
                    }
                }

                .ikon {
                    font-size: 12px;
                    margin-left: 3px;

                    transition: all ease-out 0.3s;
                }

                @media(max-width:991px) {
                    text-align: left;
                }

                @media(max-width: 450px) {}
            }

            .carddd {
                width: 100%;
                max-width: 245px;

                img {
                    width: 100%;
                    max-width: 245px;
                    height: 295px;
                    object-fit: cover;
                    border-radius: 7px;
                    display: block;
                }

                .detail {
                    padding: 10px;
                    text-transform: none;
                    font-weight: 400;

                    .title {
                        font-size: var(--text-sub);
                        color: #FED7AA;
                        text-transform: none;
                        font-weight: 400;
                        margin-bottom: 0;
                    }

                    .nama {
                        font-size: var(--text-body);
                        color: var(--text-inverse);
                        font-weight: bold;
                    }
                }
            }

            .dosen-list {
                display: grid;
                grid-template-columns: minmax(0, 245px);
                column-gap: 20px;
                row-gap: 24px;
                justify-content: center;

                @media (min-width: 576px) {
                    grid-template-columns: repeat(2, minmax(0, 245px));
                    justify-content: start;
                }

                @media (min-width: 768px) {
                    grid-template-columns: repeat(3, minmax(0, 245px));
                }

                @media (min-width: 992px) {
                    grid-template-columns: repeat(3, 245px);
                }

                @media (min-width: 1200px) {
                    grid-template-columns: repeat(4, 245px);
                }

                @media (min-width: 1400px) {
                    grid-template-columns: repeat(5, 245px);
                }
            }
        }
    }

    .bagian-kurikulum {
        padding-top: 30px;

        .title {
            font-size: var(--text-h5);
            color: var(--color-yellow-700);
            font-weight: 700;
            text-transform: uppercase;
            text-align: left;
            margin-bottom: 12px;
        }

        .desc {
            font-size: var(--text-body);
            color: #64748B;
            line-height: 150%;
            max-width: 622px;
            margin-bottom: 30px;
        }

        .content {
            /* white-space: nowrap; */
            word-break: keep-all;
            overflow-x: auto;

            .ckeditor-table-scroll {
                max-width: 100%;
                overflow-x: auto;
                -webkit-overflow-scrolling: touch;
            }

            table {
                min-width: 700px;
                border: none;

                thead {
                    background-color: #E2E8F0;
                    color: var(--text-secondary);

                    th {
                        padding: 10px 20px;
                    }
                }

                tbody {
                    tr {
                        border-bottom: 1px solid #E2E8F0;
                    }

                    td {
                        padding: 20px;
                    }
                }

            }
        }
    }

    .bagian-galeri {

        background-color: #EFF8FF;

        .title {
            font-size: var(--text-h5);
            color: var(--color-yellow-700);
            font-weight: 700;
            text-transform: uppercase;
            text-align: left;
            margin-bottom: 12px;
        }

        .tagline {
            color: #C45F12;
            font-size: var(--text-h2);
            font-weight: bold;
            margin-bottom: 12px;
        }

        .desc {
            font-size: var(--text-body);
            color: #64748B;
            line-height: 150%;
            max-width: 622px;
        }

        .more {
            text-align: right;
            display: block;
            color: var(--color-blue-300);
            transform: translateX(-10px);

            &:hover {
                color: var(--text-link);

                .ikon {
                    transform: translateX(5px);
                }
            }

            .ikon {
                font-size: 12px;
                margin-left: 3px;

                transition: all ease-out 0.3s;
            }

            @media(max-width:991px) {
                text-align: left;
            }

            @media(max-width: 450px) {}
        }

        /* Start gallery container */
        .gallery-container {
            width: 100%;
            /* max-width: 1200px; */
            margin: 0 auto;
            padding: 15px;
            box-sizing: border-box;
        }

        /* Base Grid Layout (Default untuk 4 gambar) */
        .image-collage {
            display: grid;
            grid-template-columns: 1fr 1fr 1fr;
            /* 3 Kolom */
            gap: 16px;
            width: 100%;
        }

        /* Styling Item Gambar */
        .collage-item {
            position: relative;
            overflow: hidden;
            border-radius: 16px;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
            background-color: #000;
        }

        .collage-item img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            transition: transform 0.3s ease;
        }

        .collage-item:hover img {
            transform: scale(1.03);
        }

        /* --- PENYESUAIAN BERDASARKAN JUMLAH GAMBAR --- */

        /* 1. Jika hanya ada 1 Gambar */
        .image-collage.count-1 {
            grid-template-columns: 1fr;
        }

        .image-collage.count-1 .collage-item {
            height: 450px;
            max-width: 600px;
            margin: 0 auto;
        }

        /* 2. Jika ada 2 Gambar */
        .image-collage.count-2 {
            grid-template-columns: 1fr 1fr;
        }

        .image-collage.count-2 .collage-item {
            height: 450px;
        }

        /* 3. Jika ada 3 Gambar */
        .image-collage.count-3 {
            grid-template-columns: 1fr 1fr;
        }

        /* Gambar pertama besar, 2 sisanya bertumpuk di kolom kedua */
        .image-collage.count-3 .collage-item:nth-child(1) {
            height: 450px;
        }

        .image-collage.count-3 .stack-wrapper {
            display: grid;
            grid-template-rows: 1fr 1fr;
            gap: 16px;
            height: 450px;
        }

        /* 4. Jika ada 4 Gambar (Sesuai Referensi Gambar) */
        .image-collage.count-4 .collage-item.tall {
            height: 450px;
            /* Tinggi untuk kolom 1 dan 3 */
        }

        .image-collage.count-4 .stack-wrapper {
            display: grid;
            grid-template-rows: 1fr 1fr;
            gap: 16px;
            height: 450px;
        }

        /* --- RESPONSIVE UNTUK HP / TABLET (Layar < 768px) --- */
        @media (max-width: 768px) {

            .image-collage,
            .image-collage.count-2,
            .image-collage.count-3,
            .image-collage.count-4 {
                grid-template-columns: 1fr !important;
                /* Berubah jadi 1 kolom ke bawah */
            }

            .collage-item,
            .image-collage.count-1 .collage-item,
            .image-collage.count-4 .collage-item.tall {
                height: 300px !important;
                /* Tinggi seragam yang nyaman di HP */
            }

            .stack-wrapper {
                height: auto !important;
                display: flex !important;
                flex-direction: column;
                gap: 16px;
            }

            .stack-wrapper .collage-item {
                height: 250px !important;
            }
        }
    }
}