/* --- 1. MAIN CONTENT & SIDEBAR --- */
.pkp_structure_main li { margin: 10px 0; text-align: justify; }
.pkp_structure_main p { text-align: justify; }

.sidebar_1 { width: 100%; }
.sidebar_1 td { height: 30px; padding: 3px 0; vertical-align: middle; text-align: center; border-bottom: 2px solid #ffffff; }
.sidebar_1 td a { width: 100%; display: block; }
.sidebar_1 tr { background: #4b92b7; color: #ffffff; margin: 3px; }
.sidebar_1 tr:hover { background-color: #2c3e50; }
.sidebar_1 tr a { color: #ffffff; }

/* --- 2. HEADER BACKGROUND (BLUE) --- */
.pkp_structure_head_wrapper,
.pkp_structure_head,
header.pkp_structure_head { 
    background-color: #005a9c !important; 
    border: none !important;
}
.pkp_site_name .is_text { color: #ffffff !important; }

@media (min-width: 992px) {
  .pkp_site_name .is_img img { max-height: 180px !important; }
}

/* --- 3. BASE NAVIGATION SETTINGS (Applies to Mobile & Desktop) --- */
.pkp_navigation_primary_wrapper {
    background-color: #005a9c !important;
}

ul.pkp_navigation_primary, 
ul.pkp_navigation_user {
    margin: 0 !important;
    padding: 0 !important;
}

.pkp_navigation_primary > li > a,
.pkp_navigation_user > li > a {
    color: #ffffff !important; 
    font-size: 13px !important;   
}

/* Hover Colors */
.pkp_navigation_primary > li > a:hover,
.pkp_navigation_primary > li > a:focus,
.pkp_search > a:hover,
.pkp_search > a:focus,
a.search_toggle:hover,
a.search_toggle:focus {
    color: #ff9800 !important; 
}

/* --- 4. FIX DROPDOWN MENU TEXT OVERFLOW --- */
.pkp_navigation_primary ul {
    min-width: 250px !important;
    white-space: normal !important;
}
.pkp_navigation_primary ul li,
.pkp_navigation_primary ul li a {
    white-space: normal !important;
    word-wrap: break-word !important;
    line-height: 1.4 !important;
}

/* --- 5. OVAL STYLE FOR USER BUTTONS (Login/Register) --- */
.pkp_navigation_user > li > a {
    background-color: #005a9c !important;   
    color: #ffffff !important;              
    border: 2px solid #ffffff !important;   
    border-radius: 50px !important;         
    padding: 8px 20px !important;           
    margin: 5px 10px !important;            
    display: inline-block !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;   
    line-height: 1 !important;
}

.pkp_navigation_user > li > a:hover,
.pkp_navigation_user > li > a:focus {
    background-color: #ff9800 !important;   
    border-color: #ff9800 !important;       
    color: #ffffff !important;              
}

/* --- NEW: OVAL STYLE FOR TOP RIGHT SEARCH BUTTON --- */
.custom-search-oval {
    background-color: #005a9c !important;   
    color: #ffffff !important;              
    border: 2px solid #ffffff !important;   
    border-radius: 50px !important;         
    padding: 8px 20px !important;           
    display: inline-block !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;   
    line-height: 1 !important;
    text-decoration: none !important;
}

.custom-search-oval:hover,
.custom-search-oval:focus {
    background-color: #ff9800 !important;   
    border-color: #ff9800 !important;       
    color: #ffffff !important;              
}

/* --- 6. DESKTOP ONLY: FORCE SINGLE LINE & PIN TOP RIGHT BUTTONS --- */
@media (min-width: 992px) {
    /* Primary Navigation Bar Row */
    .pkp_navigation_primary_wrapper {
        display: flex !important; 
        align-items: center !important; 
        width: 100% !important; 
        overflow: visible !important; 
    }
    
    ul.pkp_navigation_primary {
        display: flex !important; 
        flex-wrap: nowrap !important; 
        overflow: visible !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    ul.pkp_navigation_primary > li {
        white-space: nowrap !important;
    }
    
    .pkp_navigation_primary > li > a {
        padding: 12px 10px !important; 
    }

    /* Pin Top Right Buttons (Search, Register, Login) and Force Horizontal Row */
    /* Pin Top Right Buttons and Stack Vertically */
    .pkp_navigation_user_wrapper {
        display: flex !important;
        flex-direction: column !important; /* Stacks the items vertically */
        align-items: flex-end !important;  /* Aligns everything to the right edge */
        justify-content: flex-start !important;
        position: absolute !important;
        top: 15px !important;
        right: 15px !important;
        z-index: 999 !important; 
    }

    ul.pkp_navigation_user {
        display: flex !important;
        flex-direction: row !important; /* Keeps Login and Register side-by-side */
        align-items: center !important;
        margin: 0 !important;
        padding: 0 !important;
        list-style: none !important;
    }

    ul.pkp_navigation_user > li {
        display: inline-flex !important;
        align-items: center !important;
        margin: 0 !important;
    }
    
    /* Spacing for the Search button below the Login button */
    .pkp_navigation_search_wrapper {
        margin-top: 10px !important; 
        margin-right: 10px !important; 
    }
}