/* ==========================================================================
   ReputeCo — site.css
   Industrial B2B theme: deep navy + steel grey + white.
   Tailwind v3 (Play CDN, vendored) handles layout utilities; this file only
   defines component classes that Tailwind preflight cannot override.
   ========================================================================== */

:root {
  --navy-950: #081524;
  --navy-900: #0f1f33;
  --navy-800: #1d2e45;
  --accent-600: #1769e0;
  --steel-50: #f6f8fa;
  --steel-200: #e2e8f0;
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: clip; }

body {
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  color: #1e293b;
  background: #ffffff;
  -webkit-font-smoothing: antialiased;
}

::selection { background: #1769e0; color: #fff; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: .75rem 1.25rem;
  border-radius: .375rem;
  font-size: .875rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: .01em;
  border: 1px solid transparent;
  transition: background-color .15s ease, color .15s ease, border-color .15s ease;
  text-decoration: none;
  cursor: pointer;
}
.btn-primary { background: var(--navy-900); color: #fff; }
.btn-primary:hover { background: var(--navy-800); }
.btn-accent { background: var(--accent-600); color: #fff; }
.btn-accent:hover { background: #0f52b8; }
.btn-outline { background: #fff; color: var(--navy-900); border-color: #cbd5e1; }
.btn-outline:hover { border-color: var(--navy-900); background: #f8fafc; }
.btn-ghost-light { background: rgba(255,255,255,.08); color: #fff; border-color: rgba(255,255,255,.35); }
.btn-ghost-light:hover { background: rgba(255,255,255,.16); }
.btn-sm { padding: .5rem .875rem; font-size: .8125rem; }

/* ---------- Typography helpers ---------- */
.eyebrow {
  display: inline-block;
  font-size: .6875rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--accent-600);
}
.h-display {
  font-weight: 700;
  letter-spacing: -.02em;
  line-height: 1.08;
}
html[lang="zh-CN"] .h-display { letter-spacing: 0; line-height: 1.24; }
.prose-lead { font-size: 1.0625rem; line-height: 1.7; color: #475569; }

/* ---------- Cards ---------- */
.card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: .5rem;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.card-hover:hover { border-color: #b9c6d6; box-shadow: 0 8px 24px -12px rgba(15, 31, 51, .28); }
.card-media { aspect-ratio: 4 / 3; background: #f1f5f9; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Spec table ---------- */
.spec-table { width: 100%; border-collapse: collapse; font-size: .8125rem; }
.spec-table th, .spec-table td {
  padding: .625rem .75rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: top;
}
.spec-table tbody th { width: 40%; font-weight: 600; color: #334155; background: #f8fafc; }
.spec-table td { color: #0f1f33; font-variant-numeric: tabular-nums; }
.spec-table thead th {
  background: var(--navy-900);
  color: #fff;
  font-weight: 600;
  white-space: nowrap;
  border-bottom: 0;
}
.spec-table thead th:first-child { border-top-left-radius: .25rem; }
.spec-table thead th:last-child { border-top-right-radius: .25rem; }
.spec-table tr:last-child th, .spec-table tr:last-child td { border-bottom: 0; }

/* ---------- Article body ---------- */
.prose-b2b { color: #334155; font-size: 1.0625rem; line-height: 1.75; }
.prose-b2b > * + * { margin-top: 1.15rem; }
/* Grid children must be allowed to shrink below their min-content width,
   otherwise a wide table can push the whole page wider than the viewport. */
.grid > * { min-width: 0; }
.prose-b2b h2 {
  font-size: 1.5rem;
  line-height: 1.3;
  font-weight: 700;
  color: var(--navy-900);
  letter-spacing: -.01em;
  margin-top: 2.75rem;
  padding-top: .25rem;
  scroll-margin-top: 6rem;
}
.prose-b2b h2:first-child { margin-top: 0; }
.prose-b2b h3 {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--navy-900);
  margin-top: 1.9rem;
  scroll-margin-top: 6rem;
}
.prose-b2b p { margin-bottom: 0; }
.prose-b2b a { color: #0f52b8; text-decoration: underline; text-underline-offset: 2px; }
.prose-b2b a:hover { color: var(--accent-600); }
.prose-b2b strong { color: var(--navy-900); font-weight: 600; }
.prose-b2b ul, .prose-b2b ol { padding-left: 1.25rem; }
.prose-b2b ul { list-style: disc; }
.prose-b2b ol { list-style: decimal; }
.prose-b2b li { margin-top: .4rem; padding-left: .25rem; }
.prose-b2b li::marker { color: #1769e0; }
.prose-b2b img { width: 100%; height: auto; border-radius: .375rem; border: 1px solid #e2e8f0; }
.prose-b2b blockquote {
  border-left: 3px solid var(--accent-600);
  background: #f6f8fa;
  padding: 1rem 1.25rem;
  color: #1e293b;
  font-size: 1rem;
}
.prose-b2b table {
  width: 100%;
  border-collapse: collapse;
  font-size: .875rem;
  border: 1px solid #e2e8f0;
}
.prose-b2b thead th {
  background: var(--navy-900);
  color: #fff;
  font-weight: 600;
  text-align: left;
  padding: .625rem .875rem;
  white-space: nowrap;
}
.prose-b2b tbody td {
  padding: .625rem .875rem;
  border-top: 1px solid #e2e8f0;
  vertical-align: top;
}
.prose-b2b tbody tr:nth-child(even) { background: #f8fafc; }
.figure-caption { font-size: .8125rem; color: #64748b; margin-top: .5rem; }

/* ---------- Table of contents ---------- */
.toc { border: 1px solid #e2e8f0; border-radius: .5rem; background: #f8fafc; }
.toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.toc li { counter-increment: toc; font-size: .875rem; padding: .35rem 0 .35rem 1.75rem; position: relative; }
.toc li::before {
  content: counter(toc, decimal-leading-zero);
  position: absolute; left: 0; top: .35rem;
  font-size: .6875rem; font-weight: 700; color: #94a3b8;
  font-variant-numeric: tabular-nums;
}
.toc a { color: #334155; text-decoration: none; }
.toc a:hover { color: var(--accent-600); text-decoration: underline; }

/* ---------- FAQ ---------- */
.faq-item { border-bottom: 1px solid #e2e8f0; }
.faq-item > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 0;
  font-weight: 600;
  color: var(--navy-900);
  font-size: 1rem;
}
.faq-item > summary::-webkit-details-marker { display: none; }
.faq-item > summary .faq-icon {
  flex: 0 0 auto;
  width: 1.25rem; height: 1.25rem;
  margin-top: .2rem;
  color: #64748b;
  transition: transform .15s ease;
}
.faq-item[open] > summary .faq-icon { transform: rotate(45deg); color: var(--accent-600); }
.faq-item .faq-a { padding: 0 0 1.25rem; color: #475569; font-size: .9375rem; line-height: 1.7; }
.faq-item .faq-a a { color: #0f52b8; text-decoration: underline; }

/* ---------- Search overlay ---------- */
.search-backdrop { background: rgba(8, 21, 36, .62); backdrop-filter: blur(2px); }
.search-hit { display: block; padding: .75rem .875rem; border-radius: .375rem; }
.search-hit:hover, .search-hit.is-active { background: #f1f5f9; }
.search-hit mark { background: #fde68a; color: inherit; padding: 0 .1em; }

/* ---------- Header ---------- */
.nav-link { font-size: .875rem; font-weight: 500; color: #334155; padding: .5rem .75rem; border-radius: .25rem; }
.nav-link:hover { color: var(--navy-900); background: #f1f5f9; }
.nav-link[aria-current="page"] { color: var(--navy-900); font-weight: 600; }
.dropdown-panel {
  box-shadow: 0 18px 40px -18px rgba(15, 31, 51, .35);
  border: 1px solid #e2e8f0;
  border-radius: .5rem;
  background: #fff;
}

/* ---------- Utility ---------- */
.hairline { border-top: 1px solid #e2e8f0; }
.grid-lines {
  background-image: linear-gradient(to right, rgba(255,255,255,.06) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,.06) 1px, transparent 1px);
  background-size: 56px 56px;
}
.hero-photo { object-fit: cover; width: 100%; height: 100%; }
.tabular { font-variant-numeric: tabular-nums; }

@media (max-width: 640px) {
  .prose-b2b { font-size: 1rem; }
  .prose-b2b h2 { font-size: 1.3rem; margin-top: 2.1rem; }
  .prose-b2b thead th { white-space: normal; }
}

@media print {
  header, footer, .no-print { display: none !important; }
  .prose-b2b { font-size: 11pt; }
}
