/* ==============================================
   ONE·LIFE WEDDING · 年华里摄影工作室 - 样式文件
   简约时尚 · 黑白金配色
   ============================================== */

/* ---------- CSS 变量 ---------- */
:root {
  --black: #1a1a1a;
  --dark: #2d2d2d;
  --gray-dark: #666;
  --gray: #999;
  --gray-light: #ddd;
  --gray-bg: #f7f7f7;
  --white: #fff;
  --gold: #C9A96E;
  --gold-dark: #b8944f;
  --gold-light: rgba(201, 169, 110, 0.08);
  --gold-glow: rgba(201, 169, 110, 0.3);
  --font: -apple-system, BlinkMacSystemFont, 'Segoe UI',
    'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei',
    'Helvetica Neue', Arial, sans-serif;
  --nav-height: 70px;
  --transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font);
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
  text-decoration: none;
}

/* ---------- 容器 ---------- */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- 占位图加载效果 ---------- */
img {
  background: var(--gray-bg);
}

/* ==============================================
   导航栏
   ============================================== */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  transition: background var(--transition), box-shadow var(--transition);
}

.header--scrolled {
  background: rgba(255, 255, 255, 0.97);
  box-shadow: 0 1px 12px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: baseline;
  gap: 8px;
  cursor: pointer;
}

.logo-main {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--black);
  transition: color var(--transition);
}

.header--scrolled .logo-main {
  color: var(--black);
}

.logo-sub {
  font-size: 0.75rem;
  color: var(--gray);
  letter-spacing: 2px;
}

/* 导航链接 */
.nav {
  display: flex;
  gap: 36px;
}

.nav-link {
  position: relative;
  font-size: 0.875rem;
  color: var(--gray-dark);
  letter-spacing: 1px;
  transition: color var(--transition);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--gold);
  transition: width var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--black);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* 汉堡菜单 */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  transition: var(--transition);
  transform-origin: center;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.hamburger.active span:nth-child(2) {
  opacity: 0;
}
.hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ==============================================
   Hero 轮播
   ============================================== */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}

.carousel {
  position: relative;
  width: 100%;
  height: 100%;
}

.carousel-slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  transition: opacity 1.2s ease;
}

.carousel-slide.active {
  opacity: 1;
}

.carousel-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 轮播遮罩 */
.carousel-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.35);
  z-index: 2;
  pointer-events: none;
}

.hero-title {
  font-size: clamp(2rem, 5vw, 4.5rem);
  font-weight: 300;
  letter-spacing: 8px;
  color: var(--white);
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
  animation: fadeUp 1s 0.3s both;
}

.hero-subtitle {
  text-align: center;
  white-space: pre-line;
  margin-top: 16px;
  font-size: clamp(0.875rem, 1.5vw, 1.125rem);
  letter-spacing: 4px;
  color: rgba(255, 255, 255, 0.85);
  font-weight: 300;
  animation: fadeUp 1s 0.6s both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 轮播指示点 */
.carousel-dots {
  position: absolute;
  bottom: 120px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 3;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.6);
  background: transparent;
  cursor: pointer;
  transition: var(--transition);
}

.carousel-dot.active {
  background: var(--white);
  border-color: var(--white);
  transform: scale(1.2);
}

/* 轮播箭头 */
.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 50px;
  height: 50px;
  border: none;
  background: rgba(255, 255, 255, 0.15);
  color: var(--white);
  font-size: 2rem;
  cursor: pointer;
  border-radius: 50%;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  backdrop-filter: blur(4px);
}

.carousel-arrow:hover {
  background: rgba(255, 255, 255, 0.3);
}

.carousel-arrow--prev {
  left: 24px;
}
.carousel-arrow--next {
  right: 24px;
}

/* 滚动提示 */
.scroll-hint {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  letter-spacing: 2px;
  animation: bounce 2s infinite;
}

.scroll-mouse {
  width: 22px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.5);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}

.scroll-wheel {
  width: 3px;
  height: 8px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 2px;
  animation: scrollWheel 1.5s infinite;
}

@keyframes scrollWheel {
  0% { opacity: 1; transform: translateY(0); }
  100% { opacity: 0; transform: translateY(10px); }
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* ==============================================
   通用区块
   ============================================== */
.section {
  padding: 100px 0;
}

.section--gray {
  background: var(--gray-bg);
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  font-weight: 300;
  letter-spacing: 4px;
  color: var(--black);
}

.section-desc {
  margin-top: 8px;
  font-size: 0.8rem;
  color: var(--gray);
  letter-spacing: 3px;
  text-transform: uppercase;
}

.divider {
  width: 40px;
  height: 2px;
  background: var(--gold);
  margin: 20px auto 0;
}

/* ---------- 淡入动画 ---------- */
.fade-in {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==============================================
   关于我们
   ============================================== */
.about-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.about-text p {
  font-size: 0.95rem;
  line-height: 1.9;
  color: var(--gray-dark);
}

.about-image {
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

.about-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.about-image:hover img {
  transform: scale(1.03);
}

/* ==============================================
   团队
   ============================================== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 30px;
  max-width: 860px;
  margin: 0 auto;
}

.team-card {
  background: var(--white);
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.04);
  transition: var(--transition);
}

.team-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

.team-card-avatar {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.team-card-body {
  padding: 16px 16px 20px;
}

.team-card-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--black);
}

.team-card-title {
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--gray);
  letter-spacing: 1px;
}

.team-card-price {
  display: inline-block;
  margin-top: 8px;
  padding: 3px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--gold-dark);
  background: var(--gold-light);
  border-radius: 20px;
}

.team-card-bio {
  margin-top: 10px;
  font-size: 0.8rem;
  line-height: 1.6;
  color: var(--gray-dark);
}

/* ==============================================
   作品集（瀑布流）
   ============================================== */
.portfolio-grid {
  column-count: 2;
  column-gap: 24px;
}

.portfolio-card {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  cursor: pointer;
  break-inside: avoid;
  margin-bottom: 24px;
}

.portfolio-card--3-2 { aspect-ratio: 3 / 2; }
.portfolio-card--2-3 { aspect-ratio: 2 / 3; }

.portfolio-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.portfolio-card:hover img {
  transform: scale(1.05);
}

.portfolio-card-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 30px 24px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
  color: var(--white);
  transition: var(--transition);
}

.portfolio-card-title {
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 2px;
}

.portfolio-card-count {
  margin-top: 4px;
  font-size: 0.8rem;
  opacity: 0.8;
  letter-spacing: 1px;
}

.portfolio-card:hover .portfolio-card-overlay {
  padding-bottom: 40px;
}

/* ==============================================
   联系我们
   ============================================== */
.contact-intro {
  text-align: center;
  font-size: 0.95rem;
  color: var(--gray-dark);
  letter-spacing: 2px;
  margin-bottom: 48px;
  line-height: 1.8;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  max-width: 800px;
  margin: 0 auto;
}

.contact-card {
  background: var(--white);
  border: 1px solid var(--gray-light);
  border-radius: 8px;
  padding: 32px 24px;
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition);
}

.contact-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
}

.contact-card--wechat {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.contact-card-icon {
  color: var(--gold);
  margin-bottom: 12px;
}

.contact-card-label {
  font-size: 0.75rem;
  color: var(--gray);
  letter-spacing: 2px;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.contact-card-value {
  font-size: 0.95rem;
  color: var(--dark);
  letter-spacing: 1px;
}

.contact-card-value a,
.contact-card a.contact-card-value {
  color: var(--dark);
  text-decoration: none;
  transition: color var(--transition);
}

.contact-card-value a:hover,
.contact-card a.contact-card-value:hover {
  color: var(--gold);
}

/* 微信二维码 - 居中大图 */
.contact-card--wechat .contact-qr {
  margin-top: 16px;
  width: 140px;
  height: 140px;
  border: 1px solid var(--gray-light);
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
}

.contact-card--wechat .contact-qr img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ==============================================
   页脚
   ============================================== */
.footer {
  background: var(--black);
  color: rgba(255, 255, 255, 0.6);
  padding: 40px 0;
  text-align: center;
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 24px;
  margin-bottom: 20px;
}

.footer-social a {
  font-size: 0.85rem;
  letter-spacing: 1px;
  color: rgba(255, 255, 255, 0.5);
  transition: color var(--transition);
}

.footer-social a:hover {
  color: var(--gold);
}

.footer-copy {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 1px;
}

/* ==============================================
   灯箱（Lightbox）
   ============================================== */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2000;
  background: rgba(0, 0, 0, 0.92);
  align-items: center;
  justify-content: center;
}

.lightbox.open {
  display: flex;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 2px;
  box-shadow: 0 10px 60px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border: none;
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  font-size: 1.25rem;
  cursor: pointer;
  border-radius: 50%;
  transition: var(--transition);
}

.lightbox-close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 50px;
  height: 50px;
  border: none;
  background: rgba(255, 255, 255, 0.08);
  color: var(--white);
  font-size: 2rem;
  cursor: pointer;
  border-radius: 50%;
  transition: var(--transition);
}

.lightbox-arrow:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-arrow--prev { left: 24px; }
.lightbox-arrow--next { right: 24px; }

.lightbox-counter {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.85rem;
  letter-spacing: 2px;
}

/* ==============================================
   响应式
   ============================================== */

/* 平板 */
@media (max-width: 1024px) {
  .team-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* 手机 */
@media (max-width: 768px) {
  .nav {
    position: fixed;
    top: 0;
    right: -100%;
    width: 260px;
    height: 100vh;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: var(--white);
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.08);
    transition: right var(--transition);
    gap: 32px;
  }

  .nav.open {
    right: 0;
  }

  .nav-link {
    font-size: 1rem;
  }

  .hamburger {
    display: flex;
  }

  .carousel-arrow {
    display: none;
  }

  .about-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about-image {
    order: -1;
  }

  .team-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }

  .team-card-body {
    padding: 14px;
  }

  .portfolio-grid {
    column-count: 1;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .contact-card--wechat {
    grid-column: 1;
  }

  .section {
    padding: 60px 0;
  }

  .section-header {
    margin-bottom: 40px;
  }

  .lightbox-arrow {
    width: 40px;
    height: 40px;
    font-size: 1.5rem;
  }

  .hero-title {
    letter-spacing: 4px;
    text-align: center;
    width: 100%;
    padding: 0 20px;
  }

  .hero-subtitle {
    text-align: center;
    width: 100%;
    padding: 0 20px;
  }
}

/* 小手机 */
@media (max-width: 480px) {
  .team-grid {
    grid-template-columns: 1fr;
  }
}
