/* ========================================
   彩票博物馆 - 主样式表
   设计风格：复古博物馆 / 羊皮纸 / 古典
   ======================================== */

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

:root {
  --color-vintage-red: #A52A2A;
  --color-parchment: #F5DEB3;
  --color-dark-text: #333333;
  --color-wood-brown: #8B4513;
  --color-gold: #C5A55A;
  --color-cream: #FDF5E6;
  --color-dark-wood: #5C3317;
  --color-light-parchment: #FAF0E6;
  --color-seal-red: #B22222;
  --font-title: 'Noto Serif SC', 'SimSun', 'STSong', serif;
  --font-body: 'FangSong', 'STFangsong', 'KaiTi', serif;
  --border-classic: 2px solid var(--color-wood-brown);
  --shadow-exhibit: 0 4px 16px rgba(92, 51, 23, 0.3);
  --shadow-card: 0 2px 8px rgba(92, 51, 23, 0.2);
}

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

body {
  font-family: var(--font-body);
  color: var(--color-dark-text);
  background-color: var(--color-cream);
  background-image: url('../images/parchment-bg.svg');
  line-height: 1.8;
  overflow-x: hidden;
}

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

a {
  color: var(--color-vintage-red);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--color-wood-brown);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  color: var(--color-vintage-red);
  line-height: 1.4;
  margin-bottom: 0.8em;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.6rem; }
h3 { font-size: 1.3rem; }
h4 { font-size: 1.15rem; }

p {
  margin-bottom: 1em;
  text-indent: 2em;
}

/* --- Layout Container --- */
.museum-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

/* --- Parchment Background Texture (CSS generated) --- */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    radial-gradient(ellipse at 20% 50%, rgba(245,222,179,0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(139,69,19,0.05) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 80%, rgba(245,222,179,0.1) 0%, transparent 50%);
  pointer-events: none;
  z-index: -1;
}

/* ========================================
   导航栏 (Non-Sticky)
   ======================================== */
.museum-header {
  background: linear-gradient(180deg, #4A2810 0%, var(--color-wood-brown) 100%);
  border-bottom: 4px solid var(--color-gold);
  padding: 12px 0;
  position: relative;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

.museum-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.museum-logo img {
  height: 48px;
  width: auto;
  border-radius: 4px;
}

.museum-logo-text {
  font-family: var(--font-title);
  color: var(--color-parchment);
  font-size: 1.2rem;
  font-weight: bold;
  letter-spacing: 2px;
}

/* Desktop Navigation */
.museum-nav {
  display: none;
}

.museum-nav ul {
  list-style: none;
  display: flex;
  gap: 4px;
}

.museum-nav ul li a {
  color: var(--color-parchment);
  padding: 8px 14px;
  font-family: var(--font-title);
  font-size: 0.9rem;
  border-radius: 4px;
  transition: all 0.3s;
  display: block;
  white-space: nowrap;
}

.museum-nav ul li a:hover,
.museum-nav ul li a.active {
  background: rgba(245,222,179,0.15);
  color: var(--color-gold);
}

/* Mobile Hamburger */
.mobile-menu-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: 1px solid var(--color-gold);
  border-radius: 4px;
}

.mobile-menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-parchment);
  transition: all 0.3s;
}

/* Mobile Dropdown Menu */
.mobile-nav {
  display: none;
  background: linear-gradient(180deg, var(--color-wood-brown) 0%, #4A2810 100%);
  border-top: 2px solid var(--color-gold);
  padding: 0;
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s ease;
}

.mobile-nav.open {
  display: block;
  max-height: 500px;
}

.mobile-nav ul {
  list-style: none;
  padding: 8px 0;
}

.mobile-nav ul li {
  border-bottom: 1px solid rgba(197,165,90,0.2);
}

.mobile-nav ul li:last-child {
  border-bottom: none;
}

.mobile-nav ul li a {
  display: block;
  color: var(--color-parchment);
  padding: 12px 24px;
  font-family: var(--font-title);
  font-size: 1rem;
  transition: all 0.3s;
}

.mobile-nav ul li a:hover {
  background: rgba(245,222,179,0.1);
  color: var(--color-gold);
  padding-left: 32px;
}

/* ========================================
   Hero / 博物馆入口模块
   ======================================== */
.hero-entrance {
  position: relative;
  width: 100%;
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--color-dark-wood);
}

.hero-entrance .hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.85;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 40px 20px;
  max-width: 700px;
}

.hero-scroll {
  background: rgba(253,245,230,0.92);
  border: 3px solid var(--color-wood-brown);
  border-radius: 12px;
  padding: 32px 24px;
  box-shadow: var(--shadow-exhibit);
  animation: scrollUnfold 1.2s ease-out;
}

@keyframes scrollUnfold {
  from {
    transform: scaleY(0.1);
    opacity: 0;
  }
  to {
    transform: scaleY(1);
    opacity: 1;
  }
}

.hero-scroll h1 {
  font-size: 1.8rem;
  color: var(--color-vintage-red);
  margin-bottom: 16px;
  letter-spacing: 4px;
}

.hero-slogan {
  font-family: var(--font-title);
  font-size: 1.05rem;
  color: var(--color-wood-brown);
  margin-bottom: 24px;
  text-indent: 0;
  line-height: 1.8;
}

.cta-enter {
  display: inline-block;
  background: linear-gradient(135deg, var(--color-wood-brown), var(--color-dark-wood));
  color: var(--color-parchment);
  padding: 14px 36px;
  font-family: var(--font-title);
  font-size: 1.1rem;
  border: 2px solid var(--color-gold);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s;
  letter-spacing: 3px;
  text-decoration: none;
}

.cta-enter:hover {
  background: linear-gradient(135deg, var(--color-vintage-red), #8B0000);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(165,42,42,0.4);
}

/* ========================================
   展区模块通用样式
   ======================================== */
.exhibit-module {
  padding: 48px 0;
  border-bottom: 2px solid rgba(139,69,19,0.15);
}

.exhibit-module:last-child {
  border-bottom: none;
}

.module-title-frame {
  text-align: center;
  margin-bottom: 32px;
  position: relative;
}

.module-title-frame h2 {
  display: inline-block;
  background: var(--color-cream);
  padding: 8px 32px;
  border: 2px solid var(--color-wood-brown);
  border-radius: 8px;
  position: relative;
  letter-spacing: 3px;
}

.module-title-frame h2::before,
.module-title-frame h2::after {
  content: '◆';
  color: var(--color-gold);
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.7rem;
}

.module-title-frame h2::before { left: 10px; }
.module-title-frame h2::after { right: 10px; }

/* --- 古籍翻页设计 (品牌介绍) --- */
.ancient-book {
  background: linear-gradient(135deg, var(--color-light-parchment), var(--color-parchment));
  border: 3px solid var(--color-wood-brown);
  border-radius: 8px;
  padding: 28px 20px;
  box-shadow: var(--shadow-exhibit);
  position: relative;
}

.ancient-book::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: rgba(139,69,19,0.2);
  display: none;
}

.book-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.book-left, .book-right {
  flex: 1;
}

.book-left img {
  border: 3px solid var(--color-wood-brown);
  border-radius: 4px;
  box-shadow: var(--shadow-card);
  margin-bottom: 16px;
}

.book-right {
  padding: 0;
}

.book-right h3 {
  color: var(--color-vintage-red);
  border-bottom: 1px solid var(--color-gold);
  padding-bottom: 8px;
  margin-bottom: 12px;
}

/* --- 展柜卡片 --- */
.exhibit-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.exhibit-card {
  background: var(--color-light-parchment);
  border: 2px solid var(--color-wood-brown);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.3s, box-shadow 0.3s;
}

.exhibit-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-exhibit);
}

.exhibit-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 2px solid var(--color-wood-brown);
}

.exhibit-card-body {
  padding: 16px;
}

.exhibit-card-body h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.exhibit-card-body p {
  font-size: 0.9rem;
  text-indent: 2em;
  color: var(--color-dark-text);
}

/* --- 编年史时间线 --- */
.timeline-section {
  position: relative;
  padding-left: 30px;
}

.timeline-section::before {
  content: '';
  position: absolute;
  left: 10px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--color-gold), var(--color-wood-brown));
  border-radius: 2px;
}

.timeline-item {
  position: relative;
  margin-bottom: 28px;
  padding: 16px;
  background: var(--color-light-parchment);
  border: 1px solid rgba(139,69,19,0.3);
  border-radius: 8px;
  box-shadow: var(--shadow-card);
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -26px;
  top: 20px;
  width: 14px;
  height: 14px;
  background: var(--color-vintage-red);
  border: 3px solid var(--color-gold);
  border-radius: 50%;
}

.timeline-year {
  font-family: var(--font-title);
  font-size: 1.1rem;
  color: var(--color-vintage-red);
  font-weight: bold;
  margin-bottom: 4px;
}

/* --- 印章装饰 --- */
.seal-stamp {
  display: inline-block;
  border: 3px solid var(--color-seal-red);
  color: var(--color-seal-red);
  padding: 8px 16px;
  font-family: var(--font-title);
  font-weight: bold;
  transform: rotate(-5deg);
  opacity: 0.85;
  letter-spacing: 2px;
  border-radius: 4px;
  font-size: 0.9rem;
}

/* --- 专家专栏 --- */
.expert-section {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
}

.expert-photo {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  border: 4px solid var(--color-wood-brown);
  box-shadow: var(--shadow-exhibit);
}

.expert-info {
  text-align: center;
}

.expert-quote {
  font-family: var(--font-title);
  font-style: italic;
  color: var(--color-wood-brown);
  border-left: 4px solid var(--color-gold);
  padding: 12px 16px;
  margin: 16px 0;
  background: rgba(245,222,179,0.3);
  border-radius: 0 8px 8px 0;
}

/* --- APP下载模块 --- */
.app-showcase {
  text-align: center;
  padding: 32px 16px;
}

.app-envelope-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
  align-items: center;
  margin: 24px 0;
}

.app-envelope {
  background: linear-gradient(135deg, #D4A76A, var(--color-parchment));
  border: 3px solid var(--color-wood-brown);
  border-radius: 8px;
  padding: 24px;
  max-width: 280px;
  width: 100%;
  box-shadow: var(--shadow-exhibit);
  position: relative;
}

.app-envelope::after {
  content: '';
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  background: var(--color-seal-red);
  border-radius: 50%;
  opacity: 0.7;
}

.app-envelope h4 {
  color: var(--color-wood-brown);
  margin-bottom: 12px;
}

.qr-placeholder {
  width: 160px;
  height: 160px;
  margin: 0 auto;
  background: #fff;
  border: 2px solid var(--color-wood-brown);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  color: var(--color-wood-brown);
  font-size: 0.85rem;
}

.app-steps {
  margin-top: 32px;
}

.app-step {
  background: var(--color-light-parchment);
  border: 2px solid var(--color-wood-brown);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 16px;
  text-align: left;
  animation: scrollReveal 0.6s ease-out;
}

.app-step-number {
  display: inline-block;
  background: var(--color-vintage-red);
  color: #fff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  text-align: center;
  line-height: 32px;
  font-family: var(--font-title);
  font-weight: bold;
  margin-right: 12px;
  font-size: 0.9rem;
}

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

/* --- 牌照模块 --- */
.license-frame {
  background: linear-gradient(135deg, #3D2B1F, var(--color-dark-wood));
  border: 4px solid var(--color-gold);
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  color: var(--color-parchment);
  box-shadow: var(--shadow-exhibit);
}

.license-frame img {
  max-width: 100%;
  border: 3px solid var(--color-gold);
  border-radius: 8px;
  margin: 16px auto;
}

.license-frame h3 {
  color: var(--color-gold);
}

.license-frame p {
  color: var(--color-parchment);
  text-indent: 2em;
}

.license-number {
  font-family: var(--font-title);
  font-size: 1.1rem;
  color: var(--color-gold);
  letter-spacing: 2px;
  margin-top: 12px;
}

/* ========================================
   页脚 - 博物馆荣誉墙
   ======================================== */
.museum-footer {
  background: linear-gradient(180deg, #3D2B1F 0%, #2A1A0E 100%);
  border-top: 4px solid var(--color-gold);
  color: var(--color-parchment);
  padding: 40px 0 20px;
  margin-top: 48px;
}

.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 16px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  margin-bottom: 28px;
}

.footer-section h4 {
  color: var(--color-gold);
  font-family: var(--font-title);
  font-size: 1rem;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(197,165,90,0.3);
  letter-spacing: 2px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 6px;
}

.footer-section ul li a {
  color: var(--color-parchment);
  font-size: 0.9rem;
  opacity: 0.85;
  transition: all 0.3s;
}

.footer-section ul li a:hover {
  opacity: 1;
  color: var(--color-gold);
  padding-left: 4px;
}

.footer-section p {
  font-size: 0.85rem;
  opacity: 0.8;
  text-indent: 0;
  line-height: 1.6;
}

.social-icons {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 2px solid var(--color-gold);
  border-radius: 50%;
  color: var(--color-gold);
  font-size: 0.75rem;
  font-family: var(--font-title);
  transition: all 0.3s;
}

.social-icon:hover {
  background: var(--color-gold);
  color: #2A1A0E;
}

.footer-badges {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 12px;
}

.badge-18plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border: 3px solid var(--color-vintage-red);
  border-radius: 50%;
  color: var(--color-vintage-red);
  font-family: var(--font-title);
  font-weight: bold;
  font-size: 0.85rem;
  background: rgba(165,42,42,0.1);
}

.payment-icons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.payment-icon {
  display: inline-block;
  padding: 4px 10px;
  border: 1px solid rgba(197,165,90,0.4);
  border-radius: 4px;
  font-size: 0.75rem;
  color: var(--color-parchment);
  opacity: 0.7;
}

.footer-bottom {
  border-top: 1px solid rgba(197,165,90,0.3);
  padding-top: 16px;
  text-align: center;
  font-size: 0.8rem;
  opacity: 0.7;
}

.footer-bottom p {
  text-indent: 0;
  margin-bottom: 4px;
}

/* ========================================
   内页通用样式
   ======================================== */
.inner-page-hero {
  background: linear-gradient(135deg, var(--color-dark-wood), #3D2B1F);
  padding: 40px 16px;
  text-align: center;
  border-bottom: 4px solid var(--color-gold);
}

.inner-page-hero h1 {
  color: var(--color-parchment);
  font-size: 1.6rem;
  letter-spacing: 3px;
  margin-bottom: 8px;
}

.inner-page-hero .breadcrumb {
  color: rgba(245,222,179,0.7);
  font-size: 0.85rem;
}

.inner-page-hero .breadcrumb a {
  color: var(--color-gold);
}

.inner-content {
  max-width: 900px;
  margin: 0 auto;
  padding: 32px 16px;
}

.inner-content img {
  border: 3px solid var(--color-wood-brown);
  border-radius: 8px;
  margin: 20px 0;
  box-shadow: var(--shadow-card);
}

.content-section {
  margin-bottom: 32px;
}

.content-section h2 {
  border-left: 4px solid var(--color-vintage-red);
  padding-left: 16px;
  margin-bottom: 16px;
}

.content-section h3 {
  color: var(--color-wood-brown);
  margin-top: 20px;
  margin-bottom: 12px;
}

/* 趣闻卡片 */
.anecdote-card {
  background: var(--color-light-parchment);
  border: 2px solid var(--color-gold);
  border-radius: 8px;
  padding: 20px;
  margin: 16px 0;
  position: relative;
}

.anecdote-card::before {
  content: '趣';
  position: absolute;
  top: -12px;
  right: 16px;
  background: var(--color-vintage-red);
  color: #fff;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-title);
  font-size: 0.8rem;
}

/* 收藏家箴言 */
.collector-maxim {
  background: linear-gradient(135deg, var(--color-dark-wood), #3D2B1F);
  color: var(--color-parchment);
  padding: 24px;
  border-radius: 8px;
  text-align: center;
  margin: 24px 0;
  border: 2px solid var(--color-gold);
}

.collector-maxim blockquote {
  font-family: var(--font-title);
  font-size: 1.1rem;
  font-style: italic;
  line-height: 1.8;
}

.collector-maxim cite {
  display: block;
  margin-top: 12px;
  color: var(--color-gold);
  font-size: 0.9rem;
}

/* 寻宝人故事 */
.treasure-hunter-story {
  background: var(--color-parchment);
  border: 3px solid var(--color-wood-brown);
  border-radius: 8px;
  padding: 24px;
  margin: 24px 0;
  box-shadow: var(--shadow-exhibit);
}

.treasure-hunter-story h4 {
  color: var(--color-vintage-red);
  text-align: center;
  margin-bottom: 16px;
}

/* FAQ样式 */
.faq-item {
  margin-bottom: 16px;
  border: 1px solid rgba(139,69,19,0.2);
  border-radius: 8px;
  overflow: hidden;
}

.faq-question {
  background: var(--color-light-parchment);
  padding: 14px 16px;
  font-family: var(--font-title);
  font-weight: bold;
  color: var(--color-wood-brown);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-question::after {
  content: '▼';
  font-size: 0.7rem;
  transition: transform 0.3s;
}

.faq-answer {
  padding: 14px 16px;
  display: none;
  background: #fff;
}

.faq-item.open .faq-question::after {
  transform: rotate(180deg);
}

.faq-item.open .faq-answer {
  display: block;
}

/* ========================================
   动画效果
   ======================================== */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.stamp-animation {
  animation: stampDown 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

@keyframes stampDown {
  0% {
    transform: scale(2) rotate(-15deg);
    opacity: 0;
  }
  60% {
    transform: scale(0.9) rotate(-5deg);
    opacity: 1;
  }
  100% {
    transform: scale(1) rotate(-5deg);
    opacity: 0.85;
  }
}

/* ========================================
   响应式设计 - 移动端优先
   ======================================== */

/* 平板 (≥600px) */
@media (min-width: 600px) {
  .exhibit-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .app-envelope-grid {
    flex-direction: row;
    justify-content: center;
  }

  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ancient-book::before {
    display: block;
  }

  .book-content {
    flex-direction: row;
  }

  .expert-section {
    flex-direction: row;
    text-align: left;
  }

  .expert-info {
    text-align: left;
  }

  h1 { font-size: 2.2rem; }
  h2 { font-size: 1.8rem; }
}

/* 桌面 (≥900px) */
@media (min-width: 900px) {
  .museum-nav {
    display: block;
  }

  .mobile-menu-toggle {
    display: none;
  }

  .exhibit-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .hero-scroll h1 {
    font-size: 2.4rem;
  }

  .hero-slogan {
    font-size: 1.15rem;
  }

  h1 { font-size: 2.5rem; }
}

/* 大屏 (≥1200px) */
@media (min-width: 1200px) {
  .museum-container {
    max-width: 1200px;
  }
}

/* ========================================
   干扰标签隐藏
   ======================================== */
.jammer-block,
[class^="jm-"],
[id^="jm-"] {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  overflow: hidden !important;
  position: absolute !important;
  left: -9999px !important;
}
