/* YouTube Style Menu CSS */
.youtube-menu-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 240px;
    height: 100vh;
    background: #fff;
    border-right: 1px solid #e5e5e5;
    z-index: 1000;
    transform: translateX(0);
    transition: transform 0.3s ease;
    overflow-y: auto;
}

.youtube-menu-container.mobile-open {
    transform: translateX(0);
}

#guide-content.mobile-closed {
    transform: translateX(-100%);
}

#header {
    display: flex;
    align-items: center;
    padding: 8px;
    border-bottom: 1px solid #e5e5e5;
}

.hamburger-toggle {
    margin-right: 8px;
}

.hamburger-toggle svg {
    fill: #606060;
}

.logo a {
    display: block;
}

.logo svg {
    width: 93px;
    height: 20px;
}

#guide-inner-content {
    padding: 8px 0;
}

.guide-section {
    margin-bottom: 8px;
}

.guide-entry {
    display: flex;
    align-items: center;
    padding: 12px 24px;
    text-decoration: none;
    color: #030303;
    font-size: 14px;
    border-left: 3px solid transparent;
    transition: background 0.2s;
}

.guide-entry:hover,
.guide-entry.active {
    background: #f2f2f2;
    border-left-color: #f03;
}

.guide-icon {
    width: 24px;
    height: 24px;
    margin-right: 24px;
    fill: #606060;
}

.title {
    flex: 1;
}

.arrow-icon {
    width: 16px;
    height: 16px;
    fill: #606060;
}

.collapsible .header-entry {
    cursor: pointer;
}

.sub-items {
    padding-left: 24px;
    display: none; /* JS sẽ toggle */
}

.sub-items.open {
    display: block;
}

.section-title {
    padding: 12px 24px;
    font-size: 12px;
    font-weight: 500;
    color: #606060;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

#footer {
    padding: 16px 24px;
    border-top: 1px solid #e5e5e5;
    margin-top: auto;
    font-size: 12px;
    color: #606060;
}

.guide-links-primary,
.guide-links-secondary {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
}

.guide-links-primary a,
.guide-links-secondary a {
    text-decoration: none;
    color: #606060;
}

#copyright {
    font-size: 11px;
}

/* Responsive: Ẩn menu trên mobile, mở overlay */
@media (max-width: 768px) {
    .youtube-menu-container {
        transform: translateX(-100%);
        width: 280px;
        box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    }

    .youtube-menu-container.open {
        transform: translateX(0);
    }

    body.menu-open {
        overflow: hidden;
    }

    .overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(0,0,0,0.5);
        z-index: 999;
    }
}

/* Scrollbar */
.youtube-menu-container::-webkit-scrollbar {
    width: 8px;
}

.youtube-menu-container::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

/* Widget/Shortcode Mode */
.youtube-menu-container.widget-mode,
.youtube-menu-container:not(.fixed) {
    position: relative !important;
    width: auto;
    height: auto;
    border: 1px solid #e5e5e5;
    box-shadow: none;
}

.youtube-menu-container.widget-mode #header,
.youtube-menu-container:not(.fixed) #header {
    justify-content: space-between;
}

.youtube-menu-container.widget-mode .guide-section,
.youtube-menu-container:not(.fixed) .guide-section {
    border-bottom: 1px solid #f1f1f1;
}

@media (max-width: 768px) {
    .youtube-menu-container.widget-mode,
    .youtube-menu-container:not(.fixed) {
        width: 100%;
    }
}