rewrite: TS monorepo — pi SDK stateless agents, Postgres+pg-boss, SvelteKit themed UI; legacy moved to legacy/
This commit is contained in:
@@ -0,0 +1,493 @@
|
||||
/* ====================================================================
|
||||
ai-chess MENU — fight-club / tournament bulletin aesthetic
|
||||
palette
|
||||
ink #0a0a0c (background bottom)
|
||||
paper #15151a (panels)
|
||||
bone #e7e4d8 (primary text)
|
||||
ash #6a6a72 (muted text)
|
||||
gold #c0a060 (rule / decisions / accept)
|
||||
crimson #c04040 (fight / abort)
|
||||
gold-dim #6b5a35
|
||||
crimson-dim #6b2222
|
||||
==================================================================== */
|
||||
|
||||
:root {
|
||||
--ink: #0a0a0c;
|
||||
--paper: #15151a;
|
||||
--paper-2: #1d1d23;
|
||||
--bone: #e7e4d8;
|
||||
--bone-dim: #b8b4a3;
|
||||
--ash: #6a6a72;
|
||||
--rule: #2a2a30;
|
||||
--gold: #c0a060;
|
||||
--gold-dim: #6b5a35;
|
||||
--crimson: #c04040;
|
||||
--crimson-dim:#6b2222;
|
||||
}
|
||||
|
||||
* { box-sizing: border-box; }
|
||||
[hidden] { display: none !important; }
|
||||
html, body {
|
||||
margin: 0;
|
||||
background: radial-gradient(ellipse at 50% -10%, #1e1e24 0%, var(--ink) 60%) fixed;
|
||||
color: var(--bone);
|
||||
font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
|
||||
font-weight: 400;
|
||||
line-height: 1.4;
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
/* fine grain / film texture */
|
||||
.grain {
|
||||
position: fixed; inset: 0; pointer-events: none; z-index: 100;
|
||||
opacity: 0.06;
|
||||
background-image:
|
||||
repeating-linear-gradient(0deg, transparent 0 2px, rgba(255,255,255,0.05) 2px 3px),
|
||||
repeating-linear-gradient(90deg, transparent 0 2px, rgba(255,255,255,0.04) 2px 3px);
|
||||
mix-blend-mode: overlay;
|
||||
}
|
||||
|
||||
/* ---------- TOPBAR ---------- */
|
||||
.topbar {
|
||||
display: flex; justify-content: space-between; align-items: baseline;
|
||||
padding: 22px 36px;
|
||||
font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
|
||||
color: var(--ash);
|
||||
border-bottom: 1px solid var(--rule);
|
||||
}
|
||||
.brand {
|
||||
color: var(--gold);
|
||||
font-weight: 800;
|
||||
letter-spacing: 0.22em;
|
||||
font-size: 12px;
|
||||
}
|
||||
.topbar-meta { display: flex; gap: 10px; align-items: baseline; }
|
||||
.topbar-meta .sep { opacity: 0.4; }
|
||||
.topbar-meta .ver { color: var(--gold); }
|
||||
|
||||
/* ---------- HERO ---------- */
|
||||
.hero {
|
||||
max-width: 1180px;
|
||||
margin: 0 auto;
|
||||
padding: 36px 36px 80px;
|
||||
}
|
||||
|
||||
.badge-row {
|
||||
display: flex; align-items: center; gap: 14px;
|
||||
font-size: 10px; letter-spacing: 0.32em; color: var(--gold);
|
||||
text-transform: uppercase;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
.badge-line { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--gold-dim), transparent); }
|
||||
.badge { white-space: nowrap; }
|
||||
|
||||
.title {
|
||||
font-family: "Major Mono Display", "JetBrains Mono", monospace;
|
||||
font-size: clamp(56px, 9vw, 132px);
|
||||
line-height: 0.9;
|
||||
letter-spacing: 0.04em;
|
||||
margin: 0 0 18px;
|
||||
text-align: center;
|
||||
color: var(--bone);
|
||||
text-shadow: 0 0 60px rgba(192,160,96,0.18);
|
||||
font-weight: 400;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: baseline;
|
||||
gap: 0.18em;
|
||||
flex-wrap: nowrap;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.title .t1, .title .t2 { color: var(--bone); white-space: nowrap; }
|
||||
.title .t-dot {
|
||||
color: var(--crimson);
|
||||
display: inline-block;
|
||||
transform: translateY(-0.08em);
|
||||
animation: pulse-dot 2s ease-in-out infinite;
|
||||
}
|
||||
@keyframes pulse-dot {
|
||||
0%,100% { opacity: 0.7; text-shadow: 0 0 18px var(--crimson-dim); }
|
||||
50% { opacity: 1; text-shadow: 0 0 36px var(--crimson); }
|
||||
}
|
||||
|
||||
.tagline {
|
||||
text-align: center;
|
||||
color: var(--bone-dim);
|
||||
font-size: 14px;
|
||||
letter-spacing: 0.02em;
|
||||
margin: 0 auto 56px;
|
||||
max-width: 620px;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
/* ---------- ACTIVE GAME CARD (in-progress) ---------- */
|
||||
.active-card {
|
||||
position: relative;
|
||||
background:
|
||||
linear-gradient(180deg, rgba(192,160,96,0.08) 0%, rgba(15,15,18,0) 70%),
|
||||
var(--paper);
|
||||
border: 1px solid var(--gold-dim);
|
||||
border-radius: 6px;
|
||||
padding: 26px 28px 22px;
|
||||
margin-bottom: 32px;
|
||||
box-shadow: 0 30px 80px -40px rgba(192,160,96,0.45);
|
||||
overflow: hidden;
|
||||
animation: setup-in 0.35s ease both;
|
||||
}
|
||||
.active-card::after {
|
||||
content: "LIVE";
|
||||
position: absolute;
|
||||
top: 14px; right: -36px;
|
||||
background: var(--crimson); color: #fff;
|
||||
font-size: 10px; font-weight: 800; letter-spacing: 0.4em;
|
||||
padding: 3px 40px;
|
||||
transform: rotate(35deg);
|
||||
box-shadow: 0 6px 14px -6px var(--crimson);
|
||||
}
|
||||
.active-head {
|
||||
display: flex; align-items: baseline; gap: 12px;
|
||||
border-bottom: 1px dashed var(--rule);
|
||||
padding-bottom: 14px; margin-bottom: 18px;
|
||||
font-size: 11px; letter-spacing: 0.32em; text-transform: uppercase;
|
||||
color: var(--gold);
|
||||
}
|
||||
.active-pulse {
|
||||
display: inline-block; width: 8px; height: 8px;
|
||||
background: var(--crimson); border-radius: 50%;
|
||||
animation: pulse-dot 1.4s ease-in-out infinite;
|
||||
align-self: center;
|
||||
}
|
||||
.active-meta { margin-left: auto; opacity: 0.55; letter-spacing: 0.16em; color: var(--bone-dim); font-size: 11px; }
|
||||
|
||||
.active-vs {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 96px 1fr;
|
||||
gap: 18px; align-items: stretch;
|
||||
margin-bottom: 22px;
|
||||
}
|
||||
.seat {
|
||||
display: flex; flex-direction: column; gap: 4px;
|
||||
padding: 14px 18px;
|
||||
border: 1px solid var(--rule);
|
||||
border-radius: 4px;
|
||||
background: rgba(0,0,0,0.18);
|
||||
position: relative;
|
||||
}
|
||||
.seat-white { border-left: 3px solid var(--bone); }
|
||||
.seat-black { border-right: 3px solid var(--bone-dim); text-align: right; }
|
||||
.seat-pip {
|
||||
position: absolute; top: 14px; font-size: 14px; opacity: 0.7;
|
||||
}
|
||||
.seat-white .seat-pip { left: 18px; color: var(--bone); }
|
||||
.seat-black .seat-pip { right: 18px; color: var(--bone-dim); }
|
||||
.seat-name {
|
||||
font-size: 22px; font-weight: 800; letter-spacing: 0.06em;
|
||||
text-transform: uppercase;
|
||||
margin-left: 20px; /* under the pip */
|
||||
}
|
||||
.seat-black .seat-name { margin-left: 0; margin-right: 20px; }
|
||||
.seat-sub {
|
||||
font-size: 11px; color: var(--gold); letter-spacing: 0.08em;
|
||||
margin-left: 20px;
|
||||
}
|
||||
.seat-black .seat-sub { margin-left: 0; margin-right: 20px; }
|
||||
.seat-persona {
|
||||
font-size: 11px; color: var(--bone-dim); opacity: 0.7;
|
||||
margin-top: 2px;
|
||||
margin-left: 20px;
|
||||
font-style: italic;
|
||||
}
|
||||
.seat-black .seat-persona { margin-left: 0; margin-right: 20px; }
|
||||
|
||||
.active-divider {
|
||||
display: flex; flex-direction: column; align-items: center; justify-content: center;
|
||||
gap: 8px;
|
||||
}
|
||||
.active-vs-label {
|
||||
font-size: 28px; font-weight: 800; color: var(--crimson);
|
||||
letter-spacing: 0.1em;
|
||||
}
|
||||
.active-turn {
|
||||
font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase;
|
||||
color: var(--bone-dim); text-align: center;
|
||||
}
|
||||
|
||||
.active-actions {
|
||||
display: flex; gap: 16px; align-items: center;
|
||||
margin-top: 8px;
|
||||
}
|
||||
.watch-btn {
|
||||
display: inline-flex; align-items: center; gap: 14px;
|
||||
background: var(--gold); color: #1a1410;
|
||||
text-decoration: none;
|
||||
padding: 12px 32px;
|
||||
font-size: 15px; font-weight: 800; letter-spacing: 0.2em;
|
||||
border-radius: 3px;
|
||||
transition: filter 0.15s, transform 0.1s;
|
||||
box-shadow: 0 8px 28px -10px var(--gold);
|
||||
}
|
||||
.watch-btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
|
||||
.watch-btn .kbd {
|
||||
font-size: 11px; opacity: 0.7;
|
||||
border: 1px solid rgba(0,0,0,0.3); padding: 1px 6px; border-radius: 2px;
|
||||
}
|
||||
.active-abort {
|
||||
background: transparent; border: 1px solid var(--crimson-dim);
|
||||
color: var(--crimson); padding: 8px 16px;
|
||||
font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
|
||||
cursor: pointer; border-radius: 3px;
|
||||
font-family: inherit;
|
||||
transition: background 0.15s, color 0.15s;
|
||||
}
|
||||
.active-abort:hover { background: var(--crimson-dim); color: #ffe5e5; }
|
||||
.active-foot {
|
||||
margin: 18px 0 0; padding-top: 14px;
|
||||
border-top: 1px dashed var(--rule);
|
||||
font-size: 11px; color: var(--ash);
|
||||
letter-spacing: 0.04em; font-style: italic;
|
||||
}
|
||||
|
||||
/* ---------- MODE CARDS ---------- */
|
||||
.modes {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: 14px;
|
||||
margin-bottom: 32px;
|
||||
}
|
||||
.mode {
|
||||
position: relative;
|
||||
background: var(--paper);
|
||||
border: 1px solid var(--rule);
|
||||
border-radius: 4px;
|
||||
padding: 26px 22px 22px;
|
||||
cursor: pointer;
|
||||
text-align: left;
|
||||
color: var(--bone);
|
||||
font-family: inherit;
|
||||
font-size: 13px;
|
||||
display: flex; flex-direction: column; gap: 8px;
|
||||
min-height: 168px;
|
||||
transition: transform 0.18s ease, border-color 0.18s, background 0.18s, box-shadow 0.18s;
|
||||
text-decoration: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
.mode::before {
|
||||
content: "";
|
||||
position: absolute; inset: 0;
|
||||
background:
|
||||
repeating-linear-gradient(45deg, transparent 0 6px, rgba(255,255,255,0.012) 6px 12px);
|
||||
pointer-events: none;
|
||||
}
|
||||
.mode:hover {
|
||||
transform: translateY(-2px);
|
||||
border-color: var(--bone-dim);
|
||||
background: var(--paper-2);
|
||||
}
|
||||
.mode-num {
|
||||
font-size: 10px;
|
||||
color: var(--ash);
|
||||
letter-spacing: 0.3em;
|
||||
}
|
||||
.mode-name {
|
||||
font-size: 22px;
|
||||
font-weight: 800;
|
||||
letter-spacing: 0.04em;
|
||||
margin-top: 2px;
|
||||
}
|
||||
.mode-name .x { color: var(--crimson); margin: 0 4px; font-weight: 400; }
|
||||
.mode-desc {
|
||||
color: var(--bone-dim);
|
||||
font-size: 12px;
|
||||
line-height: 1.5;
|
||||
flex: 1;
|
||||
}
|
||||
.mode-tag {
|
||||
align-self: flex-start;
|
||||
padding: 2px 8px;
|
||||
font-size: 9px;
|
||||
letter-spacing: 0.25em;
|
||||
border: 1px solid currentColor;
|
||||
border-radius: 2px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
.tag-gold { color: var(--gold); }
|
||||
.tag-crimson { color: var(--crimson); }
|
||||
.tag-neutral { color: var(--ash); }
|
||||
|
||||
/* Selected card */
|
||||
.mode[aria-pressed="true"] {
|
||||
border-color: var(--gold);
|
||||
box-shadow: 0 0 0 1px var(--gold), 0 20px 60px -30px rgba(192,160,96,0.4);
|
||||
background: var(--paper-2);
|
||||
}
|
||||
.mode[aria-pressed="true"][data-mode="human_vs_ai"] {
|
||||
border-color: var(--crimson);
|
||||
box-shadow: 0 0 0 1px var(--crimson), 0 20px 60px -30px rgba(192,64,64,0.4);
|
||||
}
|
||||
|
||||
/* ---------- SETUP ---------- */
|
||||
.setup {
|
||||
background: var(--paper);
|
||||
border: 1px solid var(--rule);
|
||||
border-radius: 4px;
|
||||
padding: 24px 24px 18px;
|
||||
margin-bottom: 28px;
|
||||
animation: setup-in 0.3s ease both;
|
||||
}
|
||||
@keyframes setup-in {
|
||||
from { opacity: 0; transform: translateY(8px); }
|
||||
to { opacity: 1; transform: none; }
|
||||
}
|
||||
.setup-head {
|
||||
display: flex; align-items: center; gap: 14px;
|
||||
border-bottom: 1px dashed var(--rule);
|
||||
padding-bottom: 12px; margin-bottom: 18px;
|
||||
}
|
||||
.setup-step {
|
||||
font-size: 10px; letter-spacing: 0.3em; color: var(--gold);
|
||||
text-transform: uppercase;
|
||||
}
|
||||
.setup-title {
|
||||
font-size: 12px; letter-spacing: 0.06em; color: var(--bone-dim);
|
||||
}
|
||||
.setup-tools { margin-left: auto; display: flex; gap: 6px; }
|
||||
.tool {
|
||||
background: transparent; color: var(--bone-dim); border: 1px solid var(--rule);
|
||||
padding: 3px 10px; font-size: 11px; font-family: inherit; cursor: pointer;
|
||||
border-radius: 3px; letter-spacing: 0.05em;
|
||||
}
|
||||
.tool:hover { border-color: var(--bone-dim); color: var(--bone); }
|
||||
|
||||
.sides {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 56px 1fr;
|
||||
gap: 14px;
|
||||
align-items: stretch;
|
||||
}
|
||||
.side {
|
||||
border: 1px solid var(--rule);
|
||||
border-radius: 4px;
|
||||
padding: 18px 16px 16px;
|
||||
background: rgba(0,0,0,0.18);
|
||||
margin: 0;
|
||||
display: flex; flex-direction: column; gap: 12px;
|
||||
position: relative;
|
||||
}
|
||||
.side legend {
|
||||
display: flex; align-items: center; gap: 8px;
|
||||
padding: 0 8px;
|
||||
font-size: 11px; letter-spacing: 0.3em; font-weight: 800;
|
||||
}
|
||||
.legend-pip {
|
||||
display: inline-block; width: 8px; height: 8px;
|
||||
background: var(--bone); border-radius: 50%;
|
||||
}
|
||||
.side-white legend { color: var(--bone); }
|
||||
.side-white .legend-pip { background: var(--bone); }
|
||||
.side-black legend { color: var(--bone-dim); }
|
||||
.side-black .legend-pip { background: #1a1a1a; box-shadow: inset 0 0 0 1px var(--bone-dim); }
|
||||
|
||||
.field {
|
||||
display: flex; flex-direction: column; gap: 4px;
|
||||
font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase;
|
||||
color: var(--ash);
|
||||
}
|
||||
.field select {
|
||||
background: var(--paper-2); color: var(--bone);
|
||||
border: 1px solid var(--rule); border-radius: 3px;
|
||||
padding: 6px 8px;
|
||||
font-family: inherit; font-size: 13px; letter-spacing: 0;
|
||||
text-transform: none;
|
||||
appearance: none;
|
||||
background-image:
|
||||
linear-gradient(45deg, transparent 50%, var(--bone-dim) 50%),
|
||||
linear-gradient(-45deg, transparent 50%, var(--bone-dim) 50%);
|
||||
background-position: calc(100% - 12px) 12px, calc(100% - 7px) 12px;
|
||||
background-size: 5px 5px, 5px 5px;
|
||||
background-repeat: no-repeat;
|
||||
}
|
||||
.field select:focus { outline: 1px solid var(--gold); border-color: var(--gold); }
|
||||
|
||||
.persona-desc {
|
||||
font-size: 11px; line-height: 1.5; color: var(--bone-dim);
|
||||
margin: 4px 0 0; min-height: 2.4em; font-style: italic;
|
||||
}
|
||||
.human-note {
|
||||
font-size: 11px; color: var(--crimson); margin: 0;
|
||||
border: 1px dashed var(--crimson-dim); padding: 8px 10px; border-radius: 3px;
|
||||
}
|
||||
|
||||
.vs {
|
||||
display: flex; align-items: center; justify-content: center;
|
||||
font-size: 28px; font-weight: 800; color: var(--crimson);
|
||||
letter-spacing: 0.1em;
|
||||
position: relative;
|
||||
}
|
||||
.vs::before, .vs::after {
|
||||
content: ""; position: absolute; left: 50%; transform: translateX(-50%);
|
||||
width: 1px; height: 28%; background: var(--rule);
|
||||
}
|
||||
.vs::before { top: 0; }
|
||||
.vs::after { bottom: 0; }
|
||||
|
||||
/* warning + footer */
|
||||
#setup-warning {
|
||||
margin-top: 16px;
|
||||
background: rgba(192,64,64,0.08);
|
||||
border: 1px solid var(--crimson-dim);
|
||||
color: #e0a0a0;
|
||||
padding: 10px 14px;
|
||||
font-size: 12px; letter-spacing: 0.04em;
|
||||
border-radius: 3px;
|
||||
}
|
||||
.link-abort {
|
||||
background: transparent; border: none; color: var(--crimson);
|
||||
text-decoration: underline; cursor: pointer; font: inherit; padding: 0;
|
||||
}
|
||||
|
||||
.setup-foot {
|
||||
display: flex; align-items: center; justify-content: space-between;
|
||||
margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--rule);
|
||||
}
|
||||
.back {
|
||||
color: var(--ash); text-decoration: none; font-size: 12px;
|
||||
}
|
||||
.back:hover { color: var(--bone); }
|
||||
|
||||
.start {
|
||||
display: inline-flex; align-items: center; gap: 12px;
|
||||
background: var(--gold); color: #1a1410;
|
||||
border: none; padding: 10px 26px;
|
||||
font-family: inherit; font-size: 14px; font-weight: 800; letter-spacing: 0.16em;
|
||||
cursor: pointer;
|
||||
border-radius: 3px;
|
||||
transition: filter 0.15s, transform 0.1s;
|
||||
box-shadow: 0 6px 24px -10px var(--gold);
|
||||
}
|
||||
.start:hover:not(:disabled) { filter: brightness(1.08); transform: translateY(-1px); }
|
||||
.start:active:not(:disabled) { transform: translateY(0); }
|
||||
.start:disabled { background: var(--rule); color: var(--ash); cursor: not-allowed; box-shadow: none; }
|
||||
.start .kbd {
|
||||
font-size: 11px; opacity: 0.7;
|
||||
border: 1px solid rgba(0,0,0,0.3); padding: 1px 6px; border-radius: 2px;
|
||||
}
|
||||
.setup[data-mode="human_vs_ai"] .start { background: var(--crimson); color: #fff; box-shadow: 0 6px 24px -10px var(--crimson); }
|
||||
|
||||
/* ---------- HUD footer ---------- */
|
||||
.hud {
|
||||
display: flex; gap: 26px; justify-content: center;
|
||||
margin-top: 32px;
|
||||
font-size: 10px; letter-spacing: 0.2em; color: var(--ash);
|
||||
text-transform: uppercase;
|
||||
border-top: 1px solid var(--rule); padding-top: 16px;
|
||||
}
|
||||
.hud code {
|
||||
font-family: inherit; color: var(--gold); letter-spacing: 0.02em; text-transform: none;
|
||||
}
|
||||
|
||||
/* ---------- responsive ---------- */
|
||||
@media (max-width: 880px) {
|
||||
.modes { grid-template-columns: 1fr; }
|
||||
.sides { grid-template-columns: 1fr; }
|
||||
.vs { padding: 8px 0; }
|
||||
}
|
||||
Reference in New Issue
Block a user