/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Open Sans', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f9f9f9;
}

/* Layout */
.wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.site-content {
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 300px);
}

/* Header */
#masthead {
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#masthead .wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px;
    flex-wrap: wrap;
}

/* Site Branding */
#site-branding {
    display: flex;
    align-items: center;
    flex: 1;
}

#site-logo {
    margin-right: 20px;
}

.custom-logo {
    width: 137px;
    height: 137px;
    /* object-fit: contain; */
}

.site-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
}

.site-title a {
    text-decoration: none;
    color: #2c3e50;
}

.site-description {
    color: #7f8c8d;
    font-size: 14px;
    font-weight: 300;
}

/* Header Widgets */
.sidebar-header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

/* Desktop search in header - visible on all screen sizes */
#header-right-search {
    display: block;
}

.search-form {
    position: relative;
    display: flex;
    align-items: center;
}

.search-field {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 200px;
    font-size: 14px;
}

.search-submit {
    padding: 8px 16px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 8px;
    font-size: 14px;
}

.search-submit:hover {
    background-color: #2980b9;
}

/* Navigation */
.nav-primary {
    background-color: #2c3e50;
    border-bottom: 3px solid #3498db;
}

.nav-primary .wrapper {
    padding: 0;
}

.menu {
    list-style: none;
    display: flex;
    margin: 0;
    padding: 0;
}

.menu li {
    position: relative;
}

.menu a {
    display: block;
    padding: 15px 20px;
    color: #ecf0f1;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s;
}

.menu a:hover,
.menu .current-menu-item a {
    background-color: #34495e;
}

/* Header Featured Image */
#header-featured-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background-color: #a1a0a0;
}

.wp-post-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Main Content Layout */
.site-content .wrapper {
    display: flex;
    gap: 40px;
    padding: 40px 0;
}

.site-main {
    flex: 1;
    /* max-width: calc(100% - 280px); */
}

.sidebar-primary {
    width: 280px;
    flex-shrink: 0;
}

/* Posts */
.post {
    background-color: #fff;
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
}

.entry-container {
    padding: 30px;
}

.entry-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.3;
}

.entry-title a {
    text-decoration: none;
    color: #2c3e50;
    transition: color 0.3s;
}

.entry-title a:hover {
    color: #3498db;
}

.entry-meta {
    color: #7f8c8d;
    font-size: 14px;
    margin-bottom: 15px;
}

.entry-summary {
    color: #555;
    line-height: 1.7;
    margin-bottom: 20px;
}

.more-link {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s;
}

.more-link:hover {
    color: #2980b9;
}

/* Sidebar Widgets */
.widget {
    background-color: #fff;
    margin-bottom: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
}

.widget-wrap {
    padding: 25px;
}

.widget-title {
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #ecf0f1;
}

/* Download Items */
.download-item {
    display: flex;
    flex-direction: column;
    padding: 15px 0;
    border-bottom: 1px solid #ecf0f1;
}

.download-item:last-child {
    border-bottom: none;
}

.download-header {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.download-icon {
    width: 40px;
    height: 40px;
    background-color: #e74c3c;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
    margin-right: 12px;
    flex-shrink: 0;
}

.download-info {
    flex: 1;
    word-wrap: break-word;
    overflow: hidden;
}

.download-link {
    width: 100%;
}

.download-link .btn {
    width: 100%;
    text-align: center;
}

.download-info h5 {
    font-size: 16px;
    margin: 0 0 5px 0;
    line-height: 1.2;
    word-wrap: break-word;
    hyphens: auto;
}

.download-info a {
    text-decoration: none;
    color: #2c3e50;
    font-weight: 600;
}

.download-meta {
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: #7f8c8d;
}


.btn {
    display: inline-block;
    padding: 8px 16px;
    background-color: #3498db;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #2980b9;
}

.btn-primary {
    background-color: #3498db;
}

/* Footer */
.site-footer {
    background-color: #2c3e50;
    color: #ecf0f1;
    padding: 20px 0;
    margin-top: auto;
}

#footer-content {
    text-align: center;
    font-size: 14px;
}

#footer-content a {
    color: #3498db;
    text-decoration: none;
}

#footer-content a:hover {
    text-decoration: underline;
}

/* Mobile Menu Button - Matches Desktop Navigation Colors */
.mobile-menu-anchor {
    display: none;
    cursor: pointer;
    padding: 12px 16px;
    background: #2c3e50; /* Same as desktop navigation */
    color: white;
    border: 2px solid #3498db; /* Same accent color as desktop nav */
    border-radius: 6px;
    margin-right: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    min-width: 50px; /* Ensure whole button area is clickable */
    text-align: center;
    text-decoration: none; /* Remove link underline */
}

.mobile-menu-anchor:hover {
    background: #34495e; /* Slightly lighter on hover */
    border-color: #5dade2; /* Lighter border on hover */
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.mobile-menu-anchor:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
}

.mobile-menu-anchor i {
    font-size: 18px;
    transition: transform 0.3s ease;
    display: block; /* Ensures icon takes full button space */
}

.mobile-menu-anchor:hover i {
    transform: scale(1.05);
}

/* Remove the shimmer animation to keep it clean like desktop nav */
.mobile-menu-anchor::before {
    display: none;
}





/* Scroll to Top */
#scrollup {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    background-color: #3498db;
    color: white;
    text-align: center;
    line-height: 50px;
    border-radius: 50%;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 999;
    text-decoration: none;
}

#scrollup.show {
    opacity: 1;
    visibility: visible;
}

#scrollup:hover {
    background-color: #2980b9;
}

#scrollup i {
    font-size: 20px;
}

/* Screen Reader Text */
.screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

/* Mobile Navigation */
.mobile-menu {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100vh;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    z-index: 10001;
    transition: left 0.3s ease;
    padding-top: 60px;
    overflow-y: auto;
    box-shadow: 2px 0 10px rgba(0,0,0,0.3);
}

.mobile-menu.open {
    left: 0;
}

.mobile-menu .menu {
    flex-direction: column;
    list-style: none;
    margin: 0;
    padding: 0;
    display: block !important;
    visibility: visible !important;
}

.mobile-menu .menu li {
    position: relative;
    display: block !important;
    visibility: visible !important;
}

.mobile-menu .menu a {
    display: block !important;
    padding: 18px 30px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    color: #ecf0f1 !important;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    visibility: visible !important;
    opacity: 1 !important;
    position: relative;
    background: transparent !important;
}

.mobile-menu .menu a:hover,
.mobile-menu .menu a:focus {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.2) 0%, rgba(118, 75, 162, 0.2) 100%) !important;
    color: #ffffff !important;
    outline: none;
    padding-left: 35px;
    transform: translateX(5px);
}

.mobile-menu .menu a:hover::before {
    opacity: 1;
    transform: translateX(0);
}

/* Add subtle arrow indicator on hover */
.mobile-menu .menu a::before {
    content: '→';
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translate(-10px, -50%);
    opacity: 0;
    transition: all 0.3s ease;
    color: #667eea;
}

/* Overlay for mobile menu */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.8) 100%);
    backdrop-filter: blur(2px);
    z-index: 9999;
    transition: opacity 0.3s ease;
    opacity: 0;
}

.mobile-menu-overlay.show {
    display: block;
    opacity: 1;
}

/* Responsive Design */
@media (max-width: 768px) {
    .mobile-menu-anchor,
    #search-toggle {
        display: block;
    }

    .menu {
        display: none;
    }

    .site-content .wrapper {
        flex-direction: column;
        gap: 20px;
    }

    .site-main {
        max-width: 100%;
    }

    .sidebar-primary {
        width: 100%;
    }

    #masthead .wrapper {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        position: relative;
    }

    #site-branding {
        justify-content: center;
        order: 1;
    }

    .sidebar-header-right {
        justify-content: center;
        order: 2;
        margin-top: 10px;
    }

    .search-field {
        width: 120px;
    }

    /* Make search bar more compact on mobile */
    #header-right-search .search-field {
        width: 100px;
        padding: 6px 10px;
        font-size: 14px;
    }

    #header-right-search .search-submit {
        padding: 6px 12px;
        font-size: 14px;
    }

    .entry-container {
        padding: 20px;
    }

    .widget-wrap {
        padding: 20px;
    }

    .download-header {
        margin-bottom: 12px;
    }

    .download-icon {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .download-info {
        width: 100%;
        text-align: left;
    }

    .download-link .btn {
        font-size: 14px;
        padding: 10px 16px;
    }

    /* Improve mobile header layout */
    .mobile-menu-anchor {
        order: 3;
        margin-top: 10px;
    }

    #search-toggle {
        order: 4;
        margin-top: 10px;
        margin-left: 10px;
    }
}

@media (max-width: 480px) {
    .wrapper {
        padding: 0 15px;
    }

    .site-title {
        font-size: 24px;
    }

    .entry-title {
        font-size: 20px;
    }

    .search-field {
        width: 120px;
    }
}

/* Utility Classes */
.displaynone {
    display: none;
}

.font-awesome {
    font-family: 'Font Awesome 6 Free', sans-serif;
    font-weight: 900;
}

/* Social Icons */
#social-icons a {
    color: #3498db;
    font-size: 24px;
    margin: 0 10px;
    text-decoration: none;
    transition: color 0.3s;
}

#social-icons a:hover {
    color: #2980b9;
}

/* Focus States */
.search-field:focus,
.btn:focus {
    outline: 2px solid #3498db;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .mobile-menu,
    #scrollup,
    .search-form,
    #search-toggle {
        display: none !important;
    }

    body {
        font-size: 12pt;
        line-height: 1.4;
    }

    .site-content {
        box-shadow: none;
    }
}

/* Updates Notice Banner */
.updates-notice-banner {
    background: linear-gradient(135deg, #2196F3 0%, #1976D2 100%);
    color: #fff;
    padding: 14px 0;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    border-bottom: 3px solid #0D47A1;
    position: relative;
    z-index: 1000;
}

.updates-notice-banner .wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.updates-notice-banner i {
    font-size: 22px;
    color: #E3F2FD;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

.updates-notice-banner span {
    font-size: 15px;
    line-height: 1.4;
}

.updates-notice-banner strong {
    font-weight: 700;
    color: #E3F2FD;
}

@media (max-width: 768px) {
    .updates-notice-banner {
        padding: 16px 10px;
    }
    
    .updates-notice-banner .wrapper {
        flex-direction: row;
        gap: 10px;
        flex-wrap: wrap;
    }
    
    .updates-notice-banner span {
        font-size: 14px;
        flex: 1;
        min-width: 200px;
    }
}