/* News (Blog) page — pixel-perfect port from TS (scoped). */

/* Safety: never show the mobile categories bar above 768px (prevents regressions on blog templates). */
@media (min-width: 768px) {
  [data-fp-cat-mobile] { display: none !important; }
}

.fp-news {
  padding: 3rem 0 4rem;
}

.fp-news .fp-news__container {
  max-width: 80rem; /* 5xl */
  margin: 0 auto;
  padding: 0 1rem;
}

.fp-news__header {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

@media (min-width: 768px) {
  .fp-news__header { flex-direction: row; align-items: flex-start; justify-content: space-between; }
}

.fp-news__title {
  font-size: 2.25rem;
  line-height: 1.1;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.fp-news__subtitle {
  margin-top: 0.5rem;
  font-size: 1.125rem;
  line-height: 1.55;
  color: #4b5563;
  max-width: 42rem;
}

.fp-news__search {
  position: relative;
  width: 100%;
  max-width: 22rem;
}

.fp-news__search input {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.5rem;
  border: 1px solid #d1d5db;
  border-radius: 0.75rem;
  background: #f9fafb;
  outline: none;
}

.fp-news__search input:focus {
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.18);
  border-color: #ef4444;
}

.fp-news__search .fp-news__searchicon {
  position: absolute;
  left: 0.75rem;
  top: 50%;
  transform: translateY(-50%);
  width: 1.25rem;
  height: 1.25rem;
  opacity: 0.6;
}

.fp-news__tabs {
  display: flex;
  gap: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 2rem;
}

.fp-news__tab {
  border: none;
  background: transparent;
  padding: 0.75rem 0;
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #6b7280;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}

.fp-news__tab.is-active {
  color: #111827;
  border-bottom-color: #ef4444;
}

.fp-news__meta {
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 1rem;
}

.fp-news__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .fp-news__grid { grid-template-columns: 2fr 1fr; }
}

.fp-news__cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 768px) {
  .fp-news__cards { grid-template-columns: 1fr 1fr; }
}

.fp-news-card {
  background: #fff;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 10px 24px rgba(0,0,0,0.12);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.fp-news-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(0,0,0,0.14);
}

.fp-news-card__img {
  position: relative;
  display: block;
  width: 100%;
  /* Fixed rectangular media area (Amazon-style), independent of image source */
  aspect-ratio: 16 / 9;
  height: auto;
  background: #f3f4f6;
  overflow: hidden;
  border-top-left-radius: 1.25rem;
  border-top-right-radius: 1.25rem;
}

.fp-news-card__img img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fp-badge {
  position: absolute;
  left: 1rem;
  top: 1rem;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  border-radius: 999px;
  color: #fff;
}

.fp-badge--event { background: #ef4444; }
.fp-badge--cert { background: #2563eb; }
.fp-badge--news { background: #6b7280; }

.fp-news-card__body { padding: 1.5rem; }

.fp-news-card__date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #6b7280;
}

.fp-news-card__title {
  margin-top: 0.5rem;
  font-size: 1rem;
  font-weight: 700;
  color: #111827;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.fp-news-card__excerpt {
  margin-top: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.6;
  color: #4b5563;
}

.fp-news-card__more {
  margin-top: 1rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  color: #ef4444;
  letter-spacing: 0.06em;
}

.fp-news-card__more svg { width: 1rem; height: 1rem; }

.fp-news__sidebar {
  position: sticky;
  top: 6rem;
  align-self: start;
}

.fp-catalog {
  border-radius: 1rem;
  padding: 2rem;
  color: #fff;
  background: linear-gradient(135deg, #b91c1c 0%, #ef4444 100%);
}

.fp-catalog__title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.fp-catalog__text { margin-top: 0.5rem; opacity: 0.92; }

.fp-catalog__btn {
  margin-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  background: #fff;
  color: #b91c1c;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.fp-news__pager {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.fp-news__pager button {
  border: 1px solid #e5e7eb;
  background: #fff;
  padding: 0.5rem 0.75rem;
  border-radius: 0.75rem;
  cursor: pointer;
}

.fp-news__pager button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}


/* --- Pixel perfect tweaks (TS parity) --- */
.fp-news a { text-decoration: none; }
.fp-news-card__title{
  color:#d11a22;
  text-transform: uppercase;
  letter-spacing: .04em;
  font-weight: 800;
  font-size: 13px;
  line-height: 1.25;
}
.fp-news-card__title:hover{ color:#b5141b; }
.fp-news-card__excerpt{
  color:#4b5563;
  font-size: 14px;
  line-height: 1.6;
}
.fp-news-card__more{
  color:#d11a22;
  font-weight:700;
  letter-spacing:.02em;
}
.fp-news-card__more:hover{ color:#b5141b; }
.fp-news-card{
  border-radius: 16px;
  box-shadow: 0 10px 22px rgba(0,0,0,.08);
}
.fp-news-card__media{
  border-top-left-radius:16px;
  border-top-right-radius:16px;
}
.fp-news-card__media img{ height: 210px; object-fit: cover; }
.fp-news-card__badge{
  border-radius: 10px;
  padding: 6px 10px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.fp-catalog-card{
  border-radius: 18px;
  box-shadow: 0 18px 32px rgba(0,0,0,.14);
}

.fp-news-card__img--empty{width:100%;height:100%;background:#f3f4f6;}


/* Used when a post has no featured image */
.fp-news-card__placeholder{width:100%;height:100%;background:linear-gradient(135deg,#f1f5f9,#ffffff);}


/* v0.4.23.121 News page 3-column layout */
.fp-news__grid {
  display:block;
}

.fp-news__cards.fp-news__cards--three {
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.75rem;
  align-items: stretch;
}

.fp-news__sidebar,
.fp-catalog,
.fp-catalog-card {
  display:none !important;
}

.fp-news-card {
  height: 100%;
}

@media (max-width: 1100px) {
  .fp-news__cards.fp-news__cards--three {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 767px) {
  .fp-news__cards.fp-news__cards--three {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
}


/* v0.4.23.181 Blog search CTA + rounded body media */
.fp-news__header {
  align-items: stretch;
}

.fp-news__search {
  max-width: none;
  flex: 1 1 auto;
}

.fp-news__cta {
  width: 100%;
  max-width: 22rem;
}

.fp-news__newsletter-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 3rem;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  background: linear-gradient(180deg, #db2b33 0%, #9f1e22 100%);
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  text-decoration: none;
  box-shadow: inset 0 2px 0 rgba(255,255,255,.18), 0 8px 18px rgba(0,0,0,.18);
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
}

.fp-news__newsletter-btn:hover {
  color: #fff;
  filter: brightness(1.04);
  transform: translateY(-1px);
  box-shadow: inset 0 2px 0 rgba(255,255,255,.18), 0 10px 20px rgba(0,0,0,.2);
}

.fp-news__newsletter-btn:active {
  transform: translateY(0);
}

@media (min-width: 768px) {
  .fp-news__header {
    align-items: center;
  }

  .fp-news__cta {
    width: auto;
    flex: 0 0 22rem;
  }
}

@media (max-width: 767px) {
  .fp-news__cta {
    max-width: none;
  }
}

.fp-article-body img,
.fp-article-body .wp-caption,
.fp-article-body figure,
.fp-post-single-nohero .entry-content img,
.fp-post-single-nohero .entry-content .wp-caption,
.fp-post-single-nohero .entry-content figure {
  border-radius: 22px;
  overflow: hidden;
}

.fp-article-body img,
.fp-post-single-nohero .entry-content img {
  display: block;
  max-width: 100%;
  height: auto;
}

.fp-article-body p img,
.fp-post-single-nohero .entry-content p img {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}
