:root {
  color-scheme: dark;
  --background: #10191e;
  --surface: #19282e;
  --line: #3b5259;
  --text: #f1f7f5;
  --muted: #bacdc9;
  --accent: #a6eacc;
  font-family: system-ui, sans-serif;
  line-height: 1.6;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--background); color: var(--text); }
a { color: var(--accent); text-underline-offset: .24em; }
a:hover { color: var(--text); }
:focus-visible { outline: 3px solid #fcd58e; outline-offset: 4px; }
h1, h2, p { margin: 0; }
h1, h2 { line-height: 1.13; }
h1 { font-size: clamp(2.65rem, 7vw, 5.5rem); letter-spacing: -.055em; }
h2 { font-size: clamp(1.2rem, 2.2vw, 1.55rem); letter-spacing: -.025em; }
p { color: var(--muted); }
.wrap { width: min(76rem, calc(100% - 2rem)); margin-inline: auto; }
.skip { position: absolute; top: .75rem; left: .75rem; padding: .7rem; background: var(--background); z-index: 1; }
.skip:not(:focus) { transform: translateY(-200%); }
.site-header { border-bottom: 1px solid var(--line); }
.header-row, nav, .site-footer { display: flex; align-items: center; flex-wrap: wrap; }
.header-row, .site-footer { justify-content: space-between; gap: .4rem 1.5rem; padding-block: .85rem; }
.brand, nav a { text-decoration: none; }
.brand { color: var(--text); font-weight: 750; font-size: 1.1rem; }
.brand span { color: var(--muted); font-weight: 500; }
nav { gap: .25rem; }
nav a { padding: .55rem .65rem; color: var(--muted); }
nav a:hover, nav a[aria-current="page"] { color: var(--accent); text-decoration: underline; }
.intro { padding-block: clamp(2.75rem, 8vw, 6.5rem) clamp(1.8rem, 4vw, 3rem); }
.intro p { max-width: 59ch; margin-top: .9rem; font-size: 1.08rem; }
.filters { display: flex; flex-wrap: wrap; gap: .8rem 1rem; align-items: end; margin-bottom: 1.4rem; }
.field { display: grid; gap: .25rem; min-width: 0; }
.field:first-child { width: min(100%, 25rem); }
.field label, .count, .category, .media-label { font-size: .9rem; }
select { width: 100%; min-width: 0; padding: .65rem .8rem; color: var(--text); background: var(--surface); border: 1px solid #69858a; border-radius: .35rem; font: inherit; }
.count { margin: 0 0 .65rem auto; }
.gallery, .services { margin: 0; padding: 0; display: grid; gap: 1rem; list-style: none; }
.gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.services { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: .65rem; overflow: hidden; }
.card:target { border-color: var(--accent); }
.media {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 16 / 10;
  background-color: var(--terrain);
  background-image: repeating-radial-gradient(ellipse at 28% 100%, transparent 0 1rem, #effff52c 1.05rem 1.12rem, transparent 1.17rem 1.8rem),
    linear-gradient(150deg, #10191e30, #10191eaa);
}
.tone-property { --terrain: #306b67; }
.tone-aerial { --terrain: #416883; }
.tone-construction { --terrain: #856447; }
.tone-mapping { --terrain: #597541; }
.tone-events { --terrain: #725679; }
.tone-other { --terrain: #466775; }
.media-label { background: #10191e; padding: .35rem .7rem; border: 1px solid #7b9594; border-radius: .25rem; }
.media img, .media video { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; }
.media video { object-fit: contain; background: #0a1014; }
.media video:focus-visible { outline-offset: -4px; }
.card-copy, .service { padding: clamp(1rem, 2.5vw, 1.65rem); }
.category { margin-bottom: .3rem; color: var(--accent); }
.service { display: flex; flex-direction: column; align-items: flex-start; gap: .85rem; }
.service a { margin-top: auto; padding-block: .35rem; }
.service .brief { color: var(--text); }
.empty { padding: 1.3rem; border: 1px solid var(--line); border-radius: .4rem; }
.contact { margin-block: clamp(2.2rem, 6vw, 5rem); padding: clamp(1.1rem, 4vw, 2.3rem); border: 1px solid var(--line); border-radius: .65rem; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; }
.contact p { margin-top: .4rem; }
.button { display: inline-block; padding: .7rem 1rem; background: var(--accent); color: #11291f; font-weight: 700; border-radius: .35rem; text-decoration: none; }
.button:hover { color: #11291f; background: #d1f8e6; }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); }

@media (max-width: 55rem) {
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 36rem) {
  .gallery, .services { grid-template-columns: minmax(0, 1fr); }
  .count { flex-basis: 100%; margin: 0; }
}
