/*
 * Razem Blog — theme styles.
 * Measurements follow the Figma frames "2.1.1 L/S" (list) and "2.2.1 L/S" (article):
 * desktop at 1440px, mobile at 320px. Breakpoint between them: 782px (WP columns).
 */

:root {
	--razem-gutter: 16px;
	--razem-radius: 12px;
	--razem-text: #374354;
	--razem-contrast: #151a29;
	--razem-muted: #8fa0b5;
	--razem-muted-dark: #606d83;
	--razem-accent: #e53b34;
	--razem-link: #1a91eb;
	--razem-night: #10121a;
	--razem-surface: #f5f6fb;
	--razem-border: #dfe3e9;
	--razem-sunset: linear-gradient(105deg, #e57738 0%, #e53b35 100%);
	--razem-sunset-round: linear-gradient(135deg, #e56a38 0%, #e54434 100%);
	--razem-ocean: linear-gradient(65deg, #2f8bc8 0%, #4267ab 100%);
	--razem-dusk: linear-gradient(90deg, #476f9f 0%, #5c4b83 100%);
	--razem-ico-calendar: url(../icons/calendar-days.svg);
	--razem-ico-eye: url(../icons/eye.svg);
	--razem-ico-external: url(../icons/arrow-up-right-from-square.svg);
	--razem-ico-plus: url(../icons/plus.svg);
	--razem-ico-viber: url(../icons/viber-circle.svg);
	--razem-ico-telegram: url(../icons/telegram-circle.svg);
}

@media (min-width: 782px) {
	:root {
		--razem-gutter: 32px;
	}
}

/* Header, main and footer touch each other; spacing is set inside them. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
}

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

/* Mask icon helper: element::before takes the current text colour. */
.razem-meta__date::before,
.razem-views::before,
.razem-footer__ext a::before,
.is-style-razem-viber .wp-block-button__link::before,
.is-style-razem-telegram .wp-block-button__link::before,
.is-style-razem-dusk .wp-block-button__link::before {
	content: "";
	flex: none;
	background-color: currentColor;
	-webkit-mask: var(--razem-ico) center / contain no-repeat;
	mask: var(--razem-ico) center / contain no-repeat;
}

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

.razem-header {
	position: relative;
	z-index: 20;
	background: #fff;
}

.razem-header__inner {
	box-sizing: content-box;
	max-width: 1224px;
	min-height: 88px;
	margin-inline: auto;
	padding-inline: var(--razem-gutter);
	gap: 24px;
}

.razem-brand {
	gap: 0;
	align-items: center;
}

.razem-brand .razem-brand__logo {
	flex: none;
	margin: 0;
	line-height: 0;
}

.razem-brand__logo img {
	display: block;
	width: 176px !important;
	height: 56px !important;
}

/*
 * "СТАТЬИ": in Figma the text box sits at y=34–58 and the divider at y=33–57, i.e. a bit
 * below the logo's centre, so both are positioned from the centred box rather than centred.
 */
.razem-brand .razem-brand__section {
	position: relative;
	top: 3px;
	margin: 0 0 0 14px;
	padding-left: 14px;
	font-size: 16px;
	line-height: 24px;
	font-weight: 300;
	letter-spacing: 0.03em;
	text-transform: uppercase;
	white-space: nowrap;
}

.razem-brand__section::before {
	content: "";
	position: absolute;
	left: 0;
	top: -2px;
	width: 1px;
	height: 24px;
	background: #151b29;
}

.razem-brand__section a {
	color: #000;
}

.razem-brand__section a:hover {
	color: var(--razem-accent);
	text-decoration: none;
}

.razem-nav,
.razem-nav .wp-block-navigation__container {
	gap: 40px;
}

.razem-header__inner > .razem-nav {
	margin-left: auto;
}

/* Language switcher: "Рус ▾" with a dropdown, like the razem.work header.
   Selectors start at .razem-header__inner to beat core's `.is-layout-flex > :is(*, div) { margin: 0 }`. */
.razem-lang {
	position: relative;
	font-size: 16px;
	line-height: 24px;
}

/* 16px + the 24px flex gap = the 40px rhythm of the menu items. */
.razem-header__inner > .razem-lang {
	order: 3;
	margin-left: 16px;
}

.razem-lang__current {
	display: flex;
	align-items: center;
	gap: 4px;
	padding: 4px 0;
	color: var(--razem-text);
	cursor: pointer;
	list-style: none;
	user-select: none;
}

.razem-lang__current::-webkit-details-marker {
	display: none;
}

.razem-lang__current::after {
	content: "";
	width: 10px;
	height: 16px;
	background: currentColor;
	-webkit-mask: url(../icons/caret-down.svg) center / 10px 16px no-repeat;
	mask: url(../icons/caret-down.svg) center / 10px 16px no-repeat;
	transition: transform 0.15s ease;
}

.razem-lang__details[open] .razem-lang__current::after {
	transform: rotate(180deg);
}

.razem-lang__current:hover {
	color: var(--razem-accent);
}

.razem-lang__list {
	position: absolute;
	right: -16px;
	top: calc(100% + 8px);
	z-index: 30;
	min-width: 88px;
	margin: 0;
	padding: 8px 0;
	list-style: none;
	border-radius: 8px;
	background: #fff;
	box-shadow: 0 1px 2px rgba(21, 26, 41, 0.06), 0 8px 24px rgba(21, 26, 41, 0.12);
}

.razem-lang__list a {
	display: block;
	padding: 6px 16px;
	color: var(--razem-text);
}

.razem-lang__list a:hover {
	background: var(--razem-surface);
	text-decoration: none;
}

.razem-lang__list a[aria-current] {
	color: var(--razem-accent);
}

.razem-nav {
	font-size: 16px;
	line-height: 24px;
}

.razem-nav .wp-block-navigation-item__content {
	color: var(--razem-text);
}

.razem-nav .wp-block-navigation-item__content:hover {
	color: var(--razem-accent);
	text-decoration: none;
}

.razem-nav .wp-block-navigation__responsive-container-open {
	color: var(--razem-muted);
}

.razem-nav .wp-block-navigation__responsive-container.is-menu-open {
	padding: 24px var(--razem-gutter);
}

.razem-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container {
	gap: 24px;
	font-size: 20px;
	line-height: 28px;
}

@media (max-width: 781px) {
	.razem-header {
		box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
	}

	.razem-header__inner {
		min-height: 48px;
		gap: 12px;
	}

	.razem-brand__logo img {
		width: 128px !important;
		height: 40px !important;
	}

	/* Figma 320: divider x=154, y=16–33; caps 12px with 3% tracking from x=165. */
	.razem-brand .razem-brand__section {
		top: 2px;
		margin-left: 10px;
		padding-left: 10px;
		font-size: 12px;
		line-height: 17px;
		letter-spacing: 0.02em;
	}

	.razem-brand__section::before {
		top: -2px;
		height: 17px;
	}

	.razem-lang {
		font-size: 14px;
	}

	.razem-lang__list {
		right: -8px;
	}
}

/*
 * Below 1024px the three menu items plus the language switcher no longer fit next to the
 * logo (they wrap at 782px), so the menu collapses into the hamburger. Core only does that
 * below 600px. Order on these widths: logo, language switcher, hamburger.
 */
@media (max-width: 1023px) {
	.razem-nav .wp-block-navigation__responsive-container-open:not(.always-shown) {
		display: flex;
	}

	.razem-nav .wp-block-navigation__responsive-container:not(.hidden-by-default):not(.is-menu-open) {
		display: none;
	}

	.razem-header__inner > .razem-lang {
		order: 0;
		margin-left: auto;
	}

	.razem-header__inner > .razem-nav {
		margin-left: 0;
	}
}

/* ---------------------------------------------------------------- Shared: breadcrumbs, meta, titles */

.razem-breadcrumbs {
	font-size: 16px;
	line-height: 28px;
	color: var(--razem-muted);
}

.razem-breadcrumbs a {
	color: var(--razem-muted);
}

.razem-breadcrumbs a:hover {
	color: var(--razem-accent);
	text-decoration: none;
}

.razem-breadcrumbs__sep {
	margin-inline: 8px;
}

.razem-meta {
	gap: 32px;
	align-items: center;
}

.razem-meta__date,
.razem-views {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	margin: 0;
	font-size: 16px;
	line-height: 24px;
	color: var(--razem-muted);
}

.razem-meta__date::before,
.razem-views::before {
	width: 24px;
	height: 24px;
	-webkit-mask-size: 16px 16px;
	mask-size: 16px 16px;
}

.razem-meta__date::before {
	--razem-ico: var(--razem-ico-calendar);
}

.razem-views::before {
	--razem-ico: var(--razem-ico-eye);
}

.razem-main {
	padding-bottom: 80px;
}

/* ---------------------------------------------------------------- Archive / blog list */

.razem-archive {
	padding-bottom: 0;
}

.razem-archive .razem-archive__title {
	margin-top: 24px;
	font-size: 40px;
	line-height: 48px;
	font-weight: 500;
	text-wrap: balance;
}

.razem-archive .razem-breadcrumbs {
	margin-top: 40px;
}

.razem-archive .razem-posts {
	margin-top: 32px;
}

.razem-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 40px 24px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.razem-grid > li {
	margin: 0;
}

.razem-posts--featured .razem-grid > li:first-child {
	grid-column: 1 / -1;
}

.razem-card {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.razem-card > * {
	margin-block: 0;
}

.razem-card .razem-card__image {
	margin: 0;
}

.razem-card__image a {
	display: block;
}

.razem-card__image img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 496 / 280;
	object-fit: cover;
	border-radius: var(--razem-radius);
}

.razem-posts--featured .razem-grid > li:first-child .razem-card__image img {
	aspect-ratio: 1016 / 480;
}

.razem-card .razem-card__title {
	font-size: 32px;
	line-height: 40px;
	font-weight: 400;
}

.razem-card__title a {
	color: var(--razem-contrast);
}

.razem-card__title a:hover {
	color: var(--razem-accent);
	text-decoration: none;
}

.razem-card .razem-card__excerpt {
	font-size: 18px;
	line-height: 26px;
	color: var(--razem-text);
}

.razem-card__excerpt p {
	margin: 0;
}

.razem-card__excerpt .wp-block-post-excerpt__more-text {
	display: none;
}

.razem-pagination {
	margin-top: 64px;
}

.razem-pagination .wp-block-query-pagination-numbers {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 8px;
	margin: 0;
}

.razem-pagination .page-numbers {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 48px;
	height: 40px;
	margin: 0;
	padding: 0 7px;
	border: 1px solid var(--razem-border);
	border-radius: 8px;
	font-size: 20px;
	line-height: 28px;
	color: var(--razem-contrast);
}

.razem-pagination a.page-numbers:hover {
	border-color: var(--razem-accent);
	color: var(--razem-accent);
	text-decoration: none;
}

.razem-pagination .page-numbers.current {
	background: var(--razem-accent);
	border-color: var(--razem-accent);
	color: #fff;
}

.razem-no-results {
	padding: 40px 0;
}

@media (max-width: 781px) {
	.razem-archive .razem-archive__title {
		margin-top: 32px;
		font-size: 24px;
		line-height: 32px;
		text-align: center;
	}

	.razem-archive .razem-breadcrumbs {
		margin-top: 32px;
	}

	.razem-grid {
		grid-template-columns: minmax(0, 1fr);
		gap: 32px;
	}

	.razem-card__image img,
	.razem-posts--featured .razem-grid > li:first-child .razem-card__image img {
		aspect-ratio: 288 / 176;
	}

	.razem-card .razem-card__title {
		font-size: 24px;
		line-height: 30px;
	}

	.razem-card .razem-card__excerpt {
		font-size: 14px;
		line-height: 20px;
	}

	.razem-pagination {
		margin-top: 40px;
	}
}

/* ---------------------------------------------------------------- Messenger banner above the footer */

.razem-main .razem-channels {
	position: relative;
	z-index: 2;
	margin-top: 80px;
	margin-bottom: -174px;
	padding: 64px 24px;
	border-radius: 24px;
	background: var(--razem-sunset);
	color: #fff;
	text-align: center;
}

.razem-channels > * {
	margin-block: 0;
}

.razem-channels .razem-channels__title {
	font-size: 32px;
	line-height: 40px;
	font-weight: 500;
	color: #fff;
}

.razem-channels .razem-channels__text {
	max-width: 570px;
	margin: 36px auto 0;
	font-size: 20px;
	line-height: 28px;
}

.razem-channels .razem-channel-buttons {
	margin-top: 36px;
	justify-content: center;
	gap: 16px;
}

.razem-channels .wp-block-button__link {
	width: 288px;
}

.razem-main:has(.razem-channels) ~ .wp-block-template-part .razem-footer {
	padding-top: 254px;
}

@media (max-width: 781px) {
	.razem-main .razem-channels {
		margin: 64px calc(-1 * var(--razem-gutter)) 0 !important;
		max-width: none !important;
		padding: 44px 16px 40px;
		border-radius: 0;
		text-align: left;
	}

	.razem-channels .razem-channels__text {
		max-width: 250px;
		margin: 32px 0 0;
		font-size: 16px;
		line-height: 24px;
	}

	.razem-channels .razem-channel-buttons {
		margin-top: 32px;
		flex-direction: column;
		align-items: stretch;
	}

	.razem-channels .wp-block-button,
	.razem-channels .wp-block-button__link {
		width: 100%;
	}

	.razem-main:has(.razem-channels) ~ .wp-block-template-part .razem-footer {
		padding-top: 40px;
	}
}

/* ---------------------------------------------------------------- Buttons */

.wp-block-button.is-style-razem-viber .wp-block-button__link,
.wp-block-button.is-style-razem-telegram .wp-block-button__link,
.razem-footer .razem-button-red .wp-block-button__link {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	min-height: 48px;
	padding: 12px 24px;
	border-radius: 8px;
	font-size: 16px;
	line-height: 24px;
	font-weight: 500;
	color: #fff;
}

.wp-block-button.is-style-razem-viber .wp-block-button__link {
	background: #78509b;
}

.wp-block-button.is-style-razem-telegram .wp-block-button__link {
	background: #459ac5;
}

.is-style-razem-viber .wp-block-button__link::before,
.is-style-razem-telegram .wp-block-button__link::before {
	width: 24px;
	height: 24px;
	background-color: #fff;
}

.is-style-razem-viber .wp-block-button__link::before {
	--razem-ico: var(--razem-ico-viber);
}

.is-style-razem-telegram .wp-block-button__link::before {
	--razem-ico: var(--razem-ico-telegram);
}

.wp-block-button.is-style-razem-dusk .wp-block-button__link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 16px 32px;
	border-radius: 8px;
	background: var(--razem-dusk);
	font-size: 20px;
	line-height: 24px;
	font-weight: 500;
	color: #fff;
}

.is-style-razem-dusk .wp-block-button__link::before {
	--razem-ico: var(--razem-ico-plus);
	width: 24px;
	height: 24px;
	-webkit-mask-size: 18px 18px;
	mask-size: 18px 18px;
}

.wp-block-button[class*="is-style-razem-"] .wp-block-button__link:hover,
.razem-footer .razem-button-red .wp-block-button__link:hover {
	filter: brightness(1.08);
	text-decoration: none;
}

/* ---------------------------------------------------------------- Chat-bot card (sidebar + inline on phones) */

.razem-bot-card {
	box-sizing: border-box;
	padding: 20px 16px 24px;
	border-radius: var(--razem-radius);
	background: var(--razem-surface);
	color: var(--razem-text);
}

.razem-bot-card > * {
	margin-block: 0;
}

.razem-bot-card .razem-bot-card__head {
	gap: 16px;
	align-items: flex-start;
}

.razem-bot-card .razem-bot-card__icon {
	margin: 2px 0 0;
	flex: none;
	line-height: 0;
}

.razem-bot-card__icon img {
	width: 48px !important;
	height: 48px !important;
}

.razem-bot-card .razem-bot-card__title {
	margin: 0;
	font-size: 20px;
	line-height: 26px;
	font-weight: 500;
}

.razem-bot-card .razem-bot-card__text {
	margin-top: 20px;
	font-size: 14px;
	line-height: 20px;
}

.razem-bot-card .razem-channel-buttons {
	margin-top: 20px;
	flex-direction: column;
	align-items: stretch;
	gap: 8px;
}

.razem-bot-card .wp-block-button,
.razem-bot-card .wp-block-button__link {
	width: 100%;
}

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

.razem-single .razem-breadcrumbs {
	margin-top: 16px;
}

.razem-single .razem-single__cover {
	margin-top: 32px;
}

.razem-single__cover img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 1016 / 480;
	object-fit: cover;
	border-radius: var(--razem-radius);
}

.razem-single .razem-single__columns {
	margin-top: 28px;
	margin-bottom: 0;
	gap: 24px;
	flex-wrap: nowrap;
	align-items: stretch;
}

/* Core gives every column flex-basis:0 with a :not() selector; fixed widths need to win over it. */
.wp-block-columns.razem-single__columns > .wp-block-column.razem-article {
	flex: 0 1 704px !important;
	min-width: 0;
}

.wp-block-columns.razem-single__columns > .wp-block-column.razem-aside {
	flex: 0 0 288px !important;
}

.razem-article > * {
	margin-block: 0;
}

.razem-aside .razem-bot-card {
	position: sticky;
	top: 24px;
}

.admin-bar .razem-aside .razem-bot-card {
	top: 56px;
}

.razem-article .razem-article__title {
	font-size: 40px;
	line-height: 48px;
	font-weight: 500;
	text-align: center;
	text-wrap: balance;
}

.razem-article .razem-meta--center {
	margin-top: 40px;
	justify-content: center;
}

.razem-article .wp-block-post-content {
	margin-top: 40px;
}

.razem-article .razem-article__footer {
	margin-top: 32px;
	align-items: center;
}

.razem-related {
	margin-top: 64px;
}

.razem-related:not(:has(.razem-card)) {
	display: none;
}

.razem-related > * {
	margin-block: 0;
}

.razem-related .razem-related__title {
	font-size: 32px;
	line-height: 40px;
	font-weight: 400;
}

.razem-related .razem-posts--related {
	margin-top: 40px;
}

@media (max-width: 781px) {
	.razem-single .razem-breadcrumbs {
		margin-top: 24px;
		line-height: 22px;
	}

	.razem-single .razem-single__cover {
		margin-top: 24px;
	}

	.razem-single__cover img {
		aspect-ratio: 288 / 172;
	}

	.razem-single .razem-single__columns {
		margin-top: 28px;
		flex-direction: column;
	}

	.wp-block-columns.razem-single__columns > .wp-block-column.razem-article {
		flex: 1 1 auto !important;
	}

	.wp-block-columns.razem-single__columns > .wp-block-column.razem-aside {
		display: none;
	}

	.razem-article .razem-article__title {
		font-size: 24px;
		line-height: 30px;
		font-weight: 400;
	}

	.razem-article .razem-meta--center {
		margin-top: 20px;
	}

	.razem-article .wp-block-post-content {
		margin-top: 24px;
	}

	.razem-related .razem-posts--related {
		margin-top: 32px;
	}
}

/* ---------------------------------------------------------------- Article body */

.wp-block-post-content {
	font-size: 18px;
	line-height: 28px;
	color: var(--razem-text);
}

.wp-block-post-content > * {
	margin-block: 12px 0;
}

.wp-block-post-content > :first-child {
	margin-block-start: 0;
}

.wp-block-post-content strong,
.wp-block-post-content b {
	font-weight: 700;
}

.wp-block-post-content > h2 {
	margin-top: 48px;
	font-size: 32px;
	line-height: 40px;
	font-weight: 500;
}

.wp-block-post-content > h3 {
	margin-top: 40px;
	font-size: 24px;
	line-height: 32px;
}

.wp-block-post-content > :where(h2, h3) + * {
	margin-top: 32px;
}

.wp-block-post-content > :is(ul, ol) {
	margin-top: 24px;
}

.wp-block-post-content > :where(ul, ol) + * {
	margin-top: 32px;
}

.wp-block-post-content > .wp-block-image {
	margin-top: 40px;
}

.wp-block-post-content > :where(.wp-block-image) + * {
	margin-top: 32px;
}

.wp-block-post-content img {
	border-radius: var(--razem-radius);
}

.wp-block-post-content > .razem-bot-card--inline {
	display: none;
}

/* Lists */

.wp-block-post-content ul:not([class*="is-style-"]) {
	display: flex;
	flex-direction: column;
	gap: 24px;
	padding-left: 24px;
	list-style: none;
}

.wp-block-post-content ul:not([class*="is-style-"]) > li {
	position: relative;
	padding-left: 19px;
	font-weight: 500;
}

.wp-block-post-content ul:not([class*="is-style-"]) > li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 12px;
	width: 5px;
	height: 5px;
	border-radius: 50%;
	background: var(--razem-accent);
}

.wp-block-post-content ol:not([class*="is-style-"]) {
	padding-left: 44px;
}

.wp-block-post-content ol:not([class*="is-style-"]) > li {
	font-weight: 500;
}

.wp-block-post-content ol:not([class*="is-style-"]) > li::marker {
	font-weight: 400;
}

ol.is-style-razem-steps,
ul.is-style-razem-steps {
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding-left: 24px;
	list-style: none;
	counter-reset: razem-step;
}

.is-style-razem-steps > li {
	position: relative;
	min-height: 28px;
	padding-left: 44px;
	font-weight: 500;
	counter-increment: razem-step;
}

.is-style-razem-steps > li::before {
	content: counter(razem-step);
	position: absolute;
	left: 2px;
	top: 2px;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--razem-sunset-round);
	color: #fff;
	font-size: 14px;
	line-height: 24px;
	font-weight: 400;
	text-align: center;
}

ol.is-style-razem-inline,
ul.is-style-razem-inline {
	display: flex;
	flex-wrap: wrap;
	gap: 16px 56px;
	padding-left: 24px;
	list-style: none;
	counter-reset: razem-inline;
}

.is-style-razem-inline > li {
	display: flex;
	align-items: center;
	gap: 12px;
	font-weight: 500;
	counter-increment: razem-inline;
}

ol.is-style-razem-inline > li::before {
	content: counter(razem-inline) ".";
	font-weight: 400;
}

.is-style-razem-inline img {
	width: 24px !important;
	height: 24px !important;
	object-fit: contain;
	border-radius: 0 !important;
}

ul.is-style-razem-plain,
ol.is-style-razem-plain {
	padding-left: 0;
	list-style: none;
}

/* Paragraph styles */

.is-style-razem-lead {
	font-weight: 500;
}

p.is-style-razem-highlight {
	color: var(--razem-accent);
	font-size: 24px;
	line-height: 32px;
	font-weight: 500;
}

/* Icon lists: image block styled as a gradient circle + text */

.wp-block-group.is-style-razem-icon-list {
	display: flex;
	flex-direction: column;
	gap: 24px;
	padding-left: 24px;
}

.wp-block-group.is-style-razem-icon-grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 32px 24px;
	padding-left: 24px;
}

.razem-icon-item {
	gap: 16px;
	align-items: center;
	flex-wrap: nowrap;
}

.razem-icon-item > *,
.is-style-razem-icon-list > *,
.is-style-razem-icon-grid > * {
	margin-block: 0 !important;
}

.razem-icon-item p {
	font-weight: 500;
}

.is-style-razem-icon-grid .razem-icon-item p {
	line-height: 26px;
}

.wp-block-image.is-style-razem-icon {
	flex: none;
	margin: 0;
	line-height: 0;
}

.wp-block-image.is-style-razem-icon img {
	box-sizing: border-box;
	width: 48px !important;
	height: 48px !important;
	padding: 12px;
	border-radius: 50% !important;
	background: var(--razem-sunset-round);
	object-fit: contain;
}

.wp-block-post-content > :is(.is-style-razem-icon-list, .is-style-razem-icon-grid) {
	margin-top: 24px;
}

.wp-block-post-content > .is-style-razem-icon-grid {
	margin-top: 32px;
}

.wp-block-post-content > :where(.is-style-razem-icon-list, .is-style-razem-icon-grid) + * {
	margin-top: 40px;
}

/* Banner, note, blue box, highlight: 48px of air around them */

.wp-block-post-content > :is(.is-style-razem-cta, .is-style-razem-info, .is-style-razem-note, .is-style-razem-highlight) {
	margin-top: 48px;
}

.wp-block-post-content > :where(.is-style-razem-cta, .is-style-razem-info, .is-style-razem-note, .is-style-razem-highlight) + * {
	margin-top: 48px;
}

.wp-block-group.is-style-razem-cta {
	padding: 48px 40px;
	border-radius: var(--razem-radius);
	background: var(--razem-sunset);
	color: #fff;
	text-align: center;
}

.is-style-razem-cta > * {
	margin-block: 0 !important;
}

.is-style-razem-cta .razem-cta__title {
	font-size: 32px;
	line-height: 40px;
	font-weight: 500;
	text-wrap: balance;
}

.is-style-razem-cta .razem-cta__text {
	max-width: 400px;
	margin: 32px auto 0 !important;
	font-size: 20px;
	line-height: 28px;
}

.is-style-razem-cta .wp-block-buttons {
	margin-top: 40px !important;
	justify-content: center;
}

.wp-block-group.is-style-razem-info {
	padding: 32px;
	border-radius: var(--razem-radius);
	background: var(--razem-ocean);
	color: #fff;
	font-size: 16px;
	line-height: 24px;
}

.is-style-razem-info > * {
	margin-block: 0;
}

.is-style-razem-info > * + * {
	margin-top: 12px;
}

.is-style-razem-info a {
	color: #fff;
	text-decoration: underline;
}

.wp-block-group.is-style-razem-note {
	gap: 32px;
	align-items: center;
	flex-wrap: nowrap;
	padding-left: 24px;
}

.is-style-razem-note > * {
	margin-block: 0;
}

.is-style-razem-note .razem-note__icon {
	flex: none;
	margin: 0;
	line-height: 0;
}

.razem-note__icon img {
	width: 64px !important;
	height: 64px !important;
	border-radius: 0 !important;
}

.razem-note__body {
	font-size: 16px;
	line-height: 24px;
}

.razem-note__body > * {
	margin-block: 0;
}

.razem-note__body > * + * {
	margin-top: 8px;
}

.razem-note__body .razem-note__title {
	color: var(--razem-accent);
	font-size: 18px;
	line-height: 28px;
	font-weight: 500;
}

.razem-article__footer {
	justify-content: space-between;
}

/*
 * The highlight hangs out to the left edge of the wide (1224px) container: 104px at 1440.
 * On narrower screens that edge moves in, so the overhang shrinks to whatever space is
 * left between the text column and the page gutter, down to 0.
 */
@media (min-width: 782px) {
	.wp-block-post-content > p.is-style-razem-highlight {
		margin-left: calc(-1 * clamp(0px, (100vw - 1016px) / 2 - var(--razem-gutter), 104px));
	}
}

@media (max-width: 781px) {
	.wp-block-post-content {
		font-size: 16px;
		line-height: 22px;
	}

	.wp-block-post-content > h2 {
		margin-top: 40px;
		font-size: 24px;
		line-height: 32px;
	}

	.wp-block-post-content > h3 {
		font-size: 20px;
		line-height: 28px;
	}

	.wp-block-post-content > :where(h2, h3) + * {
		margin-top: 20px;
	}

	.wp-block-post-content > .razem-bot-card--inline {
		display: block;
		margin-top: 32px;
	}

	.wp-block-post-content ul:not([class*="is-style-"]) {
		gap: 16px;
		padding-left: 0;
	}

	.wp-block-post-content ul:not([class*="is-style-"]) > li::before {
		top: 9px;
	}

	.is-style-razem-steps,
	ol.is-style-razem-steps {
		padding-left: 0;
		gap: 20px;
	}

	ol.is-style-razem-inline,
	ul.is-style-razem-inline {
		flex-direction: column;
		gap: 24px;
		padding-left: 0;
	}

	.wp-block-group.is-style-razem-icon-list,
	.wp-block-group.is-style-razem-icon-grid {
		display: flex;
		flex-direction: column;
		gap: 16px;
		padding-left: 0;
	}

	p.is-style-razem-highlight {
		font-size: 16px;
		line-height: 22px;
	}

	.wp-block-group.is-style-razem-cta {
		padding: 32px 16px 24px;
	}

	.is-style-razem-cta .razem-cta__title {
		font-size: 24px;
		line-height: 32px;
	}

	.is-style-razem-cta .razem-cta__text {
		margin-top: 20px !important;
		font-size: 16px;
		line-height: 22px;
	}

	.is-style-razem-cta .wp-block-buttons {
		margin-top: 24px !important;
	}

	.is-style-razem-cta .wp-block-button,
	.is-style-razem-cta .wp-block-button__link {
		width: 100%;
		justify-content: center;
	}

	.wp-block-button.is-style-razem-dusk .wp-block-button__link {
		padding: 12px 16px;
		font-size: 16px;
	}

	.wp-block-group.is-style-razem-info {
		padding: 24px 16px;
		font-size: 16px;
		line-height: 22px;
	}

	.wp-block-group.is-style-razem-note {
		flex-direction: column;
		align-items: stretch;
		gap: 24px;
		padding-left: 0;
	}

	.is-style-razem-note .razem-note__icon {
		align-self: center;
	}

	.razem-note__body {
		font-size: 16px;
		line-height: 22px;
	}
}

/* ---------------------------------------------------------------- Social links */

.wp-block-social-links.is-style-razem-dark,
.wp-block-social-links.is-style-razem-light {
	gap: 16px;
	margin: 0;
	padding: 0;
}

.wp-block-social-links.is-style-razem-dark .wp-social-link,
.wp-block-social-links.is-style-razem-light .wp-social-link {
	box-sizing: border-box;
	width: 40px;
	height: 40px;
	margin: 0;
	border-radius: 50%;
}

.wp-block-social-links.is-style-razem-dark .wp-social-link {
	border: 2px solid rgba(255, 255, 255, 0.05);
	background: transparent;
	color: #fff;
}

.wp-block-social-links.is-style-razem-light .wp-social-link {
	background: var(--razem-border);
	color: var(--razem-text);
}

.wp-block-social-links.is-style-razem-dark .wp-social-link a,
.wp-block-social-links.is-style-razem-light .wp-social-link a {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 0;
	color: inherit;
}

.wp-block-social-links.is-style-razem-dark .wp-social-link svg,
.wp-block-social-links.is-style-razem-light .wp-social-link svg {
	width: 18px;
	height: 18px;
	fill: currentColor;
}

/* The design uses the plain "f" mark, core ships the round logo. */
.wp-block-social-links:is(.is-style-razem-dark, .is-style-razem-light) .wp-social-link-facebook svg {
	visibility: hidden;
	position: absolute;
}

.wp-block-social-links:is(.is-style-razem-dark, .is-style-razem-light) .wp-social-link-facebook a::before {
	content: "";
	width: 16px;
	height: 16px;
	background-color: currentColor;
	-webkit-mask: url(../icons/facebook-f.svg) center / contain no-repeat;
	mask: url(../icons/facebook-f.svg) center / contain no-repeat;
}

.wp-block-social-links.is-style-razem-dark .wp-social-link:hover,
.wp-block-social-links.is-style-razem-light .wp-social-link:hover {
	transform: none;
	opacity: 0.85;
}

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

.razem-footer {
	margin: 0;
	padding: 64px var(--razem-gutter) 40px;
	background: var(--razem-night);
	color: #fff;
	font-size: 16px;
	line-height: 22px;
}

.razem-footer > * {
	max-width: 1224px;
	margin-inline: auto;
}

.razem-footer > * + * {
	margin-top: 0;
}

.razem-footer a {
	color: #fff;
}

.razem-footer a:hover {
	color: #fff;
	text-decoration: underline;
}

.razem-footer__top {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 288px));
	grid-template-rows: auto 1fr;
	grid-template-areas:
		"about  cities jobs"
		"social cities jobs";
	column-gap: clamp(24px, 9vw, 128px);
	row-gap: 32px;
}

/* pl has no city list on razem.work: move the vacancies into the middle column. */
.razem-footer__top:not(:has(.razem-footer__cities)) {
	grid-template-areas:
		"about  jobs ."
		"social jobs .";
}

.razem-footer__top > * {
	margin: 0 !important;
}

.razem-footer__about { grid-area: about; }
.razem-footer__social { grid-area: social; }
.razem-footer__cities { grid-area: cities; }
.razem-footer__jobs { grid-area: jobs; }

.razem-footer__about > *,
.razem-footer__social > *,
.razem-footer__cities > *,
.razem-footer__jobs > * {
	margin-block: 0;
}

.razem-footer__logo {
	margin: 0;
	line-height: 0;
}

.razem-footer__logo img {
	width: 188px !important;
	height: 42px !important;
}

.razem-footer .razem-footer__tagline {
	margin-top: 8px;
	max-width: 250px;
	font-size: 14px;
	line-height: 20px;
	color: var(--razem-muted-dark);
}

.razem-footer .razem-footer__social .wp-block-social-links {
	margin-top: 16px;
}

.razem-footer .razem-footer__heading {
	margin: 0 0 16px;
	font-size: 20px;
	line-height: 20px;
	font-weight: 400;
	color: #fff;
}

.razem-footer__list {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.razem-footer .razem-footer__ext {
	margin-top: 16px;
	gap: 12px;
}

.razem-footer__ext li {
	line-height: 24px;
}

.razem-footer .razem-footer__ext a {
	display: flex;
	width: fit-content;
	align-items: center;
	gap: 8px;
	color: var(--razem-link);
}

.razem-footer__ext a::before {
	--razem-ico: var(--razem-ico-external);
	width: 24px;
	height: 24px;
	-webkit-mask-size: 16px 16px;
	mask-size: 16px 16px;
}

.razem-footer .razem-footer__sep {
	margin-top: 48px;
	border: 0;
	border-top: 1px solid var(--razem-muted-dark);
	background: none;
	opacity: 1;
}

.razem-footer__bottom {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
	padding-block: 32px;
}

.razem-footer__bottom > * {
	margin: 0 !important;
}

.razem-footer__bottom p {
	margin: 0;
}

.razem-footer__bottom .razem-footer__email a {
	color: var(--razem-link);
}

.razem-footer__bottom .wp-block-buttons {
	margin-top: 16px;
	gap: 24px;
	flex-wrap: nowrap;
}

.razem-footer__bottom .wp-block-button {
	flex: 0 1 288px;
}

.razem-footer__bottom .wp-block-button__link {
	width: 100%;
}

.razem-footer .razem-button-red .wp-block-button__link {
	background: var(--razem-accent);
}

.razem-footer .is-style-razem-viber .wp-block-button__link {
	background: #7f4ca0;
}

.razem-footer .is-style-razem-telegram .wp-block-button__link {
	background: #159bc9;
}

.razem-footer .razem-footer__bottom + .razem-footer__sep {
	margin-top: 0;
}

.razem-footer__legal {
	justify-content: space-between;
	padding-top: 24px;
	font-size: 16px;
	line-height: 20px;
	color: var(--razem-muted-dark);
}

.razem-footer__legal p {
	margin: 0;
}

@media (max-width: 781px) {
	.razem-footer {
		padding-top: 40px;
		padding-bottom: 32px;
	}

	.razem-footer__top,
	.razem-footer__top:not(:has(.razem-footer__cities)) {
		grid-template-columns: minmax(0, 1fr);
		grid-template-rows: none;
		grid-template-areas: "about" "cities" "jobs" "social";
		row-gap: 40px;
	}

	.razem-footer__bottom {
		grid-template-columns: minmax(0, 1fr);
		gap: 40px;
	}

	.razem-footer__bottom .wp-block-buttons {
		flex-direction: column;
		flex-wrap: nowrap;
		align-items: stretch;
		gap: 16px;
	}

	.razem-footer__bottom .wp-block-button {
		flex: none;
		width: 100%;
	}

	.razem-footer__legal {
		flex-wrap: nowrap;
		gap: 16px;
	}
}

/* ---------------------------------------------------------------- Plain pages, 404 */

.razem-page .razem-breadcrumbs {
	margin-top: 16px;
}

.razem-page .razem-page__title {
	margin-top: 32px;
	font-size: 40px;
	line-height: 48px;
}

.razem-page .wp-block-post-content {
	margin-top: 40px;
}

.razem-page > :is(.razem-page__title, .wp-block-post-content) {
	max-width: 704px;
}

.razem-404 {
	padding-block: 40px 80px;
}

.razem-404 .razem-404__title {
	margin-top: 24px;
	font-size: 40px;
	line-height: 48px;
}

.razem-404 .wp-block-buttons {
	margin-top: 32px;
}

@media (max-width: 781px) {
	.razem-page .razem-page__title,
	.razem-404 .razem-404__title {
		font-size: 24px;
		line-height: 32px;
	}
}

/* ---------------------------------------------------------------- Hot vacancies slider */

.razem-hot {
	--razem-hot-card: 288px;
	--razem-hot-gap: 24px;
	margin-top: 64px;
}

.razem-hot__box {
	box-sizing: border-box;
	position: relative;
	max-width: 1376px;
	margin-inline: auto;
	padding: 64px 76px;
	border-radius: 24px;
	background: #fdfaf7;
	box-shadow: 0 32px 64px -40px rgba(21, 26, 41, 0.18);
}

.razem-hot__head {
	display: flex;
	align-items: center;
	gap: 24px;
	max-width: 1224px;
	margin-inline: auto;
}

.razem-hot__title {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0;
	font-size: 32px;
	line-height: 40px;
	font-weight: 400;
	color: var(--razem-contrast);
}

.razem-hot__title::before {
	content: "";
	width: 40px;
	height: 40px;
	background: var(--razem-accent);
	-webkit-mask: url(../icons/fire.svg) center / 24px 28px no-repeat;
	mask: url(../icons/fire.svg) center / 24px 28px no-repeat;
}

.razem-hot__all {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-left: auto;
	font-size: 16px;
	line-height: 24px;
	font-weight: 500;
	color: var(--razem-accent);
	white-space: nowrap;
}

.razem-hot__all::after {
	content: "";
	width: 16px;
	height: 16px;
	margin-left: 4px;
	background: currentColor;
	-webkit-mask: url(../icons/arrow-right.svg) center / 14px 14px no-repeat;
	mask: url(../icons/arrow-right.svg) center / 14px 14px no-repeat;
}

.razem-hot__all:hover {
	text-decoration: none;
	color: #c9302a;
}

.razem-hot__count {
	padding: 0 6px;
	border-radius: 4px;
	background: #ffeae9;
}

.razem-hot__all--button {
	display: none;
}

.razem-hot__arrows {
	display: contents;
}

.razem-hot__arrow {
	position: absolute;
	top: 212px;
	width: 32px;
	height: 48px;
	padding: 0;
	border: 0;
	background: var(--razem-text);
	cursor: pointer;
	-webkit-mask: url(../icons/chevron-right.svg) center / 16px 28px no-repeat;
	mask: url(../icons/chevron-right.svg) center / 16px 28px no-repeat;
}

.razem-hot__arrow--prev {
	left: 22px;
	-webkit-mask-image: url(../icons/chevron-left.svg);
	mask-image: url(../icons/chevron-left.svg);
}

.razem-hot__arrow--next {
	right: 22px;
}

.razem-hot__arrow:disabled {
	opacity: 0.25;
	cursor: default;
}

.razem-hot__track {
	display: flex;
	gap: var(--razem-hot-gap);
	max-width: 1224px;
	margin: 24px auto 0;
	padding: 8px 0 16px;
	list-style: none;
	overflow-x: auto;
	overscroll-behavior-x: contain;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
}

.razem-hot__track::-webkit-scrollbar {
	display: none;
}

.razem-hot__item {
	flex: 0 0 var(--razem-hot-card);
	min-width: 0;
	scroll-snap-align: start;
}

.razem-hot__card {
	box-sizing: border-box;
	display: flex;
	flex-direction: column;
	height: 152px;
	padding: 20px 16px;
	border-radius: 12px;
	background: #fff;
	box-shadow: 0 1px 2px rgba(21, 26, 41, 0.04), 0 6px 20px rgba(21, 26, 41, 0.06);
	color: var(--razem-text);
}

.razem-hot__card:hover {
	text-decoration: none;
	box-shadow: 0 1px 2px rgba(21, 26, 41, 0.06), 0 10px 28px rgba(21, 26, 41, 0.12);
}

.razem-hot__name {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	font-size: 16px;
	line-height: 22px;
	font-weight: 500;
	color: var(--razem-link);
}

.razem-hot__salary,
.razem-hot__place {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 14px;
	line-height: 24px;
}

.razem-hot__salary {
	margin-top: 12px;
	font-weight: 500;
	color: var(--razem-accent);
}

.razem-hot__place {
	margin-top: 8px;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.razem-hot__salary::before,
.razem-hot__place::before {
	content: "";
	flex: none;
	width: 24px;
	height: 24px;
	background: var(--razem-muted);
	-webkit-mask: var(--razem-ico) center / 16px 16px no-repeat;
	mask: var(--razem-ico) center / 16px 16px no-repeat;
}

.razem-hot__salary::before {
	--razem-ico: url(../icons/coins.svg);
}

.razem-hot__place::before {
	--razem-ico: url(../icons/location-dot.svg);
	-webkit-mask-size: 12px 16px;
	mask-size: 12px 16px;
}

.razem-hot__flag {
	flex: none;
	width: 24px;
	height: 16px;
	object-fit: cover;
}

.razem-hot__dots {
	display: flex;
	justify-content: center;
	gap: 16px;
	margin-top: 24px;
}

.razem-hot__dots button {
	width: 7px;
	height: 7px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: #f9eee3;
	cursor: pointer;
}

.razem-hot__dots button.is-active {
	background: var(--razem-accent);
}

.razem-hot__progress {
	display: none;
}

.razem-hot + .razem-related {
	margin-top: 64px;
}

@media (max-width: 1239px) {
	.razem-hot__box {
		padding-inline: 56px;
	}

	.razem-hot__arrow--prev {
		left: 12px;
	}

	.razem-hot__arrow--next {
		right: 12px;
	}
}

@media (max-width: 781px) {
	.razem-hot {
		--razem-hot-card: 256px;
		--razem-hot-gap: 16px;
		margin-top: 48px;
	}

	.razem-hot__box {
		padding: 32px 16px;
		border-radius: 0;
		box-shadow: none;
	}

	.razem-hot__head {
		gap: 8px;
	}

	.razem-hot__title {
		font-size: 22px;
		line-height: 32px;
	}

	.razem-hot__title::before {
		width: 28px;
		height: 32px;
		-webkit-mask-size: 18px 20px;
		mask-size: 18px 20px;
	}

	.razem-hot__head > .razem-hot__all {
		display: none;
	}

	.razem-hot__arrows {
		display: flex;
		gap: 8px;
		margin-left: auto;
	}

	.razem-hot__arrow {
		position: static;
		width: 24px;
		height: 24px;
		-webkit-mask-size: 8px 14px;
		mask-size: 8px 14px;
	}

	.razem-hot__track {
		margin-inline: -16px;
		padding-inline: 16px;
		scroll-padding-inline: 16px;
	}

	.razem-hot__dots {
		display: none;
	}

	.razem-hot__progress {
		display: block;
		height: 1px;
		margin-top: 8px;
		background: var(--razem-border);
		overflow: hidden;
	}

	.razem-hot__progress span {
		display: block;
		height: 100%;
		background: var(--razem-contrast);
	}

	.razem-hot__all--button {
		display: flex;
		justify-content: center;
		height: 48px;
		margin: 32px 0 0;
		border: 1px solid var(--razem-accent);
		border-radius: 8px;
	}

	.razem-hot__all--button::after {
		display: none;
	}
}
