:root {
  color-scheme: light;
  --paper: #f4f0e8;
  --ink: #17201c;
  --muted: #65706c;
  --line: #d8d0c2;
  --terracotta: #b64f32;
  --blue: #376a8f;
  --green: #647b4e;
  --gold: #c99633;
  --white: #fffaf0;
  --shadow: 0 22px 70px rgba(23, 32, 28, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, "Segoe UI", Arial, sans-serif;
}

button,
input {
  font: inherit;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
  min-height: 72px;
  padding: 14px clamp(18px, 4vw, 56px);
  color: var(--white);
  background: linear-gradient(180deg, rgba(18, 22, 20, 0.82), rgba(18, 22, 20, 0.18));
  backdrop-filter: blur(10px);
}

.brand,
.nav-links,
.submit-link {
  display: inline-flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 250, 240, 0.55);
  border-radius: 50%;
  background: rgba(255, 250, 240, 0.12);
  font-size: 13px;
  letter-spacing: 0;
}

.nav-links {
  justify-content: center;
  gap: clamp(16px, 3vw, 34px);
  color: rgba(255, 250, 240, 0.86);
  font-size: 15px;
}

.submit-link {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid rgba(255, 250, 240, 0.5);
  border-radius: 999px;
  color: var(--white);
  font-weight: 700;
}

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: 92vh;
  padding: 120px clamp(18px, 5vw, 72px) 64px;
  overflow: hidden;
}

.hero-media,
.hero-overlay {
  position: absolute;
  inset: 0;
}

.hero-media {
  background:
    image-set(
      url("https://commons.wikimedia.org/wiki/Special:Redirect/file/Independence%20Square%20%28Kyiv%29.png") 1x
    )
    center / cover;
  transform: scale(1.02);
}

.hero-overlay {
  background:
    linear-gradient(90deg, rgba(13, 16, 14, 0.82) 0%, rgba(13, 16, 14, 0.52) 45%, rgba(13, 16, 14, 0.18) 100%),
    linear-gradient(0deg, rgba(244, 240, 232, 1) 0%, rgba(244, 240, 232, 0) 22%);
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(760px, 100%);
  color: var(--white);
}

.eyebrow,
.section-kicker,
.tag,
.dialog-tag {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  max-width: 10ch;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(58px, 11vw, 136px);
  line-height: 0.92;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 650px;
  margin-bottom: 28px;
  color: rgba(255, 250, 240, 0.9);
  font-size: clamp(18px, 2vw, 23px);
  line-height: 1.45;
}

.hero-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 48px;
  align-items: center;
  gap: 12px;
  width: min(640px, 100%);
  min-height: 58px;
  padding: 6px 6px 6px 18px;
  border: 1px solid rgba(255, 250, 240, 0.48);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.16);
  backdrop-filter: blur(16px);
}

.hero-search label {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.hero-search input {
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--white);
}

.hero-search input::placeholder {
  color: rgba(255, 250, 240, 0.68);
}

.hero-search button {
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: var(--gold);
  color: #1f1a12;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

.section-intro,
.toolbar,
.feature-grid,
.routes-band,
.calendar,
.site-footer {
  width: min(1180px, calc(100% - 36px));
  margin-inline: auto;
}

.section-intro {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(280px, 0.7fr);
  gap: clamp(24px, 6vw, 88px);
  padding: 46px 0 28px;
  border-bottom: 1px solid var(--line);
}

.section-intro h2,
.routes-copy h2,
.calendar-heading h2 {
  margin-bottom: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(34px, 5vw, 64px);
  line-height: 1;
  letter-spacing: 0;
}

.section-intro p:not(.section-kicker),
.routes-copy p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.65;
}

.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 24px 0;
}

.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.filter-btn {
  min-height: 38px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-weight: 750;
}

.filter-btn.active {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--white);
}

.quick-stats {
  display: flex;
  gap: 18px;
  color: var(--muted);
  white-space: nowrap;
}

.quick-stats strong {
  color: var(--ink);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  padding-bottom: 70px;
}

.article-card {
  display: flex;
  min-height: 430px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 10px 36px rgba(23, 32, 28, 0.08);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.article-card img,
.photo-strip {
  width: 100%;
  min-height: 185px;
  object-fit: cover;
}

.article-card:not(.lead-card) {
  flex-direction: column;
}

.lead-card {
  grid-column: span 2;
}

.lead-card img {
  width: 46%;
  min-height: 100%;
}

.card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 24px;
}

.card-body h3 {
  margin-bottom: 14px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(24px, 2.4vw, 34px);
  line-height: 1.08;
  letter-spacing: 0;
}

.article-card:not(.lead-card) .card-body h3 {
  font-size: 25px;
}

.card-body p {
  color: var(--muted);
  line-height: 1.58;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: auto;
  padding-top: 18px;
  color: var(--muted);
  font-size: 14px;
}

.read-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  font-weight: 800;
}

.color-card {
  background: #f0ddcb;
}

.color-card.green {
  background: #e1e8d8;
}

.photo-strip {
  background:
    linear-gradient(135deg, rgba(55, 106, 143, 0.86), rgba(182, 79, 50, 0.6)),
    url("https://commons.wikimedia.org/wiki/Special:Redirect/file/Kyiv_Pechersk_Lavra_exterior_in_2019.jpg") center / cover;
}

.photo-strip.gallery {
  background:
    linear-gradient(135deg, rgba(23, 32, 28, 0.62), rgba(100, 123, 78, 0.66)),
    url("https://commons.wikimedia.org/wiki/Special:Redirect/file/Independence%20Square%20%28Kyiv%29.png") center / cover;
}

.routes-band {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(280px, 0.9fr);
  gap: clamp(24px, 6vw, 78px);
  align-items: start;
  padding: 54px clamp(0px, 3vw, 36px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.route-list {
  display: grid;
  gap: 10px;
}

.route-list a {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  align-items: center;
  min-height: 64px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 250, 240, 0.54);
  font-weight: 800;
}

.route-list span {
  color: var(--terracotta);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 24px;
}

.calendar {
  padding: 70px 0;
}

.calendar-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.calendar-grid article {
  min-height: 210px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.calendar-grid span {
  color: var(--terracotta);
  font-weight: 900;
}

.calendar-grid h3 {
  margin: 24px 0 12px;
  font-size: 23px;
}

.calendar-grid p {
  color: var(--muted);
  line-height: 1.55;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 30px 0 42px;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer strong {
  color: var(--ink);
}

.site-footer p {
  margin: 6px 0 0;
}

.site-footer a {
  font-weight: 900;
}

.article-dialog {
  width: min(760px, calc(100% - 28px));
  max-height: min(760px, calc(100vh - 28px));
  padding: 34px;
  border: 0;
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  box-shadow: var(--shadow);
}

.article-dialog::backdrop {
  background: rgba(16, 20, 18, 0.62);
  backdrop-filter: blur(3px);
}

.article-dialog h2 {
  margin-bottom: 16px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(32px, 5vw, 52px);
  line-height: 1;
  letter-spacing: 0;
}

.article-dialog p {
  color: var(--muted);
  font-size: 17px;
  line-height: 1.7;
}

.article-dialog ul {
  display: grid;
  gap: 10px;
  padding-left: 20px;
  color: var(--muted);
  line-height: 1.6;
}

.close-dialog {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  font-size: 24px;
  line-height: 1;
}

.hidden {
  display: none;
}

.article-header-nav {
  background: rgba(23, 32, 28, 0.94);
}

.post-page,
.category-page {
  width: min(900px, calc(100% - 36px));
  margin-inline: auto;
  padding-top: 128px;
}

.post-hero {
  padding-bottom: 34px;
  border-bottom: 1px solid var(--line);
}

.post-back {
  display: inline-flex;
  margin-bottom: 28px;
  color: var(--muted);
  font-weight: 800;
}

.post-hero h1,
.category-page h1 {
  max-width: 12ch;
  margin-bottom: 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(42px, 8vw, 82px);
  line-height: 0.96;
  letter-spacing: 0;
}

.post-excerpt,
.category-page p {
  max-width: 720px;
  color: var(--muted);
  font-size: clamp(18px, 2vw, 22px);
  line-height: 1.55;
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
}

.post-meta span {
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 240, 0.6);
}

.post-image {
  display: block;
  width: 100%;
  max-height: 480px;
  margin-top: 28px;
  border-radius: 8px;
  object-fit: cover;
}

.post-content {
  padding: 38px 0 76px;
}

.post-content h2,
.post-content h3 {
  margin: 32px 0 12px;
  font-family: Georgia, "Times New Roman", serif;
  letter-spacing: 0;
}

.post-content p,
.post-content li {
  color: var(--muted);
  font-size: 18px;
  line-height: 1.75;
}

.post-content ul {
  display: grid;
  gap: 10px;
  padding-left: 22px;
}

.category-page {
  padding-bottom: 32px;
}

.category-grid {
  padding-bottom: 76px;
}

@media (max-width: 940px) {
  .site-header {
    grid-template-columns: 1fr auto;
  }

  .nav-links {
    display: none;
  }

  .section-intro,
  .routes-band {
    grid-template-columns: 1fr;
  }

  .toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .feature-grid,
  .calendar-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lead-card {
    grid-column: span 2;
    flex-direction: column;
  }

  .lead-card img {
    width: 100%;
    min-height: 260px;
  }
}

@media (max-width: 640px) {
  .site-header {
    min-height: 64px;
    padding: 12px 14px;
  }

  .brand span:last-child {
    max-width: 116px;
    line-height: 1.05;
  }

  .submit-link {
    justify-content: center;
    width: 42px;
    padding: 0;
    overflow: hidden;
    color: transparent;
    font-size: 0;
  }

  .submit-link::before {
    content: "+";
    color: var(--white);
    font-size: 26px;
    line-height: 1;
  }

  .hero {
    min-height: 88vh;
    padding: 96px 18px 48px;
  }

  h1 {
    font-size: 56px;
  }

  .hero-search {
    grid-template-columns: 1fr 44px;
    border-radius: 28px;
  }

  .hero-search label {
    display: none;
  }

  .hero-search button {
    width: 44px;
    height: 44px;
  }

  .quick-stats {
    flex-wrap: wrap;
    white-space: normal;
  }

  .feature-grid,
  .calendar-grid {
    grid-template-columns: 1fr;
  }

  .lead-card {
    grid-column: auto;
  }

  .article-card {
    min-height: 0;
  }

  .card-body {
    padding: 20px;
  }

  .site-footer,
  .calendar-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .article-dialog {
    padding: 28px 20px;
  }

  .post-page,
  .category-page {
    padding-top: 100px;
  }
}
