/* Shared styles for every page: skip link + site banner (field alert row + rotating announcements). */

.skip-link {
  position: absolute; left: 0.75rem; top: -3rem; z-index: 10001;
  background: #1c2e42; color: #fff; padding: 0.6rem 1rem; border-radius: 0 0 0.5rem 0.5rem;
  font: 600 0.9rem/1.2 'Inter', system-ui, sans-serif; text-decoration: none;
}
.skip-link:focus { top: 0; outline: 3px solid #9ab8d4; outline-offset: 2px; }

/* ── Banner ── under the nav at the top of the page; scrolls away with the page. site.js sets `top` = nav height. */
#site-banner {
  position: absolute; left: 0; right: 0; z-index: 99; /* below every nav (index 100, subpages 1000) so the hanging logo and menus paint over it */
  font-family: 'Inter', system-ui, sans-serif;
  box-shadow: 0 4px 12px rgba(0,0,0,0.12);
}
.sb-row {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.55rem 1rem 0.55rem 1.25rem; min-height: 2.6rem;
  font-size: 0.9rem; line-height: 1.35;
}
.sb-row a { color: inherit; font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.sb-text { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0.6rem; }
.sb-text .fa-solid { font-size: 0.95rem; opacity: 0.9; }
.sb-btn {
  background: none; border: 0; color: inherit; cursor: pointer; flex-shrink: 0;
  min-width: 2rem; min-height: 2rem; border-radius: 0.4rem; font-size: 0.85rem;
  display: inline-flex; align-items: center; justify-content: center; opacity: 0.85;
}
.sb-btn:hover { opacity: 1; background: rgba(127,127,127,0.18); }
.sb-btn:focus-visible, .sb-row a:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.sb-count { font-size: 0.75rem; opacity: 0.8; font-variant-numeric: tabular-nums; min-width: 2.2rem; text-align: center; }
.sb-thumb { width: 3rem; height: 3rem; object-fit: cover; border-radius: 0.4rem; flex-shrink: 0; }

/* Announcements: club navy */
.sb-ticker { background: #eef3f8; color: #1c2e42; border-bottom: 1px solid #c9d3de; }
.sb-ticker .sb-kicker {
  flex-shrink: 0; background: #1c2e42; color: #fff; border-radius: 9999px;
  font-size: 0.66rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; padding: 0.2rem 0.55rem;
}

/* Field alert row: color by type (always first, never rotates) */
.sb-alert { border-bottom: 3px solid; font-weight: 500; }
.sb-alert.t-warning  { background: #fffbea; color: #7a3a00; border-color: #f59e0b; }
.sb-alert.t-closed   { background: #fef2f2; color: #8f1414; border-color: #ef4444; }
.sb-alert.t-info     { background: #eff6ff; color: #1e3a8a; border-color: #3b82f6; }
.sb-alert.t-memorial { background: #1c2e42; color: #e8edf2; border-color: #7a9bbf; }
.sb-alert .sb-title { font-weight: 700; }

@media (max-width: 600px) {
  .sb-row { padding: 0.5rem 0.5rem 0.5rem 0.85rem; font-size: 0.84rem; gap: 0.4rem; }
  .sb-ticker .sb-kicker { display: none; }
  .sb-count { display: none; }
  .sb-thumb { width: 2.5rem; height: 2.5rem; }
}

/* Subpage heroes start with 8rem of top padding under the fixed nav. Always reserve one banner row (3.5rem) so the
   page doesn't jump when the banner appears; only a taller banner (field alert + announcements) pushes further.
   site.js sets --banner-h to the banner's height (0 when there is none). The homepage hero is tall enough already. */
.hero { padding-top: calc(8rem + max(3.5rem, var(--banner-h, 0px))) !important; }

/* Hide the banner while the phone menu is open (the menu is translucent). */
body:has(.nav-links.mobile-open) #site-banner { visibility: hidden; }
