/* =============================================================================
   95 · SIMPLIFIED CHINESE (zh_CN)
   =============================================================================

   Everything the Chinese storefront needs that a translation plugin cannot
   reach. Two kinds of thing live here, and only these two:

   1 · TYPOGRAPHY. Inter and Fraunces carry no CJK glyphs, so Han would drop to
       whatever serif the visitor's OS happens to install. The theme routes all
       297 font declarations through --font-primary / --font-heading
       (main.css:88-89) and hardcodes none, so redefining the two tokens under
       one locale selector reaches the entire store. Font fallback resolves per
       glyph, so Latin still renders in Inter/Fraunces inside a Chinese page.

   2 · THE 39 SENTENCES BAKED INTO `content:`. TranslatePress rewrites the HTML
       response; text a browser generates from a stylesheet was never in that
       response, so no translation plugin — TranslatePress, WPML or Polylang —
       can see it. The English lives in 11 part files (20-page-header, 25, 54,
       56, 60, 62, 64, 66, 70, 72, 93); each is restated here in Chinese under
       the same selector plus a locale prefix, which also raises specificity, so
       this does not depend on load order.

   THE COST OF THIS FILE: it forks the copy. An English edit in one of those 11
   files has to be mirrored here or the two languages drift apart. That was
   accepted over restructuring 11 stylesheets and their PHP partners into
   data-* attributes.

   The document is stamped `<html lang="zh-Hans">`, not `zh-CN` — hence the `^=`
   prefix match. An exact `[lang="zh-CN"]` selector silently matches nothing.

   Two treatments are unwound wherever they appear below:
   · `text-transform: uppercase` does nothing to Han but does mangle any Latin
     riding along inside a Chinese string (an email address, a size in mm).
   · Tracking. The label style runs `letter-spacing: 0.17em` and the display
     style runs -0.045em. Both are drawn for Latin; on Han the first reads as
     broken spacing and the second collides the glyphs. Labels are re-set to a
     restrained 0.06em, display type to 0.
   ========================================================================== */

/* -----------------------------------------------------------------------------
   1 · TYPE TOKENS
   -------------------------------------------------------------------------- */

html[lang^="zh"] {
  --font-primary: 'Inter', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'PingFang SC',
                  'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-heading: 'Fraunces', 'Noto Serif SC', 'Songti SC', Georgia, serif;
}

/* Han has no italic. Where the theme leans on one italic accent word, the
   emphasis has to be carried by colour instead — the accent colour is already
   on those rules, so only the slant is removed. */
html[lang^="zh"] em,
html[lang^="zh"] i:not([class*="icon"]) {
  font-style: normal;
  color: var(--color-accent);
}

/* -----------------------------------------------------------------------------
   2 · 20-page-header.css
   -------------------------------------------------------------------------- */

html[lang^="zh"] .blog .page-banner .breadcrumb::after {
  content: "日志";
}

/* -----------------------------------------------------------------------------
   3 · 25-controls.css — the account gate
   -------------------------------------------------------------------------- */

html[lang^="zh"] .woocommerce-account .page-content-section > .container::before {
  content: "会员";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .woocommerce-account .page-content-section > .container::after {
  content: "登录后可查看您的订单、寄送去向，以及下一泡正等着您的茶。";
  letter-spacing: 0;
}

html[lang^="zh"] .woocommerce-account.logged-in .page-content-section > .container::before {
  content: "您的档案";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .woocommerce-account.logged-in .page-content-section > .container::after {
  content: "本店为您留存的全部记录，以及寄出的每一把壶。";
  letter-spacing: 0;
}

/* -----------------------------------------------------------------------------
   4 · 54-shop-sidebar.css
   NOTE: the English hardcodes a catalogue count in CSS. It is reproduced here
   rather than corrected, so the two languages stay in step — that fix belongs
   in PHP, applied to both languages at once.
   -------------------------------------------------------------------------- */

html[lang^="zh"] .search-results-page .shop-sidebar::after {
  content: "581 件 \00B7  14 个分类";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   5 · 56-states.css — the empty cart
   The heading's own string is held at font-size:0 as the accessible name, and
   the line that is SEEN is drawn from its two pseudo-elements. So the sentence
   has to be split across ::before and ::after here too, with the second half
   carrying the emphasis.
   -------------------------------------------------------------------------- */

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block::before {
  content: "您的茶篮 \00B7  目前空无一物";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block > .wc-block-cart__empty-cart__title::before {
  content: "篮中尚且";
  letter-spacing: 0;
}

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block > .wc-block-cart__empty-cart__title::after {
  content: "空空如也。";
  font-style: normal;
  letter-spacing: 0;
}

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block > .wp-block-separator.is-style-dots::before {
  content: "数量、配送与付款都留待稍后 — 结账之前不会为您保留任何物件。以下是最近上架的新品。";
  letter-spacing: 0;
}

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block > .wp-block-heading:not(.wc-block-cart__empty-cart__title)::before {
  content: "与此同时 \00B7  货架上的新到";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .wp-block-woocommerce-empty-cart-block > .wp-block-heading:not(.wc-block-cart__empty-cart__title)::after {
  content: "由新至旧";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   6 · 60-gallery.css / 62-buybox.css — product page furniture
   -------------------------------------------------------------------------- */

html[lang^="zh"] .single-product-page .product-main-image::before {
  content: "悬停放大";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-info::after {
  content: "此件";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .variations_form:has(select option[value=""]:checked) .single_variation_wrap::before {
  content: "请先选择规格";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   7 · 64-specs.css — the spec table
   The FIELDS counter must survive: `counter(spec, …)` resolves the real field
   count for each product, and dropping it would freeze the number.
   -------------------------------------------------------------------------- */

html[lang^="zh"] .single-product-page .product-info .product-short-desc::before {
  content: "来处";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-info .product-short-desc .product-specs::after {
  content: "字段 \00B7  " counter(spec, decimal-leading-zero);
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .product-spec:nth-child(4)::before {
  content: "细节";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .product-specs + .product-spec-prose::before {
  content: "制器者手记";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   8 · 66-tabs.css — the product record
   -------------------------------------------------------------------------- */

html[lang^="zh"] .single-product-page .product-tabs .tabs-nav::after {
  content: "物件档案";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-tabs .tab-content[data-tab-content="description"]::before {
  content: "由作坊提供";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-tabs .tab-content[data-tab-content="additional"]::before {
  content: "实测数据";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-tabs .tab-content[data-tab-content="reviews"]::before {
  content: "用者手记";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .product-tabs .woocommerce-Reviews .woocommerce-noreviews::after {
  content: "关于这件器物，还没有人留下只言片语。若您与它朝夕相处过 — 手感如何、用久了怎样、是否值得 — 您的话将是档案上的第一笔。";
  letter-spacing: 0;
}

/* -----------------------------------------------------------------------------
   9 · 70-cart.css
   -------------------------------------------------------------------------- */

html[lang^="zh"] body.woocommerce-cart .wc-block-cart .wc-block-cart__main::before {
  content: "篮中之物";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-cart .wc-block-cart .wc-block-cart-items .wc-block-cart-item__prices::after {
  content: "每件";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-cart .wc-block-cart .wc-block-cart__main::after {
  content: "此处不作保留。库存、运费与关税将在下一步确认；未经您确认，不会扣款。";
  letter-spacing: 0;
}

html[lang^="zh"] body.woocommerce-cart .wc-block-cart .wc-block-cart__submit::after {
  content: "下一步 \00B7  先填配送信息，再付款";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   10 · 72-checkout.css
   The \A escapes are real line breaks held by white-space on the source rule —
   they have to survive translation or the three lines run together.
   -------------------------------------------------------------------------- */

html[lang^="zh"] body.woocommerce-checkout form.checkout::after {
  content: "发货地 \00B7  香港九龙\A 咨询 \00B7  support@teaory.net\A 发货后以电邮确认";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-checkout #customer_details .woocommerce-billing-fields > h3::before {
  content: "01 \00B7  账单信息";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-checkout #customer_details h3#ship-to-different-address::before {
  content: "02 \00B7  收货信息";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-checkout #customer_details .woocommerce-additional-fields::before {
  content: "03 \00B7  备注";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-checkout #customer_details .woocommerce-additional-fields__field-wrapper::before {
  content: "有什么需要我们知道的吗？";
  letter-spacing: 0;
}

html[lang^="zh"] body.woocommerce-checkout #payment::before {
  content: "付款";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] body.woocommerce-checkout #payment ul.payment_methods .woocommerce-info::after {
  content: "暂无可用付款方式";
  letter-spacing: 0;
}

html[lang^="zh"] body.woocommerce-checkout #payment .place-order::after {
  content: "未经确认，不会扣款";
  letter-spacing: 0.06em;
  text-transform: none;
}

/* -----------------------------------------------------------------------------
   11 · 93-coherence.css
   -------------------------------------------------------------------------- */

html[lang^="zh"] .single-product-page .sp-related .section-header::before {
  content: "同架之物";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .single-product-page .sp-related .section-header::after {
  content: "四件";
  letter-spacing: 0.06em;
  text-transform: none;
}

html[lang^="zh"] .shop-page .shop-empty > div:first-child::after {
  content: "此架暂空";
  letter-spacing: 0.06em;
  text-transform: none;
}
