slick-connections.pages.sei.../src/App.css
2025-04-05 21:52:33 -07:00

217 lines
4.6 KiB
CSS

*, :before, :after {
box-sizing: inherit;
}
:root {
box-sizing: border-box;
font-family: Inter, Avenir, Helvetica, Arial, sans-serif;
font-size: 16px;
line-height: 24px;
font-weight: 400;
--background-lightness: 90%;
--background-chroma: 0;
--background-hue: 0;
--foreground-lightness: 10%;
--foreground-chroma: 0;
--foreground-hue: 0;
--color-foreground: lch(var(--foreground-lightness) var(--foreground-chroma) var(--foreground-hue));
--color-background: lch(var(--background-lightness) var(--background-chroma) var(--background-hue));
--color-foreground-trace: lch(var(--foreground-lightness) var(--foreground-chroma) var(--foreground-hue) / 0.1);
--color-foreground-faint: lch(var(--foreground-lightness) var(--foreground-chroma) var(--foreground-hue) / 0.25);
color: var(--color-foreground);
background-color: var(--color-background);
/* --group-green: lch(74.83% 54.18 117.22);
--group-blue: lch(78.8% 23.7 270.9);
--group-yellow: lch(89.36% 57.75 90.6);
--group-purple: lch(61.69% 41.01 319.57); */
--group-green: lch(74.83% 54.18 117.22);
--group-blue: lch(75% 23.7 270.9);
--group-yellow: lch(85% 57.75 90.6);
--group-purple: lch(65% 41.01 319.57);
font-synthesis: none;
text-rendering: optimizeLegibility;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-webkit-text-size-adjust: 100%;
}
@media (prefers-color-scheme: dark) {
:root {
--background-lightness: 10%;
--background-chroma: 0;
--background-hue: 0;
--foreground-lightness: 90%;
--foreground-chroma: 0;
--foreground-hue: 0;
--group-blue: lch(30% 23.7 270.9);
--group-green: lch(30% 54.18 117.22);
--group-yellow: lch(30% 57.75 90.6);
--group-purple: lch(30% 41.01 319.57);
}
}
.container {
margin: 0;
padding-top: 10vh;
display: flex;
flex-direction: column;
justify-content: center;
text-align: center;
}
.row {
display: flex;
justify-content: center;
}
.puzzle {
--unit: min(0.5rem, 1.15vw);
display: flex;
flex-direction: column;
gap: calc(1 * var(--unit));
font-size: calc(3 * var(--unit));
width: calc((20 * 4 + 3) * var(--unit));
margin: 0 auto;
}
.puzzle-header {
display: flex;
align-items: center;
flex-direction: row;
> h1 {
flex-grow: 1;
text-align: left;
margin: 0;
}
}
.puzzle-header-actions {
display: flex;
flex-direction: row;
gap: calc(1 * var(--unit));
}
.puzzle-row {
display: flex;
justify-content: center;
height: calc(15 * var(--unit));
gap: calc(1 * var(--unit));
}
.puzzle-item {
position: relative;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
user-select: none;
flex-basis: 0;
flex-grow: 1;
padding: calc(1 * var(--unit));
border-radius: calc(1 * var(--unit));
background-color: var(--color-foreground-trace);
font-size: calc(5 * var(--unit));
font-weight: 600;
}
.badge {
position: absolute;
top: 0;
left: 0;
filter: grayscale(100%);
}
.puzzle-item.is-selected {
background-color: var(--color-foreground-faint);
outline: calc(0.33 * var(--unit)) solid var(--color-foreground);
}
.puzzle-group {
flex-grow: 1;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
border-radius: calc(1 * var(--unit));
font-weight: 500;
&[data-level="0"] {
background-color: var(--group-yellow);
}
&[data-level="1"] {
background-color: var(--group-green);
}
&[data-level="2"] {
background-color: var(--group-blue);
}
&[data-level="3"] {
background-color: var(--group-purple);
}
}
.puzzle-group-name {
font-weight: 700;
}
.puzzle-group-members {
font-weight: 500;
}
.puzzle-actions {
display: flex;
margin-top: calc(1 * var(--unit));
gap: calc(1 * var(--unit));
}
.puzzle-actions-secondary {
display: flex;
flex-direction: column;
gap: calc(1 * var(--unit));
min-width: calc(20 * var(--unit));
}
select {
font-size: 0.8em;
line-height: 1;
margin: 0;
padding: 1em;
}
a {
font-weight: 500;
color: #646cff;
text-decoration: inherit;
}
a:hover {
color: #535bf2;
}
h1 {
text-align: center;
}
button {
appearance: none;
overflow: visible;
min-width: 2em;
background: var(--color-foreground-faint);
color: var(--color-foreground);
font-size: inherit;
border: none;
padding: 0.5em;
border-radius: calc(1 * var(--unit, 0.5em));
}
button:disabled {
opacity: 0.25;
}
button:focus-visible, button:hover {
box-shadow: 0 0 3em -1.5em inset var(--color-foreground)
}
button:active {
box-shadow: 0 0 3em -1.5em inset var(--color-foreground)
}
#submitButton {
flex-grow: 1;
}