312 lines
11 KiB
CSS
312 lines
11 KiB
CSS
:root {
|
|
--rosewater: #f5e0dc;
|
|
--flamingo: #f2cdcd;
|
|
--pink: #f5c2e7;
|
|
--mauve: #cba6f7;
|
|
--red: #f38ba8;
|
|
--maroon: #eba0ac;
|
|
--peach: #fab387;
|
|
--yellow: #f9e2af;
|
|
--green: #a6e3a1;
|
|
--teal: #94e2d5;
|
|
--sky: #89dceb;
|
|
--sapphire: #74c7ec;
|
|
--blue: #89b4fa;
|
|
--lavender: #b4befe;
|
|
--text: #cdd6f4;
|
|
--subtext: #bac2de;
|
|
--overlay: #6c7086;
|
|
--surface: #313244;
|
|
--base: #1e1e2e;
|
|
--mantle: #181825;
|
|
--crust: #11111b;
|
|
}
|
|
|
|
* { box-sizing: border-box; }
|
|
[hidden] { display: none !important; }
|
|
|
|
body {
|
|
margin: 0;
|
|
background: var(--base);
|
|
color: var(--text);
|
|
font-family: system-ui, sans-serif;
|
|
}
|
|
|
|
main {
|
|
max-width: 1160px;
|
|
margin: 0 auto;
|
|
padding: 1rem;
|
|
text-align: center;
|
|
display: grid;
|
|
grid-template-columns: 340px minmax(0, 1fr);
|
|
gap: 2rem;
|
|
align-items: start;
|
|
}
|
|
|
|
.game-panel {
|
|
position: sticky;
|
|
top: 1rem;
|
|
z-index: 2;
|
|
background: var(--base);
|
|
border: 1px solid var(--surface);
|
|
border-radius: 16px;
|
|
padding: 1rem;
|
|
}
|
|
.game-panel h1 { font-size: 1.5rem; }
|
|
.game-panel #countdown { font-size: clamp(1.8rem, 3.5vw, 2.7rem); }
|
|
.game-panel #history-global-summary { font-size: 0.85rem; color: var(--subtext); }
|
|
.section-browser { min-width: 0; }
|
|
#section-nav { display: flex; flex-wrap: wrap; gap: 0.5rem; }
|
|
#section-nav button { flex: 1 0 auto; min-height: 44px; }
|
|
#section-nav button[aria-expanded="true"] {
|
|
background: var(--mauve);
|
|
color: var(--crust);
|
|
border-color: var(--mauve);
|
|
}
|
|
#section-hint { color: var(--subtext); margin-top: 2rem; }
|
|
[data-panel] { overflow-x: auto; padding: 1rem; }
|
|
[data-panel] h2 { margin-top: 0; }
|
|
form { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem; }
|
|
form input { min-width: 0; max-width: 100%; }
|
|
|
|
h1 { letter-spacing: 0.3em; }
|
|
|
|
a { color: var(--sapphire); }
|
|
|
|
section { margin: 1.5rem 0; }
|
|
|
|
#countdown {
|
|
font-family: ui-monospace, monospace;
|
|
font-size: clamp(2rem, 9vw, 4rem);
|
|
font-weight: bold;
|
|
background: none !important;
|
|
border: none !important;
|
|
}
|
|
|
|
#zone-label { text-transform: uppercase; letter-spacing: 0.2em; }
|
|
|
|
#zone-bar {
|
|
position: relative;
|
|
display: flex;
|
|
height: 14px;
|
|
margin: 0.75rem auto;
|
|
border: 1px solid var(--overlay);
|
|
border-radius: 4px;
|
|
overflow: hidden;
|
|
}
|
|
#zone-bar span { flex: 1 1 0; }
|
|
#zone-marker {
|
|
position: absolute;
|
|
top: -6px;
|
|
width: 3px;
|
|
height: 26px;
|
|
background: var(--mauve);
|
|
box-shadow: 0 0 4px var(--crust);
|
|
transition: left 0.2s linear;
|
|
}
|
|
|
|
#the-button {
|
|
width: 200px;
|
|
height: 200px;
|
|
border-radius: 50%;
|
|
font-size: 1.6rem;
|
|
font-weight: bold;
|
|
cursor: pointer;
|
|
border: 6px solid var(--mantle);
|
|
box-shadow: 0 8px 0 var(--crust);
|
|
transition: transform 0.05s;
|
|
}
|
|
#the-button:active:not(:disabled) { transform: translateY(6px); box-shadow: 0 2px 0 var(--crust); }
|
|
#the-button:disabled { cursor: not-allowed; opacity: 0.5; }
|
|
|
|
.zone-green { background: var(--green); color: var(--crust); }
|
|
.zone-blue { background: var(--blue); color: var(--crust); }
|
|
.zone-yellow { background: var(--yellow); color: var(--crust); }
|
|
.zone-red { background: var(--red); color: var(--crust); }
|
|
.zone-black { background: var(--mantle); color: var(--text); border-color: var(--overlay) !important; }
|
|
.zone-white { background: var(--text); color: var(--crust); }
|
|
|
|
#countdown.zone-green { color: var(--green); }
|
|
#countdown.zone-blue { color: var(--blue); }
|
|
#countdown.zone-yellow { color: var(--yellow); }
|
|
#countdown.zone-red { color: var(--red); }
|
|
#countdown.zone-black { color: var(--black); }
|
|
#countdown.zone-white { color: var(--white); }
|
|
|
|
.swatch {
|
|
display: inline-block;
|
|
padding: 0 0.4em;
|
|
margin: 0 0.15em;
|
|
border: 1px solid var(--overlay);
|
|
border-radius: 3px;
|
|
}
|
|
|
|
table {
|
|
margin: 0.5rem auto;
|
|
border-collapse: collapse;
|
|
min-width: 60%;
|
|
}
|
|
th, td { padding: 0.3rem 0.6rem; border-bottom: 1px solid var(--surface); }
|
|
|
|
#leaderboard-section {
|
|
padding: 1rem;
|
|
background: var(--mantle);
|
|
border: 1px solid var(--surface);
|
|
border-radius: 12px;
|
|
}
|
|
#leaderboard-section > p { color: var(--subtext); font-size: 0.9rem; }
|
|
#leaderboard-status:empty { display: none; }
|
|
.leaderboard-scroll { overflow-x: auto; }
|
|
#leaderboard { width: 100%; }
|
|
#leaderboard th { color: var(--lavender); }
|
|
#leaderboard th:nth-child(2), #leaderboard td:nth-child(2) {
|
|
text-align: left;
|
|
overflow-wrap: anywhere;
|
|
}
|
|
#leaderboard td:not(:nth-child(2)) { font-variant-numeric: tabular-nums; }
|
|
#leaderboard tbody tr:first-child { color: var(--yellow); }
|
|
#leaderboard tbody tr:hover { background: var(--surface); }
|
|
|
|
input, button {
|
|
font-size: 1rem;
|
|
padding: 0.4rem 0.8rem;
|
|
}
|
|
|
|
input {
|
|
border: 1px solid var(--overlay);
|
|
border-radius: 4px;
|
|
background: var(--mantle);
|
|
color: var(--text);
|
|
}
|
|
|
|
input::placeholder { color: var(--overlay); }
|
|
|
|
button:not(#the-button) {
|
|
border: 1px solid var(--overlay);
|
|
border-radius: 4px;
|
|
background: var(--surface);
|
|
color: var(--text);
|
|
cursor: pointer;
|
|
}
|
|
|
|
button:not(#the-button):hover { background: var(--overlay); }
|
|
button:focus-visible, a:focus-visible, input:focus-visible, summary:focus-visible {
|
|
outline: 2px solid var(--mauve);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
.share-links {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
justify-content: center;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
margin: 0.5rem 0 1rem;
|
|
}
|
|
|
|
.share-link {
|
|
display: inline-block;
|
|
padding: 0.45rem 0.8rem;
|
|
border: 1px solid var(--overlay);
|
|
border-radius: 4px;
|
|
color: var(--text);
|
|
text-decoration: none;
|
|
}
|
|
|
|
.share-link:hover, .share-link:focus-visible { background: var(--surface); }
|
|
.share-link[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }
|
|
#mastodon-instance { max-width: 100%; }
|
|
#share-controls label { display: block; }
|
|
|
|
.error { color: var(--red); }
|
|
|
|
#chat-section {
|
|
padding: 0;
|
|
text-align: left;
|
|
background: var(--mantle);
|
|
border: 1px solid var(--surface);
|
|
border-radius: 18px;
|
|
box-shadow: 0 12px 32px #11111b40;
|
|
overflow: hidden;
|
|
}
|
|
.chat-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: flex-start;
|
|
gap: 1rem;
|
|
padding: 1.75rem;
|
|
background: linear-gradient(120deg, #cba6f710, transparent 75%);
|
|
border-bottom: 1px solid var(--surface);
|
|
}
|
|
.chat-eyebrow { margin: 0 0 0.65rem; font-size: 0.65rem; letter-spacing: 0.18em; color: var(--mauve); font-weight: 700; }
|
|
#chat-heading { margin: 0; font-size: clamp(1.4rem, 2.5vw, 1.9rem); line-height: 1.2; letter-spacing: -0.03em; }
|
|
.chat-description { margin: 0.7rem 0 0; font-size: 0.85rem; color: var(--subtext); line-height: 1.6; }
|
|
.chat-badge { flex-shrink: 0; padding: 0.35rem 0.6rem; border: 1px solid #a6e3a130; border-radius: 20px; color: var(--green); background: #a6e3a109; font-size: 0.65rem; }
|
|
.chat-feed { padding: 1rem 1.25rem; min-height: 280px; }
|
|
.chat-feed-label { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem; color: var(--subtext); font-size: 0.65rem; padding: 0.25rem 0.25rem 0.9rem; }
|
|
.chat-feed-label span:first-child { text-transform: uppercase; letter-spacing: 0.12em; }
|
|
#chat-messages {
|
|
list-style: none;
|
|
margin: 0;
|
|
padding: 0 0.25rem;
|
|
max-height: 360px;
|
|
overflow-y: auto;
|
|
scrollbar-width: thin;
|
|
scrollbar-color: var(--surface) transparent;
|
|
}
|
|
#chat-messages:empty { display: none; }
|
|
#chat-messages li { display: flex; align-items: flex-start; gap: 0.65rem; padding: 0.7rem 0; }
|
|
.chat-avatar { display: grid; place-items: center; flex: 0 0 32px; width: 32px; height: 32px; border-radius: 11px; background: #cba6f71a; color: var(--mauve); font-weight: 700; font-size: 0.8rem; }
|
|
#chat-messages li:nth-child(3n + 2) .chat-avatar { background: #94e2d51a; color: var(--teal); }
|
|
#chat-messages li:nth-child(3n) .chat-avatar { background: #fab3871a; color: var(--peach); }
|
|
.chat-message-content { min-width: 0; flex: 1; }
|
|
.chat-heading { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.25rem 0.6rem; padding: 0.1rem 0 0.35rem; }
|
|
.chat-heading strong { color: var(--text); font-size: 0.8rem; overflow-wrap: anywhere; }
|
|
.chat-heading time { color: var(--subtext); font-size: 0.65rem; }
|
|
#chat-messages p { margin: 0; padding: 0.7rem 0.85rem; border: 1px solid #45475a60; border-radius: 0 12px 12px 12px; background: var(--base); font-size: 0.9rem; line-height: 1.55; overflow-wrap: anywhere; }
|
|
.chat-composer { border-top: 1px solid var(--surface); padding: 1.25rem 1.5rem; background: #11111b35; }
|
|
#chat-form { display: block; }
|
|
#chat-form label { display: block; margin-bottom: 0.6rem; font-size: 0.75rem; font-weight: 600; color: var(--subtext); }
|
|
.chat-input-row { display: flex; align-items: center; gap: 0.5rem; padding: 0.4rem; background: var(--base); border: 1px solid var(--surface); border-radius: 12px; }
|
|
.chat-input-row:focus-within { border-color: var(--mauve); }
|
|
#chat-input { flex: 1; min-width: 0; width: 100%; border: none; background: transparent; padding: 0.5rem; font-size: 0.85rem; }
|
|
#chat-input:focus-visible { outline-offset: -2px; border-radius: 6px; }
|
|
#chat-input::placeholder { color: var(--subtext); }
|
|
#chat-form #chat-send { display: flex; align-items: center; gap: 0.65rem; min-height: 40px; border: none; border-radius: 8px; background: var(--mauve); color: var(--crust); font-weight: 700; font-size: 0.8rem; }
|
|
#chat-send span { font-size: 1.2rem; }
|
|
#chat-form #chat-send:hover { background: var(--lavender); }
|
|
#chat-send:disabled { opacity: 0.5; cursor: wait; }
|
|
#chat-help { margin: 0.7rem 0 0; color: var(--subtext); font-size: 0.65rem; line-height: 1.6; }
|
|
#chat-status { margin: 0; padding: 4rem 1rem; text-align: center; color: var(--subtext); font-size: 0.85rem; line-height: 1.6; }
|
|
#chat-login { margin: 0; color: var(--lavender); font-size: 0.85rem; line-height: 1.6; }
|
|
#chat-status:empty, #chat-error:empty { display: none; }
|
|
|
|
#rules { text-align: left; font-size: 0.9rem; color: var(--subtext); }
|
|
|
|
@media (max-width: 760px) {
|
|
main { display: block; padding: 0.5rem; }
|
|
.game-panel {
|
|
top: 0;
|
|
display: grid;
|
|
grid-template-columns: minmax(0, 1fr) auto;
|
|
gap: 0.25rem 0.5rem;
|
|
padding: 0.5rem;
|
|
border-radius: 0 0 12px 12px;
|
|
box-shadow: 0 6px 16px var(--crust);
|
|
}
|
|
.game-panel h1 { grid-column: 1 / -1; margin: 0; font-size: 1rem; }
|
|
.game-panel section { margin: 0; }
|
|
.game-panel #countdown { font-size: clamp(1.4rem, 6vw, 2.5rem); }
|
|
#zone-label { font-size: 0.7rem; letter-spacing: 0.1em; }
|
|
#zone-bar { margin: 0.35rem auto; }
|
|
.game-panel #history-global-summary { margin: 0.25rem 0; font-size: 0.7rem; }
|
|
#the-button { width: 84px; height: 84px; font-size: 1rem; border-width: 4px; }
|
|
#button-section { align-self: center; }
|
|
#press-result { max-width: 110px; margin: 0.4rem 0 0; font-size: 0.7rem; }
|
|
#press-result:empty { display: none; }
|
|
.section-browser { margin-top: 1rem; }
|
|
.chat-header { padding: 1.25rem; flex-wrap: wrap; }
|
|
.chat-feed { padding: 0.9rem; min-height: 230px; }
|
|
.chat-composer { padding: 1rem; }
|
|
}
|