/* Панчарево — общ стил за всички страници */
:root {
  --deep: #123a44;
  --teal: #2c6b7a;
  --lake: #3f8590;
  --foam: #e8f2ef;
  --paper: #f7f1e3;
  --sand: #efe2c4;
  --clay: #b8573c;
  --clay-dark: #8f3f2c;
  --ink: #1f2a2c;
  --muted: #4f5d5f;
  --serif: Georgia, "Times New Roman", "DejaVu Serif", serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--clay-dark); }
a:hover { color: var(--deep); }

h1, h2, h3 { font-family: var(--serif); line-height: 1.2; color: var(--deep); font-weight: normal; }
h1 { font-size: clamp(2rem, 5vw, 3.4rem); margin: 0 0 .4em; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.2rem); margin: 0 0 .6em; }
h3 { font-size: 1.25rem; margin: 0 0 .4em; }

.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }

/* ---------- шапка ---------- */
.site-head {
  background: var(--deep);
  color: var(--foam);
  position: relative;
  padding-bottom: 14px;
}
.site-head::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -12px;
  height: 14px;
  background: radial-gradient(circle at 12px -4px, var(--deep) 12px, transparent 13px) repeat-x;
  background-size: 24px 14px;
}
.head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0 8px;
  flex-wrap: wrap;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--foam);
  text-decoration: none;
}
.brand img { width: 58px; height: 58px; }
.brand-name { font-family: var(--serif); font-size: 1.45rem; line-height: 1.1; display: block; }
.brand-sub { font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; color: #a9cfcf; }
.brand:hover { color: #fff; }

.menu { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.menu a {
  display: block;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--foam);
  text-decoration: none;
  font-size: .95rem;
  border: 1px solid transparent;
}
.menu a:hover { border-color: #5f9ea6; color: #fff; }
.menu a[aria-current="page"] { background: var(--sand); color: var(--deep); }

/* ---------- заглавна зона ---------- */
.hero {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 40px;
  align-items: center;
  padding: 64px 0 40px;
}
.hero .kicker {
  font-size: .8rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--clay-dark);
  font-weight: 600;
}
.hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 34em; }
.hero-art {
  position: relative;
}
.hero-art img {
  border-radius: 160px 18px 160px 18px;
  box-shadow: 18px 18px 0 var(--sand);
}
.hero-art .badge {
  position: absolute;
  left: -18px; bottom: 22px;
  background: var(--clay);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-family: var(--serif);
  font-size: 1rem;
  box-shadow: 0 6px 18px rgba(18,58,68,.25);
}
.hero-art .badge small { display: block; font-family: var(--sans); font-size: .75rem; opacity: .9; }

.btn {
  display: inline-block;
  padding: 11px 22px;
  border-radius: 999px;
  background: var(--deep);
  color: var(--foam);
  text-decoration: none;
  margin: 6px 8px 0 0;
}
.btn:hover { background: var(--teal); color: #fff; }
.btn.ghost { background: transparent; color: var(--deep); border: 2px solid var(--deep); }
.btn.ghost:hover { background: var(--deep); color: var(--foam); }

/* ---------- лента с дистанции ---------- */
.lane-strip {
  background: var(--lake);
  color: #fff;
  margin: 24px 0 0;
  position: relative;
}
.lane-strip ol {
  list-style: none;
  margin: 0;
  padding: 26px 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}
.lane-strip li {
  padding: 4px 20px;
  border-left: 2px dashed rgba(255,255,255,.45);
}
.lane-strip li:first-child { border-left: 0; }
.lane-strip b { display: block; font-family: var(--serif); font-size: 1.9rem; font-weight: normal; }
.lane-strip span { font-size: .92rem; color: #e1f0ee; }

/* ---------- отсечки (секции с маркер) ---------- */
.leg {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 32px;
  padding: 56px 0;
  border-bottom: 1px solid #ddcfae;
}
.leg:last-of-type { border-bottom: 0; }
.leg .mark {
  font-family: var(--serif);
  color: var(--clay-dark);
  border-top: 4px solid var(--clay);
  padding-top: 10px;
  font-size: 1.05rem;
  align-self: start;
  position: sticky;
  top: 16px;
}
.leg .mark small { display: block; font-family: var(--sans); color: var(--muted); font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: start;
}
.split.flip > :first-child { order: 2; }
figure { margin: 0; }
figure img { border-radius: 14px; }
figcaption { font-size: .88rem; color: var(--muted); margin-top: 8px; font-style: italic; }

/* мозайка от картички */
.mosaic {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 18px;
  margin-top: 24px;
}
.tile {
  background: #fffaf0;
  border: 1px solid #e3d5b5;
  border-radius: 14px;
  padding: 22px;
  grid-column: span 2;
}
.tile.wide { grid-column: span 4; }
.tile.dark { background: var(--deep); color: var(--foam); border-color: var(--deep); }
.tile.dark h3 { color: var(--sand); }
.tile.clay { background: var(--clay); color: #fff; border-color: var(--clay); }
.tile.clay h3 { color: #fff; }
.tile .num { font-family: var(--serif); font-size: 2.4rem; color: var(--clay); line-height: 1; display: block; margin-bottom: 6px; }
.tile.dark .num { color: #e2a24a; }
.tile.clay .num { color: #fff; }
.tile p { margin: 0; }

/* дневник — бележки с дати */
.log { list-style: none; margin: 0; padding: 0; position: relative; }
.log::before { content: ""; position: absolute; left: 9px; top: 6px; bottom: 6px; width: 2px; background: var(--lake); }
.log li { position: relative; padding: 0 0 22px 38px; }
.log li::before {
  content: "";
  position: absolute; left: 2px; top: 6px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--paper); border: 3px solid var(--lake);
}
.log time { font-weight: 600; color: var(--teal); display: block; font-size: .9rem; }

/* цитат */
.quote {
  background: var(--sand);
  border-radius: 0 40px 0 40px;
  padding: 34px 40px;
  font-family: var(--serif);
  font-size: 1.3rem;
  color: var(--deep);
  margin: 0;
}
.quote cite { display: block; font-family: var(--sans); font-style: normal; font-size: .9rem; color: var(--muted); margin-top: 12px; }

/* списък с отметки */
.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
.ticks li { padding-left: 30px; position: relative; margin-bottom: 8px; }
.ticks li::before {
  content: "";
  position: absolute; left: 0; top: .45em;
  width: 16px; height: 8px;
  border-left: 3px solid var(--clay); border-bottom: 3px solid var(--clay);
  transform: rotate(-45deg);
}

/* таблица с разстояния */
.dist { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: .97rem; }
.dist th, .dist td { padding: 10px 12px; text-align: left; border-bottom: 1px solid #ddcfae; }
.dist th { font-family: var(--serif); font-weight: normal; color: var(--deep); background: #f1e6cc; }
.dist td:last-child { white-space: nowrap; }

/* сезони — четири ленти */
.seasons-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid #ddcfae;
  margin-top: 24px;
}
.seasons-grid article { padding: 22px; background: #fffaf0; border-left: 1px solid #ddcfae; }
.seasons-grid article:first-child { border-left: 0; }
.seasons-grid h3 { border-bottom: 3px solid var(--lake); padding-bottom: 6px; display: inline-block; }

/* бележка */
.note {
  border-left: 5px solid var(--clay);
  background: #fffaf0;
  padding: 16px 20px;
  border-radius: 0 10px 10px 0;
  margin: 18px 0;
}

/* ---------- долен колонтитул ---------- */
.site-foot {
  background: var(--deep);
  color: #cfe3e0;
  margin-top: 40px;
  padding: 44px 0 26px;
  font-size: .95rem;
  position: relative;
}
.site-foot::before {
  content: "";
  position: absolute;
  left: 0; right: 0; top: -12px;
  height: 14px;
  background: radial-gradient(circle at 12px 18px, var(--deep) 12px, transparent 13px) repeat-x;
  background-size: 24px 14px;
}
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.site-foot h3 { color: var(--sand); font-size: 1.1rem; }
.site-foot a { color: #f0d6a0; }
.site-foot ul { list-style: none; padding: 0; margin: 0; }
.site-foot li { margin-bottom: 6px; }
.foot-brand { display: flex; gap: 12px; align-items: flex-start; }
.foot-brand img { width: 44px; height: 44px; flex: none; }
.fine { border-top: 1px solid #2c5865; margin-top: 30px; padding-top: 16px; font-size: .85rem; color: #a9c4c2; }

/* ---------- адаптивност ---------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 44px; }
  .hero-art .badge { left: 10px; }
  .lane-strip ol { grid-template-columns: repeat(2, 1fr); row-gap: 18px; }
  .lane-strip li:nth-child(3) { border-left: 0; }
  .leg { grid-template-columns: 1fr; gap: 16px; padding: 40px 0; }
  .leg .mark { position: static; display: inline-block; }
  .split { grid-template-columns: 1fr; }
  .split.flip > :first-child { order: 0; }
  .mosaic { grid-template-columns: repeat(2, 1fr); }
  .tile, .tile.wide { grid-column: span 2; }
  .seasons-grid { grid-template-columns: repeat(2, 1fr); }
  .seasons-grid article:nth-child(3) { border-left: 0; }
  .seasons-grid article:nth-child(n+3) { border-top: 1px solid #ddcfae; }
  .foot-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .head-row { flex-direction: column; align-items: flex-start; }
  .menu a { padding: 6px 11px; font-size: .9rem; }
  .hero-art img { border-radius: 90px 12px 90px 12px; box-shadow: 10px 10px 0 var(--sand); }
  .lane-strip ol { grid-template-columns: 1fr; }
  .lane-strip li { border-left: 0; border-top: 2px dashed rgba(255,255,255,.45); padding-top: 12px; }
  .lane-strip li:first-child { border-top: 0; }
  .mosaic { grid-template-columns: 1fr; }
  .tile, .tile.wide { grid-column: span 1; }
  .seasons-grid { grid-template-columns: 1fr; }
  .seasons-grid article { border-left: 0; border-top: 1px solid #ddcfae; }
  .seasons-grid article:first-child { border-top: 0; }
  .quote { padding: 24px; font-size: 1.15rem; }
  .dist th, .dist td { padding: 8px 6px; }
}

/* въвеждаща зона без голяма рисунка */
.kicker {
  font-size: .8rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--clay-dark);
  font-weight: 600;
}
.page-intro { padding-top: 56px; }
.lead-wide { font-size: 1.15rem; color: var(--muted); max-width: 46em; }
.banner { margin: 28px 0 0; }
.banner img { border-radius: 18px; width: 100%; box-shadow: 0 10px 0 var(--sand); }
.dist caption { text-align: left; color: var(--muted); font-size: .88rem; padding-bottom: 6px; }

/* не позволяваме на картинките да разтягат мрежата */
.hero > *, .split > *, .leg > *, .mosaic > *, .seasons-grid > *, .foot-grid > * { min-width: 0; }
.dist { overflow-wrap: anywhere; }
