/* =============================
   Root Variables
     --section-spacing: 80px;
   ============================= */
:root {
  --primary-red: #9E1B1B;
  --secondary-cream: #F8F5F0;
  --text-dark: #333333;
  --accent-gold: #FFD700;
  --accent-gold-rgb: 255, 215, 0;
}

/* =============================
   Reset & Base Styles
   ============================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 130px;
}
body {
  font-family: Arial, 'Noto Sans HK', sans-serif;
  color: var(--text-dark);
  line-height: 1.6;
}

/* =============================
   Layout Helpers
   ============================= */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}
.center-container {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* =============================
   Header & Navigation
   ============================= */
header {
  background: linear-gradient(to right, #7A1515, rgb(194, 77, 77));
  color: white;
  padding: 15px 0;
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-content {
  display: flex;
}
.logo-title {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-grow: 1;
}
.logo-desktop {
  display: block;
  height: 100px;
  width: auto;
  margin-right: 15px;
}
.logo-mobile {
  display: none;
}
header h1 {
  font-size: 28px;
}
nav {
  text-align: center;
  margin-top: 10px;
  position: absolute;
  top: 90px;
  right: 30px;
}
nav ul {
  list-style: none;
}
nav ul li {
  display: inline;
  margin: 0 15px;
}
nav ul li a {
  color: white;
  text-decoration: none;
  font-weight: 600;
}
/* ,
.current-menu-item > a,
.current_page_item > a
*/
nav ul li a:hover,
nav ul li a.active,
.current-menu-item a{
  color: var(--accent-gold);
}
.nav-link {
  display: inline;
}
.nav-link[data-lang="en"] {
  display: none;
}
.lang-en .nav-link[data-lang="zh"] {
  display: none;
}
.lang-en .nav-link[data-lang="en"] {
  display: inline;
}

/* =============================
   Hamburger Menu
   ============================= */
.hamburger {
  display: none;
  font-size: 24px;
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  position: absolute;
  top: 20px;
  left: 20px;
}
.menu {
  display: flex;
  justify-content: center;
}
.menu.active {
  display: block;
}

/* =============================
   Language Switch
   ============================= */
.lang-switch {
  top: 20px;
  right: 20px;
}
.lang-btn {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid white;
  color: white;
  padding: 0.5rem 1rem;
  margin-left: 10px;
  cursor: pointer;
  border-radius: 4px;
  font-size: 14px;
  display: inline-block;
  text-decoration: none;
}
html[lang="zh-HK"] .lang-btn-zh {
  display: none;
}
html[lang="zh-HK"] .lang-btn-en {
  display: inline-block;
}
html[lang="en-US"] .lang-btn-en {
  display: none;
}
html[lang="en-US"] .lang-btn-zh {
  display: inline-block;
}

/* =============================
   Hero Section
   ============================= */
.hero {
  position: relative;
  text-align: center;
  padding: 0;
}
.hero .container {
  max-width: none;
  padding: 0;
}
.hero img {
  width: 100%;
  object-fit: cover;
  display: block;
}
.fallback-text {
  display: none;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  padding: 20px;
  background: rgba(0, 0, 0, 0.5);
  border-radius: 10px;
}
.fallback-text h2 {
  font-size: 40px;
  margin-bottom: 10px;
}
.fallback-text p {
  font-size: 20px;
}

/* =============================
   Sections & Cards
   ============================= */
section {
  padding: var(--section-spacing) 0;
}
section h2 {
  font-size: 32px;
  margin-bottom: 30px;
}
.section-head h2 {
  font-size: 32px;
  text-align: center;
  margin-bottom: 30px;
}
.about,
.team {
  background: var(--secondary-cream);
}
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
  grid-auto-rows: min-content;
}
.card {
  background: white;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  text-align: center;
}
.card h3 {
  font-size: 20px;
  margin-bottom: 10px;
}
.card p {
  font-size: 16px;
  color: #4b5563;
}
.card a {
  color: #2563eb;
  text-decoration: none;
}
.card a:hover {
  text-decoration: underline;
}
.card.clickable {
  cursor: pointer;
  transition: transform 0.2s;
}
.card.clickable:hover {
  transform: scale(1.05);
}

/* =============================
   About & Bio Sections
   ============================= */
.about-photo { width: 300px;}
.about-container,
.bio-container {
  max-width: 800px;
  display: flex;
  gap: 40px;
  align-items: flex-start;
  margin-bottom: 30px;
}
.about-content,
.bio-content {
  flex: 1;
}
.about p,
.mission p,
.mission ul {
  max-width: 800px;
  margin: 0 auto 20px;
  font-size: 16px;
}
.mission ul {
  list-style: disc;
  padding-left: 20px;
}
.mission li {
  margin-bottom: 10px;
}
.mission li strong {
  color: var(--primary-red);
  font-weight: bold;
}

/* =============================
   Utilities
   ============================= */
.team-photo {
  width: 30%;
  height: auto;
  margin-bottom: 20px;
  border-radius: 8px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: rgba(var(--accent-gold-rgb), 0.6); /* 0.6 表示60%透明度 */
  color: white;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: none;
  cursor: pointer;
  border: none;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
  font-size: 20px;
  text-align: center;
  line-height: 40px;
  z-index: 1;
}
footer {
  background: var(--primary-red);
  color: white;
  text-align: center;
  padding: 20px 0;
}

/* =============================
   Modal
   ============================= */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  justify-content: center;
  align-items: center;
}
.modal-content {
  background: white;
  max-width: 800px;
  width: 90%;
  max-height: 80vh;
  overflow-y: auto;
  padding: 20px;
  border-radius: 8px;
  position: relative;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}
.modal-content h3 {
  font-size: 24px;
  margin-bottom: 15px;
  color: var(--primary-red);
}
.modal-content p {
  margin-bottom: 15px;
  font-size: 16px;
  line-height: 1.8;
}
.modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: var(--primary-red);
  color: white;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-close:hover {
  background: #7A1515;
}

/* =============================
   Accessibility
   ============================= */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* =============================
   Keyframes
   ============================= */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =============================
   Media Queries
   ============================= */
@media (min-width: 1024px) {
	.grid {
		grid-template-columns: repeat(3, 1fr);
	}
}
@media (max-width: 1020px) {
  .lang-switch {
    position: absolute;
    top: 10px;
    right: 10px;
  }
  .hamburger {
    display: block;
    position: unset;
  }
  .menu {
    display: none;
    background: #7A1515;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    padding: 10px;
    z-index: 99;
    max-height: 90vh;
    overflow-y: auto;
  }
  nav {
  position: unset;
  top: unset;
  right: unset;
  }
  nav ul li {
    display: block;
    margin: 5px 0;
    text-align: right;
  }
  nav ul li a {
    display: block;
    padding: 8px;
    font-size: 16px;
  }
  .menu.active {
    display: block;
  }
}

@media (max-width: 768px) {
  html {
    scroll-padding-top: 190px;
  }
  .logo-desktop {
    display: none;
  }
  .logo-mobile {
    display: block;
  }
  .logo-title {
    flex-direction: column;
    align-items: center;
  }
  .logo {
    height: 150px;
    margin-right: 0;
    margin-bottom: 10px;
  }
  .hamburger {
    display: block;
    position: absolute;
  }
  nav {
    position: unset;
    top: unset;
    right: unset;
  }
  nav ul li {
    display: block;
    margin: 5px 0;
    text-align: left;
  }
  header h1 {
    font-size: 16px;
    white-space: nowrap;
  }
  header h1[data-lang="zh"] {
    font-size: 20px;
  }
  .lang-btn {
    padding: 0.3rem 0.8rem;
    font-size: 12px;
  }
  .modal-content {
    max-width: 95%;
    font-size: 14px;
  }
  section h2 {
    font-size: 28px;
  }
  .team-photo {
    width: 50%;
  }
  .about-container,
  .bio-container {
    flex-direction: column;
    align-items: center;
    gap: 20px;
  }
}
