/* News module styles (cleaner + more engaging) */

:root {
  --news-surface: rgba(255, 255, 255, 0.04);
  --news-surface-2: rgba(255, 255, 255, 0.06);
  --news-border: rgba(255, 255, 255, 0.10);
  --news-text: rgba(255, 255, 255, 0.92);
  --news-muted: rgba(255, 255, 255, 0.70);

  --news-btn-bg: linear-gradient(135deg, #0270EB, #7D34DD);
  --news-btn-border: #0270EB;
  --news-btn-text: rgba(255, 255, 255, 0.94);
  --news-btn-secondary-bg: rgba(0, 0, 0, 0.18);
  --news-btn-secondary-border: rgba(255, 255, 255, 0.12);
}

/* Font polish (only for News pages) */
.news-page,
.news-post-page {
  font-family: 'Plus Jakarta Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Mobile header can be taller (nav wraps). Reserve space so content never hides under it. */
@media (max-width: 900px) {
  .news-page { padding-top: 180px; }
  .news-post-page { padding-top: 180px; }
}

@media (max-width: 480px) {
  .news-page { padding-top: 200px; }
  .news-post-page { padding-top: 200px; }
}

.news-page .news-container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 28px 16px;
}

.news-post-page .news-container {
  max-width: 1120px;
  
  /* Desktop: offset content below fixed header using container margin */
  margin: 6rem auto 0;
  
  padding: 28px 16px;
}

/* Mobile: body padding-top handles the header; don't double-offset with margin. */
@media (max-width: 768px) {
  .news-page .news-container,
  .news-post-page .news-container {
    margin-top: 0;
  }
}

.news-hero {
  width: 100%;
  margin: 4rem 0 0 0;
  padding: 3rem 0;
  background: var(--news-surface);
}

.news-hero-wrapper {
  max-width: 1280px;
  margin: 2rem auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 0.5fr 0.5fr;
  gap: 2.5rem;
  align-items: center;
}

.news-hero-content {
  position: relative;
  z-index: 1;
}

.news-hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.34rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(129, 140, 248, 0.8);
  background: linear-gradient(135deg, #0270EB, #7D34DD);
  color: rgba(191, 219, 254, 0.95);
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
}

.news-hero-pill-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.8);
  animation: news-pill-ping 1.8s infinite;
  flex-shrink: 0;
}

@keyframes news-pill-ping {
  0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.8); }
  50%       { box-shadow: 0 0 0 6px rgba(34, 197, 94, 0); }
}

.news-hero-content h1 {
  margin: 0;
  margin-top: 1.5rem;
  font-size: clamp(2.4rem, 3.8vw, 3.2rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--text-primary);
}

.news-hero-content p {
  margin: 1.2rem 0 0;
  color: rgba(255, 255, 255, 0.7);
  max-width: 100%;
  font-size: 1.05rem;
  line-height: 1.7;
}

/* CTA buttons */
.news-hero-ctas {
  margin-top: 1.6rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.news-hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 1.6rem;
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
}

.news-hero-cta-primary {
  background: linear-gradient(135deg, #0270EB, #7D34DD);
  color: #ffffff;
  box-shadow: 0 14px 40px rgba(2, 112, 235, 0.25);
}

.news-hero-cta-primary:hover {
  color: #ffffff;
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 20px 50px rgba(2, 112, 235, 0.35);
  filter: brightness(1.08);
}

.news-hero-cta-secondary {
  background: rgba(2, 112, 235, 0.08);
  border-color: rgba(2, 112, 235, 0.5);
  color: rgba(191, 219, 254, 0.95);
}

.news-hero-cta-secondary:hover {
  background: rgba(2, 112, 235, 0.15);
  border-color: rgba(129, 140, 248, 0.8);
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 18px 40px rgba(2, 112, 235, 0.15);
  color: rgba(191, 219, 254, 0.95);
}

/* Decorative preview grid */
.news-hero-visual {
  position: relative;
}

.news-hero-grid-mock {
  width: 100%;
  aspect-ratio: 4 / 3;
  border-radius: 20px;
  border: 1px solid rgba(2, 112, 235, 0.2);
  background:
    radial-gradient(circle at top left, rgba(2, 112, 235, 0.12), transparent 55%),
    radial-gradient(circle at bottom right, rgba(125, 52, 221, 0.1), transparent 60%),
    rgba(10, 14, 19, 0.95);
  padding: 1.4rem;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
  gap: 1rem;
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.5);
}

.news-hero-card {
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 1.2rem 0.8rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-hero-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(2, 112, 235, 0.15);
}

.news-hero-card--1 {
  background: linear-gradient(135deg, rgba(2, 112, 235, 0.18), rgba(59, 130, 246, 0.08));
}
.news-hero-card--2 {
  background: linear-gradient(135deg, rgba(125, 52, 221, 0.18), rgba(167, 139, 250, 0.08));
}
.news-hero-card--3 {
  background: linear-gradient(135deg, rgba(6, 182, 212, 0.18), rgba(34, 211, 238, 0.08));
}
.news-hero-card--4 {
  background: linear-gradient(135deg, rgba(244, 63, 94, 0.15), rgba(251, 146, 60, 0.08));
}

.news-hero-card-icon {
  font-size: 2rem;
  line-height: 1;
  animation: news-icon-float 3s ease-in-out infinite;
}

.news-hero-card--2 .news-hero-card-icon { animation-delay: 0.5s; }
.news-hero-card--3 .news-hero-card-icon { animation-delay: 1s; }
.news-hero-card--4 .news-hero-card-icon { animation-delay: 1.5s; }

@keyframes news-icon-float {
  0%, 100% { transform: translateY(0) scale(1); }
  50%      { transform: translateY(-4px) scale(1.1); }
}

.news-hero-card-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.85);
  text-align: center;
}

/* Hero responsive */
@media (max-width: 900px) {
  .news-hero {
    padding: 0;
    margin: 0;
    margin-bottom: 1.5rem;
  }

  .news-hero-wrapper {
    grid-template-columns: 1fr;
    gap: 0;
    padding: 0;
    margin: 0;
  }

  .news-hero-content {
    order: 2;
    padding: 2rem 1.75rem;
  }

  .news-hero-visual {
    order: 1;
  }

  .news-hero-grid-mock {
    border-radius: 0;
    border: none;
    box-shadow: none;
    aspect-ratio: auto;
  }
}

@media (max-width: 768px) {
  .news-hero-content h1 {
    font-size: clamp(2rem, 5vw, 2.5rem);
    margin-top: 1rem;
  }

  .news-hero-content p {
    font-size: 0.95rem;
    margin-top: 1rem;
  }

  .news-hero-content {
    padding: 1.75rem 1.25rem;
  }

  .news-hero-card-icon {
    font-size: 1.6rem;
  }

  .news-hero-card-label {
    font-size: 0.72rem;
  }
}


.news-search {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 18px 0 22px;
}

.news-search input {
  width: 100%;
  max-width: 620px;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(0,0,0,0.18);
  color: var(--news-text);
  font-size: 14px;
}

.news-search input::placeholder {
  color: rgba(255,255,255,0.55);
}

.news-search button {
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--news-btn-border);
  background: var(--news-btn-bg);
  color: var(--news-btn-text);
  cursor: pointer;
  font-weight: 700;
}

.news-search button:hover {
  filter: brightness(1.08);
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
}

.news-card {
  grid-column: span 6;
  border: 1px solid var(--news-border);
  border-radius: 20px;
  background: var(--news-surface);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.18);
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, box-shadow 0.18s ease;
}

.news-card:hover {
  transform: translateY(-3px);
  border-color: rgba(0, 212, 255, 0.28);
  background: var(--news-surface-2);
  box-shadow: 0 14px 34px rgba(0,0,0,0.26);
}

.news-card-media {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: rgba(0,0,0,0.20);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

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

.news-card-body {
  padding: 14px 16px 16px;
}

.news-card-title {
  margin: 0 0 8px 0;
  font-size: 18px;
  line-height: 1.25;
  letter-spacing: -0.015em;
}

.news-card-title a {
  color: var(--news-text);
}

.news-card .meta {
  font-size: 12.5px;
  color: rgba(255,255,255,0.68);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.news-card-author {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #ffffff;
  text-decoration: none;
}

.news-author-avatar {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  object-fit: cover;
}

.news-author-name {
  font-size: 12.5px;
  color: #ffffff;
  opacity: 0.95;
}

.news-card-date {
  font-size: 12px;
  opacity: 0.75;
}

.news-card .excerpt {
  margin: 0 0 12px 0;
  color: rgba(255,255,255,0.78);
  font-size: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.news-card a.read-more {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #0270EB, #7D34DD);
  text-decoration: none;
  color: #ffffff;
  font-weight: 700;
}

.news-card a.read-more:hover {
  filter: brightness(1.08);
}

@media (max-width: 900px) {
  .news-card { grid-column: span 12; }
}

@media (max-width: 480px) {
  .news-post-header h1 {
    font-size: 30px;
    line-height: 1.18;
    letter-spacing: -0.02em;
  }
}

.news-pagination {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 22px;
}

.news-pagination a {
  padding: 10px 14px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #0270EB, #7D34DD);
  text-decoration: none;
  color: #ffffff;
  font-weight: 700;
}

.news-pagination a:hover {
  filter: brightness(1.08);
}

/* News post */

.news-post-header {
  margin-bottom: 14px;
}

.news-post-header h1 {
  margin: 0;

  /* Modern responsive type scale */
  font-size: clamp(28px, 4.2vw, 36px);
  line-height: 1.12;
  letter-spacing: -0.03em;
}

.news-post-meta {
  margin-top: 10px;
  color: rgba(255,255,255,0.70);
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.news-post-author {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.news-post-date {
  margin-right: 4px;
}

.news-share {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.news-share-label {
  font-size: 12px;
  opacity: 0.85;
}

.news-share-icons {
  display: inline-flex;
  gap: 6px;
}

.news-share-icon {
  width: 32px;
  height: 32px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  color: #ffffff;
  box-shadow: 0 0 0 1px rgba(255,255,255,0.18), 0 6px 14px rgba(0,0,0,0.45);
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.news-share-svg {
  width: 18px;
  height: 18px;
}

/* Brand-like colors for each social platform */
.news-share-icon-x {
  background: #000000;
}

.news-share-icon-facebook {
  background: #1877F2;
}

.news-share-icon-whatsapp {
  background: #25D366;
}

.news-share-icon-linkedin {
  background: #0077B5;
}

.news-share-icon-email {
  background: linear-gradient(135deg, #0270EB, #7D34DD);
}

.news-share-icon-telegram {
  background: #0EA5E9;
}

.news-share-icon:hover {
  filter: brightness(1.06);
  transform: translateY(-1px) scale(1.07);
  box-shadow: 0 0 0 1px rgba(255,255,255,0.26), 0 8px 18px rgba(0,0,0,0.55);
}

.news-share-svg {
  width: 16px;
  height: 16px;
}

.news-post-page .hero-breadcrumb {
  margin-bottom: 16px;
}

.hero-breadcrumb a {
  color: #0270EB;
}

.news-post-featured {
  margin: 16px 0 18px;
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(0,0,0,0.22);
  box-shadow: 0 14px 40px rgba(0,0,0,0.25);
}

.news-post-featured img {
  width: 100%;
  height: auto;
  display: block;
}

.news-post-content {
  margin-top: 14px;
  line-height: 1.8;
  color: rgba(255,255,255,0.80);
  font-size: 16px;
}

.news-post-content p {
  color: inherit;
}

.news-post-content h2,
.news-post-content h3 {
  margin-top: 22px;
}

.news-post-nav {
  margin-top: 26px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.news-nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--news-btn-secondary-border);
  background: var(--news-btn-secondary-bg);
  text-decoration: none;
  color: rgba(255,255,255,0.88);
  font-weight: 600;
}

.news-nav-link:hover {
  border-color: var(--news-btn-border);
}

.news-nav-link-primary {
  border: none;
  background: linear-gradient(135deg, #0270EB, #7D34DD);
  color: #ffffff;
  font-weight: 700;
}

.news-nav-link-primary:hover {
  filter: brightness(1.08);
}

.news-nav-link-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}
