:root {
  --page: #f7fafc;
  --surface: #ffffff;
  --surface-soft: #eef6f8;
  --text: #1f2937;
  --muted: #64748b;
  --primary: #227c9d;
  --primary-dark: #155e75;
  --accent: #4f9d69;
  --line: #dbe7ef;
  --code: #111827;
  --shadow: 0 18px 45px rgba(34, 124, 157, 0.10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.7;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }
.section { padding: 56px 0; }
.section.compact { padding: 26px 0; }
.soft { background: var(--surface-soft); }
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; flex: 0 0 auto; }
.brand-logo { width: auto; height: 32px; object-fit: contain; }
.nav-menu { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.nav-menu a { padding: 8px 12px; border-radius: 8px; color: #334155; font-size: 14px; }
.nav-menu a:hover, .nav-menu a.is-active { background: #e8f3f7; color: var(--primary-dark); }
.nav-toggle { display: none; border: 1px solid var(--line); background: #fff; border-radius: 8px; width: 42px; height: 38px; font-size: 20px; }
.breadcrumb-wrap { border-bottom: 1px solid var(--line); background: #fff; }
.breadcrumb { display: flex; gap: 8px; align-items: center; min-height: 44px; color: var(--muted); font-size: 13px; overflow-x: auto; white-space: nowrap; }
.page-banner {
  background: linear-gradient(135deg, #eef7f6 0%, #f8fbff 52%, #ffffff 100%);
  border-bottom: 1px solid var(--line);
}
.page-banner-inner {
  min-height: 156px;
  display: grid;
  align-items: center;
  padding-top: 28px;
  padding-bottom: 28px;
}
.page-banner h1 { font-size: 34px; }
.page-banner p { max-width: 760px; color: var(--muted); margin-bottom: 0; }
.page-banner .eyebrow { color: var(--primary-dark); margin-bottom: 8px; }

.hero { padding: 54px 0 34px; background: linear-gradient(180deg, #ffffff 0%, #eef7f6 100%); }
.home-top-section { padding: 24px 0 0; }
.home-top { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, .55fr); gap: 18px; align-items: stretch; }
.home-slider, .latest-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
}
.home-slider { position: relative; min-height: 280px; overflow: hidden; }
.home-slide { position: absolute; inset: 0; display: block; opacity: 0; pointer-events: none; transition: opacity .24s ease; }
.home-slide.is-active { opacity: 1; pointer-events: auto; }
.home-slide img { width: 100%; height: 100%; object-fit: cover; }
.home-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15, 23, 42, .06), rgba(15, 23, 42, .68)); }
.home-slide span { position: absolute; z-index: 1; left: 24px; right: 24px; bottom: 24px; color: #fff; }
.home-slide strong { display: block; font-size: 25px; line-height: 1.25; }
.home-slide small { display: block; margin-top: 8px; color: rgba(255, 255, 255, .86); font-size: 14px; line-height: 1.6; }
.home-slide-dots { position: absolute; z-index: 2; right: 18px; bottom: 18px; display: flex; gap: 7px; }
.home-slide-dot { width: 9px; height: 9px; padding: 0; border: 0; border-radius: 99px; background: rgba(255,255,255,.58); cursor: pointer; }
.home-slide-dot.is-active { width: 24px; background: #fff; }
.home-slide-arrow {
  position: absolute;
  z-index: 2;
  top: 50%;
  width: 38px;
  height: 44px;
  transform: translateY(-50%);
  border: 1px solid rgba(255,255,255,.34);
  border-radius: 8px;
  background: rgba(15, 23, 42, .34);
  color: #fff;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
}
.home-slide-arrow:hover { background: rgba(15, 23, 42, .56); }
.home-slide-arrow.prev { left: 16px; }
.home-slide-arrow.next { right: 16px; }
.latest-panel { padding: 20px; }
.latest-head { border-bottom: 1px solid var(--line); padding-bottom: 12px; margin-bottom: 6px; }
.latest-head h2 { font-size: 22px; }
.latest-list { display: grid; }
.latest-item { display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 12px; min-width: 0; padding: 13px 0; border-bottom: 1px solid var(--line); align-items: center; }
.latest-item:last-child { border-bottom: 0; }
.latest-item:nth-child(n+7) { display: none; }
.latest-item span { color: var(--muted); font-size: 13px; font-weight: 800; }
.latest-item strong { display: block; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; line-height: 1.45; font-size: 15px; }
.latest-item:hover strong { color: var(--primary-dark); }
.pt-tight { padding-top: 24px; }
.tutorial-list-section { padding-top: 24px; }
.docs-detail-section { padding-top: 24px; }
.tutorial-groups { display: grid; gap: 42px; }
.tutorial-group { display: grid; gap: 18px; }
.group-head { display: flex; justify-content: space-between; align-items: end; gap: 18px; border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.group-head p { color: var(--muted); margin-bottom: 0; }
.group-head .eyebrow { color: var(--primary-dark); margin-bottom: 8px; }
.home-catalog { display: grid; gap: 18px; }
.catalog-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; }
.catalog-head h2 { font-size: 26px; }
.catalog-mode { display: inline-flex; gap: 6px; padding: 4px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.catalog-mode button { min-height: 34px; padding: 0 14px; border: 0; border-radius: 6px; background: transparent; color: var(--muted); font: inherit; font-weight: 800; cursor: pointer; }
.catalog-mode button.is-active { background: var(--primary); color: #fff; }
.catalog-view { display: none; }
.catalog-view.is-active { display: block; }
.catalog-all { display: grid; gap: 24px; }
.catalog-group { display: grid; gap: 12px; }
.catalog-group-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding-bottom: 10px; }
.catalog-group-head p { max-width: 620px; color: var(--muted); margin: 0; text-align: right; }
.home-tabs { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; align-items: start; }
.home-tab-list { display: grid; gap: 8px; position: sticky; top: 86px; }
.home-tab {
  width: 100%;
  display: grid;
  gap: 3px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}
.home-tab span { font-weight: 900; }
.home-tab small { color: var(--muted); font-size: 12px; }
.home-tab:hover, .home-tab.is-active { border-color: rgba(34, 124, 157, .45); background: #e8f3f7; color: var(--primary-dark); }
.home-tab-content { min-width: 0; }
.home-tabs.is-ready .home-tab-panel { display: none; }
.home-tabs.is-ready .home-tab-panel.is-active { display: block; }
.home-tab-head { margin-bottom: 18px; }
.home-tab-head p { max-width: 720px; color: var(--muted); margin-bottom: 0; }
.book-grid.home-tab-books { grid-template-columns: repeat(3, 1fr); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(320px, .78fr); gap: 36px; align-items: center; }
.eyebrow { margin: 0 0 10px; color: var(--primary-dark); font-size: 13px; font-weight: 800; letter-spacing: 0; }
h1, h2, h3, p { overflow-wrap: anywhere; }
h1 { margin: 0; font-size: 42px; line-height: 1.18; letter-spacing: 0; }
h2 { margin: 0; font-size: 28px; line-height: 1.25; letter-spacing: 0; }
h3 { margin: 0; font-size: 18px; line-height: 1.35; letter-spacing: 0; }
.hero-desc { color: var(--muted); font-size: 17px; max-width: 680px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 18px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--text); font-weight: 700; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.hero-panel { display: grid; gap: 12px; }
.slide-card { position: relative; overflow: hidden; border-radius: 8px; min-height: 128px; box-shadow: var(--shadow); }
.slide-card img { width: 100%; height: 150px; object-fit: cover; }
.slide-card span { position: absolute; left: 16px; right: 16px; bottom: 14px; color: #fff; font-weight: 800; text-shadow: 0 2px 12px rgba(0,0,0,.45); }

.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 18px; }
.stat strong { display: block; font-size: 26px; color: var(--primary-dark); }
.stat span { color: var(--muted); }
.section-head { margin-bottom: 22px; }
.section-head p { max-width: 720px; color: var(--muted); }
.page-section { padding-top: 24px; }
.book-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.book-grid.in-list { grid-template-columns: repeat(2, 1fr); }
.book-grid.root-list { grid-template-columns: repeat(3, 1fr); gap: 18px; align-items: stretch; }
.book-card, .chapter-card, .feature-item, .process-card, .page-title-card, .reader, .message-card, .message-item, .book-sidebar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
}
.book-card { display: block; overflow: hidden; color: inherit; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.book-card:hover { border-color: rgba(34, 124, 157, .45); box-shadow: 0 14px 34px rgba(15, 23, 42, .08); transform: translateY(-2px); }
.book-card-body { display: grid; grid-template-columns: 80px minmax(0, 1fr); gap: 14px; align-items: start; padding: 18px; }
.book-icon { position: relative; width: 80px; height: 80px; border-radius: 8px; background: linear-gradient(135deg, #e8f3f7, #f7fbfd); border: 1px solid #cfe3ec; box-shadow: inset 0 -10px 0 rgba(34, 124, 157, .08); }
.book-icon::before { content: ""; position: absolute; left: 21px; top: 18px; width: 34px; height: 42px; border: 2px solid var(--primary); border-left-width: 8px; border-radius: 5px 7px 7px 5px; background: #fff; }
.book-icon::after { content: ""; position: absolute; left: 36px; top: 27px; width: 20px; height: 2px; background: #9bb8c4; box-shadow: 0 8px 0 #9bb8c4, 0 16px 0 #9bb8c4; }
.book-card-content { min-width: 0; }
.root-list .book-card-body { padding: 18px; }
.root-list .book-card h3 { font-size: 18px; }
.root-list .book-card p { margin: 12px 0 0; font-size: 15px; line-height: 1.7; }
.root-list .book-meta { margin-top: 16px; }
.book-card p { color: var(--muted); }
.book-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 16px; font-size: 13px; color: var(--muted); }
.book-meta strong { color: var(--primary-dark); font-weight: 800; }
.split { display: grid; grid-template-columns: 280px 1fr; gap: 32px; align-items: start; }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.feature-item { padding: 20px; }
.feature-item p, .process-card p, .chapter-card p { color: var(--muted); }
.chapter-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.chapter-card { overflow: hidden; }
.chapter-card img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.chapter-card > div { padding: 16px; }
.chapter-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.chapter-tags span { display: inline-flex; align-items: center; min-height: 24px; padding: 0 8px; border-radius: 6px; background: #edf7f1; color: #266848; font-size: 12px; font-weight: 700; }
.process-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.process-card { padding: 22px; }
.process-card span { color: var(--primary); font-size: 28px; font-weight: 900; }
.faq-grid { display: grid; grid-template-columns: 280px 1fr; gap: 32px; }
.faq-item { border-bottom: 1px solid var(--line); padding: 16px 0; }
.faq-item summary { cursor: pointer; font-weight: 800; }
.faq-item p { color: var(--muted); margin-bottom: 0; }

.docs-wide { width: min(1460px, calc(100% - 32px)); }
.docs-layout { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; align-items: start; }
.docs-detail-layout { grid-template-columns: 280px minmax(0, 1fr) 220px; }
.book-sidebar { position: sticky; top: 86px; padding: 18px; max-height: calc(100vh - 110px); overflow: auto; }
.book-sidebar-toggle { display: none; width: 100%; min-height: 40px; border: 1px solid var(--line); border-radius: 8px; background: #f8fbff; color: var(--primary-dark); font: inherit; font-weight: 900; text-align: left; padding: 0 12px; cursor: pointer; }
.sidebar-title { font-weight: 900; margin-bottom: 14px; }
.book-group { border-top: 1px solid var(--line); padding-top: 12px; margin-top: 12px; }
.book-group:first-of-type { border-top: 0; padding-top: 0; margin-top: 0; }
.book-group summary { display: flex; justify-content: space-between; gap: 12px; cursor: pointer; font-weight: 800; list-style: none; }
.book-group summary::-webkit-details-marker { display: none; }
.book-group em { color: var(--muted); font-style: normal; font-size: 12px; }
.chapter-list { display: grid; gap: 6px; margin-top: 10px; }
.chapter-list a { display: grid; grid-template-columns: 28px 1fr; gap: 8px; padding: 9px; border-radius: 8px; color: #475569; font-size: 13px; }
.chapter-list a:hover, .chapter-list a.is-current { background: var(--primary); color: #fff; }
.chapter-list span { font-weight: 900; }
.docs-main { min-width: 0; }
.page-title-card { padding: 26px; margin-bottom: 18px; }
.page-title-card p { color: var(--muted); }
.chapter-list-main { display: grid; gap: 12px; }
.chapter-row { display: grid; grid-template-columns: 58px 1fr; gap: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: inherit; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease; }
.chapter-row:hover { border-color: rgba(34, 124, 157, .45); box-shadow: 0 12px 30px rgba(15, 23, 42, .07); transform: translateY(-1px); }
.chapter-no { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 8px; background: #e8f3f7; color: var(--primary-dark); font-weight: 900; }
.chapter-row p { color: var(--muted); margin-bottom: 0; }
.book-chapter-index { display: grid; gap: 10px; margin-top: 8px; }
.book-chapter-link {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.book-chapter-link:hover { border-color: rgba(34, 124, 157, .45); background: #f2fafb; }
.book-chapter-link strong { display: block; font-size: 16px; line-height: 1.45; }
.book-chapter-link em { display: block; color: var(--muted); font-style: normal; font-size: 14px; margin-top: 3px; }
.book-chapter-link small { color: var(--muted); white-space: nowrap; }
.reader { padding: 34px; min-width: 0; }
.reader-head { border-bottom: 1px solid var(--line); padding-bottom: 20px; margin-bottom: 24px; }
.reader-head p, .reader-meta { color: var(--muted); }
.inline-toc { border: 1px solid var(--line); border-radius: 8px; padding: 14px; background: #f8fbff; margin-bottom: 22px; }
.inline-toc.is-hidden { display: none; }
.doc-toc-panel { position: sticky; top: 86px; max-height: calc(100vh - 110px); overflow: auto; margin-bottom: 0; background: var(--surface); box-shadow: 0 10px 30px rgba(15, 23, 42, .04); }
.toc-title { font-weight: 900; margin-bottom: 8px; }
.toc-list { display: grid; gap: 6px; }
.toc-list a { color: var(--primary-dark); font-size: 14px; }
.toc-list a.is-h3 { padding-left: 16px; color: var(--muted); }
.article-content { font-size: 16px; line-height: 1.9; }
.article-content h2 { margin-top: 30px; margin-bottom: 12px; font-size: 24px; scroll-margin-top: 92px; }
.article-content h3 { margin-top: 24px; margin-bottom: 10px; font-size: 20px; scroll-margin-top: 92px; }
.article-content p { margin: 0 0 16px; }
.article-content ul, .article-content ol { padding-left: 1.4em; }
.article-content code { background: #eef2f7; border-radius: 6px; padding: 2px 6px; }
.article-content pre { overflow-x: auto; background: var(--code); color: #fff; border-radius: 8px; padding: 16px; }
.article-content table { width: 100%; border-collapse: collapse; display: block; overflow-x: auto; }
.article-content th, .article-content td { border: 1px solid var(--line); padding: 10px; white-space: nowrap; }
.article-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 28px; }
.article-tags a { background: #eef7f6; color: var(--primary-dark); padding: 5px 10px; border-radius: 6px; font-size: 13px; }
.prev-next { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); color: var(--muted); }
.prev-next a { color: var(--primary-dark); font-weight: 800; }
.category-section, .article-section, .message-section { padding-top: 24px; }
.article-list-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.article-list-main {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
}
.article-list-main { padding: 30px; }
.article-list-head { border-bottom: 1px solid var(--line); padding-bottom: 18px; margin-bottom: 8px; }
.article-list-head p { max-width: 760px; color: var(--muted); }
.article-list { display: grid; gap: 0; }
.article-list-item { padding: 24px 0; border-bottom: 1px solid var(--line); }
.article-list-item:last-child { border-bottom: 0; }
.article-list-content { min-width: 0; }
.article-list-meta { display: flex; gap: 8px; flex-wrap: wrap; color: var(--muted); font-size: 13px; margin-bottom: 8px; }
.article-list-meta span { display: inline-flex; align-items: center; gap: 4px; }
.article-list-meta span + span::before { content: ""; width: 4px; height: 4px; border-radius: 99px; background: var(--line); }
.article-list-item h2 { font-size: 23px; margin-bottom: 8px; }
.article-list-item h2 a:hover { color: var(--primary-dark); }
.article-list-item p { color: var(--muted); margin: 0 0 14px; max-width: 820px; }
.article-list-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.article-chip { display: inline-flex; align-items: center; min-height: 26px; padding: 0 9px; border-radius: 6px; background: #eef7f6; color: var(--primary-dark); font-size: 12px; font-weight: 800; }
.read-more { margin-left: auto; color: var(--primary-dark); font-weight: 900; font-size: 14px; }
.article-list-sidebar { position: sticky; top: 86px; display: grid; gap: 14px; }
.side-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
  padding: 18px;
}
.side-link-list, .side-article-list { display: grid; gap: 8px; }
.side-link-list a { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 11px; border-radius: 8px; color: #475569; line-height: 1.45; background: #f8fbff; }
.side-link-list small { color: var(--muted); font-size: 12px; }
.side-article-list a { display: grid; gap: 4px; padding: 11px 0; border-bottom: 1px solid var(--line); color: #475569; line-height: 1.45; }
.side-article-list a:last-child { border-bottom: 0; }
.side-article-list strong { font-size: 14px; color: var(--text); }
.side-article-list span { color: var(--muted); font-size: 12px; }
.side-link-list a:hover, .side-link-list a.is-current { background: #e8f3f7; color: var(--primary-dark); }
.side-article-list a:hover strong { color: var(--primary-dark); }
.article-page-layout { width: min(1180px, calc(100% - 32px)); display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
.article-reader { min-width: 0; }
.related-panel { border-top: 1px solid var(--line); margin-top: 28px; padding-top: 24px; }
.related-head { margin-bottom: 14px; }
.related-head h2 { font-size: 22px; }
.related-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.related-card { display: grid; gap: 6px; padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: #fbfdff; }
.related-card span { color: var(--muted); font-size: 12px; font-weight: 800; }
.related-card strong { line-height: 1.45; }
.related-card em { color: var(--muted); font-style: normal; font-size: 13px; line-height: 1.55; }
.related-card:hover { border-color: rgba(34, 124, 157, .45); background: #f2fafb; }
.pager { display: flex; gap: 8px; justify-content: center; margin-top: 26px; flex-wrap: wrap; }
.pager a, .pager span { min-width: 36px; min-height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.pager .is-active { background: var(--primary); color: #fff; }
.empty-state { padding: 28px; border: 1px dashed var(--line); border-radius: 8px; background: #fff; color: var(--muted); text-align: center; }
.narrow-page { max-width: 880px; }
.contact-grid, .feedback-layout { display: grid; grid-template-columns: .9fr 1.1fr; gap: 22px; align-items: start; }
.contact-lines { display: grid; gap: 8px; margin-top: 18px; color: var(--text); }
.feedback-intro, .message-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
}
.feedback-intro { padding: 30px; }
.feedback-intro p { color: var(--muted); }
.feedback-points { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }
.feedback-points span { display: inline-flex; align-items: center; min-height: 28px; padding: 0 10px; border-radius: 6px; background: #e8f3f7; color: var(--primary-dark); font-weight: 800; font-size: 13px; }
.message-card { padding: 24px; }
.message-form { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.message-form label { display: grid; gap: 6px; font-weight: 700; color: #334155; }
.message-form .full { grid-column: 1 / -1; }
.message-form input, .message-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 12px;
  font: inherit;
  background: #fff;
}
.form-message { grid-column: 1 / -1; padding: 10px; border-radius: 8px; background: #eef7f6; }
.hidden { display: none; }
.messages { margin-top: 28px; }
.feedback-messages { display: grid; gap: 12px; }
.message-item { padding: 16px; margin-top: 12px; }
.message-item time { color: var(--muted); margin-left: 10px; font-size: 13px; }
.not-found { min-height: 360px; display: grid; align-content: center; justify-items: start; }
.site-footer { background: #0f172a; color: #dbe7ef; padding: 42px 0 18px; }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) .85fr .9fr .75fr; gap: 18px; align-items: start; }
.footer-about, .footer-panel { min-width: 0; }
.footer-brand { color: #fff; font-weight: 900; font-size: 22px; margin-bottom: 8px; }
.site-footer h3 { color: #fff; margin: 0 0 12px; font-size: 16px; }
.site-footer p { color: #b6c5d3; margin: 4px 0; }
.footer-about > p { max-width: 360px; }
.footer-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.footer-badges span { display: inline-flex; align-items: center; min-height: 26px; padding: 0 9px; border-radius: 6px; background: rgba(34, 124, 157, .22); color: #dff6ff; font-size: 12px; font-weight: 800; }
.footer-nav, .footer-contact { display: grid; gap: 7px; }
.footer-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 14px; }
.footer-nav a { color: #b6c5d3; line-height: 1.5; }
.footer-nav a:hover { color: #fff; }
.friend-links { display: flex; flex-wrap: wrap; gap: 8px; }
.friend-links a { color: #dbe7ef; border: 1px solid rgba(255,255,255,.18); border-radius: 6px; padding: 5px 10px; font-size: 13px; background: rgba(255,255,255,.04); }
.friend-links a:hover { border-color: rgba(255,255,255,.36); background: rgba(255,255,255,.08); color: #fff; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-top: 1px solid rgba(255,255,255,.12); margin-top: 30px; padding-top: 16px; color: #94a3b8; font-size: 13px; }

.tool-shell-page {
  min-height: 100vh;
  background: #f6f9fc;
}
.tool-shell-page .site-header .container {
  width: 100%;
  max-width: none;
  padding: 0 16px;
}
.tool-shell {
  width: 100%;
  min-height: calc(100vh - 69px);
  margin: 0;
  display: grid;
  grid-template-columns: 208px minmax(0, 1fr);
  align-items: stretch;
}
.tool-rail {
  position: sticky;
  top: 69px;
  align-self: start;
  padding: 12px 8px 24px 8px;
  border-right: 1px solid var(--line);
  background: #fff;
}
.tool-rail-head {
  display: grid;
  gap: 10px;
  padding: 12px 10px 18px;
}
.tool-rail-head.compact h1 { font-size: 28px; }
.tool-rail-head h1 {
  font-size: 34px;
  line-height: 1.18;
}
.tool-rail-head p {
  margin: 0;
  color: var(--muted);
}
.tool-root-list {
  display: grid;
  gap: 8px;
}
.tool-root-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: #334155;
}
.tool-root-link span {
  min-width: 0;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tool-root-link small {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  line-height: 1;
}
.tool-root-link:hover,
.tool-root-link.is-active {
  border-color: transparent;
  background: #eef7fb;
  color: var(--primary-dark);
}
.tool-root-link:hover small,
.tool-root-link.is-active small {
  color: var(--primary-dark);
}
.tool-workspace {
  min-width: 0;
  padding: 0 16px 36px 16px;
}
.tool-workspace-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 0 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.tool-workspace-head h2 {
  font-size: 30px;
}
.tool-workspace-head p {
  max-width: 760px;
  margin: 8px 0 0;
  color: var(--muted);
}
.tool-section-list {
  display: grid;
  gap: 16px;
  padding-top: 16px;
}
.tool-category-block {
  display: grid;
  gap: 10px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 88px;
}
.tool-category-block:last-child {
  border-bottom: 0;
}
.tool-category-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.tool-category-head h3 {
  font-size: 19px;
}
.tool-category-head p {
  margin: 3px 0 0;
  color: var(--muted);
}
.tool-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}
.tool-card-grid.category-page {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
.tool-card {
  min-height: 88px;
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 10px 28px rgba(15, 23, 42, .04);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.tool-card strong {
  color: var(--text);
  font-size: 15px;
  line-height: 1.45;
}
.tool-card span {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.65;
}
.tool-card:hover {
  border-color: rgba(34, 124, 157, .45);
  box-shadow: 0 14px 34px rgba(15, 23, 42, .08);
  transform: translateY(-1px);
}
.tool-card:hover strong {
  color: var(--primary-dark);
}
.tool-detail-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.tool-subnav {
  position: sticky;
  top: 69px;
  display: grid;
  gap: 6px;
  max-height: calc(100vh - 69px);
  overflow: auto;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-subnav-title {
  padding: 2px 2px 8px;
  color: var(--text);
  font-weight: 900;
}
.tool-subnav a {
  padding: 8px 9px;
  border-radius: 8px;
  color: #475569;
  line-height: 1.45;
}
.tool-subnav a:hover,
.tool-subnav a.is-current {
  background: #e8f3f7;
  color: var(--primary-dark);
  font-weight: 800;
}
.tool-detail {
  min-width: 0;
  min-height: calc(100vh - 130px);
  padding: 16px 24px 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, .04);
}
.tool-detail-head {
  padding-bottom: 20px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line);
}
.tool-detail-head h2 {
  font-size: 30px;
}
.tool-detail-head h1 {
  font-size: 30px;
  line-height: 1.22;
}
.tool-detail-head p {
  max-width: 820px;
  margin-bottom: 0;
  color: var(--muted);
}
.tool-app {
  display: grid;
  gap: 14px;
  margin-bottom: 24px;
}
.tool-panel-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .95fr);
  gap: 14px;
}
.tool-panel {
  display: grid;
  gap: 14px;
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.tool-panel h2 {
  font-size: 20px;
}
.compact-tool {
  gap: 10px;
}
.compact-panel {
  padding: 14px;
}
.timestamp-one-screen {
  display: grid;
  grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}
.timestamp-input-zone,
.timestamp-output-zone {
  display: grid;
  gap: 10px;
  min-width: 0;
}
.timestamp-input-zone {
  padding-right: 14px;
  border-right: 1px solid var(--line);
}
.timestamp-param-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}
.timestamp-param-form label {
  display: grid;
  gap: 6px;
  min-width: 0;
  color: #334155;
  font-weight: 800;
}
.compact-form {
  gap: 9px;
}
.compact-form .tool-field {
  min-height: 38px;
  padding: 7px 10px;
}
.compact-results {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.compact-results .timestamp-result-item {
  padding: 8px 10px;
}
.compact-results .copy-chip {
  min-height: 24px;
  font-size: 14px;
}
.loan-tabs {
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(120px, 1fr));
  gap: 4px;
  width: min(100%, 360px);
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #eef6f8;
}
.loan-tab {
  min-height: 34px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-weight: 900;
  cursor: pointer;
}
.loan-tab.is-active {
  background: #fff;
  color: var(--primary-dark);
  box-shadow: 0 8px 18px rgba(15, 23, 42, .08);
}
.loan-tab-panel {
  display: none;
}
.loan-tab-panel.is-active {
  display: block;
}
.compact-live {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.compact-live > div {
  padding: 10px 12px;
}
.compact-live strong {
  font-size: 15px;
}
.compact-batch {
  padding: 12px 14px;
}
.compact-batch summary {
  cursor: pointer;
  font-weight: 900;
  color: var(--primary-dark);
}
.compact-batch .tool-io-grid {
  margin-top: 12px;
}
.tool-live-panel {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 10px;
}
.tool-live-panel.compact-live {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.tool-live-panel > div {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-live-panel span,
.timestamp-result-item span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.tool-live-panel strong {
  font-size: 18px;
  line-height: 1.3;
}
.timestamp-result-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.tool-status-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
}
.tool-status-grid div {
  display: grid;
  gap: 4px;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-status-grid span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.tool-status-grid strong {
  color: var(--primary-dark);
  font-size: 18px;
}
.timestamp-result-item {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.copy-chip {
  width: 100%;
  min-height: 30px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--primary-dark);
  font: inherit;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere;
}
.copy-chip:hover {
  text-decoration: underline;
}
.copy-toast {
  position: fixed;
  z-index: 1000;
  transform: translateY(8px);
  opacity: 0;
  pointer-events: none;
  padding: 10px 14px;
  border: 1px solid rgba(25, 118, 95, .25);
  border-radius: 8px;
  background: #0f766e;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  box-shadow: 0 16px 36px rgba(15, 23, 42, .18);
  transition: opacity .18s ease, transform .18s ease;
}
.copy-toast.is-show {
  transform: translateY(-4px);
  opacity: 1;
}
.tool-app-status,
.tool-notice {
  padding: 22px;
  border: 1px dashed #bdd4df;
  border-radius: 8px;
  background: #f8fbff;
  color: var(--muted);
}
.tool-notice strong {
  display: block;
  margin-bottom: 6px;
  color: var(--text);
  font-size: 18px;
}
.tool-notice p {
  margin: 0;
}
.tool-io-grid,
.tool-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.tool-io-grid label,
.tool-form-grid label {
  display: grid;
  gap: 7px;
  min-width: 0;
  color: #334155;
  font-weight: 800;
}
.tool-input,
.tool-output,
.tool-field,
.tool-zone,
.tool-form-grid input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
  color: var(--text);
  font: inherit;
}
.tool-input,
.tool-output {
  min-height: 310px;
  resize: vertical;
  padding: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
  font-size: 13px;
  line-height: 1.6;
}
.tool-input.small,
.tool-output.small {
  min-height: 190px;
}
.tool-output.wide {
  min-height: 190px;
}
.tool-field,
.tool-zone,
.tool-form-grid input {
  min-height: 42px;
  padding: 8px 11px;
}
.tool-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tool-action {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--primary);
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.tool-action.ghost {
  border-color: var(--line);
  background: #fff;
  color: var(--primary-dark);
}
.tool-action:hover {
  filter: brightness(.97);
}
.tool-help {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.color-preview {
  min-height: 72px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.tool-field[type="color"],
.tool-form-grid input[type="color"] {
  min-height: 46px;
  padding: 4px;
  cursor: pointer;
}
.tool-option-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tool-pill {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: #334155;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.tool-pill.is-active {
  border-color: var(--primary);
  background: #e8f3f7;
  color: var(--primary-dark);
}
.tool-result-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-result-table th,
.tool-result-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.tool-result-table th {
  background: #f3f8fb;
  color: #334155;
  font-size: 13px;
}
.tool-result-table tr:last-child td {
  border-bottom: 0;
}
.tool-scroll {
  overflow: auto;
  border-radius: 8px;
}
.color-tool-layout {
  display: grid;
  grid-template-columns: minmax(280px, 380px) minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}
.color-card {
  display: grid;
  gap: 12px;
  min-width: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.color-main-swatch {
  min-height: 172px;
  border: 1px solid rgba(15, 23, 42, .14);
  border-radius: 8px;
  background: #227c9d;
}
.color-value-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.color-value {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.color-value span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.color-value button {
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--primary-dark);
  font: inherit;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere;
}
.palette-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.palette-swatch {
  display: grid;
  align-content: end;
  min-height: 132px;
  padding: 10px;
  border: 0;
  color: #fff;
  font: inherit;
  font-weight: 900;
  text-align: left;
  text-shadow: 0 1px 6px rgba(15, 23, 42, .4);
  cursor: pointer;
}
.palette-preview {
  display: grid;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
}
.palette-preview-hero {
  display: grid;
  gap: 8px;
  padding: 18px;
  border-radius: 8px;
  color: #fff;
}
.palette-preview-row {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 12px;
}
.palette-preview-box {
  min-height: 110px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.palette-preview-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  width: fit-content;
  padding: 0 14px;
  border-radius: 8px;
  color: #fff;
  font-weight: 900;
}
.gradient-preview {
  min-height: 220px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.contrast-preview {
  display: grid;
  gap: 10px;
  min-height: 190px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.contrast-badges {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}
.contrast-badge {
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-weight: 900;
}
.contrast-badge.pass {
  border-color: rgba(22, 163, 74, .28);
  background: #f0fdf4;
  color: #166534;
}
.contrast-badge.fail {
  border-color: rgba(220, 38, 38, .25);
  background: #fef2f2;
  color: #991b1b;
}
.shadow-stage {
  display: grid;
  min-height: 260px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(148, 163, 184, .12) 1px, transparent 1px),
    linear-gradient(rgba(148, 163, 184, .12) 1px, transparent 1px),
    #f8fbff;
  background-size: 22px 22px;
}
.shadow-sample {
  display: grid;
  gap: 8px;
  width: min(100%, 260px);
  min-height: 150px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.markdown-preview,
.table-preview {
  min-height: 310px;
  overflow: auto;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfdff;
}
.table-preview table {
  width: 100%;
  border-collapse: collapse;
}
.tool-data-table {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-data-table th,
.tool-data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}
.tool-data-table th {
  width: 160px;
  color: var(--muted);
  font-weight: 800;
}
.tool-data-table tr:last-child th,
.tool-data-table tr:last-child td {
  border-bottom: 0;
}
.table-preview th,
.table-preview td {
  padding: 8px 10px;
  border: 1px solid var(--line);
  text-align: left;
  white-space: nowrap;
}
.qr-preview {
  display: grid;
  min-height: 280px;
  place-items: center;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.qr-preview canvas,
.qr-preview img {
  max-width: 100%;
  height: auto;
}
.diff-preview {
  min-height: 180px;
  max-height: 420px;
  overflow: auto;
  padding: 18px;
  white-space: pre-wrap;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  line-height: 1.8;
}
.diff-add {
  color: #166534;
  background: #dcfce7;
}
.diff-del {
  color: #991b1b;
  background: #fee2e2;
  text-decoration: line-through;
}
.diff-eq {
  color: var(--text);
}
.crop-workbench {
  min-height: 320px;
  max-height: 560px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f172a;
}
.crop-workbench img {
  display: block;
  max-width: 100%;
}
.image-preview-grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
  min-height: 180px;
}
.image-preview-grid::before,
.crop-workbench::before {
  content: "选择图片后显示预览";
  display: none;
  min-height: 180px;
  place-items: center;
  border: 1px dashed #bdd4df;
  border-radius: 8px;
  background: #f8fbff;
  color: var(--muted);
  font-weight: 800;
}
.image-preview-grid:not(:has(img[src]))::before,
.crop-workbench:not(:has(img[src]))::before {
  display: grid;
  grid-column: 1 / -1;
}
.image-preview-grid:not(:has(img[src])) {
  grid-template-columns: 1fr;
}
.image-preview-grid:not(:has(img[src])) .tool-canvas {
  display: none;
}
.image-preview-grid img {
  display: block;
  max-width: 100%;
  max-height: 360px;
  object-fit: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.image-preview-grid img:not([src]),
.image-preview-grid img[src=""],
.crop-workbench img:not([src]),
.crop-workbench img[src=""] {
  display: none;
}
.tool-actions a[id="download-image"]:not([href]) {
  display: none;
}
.tool-canvas {
  display: block;
  max-width: 100%;
  max-height: 360px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}
.tool-canvas:not([width]) {
  display: none;
}
.tool-placeholder-panel {
  min-height: 260px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  padding: 30px;
  border: 1px dashed #bdd4df;
  border-radius: 8px;
  background: #f8fbff;
  text-align: center;
}
.tool-placeholder-panel strong {
  font-size: 24px;
}
.tool-placeholder-panel span {
  max-width: 520px;
  color: var(--muted);
}
.tool-output.wide {
  width: 100%;
  min-height: 220px;
  margin-top: 14px;
}
.tool-preview pre {
  margin: 0;
  padding: 14px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0f172a;
  color: #e5eef7;
  line-height: 1.65;
}
.network-tool {
  display: grid;
  gap: 18px;
}
.network-form-card {
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
}
.advanced-field {
  display: grid;
  gap: 6px;
  margin: 0 12px 12px;
  color: var(--muted);
  font-weight: 800;
}
.advanced-preview-button {
  margin: 0 12px 12px;
}
.target-area {
  min-height: 118px;
}
.options-grid {
  padding-top: 4px;
}
.tool-check,
.tool-check-group {
  min-height: 44px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.tool-check {
  display: flex;
  align-items: center;
  gap: 9px;
}
.tool-check-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.tool-check-group legend {
  padding: 0 4px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}
.tool-check-group label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}
.advanced-options,
.raw-result {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.advanced-options summary,
.raw-result summary {
  cursor: pointer;
  padding: 10px 12px;
  color: var(--primary-dark);
  font-weight: 900;
}
.advanced-options .tool-output,
.raw-result .tool-output {
  border-right: 0;
  border-bottom: 0;
  border-left: 0;
  border-radius: 0 0 8px 8px;
}
.network-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.network-summary-card {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.network-summary-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.network-summary-card strong {
  display: block;
  min-width: 0;
  margin-top: 6px;
  overflow: hidden;
  color: var(--primary-dark);
  font-size: 15px;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.network-result {
  overflow: auto;
}
.network-result-title {
  margin: 0 0 10px;
  color: var(--primary-dark);
  font-size: 16px;
}
.raw-result.compact {
  margin-top: 12px;
}
.raw-result.compact pre {
  margin: 0;
  max-height: 360px;
  overflow: auto;
  padding: 14px;
  border-top: 1px solid var(--line);
  border-radius: 0 0 8px 8px;
  background: #0f172a;
  color: #e5eef7;
  line-height: 1.65;
  white-space: pre-wrap;
}
.network-empty,
.network-loading {
  display: grid;
  gap: 4px;
  min-height: 92px;
  align-content: center;
  padding: 18px;
  border: 1px dashed #bfd4df;
  border-radius: 8px;
  background: #f8fbff;
  color: var(--muted);
}
.network-loading strong {
  color: var(--primary-dark);
  font-size: 16px;
}
.network-loading span {
  font-weight: 700;
}
.screen-test-tool,
.keyboard-test-tool {
  display: grid;
  gap: 16px;
}
.screen-toolbar,
.keyboard-status {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.screen-toolbar span,
.keyboard-status span {
  color: var(--muted);
  font-weight: 800;
}
.screen-stage {
  min-height: 360px;
  aspect-ratio: 16 / 9;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  text-align: center;
  cursor: pointer;
}
.screen-stage strong {
  font-size: 34px;
}
.screen-stage span {
  font-weight: 800;
}
.screen-color-list {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  gap: 8px;
}
.screen-color-list button {
  min-height: 42px;
  border: 2px solid var(--line);
  border-radius: 8px;
  cursor: pointer;
}
.screen-color-list button.is-active {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(34, 124, 157, .16);
}
.keyboard-ui {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fbff;
  outline: none;
  overflow-x: auto;
}
.keyboard-row {
  display: flex;
  justify-content: center;
  gap: 6px;
  min-width: max-content;
}
.keycap {
  min-width: 44px;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid #cbd5e1;
  border-radius: 7px;
  background: #fff;
  color: var(--text);
  font-weight: 900;
  box-shadow: inset 0 -3px 0 rgba(15, 23, 42, .08);
}
.keycap[data-code="Space"] {
  min-width: 220px;
}
.keycap.is-down {
  transform: translateY(2px);
  box-shadow: inset 0 2px 0 rgba(15, 23, 42, .08);
}
.keycap.is-hit {
  border-color: var(--primary);
  background: #e8f3f7;
  color: var(--primary-dark);
}
.pointer-test-tool {
  display: grid;
  gap: 16px;
}
.pointer-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.pointer-toolbar span {
  color: var(--muted);
  font-weight: 800;
}
.pointer-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}
.pointer-summary-grid > div,
.touch-list > div {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}
.pointer-summary-grid span,
.touch-list span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}
.pointer-summary-grid strong,
.touch-list strong {
  display: block;
  margin-top: 5px;
  color: var(--primary-dark);
  font-size: 15px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.pointer-pad {
  position: relative;
  min-height: 360px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 2px dashed #b7ced9;
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(34,124,157,.08) 1px, transparent 1px),
    linear-gradient(180deg, rgba(34,124,157,.08) 1px, transparent 1px),
    #f8fbff;
  background-size: 28px 28px;
  cursor: crosshair;
  user-select: none;
  touch-action: none;
  transition: border-color .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.pointer-pad:hover,
.pointer-pad.is-testing {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(34, 124, 157, .10);
}
.pointer-pad.is-testing {
  background:
    linear-gradient(90deg, rgba(34,124,157,.10) 1px, transparent 1px),
    linear-gradient(180deg, rgba(34,124,157,.10) 1px, transparent 1px),
    #ffffff;
  background-size: 28px 28px;
}
.pointer-pad canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.pointer-pad-hint {
  position: absolute;
  inset: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 6px;
  color: var(--muted);
  text-align: center;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
}
.pointer-pad.is-testing .pointer-pad-hint {
  opacity: .12;
  transform: scale(.98);
}
.pointer-pad-hint strong {
  color: var(--primary-dark);
  font-size: 24px;
}
.pointer-cursor {
  position: absolute;
  z-index: 2;
  width: 24px;
  height: 24px;
  border: 2px solid var(--primary);
  border-radius: 50%;
  background: rgba(34, 124, 157, .20);
  box-shadow: 0 0 0 6px rgba(34, 124, 157, .10);
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.pointer-button-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}
.mouse-button {
  min-height: 50px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-weight: 900;
}
.mouse-button.is-hit {
  border-color: rgba(34,124,157,.55);
  background: #e8f3f7;
  color: var(--primary-dark);
}
.mouse-button.is-active {
  transform: translateY(2px);
  background: var(--primary);
  color: #fff;
}
.touch-points {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.touch-point {
  position: absolute;
  z-index: 2;
  display: grid;
  place-items: center;
  border: 2px solid var(--primary);
  border-radius: 50%;
  background: rgba(34, 124, 157, .22);
  color: var(--primary-dark);
  font-size: 12px;
  font-weight: 900;
  box-shadow: 0 0 0 7px rgba(34, 124, 157, .10);
  transform: translate(-50%, -50%);
}
.touch-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 960px) {
  .hero-grid, .home-top, .home-tabs, .split, .faq-grid, .docs-layout, .contact-grid, .feedback-layout, .article-list-layout, .article-page-layout, .footer-grid, .tool-shell, .tool-detail-layout, .tool-panel-grid, .tool-live-panel, .timestamp-one-screen, .compact-live, .color-tool-layout { grid-template-columns: 1fr; }
  .timestamp-input-zone { padding-right: 0; border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 14px; }
  .tool-shell { min-height: 0; }
  .tool-rail { position: static; padding: 18px; border-right: 0; border-bottom: 1px solid var(--line); }
  .tool-root-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tool-workspace { padding: 24px 18px 34px; }
  .tool-card-grid, .tool-card-grid.category-page { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tool-subnav { position: static; max-height: none; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tool-subnav-title { grid-column: 1 / -1; }
  .network-summary-grid, .pointer-summary-grid, .pointer-button-grid, .touch-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-slider { min-height: 240px; }
  .catalog-head, .catalog-group-head { align-items: start; flex-direction: column; }
  .catalog-group-head p { text-align: left; }
  .home-tab-list { position: static; display: flex; overflow-x: auto; padding-bottom: 4px; }
  .home-tab { min-width: 150px; }
  .book-grid, .book-grid.in-list, .book-grid.root-list, .book-grid.home-tab-books, .chapter-grid { grid-template-columns: repeat(2, 1fr); }
  .stats-grid, .process-grid { grid-template-columns: repeat(2, 1fr); }
  .book-sidebar { position: static; max-height: none; }
  .doc-toc-panel, .article-list-sidebar { position: static; max-height: none; }
  .footer-bottom { align-items: flex-start; flex-direction: column; }
  h1 { font-size: 34px; }
}

@media (max-width: 680px) {
  .container { width: min(100% - 24px, 1180px); }
  .section { padding: 38px 0; }
  .nav-toggle { display: block; }
  .nav-wrap { flex-wrap: wrap; }
  .nav-menu { display: none; width: 100%; justify-content: flex-start; padding-bottom: 12px; }
  .nav-menu.is-open { display: flex; }
  .nav-menu a { width: 100%; }
  .tool-root-list, .tool-card-grid, .tool-card-grid.category-page, .tool-subnav { grid-template-columns: 1fr; }
  .tool-rail-head h1, .tool-rail-head.compact h1 { font-size: 25px; }
  .tool-workspace-head, .tool-category-head { align-items: start; flex-direction: column; }
  .tool-io-grid, .tool-form-grid, .timestamp-result-grid, .tool-status-grid { grid-template-columns: 1fr; }
  .color-value-grid, .palette-preview-row, .contrast-badges { grid-template-columns: 1fr; }
  .palette-strip { grid-template-columns: 1fr; }
  .palette-swatch { min-height: 64px; }
  .network-summary-grid { grid-template-columns: 1fr; }
  .pointer-summary-grid, .pointer-button-grid, .touch-list { grid-template-columns: 1fr; }
  .screen-stage, .pointer-pad { min-height: 260px; aspect-ratio: auto; }
  .screen-color-list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .tool-detail { min-height: 0; padding: 22px; }
  .tool-detail-head h1, .tool-detail-head h2, .tool-workspace-head h2 { font-size: 25px; }
  .page-banner-inner { min-height: 128px; }
  .page-banner h1 { font-size: 27px; }
  .hero { padding-top: 34px; }
  .home-slide span { left: 18px; right: 18px; bottom: 18px; }
  .home-slide strong { font-size: 21px; }
  .group-head { align-items: start; flex-direction: column; }
  h1 { font-size: 29px; }
  h2 { font-size: 24px; }
  .book-grid, .book-grid.in-list, .book-grid.root-list, .book-grid.home-tab-books, .chapter-grid, .feature-grid, .stats-grid, .process-grid, .related-grid { grid-template-columns: 1fr; }
  .reader { padding: 22px; }
  .docs-detail-layout .doc-toc-panel { display: none; }
  .docs-detail-layout .book-sidebar { padding: 12px; overflow: visible; }
  .docs-detail-layout .book-sidebar-toggle { display: block; }
  .docs-detail-layout .book-sidebar .sidebar-title, .docs-detail-layout .book-sidebar .book-group { display: none; }
  .docs-detail-layout .book-sidebar.is-open .sidebar-title, .docs-detail-layout .book-sidebar.is-open .book-group { display: block; }
  .chapter-row { grid-template-columns: 1fr; }
  .book-chapter-link { grid-template-columns: 1fr; }
  .book-chapter-link small { white-space: normal; }
  .message-form { grid-template-columns: 1fr; }
  .prev-next { grid-template-columns: 1fr; }
}
