/* ============================================================
   附近闲置群官网 - 全站样式
   ============================================================ */
:root {
    --primary: #1a7f5a;
    --primary-dark: #116045;
    --primary-light: #e7f5ef;
    --accent: #f08c1e;
    --text: #1f2d27;
    --text-2: #5c6f66;
    --border: #e2e8e4;
    --bg: #f6f9f7;
    --card: #ffffff;
    --radius: 12px;
    --shadow: 0 2px 10px rgba(20, 60, 45, .06);
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.7;
    font-size: 15px;
}
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; display: block; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px; }

/* ---------- 页头 ---------- */
.site-header {
    background: var(--card);
    border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 50;
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { display: flex; align-items: center; gap: 10px; font-size: 20px; font-weight: 700; color: var(--text); }
.logo-mark {
    width: 38px; height: 38px; border-radius: 10px;
    background: var(--primary); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
}
.nav { display: flex; gap: 6px; }
.nav a {
    padding: 8px 16px; border-radius: 8px;
    color: var(--text-2); font-weight: 500;
}
.nav a:hover { background: var(--primary-light); color: var(--primary); }
.nav a.active { background: var(--primary-light); color: var(--primary); }

/* ---------- 首页横幅 ---------- */
.hero {
    background: linear-gradient(135deg, #116045 0%, #1a7f5a 60%, #2a9c72 100%);
    color: #fff; padding: 64px 0 72px;
}
.hero h1 { font-size: 34px; line-height: 1.35; margin-bottom: 14px; }
.hero p.lead { font-size: 16px; opacity: .92; max-width: 640px; }
.hero .hero-tags { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 10px; }
.hero .hero-tags span {
    background: rgba(255,255,255,.14);
    border: 1px solid rgba(255,255,255,.28);
    padding: 5px 14px; border-radius: 999px; font-size: 13px;
}
.hero .hero-actions { margin-top: 26px; display: flex; gap: 12px; flex-wrap: wrap; }
.btn {
    display: inline-block; padding: 10px 24px; border-radius: 8px;
    font-size: 15px; font-weight: 500; cursor: pointer; border: none;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: #d97c12; color: #fff; }
.btn-ghost { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.6); }
.btn-ghost:hover { background: rgba(255,255,255,.12); color: #fff; }
.btn-plain { background: var(--primary); color: #fff; }
.btn-plain:hover { background: var(--primary-dark); color: #fff; }

/* ---------- 区块通用 ---------- */
.section { padding: 52px 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 26px; }
.section-head h2 { font-size: 24px; }
.section-head h2 small { font-size: 14px; color: var(--text-2); font-weight: 400; margin-left: 10px; }
.section-head .more { font-size: 14px; }

/* ---------- 分类 ---------- */
.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.cat-card {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 22px 18px; display: flex; align-items: center; gap: 14px;
    box-shadow: var(--shadow); transition: transform .15s ease, box-shadow .15s ease;
}
.cat-card:hover { transform: translateY(-3px); box-shadow: 0 6px 18px rgba(20,60,45,.12); }
.cat-card .cat-icon {
    width: 52px; height: 52px; border-radius: 12px; background: var(--primary-light);
    display: flex; align-items: center; justify-content: center; font-size: 26px; flex: none;
}
.cat-card h3 { font-size: 16px; }
.cat-card p { font-size: 12px; color: var(--text-2); }

/* ---------- 商品卡片 ---------- */
.prod-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.prod-card {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column;
    transition: transform .15s ease, box-shadow .15s ease;
}
.prod-card:hover { transform: translateY(-3px); box-shadow: 0 6px 18px rgba(20,60,45,.12); }
.prod-thumb { aspect-ratio: 4 / 3; overflow: hidden; background: var(--primary-light); }
.prod-thumb img { width: 100%; height: 100%; object-fit: cover; }
.prod-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.prod-body h3 { font-size: 15px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prod-body h3 a { color: var(--text); }
.prod-meta { display: flex; gap: 8px; flex-wrap: wrap; }
.tag {
    font-size: 12px; padding: 2px 10px; border-radius: 999px;
    background: var(--bg); color: var(--text-2); border: 1px solid var(--border);
}
.tag.hot { background: #fdf1e2; color: #b26210; border-color: #f3d9b5; }
.prod-price { margin-top: auto; display: flex; align-items: baseline; gap: 8px; }
.prod-price .now { color: #d23c2e; font-size: 20px; font-weight: 700; }
.prod-price .now::before { content: "¥"; font-size: 13px; }
.prod-price .old { color: #a4b0aa; font-size: 12px; text-decoration: line-through; }

/* ---------- 详情页 ---------- */
.breadcrumb { padding: 18px 0 0; font-size: 13px; color: var(--text-2); }
.breadcrumb a { color: var(--text-2); }
.detail-layout { display: grid; grid-template-columns: 460px 1fr; gap: 32px; margin-top: 18px; }
.detail-img { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border); background: #fff; }
.detail-img img { width: 100%; }
.detail-info h1 { font-size: 22px; line-height: 1.5; margin-bottom: 12px; }
.detail-price { display: flex; align-items: baseline; gap: 12px; background: #fdf6f5; border: 1px solid #f6dcd7; padding: 14px 18px; border-radius: 10px; margin: 14px 0; }
.detail-price .now { color: #d23c2e; font-size: 30px; font-weight: 700; }
.detail-price .now::before { content: "¥"; font-size: 16px; }
.detail-price .old { color: #a4908c; text-decoration: line-through; }
.detail-desc { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 20px 22px; margin-top: 18px; }
.detail-desc h3 { font-size: 16px; margin-bottom: 10px; }

/* ---------- 二维码横幅 ---------- */
.qr-band {
    background: var(--card); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 30px; display: flex; align-items: center; gap: 26px; box-shadow: var(--shadow);
}
.qr-band img.qr { width: 150px; height: 150px; border-radius: 10px; border: 1px solid var(--border); }
.qr-band h2 { font-size: 20px; margin-bottom: 8px; }
.qr-band p { color: var(--text-2); }

/* ---------- 文章页 ---------- */
.page-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 34px 38px; margin: 26px 0; }
.page-card h1 { font-size: 24px; margin-bottom: 18px; }
.page-card p { margin-bottom: 12px; }
.page-card ul { padding-left: 22px; margin-bottom: 12px; }

/* ---------- 分页 ---------- */
.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 30px; }
.pagination .pg {
    min-width: 36px; height: 36px; padding: 0 10px;
    display: flex; align-items: center; justify-content: center;
    background: var(--card); border: 1px solid var(--border); border-radius: 8px;
    color: var(--text-2); font-size: 14px;
}
.pagination .pg.current { background: var(--primary); border-color: var(--primary); color: #fff; }

/* ---------- 页脚 ---------- */
.site-footer { background: #14231d; color: #aebbb4; margin-top: 40px; padding: 44px 0 0; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1.4fr; gap: 30px; padding-bottom: 30px; }
.footer-col h4 { color: #fff; font-size: 16px; margin-bottom: 10px; }
.footer-col p { font-size: 13px; line-height: 1.9; }
.footer-col a { color: #aebbb4; }
.footer-col a:hover { color: #fff; }
.copyright { border-top: 1px solid rgba(255,255,255,.08); padding: 16px 0; font-size: 13px; }
.copyright .wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px; }
.copyright a { color: #aebbb4; }
.copyright a:hover { color: #fff; }

/* ---------- 空状态 ---------- */
.empty {
    text-align: center; padding: 60px 20px; color: var(--text-2);
    background: var(--card); border: 1px dashed var(--border); border-radius: var(--radius);
}

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
    .cat-grid { grid-template-columns: repeat(2, 1fr); }
    .prod-grid { grid-template-columns: repeat(2, 1fr); }
    .detail-layout { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; }
    .hero h1 { font-size: 26px; }
}
@media (max-width: 560px) {
    .prod-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .cat-grid { grid-template-columns: 1fr 1fr; }
    .nav a { padding: 8px 10px; font-size: 14px; }
    .logo-text { display: none; }
    .qr-band { flex-direction: column; text-align: center; }
}
