#main-content-container {
    width: 80%;
    margin: 0 auto;
    padding: 20px;
    background-color: white;
    display: flex;
    gap: 20px;
}

.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    margin-bottom: 10px;
    /* Spacing between video and heading */
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

h3 {
    text-align: center;
    margin-top: 0;
    margin-bottom: 20px;
    font-weight: bold;
    font-size: 2em;
    width: 100%;
}

.sidebar {
    width: 25%;
    background-color: #f7f7f7;
    padding: 15px;
    box-sizing: border-box;
}

.content {
    width: 75%;
    padding: 15px;
    box-sizing: border-box;
}

.widget ul {
    list-style: none;
    padding: 0;
}

.widget ul li {
    margin-bottom: 10px;
}

.widget ul li a {
    text-decoration: none;
    color: #333;
    cursor: pointer;
}

.widget ul li a:hover {
    color: royalblue;
}

.widget ul li a:focus,
.widget ul li a:active {
    outline: 2px solid royalblue;
    outline-offset: 2px;
}

.recent-posts {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    /* 3 columns */
    grid-template-rows: repeat(9, auto);
    /* 9 rows */
    gap: 20px;
}

.post {
    background-color: #ffffff;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-shadow: 2px 2px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    box-sizing: border-box;
    transition: transform 0.2s, box-shadow 0.2s;
    text-align: center;
    /* Center content horizontally */
}

.post img {
    max-width: 100%;
    height: 100px;
    /* Set a uniform height */
    object-fit: cover;
    /* Ensures the image fills the space while maintaining aspect ratio */
    display: block;
    margin-left: auto;
    margin-right: auto;
}

.post h4 {
    text-align: center;
    font-size: 1.2em;
    margin-bottom: 10px;
}

.post p {
    margin: 10px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    height: 2.5em;
    /* Controls the visible height of the paragraph (approx. 2 lines) */
    white-space: nowrap;
}

.post .read-more {
    text-align: right;
}

.post .read-more a {
    text-decoration: none;
    color: royalblue;
    font-weight: bold;
}

.post .read-more a:hover {
    text-decoration: underline;
}

.post:hover {
    box-shadow: 4px 4px 16px rgba(0, 0, 0, 0.2);
    transform: scale(1.02);
}

@media (max-width: 768px) {
    #main-content-container {
        flex-direction: column;
    }

    .sidebar,
    .content {
        width: 100%;
    }

    .recent-posts {
        grid-template-columns: 1fr;
        /* Single column layout for smaller screens */
        grid-template-rows: auto;
        /* Automatic row height */
    }

    .post {
        width: 100%;
        /* Make sure posts take full width */
    }
}