/*
Theme Name: Nina 2026
Theme URI: https://nina-blog24.com/
Description: Своя тема официального сайта Бабы Нины: пергамент, свечи, фото в рамке. Без конструкторов.
Version: 1.0.0
Requires at least: 6.5
Requires PHP: 7.4
Text Domain: nina2026
Update URI: false
*/

:root {
	--parch: #f1ddaa;
	--parch-deep: #e3c27e;
	--paper: rgba(255, 250, 236, .9);
	--paper-solid: #fffaec;
	--ink: #2e2218;
	--ink-soft: #5b4936;
	--gold: #a8741f;
	--gold-soft: #d9b46a;
	--accent: #8f1d1d;
	--accent-hi: #b3261e;
	--line: rgba(120, 85, 35, .22);
	--shadow: 0 10px 30px rgba(84, 54, 18, .16);
	--radius: 14px;
	--slab: "Roboto Slab", Georgia, "Times New Roman", serif;
	--sans: Roboto, "Segoe UI", Arial, sans-serif;
	--wrap: 1120px;
	--text: 760px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 70px; }
body {
	margin: 0; color: var(--ink); font: 400 18px/1.7 var(--sans);
	background: var(--parch) url(assets/img/parchment.webp) center top / 900px auto repeat;
}
@media (min-width: 1024px) and (prefers-reduced-motion: no-preference) { body { background-attachment: fixed; } }
img { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-hi); }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }
.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--paper-solid); padding: 8px 14px; z-index: 100; }
.skip-link:focus { left: 8px; }
.screen-reader-text { position: absolute !important; clip: rect(1px,1px,1px,1px); width: 1px; height: 1px; overflow: hidden; }

/* ---------- шапка: картина со свечами, параллакс ---------- */
.hero { position: relative; overflow: hidden; text-align: center; padding: 18px 16px 22px; }
.hero__stage { will-change: transform; }
.hero__art { position: relative; width: min(560px, 100%); margin: 0 auto; aspect-ratio: 750 / 500; }
.hero--big .hero__art { width: min(750px, 100%); }
.hero__img {
	display: block; width: 100%; height: 100%;
	-webkit-mask-image: radial-gradient(ellipse 72% 78% at 50% 50%, #000 62%, transparent 100%);
	mask-image: radial-gradient(ellipse 72% 78% at 50% 50%, #000 62%, transparent 100%);
}
.hero__orb { position: absolute; left: 44.4%; top: 38.4%; width: 8%; height: auto; opacity: 0; transition: opacity .8s; }
.hero__orb.is-on { opacity: 1; }
.flame {
	position: absolute; top: 9%; width: 9%; aspect-ratio: 1; border-radius: 50%; pointer-events: none;
	background: radial-gradient(circle, rgba(255, 214, 120, .75) 0%, rgba(255, 170, 60, .28) 38%, transparent 70%);
	mix-blend-mode: screen; animation: flicker 3.2s infinite ease-in-out;
}
.flame--l { left: 13.1%; }
.flame--r { left: 77.1%; animation-delay: -1.4s; animation-duration: 2.7s; }
@keyframes flicker {
	0%, 100% { opacity: .85; transform: scale(1); }
	22% { opacity: .55; transform: scale(.92) translateY(1px); }
	47% { opacity: 1; transform: scale(1.08); }
	71% { opacity: .7; transform: scale(.96); }
}
@media (prefers-reduced-motion: reduce) { .flame { animation: none; } }
.hero__brand { position: relative; margin-top: 6px; }
.hero__title {
	display: inline-block; font: 700 clamp(22px, 3.6vw, 34px)/1.2 var(--slab); letter-spacing: .04em; text-transform: uppercase;
	color: var(--ink); text-decoration: none; text-shadow: 0 1px 0 rgba(255, 255, 255, .5);
}
.hero__title::after { content: ""; display: block; width: 120px; height: 10px; margin: 8px auto 0;
	background: radial-gradient(circle, var(--gold) 2.5px, transparent 3px) center / 14px 10px repeat-x,
		linear-gradient(var(--gold-soft), var(--gold-soft)) center / 100% 1px no-repeat; }
.hero__tag { max-width: 720px; margin: 10px auto 0; color: var(--ink-soft); font-size: 16px; line-height: 1.55; }

/* ---------- меню ---------- */
.topnav { position: sticky; top: 0; z-index: 50; background: rgba(233, 207, 150, .94); backdrop-filter: blur(6px);
	border-block: 1px solid var(--line); box-shadow: 0 4px 14px rgba(84, 54, 18, .1); }
.topnav__in { max-width: 1340px; margin: 0 auto; padding: 0 16px; display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 56px; }
.topnav__menu { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 0; }
.topnav__menu a { display: block; padding: 9px 9px; border-radius: 8px; color: var(--ink); text-decoration: none; font: 500 14.5px/1.3 var(--slab); white-space: nowrap; }
.topnav__menu a:hover, .topnav__menu .current-menu-item > a { background: rgba(255, 250, 236, .7); color: var(--accent); }
.topnav__menu .sub-menu { display: none; }
.topnav__toggle { display: none; align-items: center; gap: 10px; border: 1px solid var(--line); background: var(--paper-solid); color: var(--ink);
	border-radius: 10px; padding: 9px 14px; font: 500 15px var(--slab); cursor: pointer; }
.topnav__bars, .topnav__bars::before, .topnav__bars::after { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; position: relative; content: ""; }
.topnav__bars::before { position: absolute; top: -6px; } .topnav__bars::after { position: absolute; top: 6px; }
.topnav__ask { margin-left: 8px; white-space: nowrap; padding: 9px 16px; border-radius: 999px; background: var(--accent); color: #fff;
	text-decoration: none; font: 500 15px/1.2 var(--sans); box-shadow: 0 4px 14px rgba(143, 29, 29, .3); }
.topnav__ask:hover { background: var(--accent-hi); color: #fff; }
@media (max-width: 1180px) {
	.topnav__toggle { display: inline-flex; }
	.topnav__menu { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; padding: 8px 16px 14px;
		background: var(--paper-solid); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
	.topnav__menu.is-open { display: flex; }
	.topnav__menu a { padding: 12px 10px; font-size: 17px; }
}

/* ---------- содержимое ---------- */
.site-main { max-width: var(--wrap); margin: 28px auto 0; padding: 0 16px; }
.entry, .listing, .related { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
	padding: clamp(20px, 4vw, 48px); }
.related { margin-top: 24px; }
.entry__head, .entry__content > :not(.nb-cols):not(.nb-gallery):not(.nb-video), .nb-toc, .entry > .nb-ask, .crumbs { max-width: var(--text); margin-inline: auto; }
.entry--home .entry__content > * { max-width: none; }
.entry--home .entry__content > p, .entry--home .entry__content > ul, .entry--home .entry__content > ol { max-width: 900px; margin-inline: auto; }
.crumbs { font-size: 14px; color: var(--ink-soft); margin-bottom: 14px; }
.crumbs a { color: var(--ink-soft); }
.entry__title { font: 700 clamp(26px, 3.4vw, 38px)/1.22 var(--slab); color: var(--ink); margin: 0 0 12px; }
.entry--home .entry__title { text-align: center; max-width: 900px; margin-inline: auto; }
.entry__meta { margin: 0 0 22px; color: var(--ink-soft); font-size: 15px; }
.entry__content h2 { font: 700 clamp(22px, 2.5vw, 28px)/1.3 var(--slab); margin: 1.8em 0 .6em; color: var(--ink); }
.entry__content h3 { font: 600 21px/1.35 var(--slab); margin: 1.5em 0 .5em; }
.entry__content h4 { font: 600 18px/1.4 var(--slab); margin: 1.3em 0 .4em; }
.entry__content p, .entry__content ul, .entry__content ol { margin: 0 0 1.05em; }
.entry__content li { margin: .3em 0; }
.entry__content li::marker { color: var(--gold); }
.entry__content blockquote:not(.nb-review) { margin: 1.4em 0; padding: 14px 20px; border-left: 4px solid var(--gold-soft); background: rgba(255, 255, 255, .45); border-radius: 0 10px 10px 0; font-style: italic; }
.entry__content hr { border: 0; height: 12px; margin: 2em auto; max-width: 240px;
	background: radial-gradient(circle, var(--gold) 2.5px, transparent 3px) center / 16px 12px repeat-x; }
.has-text-align-center { text-align: center; }
.aligncenter { display: block; margin-inline: auto; }
.alignleft { float: left; margin: .3em 1.4em 1em 0; } .alignright { float: right; margin: .3em 0 1em 1.4em; }
@media (max-width: 600px) { .alignleft, .alignright { float: none; margin: 1em auto; display: block; } }

/* фото — в кремовой рамке, как снимок в шапке */
.entry__content img, .nb-figure img { border-radius: 4px; background: var(--paper-solid); padding: 7px;
	box-shadow: 0 1px 0 rgba(255, 255, 255, .6) inset, 0 8px 22px rgba(70, 45, 15, .22); }
.nb-figure, .wp-caption { margin: 1.4em auto; text-align: center; }
.nb-figure img { display: block; margin: 0 auto; }
.nb-figure figcaption, .wp-caption-text { margin-top: 10px; font-size: 15px; line-height: 1.5; color: var(--ink-soft); font-style: italic; }
.wp-caption { max-width: 100%; }

/* колонки: текст и фото рядом */
.nb-cols { display: grid; gap: clamp(18px, 3vw, 40px); align-items: start; margin: 1.4em 0 1.8em; }
@media (min-width: 820px) { .nb-cols-2 { grid-template-columns: 1.15fr 1fr; } .nb-cols-3 { grid-template-columns: repeat(3, 1fr); } }
.nb-col > :first-child { margin-top: 0; }
.nb-col .nb-figure { margin-top: 0; }
.nb-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 14px; margin: 1.4em 0; }
.nb-gallery .nb-figure { margin: 0; }
.nb-gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.nb-video { position: relative; aspect-ratio: 16 / 9; margin: 1.4em auto; max-width: var(--text); }
.nb-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; border-radius: 10px; box-shadow: var(--shadow); }
.nb-review { margin: 1.4em 0; padding: 20px 22px; background: rgba(255, 255, 255, .55); border: 1px solid var(--line); border-radius: 12px; display: grid; gap: 8px 16px; grid-template-columns: auto 1fr; }
.nb-review__photo { width: 72px; height: 72px; object-fit: cover; border-radius: 50%; padding: 3px; grid-row: span 2; }
.nb-review p { margin: 0; font-style: italic; }
.nb-review cite { font-style: normal; font-weight: 500; color: var(--ink-soft); }

/* оглавление */
.nb-toc { margin-block: 0 1.6em; padding: 14px 20px; background: rgba(255, 255, 255, .5); border: 1px solid var(--line); border-radius: 12px; font-size: 16px; }
.nb-toc summary { cursor: pointer; font: 600 17px var(--slab); }
.nb-toc ol { margin: 10px 0 2px; padding-left: 22px; }
.nb-toc a { color: var(--ink); text-decoration: none; } .nb-toc a:hover { color: var(--accent); text-decoration: underline; }

/* ---------- кнопки и призывы в чат ---------- */
.nb-btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 26px; border-radius: 999px; border: 0;
	background: linear-gradient(180deg, var(--accent-hi), var(--accent)); color: #fff !important; text-decoration: none;
	font: 500 17px/1.2 var(--sans); box-shadow: 0 8px 22px rgba(143, 29, 29, .32); transition: transform .15s, box-shadow .15s; }
.nb-btn::before { content: ""; width: 10px; height: 14px; border-radius: 50% 50% 45% 45%; background: radial-gradient(circle at 50% 70%, #ffe7a8, #f5b545 60%, transparent 62%);
	box-shadow: 0 0 10px 2px rgba(255, 200, 90, .7); animation: flicker 2.6s infinite; }
.nb-btn:hover { transform: translateY(-1px); box-shadow: 0 12px 26px rgba(143, 29, 29, .38); }
.nb-btn--light { background: var(--paper-solid); color: var(--accent) !important; box-shadow: none; }
.nb-cta { text-align: center; margin: 1.6em auto !important; }
.nb-ask { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; margin-top: 2.2em; padding: 22px 26px;
	border-radius: 14px; border: 1px solid rgba(168, 116, 31, .35); background: linear-gradient(135deg, rgba(255, 246, 220, .95), rgba(240, 214, 160, .9)); }
.entry__content .nb-ask { margin: 2em auto; }
.nb-ask__text { flex: 1 1 320px; }
.nb-ask__text p { margin: 0; font-size: 16px; color: var(--ink-soft); }
.nb-ask__text .nb-ask__title { font: 700 20px/1.3 var(--slab); color: var(--ink); margin-bottom: 4px; }

/* ---------- карточки записей ---------- */
.listing__head { margin-bottom: 22px; }
.related__title { font: 700 24px var(--slab); margin: 0 0 16px; }
.cards { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.card { display: flex; flex-direction: column; background: rgba(255, 255, 255, .6); border: 1px solid var(--line); border-radius: 12px; overflow: hidden;
	color: var(--ink); text-decoration: none; transition: transform .15s, box-shadow .15s; }
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.card__img { display: block; aspect-ratio: 16 / 10; background: var(--parch-deep); overflow: hidden; }
.card__img img { width: 100%; height: 100%; object-fit: cover; padding: 0; box-shadow: none; border-radius: 0; display: block; }
.card__noimg { display: block; width: 100%; height: 100%; background: url(assets/img/parchment.webp) center / cover; }
.card__title { font: 600 18px/1.35 var(--slab); margin: 14px 16px 6px; }
.card__title a { color: var(--ink); text-decoration: none; } .card__title a:hover { color: var(--accent); }
a.card .card__title { margin-bottom: 16px; }
.card__text { margin: 0 16px 16px; font-size: 15px; line-height: 1.55; color: var(--ink-soft); }
.pagination, .nav-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 30px 0 4px; }
.page-numbers { min-width: 42px; padding: 9px 13px; border-radius: 10px; text-align: center; background: rgba(255, 255, 255, .6); border: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.page-numbers.current { background: var(--accent); color: #fff; border-color: var(--accent); }
.search-form { display: flex; gap: 8px; max-width: 520px; margin: 14px 0; }
.search-field { flex: 1; padding: 12px 14px; font: inherit; font-size: 16px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.search-submit { padding: 12px 18px; border: 0; border-radius: 10px; background: var(--ink); color: #fff; font: inherit; font-size: 16px; cursor: pointer; }

/* ---------- подвал ---------- */
.site-footer { margin-top: 48px; background: #3a2a1c; color: #ead9b3; }
.site-footer__in { max-width: var(--wrap); margin: 0 auto; padding: 36px 16px 20px; display: flex; flex-wrap: wrap; gap: 28px 48px; justify-content: space-between; }
.site-footer__brand { flex: 1 1 320px; }
.site-footer__brand p { margin: 8px 0 16px; font-size: 15px; color: #cdb88f; }
.site-footer__title { font: 700 20px var(--slab); color: #f5e6c4; text-decoration: none; }
.site-footer__nav ul { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 32px; }
.site-footer__nav a { display: inline-block; padding: 5px 0; color: #ead9b3; text-decoration: none; font-size: 15px; }
.site-footer__nav a:hover { color: #fff; text-decoration: underline; }
.site-footer__copy { max-width: var(--wrap); margin: 0 auto; padding: 14px 16px 26px; border-top: 1px solid rgba(234, 217, 179, .15); font-size: 13px; color: #b9a47c; }

@media (max-width: 600px) {
	body { font-size: 17px; }
	.site-main { margin-top: 16px; padding: 0 10px; }
	.entry, .listing, .related { border-radius: 12px; }
	.nb-ask { padding: 18px; } .nb-btn { width: 100%; justify-content: center; }
	.topnav__ask { padding: 8px 12px; font-size: 14px; }
}

/* меню в одну строку: на средних экранах без кнопки (у чата своя кнопка, в тексте — призывы) */
@media (min-width: 1181px) and (max-width: 1400px) { .topnav__ask { display: none; } }

/* телефон: на внутренних страницах шапка компактнее — до текста быстрее */
@media (max-width: 600px) { .hero:not(.hero--big) { padding: 10px 16px 12px; } .hero:not(.hero--big) .hero__art { width: 64%; } .hero:not(.hero--big) .hero__tag { display: none; } .hero:not(.hero--big) .hero__title { font-size: 19px; } }
