/* TRAS — ateliér architektury a interiérů
   Modernised front-end. Aesthetic kept: near-black void, small muted grey type,
   one dim band of shifting colour, generous emptiness. */

:root {
  --bg: #080c0a;
  --panel: #0c110f;
  --fg: #7c7f7d;
  --fg-dim: #4a4d4b;
  --fg-bright: #a9abaa;
  --line: #1c211f;
  --accent: #9a9c9b;
  --maxw: 1120px;
  --gap: clamp(28px, 5vw, 56px);
  --font: "Trebuchet MS", "Segoe UI", Tahoma, Verdana, "DejaVu Sans", sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  letter-spacing: .02em;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--fg); text-decoration: none; transition: color .18s ease; }
a:hover, a:focus-visible { color: var(--fg-bright); }
img { display: block; max-width: 100%; height: auto; }

:focus-visible { outline: 1px solid var(--accent); outline-offset: 3px; }

.skip {
  position: fixed; top: 0; left: 0; z-index: 100;
  padding: 10px 16px; background: var(--panel); color: var(--fg-bright);
  transform: translateY(-120%); transition: transform .2s ease;
}
.skip:focus { transform: translateY(0); }

/* ---------- shell ---------- */

.page {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: clamp(16px, 4vw, 40px) clamp(16px, 5vw, 56px) 64px;
}

.banner {
  position: relative;
  height: clamp(84px, 17vw, 168px);
  margin-bottom: var(--gap);
  overflow: hidden;
}
.banner__slide {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center 42%;
  filter: saturate(.7) brightness(.82) contrast(1.02);
  opacity: 0;
  animation: banner 48s linear infinite;
}
.banner__slide:nth-child(1) { animation-delay:   0s; opacity: 1; }
.banner__slide:nth-child(2) { animation-delay: -32s; }
.banner__slide:nth-child(3) { animation-delay: -16s; }
.banner::after {              /* keep it dim / near-subliminal */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(var(--bg), transparent 45%, transparent 55%, var(--bg)),
              rgba(8, 12, 10, .42);
}
@keyframes banner {
  0%   { opacity: 0; }
  6%   { opacity: 1; }
  33%  { opacity: 1; }
  40%  { opacity: 0; }
  100% { opacity: 0; }
}

/* ---------- layout ---------- */

.layout {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: var(--gap);
  align-items: start;
}

/* ---------- navigation ---------- */

.nav__toggle, .nav__brand { display: none; }

.menu, .submenu { list-style: none; margin: 0; padding: 0; }
.menu > li { margin: 0 0 .5em; }
.menu a { display: inline-block; padding: 2px 0; }
.menu a.is-active { color: var(--fg-bright); font-weight: 700; }

.submenu {
  overflow: hidden;
  max-height: 0;
  margin-left: 1.1em;
  transition: max-height .3s ease;
}
.menu__group.is-open .submenu { max-height: 40em; }
.submenu li { margin: .28em 0; }
.submenu a { font-size: 13px; color: var(--fg-dim); }
.submenu a:hover, .submenu a.is-active { color: var(--fg-bright); }

/* ---------- content ---------- */

.content { min-height: 60vh; }
.content:focus { outline: none; }

.view { animation: fade .3s ease both; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.view__title {
  font-size: 14px; font-weight: 700; color: var(--fg-bright);
  margin: 0 0 1.4em; letter-spacing: .06em;
}

.view--text { max-width: 46ch; }
.lede { margin: 0 0 1.4em; }
.view--text strong { color: var(--fg-bright); font-weight: 700; }

.index { list-style: none; margin: 0; padding: 0; columns: 2; max-width: 12em; }
.index li { margin: .3em 0; }

.links { list-style: none; margin: 1.4em 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: .4em 1.4em; }
.links a { color: var(--fg-dim); }
.links a:hover { color: var(--fg-bright); }

.contact { font-style: normal; }
.contact p { margin: 0 0 1.2em; }
.contact__meta { color: var(--fg-dim); }

/* ---------- gallery ---------- */

.grid { columns: 3 200px; column-gap: 10px; }
.shot { margin: 0 0 10px; break-inside: avoid; }
.shot__btn {
  display: block; width: 100%; padding: 0; border: 0; background: none;
  cursor: zoom-in; line-height: 0;
}
.shot__btn img { width: 100%; transition: opacity .18s ease, filter .18s ease;
  filter: saturate(.9); }
.shot__btn:hover img, .shot__btn:focus-visible img { opacity: .78; filter: saturate(1); }

/* ---------- footer ---------- */

.foot {
  display: flex; justify-content: space-between;
  margin-top: 72px; padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 12px; color: var(--fg-dim);
}

/* ---------- lightbox ---------- */

.lightbox {
  position: fixed; inset: 0; z-index: 90;
  display: flex; align-items: center; justify-content: center;
  padding: clamp(12px, 4vw, 48px);
}
.lightbox__backdrop { position: absolute; inset: 0; background: rgba(4, 6, 5, .95); }
.lightbox__stage { position: relative; margin: 0; max-width: 100%; max-height: 100%; }
.lightbox__img {
  max-width: 92vw; max-height: 84vh; width: auto; height: auto;
  animation: fade .25s ease both;
}
.lightbox__count {
  position: absolute; left: 0; bottom: -1.8em;
  font-size: 12px; color: var(--fg-dim); letter-spacing: .1em;
}
.lightbox__close, .lightbox__nav {
  position: absolute; z-index: 2;
  background: none; border: 0; color: var(--fg);
  cursor: pointer; line-height: 1; transition: color .18s ease;
}
.lightbox__close:hover, .lightbox__nav:hover { color: var(--fg-bright); }
.lightbox__close { top: clamp(10px, 3vw, 28px); right: clamp(10px, 3vw, 28px);
  font-size: 30px; }
.lightbox__nav { top: 50%; transform: translateY(-50%); font-size: 44px;
  padding: 12px; }
.lightbox__nav--prev { left: clamp(2px, 2vw, 20px); }
.lightbox__nav--next { right: clamp(2px, 2vw, 20px); }
body.is-locked { overflow: hidden; }

/* ---------- responsive ---------- */

@media (max-width: 820px) {
  .layout { grid-template-columns: 1fr; gap: 28px; }

  .nav {
    display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 18px;
    border-bottom: 1px solid var(--line); padding-bottom: 12px;
  }
  .nav__brand {
    display: block; font-size: 15px; color: var(--fg-bright);
    letter-spacing: .18em; margin-right: auto;
  }
  .nav__toggle {
    display: inline-flex; align-items: center; gap: 8px;
    background: none; border: 0; color: var(--fg);
    font: inherit; cursor: pointer; padding: 4px 0;
  }
  .nav__toggle span, .nav__toggle span::before, .nav__toggle span::after {
    content: ""; display: block; width: 18px; height: 1px; background: currentColor;
    position: relative;
  }
  .nav__toggle span::before { position: absolute; top: -5px; }
  .nav__toggle span::after  { position: absolute; top: 5px; }

  .menu {
    flex-basis: 100%;
    overflow: hidden; max-height: 0; transition: max-height .3s ease;
  }
  .nav.is-open .menu { max-height: 120vh; margin-top: 14px; }
  .menu > li { margin: .1em 0; }
  .menu a { padding: 8px 0; }
  .submenu { margin-left: 1.4em; }

  .banner { margin-bottom: 28px; }
}

@media (max-width: 460px) {
  .grid { columns: 2 140px; }
  .index { columns: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .banner__slide { animation: none; }
  .banner__slide:nth-child(1) { opacity: 1; }
  .banner__slide:nth-child(2), .banner__slide:nth-child(3) { opacity: 0; }
  .view, .lightbox__img { animation: none; }
  a { transition: none; }
}
