/* ========================================
   NAVBAR CUSTOM STYLES
   ======================================== */

/* Top Nav - Add spacing below */
#top {
  margin-bottom: 20px !important;
}

/* Navbar Wrapper - Fixed and Thin */
.c-navbar-wrapper {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  z-index: 10000 !important;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

@media (min-width: 768px) {
  .c-navbar-wrapper {
    padding: 5px 0 !important;
  }
}

/* Apply background color from theme option */
.navbar-bg .c-navbar-wrapper {
  background: inherit;
}

/* Brand - Out of Flow (Absolute Positioning) */
.c-brand {
  position: absolute !important;
  top: 0 !important;
  left: 15px !important;
  z-index: 10001 !important;
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 10px;
}

/* Apply background color to brand from theme option */
.navbar-bg .c-brand {
  background: none;
}

/* Brand Logo Image - 75px x 112px */
.c-brand .c-logo img {
  width: 50px !important;
  height: 60px !important;
  object-fit: contain;
  transition: all 0.3s ease-in-out; /* Smooth transition for shrinking */
}

/* Brand Text Styles */
.c-brand h1 {
  font-size: 16px !important;
  margin: 0;
  transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
}

.c-brand h2 {
  font-size: 14px !important;
  margin: 0;
  transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
  white-space: normal;
  max-width: 400px; /* Adjust as needed to force wrap after approximately 5 words */
  word-wrap: break-word;
}

/* Smaller logo when scrolled */
.c-navbar-wrapper.scrolled .c-brand .c-logo img {
  width: 50px !important;
  height: 80px !important;
}

/* Smaller text when scrolled */
.c-navbar-wrapper.scrolled .c-brand h1 {
  font-size: 14px !important;
}

.c-navbar-wrapper.scrolled .c-brand h2 {
  font-size: 11px !important;
  transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
  white-space: normal;
  max-width: 600px; /* Adjust as needed to force wrap after approximately 5 words */
  word-wrap: break-word;
}

/* Logo styles */
.c-logo {
  display: flex;
  align-items: center;
  gap: 15px;
}

@media screen and (max-width: 768px) {
  .c-logo{
    margin-top: 10px;
  }
  #top .c-navbar .c-brand{
    padding: 0px;
  }
}

/* Mega Menu - Relative positioning within fixed navbar */
.c-mega-menu {
  position: relative !important;
  z-index: 10002 !important;
  background: transparent;
  transition: all 0.3s ease-in-out;
}

/* Add spacing for fixed navbar */
body {
  padding-top: 50px !important; /* Prevent content from hiding under fixed navbar */
}

/* Apply flexbox only on desktop to maintain mobile toggle functionality */
@media (min-width: 769px) {
  .c-mega-menu {
    display: flex !important;
    align-items: flex-end !important;
  }
}

/* Fix Quick Search Display */
.c-quick-search {
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
}

/* Enhanced Mega Menu when scrolled */
.c-mega-menu.scrolled {
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

/* Reduce menu item height */
.c-mega-menu .menu-item > a,
.c-mega-menu .c-menu > li > a {
  padding: 8px 15px !important;
  line-height: 1.4 !important;
}

.c-mega-menu .nav > li > a {
  padding-top: 10px !important;
  padding-bottom: 10px !important;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .c-brand .c-logo img {
    width: 50px !important;
    height: 75px !important;
  }
  
  .c-navbar-wrapper {
    flex-wrap: wrap;
  }
  
  .c-mega-menu {
    width: 100%;
    position: relative !important;
    margin: 60px 0 !important;
  }
}
@media (max-width: 767px) {
    #top .c-navbar .c-brand {
        float: none;
        margin: 1px 0;
        overflow: hidden;
        width: 100vw;
    }
    .navbar-bg .c-brand {
      background: inherit;
    }

    .c-brand {
      position: absolute !important;
      top: 0 !important;
      left: 0px !important;
      z-index: 10001 !important;
      display: flex;
      align-items: center;
      gap: 15px;
      padding: 10px;
  }
  
}

@media (max-width: 1536px) {
  .c-brand {
    width: 280px;
    left: 0px !important;
  }
  .c-brand h1 {
    font-size: 12px !important;
    margin: 0;
    transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
    white-space: normal;
    max-width: 200px; /* Adjust as needed to force wrap after approximately 5 words */
    word-wrap: break-word;
  }

  .c-brand h2 {
    font-size: 10px !important;
    margin: 0;
    transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
    white-space: normal;
    max-width: 240px; /* Adjust as needed to force wrap after approximately 5 words */
    word-wrap: break-word;
  }

  /* Smaller text when scrolled */
.c-navbar-wrapper.scrolled .c-brand h1 {
  font-size: 10px !important;
}

.c-navbar-wrapper.scrolled .c-brand h2 {
  font-size: 8px !important;
  transition: all 0.3s ease-in-out; /* Smooth transition for text shrinking */
  white-space: normal;
  max-width: 250px; /* Adjust as needed to force wrap after approximately 5 words */
  word-wrap: break-word;
}
.c-mega-menu {
    margin-left: 3em !important;
    position: relative !important;
  }

  
}
@media (max-width: 1280px) and (min-width: 1025px) {
  .c-mega-menu {
      margin-left: 290px !important;
      position: relative !important;
    }
}

@media (max-width: 1024px) and (min-width: 769px) {
  .c-mega-menu {
      margin-left: 200px !important;
      position: relative !important;
    }
  
  /* Reduce size of c-theme-nav menu items more aggressively */
  .c-theme-nav .menu-item > a,
  .c-theme-nav .c-menu > li > a,
  .c-theme-nav .nav > li > a {
    font-size: 10px !important;
    padding: 6px 8px !important;
    line-height: 1.2 !important;
  }
  
  /* Reduce gap between menu items more */
  .c-theme-nav .nav > li {
    margin-left: 2px !important;
    margin-right: 2px !important;
  }
  
  /* Reduce spacing in mega menu */
  .c-mega-menu .menu-item > a,
  .c-mega-menu .c-menu > li > a {
    padding: 6px 10px !important;
  }
}

.footer-top-right {
  width: 100%;
  overflow: hidden;
}


.aplikasi-wrapper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 10px;
}

.aplikasi-wrapper .aplikasi-item {
    background: #fff;
    padding: 10px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}
