/* STM_Style_Sect_NavBar.css */

/* Navigation Bar Container */
.navbar-section {
    position: fixed;
    width: 100%;
    height: 11rem;
    top: 0;
    z-index: 1000;
    overflow: hidden;
    margin: 0;
    padding: 0;
}

.navbar-section:before {
    content: "";
    display: block;
    width: 100%;
    max-width: 75rem; /* 1200px ÷ 16 = 75rem */
    margin: 0 auto;
    height:  100%; 
    background-image: url('../D_Asset/Sect_Nav_Bar_Background.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    z-index: -1;
}

/* Navbar Grid Layout */
.navbar-container {
    display: grid;  /*flex; */ /* grid; */
    flex-direction: row;
    grid-template-rows: auto 50px 60px; /* Fixed height for 3rd row */
    width: 100%;
    max-width: 75rem; /* 1200px ÷ 16 = 75rem */
    margin: 0 auto;
    /* padding: 10px 20px; */ /* Reduce top padding here */
    padding: 0 1.25rem; /* Reduce top padding here */
    box-sizing: border-box;
    position: relative;
}

/* First Row: Logo, STM Message, Bonhomme */
.navbar-row-1 {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    align-items: center;
    gap: 1.25rem; /* 20px ÷ 16 = 1.25rem */
    padding: 0px 0; /* Reduce top padding here */
    margin-top: 00px; /* Reduce or remove this margin */
}

.navbar-row-1 .logo-container {
    text-align: left;
}

.logo-container .logo {
    height:  2.5rem; /* 40px ÷ 16px = 2.5rem */
     margin-left: 1.25rem; /* 20px ÷ 16 = 1.25rem */
    transition: transform 0.3s;
}

.logo-container .logo:hover {
    /* transform: translate(3px, -3px); */
    transform: translate(0.1875rem, 0.1875rem);
}

.navbar-row-1 .stm-message {
    text-align: center;
    color: var(--Blue_Highlight_Dark);
    font-family: var(--Font_Primary); /*'Inter', sans-serif; */
    font-weight: 700;
    font-size:  var(--Font_Size_XS); /*14px; */
  /*  white-space: nowrap; */
   white-space: normal; /* Allow text to wrap */
    overflow-wrap: break-word; /* Ensure long words break and wrap */

    background-color: rgba(255, 255, 255, 0.5);
    width: 100%;
    padding: 0.5rem 0.75rem; /* 8px 12px; */
    border-radius: 0.625rem ;  /* 10px;*/
    display: inline-block;
}

.bonhommes-tool {
    height: var(--Icon_Bonhommes_Tool_Size);
    transition: transform 0.2s;
}

.logo-container .logo {
    height: var(--Logo_Size);
    margin-left: 1.25rem;
}

/*
.navbar-row-1 .bonhomme-container {
    text-align: right;
}

.bonhomme-container .bonhommes-tool {
    height: 75px;
    margin-top: 50;
    position: relative; 
}
*/
/*
.bonhomme-container .bonhomme-tool {
    height: 75px;
    transition: transform 0.3s;
    cursor: pointer;
}

.bonhomme-container .bonhomme-tool:hover {
    transform: translate(3px, -3px);
}
*/

/* Middle Row: Empty for Future Use */
.navbar-row-2 {
    height: 3.125rem ; /*50px; */
    background-color: rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: flex-end; /* Align content to the right */
    align-items: center;
}
.bonhomme-container {
    text-align: right;
    margin-top: 00px; /* Optional: Move down by 50 pixels if still needed */
}
.bonhommes-tool {
    height: 6.25rem ;  /* 100px; */
    margin-top: 00;
    position: relative; 
}
/* Third Row: Fixed height */
.navbar-row-3 {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 3.75rem ; /*60px;*/ /* Fixed height */
    padding: 0 0 5px 0;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1.25rem ;  /* 20px;*/
    margin: 0;
    padding: 0;
    height: 100%; /* Fill row height */
    align-items: center;
}

.nav-links a {
    /*
   color: var(--Blue_Logo);
    background-color: rgba(255, 255, 255, 0.4);
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    padding: 5px 10px;
    border-radius: 5px;
    transition: all 0.3s;
    height: 36px;
    line-height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transform-origin: center;
    */
    color: var(--Blue_Logo);
    background-color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-weight: 700;
    font-family: var(--Font_Primary); /* Use the primary font variable */
    font-size: var( --Icon_Font_Size);
    padding:  0.3125rem 0.625rem; /* 5px ÷ 16 = 0.3125rem, 10px ÷ 16 = 0.625rem */
    border-radius: 0.3125rem; /* 5px ÷ 16 = 0.3125rem */
    transition: all 0.3s;
    height: 2.25rem; /* 36px ÷ 16 = 2.25rem */
    line-height:  2.25rem; /* 36px ÷ 16 = 2.25rem */
    display: flex;
    align-items: center;
    position: relative;
}

.nav-links li a {
   padding-left: var(--Icon_Text_Padding);  /* Use the variable for padding */
}

.nav-links li:first-child a {
    /* padding-left: 30px;  */
    background-image: url('../D_Asset/Icon_Home.png');
    background-repeat: no-repeat;
    background-position: 0.625rem center;
    background-size: var( --Icon_Bar_Size); /* 20px; */
}

.nav-links li:nth-child(2) a {
    /* padding-left: 30px;  */
    background-image: url('../D_Asset/Icon_Prod.png');
    background-repeat: no-repeat;
    background-position: 0.625rem center;
    background-size: var( --Icon_Bar_Size); /* 20px; */
}

.nav-links li:nth-child(3) a {
    /* padding-left: 30px;  */
    background-image: url('../D_Asset/Icon_Service.png');
    background-repeat: no-repeat;
    background-position: 0.3125rem center;
    background-size: var( --Icon_Bar_Size); /* 20px; */
}

.nav-links li:nth-child(4) a {
    /* padding-left: 30px;  */
    background-image: url('../D_Asset/Icon_Company.png');
    background-repeat: no-repeat;
    background-position: 0.3125rem center;
    background-size: var( --Icon_Bar_Size); /* 20px; */
}

.nav-links li:nth-child(5) a {
    /* padding-left: 30px;  */
    background-image: url('../D_Asset/Icon_Contact.png');
    background-repeat: no-repeat;
    background-position: 0.3125rem center;
    background-size: var( --Icon_Bar_Size); /* 20px; */
}


/* Navigation Links Hover Effect */
.nav-links a:hover,
.nav-links a.active {
    background-color: rgba(255, 255, 255, 0.6);
    transform: scale(1.05);
    border: 1px solid var(--Blue_Highlight_Dark);
    border-radius: 0.3125rem ; /* 5px;*/
    z-index: 1;
}

/* Social Links */
.social-links {
    display: flex;
    gap: 0.9375rem; /* 15px ÷ 16 = 0.9375rem */
    align-items: center;
    height: 100%;
    margin-left: auto;
     margin-top: 1.25rem;
    margin-right: 1.25rem; /* 20px ÷ 16 = 1.25rem */
}

.social-links a {
    display: block;
    width: 2.5rem; /* 24px ÷ 16 = 1.5rem */
    height:2.5rem; /* 24px ÷ 16 = 1.5rem */
}

.social-icon {
    height: 2.5rem; /* 33px ÷ 16 = 2.0625rem */
    width: auto; /* 24px ÷ 16 = 1.5rem */
    transition: transform 0.1s;
}

.social-icon:hover {
    transform: scale(1.5);
}

    .menu-toggle {
        display: none;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0.625rem;
    }

/* Media query for phone displays */
@media screen and (max-width: 768px) {
   
    .navbar-section {
       height: var(--header-height);
    }
    .navbar .container {
        max-width: 48rem; /* 768px ÷ 16 = 48rem */
        display: flex;
        flex-direction: column;
        align-items: flex-start;
    }

    .bonhommes-tool {
        height: calc(var(--Icon_Bonhommes_Tool_Size) * 0.5); /* 50% of the nominal value */
        margin-right: 0.50rem;
    }

    .logo-container .logo {
        height: calc(var(--Logo_Size) * 0.5); /* 50% of the standard display */
        margin-top: 1.0rem;
        margin-left: 0.25rem;
    }

    .stm-message {
        font-size: calc(var(--Font_Size_XS) * 0.5); /* 60% of the normal font size */
    }

    .stm-message {
        width: 100%;
        margin-top: 0.625rem;
        padding: 0.300rem 0; /* 0.625rem 0; */
        text-align: center;
          white-space: normal; /* Ensure text wraps on small screens */
        word-wrap: break-word; /* Break long words if necessary */
        overflow-wrap: break-word; /* Ensure long words break and wrap */
    }

  
    .nav-links a {
        text-align: center;
    }
.nav-links li a {
   padding-left: var(--Reduced_Icon_Text_Padding);  /* Use the variable for padding */
}

    .social-links {
        margin-left: 0;
        margin-right: 0;
        justify-content: center;
    }

    .menu-toggle {
        display: block;
        /*
        background: none;
        border: none;
        cursor: pointer;
        padding: 0.625rem;
        */
    }

    /*
      .nav-links {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 0.3125rem;
        margin-left: 0;
    }
*/
 
 .nav-links {
    display: none; /* Hide the nav links by default on smaller screens */
    grid-auto-flow: row; /* Allow items to flow vertically */
    /* grid-auto-flow: column; */ /* Allow items to flow vertically */
    grid-template-columns: repeat(auto-fill, minmax(50%, 0.25fr)); /* Create columns that take up 50% of the available width */
    justify-content: center; /* Center items horizontally */
    align-items: center; /* Center items vertically */
    gap: 0.1125rem; /* Space between items */
    margin-left: 0;
    /* overflow-y: auto; */ /* Allow vertical scrolling if content overflows */
}

.nav-links {
    height: 0px; /* Fill row height */
}
.nav-links.active {
    display: grid; /* Show the nav links when active */
}

.nav-links a {
    background-position: 0.3125rem center;
    background-size: calc( var(--Reduced_Icon_Bar_Size)*0.5);
    padding: 0 var(--Reduced_Icon_Text_Padding); /* Only horizontal padding */
    font-size: var(--Reduced_Icon_Font_Size);
    
}

    .menu-toggle {
        background-color: rgba(255, 255, 255, 0.6); /* Background color for the rounded box */
        border-radius: 0.3125rem; /* Rounded corners */
        transform: translateY(-1.50rem); /* Move the content up by 2.50rem */
       /* transition: transform 0.3s; */ /* Smooth transition for the transform */
    }
    
    .menu-toggle:hover, .menu-toggle.active {
        /*transform: scale(1.05);*/ /* Scale up on hover or when active */
          border: 1px solid var(--Blue_Highlight_Dark);
           z-index: 1;
    }

    .menu-toggle-content {
        display: flex;
        align-items: center;

    }

    .menu-toggle-icon {
        width: 1.0rem;
        height: 1.0rem; 
        /*
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        */
    }

    .menu-toggle-icon span {
        display: block;
        width: 100%;
        height: 0.25rem;
        background: var(--Blue_Highlight_Dark);
    }

    .menu-text {
        color: var(--Blue_Logo);
        font-size: var(--Font_Size_XS); 
    }
    
    .social-links {
        display: flex;
        gap: 0.1rem; /* 15px ÷ 16 = 0.9375rem */
        align-items: center;
        height: 100%;
        margin-left: auto;
        margin-top: 0.5rem;
        margin-bottom: 2.5rem;
        margin-right: 0.5rem; /* 20px ÷ 16 = 1.25rem */
    }
    .social-links a {
        display: block;
        width: 3.0rem; /* 24px ÷ 16 = 1.5rem */
        height:1.5rem; /* 24px ÷ 16 = 1.5rem */
    }

    .social-icon {
        height: 1.25rem; /* 33px ÷ 16 = 2.0625rem */
        width: auto; /* 24px ÷ 16 = 1.5rem */
        margin: 0 0;
        transition: transform 0.3s;
    }

    .logo-container .logo:hover {
        /* transform: translate(3px, -3px); */
        transform: translate(0.1875rem, 0.1875rem);
    }

    .social-icon:hover {
        transform: scale(1.5);
    }

}
    