/*
Theme Name: Noor News Pro
Theme URI: https://nooreroyaeinews.ir/
Author: SaeidPix
Author URI: https://www.saeidpix.ir/
Description: قالب خبری فارسی، سریع، واکنش‌گرا و راست‌چین با نمایش کامل تصویر، تیتر، خلاصه، تاریخ و نویسنده در صفحات دسته‌بندی.
Version: 2.1.0
Requires at least: 6.2
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: noor-news-pro
Tags: news, blog, rtl-language-support, custom-logo, featured-images, two-columns, right-sidebar, block-styles
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
*/

:root {
  --nn-accent: #d71920;
  --nn-accent-dark: #ad1117;
  --nn-ink: #171a21;
  --nn-muted: #69707d;
  --nn-line: #e7e9ee;
  --nn-soft: #f5f6f8;
  --nn-white: #fff;
  --nn-radius: 16px;
  --nn-shadow: 0 12px 35px rgba(21, 29, 43, .08);
  --nn-container: 1180px;
  --nn-font-body: 'Vazirmatn', Tahoma, Arial, sans-serif;
  --nn-font-heading: 'Estedad', 'Vazirmatn', Tahoma, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  direction: rtl;
  color: var(--nn-ink);
  background: #fff;
  font-family: var(--nn-font-body);
  font-size: 15px;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; transition: .2s ease; }
a:hover { color: var(--nn-accent); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
.screen-reader-text {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.container { width: min(calc(100% - 32px), var(--nn-container)); margin-inline: auto; }
.site-main { min-height: 55vh; }

/* Top bar */
.topbar { background: #111319; color: #c7cbd4; font-size: 13px; }
.topbar-inner { min-height: 39px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.topbar-links { display: flex; gap: 18px; flex-wrap: wrap; }
.topbar a:hover { color: #fff; }

/* Header */
.site-header { background: #fff; position: relative; z-index: 40; }
.brand-row { min-height: 112px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.site-branding { display: flex; align-items: center; gap: 14px; min-width: 220px; }
.custom-logo { max-height: 74px; width: auto; }
.site-title { margin: 0; font-size: clamp(24px, 3vw, 38px); font-weight: 900; letter-spacing: -.7px; line-height: 1.15; }
.site-title span { color: var(--nn-accent); }
.site-description { margin: 6px 0 0; color: var(--nn-muted); font-size: 13px; }
.header-ad {
  flex: 1; min-height: 70px; border-radius: 12px; background: linear-gradient(135deg,#f4f5f7,#eceff3);
  display: flex; align-items: center; justify-content: center; color: #8b919c; border: 1px dashed #cfd3da;
}

.nav-shell { background: #fff; border-top: 1px solid var(--nn-line); border-bottom: 1px solid var(--nn-line); }
.nav-row { display: flex; align-items: stretch; justify-content: space-between; min-height: 57px; }
.primary-nav { display: flex; align-items: stretch; }
.primary-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: stretch; }
.primary-nav li { position: relative; display: flex; align-items: stretch; }
.primary-nav > div > ul > li > a { display: flex; align-items: center; padding: 0 17px; font-weight: 750; }
.primary-nav > div > ul > li.current-menu-item > a,
.primary-nav > div > ul > li.current-menu-ancestor > a { color: var(--nn-accent); }
.primary-nav > div > ul > li.current-menu-item > a::after,
.primary-nav > div > ul > li.current-menu-ancestor > a::after {
  content: ''; position: absolute; right: 17px; left: 17px; bottom: 0; height: 3px; background: var(--nn-accent); border-radius: 4px 4px 0 0;
}
.primary-nav .sub-menu {
  position: absolute; top: 100%; right: 0; min-width: 220px; background: #fff; display: block; visibility: hidden;
  opacity: 0; transform: translateY(8px); box-shadow: var(--nn-shadow); border: 1px solid var(--nn-line); border-radius: 0 0 12px 12px; padding: 8px;
}
.primary-nav li:hover > .sub-menu { visibility: visible; opacity: 1; transform: none; }
.primary-nav .sub-menu li { display: block; }
.primary-nav .sub-menu a { display: block; padding: 9px 12px; border-radius: 7px; }
.primary-nav .sub-menu a:hover { background: var(--nn-soft); }
.nav-tools { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 42px; height: 42px; border: 0; background: var(--nn-soft); border-radius: 11px; display: inline-flex;
  align-items: center; justify-content: center; color: var(--nn-ink);
}
.icon-btn:hover { background: var(--nn-accent); color: #fff; }
.mobile-menu-toggle { display: none; }

/* Search panel */
.search-panel { display: none; border-bottom: 1px solid var(--nn-line); background: #fff; padding: 18px 0; }
.search-panel.is-open { display: block; }
.search-form { display: flex; gap: 8px; width: 100%; }
.search-field { width: 100%; min-height: 48px; border: 1px solid var(--nn-line); border-radius: 11px; padding: 10px 15px; outline: none; }
.search-field:focus { border-color: var(--nn-accent); box-shadow: 0 0 0 3px rgba(215,25,32,.09); }
.search-submit { border: 0; border-radius: 11px; background: var(--nn-accent); color: #fff; padding: 0 22px; font-weight: 800; }

/* Breaking news */
.breaking { background: #fff; border-bottom: 1px solid var(--nn-line); }
.breaking-inner { min-height: 48px; display: flex; align-items: center; overflow: hidden; }
.breaking-label { align-self: stretch; display: flex; align-items: center; padding: 0 18px; background: var(--nn-accent); color: #fff; font-weight: 900; white-space: nowrap; }
.breaking-label::after { content: ''; width: 7px; height: 7px; background: #fff; border-radius: 50%; margin-right: 9px; animation: nnPulse 1.5s infinite; }
@keyframes nnPulse { 50% { opacity: .25; } }
.breaking-track { flex: 1; min-width: 0; padding: 0 17px; overflow: hidden; white-space: nowrap; }
.breaking-item { display: none; font-weight: 700; overflow: hidden; text-overflow: ellipsis; }
.breaking-item.is-active { display: block; }

/* Utilities */
.section { padding: 44px 0; }
.section-soft { background: var(--nn-soft); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.section-title { margin: 0; font-size: clamp(22px, 2.5vw, 31px); line-height: 1.3; font-weight: 900; }
.section-title::before { content: ''; display: inline-block; width: 5px; height: 25px; margin-left: 10px; background: var(--nn-accent); border-radius: 4px; vertical-align: -5px; }
.section-link { color: var(--nn-accent); font-weight: 800; white-space: nowrap; }
.category-chip { display: inline-flex; align-items: center; width: fit-content; padding: 3px 10px; border-radius: 999px; background: var(--nn-accent); color: #fff !important; font-size: 12px; font-weight: 800; }
.post-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; color: var(--nn-muted); font-size: 12px; }
.meta-item { display: inline-flex; align-items: center; gap: 5px; }
.meta-dot::before { content: ''; width: 4px; height: 4px; border-radius: 50%; background: #a8adb6; display: inline-block; margin-left: 10px; }
.line-clamp-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* Hero */
.home-hero { padding: 28px 0 10px; }
.hero-grid { display: grid; grid-template-columns: 1.45fr 1fr; gap: 16px; }
.hero-main, .hero-small { position: relative; overflow: hidden; border-radius: var(--nn-radius); background: #242832; color: #fff; }
.hero-main { min-height: 480px; }
.hero-side { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.hero-small { min-height: 232px; }
.hero-image, .hero-image img { width: 100%; height: 100%; object-fit: cover; display: block; position: absolute; inset: 0; }
.hero-main::after, .hero-small::after { content: ''; position: absolute; inset: 0; background: linear-gradient(0deg,rgba(6,8,12,.94),rgba(6,8,12,.05) 72%); }
.hero-content { position: absolute; z-index: 2; right: 0; left: 0; bottom: 0; padding: 26px; }
.hero-small .hero-content { padding: 17px; }
.hero-title { margin: 11px 0 10px; font-size: clamp(24px,3vw,38px); line-height: 1.45; font-weight: 900; }
.hero-small .hero-title { font-size: 17px; margin: 8px 0; line-height: 1.55; }
.hero-content .post-meta { color: #d8dce4; }

/* General post cards */
.content-layout { display: grid; grid-template-columns: minmax(0,1fr) 320px; gap: 32px; align-items: start; }
.posts-list { display: grid; gap: 20px; }
.news-card {
  display: grid; grid-template-columns: 300px minmax(0,1fr); background: #fff; border: 1px solid var(--nn-line);
  border-radius: var(--nn-radius); overflow: hidden; transition: .25s ease;
}
.news-card:hover { transform: translateY(-3px); box-shadow: var(--nn-shadow); border-color: transparent; }
.news-card-media { position: relative; min-height: 210px; overflow: hidden; background: #e8ebef; }
.news-card-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .45s ease; }
.news-card:hover .news-card-media img { transform: scale(1.04); }
.news-card-body { padding: 21px 23px; display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.news-card-title { margin: 10px 0 8px; font-size: 21px; line-height: 1.6; font-weight: 900; }
.news-card-excerpt { margin: 10px 0 0; color: #535a66; line-height: 1.95; }
.news-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-top: 15px; }
.read-more { color: var(--nn-accent); font-weight: 850; font-size: 13px; }
.image-placeholder { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: linear-gradient(145deg,#232732,#444b5a); color: #fff; text-align: center; padding: 25px; font-weight: 900; font-size: 20px; }
.image-placeholder::before { content: 'N'; width: 64px; height: 64px; display: grid; place-items: center; border: 2px solid rgba(255,255,255,.65); border-radius: 50%; margin-left: 13px; color: var(--nn-accent); background: #fff; }

/* Compact grids */
.card-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 20px; }
.grid-card { border: 1px solid var(--nn-line); border-radius: var(--nn-radius); overflow: hidden; background: #fff; transition: .25s ease; }
.grid-card:hover { transform: translateY(-4px); box-shadow: var(--nn-shadow); border-color: transparent; }
.grid-card-media { position: relative; aspect-ratio: 16/10; background: #e8ebef; overflow: hidden; }
.grid-card-media img { width: 100%; height: 100%; object-fit: cover; }
.grid-card-body { padding: 18px; }
.grid-card-title { margin: 9px 0; font-size: 18px; line-height: 1.65; font-weight: 900; }

/* Archive header */
.archive-hero { padding: 38px 0; background: linear-gradient(135deg,#f7f8fa,#eef1f5); border-bottom: 1px solid var(--nn-line); }
.breadcrumbs { color: var(--nn-muted); font-size: 13px; margin-bottom: 9px; }
.archive-title { margin: 0; font-size: clamp(27px,4vw,43px); font-weight: 950; line-height: 1.35; }
.archive-description { max-width: 760px; color: var(--nn-muted); margin: 10px 0 0; }
.result-count { margin-top: 13px; color: var(--nn-muted); font-size: 13px; }

/* Sidebar */
.sidebar { display: grid; gap: 22px; position: sticky; top: 20px; }
.widget { border: 1px solid var(--nn-line); border-radius: var(--nn-radius); padding: 20px; background: #fff; }
.widget-title { margin: 0 0 17px; padding-bottom: 12px; border-bottom: 1px solid var(--nn-line); font-size: 18px; font-weight: 900; }
.widget-title::before { content: ''; display: inline-block; width: 4px; height: 18px; border-radius: 3px; background: var(--nn-accent); margin-left: 8px; vertical-align: -3px; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li + li { border-top: 1px dashed var(--nn-line); }
.widget li a { display: block; padding: 10px 0; font-weight: 700; }
.sidebar-post { display: grid; grid-template-columns: 82px 1fr; gap: 11px; align-items: center; }
.sidebar-post + .sidebar-post { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--nn-line); }
.sidebar-post-thumb { aspect-ratio: 1.15; border-radius: 9px; overflow: hidden; background: var(--nn-soft); }
.sidebar-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.sidebar-post-title { font-size: 13px; line-height: 1.65; font-weight: 850; }
.sidebar-post-date { color: var(--nn-muted); font-size: 11px; }

/* Pagination */
.pagination { margin-top: 30px; }
.nav-links { display: flex; flex-wrap: wrap; gap: 8px; }
.page-numbers { min-width: 42px; height: 42px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--nn-line); display: inline-flex; align-items: center; justify-content: center; font-weight: 800; }
.page-numbers.current, .page-numbers:hover { background: var(--nn-accent); color: #fff; border-color: var(--nn-accent); }

/* Single */
.single-wrap { max-width: 900px; margin-inline: auto; }
.article-header { padding: 42px 0 24px; text-align: center; }
.article-category { justify-content: center; }
.article-title { margin: 14px auto 15px; max-width: 900px; font-size: clamp(30px,5vw,52px); line-height: 1.5; font-weight: 950; letter-spacing: -.6px; }
.article-meta { justify-content: center; font-size: 13px; }
.article-cover { overflow: hidden; border-radius: 20px; margin: 10px 0 30px; background: var(--nn-soft); }
.article-cover img { width: 100%; display: block; }
.article-content { font-size: 17px; line-height: 2.15; }
.article-content h2, .article-content h3, .article-content h4 { line-height: 1.65; margin-top: 1.8em; }
.article-content a { color: var(--nn-accent); text-decoration: underline; text-underline-offset: 3px; }
.article-content blockquote { margin: 25px 0; padding: 18px 22px; background: var(--nn-soft); border-right: 4px solid var(--nn-accent); border-radius: 10px; }
.article-content figure { margin: 28px 0; }
.article-content img { border-radius: 12px; }
.article-content table { width: 100%; border-collapse: collapse; }
.article-content th, .article-content td { border: 1px solid var(--nn-line); padding: 10px; }
.post-tags { margin: 28px 0; display: flex; flex-wrap: wrap; gap: 8px; }
.post-tags a { background: var(--nn-soft); padding: 5px 11px; border-radius: 8px; font-size: 13px; }
.author-box { display: grid; grid-template-columns: 78px 1fr; gap: 18px; padding: 22px; border: 1px solid var(--nn-line); border-radius: var(--nn-radius); margin: 28px 0; }
.author-box img { border-radius: 50%; }
.author-name { margin: 0 0 5px; font-size: 18px; }
.comments-area { margin: 38px 0; }

/* Empty */
.empty-state { text-align: center; padding: 65px 25px; border: 1px dashed #ccd0d8; border-radius: var(--nn-radius); background: var(--nn-soft); }
.empty-state h2 { margin-top: 0; }

/* Footer */
.site-footer { margin-top: 50px; background: #111319; color: #c6cad2; }
.footer-widgets { display: grid; grid-template-columns: 1.35fr 1fr 1fr 1fr; gap: 35px; padding: 55px 0 40px; }
.site-footer .widget { border: 0; background: transparent; padding: 0; }
.site-footer .widget-title { color: #fff; border-color: #2b2f38; }
.site-footer .widget li + li { border-color: #2b2f38; }
.site-footer a:hover { color: #fff; }
.footer-brand-title { color: #fff; font-size: 26px; font-weight: 950; margin-bottom: 8px; }
.copyright { border-top: 1px solid #292d35; padding: 18px 0; font-size: 13px; }
.copyright-inner { display: flex; justify-content: space-between; gap: 20px; }
.back-to-top { color: #fff; }

/* Responsive */
@media (max-width: 1050px) {
  .content-layout { grid-template-columns: minmax(0,1fr) 285px; gap: 22px; }
  .news-card { grid-template-columns: 250px minmax(0,1fr); }
  .card-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .header-ad { display: none; }
}
@media (max-width: 860px) {
  .brand-row { min-height: 88px; }
  .mobile-menu-toggle { display: inline-flex; }
  .primary-nav { position: absolute; right: 16px; left: 16px; top: calc(100% + 1px); display: none; background: #fff; border: 1px solid var(--nn-line); box-shadow: var(--nn-shadow); border-radius: 0 0 14px 14px; padding: 10px; }
  .primary-nav.is-open { display: block; }
  .primary-nav ul { display: block; }
  .primary-nav li { display: block; }
  .primary-nav > div > ul > li > a { padding: 10px 12px; }
  .primary-nav .sub-menu { position: static; box-shadow: none; border: 0; visibility: visible; opacity: 1; transform: none; display: block; padding-right: 15px; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-main { min-height: 410px; }
  .content-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; }
  .footer-widgets { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .container { width: min(calc(100% - 22px), var(--nn-container)); }
  .topbar-links { display: none; }
  .topbar-inner { justify-content: center; }
  .site-description { display: none; }
  .site-title { font-size: 23px; }
  .custom-logo { max-height: 57px; max-width: 210px; }
  .nav-row { min-height: 52px; }
  .breaking-label { padding: 0 11px; font-size: 12px; }
  .breaking-track { padding: 0 10px; font-size: 12px; }
  .home-hero { padding-top: 14px; }
  .hero-main { min-height: 360px; }
  .hero-side { grid-template-columns: 1fr; }
  .hero-small { min-height: 235px; }
  .hero-title { font-size: 24px; }
  .section { padding: 32px 0; }
  .section-head { align-items: center; }
  .section-title { font-size: 21px; }
  .news-card { grid-template-columns: 1fr; }
  .news-card-media { min-height: auto; aspect-ratio: 16/10; }
  .news-card-body { padding: 17px; }
  .news-card-title { font-size: 18px; }
  .news-card-footer { align-items: flex-start; flex-direction: column; }
  .card-grid { grid-template-columns: 1fr; }
  .archive-hero { padding: 28px 0; }
  .article-header { padding-top: 28px; }
  .article-title { font-size: 29px; }
  .article-content { font-size: 16px; }
  .footer-widgets { grid-template-columns: 1fr; gap: 25px; }
  .copyright-inner { flex-direction: column; text-align: center; }
}


.topbar-menu li{list-style:none}.topbar-menu li a{display:inline-flex;align-items:center}.primary-nav > ul > li > a{display:flex;align-items:center;padding:0 17px;font-weight:750}.primary-nav > ul > li.current-menu-item > a,.primary-nav > ul > li.current-menu-ancestor > a{color:var(--nn-accent)}.primary-nav > ul > li.current-menu-item > a::after,.primary-nav > ul > li.current-menu-ancestor > a::after{content:'';position:absolute;right:17px;left:17px;bottom:0;height:3px;background:var(--nn-accent);border-radius:4px 4px 0 0}



/* Typography — Vazirmatn for reading, Estedad for editorial headlines */
h1,
h2,
h3,
h4,
h5,
h6,
.site-title,
.section-title,
.hero-title,
.news-card-title,
.grid-card-title,
.archive-title,
.widget-title,
.sidebar-post-title,
.article-title,
.footer-brand-title,
.category-page-title,
.category-lead-title,
.category-list-heading h2,
.category-news-title,
.category-side-title,
.category-side-post-title,
.category-info-box h2 {
  font-family: var(--nn-font-heading);
  font-feature-settings: 'kern' 1, 'ss01' 1;
  text-rendering: optimizeLegibility;
}

body,
button,
input,
textarea,
select,
.primary-nav,
.topbar,
.entry-meta,
.category-meta,
.category-page-description,
.category-lead-excerpt,
.category-news-excerpt,
.article-content {
  font-family: var(--nn-font-body);
}

.primary-nav a,
.topbar a,
.search-submit,
.category-chip,
.read-more,
.category-primary-button,
.category-news-footer a,
.category-tab {
  font-weight: 700;
}

.article-content,
.category-page-description,
.category-lead-excerpt,
.category-news-excerpt {
  font-weight: 400;
}

/* =========================================================
   Noor News Pro 2.0 — professional category archive
   ========================================================= */
body {
  background: #fff;
  font-family: var(--nn-font-body);
  font-weight: 400;
  letter-spacing: 0;
}

.site-header .brand-row {
  min-height: 98px;
}

.site-header .header-ad {
  min-height: 64px;
  max-width: 680px;
}

.category-masthead {
  position: relative;
  overflow: hidden;
  padding: 34px 0 28px;
  border-bottom: 1px solid var(--nn-line);
  background:
    radial-gradient(circle at 8% 20%, rgba(215, 25, 32, .08), transparent 28%),
    linear-gradient(135deg, #ffffff 0%, #f7f8fa 58%, #f1f3f6 100%);
}

.category-masthead::after {
  content: '';
  position: absolute;
  width: 210px;
  height: 210px;
  left: -85px;
  bottom: -115px;
  border: 32px solid rgba(215, 25, 32, .045);
  border-radius: 50%;
  pointer-events: none;
}

.category-masthead .breadcrumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 19px;
  color: #7b818c;
}

.category-masthead .breadcrumbs a {
  font-weight: 750;
}

.category-masthead-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px;
  align-items: center;
  gap: 36px;
}

.category-heading-copy {
  max-width: 820px;
}

.category-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--nn-accent);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .1px;
}

.category-kicker::before {
  content: '';
  width: 22px;
  height: 3px;
  border-radius: 4px;
  background: var(--nn-accent);
}

.category-page-title {
  margin: 6px 0 8px;
  font-size: clamp(30px, 4.2vw, 48px);
  line-height: 1.35;
  font-weight: 950;
  letter-spacing: -.5px;
}

.category-page-description {
  max-width: 780px;
  margin: 0;
  color: #5f6672;
  font-size: 15px;
  line-height: 2;
}

.category-page-description p {
  margin: 0;
}

.category-count-card {
  min-height: 126px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 18px;
  border: 1px solid rgba(215, 25, 32, .13);
  border-radius: 18px;
  background: rgba(255, 255, 255, .84);
  box-shadow: 0 16px 38px rgba(28, 35, 48, .07);
  text-align: center;
  backdrop-filter: blur(8px);
}

.category-count-card strong {
  color: var(--nn-accent);
  font-size: 34px;
  line-height: 1.15;
  font-weight: 950;
}

.category-count-card span {
  margin-top: 7px;
  color: #676e79;
  font-size: 12px;
  font-weight: 750;
}

.category-tabs {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 25px;
  padding-bottom: 2px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.category-tab {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 40px;
  padding: 7px 13px;
  border: 1px solid #e1e4e9;
  border-radius: 999px;
  background: #fff;
  color: #343944;
  font-size: 13px;
  font-weight: 800;
}

.category-tab small {
  min-width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  padding: 0 6px;
  border-radius: 999px;
  background: #f0f2f5;
  color: #717783;
  font-size: 10px;
}

.category-tab:hover,
.category-tab.is-current {
  border-color: var(--nn-accent);
  background: var(--nn-accent);
  color: #fff;
}

.category-tab:hover small,
.category-tab.is-current small {
  background: rgba(255, 255, 255, .18);
  color: #fff;
}

.category-section {
  padding-top: 34px;
  background: #fff;
}

.category-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 30px;
  align-items: start;
}

.category-main-column {
  min-width: 0;
}

.category-lead-card {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(330px, .92fr);
  min-height: 405px;
  overflow: hidden;
  border: 1px solid var(--nn-line);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(22, 29, 42, .08);
}

.category-lead-media {
  position: relative;
  min-height: 405px;
  overflow: hidden;
  background: #e8ebef;
}

.category-lead-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(13, 17, 24, .03), rgba(13, 17, 24, .22));
  pointer-events: none;
}

.category-lead-media img,
.category-lead-media .image-placeholder {
  width: 100%;
  height: 100%;
}

.category-lead-media img {
  display: block;
  object-fit: cover;
  transition: transform .55s ease;
}

.category-lead-card:hover .category-lead-media img {
  transform: scale(1.035);
}

.category-lead-label {
  position: absolute;
  z-index: 2;
  top: 18px;
  right: 18px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 12px;
  border-radius: 999px;
  background: var(--nn-accent);
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(215, 25, 32, .28);
}

.category-lead-label::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
}

.category-lead-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 34px 32px;
}

.category-lead-title {
  margin: 13px 0 12px;
  font-size: clamp(25px, 3vw, 36px);
  line-height: 1.55;
  font-weight: 950;
  letter-spacing: -.35px;
}

.category-lead-title a:hover {
  color: var(--nn-accent);
}

.category-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
  color: #747b86;
  font-size: 12px;
  font-weight: 650;
}

.category-meta span {
  position: relative;
}

.category-meta span + span::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 4px;
  margin-left: 9px;
  border-radius: 50%;
  background: #c2c6cd;
  vertical-align: middle;
}

.category-lead-excerpt {
  margin: 17px 0 23px;
  color: #555d68;
  font-size: 15px;
  line-height: 2;
}

.category-primary-button {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 44px;
  padding: 8px 18px;
  border-radius: 11px;
  background: var(--nn-accent);
  color: #fff;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(215, 25, 32, .2);
}

.category-primary-button:hover {
  background: var(--nn-accent-dark);
  color: #fff;
  transform: translateY(-1px);
}

.category-list-heading {
  display: flex;
  align-items: end;
  gap: 18px;
  margin: 34px 0 18px;
}

.category-list-heading > div {
  flex: 0 0 auto;
}

.category-list-heading span:first-child {
  color: var(--nn-accent);
  font-size: 11px;
  font-weight: 900;
}

.category-list-heading h2 {
  margin: 1px 0 0;
  font-size: 23px;
  line-height: 1.5;
  font-weight: 950;
}

.category-heading-line {
  flex: 1;
  height: 1px;
  margin-bottom: 10px;
  background: linear-gradient(to left, #e0e3e8, transparent);
}

.category-news-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.category-news-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--nn-line);
  border-radius: 17px;
  background: #fff;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.category-news-card:hover {
  transform: translateY(-4px);
  border-color: transparent;
  box-shadow: 0 15px 36px rgba(21, 29, 43, .09);
}

.category-news-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #e8ebef;
}

.category-news-media::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 58%, rgba(8, 11, 16, .28));
  pointer-events: none;
}

.category-news-media img,
.category-news-media .image-placeholder {
  width: 100%;
  height: 100%;
}

.category-news-media img {
  display: block;
  object-fit: cover;
  transition: transform .48s ease;
}

.category-news-card:hover .category-news-media img {
  transform: scale(1.045);
}

.category-news-badge {
  position: absolute;
  z-index: 2;
  right: 14px;
  bottom: 13px;
  max-width: calc(100% - 28px);
  overflow: hidden;
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .94);
  color: var(--nn-accent);
  font-size: 10px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
  box-shadow: 0 5px 18px rgba(0, 0, 0, .12);
}

.category-news-content {
  padding: 18px 19px 17px;
}

.category-card-meta {
  min-height: 24px;
  font-size: 11px;
}

.category-news-title {
  min-height: 62px;
  margin: 7px 0 8px;
  font-size: 18px;
  line-height: 1.72;
  font-weight: 950;
}

.category-news-title a:hover {
  color: var(--nn-accent);
}

.category-news-excerpt {
  min-height: 59px;
  margin: 0;
  color: #59616c;
  font-size: 13px;
  line-height: 2;
}

.category-news-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 15px;
  padding-top: 13px;
  border-top: 1px solid #eceef2;
  color: #818793;
  font-size: 11px;
  font-weight: 700;
}

.category-news-footer a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--nn-accent);
  font-size: 12px;
  font-weight: 900;
}

.category-sidebar {
  position: sticky;
  top: 20px;
  display: grid;
  gap: 19px;
}

.category-side-widget {
  overflow: hidden;
  padding: 19px;
  border: 1px solid var(--nn-line);
  border-radius: 16px;
  background: #fff;
}

.category-side-title {
  position: relative;
  margin: 0 0 15px;
  padding-right: 13px;
  font-size: 17px;
  line-height: 1.6;
  font-weight: 950;
}

.category-side-title::before {
  content: '';
  position: absolute;
  top: 5px;
  right: 0;
  width: 4px;
  height: 18px;
  border-radius: 5px;
  background: var(--nn-accent);
}

.category-side-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 15px;
}

.category-side-head .category-side-title {
  margin-bottom: 0;
}

.category-side-head > span {
  padding: 4px 8px;
  border-radius: 7px;
  background: #fff0f1;
  color: var(--nn-accent);
  font-size: 9px;
  font-weight: 900;
}

.category-search-widget .search-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 9px;
}

.category-search-widget .search-field {
  min-height: 44px;
  background: #fafbfc;
}

.category-search-widget .search-submit {
  min-height: 42px;
}

.category-side-posts {
  display: grid;
  gap: 13px;
}

.category-side-post {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
}

.category-side-post + .category-side-post {
  padding-top: 13px;
  border-top: 1px dashed #e3e6eb;
}

.category-side-thumb {
  position: relative;
  display: block;
  aspect-ratio: 1.18;
  overflow: hidden;
  border-radius: 10px;
  background: #eceff3;
}

.category-side-thumb img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.category-side-placeholder {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #242832, #4a5160);
  color: #fff;
  font-size: 24px;
  font-weight: 950;
}

.category-side-post-title {
  margin: 0 0 5px;
  font-size: 12px;
  line-height: 1.75;
  font-weight: 900;
}

.category-side-post time {
  color: #858b95;
  font-size: 10px;
}

.category-side-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.category-side-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #8a909a;
  font-size: 11px;
}

.category-side-list li + li {
  border-top: 1px dashed #e3e6eb;
}

.category-side-list a {
  flex: 1;
  display: flex;
  align-items: center;
  min-height: 42px;
  color: #343944;
  font-size: 12px;
  font-weight: 800;
}

.category-side-list a::before {
  content: '';
  width: 6px;
  height: 6px;
  margin-left: 9px;
  border: 2px solid #d5d9e0;
  border-radius: 50%;
}

.category-side-list a:hover::before,
.category-side-list .current-cat > a::before {
  border-color: var(--nn-accent);
  background: var(--nn-accent);
}

.category-info-box {
  position: relative;
  overflow: hidden;
  border: 0;
  background: linear-gradient(145deg, #1c2029, #2b313d);
  color: #fff;
}

.category-info-box::after {
  content: 'N';
  position: absolute;
  left: -10px;
  bottom: -54px;
  color: rgba(255, 255, 255, .04);
  font-size: 150px;
  line-height: 1;
  font-weight: 950;
}

.category-info-label {
  position: relative;
  z-index: 1;
  color: #ff777c;
  font-size: 10px;
  font-weight: 900;
}

.category-info-box h2 {
  position: relative;
  z-index: 1;
  margin: 7px 0 9px;
  font-size: 20px;
  line-height: 1.7;
  font-weight: 950;
}

.category-info-box p {
  position: relative;
  z-index: 1;
  margin: 0;
  color: #c8cdd6;
  font-size: 12px;
  line-height: 2;
}

.category-main-column .pagination {
  margin-top: 28px;
}

@media (max-width: 1080px) {
  .category-layout {
    grid-template-columns: minmax(0, 1fr) 285px;
    gap: 22px;
  }

  .category-lead-card {
    grid-template-columns: minmax(0, 1fr) minmax(300px, .88fr);
  }

  .category-lead-content {
    padding: 28px 25px;
  }
}

@media (max-width: 900px) {
  .category-layout {
    grid-template-columns: 1fr;
  }

  .category-sidebar {
    position: static;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }

  .category-search-widget,
  .category-info-box {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  .category-masthead {
    padding: 27px 0 23px;
  }

  .category-masthead-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .category-count-card {
    min-height: auto;
    flex-direction: row;
    justify-content: flex-start;
    gap: 10px;
    padding: 12px 15px;
    text-align: right;
  }

  .category-count-card strong {
    font-size: 25px;
  }

  .category-count-card span {
    margin: 0;
  }

  .category-lead-card {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .category-lead-media {
    min-height: 0;
    aspect-ratio: 16 / 10;
  }

  .category-lead-content {
    padding: 23px 21px;
  }

  .category-lead-title {
    font-size: 25px;
  }
}

@media (max-width: 620px) {
  .category-section {
    padding-top: 25px;
  }

  .category-page-title {
    font-size: 31px;
  }

  .category-page-description {
    font-size: 13px;
  }

  .category-news-grid,
  .category-sidebar {
    grid-template-columns: 1fr;
  }

  .category-search-widget,
  .category-info-box {
    grid-column: auto;
  }

  .category-news-title {
    min-height: 0;
  }

  .category-news-excerpt {
    min-height: 0;
  }

  .category-list-heading {
    margin-top: 27px;
  }

  .category-list-heading h2 {
    font-size: 20px;
  }

  .category-meta {
    gap: 6px 11px;
  }

  .category-meta span + span::before {
    margin-left: 6px;
  }
}
