/* =====================================================================
   Блог 2026 — по КП «Обновление дизайна блога» (слайды 3–5, 8–10).
   Всё под префиксом rb-, старый шаблон news и раздел «Новости» не затрагиваются.
   ===================================================================== */

.rb-page {
	--rb-bg: #f2f3f5;
	--rb-card: #fff;
	--rb-text: #111;
	--rb-muted: #8a8f98;
	--rb-line: #e4e6ea;
	--rb-accent: #f7941d;      /* оранжевый РИМ */
	--rb-accent-dark: #d9770a;
	--rb-radius: 24px;
	--rb-radius-s: 16px;
	font-family: 'Uni Neue', Arial, sans-serif;
	color: var(--rb-text);
}
/* base.css шаблона подключается позже и задаёт .right-column белый фон — нужна специфичность выше */
.right-column.rb-page { background: var(--rb-bg); }
.rb-page * { font-family: inherit; }
.rb-main { max-width: 1320px; margin: 0 auto; }

/* ---------- Светлая боковая колонка вместо чёрной полосы (слайд 9) ---------- */
@media (min-width: 1200px) {
	.sidebar.rb-sidebar { background: var(--rb-bg, #f2f3f5); color: #111; }
	.rb-sidebar .sidebar__city__list--type2 > ul > li > a { color: #111; font-size: 17px; border-radius: 10px; }
	.rb-sidebar .sidebar__city__list--type2 > ul > li > a:hover { background: #e7e9ed; text-decoration: none; }
	.rb-sidebar .sidebar__city__list--type2 > ul > li.active > a { background: #fff; font-weight: 700; }
	.rb-sidebar .sidebar__city__list--type2 > ul > li > ul > li > a { color: #5b616b; }
	.rb-sidebar .sidebar__city__list--type2 > ul > li > ul > li::before { background-color: #5b616b; }
}

/* ---------- Заголовок страницы: один раз, крупно, чёрным ---------- */
.rb-title {
	margin: 8px 0 0;
	padding-bottom: 32px;
	font-size: clamp(32px, 3.2vw, 48px);
	font-weight: 900;
	line-height: 1.1;
	color: var(--rb-text);
}

/* ---------- Сетка карточек (слайды 3, 4, 10) ---------- */
.rb-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 40px 32px;
}
.rb-card { display: flex; flex-direction: column; min-width: 0; }
.rb-card__link { display: flex; flex-direction: column; gap: 16px; color: inherit; text-decoration: none; }
.rb-card__link:hover, .rb-card__link:focus { color: inherit; text-decoration: none; }
.rb-card__img {
	display: block;
	aspect-ratio: 16 / 10;
	border-radius: var(--rb-radius);
	overflow: hidden;
	background: #dfe2e7;
}
.rb-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .35s ease; }
.rb-card__link:hover .rb-card__img img { transform: scale(1.03); }
/* Заголовок целиком, без обрезки (слайд 10: «сейчас длинные заголовки просто обрезаются») */
.rb-card__title {
	font-size: 22px;
	font-weight: 700;
	line-height: 1.25;
	color: var(--rb-text);
	overflow-wrap: anywhere;
}
.rb-card__link:hover .rb-card__title { color: var(--rb-accent-dark); }
.rb-card__date { margin-top: 8px; font-size: 15px; font-weight: 500; color: var(--rb-muted); }

.rb-grid--small { gap: 32px 24px; }
.rb-grid--small .rb-card__title { font-size: 19px; }

/* ---------- Постраничная навигация (штатный NAV_STRING) ---------- */
.rb-pager { margin: 48px 0 16px; text-align: center; font-size: 17px; }
.rb-pager a, .rb-pager b, .rb-pager span.current {
	display: inline-block; min-width: 40px; padding: 8px 12px; margin: 2px;
	border-radius: 12px; color: var(--rb-text); text-decoration: none; background: var(--rb-card);
}
.rb-pager a:hover { background: #e7e9ed; }
.rb-pager b, .rb-pager span.current { background: var(--rb-text); color: #fff; }

/* ---------- Статья (слайд 5) ---------- */
.rb-article {
	background: var(--rb-card);
	border-radius: var(--rb-radius);
	padding: 56px clamp(20px, 7%, 100px) 48px;
	max-width: 1000px;
	margin: 0 auto;
}
.rb-article__head, .rb-content, .rb-article__share { max-width: 760px; margin-left: auto; margin-right: auto; }
/* отступ после заголовка — на обёртке: стили шаблона сайта сбрасывают margin у h1 */
.rb-article__head { padding-bottom: 40px; }
.rb-article__date { display: block; font-size: 15px; color: var(--rb-muted); margin-bottom: 12px; }
.rb-article__title {
	margin: 0;
	font-size: clamp(30px, 3.4vw, 48px);
	font-weight: 900;
	line-height: 1.1;
	color: var(--rb-text);
	overflow-wrap: anywhere;
}
.rb-article__cover { margin: 0 0 40px; }
.rb-article__cover img { display: block; width: 100%; height: auto; border-radius: var(--rb-radius); }

/* Текст: размер не растёт на ноутбуках — полоса текста не сужается (слайд 8) */
/* В шрифтах сайта «обычный» Uni Neue — это вес 500 (400 = Book, слишком тонкий для текста) */
.rb-content { font-size: 19px; line-height: 1.6; font-weight: 500; color: #1d1f23; overflow-wrap: break-word; }
.rb-content > *:first-child { margin-top: 0; }
.rb-content p { margin: 0 0 1em; }
.rb-content__lead { font-size: 22px; line-height: 1.5; font-weight: 500; }
.rb-content h2 { font-size: 30px; font-weight: 800; line-height: 1.2; margin: 1.6em 0 .6em; }
.rb-content h3 { font-size: 24px; font-weight: 700; line-height: 1.25; margin: 1.4em 0 .5em; }
/* старые статьи: размеры шрифта прописаны прямо в тексте — приводим к общему виду */
.rb-content span, .rb-content b, .rb-content strong { font-size: inherit !important; }
.rb-content b, .rb-content strong { font-weight: 700; }
.rb-content a { color: var(--rb-accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.rb-content img { max-width: 100%; height: auto; border-radius: var(--rb-radius-s); }
.rb-content table { width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: 17px; }
.rb-content td, .rb-content th { padding: 10px 12px; border: 1px solid var(--rb-line); vertical-align: top; }

/* Списки: с маркерами и номерами, на сером фоне (слайд 11 — полный вид списков в этапе 2) */
.rb-content ul, .rb-content ol { margin: 1.4em 0; padding: 24px 32px 24px 56px; background: var(--rb-bg); border-radius: var(--rb-radius-s); }
.rb-content ul { list-style: disc outside; }
.rb-content ol { list-style: decimal outside; }
.rb-content ul ul { list-style-type: circle; }
.rb-content li { display: list-item; margin-bottom: .5em; padding-left: 4px; }
.rb-content li::marker { color: var(--rb-accent); font-weight: 700; }
.rb-content li:last-child { margin-bottom: 0; }
.rb-content table ul, .rb-content table ol { background: none; padding: 0 0 0 20px; margin: 0; }

/* Обычная цитата из старых статей */
.rb-content blockquote { margin: 1.6em 0; padding: 4px 0 4px 24px; border-left: 4px solid var(--rb-accent); font-size: 21px; color: #2b2e33; }
.rb-content blockquote p:last-child { margin-bottom: 0; }

/* ---------- Блоки из редактора портала ---------- */

/* Цитата */
.rb-content .rim-quote {
	position: relative;
	margin: 2em 0;
	padding: 32px 36px 28px 72px;
	border: 0;
	border-radius: var(--rb-radius);
	background: var(--rb-bg);
	font-size: 22px;
	line-height: 1.45;
	font-weight: 500;
}
.rb-content .rim-quote::before {
	content: "«";
	position: absolute; left: 28px; top: 14px;
	font-size: 64px; line-height: 1; font-weight: 900; color: var(--rb-accent);
}
.rb-content .rim-quote footer { margin-top: 12px; font-size: 16px; font-weight: 400; color: var(--rb-muted); }

/* Галерея */
.rb-content .rim-gallery {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 12px;
	margin: 2em 0;
}
.rb-content .rim-gallery figure { margin: 0; }
.rb-content .rim-gallery img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--rb-radius-s); }
.rb-content .rim-gallery figcaption { margin-top: 6px; font-size: 14px; color: var(--rb-muted); }
.rb-content .rim-gallery figcaption:empty { display: none; }

/* Рекламная интеграция */
.rb-content .rim-ad {
	display: flex;
	align-items: center;
	gap: 28px;
	margin: 2em 0;
	padding: 24px;
	border-radius: var(--rb-radius);
	background: linear-gradient(135deg, #fff4e6 0%, #f3ecff 100%);
}
.rb-content .rim-ad > img { flex: 0 0 220px; width: 220px; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--rb-radius-s); }
.rb-content .rim-ad__body { flex: 1; min-width: 0; }
.rb-content .rim-ad__title { margin: 0 0 6px; font-size: 24px; font-weight: 800; line-height: 1.2; }
.rb-content .rim-ad__text { margin: 0 0 16px; font-size: 17px; color: #3a3e45; }
.rb-content .rim-ad__button {
	display: inline-block;
	padding: 12px 24px;
	border-radius: 999px;
	background: var(--rb-text);
	color: #fff !important;
	font-size: 16px;
	font-weight: 700;
	text-decoration: none !important;
}
.rb-content .rim-ad__button:hover { background: var(--rb-accent-dark); }

/* ---------- Поделиться ---------- */
.rb-article__share { display: flex; align-items: center; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--rb-line); }
.rb-article__share-label { font-size: 15px; color: var(--rb-muted); }

/* ---------- Другие статьи ---------- */
.rb-more { max-width: 1000px; margin: 56px auto 24px; }
.rb-more__title { margin: 0 0 24px; font-size: 32px; font-weight: 900; }

/* ---------- Адаптив ---------- */
@media (max-width: 1199px) {
	.rb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	/* боковые отступы страницы меньше — карточка статьи сама даёт поля */
	.section--p2.section-main.rb-main { padding-left: 12px; padding-right: 12px; }
	.rb-title { margin-left: 6px; }
	.rb-grid, .rb-grid--small { grid-template-columns: 1fr; gap: 32px; }
	.rb-card__title { font-size: 20px; }
	.rb-article { padding: 28px 18px 32px; border-radius: var(--rb-radius-s); }
	.rb-article__cover img { border-radius: var(--rb-radius-s); }
	.rb-content { font-size: 17px; }
	.rb-content__lead { font-size: 19px; }
	.rb-content h2 { font-size: 24px; }
	.rb-content ul, .rb-content ol { padding: 18px 18px 18px 40px; }
	.rb-content .rim-quote { padding: 24px 20px 20px 52px; font-size: 19px; }
	.rb-content .rim-quote::before { left: 16px; font-size: 48px; }
	.rb-content .rim-ad { flex-direction: column; align-items: stretch; padding: 18px; }
	.rb-content .rim-ad > img { width: 100%; flex-basis: auto; }
	.rb-more__title { font-size: 26px; }
}
