:root {
  --navy: #141b33;
  --navy-2: #1f2a50;
  --gold: #d8a94f;
  --gold-2: #f3d99b;
  --cream: #faf7f0;
  --paper: #fff;
  --ink: #1b2036;
  --muted: #646b80;
  --line: #e6e0d2;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(20, 27, 51, .06), 0 8px 24px rgba(20, 27, 51, .08);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
body {
  margin: 0;
  font: 1.0625rem/1.65 system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--cream);
}
img { max-width: 100%; height: auto; }
a { color: var(--navy-2); }
h1, h2, h3 { line-height: 1.15; text-wrap: balance; margin: 0 0 .5em; }
h1, h2 { font-style: italic; font-weight: 800; text-transform: uppercase; letter-spacing: -.01em; }
h2 { font-size: clamp(1.6rem, 4vw, 2.25rem); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.wrap { width: min(1120px, 100% - 2rem); margin-inline: auto; }
.narrow { width: min(760px, 100% - 2rem); }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 1rem; top: 1rem; z-index: 99; background: var(--paper); padding: .5rem 1rem; }

/* header */
.site-header { position: sticky; top: 0; z-index: 10; background: var(--navy); color: #fff; box-shadow: 0 2px 0 var(--gold); }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 4rem; }
.brand { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; font-weight: 800; font-style: italic; text-transform: uppercase; font-size: 1.25rem; line-height: 1.1; }
.brand img { width: 3rem; height: auto; }
.brand small { display: block; font-size: .65rem; font-weight: 600; font-style: normal; letter-spacing: .08em; color: var(--gold-2); white-space: nowrap; }
#nav { display: flex; gap: .25rem; }
#nav a { color: #fff; text-decoration: none; padding: .5rem .8rem; border-radius: 999px; font-weight: 600; font-size: .95rem; }
#nav a:hover, #nav a[aria-current] { background: rgba(255, 255, 255, .1); color: var(--gold-2); }
.nav-toggle { display: none; background: none; border: 1px solid rgba(255, 255, 255, .35); color: #fff; border-radius: 999px; padding: .4rem 1rem; font: inherit; font-weight: 600; cursor: pointer; }

/* hero */
.hero {
  color: #fff;
  background: linear-gradient(100deg, rgba(20, 27, 51, .96) 35%, rgba(31, 42, 80, .78)), url(../wp-content/uploads/2012/10/vojvode-kup-2012.jpg) center 25% / cover;
  padding: clamp(2.5rem, 7vw, 5rem) 0 0;
}
.hero-grid { display: grid; grid-template-columns: 1.3fr 1fr; align-items: center; gap: 2rem; }
.hero h1 { font-size: clamp(2.6rem, 8vw, 5rem); margin-bottom: .3em; }
.hero h1 em { color: var(--gold); }
.crest { width: min(420px, 100%); justify-self: center; filter: drop-shadow(0 12px 30px rgba(0, 0, 0, .45)); }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; font-weight: 700; color: var(--gold); margin: 0 0 .75rem; }
.lead { font-size: 1.15rem; max-width: 60ch; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }
.btn { display: inline-block; background: var(--gold); color: var(--navy); font: inherit; font-weight: 700; text-decoration: none; padding: .7rem 1.4rem; border-radius: 999px; border: 2px solid var(--gold); cursor: pointer; transition: transform .15s, background .15s; }
.btn:hover { background: var(--gold-2); transform: translateY(-1px); }
.btn.ghost { background: transparent; color: inherit; }
.btn.ghost:hover { background: rgba(216, 169, 79, .18); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); margin-block: clamp(2rem, 6vw, 4rem) 0; border-top: 1px solid rgba(255, 255, 255, .18); }
.stats div { padding: 1.25rem .5rem; text-align: center; }
.stats dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--gold-2); }
.stats dd { margin: 0; font-size: clamp(1.6rem, 5vw, 2.5rem); font-weight: 800; font-style: italic; }
.stats .years { display: flex; flex-wrap: wrap; justify-content: center; gap: .3rem; margin-top: .4rem; font-size: .75rem; font-style: normal; font-weight: 600; }
.stats .years span { border: 1px solid rgba(243, 217, 155, .5); color: var(--gold-2); border-radius: 999px; padding: .05rem .55rem; }
.stats .years a { color: var(--gold-2); }

/* sections */
.section { padding-block: clamp(2.5rem, 7vw, 5rem); }
.section-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.section-head h2 { margin: 0; }
input[type=search] { font: inherit; padding: .6rem 1rem; border: 1px solid var(--line); border-radius: 999px; background: var(--paper); width: min(100%, 18rem); }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.5rem; }
.chip { font: inherit; font-size: .9rem; font-weight: 600; padding: .35rem .95rem; border-radius: 999px; border: 1px solid var(--line); background: var(--paper); color: var(--ink); cursor: pointer; }
.chip[aria-pressed=true] { background: var(--navy); border-color: var(--navy); color: #fff; }

.cards { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 1.25rem; }
.card { background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; border-top: 3px solid var(--gold); transition: transform .15s, box-shadow .15s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 2px 4px rgba(20, 27, 51, .08), 0 14px 34px rgba(20, 27, 51, .14); }
.card a { display: block; height: 100%; padding: 1.25rem; color: inherit; text-decoration: none; }
.card a > img, .ph { display: block; width: calc(100% + 2.5rem); max-width: none; margin: -1.25rem -1.25rem 1rem; aspect-ratio: 16 / 9; object-fit: cover; }
.ph { display: grid; place-items: center; background: var(--navy); }
.ph img { width: 36%; height: auto; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .3)); }
.ph-1 { background: #b98a2f; }
.ph-2 { background: #2f4a8a; }
.ph-3 { background: #7a2e3a; }
.ph-4 { background: #2e6b5a; }
.ph-5 { background: #4a4f66; }
.card h3 { font-size: 1.2rem; }
.card p { margin: 0; color: var(--muted); font-size: .95rem; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; font-size: .8rem; color: var(--muted); margin: 0 0 .6rem !important; }
.tag { background: var(--navy); color: var(--gold-2); font-weight: 700; text-transform: uppercase; letter-spacing: .06em; font-size: .7rem; padding: .15rem .6rem; border-radius: 999px; }
.more, .empty { text-align: center; margin-top: 2rem; }

.band { background: var(--navy); color: #fff; padding-block: clamp(2.5rem, 7vw, 5rem); }
.split { display: grid; grid-template-columns: minmax(0, 340px) 1fr; gap: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.poster img { display: block; border-radius: var(--radius); box-shadow: 0 20px 50px rgba(0, 0, 0, .4); }

.contacts, .friends { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: 1.25rem; }
.contacts { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.contacts li { background: var(--paper); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); }
.contacts h3 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.contacts p { margin: .15rem 0; overflow-wrap: anywhere; }
.friends-title { margin-top: 3rem; font-size: 1.3rem; }
.friends { display: flex; flex-wrap: wrap; }
.friends img { display: block; border-radius: 10px; box-shadow: var(--shadow); }

/* post */
.post { padding-block: clamp(2rem, 6vw, 4rem); }
.post h1 { font-size: clamp(1.9rem, 5.5vw, 3rem); }
.back { display: inline-block; margin-bottom: 1.5rem; font-weight: 600; text-decoration: none; }
.content { overflow-wrap: break-word; }
.content img { border-radius: 8px; }
.content .alignleft { float: left; margin: .25rem 1rem .5rem 0; }
.content .aligncenter, .content figure { display: block; margin-inline: auto; text-align: center; }
.content figure { margin-block: 1.5rem; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: .5rem; margin-block: 1.5rem; }
.gallery img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: opacity .15s; }
.gallery a:hover img { opacity: .8; }

.comments { margin-top: 3rem; padding-top: 2rem; border-top: 2px solid var(--gold); }
.comments h2 { font-size: 1.4rem; }
.comments h2 span { color: var(--muted); font-style: normal; }
.comments ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.comments li { background: var(--paper); border-radius: var(--radius); padding: 1rem 1.25rem; box-shadow: var(--shadow); }
.c-head { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; }
.c-head time { color: var(--muted); font-size: .8rem; margin-left: auto; }
.avatar { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; background: var(--navy); color: var(--gold-2); font-weight: 700; }
.c-body { overflow-wrap: anywhere; }
.c-body p { margin: .6rem 0 0; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 3rem; }
.pager a { background: var(--paper); border-radius: var(--radius); padding: 1rem 1.25rem; box-shadow: var(--shadow); text-decoration: none; font-weight: 700; line-height: 1.3; }
.pager .next { text-align: right; }
.pager small { display: block; color: var(--muted); font-weight: 500; margin-bottom: .25rem; }

/* lightbox */
dialog.lightbox { border: 0; padding: 0; background: transparent; max-width: 100vw; max-height: 100vh; }
dialog.lightbox::backdrop { background: rgba(10, 14, 28, .92); }
dialog.lightbox img { display: block; max-width: 96vw; max-height: 92vh; border-radius: 6px; }
dialog.lightbox button { position: fixed; top: 50%; translate: 0 -50%; width: 3rem; height: 3rem; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .15); color: #fff; font-size: 1.5rem; cursor: pointer; }
dialog.lightbox button:hover { background: var(--gold); color: var(--navy); }
dialog.lightbox .lb-prev { left: 1rem; }
dialog.lightbox .lb-next { right: 1rem; }
dialog.lightbox .lb-close { top: 2.25rem; right: 1rem; }

.site-footer { background: var(--navy); color: #cfd3e0; text-align: center; padding: 2.5rem 0; font-size: .9rem; border-top: 2px solid var(--gold); }
.site-footer img { width: 5rem; }
.site-footer p { margin: .35rem 0; }
.site-footer a { color: var(--gold-2); }

@media (max-width: 760px) {
  .nav-toggle { display: block; }
  #nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; background: var(--navy); padding: .5rem 1rem 1rem; box-shadow: 0 2px 0 var(--gold); }
  #nav.open { display: flex; }
  .hero-grid, .split { grid-template-columns: 1fr; }
  .crest { order: -1; width: min(240px, 60%); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .poster { max-width: 320px; margin-inline: auto; }
  .pager { grid-template-columns: 1fr; }
  .pager .next { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
