:root { --fg: #333; --muted: #808080; --line: #ccc; --accent: #ED1C24; }
* { box-sizing: border-box; }
html { min-height: 100vh; }
body { margin: 0; font-family: helvetica, verdana, sans-serif; color: var(--fg); background: #f0f0f0 linear-gradient(#fff, #f0f0f0) fixed; line-height: 1.5; }
a { color: var(--muted); text-decoration: none; transition: color .3s, background-color .3s; }
a:hover { color: #000; }
.page { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.header { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding-top: 20px; margin-bottom: 20px; }
.logo img { width: 200px; height: auto; display: block; }
.menu { flex: 1; display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 4px; }
.menu a, .cats a { display: inline-block; padding: .5rem 1rem; color: #000; }
/* Equal-width menu entries, language button included. */
.menu > a, .lang summary { min-width: 6em; text-align: center; justify-content: center; box-sizing: border-box; }
.menu a.selected, .menu a:hover, .cats a.selected, .cats a:hover { color: #fff; background: var(--fg); }
.lang { position: relative; }
.lang summary { list-style: none; display: inline-flex; align-items: center; gap: .45em; cursor: pointer; padding: .5rem 1rem; color: var(--muted); user-select: none; }
.lang summary::-webkit-details-marker { display: none; }
/* CSS triangle: sits exactly on the text's vertical centre, unlike a glyph. */
.lang summary::after { content: ""; border: 5px solid transparent; border-top: 7px solid currentColor; border-bottom: 0; }
.lang[open] summary, .lang summary:hover { color: #fff; background: var(--fg); }
.lang div { position: absolute; right: 0; top: 100%; z-index: 10; min-width: 100%; background: #fff; border: 1px solid var(--line); box-shadow: 0 4px 12px rgba(0,0,0,.1); }
.lang div a { display: block; white-space: nowrap; }
.cats { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 20px; }

/* Hamburger below 640px: menu collapses into a column under the header. */
.burger { display: none; margin-left: auto; width: 44px; height: 44px; cursor: pointer; position: relative; }
.burger span, .burger span::before, .burger span::after { position: absolute; width: 24px; height: 2px; background: var(--fg); transition: transform .2s, background .2s; }
.burger span { top: 21px; left: 10px; }
.burger span::before, .burger span::after { content: ""; left: 0; }
.burger span::before { top: -8px; }
.burger span::after { top: 8px; }
.nav-open:checked ~ .burger span { background: transparent; }
.nav-open:checked ~ .burger span::before { transform: translateY(8px) rotate(45deg); }
.nav-open:checked ~ .burger span::after { transform: translateY(-8px) rotate(-45deg); }
@media (max-width: 640px) {
  .burger { display: block; }
  .menu { display: none; flex-basis: 100%; flex-direction: column; align-items: stretch; gap: 0; border-top: 1px solid var(--line); padding-top: 8px; }
  .nav-open:checked ~ .menu { display: flex; }
  .menu > a, .lang summary { text-align: left; justify-content: flex-start; }
  .lang summary { display: flex; }
  .lang div { position: static; border: 0; box-shadow: none; background: none; padding-left: 1rem; }
}
h1, h2 { font-size: 110%; font-weight: normal; border-bottom: 1px solid var(--line); padding-bottom: 10px; margin: 0 0 20px; }
h1 a { color: inherit; }
.footer { margin-top: 20px; padding: 20px 0; font-size: 14px; color: var(--muted); }
.flash { padding: 10px 14px; border-left: 3px solid var(--fg); background: #fff; }
.flash.err { border-color: var(--accent); }
.hint { font-size: 14px; color: var(--muted); }

/* gallery */
.gallery { margin-bottom: 30px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.item { position: relative; display: block; background: #fff; border: 1px solid var(--line); overflow: hidden; }
.item img { display: block; width: 100%; height: auto; aspect-ratio: 5 / 4; object-fit: cover; transition: transform .3s; }
.item:hover img { transform: scale(1.04); }
.item .caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 6px 10px; font-size: 13px; color: #fff; background: rgba(0,0,0,.55); opacity: 0; transition: opacity .3s; }
.item:hover .caption { opacity: 1; }
@media (max-width: 600px) { .grid { grid-template-columns: repeat(2, 1fr); gap: 6px; } .item .caption { opacity: 1; } }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.92); display: flex; align-items: center; justify-content: center; touch-action: pan-y; }
.lb[hidden] { display: none; }
.lb-figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.lb-img { max-width: 100vw; max-height: 100vh; object-fit: contain; }
.lb-figure:has(.lb-cap:not(:empty)) .lb-img { max-height: calc(100vh - 70px); }
.lb-cap { color: #ddd; font-size: 14px; padding: 10px 16px; text-align: center; max-width: 800px; }
.lb-cap b { color: #fff; display: block; }
.lb button { position: absolute; background: none; border: 0; color: #fff; font-size: 40px; line-height: 1; cursor: pointer; padding: 10px 16px; opacity: .7; }
.lb button:hover { opacity: 1; }
.lb-close { top: 6px; right: 10px; }
.lb-prev { left: 0; top: 50%; transform: translateY(-50%); }
.lb-next { right: 0; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; top: 16px; left: 16px; color: #aaa; font-size: 14px; }

/* forms */
.contact { max-width: 600px; }
.contact label { display: block; font-size: 14px; margin-bottom: 14px; }
.contact label.check { display: flex; gap: 8px; align-items: center; }
.contact input[type=text], .contact input[type=email], .contact textarea, .contact select {
  display: block; width: 100%; margin-top: 5px; padding: 8px; font: inherit; border: 1px solid var(--line); background: #efefef; }
.contact input[type=file] { display: block; margin-top: 5px; }
button, .button { font: inherit; padding: .5rem 1.2rem; border: 1px solid var(--fg); background: var(--fg); color: #fff; cursor: pointer; }
button:hover { background: #000; }
button.danger { background: #fff; color: var(--accent); border-color: var(--accent); }
button.linklike { background: none; border: 0; padding: 0; color: var(--muted); text-decoration: underline; cursor: pointer; }
form.inline { display: inline; }
.hp { position: absolute; left: -9999px; }
.cf-turnstile { margin-bottom: 14px; }
