Claude
Claude Opus 5.5
Life² as a Hugging Face Space: game page + Gradio narrate/paint endpoints
510a1f1 unverified Download game/style.css from Aluode/Life2: direct link, hf CLI and curl.
- Browser
- Download file 11.9 kB
-
https://huggingface.co/spaces/Aluode/Life2/resolve/main/game/style.css
- Command line
-
hf download hf://spaces/Aluode/Life2/game/style.css
-
curl -L -o style.css https://huggingface.co/spaces/Aluode/Life2/resolve/main/game/style.css
11.9 kB
| :root { | |
| --bg: #0b100d; --panel: #111814; --line: #22302a; --ink: #e7e3d6; --dim: #8f988f; | |
| --warm: #e5b45a; --green: #79c28a; --cold: #8fa9b8; --loss: #b98a62; | |
| --serif: "Fraunces", Georgia, serif; --mono: "IBM Plex Mono", ui-monospace, monospace; | |
| } | |
| * { box-sizing: border-box; } | |
| html, body { margin: 0; height: 100%; background: var(--bg); color: var(--ink); font-family: var(--mono); font-size: 14px; } | |
| button, select, input { font: inherit; color: var(--ink); background: #1a241e; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; } | |
| button { cursor: pointer; } | |
| button:hover { border-color: #3c5146; } | |
| button.primary { background: #d9c08a; color: #1b1a14; border-color: #d9c08a; font-weight: 500; } | |
| button.primary:hover { background: #e9d29e; } | |
| button:disabled { opacity: 0.4; cursor: default; } | |
| .hidden { display: none ; } | |
| .dim { color: var(--dim); } | |
| .small { font-size: 12px; } | |
| h4 { font-weight: 500; color: var(--dim); font-size: 12px; margin: 14px 0 6px; letter-spacing: 0.3px; } | |
| #app { display: grid; grid-template-columns: 1fr 400px; height: 100vh; } | |
| #stage { position: relative; overflow: hidden; } | |
| #world { width: 100%; height: 100%; display: block; } | |
| #where { position: absolute; top: 16px; left: 22px; pointer-events: none; } | |
| #whereYear { font-family: var(--serif); font-weight: 300; font-size: 34px; } | |
| #wherePlace { color: var(--dim); font-size: 12px; margin-top: 2px; } | |
| #polaroid { position: absolute; top: 16px; right: 18px; margin: 0; width: min(34vw, 340px); background: #efe8d8; padding: 10px 10px 6px; border-radius: 3px; transform: rotate(1.2deg); box-shadow: 0 12px 40px rgba(0,0,0,0.55); } | |
| #polaroid img { width: 100%; display: block; aspect-ratio: 3 / 2; object-fit: cover; background: #ccc4b0; } | |
| #polaroid figcaption { display: flex; justify-content: space-between; align-items: center; color: #3b3a33; font-family: var(--serif); font-style: italic; font-size: 13px; padding-top: 6px; gap: 8px; } | |
| #polaroid figcaption button { background: none; border: none; color: #6b6656; padding: 0 4px; } | |
| #narr { position: absolute; left: 18px; right: 18px; bottom: 16px; max-width: 640px; background: rgba(12, 17, 14, 0.82); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px 10px; backdrop-filter: blur(4px); } | |
| #narrText { margin: 0; font-family: var(--serif); font-size: 17px; line-height: 1.5; font-weight: 300; min-height: 1.5em; } | |
| .narrBar { display: flex; gap: 8px; align-items: center; margin-top: 8px; color: var(--dim); font-size: 11px; } | |
| .narrBar span { flex: 1; } | |
| .narrBar button { padding: 3px 9px; font-size: 11px; } | |
| #panel { background: var(--panel); border-left: 1px solid var(--line); display: flex; flex-direction: column; padding: 16px 16px 10px; gap: 10px; overflow-y: auto; } | |
| #panel header { display: flex; justify-content: space-between; align-items: flex-start; } | |
| .brand { font-family: var(--serif); font-size: 26px; font-weight: 500; } | |
| .who { color: var(--dim); font-size: 12px; margin-top: 2px; } | |
| .age { font-family: var(--serif); font-size: 40px; font-weight: 300; line-height: 1; } | |
| .age small { font-family: var(--mono); font-size: 11px; color: var(--dim); margin-left: 6px; } | |
| .tabs { display: flex; gap: 4px; } | |
| .tabs button { flex: 1; padding: 6px; font-size: 12px; background: transparent; } | |
| .tabs button.on { background: #1f2b24; border-color: #3c5146; } | |
| .meters { display: grid; gap: 8px; } | |
| .meter { display: grid; grid-template-columns: 64px 1fr 40px; align-items: center; gap: 10px; color: var(--dim); font-size: 12px; } | |
| .meter b { color: var(--ink); font-weight: 500; text-align: right; } | |
| .meter.money { grid-template-columns: 64px 1fr; } .meter.money b { text-align: left; } | |
| .bar { height: 6px; background: #1c2721; border-radius: 3px; overflow: hidden; } | |
| .bar i { display: block; height: 100%; width: 50%; background: var(--green); transition: width 0.6s, background 0.6s; } | |
| .bar.warm i { background: var(--warm); } | |
| .allocHead { display: flex; justify-content: space-between; color: var(--dim); font-size: 12px; margin: 10px 0 6px; gap: 8px; } | |
| .left { color: var(--warm); white-space: nowrap; letter-spacing: 2px; } | |
| #rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; } | |
| #rows li { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 8px; background: #141d18; border: 1px solid transparent; } | |
| #rows li.fading { border-color: #4a3a2a; } | |
| #rows .nm { font-size: 13px; } #rows .kd { color: var(--dim); font-size: 11px; margin-left: 6px; } | |
| .bond { height: 3px; background: #1f2b24; border-radius: 2px; margin-top: 5px; overflow: hidden; } | |
| .bond i { display: block; height: 100%; background: var(--green); transition: width 0.6s; } | |
| li.fading .bond i { background: var(--loss); } | |
| .pour { display: flex; align-items: center; gap: 6px; } | |
| .pour button { width: 28px; height: 28px; padding: 0; border-radius: 50%; line-height: 1; } | |
| .drops { font-size: 13px; letter-spacing: 1px; color: var(--warm); min-width: 54px; text-align: center; } | |
| .fortune .big { font-family: var(--serif); font-size: 28px; } | |
| .asset { display: grid; grid-template-columns: 1fr 52px; gap: 4px 10px; align-items: center; margin-bottom: 8px; } | |
| .asset label { font-size: 13px; } .asset .why { grid-column: 1 / -1; color: var(--dim); font-size: 11px; margin-top: -2px; } | |
| .asset input[type=range] { grid-column: 1 / -1; width: 100%; accent-color: #d9c08a; padding: 0; } | |
| .asset b { text-align: right; color: var(--warm); font-weight: 500; } | |
| .note { color: var(--dim); font-size: 12px; line-height: 1.5; } | |
| #gens { padding-left: 18px; margin: 0; font-size: 12px; line-height: 1.55; } | |
| #gens li span { color: var(--dim); } | |
| #heirs { padding-left: 0; list-style: none; font-size: 12px; line-height: 1.55; margin: 0; } | |
| .actions { display: grid; grid-template-columns: 1fr auto; gap: 8px; } | |
| .tools { display: flex; gap: 4px; flex-wrap: wrap; } | |
| .tools button { padding: 5px 9px; font-size: 12px; } | |
| .log { flex: 1; min-height: 60px; } | |
| #log { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; font-size: 12px; color: var(--dim); } | |
| #log li span { color: #5d675f; margin-right: 6px; } | |
| #log li.warm { color: #d9c49a; } #log li.loss { color: #c39b78; } #log li.grief { color: #b3bcc4; } #log li.money { color: #a9c2a2; } #log li.end { color: var(--ink); } | |
| .overlay { position: fixed; inset: 0; background: rgba(6, 9, 7, 0.76); display: grid; place-items: center; z-index: 10; padding: 16px; overflow-y: auto; } | |
| .card { background: #121a15; border: 1px solid var(--line); border-radius: 14px; padding: 24px 24px 18px; max-width: 480px; width: 100%; box-shadow: 0 20px 80px rgba(0,0,0,0.5); } | |
| .card.wide { max-width: 900px; } | |
| .card h1 { font-family: var(--serif); font-weight: 500; font-size: 48px; margin: 0 0 4px; } | |
| .card h2 { font-family: var(--serif); font-weight: 400; font-size: 26px; margin: 2px 0 8px; } | |
| .card h3 { font-size: 12px; color: var(--dim); font-weight: 500; margin: 12px 0 6px; } | |
| .card p { line-height: 1.55; color: #c9c5b8; } | |
| .card .tag { font-family: var(--serif); font-style: italic; font-size: 18px; color: var(--warm); margin-top: 0; } | |
| .eHead { color: var(--warm); font-size: 12px; } | |
| .choices { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; } | |
| .starts { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; } | |
| .start { text-align: left; padding: 10px 12px; border-radius: 10px; background: #151e19; border: 1px solid var(--line); cursor: pointer; } | |
| .start.on { border-color: #d9c08a; background: #1d2620; } | |
| .start b { font-family: var(--serif); font-weight: 500; font-size: 17px; display: block; } | |
| .start span { color: var(--dim); font-size: 12px; line-height: 1.45; } | |
| .setup { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; align-items: center; color: var(--dim); font-size: 13px; } | |
| .setup label { display: flex; gap: 6px; align-items: center; } | |
| #continueBox { margin: 6px 0 10px; } | |
| .endTop { display: grid; grid-template-columns: 340px 1fr; gap: 22px; } | |
| #portrait { width: 100%; border-radius: 10px; background: #0b100d; } | |
| .died { font-family: var(--serif); font-size: 32px; } | |
| .eline { font-family: var(--serif); font-style: italic; font-size: 20px; color: var(--warm) ; margin: 6px 0; } | |
| .estats { color: var(--dim) ; font-size: 13px; } | |
| .cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; } | |
| .cols p, .cols ul, #dLost { font-size: 12px; margin: 0; padding: 0; list-style: none; color: #c9c5b8; line-height: 1.6; } | |
| .heirCards { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; } | |
| .heir { text-align: left; padding: 10px 12px; border-radius: 10px; background: #151e19; border: 1px solid var(--line); cursor: pointer; } | |
| .heir:hover { border-color: #d9c08a; } | |
| .heir b { font-family: var(--serif); font-size: 18px; font-weight: 500; display: block; } | |
| .heir span { color: var(--dim); font-size: 12px; display: block; line-height: 1.5; } | |
| .book { max-width: 820px; max-height: 92vh; display: flex; flex-direction: column; } | |
| .bookHead { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; } | |
| .bookHead .choices { margin: 0; } | |
| #bookBody { overflow-y: auto; padding-right: 6px; margin-top: 8px; } | |
| .chap { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; } | |
| .chap h3 { font-family: var(--serif); font-size: 22px; color: var(--ink); font-weight: 500; margin: 0; } | |
| .chap .sub { color: var(--dim); font-size: 12px; margin-bottom: 8px; } | |
| .chap .epi { font-family: var(--serif); font-style: italic; color: var(--warm); } | |
| .yr { display: grid; grid-template-columns: 70px 1fr; gap: 10px; margin: 8px 0; } | |
| .yr .y { color: var(--dim); font-size: 12px; padding-top: 3px; } | |
| .yr p { margin: 0; font-family: var(--serif); font-weight: 300; font-size: 15px; line-height: 1.5; } | |
| .yr img { width: 100%; max-width: 520px; border-radius: 4px; margin: 6px 0 2px; display: block; } | |
| .saveList { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; } | |
| .saveList li { display: grid; grid-template-columns: 1fr auto; gap: 8px; align-items: center; background: #151e19; padding: 8px 10px; border-radius: 8px; font-size: 12px; } | |
| .saveList li b { font-size: 13px; font-weight: 500; } | |
| .saveList li div.b { display: flex; gap: 4px; } | |
| .saveList li button { padding: 4px 8px; font-size: 12px; } | |
| .setGrid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; } | |
| .setGrid label { display: block; margin: 6px 0; font-size: 13px; } | |
| .setGrid .sub { margin: 2px 0 8px 22px; display: flex; gap: 6px; align-items: center; color: var(--dim); font-size: 12px; flex-wrap: wrap; } | |
| .setGrid .sub input { padding: 4px 8px; font-size: 12px; } | |
| .setGrid .sub select { max-width: 260px; padding: 3px 6px; font-size: 12px; background: var(--bg, #0c110e); color: inherit; border: 1px solid var(--line); border-radius: 6px; } | |
| .setGrid h4 + label, .setGrid h4 { margin-top: 14px; } | |
| .testRow { display: flex; gap: 10px; align-items: center; margin: 8px 0 4px; } | |
| .testRow button { flex: none; padding: 4px 10px; font-size: 12px; } | |
| .testRow span { line-height: 1.4; } | |
| .testImg { display: block; width: 100%; max-width: 384px; margin-top: 8px; border-radius: 6px; border: 1px solid var(--line); } | |
| #narrVoice.on { color: var(--warm, #e8c47a); border-color: currentColor; } | |
| .howto { background: #0b100d; border: 1px solid var(--line); border-radius: 8px; padding: 10px; font-size: 12px; color: #c9c5b8; white-space: pre-wrap; } | |
| @media (max-width: 900px) { | |
| #app { grid-template-columns: 1fr; grid-template-rows: 58vh auto; height: auto; } | |
| #stage { height: 58vh; } | |
| #panel { border-left: 0; border-top: 1px solid var(--line); overflow: visible; } | |
| .endTop, .setGrid { grid-template-columns: 1fr; } | |
| #portrait { max-width: 340px; margin: 0 auto; display: block; } | |
| .overlay { place-items: start center; } | |
| #polaroid { width: 42vw; } | |
| #narr { right: 12px; left: 12px; bottom: 10px; } | |
| #narrText { font-size: 15px; } | |
| } | |