/* ==========================================================================
   黔菜菜谱大全 · style.css
   设计基线：03-ui/home-ui-desktop.png（1024×1536 → 1440×2160）
   分区预算见 03-ui/compare-log.md，勿随手改区块高度
   ========================================================================== */

:root{
  /* 面 */
  --bg: #f8ecd8;
  --bg-head: #faefdb;
  --surface: #efe5d1;
  --surface-2: #ede8d5;
  --paper: #fbf3e4;

  /* 墨 */
  --ink: #23180e;
  --body: #4c3d2b;
  --muted: #6c675a;
  --muted-2: #8b8672;

  /* 强调：稿上是深墨绿，不是红 */
  --green: #27462c;
  --green-deep: #1b3320;
  --green-soft: #3d5f43;
  --cream: #f7eedb;

  --line: rgba(35,24,14,.14);
  --line-soft: rgba(35,24,14,.07);

  /* 尺寸 */
  --wrap: 1364px;
  --header-h: 70px;
  --radius-sm: 4px;
  --radius: 8px;
  --pill: 999px;

  --font-serif: 'Songti SC',SimSun,'Noto Serif SC',Georgia,serif;
  --font-sans: 'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
}

*,*::before,*::after{ box-sizing: border-box; }

html{ -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body{
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img{ display: block; max-width: 100%; height: auto; }
a{ color: inherit; text-decoration: none; }
p{ margin: 0; }
ul,ol,dl,dd,dt{ margin: 0; padding: 0; list-style: none; }
button{ font: inherit; color: inherit; }

h1,h2,h3,h4{
  font-family: var(--font-serif);
  color: var(--ink);
  font-weight: 700;
  letter-spacing: .01em;
  margin: 0;
  line-height: 1.2;
}

:focus-visible{ outline: 2px solid var(--green-soft); outline-offset: 3px; }

.sr-only{
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip{
  position: absolute; left: -9999px; top: 0; z-index: 200;
  padding: 10px 16px; background: var(--green); color: var(--cream);
}
.skip:focus{ left: 12px; top: 12px; }

.wrap{
  width: min(var(--wrap), calc(100% - 76px));
  margin: 0 auto;
}

.eyebrow{
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-size: 11px;
  letter-spacing: .17em;
  text-transform: uppercase;
  color: var(--green);
  font-weight: 700;
  margin: 0;
}
.eyebrow .cn{
  font-family: var(--font-serif);
  text-transform: none;
  letter-spacing: .05em;
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
}

/* ==========================================================================
   M0 site-header  ·  预算 70px
   ========================================================================== */

.site-header{
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-head);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.site-header.is-stuck{
  border-bottom-color: var(--line-soft);
  box-shadow: 0 10px 26px -24px rgba(35,24,14,.7);
}

.header-inner{
  width: 100%;
  padding: 0 24px;
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 20px;
}

.brand{ display: flex; align-items: baseline; gap: 9px; flex: none; }
.brand-name{
  font-family: var(--font-serif);
  font-size: 21px;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: .02em;
}
.brand-kicker{
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--green);
  border-left: 1px solid var(--line);
  padding-left: 9px;
}

.nav{
  display: flex;
  align-items: center;
  gap: 17px;
  margin-left: auto;
  font-size: 13.5px;
  color: var(--body);
}
.nav a{
  position: relative;
  padding: 6px 0;
  white-space: nowrap;
  transition: color .18s ease;
}
.nav a::after{
  content: "";
  position: absolute; left: 0; right: 100%; bottom: 0;
  height: 1px; background: var(--green);
  transition: right .2s ease;
}
.nav a:hover{ color: var(--ink); }
.nav a:hover::after{ right: 0; }
.nav a[aria-current="page"]{ color: var(--green); font-weight: 700; }
.nav a[aria-current="page"]::after{ right: 0; }

.nav-toggle{
  display: none;
  margin-left: auto;
  width: 40px; height: 34px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
}
.nav-toggle span{
  display: block; width: 16px; height: 1.5px; margin: 3.5px auto;
  background: var(--ink);
}

.search{
  flex: none;
  display: flex; align-items: center; gap: 7px;
  width: 146px; height: 33px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: var(--pill);
  background: var(--paper);
  transition: border-color .18s ease, background .18s ease, width .2s ease;
}
.search:focus-within{ border-color: var(--green); background: #fff; width: 205px; }
.search svg{ width: 13px; height: 13px; flex: none; fill: none; stroke: var(--muted); stroke-width: 1.6; }
.search input{
  width: 100%;
  border: 0; background: transparent; outline: none;
  font: inherit; font-size: 12.5px; color: var(--ink);
}
.search input::placeholder{ color: var(--muted); }

/* ==========================================================================
   M1 hero  ·  预算 338px，满幅出血照 + 左侧压字（稿上无奶油面板）
   ========================================================================== */

.hero{
  position: relative;
  height: 338px;
  overflow: hidden;
  background: #2a1c0e;
}
.hero-photo{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: 64% 50%;
}
.hero-veil{
  position: absolute; inset: 0;
  background:
    linear-gradient(94deg, rgba(24,14,6,.92) 0%, rgba(26,15,7,.84) 32%, rgba(28,17,8,.56) 55%, rgba(30,18,8,.18) 78%, rgba(30,18,8,.06) 100%);
}
.hero-inner{
  position: relative;
  height: 100%;
  padding-top: 47px;
  color: var(--cream);
}
.hero-eyebrow{
  font-size: 11px;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: #cbd2a6;
  font-weight: 700;
}
.hero h1{
  margin-top: 14px;
  max-width: 640px;
  font-size: 40px;
  line-height: 1.28;
  color: #fdf6e7;
  letter-spacing: .015em;
}
.hero-lead{
  margin-top: 20px;
  max-width: 600px;
  font-size: 14.5px;
  line-height: 1.85;
  color: rgba(247,238,219,.88);
}
.hero-actions{
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.btn{
  display: inline-flex; align-items: center; justify-content: center;
  height: 36px; padding: 0 20px;
  border-radius: var(--pill);
  font-size: 13.5px;
  letter-spacing: .02em;
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}
.btn-solid{ background: var(--green); color: #fdf6e7; }
.btn-solid:hover{ background: var(--green-deep); transform: translateY(-1px); }
.btn-ghost{ border: 1px solid rgba(247,238,219,.5); color: #fdf6e7; }
.btn-ghost:hover{ border-color: rgba(247,238,219,.9); background: rgba(247,238,219,.1); }

.hero-stats{
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  color: rgba(247,238,219,.8);
  font-size: 13px;
}
.hero-stats li{
  padding: 0 13px;
  border-left: 1px solid rgba(247,238,219,.26);
  line-height: 1.2;
}
.hero-stats li:first-child{ padding-left: 0; border-left: 0; }
.hero-note{
  position: absolute;
  right: 0; bottom: 12px;
  font-size: 11.5px;
  letter-spacing: .02em;
  color: rgba(247,238,219,.6);
}

/* ==========================================================================
   通用小节头
   ========================================================================== */

.section{ padding-top: 20px; }
.path{ padding-top: 8px; }
.pantry{ padding-top: 10px; }
.technique{ padding-top: 4px; }
.tail{ padding-top: 6px; }
.sec-head h2{
  font-size: 22px;
  margin-top: 6px;
  max-width: 900px;
}
.sec-head.is-inline{
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}
.sec-head.is-inline h2{ margin-top: 0; font-size: 21px; }

.band-note{
  font-size: 12px;
  line-height: 1.7;
  color: var(--muted);
}

/* ==========================================================================
   M2 category-index  ·  预算 392px；7 列，图高 111
   ========================================================================== */

.categories .cat-grid{
  margin-top: 15px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 17px;
}
.cat-thumb{
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface);
}
.cat-thumb img{
  width: 100%;
  height: 111px;
  object-fit: cover;
  transition: transform .4s ease;
}
.cat:hover .cat-thumb img{ transform: scale(1.04); }
.cat-name{
  margin-top: 11px;
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
}
.cat-num{
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--green);
  margin-right: 5px;
}
.cat-desc{
  margin-top: 7px;
  font-size: 12.4px;
  line-height: 1.78;
  color: var(--muted);
}
.categories .band-note{ margin-top: 42px; }
.categories{ padding-bottom: 26px; }

/* ==========================================================================
   M3 flavor-atlas  ·  预算 195px；左标题块 300px + 右 8 列窄图
   ========================================================================== */

.atlas-band{
  margin-top: 4px;
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  gap: 38px;
  align-items: start;
}
.atlas-head h2{
  margin-top: 6px;
  font-size: 21px;
  max-width: 268px;
}
.atlas-sub{
  margin-top: 9px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--muted);
}
.atlas-grid{
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 17px;
}
.atlas-thumb{
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface);
}
.atlas-thumb img{ width: 100%; height: 74px; object-fit: cover; }
.atlas-name{
  margin-top: 5px;
  font-family: var(--font-serif);
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.35;
}
.atlas-name .cat-num{ font-size: 10px; margin-right: 4px; }
.atlas-desc{
  margin-top: 2px;
  font-size: 10.2px;
  line-height: 1.42;
  color: var(--muted);
}
.atlas .band-note{ margin-top: 9px; padding-left: 338px; }

/* ==========================================================================
   M4 featured-dishes  ·  预算 270px；1 行 6 列，图高 111
   ========================================================================== */

.featured .dish-grid{
  margin-top: 12px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 18px;
}
.dish-thumb{
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--surface);
}
.dish-thumb img{ width: 100%; height: 100px; object-fit: cover; transition: transform .4s ease; }
.dish:hover .dish-thumb img{ transform: scale(1.04); }
.dish-name{
  margin-top: 10px;
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}
.dish-desc{
  margin-top: 5px;
  font-size: 11.8px;
  line-height: 1.68;
  color: var(--muted);
}
.featured .band-note{ margin-top: 12px; }

/* ==========================================================================
   M5 kitchen-path  ·  预算 180px；左右出血图 + 中间三段步骤
   ========================================================================== */

/* 双侧出血图：出血宽度以 1440 设计宽为界，超宽屏跟着容器一起收 */
.path-band{
  position: relative;
  margin-top: 10px;
  width: min(1440px, 100%);
  margin-left: auto;
  margin-right: auto;
  display: grid;
  grid-template-columns: 300px 24px minmax(0, 1fr) 24px 238px;
  align-items: stretch;
}
.path-photo{
  overflow: hidden;
  background: var(--surface);
}
.path-photo img{ width: 100%; height: 100%; min-height: 120px; object-fit: cover; }
.path-photo.is-left{ grid-column: 1; }
.path-body{ grid-column: 3; }
.path-photo:not(.is-left){ grid-column: 5; }
.path-body h2{ font-size: 20px; margin-top: 5px; }
.path-steps{
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 26px;
}
.step-no{
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .1em;
  color: var(--green);
}
.step-name{
  margin-top: 2px;
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
}
.step-desc{
  margin-top: 3px;
  font-size: 10.2px;
  line-height: 1.4;
  color: var(--muted);
}
.path-warn{
  margin-top: 6px;
  font-size: 10.4px;
  line-height: 1.42;
  color: var(--body);
  border-left: 2px solid var(--green);
  padding-left: 11px;
}

/* ==========================================================================
   M6 seasoning-shelf  ·  预算 155px；4 列，图 100×78
   ========================================================================== */

.pantry .pantry-grid{
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}
.pantry-item{ display: flex; gap: 11px; align-items: flex-start; }
.pantry-item img{
  width: 92px; height: 68px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex: none;
}
.pantry-name{
  font-family: var(--font-serif);
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
}
.pantry-desc{
  margin-top: 3px;
  font-size: 11px;
  line-height: 1.58;
  color: var(--muted);
}
.pantry .band-note{ margin-top: 6px; }

/* ==========================================================================
   M7 technique-strip  ·  预算 140px；4 列，图 86×62
   ========================================================================== */

.technique .tech-grid{
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}
.tech-item{ display: flex; gap: 11px; align-items: flex-start; }
.tech-item img{
  width: 74px; height: 52px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  flex: none;
}
.tech-name{
  font-family: var(--font-serif);
  font-size: 13.5px;
  font-weight: 700;
  color: var(--ink);
}
.tech-desc{
  margin-top: 2px;
  font-size: 10.6px;
  line-height: 1.5;
  color: var(--muted);
}
.technique .band-note{ margin-top: 5px; }

/* ==========================================================================
   M8 faq + M9 scope-note  ·  同一行：左 FAQ 57%，右 NOTES 30%
   ========================================================================== */

.tail-band{
  margin-top: 10px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 392px;
  gap: 170px;
  align-items: start;
}
.faq-list{ margin-top: 9px; }
.faq-item{ border-top: 1px solid var(--line); }
.faq-item:last-child{ border-bottom: 1px solid var(--line); }
.faq-item summary{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 2px 2px;
  cursor: pointer;
  font-family: var(--font-serif);
  font-size: 12.4px;
  font-weight: 700;
  color: var(--ink);
  list-style: none;
}
.faq-item summary::-webkit-details-marker{ display: none; }
.faq-item summary::after{
  content: "+";
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: var(--green);
  line-height: 1;
}
.faq-item[open] summary::after{ content: "−"; }
.faq-item summary:hover{ color: var(--green); }
.faq-answer{
  padding: 0 26px 8px 2px;
  font-size: 11.2px;
  line-height: 1.56;
  color: var(--body);
}

.scope-block{ margin-top: 7px; }
.scope-block h3{
  font-size: 13px;
  color: var(--green);
  letter-spacing: .04em;
}
.scope-block p{
  margin-top: 2px;
  font-size: 10.6px;
  line-height: 1.48;
  color: var(--body);
}

/* ==========================================================================
   M10 site-footer  ·  预算 205px，深墨绿通栏 #27462c
   ========================================================================== */

.site-footer{
  margin-top: 5px;
  background: var(--green);
  color: #e6e3cc;
  padding: 41px 0 35px;
}
.footer-top{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 60px;
  flex-wrap: wrap;
}
.footer-brand{
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  color: #f7f2df;
}
.footer-line{
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.75;
  color: rgba(247,242,223,.82);
  max-width: 560px;
}
.footer-col{ flex: 1 1 180px; min-width: 170px; }
.footer-col-title{
  margin: 0 0 12px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(247,242,223,.62);
}
.footer-col a{
  display: block;
  font-size: 13px;
  line-height: 2.1;
  color: rgba(247,242,223,.9);
}
.footer-col a:hover{ color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer-links{
  display: flex;
  flex-wrap: wrap;
  gap: 9px 20px;
  font-size: 13px;
  color: rgba(247,242,223,.9);
  max-width: 560px;
}
.footer-links a:hover{ color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.footer-about{ margin-top: 9px; font-size: 12.5px; color: rgba(247,242,223,.82); }
.footer-about a{ color: #f7f2df; }
.footer-icp{ margin-top: 6px; font-size: 12px; color: rgba(247,242,223,.68); }
.footer-copy{
  margin-top: 26px;
  padding-top: 14px;
  border-top: 1px solid rgba(247,242,223,.2);
  font-size: 11.5px;
  color: rgba(247,242,223,.68);
}

/* ==========================================================================
   响应式
   ========================================================================== */

@media (max-width: 1260px){
  .hero h1{ font-size: 36px; }
  .categories .cat-grid{ grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
  .atlas-band{ grid-template-columns: 1fr; gap: 18px; }
  .atlas-grid{ grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
  .atlas .band-note{ padding-left: 0; }
  .featured .dish-grid{ grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
  .path-band{ grid-template-columns: minmax(0,1fr) 240px; gap: 24px; }
  .path-photo.is-left{ display: none; }
  .path-body{ grid-column: 1; }
  .path-photo:not(.is-left){ grid-column: 2; }
  .pantry .pantry-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .technique .tech-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tail-band{ grid-template-columns: minmax(0,1fr) 320px; gap: 48px; }
}

@media (max-width: 1080px){
  .nav{ display: none; }
  .nav-toggle{ display: block; order: 2; }
  .search{ order: 3; width: 128px; }
  .site-header.menu-open .nav{
    display: flex;
    position: absolute;
    left: 0; right: 0; top: var(--header-h);
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 8px 22px 14px;
    background: var(--bg-head);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 18px 30px -26px rgba(35,24,14,.7);
  }
  .site-header.menu-open .nav a{ width: 100%; padding: 10px 0; font-size: 15px; }
  .tail-band{ grid-template-columns: 1fr; gap: 26px; }
  .path-band{ grid-template-columns: 1fr; width: 100%; }
  .path-body{ grid-column: 1; }
  .path-photo:not(.is-left){ grid-column: 1; height: 210px; }
}

@media (max-width: 820px){
  .wrap{ width: calc(100% - 44px); }
  .header-inner{ padding: 0 16px; gap: 12px; }
  .search{ width: 112px; padding: 0 11px; }
  .search input{ font-size: 12px; }
  .hero{ height: auto; min-height: 380px; }
  .hero-inner{ padding: 32px 0 40px; }
  .hero h1{ font-size: 28px; max-width: 100%; }
  .hero-lead{ font-size: 14px; }
  .hero-note{ position: static; margin-top: 14px; }
  .hero-stats{ margin-top: 16px; }
  .hero-stats li{ padding: 0 9px; font-size: 12px; }
  .categories .cat-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .atlas-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .featured .dish-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .path-steps{ grid-template-columns: 1fr; gap: 14px; }
  .pantry .pantry-grid{ grid-template-columns: 1fr; }
  .technique .tech-grid{ grid-template-columns: 1fr; }
  .sec-head.is-inline{ display: block; }
  .sec-head.is-inline h2{ margin-top: 5px; }
  .footer-top{ gap: 20px; flex-direction: column; }
  .footer-col{ min-width: 0; width: 100%; }
}

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *{ transition: none !important; animation: none !important; }
}
