/* DiveWP Layout Styles That Handle the sidebars, main content area and all realted to the grid system we use to display content.
   ========================================================================== */

/* Main Container */
.divewp-container {
    display: flex;
    background-color: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    margin: 20px;
    overflow: hidden;
    min-height: calc(100vh - 100px);
}

/* Left Sidebar */

/* Update logo styling */

/* Logo container in sidebar */
.divewp-logo-container {
    padding: 16px 24px 16px 24px;
    border-bottom: 1px solid #edf2f7;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
}

.divewp-logo {
    max-width: 120px;
    height: auto;
    display: block;
    margin: 0;
}

.divewp-tabs-column {
    width: 280px;
    background: #fff;
    border-right: 1px solid #e5e7eb;
    height: 100%;
    padding: 0;
}

/* Main Content Area */
.divewp-main-content {
    flex: 1;
    padding: 24px;
    background: #fff;
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.divewp-content-wrapper {
    flex: 1;
    background: #fff;
    overflow: auto;
    position: relative;
}

.divewp-content {
    padding: 32px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Right Sidebar */
.divewp-right-sidebar,
.divewp-sidebar {
    width: 240px;
    background: #fff;
    border-left: 1px solid #e5e7eb;
    padding: 16px;
    overflow-y: auto;
}

/* YouTube Subscribe Section */
.divewp-yt-subscribe {
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 10px;
    text-align: center;
}

.divewp-yt-subscribe__icon {
    margin-bottom: 8px;
}

.divewp-yt-subscribe h3 {
    color: #1a1a1a;
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 6px 0;
}

.divewp-yt-subscribe__desc {
    color: #666;
    font-size: 11px;
    line-height: 1.5;
    margin: 0 0 10px 0;
}

.divewp-yt-subscribe__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #FF0000;
    color: #fff;
    padding: 8px 16px;
    border-radius: 24px;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s, transform 0.2s;
}

.divewp-yt-subscribe__btn:hover {
    background: #cc0000;
    color: #fff;
    transform: translateY(-1px);
}

.divewp-yt-subscribe__btn:focus {
    outline: 2px solid #FF0000;
    outline-offset: 2px;
}

/* Grid Layout */
.divewp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin: 24px 0;
}

.divewp-grid-2 {
    grid-template-columns: repeat(2, 1fr);
}

.divewp-grid-3 {
    grid-template-columns: repeat(3, 1fr);
}

/* Section Layout */
.divewp-section {
    margin-bottom: 32px;
}

.divewp-section-header {
    margin-bottom: 24px;
}

/* Responsive Layout */

/* Below 1920px: Move sidebar below content, horizontal layout */
@media screen and (max-width: 1919px) {
    .divewp-container {
        flex-wrap: wrap;
    }
    
    .divewp-tabs-column {
        flex-shrink: 0;
    }
    
    .divewp-main-content {
        flex: 1;
        min-width: 0;
    }
    
    .divewp-right-sidebar,
    .divewp-sidebar {
        width: 100%;
        border-left: none;
        border-top: 1px solid #e5e7eb;
        padding: 16px 24px;
        display: flex;
        flex-wrap: wrap;
        gap: 16px;
        order: 3; /* Ensure sidebar appears after main content */
    }
    
    /* Sidebar sections become horizontal cards */
    .divewp-sidebar .sidebar-section {
        flex: 1;
        min-width: 250px;
        max-width: 400px;
        margin-bottom: 0;
    }
    
    /* Beta notice section styling for horizontal layout */
    .divewp-sidebar .sidebar-section.beta-notice {
        flex: 1;
        min-width: 280px;
    }
    
    /* YouTube section styling for horizontal layout */
    .divewp-sidebar .divewp-yt-subscribe {
        flex: 1;
        min-width: 200px;
        max-width: 300px;
        margin-bottom: 0;
    }
}

@media screen and (max-width: 1400px) {
    .divewp-grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Below 1200px: Stack everything vertically (mobile/tablet) */
@media screen and (max-width: 1200px) {
    .divewp-container {
        flex-direction: column;
    }
    
    .divewp-tabs-column {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e5e7eb;
    }
    
    .divewp-right-sidebar,
    .divewp-sidebar {
        width: 100%;
        flex-direction: column;
        padding: 16px;
    }
    
    /* Sidebar sections stack vertically on mobile */
    .divewp-sidebar .sidebar-section,
    .divewp-sidebar .sidebar-section.beta-notice,
    .divewp-sidebar .divewp-yt-subscribe {
        flex: none;
        width: 100%;
        max-width: none;
        min-width: 0;
        margin-bottom: 10px;
    }
    
    .divewp-sidebar .sidebar-section:last-child {
        margin-bottom: 0;
    }

    .divewp-grid-2,
    .divewp-grid-3 {
        grid-template-columns: 1fr;
    }
}

/* Tab Content */
.divewp-tab-content {
    display: none;
}

.divewp-tab-content.active {
    display: block;
}

/* Utility Classes */
.divewp-flex {
    display: flex;
}

.divewp-flex-col {
    display: flex;
    flex-direction: column;
}

.divewp-flex-1 {
    flex: 1;
}

.divewp-flex-wrap {
    flex-wrap: wrap;
}

.divewp-items-center {
    align-items: center;
}

.divewp-justify-between {
    justify-content: space-between;
}

.divewp-gap-4 {
    gap: 16px;
}

.divewp-overflow-hidden {
    overflow: hidden;
}

.divewp-h-full {
    height: 100%;
}

.divewp-w-full {
    width: 100%;
}

.divewp-relative {
    position: relative;
}

.divewp-absolute {
    position: absolute;
}
