Portal/rsconcept/frontend/src/styling/setup.css

172 lines
2.7 KiB
CSS
Raw Normal View History

2024-06-07 20:17:03 +03:00
/**
* Module: Basic styling setup.
*/
2025-02-20 20:22:05 +03:00
@import './constants.css' layer(base);
2025-03-10 16:01:40 +03:00
/* Uncomment to debug layering and overflow */
/* *,
*::after,
*::before {
background: hsla(135, 50%, 50%, 0.05) !important;
outline: 2px solid hotpink !important;
:focus,
:focus-visible,
:focus-within {
outline: 2px solid hotpink !important;
}
} */
2025-02-20 20:22:05 +03:00
@layer utilities {
*,
*::after,
*::before {
box-sizing: border-box;
}
2025-02-22 11:22:34 +03:00
}
@layer base {
*,
::after,
::before,
::backdrop,
::file-selector-button {
border-color: var(--clr-prim-400);
}
2024-10-23 23:22:35 +03:00
2025-02-20 20:22:05 +03:00
html {
-webkit-text-size-adjust: none;
-moz-text-size-adjust: none;
text-size-adjust: none;
2024-10-03 16:26:00 +03:00
2025-02-20 20:22:05 +03:00
hanging-punctuation: first last;
color-scheme: dark light;
2024-10-03 16:26:00 +03:00
2025-02-20 20:22:05 +03:00
interpolate-size: allow-keywords;
}
2024-06-08 21:44:30 +03:00
2025-02-20 20:22:05 +03:00
body {
margin: 0px;
padding: 0px;
overflow-x: hidden;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
[data-color-scheme='dark'] {
color-scheme: dark;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
[data-color-scheme='light'] {
color-scheme: light;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
/* Default scroll behavior */
@media (prefers-reduced-motion: no-preference) {
:has(:target) {
scroll-behavior: smooth;
scroll-padding-top: var(--scroll-padding);
}
2024-06-07 20:17:03 +03:00
}
2025-02-20 20:22:05 +03:00
:root {
interpolate-size: allow-keywords;
2024-10-23 23:22:35 +03:00
2025-02-20 20:22:05 +03:00
font-size: var(--font-size-base);
line-height: var(--line-height);
font-family: var(--font-main);
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
color: var(--clr-prim-999);
border-color: var(--clr-prim-400);
background-color: var(--clr-prim-100);
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
@media only screen and (max-width: 639px) {
:root {
font-size: var(--font-size-sm);
}
2024-06-07 20:17:03 +03:00
}
2025-02-20 20:22:05 +03:00
:focus,
:focus-visible,
:focus-within {
outline-width: 2px;
outline-style: solid;
outline-color: transparent;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
::selection {
background: var(--clr-sec-100);
2025-02-26 00:10:23 +03:00
}
tr:hover ::selection {
background: var(--clr-warn-100);
2024-06-07 20:17:03 +03:00
}
2025-02-20 20:22:05 +03:00
::placeholder {
color: var(--clr-prim-600);
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
/* Wrapping headers */
h1,
h2,
h3,
h4,
h5,
h6 {
text-wrap: balance;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
/* Limit text lines and setup wrapping */
p,
li {
max-width: var(--text-max-width);
text-wrap: pretty;
}
2024-06-07 20:17:03 +03:00
2025-02-20 20:22:05 +03:00
div:not(.dense) > p:not(:last-child) {
margin-bottom: 0.5rem;
}
2024-06-07 20:17:03 +03:00
h1 {
font-weight: 600;
font-size: 1.125rem;
line-height: 1.75rem;
text-align: center;
2024-06-07 20:17:03 +03:00
}
h2 {
font-weight: 600;
text-align: center;
&:not(:first-child) {
:not([role='manuals']) & {
margin-top: 0.5rem;
}
[role='manuals'] & {
margin-top: 0.75rem;
margin-bottom: 0.5rem;
}
2024-10-03 16:26:00 +03:00
}
2024-06-07 20:17:03 +03:00
}
b {
font-weight: 600;
2024-06-07 20:17:03 +03:00
}
code {
font-family: var(--font-math);
}
li {
list-style-position: inside;
}
li::marker {
2024-08-22 15:28:59 +03:00
content: '\2009';
2024-06-07 20:17:03 +03:00
}
}
2025-02-21 21:13:40 +03:00
@utility border {
border-radius: 0.25rem;
}