/* News archive and detail pages — fixed editorial system for the AGAT prototype. */
.home-news {
  position: relative;
  overflow: hidden;
  padding: 76px 0 84px;
  border-top: 1px solid var(--premium-line, #dce4e2);
  border-bottom: 1px solid var(--premium-line, #dce4e2);
  background: #f2f6f4;
}
.home-news::after {
  content: "";
  position: absolute;
  top: -160px;
  right: -180px;
  width: 420px;
  height: 420px;
  border: 1px solid rgba(60, 180, 200, .12);
  border-radius: 50%;
  box-shadow: 0 0 0 40px rgba(255, 255, 255, .2), 0 0 0 82px rgba(60, 180, 200, .025);
}
.home-news > .shell { position: relative; z-index: 1; }
.home-news .section-heading { align-items: end; }
.home-news__note {
  max-width: 760px;
  margin: -10px 0 30px;
  color: #53686c;
  font-size: 12px;
  line-height: 1.65;
}
.home-news__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-rows: 1fr;
  align-items: stretch;
  gap: 18px;
}
.home-news__secondary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.news-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--inner-line, #dce4e2);
  border-radius: 2px 18px 2px 2px;
  background: #fff;
  color: var(--inner-ink, #18373d);
  text-decoration: none;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.news-card:hover {
  border-color: rgba(45, 96, 104, .42);
  box-shadow: 0 18px 44px rgba(24, 55, 61, .08);
  transform: translateY(-2px);
}
.news-card:focus-visible { outline: 3px solid var(--home-orange, #fe1f15); outline-offset: 3px; }
.news-card__media {
  position: relative;
  display: block;
  overflow: hidden;
  background: #dfeae7;
}
.news-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(255, 255, 255, .16);
  pointer-events: none;
}
.news-card__media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .45s ease;
}
.news-card:hover .news-card__media img { transform: scale(1.025); }
.home-news .news-card__media--banner {
  min-height: 0;
  aspect-ratio: auto;
  background: #f2f6f4;
}
.home-news .news-card__media--banner img {
  width: 100%;
  height: auto;
  object-fit: contain;
  transform: none;
}
.home-news .news-card__media--fallback { aspect-ratio: 5 / 3; }
.home-news .news-card:hover .news-card__media--banner img { transform: none; }
.news-card__media--fallback {
  background: linear-gradient(145deg, #62c4c9, #2d6068);
}
.news-card__media--fallback i {
  position: absolute;
  width: 0;
  height: 0;
  border-right: 28px solid transparent;
  border-bottom: 48px solid rgba(255, 255, 255, .78);
  border-left: 28px solid transparent;
  transform: rotate(18deg);
}
.news-card__media--fallback i:nth-child(1) { top: 20%; left: 20%; }
.news-card__media--fallback i:nth-child(2) { right: 17%; bottom: 17%; border-bottom-color: var(--premium-orange, #fe1f15); transform: scale(.64) rotate(-12deg); }
.news-card__media--fallback i:nth-child(3) { right: 38%; bottom: 30%; transform: scale(.35) rotate(28deg); }
.news-card__content { display: flex; flex-direction: column; min-width: 0; }
.news-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: #6a7a7d;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.news-card__meta > span:first-child { color: var(--inner-orange, #d5160f); }
.news-card__title {
  display: block;
  margin: 0;
  font-family: "Onest", "Segoe UI", sans-serif;
  font-weight: 440;
  line-height: 1.16;
  letter-spacing: -.025em;
}
.news-card__excerpt {
  display: -webkit-box;
  overflow: hidden;
  color: var(--inner-muted, #5d6e73);
  line-height: 1.55;
  -webkit-box-orient: vertical;
}
.news-card__action {
  display: block;
  margin-top: auto;
  color: var(--inner-teal, #2d6068);
  font-size: 10px;
  font-weight: 680;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.news-card--feature { min-height: 0; display: flex; flex-direction: column; }
.news-card--feature .news-card__media { position: relative; inset: auto; }
.news-card--feature .news-card__media::before { display: none; }
.news-card--feature .news-card__content {
  position: relative;
  z-index: 1;
  flex: 1;
  padding: 30px 32px 28px;
  color: var(--inner-ink, #18373d);
}
.news-card--feature .news-card__meta { justify-content: flex-start; color: var(--inner-muted, #5d6e73); }
.news-card--feature .news-card__meta > span:first-child { color: var(--inner-orange, #d5160f); }
.news-card--feature .news-card__title { max-width: 720px; margin-top: 13px; font-size: clamp(28px, 2.8vw, 40px); }
.news-card--feature .news-card__excerpt { max-width: 680px; margin-top: 14px; color: var(--inner-muted, #5d6e73); font-size: 13px; -webkit-line-clamp: 2; }
.news-card--feature .news-card__action { margin-top: 22px; color: var(--inner-teal, #2d6068); }

.news-card--compact {
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-radius: 2px 12px 2px 2px;
}
.news-card--compact .news-card__media { min-height: 0; }
.news-card--compact .news-card__content { flex: 1; padding: 21px 20px 20px; }
.news-card--compact .news-card__meta { align-items: flex-start; flex-direction: column; gap: 4px; }
.news-card--compact .news-card__title { margin-top: 12px; font-size: 18px; }
.news-card--compact .news-card__excerpt { margin-top: 10px; font-size: 11px; -webkit-line-clamp: 2; }
.news-card--compact .news-card__action { margin-top: 14px; }

.news-card--home {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  border-radius: 2px 14px 2px 2px;
}
.news-card--home-primary::before {
  content: "";
  position: absolute;
  z-index: 3;
  top: 0;
  left: 0;
  width: 84px;
  height: 3px;
  background: linear-gradient(90deg, var(--premium-orange, #fe1f15) 0 34%, var(--premium-cyan, #00b5ca) 34% 100%);
}
.news-card--home .news-card__media { min-height: 0; }
.news-card--home .news-card__content { flex: 1; padding: 22px 20px 21px; }
.news-card--home .news-card__meta { align-items: flex-start; flex-direction: column; gap: 4px; }
.news-card--home .news-card__title { margin-top: 13px; font-size: 20px; }
.news-card--home .news-card__excerpt { margin-top: 10px; font-size: 11px; -webkit-line-clamp: 3; }
.news-card--home .news-card__action { margin-top: 18px; }

/* Archive */
body.inner-page--news .news-intro__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr);
  align-items: end;
  gap: clamp(42px, 7vw, 100px);
}
body.inner-page--news .news-intro__lead {
  max-width: 480px;
  margin: 0 0 7px;
  color: var(--inner-muted);
  font-size: 16px;
  line-height: 1.72;
}
.news-archive { padding: 54px 0 100px; background: #fff; }
.news-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 17px 18px;
  border: 1px solid var(--inner-line);
  border-radius: 2px 14px 2px 2px;
  background: #f8faf9;
}
.news-filters { display: flex; flex-wrap: wrap; gap: 7px; }
.news-filters button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 2px;
  background: transparent;
  color: var(--inner-muted);
  font: inherit;
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .05em;
  text-transform: uppercase;
  cursor: pointer;
}
.news-filters button:hover { border-color: var(--inner-line); color: var(--inner-teal); }
.news-filters button.is-active { border-color: var(--inner-teal); background: var(--inner-teal); color: #fff; }
.news-filters button:disabled:not(.is-active) { opacity: .42; cursor: default; }
.news-year {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  gap: 10px;
  color: var(--inner-muted);
  font-size: 11px;
  font-weight: 650;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.news-year select {
  min-width: 112px;
  height: 40px;
  padding: 0 30px 0 12px;
  border: 1px solid var(--inner-line);
  border-radius: 2px;
  background: #fff;
  color: var(--inner-ink);
  font: inherit;
}
.news-archive__status {
  display: flex;
  align-items: center;
  min-height: 66px;
  color: var(--inner-muted);
  font-size: 12px;
}
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.news-grid .news-card--standard { min-height: 440px; display: flex; flex-direction: column; }
.news-grid .news-card__media { aspect-ratio: 16 / 10; }
.news-grid .news-card__content { flex: 1; padding: 25px 25px 23px; }
.news-grid .news-card__title { margin-top: 16px; font-size: 24px; }
.news-grid .news-card__excerpt { margin-top: 12px; font-size: 12px; -webkit-line-clamp: 3; }
.news-grid .news-card__action { margin-top: 25px; }
.news-pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-top: 46px;
}
.news-pagination button {
  width: 42px;
  height: 42px;
  border: 1px solid var(--inner-line);
  border-radius: 2px;
  background: #fff;
  color: var(--inner-teal);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}
.news-pagination button:hover:not(:disabled) { border-color: var(--inner-teal); }
.news-pagination button[aria-current="page"] { border-color: var(--inner-teal); background: var(--inner-teal); color: #fff; }
.news-pagination button:disabled { opacity: .35; cursor: default; }
.news-pagination__ellipsis {
  width: 26px;
  height: 42px;
  display: grid;
  place-items: center;
  color: var(--inner-muted);
}
.news-archive__note {
  max-width: 760px;
  margin: 38px auto 0;
  color: #56696d;
  font-size: 12px;
  line-height: 1.65;
  text-align: center;
}

/* Detail */
body.inner-page--news-item .news-item-intro { padding-bottom: 64px; }
.news-item-intro__meta { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.news-item-intro__type {
  color: var(--inner-orange);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.news-item-intro__meta time { color: var(--inner-muted); font-size: 11px; }
body.inner-page--news-item .inner-intro h1 { max-width: 980px; font-size: clamp(48px, 5.2vw, 72px); }
.news-item-intro__lead {
  max-width: 760px;
  margin: 28px 0 0;
  color: var(--inner-muted);
  font-size: 17px;
  line-height: 1.7;
}
.news-item-intro__back {
  display: inline-flex;
  margin-top: 27px;
  color: var(--inner-teal);
  font-size: 12px;
  font-weight: 680;
  text-underline-offset: 4px;
}
.news-detail { padding: 62px 0 96px; background: #fff; }
.news-detail__cover {
  max-width: 1100px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 2px 22px 2px 2px;
  background: #e3ece9;
}
.news-detail__cover img { width: 100%; max-height: 720px; display: block; object-fit: cover; }
.news-detail__layout {
  display: grid;
  grid-template-columns: minmax(0, 760px) minmax(240px, 1fr);
  gap: clamp(54px, 8vw, 110px);
  max-width: 1100px;
  margin: 58px auto 0;
}
.news-detail__body { color: #2f4145; font-size: 16px; line-height: 1.78; }
.news-detail__body p { margin: 0 0 21px; }
.news-detail__body ul { margin: 0 0 25px; padding-left: 22px; }
.news-detail__body li { margin: 8px 0; padding-left: 5px; }
.news-detail__body a { color: var(--inner-teal); font-weight: 620; text-decoration-thickness: 1px; text-underline-offset: 4px; overflow-wrap: anywhere; }
.news-detail__source-links {
  display: grid;
  justify-items: start;
  gap: 9px;
  margin-top: 36px;
  padding-top: 25px;
  border-top: 1px solid var(--inner-line);
}
.news-detail__source-links strong { margin-bottom: 2px; color: var(--inner-ink); font-size: 13px; }
.news-detail__aside {
  align-self: start;
  padding: 24px 0 0 24px;
  border-top: 2px solid var(--inner-cyan);
  border-left: 1px solid var(--inner-line);
  color: var(--inner-muted);
  font-size: 11px;
  line-height: 1.65;
}
.news-detail__aside strong { display: block; margin-bottom: 9px; color: var(--inner-ink); font-size: 13px; }
.news-detail__aside a { display: inline-block; margin-top: 15px; color: var(--inner-teal); font-weight: 650; text-underline-offset: 4px; }
.news-detail__gallery-section { max-width: 1100px; margin: 76px auto 0; }
.news-detail__gallery-section h2 { margin: 0 0 28px; color: var(--inner-ink); font-size: 32px; font-weight: 400; letter-spacing: -.035em; }
.news-detail__gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.news-detail__gallery img {
  width: 100%;
  min-height: 300px;
  max-height: 640px;
  display: block;
  border-radius: 2px 12px 2px 2px;
  background: #e3ece9;
  object-fit: cover;
}
.news-related { padding: 82px 0 94px; border-top: 1px solid var(--inner-line); background: #f2f6f4; }
.news-related .section-heading { align-items: end; margin-bottom: 35px; }
.news-related .news-grid .news-card--standard { min-height: 410px; }
.news-not-found .news-detail { display: none; }

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

@media (max-width: 880px) {
  .home-news__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-news__secondary { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; }
  .news-card--compact .news-card__media { min-height: 0; }
  body.inner-page--news .news-intro__grid { grid-template-columns: 1fr; gap: 28px; }
  body.inner-page--news .news-intro__lead { max-width: 620px; }
  .news-toolbar { align-items: stretch; flex-direction: column; }
  .news-year { justify-content: space-between; }
  .news-detail__layout { grid-template-columns: 1fr; gap: 42px; }
  .news-detail__aside { max-width: 560px; }
}

@media (max-width: 760px) {
  .home-news { padding: 66px 0 70px; }
  .home-news__grid { grid-template-columns: 1fr; grid-auto-rows: auto; }
  .home-news .section-heading { display: block; }
  .home-news .section-link { display: inline-flex; margin-top: 18px; }
  .news-card--feature { min-height: 0; display: grid; grid-template-rows: auto auto; }
  .news-card--feature .news-card__media { position: relative; inset: auto; }
  .news-card--feature .news-card__media::before { display: none; }
  .news-card--feature .news-card__content { position: relative; inset: auto; padding: 27px 24px 25px; color: var(--inner-ink); }
  .news-card--feature .news-card__meta { color: var(--inner-muted); }
  .news-card--feature .news-card__meta > span:first-child { color: var(--inner-orange); }
  .news-card--feature .news-card__title { font-size: clamp(27px, 7.4vw, 35px); }
  .news-card--feature .news-card__excerpt { color: var(--inner-muted); }
  .news-card--feature .news-card__action { color: var(--inner-teal); }
  .news-card--feature .news-card__excerpt { font-size: 12px; }
  .home-news__secondary { grid-template-columns: 1fr; }
  .news-card--compact { min-height: 0; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; }
  .news-card--compact .news-card__media { min-height: 0; }
  .news-card--compact .news-card__content { padding: 20px 18px; }
  .news-card--compact .news-card__title { margin-top: 10px; font-size: 18px; }
  .news-card--compact .news-card__excerpt,
  .news-card--compact .news-card__action { display: none; }
  .news-archive { padding: 40px 0 78px; }
  .news-toolbar { padding: 13px; }
  .news-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .news-filters button { min-height: 42px; padding-inline: 8px; border-color: var(--inner-line); }
  .news-grid { grid-template-columns: 1fr; gap: 12px; }
  .news-grid .news-card--standard { min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; }
  .news-grid .news-card__media { min-height: 0; aspect-ratio: auto; }
  .news-card__media--banner {
    min-height: 0;
    aspect-ratio: auto;
    background: #f2f6f4;
  }
  .news-card__media--banner img {
    width: 100%;
    height: auto;
    object-fit: contain;
    transform: none;
  }
  .news-card__media--fallback {
    min-height: 0;
    aspect-ratio: 5 / 3;
  }
  .news-grid .news-card__content { padding: 20px 18px; }
  .news-grid .news-card__meta { align-items: flex-start; flex-direction: column; gap: 3px; }
  .news-grid .news-card__title { margin-top: 10px; font-size: 19px; }
  .news-grid .news-card__excerpt { margin-top: 8px; font-size: 10px; -webkit-line-clamp: 2; }
  .news-grid .news-card__action { display: none; }
  .news-pagination { gap: 4px; margin-top: 34px; }
  .news-pagination button { width: 36px; height: 38px; }
  .news-pagination__ellipsis { width: 19px; height: 38px; }
  body.inner-page--news-item .news-item-intro { padding-bottom: 48px; }
  body.inner-page--news-item .inner-intro h1 { font-size: clamp(39px, 10.5vw, 50px); }
  .news-item-intro__lead { margin-top: 21px; font-size: 15px; }
  .news-detail { padding: 38px 0 72px; }
  .news-detail__cover { border-radius: 2px 12px 2px 2px; }
  .news-detail__cover img {
    height: auto;
    max-height: none;
    object-fit: contain;
  }
  .news-detail__layout { margin-top: 36px; }
  .news-detail__body { font-size: 15px; line-height: 1.72; }
  .news-detail__gallery-section { margin-top: 54px; }
  .news-detail__gallery-section h2 { font-size: 28px; }
  .news-detail__gallery { grid-template-columns: 1fr; }
  .news-detail__gallery img {
    height: auto;
    min-height: 0;
    max-height: none;
    object-fit: contain;
  }
  .news-related { padding: 64px 0 72px; }
}

@media (max-width: 430px) {
  .news-card--feature { min-height: 0; grid-template-rows: auto auto; }
  .news-card--feature .news-card__excerpt { display: -webkit-box; }
  .news-card--compact { grid-template-columns: minmax(0, 1fr); }
  .news-grid .news-card--standard { grid-template-columns: minmax(0, 1fr); }
  .news-grid .news-card__title { font-size: 17px; }
  .news-grid .news-card__excerpt { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .news-card,
  .news-card__media img { transition: none; }
}
