/* czstsg.css - 公共样式（首页/列表/详情页共用） */

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

:root {
  --ink:        oklch(18% 0.02 60);
  --ink-soft:   oklch(35% 0.015 60);
  --paper:      oklch(97% 0.008 70);
  --paper-warm: oklch(94% 0.015 65);
  --accent:     oklch(48% 0.18 25);
  --accent-dim: oklch(38% 0.16 25);
  --gold:       oklch(75% 0.14 85);
  --gold-light: oklch(92% 0.06 85);
  --cream:      oklch(96% 0.012 75);
  --white:      oklch(100% 0 0);
  --font-display: 'Noto Serif SC', 'Songti SC', 'STSong', 'SimSun', serif;
  --font-body:    'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
}

html { scroll-behavior: smooth; overflow-y: scroll; scrollbar-width: none; }
html::-webkit-scrollbar { display: none; }

body {
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

/* ── Top Navigation (子页面用：白底 sticky) ── */
.top-nav {
  position: sticky; top: 0; left: 0; right: 0; z-index: 1000;
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 48px;
  background: oklch(100% 0 0 / 0.9);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid oklch(88% 0.01 65 / 0.5);
}
.top-nav .logo-area { display: flex; align-items: center; gap: 10px; }
.top-nav .logo-area img { height: 36px; width: auto; }
.top-nav .nav-links { display: flex; gap: 4px; }
.top-nav .nav-links > li { position: relative; }
.top-nav .nav-links > li > a {
  display: block; padding: 9px 14px;
  color: var(--ink-soft);
  font-size: 0.84rem; font-weight: 500;
  letter-spacing: 0.03em;
  border-radius: 6px;
  transition: all 200ms ease;
  white-space: nowrap;
}
.top-nav .nav-links > li > a:hover { color: var(--accent); background: oklch(48% 0.18 25 / 0.05); }
.top-nav .nav-links > li .dropdown {
  position: absolute; top: 100%; left: 50%;
  transform: translateX(-50%) translateY(4px);
  background: var(--white);
  border-radius: 10px;
  box-shadow: 0 12px 40px oklch(0 0 0 / 0.1);
  border: 1px solid oklch(88% 0.01 65 / 0.6);
  min-width: 160px;
  padding: 8px 0;
  opacity: 0; visibility: hidden;
  transform-origin: top center;
  transition: all 220ms var(--ease-out-expo);
}
.top-nav .nav-links > li:hover .dropdown {
  opacity: 1; visibility: visible;
  transform: translateX(-50%) translateY(8px);
}
.top-nav .nav-links > li .dropdown a {
  display: block; padding: 8px 18px;
  font-size: 0.8rem; color: var(--ink-soft);
  transition: all 180ms ease;
  white-space: nowrap;
}
.top-nav .nav-links > li .dropdown a:hover { color: var(--accent); background: oklch(48% 0.18 25 / 0.04); }

/* ── Page Banner（子页面顶部条幅，复用首页 hero 背景图） ── */
.page-banner {
  height: 320px;
  background:
    linear-gradient(oklch(0 0 0 / 0.35), oklch(0 0 0 / 0.5)),
    url('../images/hero-bg.jpg') center/cover no-repeat;
  position: relative;
  overflow: hidden;
}
.page-banner::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 48px;
  background: linear-gradient(to top, var(--paper), transparent);
  pointer-events: none;
}

/* ── Main Content Wrapper ── */
.content-wrapper {
  max-width: 1280px;
  margin: 0 auto;
  padding: 48px 24px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
  flex: 1 0 auto;
  width: 100%;
}
.content-nav { position: sticky; top: 88px; align-self: start; }
.content-nav .nav-cat-title {
  font-family: var(--font-display);
  font-size: 1.2rem; font-weight: 600;
  padding: 14px 20px;
  background: var(--accent);
  color: var(--white);
  border-radius: 6px 6px 0 0;
}
.content-nav ul {
  background: var(--white);
  border: 1px solid oklch(80% 0.02 60 / 0.2);
  border-top: none;
  border-radius: 0 0 6px 6px;
}
.content-nav ul li a {
  display: block;
  padding: 12px 20px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  transition: all 180ms ease;
  border-left: 3px solid transparent;
}
.content-nav ul li a:hover { color: var(--accent); background: var(--paper-warm); }
.content-nav ul li a.active {
  color: var(--accent);
  border-left-color: var(--accent);
  background: oklch(48% 0.18 25 / 0.04);
  font-weight: 500;
}

/* ── Site Footer（深色版，结构对齐首页 info 区块） ── */
.site-footer {
  background: var(--ink);
  color: oklch(82% 0.01 60);
  padding: 56px 48px 28px;
  flex-shrink: 0;
}
.site-footer .footer-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
  gap: 40px;
  align-items: start;
}
.site-footer .footer-brand .brand-name {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 14px;
  letter-spacing: 0.02em;
}
.site-footer .footer-brand p {
  font-size: 0.82rem;
  color: oklch(72% 0.01 60);
  line-height: 1.75;
}
.site-footer .footer-hours h3,
.site-footer .footer-links h3,
.site-footer .footer-friendly h3 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  color: var(--gold-light);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
  letter-spacing: 0.04em;
}
.site-footer .footer-hours dl {
  font-size: 0.8rem;
  line-height: 1.8;
}
.site-footer .footer-hours dt {
  color: oklch(92% 0.01 60);
  font-weight: 500;
  margin-top: 6px;
}
.site-footer .footer-hours dt:first-child { margin-top: 0; }
.site-footer .footer-hours dd { color: oklch(72% 0.01 60); }
.site-footer .footer-links ul li { margin-bottom: 8px; }
.site-footer .footer-links ul li a {
  font-size: 0.82rem;
  color: oklch(72% 0.01 60);
  transition: color 200ms ease;
}
.site-footer .footer-links ul li a:hover { color: var(--gold); }
.site-footer .footer-friendly .link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
}
.site-footer .footer-friendly .link-row a {
  font-size: 0.76rem;
  color: oklch(72% 0.01 60);
  padding: 3px 10px;
  background: oklch(0 0 0 / 0.25);
  border-radius: 12px;
  transition: all 200ms ease;
}
.site-footer .footer-friendly .link-row a:hover {
  color: var(--gold);
  background: oklch(48% 0.18 25 / 0.3);
}
.site-footer .footer-bottom {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 0.78rem;
  color: oklch(68% 0.01 60);
  padding-top: 24px;
  margin-top: 8px;
  border-top: 1px solid oklch(50% 0.01 60 / 0.3);
}
.site-footer .footer-bottom p { margin-top: 4px; }
.site-footer .footer-bottom p:first-child { margin-top: 0; }

/* ── Back to Top Button ── */
.back-top {
  position: fixed; right: 32px; bottom: 32px;
  width: 44px; height: 44px;
  background: var(--accent);
  color: var(--white);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px oklch(48% 0.18 25 / 0.4);
  opacity: 0; visibility: hidden;
  transform: translateY(20px);
  transition: all 280ms var(--ease-out-expo);
  z-index: 90;
}
.back-top.visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-top svg { width: 20px; height: 20px; }
.back-top:hover { background: var(--accent-dim); transform: translateY(-2px); }

/* ── Responsive (≤1000px) ── */
@media (max-width: 1000px) {
  .top-nav { padding: 12px 20px; flex-wrap: wrap; }
  .top-nav .nav-links {
    order: 3; width: 100%;
    flex-wrap: wrap; justify-content: center;
    margin-top: 8px;
  }
  .content-wrapper { grid-template-columns: 1fr; gap: 24px; padding: 32px 16px; }
  .content-nav { position: static; }
  .content-nav ul { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; }
  .content-nav ul li a { padding: 8px 14px; border-left: none; border-radius: 4px; }
  .content-nav ul li a.active { border-left: none; background: var(--accent); color: var(--white); }
  .site-footer { padding: 36px 20px 20px; }
  .site-footer .footer-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .site-footer .footer-hours h3,
  .site-footer .footer-links h3,
  .site-footer .footer-friendly h3 {
    display: block;
  }
  .back-top { right: 16px; bottom: 16px; width: 40px; height: 40px; }
}
