@import url('https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Quicksand:wght@300..700&display=swap');

:root {
  --header-height: 150px;
  --white: #ffffff;
  --dark: #0f0f0f;
  --text: #0a0a0a;
  --muted: #666666;
  --accent: #0c71c3;
  --nav-link-blue: #0f4ac0;
  --nav-link-blue-active: #4f8de2;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Nunito Sans', 'Quicksand', 'STHeiti', '微軟正黑體', 'Microsoft JhengHei', 'Heiti SC', sans-serif;
  color: var(--text);
  background: linear-gradient(rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0.5)),
    url("image/background-pantone.jpg") center/cover no-repeat;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  background: var(--white);
  z-index: 1000;
  border-bottom: 1px solid #e6e6e6;
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo {
  width: 450px;
  height: auto;
  object-fit: contain;
}

.brand-name {
  font-size: 1.75rem;
  font-weight: 700;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex: 1;
  justify-content: flex-end;
  min-width: 420px;
  max-width: 760px;
}

.nav-links a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.25rem;
  background: transparent;
  border: none;
  cursor: pointer;
}

.nav-links a.eng-link {
  color: var(--nav-link-blue);
}

.nav-links a.eng-link:active {
  color: var(--nav-link-blue-active);
}

.nav-links a.eng-link:focus-visible,
.nav-links a.eng-link:hover {
  color: var(--nav-link-blue-active);
}

.mobile-nav a.eng-link {
  color: var(--nav-link-blue);
}

.mobile-nav a.eng-link:active,
.mobile-nav a.eng-link:focus-visible,
.mobile-nav a.eng-link:hover {
  color: var(--nav-link-blue-active);
}

.dropdown-toggle {
  color: var(--text);
  text-decoration: none;
  font-weight: 400;
  font-size: 1.25rem;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dropdown-toggle::after {
  content: '▼';
  font-size: 0.75rem;
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  right: 0;
  top: 100%;
  background: var(--white);
  min-width: 180px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  border: 1px solid #ddd;
  border-radius: 6px;
  overflow: hidden;
  margin-top: 12px;
  z-index: 2000;
}

.dropdown-menu a {
  display: block;
  padding: 12px 16px;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.dropdown-menu a:hover {
  background: #f4f4f4;
}

.dropdown.open .dropdown-menu {
  display: block;
}

.mobile-menu-toggle {
  display: none;
  font-size: 1.8rem;
  border: none;
  background: transparent;
  cursor: pointer;
}

.mobile-nav {
  display: none;
  flex-direction: column;
  background: var(--white);
  position: absolute;
  left: 0;
  right: 0;
  top: var(--header-height);
  border-bottom: 1px solid #e6e6e6;
  padding: 16px 24px;
  gap: 10px;
}

.mobile-nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.hero-carousel {
  padding-top: var(--header-height);
}

.carousel {
  position: relative;
  height: 500px;
  overflow: hidden;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transition: opacity 0.8s ease;
}

.slide.active {
  opacity: 1;
}

.slide-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: rgba(0, 0, 0, 0.28);
}

.slide-caption h1 {
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 4rem);
  margin: 0;
  padding: 0 16px;
}

.carousel-controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  display: flex;
  justify-content: space-between;
  transform: translateY(-50%);
  pointer-events: none;
}

.carousel-controls button {
  pointer-events: all;
  border: none;
  background: rgba(255, 255, 255, 0.75);
  color: var(--dark);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.6rem;
  margin: 0 16px;
}

.gallery-section {
  max-width: 1200px;
  margin: 40px auto 80px;
  padding: 0 24px;
}

.gallery-section h2 {
  font-size: 2rem;
  margin-bottom: 24px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
}

.about-section {
  max-width: 1200px;
  margin: 40px auto;
  padding: 40px 24px;
  background: url("image/pexels-artempodrez-7048040-new.jpg") center/cover no-repeat;
  border-radius: 20px;
  scroll-margin-top: calc(var(--header-height) + 20px);
}

.about-content {
  max-width: 1200px;
  margin: 0 auto;
}

.about-section h1 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.about-section p {
  line-height: 1.8;
  font-size: 1.1rem;
  color: #222222;
  margin: 0;
}

.gallery-item {
  background: #ffffff;
  border-radius: 14px;
  overflow: hidden;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 16px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  cursor: pointer;
  position: relative;
  touch-action: manipulation;
}

.gallery-item::after {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 24px;
  color: #ffffff;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.25s ease;
  background: linear-gradient(to top, rgba(12, 113, 195, 0.72), transparent 50%);
  z-index: 0;
  pointer-events: none;
}

.gallery-item:hover,
.gallery-item.active,
.gallery-item:active,
.gallery-item:focus-within {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.18);
  background: radial-gradient(circle at center, rgba(255, 255, 255, 1) 0%, rgba(235, 245, 255, 0.95) 40%, rgba(54, 116, 116, 0.95) 100%);
}

.gallery-item:hover::after,
.gallery-item.active::after,
.gallery-item:active::after,
.gallery-item:focus-within::after {
  opacity: 1;
}

.gallery-item img {
  width: 100%;
  height: 300px;
  object-fit: contain;
  margin-bottom: 16px;
  transition: transform 0.35s ease;
  position: relative;
  z-index: 1;
}

.gallery-item.active img,
.gallery-item:active img,
.gallery-item:focus-within img {
  transform: scale(1.05);
}

.gallery-item.active p,
.gallery-item:active p,
.gallery-item:focus-within p {
  color: var(--nav-link-blue);
}

.gallery-item:hover img,
.gallery-item:focus-within img {
  transform: scale(1.05);
}

.gallery-item p {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  position: relative;
  z-index: 1;
  transition: color 0.25s ease;
}

.gallery-item:hover p,
.gallery-item:focus-within p {
  color: var(--nav-link-blue);
}

.site-footer {
  background: var(--dark);
  color: var(--white);
  padding: 40px 24px 24px;
}

.footer-content {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  max-width: 1200px;
  margin: 0 auto;
}

.footer-left,
.footer-right {
  flex: 1 1 45%;
  min-width: 280px;
}

.footer-right {
  margin-top: 24px;
}

.footer-logo {
  font-size: 23px;
  font-weight: 700;
  margin-bottom: 18px;
}

.site-footer h3 {
  margin: 8px 0 10px;
  font-size: 1.1rem;
}

.site-footer p {
  margin: 8px 0;
  color: #dcdcdc;
}

.site-footer a[href^="mailto:"] {
  color: var(--white);
  text-decoration: none;
}
.site-footer a[href^="mailto:"]:hover,
.site-footer a[href^="mailto:"]:focus {
  color: var(--white);
  text-decoration: none;
}

/* Footer website link: default white, clicked/visited -> light blue */
.site-footer a[href*="creditppl.hk"] {
  color: var(--white);
  text-decoration: none;
}
.site-footer a[href*="creditppl.hk"]:hover,
.site-footer a[href*="creditppl.hk"]:focus,
.site-footer a[href*="creditppl.hk"]:active {
  color: #8fcfff;
}
.site-footer a[href*="creditppl.hk"]:visited {
  color: #8fcfff;
}

.footer-bottom {
  border-top: 1px solid #333;
  padding-top: 16px;
  margin-top: 24px;
  text-align: center;
}

@media (max-width: 960px) {
  .header-inner {
    padding: 0 16px;
  }

  .logo {
    width: min(320px, 30vw);
  }

  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .nav-links {
    display: none;
  }

  .header-inner {
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
  }

  .brand {
    width: 100%;
  }

  .logo {
    width: 100%;
    max-width: 100%;
    height: auto;
  }

  .mobile-menu-toggle {
    display: block;
    order: 1;
    margin: 12px 0 0;
    align-self: flex-end;
  }

  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .footer-content {
    flex-direction: column;
  }

  .mobile-nav {
    display: none;
  }

  .mobile-nav.open {
    display: flex;
  }
}
