:root {
  --blue: #3788f9;
  --blue-dark: #1976eb;
  --red: #ef3030;
  --ink: #20242b;
  --muted: #8a99a7;
  --line: #e9edf2;
  --background: #f7f8fa;
  --surface: #fff;
  --shadow: 0 4px 16px rgba(29, 50, 78, .09);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--background); font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans SC", "Microsoft YaHei", sans-serif; line-height: 1.65; }
a { color: inherit; }
button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

.site-header { height: 92px; background: #fff; box-shadow: 0 1px 0 rgba(31, 41, 55, .04); position: sticky; top: 0; z-index: 20; }
.header-inner { width: min(1200px, calc(100% - 36px)); height: 100%; margin: 0 auto; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 30px; }
.brand { display: inline-flex; align-items: center; gap: 14px; width: max-content; color: #101114; font-size: 23px; font-weight: 800; text-decoration: none; white-space: nowrap; letter-spacing: -.02em; }
.brand img { width: 46px; height: 46px; }
.brand-divider { margin: 0 2px; font-weight: 500; }
.main-nav { display: flex; align-items: center; justify-content: center; gap: 52px; }
.main-nav a { color: #25282d; font-size: 15px; font-weight: 650; text-decoration: none; }
.main-nav a:hover { color: var(--blue); }
.outline-button { justify-self: end; min-width: 118px; height: 42px; padding: 0 18px; border: 1px solid var(--blue); border-radius: 3px; background: #fff; color: var(--blue); cursor: pointer; font-weight: 600; }
.outline-button:hover { color: #fff; background: var(--blue); }

.store-main, .detail-main { width: min(1200px, calc(100% - 36px)); min-height: calc(100vh - 168px); margin: 0 auto; padding: 24px 0 70px; }
.store-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 18px; }
.store-heading-row { display: flex; align-items: center; justify-content: space-between; gap: 30px; min-height: 58px; }
.store-heading-row h1 { margin: 0; color: #91a0ac; font-size: 19px; font-weight: 750; }
.store-heading-row h1 span { margin: 0 2px; font-weight: 500; }
.search-wrap { position: relative; width: 280px; }
.search-wrap > span { position: absolute; left: 15px; top: 14px; width: 15px; height: 15px; border: 2px solid #95a5b3; border-radius: 50%; pointer-events: none; }
.search-wrap > span::after { content: ""; position: absolute; right: -6px; bottom: -4px; width: 7px; height: 2px; background: #95a5b3; transform: rotate(45deg); border-radius: 2px; }
.store-search { width: 100%; height: 44px; padding: 0 16px 0 44px; color: #374151; background: #f1f4fa; border: 1px solid transparent; border-radius: 5px; outline: 0; }
.store-search::placeholder { color: #a3afba; }
.store-search:focus { background: #fff; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(55, 136, 249, .1); }

.notice-box { display: flex; align-items: center; margin: 0; }
.notice-label { display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto; height: 42px; padding: 0 14px; border: 1px solid var(--blue); border-radius: 3px; color: var(--blue); background: #fff; font-size: 15px; }
.notice-label { cursor: pointer; }
.category-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; overflow-x: auto; scrollbar-width: none; }
.category-tabs::-webkit-scrollbar { display: none; }
.category-tab { position: relative; height: 42px; padding: 0 20px; color: var(--blue); background: #fff; border: 1px solid var(--blue); border-radius: 7px; font-size: 15px; white-space: nowrap; cursor: pointer; }
.category-tab span { display: none; }
.category-tab.active { color: #fff; background: linear-gradient(135deg, #3295ff, #347af3); box-shadow: 0 4px 10px rgba(55, 136, 249, .18); }
.category-tab.active span { display: grid; place-items: center; position: absolute; right: -1px; bottom: -1px; width: 28px; height: 24px; color: #dceaff; background: rgba(255, 255, 255, .17); border-radius: 18px 0 6px 0; }

.product-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.product-card { min-width: 0; overflow: hidden; background: #fff; border: 1px solid #eef0f3; border-radius: 6px; box-shadow: 0 3px 10px rgba(26, 39, 56, .09); transition: transform .2s, box-shadow .2s; }
.product-card:hover { transform: translateY(-4px); box-shadow: 0 10px 28px rgba(26, 39, 56, .14); }
.product-card-link { display: flex; flex-direction: column; min-height: 365px; padding: 26px 20px 18px; color: inherit; text-decoration: none; }
.product-visual { display: grid; place-items: center; height: 140px; margin-bottom: 8px; }
.product-visual img { display: block; width: 112px; height: 112px; object-fit: contain; }
.product-visual.small { height: 100px; }
.product-visual.small img { width: 88px; height: 88px; }
.delivery-mark { display: block; min-height: 24px; margin: 0; color: #fb4139; font-size: 13px; font-weight: 650; text-align: center; white-space: nowrap; }
.product-card h3 { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; min-height: 50px; margin: 0; color: #1e2329; font-size: 16px; font-weight: 520; line-height: 1.55; }
.product-card-bottom { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 13px; }
.product-card-bottom strong { color: var(--red); font-size: 24px; line-height: 1; }
.inventory { color: #38a169; font-size: 12px; }
.empty-state { padding: 40px; color: var(--muted); background: #fff; text-align: center; border: 1px solid var(--line); }

.seo-guide { display: grid; grid-template-columns: 1.25fr 1fr; gap: 50px; align-items: center; margin-top: 44px; padding: 30px 34px; background: #fff; border: 1px solid var(--line); border-radius: 8px; }
.section-kicker { color: var(--blue); font-size: 13px; font-weight: 750; }
.seo-guide h2 { margin: 4px 0 7px; font-size: 22px; }
.seo-guide p { margin: 0; color: #748391; font-size: 14px; }
.guide-links { display: grid; }
.guide-links a { padding: 9px 0; color: var(--blue); text-decoration: none; border-bottom: 1px solid var(--line); }

.breadcrumb { display: flex; gap: 8px; overflow: hidden; margin: 2px 0 14px; color: #99a5af; font-size: 13px; white-space: nowrap; }
.breadcrumb a { color: var(--blue); text-decoration: none; }
.breadcrumb span:last-child { overflow: hidden; text-overflow: ellipsis; }
.detail-page-title { margin: 0 0 26px; color: #91a0ac; font-size: 20px; font-weight: 750; }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1.72fr) minmax(330px, .86fr); gap: 18px; align-items: start; }
.product-description-card, .purchase-panel { background: #fff; border: 1px solid #f0f1f3; border-radius: 5px; box-shadow: 0 6px 22px rgba(42, 58, 79, .06); }
.product-description-card { min-height: 680px; padding: 28px 30px 40px; }
.product-description-card h2 { margin: 0 0 8px; color: #8b9aa6; font-size: 17px; }
.description-highlight { margin-bottom: 17px; color: #f22727; font-size: 18px; font-weight: 750; }
.rich-description { color: #606a73; font-size: 15px; line-height: 1.9; overflow-wrap: anywhere; }
.rich-description p { margin: 0 0 15px; }
.rich-description h1,.rich-description h2,.rich-description h3 { color: #34424e; line-height: 1.45; }
.rich-description img,.rich-description video,.rich-description iframe { max-width: 100%; height: auto; }
.rich-description table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
.rich-description th,.rich-description td { padding: 7px 9px; border: 1px solid #dce2e8; }
.rich-description a { color: var(--blue); }
.detail-notes { margin-top: 26px; padding-top: 23px; border-top: 1px solid #f0f1f3; }
.detail-notes h3, .inline-tutorials h3 { color: #687783; font-size: 17px; }
.detail-notes ol { margin: 0; padding-left: 24px; color: #606a73; }
.detail-notes li { margin: 0 0 15px; padding-left: 3px; }
.warning-text { color: #f22727; font-weight: 700; }
.inline-tutorials { margin-top: 28px; padding: 20px 24px; background: #fbfcff; border-left: 3px solid var(--blue); }
.inline-tutorials h3 { margin: 0 0 8px; }
.inline-tutorials a { display: inline-block; margin: 4px 20px 4px 0; color: var(--blue); text-decoration: none; }

.purchase-panel { position: sticky; top: 112px; padding: 30px 28px; }
.purchase-product-head { display: grid; grid-template-columns: 62px 1fr; gap: 15px; align-items: center; }
.purchase-product-head img { width: 62px; height: 62px; object-fit: contain; }
.purchase-product-head h2 { margin: 0; font-size: 22px; font-weight: 520; line-height: 1.35; }
.status-badges { display: flex; gap: 6px; margin: 17px 0 6px 77px; }
.status-badges span { padding: 1px 6px; color: var(--blue); border: 1px solid var(--blue); border-radius: 4px; font-size: 11px; }
.detail-price { margin: 8px 0 15px; color: #f45151; font-size: 30px; font-weight: 450; }
.field-label { display: block; margin-bottom: 6px; color: #7b8995; font-size: 15px; }
.required-mark { color: #ef4444; }
.contact-input { width: 100%; height: 44px; margin-bottom: 17px; padding: 0 12px; color: #5f6d78; border: 1px solid #dce2e8; border-radius: 3px; outline: 0; }
.contact-input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(55,136,249,.1); }
.contact-input::placeholder { color: #adb8c2; }
.quantity-picker { display: grid; grid-template-columns: 44px 1fr 44px; height: 44px; margin-bottom: 18px; }
.quantity-picker input { width: 100%; min-width: 0; color: #6c7780; text-align: center; border: solid #dce2e8; border-width: 1px 0; border-radius: 0; outline: 0; -moz-appearance: textfield; }
.quantity-picker input::-webkit-inner-spin-button { -webkit-appearance: none; }
.quantity-button { color: #fff; background: var(--blue); border: 0; cursor: pointer; font-size: 20px; }
.quantity-button:first-child { border-radius: 3px 0 0 3px; }
.quantity-button:last-child { border-radius: 0 3px 3px 0; }
.payment-methods { margin: 0 0 18px; padding: 0; border: 0; }
.payment-methods legend { margin-bottom: 7px; color: #7b8995; font-size: 15px; }
.payment-methods { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.payment-methods legend { grid-column: 1 / -1; }
.payment-methods label { position: relative; display: flex; align-items: center; justify-content: center; gap: 9px; min-height: 54px; padding: 7px; border: 2px solid #c7d2df; cursor: pointer; }
.payment-methods label:has(input:checked) { border-color: var(--blue); }
.payment-methods input { position: absolute; opacity: 0; pointer-events: none; }
.payment-method-icon { display: grid; place-items: center; width: 35px; height: 35px; color: #fff; background: #10a9e8; border-radius: 9px; font-size: 21px; font-weight: 800; }
.payment-methods .wxpay .payment-method-icon { background: #06b91e; border-radius: 50%; }
.payment-methods label strong { font-size: 15px; font-weight: 550; }
.payment-unavailable { margin-bottom: 18px; padding: 12px; color: #b45309; background: #fffbeb; border: 1px solid #fde68a; border-radius: 4px; font-size: 12px; }
.fulfilment-box { display: flex; align-items: center; gap: 10px; margin: 8px 0 20px; padding: 12px 13px; color: #4c5963; background: #f7faff; border: 1px solid #e4efff; border-radius: 4px; }
.fulfilment-box > span { color: var(--blue); font-size: 20px; }
.fulfilment-box div { display: grid; }
.fulfilment-box strong { font-size: 13px; }
.fulfilment-box small { color: #8c99a4; font-size: 11px; }
.submit-order-button, .primary-button { display: block; min-height: 45px; padding: 0 24px; color: #fff; background: #ff6262; border: 0; border-radius: 4px; font-weight: 650; cursor: pointer; }
.submit-order-button { min-width: 132px; margin: 0 auto; }
.primary-button { width: 100%; background: var(--blue); }
.submit-order-button:hover { background: #f44c4c; }
.submit-order-button:disabled { opacity: .48; cursor: not-allowed; }
.purchase-tip { margin: 16px 0 0; color: #99a5ae; font-size: 11px; text-align: center; }
.order-result { padding: 13px; margin-top: 16px; overflow-wrap: anywhere; color: #24663a; background: #effcf3; border: 1px solid #bce8c9; border-radius: 4px; font-size: 12px; }
.related-products { margin-top: 42px; }
.related-products > h2 { color: #6f7e89; font-size: 20px; }
.product-grid.compact .product-card-link { min-height: 280px; }

.site-footer { color: #9aa8b3; background: #fff; border-top: 1px solid var(--line); font-size: 13px; }
.footer-inner { width: min(1200px, calc(100% - 36px)); min-height: 76px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.footer-inner a { color: #8293a0; text-decoration: none; }

.dialog { width: min(440px, calc(100% - 28px)); padding: 26px; border: 0; border-radius: 9px; box-shadow: 0 24px 70px rgba(0, 0, 0, .25); }
.dialog::backdrop { background: rgba(15, 23, 42, .55); }
.dialog h2 { margin: 0; }
.dialog p { color: #778591; }
.order-lookup-dialog { width: min(520px, calc(100% - 24px)); padding: 28px 32px 32px; }
.order-lookup-dialog > h2 { color: #7e8c98; }
.query-limit { padding: 14px 16px; color: #8795a1!important; background: #f8fafc; border-radius: 6px; font-size: 13px; }
.query-tabs { display: grid; grid-template-columns: 1fr 1.45fr; margin: 22px 0 20px; border-bottom: 2px solid #e5e7eb; }
.query-tabs button { padding: 12px 6px; color: #8a98a5; background: transparent; border: 0; border-bottom: 3px solid transparent; font-weight: 750; cursor: pointer; }
.query-tabs button.active { color: #374151; border-bottom-color: var(--blue); }
.query-actions { display: flex; gap: 8px; margin-top: 8px; }
.query-actions .primary-button { width: auto; }
.reset-button { min-height: 45px; padding: 0 24px; color: #fff; background: var(--blue); border: 0; border-radius: 4px; cursor: pointer; }
.lookup-result { display: grid; gap: 8px; margin-top: 18px; }
.lookup-order { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 12px 13px; color: #52616d; background: #f8fafc; border: 1px solid #e5eaf0; border-radius: 5px; }
.lookup-order strong { overflow-wrap: anywhere; color: #334155; font-size: 13px; }
.lookup-order span { color: var(--blue); font-size: 12px; font-weight: 700; }
.lookup-order small { grid-column: 1 / -1; color: #8795a1; }
.lookup-empty { padding: 18px; color: #8795a1; background: #f8fafc; text-align: center; }
.announcement-dialog { width: min(620px, calc(100% - 28px)); }
.announcement-body { max-height: 60vh; overflow: auto; color: #475569; line-height: 1.8; }
.announcement-body img { max-width: 100%; height: auto; }
.announcement-body a { color: var(--blue); }
.purchase-notice-dialog { width: min(620px, calc(100% - 24px)); padding: 0 0 22px; }
.purchase-notice-head { position: relative; display: flex; align-items: center; min-height: 48px; padding: 0 20px; color: #71808c; border-bottom: 1px solid var(--line); }
.purchase-notice-head .dialog-close { top: 5px; }
.purchase-notice-body { max-height: 58vh; overflow: auto; padding: 25px 30px; color: #334155; font-size: 16px; line-height: 1.8; overflow-wrap: anywhere; }
.purchase-notice-body img { max-width: 100%; height: auto; }
.purchase-notice-body a { color: var(--blue); }
.notice-confirm { width: auto; min-width: 120px; margin: 0 auto; }
.dialog-close { position: absolute; top: 9px; right: 13px; padding: 3px 9px; color: #66737e; background: transparent; border: 0; font-size: 26px; cursor: pointer; }
.stack-form label { display: grid; gap: 5px; margin-bottom: 12px; color: #5d6973; font-size: 13px; font-weight: 650; }
.stack-form input { width: 100%; height: 42px; padding: 0 11px; border: 1px solid #d8e0e6; border-radius: 4px; outline: 0; }
.stack-form input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(55, 136, 249, .1); }
.result { overflow: auto; padding: 12px; color: #46525c; background: #f6f8fa; border-radius: 4px; white-space: pre-wrap; }
.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; }
.payment-home-link { display: inline-grid; place-items: center; text-decoration: none; }
.payment-page { width: min(1000px, calc(100% - 32px)); min-height: calc(100vh - 92px); margin: 0 auto; padding: 46px 0 70px; }
.payment-page > h1 { margin: 0 0 30px; color: #8b99a5; font-size: 25px; }
.payment-summary { padding: 38px 44px 45px; background: #fff; border-radius: 7px; box-shadow: 0 7px 28px rgba(42,58,79,.06); }
.payment-summary dl { display: grid; gap: 18px; margin: 0; }
.payment-summary dl div { display: grid; grid-template-columns: 110px 1fr; gap: 12px; }
.payment-summary dt { color: #82909c; font-weight: 750; }
.payment-summary dd { margin: 0; color: #8493a0; overflow-wrap: anywhere; }
.payment-action { margin-top: 42px; text-align: center; }
.payment-action p { color: #ff6262; }
.pay-now-button { display: inline-grid; place-items: center; min-width: 140px; min-height: 50px; padding: 0 25px; color: #fff; background: #ff6262; border-radius: 4px; text-decoration: none; font-weight: 700; }
.pay-now-button:hover { background: #f04f4f; }
.payment-complete { margin-top: 35px; padding: 18px; color: #166534; background: #f0fdf4; border: 1px solid #bbf7d0; text-align: center; }

/* Tutorial pages retain the same site language. */
.article-container { width: min(1050px, calc(100% - 36px)); min-height: calc(100vh - 168px); margin: 0 auto; padding: 34px 0 70px; display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 25px; }
.article-container > .breadcrumb { grid-column: 1 / -1; margin: 0; }
.article, .article-links { padding: 32px; background: #fff; border: 1px solid var(--line); border-radius: 7px; box-shadow: 0 5px 18px rgba(42, 58, 79, .05); }
.article h1 { margin-top: 0; font-size: clamp(27px, 4vw, 38px); line-height: 1.28; }
.lead { color: #71808c; font-size: 17px; }
.article-body { margin-top: 30px; }
.article-body p { color: #485560; white-space: pre-line; }
.article-links { align-self: start; padding: 22px; }
.article-links h2 { margin: 18px 0 5px; color: #687783; font-size: 15px; }
.article-links h2:first-child { margin-top: 0; }
.article-links a { display: block; padding: 8px 0; color: var(--blue); border-bottom: 1px solid var(--line); text-decoration: none; font-size: 13px; }

@media (max-width: 920px) {
  .site-header { height: auto; }
  .header-inner { min-height: 82px; grid-template-columns: 1fr auto; gap: 15px; }
  .main-nav { display: none; }
  .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .detail-layout { grid-template-columns: 1fr; }
  .purchase-panel { position: static; }
  .seo-guide, .article-container { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .header-inner, .store-main, .detail-main, .footer-inner, .article-container { width: min(100% - 24px, 1200px); }
  .header-inner { min-height: 70px; }
  .brand { gap: 9px; font-size: 17px; }
  .brand img { width: 36px; height: 36px; }
  .brand-divider { display: none; }
  .outline-button { min-width: auto; height: 38px; padding: 0 10px; font-size: 13px; }
  .store-main, .detail-main { padding-top: 16px; }
  .store-toolbar { gap: 10px; margin-bottom: 14px; }
  .search-wrap { width: min(210px, calc(100% - 100px)); }
  .store-search { height: 40px; padding-left: 40px; font-size: 13px; }
  .search-wrap > span { top: 12px; }
  .notice-label { height: 40px; padding: 0 14px; font-size: 14px; }
  .category-tabs { margin-top: 0; overflow: visible; }
  .category-tab { height: 39px; padding: 0 15px; font-size: 13px; }
  .product-grid { grid-template-columns: 1fr; gap: 12px; }
  .product-card-link { display: grid; grid-template-columns: 112px minmax(0,1fr); grid-template-rows: 28px 1fr 30px; column-gap: 12px; min-height: 138px; padding: 13px 14px; }
  .delivery-mark { grid-column: 1; grid-row: 1; min-height: 0; font-size: 9px; text-align: left; }
  .product-visual { grid-column: 1; grid-row: 2 / 4; width: 84px; height: 84px; margin: 0 auto; align-self: center; }
  .product-visual img { width: 76px; height: 76px; }
  .product-card h3 { grid-column: 2; grid-row: 1 / 3; align-self: center; min-height: 0; margin: 0; font-size: 15px; -webkit-line-clamp: 3; }
  .product-card-bottom { grid-column: 2; grid-row: 3; align-items: center; margin: 0; padding: 0; }
  .product-card-bottom strong { font-size: 20px; }
  .inventory { display: none; }
  .seo-guide { gap: 18px; margin-top: 28px; padding: 23px 20px; }
  .seo-guide h2 { font-size: 19px; }
  .detail-page-title { margin-bottom: 16px; }
  .detail-layout { display: grid; }
  .purchase-panel { order: -1; }
  .product-description-card { padding: 22px 19px 30px; }
  .description-highlight { font-size: 16px; }
  .purchase-panel { padding: 23px 19px; }
  .purchase-product-head { grid-template-columns: 50px 1fr; gap: 11px; }
  .purchase-product-head img { width: 50px; height: 50px; }
  .purchase-product-head h2 { font-size: 19px; }
  .status-badges { margin-left: 61px; }
  .article, .article-links { padding: 22px 19px; }
  .purchase-notice-dialog { width: calc(100% - 18px); }
  .purchase-notice-body { padding: 22px 18px; font-size: 15px; }
  .order-lookup-dialog { padding: 25px 20px 28px; }
  .query-limit { margin: 18px 0; }
  .query-tabs { margin-top: 18px; }
  .query-actions .primary-button,.query-actions .reset-button { padding: 0 20px; }
  .footer-inner { min-height: 66px; flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; }
  .payment-page { padding-top: 25px; }
  .payment-page > h1 { margin-bottom: 18px; font-size: 22px; }
  .payment-summary { padding: 25px 20px 30px; }
  .payment-summary dl div { grid-template-columns: 82px 1fr; gap: 7px; font-size: 14px; }
  .payment-action { margin-top: 28px; }
}
