479 lines
12 KiB
CSS
479 lines
12 KiB
CSS
@import './_schedule.css';
|
|
@import './_gallery.css';
|
|
|
|
/*
|
|
* 40C3 "MODEL_CITIZENS" design, after the 40C3 styleguide.
|
|
* Key colours: green (0), paper (A) and ink (B); the other colours are accents.
|
|
* Dark: ink background, paper text, green accents.
|
|
* Light: #e2eed6 background and #010801 text (picked for this site, not from the styleguide).
|
|
* WCAG AA contrast: on ink every palette colour works as text, but on the light background
|
|
* only the foreground does. So in the light scheme green is only ever a fill or a line,
|
|
* with foreground-coloured text on it.
|
|
*/
|
|
:root {
|
|
--c40-green: #75b44b;
|
|
--c40-teal: #15ada3;
|
|
--c40-periwinkle: #9fa4e8;
|
|
--c40-lilac: #c892d6;
|
|
--c40-pink: #ee5da2;
|
|
--c40-coral: #ea6f82;
|
|
--c40-orange: #f88a30;
|
|
--c40-amber: #ffbc40;
|
|
--c40-paper: #ebedf0;
|
|
--c40-ink: #001300;
|
|
|
|
--c40-light-bg: #e2eed6;
|
|
--c40-light-fg: #010801;
|
|
|
|
/* Text on green and amber fills. */
|
|
--c40-on-fill: light-dark(var(--c40-light-fg), var(--c40-ink));
|
|
|
|
/* Hack has a large x-height, so 16px reads about as big as the old 18px serif. */
|
|
--base-font-size: 16;
|
|
|
|
/* Jersey 10 is a small pixel font; it needs about this much more size to match Hack. */
|
|
--display-scale: 1.45;
|
|
|
|
--ff-body: 'Hack', ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
|
|
--ff-headings: var(--ff-body);
|
|
--ff-alt: var(--ff-body);
|
|
--ff-monospace: var(--ff-body);
|
|
--ff-display: 'Jersey 10', var(--ff-body);
|
|
|
|
/* Square corners, like the pixel boxes in the styleguide. */
|
|
--radius-xl: 0;
|
|
--radius-l: 0;
|
|
--radius-m: 0;
|
|
--radius-s: 0;
|
|
--radius-xs: 0;
|
|
|
|
--color-body-bg: light-dark(var(--c40-light-bg), var(--c40-ink));
|
|
--color-page-bg: transparent;
|
|
--color-header-bg: transparent;
|
|
--color-footer-bg: transparent;
|
|
|
|
--color-text: light-dark(var(--c40-light-fg), var(--c40-paper));
|
|
--color-text-bg: light-dark(var(--c40-light-bg), var(--c40-ink));
|
|
--color-text-meta: light-dark(
|
|
color-mix(in srgb, var(--c40-light-fg) 78%, var(--c40-light-bg)),
|
|
color-mix(in srgb, var(--c40-paper) 80%, var(--c40-ink))
|
|
);
|
|
--color-headings: var(--color-text);
|
|
--color-code: var(--color-text);
|
|
|
|
--color-link: light-dark(var(--c40-light-fg), var(--c40-green));
|
|
--color-link-visited: var(--color-link);
|
|
--color-link-hover: var(--c40-on-fill);
|
|
--color-link-active: var(--c40-on-fill);
|
|
|
|
--color-button: var(--c40-green);
|
|
--color-button-text: var(--c40-on-fill);
|
|
--color-button-hover: var(--c40-amber);
|
|
--color-button-text-hover: var(--c40-on-fill);
|
|
|
|
--color-border: light-dark(var(--c40-light-fg), var(--c40-green));
|
|
--color-border-light: var(--color-border);
|
|
--color-border-dark: var(--color-border);
|
|
|
|
--color-mobile-menu: var(--color-body-bg);
|
|
--color-mobile-menu-cover: rgb(0 19 0 / 0.6);
|
|
|
|
/* Height of the mobile menu bar at the bottom of the screen. */
|
|
--mobile-bar-h: 3.25rem;
|
|
|
|
--color-accent: var(--c40-green);
|
|
--color-highlight: var(--c40-amber);
|
|
--color-mark-highlight: var(--c40-amber);
|
|
--color-row-odd: light-dark(
|
|
color-mix(in srgb, var(--c40-light-fg) 7%, var(--c40-light-bg)),
|
|
color-mix(in srgb, var(--c40-paper) 9%, var(--c40-ink))
|
|
);
|
|
|
|
--color-info: var(--c40-teal);
|
|
--color-success: var(--c40-green);
|
|
--color-warning: var(--c40-amber);
|
|
--color-error: var(--c40-coral);
|
|
|
|
--color-focus: light-dark(var(--c40-light-fg), var(--c40-amber));
|
|
}
|
|
|
|
:focus-visible {
|
|
outline: 3px solid var(--color-focus);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
/* Long URLs, the e-mail address and long German words would otherwise make pages wider than a
|
|
phone screen, and mobile browsers then zoom the whole page out. Links get `anywhere` because
|
|
break-word doesn't shrink the theme's table-style lists (`article > ul`). */
|
|
body {
|
|
overflow-wrap: break-word;
|
|
}
|
|
|
|
.layout__main a {
|
|
overflow-wrap: anywhere;
|
|
}
|
|
|
|
/* Links: underlined, and a green chip with dark text on hover and focus (AA in both schemes). */
|
|
a:hover,
|
|
a:focus-visible {
|
|
background: var(--c40-green);
|
|
}
|
|
|
|
.header__logo:hover,
|
|
.header__logo:focus-visible {
|
|
background: none;
|
|
}
|
|
|
|
mark {
|
|
color: var(--c40-on-fill);
|
|
}
|
|
|
|
/* Headings: Jersey 10 for the big ones. h1 is the "loud header" (filled chip), h3 and below
|
|
are Hack Bold, h3 underlined like the styleguide's subheads. */
|
|
h1,
|
|
h2,
|
|
.header__intro_headline {
|
|
font-family: var(--ff-display);
|
|
font-weight: 400;
|
|
letter-spacing: 0;
|
|
line-height: 1;
|
|
}
|
|
|
|
h1,
|
|
.header__intro_headline {
|
|
width: fit-content;
|
|
max-width: 100%;
|
|
padding: 0.12em 0.3em 0.2em;
|
|
background: var(--c40-green);
|
|
color: var(--c40-on-fill);
|
|
font-size: calc(var(--fs-xxl) * var(--display-scale));
|
|
}
|
|
|
|
h2 {
|
|
color: light-dark(var(--c40-light-fg), var(--c40-green));
|
|
font-size: calc(var(--fs-xl) * var(--display-scale));
|
|
}
|
|
|
|
h3 {
|
|
font-size: var(--fs-l);
|
|
text-decoration: underline;
|
|
text-decoration-thickness: 2px;
|
|
text-underline-offset: 0.25em;
|
|
}
|
|
|
|
h2 a {
|
|
margin-right: 2em;
|
|
}
|
|
|
|
.title-post-date {
|
|
margin-left: 0;
|
|
color: var(--color-text-meta);
|
|
font-family: var(--ff-body);
|
|
font-size: var(--fs-s);
|
|
letter-spacing: 0;
|
|
}
|
|
|
|
/* Shared branding; inner pages keep their own main h1. */
|
|
.header {
|
|
color: var(--color-text);
|
|
}
|
|
|
|
.header__intro_headline {
|
|
margin: 0 0 0.5rem;
|
|
}
|
|
|
|
.header__site-link {
|
|
color: inherit;
|
|
}
|
|
|
|
.header__intro_text {
|
|
font-family: var(--ff-body);
|
|
}
|
|
|
|
/* Main menu: quiet (outlined) chips, the current page and hover are filled green. */
|
|
.main-menu a,
|
|
.mobile-nav__navbar a {
|
|
padding: 0.15rem 0.75rem;
|
|
background: transparent;
|
|
box-shadow: inset 0 0 0 1px currentcolor;
|
|
color: var(--color-text);
|
|
text-decoration: none;
|
|
|
|
&:hover,
|
|
&:focus-visible,
|
|
&[aria-current] {
|
|
background: var(--c40-green);
|
|
box-shadow: none;
|
|
color: var(--c40-on-fill);
|
|
text-decoration: none;
|
|
}
|
|
}
|
|
|
|
/* Nav row (layouts/_partials/menu.html): menu chips, and the language switch on the right. */
|
|
.nav-bar__row {
|
|
display: flex;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
gap: 0.5rem;
|
|
}
|
|
|
|
.nav-bar .header__region {
|
|
margin-inline-start: auto;
|
|
}
|
|
|
|
/* On small screens mobilemenu.js hides both parts; drop the then empty row too. */
|
|
.nav-bar:has(.main-menu[hidden]) {
|
|
display: none;
|
|
}
|
|
|
|
/* Language switch: a periwinkle chip with the icon, so it doesn't read as a menu entry. */
|
|
.language-selector {
|
|
font-size: inherit;
|
|
|
|
a {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.45em;
|
|
padding: 0.15rem 0.75rem;
|
|
background: var(--c40-amber);
|
|
color: var(--c40-on-fill);
|
|
text-decoration: none;
|
|
|
|
&:hover,
|
|
&:focus-visible {
|
|
background: var(--c40-green);
|
|
color: var(--c40-on-fill);
|
|
}
|
|
}
|
|
}
|
|
|
|
.language-icon {
|
|
inline-size: 1.1em;
|
|
block-size: 1.1em;
|
|
margin: 0;
|
|
fill: currentcolor;
|
|
}
|
|
|
|
/*
|
|
* Mobile menu (below 667px, switched on by the theme's mobilemenu.js): the toggle is a green
|
|
* bar fixed to the bottom of the screen. It opens a panel that slides up out of the bar, sized
|
|
* to its content so the language switch and the menu chips sit right above the bar.
|
|
*/
|
|
.layout__page:has(> .mobile-nav:not([hidden])) {
|
|
padding-block-end: calc(var(--mobile-bar-h) + env(safe-area-inset-bottom, 0px));
|
|
}
|
|
|
|
/* Keep focused and scrolled-to elements clear of the bar. */
|
|
:root:has(.mobile-nav:not([hidden])) {
|
|
scroll-padding-block-end: calc(var(--mobile-bar-h) + 1rem);
|
|
}
|
|
|
|
.mobile-nav__toggle.button {
|
|
position: fixed;
|
|
inset: auto 0 0;
|
|
justify-content: center;
|
|
gap: 0.6rem;
|
|
width: auto;
|
|
block-size: calc(var(--mobile-bar-h) + env(safe-area-inset-bottom, 0px));
|
|
padding: 0 var(--gutters) env(safe-area-inset-bottom, 0px);
|
|
border: 0;
|
|
border-block-start: 2px solid var(--color-border);
|
|
background: var(--c40-green);
|
|
color: var(--c40-on-fill);
|
|
font-family: var(--ff-display);
|
|
font-size: calc(var(--fs-l) * var(--display-scale));
|
|
line-height: 1;
|
|
|
|
/* Touch screens keep :hover after a tap, so only the open state changes the colour. */
|
|
&:hover,
|
|
&:focus-visible,
|
|
&:active {
|
|
border-color: var(--color-border);
|
|
background: var(--c40-green);
|
|
box-shadow: none;
|
|
color: var(--c40-on-fill);
|
|
}
|
|
|
|
&:focus-visible {
|
|
outline-color: var(--c40-on-fill);
|
|
outline-offset: -6px;
|
|
}
|
|
|
|
&[aria-expanded='true'] {
|
|
background: var(--c40-amber);
|
|
}
|
|
|
|
@media (hover: hover) {
|
|
&:hover {
|
|
background: var(--c40-amber);
|
|
}
|
|
}
|
|
}
|
|
|
|
.mobile-nav__hamburger {
|
|
fill: currentcolor;
|
|
}
|
|
|
|
/* The theme sizes the overlay with 100vw/100dvh, which don't match the screen when a mobile
|
|
browser zooms the page out. Size it from the screen edges instead, and anchor the panel to
|
|
the bar. */
|
|
.mobile-nav {
|
|
position: fixed;
|
|
inset: 0;
|
|
width: auto;
|
|
height: auto;
|
|
}
|
|
|
|
.mobile-nav__cover {
|
|
inset: 0;
|
|
width: auto;
|
|
height: auto;
|
|
}
|
|
|
|
.mobile-nav__sheet {
|
|
position: absolute;
|
|
inset: auto 0 calc(var(--mobile-bar-h) + env(safe-area-inset-bottom, 0px));
|
|
width: auto;
|
|
height: auto;
|
|
max-height: calc(100% - var(--mobile-bar-h) - env(safe-area-inset-bottom, 0px) - var(--spacing-l));
|
|
overflow-y: auto;
|
|
padding: var(--spacing-m) var(--gutters);
|
|
border-block-start: 2px solid var(--color-border);
|
|
/* Closed, it sits behind the bar. */
|
|
transform: translateY(100%);
|
|
|
|
[data-navopen] & {
|
|
box-shadow: none;
|
|
transform: translateY(0);
|
|
}
|
|
}
|
|
|
|
.mobile-nav__region:not(:empty) {
|
|
margin-block-end: var(--spacing-m);
|
|
}
|
|
|
|
.mobile-nav__navbar {
|
|
gap: 0.5rem;
|
|
|
|
a {
|
|
display: block;
|
|
padding: 0.5rem 0.75rem;
|
|
}
|
|
}
|
|
|
|
/* Buttons: flat fills. */
|
|
.button {
|
|
background: var(--color-button);
|
|
border-color: var(--color-button);
|
|
|
|
&:hover,
|
|
&:focus-visible {
|
|
background: var(--color-button-hover);
|
|
border-color: var(--color-button-hover);
|
|
}
|
|
}
|
|
|
|
table,
|
|
th,
|
|
td {
|
|
border: 1px solid;
|
|
}
|
|
|
|
th,
|
|
td {
|
|
padding: 3px 6px;
|
|
font-variant-numeric: tabular-nums;
|
|
}
|
|
|
|
/*
|
|
* Footer: a pixel ruler after the styleguide's boxes pattern instead of a plain line.
|
|
* One frame (top/bottom borders) with a divider per cell; the width snaps down to
|
|
* whole cells and the divider tile repeats into the end padding to close the last box,
|
|
* so there are no cut-off cells or doubled lines. Without round(), `round` repeat
|
|
* stretches the cells to fit instead.
|
|
*/
|
|
.footer {
|
|
--ruler-line: 0.125rem;
|
|
--ruler-cell: 0.75rem;
|
|
|
|
border-block-start: 0;
|
|
|
|
&::before {
|
|
content: '';
|
|
display: block;
|
|
box-sizing: border-box;
|
|
inline-size: 100%;
|
|
inline-size: calc(round(down, 100% - var(--ruler-line), var(--ruler-cell)) + var(--ruler-line));
|
|
block-size: calc(var(--ruler-cell) + var(--ruler-line));
|
|
margin-inline: auto;
|
|
margin-block-end: var(--spacing-s);
|
|
padding-inline-end: var(--ruler-line);
|
|
border-block: var(--ruler-line) solid var(--color-border);
|
|
background: linear-gradient(to right, var(--color-border) var(--ruler-line), transparent 0) 0 0 /
|
|
var(--ruler-cell) 100% round no-repeat content-box border-box;
|
|
}
|
|
}
|
|
|
|
.footer__logo {
|
|
display: block;
|
|
margin-block: var(--spacing-xs);
|
|
|
|
img {
|
|
display: block;
|
|
width: auto;
|
|
height: 3.5rem;
|
|
margin-inline: auto;
|
|
}
|
|
}
|
|
|
|
.event-logo {
|
|
display: block;
|
|
margin-block: var(--spacing-s);
|
|
|
|
img {
|
|
display: block;
|
|
width: auto;
|
|
height: 5rem;
|
|
}
|
|
}
|
|
|
|
/* Visible when focused with the keyboard; the visually-hidden class hides it otherwise. */
|
|
.skip-link:focus {
|
|
position: absolute;
|
|
inset-block-start: 0.5rem;
|
|
inset-inline-start: 0.5rem;
|
|
z-index: 100;
|
|
padding: 0.5rem 1rem;
|
|
background: var(--color-button);
|
|
color: var(--color-button-text);
|
|
}
|
|
|
|
#main-content:focus {
|
|
outline: none;
|
|
}
|
|
|
|
/* Content images with their credit, see layouts/_markup/render-image.html. */
|
|
.content-image {
|
|
margin: 1rem 0;
|
|
|
|
img {
|
|
display: block;
|
|
max-width: 100%;
|
|
height: auto;
|
|
}
|
|
}
|
|
|
|
span.content-image {
|
|
display: inline-block;
|
|
vertical-align: top;
|
|
max-width: 100%;
|
|
margin: 0 0.5rem 0.5rem 0;
|
|
}
|
|
|
|
.content-image__credit {
|
|
display: block;
|
|
margin-block-start: 0.25rem;
|
|
font-family: var(--ff-alt);
|
|
font-size: var(--fs-xs);
|
|
color: var(--color-text-meta);
|
|
}
|