:root {
  --paper: #f5f0e7;
  --paper-deep: #ebe3d6;
  --white: #ffffff;
  --ink: #1c1714;
  --muted: #6a5e54;
  --rust: #77392d;
  --rust-soft: #f0d2c6;
  --line: rgba(28, 23, 20, 0.14);
  --line-light: rgba(246, 241, 234, 0.28);
  --cream: #f6f1ea;
  --footer: #141210;
  --sans: "Outfit", "Segoe UI", sans-serif;
  --serif: "Newsreader", "Iowan Old Style", Palatino, Georgia, serif;
  --gutter: 1.35rem;
  --max: 42rem;
  --radius: 0.85rem;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.05rem;
  line-height: 1.6;
  font-weight: 400;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--rust); outline-offset: 3px; }

.sl, .en { display: none; }
html[lang="sl"] .sl { display: revert; }
html[lang="en"] .en { display: revert; }
html[lang="sl"] li.sl,
html[lang="en"] li.en { display: list-item; }
html[lang="sl"] p.sl,
html[lang="en"] p.en,
html[lang="sl"] h1.sl,
html[lang="en"] h1.en,
html[lang="sl"] h2.sl,
html[lang="en"] h2.en,
html[lang="sl"] h3.sl,
html[lang="en"] h3.en,
html[lang="sl"] h3 .sl,
html[lang="en"] h3 .en,
html[lang="sl"] figcaption.sl,
html[lang="en"] figcaption.en,
html[lang="sl"] span.sl.block,
html[lang="en"] span.en.block { display: block; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* —— logo —— */
.mark {
  display: grid;
  place-items: center;
  width: 2.1rem;
  height: 2.1rem;
  flex-shrink: 0;
  background: var(--rust);
  color: var(--cream);
}
.mark svg { width: 1.15rem; height: 1.15rem; display: block; }

/* —— header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  min-height: 4.1rem;
}
.brand-lockup {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  text-decoration: none;
}
.brand-lockup strong {
  display: block;
  font-family: var(--sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.25;
  text-transform: uppercase;
}
.langs {
  display: inline-flex;
  flex-shrink: 0;
  border: 1px solid var(--ink);
  border-radius: 999px;
  overflow: hidden;
  background: var(--white);
}
.langs button {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.42rem 0.7rem;
  cursor: pointer;
}
.langs button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--white);
}

/* —— hero —— */
.hero { padding: 2.6rem 0 3.5rem; }
.kicker {
  margin: 0 0 0.85rem;
  color: var(--rust);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.kicker-line {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}
.kicker-line::before {
  content: "";
  width: 1.4rem;
  height: 2px;
  background: var(--rust);
  flex-shrink: 0;
}
.band-rust .kicker,
.band-rust .kicker-line { color: var(--rust-soft); }
.band-rust .kicker-line::before { background: var(--rust-soft); }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.03em;
}
h1 {
  margin: 0;
  font-size: clamp(2.55rem, 8vw, 4.2rem);
  line-height: 0.98;
}
h2 {
  margin: 0;
  font-size: clamp(1.85rem, 5vw, 2.55rem);
  line-height: 1.08;
}

.place {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 1.1rem 0 0;
  font-size: 1rem;
}
.place::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: var(--rust);
  flex-shrink: 0;
}

figure { margin: 0; }
.hero figure { margin-top: 1.85rem; }
.frame { background: #ddd4c8; }
.frame img { width: 100%; }
.hero img { width: 100%; height: auto; }

figcaption {
  margin-top: 0.8rem;
  padding-left: 0.85rem;
  border-left: 3px solid var(--rust);
  color: var(--ink);
  font-size: 0.95rem;
  line-height: 1.45;
}

/* —— bands —— */
.band { padding: 4.2rem 0; }
.band-rust {
  background: var(--rust);
  color: var(--cream);
}
.band-beige { background: var(--paper-deep); }
.band-white { background: var(--white); }

.lead {
  margin: 0.35rem 0 0;
  max-width: 22em;
  font-family: var(--serif);
  font-size: clamp(1.65rem, 4vw, 2.2rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.section-head { margin-bottom: 1.4rem; }

.prose {
  display: grid;
  gap: 1.05rem;
}
.prose p { margin: 0; }

/* —— na kratko —— */
.layers {
  margin: 2.4rem 0 0;
  padding: 0;
  list-style: none;
}
.layers li {
  display: grid;
  grid-template-columns: 0.7rem minmax(0, 1fr);
  column-gap: 0.85rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--line-light);
  list-style: none;
}
.layers li::marker { content: none; }
.layers li::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  margin-top: 0.55rem;
  border-radius: 50%;
  background: var(--rust-soft);
}
.layers h3 {
  margin: 0 0 0.35rem;
  font-family: var(--sans);
  font-size: 1.12rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.layers p { margin: 0; }

/* —— media stack —— */
.stack {
  display: grid;
  gap: 2rem;
  margin-top: 2.2rem;
}
.stack a.zoom {
  display: block;
  color: inherit;
  text-decoration: none;
}

.quote {
  margin: 2.4rem 0 0;
  padding: 1.15rem 1.15rem 1.2rem;
  background: var(--paper);
  border-left: 3px solid var(--rust);
}
.quote .kicker { margin-bottom: 0.55rem; }
.quote p:last-child {
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(1.25rem, 2.8vw, 1.55rem);
  font-style: italic;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

/* —— timeline —— */
.timeline {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
}
.timeline li {
  display: grid;
  grid-template-columns: 0.85rem 1fr;
  column-gap: 1rem;
  position: relative;
  padding: 0 0 2.1rem;
  list-style: none;
}
.timeline li::marker { content: none; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: 0.42rem;
  top: 0.85rem;
  bottom: 0;
  width: 2px;
  background: #b9aa96;
}
.timeline li:last-child::before { display: none; }
.timeline .dot {
  position: relative;
  z-index: 1;
  width: 0.875rem;
  height: 0.875rem;
  margin-top: 0.35rem;
  border-radius: 50%;
  box-shadow: 0 0 0 4px var(--paper-deep);
}
/* Črna = hiša / gradnja; rdeča = plošča / obeležje */
.timeline .dot--house { background: #191714; }
.timeline .dot--memorial { background: #a64f3b; }
.timeline-body { min-width: 0; }
.year {
  margin: 0;
  color: var(--rust);
  font-family: var(--serif);
  font-size: clamp(1.35rem, 4vw, 1.55rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.timeline h3 {
  margin: 0.25rem 0 0;
  font-family: var(--sans);
  font-size: 1.02rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.3;
}
.timeline p {
  margin: 0.4rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* —— archive —— */
.archive-label {
  margin: 2.2rem 0 0.7rem;
  color: var(--rust);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.archive-title {
  margin: 0 0 1.25rem;
  font-family: var(--serif);
  font-size: clamp(1.55rem, 4vw, 1.9rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1.15;
}
.gallery {
  display: grid;
  gap: 1.6rem;
}
.gallery-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}
.gallery figure img { width: 100%; }
.gallery .frame {
  border: 1px solid #b9aa96;
  background: #ddd4c8;
}
.gallery figcaption {
  margin-top: 0.65rem;
  font-size: 0.88rem;
}
.gallery-pair figcaption {
  border-left: 0;
  padding-left: 0;
}
.stack .gallery-pair {
  gap: 0.85rem;
}
.stack .gallery-pair figcaption {
  border-left: 3px solid var(--rust);
  padding-left: 0.85rem;
}
@media (max-width: 640px) {
  .stack .gallery-pair {
    grid-template-columns: 1fr;
    gap: 1.6rem;
  }
}

.doc-links {
  display: grid;
  gap: 0.7rem;
  margin-top: 1.4rem;
}
.doc {
  display: grid;
  gap: 0.15rem;
  padding: 1rem 1.05rem;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(28, 23, 20, 0.08);
  text-decoration: none;
}
.doc:hover { border-color: var(--rust); }
.doc-year {
  font-family: var(--serif);
  font-size: 1.3rem;
  letter-spacing: -0.03em;
}
html[lang="sl"] .doc-name.sl,
html[lang="en"] .doc-name.en {
  display: block;
  font-size: 0.98rem;
}
.doc-file {
  color: var(--muted);
  font-size: 0.8rem;
}

/* —— change —— */
.facts {
  margin: 2rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.75rem;
}
.facts li {
  display: grid;
  grid-template-columns: 2.4rem minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  padding: 1rem 0.95rem 1.05rem;
  border: 1px solid var(--line-light);
  list-style: none;
}
.facts li::marker { content: none; }
.facts .num {
  font-family: var(--serif);
  font-size: 1.55rem;
  letter-spacing: -0.03em;
  line-height: 1;
}
.facts h3 {
  margin: 0.1rem 0 0;
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.facts p {
  margin: 0.25rem 0 0;
  color: var(--rust-soft);
  font-size: 0.95rem;
}

/* —— continuity —— */
.continuity h2 {
  max-width: 16em;
  font-style: italic;
  font-weight: 450;
  font-size: clamp(1.9rem, 5vw, 2.8rem);
  line-height: 1.12;
}
.continuity .prose { margin-top: 1.35rem; }

/* —— stats —— */
.stat-grid {
  display: grid;
  gap: 0.85rem;
  margin-top: 1.5rem;
}
.stat-card {
  padding: 1.2rem 1.15rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.stat-card .label {
  margin: 0;
  color: var(--rust);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.stat-card strong {
  display: block;
  margin: 0.55rem 0 0.35rem;
  font-family: var(--serif);
  font-size: 2.4rem;
  font-weight: 500;
  letter-spacing: -0.04em;
  line-height: 1;
}
.stat-card .hint {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.chart-title {
  margin: 0 0 0.7rem;
  font-size: 0.98rem;
}
.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin: 0 0 0.9rem;
  color: var(--muted);
  font-size: 0.82rem;
}
.legend li {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}
.swatch {
  width: 0.7rem;
  height: 0.7rem;
  background: var(--rust);
}
.swatch.en { background: #2a211c; }
.chart {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.65rem;
  align-items: end;
}
.bars {
  display: flex;
  justify-content: center;
  align-items: end;
  gap: 0.3rem;
  height: 140px;
  border-bottom: 1px solid var(--line);
}
.bar {
  width: 0.85rem;
  height: 0;
  min-height: 0;
  background: var(--rust);
}
.bar.en { background: #2a211c; }
.chart span {
  display: block;
  margin-top: 0.4rem;
  text-align: center;
  color: var(--rust);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
}
.table-wrap {
  margin-top: 1.35rem;
  overflow-x: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
th, td {
  padding: 0.7rem 0.4rem;
  text-align: right;
  border-bottom: 1px solid var(--line);
  font-weight: 400;
}
th:first-child,
td:first-child { text-align: left; }
thead th {
  background: var(--paper);
  color: var(--rust);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.note {
  margin: 1.1rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* —— sources —— */
.sources,
.legend {
  margin: 1.35rem 0 0;
  padding: 0;
  list-style: none;
}
.sources li::marker,
.legend li::marker { content: none; }
.sources li {
  padding: 0.75rem 0;
  border-top: 1px solid var(--line);
}
.sources a {
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}
.sources a:hover { color: var(--rust); }

.credit-note {
  margin: 1.5rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}
.credit-note p { margin: 0.25rem 0 0; }

/* —— footer —— */
.site-footer {
  background: var(--footer);
  color: #f3eee6;
  padding: 2.2rem 0 2.6rem;
}
.footer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.6rem;
}
.to-top {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.85rem;
  border: 1px solid rgba(243, 238, 230, 0.55);
  border-radius: 999px;
  color: #f3eee6;
  text-decoration: none;
  font-size: 0.88rem;
}
.to-top:hover { border-color: #f3eee6; }
.site-footer h2 {
  margin: 0;
  max-width: 16em;
  color: #fff;
  font-size: clamp(1.55rem, 4vw, 2rem);
  line-height: 1.15;
}
.site-footer .place {
  margin-top: 0.85rem;
  color: rgba(243, 238, 230, 0.7);
}
.site-footer .place::before { background: var(--rust); }

@media (max-width: 640px) {
  :root { --gutter: 1.5rem; }
  body { font-size: 1rem; }
  .site-header .wrap { min-height: 3.75rem; }
  .brand-lockup strong { font-size: 0.6rem; letter-spacing: 0.06em; }
  .langs button { padding: 0.38rem 0.62rem; font-size: 0.68rem; }
  .hero { padding: 2rem 0 2.75rem; }
  h1 { font-size: clamp(2.2rem, 11vw, 2.9rem); }
  h2 { font-size: clamp(1.65rem, 7vw, 2.1rem); }
  .lead { font-size: clamp(1.45rem, 6.5vw, 1.85rem); }
  .band { padding: 3rem 0; }
  .gallery { gap: 1.35rem; }
  .gallery-pair {
    grid-template-columns: 1fr;
    gap: 1.35rem;
  }
  .stat-card { padding: 1.05rem 1rem 1.1rem; }
  .chart {
    gap: 0.4rem;
  }
  .bars { height: 120px; }
  .bar { width: 0.7rem; }
  .facts li { padding: 0.9rem 0.85rem; }
  .site-footer { padding: 2rem 0 2.3rem; }
  .site-footer h2 { font-size: 1.45rem; }
}

@media print {
  .site-header { position: static; }
  .band-rust, .site-footer {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
}
