/* ============================================================
   评享 PingXiang —— 全民到店点评平台 官网全局样式
   全站复用：导航 / 页脚 / 容器 / 按钮 / 卡片 / 排版 / 动效
   ============================================================ */

/* ---------- 设计变量 ---------- */
:root {
  --primary: #ff5a36;
  --primary-dark: #e8431f;
  --primary-light: #ff8a5c;
  --accent: #2ec4b6;       /* 优惠券 / 省钱 */
  --accent-dark: #18a89b;
  --warning: #ffb020;
  --dark: #1a1d29;
  --gray-800: #272b38;
  --gray-700: #374151;
  --gray-600: #4b5563;
  --gray-500: #6b7280;
  --gray-400: #9ca3af;
  --gray-200: #e5e7eb;
  --gray-100: #f3f4f6;
  --gray-50: #f9fafb;
  --white: #ffffff;

  --grad-primary: linear-gradient(135deg, #ff7a45 0%, #ff5a36 50%, #ff3d6e 100%);
  --grad-hero: linear-gradient(135deg, #fff5ef 0%, #ffe9de 45%, #ffe1ec 100%);
  --grad-accent: linear-gradient(135deg, #2ec4b6 0%, #20a39e 100%);
  --grad-dark: linear-gradient(135deg, #1a1d29 0%, #2d3142 100%);

  --shadow-sm: 0 1px 2px rgba(26, 29, 41, .06), 0 1px 3px rgba(26, 29, 41, .08);
  --shadow-md: 0 4px 12px rgba(26, 29, 41, .08), 0 2px 4px rgba(26, 29, 41, .05);
  --shadow-lg: 0 12px 32px rgba(26, 29, 41, .12), 0 4px 8px rgba(26, 29, 41, .06);
  --shadow-primary: 0 10px 24px rgba(255, 90, 54, .32);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 999px;

  --container: 1200px;
  --nav-h: 68px;
}

/* ---------- 基础重置 ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  color: var(--gray-700);
  background: var(--white);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
h1, h2, h3, h4 { color: var(--dark); line-height: 1.25; font-weight: 700; }
h1 { font-size: clamp(28px, 4vw, 44px); }
h2 { font-size: clamp(24px, 3vw, 34px); }
h3 { font-size: clamp(18px, 2vw, 22px); }

/* ---------- 通用容器 ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}
section { padding: 80px 0; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head .tag {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--primary);
  background: rgba(255, 90, 54, .1);
  padding: 6px 16px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
}
.section-head h2 { margin-bottom: 14px; }
.section-head p { color: var(--gray-500); font-size: 17px; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  font-size: 15px;
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: all .25s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--grad-primary); color: #fff; box-shadow: var(--shadow-primary); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(255, 90, 54, .42); }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-ghost { background: var(--white); color: var(--gray-700); box-shadow: var(--shadow-sm); }
.btn-ghost:hover { color: var(--primary); transform: translateY(-2px); }
.btn-dark { background: var(--dark); color: #fff; }
.btn-dark:hover { background: #000; transform: translateY(-2px); }

/* ---------- 导航栏 ---------- */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(255, 255, 255, .85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid rgba(0, 0, 0, .05);
  z-index: 1000;
  transition: box-shadow .25s ease;
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
.nav-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 800; color: var(--dark); }
.logo .logo-mark {
  width: 36px; height: 36px;
  background: var(--grad-primary);
  border-radius: 10px;
  display: grid; place-items: center;
  color: #fff; font-size: 18px;
  box-shadow: var(--shadow-primary);
}
.logo span b { color: var(--primary); }
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links a {
  padding: 8px 14px;
  font-size: 15px;
  font-weight: 500;
  color: var(--gray-600);
  border-radius: var(--radius-sm);
  transition: all .2s;
}
.nav-links a:hover { color: var(--primary); background: rgba(255, 90, 54, .08); }
.nav-links a.active { color: var(--primary); font-weight: 600; }
.nav-cta { display: flex; align-items: center; gap: 10px; }
.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
}
.nav-toggle span {
  width: 22px; height: 2px; background: var(--dark);
  border-radius: 2px; transition: all .3s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- 页脚 ---------- */
.footer { background: var(--grad-dark); color: #cfd2dc; padding: 64px 0 24px; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.footer-brand .logo { color: #fff; margin-bottom: 14px; }
.footer-brand p { font-size: 14px; line-height: 1.8; color: #9fa3b3; max-width: 300px; }
.footer h4 { color: #fff; font-size: 15px; margin-bottom: 16px; font-weight: 600; }
.footer ul li { margin-bottom: 10px; }
.footer ul li a { font-size: 14px; color: #9fa3b3; transition: color .2s; }
.footer ul li a:hover { color: var(--primary-light); }
.footer-contact li { font-size: 14px; color: #9fa3b3; margin-bottom: 10px; }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 24px;
  font-size: 13px;
  color: #6f7384;
  flex-wrap: wrap;
  gap: 12px;
}

/* ---------- 卡片 ---------- */
.card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--gray-100);
  transition: all .3s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.feature-icon {
  width: 56px; height: 56px;
  border-radius: 16px;
  display: grid; place-items: center;
  font-size: 26px;
  margin-bottom: 18px;
  color: #fff;
}
.ic-orange { background: linear-gradient(135deg, #ff8a5c, #ff5a36); }
.ic-teal { background: linear-gradient(135deg, #4fd1c5, #2ec4b6); }
.ic-purple { background: linear-gradient(135deg, #a78bfa, #7c5cff); }
.ic-blue { background: linear-gradient(135deg, #60a5fa, #3b82f6); }
.ic-yellow { background: linear-gradient(135deg, #fbbf24, #f59e0b); }
.ic-pink { background: linear-gradient(135deg, #fda4af, #fb7185); }

/* ---------- 网格 ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px; }

/* ---------- 标签 / 徽标 ---------- */
.badge {
  display: inline-block;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  border-radius: var(--radius-full);
  background: rgba(255, 90, 54, .1);
  color: var(--primary);
}
.badge-teal { background: rgba(46, 196, 182, .12); color: var(--accent-dark); }
.badge-blue { background: rgba(59, 130, 246, .1); color: #3b82f6; }

/* ---------- 页内页头（子页面） ---------- */
.page-hero {
  padding-top: calc(var(--nav-h) + 60px);
  padding-bottom: 60px;
  background: var(--grad-hero);
  text-align: center;
}
.page-hero .tag {
  display: inline-block;
  font-size: 13px; font-weight: 600; letter-spacing: 1px;
  color: var(--primary); background: rgba(255, 90, 54, .12);
  padding: 6px 16px; border-radius: var(--radius-full); margin-bottom: 16px;
}
.page-hero h1 { margin-bottom: 14px; }
.page-hero p { color: var(--gray-600); font-size: 17px; max-width: 640px; margin: 0 auto; }

/* ---------- 滚动进入动画 ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .7s ease, transform .7s ease; }
.reveal.visible { opacity: 1; transform: none; }

/* ---------- 返回顶部 ---------- */
.back-top {
  position: fixed; right: 24px; bottom: 24px;
  width: 48px; height: 48px;
  background: var(--grad-primary);
  color: #fff; border-radius: 50%;
  display: grid; place-items: center;
  box-shadow: var(--shadow-primary);
  opacity: 0; visibility: hidden;
  transition: all .3s;
  z-index: 900;
  font-size: 18px;
}
.back-top.show { opacity: 1; visibility: visible; }
.back-top:hover { transform: translateY(-3px); }

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  section { padding: 56px 0; }
  .nav-toggle { display: flex; }
  .nav-cta .btn-primary { display: none; }
  .nav-links {
    position: fixed;
    top: var(--nav-h); left: 0; right: 0;
    background: #fff;
    flex-direction: column;
    align-items: stretch;
    padding: 16px 24px 24px;
    gap: 4px;
    box-shadow: var(--shadow-lg);
    transform: translateY(-130%);
    transition: transform .35s ease;
    border-bottom: 1px solid var(--gray-100);
  }
  .nav-links.open { transform: translateY(0); }
  .nav-links a { padding: 12px 8px; font-size: 16px; border-bottom: 1px solid var(--gray-100); }
  .nav-links a:last-child { border-bottom: none; }
  .grid-3, .grid-4, .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .card { padding: 24px; }
}
