/* News listing page + shared news components */

#news.news-section {
  background: #eef2f5;
  padding: 48px 0 88px;
}

.news-page-title {
  font-size: clamp(32px, 4vw, 44px);
  font-weight: 800;
  color: #1a1a1a;
  margin: 0;
  letter-spacing: -0.02em;
}

.news-breadcrumb {
  font-size: 13px;
  color: #6b8a94;
  margin-bottom: 12px;
}

.news-breadcrumb a {
  color: #023a49;
  text-decoration: none;
}

.news-breadcrumb a:hover { text-decoration: underline; }

.news-section-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.news-all-link {
  font-size: 13px;
  font-weight: 600;
  color: #023a49;
  text-decoration: none;
  border-bottom: 1px solid rgba(2,58,73,0.3);
  padding-bottom: 2px;
  white-space: nowrap;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 28px 24px;
}

.news-grid--home { grid-template-columns: repeat(3, 1fr); }

.news-card {
  display: flex;
  flex-direction: column;
  background: transparent;
  border: none;
  padding: 0;
  text-align: left;
  cursor: pointer;
  font-family: inherit;
  width: 100%;
  transition: transform 0.2s ease;
}

.news-card:hover { transform: translateY(-3px); }

.news-card-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #dce4ea;
  margin-bottom: 14px;
}

.news-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.news-card:hover .news-card-media img { transform: scale(1.03); }

.news-card-date {
  font-size: 13px;
  color: #8a96a0;
  margin-bottom: 10px;
  line-height: 1.3;
}

.news-card-title {
  font-size: 13px;
  font-weight: 800;
  color: #023a49;
  line-height: 1.45;
  margin: 0 0 12px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.news-card-source {
  font-size: 12px;
  color: #9aa5ad;
  line-height: 1.4;
  margin-top: auto;
}

.news-empty { color: #888; font-size: 14px; margin: 0; }

.news-detail-modal {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 24px 16px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s, visibility 0.25s;
}

.news-detail-modal.is-open { opacity: 1; visibility: visible; }

.news-detail-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 30, 42, 0.72);
  backdrop-filter: blur(4px);
}

.news-detail-panel {
  position: relative;
  z-index: 1;
  width: min(1100px, 100%);
  margin: 24px auto 48px;
  background: #fff;
  box-shadow: 0 24px 80px rgba(2, 58, 73, 0.28);
  overflow: hidden;
}

.news-detail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 24px 0;
}

.news-detail-back {
  font-size: 13px;
  font-weight: 600;
  color: #023a49;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 8px 0;
}

.news-detail-close {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: #eef2f5;
  color: #023a49;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  flex-shrink: 0;
}

.news-detail-hero {
  position: relative;
  min-height: 200px;
  background: #e8f0f3;
  cursor: zoom-in;
}

.news-detail-hero img,
.news-detail-hero video {
  width: 100%;
  max-height: 520px;
  object-fit: contain;
  display: block;
  background: #111;
}

.news-detail-hero-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  color: #023a49;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.news-detail-hero-nav.prev { left: 16px; }
.news-detail-hero-nav.next { right: 16px; }
.news-detail-hero-nav[hidden] { display: none !important; }

.news-detail-content { padding: 28px 40px 32px; }

.news-detail-date {
  display: block;
  font-size: 14px;
  color: #8a96a0;
  margin-bottom: 16px;
}

.news-detail-title {
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 800;
  color: #023a49;
  line-height: 1.35;
  margin: 0 0 24px;
  text-transform: uppercase;
}

.news-detail-body {
  font-size: 16px;
  line-height: 1.8;
  color: #334;
}

.news-detail-body p { margin: 0 0 16px; }

.news-detail-source {
  margin-top: 28px;
  font-size: 13px;
  color: #9aa5ad;
}

.news-detail-more {
  padding: 36px 40px 44px;
  background: #eef2f5;
  border-top: 1px solid rgba(2,58,73,0.08);
}

.news-detail-more h3 {
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 800;
  color: #1a1a1a;
  margin: 0 0 28px;
}

.news-detail-more-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

body.news-detail-open,
body.news-lightbox-open { overflow: hidden; }

.news-lightbox {
  position: fixed;
  inset: 0;
  z-index: 13000;
  background: rgba(0,0,0,0.88);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 64px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s, visibility 0.2s;
}

.news-lightbox.is-open { opacity: 1; visibility: visible; }

.news-lightbox img {
  max-width: 100%;
  max-height: calc(100vh - 96px);
  object-fit: contain;
}

.news-lightbox-close {
  position: absolute;
  top: 16px;
  right: 20px;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  color: #fff;
  font-size: 28px;
  cursor: pointer;
}

.news-lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  color: #fff;
  font-size: 32px;
  cursor: pointer;
}

.news-lightbox-nav.prev { left: 20px; }
.news-lightbox-nav.next { right: 20px; }
.news-lightbox-nav[hidden] { display: none !important; }

@media (max-width: 1500px) {
  .news-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 1024px) {
  #news .news-grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .news-detail-more-grid { grid-template-columns: repeat(2, 1fr); }
  .news-detail-content, .news-detail-more { padding-left: 24px; padding-right: 24px; }
}

@media (max-width: 640px) {
  .news-grid, .news-grid--home { grid-template-columns: 1fr; }
  .news-detail-more-grid { grid-template-columns: 1fr; }
}
