/*
Theme Name: 予晴影像 Yuching Photo
Theme URI: https://yuchingphoto.com
Author: Alice / Yuching Photo
Author URI: https://yuchingphoto.com
Description: 予晴影像官方網站主題。自然簡約、溫柔質感攝影品牌。昭源宋體 + Cormorant Garamond。
Version: 1.4.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: Private
Text Domain: yuching
Tags: photography, portfolio, custom-colors, full-width-template
*/

/* ══════════════════════════════════════════
   DESIGN TOKENS
══════════════════════════════════════════ */
:root {
  --cream: #F8F4EF;
  --cream-dark: #EDE7DE;
  --cream-mid: #F2EDE6;
  --ink: #221E18;
  --ink-light: #6B6058;
  --ink-muted: #A09488;
  --accent: #C9A882;
  --accent-soft: #E8D8C4;
  --white: #FDFAF7;
  --nav-h: 72px;
}

/* ══════════════════════════════════════════
   RESET — 覆蓋 Elementor / Hello 主題殘留樣式
══════════════════════════════════════════ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  overflow-x: clip !important;
  width: 100%; max-width: 100%;
  scroll-behavior: smooth;
}
body {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', 'Georgia', serif !important;
  background: var(--cream) !important;
  color: var(--ink) !important;
  font-weight: 400;
  line-height: 1.8;
  /* 消除 Elementor admin bar 補白 */
  margin-top: 0 !important;
  padding-top: 0 !important;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; }
.en { font-family: 'Cormorant Garamond', serif; }

/* 清除 WordPress / Elementor 預設間距 */
.site, .site-content, #content, .elementor-section-wrap,
#page, .hfeed { margin: 0 !important; padding: 0 !important; }
p { margin: 0; }

/* ══════════════════════════════════════════
   NAVIGATION
   關鍵修正：
   - 首頁 (body.home) → nav 透明 + 白色字（因為有全屏 Hero）
   - 其他頁 → nav 直接顯示奶油背景 + 深色字（無 Hero 大圖）
══════════════════════════════════════════ */
nav#mainNav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.2rem 6vw;
  height: var(--nav-h);
  transition: background .4s, border-color .4s, padding .4s;
  border-bottom: .5px solid rgba(44,40,32,.08);
  /* 非首頁：完全不透明奶油色，無 blur，無白條 */
  background: #F8F4EF;
}

/* 首頁：導覽列預設透明（JS 滾動後才加 .scrolled） */
body.home nav#mainNav {
  background: transparent;
  border-bottom-color: transparent;
}
body.home nav#mainNav.scrolled {
  background: rgba(248,244,239,.96);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: rgba(44,40,32,.08);
}

/* Logo — 主字用昭源宋體，小字用 Cormorant */
.nav-logo {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', 'Noto Serif TC', 'Georgia', serif;
  font-weight: 400;
  font-size: 1.15rem;
  letter-spacing: .18em;
  line-height: 1.3;
  text-decoration: none;
  transition: color .35s;
  color: var(--ink);
  white-space: nowrap;
}
.nav-logo small {
  font-family: 'Cormorant Garamond', serif;
  display: block; font-size: .46rem;
  letter-spacing: .48em; opacity: .55; margin-top: 2px;
  font-weight: 300;
}

.nav-logo-main {
  display: block;
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', 'Noto Serif TC', 'Georgia', serif;
  font-size: 1.15rem;
  font-weight: 400;
  letter-spacing: .18em;
  color: inherit;
}

/* 首頁 Logo 白色；滾動後變深色 */
body.home nav#mainNav:not(.scrolled) .nav-logo { color: #fff; }
body.home nav#mainNav.scrolled .nav-logo { color: var(--ink); }

/* Hamburger */
.nav-hamburger {
  display: flex; align-items: center; gap: 10px;
  cursor: pointer; background: none; border: none;
  z-index: 400; padding: 4px 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: .6rem; letter-spacing: .4em;
  text-transform: uppercase;
  transition: color .35s;
  /* 預設深色（非首頁） */
  color: var(--ink);
}
body.home nav#mainNav:not(.scrolled) .nav-hamburger { color: #fff; }
body.home nav#mainNav.scrolled .nav-hamburger { color: var(--ink); }
.nav-hamburger.open { color: var(--ink) !important; }
.nav-hamburger span { display: none; }

/* Overlay */
.nav-overlay {
  position: fixed; inset: 0;
  background: rgba(34,30,24,0);
  pointer-events: none; z-index: 8000;
  transition: background .45s;
}
.nav-overlay.open {
  background: rgba(34,30,24,.38);
  pointer-events: all;
}

/* Drawer Menu */
.nav-menu {
  position: fixed; top: 0; right: 0;
  width: min(380px, 88vw); height: 100dvh;
  background: var(--white);
  display: flex; flex-direction: column;
  padding: 6rem 3.5rem 4rem;
  transform: translateX(100%);
  transition: transform .45s cubic-bezier(.16,1,.3,1);
  z-index: 9000; overflow-y: auto; overflow-x: hidden;
}
.nav-menu.open { transform: translateX(0); }

.menu-cat {
  font-family: 'Cormorant Garamond', serif;
  font-size: .55rem; letter-spacing: .5em;
  color: var(--accent); text-transform: uppercase;
  margin-bottom: .7rem; padding-bottom: .55rem;
  border-bottom: .5px solid var(--cream-dark);
}
.menu-acc-btn {
  width: 100%; background: none; border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between;
  padding: .3rem 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.5rem; font-weight: 300;
  color: var(--ink); letter-spacing: .04em;
  text-decoration: none; transition: color .2s;
}
.menu-acc-btn:hover { color: var(--accent); }
.menu-acc-arrow {
  display: inline-flex; align-items: center;
  flex-shrink: 0; transition: transform .3s;
}
.menu-acc-arrow svg { width: 16px; height: 16px; stroke: var(--ink-muted); stroke-width: 1.5; fill: none; }
.menu-acc-btn[aria-expanded="true"] .menu-acc-arrow { transform: rotate(180deg); }
.menu-acc-body { overflow: hidden; max-height: 0; transition: max-height .35s ease; }
.menu-acc-body.open { max-height: 300px; }
.menu-sub {
  display: block;
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .8rem; color: var(--ink-muted); text-decoration: none;
  padding: .4rem 0 .4rem 1rem;
  border-left: .5px solid var(--cream-dark); margin-left: .15rem;
  transition: color .2s, border-color .2s;
}
.menu-sub:hover { color: var(--ink); border-color: var(--accent); }
.menu-section { margin-bottom: 2.2rem; }
.menu-divider { height: .5px; background: var(--cream-dark); margin: .5rem 0 1.8rem; }
.menu-contact {
  margin-top: auto;
  font-family: 'Cormorant Garamond', serif;
  font-size: .72rem; letter-spacing: .28em;
  color: var(--ink-muted); text-decoration: none;
  transition: color .2s;
}
.menu-contact:hover { color: var(--accent); }

/* ══════════════════════════════════════════
   HERO（首頁全屏）
══════════════════════════════════════════ */
#hero {
  position: relative; width: 100%; height: 100dvh;
  overflow: hidden;
}
/* 非首頁頁面需要 nav 高度補白 */
body:not(.home) { padding-top: var(--nav-h); }

.slide {
  position: absolute; inset: 0; opacity: 0;
  transition: opacity 1.4s ease;
  display: flex; align-items: center; justify-content: center;
}
.slide.active { opacity: 1; }
.slide-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  transform: scale(1.06); transition: transform 8s ease;
}
.slide.active .slide-bg { transform: scale(1); }
.slide:nth-child(1) .slide-bg { background-color: #D4C5B2; }
.slide:nth-child(2) .slide-bg { background-color: #C8BAA8; }
.slide:nth-child(3) .slide-bg { background-color: #BFB09E; }
.slide:nth-child(4) .slide-bg { background-color: #D9CCBB; }
.slide:nth-child(5) .slide-bg { background-color: #CAB9A6; }
.slide::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to bottom,
    rgba(34,30,24,.12) 0%,
    rgba(34,30,24,.04) 40%,
    rgba(34,30,24,.52) 100%);
}
.slide-caption {
  position: relative; z-index: 2;
  text-align: center; color: #fff; padding: 0 8vw;
}
.slide-caption-sub {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(.58rem,.85vw,.7rem);
  letter-spacing: .55em; text-transform: uppercase;
  opacity: .72; margin-bottom: 1.2rem; display: block;
}
.slide-caption-title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  font-size: clamp(2.4rem, 5.5vw, 5rem);
  line-height: 1.08; letter-spacing: .04em; margin-bottom: 1.6rem;
}
.slide-caption-title em { font-style: italic; }
.slide-caption-desc {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: clamp(.75rem, 1vw, .88rem);
  letter-spacing: .2em; opacity: .78; line-height: 2;
}
.hero-cta {
  position: absolute; bottom: 3.5rem;
  left: 50%; transform: translateX(-50%);
  z-index: 3; display: flex; flex-direction: column;
  align-items: center; gap: 1rem;
}
.hero-cta-btn {
  font-family: 'Cormorant Garamond', serif;
  font-size: .68rem; letter-spacing: .38em; color: #fff;
  text-decoration: none;
  border: .5px solid rgba(255,255,255,.55);
  padding: .75rem 2.8rem;
  transition: background .25s, border-color .25s;
}
.hero-cta-btn:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.hero-scroll {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  font-family: 'Cormorant Garamond', serif;
  font-size: .56rem; letter-spacing: .42em;
  color: rgba(255,255,255,.48);
  animation: breathe 2.5s ease infinite;
}
.hero-scroll::after {
  content: ''; display: block;
  width: .5px; height: 36px; background: rgba(255,255,255,.35);
}
@keyframes breathe { 0%,100%{ opacity:.48; } 50%{ opacity:1; } }
.slide-dots {
  position: absolute; bottom: 3rem; right: 5vw;
  z-index: 3; display: flex; flex-direction: column; gap: 8px;
}
.dot {
  width: 4px; height: 4px; border-radius: 50%;
  background: rgba(255,255,255,.35);
  cursor: pointer; transition: background .3s, transform .3s;
  border: none;
}
.dot.active { background: #fff; transform: scale(1.5); }
.slide-arrow {
  position: absolute; top: 50%; z-index: 3;
  transform: translateY(-50%);
  background: none; border: none; cursor: pointer;
  padding: 1rem; opacity: 0; transition: opacity .3s;
}
#hero:hover .slide-arrow { opacity: 1; }
.slide-arrow svg { width: 18px; height: 18px; stroke: rgba(255,255,255,.8); stroke-width: 1; fill: none; }
.slide-arrow.prev { left: 2vw; } .slide-arrow.next { right: 2vw; }

/* ══════════════════════════════════════════
   SECTION COMMONS
══════════════════════════════════════════ */
section { padding: 7rem 6vw; }
.section-eyebrow {
  font-family: 'Cormorant Garamond', serif;
  font-size: .57rem; letter-spacing: .55em;
  color: var(--accent); text-transform: uppercase;
  display: block; margin-bottom: .9rem;
}
.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300; font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.1; color: var(--ink); margin-bottom: 1.2rem;
}
.section-title em { font-style: italic; color: var(--ink-light); }
.section-desc {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .86rem; color: var(--ink-light);
  line-height: 2.1; max-width: 480px;
}
.divider { width: 28px; height: .5px; background: var(--accent); margin: 1.4rem 0; }

/* ══════════════════════════════════════════
   PORTFOLIO TABS（首頁精選作品）
══════════════════════════════════════════ */
#portfolio { background: var(--white); padding-top: 6rem; }
.portfolio-header {
  display: flex; align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 2.8rem; flex-wrap: wrap; gap: 2rem;
}
.portfolio-tabs { display: flex; border-bottom: .5px solid var(--cream-dark); flex-wrap: wrap; }
.tab-btn {
  background: none; border: none;
  border-bottom: 1px solid transparent;
  padding: .65rem 1.3rem; margin-bottom: -.5px;
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .76rem; letter-spacing: .12em;
  color: var(--ink-muted); cursor: pointer; transition: all .2s;
}
.tab-btn.active { color: var(--ink); border-bottom-color: var(--ink); }
.tab-panel { display: none; } .tab-panel.active { display: block; }

/* Carousel */
.pf-carousel {
  position: relative; width: 100%; aspect-ratio: 4/3;
  background: var(--cream-dark); overflow: hidden;
}
@media(max-width:600px) { .pf-carousel { aspect-ratio: 3/4; } }
.pf-track { display: flex; height: 100%; transition: transform .7s cubic-bezier(.16,1,.3,1); }
.pf-slide { flex: 0 0 100%; height: 100%; position: relative; }
.pf-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pf-ph {
  width: 100%; height: 100%;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: .9rem;
  background: var(--cream-dark);
}
.pf-ph svg { width: 32px; height: 32px; stroke: rgba(160,148,136,.3); stroke-width: 1; fill: none; }
.pf-ph p { font-family: 'Cormorant Garamond', serif; font-size: .58rem; letter-spacing: .38em; color: var(--ink-muted); }
.pf-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  z-index: 4; background: rgba(253,250,247,.82);
  backdrop-filter: blur(8px); border: none; cursor: pointer;
  width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transition: opacity .3s, background .2s;
}
.pf-carousel:hover .pf-arrow { opacity: 1; }
.pf-arrow:hover { background: var(--white); }
.pf-arrow svg { width: 15px; height: 15px; stroke: var(--ink); stroke-width: 1.5; fill: none; }
.pf-arrow.prev { left: 1.2rem; } .pf-arrow.next { right: 1.2rem; }
.pf-dots { display: flex; justify-content: center; gap: 8px; padding: 1.2rem 0 .4rem; }
.pf-dot {
  width: 4px; height: 4px; border-radius: 50%;
  background: var(--cream-dark); border: .5px solid var(--ink-muted);
  cursor: pointer; transition: background .3s, transform .3s;
}
.pf-dot.active { background: var(--ink); border-color: var(--ink); transform: scale(1.4); }
.pf-counter {
  font-family: 'Cormorant Garamond', serif;
  font-size: .6rem; letter-spacing: .3em;
  color: var(--ink-muted); text-align: center; padding-bottom: 1rem;
}
.pf-viewall {
  display: block; text-align: right; padding: .6rem 0 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: .62rem; letter-spacing: .3em;
  color: var(--ink-muted); text-decoration: none; transition: color .2s;
}
.pf-viewall:hover { color: var(--accent); }

/* ══════════════════════════════════════════
   SERVICES
══════════════════════════════════════════ */
#services { background: var(--cream); padding: 8rem 6vw; }
.services-header { text-align: center; margin-bottom: 5rem; }
.services-header .section-title { margin-bottom: 0; }
.services-grid {
  display: grid; grid-template-columns: repeat(2,1fr);
  gap: 1px; background: var(--cream-dark);
}
.svc-card {
  background: var(--cream); padding: 3.2rem 3rem;
  position: relative; overflow: hidden; transition: background .4s;
}
.svc-card::before {
  content: ''; position: absolute; top: 0; left: 0;
  width: 0; height: 1.5px; background: var(--accent);
  transition: width .55s cubic-bezier(.16,1,.3,1);
}
.svc-card:hover::before { width: 100%; }
.svc-card:hover { background: var(--white); }
.svc-card-num {
  font-family: 'Cormorant Garamond', serif;
  font-size: .62rem; letter-spacing: .45em;
  color: var(--accent); margin-bottom: 1.8rem; display: block; opacity: .8;
}
.svc-card-icon { width: 36px; height: 1px; background: var(--accent-soft); margin-bottom: 2rem; transition: width .4s; }
.svc-card:hover .svc-card-icon { width: 52px; }
.svc-card-name {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: 1.05rem; color: var(--ink);
  letter-spacing: .1em; margin-bottom: .9rem; line-height: 1.5;
}
.svc-card-en {
  font-family: 'Cormorant Garamond', serif;
  font-size: .6rem; letter-spacing: .38em;
  color: var(--ink-muted); text-transform: uppercase;
  margin-bottom: 1.5rem; display: block;
}
.svc-card-desc {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .78rem; color: var(--ink-muted); line-height: 2.1; letter-spacing: .04em;
}
.svc-card-link {
  display: inline-flex; align-items: center; gap: .5rem;
  margin-top: 1.8rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: .62rem; letter-spacing: .3em;
  color: var(--ink-light); text-decoration: none;
  transition: color .2s, gap .3s;
}
.svc-card-link:hover { color: var(--accent); gap: .8rem; }
.svc-card-link svg { width: 14px; height: 14px; stroke: currentColor; stroke-width: 1.5; fill: none; flex-shrink: 0; }
.services-note-bar {
  margin-top: 4rem; display: flex; align-items: center;
  gap: 2rem; justify-content: center;
}
.services-note-bar::before, .services-note-bar::after {
  content: ''; flex: 1; max-width: 60px;
  height: .5px; background: var(--accent-soft);
}
.services-note-bar p {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .76rem; color: var(--ink-muted);
  letter-spacing: .08em; text-align: center; line-height: 1.9;
}

/* ══════════════════════════════════════════
   INSTAGRAM
══════════════════════════════════════════ */
#instagram {
  background: var(--white); padding: 6rem 6vw;
  text-align: center; border-top: .5px solid var(--cream-dark);
}
.ig-caption {
  font-size: .78rem; color: var(--ink-muted);
  margin-top: .8rem; margin-bottom: 2.8rem; letter-spacing: .06em;
}
.ig-handle {
  display: inline-flex; align-items: center; gap: .6rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: .72rem; letter-spacing: .38em;
  color: var(--ink-muted); margin-bottom: 1.2rem;
  text-decoration: none; transition: color .2s;
}
.ig-handle:hover { color: var(--accent); }
.ig-handle svg { width: 15px; height: 15px; stroke: currentColor; stroke-width: 1.5; fill: none; }
.ig-grid {
  display: grid; grid-template-columns: repeat(6,1fr);
  gap: 3px; margin-bottom: 2.5rem;
}
.ig-cell {
  aspect-ratio: 1; background: var(--cream-dark);
  overflow: hidden; position: relative; cursor: pointer;
}
.ig-cell img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .55s ease; }
.ig-cell:hover img { transform: scale(1.06); }
.ig-cell-overlay {
  position: absolute; inset: 0;
  background: rgba(34,30,24,0); transition: background .3s;
  display: flex; align-items: center; justify-content: center;
}
.ig-cell:hover .ig-cell-overlay { background: rgba(34,30,24,.18); }
.ig-follow-btn {
  display: inline-flex; align-items: center; gap: .7rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: .7rem; letter-spacing: .38em;
  color: var(--ink); border: .5px solid var(--ink-muted);
  padding: .85rem 2.8rem; text-decoration: none;
  transition: border-color .25s, color .25s, background .25s;
}
.ig-follow-btn:hover { border-color: var(--ink); background: var(--ink); color: var(--white); }
.ig-follow-btn svg { width: 16px; height: 16px; stroke: currentColor; stroke-width: 1.5; fill: none; }

/* ══════════════════════════════════════════
   CONTACT / CTA 區塊
══════════════════════════════════════════ */
#contact { background: var(--ink); color: var(--cream); }
#contact .section-title { color: var(--cream); }
#contact .section-eyebrow { color: var(--accent); }
#contact .divider { background: var(--accent); margin-left: auto; margin-right: auto; }

/* LINE 按鈕 — 黑金色系 */
.line-btn {
  display: inline-flex; align-items: center; gap: .8rem;
  padding: .95rem 2.6rem;
  background: transparent;
  border: .5px solid rgba(201,168,130,.55);
  color: rgba(201,168,130,.92);
  text-decoration: none;
  font-family: 'Cormorant Garamond', serif;
  font-size: .72rem; letter-spacing: .3em; text-transform: uppercase;
  transition: background .3s, color .3s, border-color .3s;
  margin-top: 2rem;
}
.line-btn:hover { background: var(--accent); color: var(--ink); border-color: var(--accent); }

/* ══════════════════════════════════════════
   FOOTER
══════════════════════════════════════════ */
footer, .site-footer {
  background: var(--ink);
  border-top: .5px solid rgba(255,255,255,.06);
  padding: 2.5rem 6vw;
  display: flex; align-items: center;
  justify-content: space-between; flex-wrap: wrap; gap: 1rem;
}
.footer-logo {
  font-family: 'Cormorant Garamond', serif;
  font-size: .95rem; letter-spacing: .25em;
  color: rgba(248,244,239,.45); font-weight: 300;
}
.footer-copy {
  font-family: 'Cormorant Garamond', serif;
  font-size: .6rem; letter-spacing: .15em;
  color: rgba(248,244,239,.22);
}

/* ══════════════════════════════════════════
   FADE-UP 動畫
══════════════════════════════════════════ */
.fade-up {
  opacity: 0; transform: translateY(28px);
  transition: opacity .85s ease, transform .85s ease;
}
.fade-up.visible { opacity: 1; transform: none; }

/* ══════════════════════════════════════════
   作品列表頁（Archive）
══════════════════════════════════════════ */
.archive-hero {
  padding: 5rem 6vw 4rem;
  background: var(--white);
  border-bottom: .5px solid var(--cream-dark);
}
.portfolio-grid-main {
  display: grid; grid-template-columns: repeat(3,1fr); gap: 3px; padding: 0;
}
@media(max-width:900px) { .portfolio-grid-main { grid-template-columns: repeat(2,1fr); } }
@media(max-width:500px) { .portfolio-grid-main { grid-template-columns: 1fr; } }
.pf-item {
  position: relative; aspect-ratio: 4/3; overflow: hidden;
  display: block; background: var(--cream-dark);
}
.pf-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .65s ease; }
.pf-item:hover img { transform: scale(1.06); }
.pf-item-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(34,30,24,.7) 0%, transparent 55%);
  opacity: 0; transition: opacity .4s;
  display: flex; flex-direction: column;
  justify-content: flex-end; padding: 1.5rem;
}
.pf-item:hover .pf-item-overlay { opacity: 1; }
.pf-item-name {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .82rem; color: #fff; letter-spacing: .1em;
}
.pf-item-meta {
  font-family: 'Cormorant Garamond', serif;
  font-size: .58rem; letter-spacing: .38em;
  color: rgba(255,255,255,.6); margin-top: .3rem;
}
.archive-section { padding: 3rem 6vw 6rem; background: var(--white); }

/* ══════════════════════════════════════════
   個案詳細頁
══════════════════════════════════════════ */
.case-hero {
  position: relative; width: 100%; height: 90dvh;
  overflow: hidden; background: var(--cream-dark);
  /* 個案頁有 hero，補回 nav 高度讓圖片從頂部開始 */
  margin-top: calc(-1 * var(--nav-h));
}
.case-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.case-hero::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(34,30,24,.72) 0%, rgba(34,30,24,.1) 60%, transparent 100%);
}
.case-hero-content {
  position: absolute; bottom: 4rem; left: 6vw; z-index: 2; color: #fff;
}
.case-breadcrumb {
  font-family: 'Cormorant Garamond', serif;
  font-size: .58rem; letter-spacing: .42em;
  color: rgba(255,255,255,.55); text-transform: uppercase;
  margin-bottom: 1rem; display: flex; align-items: center; gap: .6rem;
}
.case-breadcrumb a { color: inherit; text-decoration: none; transition: color .2s; }
.case-breadcrumb a:hover { color: var(--accent); }
.case-eyebrow {
  font-family: 'Cormorant Garamond', serif;
  font-size: .58rem; letter-spacing: .55em;
  color: var(--accent); text-transform: uppercase;
  display: block; margin-bottom: .8rem;
}
.case-title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300; font-size: clamp(2rem, 5vw, 4.4rem);
  line-height: 1.1; color: #fff; margin-bottom: 1rem;
}
.case-meta { display: flex; gap: 1.8rem; flex-wrap: wrap; }
.case-meta span {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: .72rem; letter-spacing: .12em;
  color: rgba(255,255,255,.65);
  display: flex; align-items: center; gap: .4rem;
}
.case-story {
  max-width: 640px; margin: 0 auto;
  padding: 6rem 6vw; background: var(--white);
}
.case-story p {
  font-family: 'Chiron Sung HK', 'Chiron Sung HK WS', serif;
  font-size: clamp(.9rem, 1.3vw, 1rem);
  color: var(--ink-light); line-height: 2.5; letter-spacing: .06em;
}
.case-gallery { padding: 0 6vw 6rem; background: var(--white); }
.masonry { columns: 3; column-gap: 4px; }
@media(max-width:900px) { .masonry { columns: 2; } }
@media(max-width:500px) { .masonry { columns: 1; } }
.masonry-item {
  break-inside: avoid; margin-bottom: 4px;
  cursor: pointer; overflow: hidden; display: block;
}
.masonry-item img { width: 100%; display: block; transition: transform .6s ease; }
.masonry-item:hover img { transform: scale(1.04); }

/* Lightbox */
#yuching-lightbox {
  position: fixed; inset: 0;
  background: rgba(10,8,6,.94); z-index: 99999;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity .3s;
}
#yuching-lightbox.open { opacity: 1; pointer-events: all; }
.lb-img { max-width: 90vw; max-height: 88dvh; object-fit: contain; display: block; }
.lb-close {
  position: absolute; top: 1.5rem; right: 2rem;
  background: none; border: none;
  color: rgba(255,255,255,.6); font-size: 1.2rem;
  cursor: pointer; font-family: 'Cormorant Garamond', serif;
  letter-spacing: .2em; transition: color .2s;
}
.lb-close:hover { color: #fff; }
.lb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: none; padding: 1rem;
  cursor: pointer; opacity: .5; transition: opacity .2s;
}
.lb-btn:hover { opacity: 1; }
.lb-btn svg { width: 20px; height: 20px; stroke: #fff; stroke-width: 1.5; fill: none; }
.lb-prev { left: 1.5rem; } .lb-next { right: 1.5rem; }

/* ══════════════════════════════════════════
   DESKTOP 字體加大
══════════════════════════════════════════ */
@media(min-width:901px) {
  #portfolio .section-title,
  #services .section-title,
  #contact .section-title { font-size: 2.0rem; }
  .tab-btn { font-size: 1.3rem; letter-spacing: .08em; padding: .65rem 1.6rem; }
  .svc-card-name { font-size: 1.5rem; }
  .svc-card-desc { font-size: 1.2rem; line-height: 2; }
  .services-note-bar p { font-size: 1.2rem; }
  .ig-caption { font-size: .88rem; }
}

/* ══════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════ */
@media(max-width:900px) {
  .ig-grid { grid-template-columns: repeat(3,1fr); }
  .svc-card { padding: 2.4rem 2rem; }
}
@media(max-width:600px) {
  section { padding: 5rem 5vw; }
  footer, .site-footer { flex-direction: column; align-items: flex-start; }
  .hero-cta { bottom: 4.5rem; }
  .services-grid { grid-template-columns: 1fr; }
  .ig-grid { grid-template-columns: repeat(2,1fr); }
  .archive-hero { padding: 3.5rem 5vw 3rem; }
}

/* ══════════════════════════════════════════
   WORDPRESS CORE
══════════════════════════════════════════ */
.alignleft { float: left; margin-right: 1.5em; }
.alignright { float: right; margin-left: 1.5em; }
.aligncenter { margin-left: auto; margin-right: auto; }
.screen-reader-text {
  clip: rect(1px,1px,1px,1px);
  position: absolute; height: 1px; width: 1px; overflow: hidden;
}
/* 分頁 */
.nav-links { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; margin-top: 3rem; }
.nav-links a, .nav-links span {
  font-family: 'Cormorant Garamond', serif;
  font-size: .65rem; letter-spacing: .3em;
  color: var(--ink-muted); text-decoration: none;
  border: .5px solid var(--cream-dark); padding: .5rem 1rem;
  transition: all .2s;
}
.nav-links a:hover { border-color: var(--accent); color: var(--accent); }
.nav-links .current { border-color: var(--ink); color: var(--ink); }

/* ══════════════════════════════════════════
   WORDPRESS ADMIN BAR 修正
   登入後台時，WordPress 會在頁面頂部加一條 32px（手機 46px）的黑色管理列
   需要讓 nav 往下移，避免被蓋住
══════════════════════════════════════════ */

/* Admin bar 固定在最頂部 */
#wpadminbar {
  position: fixed !important;
  top: 0 !important;
  z-index: 99999 !important;
}

/* 有 Admin Bar 時，nav 往下移 32px */
.admin-bar nav#mainNav {
  top: 32px !important;
}

/* 有 Admin Bar 時，Hero 區塊高度補回 */
.admin-bar #hero {
  height: calc(100dvh - 32px);
}

/* 手機版 Admin Bar 是 46px */
@media screen and (max-width: 782px) {
  .admin-bar nav#mainNav {
    top: 46px !important;
  }
  .admin-bar #hero {
    height: calc(100dvh - 46px);
  }
}

/* 取消 WordPress 預設對 html 加的 margin-top */
html { margin-top: 0 !important; }
.admin-bar html { margin-top: 0 !important; }
