* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Noto Sans TC', sans-serif;
}

html, body {
  height: 100%;
}

body {
  padding-top: 138px;
  overflow-x: hidden;
}

/* === Header Block === */
.header-block {
  background-color: white;
  z-index: 999;
  position: fixed;
  width: 100%;
  top: 0;
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  min-height: 110px;
}

.header-block.hide {
  transform: translateY(-100%);
}

/* === Top Bar === */
header.topbar {
  width: 100%;
  max-width: 1400px;
  background-color: white;
  padding: 1rem 2rem 0.5rem;
  position: relative;
}

.topbar-flex {
  max-width: 1200px;
  margin: 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  width: 100%;
  
}

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 15px;
}

.logo-wrap img {
  height: 40px;
  width: auto;
  max-height: 48px;
  object-fit: contain;
  display: block;
}

.logo-img {
  height: 40px;
  max-width: 100px;
  object-fit: contain;
}

/* === Language Switcher === */
.lang-switcher {
  position: static;
  transform: none;
  margin-top: 0;
  display: flex;
  justify-content: flex-end;
  width: auto;
}

.lang-switcher select {
  width: 175px;
  max-width: 90%;
}

/* === Navbar === */
.navbar {
  width: 100%;
  background-color: #003580;
  padding: 5px 0;
}

.navbar ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  list-style: none;
  padding: 0;
  margin: 0 auto;
  max-width: 1200px;
  gap: 20px;
}

.navbar li {
  margin: 0;
}

.navbar li a {
  color: white;
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.3s;
  text-align: center;
  display: inline-block;
  padding: 6px 8px;
}

/* Hover & Active */
.navbar li a:hover {
  color: #00bcd4;
}

/* === Responsive: Mobile (max-width: 768px) === */
@media (max-width: 768px) {
  body {
    padding-top: 100px;
  }

  .header-block {
    min-height: auto;
  }

  .logo-wrap {
    margin: 0 auto;
    justify-content: center;
  }

  .logo-wrap img {
    height: 28px;
    max-height: 30px;
  }

  .topbar-flex {
    padding: 0 10px;
  }

  .lang-switcher {
    margin-top: 15px;
  }

  .lang-switcher select {
    width: 100px;
    font-size: 0.95rem;
  }

  .navbar li a {
    padding: 8px 10px;
    font-size: 1rem;
  }

  .navbar ul {
    gap: 10px;
  }

  .hero-text {
    font-size: 1.6rem !important;
    padding: 20px !important;
    text-align: center !important;
  }

  .form-wrapper h3 {
    font-size: 1.6rem;
  }

  input,
  textarea,
  button {
    font-size: 1rem;
    padding: 10px !important;
  }

  .submit-btn {
    font-size: 1rem;
    padding: 12px;
  }

  .footer-nav a {
    font-size: 14px;
  }

  .footer-inner {
    padding: 20px !important;
    gap: 10px !important;
  }

  .contact-info-text h2 {
    font-size: 1.6rem !important;
    margin-bottom: 30px !important;
  }

  .contact-info-text p {
    font-size: 0.95rem !important;
    margin-bottom: 20px !important;
  }
  
}
  @media (max-width: 768px) {


  .navbar {
    padding: 60px 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 1px;
    overflow-y: auto;
  }

  .navbar ul {
    width: 100%;
    list-style: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
  }

  .navbar.show {
    display: flex !important;
  }

  .navbar li {
    width: 100%;
    text-align: center;
  }

  .navbar li a {
    width: 100%;
    margin: 0;
    padding: 6px 8px;
    display: block;
    font-weight: bold;
    font-size: 12.5px;
    color: white;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-sizing: border-box;
    position: relative;
  }

  .navbar li a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 2px;
    background-color: #00bcd4;
    opacity: 0;
    transition: opacity 0.3s ease;
  }

  .navbar li a.active::after {
    opacity: 1;
  }

  .navbar a {
    position: relative;
  }

      .header-block {
        min-height: 100px !important;
      }
      .topbar {
        padding: 32px 0 16px !important;
      }
      .logo-img {
        height: 44px !important;
        display: inline-block;
        vertical-align: middle;
      }
      .logo-wrap {
        display: flex;
        align-items: center;
        gap: 10px;
      }

    }
@media (max-width: 375px) {
  .logo-img {
    height: 18px;
  }
  .lang-switcher {
    width: 68px;
  }
  .lang-switcher select {
    font-size: 0.7rem;
    padding: 2px 2px;
  }
  .menu-toggle {
    left: 6px;
    top: 8px;
    font-size: 1.2rem;
  }
}
@media (min-width: 376px) and (max-width: 430px) {
  .logo-img {
    height: 22px;
  }
  .lang-switcher {
    width: 72px;
  }
  .lang-switcher select {
    font-size: 0.8rem;
    padding: 3px 4px;
  }
  .menu-toggle {
    left: 10px;
    top: 10px;
    font-size: 1.4rem;
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
    font-size: 1.4rem;
    background: none;
    border: none;
    color: #00bcd4;
    cursor: pointer;
    z-index: 1200;
    position: absolute;
    top: 12px;
    left: 10px;
    background-color: transparent !important;
    padding: 4px;
    border-radius: 6px;
    box-shadow: none;
  }

  .logo-flex {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    position: relative;
    padding: 6px 16px;
  }

  .logo-wrap {
    gap: 4px;
  }

  .logo-img {
    height: 20px;
  }

  .lang-switcher {
    right: 4px;
    width: 72px;
  }

  .lang-switcher select {
    font-size: 0.75rem;
    padding: 2px 4px;
  }
}