@font-face {
  font-family: "Noto Sans TC Local";
  src: url("/assets/fonts/NotoSansTC-Page.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --bg: #e7ecee;
  --surface: #dce3e6;
  --surface-deep: #cbd5d9;
  --ink: #17242a;
  --muted: #4c5f68;
  --line: #9baab0;
  --accent: #9b4938;
  --accent-ink: #f5f0ed;
  --photo-ground: #24343c;
  --focus: #9b4938;
  --header-bg: rgb(231 236 238 / .94);
  --selection: #b96550;
  --section-space: clamp(5rem, 10vw, 10rem);
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #10181d;
  --surface: #172329;
  --surface-deep: #213039;
  --ink: #e8edef;
  --muted: #acbbc1;
  --line: #465861;
  --accent: #c06a55;
  --accent-ink: #11181c;
  --photo-ground: #0a1014;
  --focus: #df8a73;
  --header-bg: rgb(16 24 29 / .94);
  --selection: #934d3d;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--bg); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Noto Sans TC Local", "PingFang TC", "Microsoft JhengHei", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  text-rendering: optimizeLegibility;
  transition: background-color .25s ease, color .25s ease;
}
::selection { color: var(--accent-ink); background: var(--selection); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
a { color: inherit; text-decoration-color: var(--accent); text-underline-offset: .3em; }
button { font: inherit; }
img { display: block; max-width: 100%; }

.skip-link {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 100;
  padding: .65rem 1rem;
  background: var(--accent);
  color: var(--accent-ink);
  transform: translateY(-160%);
}
.skip-link:focus { transform: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.25rem, 3.5vw, 3.75rem);
  border-bottom: 1px solid var(--line);
  background: var(--header-bg);
  backdrop-filter: blur(12px);
}
.brand, .footer-brand {
  display: inline-flex;
  align-items: center;
  gap: .75rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: .04em;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 2rem;
  height: 2rem;
  background: var(--accent);
  color: var(--accent-ink);
  line-height: 1;
}
.header-actions { display: flex; align-items: center; gap: clamp(.5rem, 2vw, 2rem); }
.site-nav { display: flex; align-items: center; gap: clamp(1.25rem, 2.5vw, 2.5rem); }
.site-nav a {
  position: relative;
  font-size: .9rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
}
.site-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -.4rem;
  left: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .25s cubic-bezier(.16, 1, .3, 1);
}
.site-nav a:hover::after, .site-nav a:focus-visible::after { transform: scaleX(1); transform-origin: left; }
.theme-toggle, .nav-toggle {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background-color .2s ease, border-color .2s ease, transform .15s ease;
}
.theme-toggle:hover, .nav-toggle:hover { background: var(--surface-deep); border-color: var(--ink); }
.theme-toggle:active, .nav-toggle:active { transform: translateY(1px); }
.theme-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  width: 4.4rem;
  height: 2.25rem;
  padding: .2rem;
}
.theme-toggle span { display: grid; place-items: center; font-size: .75rem; font-weight: 700; }
.theme-label-light, html[data-theme="dark"] .theme-label-dark { background: var(--ink); color: var(--bg); }
.theme-label-dark, html[data-theme="dark"] .theme-label-light { background: transparent; color: var(--muted); }
.nav-toggle { display: none; width: 2.5rem; height: 2.25rem; padding: .6rem; }
.nav-toggle span { display: block; height: 1px; margin: .28rem 0; background: currentColor; transition: transform .2s ease; }
.nav-toggle[aria-expanded="true"] span:first-child { transform: translateY(.27rem) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:last-child { transform: translateY(-.27rem) rotate(-45deg); }

.hero {
  min-height: calc(100dvh - 72px);
  display: grid;
  grid-template-columns: minmax(300px, 32%) minmax(0, 68%);
  grid-template-rows: minmax(0, 1fr) 96px;
  border-bottom: 1px solid var(--line);
}
.hero-copy {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: clamp(2.5rem, 5.5vw, 6rem) clamp(2rem, 4.5vw, 5rem);
}
.hero-context { margin: 0 0 1.4rem; color: var(--accent); font-weight: 700; }
h1, h2, p { margin-top: 0; }
h1 {
  max-width: 7.5ch;
  margin-bottom: 1.8rem;
  font-size: clamp(3.2rem, 5.4vw, 5.8rem);
  font-weight: 760;
  line-height: 1.04;
  letter-spacing: -.04em;
}
.hero-intro { max-width: 18em; margin: 0; color: var(--muted); font-size: clamp(1rem, 1.25vw, 1.16rem); }
.hero-figure {
  grid-column: 2;
  grid-row: 1 / 3;
  min-width: 0;
  margin: 0;
  display: grid;
  grid-template-rows: minmax(0, 1fr) 48px;
  background: var(--photo-ground);
}
.hero-image-wrap { min-height: 0; overflow: hidden; }
.hero-figure img { width: 100%; height: 100%; object-fit: contain; object-position: center; }
.hero-figure img[data-current-view="night"] { object-fit: cover; object-position: center 53%; }
.hero-figure figcaption {
  display: flex;
  align-items: center;
  padding: 0 1.25rem;
  background: var(--photo-ground);
  color: #dce5e8;
  font-size: .78rem;
  letter-spacing: .04em;
}
.view-switch {
  grid-column: 1;
  grid-row: 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--line);
}
.view-switch button {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: .1rem;
  padding: 1rem clamp(1rem, 2.2vw, 2.25rem);
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  text-align: left;
}
.view-switch button[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); }
.view-switch button:not([aria-pressed="true"]):hover { background: var(--surface-deep); color: var(--ink); }
.view-switch span { font-weight: 700; white-space: nowrap; }
.view-switch small { font-size: .7rem; }

.about-section, .details-section, .visit-section { padding: var(--section-space) clamp(1.25rem, 6vw, 7rem); }
.about-section {
  max-width: 1500px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, .65fr);
  gap: clamp(3rem, 9vw, 9rem);
  align-items: end;
}
h2 {
  max-width: 12ch;
  margin-bottom: 1.5rem;
  font-size: clamp(2.35rem, 5vw, 5rem);
  font-weight: 700;
  line-height: 1.13;
  letter-spacing: -.035em;
}
.section-title-block > p { max-width: 30em; margin: 0; font-size: clamp(1.12rem, 1.5vw, 1.35rem); }
.about-note { padding-top: 2rem; border-top: 1px solid var(--line); color: var(--muted); }
.verification-note { margin-bottom: 0; font-size: .82rem; }

.details-section {
  padding-top: clamp(5rem, 10vw, 10rem);
  background: var(--surface);
}
.details-section > h2 { max-width: 13ch; }
.section-intro { max-width: 38em; margin-bottom: clamp(2.5rem, 5vw, 5rem); color: var(--muted); }
.detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(260px, .75fr);
  gap: clamp(1.5rem, 3vw, 3.5rem);
  max-width: 1500px;
  margin: 0 auto;
}
.detail-grid figure { margin: 0; min-width: 0; }
.detail-wide { grid-column: 1 / -1; }
.detail-grid img { width: 100%; height: clamp(300px, 42vw, 600px); object-fit: cover; background: var(--photo-ground); }
.detail-wide img { height: clamp(220px, 26vw, 390px); }
.detail-grid figcaption { display: grid; grid-template-columns: minmax(8rem, .35fr) 1fr; gap: 1.5rem; padding-top: 1rem; }
.detail-grid strong { color: var(--accent); }
.detail-grid span { color: var(--muted); max-width: 32em; }

.night-section {
  display: grid;
  grid-template-columns: minmax(320px, .8fr) minmax(0, 1.2fr);
  min-height: 90dvh;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.night-figure { min-width: 0; margin: 0; background: var(--photo-ground); }
.night-figure img { width: 100%; height: 100%; max-height: 1080px; object-fit: cover; object-position: center 62%; }
.night-copy { align-self: center; padding: clamp(4rem, 10vw, 11rem); }
.night-copy h2 { max-width: 10ch; text-wrap: balance; }
.night-copy p { max-width: 31em; color: var(--muted); font-size: clamp(1rem, 1.4vw, 1.22rem); }
.night-copy p:last-child { margin-bottom: 0; color: var(--accent); font-weight: 650; }

.visit-section { max-width: 1500px; margin: 0 auto; }
.privacy-statement { display: grid; grid-template-columns: minmax(240px, .7fr) minmax(0, 1.3fr); gap: clamp(2rem, 8vw, 8rem); align-items: center; }
.privacy-word {
  color: transparent;
  font-size: clamp(5rem, 13vw, 12rem);
  font-weight: 850;
  line-height: .8;
  letter-spacing: -.08em;
  -webkit-text-stroke: 1px var(--accent);
}
.privacy-statement h2 { max-width: 8ch; margin-bottom: 1.5rem; }
.privacy-statement p { max-width: 34em; margin: 0; color: var(--muted); font-size: 1.12rem; }
.visit-footnote { margin: clamp(4rem, 8vw, 8rem) 0 0; padding-top: 1.25rem; border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; }

.site-footer {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 2rem;
  padding: 3rem clamp(1.25rem, 6vw, 7rem);
  border-top: 1px solid var(--line);
  background: var(--surface);
  font-size: .83rem;
}
.site-footer p { margin: 0; color: var(--muted); }
.footer-brand { align-items: flex-start; }

::-webkit-scrollbar { width: 12px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--line); border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

@media (max-width: 900px) {
  .site-header { height: 64px; }
  .nav-toggle { display: block; }
  .site-nav {
    position: fixed;
    top: 64px;
    right: 0;
    left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 1rem 1.25rem 1.5rem;
    border-bottom: 1px solid var(--line);
    background: var(--bg);
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: .9rem 0; border-bottom: 1px solid var(--line); font-size: 1rem; }
  .site-nav a:last-child { border-bottom: 0; }
  .site-nav a::after { display: none; }
  .hero {
    min-height: calc(100dvh - 64px);
    grid-template-columns: 1fr;
    grid-template-rows: auto 72px auto;
  }
  .hero-copy { grid-column: 1; grid-row: 1; padding: clamp(1.25rem, 4dvh, 2.25rem) 1.25rem; }
  h1 { width: 100%; max-width: none; margin-bottom: .75rem; font-size: clamp(2.65rem, 12vw, 4.3rem); }
  .hero-context { margin-bottom: .75rem; }
  .hero-figure { grid-column: 1; grid-row: 3; grid-template-rows: auto 40px; }
  .hero-image-wrap { aspect-ratio: 1705 / 960; }
  .hero-figure img[data-current-view="night"] { object-fit: cover; object-position: center 62%; }
  .view-switch { grid-column: 1; grid-row: 2; }
  .about-section { grid-template-columns: 1fr; gap: 3rem; }
  .details-section, .about-section, .visit-section { padding-right: 1.25rem; padding-left: 1.25rem; }
  .night-copy { padding: 4rem 2rem; }
  .privacy-statement { grid-template-columns: 1fr; }
  .privacy-word { font-size: min(35vw, 9rem); }
}

@media (max-width: 680px) {
  .brand > span:last-child { display: none; }
  .header-actions { gap: .5rem; }
  .hero { min-height: auto; }
  .hero-intro { max-width: 17em; }
  .detail-grid { grid-template-columns: 1fr; gap: 3rem; }
  .detail-wide { grid-column: auto; }
  .detail-grid img, .detail-wide img { height: auto; aspect-ratio: auto; object-fit: contain; }
  .detail-grid figcaption { grid-template-columns: 1fr; gap: .25rem; }
  .night-section { grid-template-columns: 1fr; min-height: auto; }
  .night-figure img { height: auto; max-height: none; object-fit: contain; }
  .night-copy { padding: 4rem 1.25rem 5rem; }
  .site-footer { grid-template-columns: 1fr; gap: 1rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

@media (prefers-reduced-transparency: reduce) {
  .site-header { background: var(--bg); backdrop-filter: none; }
}
