:root {
  --ink: #251a14;
  --green: #33563f;
  --orange: #ef5b09;
  --paper: #f6f1e8;
  --line: #e8e1d7;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: Arial, Helvetica, sans-serif;
}
a { color: inherit; }
img { max-width: 100%; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  display: grid;
  grid-template-columns: minmax(280px, 1fr) auto minmax(620px, 1fr);
  align-items: center;
  min-height: 86px;
  padding: 10px clamp(20px, 4vw, 70px);
  background: rgba(255,255,255,.97);
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 12px rgba(36,22,15,.04);
}
.site-brand {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
  font-size: clamp(20px, 2vw, 29px);
  white-space: nowrap;
}
.site-brand img { width: 74px; height: 58px; object-fit: contain; }
.site-brand strong { font-weight: 700; }
.visitor-counter {
  position: relative;
  display: grid;
  place-items: center;
  width: 110px;
  height: 66px;
  margin: 0 24px;
  color: var(--green);
  cursor: help;
  outline: none;
}
.visitor-counter__icon {
  position: absolute;
  inset: 0;
  width: 110px;
  height: 66px;
  overflow: visible;
  fill: none;
  z-index: 2;
}
.visitor-counter__steam {
  fill: none;
  stroke: var(--orange);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.visitor-counter__plate-outer { fill: var(--green); }
.visitor-counter__plate-inner {
  fill: #fff;
  stroke: var(--green);
  stroke-width: 2;
}
.visitor-counter__mark {
  position: absolute;
  left: 50%;
  top: 10px;
  width: 98px;
  height: auto;
  transform: translateX(-50%);
  filter: invert(27%) sepia(18%) saturate(721%) hue-rotate(91deg) brightness(91%) contrast(91%);
  z-index: 1;
}
.visitor-counter strong {
  position: absolute;
  left: 50%;
  top: 39px;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  color: var(--orange);
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  z-index: 3;
}
.visitor-counter strong[data-digits="3"] { font-size: 14px; }
.visitor-counter strong[data-digits="4"] { font-size: 11px; }
.visitor-counter__tooltip {
  position: absolute;
  top: calc(100% + 9px);
  left: 50%;
  z-index: 10;
  width: max-content;
  max-width: none;
  padding: 9px 12px;
  transform: translate(-50%, -5px);
  border-radius: 7px;
  background: #2b1c14;
  color: #fff;
  box-shadow: 0 7px 20px rgba(43, 28, 20, .18);
  font-size: 13px;
  font-weight: 400;
  line-height: 1.35;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .16s ease, transform .16s ease, visibility .16s ease;
}
.visitor-counter__tooltip::before {
  content: "";
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-bottom-color: #2b1c14;
}
.visitor-counter:hover .visitor-counter__tooltip,
.visitor-counter:focus-visible .visitor-counter__tooltip {
  transform: translate(-50%, 0);
  opacity: 1;
  visibility: visible;
}
.visitor-counter:focus-visible {
  border-radius: 8px;
  box-shadow: 0 0 0 2px rgba(51, 86, 63, .22);
}
.site-nav { display: flex; align-items: center; justify-self: end; gap: clamp(18px, 2vw, 34px); }
.site-nav__link {
  padding: 12px 0 9px;
  color: #4a433f;
  text-decoration: none;
  font-size: 15px;
  border-bottom: 2px solid transparent;
}
.site-nav__link:hover, .site-nav__link.is-active { color: var(--ink); border-color: var(--green); }
.site-nav-toggle { display: none; }
.site-main { min-height: 65vh; padding: clamp(32px, 5vw, 78px) 18px; overflow: hidden; }
.site-main > .b-c { width: min(1120px, 100%); margin: 0 auto; }
.site-footer {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  padding: 34px clamp(24px, 6vw, 90px);
  color: #fff;
  background: #2d4937;
  line-height: 1.6;
  font-size: 14px;
}
.site-footer > div:nth-child(2) { text-align: center; }
.site-footer > div:last-child { text-align: right; }
.site-footer a { color: #fff; text-decoration: none; }

@media (max-width: 920px) {
  .site-header { grid-template-columns: 1fr auto; min-height: 72px; padding: 7px 18px; }
  .site-brand img { width: 60px; height: 48px; }
  .site-brand { font-size: 21px; }
  .site-nav-toggle {
    display: block;
    grid-column: 2;
    grid-row: 1;
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--ink);
    font-weight: 700;
  }
  .site-nav {
    display: none;
    grid-column: 1 / -1;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 13px;
  }
  .site-nav.is-open { display: flex; }
  .visitor-counter {
    grid-column: 1 / -1;
    grid-row: 2;
    margin: 0 auto 3px;
  }
  .visitor-counter__tooltip { white-space: normal; text-align: center; }
  .visitor-counter__tooltip { width: min(320px, calc(100vw - 24px)); }
  .site-nav__link { padding: 11px 6px; border-bottom-width: 1px; }
  .site-main { padding: 28px 10px 45px; }
  .site-footer { grid-template-columns: 1fr; text-align: center; }
  .site-footer > div:nth-child(2), .site-footer > div:last-child { text-align: center; }
}
