study-lab/styles.css
styles.cssRaw
1:root {
2 --ink: #18201d;
3 --muted: #69716d;
4 --paper: #f8f7f2;
5 --panel: #eeeee7;
6 --card: #fff;
7 --line: #d9d9d0;
8 --sage: #8ba397;
9 --sage-dark: #4f6d60;
10 --orange: #e98557;
11 --shadow: 0 18px 50px rgba(30, 39, 35, .12);
12 --map-width: 340px;
13 color-scheme: light;
14}
15
16:root[data-theme="dark"] {
17 --ink: #e8ece9;
18 --muted: #9da7a2;
19 --paper: #151a18;
20 --panel: #1b211e;
21 --card: #222925;
22 --line: #343c38;
23 --sage: #89a99a;
24 --sage-dark: #a6c9b8;
25 --orange: #ef986d;
26 --shadow: 0 18px 54px rgba(0, 0, 0, .42);
27 color-scheme: dark;
28}
29
30* { box-sizing: border-box; }
31html { height: 100%; background: var(--paper); }
32body {
33 margin: 0;
34 min-height: 100%;
35 color: var(--ink);
36 background: var(--paper);
37 font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
38 text-rendering: optimizeLegibility;
39}
40button, textarea, input, select { font: inherit; }
41button { color: inherit; }
42
43.topbar {
44 height: 68px;
45 padding: 0 22px;
46 display: flex;
47 align-items: center;
48 justify-content: space-between;
49 border-bottom: 1px solid var(--line);
50 background: rgba(248, 247, 242, .92);
51 backdrop-filter: blur(12px);
52 position: fixed;
53 inset: 0 0 auto 0;
54 z-index: 20;
55}
56.brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-weight: 760; letter-spacing: -.02em; }
57.brand-mark { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50% 48% 44% 52%; background: var(--ink); color: white; font-family: Georgia, serif; font-style: italic; }
58.top-actions { display: flex; align-items: center; gap: 8px; }
59.theme-toggle { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid var(--line); border-radius: 50%; background: transparent; cursor: pointer; font-size: 1rem; transition: transform .18s, background .18s; }
60.theme-toggle:hover { background: var(--card); transform: rotate(8deg); }
61.button { border: 1px solid transparent; border-radius: 999px; padding: 9px 15px; cursor: pointer; font-weight: 650; font-size: .86rem; transition: transform .15s, background .15s; }
62.button:hover { transform: translateY(-1px); }
63.button-dark { background: var(--ink); color: white; }
64.button-dark:hover { background: #2b3631; }
65.button-ghost { background: transparent; border-color: var(--line); }
66.button-ghost:hover { background: #fff; }
67.status-dot { display: inline-block; width: 7px; height: 7px; margin-right: 6px; border-radius: 50%; background: #a8aca9; }
68.status-dot.ready { background: #78ad80; box-shadow: 0 0 0 3px rgba(120, 173, 128, .15); }
69
70.app-shell { padding-top: 68px; min-height: 100vh; }
71.workspace { min-height: calc(100vh - 68px); margin-right: var(--map-width); position: relative; display: flex; flex-direction: column; }
72.welcome { width: min(820px, calc(100% - 48px)); margin: auto; padding: 64px 0 180px; text-align: center; }
73.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: .67rem; font-weight: 800; color: var(--sage-dark); }
74.welcome h1 { margin: 18px 0; font-family: Georgia, "Times New Roman", serif; font-size: clamp(3rem, 6vw, 5.8rem); line-height: .93; font-weight: 400; letter-spacing: -.055em; }
75.welcome h1 em { color: var(--sage-dark); font-weight: 400; }
76.welcome > p { color: var(--muted); max-width: 570px; margin: 0 auto 34px; line-height: 1.65; }
77.starter-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; text-align: left; }
78.starter { border: 1px solid var(--line); background: rgba(255,255,255,.58); padding: 18px; min-height: 120px; border-radius: 15px; cursor: pointer; display: grid; grid-template-columns: 32px 1fr; grid-template-rows: auto auto; column-gap: 10px; text-align: left; transition: border .15s, transform .15s, background .15s; }
79.starter:hover { border-color: var(--sage); transform: translateY(-2px); background: white; }
80.starter-icon { grid-row: 1 / span 2; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: #e4ebe7; color: var(--sage-dark); }
81.starter strong { align-self: end; font-size: .86rem; }
82.starter small { color: var(--muted); line-height: 1.4; }
83
84.conversation { width: min(850px, calc(100% - 50px)); margin: 0 auto; padding: 54px 0 220px; }
85.message { content-visibility: auto; contain-intrinsic-size: auto 220px; margin-bottom: 34px; }
86.question-row { display: flex; justify-content: flex-end; }
87.question-bubble { max-width: min(680px, 88%); background: #e7ebe7; padding: 13px 17px; border-radius: 18px 18px 5px 18px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; }
88.answer { margin-top: 22px; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 13px; }
89.answer-mark { display: grid; place-items: center; align-self: start; width: 29px; height: 29px; border-radius: 9px; background: var(--ink); color: white; font-family: Georgia, serif; font-style: italic; font-size: .85rem; }
90.answer-body { min-width: 0; line-height: 1.72; font-size: .98rem; overflow-wrap: anywhere; }
91.answer-body > :first-child { margin-top: 1px; }
92.answer-body > :last-child { margin-bottom: 0; }
93.answer-body h1, .answer-body h2, .answer-body h3 { font-family: Georgia, serif; line-height: 1.25; margin: 1.5em 0 .55em; }
94.answer-body h1 { font-size: 1.55rem; } .answer-body h2 { font-size: 1.3rem; } .answer-body h3 { font-size: 1.12rem; }
95.answer-body p { margin: 0 0 1em; }
96.answer-body ul, .answer-body ol { padding-left: 1.35em; }
97.answer-body li { margin: .35em 0; }
98.answer-body code { font-family: "SFMono-Regular", Consolas, monospace; background: #eaeae4; border-radius: 5px; padding: .12em .34em; font-size: .88em; }
99.answer-body pre { overflow: auto; padding: 15px; background: #202724; color: #f3f5f2; border-radius: 12px; line-height: 1.5; tab-size: 2; }
100.answer-body pre code { background: none; padding: 0; font-size: .84rem; }
101.answer-body blockquote { border-left: 3px solid var(--sage); margin-left: 0; padding-left: 15px; color: var(--muted); }
102.answer-body a { color: var(--sage-dark); text-underline-offset: 3px; }
103.answer-body .katex-display { overflow-x: auto; overflow-y: hidden; padding: 5px 0; }
104.answer-actions { display: flex; gap: 4px; margin: 12px 0 0 43px; opacity: .58; }
105.mini-action { border: 0; background: transparent; border-radius: 7px; padding: 5px 8px; cursor: pointer; color: var(--muted); font-size: .75rem; }
106.mini-action:hover { background: #e9e9e2; color: var(--ink); }
107.thinking { display: inline-flex; gap: 5px; padding-top: 6px; }
108.thinking i { width: 6px; height: 6px; border-radius: 50%; background: var(--sage); animation: pulse 1.1s infinite; }
109.thinking i:nth-child(2) { animation-delay: .16s; }.thinking i:nth-child(3) { animation-delay: .32s; }
110@keyframes pulse { 0%, 70%, 100% { opacity: .25; transform: translateY(0); } 35% { opacity: 1; transform: translateY(-3px); } }
111.error-text { color: #a33f36; background: #f8e7e3; border-radius: 9px; padding: 10px 12px; }
112
113.composer-wrap { position: fixed; bottom: 0; left: 0; right: var(--map-width); z-index: 10; padding: 22px max(24px, calc((100% - var(--map-width) - 850px) / 2)) 12px; background: linear-gradient(transparent, var(--paper) 22%, var(--paper)); }
114.composer { max-width: 850px; margin: 0 auto; padding: 11px 12px 9px 17px; border: 1px solid #cfd2cc; border-radius: 18px; background: white; box-shadow: 0 9px 32px rgba(34,43,39,.09); }
115.composer:focus-within { border-color: var(--sage-dark); box-shadow: 0 0 0 3px rgba(79,109,96,.1), 0 9px 32px rgba(34,43,39,.09); }
116.composer textarea { display: block; width: 100%; max-height: 180px; resize: none; border: 0; outline: 0; background: transparent; line-height: 1.5; padding: 2px 5px 8px 0; }
117.composer-footer { display: flex; justify-content: space-between; align-items: center; }
118.hint { font-size: .68rem; color: #8b918e; }
119kbd { font-family: inherit; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; padding: 1px 4px; background: #fafafa; }
120.send { border: 0; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; background: var(--ink); color: white; cursor: pointer; font-size: 1.15rem; }
121.send:disabled { opacity: .35; cursor: default; }
122.privacy-note { max-width: 850px; margin: 7px auto 0; text-align: center; color: #8b918e; font-size: .66rem; }
123.branch-context { max-width: 850px; margin: 0 auto 7px; padding: 7px 11px; border: 1px solid #cfd9d2; border-radius: 10px; background: #edf2ee; color: var(--sage-dark); display: flex; justify-content: space-between; font-size: .75rem; }
124.branch-context[hidden] { display: none; }
125.branch-context strong { display: inline-block; max-width: 48ch; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; white-space: nowrap; }
126.branch-context button { border: 0; background: none; cursor: pointer; }
127
128.map-panel { position: fixed; z-index: 15; right: 0; top: 68px; bottom: 0; width: var(--map-width); background: var(--panel); border-left: 1px solid var(--line); display: flex; flex-direction: column; padding: 28px 20px 16px; transition: transform .2s; }
129.map-heading { display: flex; align-items: start; justify-content: space-between; }
130.map-heading h2, .dialog-heading h2 { font-family: Georgia, serif; font-weight: 400; margin: 5px 0 0; font-size: 1.55rem; }
131.icon-button { border: 1px solid var(--line); background: rgba(255,255,255,.4); width: 31px; height: 31px; border-radius: 9px; cursor: pointer; }
132.map-help { font-size: .75rem; color: var(--muted); line-height: 1.5; margin: 12px 0 18px; }
133.tree { flex: 1; min-height: 0; overflow: auto; padding: 5px 4px 30px; scrollbar-width: thin; }
134.tree ul { list-style: none; margin: 0; padding: 0 0 0 20px; position: relative; }
135.tree > ul { padding-left: 0; }
136.tree ul ul::before { content: ""; position: absolute; top: -6px; bottom: 13px; left: 7px; border-left: 1px solid #c2c8c2; }
137.tree li { position: relative; padding: 4px 0; }
138.tree ul ul > li::before { content: ""; position: absolute; width: 12px; left: -13px; top: 20px; border-top: 1px solid #c2c8c2; }
139.tree-node { width: 100%; border: 1px solid transparent; border-radius: 11px; background: transparent; padding: 8px 9px; text-align: left; cursor: pointer; display: grid; grid-template-columns: 19px minmax(0,1fr); gap: 7px; align-items: start; }
140.tree-node:hover { background: rgba(255,255,255,.55); }
141.tree-node.active { background: white; border-color: #cbd4ce; box-shadow: 0 3px 12px rgba(40,48,44,.06); }
142.node-dot { width: 17px; height: 17px; border-radius: 50%; display: grid; place-items: center; margin-top: 1px; background: #cad6cf; color: var(--sage-dark); font-size: .54rem; font-weight: 800; }
143.tree-node.active .node-dot { background: var(--sage-dark); color: white; }
144.node-copy { min-width: 0; }
145.node-title { display: block; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: .76rem; font-weight: 680; }
146.node-meta { color: #858c88; font-size: .62rem; }
147.map-empty { margin: auto; width: 170px; text-align: center; color: var(--muted); font: 1rem/1.5 Georgia, serif; }
148.empty-orbit { display: grid; place-items: center; width: 54px; height: 54px; margin: auto; border: 1px dashed var(--sage); border-radius: 50%; color: var(--sage-dark); }
149.map-stats { border-top: 1px solid var(--line); padding-top: 13px; display: flex; gap: 18px; color: var(--muted); font-size: .7rem; }
150.map-stats strong { color: var(--ink); }
151.expand-map { position: fixed; z-index: 12; right: 0; top: 84px; border: 1px solid var(--line); border-right: 0; border-radius: 10px 0 0 10px; background: var(--panel); padding: 9px 12px; cursor: pointer; font-size: .75rem; }
152body.map-collapsed .map-panel { transform: translateX(100%); }
153body.map-collapsed .workspace { margin-right: 0; }
154body.map-collapsed .composer-wrap { right: 0; }
155
156.selection-menu { position: fixed; z-index: 40; width: min(330px, calc(100vw - 24px)); padding: 13px; border: 1px solid #cdd2cd; border-radius: 14px; background: white; box-shadow: var(--shadow); }
157.selection-menu[hidden] { display: none; }
158.selection-topline { display: flex; justify-content: space-between; font-size: .7rem; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
159.selection-topline button { border: 0; background: none; cursor: pointer; }
160.selection-menu blockquote { margin: 10px 0; padding: 7px 9px; border-left: 2px solid var(--sage); background: #f4f5f1; color: var(--muted); font-size: .74rem; line-height: 1.4; max-height: 70px; overflow: hidden; }
161.selection-menu select, .selection-menu textarea { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 8px; margin-bottom: 8px; background: white; font-size: .78rem; }
162.selection-menu .button { width: 100%; }
163
164.settings-dialog { width: min(500px, calc(100vw - 28px)); border: 0; border-radius: 20px; padding: 0; color: var(--ink); box-shadow: var(--shadow); }
165.settings-dialog::backdrop { background: rgba(25,31,28,.36); backdrop-filter: blur(3px); }
166.settings-dialog form { padding: 24px; }
167.dialog-heading { display: flex; justify-content: space-between; align-items: start; margin-bottom: 12px; }
168.settings-copy { color: var(--muted); font-size: .8rem; line-height: 1.55; }
169.settings-dialog label { display: block; margin: 14px 0; font-size: .73rem; font-weight: 750; }
170.settings-dialog input, .settings-dialog textarea { width: 100%; margin-top: 6px; padding: 10px 11px; border: 1px solid var(--line); border-radius: 9px; outline: none; resize: vertical; font-weight: 400; }
171.settings-dialog input:focus, .settings-dialog textarea:focus { border-color: var(--sage-dark); box-shadow: 0 0 0 3px rgba(79,109,96,.1); }
172.secret-field { display: flex; position: relative; }
173.secret-field input { padding-right: 58px; }
174.secret-field button { position: absolute; right: 6px; top: 12px; border: 0; background: transparent; color: var(--sage-dark); cursor: pointer; font-size: .72rem; }
175.settings-dialog summary { cursor: pointer; color: var(--sage-dark); font-size: .78rem; font-weight: 700; }
176.security-callout { background: #f4eee5; color: #6d5945; border-radius: 9px; padding: 10px 12px; font-size: .7rem; line-height: 1.5; }
177.dialog-actions { display: flex; justify-content: space-between; margin-top: 18px; }
178.danger { color: #9d443e; }
179.toast { position: fixed; z-index: 60; left: 50%; bottom: 24px; transform: translate(-50%, 20px); background: var(--ink); color: white; padding: 9px 14px; border-radius: 9px; font-size: .76rem; opacity: 0; pointer-events: none; transition: .2s; }
180.toast.show { opacity: 1; transform: translate(-50%, 0); }
181
182@media (max-width: 850px) {
183 :root { --map-width: min(88vw, 340px); }
184 .workspace, .composer-wrap { margin-right: 0; right: 0; }
185 .map-panel { box-shadow: -12px 0 38px rgba(25,31,28,.12); }
186 body:not(.map-open) .map-panel { transform: translateX(100%); }
187 body:not(.map-open) .expand-map { display: block; }
188 .starter-grid { grid-template-columns: 1fr; }
189 .starter { min-height: 78px; }
190 .welcome { padding-top: 45px; }
191}
192@media (max-width: 540px) {
193 .topbar { height: 60px; padding: 0 13px; }
194 .app-shell { padding-top: 60px; }
195 .map-panel { top: 60px; }
196 .top-actions .button { padding: 8px 10px; }
197 .welcome { width: calc(100% - 28px); }
198 .welcome h1 { font-size: 3.2rem; }
199 .conversation { width: calc(100% - 26px); padding-top: 25px; }
200 .composer-wrap { padding-left: 12px; padding-right: 12px; }
201 .hint { display: none; }
202 .answer { grid-template-columns: 25px minmax(0,1fr); gap: 9px; }
203 .answer-mark { width: 25px; height: 25px; }
204 .answer-actions { margin-left: 34px; }
205}
206@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; } }
207
208:root[data-theme="dark"] .topbar { background: rgba(21, 26, 24, .92); }
209:root[data-theme="dark"] .brand-mark,
210:root[data-theme="dark"] .answer-mark,
211:root[data-theme="dark"] .send,
212:root[data-theme="dark"] .button-dark { background: #e6ebe7; color: #18201d; }
213:root[data-theme="dark"] .button-dark:hover { background: #fff; }
214:root[data-theme="dark"] .button-ghost:hover,
215:root[data-theme="dark"] .starter:hover,
216:root[data-theme="dark"] .tree-node.active { background: var(--card); }
217:root[data-theme="dark"] .starter { background: rgba(255,255,255,.025); }
218:root[data-theme="dark"] .starter-icon { background: #29372f; }
219:root[data-theme="dark"] .question-bubble { background: #29332e; }
220:root[data-theme="dark"] .answer-body code { background: #29302d; }
221:root[data-theme="dark"] .answer-body pre { background: #0d110f; color: #e9eeeb; }
222:root[data-theme="dark"] .mini-action:hover { background: #252d29; }
223:root[data-theme="dark"] .composer { background: var(--card); border-color: #3a4640; box-shadow: 0 9px 32px rgba(0,0,0,.22); }
224:root[data-theme="dark"] .composer-wrap { background: linear-gradient(transparent, var(--paper) 22%, var(--paper)); }
225:root[data-theme="dark"] kbd { background: #252c29; }
226:root[data-theme="dark"] .branch-context { background: #223029; border-color: #35493f; }
227:root[data-theme="dark"] .icon-button { background: rgba(255,255,255,.035); }
228:root[data-theme="dark"] .tree-node:hover { background: rgba(255,255,255,.045); }
229:root[data-theme="dark"] .selection-menu,
230:root[data-theme="dark"] .settings-dialog,
231:root[data-theme="dark"] .selection-menu select,
232:root[data-theme="dark"] .selection-menu textarea { background: var(--card); }
233:root[data-theme="dark"] .selection-menu blockquote { background: #1a211e; }
234:root[data-theme="dark"] .security-callout { background: #30291f; color: #d1b99e; }
235:root[data-theme="dark"] .error-text { color: #f0aaa2; background: #3c2422; }