/*
Theme Name: 孙大妈小吃知识库
Theme URI: https://sdmzhishiku.com/
Author: 孙大妈小吃知识库
Description: A warm, editorial WordPress theme for the Sundama snack knowledge base.
Version: 2.2.1
Text Domain: sundama-knowledge
*/

:root {
  --ink: #252525;
  --muted: #6e6a63;
  --red: #b52a1d;
  --red-dark: #8e2118;
  --cream: #fbf8f2;
  --paper: #ffffff;
  --line: #e9e2d7;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--cream);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  line-height: 1.75;
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
.site-shell { min-height: 100vh; }
.container { width: min(var(--max), calc(100% - 48px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(251, 248, 242, .96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.header-inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0;
}
.brand-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--red);
  border-radius: 50%;
  font-size: 16px;
}
.main-nav { display: flex; align-items: center; gap: 22px; font-size: 14px; list-style: none; margin: 0; padding: 0; overflow-x: auto; white-space: nowrap; }
.main-nav li { list-style: none; margin: 0; padding: 0; }
.main-nav li::before { content: none; }
.main-nav a { color: #4f4a43; }
.main-nav a:hover { color: var(--red); }
.nav-cta {
  padding: 9px 16px;
  color: #fff !important;
  background: var(--red);
  border-radius: 4px;
}

.hero {
  min-height: 620px;
  display: flex;
  align-items: center;
  background:
    linear-gradient(90deg, rgba(28, 19, 15, .83) 0%, rgba(28, 19, 15, .58) 39%, rgba(28, 19, 15, .08) 72%),
    url("assets/hero.jpeg") center / cover no-repeat;
}
.hero-copy { max-width: 600px; padding: 88px 0; color: #fff; }
.eyebrow {
  margin: 0 0 16px;
  color: #f2c58f;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
}
.hero h1 { margin: 0 0 18px; font-size: clamp(40px, 6vw, 72px); line-height: 1.1; letter-spacing: 0; }
.hero p { max-width: 520px; margin: 0 0 30px; color: rgba(255,255,255,.86); font-size: 19px; }
.button-row { display: flex; flex-wrap: wrap; gap: 12px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 4px;
  font-size: 15px;
  font-weight: 700;
}
.button-primary { color: #fff; background: var(--red); }
.button-primary:hover { background: var(--red-dark); }
.button-light { color: #fff; border-color: rgba(255,255,255,.7); background: rgba(255,255,255,.08); }
.button-light:hover { background: rgba(255,255,255,.18); }

.section { padding: 92px 0; }
.section-paper { background: var(--paper); }
.section-heading { max-width: 660px; margin-bottom: 38px; }
.section-heading.center { margin-right: auto; margin-left: auto; text-align: center; }
.section-kicker { margin: 0 0 8px; color: var(--red); font-size: 13px; font-weight: 800; letter-spacing: .1em; }
.section h2 { margin: 0 0 12px; font-size: clamp(30px, 4vw, 44px); line-height: 1.2; }
.section-heading p { margin: 0; color: var(--muted); font-size: 17px; }
.grid { display: grid; gap: 18px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-5 { grid-template-columns: repeat(5, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.tile {
  min-height: 166px;
  padding: 24px;
  border: 1px solid var(--line);
  background: var(--paper);
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.tile:hover { transform: translateY(-3px); border-color: #d8b39e; box-shadow: 0 12px 28px rgba(75, 43, 23, .08); }
.tile h3 { margin: 0 0 8px; font-size: 20px; }
.tile p { margin: 0; color: var(--muted); font-size: 14px; }
.tile-link { display: inline-block; margin-top: 15px; color: var(--red); font-size: 14px; font-weight: 700; }
.number { margin-bottom: 18px; color: var(--red); font-size: 14px; font-weight: 800; }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}
.split-image { min-height: 420px; background: url("assets/hero.jpeg") center / cover no-repeat; }
.check-list { display: grid; gap: 14px; margin: 26px 0 0; padding: 0; list-style: none; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; color: #514c45; }
.check-list li::before { content: "✓"; color: var(--red); font-weight: 800; }
.disclaimer { color: var(--muted); font-size: 13px; }

.faq-list { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 44px; }
.faq-list details { padding: 18px 0; border-top: 1px solid var(--line); }
.faq-list summary { cursor: pointer; font-weight: 700; }
.faq-list p { margin: 12px 0 0; color: var(--muted); }

.contact-band { color: #fff; background: var(--red); }
.contact-band .section-heading p { color: rgba(255,255,255,.78); }
.contact-band .button-primary { color: var(--red); background: #fff; }
.contact-band .button-light { border-color: rgba(255,255,255,.6); }

.site-footer { padding: 34px 0; color: #766e64; background: #f2ede5; font-size: 13px; }
.footer-inner { display: flex; justify-content: space-between; gap: 24px; }
.footer-inner p { margin: 4px 0; }

.entry-content { padding: 72px 0 96px; background: var(--paper); }
.entry-content .container { max-width: 900px; }
.entry-content article { max-width: 820px; }
.entry-content h1 { margin: 0 0 18px; color: var(--ink); font-size: clamp(36px, 5vw, 58px); line-height: 1.16; }
.entry-content h2 { margin: 48px 0 14px; color: var(--ink); font-size: 29px; line-height: 1.3; }
.entry-content h3 { margin: 28px 0 8px; color: var(--ink); font-size: 21px; }
.entry-content p, .entry-content li { color: #514c45; }
.entry-content p { max-width: 760px; }
.entry-content ul { padding-left: 1.35em; }
.entry-content .content-lead { margin: 0 0 32px; color: var(--muted); font-size: 18px; }
.entry-content .info-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 28px 0 36px; }
.entry-content .info-card { padding: 20px; border: 1px solid var(--line); background: #fcfaf6; }
.entry-content .info-card h3 { margin-top: 0; font-size: 18px; }
.entry-content .article-list { display: grid; gap: 12px; margin: 22px 0 36px; }
.entry-content .article-card { display: block; padding: 18px 20px; border: 1px solid var(--line); background: #fff; }
.entry-content .article-card:hover { border-color: #d8b39e; box-shadow: 0 10px 24px rgba(75, 43, 23, .06); }
.entry-content .article-card h3 { margin: 0 0 5px; }
.entry-content .article-card p { margin: 0; color: var(--muted); font-size: 14px; }
.entry-content .notice { margin: 30px 0; padding: 18px 20px; border-left: 4px solid var(--red); background: #fbf3e9; color: #514c45; }
.contact-box { margin: 26px 0; padding: 20px 22px; border: 1px solid #e6cdb9; background: #fff9f2; }
.contact-box p { margin: 6px 0 12px; }
.hub-image { margin: 0 0 34px; }
.entry-content .info-card h2 { margin: 0 0 12px; font-size: 22px; }
.hub-image img { width: 100%; max-height: 330px; object-fit: cover; border-radius: 2px; }
.hub-image figcaption { margin-top: 8px; color: var(--muted); font-size: 12px; }
.breadcrumbs { margin-bottom: 28px; color: var(--muted); font-size: 13px; }
.breadcrumbs a, .text-link { color: var(--red); font-weight: 700; }
.article-meta { margin: 0 0 12px; color: var(--muted) !important; font-size: 13px !important; }
.post-categories { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 30px; padding: 0; list-style: none; }
.post-categories li { list-style: none; }
.post-categories a { display: inline-block; padding: 4px 10px; color: var(--red); border: 1px solid #e5c9b4; background: #fffaf4; font-size: 13px; }
.post-links { display: flex; justify-content: space-between; gap: 18px; margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 14px; }
.post-links a { color: var(--red); }

@media (max-width: 900px) {
  .header-inner { align-items: flex-start; padding: 14px 0; }
  .main-nav { max-width: 54vw; gap: 14px; font-size: 12px; padding-bottom: 4px; }
  .grid-5, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .split-image { min-height: 300px; order: -1; }
  .entry-content .info-grid { grid-template-columns: 1fr; }
  .post-links { display: block; }
  .post-links a { display: block; margin: 8px 0; }
}
@media (max-width: 640px) {
  .container { width: min(var(--max), calc(100% - 32px)); }
  .header-inner { min-height: 64px; display: block; }
  .brand { font-size: 17px; }
  .brand-mark { width: 28px; height: 28px; }
  .main-nav { max-width: 100%; margin-top: 10px; }
  .hero { min-height: 620px; background-position: 64% center; }
  .hero-copy { padding: 72px 0; }
  .hero h1 { font-size: 43px; }
  .hero p { font-size: 17px; }
  .section { padding: 64px 0; }
  .grid-3, .grid-5, .grid-4, .faq-list { grid-template-columns: 1fr; }
  .tile { min-height: auto; }
  .footer-inner { display: block; }
}
