/* ═══════════════════════════════════════════════════════════
   JAGGI NEWS WIDGETS  v9.0
   Styles for [jaggi_latest_news] and [jaggi_news_ticker]
   All rules scoped to avoid theme conflicts
   ═══════════════════════════════════════════════════════════ */

/* ══════════════════════════════════════════════════════════════
   [jaggi_latest_news] — 3-column latest news cards
   ══════════════════════════════════════════════════════════════ */
.jn-latest-wrap {
  width: 100%;
  font-family: ui-sans-serif, system-ui, sans-serif;
  margin: 0;
  padding: 0;
}

.jn-latest-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid #e4e4e4;
  flex-wrap: wrap;
  gap: 8px;
}

.jn-latest-heading {
  font-size: 22px !important;
  font-weight: 700 !important;
  color: #111111 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: none !important;
  background: none !important;
  font-family: ui-sans-serif, system-ui, sans-serif !important;
}

.jn-latest-view-all {
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #E0370E !important;
  text-decoration: none !important;
  border: none !important;
  box-shadow: none !important;
  transition: color .15s !important;
}
.jn-latest-view-all:hover {
  color: #b82d08 !important;
  text-decoration: none !important;
}

/* Grid: 3 col desktop → 2 col tablet → 1 col mobile */
.jn-latest-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  align-items: stretch;
}

/* Card */
.jn-latest-card {
  background: #ffffff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 8px rgba(0,0,0,.08);
  transition: transform .22s ease, box-shadow .22s ease;
  display: flex;
  flex-direction: column;
  border: none;
  height: 100%;
}
.jn-latest-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 28px rgba(0,0,0,.13);
}

.jn-latest-card-link {
  display: flex;
  flex-direction: column;
  flex: 1;
  text-decoration: none !important;
  color: inherit !important;
  border: none !important;
  box-shadow: none !important;
}

/* Card image */
.jn-latest-img {
  position: relative;
  padding-top: 56%;
  overflow: hidden;
  background: #e0dbd4;
  flex-shrink: 0;
}
.jn-latest-img img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .35s ease;
  border: none !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  max-width: none !important;
}
.jn-latest-card:hover .jn-latest-img img {
  transform: scale(1.05);
}
.jn-latest-img-placeholder {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #e8e0d8 0%, #d8cfc5 100%);
}

/* Country badge */
.jn-latest-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #E0370E;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: .4px;
  line-height: 1.5;
  font-family: ui-sans-serif, system-ui, sans-serif;
}

/* Card body */
.jn-latest-body {
  padding: 14px 16px 12px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.jn-latest-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: #888888;
  margin-bottom: 8px;
  font-family: ui-sans-serif, system-ui, sans-serif;
}
.jn-latest-dot { color: #cccccc; }

.jn-latest-title {
  font-size: 14.5px !important;
  font-weight: 700 !important;
  line-height: 1.42 !important;
  color: #111111 !important;
  margin: 0 0 8px !important;
  padding: 0 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 3 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  border: none !important;
  background: none !important;
  transition: color .18s !important;
  font-family: ui-sans-serif, system-ui, sans-serif !important;
}
.jn-latest-card:hover .jn-latest-title {
  color: #E0370E !important;
}

.jn-latest-excerpt {
  font-size: 13px !important;
  color: #444444 !important;
  line-height: 1.5 !important;
  margin: 0 0 12px !important;
  padding: 0 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  font-family: ui-sans-serif, system-ui, sans-serif !important;
	font-weight:400 !important;
}

.jn-latest-read-more {
  font-size: 13px;
  font-weight: 600;
  color: #E0370E;
  margin-top: auto;
  display: inline-block;
  transition: letter-spacing .18s;
}
.jn-latest-card:hover .jn-latest-read-more {
  letter-spacing: .3px;
}

/* WhatsApp button at card bottom */
.jn-latest-wa {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: #f6fef9;
  color: #1a8f47 !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  padding: 10px 16px !important;
  border-top: 1px solid #e6f4ec !important;
  text-decoration: none !important;
  transition: background .15s !important;
  border-radius: 0 0 10px 10px !important;
  box-shadow: none !important;
  font-family: ui-sans-serif, system-ui, sans-serif !important;
}
.jn-latest-wa:hover {
  background: #e8f8ee !important;
  color: #1a8f47 !important;
  text-decoration: none !important;
}

/* Responsive */
@media (max-width: 900px) {
  .jn-latest-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 560px) {
  .jn-latest-grid {
    grid-template-columns: 1fr;
  }
  .jn-latest-heading {
    font-size: 18px !important;
  }
}


/* ══════════════════════════════════════════════════════════════
   [jaggi_news_ticker] — scrolling headline ticker
   ══════════════════════════════════════════════════════════════ */
.jn-ticker-wrap {
  display: flex;
  align-items: stretch;
  background: #E0370E;
  border-radius: 0px;
  overflow: hidden;
  width: 100%;
  font-family: ui-sans-serif, system-ui, sans-serif;
  min-height: 42px;
  position: relative;
}

/* "Latest News" label on the left */
.jn-ticker-label {
  display: flex;
  align-items: center;
  gap: 7px;
  background: #b82d08;
  color: #ffffff;
  font-size: 12.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .6px;
  padding: 0 16px;
  white-space: nowrap;
  flex-shrink: 0;
  z-index: 2;
}

/* Blinking red dot inside label */
.jn-ticker-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ffffff;
  flex-shrink: 0;
  animation: jn-ticker-blink 1.2s ease-in-out infinite;
}
@keyframes jn-ticker-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: .25; }
}

/* Scrolling track container */
.jn-ticker-track-wrap {
  flex: 1;
  overflow: hidden;
  display: flex;
  align-items: center;
  /* fade edges */
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 3%, black 97%, transparent 100%);
  mask-image: linear-gradient(to right, transparent 0%, black 3%, black 97%, transparent 100%);
}

/* The scrolling row — duplicated for seamless loop */
.jn-ticker-track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  animation: jn-ticker-scroll linear infinite;
  /* duration set inline via shortcode speed attribute */
  will-change: transform;
}
@keyframes jn-ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); } /* -50% because content is duplicated */
}

/* Individual ticker item */
.jn-ticker-item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 0 8px;
}

.jn-ticker-badge {
  background: rgba(255,255,255,.22);
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 50px;
  text-transform: uppercase;
  letter-spacing: .4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.jn-ticker-link {
  color: #ffffff !important;
  font-size: 13.5px !important;
  font-weight: 500 !important;
  text-decoration: none !important;
  border: none !important;
  box-shadow: none !important;
  white-space: nowrap;
  transition: opacity .15s;
}
.jn-ticker-link:hover {
  opacity: .8 !important;
  text-decoration: underline !important;
  color: #ffffff !important;
}

.jn-ticker-sep {
  color: rgba(255,255,255,.4);
  font-size: 14px;
  flex-shrink: 0;
}

/* Pause button on the right */
.jn-ticker-pause {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,.15);
  border: none;
  color: #ffffff;
  width: 38px;
  flex-shrink: 0;
  cursor: pointer;
  transition: background .15s;
  padding: 0;
  border-radius: 0;
  outline: none;
}
.jn-ticker-pause:hover {
  background: rgba(0,0,0,.3);
}
.jn-ticker-pause:focus-visible {
  outline: 2px solid rgba(255,255,255,.8);
  outline-offset: -2px;
}

/* Mobile: smaller label, slightly smaller text */
@media (max-width: 560px) {
  .jn-ticker-label {
    padding: 0 10px;
    font-size: 11px;
    letter-spacing: .3px;
  }
  .jn-ticker-link {
    font-size: 13px !important;
  }
}
