:root{
  --nha-ratio-desktop: 16 / 9;
  --nha-ratio-mobile:  3 / 4;
  --nha-maxw:          clamp(260px, 92vw, 1100px);
  --nha-ovl-top: .55;
  --nha-ovl-mid: .45;
  --nha-ovl-bot: .65;
}

.nha-postcards-container{
  max-width: var(--nha-maxw);
  margin: 0 auto;
  padding: 0 12px;
}

.nha-card{
  width: 100%;
  aspect-ratio: var(--nha-ratio-desktop);
  position: relative;
  overflow: hidden;
  border-radius: 16px;
  text-align: center;
  color: #f6fbfa;
  background: #0e1412 center/cover no-repeat;
  box-shadow: 0 12px 36px rgba(0,0,0,.35),
              inset 0 0 0 1px rgba(255,255,255,.02);
  margin: 8px 0 18px 0;
  transition: transform .18s ease, box-shadow .18s ease;
}
.nha-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 16px 46px rgba(0,0,0,.38),
              inset 0 0 0 1px rgba(255,255,255,.02);
}

.nha-card > img.nha-bg{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  display: block;
}

.nha-card::before{
  content:""; position:absolute; inset:0; pointer-events:none; z-index:2;
  background:
    radial-gradient(115% 120% at 50% 18%, rgba(0,0,0,var(--nha-ovl-top)), transparent 60%),
    linear-gradient(180deg, rgba(0,0,0,var(--nha-ovl-bot)),
                         rgba(0,0,0,var(--nha-ovl-mid)) 46%,
                         rgba(0,0,0,var(--nha-ovl-bot)));
}

.nha-content{
  position: relative; z-index: 3;
  width: 100%; height: 100%;
  max-width: 92%; margin: 0 auto;
  padding: clamp(16px, 4vw, 28px);
  display: flex; align-items: center; justify-content: center;
}

.nha-textwrap{
  max-width: 52ch;
  padding: clamp(10px, 2vw, 16px) clamp(12px, 2.4vw, 20px);
  border-radius: 12px;
  background: rgba(0,0,0,.55);
  -webkit-backdrop-filter: saturate(110%) blur(3px);
  backdrop-filter: saturate(110%) blur(3px);
}

.nha-title{
  margin: 0 0 .42rem 0;
  line-height: 1.24;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
  text-overflow: clip !important;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
  hyphens: auto;
}
.nha-title a{
  color: inherit;
  text-decoration: none !important;
  border-bottom: 0 !important;
}
.nha-title a:hover{
  text-decoration: underline;
  text-underline-offset: 2px;
}

.nha-card:not(.nha-card-archive) .nha-title{
  font-size: clamp(0.98rem, 2.0vw, 1.45rem);
}

.nha-card.nha-card-archive .nha-title{
  font-size: clamp(0.95rem, 1.6vw, 1.15rem);
}

.nha-excerpt{
  margin: .15rem 0 .4rem 0;
  line-height: 1.45;
  font-size: clamp(.9rem, 1.6vw, 1.05rem);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  overflow: hidden;
  text-overflow: clip !important;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
  hyphens: auto;
}
.nha-meta{
  margin: 0;
  opacity: .95;
  font-size: clamp(.85rem, 1.5vw, .96rem);
}

.nha-archive-grid{
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px,1fr));
  gap: 20px;
  margin-top: 2rem;
}
.nha-card.nha-card-archive{
  aspect-ratio: var(--nha-ratio-desktop);
  margin: 0;
}
.nha-card.nha-card-archive .nha-textwrap{
  max-width: 44ch;
  padding: clamp(8px, 1.6vw, 14px);
}
.nha-card.nha-card-archive .nha-excerpt{
  -webkit-line-clamp: 3;
  line-clamp: 3;
}

.nha-card-link{
  position: absolute; inset: 0; z-index: 4;
}

.nha-pagination{
  margin-top: 1.8rem;
  text-align: center;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .5rem;
}
.nha-pagination a,
.nha-pagination span{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.4rem;
  height: 2.4rem;
  padding: 0 .75rem;
  border-radius: 10px;
  font-size: 1rem;
  line-height: 1;
  background: rgba(255,255,255,0.08);
  color: #eaf4f1;
  text-decoration: none;
  transition: background .2s, transform .15s;
}
.nha-pagination a:hover{
  background: #00997a;
  transform: translateY(-1px);
}
.nha-pagination .current{
  background: #00cc99;
  color: #fff;
  font-weight: 600;
}

@media (max-width: 700px){
  .nha-card{ aspect-ratio: var(--nha-ratio-mobile); }
  .nha-postcards-container{ padding-inline: 10px; }
  .nha-textwrap{ max-width: 100%; padding: 12px; }

  .nha-card:not(.nha-card-archive) .nha-title{
    font-size: clamp(.95rem, 4.4vw, 1.2rem);
  }
  .nha-card.nha-card-archive .nha-title{
    font-size: clamp(.88rem, 3.9vw, 1.04rem);
  }
  .nha-excerpt{
    font-size: clamp(.85rem, 4.2vw, .95rem);
  }

  .nha-archive-grid{
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .nha-pagination a,
  .nha-pagination span{
    min-width: 2.8rem;
    height: 2.8rem;
    font-size: .95rem;
    border-radius: 8px;
  }
}
