:root {
  --nm-news-bg: #f6f0ea;
  --nm-news-card: #fffdfb;
  --nm-news-card-soft: rgba(255, 253, 251, .82);
  --nm-news-text: #2f2521;
  --nm-news-muted: #8e8179;
  --nm-news-brown: #5f402d;
  --nm-news-brown-hover: #4d3223;
  --nm-news-border: rgba(111, 82, 62, .14);
  --nm-news-pill: #e4f0df;
  --nm-news-shadow: 0 22px 60px rgba(88, 63, 47, .10);
  --nm-news-shadow-small: 0 12px 32px rgba(88, 63, 47, .10);
}

.nm-news,
.nm-news * {
  box-sizing: border-box;
}

.nm-news {
  width: min(100%, 1320px);
  margin: 0 auto;
  padding: clamp(34px, 5vw, 76px) clamp(16px, 3vw, 28px);
  color: var(--nm-news-text);
  font-family: Gilroy, Montserrat, Arial, sans-serif;
}

.nm-news a {
  color: inherit;
  text-decoration: none !important;
  box-shadow: none !important;
}

.nm-news__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 28px;
}

.nm-news__intro {
  max-width: 560px;
}

.nm-news__title {
  margin: 0 0 12px;
  color: var(--nm-news-text);
  font-size: clamp(42px, 5vw, 66px);
  line-height: .95;
  letter-spacing: -0.05em;
  font-weight: 800;
}

.nm-news__subtitle {
  margin: 0;
  color: var(--nm-news-muted);
  font-size: clamp(16px, 1.3vw, 20px);
  line-height: 1.5;
}

.nm-news__filters {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 14px;
  max-width: 690px;
}

.nm-news-filter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 27px;
  border-radius: 999px;
  background: rgba(255, 253, 251, .76);
  border: 1px solid var(--nm-news-border);
  color: var(--nm-news-text);
  font-size: 16px;
  font-weight: 650;
  line-height: 1;
  transition: transform .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}

.nm-news-filter:hover {
  transform: translateY(-1px);
  border-color: rgba(95, 64, 45, .25);
}

.nm-news-filter.is-active {
  background: var(--nm-news-brown);
  border-color: var(--nm-news-brown);
  color: #fff;
}

.nm-news-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.nm-news-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  background: var(--nm-news-card);
  border-radius: 28px;
  box-shadow: var(--nm-news-shadow-small);
  border: 1px solid rgba(255, 255, 255, .72);
}

.nm-news-card__image {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1.74 / 1;
  overflow: hidden;
  background: linear-gradient(135deg, #d9cfc7, #f7f0eb);
}

.nm-news-card__image img,
.nm-news-single__image img,
.nm-news-mini__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.nm-news-card__placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: rgba(95, 64, 45, .36);
  font-size: 28px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.nm-news-badge {
  position: absolute;
  top: 18px;
  left: 18px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 9px 20px;
  border-radius: 999px;
  background: var(--nm-news-pill);
  color: #6c625b;
  font-size: 15px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 7px 18px rgba(49, 35, 26, .10);
}

.nm-news-badge--static {
  position: static;
  min-height: 34px;
  padding: 8px 17px;
  font-size: 14px;
  box-shadow: none;
}

.nm-news-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 23px 24px 26px;
}

.nm-news-card__date {
  margin-bottom: 14px;
  color: var(--nm-news-muted);
  font-size: 14px;
  line-height: 1.2;
}

.nm-news-card__title {
  margin: 0 0 13px;
  color: var(--nm-news-text);
  font-size: clamp(22px, 2vw, 28px);
  line-height: 1.05;
  letter-spacing: -0.035em;
  font-weight: 800;
}

.nm-news-card__text {
  margin: 0 0 24px;
  color: var(--nm-news-muted);
  font-size: 17px;
  line-height: 1.42;
}

.nm-news-card__button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-width: 146px;
  min-height: 45px;
  margin-top: auto;
  padding: 12px 26px;
  border-radius: 12px;
  background: var(--nm-news-brown);
  color: #fff !important;
  font-size: 16px;
  font-weight: 750;
  line-height: 1;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
  box-shadow: 0 12px 26px rgba(95, 64, 45, .18) !important;
}

.nm-news-card__button:hover {
  transform: translateY(-1px);
  background: var(--nm-news-brown-hover);
  color: #fff !important;
}

.nm-news-empty {
  padding: 34px;
  border-radius: 24px;
  background: var(--nm-news-card);
  box-shadow: var(--nm-news-shadow-small);
  color: var(--nm-news-muted);
  font-size: 18px;
}

.nm-news-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 34px;
}

.nm-news-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 42px;
  height: 42px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--nm-news-card);
  border: 1px solid var(--nm-news-border);
  color: var(--nm-news-text);
  font-weight: 700;
}

.nm-news-pagination .page-numbers.current {
  background: var(--nm-news-brown);
  border-color: var(--nm-news-brown);
  color: #fff;
}

.nm-news-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 28px;
  color: var(--nm-news-text);
  font-size: 16px;
  font-weight: 600;
}

.nm-news-back:hover {
  color: var(--nm-news-brown);
}

.nm-news-single__hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, 520px);
  align-items: center;
  gap: clamp(28px, 5vw, 70px);
  margin-bottom: 40px;
}

.nm-news-single__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 22px;
  color: var(--nm-news-muted);
  font-size: 15px;
  font-weight: 600;
}

.nm-news-single__title {
  margin: 0 0 22px;
  color: var(--nm-news-text);
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.03;
  letter-spacing: -0.055em;
  font-weight: 850;
}

.nm-news-single__lead {
  max-width: 650px;
  margin: 0;
  color: var(--nm-news-muted);
  font-size: clamp(17px, 1.3vw, 20px);
  line-height: 1.55;
}

.nm-news-single__image {
  width: 100%;
  aspect-ratio: 1.72 / 1;
  overflow: hidden;
  margin: 0;
  border-radius: 28px;
  box-shadow: var(--nm-news-shadow-small);
  background: #eee5dd;
}

.nm-news-content {
  width: 100%;
  margin: 0 auto;
  padding: clamp(24px, 4vw, 42px);
  border-radius: 28px;
  background: var(--nm-news-card-soft);
  border: 1px solid rgba(255,255,255,.7);
  box-shadow: var(--nm-news-shadow-small);
  color: var(--nm-news-text);
  font-size: clamp(16px, 1.2vw, 18px);
  line-height: 1.72;
}

.nm-news-content > *:first-child {
  margin-top: 0 !important;
}

.nm-news-content > *:last-child {
  margin-bottom: 0 !important;
}

.nm-news-content p,
.nm-news-content ul,
.nm-news-content ol {
  margin: 0 0 22px;
  color: #6f625a;
}

.nm-news-content h2,
.nm-news-content h3,
.nm-news-content h4 {
  margin: 30px 0 14px;
  color: var(--nm-news-text);
  line-height: 1.12;
  letter-spacing: -0.035em;
  font-weight: 800;
}

.nm-news-content h2 {
  font-size: clamp(26px, 2.4vw, 36px);
}

.nm-news-content h3 {
  font-size: clamp(22px, 2vw, 28px);
}

.nm-news-content a {
  color: var(--nm-news-brown);
  font-weight: 750;
}

.nm-news-content img {
  max-width: 100%;
  height: auto;
  border-radius: 22px;
}

.nm-news-content figure {
  margin: 30px 0;
}

.nm-news-content blockquote {
  margin: 30px 0;
  padding: 24px 28px;
  border-left: 4px solid var(--nm-news-brown);
  border-radius: 18px;
  background: rgba(95, 64, 45, .06);
  color: var(--nm-news-text);
  font-size: 20px;
  line-height: 1.45;
}

.nm-news-content .wp-block-button__link,
.nm-news-content .wp-element-button {
  border-radius: 14px !important;
  background: var(--nm-news-brown) !important;
  color: #fff !important;
  padding: 15px 28px !important;
  font-weight: 750 !important;
}

.nm-news-related {
  margin-top: 38px;
}

.nm-news-related__title {
  margin: 0 0 18px;
  color: var(--nm-news-text);
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.05;
  letter-spacing: -0.045em;
  font-weight: 850;
}

.nm-news-related__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.nm-news-mini {
  display: grid;
  grid-template-columns: 128px minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  min-height: 118px;
  padding: 13px 16px 13px 13px;
  border-radius: 20px;
  background: var(--nm-news-card);
  border: 1px solid rgba(255,255,255,.72);
  box-shadow: 0 12px 34px rgba(88, 63, 47, .08);
  transition: transform .2s ease, box-shadow .2s ease;
}

.nm-news-mini:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(88, 63, 47, .12);
}

.nm-news-mini__image {
  display: block;
  width: 128px;
  height: 88px;
  overflow: hidden;
  border-radius: 14px;
  background: #eee5dd;
}

.nm-news-mini__body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 11px;
}

.nm-news-mini__title {
  color: var(--nm-news-text);
  font-size: 16px;
  line-height: 1.18;
  font-weight: 800;
}

.nm-news-mini__date {
  color: var(--nm-news-muted);
  font-size: 13px;
  line-height: 1;
}

.nm-news-mini__arrow {
  color: var(--nm-news-brown);
  font-size: 30px;
  line-height: 1;
  font-weight: 500;
}

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

  .nm-news-single__hero {
    grid-template-columns: 1fr;
  }

  .nm-news-single__image {
    max-width: 720px;
  }

  .nm-news-related__grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .nm-news {
    padding: 32px 16px 54px;
  }

  .nm-news__head {
    align-items: flex-start;
    flex-direction: column;
    gap: 22px;
    margin-bottom: 24px;
  }

  .nm-news__filters {
    justify-content: flex-start;
    width: 100%;
    gap: 10px;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }

  .nm-news-filter {
    min-height: 42px;
    padding: 11px 20px;
    white-space: nowrap;
    font-size: 15px;
  }

  .nm-news-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .nm-news-card {
    border-radius: 24px;
  }

  .nm-news-card__image {
    aspect-ratio: 1.55 / 1;
  }

  .nm-news-card__body {
    padding: 21px 20px 22px;
  }

  .nm-news-card__button {
    width: 100%;
  }

  .nm-news-single__hero {
    gap: 24px;
    margin-bottom: 26px;
  }

  .nm-news-single__image {
    border-radius: 22px;
  }

  .nm-news-content {
    border-radius: 24px;
  }

  .nm-news-mini {
    grid-template-columns: 106px minmax(0, 1fr) auto;
    gap: 14px;
    padding: 12px 14px 12px 12px;
  }

  .nm-news-mini__image {
    width: 106px;
    height: 78px;
  }
}

@media (max-width: 480px) {
  .nm-news__title,
  .nm-news-single__title {
    letter-spacing: -0.045em;
  }

  .nm-news-badge {
    top: 14px;
    left: 14px;
    min-height: 34px;
    padding: 8px 16px;
    font-size: 14px;
  }

  .nm-news-card__title {
    font-size: 24px;
  }

  .nm-news-mini {
    grid-template-columns: 92px minmax(0, 1fr);
  }

  .nm-news-mini__image {
    width: 92px;
    height: 72px;
  }

  .nm-news-mini__arrow {
    display: none;
  }
}
