/* Homepage voting-dates bar. */
.jj-vote-bar {
  background: #c41230;
  color: #fff;
  padding: 20px 24px;
}
.jj-vote-bar-inner {
  max-width: 1240px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
}
.jj-vote-dates {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
}
.jj-vote-dates p {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 2px 32px;
  font: 400 16px/1.3 Montserrat, Arial, sans-serif;
}
.jj-vote-dates p:first-child {
  padding-left: 0;
}
.jj-vote-dates p + p {
  border-left: 1px solid rgba(255, 255, 255, 0.55); /* thin divider, as in the campaign mockup */
}
.jj-vote-icon {
  flex: none;
  width: 30px;
  height: 30px;
}
.jj-vote-dates strong {
  display: block;
  margin-bottom: 3px;
  font: 700 12px/1.3 Montserrat, Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.jj-vote-cta {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 22px;
  background: #0a2240;
  color: #fff;
  font: 700 13px/1.4 Montserrat, Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  text-decoration: none;
  transition: background 0.15s ease;
}
.jj-vote-cta:hover {
  background: #121961;
}
.jj-vote-cta:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}
@media (max-width: 1023px) {
  .jj-vote-dates {
    display: grid;
    grid-template-columns: repeat(3, auto); /* keeps the three items on one row so the dividers stay aligned */
  }
  .jj-vote-dates p {
    padding: 2px 20px;
    font-size: 15px;
  }
}
@media (max-width: 640px) {
  .jj-vote-dates {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }
  .jj-vote-dates p,
  .jj-vote-dates p:first-child {
    padding: 0;
    font-size: 15px;
  }
  .jj-vote-dates p + p {
    border-left: 0;
  }
  .jj-vote-icon {
    width: 26px;
    height: 26px;
  }
}

/* Shared heading style matches the first homepage sections. */
body .jj-section-heading .jj-section-kicker {
  margin: 0 0 12px;
  color: #c41230;
  font:
    700 12px/1.5 Montserrat,
    Arial,
    sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.35em;
}
body .jj-section-heading h2 {
  margin: 0;
  color: #0a2240;
  font:
    900 48px/1 Montserrat,
    Arial,
    sans-serif;
  text-transform: uppercase;
  letter-spacing: normal;
}
@media (max-width: 639px) {
  body .jj-section-heading h2 {
    font-size: 36px;
  }
  body .jj-section-heading .jj-section-kicker {
    letter-spacing: 0.25em;
  }
}

/* Section links match “Read John's full story” and “See the full plan”. */
body .jj-home-news-link,
body .jj-home-ads-link {
  font-family: Montserrat, Arial, sans-serif;
  font-size: 14px;
  font-weight: 900;
  line-height: 20px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #c41230;
  gap: 6px;
  text-decoration: none;
}
body .jj-home-news-link span,
body .jj-home-ads-link span {
  font-size: inherit;
  line-height: inherit;
}
body .jj-home-news-link:hover,
body .jj-home-ads-link:hover {
  color: #0a2240;
  text-decoration: none;
}

.jj-news-archive-grid { margin-top: 32px; }
.jj-news-archive { scroll-margin-top: 100px; }
.jj-war-room { padding: 72px 24px; background: white; scroll-margin-top: 100px; }
.jj-war-room-inner { max-width: 1280px; margin: 0 auto; }
.jj-war-room-panel { margin-top: 32px; padding: 28px; background: #f8fafc; border: 1px solid #e2e7ed; max-width: 760px; }
.jj-war-room-panel > p { color: #526176; line-height: 1.6; }
.jj-war-room-panel a { color: #c41230; text-decoration: underline; }
.jj-news-archive .jj-news-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}
.jj-news-archive .jj-news-filters a {
  display: inline-block;
  padding: 11px 18px;
  border: 1px solid #dce3eb;
  color: #0a2240;
  font: 800 12px/1.5 Montserrat, Arial, sans-serif;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.jj-news-archive .jj-news-filters a[aria-current],
.jj-news-archive .jj-news-filters a:hover {
  background: #0a2240;
  border-color: #0a2240;
  color: #fff;
}
.jj-news-archive .jj-news-filters a:focus-visible { outline: 3px solid #c41230; outline-offset: 3px; }

/* Cached X posts, styled consistently with the news cards. */
.jj-x-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: start;
  gap: 24px;
  margin-top: 32px;
}
.jj-x-card {
  min-width: 0;
  padding: 26px;
  border: 1px solid #e2e7ed;
  border-radius: 5px;
  background: #fff;
  color: #0a2240;
}
.jj-x-card-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}
.jj-x-card-header a { color: #0a2240; overflow-wrap: anywhere; }
.jj-x-card-header strong { display: block; font-weight: 800; }
.jj-x-card-header a span, .jj-x-date { color: #526176; font-size: 14px; }
.jj-x-mark { font-size: 26px; line-height: 1; }
.jj-x-date { display: inline-block; margin-top: 8px; }
.jj-x-text {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  margin: 20px 0;
  font-size: 17px;
  line-height: 1.65;
}
.jj-x-media { display: block; margin-bottom: 20px; }
.jj-x-media img { width: 100%; height: auto; border-radius: 3px; }
.jj-x-source, .jj-x-profile { display: inline-flex; align-items: center; }
.jj-x-profile { margin-top: 28px; }
.jj-x-card a:focus-visible, .jj-x-profile:focus-visible {
  outline: 3px solid #c41230;
  outline-offset: 4px;
}
/* Ticker tape: posts scroll continuously; pauses on hover/focus; static horizontal scroll when motion is reduced. */
.jj-x-ticker {
  position: relative;
  margin-top: 32px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent);
}
.jj-x-ticker-track {
  display: flex;
  width: max-content;
  animation: jj-x-ticker calc(var(--jj-ticker-count, 6) * 7s) linear infinite;
  will-change: transform;
}
.jj-x-ticker:hover .jj-x-ticker-track,
.jj-x-ticker:focus-within .jj-x-ticker-track { animation-play-state: paused; }
.jj-x-ticker .jj-x-grid {
  display: flex;
  flex: none;
  align-items: stretch;
  gap: 24px;
  margin: 0;
  padding-right: 24px;
}
.jj-x-ticker .jj-x-card {
  display: flex;
  flex-direction: column;
  width: 360px;
  flex: none;
}
.jj-x-ticker .jj-x-text {
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
  overflow: hidden;
  white-space: normal;
  flex: 1 1 auto;
}
.jj-x-ticker .jj-x-media { max-height: 200px; overflow: hidden; }
.jj-x-ticker .jj-x-media img { height: 200px; object-fit: cover; }
.jj-x-card-featured { border-color: #c41230; box-shadow: inset 0 3px 0 #c41230; }
@keyframes jj-x-ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .jj-x-ticker { overflow-x: auto; -webkit-mask-image: none; mask-image: none; scroll-snap-type: x proximity; }
  .jj-x-ticker-track { animation: none; }
  .jj-x-ticker .jj-x-grid[aria-hidden="true"] { display: none; }
  .jj-x-ticker .jj-x-card { scroll-snap-align: start; }
}
@media (max-width: 1023px) {
  .jj-x-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .jj-x-grid { grid-template-columns: minmax(0, 1fr); }
  .jj-x-card { padding: 22px; }
  .jj-x-ticker .jj-x-card { width: 300px; }
  .jj-x-ticker .jj-x-grid { gap: 16px; padding-right: 16px; }
}
