/* ===== 豫见农香 - 公共样式 ===== */

/* Reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  font-family: 'Inter', sans-serif;
  background: #FAFAF5;
  color: #1A1A1A;
  overflow-x: hidden;
}

/* 滚动条 */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: #FAFAF5;
}
::-webkit-scrollbar-thumb {
  background: #2E7D32;
  border-radius: 4px;
}

/* 噪点纹理背景 */
body::before {
  content: '';
  position: fixed;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

/* 入场动画 */
@keyframes slideUp {
  0% { opacity: 0; transform: translateY(30px); }
  100% { opacity: 1; transform: translateY(0); }
}
.anim-up {
  animation: slideUp .8s cubic-bezier(.16, 1, .3, 1) forwards;
}
.anim-up-d1 {
  animation: slideUp .8s cubic-bezier(.16, 1, .3, 1) .1s forwards;
  opacity: 0;
}
.anim-up-d2 {
  animation: slideUp .8s cubic-bezier(.16, 1, .3, 1) .2s forwards;
  opacity: 0;
}

/* 导航栏 */
.nav-glass {
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
  transition: all .3s;
}
.nav-scrolled {
  background: rgba(255, 255, 255, .98);
  border-bottom-color: rgba(0, 0, 0, .1);
}

/* 导航链接 */
.nav-link {
  position: relative;
  color: #6B7280;
  transition: color .3s;
  font-size: .875rem;
  font-weight: 500;
}
.nav-link:hover,
.nav-link.active {
  color: #1B5E20;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #2E7D32;
  transition: width .3s;
}
.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* 主按钮 */
.btn-gold {
  background: #2E7D32;
  color: #fff;
  font-weight: 600;
  font-size: .875rem;
  padding: 12px 28px;
  border-radius: 10px;
  transition: all .3s;
  border: none;
  cursor: pointer;
}
.btn-gold:hover {
  background: #4CAF50;
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(46, 125, 50, .3);
}

/* 描边按钮 */
.btn-outline {
  background: transparent;
  color: #2E7D32;
  font-weight: 500;
  font-size: .875rem;
  padding: 11px 27px;
  border-radius: 10px;
  border: 1px solid rgba(46, 125, 50, .4);
  transition: all .3s;
  cursor: pointer;
}
.btn-outline:hover {
  background: rgba(46, 125, 50, .1);
  border-color: #2E7D32;
}

/* 分割线 */
.divider-gold {
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, #2E7D32, #4CAF50);
  border-radius: 2px;
}

/* 滚动显示动画 */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity .8s cubic-bezier(.16, 1, .3, 1), transform .8s cubic-bezier(.16, 1, .3, 1);
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* 汉堡菜单 */
.hamburger-line {
  display: block;
  width: 24px;
  height: 2px;
  background: #1A1A1A;
  transition: all .3s;
  border-radius: 1px;
}
.hamburger-open .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger-open .hamburger-line:nth-child(2) {
  opacity: 0;
}
.hamburger-open .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* 移动端菜单 */
.mobile-menu {
  transform: translateX(100%);
  transition: transform .4s cubic-bezier(.16, 1, .3, 1);
}
.mobile-menu.open {
  transform: translateX(0);
}

/* ===== 多页面共享组件样式 ===== */

/* 产品卡片 (index + products) */
.product-card {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, .06);
  border-radius: 16px;
  overflow: hidden;
  transition: all .4s cubic-bezier(.16, 1, .3, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
}
.product-card:hover {
  border-color: rgba(46, 125, 50, .3);
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, .08);
}
.product-card:hover .p-img {
  transform: scale(1.08);
}
.product-card:hover .p-actions {
  opacity: 1;
  transform: translateY(0);
}
.p-img-wrap {
  overflow: hidden;
  position: relative;
}
.p-img {
  transition: transform .6s cubic-bezier(.16, 1, .3, 1);
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
}
.p-actions {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  opacity: 0;
  transform: translateY(10px);
  transition: all .3s;
}

/* 标签 (index + products) */
.tag-origin {
  background: rgba(46, 125, 50, .1);
  color: #2E7D32;
  border: 1px solid rgba(46, 125, 50, .2);
}
.tag-category {
  background: rgba(212, 163, 115, .15);
  color: #D4A373;
  border: 1px solid rgba(212, 163, 115, .25);
}

/* 新闻卡片 (index + news) */
.news-card {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, .06);
  border-radius: 16px;
  overflow: hidden;
  transition: all .3s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .04);
}
.news-card:hover {
  border-color: rgba(46, 125, 50, .3);
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, .08);
}
.news-card:hover img {
  transform: scale(1.05);
}

/* 分类标签 (index + news) */
.cat-tag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 500;
}

/* 筛选按钮 (products + news) */
.filter-btn {
  padding: 6px 16px;
  border-radius: 8px;
  font-size: .8rem;
  border: 1px solid rgba(0, 0, 0, .1);
  color: #6B7280;
  cursor: pointer;
  transition: all .2s;
  background: transparent;
}
.filter-btn:hover {
  border-color: rgba(46, 125, 50, .3);
  color: #1B5E20;
}
.filter-btn.active {
  background: rgba(46, 125, 50, .1);
  border-color: rgba(46, 125, 50, .4);
  color: #2E7D32;
}

/* 地图区域 (index + culture) */
.map-region {
  position: absolute;
  cursor: pointer;
  transition: all .3s;
}
.map-region:hover .map-dot {
  transform: scale(1.5);
  box-shadow: 0 0 20px rgba(46, 125, 50, .6);
}
.map-region:hover .map-label {
  opacity: 1;
}
.map-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #2E7D32;
  border: 2px solid #4CAF50;
  transition: all .3s;
}
.map-label {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  white-space: nowrap;
  font-size: 11px;
  color: #2E7D32;
  opacity: .7;
  transition: opacity .3s;
  pointer-events: none;
}

/* 骨架屏 (index + products + news) */
.skeleton {
  background: linear-gradient(90deg, rgba(0, 0, 0, .03) 25%, rgba(0, 0, 0, .06) 50%, rgba(0, 0, 0, .03) 75%);
  background-size: 200% 100%;
  animation: skeleton 1.5s infinite;
}
@keyframes skeleton {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* 分类滚动隐藏滚动条 (products + news) */
.cat-scroll::-webkit-scrollbar {
  display: none;
}
.cat-scroll {
  -ms-overflow-style: none;
  scrollbar-width: none;
}
