/* youtube-section.css */

.youtube-playlist-section,
.youtube-playlist-section-mobile {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 2rem; /* Adds space below the video */
}

/* Container to maintain aspect ratio and responsiveness */
.video-container {
    position: relative;
    width: 100%;
    max-width: 960px; /* Optional: Adjust as needed or remove for full responsiveness */
    margin: 0 auto; /* Center the container horizontally */
    aspect-ratio: 16 / 9; /* Maintain a 16:9 aspect ratio */
    overflow: hidden; /* Hide any overflowing content */
    border-radius: 0px; /* Rounded corners for the container */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); /* Enhanced shadow for better depth */
    background-color: #000; /* Fallback background color while the video loads */
    transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth transitions for interactions */
}

/* Iframe styling for the YouTube video */
.video-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 8px; /* Match container's rounded corners */
    box-shadow: none; /* Remove iframe's shadow to prevent double shadows */
    transition: transform 0.3s ease; /* Smooth scaling on hover */
    display: block; /* Remove any default inline spacing */
}

.video-section-wrapper {
    display: flex;
    flex-direction: row;       
    gap: 1rem;                   
    justify-content: center;
    align-items: center;
    margin-bottom: 1rem;
  }

.video-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    flex: 1;
    min-width: 0; /* 允许内容收缩 */
    flex-direction: column;
    gap: 0rem;
    padding: 0 0.5rem;
}

.video-title {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
    padding: 0 1rem;
    max-width: 960px;      
    width: 100%;           
    box-sizing: border-box;
    word-wrap: break-word;
}


@media (max-width: 768px) {
    .youtube-playlist-section-mobile {
        margin-bottom: 1.5rem;
    }

    .video-section-wrapper {
        flex-direction: column;
        gap: 0rem; 
        margin-top: 2rem;
        margin-bottom: 0rem;
      }
    
      .video-block {
        flex: none;
        width: 100%;
        padding: 0;
        margin-bottom: 1.5rem;
    }
    
    .video-title {
        font-size: 0.8rem;
        padding: 0.8 0rem;
    }

}