/* Peakstar Docs：安靜的文件主題。品牌色只用在連結、目前頁、少量強調。 */
:root {
  --ink: #0f1719;
  --ink-2: #384a4d;
  --ink-3: #6b8083;
  --brand-ink: #22577a;
  --brand: #2e8c8c;
  --brand-soft: #ecf6f4;
  --paper: #ffffff;
  --paper-2: #f6f8f8;
  --line: #e4ecec;
  --warn-bg: #fff7e8;
  --warn-ink: #8a5a10;
  --note-bg: #eef4fb;
  --note-ink: #23486d;
  --radius: 10px;
  --shadow: 0 8px 24px -8px rgba(15, 40, 50, .12);
  --sidebar: 268px;
  --content: 820px;
  --font-body: 'Inter', 'Noto Sans TC', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Manrope', 'Noto Sans TC', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.75; letter-spacing: 0; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
img { max-width: 100%; height: auto; display: block; }
code, kbd { font-family: var(--font-mono); font-size: .92em; background: var(--paper-2); border: 1px solid var(--line); border-radius: 5px; padding: .08em .4em; }
kbd { border-bottom-width: 2px; }
pre { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; overflow: auto; font-size: .9em; line-height: 1.6; }
pre code { border: 0; background: transparent; padding: 0; }
table { border-collapse: collapse; width: 100%; margin: 18px 0 24px; font-size: .95em; }
th, td { text-align: left; vertical-align: top; padding: 9px 12px; border-bottom: 1px solid var(--line); }
th { background: var(--paper-2); font-weight: 600; color: var(--ink-2); }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--ink); line-height: 1.3; margin: 0; }
h1 { font-size: 30px; font-weight: 700; letter-spacing: -0.01em; margin-bottom: 6px; }
h2 { font-size: 22px; font-weight: 700; margin-top: 44px; padding-top: 24px; border-top: 1px solid var(--line); }
h2:first-of-type { border-top: 0; padding-top: 0; }
h3 { font-size: 18px; font-weight: 600; margin-top: 30px; }
h4 { font-size: 16px; font-weight: 600; margin-top: 22px; color: var(--ink-2); }
p { margin: 12px 0; }
ul, ol { padding-left: 1.4em; margin: 12px 0; }
li { margin: 4px 0; }
li > ul, li > ol { margin: 4px 0; }
hr { border: 0; border-top: 1px solid var(--line); margin: 32px 0; }
.eyebrow { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); font-weight: 600; margin-bottom: 8px; }
.lead { font-size: 17px; color: var(--ink-2); margin-top: 8px; }

/* 版面 */
.topbar { position: sticky; top: 0; z-index: 30; display: flex; align-items: center; gap: 14px; height: 56px; padding: 0 20px; background: rgba(255,255,255,.92); backdrop-filter: saturate(160%) blur(8px); border-bottom: 1px solid var(--line); }
.topbar .brand { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-weight: 700; color: var(--ink); white-space: nowrap; }
.topbar .brand img { height: 26px; width: 26px; }
.topbar .brand span.docs { color: var(--ink-3); font-weight: 500; }
.topbar .product { color: var(--ink-3); font-size: 14px; }
.topbar .product::before { content: '/'; margin: 0 8px; color: var(--line); }
.topbar .spacer { flex: 1; }
.topbar .site-link { font-size: 14px; color: var(--ink-2); }
.topbar .menu-btn { display: none; border: 1px solid var(--line); background: var(--paper); border-radius: 8px; padding: 6px 10px; font: inherit; font-size: 14px; }
.layout { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: calc(100vh - 56px); background: linear-gradient(to right, var(--paper-2) var(--sidebar), var(--paper) var(--sidebar)); }
.sidebar { border-right: 1px solid var(--line); background: var(--paper-2); padding: 22px 16px 40px; position: sticky; top: 56px; height: calc(100vh - 56px); overflow: auto; }
.sidebar .group { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); font-weight: 600; margin: 18px 8px 6px; }
.sidebar .group:first-child { margin-top: 0; }
.sidebar a.item { display: block; padding: 7px 10px; border-radius: 7px; color: var(--ink-2); font-size: 14.5px; }
.sidebar a.item:hover { background: #eef2f2; text-decoration: none; }
.sidebar a.item.current { background: var(--brand-soft); color: var(--brand-ink); font-weight: 600; }
.sidebar a.sub { padding-left: 22px; font-size: 13.5px; color: var(--ink-3); }
main { padding: 36px 48px 80px; }
.content { max-width: var(--content); }
.breadcrumb { font-size: 13px; color: var(--ink-3); margin-bottom: 18px; }
.breadcrumb a { color: var(--ink-3); }
.breadcrumb span { margin: 0 6px; }

/* 圖 */
figure { margin: 22px 0 28px; }
figure img { border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
figure.phone { display: flex; gap: 20px; align-items: flex-start; flex-wrap: wrap; }
figure.phone img { width: 280px; }
figcaption { font-size: 13.5px; color: var(--ink-3); margin-top: 8px; }
.two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.two-up figure { margin: 0; }

/* 提示框 */
.callout { border-left: 3px solid var(--brand); background: var(--brand-soft); padding: 12px 16px; border-radius: 0 var(--radius) var(--radius) 0; margin: 18px 0; font-size: .96em; }
.callout.warn { border-color: #d99530; background: var(--warn-bg); color: var(--warn-ink); }
.callout.note { border-color: #3885b5; background: var(--note-bg); color: var(--note-ink); }
.callout strong { font-weight: 600; }
.steps { counter-reset: step; list-style: none; padding-left: 0; }
.steps > li { counter-increment: step; position: relative; padding-left: 40px; margin: 12px 0; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: 2px; width: 26px; height: 26px; border-radius: 50%; background: var(--brand-ink); color: #fff; font-size: 13px; font-weight: 600; display: flex; align-items: center; justify-content: center; }
.tag { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 999px; background: var(--paper-2); border: 1px solid var(--line); color: var(--ink-2); margin-right: 4px; }
.tag.role { background: #eef4fb; border-color: #cfe0f3; color: #23486d; }
.tag.pack-design { background: #eef2f8; border-color: #cbd6ea; color: #1f3a5f; }
.tag.pack-fire { background: #faf0ee; border-color: #ecc9c3; color: #8c2d24; }
.tag.pack-law { background: #efeff6; border-color: #cfcfe4; color: #2b2b50; }

/* 入口卡片 */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 18px; margin: 24px 0; }
.card { display: block; background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 20px 22px; box-shadow: var(--shadow); color: inherit; }
.card:hover { text-decoration: none; border-color: #cfe0dd; }
.card h3 { margin: 0 0 6px; font-size: 17px; }
.card p { margin: 0; color: var(--ink-3); font-size: 14.5px; }
.card .soon { color: var(--ink-3); font-size: 12px; font-family: var(--font-mono); }
.card.muted { opacity: .65; box-shadow: none; }

/* 頁尾與翻頁 */
.pager { display: flex; justify-content: space-between; gap: 16px; margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 14.5px; }
.pager a { padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; color: var(--ink-2); }
.pager a:hover { text-decoration: none; border-color: var(--brand); color: var(--brand-ink); }
.pager .next { margin-left: auto; }
footer.site { border-top: 1px solid var(--line); color: var(--ink-3); font-size: 13px; padding: 20px 48px; }
.toc { float: right; width: 220px; margin: 0 0 16px 24px; font-size: 13.5px; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; background: var(--paper-2); }
.toc strong { display: block; margin-bottom: 6px; color: var(--ink-2); }
.toc a { display: block; padding: 2px 0; color: var(--ink-2); }

@media (max-width: 1100px) { .toc { float: none; width: auto; margin: 16px 0; } }
@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; background: var(--paper); }
  .sidebar { display: none; position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar.open { display: block; }
  .topbar .menu-btn { display: inline-block; }
  .topbar .product { display: none; }
  main { padding: 24px 16px 60px; }
  .two-up { grid-template-columns: 1fr; }
  footer.site { padding: 20px 16px; }
  h1 { font-size: 26px; }
}
@media print {
  .topbar, .sidebar, .pager, .menu-btn { display: none !important; }
  .layout { grid-template-columns: 1fr; }
  main { padding: 0; }
  figure img { box-shadow: none; }
}
