/* 页面布局 · 东北菜菜谱大全首页
   基准 1440×2160；分区预算见 03-ui/compare-log.md
   内容栏 1354 = 1440 − 2×43 */

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

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

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: var(--fs-4);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, p { margin: 0; }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gut);
}

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

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 99;
  padding: 10px 16px;
  background: var(--accent);
  color: var(--on-dark);
}
.skip-link:focus { left: 8px; top: 8px; }

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

/* ---------------- 页头 M0 0–76 ---------------- */
.site-header {
  height: 76px;
  background: var(--accent);
  color: var(--on-dark);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 26px;
  height: 76px;
}
.brand {
  display: flex;
  flex-direction: column;
  flex: 0 0 auto;
  line-height: 1.1;
}
.brand-cn {
  font-family: var(--font-serif);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fdf1de;
}
.brand-en {
  margin-top: 3px;
  font-size: 9px;
  letter-spacing: 0.3em;
  color: rgba(247, 231, 210, 0.72);
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 17px;
  margin-left: auto;
  font-size: 13px;
}
.main-nav a {
  position: relative;
  color: rgba(253, 241, 222, 0.88);
  padding: 4px 0;
  white-space: nowrap;
}
.main-nav a:hover { color: #fff7ea; }
.main-nav a.is-active { color: #fff7ea; }
.main-nav a.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -4px;
  height: 2px;
  background: #f4dec1;
}
.nav-cta {
  flex: 0 0 auto;
  margin-left: 6px;
  padding: 6px 14px;
  border: 1px solid rgba(247, 231, 210, 0.5);
  border-radius: var(--r-pill);
  font-size: 12px;
  color: #fdf1de;
}
.nav-cta:hover { background: rgba(247, 231, 210, 0.14); }
.nav-drop { position: relative; }
.nav-drop-link { display: inline-flex; align-items: center; gap: 5px; }
.nav-caret {
  width: 0; height: 0;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 5px solid currentColor;
  opacity: 0.75;
}
.drop-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  z-index: 40;
  min-width: 168px;
  max-height: 360px;
  overflow-y: auto;
  margin: 10px 0 0;
  padding: 8px 0;
  border-radius: var(--r-card);
  background: #fffaf2;
  box-shadow: 0 14px 30px rgba(26, 20, 16, 0.22);
  transform: translateX(-50%);
  list-style: none;
}
.nav-drop:hover .drop-menu { display: block; }
.drop-menu a {
  display: block;
  padding: 7px 16px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--body);
  white-space: nowrap;
}
.drop-menu a:hover { background: rgba(129, 39, 28, 0.08); color: var(--accent); }
.nav-toggle {
  display: none;
  width: 40px; height: 40px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}
.nav-toggle-bar {
  display: block;
  width: 22px; height: 2px;
  margin: 4px auto;
  background: #fdf1de;
}

/* ---------------- 首屏 M1 76–515（439） ---------------- */
.hero {
  position: relative;
  height: 439px;
  overflow: hidden;
  background: var(--bg-hero);
  isolation: isolate;
}
.hero-media {
  position: absolute;
  top: 0;
  right: max(0px, calc((100% - 1440px) / 2));
  bottom: 0;
  width: 740px;
  margin: 0;
  z-index: 0;
}
.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(244, 222, 193, 0.95) 0%, rgba(244, 222, 193, 0.9) 26%, rgba(244, 222, 193, 0.72) 38%, rgba(244, 222, 193, 0.38) 50%, rgba(244, 222, 193, 0.1) 60%, rgba(244, 222, 193, 0) 70%),
    linear-gradient(180deg, rgba(244, 222, 193, 0.1) 0%, rgba(250, 240, 225, 0) 26%, rgba(250, 240, 225, 0) 96%, rgba(250, 240, 225, 0.75) 100%),
    linear-gradient(270deg, rgba(244, 222, 193, 0.22) 0%, rgba(244, 222, 193, 0.06) 26%, rgba(244, 222, 193, 0) 46%);
}
.hero-inner {
  position: relative;
  z-index: 2;
  height: 100%;
  padding-top: 33px;
}
.hero-eyebrow {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.24em;
  color: var(--accent-soft);
  line-height: 26px;
}
.hero-title {
  margin-top: 12px;
  max-width: 470px;
  font-family: var(--font-serif);
  font-size: 66px;
  line-height: 73px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--accent);
}
.hero-title span { display: block; }
.hero-slogan {
  margin-top: 20px;
  font-family: var(--font-serif);
  font-size: 25px;
  line-height: 30px;
  font-weight: 600;
  color: var(--accent-deep);
}
.hero-lead {
  margin-top: 27px;
  max-width: 620px;
  font-size: 15px;
  line-height: 28px;
  color: #4f1d04;
}
.hero-foot {
  margin-top: 12px;
}
.hero-stats {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.fact {
  display: inline-block;
  padding: 6px 18px;
  border-radius: var(--r-pill);
  background: rgba(255, 250, 242, 0.72);
  color: #6d2a14;
  font-size: 13px;
  line-height: 20px;
  white-space: nowrap;
}
a.pill {
  background: transparent;
  box-shadow: inset 0 0 0 1px rgba(129, 39, 28, 0.42);
  color: var(--accent);
  transition: background-color 0.18s ease;
}
a.pill:hover { background: rgba(129, 39, 28, 0.08); }
.pill-solid {
  background: var(--accent) !important;
  box-shadow: none !important;
  color: #fdf1de !important;
}
.pill-solid:hover { background: var(--accent-deep) !important; }

/* ---------------- 分区标题 ---------------- */
.sec-head h2 {
  font-family: var(--font-serif);
  font-size: 30px;
  line-height: 36px;
  font-weight: 700;
  color: var(--ink);
}
.sec-sub {
  margin-top: 6px;
  font-size: 14px;
  line-height: 21px;
  color: var(--body-soft);
}

/* ---------------- 分类索引 M2 515–809（294） ---------------- */
.cats {
  height: auto;
  padding-top: 24px;
  padding-bottom: 26px;
}
.cat-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
  padding: 0 10px;
}
.cat-link { display: block; }
.cat-media {
  display: block;
  overflow: hidden;
  border-radius: var(--r-card);
  background: var(--tan);
  aspect-ratio: 178 / 99;
}
.cat-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.cat-link:hover .cat-media img { transform: scale(1.04); }
.cat-name {
  display: block;
  margin-top: 14px;
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 700;
  line-height: 23px;
  color: var(--ink);
}
.cat-name em {
  margin-right: 7px;
  font-family:'PingFang SC','Microsoft YaHei','Noto Sans SC',-apple-system,BlinkMacSystemFont,'Segoe UI',Arial,sans-serif;
  font-style: normal;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--accent-soft);
}
.cat-desc {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 2px;
  font-size: 11px;
  line-height: 15px;
  color: #786d60;
}

/* ---------------- 做法速查 M3 809–1120（311） ---------------- */
.methods {
  height: 311px;
  padding-top: 0;
}
.method-table {
  width: 100%;
  margin-top: 16px;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 13.5px;
}
.method-table col:nth-child(1) { width: 210px; }
.method-table col:nth-child(2) { width: 400px; }
.method-table col:nth-child(3) { width: 300px; }
.method-table col:nth-child(4) { width: auto; }
.method-table th,
.method-table td {
  text-align: center;
  font-weight: 400;
  padding: 0;
  height: 31px;
  border-bottom: 1px solid var(--line-soft);
}
.method-table thead th {
  height: 33px;
  background: var(--accent);
  color: #fdf1de;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.06em;
  border-bottom: 0;
}
.method-table tbody th {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  color: var(--accent);
}
.method-table tbody td { color: var(--body-soft); }
.method-table tbody tr:hover td,
.method-table tbody tr:hover th { background: rgba(242, 217, 185, 0.42); }
.method-table tbody td a {
  color: var(--accent);
  border-bottom: 1px solid rgba(129, 39, 28, 0.28);
}
.method-table tbody td a:hover { border-bottom-color: var(--accent); }

/* ---------------- 本周精选 M4 1120–1462（342） ---------------- */
.featured {
  height: 342px;
  padding-top: 12px;
}
.featured .sec-head,
.steps .sec-head {
  display: flex;
  align-items: baseline;
  gap: 30px;
}
.featured .sec-head h2 { flex: 0 0 auto; }
.featured .sec-sub {
  margin-top: 0;
  margin-left: auto;
  text-align: right;
  font-size: 13px;
  line-height: 20px;
  max-width: 640px;
}
.feat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-top: 20px;
}
.feat-media {
  display: block;
  overflow: hidden;
  border-radius: var(--r-card);
  aspect-ratio: 2 / 1;
  background: var(--tan);
}
.feat-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.feat-card:hover .feat-media img { transform: scale(1.03); }
.feat-name {
  display: block;
  margin-top: 5px;
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 700;
  line-height: 23px;
  color: var(--ink);
}
.feat-desc {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 0;
  font-size: 12.5px;
  line-height: 16px;
  color: var(--body-soft);
}
.feat-meta {
  display: block;
  margin-top: 23px;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: 0.02em;
  color: var(--muted);
}

/* ---------------- 复刻四步 M5 1462–1660（198） ---------------- */
.steps {
  height: 198px;
  padding-top: 11px;
}
.steps .sec-head h2 { flex: 0 0 auto; }
.steps .sec-sub {
  margin-top: 0;
  margin-left: auto;
  max-width: 580px;
  text-align: right;
  font-size: 13px;
  line-height: 20px;
}
.step-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
}
.step-num {
  display: block;
  font-family: var(--font-serif);
  font-size: 34px;
  line-height: 38px;
  font-weight: 700;
  color: var(--accent);
}
.step-card h3 {
  margin-top: 0;
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  line-height: 22px;
  color: var(--ink);
}
.step-card p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 0;
  font-size: 12px;
  line-height: 16px;
  color: var(--muted);
}

/* ---------------- 厨房底线 M6 1660–1870（210） ---------------- */
.notes {
  height: 210px;
  padding-top: 11px;
}
.note-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 44px;
  margin-top: 15px;
}
.note-card {
  padding-top: 13px;
  border-top: 1px solid var(--line);
}
.note-card h3 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  line-height: 22px;
  color: var(--ink);
}
.note-card p {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-top: 4px;
  font-size: 12px;
  line-height: 17px;
  color: #6d6357;
}

/* ---------------- 收录说明 M7 1870–2066（196） ---------------- */
.collect {
  height: 196px;
  padding-top: 20px;
}
.collect h2 {
  font-family: var(--font-serif);
  font-size: 26px;
  line-height: 30px;
  font-weight: 700;
  color: var(--ink);
}
.collect-body {
  margin-top: 1px;
  max-width: 1200px;
  font-size: 13px;
  line-height: 22px;
  color: var(--body-soft);
}
.collect-band {
  margin-top: 29px;
  height: 72px;
  background: var(--tan);
}
.collect-note {
  padding-top: 6px;
  font-size: 15px;
  line-height: 21px;
  color: #5a3a22;
}

/* ---------------- 页脚 M8 2066–2160（94） ---------------- */
.site-footer {
  min-height: 94px;
  padding-bottom: 10px;
  background: var(--accent-deep);
  color: var(--on-dark);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px 40px;
  padding-top: 15px;
}
.footer-col {
  flex: 1 1 180px;
  min-width: 170px;
}
.footer-brand { flex: 1 1 260px; }
.footer-name {
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 700;
  line-height: 23px;
  color: #fdf1de;
}
.footer-en {
  font-size: 9px;
  letter-spacing: 0.3em;
  line-height: 14px;
  color: rgba(247, 231, 210, 0.62);
}
.footer-desc {
  margin-top: 6px;
  font-size: 12px;
  line-height: 17px;
  color: rgba(247, 231, 210, 0.66);
}
.footer-nav h2,
.footer-about h2 {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 15px;
  color: rgba(247, 231, 210, 0.6);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 14px;
  margin-top: 3px;
  font-size: 12px;
  line-height: 16px;
}
.footer-links a { color: rgba(253, 241, 222, 0.88); }
.footer-links a:hover { color: #fff7ea; text-decoration: underline; }
.footer-icp {
  margin-top: 6px;
  font-size: 11px;
  line-height: 15px;
  color: rgba(247, 231, 210, 0.6);
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 8px;
  padding-top: 6px;
  border-top: 1px solid var(--line-dark);
  font-size: 11px;
  line-height: 15px;
  color: rgba(247, 231, 210, 0.58);
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1180px) {
  .brand-cn { font-size: 19px; }
  .main-nav { gap: 12px; font-size: 12.5px; }
  .hero-title { font-size: 56px; line-height: 62px; }
  .cat-grid { gap: 12px; }
  .feat-grid { gap: 12px; }
}

@media (max-width: 1023px) {
  .wrap { padding: 0 28px; }
  .site-header, .header-inner { height: 68px; }
  .header-inner { gap: 16px; }
  .main-nav {
    gap: 14px;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .main-nav::-webkit-scrollbar { display: none; }
  .drop-menu { display: none !important; }
  .nav-caret { display: none; }
  .nav-cta { margin-left: 0; }

  .hero { height: auto; min-height: 430px; }
  .hero-inner { padding: 28px 0 34px; }
  .hero::after {
    background: linear-gradient(180deg, rgba(244, 222, 193, 0.97) 0%, rgba(244, 222, 193, 0.9) 62%, rgba(244, 222, 193, 0.55) 82%, rgba(250, 240, 225, 0.92) 100%);
  }
  .hero-media img { object-position: 58% 50%; }
  .hero-title { font-size: 48px; line-height: 54px; }
  .hero-lead { max-width: 660px; }

  .cats, .methods, .featured, .steps, .notes, .collect { height: auto; padding-bottom: 30px; }
  .cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 0; }
  .feat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; margin-top: 22px; }
  .note-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
  .method-table { font-size: 12.5px; }
  .method-table col:nth-child(1) { width: 110px; }
  .method-table col:nth-child(2) { width: 250px; }
  .method-table col:nth-child(3) { width: 210px; }
  .featured .sec-head, .steps .sec-head { display: block; }
  .featured .sec-sub, .steps .sec-sub { margin-left: 0; max-width: none; text-align: left; }
  .collect-band { height: auto; padding-bottom: 12px; }
  .site-footer { padding-bottom: 14px; }
  .footer-inner { padding-top: 16px; gap: 20px; }
  .footer-links { gap: 4px 12px; }
}

@media (max-width: 767px) {
  .wrap { padding: 0 20px; }
  .hero-title { font-size: 40px; line-height: 46px; }
  .hero-slogan { font-size: 19px; line-height: 26px; }
  .hero-lead { font-size: 14px; line-height: 25px; }
  .hero-stats { gap: 8px; }
  .cat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .cat-desc { font-size: 11.5px; line-height: 15px; }
  .feat-grid { grid-template-columns: 1fr; }
  .step-grid { grid-template-columns: 1fr; }
  .note-grid { grid-template-columns: 1fr; }
  .sec-head h2 { font-size: 27px; line-height: 33px; }
  .sec-sub { font-size: 14px; line-height: 22px; }
  .methods .wrap { overflow-x: auto; }
  .method-table { min-width: 560px; }
  .footer-inner { display: block; }
  .footer-col { min-width: 0; margin-bottom: 14px; }
  .footer-bottom { display: block; }
}

@media (max-width: 480px) {
  .brand-en { display: none; }
  .nav-cta { display: none; }
  .hero-title { font-size: 34px; line-height: 40px; }
  .hero-stats { flex-direction: column; align-items: flex-start; gap: 6px; }
  .fact, a.pill { width: 100%; text-align: center; }
  .cat-grid { grid-template-columns: 1fr; }
}

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