/* ══════════════════════════════════════════
   DESIGN TOKENS — tomaszstruk.com exact
   Font: Lato 300 / 400
   Palette: white / near-black / greys only
   Captions: Tytuł | Rok | Technika  (12px/300)
══════════════════════════════════════════ */
:root {
  --white:       #ffffff;
  --bg:          #f5f5f5;
  --bg2:         #eeeeee;
  --border:      #e0e0e0;
  --border-dk:   #c8c8c8;
  --text:        #222222;
  --text-mid:    #555555;
  --text-muted:  #888888;
  --text-faint:  #bbbbbb;
  --font:        'Lato', 'Helvetica Neue', Arial, sans-serif;
  --sidebar-w:   250px;
  --nav-h:       56px;
  --tr:          0.18s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 14px; scroll-behavior: smooth; }
body {
  background: var(--white);
  color: var(--text);
  font-family: var(--font);
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* ───────── NAV ───────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: var(--white);
  border-bottom: 1px solid var(--border);
  z-index: 200;
  display: flex;
  align-items: center;
  padding: 0 26px;
}
.nav-logo {
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text);
  text-decoration: none;
  flex-shrink: 0;
}
.nav-sep { width: 1px; height: 15px; background: var(--border); margin: 0 16px; flex-shrink: 0; }
.nav-section {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.nav-search-wrap { margin-left: auto; position: relative; display: flex; align-items: center; gap: 12px; }
.nav-search {
  display: flex; align-items: center; gap: 7px;
  border-bottom: 1px solid var(--border-dk);
  padding: 4px 0; width: 195px;
  transition: border-color var(--tr), width var(--tr);
  background: none; cursor: text;
}
.nav-search.focused { border-bottom-color: var(--text); width: 270px; }
.nav-search svg { color: var(--text-muted); flex-shrink: 0; }
.nav-search.focused svg { color: var(--text); }
.nav-search input {
  background: none; border: none; outline: none;
  font-family: var(--font); font-size: 12px; font-weight: 300;
  color: var(--text); width: 100%;
}
.nav-search input::placeholder { color: var(--text-muted); }
.nav-lang { display: flex; align-items: center; flex-shrink: 0; font-size: 11px; font-weight: 300; color: var(--text-muted); }
.nav-lang a { color: var(--text-muted); text-decoration: none; padding: 3px 5px; letter-spacing: 0.06em; transition: color var(--tr); }
.nav-lang a.active { color: var(--text); font-weight: 400; }
.nav-lang a:hover { color: var(--text); }
.nav-lang s { padding: 0 1px; text-decoration: none; }
.nav-portfolio {
    margin-left: 14px;
    font-size: 11px;
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-mid);
    text-decoration: none;
    border: 1px solid var(--border-dk);
    padding: 5px 11px;
    transition: color var(--tr), border-color var(--tr), background var(--tr);
    flex-shrink: 0;
}
.nav-portfolio:hover { color: #fff; background: var(--text); border-color: var(--text); }
@media (max-width: 480px) {
    .nav-portfolio { padding: 4px 8px; letter-spacing: 0.06em; margin-left: 8px; }
}

/* Hamburger */
.hamburger {
  width: 32px; height: 32px; display: flex; flex-direction: column;
  justify-content: center; align-items: center; gap: 5px;
  background: none; border: none; cursor: pointer;
  margin-left: 12px; flex-shrink: 0; padding: 5px;
}
.hamburger span {
  display: block; width: 20px; height: 1px; background: var(--text);
  transition: transform 0.27s ease, opacity 0.27s ease, width 0.27s ease;
  transform-origin: center;
}
.hamburger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; width: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ───────── FULLSCREEN MENU ───────── */
.menu-overlay {
  position: fixed; inset: 0; background: var(--white); z-index: 190;
  padding-top: var(--nav-h); opacity: 0; pointer-events: none;
  transition: opacity 0.24s ease; display: flex; flex-direction: column;
}
.menu-overlay.open { opacity: 1; pointer-events: all; }
.menu-inner { display: flex; flex: 1; overflow: hidden; }
.menu-left {
  flex: 1; padding: 42px 50px; display: flex;
  flex-direction: column; justify-content: space-between;
  border-right: 1px solid var(--border); overflow-y: auto;
}
.menu-nav-list { list-style: none; }
.menu-nav-item { border-bottom: 1px solid var(--border); }
.menu-nav-link {
  display: flex; align-items: baseline; gap: 16px; padding: 15px 0;
  text-decoration: none; color: var(--text); transition: opacity var(--tr); cursor: pointer;
}
.menu-nav-link:hover { opacity: 0.45; }
.menu-nav-num { font-size: 11px; font-weight: 300; color: var(--text-muted); letter-spacing: 0.1em; min-width: 18px; }
.menu-nav-title { font-size: 26px; font-weight: 300; letter-spacing: 0.03em; line-height: 1.15; }
.menu-nav-sub { display: block; font-size: 12px; font-weight: 300; color: var(--text-muted); letter-spacing: 0.04em; margin-top: 3px; }
.menu-footer { display: flex; flex-direction: column; gap: 4px; padding-top: 26px; }
.menu-footer a { font-size: 12px; font-weight: 300; color: var(--text-muted); text-decoration: none; letter-spacing: 0.04em; transition: color var(--tr); }
.menu-footer a:hover { color: var(--text); }
.menu-right {
  width: 340px; flex-shrink: 0; padding: 42px 40px;
  background: var(--bg); border-left: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 16px;
}
.menu-preview { opacity: 0; transition: opacity 0.2s; }
.menu-preview.visible { opacity: 1; }
.menu-preview-label { font-size: 10px; font-weight: 300; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 10px; }
.menu-preview-img {
  width: 100%; aspect-ratio: 4/3; background: var(--bg2);
  border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
}
.menu-preview-img span { font-size: 11px; font-weight: 300; color: var(--text-faint); letter-spacing: 0.08em; text-transform: uppercase; }
.menu-preview-cap { margin-top: 7px; font-size: 12px; font-weight: 300; color: var(--text-muted); line-height: 1.5; }

/* ───────── LAYOUT ───────── */
.layout { display: flex; padding-top: var(--nav-h); min-height: 100vh; }

/* ───────── SIDEBAR ───────── */
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0;
  position: sticky; top: var(--nav-h); height: calc(100vh - var(--nav-h));
  overflow-y: auto; border-right: 1px solid var(--border);
  background: var(--white); scrollbar-width: thin; scrollbar-color: var(--border) transparent;
}
.sidebar-hdr { padding: 18px 18px 14px; border-bottom: 1px solid var(--border); }
.sidebar-title { font-size: 10px; font-weight: 400; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 11px; }
.sidebar-stats { display: flex; flex-direction: column; gap: 5px; }
.sstat { display: flex; justify-content: space-between; align-items: baseline; }
.sstat-l { font-size: 12px; font-weight: 300; color: var(--text-muted); }
.sstat-v { font-size: 13px; font-weight: 400; color: var(--text); }

.sidebar-count {
  display: flex;
  align-items: baseline;
  gap: 7px;
  padding: 14px 14px 12px;
  border-bottom: 1px solid var(--border);
}
.sidebar-count-n {
  font-size: 22px;
  font-weight: 300;
  color: var(--text);
  letter-spacing: -0.01em;
  line-height: 1;
}
.sidebar-count-l {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* Chips */
.chips-row { padding: 8px 22px; border-bottom: 1px solid var(--border); background: var(--white); display: flex; flex-wrap: wrap; gap: 6px; }
.chips-row:empty { display: none; }
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1px solid var(--border-dk); padding: 3px 8px;
  font-size: 11px; font-weight: 300; letter-spacing: 0.04em;
  color: var(--text-mid); cursor: pointer; transition: opacity var(--tr);
  text-decoration: none;
}
.chip:hover { opacity: 0.5; text-decoration: none; }
.chip-x { font-size: 12px; line-height: 1; }

/* Filter groups */
.fg { border-bottom: 1px solid var(--border); }
.fg-hdr { display: flex; align-items: center; justify-content: space-between; padding: 11px 14px 9px; cursor: pointer; user-select: none; }
.fg-label { font-size: 10px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-mid); }
.fg-chev { font-size: 9px; color: var(--text-muted); transition: transform 0.2s; }
.fg.closed .fg-chev { transform: rotate(-90deg); }
.fg-body { padding: 2px 14px 11px; }
.fg.closed .fg-body { display: none; }
.fopt { display: flex; align-items: center; gap: 8px; padding: 5px 0; cursor: pointer; }
.fopt:hover .fopt-l { color: var(--text); }
.fchk { width: 12px; height: 12px; border: 1px solid var(--border-dk); flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.fchk.on { background: var(--text); border-color: var(--text); }
.fchk.on::after { content: ''; width: 5px; height: 3px; border-left: 1.5px solid #fff; border-bottom: 1.5px solid #fff; transform: rotate(-45deg) translateY(-1px); display: block; }
.fopt-l { font-size: 12px; font-weight: 300; color: var(--text-mid); flex: 1; }
.fopt-n { font-size: 11px; font-weight: 300; color: var(--text-faint); }

/* Year range */
.year-range { padding: 5px 0 2px; }
.year-inps { display: flex; align-items: center; gap: 6px; margin-bottom: 10px; }
.year-inp { background: var(--bg); border: 1px solid var(--border); padding: 4px 6px; font-family: var(--font); font-size: 12px; font-weight: 300; color: var(--text); width: 60px; outline: none; }
.year-inp:focus { border-color: var(--text); }
.year-dash { font-size: 12px; font-weight: 300; color: var(--text-faint); }
.rtrack { height: 1px; background: var(--border-dk); position: relative; margin: 2px 4px; }
.rfill { position: absolute; height: 100%; background: var(--text); left: 8%; right: 18%; }
.rh { position: absolute; width: 10px; height: 10px; background: var(--white); border: 1.5px solid var(--text); border-radius: 50%; top: -4.5px; cursor: grab; }
.rh.l { left: 8%; transform: translateX(-50%); }
.rh.r { right: 18%; transform: translateX(50%); }

.sidebar-clear { display: block; text-align: center; text-decoration: none; margin: 13px 14px; width: calc(100% - 28px); padding: 8px 0; background: none; border: 1px solid var(--border-dk); font-family: var(--font); font-size: 11px; font-weight: 300; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); cursor: pointer; transition: all var(--tr); }
.sidebar-clear:hover { color: var(--text); border-color: var(--text); text-decoration: none; }

/* ───────── MAIN ───────── */
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }

.page-header { padding: 32px 26px 22px; border-bottom: 1px solid var(--border); background: var(--white); display: flex; align-items: flex-end; justify-content: space-between; }
.page-eyebrow { font-size: 10px; font-weight: 300; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 6px; }
.page-title { font-size: 28px; font-weight: 300; letter-spacing: 0.06em; color: var(--text); line-height: 1.1; }
.page-count-n { font-size: 40px; font-weight: 300; color: var(--text-faint); line-height: 1; text-align: right; }
.page-count-l { font-size: 10px; font-weight: 300; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-faint); margin-top: 3px; text-align: right; }

/* Cycle strip */
.cycle-strip { display: flex; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--border); background: var(--white); }
.cycle-strip::-webkit-scrollbar { display: none; }
.citem { flex-shrink: 0; padding: 11px 18px; font-size: 11px; font-weight: 300; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); border-right: 1px solid var(--border); cursor: pointer; transition: color var(--tr); white-space: nowrap; position: relative; }
.citem::after { content: ''; position: absolute; bottom: -1px; left: 0; right: 0; height: 1px; background: var(--text); transform: scaleX(0); transition: transform 0.2s; }
.citem.active { color: var(--text); }
.citem.active::after { transform: scaleX(1); }
.citem:hover { color: var(--text); }

/* Toolbar */
.toolbar { display: flex; align-items: center; gap: 14px; padding: 9px 22px; border-bottom: 1px solid var(--border); background: var(--bg); position: sticky; top: var(--nav-h); z-index: 100; }
.tb-count { font-size: 12px; font-weight: 300; color: var(--text-muted); }
.tb-count strong { font-weight: 400; color: var(--text); }
.tb-div { width: 1px; height: 13px; background: var(--border-dk); flex-shrink: 0; }
.tb-sort { display: flex; align-items: center; gap: 7px; }
.tb-sort-l { font-size: 10px; font-weight: 300; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.tb-select { background: none; border: none; border-bottom: 1px solid var(--border-dk); font-family: var(--font); font-size: 12px; font-weight: 300; color: var(--text-mid); padding: 2px 16px 2px 2px; outline: none; cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='8' height='5'%3E%3Cpath d='M0 0l4 5 4-5z' fill='%23888'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 1px center; }
.view-sw { margin-left: auto; display: flex; gap: 2px; }
.vbtn { background: none; border: 1px solid var(--border); padding: 4px 7px; cursor: pointer; color: var(--text-muted); display: flex; align-items: center; transition: all var(--tr); }
.vbtn.active { background: var(--text); border-color: var(--text); color: #fff; }

/* ───────── GALLERY ───────── */
.gallery { padding: 28px 22px 0; flex: 1; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(195px, 1fr)); gap: 28px; }

/* Card */
.card { background: var(--white); cursor: pointer; display: flex; flex-direction: column; transition: opacity var(--tr); }
.card:hover { opacity: 0.78; }
.card-thumb { aspect-ratio: 3/4; position: relative; overflow: hidden; background: var(--white); border: 1px solid var(--border); }
.card-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }

/* Greyscale washes (placeholders when no image) */
.t1 { background: linear-gradient(155deg,#e8e8e8 0%,#d2d2d2 100%); }
.t2 { background: linear-gradient(200deg,#e2e2e2 0%,#cacaca 60%,#d8d8d8 100%); }
.t3 { background: radial-gradient(ellipse at 35% 65%,#dcdcdc 0%,#c6c6c6 70%); }
.t4 { background: linear-gradient(120deg,#d2d2d2 0%,#e0e0e0 50%,#c8c8c8 100%); }
.t5 { background: conic-gradient(from 30deg,#e4e4e4,#cecece,#dcdcdc,#e4e4e4); }
.t6 { background: linear-gradient(180deg,#dadada 0%,#c4c4c4 50%,#d2d2d2 100%); }

.card-overlay { position: absolute; inset: 0; background: transparent; transition: background 0.22s; display: flex; align-items: flex-end; padding: 10px; }
.card:hover .card-overlay { background: rgba(0,0,0,0.07); }
.card-quick { font-size: 10px; font-weight: 300; letter-spacing: 0.14em; text-transform: uppercase; color: var(--white); background: rgba(34,34,34,0.82); padding: 4px 10px; opacity: 0; transform: translateY(5px); transition: opacity 0.2s, transform 0.2s; }
.card:hover .card-quick { opacity: 1; transform: translateY(0); }
.card-badge { position: absolute; top: 8px; left: 8px; font-size: 9px; font-weight: 300; letter-spacing: 0.06em; color: var(--text-mid); background: rgba(255,255,255,0.88); padding: 2px 6px; }
.card-award { position: absolute; top: 8px; right: 8px; width: 18px; height: 18px; background: rgba(255,255,255,0.9); border: 1px solid var(--border-dk); display: flex; align-items: center; justify-content: center; }
.card-award svg { width: 10px; }

/* ── CAPTION — format: Tytuł | Rok | Technika ── */
.card-caption { padding: 8px 0 0; }
.card-caption-main { font-size: 12px; font-weight: 300; color: var(--text); line-height: 1.45; letter-spacing: 0.01em; }
.card-caption-award { font-size: 12px; font-weight: 300; color: var(--text-muted); line-height: 1.45; margin-top: 2px; }
.card-caption-tech { font-size: 12px; font-weight: 300; color: var(--text-muted); line-height: 1.45; margin-top: 1px; }
.card-caption-inv { font-size: 11px; font-weight: 300; color: var(--text-faint); letter-spacing: 0.04em; margin-top: 4px; line-height: 1.4; }

/* Load more */
.load-area { padding: 34px 22px; display: flex; align-items: center; justify-content: center; gap: 20px; border-top: 1px solid var(--border); margin-top: 28px; }
.prog-wrap { display: flex; align-items: center; gap: 10px; }
.prog-label { font-size: 12px; font-weight: 300; color: var(--text-muted); }
.prog-track { width: 130px; height: 1px; background: var(--border-dk); position: relative; }
.prog-fill { position: absolute; height: 100%; background: var(--text); }
.load-btn { font-family: var(--font); font-size: 11px; font-weight: 300; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text); background: none; border: 1px solid var(--text); padding: 8px 20px; cursor: pointer; transition: background var(--tr), color var(--tr); text-decoration: none; display: inline-block; }
.load-btn:hover { background: var(--text); color: #fff; text-decoration: none; }

/* ───────── LIST VIEW ───────── */
.list-wrap { display: none; }
.list-wrap.show { display: block; }
.grid-wrap.hide { display: none; }
.list-head { display: grid; grid-template-columns: 50px 1fr 66px 66px 185px 88px; gap: 12px; padding: 8px 22px; background: var(--bg); border-bottom: 1px solid var(--border); }
.lh { font-size: 9px; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-muted); cursor: pointer; display: flex; align-items: center; gap: 3px; }
.lh:hover { color: var(--text); }
.sarr { font-size: 8px; color: var(--text); }
.list-row { display: grid; grid-template-columns: 50px 1fr 66px 66px 185px 88px; gap: 12px; padding: 10px 22px; border-bottom: 1px solid var(--border); cursor: pointer; align-items: center; transition: background var(--tr); }
.list-row:hover { background: var(--bg); }
.lr-thumb { width: 50px; height: 38px; overflow: hidden; background: var(--white); border: 1px solid var(--border); }
.lr-thumb img { width: 100%; height: 100%; object-fit: contain; display: block; }
.lr-thumb div { width: 100%; height: 100%; }
.lrc { font-size: 12px; font-weight: 300; color: var(--text-mid); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lrc.title { color: var(--text); }
.lrc.tag { font-size: 10px; font-weight: 300; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); border: 1px solid var(--border-dk); padding: 2px 6px; display: inline-block; width: fit-content; }

/* ───────── SEARCH DROPDOWN ───────── */
.sdrop { position: absolute; top: calc(100% + 8px); right: 0; width: 330px; background: var(--white); border: 1px solid var(--border-dk); box-shadow: 0 8px 28px rgba(0,0,0,0.09); z-index: 300; display: none; }
.sdrop.show { display: block; }
.sd-sec { padding: 12px 15px 9px; border-bottom: 1px solid var(--border); }
.sd-sec:last-child { border-bottom: none; }
.sd-label { font-size: 9px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 7px; }
.sd-row { display: flex; justify-content: space-between; align-items: baseline; padding: 5px 5px; cursor: pointer; transition: background var(--tr); text-decoration: none; }
.sd-row:hover { background: var(--bg); text-decoration: none; }
.sd-text { font-size: 12px; font-weight: 300; color: var(--text); text-decoration: none; }
.sd-meta { font-size: 11px; font-weight: 300; color: var(--text-muted); text-decoration: none; }

/* ───────── DETAIL PANEL ───────── */
.detail-bg { position: fixed; inset: 0; background: rgba(0,0,0,0.35); z-index: 400; opacity: 0; pointer-events: none; transition: opacity 0.26s; }
.detail-bg.show { opacity: 1; pointer-events: all; }
.detail-panel { position: fixed; top: 0; right: 0; bottom: 0; width: 620px; max-width: 92vw; background: var(--white); border-left: 1px solid var(--border); z-index: 401; display: flex; flex-direction: column; transform: translateX(32px); opacity: 0; pointer-events: none; transition: transform 0.32s cubic-bezier(0.22,1,0.36,1), opacity 0.26s; overflow-y: auto; }
.detail-panel.show { transform: translateX(0); opacity: 1; pointer-events: all; }
.dp-hdr { padding: 15px 22px; border-bottom: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; position: sticky; top: 0; background: var(--white); z-index: 2; }
.dp-inv { font-size: 12px; font-weight: 300; color: var(--text-muted); letter-spacing: 0.03em; }
.dp-close { width: 29px; height: 29px; background: none; border: 1px solid var(--border-dk); cursor: pointer; font-family: var(--font); font-size: 16px; font-weight: 300; color: var(--text-muted); display: flex; align-items: center; justify-content: center; transition: all var(--tr); }
.dp-close:hover { background: var(--text); color: #fff; border-color: var(--text); }
.dp-image { background: var(--bg); min-height: 290px; display: flex; align-items: center; justify-content: center; position: relative; flex-shrink: 0; }
.dp-img-ph { width: 100%; height: 310px; background: linear-gradient(155deg,#e8e8e8 0%,#d2d2d2 100%); display: flex; align-items: center; justify-content: center; }
.dp-img-ph img { max-width: 90%; max-height: 290px; object-fit: contain; display: block; }
.dp-img-ph span { font-size: 11px; font-weight: 300; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); }
.dp-img-nav { position: absolute; bottom: 11px; right: 11px; display: flex; gap: 3px; }
.dp-nbtn { width: 27px; height: 27px; background: rgba(255,255,255,0.9); border: 1px solid var(--border-dk); cursor: pointer; font-size: 14px; color: var(--text); display: flex; align-items: center; justify-content: center; transition: all var(--tr); font-family: var(--font); }
.dp-nbtn:hover { background: var(--text); color: #fff; border-color: var(--text); }
.dp-body { padding: 22px 22px 14px; }
.dp-title { font-size: 22px; font-weight: 300; color: var(--text); letter-spacing: 0.04em; margin-bottom: 5px; line-height: 1.2; }
.dp-caption-line { font-size: 12px; font-weight: 300; color: var(--text-muted); margin-bottom: 4px; line-height: 1.5; }
.dp-award-line { font-size: 12px; font-weight: 300; color: var(--text-muted); margin-bottom: 18px; line-height: 1.5; }
.dp-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 13px 22px; padding: 16px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 16px; }
.dp-mk { font-size: 9px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 4px; }
.dp-mv { font-size: 12px; font-weight: 300; color: var(--text-mid); line-height: 1.4; }
.dp-mv.mono { font-size: 11px; letter-spacing: 0.04em; color: var(--text-muted); }
.dp-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 16px; }
.dp-tag { font-family: var(--font); font-size: 11px; font-weight: 300; letter-spacing: 0.08em; color: var(--text-muted); border: 1px solid var(--border-dk); padding: 3px 8px; cursor: pointer; background: none; transition: all var(--tr); }
.dp-tag:hover { color: var(--text); border-color: var(--text); }
.dp-note { font-size: 12px; font-weight: 300; color: var(--text-muted); line-height: 1.6; padding: 11px 13px; background: var(--bg); border-left: 2px solid var(--border-dk); margin-bottom: 16px; }
.dp-exh-hd { font-size: 9px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 9px; }
.dp-exh-list { display: flex; flex-direction: column; gap: 6px; }
.dp-exh-item { display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 300; color: var(--text-mid); }
.exdot { width: 3px; height: 3px; background: var(--text-faint); border-radius: 50%; flex-shrink: 0; }
.dp-footer { padding: 13px 22px; border-top: 1px solid var(--border); display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; background: var(--bg); }
.dp-pn { display: flex; gap: 5px; }
.dp-pn button { background: none; border: 1px solid var(--border-dk); padding: 6px 13px; font-family: var(--font); font-size: 11px; font-weight: 300; letter-spacing: 0.08em; color: var(--text-muted); cursor: pointer; transition: all var(--tr); }
.dp-pn button:hover { background: var(--text); color: #fff; border-color: var(--text); }
.dp-back { font-family: var(--font); font-size: 11px; font-weight: 300; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); background: none; border: none; border-bottom: 1px solid var(--border-dk); padding-bottom: 1px; cursor: pointer; transition: color var(--tr); }
.dp-back:hover { color: var(--text); }

/* Footer */
.footer { border-top: 1px solid var(--border); padding: 16px 26px; background: var(--white); display: flex; align-items: center; justify-content: space-between; }
.footer-copy { font-size: 11px; font-weight: 300; color: var(--text-faint); letter-spacing: 0.04em; }
.footer-mail a { font-size: 11px; font-weight: 300; color: var(--text-muted); text-decoration: none; border-bottom: 1px solid var(--border-dk); transition: color var(--tr); }
.footer-mail a:hover { color: var(--text); }

/* Focus */
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 1px solid var(--text); outline-offset: 2px; }

/* nav pipe + section */
.nav-pipe { font-size: 13px; font-weight: 300; color: var(--text-muted); margin: 0 10px; }
.nav-section { font-size: 12px; font-weight: 300; letter-spacing: 0.1em; color: var(--text-mid); }

/* collapsible search */
.search-icon-btn { background: none; border: none; cursor: pointer; color: var(--text-muted); display: flex; align-items: center; padding: 6px; transition: color var(--tr); }
.search-icon-btn:hover { color: var(--text); }
.nav-search-expanded { position: absolute; right: 0; top: 50%; transform: translateY(-50%); width: 0; overflow: hidden; transition: width 0.28s cubic-bezier(0.22,1,0.36,1); display: flex; flex-direction: column; }
.nav-search-expanded.open { width: 320px; overflow: visible; }
.nav-search-expanded .nav-search { border-bottom: 1px solid var(--text); width: 100%; }
.search-close-btn { background: none; border: none; cursor: pointer; font-family: var(--font); font-size: 16px; font-weight: 300; color: var(--text-muted); padding: 0 4px; flex-shrink: 0; transition: color var(--tr); line-height: 1; }
.search-close-btn:hover { color: var(--text); }

/* artwork frame in detail panel */
.dp-artwork-frame { padding: 20px; background: var(--white); display: inline-flex; box-shadow: 0 2px 24px rgba(0,0,0,0.10); }
.dp-artwork-inner { width: 260px; height: 340px; background-size: cover; background-position: center; }

/* clickable image hint inside detail panel */
.dp-img-ph img { cursor: zoom-in; transition: opacity 0.18s; }
.dp-img-ph img:hover { opacity: 0.92; }
.dp-zoom-hint {
    position: absolute; top: 11px; left: 11px;
    font-family: var(--font);
    font-size: 9px; font-weight: 300; letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--text-mid);
    background: rgba(255,255,255,0.9);
    border: 1px solid var(--border-dk);
    padding: 3px 8px;
    display: inline-flex; align-items: center; gap: 5px;
    cursor: zoom-in;
    transition: background 0.18s, color 0.18s, border-color 0.18s;
    z-index: 2;
}
.dp-zoom-hint:hover { background: var(--text); color: #fff; border-color: var(--text); }
.dp-zoom-hint.hidden { display: none; }

/* ───────── LIGHTBOX ───────── */
.lightbox {
    position: fixed; inset: 0;
    background: rgba(15,15,15,0.94);
    z-index: 500;
    opacity: 0; pointer-events: none;
    transition: opacity 0.26s ease;
    display: flex; align-items: center; justify-content: center;
    padding: 4vh 4vw;
    cursor: zoom-out;
}
.lightbox.show { opacity: 1; pointer-events: all; }
.lightbox img {
    max-width: 100%; max-height: 100%;
    object-fit: contain;
    user-select: none;
    -webkit-user-drag: none;
    display: block;
    box-shadow: 0 8px 60px rgba(0,0,0,0.6);
    transition: transform 0.26s cubic-bezier(0.22,1,0.36,1), opacity 0.2s;
    opacity: 0;
    transform: scale(0.96);
}
.lightbox.show img { opacity: 1; transform: scale(1); }
.lightbox-close {
    position: fixed; top: 18px; right: 18px;
    width: 36px; height: 36px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.32);
    cursor: pointer;
    color: #fff;
    font-family: var(--font);
    font-size: 22px; font-weight: 300;
    display: flex; align-items: center; justify-content: center;
    transition: background 0.18s, border-color 0.18s;
    z-index: 501;
    line-height: 1;
}
.lightbox-close:hover { background: rgba(255,255,255,0.18); border-color: rgba(255,255,255,0.7); }
.lightbox-meta {
    position: fixed; bottom: 18px; left: 50%; transform: translateX(-50%);
    color: rgba(255,255,255,0.78);
    font-size: 11px; font-weight: 300; letter-spacing: 0.06em;
    padding: 6px 12px;
    background: rgba(0,0,0,0.4);
    border: 1px solid rgba(255,255,255,0.12);
    z-index: 501;
    white-space: nowrap;
    max-width: 90vw;
    overflow: hidden; text-overflow: ellipsis;
}
@media (max-width: 480px) {
    .lightbox { padding: 8px; }
    .lightbox-close { top: 10px; right: 10px; width: 32px; height: 32px; font-size: 19px; }
    .lightbox-meta { bottom: 10px; font-size: 10px; }
}

/* ───────── PUBLIC LIST PAGES (Exhibitions/Awards/Collections/Cycles) ───────── */
.page-wrap {
    padding-top: var(--nav-h);
    min-height: 100vh;
    display: flex; flex-direction: column;
}
.page-shell { flex: 1; max-width: 1100px; margin: 0 auto; padding: 40px 26px 60px; width: 100%; }
.page-eyebrow { font-size: 10px; font-weight: 300; letter-spacing: 0.18em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px; }
.page-h1 { font-size: 32px; font-weight: 300; letter-spacing: 0.04em; color: var(--text); margin-bottom: 6px; line-height: 1.1; }
.page-sub { font-size: 12px; font-weight: 300; color: var(--text-muted); margin-bottom: 36px; }

.section-h { font-size: 11px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-mid); margin: 28px 0 12px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }

.rec-list { display: flex; flex-direction: column; }
.rec-row {
    display: grid;
    grid-template-columns: 70px 1fr auto;
    align-items: baseline;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
    text-decoration: none;
    color: var(--text);
    transition: background var(--tr);
}
.rec-row:hover { background: var(--bg); }
.rec-year { font-size: 12px; font-weight: 400; color: var(--text-muted); letter-spacing: 0.04em; }
.rec-name { font-size: 14px; font-weight: 300; color: var(--text); line-height: 1.4; }
.rec-meta { font-size: 11px; font-weight: 300; color: var(--text-muted); letter-spacing: 0.04em; white-space: nowrap; }

.cycle-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1px; background: var(--border); border: 1px solid var(--border); }
.cycle-card {
    background: var(--white);
    padding: 20px;
    text-decoration: none;
    color: var(--text);
    transition: background var(--tr);
    display: flex; flex-direction: column; gap: 6px;
}
.cycle-card:hover { background: var(--bg); }
.cycle-card-num { font-size: 10px; font-weight: 400; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-muted); }
.cycle-card-name { font-size: 18px; font-weight: 300; color: var(--text); letter-spacing: 0.02em; }
.cycle-card-meta { font-size: 11px; font-weight: 300; color: var(--text-muted); margin-top: auto; padding-top: 14px; display: flex; justify-content: space-between; align-items: baseline; }

.country-group { margin-bottom: 32px; }
.country-name {
    font-size: 12px; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase;
    color: var(--text-mid);
    padding: 6px 0; border-bottom: 1px solid var(--border);
    margin-bottom: 12px;
}

@media (max-width: 600px) {
    .page-shell { padding: 28px 14px 40px; }
    .page-h1 { font-size: 24px; }
    .rec-row { grid-template-columns: 50px 1fr; }
    .rec-row .rec-meta { grid-column: 1 / -1; padding-left: 50px; }
}

/* ───────── SIENNA A11Y BUTTON OVERRIDE ───────── */
.asw-menu-btn {
    --asw-btn-size: 40px !important;
    --asw-icon-size: 25px !important;
    position: fixed !important;
    z-index: 500000 !important;
    left: auto !important;
    right: 20px !important;
    bottom: var(--asw-bottom, 30px) !important;
    top: var(--asw-top, auto) !important;
    box-shadow: 0 5px 15px #252c6126, 0 2px 4px #5d649433 !important;
    transition: transform .2s ease !important;
    border-radius: 50% !important;
    align-items: center !important;
    justify-content: center !important;
    width: var(--asw-btn-size) !important;
    height: var(--asw-btn-size) !important;
    display: flex !important;
    cursor: pointer !important;
    border: 3px solid white !important;
    outline: 5px solid #000000 !important;
    text-decoration: none !important;
    background: #000000 !important;
    background: linear-gradient(96deg, #000000 0%, #000000 100%) !important;
}

/* ───────── MOBILE FILTER TOGGLE + BACKDROP ───────── */
.sidebar-backdrop {
    position: fixed; inset: 0; background: rgba(0,0,0,0.35);
    z-index: 170; opacity: 0; pointer-events: none;
    transition: opacity 0.24s ease;
}
.sidebar-backdrop.show { opacity: 1; pointer-events: all; }

.sidebar-close {
    display: none;
    width: 29px; height: 29px;
    background: none; border: 1px solid var(--border-dk);
    cursor: pointer; font-family: var(--font); font-size: 16px;
    font-weight: 300; color: var(--text-muted);
    align-items: center; justify-content: center;
    transition: all var(--tr);
    margin-left: auto;
}
.sidebar-close:hover { background: var(--text); color: #fff; border-color: var(--text); }

.filter-toggle {
    display: none;
    background: none; border: 1px solid var(--border-dk);
    font-family: var(--font); font-size: 11px; font-weight: 300;
    letter-spacing: 0.12em; text-transform: uppercase;
    color: var(--text-mid); padding: 5px 11px;
    cursor: pointer; transition: all var(--tr);
    align-items: center; gap: 6px;
}
.filter-toggle:hover { color: var(--text); border-color: var(--text); }
.filter-toggle-n {
    font-size: 10px; color: var(--text-faint); padding-left: 4px;
    border-left: 1px solid var(--border-dk);
}

/* ───────── MOBILE: ≤ 768px ───────── */
@media (max-width: 768px) {
    .layout { padding-top: var(--nav-h); flex-direction: column; }

    /* Sidebar becomes off-canvas drawer */
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        height: 100vh;
        width: 84vw;
        max-width: 340px;
        z-index: 180;
        padding-top: var(--nav-h);
        transform: translateX(-100%);
        transition: transform 0.28s cubic-bezier(0.22,1,0.36,1);
        box-shadow: 0 0 30px rgba(0,0,0,0.18);
        border-right: 1px solid var(--border);
    }
    .sidebar.open { transform: translateX(0); }

    .sidebar-close { display: flex; }
    .sidebar-count {
        display: flex; align-items: center; gap: 9px;
        padding: 13px 14px 11px;
    }

    /* Show mobile filter toggle in toolbar */
    .filter-toggle { display: inline-flex; }

    /* Toolbar wraps, hide bulk count text */
    .toolbar {
        flex-wrap: wrap;
        gap: 8px;
        padding: 9px 14px;
    }
    .toolbar .tb-count { display: none; }
    .toolbar .tb-div { display: none; }
    .toolbar .tb-sort { gap: 5px; }
    .toolbar .tb-sort-l { display: none; }
    .toolbar .view-sw { margin-left: 0; }

    /* Grid: smaller */
    .gallery { padding: 16px 14px 0; }
    .grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 18px; }

    /* List view: hide some columns */
    .list-head, .list-row {
        grid-template-columns: 40px 1fr 60px;
        gap: 8px;
        padding: 8px 14px;
    }
    .list-head > .lh:nth-child(4),
    .list-head > .lh:nth-child(5),
    .list-head > .lh:nth-child(6),
    .list-row > .lrc:nth-child(4),
    .list-row > .lrc:nth-child(5),
    .list-row > .lrc:nth-child(6) { display: none; }

    /* Chips wrap & compact */
    .chips-row { padding: 6px 14px; }

    /* Detail panel: full screen */
    .detail-panel {
        width: 100%;
        max-width: 100%;
        border-left: none;
    }
    .dp-image { min-height: 220px; }
    .dp-img-ph { height: 240px; }
    .dp-body { padding: 18px 16px 14px; }
    .dp-title { font-size: 19px; }
    .dp-meta { grid-template-columns: 1fr; gap: 10px; padding: 14px 0; }

    /* Load area: stack */
    .load-area { flex-direction: column; gap: 12px; padding: 22px 14px; }
    .prog-wrap { width: 100%; justify-content: center; }
    .load-btn { width: 100%; padding: 11px; }

    /* Footer: stack */
    .footer { flex-direction: column; gap: 6px; align-items: flex-start; padding: 14px 16px; }

    /* Nav: trim spacing */
    .nav { padding: 0 14px; }
    .nav-pipe { margin: 0 8px; }
    .nav-section { font-size: 11px; }

    /* Fullscreen menu inner stacks */
    .menu-inner { flex-direction: column; }
    .menu-left { padding: 28px 22px; border-right: none; border-bottom: 1px solid var(--border); }
    .menu-right { width: 100%; padding: 28px 22px; }
    .menu-nav-title { font-size: 21px; }
}

/* ───────── SMALL MOBILE: ≤ 480px ───────── */
@media (max-width: 480px) {
    .nav-section { display: none; }
    .nav-pipe { display: none; }
    .nav-logo { font-size: 13px; letter-spacing: 0.14em; }

    .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .gallery { padding: 14px 12px 0; }

    .card-caption-main { font-size: 11px; }
    .card-caption-tech, .card-caption-award { font-size: 11px; }
    .card-caption-inv { font-size: 10px; }

    .nav-search-expanded.open { width: calc(100vw - 100px); }

    .menu-left { padding: 22px 18px; }
    .menu-nav-link { padding: 12px 0; gap: 12px; }
    .menu-nav-title { font-size: 18px; }
}
