body {
  margin: 0;
  padding: 0;
  background-image: linear-gradient(125deg, rgb(0, 0, 0), rgb(68, 68, 68), rgb(0, 0, 0));
  color: #fff;
  transition: opacity 2s ease-out; /* 讓畫面淡出 */
  font-family: 'Noto Sans TC', 'Helvetica', sans-serif;
}
.button-group {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  padding: 8px 16px 0;
}
.button-group button {
  padding: 8px 16px;
  background: transparent;
  border: 1px solid rgb(207, 207, 207);
  border-radius: 10px;
  color: #fff;
  cursor: pointer;
  flex: none;
  letter-spacing: 0.2em;
  font-weight: 300;
  font-size: 0.9rem;
}
.gallery {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
  padding: 30px 60px;

}
.gallery-item {
  position: relative;
  flex: 0 0 calc(25% - 16px);
  aspect-ratio: 16 / 9;
  background: #222;
  border-radius: 15px;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(12, 12, 12, 0.7);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  font-weight:  300;
  font-size: 0.9rem;
  text-align: center;
  padding: 1rem;
  box-sizing: border-box;
  letter-spacing: 0.2em;
}
.gallery-item:hover .overlay {
  opacity: 1;
}

@media (max-width: 768px) {
  .button-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    grid-template-areas:
      "all all all"
      "brand package web";
  }
  .button-group button {
    width: 100%;
  }
  .button-group button:nth-child(1) {
    grid-area: all;
  }
  .button-group button:nth-child(2) {
    grid-area: brand;
  }
  .button-group button:nth-child(3) {
    grid-area: package;
  }
  .button-group button:nth-child(4) {
    grid-area: web;
  }
  .gallery-item {
    flex: 1 1 100%;
    aspect-ratio: 4 / 3;
  }
}


.close-btn {
  position: fixed;
  bottom: 5%;
  left: 10%;
  font-size: 1rem;
  font-weight: lighter;
  color: rgb(207, 207, 207);
  letter-spacing: 0.2rem;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2222!important;
  background-color: transparent !important; 
}

.contact-page header{
  z-index: 1116!important;
}


.close-btn:hover {
  background: rgb(207, 207, 207);
}

.button-group button.active {
  background-color: rgb(207, 207, 207);
  color: #000;
}

h2 {
  text-align: center;
  color: rgb(255, 255, 255);
  letter-spacing: 0.15em!important;
  margin-bottom: 8px; /* 新增這一行減少與下方段落距離 */
  letter-spacing: 0.05em;
  font-weight: normal;
  padding-top: 20px;
}