/* Site-level layout & interaction rules, on top of the design-system tokens (styles.css). */
.evt .card-img,
.evt img.card-img { transition: transform var(--dur-slow, 420ms) var(--ease-standard, cubic-bezier(.4,0,.2,1)); }
.evt:hover .card-img { transform: scale(1.03); }
.evt:hover h4 { color: var(--accent-primary, #A50404); }

/* Grid/flex children default to min-width:auto (= content's min-content size), which stops
   Cyrillic caps labels and images from shrinking and forces the whole page to overflow
   horizontally on narrow screens. Force them shrinkable everywhere. */
div[style*="display:grid"] > *,
div[style*="display:flex"] > *,
nav div[style*="display:flex"] > a { min-width: 0; }
img { max-width: 100%; height: auto; }

@media (max-width: 900px) {
  div[style*="grid-template-columns:repeat(3"] { grid-template-columns: 1fr 1fr !important; }
  div[style*="grid-template-columns:380px"] { grid-template-columns: 1fr !important; }
  div[style*="grid-template-columns:1fr 420px"] { grid-template-columns: 1fr !important; }
  div[style*="grid-template-columns:1fr 1.1fr"] { grid-template-columns: 1fr !important; }
  div[style*="margin-left:calc(380px"] { margin-left: 0 !important; max-width: 100% !important; }
}

@media (max-width: 640px) {
  div[style*="grid-template-columns:repeat(3"] { grid-template-columns: 1fr !important; }
  header div[style*="max-width:1280px"] { flex-wrap: wrap; row-gap: 12px; }
  nav div[style*="max-width:1280px"] { flex-wrap: wrap; row-gap: 4px; padding-top: 4px; padding-bottom: 4px; }
  h1 { font-size: 30px !important; line-height: 36px !important; }
  div[style*="padding:0 24px"] { padding-left: 16px !important; padding-right: 16px !important; }
}

html, body { overflow-x: hidden; }
::-moz-selection { background: #A50404; color: #fff; }
