/* ===== CSS VARIABLES ===== */
:root {
  /* Colors */
  --primary-color: #000000;
  --secondary-color: #1a1a1a;
  --accent-color: #333333;
  --text-primary: #ffffff;
  --text-secondary: #cccccc;
  --text-white: #ffffff;
  --bg-white: #000000;
  --bg-light: #1a1a1a;
  --bg-overlay: rgba(0, 0, 0, 0.9);

  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
  --gradient-hero: linear-gradient(135deg, rgba(0, 0, 0, 0.8) 0%, rgba(26, 26, 26, 0.9) 100%);
  --gradient-overlay: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, 0.7) 100%);

  /* Typography */
  --font-primary: 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  /* Spacing */
  --container-max-width: 1200px;
  --section-padding: 80px 0;
  --element-margin: 2rem;

  /* Shadows */
  --shadow-light: 0 2px 10px rgba(0, 0, 0, 0.1);
  --shadow-medium: 0 4px 20px rgba(0, 0, 0, 0.15);
  --shadow-heavy: 0 8px 30px rgba(0, 0, 0, 0.2);

  /* Transitions */
  --transition-fast: 0.2s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Border Radius */
  --border-radius-small: 4px;
  --border-radius-medium: 8px;
  --border-radius-large: 16px;
}

/* ===== RESET & BASE STYLES ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-primary);
  font-weight: var(--font-weight-normal);
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-white);
  overflow-x: visible;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-normal);
}

button {
  border: none;
  background: none;
  cursor: pointer;
  font-family: inherit;
  transition: var(--transition-normal);
}

ul {
  list-style: none;
}

/* ===== LOADING SCREEN ===== */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-white);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  transition: opacity var(--transition-slow), visibility var(--transition-slow);
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-content {
  text-align: center;
  color: var(--text-primary);
}

.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(0, 0, 0, 0.3);
  border-top: 3px solid var(--text-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ===== HEADER & NAVIGATION ===== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: transparent;
  z-index: 1000;
  transition: var(--transition-normal);
}

.nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 2rem;
  max-width: var(--container-max-width);
  margin: 0 auto;
}

.nav__logo h1 a {
  font-size: 1.5rem;
  font-weight: var(--font-weight-bold);
  color: var(--text-white);
}

.nav__menu {
  display: flex;
  gap: 2rem;
}

.nav__link {
  font-weight: var(--font-weight-medium);
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius-medium);
  position: relative;
  transition: var(--transition-normal);
  color: var(--text-white);
}

.nav__link:hover,
.nav__link.active {
  color: var(--text-white);
  background: rgba(255, 255, 255, 0.1);
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--text-white);
  transition: var(--transition-normal);
  transform: translateX(-50%);
}

.nav__link:hover::after,
.nav__link.active::after {
  width: 80%;
}

.nav__toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
}

.nav__toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-white);
  transition: var(--transition-normal);
}

/* ===== MAIN CONTENT ===== */
.main {
  margin-top: 60px;
}

.container {
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-title {
  font-size: 2.5rem;
  font-weight: var(--font-weight-bold);
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.section-subtitle {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin: 0 auto;
}

/* ===== HEADER AUTO HIDE ===== */
.header {
  transform: translateY(0);
  transition: transform 0.3s ease;
}

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

/* ===== HERO SECTION ===== */
.hero {
  padding: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-light);
}

/* ===== Hero Grid Styles ===== */
.hero-grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0; /* No gap between panels */
    width: 100%;
    height: 100vh;
}

.hero-grid__item {
    position: relative;
    overflow: hidden;
    height: 100%;
    margin: 0;
    padding: 0;
    border: none;
}

.hero-grid__image {
    width: 100%;
    height: 100%;
    object-fit: cover; /* This will crop the image to fit the panel */
    transition: transform 0.4s ease, filter 0.4s ease;
    margin: 0;
    padding: 0;
    border: none;
    display: block;
}

.hero-grid__item:hover .hero-grid__image {
    transform: scale(1.05);
    filter: brightness(1.1);
}

.hero-grid__overlay {
    display: none; /* 完全隐藏overlay和标题 */
}

.hero-grid__title {
    display: none; /* 完全隐藏标题 */
}

/* Responsive adjustments for hero grid */
@media (max-width: 1024px) {
    .hero-grid-container {
        grid-template-columns: repeat(2, 1fr);
        height: auto; /* 允许高度自适应 */
    }

    .hero-grid__item {
        height: auto; /* 允许每个项目自适应高度 */
    }

    .hero-grid__image {
        height: auto; /* 图片高度自适应 */
        width: 100%;
    }
}

@media (max-width: 767px) {
    .hero {
        height: auto; /* 允许hero区域自适应内容高度 */
    }

    .hero-grid-container {
        grid-template-columns: 1fr; /* 单列显示 */
        height: auto; /* 允许高度自适应 */
        gap: 0;
    }

    .hero-grid__item {
        width: 100%;
        height: auto; /* 高度自适应图片 */
        position: relative;
    }

    .hero-grid__image {
        width: 100%;
        height: auto; /* 图片高度自适应原始比例 */
        object-fit: contain; /* 完整显示图片，不裁剪 */
        display: block;
        background: var(--bg-light); /* 避免留白时显得突兀 */
    }
}

/* ===== Gallery Section Overrides ===== */
.gallery-section {
    padding: 0;
}

#waterfall-gallery-container {
    width: 100%;
    max-width: none;
    padding: 0;
    box-sizing: border-box;
}

/* ===== Fullscreen Album Waterfall Styles ===== */
#fullscreen-waterfall-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

#fullscreen-waterfall-container .waterfall-gallery__grid {
    gap: 1rem; /* Add gap between columns */
}

#fullscreen-waterfall-container .waterfall-gallery__column {
    gap: 1rem; /* Add gap between items */
}

#fullscreen-waterfall-container .waterfall-gallery__item {
    box-shadow: none;
    border-radius: 0;
    overflow: hidden;
    margin-bottom: 0; /* Reset any margin */
}

/* Responsive styles for fullscreen album */
@media (max-width: 768px) {
    #fullscreen-waterfall-container {
        padding: 0 1rem;
    }

    #fullscreen-waterfall-container .waterfall-gallery__grid {
        gap: 0.5rem;
    }

    #fullscreen-waterfall-container .waterfall-gallery__column {
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    #fullscreen-waterfall-container {
        padding: 0 0.5rem;
    }
}

/* ===== About Section ===== */
.about-section {
    padding: 80px 0;
    background: #000000;
}

.about__content {
    max-width: 600px;
    margin: 0 auto;
    text-align: left;
}

.about__text {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.about__text .section-title {
    color: rgba(255, 255, 255, 0.95);
    font-size: 2.8rem;
    font-weight: 300;
    margin-bottom: 0;
    letter-spacing: 0.5px;
}

.contact-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-bottom: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.contact-button:hover {
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 1);
}

.contact-button svg {
    flex-shrink: 0;
}



.about__intro {
    max-width: 600px;
}

.about__subtitle {
    font-size: 1.3rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 1.5rem;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.about__main-description {
    font-size: 1.4rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 300;
    margin: 0;
}

.about__footer {
    margin-top: auto;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.about__copyright {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
    font-weight: 300;
}

/* About Section Responsive */
@media screen and (max-width: 768px) {
    .about__content {
        text-align: center;
    }

    .about__text .section-title {
        font-size: 2.2rem;
    }

    .about__subtitle {
        font-size: 1.1rem;
    }

    .about__main-description {
        font-size: 1.2rem;
        line-height: 1.7;
    }
}

.about__stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.stat__number {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
}

.stat__label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ===== Footer ===== */
.footer {
    background: #000000;
    padding: 3rem 0 2rem;
    color: rgba(255, 255, 255, 0.8);
}

.footer__content {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    text-align: center;
    align-items: center;
}

.footer__info h3 {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.footer__info p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
}

.footer__links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.footer__links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer__links a:hover {
    color: rgba(255, 255, 255, 0.9);
}

.footer__social p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    font-style: italic;
}

.footer__bottom {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.footer__bottom a {
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
}

.footer__bottom a:hover {
    color: rgba(255, 255, 255, 0.8);
}

