/*
 * Forum (IP.Board 2.x, skin set 4 "runet") and blogs (IP.Blog 1.4) in the portal look, Nov 2026.
 * Loaded after css_4.css / blog_css.css and the portal's layout.css (page sheet, header, menu band, footer, Inter font,
 * colour tokens --nm-*), so it only has to restyle the IPB parts. Rules are scoped with #nmpage to win over the
 * older skin files (blog_css.css is imported again inside the page body on the blog list).
 * Icons: original line icons drawn for the site (forum/style_images/nm, forum/style_forumicons/nm; source icons.py).
 * Design rules of the site: square corners, no all-caps captions, no serif fonts.
 */

/* ---------- page ---------- */

body.nmf {
	margin: 0;
}

#nmpage {
	--nmf-row: #fbfcfe;
	--nmf-hover: #f5f8fc;
	--nmf-text: 13px;
	font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
}

/* the old skin left <br />s between blocks; spacing comes from margins now */
#nmpage #ipbwrapper > table > tbody > tr > td > br,
#nmpage #ipbwrapper > br,
#nmpage #main_column > br {
	display: none;
}

#nmpage a:link,
#nmpage a:visited {
	color: var(--nm-accent);
}

#nmpage a:hover {
	color: var(--nm-accent-dk);
}

#nmpage img {
	vertical-align: middle;
}

/* the menu band keeps the portal's white links (layout.css; the link colour above would otherwise win) */
#nmpage a.mainlevel-nav:link,
#nmpage a.mainlevel-nav:visited,
#nmpage a.mainlevel-nav:hover {
	color: #fff;
}

/* links inside lists: no underline until hovered */
#nmpage table.ipbtable td a,
#nmpage .lastaction a,
#nmpage .forumdesc a {
	text-decoration: none;
}

#nmpage table.ipbtable td a:hover,
#nmpage .lastaction a:hover,
#nmpage .forumdesc a:hover {
	text-decoration: underline;
}

/* default avatars: the site's own square picture instead of IPB's glossy bust */
#nmpage img[src$="style_avatars/noavatar.png"],
#nmpage img[src$="folder_profile_portal/pp-blank-thumb.png"] {
	content: url(/forum/style_images/nm/avatar.svg);
}

#nmpage .sig_thumbc,
#nmpage .sig_thumb {
	display: inline-block;
	margin: 0;
	background: none !important;
}

#nmpage .sig_thumbc img,
#nmpage .sig_thumb img {
	margin: 0;
	padding: 0;
	box-shadow: none;
}

/* ---------- welcome band: no second login form (the header has it, as on the portal) ---------- */

#nmpage table.newslink form[action*="act=Login"] {
	display: none;
}

/* ---------- breadcrumbs ---------- */

#nmpage #navstrip {
	display: block;
	height: auto;
	margin: 0 0 14px;
	padding: 0;
	color: var(--nm-muted);
	font-size: 13px;
	line-height: 1.5;
}

#nmpage #navstrip a {
	font-weight: normal;
	text-decoration: none;
}

#nmpage #navstrip a:hover {
	text-decoration: underline;
}

#nmpage #navstrip a:last-child {
	color: var(--nm-ink);
	font-weight: bold;
}

#nmpage #ipbwrapper > table:first-child,
#nmpage #ipbwrapper > table:first-child td {
	padding: 0;
	border: 0;
}

/* ---------- welcome / search band above the forum list ---------- */

#nmpage table.newslink {
	margin: 0 0 18px;
	border: 1px solid var(--nm-line);
	background: var(--nm-soft);
	border-collapse: collapse;
}

#nmpage table.newslink td {
	padding: 9px 14px;
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage table.newslink td b {
	font-weight: normal;
	color: var(--nm-ink);
}

#nmpage table.newslink span {
	color: var(--nm-ink);
	font-style: normal;
	font-weight: bold;
}

/* ---------- form fields and buttons (square, roomy) ---------- */

#nmpage input[type="text"],
#nmpage input[type="password"],
#nmpage input:not([type]),
#nmpage select,
#nmpage textarea {
	box-sizing: border-box;
	padding: 5px 8px;
	border: 1px solid #c3cedb;
	border-radius: 0;
	background: #fff;
	color: var(--nm-ink);
	font: 13px/1.4 Verdana, Geneva, Arial, sans-serif;
}

#nmpage input[type="text"]:focus,
#nmpage input[type="password"]:focus,
#nmpage select:focus,
#nmpage textarea:focus {
	border-color: var(--nm-accent);
	outline: 2px solid rgba(56, 92, 136, .18);
	outline-offset: 0;
}

#nmpage input.button,
#nmpage input[type="submit"],
#nmpage input[type="button"],
#nmpage button {
	padding: 5px 14px;
	border: 1px solid var(--nm-accent-dk);
	border-radius: 0;
	background: var(--nm-accent);
	color: #fff;
	font: 600 13px/1.4 var(--nm-head);
	cursor: pointer;
}

#nmpage input.button:hover,
#nmpage input[type="submit"]:hover,
#nmpage input[type="button"]:hover,
#nmpage button:hover {
	background: var(--nm-accent-dk);
}

/* image buttons (search, quick login): the arrow icon in an accent square */
#nmpage input[type="image"] {
	box-sizing: content-box;
	width: 16px;
	height: 16px;
	padding: 6px;
	border: 1px solid var(--nm-accent-dk);
	background: var(--nm-accent);
	filter: none;
	vertical-align: middle;
}

#nmpage input[type="image"][src$="arrow-right.svg"] {
	background: #fff;
	border-color: #c3cedb;
}

#nmpage input[type="image"][src$="arrow-right.svg"]:hover {
	border-color: var(--nm-accent);
}

/* ---------- blocks: a white frame with a title bar like the portal's sidebar blocks ---------- */

#nmpage .borderwrap {
	margin: 0 0 18px;
	padding: 0;
	border: 1px solid var(--nm-line);
	background: #fff;
}

#nmpage .maintitle,
#nmpage .maintitlecollapse,
#nmpage .borderwrap h3 {
	display: flow-root;
	height: auto;
	margin: 0;
	padding: 9px 14px 8px;
	border-bottom: 2px solid var(--nm-accent);
	background: var(--nm-soft);
	color: var(--nm-ink);
	font: bold 16px/1.35 var(--nm-head);
	text-align: left;
}

#nmpage .maintitlecollapse {
	border-bottom: 0;
}

/* the title is a <p> inside the bar; the old skin's paragraph rules must not shrink it */
#nmpage .borderwrap .maintitle p,
#nmpage .borderwrap .maintitlecollapse p {
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	font: inherit;
}

#nmpage .maintitle a:link,
#nmpage .maintitle a:visited,
#nmpage .maintitlecollapse a:link,
#nmpage .maintitlecollapse a:visited {
	color: var(--nm-ink);
	font: inherit;
	text-decoration: none;
}

#nmpage .maintitle a:hover,
#nmpage .maintitlecollapse a:hover {
	color: var(--nm-accent);
	text-decoration: underline;
}

#nmpage .maintitle table,
#nmpage .maintitle td {
	padding: 0;
	border: 0;
	font: inherit;
}

/* collapse / expand toggle on the right of a category */
#nmpage .maintitle p.expand,
#nmpage .maintitlecollapse p.expand {
	margin-left: 10px !important;
	line-height: 1;
}

#nmpage .maintitle p.expand a,
#nmpage .maintitlecollapse p.expand a {
	display: inline-block;
	padding: 3px;
	opacity: .6;
}

#nmpage .maintitle p.expand a:hover,
#nmpage .maintitlecollapse p.expand a:hover {
	opacity: 1;
	text-decoration: none;
}

/* menu buttons in a title bar ("Налаштування форуму") */
#nmpage .popmenubutton,
#nmpage .popmenubutton-new,
#nmpage .popmenubutton-new-out {
	width: auto;
	height: auto;
	margin: 0;
	padding: 3px 8px;
	border: 1px solid var(--nm-line);
	border-radius: 0;
	background: #fff;
	font: normal 12px/1.4 Verdana, Geneva, Arial, sans-serif;
	white-space: nowrap;
}

#nmpage .popmenubutton a,
#nmpage .popmenubutton-new a,
#nmpage .popmenubutton-new-out a {
	color: var(--nm-accent);
	font: inherit;
	text-decoration: none;
}

#nmpage .popmenubutton img,
#nmpage .pagelink img {
	width: 12px;
	height: 12px;
}

/* inside the post header the member name is a plain line, not a box */
#nmpage .normalname .popmenubutton-new,
#nmpage td > .popmenubutton-new-out,
#nmpage td > .popmenubutton-new {
	padding: 0;
	border: 0;
	background: none;
}

/* drop-down menus */
#nmpage .popupmenu,
#nmpage .popupmenu-new,
#nmpage .popupmenu-item,
#nmpage .popupmenu-item-last,
.popupmenu,
.popupmenu-new {
	border-radius: 0;
}

.popupmenu,
.popupmenu-new {
	border: 1px solid var(--nm-line, #dfe5ec) !important;
	background: #fff !important;
	box-shadow: 0 8px 24px rgba(15, 23, 42, .14);
	font: 13px/1.5 Verdana, Geneva, Arial, sans-serif;
}

.popupmenu-category {
	padding: 6px 10px !important;
	background: var(--nm-soft, #f3f6fa) !important;
	color: var(--nm-ink, #1e293b) !important;
	font: bold 12px/1.4 Verdana, Geneva, Arial, sans-serif !important;
}

.popupmenu-item,
.popupmenu-item-last {
	padding: 6px 10px !important;
	border-bottom: 1px solid var(--nm-line, #dfe5ec);
}

/* ---------- tables: forum list, topic list, stats ---------- */

#nmpage table.ipbtable {
	width: 100%;
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	border-collapse: collapse;
	border-spacing: 0;
}

#nmpage .borderwrap > table.ipbtable + table.ipbtable {
	border-top: 1px solid var(--nm-line);
}

#nmpage table.ipbtable th {
	padding: 7px 10px;
	border-bottom: 1px solid var(--nm-line);
	background: #fff;
	color: var(--nm-muted);
	font: normal 12px/1.4 Verdana, Geneva, Arial, sans-serif;
	letter-spacing: 0;
	text-transform: none;
}

#nmpage table.ipbtable th a:link,
#nmpage table.ipbtable th a:visited {
	color: var(--nm-accent);
	font: inherit;
	letter-spacing: 0;
}

#nmpage table.ipbtable td.row1,
#nmpage table.ipbtable td.row2,
#nmpage table.ipbtable td.row3,
#nmpage table.ipbtable td.row4 {
	padding: 11px 10px;
	border-top: 1px solid var(--nm-line);
	background: #fff;
	font-size: var(--nmf-text);
	line-height: 1.5;
	vertical-align: middle;
}

#nmpage table.ipbtable tr:hover > td.row1,
#nmpage table.ipbtable tr:hover > td.row2 {
	background: var(--nmf-hover);
}

#nmpage table.ipbtable td.formsubtitle {
	padding: 8px 10px 6px;
	border-top: 1px solid var(--nm-line);
	background: var(--nmf-row);
	color: var(--nm-ink);
	font: bold 13px/1.4 var(--nm-head);
}

#nmpage td.darkrow1,
#nmpage td.darkrow2,
#nmpage td.darkrow3,
#nmpage .subtitle,
#nmpage .subtitlediv {
	padding: 7px 10px;
	background: var(--nmf-row);
	color: var(--nm-muted);
	font: normal 12px/1.4 Verdana, Geneva, Arial, sans-serif;
	letter-spacing: 0;
}

#nmpage .subtitlediv a,
#nmpage .subtitle a {
	color: var(--nm-accent) !important;
	font: inherit !important;
	letter-spacing: 0 !important;
}

/* ---------- forum list ---------- */

/* the forum's own icon: a square tile, filled when there are new posts */
#nmpage .nmfi {
	display: inline-flex;
	width: 40px;
	height: 40px;
	align-items: center;
	justify-content: center;
	background: #e9eff6;
	color: var(--nm-accent);
	vertical-align: middle;
}

#nmpage .nmfi svg {
	width: 24px;
	height: 24px;
}

#nmpage .nmfi-on {
	background: var(--nm-accent);
	color: #fff;
}

#nmpage td:has(> .nmfi),
#nmpage td:has(> img[src*="/nm/f-"]) {
	width: 40px;
	padding-right: 4px !important;
	text-align: center;
}

/* forum name and description */
#nmpage td:has(> .nmfi) + td > b > a,
#nmpage td:has(> img[src*="/nm/f-"]) + td > b > a {
	color: var(--nm-ink);
	font: 600 15px/1.35 var(--nm-head);
	text-decoration: none;
}

#nmpage td:has(> .nmfi) + td > b > a:hover,
#nmpage td:has(> img[src*="/nm/f-"]) + td > b > a:hover {
	color: var(--nm-accent);
	text-decoration: underline;
}

#nmpage td:has(> .nmfi) + td > br:first-of-type {
	display: none;
}

#nmpage .forumdesc {
	display: block;
	margin-top: 2px;
	color: var(--nm-muted);
	font-size: 12px;
	line-height: 1.5;
}

#nmpage .forumdesc b {
	color: var(--nm-ink);
	font-weight: normal;
}

/* topic and reply counts */
#nmpage table.ipbtable:has(.nmfi) td.row1[align="center"],
#nmpage table.ipbtable:has(img[src*="/nm/f-"]) td.row1[align="center"] {
	color: var(--nm-ink);
	font: 600 14px/1.3 var(--nm-head);
}

/* last post: date, author and topic in two quiet lines */
#nmpage table.ipbtable:has(.nmfi) td:last-child,
#nmpage table.ipbtable:has(img[src*="/nm/f-"]) td:last-child {
	color: var(--nm-muted);
	font-size: 12px;
	line-height: 1.55;
}

#nmpage table.ipbtable:has(.nmfi) td:last-child > a:first-child img,
#nmpage table.ipbtable:has(img[src*="/nm/f-"]) td:last-child > a:first-child img {
	opacity: .7;
}

/* ---------- topic list ---------- */

#nmpage td[id^="tid-folder"] {
	width: 28px;
	padding-right: 2px !important;
	cursor: default;
}

#nmpage td[id^="tid-folder"] img {
	display: block;
	width: 28px;
	height: 28px;
}

/* the topic's own small picture (?, !, smileys) only when it has one */
#nmpage td[id^="tid-folder"] + td {
	width: 18px;
	padding-left: 4px !important;
	padding-right: 0 !important;
}

#nmpage a[id^="tid-link-"] {
	color: var(--nm-ink);
	font: 600 14px/1.4 var(--nm-head);
	text-decoration: none;
}

#nmpage a[id^="tid-link-"]:visited {
	color: #475569;
}

#nmpage a[id^="tid-link-"]:hover {
	color: var(--nm-accent);
	text-decoration: underline;
}

#nmpage table.ipbtable .desc,
#nmpage table.ipbtable .desc span {
	color: var(--nm-muted);
	font-size: 12px;
	line-height: 1.5;
}

#nmpage .lastaction {
	color: var(--nm-muted);
	font-size: 12px;
	line-height: 1.55;
}

#nmpage .lastaction b a {
	font-weight: normal;
}

/* pinned and announcement rows stand out a little */
#nmpage table.ipbtable tr:has(img[src*="t-pinned"]) > td {
	background: #fffaf3;
}

/* ---------- paging and the action links above lists ---------- */

#nmpage .pagelink,
#nmpage .pagelinklast,
#nmpage .pagecurrent {
	display: inline-block;
	min-width: 14px;
	margin: 0 0 4px;
	padding: 4px 9px;
	border: 1px solid var(--nm-line);
	background: #fff;
	color: var(--nm-muted);
	font: 13px/1.4 Verdana, Geneva, Arial, sans-serif;
	text-align: center;
}

#nmpage .pagelink a,
#nmpage .pagelinklast a {
	text-decoration: none;
}

#nmpage .pagecurrent {
	border-color: var(--nm-accent);
	background: var(--nm-accent);
	color: #fff;
	font-weight: bold;
}

#nmpage .pagelink:has(> a):hover,
#nmpage .pagelinklast:has(> a):hover {
	border-color: var(--nm-accent);
}

/* first .pagelink is "N Сторінки ▾" (jump menu) */
#nmpage span[id^="page-jump"] {
	cursor: pointer;
	color: var(--nm-ink);
}

#nmpage .minipagelink,
#nmpage .minipagelinklast {
	display: inline-block;
	margin: 0 1px;
	padding: 0 4px;
	border: 1px solid var(--nm-line);
	background: #fff;
	font-size: 11px;
	line-height: 1.5;
}

/* the tables above and below a list: paging on the left, actions on the right */
#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) {
	margin: 0 0 10px;
}

#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) > tbody > tr > td {
	padding: 0 0 4px !important;
	vertical-align: bottom;
}

/* "Створити нову тему", "Відповісти": the main actions are buttons */
#nmpage a[href*="do=new_post"],
#nmpage a[href*="do=reply_post"],
#nmpage a[href*="act=post&amp;do=new_post"] {
	display: inline-block;
	margin: 0 0 0 6px;
	padding: 7px 14px 7px 12px;
	border: 1px solid var(--nm-accent-dk);
	background: var(--nm-accent);
	color: #fff !important;
	font: 600 13px/1.3 var(--nm-head) !important;
	text-decoration: none;
	white-space: nowrap;
}

#nmpage a[href*="do=new_post"]:hover,
#nmpage a[href*="do=reply_post"]:hover {
	background: var(--nm-accent-dk);
}

#nmpage a[href*="do=reply_post"] ~ a[href*="do=new_post"] {
	border-color: var(--nm-line);
	background: #fff;
	color: var(--nm-accent) !important;
}

#nmpage a[href*="do=reply_post"] ~ a[href*="do=new_post"]:hover {
	border-color: var(--nm-accent);
	background: #fff;
}

#nmpage a[href*="do=new_post"] img,
#nmpage a[href*="do=reply_post"] img {
	width: 16px;
	height: 16px;
	margin: -2px 6px 0 0;
	filter: brightness(0) invert(1);
}

#nmpage a[href*="do=reply_post"] ~ a[href*="do=new_post"] img {
	filter: none;
}

#nmpage .toplinks {
	margin: 0 0 8px;
	text-align: right;
	font-size: 12px;
}

#nmpage .toplinks span {
	color: var(--nm-muted);
}

/* ---------- topic: posts ---------- */

#nmpage table.ipbtable:has(.postcolor) {
	margin: 0 0 16px;
	border: 1px solid var(--nm-line);
	background: #fff;
	table-layout: auto;
}

/* posts sit inside the topic's frame: no frame of their own, a soft band between them */
#nmpage .borderwrap table.ipbtable:has(.postcolor) {
	margin: 0;
	border: 0;
	border-top: 10px solid var(--nm-soft);
}

#nmpage .borderwrap .maintitle + table.ipbtable:has(.postcolor),
#nmpage .borderwrap .maintitle + * + table.ipbtable:has(.postcolor) {
	border-top: 0;
}

/* head row: author on the left, date and number on the right */
#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td {
	padding: 8px 12px;
	border: 0;
	border-bottom: 1px solid var(--nm-line);
	background: var(--nm-soft);
}

#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child:hover > td {
	background: var(--nm-soft);
}

#nmpage .normalname,
#nmpage .normalname a:link,
#nmpage .normalname a:visited {
	color: var(--nm-ink);
	font: 600 14px/1.3 var(--nm-head);
	text-decoration: none;
}

#nmpage .normalname img {
	width: 16px;
	height: 16px;
	margin: -2px 5px 0 0;
}

#nmpage .postdetails {
	color: var(--nm-muted);
	font: 12px/1.6 Verdana, Geneva, Arial, sans-serif;
}

#nmpage .postdetails img[src*="clock.svg"] {
	width: 14px;
	height: 14px;
	margin: -2px 4px 0 0;
	padding: 0 !important;
}

#nmpage .postdetails a:link,
#nmpage .postdetails a:visited {
	font-size: 12px;
}

/* author column */
#nmpage td.post1,
#nmpage td.post2 {
	padding: 14px 12px;
	background: #fff;
	vertical-align: top;
}

#nmpage td.post1:first-child,
#nmpage td.post2:first-child {
	width: 150px;
	border-right: 1px solid var(--nm-line);
	background: var(--nmf-row);
}

#nmpage td.post1:first-child > img[width="160"],
#nmpage td.post2:first-child > img[width="160"] {
	width: 150px;
}

#nmpage td.post1:first-child .postdetails,
#nmpage td.post2:first-child .postdetails {
	display: block;
	font-size: 11px;
	line-height: 1.6;
}

#nmpage a.sig_thumbc img,
#nmpage td.post1:first-child img[src*="style_avatars"],
#nmpage td.post2:first-child img[src*="style_avatars"] {
	display: block;
	max-width: 100px;
	height: auto;
	margin: 0 auto 8px;
	border: 1px solid var(--nm-line);
	background: #fff;
}

/* the post itself: a calm reading size */
#nmpage .postcolor {
	color: var(--nm-ink);
	font: 14px/1.7 Verdana, Geneva, Arial, sans-serif;
	overflow-wrap: break-word;
}

#nmpage .postcolor img {
	max-width: 100%;
	height: auto;
}

#nmpage .signature {
	margin-top: 12px;
	padding-top: 8px;
	border-top: 1px solid var(--nm-line);
	color: var(--nm-muted);
	font-size: 11px;
}

#nmpage .edit {
	margin-top: 10px;
	color: var(--nm-muted);
	font-size: 11px;
}

/* bottom row: Догори on the left, Цитата / Відповісти on the right, as quiet links with icons */
#nmpage td.formbuttonrow {
	padding: 7px 12px !important;
	border: 0 !important;
	border-top: 1px solid var(--nm-line) !important;
	background: #fff !important;
	font-size: 12px;
}

#nmpage td.formbuttonrow a:link,
#nmpage td.formbuttonrow a:visited {
	display: inline-block;
	padding: 2px 4px;
	color: var(--nm-accent);
	font-size: 12px;
	text-decoration: none;
}

#nmpage td.formbuttonrow a:hover {
	background: var(--nm-soft);
}

#nmpage td.formbuttonrow img {
	width: 16px;
	height: 16px;
	margin: -2px 4px 0 0;
}

/* quotes and code */
#nmpage .quotetop,
#nmpage .codetop,
#nmpage .sqltop,
#nmpage .htmltop {
	margin: 10px 0 0;
	padding: 6px 12px 2px;
	border: 0;
	border-left: 3px solid var(--nm-accent);
	background: var(--nm-soft);
	color: var(--nm-muted);
	font: bold 11px/1.4 Verdana, Geneva, Arial, sans-serif;
}

#nmpage .quotemain {
	margin: 0 0 10px;
	padding: 4px 12px 10px;
	border: 0;
	border-left: 3px solid var(--nm-accent);
	background: var(--nm-soft);
	color: #334155;
}

#nmpage .codemain,
#nmpage .sqlmain,
#nmpage .htmlmain {
	margin: 0 0 10px;
	padding: 8px 12px;
	border: 0;
	border-left: 3px solid #94a3b8;
	background: #f6f8fb;
	color: #1e293b;
	font: 12px/1.6 Consolas, "Courier New", monospace;
	overflow-x: auto;
}

/* the line under the posts: search in topic, previous / next topic */
#nmpage .borderwrap ~ table.ipbtable:not(:has(.postcolor)) {
	margin-bottom: 14px;
}

/* attachments */
#nmpage img.attach,
#nmpage .thumbwrap,
#nmpage .fullimagewrap {
	border-color: var(--nm-line);
	background-color: #fff;
}

/* ---------- board statistics, online list ---------- */

#nmpage td.row1[align="center"] > img[src*="/nm/"] {
	width: 20px;
	height: 20px;
	opacity: .85;
}

#nmpage .thin {
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage .formsubtitle {
	padding: 6px 14px;
	font-size: 12px;
}

#nmpage .formsubtitle p.members {
	color: var(--nm-muted);
}

/* ---------- forms, messages, the user's own pages ---------- */

#nmpage .formtable td,
#nmpage .pformleft,
#nmpage .pformleftw,
#nmpage .pformright,
#nmpage .formtable td.formstrip {
	padding: 9px 12px;
	border-color: var(--nm-line);
	font-size: 13px;
}

#nmpage td.pformstrip,
#nmpage .pformstrip,
#nmpage .borderwrap h4,
#nmpage .errorwrap h4,
#nmpage .fieldwrap h4 {
	padding: 8px 12px;
	border-color: var(--nm-line);
	background: var(--nm-soft);
	color: var(--nm-ink);
	font: bold 13px/1.4 var(--nm-head);
}

#nmpage .borderwrap p {
	margin: 10px 12px;
	padding: 10px 12px;
	border: 1px solid var(--nm-line);
	font-size: 13px;
}

#nmpage .borderwrap p.formbuttonrow,
#nmpage .borderwrap p.formbuttonrow1 {
	margin: 0 !important;
	padding: 10px 12px !important;
	border: 0;
	border-top: 1px solid var(--nm-line);
	text-align: center;
}

#nmpage .errorwrap {
	margin: 10px 12px;
	border-color: var(--nm-line);
	background: #fff;
}

#nmpage .errorwrap p {
	padding: 10px 12px;
	font-size: 13px;
}

#nmpage .ruleswrap {
	padding: 10px 12px;
	border-color: var(--nm-line);
	border-left: 3px solid var(--nm-accent);
}

#nmpage #ucpmenu,
#nmpage #ucpcontent {
	border-color: var(--nm-line);
}

/* ---------- footer line of the forum (RSS, text version, time) ---------- */

#nmpage #gfooter {
	margin: 6px 0 0;
	border-top: 1px solid var(--nm-line);
}

#nmpage #gfooter td {
	padding: 10px 0 0;
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage #gfooter a:link,
#nmpage #gfooter a:visited {
	color: var(--nm-accent);
	font-weight: normal;
}

#nmpage #gfooter a b {
	font-weight: normal;
}

#nmpage img#rss-syndication {
	width: 18px;
	height: 18px;
	padding: 4px;
	border: 1px solid var(--nm-line);
	background: #fff;
	cursor: pointer;
}

/* ================================================================= blogs ========== */

/* blog page: the font and colours of the rest of the site instead of the blog's own blue bars */
#nmpage #main_blog_wrapper,
#nmpage .blog_wrapper {
	color: var(--nm-ink);
	font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
}

#nmpage #main_blog_wrapper a,
#nmpage .blog_wrapper a {
	color: var(--nm-accent);
}

#nmpage #main_blog_wrapper a:hover,
#nmpage .blog_wrapper a:hover {
	color: var(--nm-accent-dk);
}

#nmpage #main_column_wrap {
	max-width: 52rem;
	padding-top: 6px;
}

/* the rating chip next to the breadcrumbs */
#nmpage #blog-rating {
	padding: 4px 10px;
	color: var(--nm-muted);
	font-size: 12px;
}

/* entries */
#nmpage .entry_wrap {
	margin: 0 0 22px;
	border: 1px solid var(--nm-line);
	background: #fff;
}

#nmpage .entry_wrap h2 {
	margin: 0;
	padding: 16px 20px 4px;
	background: #fff;
	color: var(--nm-ink);
	font: bold 22px/1.3 var(--nm-head);
}

#nmpage .entry_wrap h2 a,
#nmpage #main_blog_wrapper .entry_wrap h2 a {
	color: var(--nm-ink);
	text-decoration: none;
}

#nmpage .entry_wrap h2 a:hover {
	color: var(--nm-accent);
	text-decoration: underline;
}

#nmpage .entry_wrap .posted_info {
	padding: 0 20px 12px;
	border-bottom: 2px solid var(--nm-accent);
	background: #fff;
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage .entry_wrap .posted_info strong {
	font-weight: normal;
}

#nmpage .entry {
	max-width: 70ch;
	padding: 16px 20px 18px;
	color: var(--nm-ink);
	font: 15px/1.75 Verdana, Geneva, Arial, sans-serif;
}

#nmpage .entry > a[href*="entry"]:last-of-type {
	font-weight: bold;
}

#nmpage .entry_wrap.hidden h2 {
	background: #fff;
	color: #9a4a40;
}

#nmpage .entry_footer {
	display: flow-root;
	padding: 8px 20px;
	border-top: 1px solid var(--nm-line);
	background: var(--nmf-row);
}

#nmpage #main_blog_wrapper .entry_links,
#nmpage .entry_links {
	font-size: 12px;
}

#nmpage .entry_links .comments,
#nmpage .entry_links .trackbacks,
#nmpage .entry_links .send_trackback {
	border-right-color: var(--nm-line);
}

/* share line: e-mail and print keep their icons; Facebook as a word, the dead bookmark services go */
#nmpage .share_links li {
	padding: 0 2px;
}

#nmpage .share_links li.share {
	padding-right: 6px;
	color: var(--nm-muted);
}

#nmpage #main_blog_wrapper .share_links a {
	display: inline-flex;
	min-width: 28px;
	height: 28px;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	padding: 0 6px;
	border: 1px solid var(--nm-line);
	background: #fff;
	vertical-align: middle;
	text-decoration: none;
}

#nmpage #main_blog_wrapper .share_links a:hover {
	border-color: var(--nm-accent);
}

#nmpage .share_links img {
	width: 16px;
	height: 16px;
}

#nmpage .share_links a[href*="del.icio.us"],
#nmpage .share_links a[href*="digg.com"],
#nmpage .share_links a[href*="mixx.com"],
#nmpage .share_links a[href*="stumbleupon.com"],
#nmpage .share_links a[href*="reddit.com"],
#nmpage .share_links a[href*="google.com/bookmarks"],
#nmpage .share_links li:has(> a[href*="del.icio.us"], > a[href*="digg.com"], > a[href*="mixx.com"], > a[href*="stumbleupon.com"], > a[href*="reddit.com"], > a[href*="google.com/bookmarks"]) {
	display: none !important;
}

#nmpage .share_links a[href*="facebook.com"] img {
	display: none;
}

#nmpage .share_links a[href*="facebook.com"]::after {
	content: "Facebook";
	font-size: 12px;
}

/* comments */
#nmpage #main_comment_wrap h3 {
	padding: 8px 14px;
	border: 0;
	border-bottom: 2px solid var(--nm-accent);
	background: var(--nm-soft);
	color: var(--nm-ink);
	font: bold 16px/1.35 var(--nm-head);
}

#nmpage .comment_wrap {
	border-color: var(--nm-line);
}

#nmpage .comment_wrap:nth-of-type(even) {
	background: #fff;
}

#nmpage .comment_wrap h4,
#nmpage .comment_wrap.by_author h4 {
	padding: 7px 12px;
	border-bottom: 1px solid var(--nm-line);
	background: var(--nmf-row);
	color: var(--nm-muted);
	font: normal 12px/1.5 Verdana, Geneva, Arial, sans-serif;
}

#nmpage .comment_wrap.by_author {
	border-left: 3px solid var(--nm-accent);
}

#nmpage .add_comment {
	border-color: var(--nm-line);
	background: var(--nmf-row);
}

/* sidebar blocks: as on the portal (soft title, accent rule) */
#nmpage .cblock {
	margin: 0 0 16px;
	border: 1px solid var(--nm-line);
}

#nmpage .cblock h3 {
	padding: 8px 12px 7px;
	border-bottom: 2px solid var(--nm-accent);
	background: var(--nm-soft);
	color: var(--nm-ink);
	font: bold 14px/1.35 var(--nm-head);
}

#nmpage .cblock h3 a,
#nmpage #main_blog_wrapper .cblock h3 a {
	color: var(--nm-ink);
	text-decoration: none;
}

#nmpage .cblock h3 a:hover {
	color: var(--nm-accent);
}

#nmpage .cblock .cblock_content {
	padding: 10px 12px 12px;
	font-size: 13px;
	line-height: 1.55;
}

/* "Останні записи", links in a block: one per line with a little room */
#nmpage .cblock .cblock_content > a {
	display: inline-block;
	padding: 3px 0;
}

#nmpage .last_comment_row {
	padding: 7px 0;
	border-bottom-color: var(--nm-line);
}

#nmpage .last_comment_row:nth-child(even) {
	background: none;
}

#nmpage .last_comment_row img {
	width: 24px;
	height: auto;
	margin-right: 6px;
	border: 1px solid var(--nm-line);
}

/* the month calendar */
#nmpage .cblock .cblock_content table td.subtitle {
	padding: 4px 0;
	background: none;
	color: var(--nm-muted);
	font-size: 11px;
	text-align: center;
}

#nmpage .cblock .calday {
	padding: 4px 0 !important;
	border: 0;
	background: var(--nmf-row);
	color: #94a3b8;
	font: 12px/1.6 Verdana, Geneva, Arial, sans-serif;
	text-align: center;
}

#nmpage .cblock .calday a {
	display: block;
	margin: -4px 0;
	padding: 4px 0;
	background: var(--nm-soft);
	font-weight: bold;
	text-decoration: none;
}

#nmpage .cblock .mcelltoday .calday {
	box-shadow: inset 0 -2px 0 var(--nm-accent);
	color: var(--nm-ink);
}

#nmpage .cblock .mcellblank {
	background: none;
}

/* ---------- list of blogs / latest entries (forum wrapper, autocom=blog) ---------- */

#nmpage .blog_list .block {
	margin: 0 0 14px;
	padding: 0 0 12px;
	border: 1px solid var(--nm-line);
	background: #fff;
}

#nmpage .blog_list .block.second {
	background: #fff;
}

#nmpage .blog_list .block .header {
	height: auto;
	padding: 14px 16px 4px;
	border: 0;
	background: #fff;
}

#nmpage .blog_list h4 {
	padding: 0;
	font: bold 18px/1.3 var(--nm-head);
}

#nmpage .blog_list h4 a,
#nmpage .blog_list h4 a:link,
#nmpage .blog_list h4 a:visited {
	color: var(--nm-ink);
}

#nmpage .blog_list h4 a:hover {
	color: var(--nm-accent);
	text-decoration: underline !important;
}

#nmpage .blog_list .posted_info {
	padding: 2px 0 0;
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage .blog_list .block .profile_photo {
	margin: 10px 12px 4px 16px;
	padding: 0;
	border: 1px solid var(--nm-line);
}

#nmpage .blog_list .block .profile_photo img {
	display: block;
	width: 44px;
	height: 44px;
	object-fit: cover;
}

#nmpage .blog_list .block p {
	margin: 10px 16px 0;
	color: #334155;
	font-size: 14px;
	line-height: 1.65;
}

#nmpage .blog_list .readmore a {
	font-weight: bold;
}

#nmpage .blog_list .readmore img {
	width: 14px;
	height: 14px;
	margin: -2px 0 0 4px;
}

#nmpage .blog_list .block .stats {
	margin: 12px 16px 0;
	padding-top: 8px;
	border-top: 1px solid var(--nm-line);
	color: var(--nm-muted);
	font-size: 12px;
}

#nmpage .blog_list .block .stats img {
	width: 14px;
	height: 14px;
	margin: -2px 3px 0 6px;
}

#nmpage .blog_list .block .stats strong {
	color: var(--nm-ink);
	font-weight: normal;
}

#nmpage h2.blog_section,
#nmpage h3.blog_section {
	padding: 9px 14px 8px;
	border-bottom: 2px solid var(--nm-accent);
	background: var(--nm-soft);
	color: var(--nm-ink);
	font: bold 16px/1.35 var(--nm-head);
}

#nmpage .featured_wrap {
	border: 1px solid var(--nm-line);
	border-left: 3px solid var(--nm-accent);
	background: #fff;
}

/* ================================================= phones and small tablets (860 px and below) ========== */

@media (max-width: 860px) {
	body.nmf {
		-webkit-text-size-adjust: 100%;
		text-size-adjust: 100%;
		background: #fff;
	}

	#nmpage {
		--nmf-text: 14px;
		border-top-width: 3px;
	}

	/* menu: one line that scrolls sideways (nm_nav.js centres the current item and sets the edge fades) */
	#nmpage .nmnav table,
	#nmpage .nmnav tbody,
	#nmpage .nmnav tr,
	#nmpage .nmnav td {
		display: block;
		width: auto;
	}

	#nmpage .nmnav #mainlevel-nav td {
		position: relative;
		padding: 0 4px;
		overflow-x: auto;
		white-space: nowrap;
		scrollbar-width: none;
		-webkit-overflow-scrolling: touch;
	}

	#nmpage .nmnav #mainlevel-nav td::-webkit-scrollbar {
		display: none;
	}

	#nmpage .nmnav #mainlevel-nav td.nm-more-r {
		-webkit-mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent);
		mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent);
	}

	#nmpage .nmnav #mainlevel-nav td.nm-more-l {
		-webkit-mask-image: linear-gradient(to left, #000 calc(100% - 36px), transparent);
		mask-image: linear-gradient(to left, #000 calc(100% - 36px), transparent);
	}

	#nmpage .nmnav #mainlevel-nav td.nm-more-l.nm-more-r {
		-webkit-mask-image: linear-gradient(to right, transparent, #000 36px, #000 calc(100% - 36px), transparent);
		mask-image: linear-gradient(to right, transparent, #000 36px, #000 calc(100% - 36px), transparent);
	}

	#nmpage a.mainlevel-nav:link,
	#nmpage a.mainlevel-nav:visited {
		padding: 11px 11px;
		color: #fff;
		font-size: 15px;
	}

	#nmpage a#active_menu-nav {
		box-shadow: inset 0 -3px 0 #fff;
		text-decoration: none;
	}

	/* body */
	#nmpage #ipbwrapper {
		margin: 12px 10px 16px;
		overflow-x: hidden;
	}

	#nmpage #ipbwrapper > table,
	#nmpage #ipbwrapper > table > tbody,
	#nmpage #ipbwrapper > table > tbody > tr,
	#nmpage #ipbwrapper > table > tbody > tr > td {
		display: block;
		width: auto;
	}

	#nmpage #navstrip {
		margin-bottom: 10px;
		font-size: 13px;
	}

	/* welcome band: the quick login form goes (Вхід is in the header) */
	#nmpage table.newslink,
	#nmpage table.newslink > tbody,
	#nmpage table.newslink > tbody > tr,
	#nmpage table.newslink > tbody > tr > td {
		display: block;
		width: auto;
		text-align: left;
	}

	#nmpage table.newslink form[action*="act=Login"] {
		display: none;
	}

	#nmpage table.newslink form input[type="text"] {
		width: calc(100% - 36px);
	}

	#nmpage .maintitle,
	#nmpage .maintitlecollapse,
	#nmpage .borderwrap h3 {
		padding: 10px 12px 9px;
		font-size: 16px;
	}

	#nmpage .borderwrap {
		margin-bottom: 16px;
	}

	/* ----- forum list: each forum is a small card: icon | name + description, then counts, then last post ----- */
	#nmpage table.ipbtable:has(.nmfi) > tbody > tr:has(> th),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr:has(> th) {
		display: none;
	}

	#nmpage table.ipbtable:has(.nmfi),
	#nmpage table.ipbtable:has(.nmfi) > tbody,
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody {
		display: block;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr,
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr {
		display: grid;
		grid-template-columns: 40px auto auto 1fr;
		grid-template-areas:
			"icon name name name"
			"icon topics posts ."
			"icon last last last";
		column-gap: 12px;
		padding: 12px;
		border-top: 1px solid var(--nm-line);
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr:nth-child(2),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr:nth-child(2) {
		border-top: 0;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td,
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td {
		display: block;
		width: auto !important;
		padding: 0 !important;
		border: 0;
		background: none !important;
		text-align: left;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(1),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(1) {
		grid-area: icon;
		align-self: start;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(2),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(2) {
		grid-area: name;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(3),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(3) {
		grid-area: topics;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(4),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(4) {
		grid-area: posts;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(5),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(5) {
		grid-area: last;
		margin-top: 2px;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(3),
	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(4),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(3),
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(4) {
		margin-top: 6px;
		color: var(--nm-ink);
		font: 600 13px/1.4 var(--nm-head);
		white-space: nowrap;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(3)::after,
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(3)::after {
		content: " тем";
		color: var(--nm-muted);
		font-weight: normal;
	}

	#nmpage table.ipbtable:has(.nmfi) > tbody > tr > td:nth-child(4)::after,
	#nmpage table.ipbtable:has(img[src*="/nm/f-"]) > tbody > tr > td:nth-child(4)::after {
		content: " відповідей";
		color: var(--nm-muted);
		font-weight: normal;
	}

	#nmpage .forumdesc {
		font-size: 13px;
	}

	/* ----- topic list: icon | title + description, then author · replies · views, then the last post ----- */
	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr:has(> th) {
		display: none;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]),
	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody {
		display: block;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr:has(td[id^="tid-folder"]) {
		display: grid;
		grid-template-columns: 28px auto auto auto 1fr;
		grid-template-areas:
			"icon title title title title"
			"icon author posts views ."
			"icon last last last last";
		column-gap: 10px;
		padding: 11px 12px;
		border-top: 1px solid var(--nm-line);
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td {
		display: block;
		width: auto !important;
		padding: 0 !important;
		border: 0;
		background: none !important;
		text-align: left;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(1) {
		grid-area: icon;
		align-self: start;
		margin-top: 1px;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(2) {
		display: none;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(3) {
		grid-area: title;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(4) {
		grid-area: posts;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(5) {
		grid-area: author;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(6) {
		grid-area: views;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(7) {
		grid-area: last;
		margin-top: 2px;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(n+4):nth-child(-n+6) {
		margin-top: 4px;
		color: var(--nm-muted);
		font-size: 12px;
		white-space: nowrap;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(4)::before {
		content: "відповідей: ";
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) > tbody > tr > td:nth-child(6)::before {
		content: "переглядів: ";
	}

	/* the last post's date and "Останній пост: name" on one line */
	#nmpage table.ipbtable:has(td[id^="tid-folder"]) .lastaction br {
		display: none;
	}

	#nmpage table.ipbtable:has(td[id^="tid-folder"]) .lastaction > a:first-of-type {
		margin-left: 6px;
	}

	#nmpage a[id^="tid-link-"] {
		font-size: 15px;
	}

	/* paging row and actions above lists stack: actions first, full width */
	#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table),
	#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) > tbody,
	#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) > tbody > tr {
		display: block;
	}

	#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) > tbody > tr {
		display: flex;
		flex-wrap: wrap-reverse;
		gap: 8px;
	}

	#nmpage #ipbwrapper td > table.ipbtable:not(.borderwrap table) > tbody > tr > td {
		display: block;
		width: auto !important;
		text-align: left !important;
		white-space: normal !important;
	}

	#nmpage a[href*="do=new_post"],
	#nmpage a[href*="do=reply_post"] {
		margin: 0 6px 4px 0;
		padding: 9px 14px;
		font-size: 14px !important;
	}

	#nmpage .pagelink,
	#nmpage .pagelinklast,
	#nmpage .pagecurrent {
		padding: 7px 11px;
		font-size: 14px;
	}

	/* ----- posts: the author's name and date on top, the text under it at full width ----- */
	#nmpage table.ipbtable:has(.postcolor),
	#nmpage table.ipbtable:has(.postcolor) > tbody {
		display: block;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr {
		display: flex;
		flex-wrap: wrap;
		align-items: center;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr > td {
		display: block;
		box-sizing: border-box;
		width: auto !important;
		white-space: normal !important;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child {
		background: var(--nm-soft);
		border-bottom: 1px solid var(--nm-line);
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td {
		border: 0;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td:first-child {
		flex: 1 1 auto;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td + td {
		flex: 0 1 auto;
		padding-left: 0;
	}

	/* date only; the "#N" number stays as a small link */
	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td + td > div {
		float: none !important;
		display: inline;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td + td > div[align="right"] .postdetails {
		font-size: 0;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:first-child > td + td > div[align="right"] .postdetails a {
		margin-left: 6px;
		font-size: 12px;
	}

	/* the author column (avatar, rank, counts) folds away: name and status are in the head row */
	#nmpage td.post1:first-child,
	#nmpage td.post2:first-child {
		display: none !important;
	}

	#nmpage td.post1:last-child,
	#nmpage td.post2:last-child {
		flex: 1 1 100%;
		padding: 12px;
	}

	#nmpage .postcolor {
		font-size: 15px;
		line-height: 1.7;
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:last-child {
		border-top: 1px solid var(--nm-line);
	}

	#nmpage table.ipbtable:has(.postcolor) > tbody > tr:last-child > td {
		flex: 1 1 auto;
		border: 0 !important;
	}

	#nmpage td.formbuttonrow a:link,
	#nmpage td.formbuttonrow a:visited {
		padding: 6px 6px;
		font-size: 14px;
	}

	/* every other wide table scrolls inside the screen instead of widening the page */
	#nmpage .borderwrap > table.ipbtable:not(:has(.nmfi)):not(:has(td[id^="tid-folder"])):not(:has(.postcolor)) {
		display: block;
		overflow-x: auto;
	}

	#nmpage .postcolor table,
	#nmpage .postcolor pre {
		display: block;
		max-width: 100%;
		overflow-x: auto;
	}

	/* forms: 16 px stops phones from zooming in */
	#nmpage input[type="text"],
	#nmpage input[type="password"],
	#nmpage input:not([type]),
	#nmpage select,
	#nmpage textarea {
		max-width: 100%;
		min-height: 38px;
		font-size: 16px;
	}

	#nmpage textarea {
		width: 100% !important;
	}

	/* blogs: one column, the sidebar after the entries */
	#nmpage #main_blog_wrapper,
	#nmpage #main_blog_wrapper > tbody,
	#nmpage #main_blog_wrapper > tbody > tr,
	#nmpage #main_blog_wrapper > tbody > tr > td {
		display: block;
		width: auto;
	}

	/* the floated rating button must not squeeze the column beside it */
	#nmpage #main_blog_wrapper {
		clear: both;
	}

	/* blog list cards: padding inside the width, no overflow */
	#nmpage .blog_list .header {
		box-sizing: border-box;
	}

	#nmpage #cblock_right_wrap,
	#nmpage #cblock_left_wrap {
		padding: 8px 0;
	}

	#nmpage .entry_wrap h2 {
		padding: 14px 14px 4px;
		font-size: 19px;
	}

	#nmpage .entry_wrap .posted_info {
		padding: 0 14px 10px;
	}

	#nmpage .entry {
		max-width: none;
		padding: 14px;
		font-size: 16px;
	}

	#nmpage .entry_footer {
		padding: 8px 14px;
	}

	#nmpage .entry_links,
	#nmpage #main_blog_wrapper .entry_links,
	#nmpage .share_links {
		float: none;
	}

	#nmpage .share_links {
		margin-top: 6px;
	}

	#nmpage .blog_list .block .header {
		padding: 12px 12px 2px;
	}

	#nmpage .blog_list h4 {
		overflow-wrap: anywhere;
	}

	#nmpage .blog_list .block .rating:empty {
		display: none;
	}

	/* blog search: field and arrow button on one line */
	#nmpage table.newslink form {
		display: flex;
		gap: 6px;
		align-items: center;
	}

	#nmpage table.newslink form input[type="text"] {
		flex: 1 1 auto;
		width: auto;
		min-width: 0;
	}

	#nmpage .blog_list h4 {
		font-size: 17px;
	}

	#nmpage .blog_list .block p,
	#nmpage .blog_list .block .stats {
		margin-left: 12px;
		margin-right: 12px;
	}

	#nmpage .blog_list .block .profile_photo {
		margin-left: 12px;
	}

	/* footer (as on the portal) */
	#nmpage table.footer,
	#nmpage table.footer > tbody,
	#nmpage table.footer > tbody > tr,
	#nmpage table.footer > tbody > tr > td {
		display: block;
		width: auto;
		text-align: left;
	}

	#nmpage table.footer td[width],
	#nmpage table.footer tr + tr {
		display: none;
	}

	#nmpage table.footer td {
		padding: 4px 12px;
		font-size: 13px;
		line-height: 1.8;
	}

	#nmpage table.footer > tbody > tr:first-child > td:nth-child(2) {
		padding-top: 14px;
	}

	#nmpage table.footer td[align="right"] {
		padding-bottom: 14px;
	}

	#nmpage #gfooter,
	#nmpage #gfooter > tbody,
	#nmpage #gfooter > tbody > tr,
	#nmpage #gfooter > tbody > tr > td {
		display: block;
		width: auto;
		text-align: left;
	}
}

/* ---------- blog page on phones: compact header, one-line entry footer, sidebar order ---------- */
@media (max-width: 860px) {
	/* breadcrumbs and the rating chip share one line */
	#nmpage table:has(> tbody > tr > td > #blog-rating),
	#nmpage table:has(> tbody > tr > td > #blog-rating) > tbody {
		display: block;
		width: 100%;
	}

	#nmpage table:has(> tbody > tr > td > #blog-rating) > tbody > tr {
		display: flex;
		align-items: center;
		gap: 10px;
	}

	#nmpage table:has(> tbody > tr > td > #blog-rating) > tbody > tr > td {
		display: block;
		width: auto;
		padding: 0;
	}

	#nmpage table:has(> tbody > tr > td > #blog-rating) > tbody > tr > td:first-child {
		flex: 1 1 auto;
		min-width: 0;
	}

	#nmpage #blog-rating {
		float: none;
		margin: 0;
		white-space: nowrap;
	}

	/* pagination: the page numbers are enough, the "N Сторінки" jump menu goes */
	#nmpage #main_blog_wrapper .pagelink[id^="page-jump"] {
		display: none;
	}

	/* ...and the &nbsp; spacers after it must not indent the numbers */
	#nmpage #main_blog_wrapper td:has(> .pagelink[id^="page-jump"]) {
		font-size: 0;
	}

	#nmpage #main_blog_wrapper td:has(> .pagelink[id^="page-jump"]) > span {
		margin-right: 5px;
		font-size: 14px;
	}

	/* entry footer: comments and link on the left, mail / print / Facebook on the right */
	#nmpage .entry_footer {
		display: flex;
		flex-wrap: wrap;
		align-items: center;
		justify-content: space-between;
		gap: 4px 12px;
	}

	#nmpage .share_links {
		margin-top: 0;
	}

	#nmpage .share_links li.share {
		display: none;
	}

	#nmpage #main_blog_wrapper .share_links a {
		min-width: 38px;
		height: 38px;
	}

	#nmpage .share_links img {
		width: 18px;
		height: 18px;
	}

	#nmpage .entry_links li a {
		display: inline-block;
		padding: 10px 0;
		font-size: 13px;
	}

	/* "Посилання" only pops up the entry's address; on a phone the browser shares it */
	#nmpage .entry_links li.permalink {
		display: none;
	}

	#nmpage .entry_links li.comments {
		border-right: 0;
	}

	/* "Прочитати повністю..." as a comfortable tap target */
	#nmpage .entry > a[href*="entry"]:last-of-type {
		display: inline-block;
		padding: 8px 0 2px;
	}

	/* sidebar under the entries: latest entries and comments first, calendar and feeds last */
	#nmpage #cblock_right_wrap {
		display: flex;
		flex-direction: column;
	}

	#nmpage #cblock_right_wrap > .cblock {
		order: 1;
	}

	#nmpage #cblock_right_wrap > .cblock:has(.last_comment_row) {
		order: 2;
	}

	#nmpage #cblock_right_wrap > .cblock:has(.calday) {
		order: 3;
	}

	#nmpage #cblock_right_wrap > .cblock:has(a[href$="syndicate.html"]) {
		order: 4;
	}

	/* link lists in blocks: one row per link, easy to tap */
	#nmpage .cblock .cblock_content:has(> a + br) > br {
		display: none;
	}

	#nmpage .cblock .cblock_content:has(> a + br) {
		padding-top: 2px;
		padding-bottom: 2px;
	}

	#nmpage .cblock .cblock_content:has(> a + br) > a {
		display: block;
		padding: 10px 0;
		border-bottom: 1px solid var(--nm-line);
		font-size: 14px;
	}

	#nmpage .cblock .cblock_content:has(> a + br) > a:last-of-type {
		border-bottom: 0;
	}

	#nmpage .last_comment_row {
		padding: 9px 0;
		font-size: 14px;
	}

	/* the calendar keeps a sensible size on wider phones */
	#nmpage .cblock:has(.calday) .cblock_content > table {
		max-width: 360px;
		margin: 0 auto;
	}
}

@media (max-width: 380px) {
	#nmpage a.mainlevel-nav:link,
	#nmpage a.mainlevel-nav:visited {
		padding: 11px 9px;
	}
}
