/* =========================================
   3. BLOG & SIDEBAR LAYOUT
   ========================================= */
.page-layout {
    display: flex;
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

.main-content {
    flex: 3;
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.sidebar {
    flex: 1;
    background-color: #f9f9f9;
    padding: 20px;
    border-radius: 8px;
    height: fit-content;
    border: 1px solid #eee;
}

.sidebar h3 {
    font-size: 1.2em;
    border-bottom: 2px solid #ddd;
    padding-bottom: 10px;
    margin-top: 0;
}

.sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar li {
    margin-bottom: 15px;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
}

.sidebar li:last-child {
    border-bottom: none;
}

.sidebar a {
    text-decoration: none;
    color: #27ae60;
    font-weight: bold;
    display: block;
    margin-bottom: 5px;
}

.sidebar a:hover {
    text-decoration: underline;
}

.sidebar .date {
    font-size: 0.85em;
    color: #777;
}

/* Responsive: stack on mobile */
@media (max-width: 768px) {
    .page-layout {
        flex-direction: column;
    }
}
body { 
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif; 
    line-height: 1.6; 
    color: #333; 
    max-width: 900px; 
    margin: 0 auto; 
    padding: 20px; 
    background-color: #fcfcfc; 
}

header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    border-bottom: 2px solid #eee; 
    padding-bottom: 10px; 
    margin-bottom: 30px; 
    flex-wrap: wrap; 
}

.lang-select ul { 
    list-style: none; 
    display: flex; 
    flex-wrap: wrap; 
    gap: 15px; 
    margin: 0; 
    padding: 0; 
}

.lang-select a { 
    text-decoration: none; 
    color: #007BFF; 
    font-weight: bold; 
}

h1 { 
    color: #2c3e50; 
}

h2 { 
    color: #34495e; 
    margin-top: 30px; 
}

.hero { 
    text-align: center; 
    padding: 40px 20px; 
    background-color: #e8f4f8; 
    border-radius: 10px; 
    margin-bottom: 30px; 
}

.content-section { 
    background-color: #fff; 
    padding: 30px; 
    border-radius: 8px; 
    box-shadow: 0 2px 4px rgba(0,0,0,0.05); 
    text-align: center; 
}

.index {
    text-align: left !important;
}

.terms {
    text-align: left !important;
}

.downloads { 
    display: flex; 
    flex-wrap: wrap; 
    gap: 15px; 
    justify-content: center; 
    align-items: center; 
    margin-top: 30px; 
}

.downloads img { 
    max-width: 180px; 
    height: auto; 
    transition: transform 0.2s; 
}

.downloads img:hover { 
    transform: scale(1.05); 
}

.cta-button { 
    display: inline-block; 
    background-color: #27ae60; 
    color: white; 
    padding: 15px 30px; 
    text-decoration: none; 
    border-radius: 5px; 
    font-size: 1.2em; 
    font-weight: bold; 
    margin: 20px 0; 
}

.email-link { 
    font-size: 1.2em; 
    color: #27ae60; 
    font-weight: bold; 
    text-decoration: none; 
}

.email-link:hover { 
    text-decoration: underline; 
}

/* =========================================
   MOBILE SIDEBAR DRAWER STYLES
   ========================================= */

/* Desktop behavior (Default) */
.sidebar-overlay {
    display: none;
}

/* Mobile behavior (Triggered on screens smaller than 768px) */
@media screen and (max-width: 768px) {
    /* 1. Hide the sidebar off-screen to the right */
    .sidebar {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px; /* Adjust width as needed */
        height: 100vh;
        background-color: #ffffff;
        box-shadow: -4px 0 15px rgba(0, 0, 0, 0.1);
        z-index: 9999;
        overflow-y: auto;
        transition: right 0.3s ease-in-out;
        padding: 20px;
        margin: 0;
    }

    /* 2. Class added by JS to slide it in */
    .sidebar.active {
        right: 0;
    }

    /* 3. The dark background overlay */
    .sidebar-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(0, 0, 0, 0.5);
        z-index: 9998;
        display: block;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease-in-out;
    }

    .sidebar-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    /* 4. The floating Action Button */
    .mobile-sidebar-toggle {
        position: fixed;
        bottom: 20px;
        right: 20px;
        background-color: #4CAF50; /* Match your brand color */
        color: white;
        border: none;
        border-radius: 50%;
        width: 55px;
        height: 55px;
        font-size: 24px;
        box-shadow: 0 4px 10px rgba(0,0,0,0.2);
        z-index: 10000;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        transition: transform 0.2s;
    }

    .mobile-sidebar-toggle:active {
        transform: scale(0.95);
    }
}

/* Hide the toggle button on desktop */
@media screen and (min-width: 769px) {
    .mobile-sidebar-toggle {
        display: none !important;
    }
}

footer { 
    text-align: center; 
    margin-top: 50px; 
    padding-top: 20px; 
    border-top: 1px solid #ccc; 
    font-size: 0.9em; 
}

footer a { 
    color: #555; 
    margin: 0 10px; 
}