feat: implement core application structure with Fastify server and SQLite persistence
- Add Fastify server in `app/src/index.ts` with health check and API routes for game state and turn processing. - Create `latentEntities.ts` to handle personal item plausibility and promote beliefs to facts based on actor context. - Introduce `llmAdapter.ts` for action extraction from prose input. - Develop `truthEngine.ts` for pure validation logic, handling all verbs with explicit rejection reasons. - Define new types in `types.ts` for facts, affordances, and latent entity requests/resolutions. - Update `docker-compose.yml` for improved service structure and volume management. - Create frontend structure with React, including Dockerfile, Vite configuration, and initial components for state inspection. - Implement basic styles and HTML structure for the frontend application. - Document current status and next steps in `thoughts.md`.
This commit is contained in:
181
charactergarden/frontend/src/styles.css
Normal file
181
charactergarden/frontend/src/styles.css
Normal file
@@ -0,0 +1,181 @@
|
||||
:root {
|
||||
font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
|
||||
color: #f4efe4;
|
||||
background:
|
||||
radial-gradient(circle at top left, rgba(199, 166, 106, 0.16), transparent 36%),
|
||||
linear-gradient(160deg, #112419 0%, #1c3024 52%, #31261b 100%);
|
||||
line-height: 1.5;
|
||||
font-weight: 400;
|
||||
}
|
||||
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
body {
|
||||
margin: 0;
|
||||
min-width: 320px;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
button,
|
||||
textarea {
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
.page-shell {
|
||||
width: min(1400px, calc(100vw - 32px));
|
||||
margin: 0 auto;
|
||||
padding: 32px 0 48px;
|
||||
}
|
||||
|
||||
.hero-panel {
|
||||
padding: 32px;
|
||||
border: 1px solid rgba(244, 239, 228, 0.16);
|
||||
background: rgba(19, 24, 18, 0.68);
|
||||
backdrop-filter: blur(12px);
|
||||
border-radius: 28px;
|
||||
box-shadow: 0 22px 70px rgba(0, 0, 0, 0.24);
|
||||
}
|
||||
|
||||
.eyebrow {
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 0.22em;
|
||||
font-size: 0.78rem;
|
||||
color: #dcbf8d;
|
||||
}
|
||||
|
||||
h1,
|
||||
h2,
|
||||
h3,
|
||||
p {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
h1 {
|
||||
font-family: "Alegreya", Georgia, serif;
|
||||
font-size: clamp(2.5rem, 4vw, 4.5rem);
|
||||
margin-bottom: 12px;
|
||||
}
|
||||
|
||||
.lede {
|
||||
max-width: 58rem;
|
||||
color: rgba(244, 239, 228, 0.78);
|
||||
}
|
||||
|
||||
.turn-form {
|
||||
display: grid;
|
||||
gap: 12px;
|
||||
margin-top: 24px;
|
||||
}
|
||||
|
||||
.turn-form textarea {
|
||||
width: 100%;
|
||||
border: 1px solid rgba(244, 239, 228, 0.18);
|
||||
background: rgba(12, 16, 12, 0.72);
|
||||
color: inherit;
|
||||
border-radius: 18px;
|
||||
padding: 16px;
|
||||
resize: vertical;
|
||||
}
|
||||
|
||||
.actions-row {
|
||||
display: grid;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
.actions-row > button,
|
||||
.chip {
|
||||
border: 0;
|
||||
border-radius: 999px;
|
||||
padding: 12px 18px;
|
||||
background: linear-gradient(135deg, #d8b16f, #a96c36);
|
||||
color: #1d1b17;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.chips {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
gap: 10px;
|
||||
}
|
||||
|
||||
.chip {
|
||||
background: rgba(244, 239, 228, 0.08);
|
||||
color: #f4efe4;
|
||||
border: 1px solid rgba(244, 239, 228, 0.12);
|
||||
}
|
||||
|
||||
.result-card,
|
||||
.panel {
|
||||
border-radius: 24px;
|
||||
padding: 24px;
|
||||
border: 1px solid rgba(244, 239, 228, 0.12);
|
||||
background: rgba(11, 16, 12, 0.58);
|
||||
}
|
||||
|
||||
.result-card {
|
||||
margin-top: 24px;
|
||||
}
|
||||
|
||||
.inspector-grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
gap: 20px;
|
||||
margin-top: 24px;
|
||||
}
|
||||
|
||||
.entity-list,
|
||||
.timeline-list {
|
||||
list-style: none;
|
||||
padding: 0;
|
||||
margin: 0;
|
||||
display: grid;
|
||||
gap: 14px;
|
||||
}
|
||||
|
||||
.entity-list li,
|
||||
.timeline-list li {
|
||||
padding: 16px;
|
||||
border-radius: 18px;
|
||||
background: rgba(255, 255, 255, 0.03);
|
||||
border: 1px solid rgba(255, 255, 255, 0.05);
|
||||
}
|
||||
|
||||
.entity-list span {
|
||||
display: inline-block;
|
||||
margin-left: 8px;
|
||||
opacity: 0.7;
|
||||
}
|
||||
|
||||
pre {
|
||||
white-space: pre-wrap;
|
||||
word-break: break-word;
|
||||
font-size: 0.85rem;
|
||||
color: #cfd9c2;
|
||||
}
|
||||
|
||||
.compact li {
|
||||
padding: 12px;
|
||||
}
|
||||
|
||||
.error-banner {
|
||||
margin-top: 16px;
|
||||
color: #ffd2b8;
|
||||
}
|
||||
|
||||
@media (max-width: 900px) {
|
||||
.inspector-grid {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.page-shell {
|
||||
width: min(100vw - 20px, 1400px);
|
||||
padding-top: 20px;
|
||||
}
|
||||
|
||||
.hero-panel,
|
||||
.panel {
|
||||
padding: 20px;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user