/* =========================================================
   Chenfeng — Resources content center
   /resources/, /resources/{slug}/, /resources/shipment-notes/
   Loaded after site.css + catalog.css. Same tokens.
   ========================================================= */

/* ---------- index header ---------- */
.rhead {
  padding: 34px 0 30px;
  border-bottom: 1px solid var(--line);
}
.rhead .eyebrow { margin-bottom: 14px; }
.rhead h1 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(27px, 4vw, 40px); line-height: 1.1;
  letter-spacing: -0.026em; margin: 0;
  max-width: 22ch; text-wrap: balance;
}
.rhead-sub {
  margin: 16px 0 0; max-width: 64ch;
  font-size: 15.5px; line-height: 1.62; color: var(--muted);
}
.rhead-facts {
  display: flex; flex-wrap: wrap; gap: 0 34px;
  list-style: none; margin: 24px 0 0; padding: 16px 0 0;
  border-top: 1px solid var(--line-2);
  font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-2);
}
.rhead-facts li { display: flex; align-items: baseline; gap: 8px; }
.rhead-facts span {
  font-family: var(--ff-head); font-size: 20px; font-weight: 700;
  letter-spacing: -0.02em; text-transform: none; color: var(--ink);
}
.rhead-sm { padding-bottom: 26px; }

/* ---------- jump bar ---------- */
.rnav { border-bottom: 1px solid var(--line-2); background: var(--soft); }
.rnav-in { display: flex; align-items: center; gap: 18px; overflow-x: auto; scrollbar-width: none; }
.rnav-in::-webkit-scrollbar { display: none; }
.rnav-in > p {
  margin: 0; flex: none; font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2);
}
.rnav-in ul { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.rnav-in a {
  display: block; padding: 11px 0; white-space: nowrap;
  font-size: 13px; font-weight: 500; color: var(--muted);
  border-bottom: 2px solid transparent;
}
.rnav-in a:hover { color: var(--ink); border-bottom-color: var(--accent); }

/* ---------- content lines ---------- */
.rline { padding: 46px 0 8px; scroll-margin-top: 70px; }
.rline + .rline { border-top: 1px solid var(--line-2); }
.rline-h { display: grid; gap: 16px; margin-bottom: 22px; }
.rkick {
  margin: 0 0 8px; font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-dk);
}
.rline-h h2 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(20px, 2.4vw, 25px); line-height: 1.2;
  letter-spacing: -0.018em; margin: 0; max-width: 30ch;
}
.rline-b { margin: 10px 0 0; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: 62ch; }
.rline-n {
  margin: 0; align-self: start; display: flex; align-items: center; gap: 14px;
  font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted-2);
}
.rmore { font-weight: 600; color: var(--accent-dk); text-transform: none; letter-spacing: 0; border-bottom: 1px solid #E4CBB4; }

.rgrid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 14px; }
.rcard {
  display: flex; flex-direction: column; gap: 8px;
  padding: 20px 20px 18px;
  border: 1px solid var(--line); background: #fff;
  transition: border-color .16s ease, transform .16s ease, box-shadow .16s ease;
}
.rcard:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(27, 42, 58, 0.07);
}
.rcard-lb {
  margin: 0; font-size: 10px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2);
}
.rcard-guide .rcard-lb { color: var(--accent-dk); }
.rcard h3 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: 16.5px; line-height: 1.3; letter-spacing: -0.012em;
  margin: 0; color: var(--ink);
}
.rcard-ex {
  margin: 0; font-size: 13.5px; line-height: 1.58; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.rcard-m {
  margin: auto 0 0; padding-top: 12px;
  display: flex; align-items: center; gap: 8px;
  font-size: 11.5px; color: var(--muted-2); border-top: 1px solid var(--line-2);
}
.adot { width: 3px; height: 3px; border-radius: 50%; background: var(--line-2); display: inline-block; }

/* ---------- how it is written ---------- */
.rhow { padding: 48px 0; background: var(--soft); border-top: 1px solid var(--line); margin-top: 40px; }
.rhow-in { display: grid; gap: 26px; }
.rhow h2 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(20px, 2.4vw, 26px); line-height: 1.22;
  letter-spacing: -0.02em; margin: 0 0 12px; max-width: 28ch;
}
.rhow p { margin: 0 0 12px; font-size: 14.5px; line-height: 1.66; color: var(--muted); max-width: 62ch; }
.rhow-l { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); }
.rhow-l li { background: #fff; padding: 14px 16px; font-size: 13.5px; line-height: 1.55; color: var(--muted); }
.rhow-l strong { display: block; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink); margin-bottom: 4px; }

/* =========================================================
   ARTICLE
   ========================================================= */
.ahead { padding: 26px 0 26px; border-bottom: 1px solid var(--line); }
.ahead h1 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(26px, 3.6vw, 38px); line-height: 1.12;
  letter-spacing: -0.025em; margin: 14px 0 0;
  max-width: 26ch; text-wrap: balance;
}
.aline {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  margin: 0; font-size: 11.5px; letter-spacing: 0.02em; color: var(--muted-2);
}
.aline a { color: var(--accent-dk); font-weight: 600; border-bottom: 1px solid #E4CBB4; }
.asample {
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 3px 7px; color: #8A5A18; background: #FDF1E4; border: 1px solid #F0D9C0;
}
.asub { margin: 14px 0 0; max-width: 64ch; font-size: 16px; line-height: 1.58; color: var(--muted); }

.alay { display: grid; grid-template-columns: minmax(0, 1fr); gap: 34px; padding: 30px var(--pad) 10px; }
.abody { min-width: 0; }

/* definition — the sentence an AI answer or a colleague can quote */
.adef {
  padding: 16px 18px 16px 20px;
  background: var(--soft);
  border-left: 3px solid var(--accent);
}
.adef-lb {
  display: block; margin-bottom: 7px;
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--accent-dk);
}
.adef p {
  margin: 0; font-size: 15px; line-height: 1.6; color: var(--ink);
  max-width: 66ch; font-weight: 450;
}

/* the one-sentence answer */
.averdict {
  margin: 18px 0 30px; padding: 20px 20px 6px;
  border: 1px solid var(--line); border-top: 3px solid var(--ink);
  background: #fff;
}
.averdict-lb {
  margin: 0 0 8px; font-size: 9.5px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent-dk);
}
.averdict-p {
  margin: 0 0 18px; font-family: var(--ff-head); font-weight: 700;
  font-size: 18px; line-height: 1.42; letter-spacing: -0.012em; color: var(--ink);
  max-width: 62ch;
}
.averdict-facts {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px; list-style: none; margin: 0; padding: 14px 0 14px;
  border-top: 1px solid var(--line-2);
}
.averdict-facts li { font-size: 10.5px; line-height: 1.35; color: var(--muted); }
.averdict-facts span {
  display: block; font-family: var(--ff-head); font-weight: 700;
  font-size: 18px; letter-spacing: -0.02em; color: var(--ink); margin-bottom: 3px;
}

/* sections */
.asec { padding: 26px 0 4px; border-top: 1px solid var(--line-2); scroll-margin-top: 76px; }
.asec:first-of-type { border-top: 0; }
.asec-h { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; }
.anum {
  flex: none; margin-top: 4px;
  font-family: var(--ff-mono); font-size: 10.5px; font-weight: 500;
  letter-spacing: 0.06em; color: var(--accent);
}
.asec h2 {
  font-family: var(--ff-head); font-weight: 700;
  font-size: clamp(19px, 2.2vw, 23px); line-height: 1.22;
  letter-spacing: -0.018em; margin: 0; max-width: 34ch;
}
.skick {
  margin: 0 0 5px; font-size: 10px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2);
}
.abody h3 {
  font-family: var(--ff-body); font-weight: 600;
  font-size: 14.5px; line-height: 1.45; letter-spacing: -0.005em;
  margin: 18px 0 6px; color: var(--ink);
}
.abody p { margin: 0 0 13px; font-size: 15.5px; line-height: 1.7; color: #2B3B4B; max-width: 70ch; }
.abody a { color: var(--accent-dk); border-bottom: 1px solid #E4CBB4; }
.abody a:hover { border-color: var(--accent); }
.abody strong { color: var(--ink); }

/* ---------- real tables, copyable ---------- */
.rtab {
  margin: 16px 0 18px;
  border: 1px solid var(--line);
  background: #fff;
}
.rtab-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 9px 12px;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}
.rtab-bar figcaption {
  font-size: 11px; font-weight: 600; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--ink);
}
.rtab-copy {
  flex: none; cursor: pointer;
  font-family: inherit; font-size: 10.5px; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--muted); background: #fff;
  border: 1px solid var(--line); padding: 5px 9px;
  transition: color .15s ease, border-color .15s ease;
}
.rtab-copy:hover { color: var(--accent-dk); border-color: var(--accent); }
.rtab-copy[data-done] { color: var(--ok); border-color: var(--ok); }
.rtab-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.rtab table { width: 100%; border-collapse: collapse; font-size: 13px; }
.rtab th {
  text-align: left; vertical-align: bottom;
  padding: 9px 12px;
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted-2); background: #fff;
  border-bottom: 1px solid var(--line);
  line-height: 1.3;
}
.rtab td {
  padding: 10px 12px; vertical-align: top;
  border-bottom: 1px solid var(--line-2);
  line-height: 1.5; color: #33455A;
}
.rtab tr:last-child td { border-bottom: 0; }
.rtab td:first-child { color: var(--ink); font-weight: 500; }
.rtab td a { color: var(--accent-dk); border-bottom: 1px solid #E4CBB4; }
.rtab tbody tr:hover td { background: #FBFCFD; }
.rtab-note {
  margin: 0; padding: 10px 12px 12px;
  font-size: 11.5px; line-height: 1.55; color: var(--muted-2);
  border-top: 1px solid var(--line-2);
}

/* ---------- pitfalls ---------- */
.apit { list-style: none; margin: 6px 0 0; padding: 0; counter-reset: pit; }
.apit li { counter-increment: pit; position: relative; padding: 14px 0 14px 34px; border-top: 1px solid var(--line-2); }
.apit li:first-child { border-top: 0; }
.apit li::before {
  content: counter(pit, decimal-leading-zero);
  position: absolute; left: 0; top: 16px;
  font-family: var(--ff-mono); font-size: 10.5px; color: var(--accent);
}
.apit h3 { margin: 0 0 5px; font-size: 14.5px; font-weight: 600; }
.apit p { margin: 0; font-size: 14px; line-height: 1.62; color: var(--muted); max-width: 68ch; }

/* ---------- faq ---------- */
.arfaq { margin-top: 4px; border-top: 1px solid var(--line-2); }
.arfaq details { border-bottom: 1px solid var(--line-2); }
.arfaq summary {
  position: relative; cursor: pointer; list-style: none;
  padding: 13px 30px 13px 0;
  font-size: 14.5px; font-weight: 600; line-height: 1.45; color: var(--ink);
}
.arfaq summary::-webkit-details-marker { display: none; }
.arfaq summary::after {
  content: "+"; position: absolute; right: 2px; top: 11px;
  font-family: var(--ff-mono); font-size: 15px; color: var(--muted-2);
}
.arfaq details[open] summary::after { content: "–"; color: var(--accent); }
.arfaq details > div { padding: 0 30px 15px 0; font-size: 14px; line-height: 1.66; color: var(--muted); max-width: 70ch; }
.arfaq details > div a { color: var(--accent-dk); border-bottom: 1px solid #E4CBB4; }

/* ---------- category strip + model cards ---------- */
.acats { margin: 4px 0 18px; padding: 14px 16px; background: var(--soft); border-left: 2px solid var(--line); }
.acats-h { margin: 0 0 10px; font-size: 10px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.acats-g { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; }
.acats-g a { display: block; padding: 3px 0; border-bottom: 1px solid transparent; }
.acats-g strong { display: block; font-size: 13.5px; font-weight: 600; color: var(--ink); }
.acats-g span { display: block; font-size: 11.5px; color: var(--muted-2); }
.acats-g a:hover strong { color: var(--accent-dk); }

.amc-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
.amc { display: flex; flex-direction: column; padding: 13px 14px; border: 1px solid var(--line); background: #fff; }
.amc-m {
  display: block;
  font-family: var(--ff-mono); font-size: 12.5px; font-weight: 500;
  color: var(--ink); line-height: 1.35; overflow-wrap: anywhere;
}
.amc-m:hover { color: var(--accent-dk); }
.amc-tag {
  display: block; margin-top: 3px;
  font-size: 9px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted-2);
}
.rtab td code, .abody code {
  font-family: var(--ff-mono); font-size: 11.5px; color: var(--ink-2);
  background: none; padding: 0; letter-spacing: -0.01em;
}
.amc-brand { display: block; margin-top: 2px; font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent-dk); }
.amc p { margin: 7px 0 9px; font-size: 12.5px; line-height: 1.5; color: var(--muted); }
.amc-go { margin-top: auto; font-size: 11.5px; font-weight: 600; color: var(--ink); border-bottom: 1px solid var(--line); align-self: flex-start; }
.amc-go:hover { color: var(--accent-dk); border-color: var(--accent); }

/* ---------- shipment lesson ---------- */
.alesson { margin: 22px 0 6px; padding: 16px 18px; background: #FFF8F2; border: 1px solid #F0DCC8; }
.alesson-lb {
  display: block; margin-bottom: 6px;
  font-size: 9.5px; font-weight: 600; letter-spacing: 0.13em; text-transform: uppercase; color: #A85A18;
}
.alesson p { margin: 0; font-size: 14px; line-height: 1.62; color: #4A3A2C; max-width: 68ch; }

/* ---------- aside ---------- */
.aside { display: flex; flex-direction: column; gap: 18px; }
.atoc { border-top: 2px solid var(--ink); padding-top: 12px; }
.atoc-h { margin: 0 0 10px; font-size: 10px; font-weight: 600; letter-spacing: 0.13em; text-transform: uppercase; color: var(--muted-2); }
.atoc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; }
.atoc li { counter-increment: toc; border-bottom: 1px solid var(--line-2); }
.atoc a {
  display: flex; gap: 10px; padding: 8px 0;
  font-size: 12.5px; line-height: 1.4; color: var(--muted);
  transition: color .14s ease;
}
.atoc a::before {
  content: counter(toc, decimal-leading-zero);
  font-family: var(--ff-mono); font-size: 9.5px; color: var(--muted-2); padding-top: 2px;
}
.atoc a:hover, .atoc a[aria-current] { color: var(--ink); }
.atoc a[aria-current]::before { color: var(--accent); }

.aqt { padding: 16px 16px 14px; border: 1px solid var(--line); background: var(--soft); }
.aqt-h { margin: 0 0 8px; font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent-dk); }
.aqt p { margin: 0 0 12px; font-size: 12.5px; line-height: 1.55; color: var(--muted); }
.aqt .btn { min-height: 38px; font-size: 12.5px; }
.aqt-alt { margin: 10px 0 0 !important; font-size: 11.5px !important; }
.aqt-alt a { color: var(--accent-dk); border-bottom: 1px solid #E4CBB4; }

/* ---------- read next ---------- */
.areadnext { padding: 34px 0 8px; border-top: 1px solid var(--line); margin-top: 22px; }
.areadnext h2 {
  font-family: var(--ff-head); font-weight: 700; font-size: 15px;
  letter-spacing: 0.02em; margin: 0 0 14px; color: var(--ink);
}
.arn-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; }
.arn {
  display: flex; flex-direction: column; gap: 5px;
  padding: 15px 16px; border: 1px solid var(--line);
  transition: border-color .15s ease, transform .15s ease;
}
.arn:hover { border-color: var(--accent); transform: translateY(-1px); }
.arn-lb { font-size: 9.5px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.arn strong { font-family: var(--ff-head); font-size: 14.5px; line-height: 1.35; letter-spacing: -0.01em; color: var(--ink); }
.arn-m { font-size: 11px; color: var(--muted-2); }

/* ---------- closing CTA ---------- */
.acta { margin-top: 30px; background: var(--ink); color: #fff; }
.acta-in { display: grid; gap: 22px; padding: 34px 0; }
.acta-lb { margin: 0 0 8px; font-size: 10px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: #E87722; }
.acta h2 {
  font-family: var(--ff-head); font-weight: 700; color: #fff;
  font-size: clamp(19px, 2.4vw, 25px); line-height: 1.22;
  letter-spacing: -0.018em; margin: 0 0 10px; max-width: 32ch;
}
.acta p { margin: 0; font-size: 13.5px; line-height: 1.6; color: #B9C6D3; max-width: 58ch; }
.acta-act { display: flex; flex-wrap: wrap; gap: 10px; align-content: start; }
.acta .btn-ghost { color: #fff; border-color: rgba(255,255,255,0.32); }
.acta .btn-ghost:hover { background: #fff; color: var(--ink); border-color: #fff; }

/* =========================================================
   breakpoints
   ========================================================= */
@media (min-width: 640px) {
  .rgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .amc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arn-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .acta-act { flex-wrap: nowrap; }
  .alay { padding-top: 34px; }
}

@media (min-width: 900px) {
  .rline { padding-top: 52px; }
  .rline-h { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
  .rline-n { justify-self: end; }
  .rhow-in { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 40px; }
  .acta-in { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 38px 0; }
  .alay { grid-template-columns: minmax(0, 1fr) 268px; gap: 44px; }
  .atoc { position: sticky; top: 76px; }
  .amc-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 1100px) {
  .rgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .rgrid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .alay { grid-template-columns: minmax(0, 1fr) 296px; gap: 56px; }
  .abody { max-width: 74ch; }
}

@media (max-width: 639px) {
  .rhead { padding: 24px 0 22px; }
  .rhead-facts { gap: 10px 18px; }
  .rhead-facts span { font-size: 17px; }
  .averdict-facts { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .averdict-facts li { display: flex; align-items: baseline; gap: 8px; }
  .averdict-facts span { margin: 0; }
  .rtab table { font-size: 12px; }
  .rtab th, .rtab td { padding: 8px 10px; }
  .abody p { font-size: 15px; }
}

/* ---------- print ---------- */
@media print {
  .ahead { border-bottom: 1px solid #ccc; }
  .aside, .acta, .areadnext, .rnav, .mbar, .wa-fab { display: none !important; }
  .alay { display: block; }
  .asec { break-inside: auto; }
  .rtab { break-inside: avoid; }
  .artab-scroll { overflow: visible; }
  .averdict { border: 1px solid #999; }
}
