/* =========================
   Reset & Base
   ========================= */
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
  color: #222;
  background: #f7f7f8;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: #0b66c3; text-decoration: none; }
.container { max-width: 1100px; margin: 0 auto; padding: 24px; }

/* Utilities */
.small { font-size: 0.9rem; }
.muted { color: #777; }
.visually-hidden {
  position: absolute !important;
  height: 1px; width: 1px; overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px); white-space: nowrap;
  border: 0; padding: 0; margin: -1px;
}

/* =========================
   Header / Brand / Nav
   ========================= */
.site-header {
  background: #fff;
  border-bottom: 1px solid #e6e6e9;
  position: sticky;
  top: 0;
  z-index: 9999; /* keep header above content */
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 24px;
}

/* Brand */
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  flex: 0 0 auto; /* take only needed space */
}
.brand img,
.brand-logo {
  display: block;
  width: auto;
  height: 56px;        /* desktop default */
  max-width: 180px;
  object-fit: contain;
  border-radius: 4px;
  flex-shrink: 0;
}
.brand h1 {
  font-size: 1.05rem;
  margin: 0;
  line-height: 1.1;
  color: inherit;
}
.brand h2 {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 400;
  color: #666;
  line-height: 1.05;
}

/* Navigation */
.nav, nav.nav {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-left: auto; /* push navigation to the right */
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.nav a, nav.nav a {
  padding: 8px 10px;
  border-radius: 6px;
  font-weight: 650;
  display: inline-block;
  white-space: nowrap;
}
.nav a:hover, nav.nav a:hover { background: #f0f6ff; }

/* =========================
   Hero / Page layout / Logo block
   ========================= */
.hero-side { padding: 28px 0; }
.hero-side-inner {
  display: flex;
  align-items: center;
  gap: 28px;
}
.hero-logo img {
  width: 220px;
  height: auto;
  display: block;
  border-radius: 8px;
}
.hero-text h1 {
  font-size: 2rem;
  margin: 0;
  line-height: 1.05;
}
.hero-text .lead {
  color: #444;
  margin-bottom: 12px;
  font-size: 1rem;
}

/* Page with left logo / right content */
.page-with-logo {
  display: grid;
  grid-template-columns: 220px minmax(600px, 1fr);
  gap: 32px;
  align-items: stretch;
  margin-top: 20px;
}

/* Left column images (logo, season photos) */
.page-logo img,
.season-photo img,
.hero-logo img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  display: block;
  margin: 0 auto;
}
.season-sidebar {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding-left: 12px;
  min-height: 0;
}

/* Season list links */
.season-list a {
  display: block;
  padding: 4px 0;
  color: #0b66c3;
  font-weight: 600;
  text-decoration: none;
  transition: color .12s, background .12s;
}
.season-list a:hover { text-decoration: underline; }
.season-list a.active {
  color: #083a72;
  background: rgba(11,102,195,0.06);
  padding-left: 6px;
  border-radius: 4px;
}

/* =========================
   Page content & cards
   ========================= */
.page-content h1 { margin-top: 0; font-size: 1.6rem; margin-bottom: 12px; }
.page-content p { text-align: justify; margin-bottom: 14px; color: #333; line-height: 1.6; }

.card {
  background: #fff;
  padding: 16px;
  border-radius: 10px;
  border: 1px solid #eef0f3;
}
.card h2 { margin-bottom: 14px; }
.card ul { list-style: none; padding-left: 0; margin-left: 0; }
.card li { margin-bottom: 6px; }

/* Table */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid #f0f0f2;
}
.table th { font-weight: 700; background: #fafbfc; }

/* Table section title */
.table-section-title {
  font-weight: 700;
  text-align: left;
  margin-left: 60px;
  margin-bottom: 6px;
  font-size: 1.05rem;
  color: #222;
}

/* Link row (two variants: flex and grid) */
.link-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f2;
}
.link-row span { font-weight: 600; color: #222; }
.link-row a {
  font-weight: 600;
  color: #0b66c3;
  white-space: nowrap;
  text-decoration: none;
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Alternate grid layout */
.link-row.grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 12px;
}
.link-row.grid span { grid-column: 1; justify-self: start; padding-right: 8px; }
.link-row.grid a { grid-column: 2; justify-self: start; text-align: left; white-space: nowrap; }

/* =========================
   Map preview / Photos / Stepan layout
   ========================= */
.map-preview {
  margin-top: 22px;
  display: flex;
  justify-content: center;
}
.map-preview img {
  width: 100%;
  max-width: 650px;
  border-radius: 12px;
  display: block;
  box-shadow: 0 4px 12px rgba(0,0,0,0.10);
  transition: transform 0.15s ease;
}
.map-preview img:hover { transform: scale(1.02); }

.stepan-photo,
.season-photo {
  text-align: center;
  margin: 20px 0;
}
.stepan-photo img,
.season-photo img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  display: block;
  margin: 0 auto;
}

/* two-column stepan layout */
.stepan-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin-top: 20px;
  align-items: start;
}

/* Winners list */
.winners-list { margin-top: 16px; }
.winners-list-title { text-align: center; margin-bottom: 14px; }

.winner-row {
  display: flex;
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f2;
  align-items: center;
}
.winner-row:last-child { border-bottom: none; }
.winner-row span:first-child {
  width: 160px;
  font-weight: 600;
}
.winner-row span:last-child {
  margin-left: auto;
  font-weight: 600;
  white-space: nowrap;
}

/* =========================
   Latest posts / articles
   ========================= */
.latest-post .post-date,
.post-date {
  color: #777;
  font-size: 0.9rem;
  margin-bottom: 8px;
  display: block;
}
.latest-post .post-title,
article h1 {
  margin: 6px 0 8px;
  font-size: 1.25rem;
  color: #111;
}

/* excerpt truncated to 2 lines (expand on small devices) */
.post-excerpt {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #444;
}

/* Buttons */
.btn {
  background: #0b66c3;
  color: #fff;
  padding: 8px 12px;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 700;
  display: inline-block;
}
.btn-ghost {
  background: transparent;
  color: #0b66c3;
  border: 1px solid #0b66c3;
  padding: 8px 12px;
  border-radius: 6px;
  text-decoration: none;
}

/* Post body */
.post-body p { margin-bottom: 14px; color: #333; line-height: 1.6; }

/* Footer */
.site-footer .container { text-align: center; padding: 18px 0; color: #666; }

/* =========================
   Logo & header responsiveness (consolidated)
   ========================= */
/* desktop already defined above; now responsive tweaks below */

/* Breakpoint: <= 880px */
@media (max-width:880px){
  .nav { display: none; } /* optional: hide nav in small desktop/tablet */
  .brand h1 { font-size: 1rem; }
  .hero-logo img { width: 160px; }
  .hero-text h1 { font-size: 1.6rem; }
}

/* Breakpoint: <= 780px */
@media (max-width:780px) {
  .link-row { flex-direction: column; align-items: flex-start; gap: 6px; }
  .link-row a { white-space: normal; text-overflow: unset; }
  .link-row.grid { grid-template-columns: 1fr; }

  .page-with-logo { grid-template-columns: 1fr; }
  .season-sidebar { order: -1; padding-left: 0; align-items: center; }
  .season-list { max-width: 100%; align-items: center; }
  .season-list a { white-space: normal; text-align: center; }
  .season-photo img { width: 100%; }

  .latest-post .post-title { font-size: 1.1rem; }
  .post-excerpt { -webkit-line-clamp: 4; }

  .stepan-layout { grid-template-columns: 1fr; }
}

/* Breakpoint: <= 720px */
@media (max-width:720px) {
  .brand img.brand-logo,
  .brand-logo { height: 44px; max-width: 140px; }
  .brand-text h1 { font-size: 0.95rem; }
  .brand-text h2 { font-size: 0.8rem; }

  /* shrink content logo */
  .page-logo img,
  .page-logo .resp,
  .page-logo img.resp { max-width: 160px; margin-top: 6px; margin-bottom: 10px; }

  /* navigation safeguards */
  nav.nav { margin-left: 8px; overflow-x: auto; }
}

/* Breakpoint: <= 520px (mobile) */
@media (max-width:520px) {
  .brand img { width: 40px; height: 40px; }
  .brand-logo { height: 36px; max-width: 90px; }
  .brand-text { display: none; } /* hide text on small phones */
  nav.nav { font-size: 0.95rem; }

  .winner-row span:first-child { width: 120px; }
  .page-content p { font-size: 0.95rem; }

  /* content logo smaller */
  .page-logo img,
  .page-logo .resp,
  .page-logo img.resp { max-width: 120px; }
}

/* Breakpoint: <= 420px (very small) */
@media (max-width:420px) {
  .brand img.brand-logo,
  .brand-logo { height: 36px; max-width: 110px; }
  .page-logo img,
  .page-logo .resp { max-width: 120px; }
}