.np-homepage { padding-block: var(--np-space-6) var(--np-space-12); }
.np-homepage a { text-decoration: none; }
.np-home-hero { display: grid; min-width: 0; gap: var(--np-space-6); }
.np-hero-main, .np-small-card, .np-latest-card, .np-category-main { min-width: 0; }
.np-hero-main__image, .np-small-card__image, .np-latest-card__image, .np-category-main__image { display: block; overflow: hidden; border-radius: var(--np-radius-md); background: var(--np-color-surface); }
.np-hero-main__image { aspect-ratio: 16 / 9; margin-block-end: var(--np-space-4); }
.np-hero-main__image img, .np-small-card__image img, .np-latest-card__image img, .np-category-main__image img { width: 100%; height: 100%; object-fit: cover; }
.np-category-label { display: inline-block; margin-block-end: var(--np-space-2); color: var(--np-color-primary); font-size: 0.75rem; font-weight: 800; letter-spacing: 0.055em; line-height: 1.3; text-transform: uppercase; }
.np-hero-main__title { margin-block-end: var(--np-space-3); font-size: clamp(1.5rem, 6.5vw, 2.5rem); letter-spacing: -0.035em; }
.np-hero-main__title a, .np-small-card__title a, .np-latest-card__title a, .np-category-section h3 a, .np-popular-list h3 a { color: var(--np-color-text); }
.np-hero-main__excerpt { display: -webkit-box; margin-block-end: var(--np-space-3); overflow: hidden; color: var(--np-color-text-muted); -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.np-card-time { color: var(--np-color-text-muted); font-size: 0.75rem; }
.np-hero-secondary { display: grid; gap: var(--np-space-4); }
.np-small-card { display: grid; grid-template-columns: minmax(7rem, 38%) minmax(0, 1fr); align-items: start; gap: var(--np-space-3); padding-block-end: var(--np-space-4); border-bottom: 1px solid var(--np-color-border); }
.np-small-card__image { aspect-ratio: 16 / 9; }
.np-small-card__content { min-width: 0; }
.np-small-card .np-category-label { margin-block-end: var(--np-space-1); font-size: 0.6875rem; }
.np-small-card__title { display: -webkit-box; margin-block-end: var(--np-space-2); overflow: hidden; font-size: clamp(0.9375rem, 3.8vw, 1.125rem); line-height: 1.3; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.np-small-card.np-card--no-image { grid-template-columns: minmax(0, 1fr); }
.np-advertisement { display: flex; min-height: 5.625rem; align-items: center; justify-content: center; flex-direction: column; gap: var(--np-space-1); margin-block: var(--np-space-8); border: 1px dashed #d0d0d0; border-radius: var(--np-radius-sm); background: var(--np-color-surface); color: var(--np-color-text-muted); text-align: center; }
.np-advertisement span { font-size: 0.6875rem; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; }
.np-advertisement small { font-size: 0.6875rem; }
.np-advertisement--compact { min-height: 12rem; margin-block: 0; }
.np-home-content-grid { display: grid; min-width: 0; gap: var(--np-space-10); }
.np-home-main-column, .np-home-sidebar { min-width: 0; }
.np-home-content-grid--full { grid-template-columns: minmax(0, 1fr); }
.np-home-section + .np-home-section, .np-home-category-sections { margin-block-start: var(--np-space-10); }
.np-section-heading { display: flex; align-items: center; min-height: 2.75rem; margin-block-end: var(--np-space-5); border-bottom: 2px solid var(--np-color-border); }
.np-section-heading h2 { position: relative; margin: 0; padding-block-end: var(--np-space-3); font-size: clamp(1.25rem, 4.5vw, 1.625rem); letter-spacing: -0.02em; text-transform: uppercase; }
.np-section-heading h2::after { position: absolute; bottom: -2px; left: 0; width: 3rem; height: 2px; background: var(--np-color-primary); content: ""; }
.np-section-heading--with-link { justify-content: space-between; gap: var(--np-space-4); }
.np-section-heading--with-link > a, .np-section-more { color: var(--np-color-primary-dark); font-size: 0.8125rem; font-weight: 700; white-space: nowrap; }
.np-latest-list { display: grid; gap: var(--np-space-6); }
.np-latest-card { display: grid; gap: var(--np-space-4); padding-block-end: var(--np-space-6); border-bottom: 1px solid var(--np-color-border); }
.np-latest-card__image { aspect-ratio: 16 / 9; }
.np-latest-card__content { min-width: 0; }
.np-latest-card__title { margin-block-end: var(--np-space-2); font-size: clamp(1.125rem, 4.5vw, 1.45rem); letter-spacing: -0.02em; }
.np-latest-card__content p { display: -webkit-box; margin-block-end: var(--np-space-2); overflow: hidden; color: var(--np-color-text-muted); font-size: 0.9375rem; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.np-section-more { display: inline-flex; min-height: 2.75rem; align-items: center; gap: var(--np-space-2); margin-block-start: var(--np-space-5); }
.np-home-sidebar { min-height: 0; }
.np-home-sidebar__inner { display: grid; align-content: start; gap: var(--np-space-8); }
.np-home-widget { min-width: 0; overflow-wrap: anywhere; }
.np-home-widget img { width: 100%; height: auto; }
.np-home-widget select, .np-home-widget input, .np-home-widget textarea { max-width: 100%; }
.np-sidebar-section { min-width: 0; }
.np-popular-list { margin: 0; padding: 0; list-style: none; }
.np-popular-list li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); gap: var(--np-space-3); padding-block: var(--np-space-4); border-bottom: 1px solid var(--np-color-border); }
.np-popular-list li:first-child { padding-block-start: 0; }
.np-popular-number { color: #c7c7c7; font-size: 1.75rem; font-weight: 800; line-height: 1; }
.np-popular-list h3 { margin-block-end: var(--np-space-1); font-size: 0.975rem; line-height: 1.4; }
.np-trending-tags { display: flex; flex-wrap: wrap; gap: var(--np-space-2); }
.np-trending-tags a { display: inline-flex; min-height: 2.5rem; align-items: center; padding-inline: var(--np-space-3); border: 1px solid var(--np-color-border); border-radius: 999px; color: var(--np-color-text); font-size: 0.8125rem; font-weight: 600; }
.np-trending-tags a:hover { border-color: var(--np-color-primary); color: var(--np-color-primary); }
.np-category-section { padding-block-start: var(--np-space-2); }
.np-category-grid { display: grid; gap: var(--np-space-6); }
.np-category-main__image { aspect-ratio: 16 / 9; margin-block-end: var(--np-space-4); }
.np-category-main h3 { margin-block-end: var(--np-space-2); font-size: clamp(1.25rem, 4.8vw, 1.75rem); letter-spacing: -0.025em; }
.np-category-main p { display: -webkit-box; margin-block-end: var(--np-space-2); overflow: hidden; color: var(--np-color-text-muted); -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.np-category-secondary { display: grid; gap: var(--np-space-4); }

/* Dynamic category layout system. */
.np-category-section { min-width: 0; }
.np-category-section__header { margin-block-end: var(--np-space-5); }
.np-category-section__more { color: var(--np-color-primary-dark); font-size: 0.8125rem; font-weight: 700; white-space: nowrap; }
.np-category-feature-list, .np-category-two-column-list, .np-category-card-grid, .np-category-mosaic, .np-category-horizontal-cards, .np-category-lead-headlines { display: grid; min-width: 0; gap: var(--np-space-5); }
.np-category-lead, .np-category-card { min-width: 0; }
.np-category-lead__image, .np-category-card__image { display: block; overflow: hidden; margin-block-end: var(--np-space-3); border-radius: var(--np-radius-md); background: var(--np-color-surface); aspect-ratio: 16 / 9; }
.np-category-lead__image img, .np-category-card__image img { width: 100%; height: 100%; object-fit: cover; }
.np-category-lead h3, .np-category-card__title { display: -webkit-box; margin-block-end: var(--np-space-2); overflow: hidden; color: var(--np-color-text); font-size: clamp(1.125rem, 4.5vw, 1.65rem); letter-spacing: -0.025em; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
.np-category-card__title { font-size: clamp(1rem, 4vw, 1.25rem); }
.np-category-lead p { display: -webkit-box; margin-block-end: var(--np-space-2); overflow: hidden; color: var(--np-color-text-muted); -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.np-category-compact-list { display: grid; align-content: start; gap: var(--np-space-4); }
.np-category-two-column-list .np-small-card:last-child, .np-category-compact-list .np-small-card:last-child { border-bottom: 0; }
.np-category-card { padding-block-end: var(--np-space-4); border-bottom: 1px solid var(--np-color-border); }
.np-category-headline-list { margin: 0; padding: 0; list-style: none; }
.np-category-headline-list li { display: grid; grid-template-columns: 2.5rem minmax(0, 1fr); gap: var(--np-space-3); padding-block: var(--np-space-4); border-bottom: 1px solid var(--np-color-border); }
.np-category-headline-list li:first-child { padding-block-start: 0; }
.np-category-headline-list li > span { color: #c7c7c7; font-size: 1.65rem; font-weight: 800; line-height: 1; }
.np-category-headline-list h3 { display: -webkit-box; margin-block-end: var(--np-space-1); overflow: hidden; font-size: 1rem; line-height: 1.4; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }

@media (min-width: 640px) {
	.np-homepage { padding-block-start: var(--np-space-8); }
	.np-hero-secondary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.np-hero-secondary .np-small-card { grid-template-columns: minmax(0, 1fr); align-content: start; }
	.np-hero-secondary .np-small-card__image { margin-block-end: var(--np-space-1); }
	.np-latest-card { grid-template-columns: minmax(12rem, 38%) minmax(0, 1fr); align-items: start; }
	.np-category-secondary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.np-category-secondary .np-small-card { grid-template-columns: minmax(0, 1fr); }
	.np-category-two-column-list, .np-category-card-grid, .np-category-horizontal-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.np-category-card-grid .np-category-card, .np-category-horizontal-cards .np-category-card { display: flex; min-height: 100%; flex-direction: column; }
	.np-category-card-grid .np-card-time, .np-category-horizontal-cards .np-card-time { margin-block-start: auto; }
	.np-category-mosaic { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.np-category-card--mosaic-lead { grid-column: 1 / -1; }
}

@media (min-width: 768px) {
	.np-home-hero { grid-template-columns: minmax(0, 1.35fr) minmax(18rem, 0.65fr); align-items: stretch; }
	.np-hero-main { display: flex; min-height: 100%; flex-direction: column; }
	.np-hero-main__content { margin-block-start: auto; }
	.np-hero-secondary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.np-hero-secondary .np-small-card__title { font-size: 0.9375rem; }
	.np-home-category-sections { margin-block-start: var(--np-space-12); }
	.np-category-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); }
	.np-category-secondary { grid-template-columns: minmax(0, 1fr); }
	.np-category-secondary .np-small-card { grid-template-columns: minmax(6.5rem, 36%) minmax(0, 1fr); }
	.np-category-feature-list, .np-category-lead-headlines { grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); align-items: start; }
	.np-category-compact-list .np-small-card { grid-template-columns: minmax(6.5rem, 36%) minmax(0, 1fr); }
	.np-category-mosaic { grid-template-columns: minmax(0, 1.2fr) repeat(2, minmax(0, 0.6fr)); }
	.np-category-card--mosaic-lead { grid-row: span 2; grid-column: auto; }
	.np-category-card--mosaic-lead .np-category-card__image { aspect-ratio: 4 / 3; }
}

@media (min-width: 1024px) {
	.np-homepage { padding-block-start: var(--np-space-10); }
	.np-home-content-grid { grid-template-columns: minmax(0, 2fr) minmax(17.5rem, 0.8fr); gap: var(--np-space-10); }
	.np-home-content-grid--full { grid-template-columns: minmax(0, 1fr); }
	.np-home-sidebar { position: relative; }
	.np-home-category-sections { display: grid; gap: var(--np-space-12); }
	.np-category-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); }
	.np-category-two-column-list { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--np-space-8); }
	.np-category-card-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.np-category-horizontal-cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
	.np-category-horizontal-cards .np-category-card__title { font-size: 1.05rem; }
}

@media (min-width: 1280px) {
	.np-home-hero { grid-template-columns: minmax(0, 1.55fr) minmax(25rem, 0.75fr); gap: var(--np-space-8); }
	.np-hero-main__title { font-size: 2.5rem; }
	.np-hero-secondary { gap: var(--np-space-5); }
	.np-home-content-grid { gap: var(--np-space-12); }
}

/* Milestone 5.8 editorial density pass. */
.np-homepage { padding-block: 1.5rem 3.5rem; }
.np-home-hero { gap: 1.25rem; padding-bottom: 1.75rem; border-bottom: 1px solid var(--np-color-border); }
.np-hero-main__image, .np-small-card__image, .np-latest-card__image, .np-category-main__image,
.np-category-lead__image, .np-category-card__image { border-radius: .25rem; }
.np-hero-main__image { margin-bottom: .85rem; }
.np-hero-main__title { margin-bottom: .55rem; font-size: 1.5rem; line-height: 1.16; }
.np-hero-main__excerpt { margin-bottom: .55rem; font-size: .92rem; line-height: 1.55; }
.np-category-label { margin-bottom: .3rem; font-size: .68rem; }
.np-hero-secondary { gap: .85rem 1rem; }
.np-small-card { gap: .75rem; padding-bottom: .85rem; }
.np-small-card__title { margin-bottom: .25rem; font-size: clamp(.9rem,3.5vw,1.05rem); line-height: 1.32; }
.np-advertisement { margin-block: 1.75rem; }
.np-home-content-grid { gap: 2.25rem; }
.np-home-section + .np-home-section, .np-home-category-sections { margin-top: 2.25rem; }
.np-section-heading { min-height: 2.35rem; margin-bottom: 1rem; }
.np-section-heading h2 { padding-bottom: .6rem; font-size: clamp(1.1rem,3vw,1.4rem); }
.np-latest-list { gap: 1rem; }
.np-latest-card { gap: 1rem; padding-bottom: 1rem; }
.np-latest-card__title { margin-bottom: .35rem; font-size: clamp(1.05rem,3vw,1.3rem); line-height: 1.28; }
.np-latest-card__content p { margin-bottom: .35rem; font-size: .86rem; line-height: 1.5; }
.np-home-sidebar__inner { gap: 1.75rem; }
.np-popular-list li { padding-block: .75rem; }
.np-popular-number { font-size: 1.55rem; }
.np-popular-list h3 { font-size: .9rem; line-height: 1.35; }
.np-trending-tags a { min-height: 2.1rem; padding-inline: .7rem; border-radius: .25rem; font-size: .75rem; }
.np-home-category-sections { gap: 2.75rem; }
.np-category-section__header { margin-bottom: 1rem; }
.np-category-feature-list, .np-category-two-column-list, .np-category-card-grid, .np-category-mosaic,
.np-category-horizontal-cards, .np-category-lead-headlines { gap: 1rem; }
.np-category-lead__image, .np-category-card__image { margin-bottom: .65rem; }
.np-category-lead h3, .np-category-card__title { margin-bottom: .35rem; font-size: clamp(1.05rem,3vw,1.45rem); line-height: 1.25; }
.np-category-card__title { font-size: clamp(.95rem,2.4vw,1.12rem); }
.np-category-card { padding-bottom: .85rem; }
.np-category-compact-list { gap: .85rem; }
.np-category-headline-list li { padding-block: .75rem; }
.np-category-headline-list h3 { font-size: .92rem; line-height: 1.35; }

@media (max-width: 639px) {
	.np-homepage { padding-top: 1rem; }
	.np-hero-main__excerpt { display: none; }
	.np-hero-secondary { display: grid; grid-template-columns: 1fr; }
	.np-hero-secondary .np-small-card { grid-template-columns: 7.25rem minmax(0,1fr); }
	.np-home-content-grid { gap: 2rem; }
	.np-latest-card { grid-template-columns: 7.5rem minmax(0,1fr); }
	.np-latest-card__content p { display: none; }
	.np-latest-card__image { aspect-ratio: 4/3; }
	.np-category-horizontal-cards .np-category-card, .np-category-card-grid .np-category-card { display: grid; grid-template-columns: 7.25rem minmax(0,1fr); gap: .75rem; }
	.np-category-horizontal-cards .np-category-card__image, .np-category-card-grid .np-category-card__image { margin: 0; aspect-ratio: 4/3; }
}

@media (min-width: 768px) {
	.np-home-hero { grid-template-columns: minmax(0,1.35fr) minmax(20rem,1fr); }
	.np-hero-main__image { aspect-ratio: 2/1; }
	.np-hero-secondary { grid-template-columns: repeat(2,minmax(0,1fr)); }
	.np-hero-secondary .np-small-card { display: block; }
	.np-hero-secondary .np-small-card__image { margin-bottom: .55rem; aspect-ratio: 16/10; }
	.np-latest-list--two-column { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1.25rem; }
	.np-latest-list--two-column .np-latest-card { display: block; }
	.np-latest-list--two-column .np-latest-card__image { margin-bottom: .7rem; aspect-ratio: 16/9; }
	.np-latest-list--two-column .np-latest-card__content p { -webkit-line-clamp: 2; }
}

@media (min-width: 1024px) {
	.np-homepage { padding-top: 1.75rem; }
	.np-home-content-grid { grid-template-columns: minmax(0,2.15fr) minmax(17rem,.85fr); gap: 2.75rem; }
	.np-home-sidebar--sticky.is-sticky-ready .np-home-sidebar__inner { position: sticky; top: var(--np-smart-sticky-top,var(--np-sidebar-sticky-offset,80px)); }
	.np-latest-list--card-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 1.1rem; }
	.np-latest-list--card-grid .np-latest-card { display: block; }
	.np-latest-list--card-grid .np-latest-card__image { margin-bottom: .65rem; aspect-ratio: 4/3; }
	.np-latest-list--card-grid .np-latest-card__title { font-size: 1rem; }
	.np-latest-list--card-grid .np-latest-card__content p { display: none; }
	.np-category-card-grid { gap: 1.25rem; }
}

@media (min-width: 1280px) {
	.np-home-hero { grid-template-columns: minmax(0,1.42fr) minmax(25rem,1fr); gap: 1.5rem; }
	.np-hero-main__title { font-size: 1.5rem; }
}
