/* ==========================================================================
   Arhitektura Zagreba — redesign.css
   New visual design system. Loaded ALONGSIDE the existing bootstrap.min.css
   and site.css (needed by the Vue-rendered fragments on a few pages) —
   this file re-themes everything on top of them. See scratchpad sketch
   az-redesign.html for the design reference this ports.
   ========================================================================== */

:root {
  --paper: #eceeee;        /* concrete, slight blue bias */
  --sheet: #ffffff;        /* card / surface */
  --ink: #15181d;
  --muted: #5d636c;
  --line: #cdd1d4;
  --plate: #1d3a8c;        /* house-number enamel blue */
  --plate-ink: #ffffff;
  --tint: #e2e7f3;         /* plate blue, washed */
  --display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --body: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --s-1: 12px; --s0: 14px; --s1: 16px; --s2: 20px; --s3: 28px; --s4: 40px; --s5: 60px;
  --radius: 6px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #111418; --sheet: #1a1e24; --ink: #e8eaee; --muted: #98a0ab; --line: #2f353e;
    --plate: #4a6fd6; --plate-ink: #ffffff; --tint: #1f2a44;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #111418; --sheet: #1a1e24; --ink: #e8eaee; --muted: #98a0ab; --line: #2f353e;
  --plate: #4a6fd6; --plate-ink: #ffffff; --tint: #1f2a44;
}

/* ---------- reset / base ---------- */
.az { color-scheme: light dark; }
html.az-root { background: var(--paper); }
body.az-root {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: var(--s0);
  line-height: 1.5;
  margin: 0;
  padding-left: max(0px, env(safe-area-inset-left, 0px));
  padding-right: max(0px, env(safe-area-inset-right, 0px));
}
body.az-root h1, body.az-root h2, body.az-root h3, body.az-root h4 {
  font-family: var(--display);
  text-wrap: balance;
  margin: 0;
}
body.az-root a { color: inherit; text-decoration: none; }
body.az-root a.az-link { color: var(--plate); text-decoration: none; font-weight: 600; }
body.az-root a.az-link:hover { text-decoration: underline; }
body.az-root .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
body.az-root .eyebrow {
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em;
  text-transform: uppercase; color: var(--muted);
}
.az-wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 max(16px, env(safe-area-inset-left, 0px)) 0 max(16px, env(safe-area-inset-right, 0px));
}

/* ---------- plate: the signature element ---------- */
.plate {
  display: inline-flex; align-items: center; gap: .5em;
  background: var(--plate); color: var(--plate-ink);
  font-family: var(--display); font-stretch: 80%; font-weight: 700;
  border-radius: 4px; padding: .22em .6em;
  box-shadow: inset 0 0 0 2px var(--plate), inset 0 0 0 3.5px rgba(255, 255, 255, .85);
  line-height: 1.15; white-space: nowrap;
}
.plate b { font-stretch: 62%; font-weight: 800; font-size: 1.2em; }
.plate.plate-lg { font-size: 22px; }
.plate.plate-sm { font-size: 12px; }
/* Plate text is always white on the blue: beats `body.az-root a { color: inherit }`
   for plates that are links, and link hover colours on the lighter pages. */
body.az-root .plate, body.az-root a.plate:hover, body.az-root .plate b { color: var(--plate-ink); }

/* ---------- header ---------- */
.site-header {
  background: var(--sheet);
  border-bottom: 1px solid var(--line);
}
.site-header .az-wrap {
  display: flex; align-items: center; gap: var(--s3);
  padding-top: 14px; padding-bottom: 14px;
  flex-wrap: wrap;
}
.brand { font-family: var(--display); font-weight: 800; font-stretch: 65%; font-size: 22px; letter-spacing: .01em; line-height: 1; }
.brand small {
  display: block; font-family: var(--mono); font-weight: 400; font-size: 9px;
  letter-spacing: .14em; color: var(--muted); margin-top: 2px; text-transform: uppercase;
}
.site-nav { display: flex; align-items: center; gap: 22px; list-style: none; margin: 0; padding: 0; font-weight: 500; }
.site-nav a:hover, .site-nav a.active { color: var(--plate); }
.nav-search {
  margin-left: auto; display: flex; align-items: center; gap: 8px;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 0;
  min-width: 180px; max-width: 280px; flex: 1 1 180px; background: var(--paper);
}
.nav-search input {
  border: 0; background: transparent; font-family: var(--body); font-size: 14px;
  color: var(--ink); padding: 8px 10px; width: 100%; outline: none;
}
.nav-search button {
  border: 0; background: transparent; color: var(--muted); padding: 8px 10px;
  cursor: pointer; font-size: 15px;
}
.nav-toggle-input { position: absolute; opacity: 0; pointer-events: none; }
.nav-toggle-btn { display: none; }

@media (max-width: 760px) {
  .site-header .az-wrap { gap: 10px; padding-top: 10px; padding-bottom: 10px; }
  .nav-toggle-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; border: 1px solid var(--line); border-radius: var(--radius);
    margin-left: auto; order: 2; background: var(--sheet); cursor: pointer; font-size: 18px;
  }
  .site-nav {
    order: 4; flex-basis: 100%; flex-direction: column; align-items: flex-start; gap: 2px;
    max-height: 0; overflow: hidden; width: 100%;
  }
  .nav-search { order: 3; flex-basis: 100%; max-width: none; }
  .nav-toggle-input:checked ~ .az-wrap .site-nav {
    max-height: 400px;
  }
  .site-nav li { width: 100%; padding: 8px 4px; border-bottom: 1px solid var(--line); }
}

/* ---------- footer ---------- */
.site-footer { background: var(--sheet); border-top: 1px solid var(--line); margin-top: var(--s5); }
.site-footer .az-wrap {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap;
  gap: 10px; padding-top: 18px; padding-bottom: 18px; font-size: 13px; color: var(--muted);
}
.site-footer ul { display: flex; gap: 18px; list-style: none; margin: 0; padding: 0; }
.site-footer a:hover { color: var(--plate); }

/* ---------- generic layout helpers ---------- */
.az-main { padding-top: var(--s3); padding-bottom: var(--s5); }
.az-crumbs { font-size: 12px; color: var(--muted); padding-bottom: var(--s1); }
.az-crumbs a:hover { color: var(--plate); }
.row-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.row-h h2, .row-h h4 { font-stretch: 85%; font-weight: 700; margin: 0; }

/* ---------- buttons / chips ---------- */
.az-btn {
  display: inline-flex; align-items: center; gap: 8px; border: 2px solid var(--ink);
  border-radius: var(--radius); padding: 8px 16px; font-family: var(--body); font-weight: 600;
  background: var(--ink); color: var(--sheet); cursor: pointer; font-size: 14px;
}
.az-btn:hover { background: var(--plate); border-color: var(--plate); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip {
  display: inline-block; border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 12px; font-size: 12px; background: var(--sheet); color: var(--ink);
}
.chip:hover { border-color: var(--plate); color: var(--plate); }

/* ---------- hero / index ---------- */
.hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--s4); align-items: center; padding: var(--s4) 0; }
.hero h1 {
  font-size: clamp(34px, 5.2vw, 58px); font-weight: 800; font-stretch: 64%;
  line-height: .96; letter-spacing: -.01em;
}
.hero h1 em { font-style: normal; color: var(--plate); }
.hero p { color: var(--muted); max-width: 44ch; margin-top: 14px; font-size: 15px; }
.bigsearch {
  margin-top: 20px; display: flex; align-items: center; gap: 10px;
  border: 2px solid var(--ink); border-radius: 8px; padding: 12px 14px; font-size: 15px;
  background: var(--sheet);
}
.bigsearch input {
  border: 0; outline: none; background: transparent; font-family: var(--body);
  font-size: 15px; color: var(--ink); width: 100%;
}
.bigsearch input::placeholder { color: var(--muted); }
.hero .chips { margin-top: 14px; }
.counts { display: flex; gap: 28px; margin-top: 22px; flex-wrap: wrap; }
.counts div { display: grid; }
.counts b { font-family: var(--display); font-stretch: 70%; font-size: 30px; font-weight: 700; line-height: 1; }
.counts span { font-size: 12px; color: var(--muted); }

/* ---------- "U blizini" (nearby buildings) ---------- */
.nearby { margin-top: 12px; display: grid; gap: 6px; justify-items: start; }
.nearby[hidden] { display: none; }
.near-btn {
  display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
  font: 600 14px var(--body); color: var(--plate); background: transparent;
  border: 1px solid var(--plate); border-radius: 6px; padding: 7px 14px;
}
.near-btn:hover { background: var(--plate); color: var(--plate-ink); }
.near-btn:disabled { opacity: .6; cursor: wait; }
.near-note { font-size: 12px; color: var(--muted); }
.near-note a { color: var(--plate); }
.near-results { justify-self: stretch; padding-top: 10px; }
.near-results[hidden] { display: none; }
.near-results .row-h h2 { font-size: 20px; }
.near-list { display: grid; }
.near-row {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center;
  padding: 8px 0; border-bottom: 1px solid var(--line);
}
.near-row img { width: 56px; height: 56px; object-fit: cover; border-radius: 4px; background: var(--line); }
.near-row b { display: block; font-size: 14px; }
.near-row span { font-size: 12px; color: var(--muted); }
.near-row:hover b { color: var(--plate); }
.near-dist { white-space: nowrap; }
.near-msg { font-size: 14px; color: var(--muted); margin: 8px 0 0; }
@media (max-width: 700px) {
  /* on a phone this is the main way in: make it the big, thumb-sized action */
  .nearby { justify-items: stretch; }
  .near-btn { justify-content: center; padding: 12px 16px; font-size: 16px;
    background: var(--plate); color: var(--plate-ink); border-color: var(--plate); }
}

.feature-grid {
  display: grid; grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr;
  gap: 8px; height: 360px;
}
.feature-grid a:first-child { grid-row: span 2; }
.feature-grid a {
  position: relative; display: block; overflow: hidden; border-radius: var(--radius);
  background: var(--line);
}
.feature-grid img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .4s ease;
}
.feature-grid a:hover img { transform: scale(1.04); }
.feature-grid .plate {
  position: absolute; left: 10px; bottom: 10px; z-index: 1; font-size: 12px;
}

/* ---------- decade histogram ---------- */
.decades { padding: var(--s3) 0 0; }
.hist {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(6px, 1fr);
  align-items: end; gap: 3px; height: 96px; margin-top: 10px; border-bottom: 1px solid var(--ink);
}
.hist .bar {
  appearance: none; border: 0; padding: 0; margin: 0; height: 100%; cursor: pointer;
  background: linear-gradient(to top, var(--plate) var(--h), transparent var(--h));
  border-radius: 2px 2px 0 0; opacity: .8; transition: opacity .15s;
}
.hist .bar:hover, .hist .bar[aria-pressed="true"] { opacity: 1; }
.hist .bar[aria-pressed="true"] { background: linear-gradient(to top, var(--ink) var(--h), var(--tint) var(--h)); }
.hist .bar:disabled { cursor: default; opacity: .8; }
.hist .bar:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.decade-results { display: grid; gap: var(--s1); padding-top: var(--s3); }
.decade-results[hidden] { display: none; }
.decade-results .row-h h2 { font-size: 22px; }
.link-btn, .more-btn {
  font: 600 13px var(--body); color: var(--plate); background: none; border: 0; padding: 0; cursor: pointer;
}
.more-btn { justify-self: center; border: 1px solid var(--line); border-radius: 6px; padding: 8px 16px; color: var(--ink); }
.more-btn:disabled { opacity: .5; cursor: wait; }
.az-loading { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: var(--s3) 0; color: var(--muted); font-size: 14px; }
.az-spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line);
  border-top-color: var(--plate); animation: az-spin .7s linear infinite; }
@keyframes az-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .az-spinner { animation-duration: 2s; } }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.histlab {
  display: grid; grid-auto-flow: column; grid-auto-columns: minmax(6px, 1fr);
  gap: 3px; font-family: var(--mono); font-size: 10px; color: var(--muted); margin-top: 4px;
}
.histlab span { white-space: nowrap; overflow: hidden; }

/* ---------- card grid (shared across index / streets / districts / architects) ---------- */
.az-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; padding-top: var(--s2);
}
.az-card { display: grid; gap: 8px; }
.az-card .thumb {
  display: block; aspect-ratio: 4 / 5; max-width: 100%; border-radius: var(--radius);
  overflow: hidden; background: var(--line); position: relative;
}
.az-card .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; filter: grayscale(.08); }
.az-card .thumb:hover img { transform: scale(1.05); filter: grayscale(0); }
.az-card .plate { justify-self: start; font-size: 12px; }
.az-card h5 { margin: 0; font-family: var(--body); font-size: 14px; font-weight: 600; line-height: 1.3; }
.az-card p { font-size: 12px; color: var(--muted); margin: 0; }
.az-card .meta { display: flex; gap: 8px; align-items: center; font-size: 12px; color: var(--muted); }

@media (max-width: 980px) { .az-grid { grid-template-columns: repeat(3, 1fr); } .hero { grid-template-columns: 1fr; } .feature-grid { height: 300px; } }
@media (max-width: 700px) { .az-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 420px) { .az-grid { grid-template-columns: 1fr 1fr; gap: 12px; } .counts { gap: 18px; } }

/* ---------- building page ---------- */
.building-layout { display: grid; grid-template-columns: 1.5fr 1fr; gap: var(--s4); padding-top: var(--s1); align-items: start; }
.facts { display: grid; gap: var(--s3); align-content: start; }
.facts .plates { display: flex; flex-wrap: wrap; gap: 8px; }
.facts a.plate { text-decoration: none; }
.facts a.plate:hover { filter: brightness(1.12); }
.facts h1 { font-size: clamp(34px, 4.4vw, 54px); font-weight: 800; font-stretch: 64%; line-height: .95; margin: -8px 0 0; }
.facts .sub { color: var(--muted); margin: -18px 0 0; }
.facts .sub a:hover { color: var(--plate); }
.facts .years { border-left: 2px solid var(--ink); padding-left: 14px; }
.facts .years .mono { font-size: 22px; font-weight: 500; margin: 2px 0 0; }

.az-gallery { display: grid; gap: 8px; }
.az-gallery .main-shot { aspect-ratio: 4 / 3; border-radius: var(--radius); overflow: hidden; background: var(--line); display: block; }
.az-gallery .main-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.az-gallery .photo-meta { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); gap: 10px; }
.az-gallery .photo-meta span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.filmstrip { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 8px; }
.filmstrip a { display: block; aspect-ratio: 1; border-radius: 4px; overflow: hidden; background: var(--line); }
.filmstrip img { width: 100%; height: 100%; object-fit: cover; display: block; opacity: .82; }
.filmstrip a:hover img, .filmstrip a:focus img { opacity: 1; }

.arch-list { display: grid; gap: 8px; margin-top: 10px; }
.arch {
  display: grid; grid-template-columns: 40px 1fr; gap: 12px; align-items: center;
  padding: 8px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--sheet);
}
.arch .face {
  width: 40px; height: 40px; border-radius: 50%; background: linear-gradient(160deg, #b8bcc2, #6f747b);
  display: grid; place-items: center; color: #fff; font-family: var(--display); font-weight: 700; font-size: 14px;
  overflow: hidden;
}
.arch .face img { width: 100%; height: 100%; object-fit: cover; }
.arch b { display: block; font-weight: 600; }

.building-desc { padding-top: var(--s3); display: grid; grid-template-columns: 1.5fr 1fr; gap: var(--s4); }
.building-desc .text { max-width: 62ch; font-size: 15px; line-height: 1.65; }
.map-box { border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; background: var(--paper); }
.map-box .embed-box { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.map-box iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

@media (max-width: 860px) {
  .building-layout, .building-desc { grid-template-columns: 1fr; }
}

/* ---------- architect page ---------- */
.architect-head {
  display: grid; grid-template-columns: 140px 1fr auto; gap: var(--s3); align-items: start;
  padding: var(--s3) 0 var(--s2); border-bottom: 1px solid var(--line);
}
.architect-head.no-portrait { grid-template-columns: 1fr auto; }
.architect-head .portrait {
  width: 100%; max-width: 140px; height: auto; aspect-ratio: 140 / 176;
  border-radius: 4px; object-fit: cover; background: linear-gradient(170deg, #c9ccd0, #5f646b);
  display: block;
}
.architect-head h1 { font-size: clamp(32px, 5vw, 60px); font-weight: 800; font-stretch: 62%; line-height: .9; }
.architect-head p { max-width: 58ch; margin-top: 10px; color: var(--muted); }
.architect-head .stat { text-align: right; }
.architect-head .stat b { font-family: var(--display); font-stretch: 70%; font-size: 38px; font-weight: 700; line-height: 1; display: block; }
.architect-head .stat span { font-size: 12px; color: var(--muted); }

.works-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--s4); padding-top: var(--s2); }
@media (max-width: 860px) { .works-list { grid-template-columns: 1fr; } }
.wrow {
  display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center;
  padding: 10px 0; border-bottom: 1px solid var(--line);
}
.wrow .thumb { height: 56px; width: 56px; border-radius: 4px; overflow: hidden; background: var(--line); display: block; }
.wrow .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.wrow b { font-weight: 600; display: block; }
.wrow span.addr { font-size: 12px; color: var(--muted); }
.wrow .yr { font-family: var(--mono); font-size: 13px; white-space: nowrap; }

@media (max-width: 760px) {
  .architect-head { grid-template-columns: 96px 1fr; }
  .architect-head.no-portrait { grid-template-columns: 1fr; }
  .architect-head .stat { grid-column: 1 / -1; text-align: left; }
}

/* ==========================================================================
   Lighter restyle: tokens / type only, on top of Bootstrap-rendered
   markup (streets, architects, districts, map, search, detailed_search,
   about, contact, literatura, 404/500) and the Vue bundle output.
   ========================================================================== */
body.az-root h1, body.az-root h2, body.az-root h3, body.az-root h4, body.az-root h5, body.az-root h6 {
  font-stretch: 80%;
}
body.az-root p, body.az-root li { font-family: var(--body); }
body.az-root .card {
  background: var(--sheet); border-color: var(--line); border-radius: var(--radius);
}
body.az-root .card-title { font-family: var(--body); color: var(--ink); }
body.az-root .btn-primary, body.az-root .btn-outline-info {
  background: var(--plate); border-color: var(--plate); color: #fff; border-radius: var(--radius);
  font-family: var(--body); font-weight: 600;
}
body.az-root .btn-primary:hover, body.az-root .btn-outline-info:hover { opacity: .9; color: #fff; }
body.az-root .btn-outline-info { background: transparent; color: var(--plate); }
body.az-root .btn-outline-info:hover { background: var(--plate); color: #fff; }
body.az-root .form-control {
  background: var(--sheet); color: var(--ink); border-color: var(--line); border-radius: var(--radius);
}
body.az-root .form-control:focus { border-color: var(--plate); box-shadow: 0 0 0 2px var(--tint); }
body.az-root .alert-secondary { background: var(--tint); border-color: var(--line); color: var(--ink); }
body.az-root .alert-success { background: var(--tint); border-color: var(--plate); color: var(--ink); }
body.az-root .alert-danger { background: #f4dede; border-color: #c0392b; color: #7a1f1f; }
body.az-root .alert-link { color: var(--plate); font-weight: 700; }
body.az-root .spinner-border { color: var(--plate) !important; }
body.az-root .breadcrumb { background: transparent; padding-left: 0; font-size: 13px; }
body.az-root .breadcrumb-item a { color: var(--plate); }
body.az-root .embed-responsive { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); }
body.az-root .img-hover-zoom, body.az-root .img-hover-zoom--colorize {
  border-radius: var(--radius); background: var(--line);
}
body.az-root a.alert-link h3 { color: inherit; }
body.az-root .lighter-page h1 { font-size: clamp(26px, 4.4vw, 40px); font-weight: 800; font-stretch: 68%; }
body.az-root .lighter-page .page-head { padding: var(--s3) 0 var(--s1); }
body.az-root .lighter-page a:not(.btn):hover { color: var(--plate); }

/* generic page wrapper used by lighter-restyle templates that still render
   via {% extends 'base.html' %} and the old bootstrap .container */
body.az-root .container.lighter-page { max-width: 1120px; }

/* street_slug / street_slug_small: card grid + sticky map sidebar */
.street-layout { display: grid; grid-template-columns: 1fr 300px; gap: var(--s4); align-items: start; }
@media (max-width: 860px) {
  .street-layout { grid-template-columns: 1fr; }
  .street-layout .map-box { position: static !important; }
}

/* ---------- building page: neighbours on the same street ---------- */
.neighbours { padding-top: var(--s4); display: grid; gap: var(--s1); }
.neighbours .row-h h2 { font-size: 20px; }
.neighbours .row-h a { font-size: 13px; font-weight: 600; color: var(--plate); text-decoration: none; }
.strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(110px, 170px); justify-content: start; gap: 10px; overflow-x: auto; padding: 3px 3px 6px; }
.strip a { position: relative; display: block; aspect-ratio: 4 / 5; border-radius: 4px; overflow: hidden; background: var(--line); }
.strip img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease; }
.strip a:hover img { transform: scale(1.04); }
.strip a.here { outline: 2px solid var(--plate); outline-offset: 2px; }
.strip a:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.strip .plate { position: absolute; left: 6px; bottom: 6px; }
@media (prefers-reduced-motion: reduce) { .strip img { transition: none; } }

/* ---------- map page: Google Maps info window follows the theme ---------- */
.gm-style .gm-style-iw-c { background: var(--sheet); color: var(--ink); border-radius: 6px; padding: 10px 14px !important; box-shadow: 0 6px 20px -8px rgba(0, 0, 0, .45); }
.gm-style .gm-style-iw-d { overflow: hidden !important; }
.gm-style .gm-style-iw-tc::after { background: var(--sheet); }
.gm-style .gm-style-iw-chr { display: none; } /* close button: hover label closes on mouseout */
.map-label { font-family: var(--display); font-stretch: 80%; font-weight: 700; font-size: 16px; color: var(--ink); white-space: nowrap; }

/* ---------- architect page: bio clamp + career lane ---------- */
.architect-head .bio { max-height: 7.5em; overflow: hidden; position: relative; }
.architect-head .bio p { margin-top: 10px; }
.architect-head .bio:not(.open)::after { content: ""; position: absolute; inset: auto 0 0; height: 2.5em; background: linear-gradient(transparent, var(--paper)); }
.architect-head .bio.open { max-height: none; }
.bio-toggle { margin-top: 8px; }
.career { padding-top: var(--s3); display: grid; gap: var(--s1); }
.lane { position: relative; height: calc(var(--rows) * 54px + 10px); border-bottom: 1px solid var(--ink); margin: 0 22px; }
.lane .work {
  position: absolute; bottom: calc(var(--row) * 54px + 8px); width: 44px; height: 46px; transform: translateX(-50%);
  border-radius: 3px; overflow: hidden; background: var(--line); box-shadow: 0 0 0 2px var(--paper);
}
.lane .work { overflow: visible; }
.lane .work img { border-radius: 3px; }
.lane .work::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1px; height: calc(var(--row) * 54px + 8px); background: var(--line); }
.lane .work img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s; }
.lane .work:hover { z-index: 2; box-shadow: 0 0 0 2px var(--plate); }
.lane .work:hover img { transform: scale(1.08); }
.axis { position: relative; height: 18px; margin: 0 22px; font-family: var(--mono); font-size: 10px; color: var(--muted); }
.axis span { position: absolute; transform: translateX(-50%); top: 4px; }
@media (prefers-reduced-motion: reduce) { .lane .work img { transition: none; } }

/* ---------- click-to-load Google maps (map-gate.js) ---------- */
.map-gate { position: relative; }
.map-page { min-height: 420px; }
.map-gate-cover {
  position: absolute; inset: 0; z-index: 1; display: grid; align-content: center; justify-items: start; gap: 10px;
  padding: var(--s3); background: var(--sheet);
  background-image: repeating-linear-gradient(90deg, transparent 0 39px, var(--line) 39px 40px),
                    repeating-linear-gradient(0deg, transparent 0 39px, var(--line) 39px 40px);
}
.map-page .map-gate-cover { justify-items: center; text-align: center; }
.map-gate.is-open .map-gate-cover { display: none; }
.map-gate-title { font-family: var(--display); font-stretch: 80%; font-weight: 700; font-size: 20px; margin: 0; }
.map-gate-note { max-width: 46ch; font-size: 13px; color: var(--muted); margin: 0; background: var(--sheet); }
.map-gate-note a { color: var(--plate); }
.map-gate-btn {
  font: 600 14px var(--body); color: var(--plate-ink); background: var(--plate); border: 0; border-radius: 6px;
  padding: 9px 16px; cursor: pointer;
}
.map-gate-btn:hover { filter: brightness(1.1); }
.map-gate-btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.map-gate-remember-label { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); background: var(--sheet); }
.map-gate-error { font-size: 13px; color: var(--muted); margin: 0; }

/* ---------- long-form text pages (privacy) ---------- */
.prose { max-width: 68ch; padding-block: var(--s3) var(--s4); }
.prose h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 800; font-stretch: 64%; line-height: .95; margin: 6px 0 var(--s2); }
.prose h2 { font-size: 22px; font-stretch: 85%; font-weight: 700; margin: var(--s4) 0 8px; scroll-margin-top: 80px; }
.prose p, .prose li { font-size: 15px; line-height: 1.65; }
.prose ul { padding-left: 1.2em; display: grid; gap: 6px; }
.prose a { color: var(--plate); }
.prose code { font-family: var(--mono); font-size: 13px; background: var(--tint); padding: 1px 5px; border-radius: 3px; }
.prose .lede { font-size: 17px; color: var(--muted); }
.prose .maps-choice { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.prose .maps-choice .map-gate-btn:disabled { opacity: .45; cursor: default; filter: none; }
.prose .muted { color: var(--muted); font-size: 13px; }
.site-footer a[href="/privatnost/"] { white-space: nowrap; }
