/* ============================================================ LemonBoss PRD/SDD doc site — global styles ============================================================ */ :root { --bg: #fafaf7; --bg-2: #ffffff; --bg-3: #f3f3ee; --fg: #1d1d1f; --fg-2: #5a5a60; --fg-3: #8a8a92; --border: #e3e3dd; --border-2: #d4d4cd; --accent: #f5a524; /* lemon */ --accent-2: #e69500; --accent-soft: #fff4dc; --link: #0a66c2; --code-bg: #f5f5ef; --code-fg: #2d2d33; --shadow: 0 1px 2px rgba(0,0,0,.04), 0 4px 12px rgba(0,0,0,.04); --shadow-lg: 0 12px 32px rgba(0,0,0,.08); --radius: 8px; --radius-sm: 4px; --side-w: 280px; --top-h: 52px; --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Roboto Mono", monospace; --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Helvetica, Arial, sans-serif; } [data-theme="dark"] { --bg: #16161a; --bg-2: #1d1d22; --bg-3: #25252b; --fg: #e8e8ea; --fg-2: #b0b0b8; --fg-3: #76767e; --border: #2d2d34; --border-2: #3a3a42; --accent: #f5a524; --accent-2: #ffbe3d; --accent-soft: #3a2f15; --link: #6db4ff; --code-bg: #25252b; --code-fg: #e6e6e8; --shadow: 0 1px 2px rgba(0,0,0,.4), 0 4px 12px rgba(0,0,0,.3); --shadow-lg: 0 12px 32px rgba(0,0,0,.6); } * { box-sizing: border-box; } html, body { margin: 0; padding: 0; height: 100%; font-family: var(--sans); font-size: 14px; background: var(--bg); color: var(--fg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } a { color: var(--link); text-decoration: none; } a:hover { text-decoration: underline; } button { background: none; border: none; color: inherit; font: inherit; cursor: pointer; } /* ─── Topbar ─── */ .topbar { position: fixed; top: 0; left: 0; right: 0; height: var(--top-h); background: var(--bg-2); border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 12px; padding: 0 16px; z-index: 50; } .burger { display: none; padding: 6px; border-radius: var(--radius-sm); color: var(--fg-2); } .burger:hover { background: var(--bg-3); color: var(--fg); } .brand { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--fg); flex-shrink: 0; } .brand .lemon { font-size: 20px; } .brand .title { font-size: 15px; } .brand .subtitle { font-size: 12px; font-weight: 400; color: var(--fg-3); margin-left: 6px; padding-left: 10px; border-left: 1px solid var(--border); } .search-wrap { flex: 1; max-width: 520px; margin: 0 auto; position: relative; } .search-wrap input { width: 100%; height: 32px; padding: 0 36px 0 12px; border: 1px solid var(--border); background: var(--bg); border-radius: var(--radius-sm); color: var(--fg); font-family: var(--sans); outline: none; transition: border-color .15s, box-shadow .15s; } .search-wrap input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); } .kbd { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); font-family: var(--mono); font-size: 11px; color: var(--fg-3); background: var(--bg-3); border: 1px solid var(--border); border-radius: 3px; padding: 1px 5px; pointer-events: none; } .theme-toggle { padding: 6px; border-radius: var(--radius-sm); color: var(--fg-2); } .theme-toggle:hover { background: var(--bg-3); color: var(--fg); } .theme-toggle .ico-moon { display: none; } [data-theme="dark"] .theme-toggle .ico-sun { display: none; } [data-theme="dark"] .theme-toggle .ico-moon { display: block; } /* ─── Layout ─── */ .layout { position: fixed; top: var(--top-h); left: 0; right: 0; bottom: 0; display: flex; } /* ─── Sidebar ─── */ .sidebar { width: var(--side-w); background: var(--bg-2); border-right: 1px solid var(--border); overflow-y: auto; overflow-x: hidden; flex-shrink: 0; } .sidebar::-webkit-scrollbar { width: 8px; } .sidebar::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 4px; } .menu { padding: 8px 0; } .menu-chapter { margin-bottom: 2px; } .menu-chapter > .menu-link { font-weight: 600; color: var(--fg); } .menu-section > .menu-link { font-weight: 500; color: var(--fg-2); padding-left: 28px; } .menu-sub > .menu-link { font-weight: 400; color: var(--fg-3); padding-left: 44px; font-size: 13px; } .menu-link { display: flex; align-items: center; gap: 6px; padding: 6px 12px; cursor: pointer; text-decoration: none; user-select: none; border-radius: 4px; margin: 1px 6px; transition: background .12s; line-height: 1.4; } .menu-link:hover { background: var(--bg-3); text-decoration: none; } .menu-link.active { background: var(--accent-soft); color: var(--accent-2); font-weight: 600; } [data-theme="dark"] .menu-link.active { color: var(--accent); } .caret { width: 12px; text-align: center; font-size: 10px; color: var(--fg-3); flex-shrink: 0; transition: transform .15s; } .menu-chapter.collapsed > .menu-link .caret, .menu-section.collapsed > .menu-link .caret { transform: rotate(-90deg); } .menu-chapter > .children, .menu-section > .children { overflow: hidden; max-height: 4000px; transition: max-height .2s ease-out; } .menu-chapter.collapsed > .children, .menu-section.collapsed > .children { max-height: 0; } .menu-num { font-family: var(--mono); font-size: 11px; color: var(--fg-3); margin-right: 4px; flex-shrink: 0; } .menu-link.active .menu-num { color: var(--accent-2); } /* ─── Content ─── */ .content { flex: 1; display: flex; flex-direction: column; background: var(--bg); min-width: 0; } .tabs { height: 36px; display: flex; border-bottom: 1px solid var(--border); background: var(--bg-2); padding: 0 12px; gap: 4px; flex-shrink: 0; } .tab { padding: 0 14px; height: 100%; display: flex; align-items: center; gap: 6px; border-bottom: 2px solid transparent; color: var(--fg-2); font-size: 13px; transition: color .12s, border-color .12s; } .tab:hover { color: var(--fg); } .tab.active { color: var(--accent-2); border-bottom-color: var(--accent); font-weight: 500; } [data-theme="dark"] .tab.active { color: var(--accent); } .tab .badge { background: var(--bg-3); color: var(--fg-3); font-size: 11px; padding: 1px 6px; border-radius: 9px; font-family: var(--mono); } .tab.active .badge { background: var(--accent); color: #fff; } .pane { display: none; flex: 1; overflow: hidden; } .pane.active { display: flex; flex-direction: column; } .pane-reader iframe { flex: 1; width: 100%; border: none; background: var(--bg); } /* ─── Search results pane ─── */ .search-header { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; border-bottom: 1px solid var(--border); background: var(--bg-2); color: var(--fg-2); font-size: 13px; } .clear-btn { padding: 4px 10px; border-radius: var(--radius-sm); border: 1px solid var(--border); color: var(--fg-2); font-size: 12px; } .clear-btn:hover { background: var(--bg-3); color: var(--fg); } .results { list-style: none; margin: 0; padding: 8px 0; overflow-y: auto; flex: 1; } .result-item { padding: 10px 20px; border-bottom: 1px solid var(--border); cursor: pointer; transition: background .1s; } .result-item:hover { background: var(--bg-3); } .result-path { font-size: 11px; color: var(--fg-3); font-family: var(--mono); margin-bottom: 4px; } .result-title { font-size: 14px; font-weight: 600; color: var(--fg); margin-bottom: 4px; } .result-snippet { font-size: 12px; color: var(--fg-2); line-height: 1.5; } .result-snippet mark { background: var(--accent-soft); color: var(--accent-2); padding: 0 2px; border-radius: 2px; font-weight: 600; } [data-theme="dark"] .result-snippet mark { color: var(--accent); } /* ─── Responsive ─── */ @media (max-width: 768px) { .burger { display: flex; } .brand .subtitle { display: none; } .sidebar { position: fixed; left: 0; top: var(--top-h); bottom: 0; z-index: 40; transform: translateX(-100%); transition: transform .2s; box-shadow: var(--shadow-lg); } body.sidebar-open .sidebar { transform: translateX(0); } .search-wrap { max-width: none; } }