/* --- GLOBAL VARIABLES & RESET --- */
:root {
  --primary-red: #d32f2f;
  --dark-red: #a51c1c;
  --text-dark: #333333;
  --text-gray: #666666;
  --bg-light: #f9f9f9;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Montserrat", sans-serif !important;
  color: var(--text-dark);
  line-height: 1.6;
  overflow-x: hidden;
}

/* --- SMOOTH SCROLLING --- */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0px 0;
}

/* --- GENERAL SECTIONS --- */
.red-section {
  background-color: var(--dark-red);
  color: white;
  padding: 20px 0;
}

.red-section h2 {
  font-size: 2.2rem;
  margin-bottom: 40px;
  font-weight: 700;
}

.section-desc {
  color: var(--text-gray);
  margin-bottom: 40px;
}

/* --- FOOTER --- */
.site-footer {
  background-color: #f4f4f4;
  padding: 70px 0 30px;
  width: 100%;
}

.footer-container {
  width: 90%;
  max-width: 1300px;
  margin: 0 auto;
}

.footer-top {
  text-align: center;
  margin-bottom: 60px;
}

.footer-logo {
  height: 100px;
  object-fit: contain;
  margin-bottom: 20px;
}

.footer-address {
  color: #a0a0a0;
  font-size: 0.9rem;
  line-height: 1.6;
  font-weight: 500;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #dddddd;
  padding-top: 30px;
}

.footer-copy {
  color: #a0a0a0;
  font-size: 0.9rem;
  font-weight: 500;
}

.footer-socials {
  display: flex;
  gap: 15px;
}

.footer-socials a {
  color: #333333;
  font-size: 20px;
  transition: color 0.3s ease, transform 0.3s ease;
}

.footer-socials a:hover {
  color: #df444c;
  transform: translateY(-3px);
}

/* --- NAVBAR STRUCTURE --- */
.navbar,
.nav-container {
  overflow: visible !important;
}

.nav-container {
  width: 90%;
  max-width: 1300px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center !important;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* --- LEFT & RIGHT CONTAINERS --- */
.nav-left {
  display: flex;
  align-items: center; /* Menyejajarkan secara vertikal */
  gap: 20px;
  flex-shrink: 0;
  z-index: 10;
  height: 100%; /* Memastikan kontainer mengisi penuh tinggi navbar */
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 15px;
  flex-shrink: 0;
  padding-left: 20px;
  z-index: 100 !important;
  position: relative;
  background: transparent;
}

/* --- NAV-CENTER DESKTOP --- */
.nav-center {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: safe center;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding-left: 15px;
  padding-right: 15px;
}

.nav-center::-webkit-scrollbar {
  display: none;
}

.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
  gap: 18px;
  margin: 0 !important; /* Disesuaikan agar menu awal tidak terpotong ke kiri */
  width: max-content;
  padding: 12px 0;
  white-space: nowrap;
}

.nav-links li {
  position: relative;
  display: flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}

/* --- LINK MENU PARENT --- */
.nav-links > li > .nav-item-link,
.nav-links > li > a {
  color: #ffffff !important;
  font-weight: 700;
  font-size: 12px;
  transition: all 0.3s ease;
  white-space: nowrap !important;
  display: inline-flex;
  align-items: center;
}

.lang-menu {
  color: #ffffff !important;
  font-weight: 700;
  font-size: 12px;
  transition: all 0.3s ease;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
}

/* HOVER EFFECT: UNDERLINE UNTUK SEMUA LINK NAVBAR */
.nav-links a:hover,
.dropdown-menu li a:hover,
.lang-menu:hover,
.search-icon:hover {
  text-decoration: underline !important;
}

/* --- STYLE ACTIVE KAPSUL GLASSMORPHISM --- */
.nav-links a.active,
.nav-links .nav-item-link.active {
  font-weight: 800 !important;
  background: rgba(255, 255, 255, 0.25) !important;
  border-radius: 10px !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  box-shadow: 0 0 0 0 rgba(31, 38, 135, 0.15),
              inset 0 0 12px 0 rgba(255, 255, 255, 0.35) !important;
  padding: 8px 14px !important;
  display: inline-flex !important;
  align-items: center !important;
  color: #ffffff !important;
}

/* Style Active khusus Child Item di dalam Dropdown */
.dropdown-menu li a.active,
.dropdown-menu li .nav-item-link.active {
  font-size: 12px !important;
  font-weight: 700 !important;
  background: rgba(255, 255, 255, 0.25) !important;
  border-radius: 8px !important;
  backdrop-filter: blur(12px) !important;
  -webkit-backdrop-filter: blur(12px) !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  box-shadow: 0 0 0 0 rgba(31, 38, 135, 0.15),
              inset 0 0 12px 0 rgba(255, 255, 255, 0.35) !important;
  padding: 6px 10px !important;
  display: block !important;
  color: #ffffff !important;
  text-decoration: none !important;
  white-space: normal !important;
  word-break: break-word !important;
  line-height: 1.4;
  max-width: 100% !important;
}

/* --- DROPDOWN SUBMENU LEVEL 1 (DESKTOP) --- */
.nav-links li.has-dropdown > .nav-item-link,
.nav-links li.has-dropdown > a {
  display: inline-flex !important;
  align-items: center;
  gap: 4px;
}

.dropdown-arrow {
  font-size: 9px;
  margin-left: 3px;
  flex-shrink: 0;
}

.nav-links .dropdown-menu {
  display: none;
  position: fixed !important;
  top: 55px;
  background: #1e1e1e;
  min-width: 240px;
  max-width: 340px;
  width: max-content;
  list-style: none;
  padding: 8px !important;
  margin-top: 0 !important;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0px 8px 20px rgba(0, 0, 0, 0.6);
  z-index: 999999 !important;
}

.nav-links .dropdown-menu::before {
  content: "";
  position: absolute;
  top: -20px;
  left: 0;
  width: 100%;
  height: 25px;
  background: transparent;
}

.nav-links > li:nth-last-child(-n+3) .dropdown-menu {
  left: auto !important;
  right: 120px !important;
}

.nav-links li:hover > .dropdown-menu {
  display: block !important;
}

/* --- SUBMENU REKURSIF LEVEL 2 (DESKTOP OVERFLOW POP-OUT) --- */
.dropdown-menu li {
  position: relative !important;
  margin-bottom: 4px;
  display: block;
  max-width: 100% !important;
}

.dropdown-menu li:last-child {
  margin-bottom: 0;
}

.nav-links .dropdown-menu .dropdown-menu {
  display: none;
  position: absolute !important;
  top: 0 !important;
  left: 100% !important;
  box-shadow: 0px 8px 20px rgba(0, 0, 0, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  background: #1e1e1e !important;
  margin: 0 0 0 6px !important;
  padding: 8px !important;
  border-radius: 8px !important;
  min-width: 220px !important;
  width: max-content !important;
  z-index: 1000000 !important;
}

.nav-links .dropdown-menu .dropdown-menu::before {
  content: "";
  position: absolute;
  top: 0;
  left: -10px;
  width: 12px;
  height: 100%;
  background: transparent;
}

.nav-links > li:nth-last-child(-n+3) .dropdown-menu .dropdown-menu {
  left: auto !important;
  right: 100% !important;
  margin: 0 6px 0 0 !important;
}

.nav-links > li:nth-last-child(-n+3) .dropdown-menu .dropdown-menu::before {
  left: auto;
  right: -10px;
}

/* Item Dropdown Default */
.dropdown-menu li a:not(.active),
.dropdown-menu li .nav-item-link:not(.active) {
  padding: 8px 14px;
  display: block;
  color: #ffffff !important;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  background: transparent !important;
  border: none !important;
  border-radius: 6px;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  box-shadow: none !important;
  transition: background-color 0.2s ease;
  white-space: normal !important;
  word-break: break-word !important;
  line-height: 1.4;
  max-width: 100% !important;
}

.dropdown-menu li a:not(.active):hover,
.dropdown-menu li .nav-item-link:not(.active):hover {
  background-color: rgba(255, 255, 255, 0.15) !important;
  text-decoration: underline !important;
}

/* --- LOGO & NAV RIGHT --- */
.logo-container {
  display: flex;
  align-items: center; /* Menyejajarkan pembungkus logo di tengah */
  justify-content: center;
  gap: 5px;
  height: 100%;
}
.logo-container a {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}
.nav-logo {
  height: 40px;
  width: auto;
  object-fit: contain;
  display: block; /* Menghilangkan gap bawaan elemen inline */
}

.nav-logo-2 {
  height: 80px;
  width: auto;
  object-fit: contain;
  display: block; /* Menghilangkan gap bawaan elemen inline */
}

.lang-menu {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  color: #ffffff !important;
  font-weight: 700;
  font-size: 14px;
}

.flag-circle {
  border-radius: 50%;
  object-fit: cover;
  display: block;
  width: 24px;
  height: 24px;
  pointer-events: none;
}

/* Dropdown Language */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 0px;
  background-color: #1e1e1e;
  min-width: 110px;
  box-shadow: 0px 8px 20px rgba(0, 0, 0, 0.6);
  border-radius: 8px;
  z-index: 999999 !important;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.dropdown:hover .dropdown-content,
.dropdown.active .dropdown-content {
  display: block;
}

.dropdown-content a {
  color: #ffffff !important;
  opacity: 1 !important;
  padding: 10px 14px;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 700;
  font-size: 12px;
  transition: background-color 0.2s ease;
}

.dropdown-content a:hover,
.dropdown-content a:active {
  background-color: rgba(255, 255, 255, 0.2) !important;
  color: #ffffff !important;
  text-decoration: underline !important;
}

.dropbtn.lang-menu {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #ffffff !important;
  text-decoration: none;
  font-weight: 700;
  font-size: 12px;
  padding: 6px 10px;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

/* --- NAVBAR HEADER --- */
.navbar-toggler {
  display: none; /* Dihapus !important agar media query bisa mengambil alih */
  justify-content: center;
  align-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  cursor: pointer;
  padding: 0;
  transition: background 0.3s ease;
}

.navbar-toggler:hover {
  background: rgba(255, 255, 255, 0.3);
}

.hamburger-box {
  width: 18px;
  height: 14px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.navbar-toggler .bar {
  display: block;
  width: 100%;
  height: 2px;
  background-color: #ffffff;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  padding: 0px;
  transition: all 0.3s ease;
  background: linear-gradient(
    180deg, 
    rgba(68, 68, 68, 0.2) 0%, 
    rgba(32, 32, 32, 0.2) 100%
  );
  backdrop-filter: blur(1px);
  -webkit-backdrop-filter: blur(1px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.navbar.sticky-active {
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
  border-top: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 
    inset 0 1px 1px rgba(255, 255, 255, 0.3),
    0 8px 32px 0 rgba(0, 0, 0, 0.37);
  background-color: rgba(1, 1, 1, 0.1);
}

/* --- RESPONSIVE MEDIA QUERIES --- */
@media (min-width: 1201px) and (max-width: 1440px) { 
  .navbar.sticky-active {
    position: fixed;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 260px;
    height: 6px;
    padding: 0 !important;
    background: rgba(255, 255, 255, 0.75) !important;
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25), 
                0 0 10px rgba(255, 255, 255, 0.4);
    overflow: visible !important;
    cursor: pointer;
  }

  .navbar.sticky-active .nav-container {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease;
  }

  .navbar.sticky-active:hover {
    top: 0;
    left: 0;
    transform: translateX(0);
    width: 100%;
    height: 80px;
    border-radius: 0;
    overflow: visible !important;
    background: linear-gradient(
      180deg, 
      rgba(20, 20, 20, 0.75) 0%, 
      rgba(10, 10, 10, 0.60) 100%
    ) !important;
    backdrop-filter: blur(2px) saturate(180%);
    -webkit-backdrop-filter: blur(2px) saturate(180%);
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35),
                inset 0 1px 0 rgba(255, 255, 255, 0.15);
  }

  .navbar.sticky-active:hover .nav-container {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.35s ease 0.1s;
  }

  .navbar.sticky-active:hover .nav-center {
    display: flex !important;
  }
} 

/* ========================================================= */
/* --- TABLET & MOBILE VIEW (MAX-WIDTH: 1200PX) PERBAIKAN --- */
/* ========================================================= */
@media (max-width: 1200px) { 
  .nav-logo-2 {
    height: 50px;
    width: auto;
    object-fit: contain;
  }

  .navbar-toggler {
    display: flex !important;
    justify-content: center;
    align-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
  }

  .navbar-toggler:active {
    transform: scale(0.95);
    background: rgba(255, 255, 255, 0.25) !important;
  }

  .nav-center {
    position: absolute !important;
    top: 100% !important;
    left: 0;
    width: 100%;
    padding: 0 !important;
    margin-bottom: 0 !important;
    background: rgba(18, 18, 18, 0.98) !important;
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    
    max-height: 0;
    overflow-y: auto !important;
    visibility: hidden;
    opacity: 0;
    transition: max-height 0.4s ease, opacity 0.3s ease, visibility 0.3s ease;
  }

  .nav-center.active {
    max-height: calc(100vh - 100%);
    visibility: visible;
    opacity: 1;
  }

  .nav-links {
    display: flex;
    flex-direction: column;
    align-items: stretch !important;
    width: 100% !important;
    padding: 15px 20px 30px 20px;
    margin: 0 !important;
    gap: 0;
    white-space: normal !important;
  }

  .nav-links li {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    width: 100%;
    max-width: 100% !important;
    white-space: normal !important;
  }

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

  .nav-links li .nav-item-link,
  .nav-links li a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 10px;
    color: #ffffff !important;
    font-size: 13px;
    font-weight: 600;
    width: 100%;
    max-width: 100% !important;
    white-space: normal !important;
    overflow: visible !important;
  }

  .nav-links li a:hover,
  .nav-links li .nav-item-link:hover {
    text-decoration: underline !important;
    padding-left: 14px;
  }

  .nav-links a.active,
  .nav-links .nav-item-link.active {
    border-radius: 6px !important;
    padding: 10px 12px !important;
    margin: 4px 0;
  }

  /* RESET SUPAYA DROPDOWN MOBILE BERGAYA ACCORDION BERSIH TANPA POSISI FIXED */
  .nav-links .dropdown-menu {
    position: static !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-shadow: none !important;
    border: none !important;
    background: rgba(255, 255, 255, 0.05) !important;
    padding: 0 0 0 15px !important;
    margin: 0 0 8px 0 !important;
    border-radius: 6px !important;
    right: auto !important;
    left: auto !important;
    top: auto !important;
  }

  .nav-links .dropdown-menu::before {
    display: none !important;
  }

  .nav-links .dropdown-menu .dropdown-menu {
    position: static !important;
    display: block !important;
    width: calc(100% - 10px) !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-shadow: none !important;
    border: none !important;
    background: rgba(255, 255, 255, 0.08) !important;
    padding: 4px 8px !important;
    margin: 4px 0 4px 10px !important;
    border-radius: 6px !important;
    right: auto !important;
    left: auto !important;
    top: auto !important;
  }

  .nav-links .dropdown-menu .dropdown-menu::before {
    display: none !important;
  }

  .dropdown-menu li a,
  .dropdown-menu li .nav-item-link {
    padding: 10px 12px !important;
    font-size: 12px !important;
  }
} 

@media (max-width: 1024px) { 
  .footer-address,
  .footer-copy {
    font-size: 0.8rem;
  }
} 

@media (max-width: 599px) { 
  .nav-logo-2 {
    height: 45px;
  }
  .site-footer {
    padding: 60px 0 30px;
  }
  .footer-top {
    margin-bottom: 50px;
  }
  .footer-address,
  .footer-copy {
    font-size: 0.75rem;
  }
} 

@media (max-width: 480px) { 
  .nav-logo-2 {
    height: 38px;
  }
  .site-footer {
    padding: 50px 0 30px;
  }
  .footer-top {
    margin-bottom: 40px;
  }
}

#main-content {
  min-height: 40vw;
}

.form-control:invalid, .form-control.is-invalid {
  padding: .5rem 1rem !important;
}

.text-danger {
  --bs-text-opacity: 1;
  color: rgba(192, 50, 33, var(--bs-text-opacity)) !important;
}

.invalid-feedback {
  display: none;
  width: 100%;
  margin-top: 0.25rem;
  font-size: 0.875em;
  color: #c03221;
}

@media (max-width: 768px) { 
  .flag-circle {
    width:22px;
    height: 22px;
  }
  .dropbtn.lang-menu {
    font-size: 10px;
  }
  .hamburger-box {
    width: 14px;
    height: 10px;
  }
  .navbar-toggler {
    width: 25px;
    height: 25px;
  }
} 