/* Тема сайта «Региональный кадровый центр» — НОВОСТИ В СТИЛЕ ОСНОВНОГО САЙТА.
   Подключается после site-rcc.css в layouts/rcc.php и layouts/rcc_home.php.
   Все правила — под скоупом `.rcc-news` (обёртка вокруг списка/страницы новости и
   блока новостей на главной РКЦ), чтобы не влиять на остальную (старую) вёрстку РКЦ.
   Значения — перенесены из публичных модулей основного сайта (site-base/site-controls/
   site-home/site-content/site-responsive), токены `--c-*` заданы на `.rcc-news`. */

/* ===== Токены основного сайта (на обёртке новостей) ===== */
.rcc-news {
  --c-blue: #0d4573;
  --c-blue-600: #15598f;
  --c-blue-100: #e8f1f9;
  --c-blue-50: #f3f8fc;
  --c-aqua: #1e7f8c;
  --c-green: #4a9a8f;
  --c-violet: #6d5ca0;
  --c-rose: #b26a8e;
  --c-sand: #b98a5a;
  --c-red: #c0392b;

  --c-dark: #15293d;
  --c-text: #2c3e50;
  --c-muted: #5b6d80;

  --c-border: #e3ebf2;
  --c-white: #fff;
  --c-surface: #fff;
  --c-surface-alt: #f2f6fa;
  --c-soft: #f2f6fa;
  --c-link: var(--c-blue);
  --c-link-hover: var(--c-blue-600);
  --c-focus: var(--c-blue-600);

  --font-main: "Roboto", "Segoe UI", Arial, sans-serif;
  --font-head: "Roboto", "Segoe UI", Arial, sans-serif;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 8px 24px rgba(13, 69, 115, .10);
  --shadow-lg: 0 16px 40px rgba(13, 69, 115, .14);
  --container: 1600px;

  color: var(--c-text);
}
.rcc-news *, .rcc-news *::before, .rcc-news *::after { box-sizing: border-box; }

.rcc-news .ic { width: 16px; height: 16px; flex: 0 0 auto; }
.rcc-news .img-cover { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Плейсхолдеры изображений */
.rcc-news .ph {
  background: linear-gradient(135deg, rgba(255,255,255,.25), rgba(255,255,255,0)), var(--c-blue-600);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.75);
  font-family: var(--font-head);
  font-weight: 600;
}
.rcc-news .ph::after { content: "изображение"; }
.rcc-news .ph[data-ph]::after { content: attr(data-ph); }
.rcc-news .ph[data-ph] {
  background-image: url('../img/news-placeholder.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--c-blue-600, #15598f);
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  letter-spacing: .01em;
  text-shadow: 0 1px 0 #fff, 0 0 12px rgba(255,255,255,.95);
}
.rcc-news .media--blue   { background-color: var(--c-blue-600); }
.rcc-news .media--aqua   { background-color: var(--c-aqua); }
.rcc-news .media--green  { background-color: var(--c-green); }
.rcc-news .media--violet { background-color: var(--c-violet); }
.rcc-news .media--rose   { background-color: var(--c-rose); }
.rcc-news .media--sand   { background-color: var(--c-sand); }

/* ===== Сетка секций ===== */
.rcc-news .container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 16px; }
.rcc-news .section { padding: 56px 0; }
.rcc-news .section--compact { padding: 40px 0; }
.rcc-news .section--soft { background: var(--c-blue-50); }
.rcc-news .section--flush { padding-top: 0; }
.rcc-news .section--tight { padding-top: 8px; }
.rcc-news .section--gap { padding-top: 24px; }

.rcc-news .section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}
.rcc-news .section-title { font-size: 1.75rem; font-weight: 800; margin: 0; color: var(--c-dark); }
.rcc-news .section-title--sm { font-size: 1.3125rem; }
.rcc-news .link-more { font-weight: 600; font-size: 0.90625rem; white-space: nowrap; }

/* ===== Кнопки ===== */
.rcc-news .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 0.90625rem;
  line-height: inherit;
  border: 0;
  border-radius: var(--radius-sm);
  padding: 13px 26px;
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
}
.rcc-news .btn:hover { text-decoration: none; transform: translateY(-1px); }
.rcc-news .btn--sm { padding: 10px 20px; font-size: 0.84375rem; }
.rcc-news .btn--primary { background: var(--c-blue); color: #fff; }
.rcc-news .btn--primary:hover { background: var(--c-blue-600); color: #fff; }
.rcc-news .btn--light { background: #fff; color: var(--c-blue); }
.rcc-news .btn--light:hover { background: var(--c-blue-50); color: var(--c-blue); }

.rcc-news .btn-text {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--c-link);
}
.rcc-news .btn-text:hover { color: var(--c-link-hover); text-decoration: none; }
.rcc-news .btn-text .ic { width: 16px; height: 16px; }

/* ===== Заголовок раздела / список новостей ===== */
.rcc-news .page-head {
  display: flex;
  align-items: baseline;
  gap: 18px;
  flex-wrap: wrap;
  padding: 14px 0 30px;
}
.rcc-news .page-title { font-size: 2.125rem; font-weight: 800; margin: 0; letter-spacing: -.3px; color: var(--c-dark); }
.rcc-news .page-head__note { color: var(--c-muted); font-size: 0.875rem; }
.rcc-news .page-head--filter { align-items: center; padding-bottom: 22px; }
.rcc-news .page-head--slim { padding-bottom: 14px; }

.rcc-news .news-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-left: auto; }
.rcc-news .news-filter__chip {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 8px 8px 8px 16px;
  border: 1px solid var(--c-border);
  border-radius: 999px;
  background: var(--c-surface);
  font-size: 0.90625rem;
  font-weight: 600;
  color: var(--c-text);
  line-height: 1.2;
  transition: border-color .15s ease, color .15s ease, background .15s ease, box-shadow .15s ease;
}
.rcc-news .news-filter__chip:hover {
  border-color: var(--c-link);
  color: var(--c-link);
  background: var(--c-blue-50);
  text-decoration: none;
}
.rcc-news .news-filter__chip:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 2px; }
.rcc-news .news-filter__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 25px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--c-blue-50);
  color: var(--c-muted);
  font-size: 0.78125rem;
  font-weight: 700;
}
.rcc-news .news-filter__chip.is-active {
  border-color: transparent;
  background: linear-gradient(135deg, var(--c-blue) 0%, var(--c-blue-600) 100%);
  color: #fff;
  box-shadow: 0 6px 16px rgba(13, 69, 115, .18);
}
.rcc-news .news-filter__chip.is-active:hover { color: #fff; }
.rcc-news .news-filter__chip.is-active .news-filter__count { background: rgba(255, 255, 255, .24); color: #fff; }

/* ===== Блок новостей на главной (featured + список) ===== */
.rcc-news .events { display: grid; grid-template-columns: 1.1fr .9fr; gap: 24px; align-items: stretch; }
.rcc-news .events--split { grid-template-columns: 1.1fr .9fr; align-items: stretch; }
.rcc-news .events__side { display: flex; flex-direction: column; gap: 14px; }

.rcc-news .event {
  display: flex;
  gap: 18px;
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  padding: 20px 22px;
  transition: box-shadow .2s;
}
.rcc-news .event:hover { box-shadow: var(--shadow); }
.rcc-news .event--featured { border-left: 5px solid var(--c-blue); height: 100%; position: relative; }
.rcc-news .event--news { flex-direction: column; padding: 0; gap: 0; overflow: hidden; }
.rcc-news .events--split .event--news { height: 100%; }

.rcc-news .event__news-media {
  aspect-ratio: 3 / 1;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  background-color: var(--c-blue-100);
}
.rcc-news .event__news-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rcc-news .event__news-media--ph { background-image: url('../img/news-1.svg'); }
.rcc-news .event__news-wrap { display: flex; flex-direction: column; gap: 16px; padding: 20px 22px; }
.rcc-news .event--news .event__news-wrap { flex: 1 1 auto; }
.rcc-news .event__news-top { display: flex; align-items: center; gap: 16px; }

.rcc-news .event__date {
  flex: 0 0 76px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--c-blue-50);
  border-radius: var(--radius-sm);
  padding: 12px 8px;
  text-align: center;
  align-self: flex-start;
  min-height: 76px;
}
.rcc-news .event__date b { font-family: var(--font-head); font-size: 1.5rem; font-weight: 800; color: var(--c-link); line-height: 1; }
.rcc-news .event__date span { font-size: 0.75rem; color: var(--c-muted); margin-top: 3px; text-transform: lowercase; }
.rcc-news .event--news .event__date { flex: 0 0 76px; width: 76px; height: 76px; padding: 8px 6px; }
.rcc-news .event--news .event__date span { font-size: 0.6875rem; }

.rcc-news .event__body { flex: 1; min-width: 0; }
.rcc-news .event__title { font-size: 1.0625rem; font-weight: 700; margin: 0 0 8px; line-height: 1.35; }
.rcc-news .event__title a { color: var(--c-dark); }
.rcc-news .event__title a:hover { color: var(--c-link); text-decoration: none; }
.rcc-news .event--news .event__title { font-size: 1.375rem; line-height: 1.3; margin: 0; min-width: 0; }
.rcc-news .event__text { font-size: 0.875rem; color: var(--c-muted); margin: 0 0 14px; }
.rcc-news .event--news .event__text { margin: 0; text-align: justify; }
.rcc-news .event--news .btn { align-self: flex-start; margin-top: auto; }

/* Карточки правой колонки новостей — ярлык даты строго квадрат, текст по центру высоты */
.rcc-news .events__side .event { align-items: center; flex: 1 1 0; }
.rcc-news .events__side .event .event__date {
  flex: 0 0 76px;
  width: 76px;
  height: 76px;
  min-height: 76px;
  padding: 8px 6px;
  align-self: center;
}
.rcc-news .events__side .event .event__date span { font-size: 0.6875rem; }
.rcc-news .events__side .event .event__body { display: flex; flex-direction: column; justify-content: center; }
.rcc-news .events__side .event .event__title { width: 100%; margin-bottom: 0; }

/* ===== Сетка карточек новостей ===== */
.rcc-news .news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; }
.rcc-news .news-card { display: flex; flex-direction: column; gap: 12px; }
.rcc-news .news-card__media {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
  display: block;
}
.rcc-news .news-card__media.ph { display: flex; }
.rcc-news .news-card__media.ph::after { font-size: 1.25rem; }
.rcc-news .news-card__date {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--c-muted);
  text-transform: uppercase;
  letter-spacing: .5px;
}
.rcc-news .news-card__title { font-size: 1.125rem; font-weight: 700; line-height: 1.35; margin: 0; }
.rcc-news .news-card__title a { color: var(--c-dark); }
.rcc-news .news-card__title a:hover { color: var(--c-link); text-decoration: none; }
.rcc-news .news-card__text { font-size: 0.90625rem; color: var(--c-muted); margin: 0; flex: 1; text-align: justify; }
.rcc-news .news-pin {
  align-self: flex-start;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--c-blue);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: .02em;
}
.rcc-news .news-card--pinned .news-card__media { box-shadow: 0 0 0 3px var(--c-blue-100); }

/* ===== Пейджер ===== */
.rcc-news .pager { display: flex; align-items: center; gap: 8px; margin-top: 42px; flex-wrap: wrap; }
.rcc-news .pager a,
.rcc-news .pager .is-current {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 8px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.90625rem;
  color: var(--c-text);
  border: 1px solid var(--c-border);
  background: var(--c-surface);
}
.rcc-news .pager a:hover { border-color: var(--c-link); color: var(--c-link); text-decoration: none; }
.rcc-news .pager .is-current { background: var(--c-blue); border-color: var(--c-blue); color: #fff; }
.rcc-news .pager__dots { color: var(--c-muted); padding: 0 4px; }

/* ===== Детальная новости ===== */
.rcc-news .article { max-width: none; }
.rcc-news .article__meta {
  display: flex;
  gap: 22px;
  flex-wrap: wrap;
  color: var(--c-muted);
  font-size: 0.84375rem;
  margin: 0 0 22px;
}
.rcc-news .article__meta span { display: inline-flex; align-items: center; gap: 7px; }
.rcc-news .article__meta .ic { width: 15px; height: 15px; }
.rcc-news .article__share { gap: 8px; }
.rcc-news .article__share-label { font-size: 0.8125rem; color: var(--c-muted); }
.rcc-news .article__share a {
  display: inline-flex; align-items: center; justify-content: center;
  width: auto; height: auto; border-radius: 0; background: none;
  color: var(--c-muted); transition: color .15s ease;
}
.rcc-news .article__share a:hover { background: none; color: var(--c-link); text-decoration: none; }
.rcc-news .article__share .ic { width: 16px; height: 16px; }

.rcc-news .article__lead {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--c-dark);
  line-height: 1.55;
  margin: 0 0 20px;
  text-align: justify;
}
.rcc-news .article__hero-img {
  width: 100%;
  max-width: 780px;
  margin: 0 auto 28px;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  overflow: hidden;
}
.rcc-news .article__hero-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rcc-news .article__hero-img.ph { display: flex; align-items: center; justify-content: center; text-align: center; }

.rcc-news .article__videos { margin: 28px 0 4px; display: flex; flex-direction: column; gap: 20px; }
.rcc-news .article__video { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; }
.rcc-news .article__video iframe, .rcc-news .article__video video { display: block; width: 100%; height: 100%; border: 0; }
.rcc-news .article__video-link { margin: 8px 0; }

.rcc-news .article__tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 22px 0 4px; }
.rcc-news .article__tags-label { color: var(--c-muted); font-size: .875rem; }
.rcc-news .article__tag {
  display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 999px;
  background: var(--c-blue-50); color: var(--c-blue); font-size: .85rem; font-weight: 600; text-decoration: none;
}
.rcc-news .article__tag:hover { background: var(--c-blue-100); text-decoration: none; }

/* Боковое меню и колонки */
.rcc-news .page-layout { display: flex; align-items: flex-start; gap: 36px; }
.rcc-news .page-side { flex: 0 0 264px; min-width: 0; align-self: flex-start; }
.rcc-news .page-side--gallery { position: static; max-height: none; overflow: visible; }
.rcc-news .page-layout__body { flex: 1 1 auto; min-width: 0; }
.rcc-news .side-menu {
  border: 1px solid var(--c-border); border-radius: var(--radius); background: var(--c-surface);
  overflow: hidden; box-shadow: var(--shadow);
}
.rcc-news .side-menu__title {
  display: block; padding: 14px 16px; font-family: var(--font-head);
  font-size: 0.875rem; font-weight: 800; color: var(--c-dark);
  background: var(--c-blue-50); border-bottom: 1px solid var(--c-border); text-decoration: none;
}
.rcc-news .side-menu__list { list-style: none; margin: 0; padding: 6px 0; }
.rcc-news .side-menu__link {
  display: block; padding: 9px 16px; font-size: 0.8125rem; font-weight: 600;
  line-height: 1.35; color: var(--c-text); text-decoration: none;
  border-left: 3px solid transparent; text-align: justify;
}
.rcc-news .side-menu__link:hover { color: var(--c-link); background: var(--c-blue-50); }

/* Галерея доп. фото новости */
.rcc-news .news-gallery { display: flex; flex-direction: column; gap: 12px; }
.rcc-news .news-gallery__img {
  display: block; width: 100%; height: auto;
  border-radius: var(--radius-sm);
  cursor: zoom-in;
  position: relative;
  transform-origin: right center;
  transition: transform .2s ease, box-shadow .2s ease;
  will-change: transform;
}
.rcc-news .news-gallery__img:hover {
  transform: scale(2.5);
  z-index: 60;
  box-shadow: 0 18px 50px rgba(10, 25, 45, .4);
}

/* ===== Контент статьи (canon-классы из site-content.css) ===== */
.rcc-news .content { max-width: none; }
.rcc-news .content a { text-decoration: underline; text-underline-offset: 2px; }
.rcc-news .content a:hover { text-decoration: none; }
.rcc-news .content h1 { font-size: 1.875rem; color: var(--c-dark); }
.rcc-news .content h2 { font-size: 1.5rem; margin: 32px 0 14px; color: var(--c-dark); }
.rcc-news .content h3 { font-size: 1.25rem; margin: 26px 0 12px; color: var(--c-dark); }
.rcc-news .content h4 { font-size: 1.125rem; margin: 22px 0 10px; color: var(--c-dark); }
.rcc-news .content h5 { font-size: 1rem; margin: 18px 0 8px; color: var(--c-dark); }
.rcc-news .content h6 { font-size: 0.9375rem; margin: 16px 0 8px; color: var(--c-dark); }
.rcc-news .content > :first-child { margin-top: 0; }
.rcc-news .content > :last-child { margin-bottom: 0; }
.rcc-news .content p { margin: 0 0 14px; font-size: 1rem; }
.rcc-news .content ul, .rcc-news .content ol { padding-left: 1.4em; margin: 0 0 14px; }
.rcc-news .content li { margin-bottom: 6px; }
.rcc-news .content blockquote {
  margin: 18px 0; padding: 12px 18px;
  border-left: 4px solid var(--c-blue-100); background: var(--c-surface-alt);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.rcc-news .content hr { margin: 26px 0; border: 0; border-top: 1px solid var(--c-border); }
.rcc-news .content img { max-width: 100%; height: auto; border-radius: var(--radius-sm); }
.rcc-news .content figure { margin: 18px 0; }
.rcc-news .content figure img { display: block; }
.rcc-news .content figcaption { margin-top: 8px; font-size: 0.8125rem; color: var(--c-muted); }
.rcc-news .content .content-img-center { display: block; width: 300px; height: auto; max-width: 100%; margin: 0 auto 14px; }
.rcc-news .content table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 0.8125rem; }
.rcc-news .content th, .rcc-news .content td { vertical-align: top; padding: 6px 10px; line-height: 1.4; border: 1px solid var(--c-border); }
.rcc-news .content th { background: var(--c-surface-alt); font-weight: 600; }

/* ===== Адаптивность ===== */
@media (max-width: 1024px) {
  .rcc-news .news-grid { grid-template-columns: repeat(2, 1fr); }
  .rcc-news .events, .rcc-news .events--split { grid-template-columns: 1fr; }
  .rcc-news .page-layout { flex-direction: column; gap: 24px; align-items: stretch; }
  .rcc-news .page-side { flex: 1 1 auto; width: 100%; }
  .rcc-news .page-layout__body { width: 100%; }
}
@media (max-width: 768px) {
  .rcc-news .page-title { font-size: 1.625rem; }
  .rcc-news .news-grid { grid-template-columns: 1fr; }
  .rcc-news .pager { justify-content: center; }
  .rcc-news .event { flex-direction: column; }
  .rcc-news .event__date { flex-basis: auto; min-height: 0; flex-direction: row; gap: 8px; align-self: flex-start; }
  .rcc-news .events__side .event { align-items: stretch; }
  .rcc-news .events__side .event .event__date { flex: 0 0 auto; width: auto; height: auto; min-height: 0; align-self: flex-start; padding: 6px 10px; }
}
