/* =========================================================
   NightShelf theme styles
   コンセプト: 深夜の同人書店（ダーク×ネオンピンク）
   ========================================================= */

:root {
	--ns-bg: #0d0e12;
	--ns-bg-2: #14161d;
	--ns-surface: #191c25;
	--ns-surface-2: #1f2330;
	--ns-border: #262a36;
	--ns-text: #e8e9ee;
	--ns-text-sub: #9aa0b0;
	--ns-accent: #ff4d8d;
	--ns-accent-2: #4dd8ff;
	--ns-cta: #ff2e63;
	--ns-radius: 12px;
	--ns-radius-s: 8px;
	--ns-font: -apple-system, BlinkMacSystemFont, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, "Segoe UI", sans-serif;
}

/* ---------- Reset / base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
	margin: 0;
	background: var(--ns-bg);
	color: var(--ns-text);
	font-family: var(--ns-font);
	font-size: 16px;
	line-height: 1.8;
	overflow-wrap: break-word;
}

img { max-width: 100%; height: auto; }
video, iframe { max-width: 100%; }

a { color: var(--ns-accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
	outline: 2px solid var(--ns-accent);
	outline-offset: 2px;
}

/* hidden属性はdisplay指定より常に優先させる */
[hidden] { display: none !important; }

.screen-reader-text {
	border: 0; clip-path: inset(50%); height: 1px; width: 1px;
	margin: -1px; overflow: hidden; padding: 0; position: absolute;
}

.ns-skip-link {
	position: absolute; left: -9999px; top: 0;
	background: var(--ns-accent); color: #fff; padding: 8px 16px; z-index: 200;
}
.ns-skip-link:focus { left: 8px; top: 8px; }

/* ---------- PR bar ---------- */

.ns-pr-bar {
	background: var(--ns-bg-2);
	color: var(--ns-text-sub);
	font-size: 11px;
	text-align: center;
	padding: 4px 12px;
	border-bottom: 1px solid var(--ns-border);
}

/* ---------- Header ---------- */

.ns-header {
	background: linear-gradient(180deg, #14161d 0%, #0d0e12 100%);
	border-bottom: 1px solid var(--ns-border);
	position: relative;
}

.ns-header__inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 14px 16px;
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
}

.ns-brand { flex: 1 1 auto; min-width: 0; }

.ns-brand__title {
	margin: 0;
	font-size: 22px;
	font-weight: 800;
	letter-spacing: .02em;
	line-height: 1.3;
}
.ns-brand__title a {
	color: var(--ns-text);
	text-decoration: none;
	background: linear-gradient(90deg, var(--ns-text) 60%, var(--ns-accent));
	-webkit-background-clip: text;
	background-clip: text;
}
.ns-brand__title a:hover { color: var(--ns-accent); }

.ns-brand__tagline {
	margin: 2px 0 0;
	font-size: 11px;
	color: var(--ns-text-sub);
}

.custom-logo { max-height: 60px; width: auto; display: block; }

/* Nav */

.ns-nav-toggle {
	display: none;
	background: var(--ns-surface);
	color: var(--ns-text);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	padding: 8px 12px;
	font-size: 12px;
	cursor: pointer;
	align-items: center;
	gap: 8px;
}
.ns-nav-toggle__bars {
	display: inline-block; width: 16px; height: 2px; background: var(--ns-text);
	position: relative;
}
.ns-nav-toggle__bars::before, .ns-nav-toggle__bars::after {
	content: ""; position: absolute; left: 0; width: 16px; height: 2px; background: var(--ns-text);
}
.ns-nav-toggle__bars::before { top: -5px; }
.ns-nav-toggle__bars::after { top: 5px; }

.ns-nav {
	display: flex;
	align-items: center;
	gap: 16px;
	flex-wrap: wrap;
}

.ns-nav__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	gap: 4px;
	flex-wrap: wrap;
}
.ns-nav__list li { position: relative; }
.ns-nav__list a {
	display: block;
	padding: 6px 12px;
	color: var(--ns-text);
	font-size: 14px;
	border-radius: 999px;
	text-decoration: none;
}
.ns-nav__list a:hover { background: var(--ns-surface-2); color: var(--ns-accent); }
.ns-nav__list .sub-menu {
	list-style: none; margin: 0; padding: 6px;
	position: absolute; top: 100%; left: 0; min-width: 180px; z-index: 50;
	background: var(--ns-surface); border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	display: none;
}
.ns-nav__list li:hover > .sub-menu,
.ns-nav__list li:focus-within > .sub-menu { display: block; }

@media (max-width: 860px) {
	.ns-nav-toggle { display: inline-flex; }
	.ns-nav {
		display: none;
		width: 100%;
		flex-direction: column;
		align-items: stretch;
		padding: 8px 0 4px;
	}
	.ns-nav.is-open { display: flex; }
	.ns-nav__list { flex-direction: column; }
	.ns-nav__list .sub-menu {
		position: static; display: block; border: none; padding: 0 0 0 16px; background: transparent;
	}
}

/* Search form */

.ns-searchform { display: flex; gap: 6px; }
.ns-searchform__input {
	background: var(--ns-bg-2);
	border: 1px solid var(--ns-border);
	color: var(--ns-text);
	border-radius: 999px;
	padding: 7px 14px;
	font-size: 13px;
	min-width: 180px;
}
.ns-searchform__submit {
	background: var(--ns-accent);
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 7px 16px;
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
}
.ns-searchform__submit:hover { filter: brightness(1.1); }

/* ---------- Layout ---------- */

.ns-main {
	max-width: 1200px;
	margin: 0 auto;
	padding: 20px 16px 64px;
}

.ns-hero { padding: 8px 0 0; }
.ns-hero__lead { color: var(--ns-text-sub); font-size: 14px; margin: 8px 0 0; }

.ns-shelf { margin: 28px 0 0; }

.ns-shelf__title {
	font-size: 20px;
	font-weight: 800;
	margin: 0 0 14px;
	padding-left: 12px;
	border-left: 4px solid var(--ns-accent);
	line-height: 1.4;
}

.ns-shelf__desc { color: var(--ns-text-sub); font-size: 14px; margin: -6px 0 14px; }

.ns-shelf__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	flex-wrap: wrap;
}
.ns-shelf__head .ns-shelf__title { margin-bottom: 14px; }

/* 並び替え（新着順 / 人気順） */

.ns-sort {
	display: inline-flex;
	gap: 4px;
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: 999px;
	padding: 3px;
	margin: 0 0 14px;
}
.ns-sort__item {
	display: inline-block;
	padding: 5px 14px;
	font-size: 12px;
	font-weight: 700;
	border-radius: 999px;
	color: var(--ns-text-sub);
	text-decoration: none;
}
.ns-sort__item:hover { color: var(--ns-accent); text-decoration: none; }
.ns-sort__item.is-current {
	background: var(--ns-accent);
	color: #fff;
}

/* ジャンルから探す（チップ棚） */

.ns-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ns-chips__chip {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	color: var(--ns-text);
	font-size: 13px;
	padding: 6px 14px;
	border-radius: 999px;
	text-decoration: none;
	transition: border-color .15s ease, color .15s ease;
}
.ns-chips__chip:hover { border-color: var(--ns-accent); color: var(--ns-accent); text-decoration: none; }
.ns-chips__chip--cat {
	background: rgba(255, 77, 141, .1);
	border-color: rgba(255, 77, 141, .35);
}
.ns-chips__count {
	font-size: 10px;
	color: var(--ns-text-sub);
	background: var(--ns-bg-2);
	border-radius: 999px;
	padding: 1px 7px;
}

/* ---------- Card grid ---------- */

.ns-grid {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 14px;
}
@media (min-width: 600px) { .ns-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 900px) { .ns-grid { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1120px) { .ns-grid { grid-template-columns: repeat(5, 1fr); } }

.ns-card {
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius);
	overflow: hidden;
	transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.ns-card:hover {
	transform: translateY(-3px);
	border-color: var(--ns-accent);
	box-shadow: 0 8px 24px rgba(255, 77, 141, .12);
}

.ns-card__link { display: block; color: inherit; text-decoration: none; }
.ns-card__link:hover { text-decoration: none; }

.ns-card__cover {
	position: relative;
	aspect-ratio: 3 / 4;
	background: radial-gradient(120% 120% at 50% 0%, #1d212d 0%, #101218 100%);
	display: flex;
	align-items: center;
	justify-content: center;
}
.ns-card__cover img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	display: block;
}

.ns-card__noimage {
	color: var(--ns-text-sub);
	font-size: 11px;
	letter-spacing: .2em;
}

.ns-card__badge {
	position: absolute; top: 8px; right: 8px; z-index: 2;
	background: var(--ns-accent);
	color: #fff;
	font-size: 10px;
	font-weight: 800;
	letter-spacing: .08em;
	padding: 2px 8px;
	border-radius: 999px;
}

.ns-card__rank {
	position: absolute; top: 0; left: 0; z-index: 2;
	min-width: 34px; height: 34px;
	display: flex; align-items: center; justify-content: center;
	background: var(--ns-surface-2);
	color: var(--ns-text);
	font-size: 15px;
	font-weight: 800;
	border-radius: 0 0 var(--ns-radius-s) 0;
	border-right: 1px solid var(--ns-border);
	border-bottom: 1px solid var(--ns-border);
}
.ns-card__rank--top {
	background: linear-gradient(135deg, var(--ns-accent), var(--ns-cta));
	color: #fff;
	border: none;
}

.ns-card__body { padding: 10px 12px 12px; }

.ns-card__title {
	margin: 0 0 6px;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.5;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	min-height: calc(1.5em * 2);
}

.ns-card__meta {
	display: flex;
	align-items: center;
	gap: 8px;
	flex-wrap: wrap;
	color: var(--ns-text-sub);
	font-size: 11px;
}

.ns-card__chip {
	background: rgba(255, 77, 141, .12);
	color: var(--ns-accent);
	border: 1px solid rgba(255, 77, 141, .35);
	padding: 1px 8px;
	border-radius: 999px;
	font-size: 10px;
	font-weight: 700;
	text-decoration: none;
	max-width: 12em;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ns-card__views { white-space: nowrap; }

/* ---------- Single ---------- */

.ns-single { max-width: 960px; margin: 0 auto; }

.ns-single__header { margin: 8px 0 16px; }

.ns-single__title {
	font-size: 24px;
	font-weight: 800;
	line-height: 1.5;
	margin: 0 0 10px;
}
@media (max-width: 600px) { .ns-single__title { font-size: 19px; } }

.ns-single__meta {
	display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
	color: var(--ns-text-sub); font-size: 13px;
}

.ns-single__thumb { text-align: center; margin: 0 0 20px; }
.ns-single__thumb img { border-radius: var(--ns-radius); }

/* Breadcrumb */

.ns-breadcrumb { font-size: 12px; color: var(--ns-text-sub); margin: 0 0 12px; }
.ns-breadcrumb ol {
	list-style: none; margin: 0; padding: 0;
	display: flex; flex-wrap: wrap; gap: 4px;
}
.ns-breadcrumb li + li::before { content: "›"; margin: 0 6px 0 2px; color: var(--ns-border); }
.ns-breadcrumb a { color: var(--ns-text-sub); }
.ns-breadcrumb a:hover { color: var(--ns-accent); }
.ns-breadcrumb span[aria-current] {
	color: var(--ns-text);
	display: inline-block;
	max-width: 24em;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	vertical-align: bottom;
}

/* ---------- Entry content（プラグイン生成HTMLの整形） ---------- */

.ns-entry { font-size: 15px; }

.ns-entry h2 {
	font-size: 19px;
	font-weight: 800;
	margin: 36px 0 14px;
	padding: 8px 12px;
	background: var(--ns-surface);
	border-left: 4px solid var(--ns-accent);
	border-radius: 0 var(--ns-radius-s) var(--ns-radius-s) 0;
	line-height: 1.5;
}
.ns-entry h3 {
	font-size: 16px;
	margin: 28px 0 10px;
	padding-bottom: 6px;
	border-bottom: 2px solid var(--ns-border);
}

.ns-entry p { margin: 0 0 1.2em; }

.ns-entry img { border-radius: var(--ns-radius-s); }

.ns-entry .wp-block-image { margin: 18px auto; text-align: center; }
.ns-entry .wp-block-image figure { margin: 0; }
.ns-entry .wp-block-image img { cursor: zoom-in; }

.ns-entry video, .ns-entry iframe {
	display: block;
	margin: 18px auto;
	border-radius: var(--ns-radius-s);
	background: #000;
}

/* 商品情報テーブル（プラグインの wp-block-table を整形） */

.ns-entry .wp-block-table { margin: 18px 0; overflow-x: auto; }
.ns-entry table {
	width: 100%;
	border-collapse: collapse;
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	overflow: hidden;
	font-size: 14px;
}
.ns-entry th, .ns-entry td {
	padding: 10px 12px;
	border-bottom: 1px solid var(--ns-border);
	text-align: left;
	vertical-align: top;
}
.ns-entry tr:last-child th, .ns-entry tr:last-child td { border-bottom: none; }
.ns-entry th {
	background: var(--ns-surface-2);
	color: var(--ns-text-sub);
	font-weight: 700;
	white-space: nowrap;
	width: 7em;
}
.ns-entry td a { color: var(--ns-accent-2); }

/* プラグインのボタン（content1 / content2 / tachiyomi）を大きく・押しやすく */

.ns-entry .wp-block-buttons { margin: 22px auto; display: flex; justify-content: center; }
.ns-entry .wp-block-button { width: 100%; max-width: 480px; }
.ns-entry .wp-block-button__link {
	display: block;
	text-align: center;
	padding: 15px 20px;
	font-size: 16px;
	text-decoration: none;
	box-shadow: 0 4px 16px rgba(0, 0, 0, .35);
	transition: transform .15s ease, filter .15s ease;
}
.ns-entry .wp-block-button__link:hover {
	transform: translateY(-2px);
	filter: brightness(1.08);
	text-decoration: none;
}

/* Cocoonテンプレート互換ボタン
   （Cocoon前提で作られた旧FANZAテンプレートの .btn 系クラスをボタン表示にする） */

.ns-entry a.btn {
	display: block;
	max-width: 480px;
	margin: 22px auto;
	padding: 15px 20px;
	text-align: center;
	font-size: 16px;
	font-weight: 700;
	color: #fff;
	background: linear-gradient(135deg, var(--ns-cta), var(--ns-accent));
	border-radius: 999px;
	text-decoration: none;
	box-shadow: 0 4px 16px rgba(0, 0, 0, .35);
	transition: transform .15s ease, filter .15s ease;
}
.ns-entry a.btn:hover {
	transform: translateY(-2px);
	filter: brightness(1.08);
	text-decoration: none;
	color: #fff;
}
.ns-entry a.btn-s { max-width: 300px; padding: 10px 16px; font-size: 14px; }
.ns-entry a.btn-m { max-width: 400px; }
.ns-entry a.btn-l { max-width: 560px; font-size: 17px; }

.ns-entry a.btn-pink { background: linear-gradient(135deg, #ff2e63, #ff4d8d); }
.ns-entry a.btn-red { background: linear-gradient(135deg, #d92645, #ff5e6e); }
.ns-entry a.btn-green { background: linear-gradient(135deg, #0da878, #2ecc71); }
.ns-entry a.btn-blue { background: linear-gradient(135deg, #2470c2, #4da3ff); }
.ns-entry a.btn-orange { background: linear-gradient(135deg, #e67e22, #f5a623); }
.ns-entry a.btn-yellow { background: linear-gradient(135deg, #d8a300, #f1c40f); color: #1c1c1c; }
.ns-entry a.btn-yellow:hover { color: #1c1c1c; }
.ns-entry a.btn-purple { background: linear-gradient(135deg, #7d3ce2, #a55eea); }

/* ---------- 商品テンプレート（.ns-product） ---------- */

.ns-product__hero {
	display: grid;
	grid-template-columns: 1fr;
	gap: 20px;
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius);
	padding: 18px;
	margin: 0 0 8px;
}
@media (min-width: 860px) {
	.ns-product__hero { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; }
}

.ns-product__cover .wp-block-image { margin: 0; }
.ns-product__cover img { border-radius: var(--ns-radius-s); width: 100%; height: auto; object-fit: contain; }

.ns-product__eyebrow {
	margin: 0 0 8px;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: .18em;
	color: var(--ns-accent);
}

.ns-product__facts .wp-block-table { margin: 0 0 12px; }

.ns-product__note { font-size: 12px; color: var(--ns-text-sub); margin: 0 0 8px; }

.ns-product__actions .wp-block-buttons { margin: 10px 0; }
.ns-product__actions .wp-block-button { max-width: none; }

.ns-product__heading { scroll-margin-top: 20px; }

.ns-product__movie video, .ns-product__movie iframe { width: 100%; }

.ns-product__gallery .wp-block-image { margin: 14px auto; }

.ns-product__closing {
	margin: 40px 0 0;
	padding: 24px 18px;
	text-align: center;
	background: linear-gradient(135deg, rgba(255, 77, 141, .12), rgba(255, 46, 99, .08));
	border: 1px solid rgba(255, 77, 141, .3);
	border-radius: var(--ns-radius);
}
.ns-product__closing-copy { font-weight: 800; font-size: 16px; margin: 0 0 4px; }

.ns-price-note { font-size: 12px; color: var(--ns-text-sub); margin: 18px 0 0; }

/* ---------- Tags / postnav ---------- */

.ns-taglist { margin: 20px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ns-taglist__tag {
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	color: var(--ns-text-sub);
	font-size: 12px;
	padding: 4px 12px;
	border-radius: 999px;
	text-decoration: none;
}
.ns-taglist__tag:hover { color: var(--ns-accent); border-color: var(--ns-accent); text-decoration: none; }

.ns-postnav {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	margin: 28px 0 0;
	font-size: 13px;
}
.ns-postnav__prev, .ns-postnav__next { max-width: 48%; }
.ns-postnav a {
	color: var(--ns-text-sub);
	display: inline-block;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	max-width: 100%;
}
.ns-postnav a:hover { color: var(--ns-accent); }

/* ---------- Pagination ---------- */

.ns-main .pagination { margin: 28px 0 0; }
.ns-main .nav-links {
	display: flex;
	justify-content: center;
	gap: 6px;
	flex-wrap: wrap;
}
.ns-main .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 12px;
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	color: var(--ns-text);
	font-size: 14px;
	text-decoration: none;
}
.ns-main .page-numbers.current {
	background: var(--ns-accent);
	border-color: var(--ns-accent);
	color: #fff;
	font-weight: 800;
}
.ns-main a.page-numbers:hover { border-color: var(--ns-accent); color: var(--ns-accent); text-decoration: none; }

/* ---------- Comments ---------- */

.ns-comments { margin: 40px 0 0; }
.ns-comments__title { font-size: 18px; }
.ns-comments__list { list-style: none; padding: 0; }
.ns-comments .comment-body {
	background: var(--ns-surface);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	padding: 14px;
	margin: 0 0 12px;
	font-size: 14px;
}
.ns-comments input[type="text"], .ns-comments input[type="email"],
.ns-comments input[type="url"], .ns-comments textarea {
	width: 100%;
	background: var(--ns-bg-2);
	border: 1px solid var(--ns-border);
	color: var(--ns-text);
	border-radius: var(--ns-radius-s);
	padding: 10px;
}
.ns-comments .submit {
	background: var(--ns-accent); color: #fff; border: none;
	border-radius: var(--ns-radius-s); padding: 10px 24px; font-weight: 700; cursor: pointer;
}

/* ---------- Footer ---------- */

.ns-footer {
	background: var(--ns-bg-2);
	border-top: 1px solid var(--ns-border);
	margin-top: 48px;
}
.ns-footer__inner {
	max-width: 1200px;
	margin: 0 auto;
	padding: 28px 16px 88px;
	color: var(--ns-text-sub);
	font-size: 12px;
}
.ns-footer__widgets {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px;
	margin: 0 0 20px;
}
.ns-footer-widget__title { font-size: 13px; color: var(--ns-text); margin: 0 0 8px; }
.ns-footer__menu {
	list-style: none; margin: 0 0 16px; padding: 0;
	display: flex; flex-wrap: wrap; gap: 4px 18px;
}
.ns-footer__menu a { color: var(--ns-text-sub); }
.ns-footer__menu a:hover { color: var(--ns-accent); }
.ns-footer__note { margin: 12px 0 4px; }
.ns-footer__copy { margin: 0; }

/* ---------- Sticky CTA ---------- */

.ns-sticky-cta {
	position: fixed;
	left: 0; right: 0; bottom: 0;
	z-index: 90;
	padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
	background: rgba(13, 14, 18, .92);
	backdrop-filter: blur(6px);
	border-top: 1px solid var(--ns-border);
}
.ns-sticky-cta__button {
	display: block;
	max-width: 560px;
	margin: 0 auto;
	background: linear-gradient(135deg, var(--ns-cta), var(--ns-accent));
	color: #fff;
	text-align: center;
	font-weight: 800;
	font-size: 15px;
	padding: 13px 16px;
	border-radius: 999px;
	text-decoration: none;
	box-shadow: 0 6px 20px rgba(255, 46, 99, .35);
}
.ns-sticky-cta__button:hover { filter: brightness(1.08); text-decoration: none; }

@media (min-width: 1000px) {
	.ns-sticky-cta { display: none; }
}

/* ---------- Lightbox ---------- */

.ns-lightbox {
	position: fixed; inset: 0; z-index: 250;
	background: rgba(8, 9, 12, .95);
	display: flex; align-items: center; justify-content: center;
}
.ns-lightbox__img {
	max-width: min(92vw, 1100px);
	max-height: 88vh;
	object-fit: contain;
	border-radius: var(--ns-radius-s);
}
.ns-lightbox__close {
	position: absolute; top: 12px; right: 16px;
	background: transparent; border: none;
	color: #fff; font-size: 36px; line-height: 1; cursor: pointer;
	padding: 8px;
}
.ns-lightbox__nav {
	position: absolute; top: 50%; transform: translateY(-50%);
	background: rgba(25, 28, 37, .8);
	border: 1px solid var(--ns-border);
	color: #fff;
	font-size: 28px;
	line-height: 1;
	width: 48px; height: 48px;
	border-radius: 50%;
	cursor: pointer;
}
.ns-lightbox__nav--prev { left: 12px; }
.ns-lightbox__nav--next { right: 12px; }
.ns-lightbox__nav:hover { border-color: var(--ns-accent); }

body.ns-lightbox-open { overflow: hidden; }

/* ---------- Misc ---------- */

.ns-none { padding: 24px 0; color: var(--ns-text-sub); }
.ns-none .ns-searchform { margin-top: 12px; }

.ns-entry .alignleft { float: left; margin: 0 16px 12px 0; }
.ns-entry .alignright { float: right; margin: 0 0 12px 16px; }
.ns-entry .aligncenter { margin-left: auto; margin-right: auto; }
.ns-entry::after { content: ""; display: block; clear: both; }

.ns-entry blockquote {
	margin: 18px 0;
	padding: 12px 16px;
	border-left: 4px solid var(--ns-border);
	background: var(--ns-surface);
	color: var(--ns-text-sub);
	border-radius: 0 var(--ns-radius-s) var(--ns-radius-s) 0;
}

.ns-entry pre {
	background: var(--ns-bg-2);
	border: 1px solid var(--ns-border);
	border-radius: var(--ns-radius-s);
	padding: 12px;
	overflow-x: auto;
	font-size: 13px;
}
