/*
 * RACE CLUB — v4: финальный дизайн-слой «Линия старта».
 * Подключается после style.css и v3.css (handle raceclub-v4).
 */

/* ==========================================================================
   0. Токены
   ========================================================================== */
:root {
	--v4-ink: #101820;
	--v4-muted: #66717c;
	--v4-bg: #f5f7fa;
	--v4-surface: #ffffff;
	--v4-fill: #eef1f4;
	--v4-fill-2: #e6eaee;
	--v4-line: #e3e8ed;
	--v4-control: #c8d0d8;
	--v4-accent: #b83a1b;
	--v4-accent-hover: #982f18;
	--v4-accent-active: #7f2713;
	--v4-on-dark: #d5dde5;
	--v4-on-dark-muted: #a9b6c3;

	--v4-ease: cubic-bezier(.2, .7, .3, 1);
	--v4-dur: 180ms;

	--v4-fs-hero: clamp(2.75rem, 2.1rem + 2.667vw, 4.5rem);
	--v4-fs-h1: clamp(2.25rem, 1.879rem + 1.524vw, 3.25rem);
	--v4-fs-h2: clamp(1.75rem, 1.564rem + 0.762vw, 2.25rem);
	--v4-fs-h3: clamp(1.25rem, 1.157rem + 0.381vw, 1.5rem);
	--v4-fs-body: 1rem;
	--v4-fs-small: 0.875rem;
	--v4-fs-micro: 0.6875rem;

	--v4-gutter: 20px;
	--v4-section: 64px;
	--v4-head-gap: 24px;
	--v4-header-h: 60px;

	--v4-r-btn: 6px;
	--v4-r-card: 8px;
	--v4-r-img: 6px;

	/* Переопределение старых токенов — выравнивает правила style.css/v3.css */
	--rc-text: var(--v4-ink);
	--rc-muted: var(--v4-muted);
	--rc-bg: var(--v4-bg);
	--rc-border: var(--v4-line);
	--rc-control-border: var(--v4-control);
	--rc-accent-hover: var(--v4-accent-hover);
	--rc-radius-sm: 6px;
	--rc-radius-md: 6px;
	--rc-radius-card: 8px;
	--rc-radius-hero: 8px;
	--rc-shadow-card: none;
	--rc-shadow-hover: 0 12px 32px rgb(16 24 32 / 10%);
	--rc-fs-micro: 0.75rem;
	--rc-fs-small: 0.875rem;
	--rc-fs-body: 1rem;
	--rc-fs-large: 1.125rem;
	--rc-fs-h3: var(--v4-fs-h3);
	--rc-fs-h2: var(--v4-fs-h2);
	--rc-fs-h1: var(--v4-fs-h1);
	--rc-gutter: var(--v4-gutter);
	--rc-section-space: var(--v4-section);
}

@media (min-width: 768px) {
	:root {
		--v4-gutter: 32px;
		--v4-section: 80px;
		--v4-head-gap: 28px;
	}
}

@media (min-width: 1024px) {
	:root {
		--v4-gutter: 48px;
		--v4-section: 104px;
		--v4-head-gap: 32px;
		--v4-header-h: 76px;
		--v4-fs-body: 1.0625rem;
	}
}

html body {
	--wp--style--root--padding-left: var(--v4-gutter);
	--wp--style--root--padding-right: var(--v4-gutter);
	position: relative;
	background: var(--v4-bg);
	color: var(--v4-ink);
	font-family: var(--rc-font);
	font-size: var(--v4-fs-body);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   1. Типографика
   ========================================================================== */
html body :is(h1, h2, h3, h4, h5, h6) {
	color: var(--v4-ink);
	font-family: var(--rc-font-display);
	font-weight: 600;
	text-transform: none;
	text-wrap: balance;
}

html body h1 {
	font-size: var(--v4-fs-h1);
	line-height: 1.12;
	letter-spacing: -0.03em;
}

html body h2 {
	font-size: var(--v4-fs-h2);
	line-height: 1.18;
	letter-spacing: -0.025em;
}

html body h3 {
	font-size: var(--v4-fs-h3);
	line-height: 1.25;
	letter-spacing: -0.015em;
}

html body h4 {
	font-size: 1.125rem;
	line-height: 1.35;
	letter-spacing: -0.01em;
}

@media (max-width: 599px) {
	html body h1 {
		font-size: var(--v4-fs-h1);
		hyphens: manual;
	}

	html body h2 {
		font-size: var(--v4-fs-h2);
		hyphens: manual;
	}

	html body h3 {
		font-size: var(--v4-fs-h3);
	}
}

.wp-block-query-title,
.woocommerce-products-header__title.page-title,
.rc-section-title,
.rc-sitemap .rc-sitemap__title,
.woocommerce .cart_totals > h2,
.woocommerce-checkout :is(.woocommerce-billing-fields, .woocommerce-shipping-fields, .woocommerce-additional-fields) h3,
.woocommerce-checkout #order_review_heading,
body.woocommerce div.product :is(section.related, section.upsells) > h2 {
	text-transform: none !important;
}

p,
li {
	text-wrap: pretty;
}

strong,
b {
	font-weight: 600;
}

small {
	font-size: var(--v4-fs-small);
}

.rc-eyebrow,
.rc-kicker {
	display: block;
	margin: 0;
	color: var(--v4-muted);
	font-family: var(--rc-font);
	font-size: var(--v4-fs-micro);
	font-weight: 600;
	line-height: 16px;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.rc-kicker::before {
	content: none;
}

@media (min-width: 1024px) {
	.rc-eyebrow,
	.rc-kicker {
		font-size: 0.75rem;
	}
}

/* Ссылки */
a {
	color: var(--v4-accent);
	text-decoration-thickness: 1px;
	text-underline-offset: 0.2em;
}

a:hover {
	color: var(--v4-accent-hover);
	text-decoration-thickness: 1px;
}

/* Фокус — аккуратный, графитовый */
:focus-visible,
html body a:focus-visible,
html body button:focus-visible {
	outline: 2px solid var(--v4-ink);
	outline-offset: 3px;
	border-radius: 2px;
	box-shadow: none;
}

:focus:not(:focus-visible) {
	outline: none;
}

::selection {
	background: var(--v4-ink);
	color: #fff;
}

/* ==========================================================================
   2. Секции и ритм
   ========================================================================== */
.rc-main {
	padding-block-end: var(--v4-section);
}

.rc-main > * + * {
	margin-block-start: 24px;
}

.rc-section {
	padding-block: var(--v4-section);
}

html body .rc-section--hero {
	padding-block: 24px 0;
}

html body .rc-section--cats {
	padding-block-start: calc(var(--v4-section) * 0.75);
}

.rc-section--surface {
	background: var(--v4-surface);
	border-block: 0;
}

.rc-section--topo {
	background: var(--v4-surface);
}

.rc-section--track::before,
.rc-section--target::after {
	content: none;
	display: none;
}

.rc-section-head {
	gap: 12px 24px;
	margin-block-end: var(--v4-head-gap);
}

html body .rc-section-title {
	margin: 0;
	font-size: var(--v4-fs-h2);
	font-weight: 600;
}

.rc-section-lead {
	max-width: 60ch;
	margin-block: 8px 0;
	color: var(--v4-muted);
	font-size: var(--v4-fs-body);
	line-height: 1.55;
}

@media (max-width: 599px) {
	.rc-section {
		padding-block: var(--v4-section);
	}

	.rc-section-head {
		margin-block-end: var(--v4-head-gap);
	}
}

/* Текстовая ссылка со стрелкой */
.rc-link-arrow a {
	display: inline-flex;
	min-height: 44px;
	align-items: center;
	gap: 8px;
	color: var(--v4-ink);
	font-size: var(--v4-fs-small);
	font-weight: 600;
	text-decoration: none;
}

.rc-link-arrow a::after {
	content: "→";
	content: "→" / "";
	display: inline-block;
	color: var(--v4-accent);
}

.rc-link-arrow a:hover {
	color: var(--v4-ink);
	text-decoration: underline;
	text-decoration-color: var(--v4-control);
}

/* ==========================================================================
   3. Кнопки
   ========================================================================== */
.rc-btn,
.rc-button,
.wp-block-button__link,
html body :is(.woocommerce, .woocommerce-page) :is(a, button, input).button.button,
html body ul.products li.product .button.button,
html body .woocommerce button.single_add_to_cart_button.button,
.wc-block-components-button:not(.is-link) {
	box-sizing: border-box;
	display: inline-flex;
	min-height: 48px;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 12px 22px;
	border: 1px solid transparent;
	border-radius: var(--v4-r-btn) !important;
	background: var(--v4-accent);
	color: #fff;
	font-family: var(--rc-font);
	font-size: 1rem;
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: 0;
	text-transform: none;
	text-decoration: none;
	box-shadow: none;
	cursor: pointer;
}

.rc-btn:hover,
.rc-button:hover,
.wp-block-button__link:hover,
html body :is(.woocommerce, .woocommerce-page) :is(a, button, input).button.button:hover,
html body ul.products li.product .button.button:hover,
html body .woocommerce button.single_add_to_cart_button.button:hover,
.wc-block-components-button:not(.is-link):hover {
	background: var(--v4-accent-hover);
	color: #fff;
	text-decoration: none;
}

.rc-btn:active,
.wp-block-button__link:active,
html body :is(.woocommerce, .woocommerce-page) :is(a, button, input).button.button:active {
	background: var(--v4-accent-active);
}

.rc-btn--primary {
	background: var(--v4-accent);
	color: #fff;
}

/* Secondary / outline */
.rc-btn--secondary,
.rc-button--secondary,
.wp-block-button.is-style-outline > .wp-block-button__link,
html body .woocommerce table.cart td.actions :is(button[name="update_cart"], button[name="apply_coupon"]).button.button {
	border: 1px solid var(--v4-control);
	background: transparent;
	color: var(--v4-ink);
}

.rc-btn--secondary:hover,
.rc-button--secondary:hover,
.wp-block-button.is-style-outline > .wp-block-button__link:hover,
html body .woocommerce table.cart td.actions :is(button[name="update_cart"], button[name="apply_coupon"]).button.button:hover {
	border-color: var(--v4-control);
	background: var(--v4-fill);
	color: var(--v4-ink);
}

/* Неактивные (orders-closed) — остаются видимыми и явно недоступными */
html body :is(.woocommerce, .woocommerce-page) :is(a, button, input).button.button:is(.disabled, :disabled, [aria-disabled="true"]),
html body :is(.woocommerce, .woocommerce-page) :is(a, button, input).button.button:is(.disabled, :disabled, [aria-disabled="true"]):hover,
html body .rc-orders-closed-locked.rc-orders-closed-locked {
	background: var(--v4-accent);
	color: #fff;
	cursor: not-allowed;
}

/* ==========================================================================
   4. Поля
   ========================================================================== */
:where(input:not([type="checkbox"], [type="radio"], [type="submit"], [type="button"], [type="hidden"], [type="range"], [type="color"], [type="file"], [type="image"], [type="reset"]), select, textarea),
.woocommerce form .form-row :is(.input-text, select),
.select2-container .select2-selection--single {
	min-height: 48px;
	border: 1px solid var(--v4-control);
	border-radius: var(--v4-r-btn);
	background-color: var(--v4-surface);
	color: var(--v4-ink);
}

:where(input, select, textarea):focus-visible,
.woocommerce form .form-row :is(.input-text, select):focus {
	outline: 2px solid var(--v4-ink);
	outline-offset: 0;
	border-color: var(--v4-ink);
}

:where(input[type="checkbox"], input[type="radio"]) {
	accent-color: var(--v4-ink);
}

label {
	font-weight: 500;
}

/* ==========================================================================
   5. Объединённая топ-полоса (orders-closed + RACESTART)
   ========================================================================== */
body .rc-orders-closed-notice.rc-orders-closed-notice--top {
	box-sizing: border-box;
	display: flex;
	min-height: 30px;
	align-items: center;
	margin: 0;
	padding: 8px var(--v4-gutter) 2px !important;
	border: 0;
	background: var(--v4-ink);
	color: #fff;
	font-family: var(--rc-font);
	font-size: 13px !important;
	font-weight: 500;
	line-height: 20px !important;
	letter-spacing: 0;
	text-align: left;
}

body .rc-orders-closed-notice.rc-orders-closed-notice--top p {
	display: flex;
	align-items: center;
	gap: 8px;
	margin: 0 !important;
	color: #fff;
	font-size: inherit !important;
	line-height: inherit !important;
}

body .rc-orders-closed-notice.rc-orders-closed-notice--top p::before {
	content: "";
	flex: 0 0 6px;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: var(--v4-accent);
}

.rc-topbar {
	box-sizing: border-box;
	display: flex;
	min-height: 28px;
	align-items: center;
	padding: 2px var(--v4-gutter) 8px;
	background: var(--v4-ink);
	color: var(--v4-on-dark);
	font-family: var(--rc-font);
	font-size: 13px;
	line-height: 18px;
}

.rc-topbar:not(.rc-orders-closed-notice--top ~ .rc-topbar) {
	min-height: 36px;
	justify-content: center;
	padding-block: 8px;
}

.rc-topbar__promo {
	min-width: 0;
	margin: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.rc-topbar__label {
	color: var(--v4-on-dark-muted);
}

.rc-topbar__code {
	color: #ff9b7d;
	font-weight: 600;
	letter-spacing: 0.06em;
}

@media (max-width: 419px) {
	.rc-topbar__text {
		display: none;
	}

	.rc-topbar__label::after {
		content: " на бесплатную доставку:";
	}
}

@media (min-width: 768px) {
	body .rc-orders-closed-notice.rc-orders-closed-notice--top {
		min-height: 36px;
		padding: 0 max(var(--v4-gutter), calc((100% - 1280px) / 2 + var(--v4-gutter))) !important;
	}

	.rc-orders-closed-notice--top ~ .rc-topbar {
		position: absolute;
		z-index: 101;
		top: 0;
		right: 0;
		min-height: 36px;
		padding: 0 max(var(--v4-gutter), calc((100vw - 1280px) / 2 + var(--v4-gutter)));
		background: transparent;
	}

	.rc-topbar:not(.rc-orders-closed-notice--top ~ .rc-topbar) {
		justify-content: flex-end;
		padding-inline: max(var(--v4-gutter), calc((100% - 1280px) / 2 + var(--v4-gutter)));
	}
}

@media (min-width: 768px) and (max-width: 1023px) {
	.rc-topbar__text {
		display: none;
	}

	.rc-topbar__label::after {
		content: " на бесплатную доставку:";
	}
}

html.has-modal-open .rc-topbar {
	z-index: 1;
}

/* Старая промо-полоса (на случай кэша/повторного вывода) */
.rc-promo {
	display: none !important;
}

/* ==========================================================================
   6. Шапка
   ========================================================================== */
.rc-header {
	border-bottom: 1px solid var(--v4-line);
	background: var(--v4-surface);
}

html body .rc-header__inner {
	min-height: var(--v4-header-h);
	gap: 12px;
}

.rc-header__actions {
	gap: 4px;
}

.rc-logo .rc-wordmark {
	font-size: 18px;
	letter-spacing: 0.01em;
}

@media (max-width: 781px) {
	html body .rc-logo .rc-wordmark {
		font-size: 17px;
	}
}

@media (min-width: 1024px) {
	.rc-logo .rc-wordmark {
		font-size: 22px;
	}

	html body .rc-header__actions {
		flex: 1 1 auto;
		gap: 16px;
	}

	.rc-header__actions > .rc-nav {
		margin-inline: auto;
	}
}

/* Навигация десктоп */
@media (min-width: 782px) {
	html body .rc-nav {
		font-size: 15px;
		font-weight: 500;
	}

	header .rc-nav.wp-block-navigation,
	header .rc-nav .wp-block-navigation__container {
		gap: clamp(16px, 2vw, 32px);
	}

	.rc-nav .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content {
		position: relative;
		color: var(--v4-ink);
		text-decoration: none;
	}

	.rc-nav .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content::after {
		content: "";
		position: absolute;
		right: 0;
		bottom: 8px;
		left: 0;
		height: 1.5px;
		background: currentColor;
		transform: scaleX(0);
		transform-origin: left center;
	}

	html body .rc-nav .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content:hover,
	html body .rc-nav .wp-block-navigation__container > .current-menu-item > .wp-block-navigation-item__content,
	html body .rc-nav .wp-block-navigation__container > .wp-block-navigation-item > [aria-current="page"] {
		color: var(--v4-ink);
		text-decoration: none;
	}

	.rc-nav .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content:hover::after,
	.rc-nav .wp-block-navigation__container > .current-menu-item > .wp-block-navigation-item__content::after,
	.rc-nav .wp-block-navigation__container > .wp-block-navigation-item > [aria-current="page"]::after {
		transform: scaleX(1);
	}

	html body .rc-nav .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-container {
		border-radius: var(--v4-r-card) !important;
		border-color: var(--v4-line) !important;
		box-shadow: 0 12px 32px rgb(16 24 32 / 10%) !important;
	}

	html body .rc-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover,
	html body .rc-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:focus-visible {
		background: var(--v4-fill) !important;
		color: var(--v4-ink) !important;
	}

	html body .rc-nav .wp-block-navigation__submenu-container .wp-block-navigation-item__content:hover .rc-nav-ico {
		color: var(--v4-ink);
	}
}

/* Кнопка меню и корзина — одинаковые 44×44 иконки без рамок */
html body .rc-nav .wp-block-navigation__responsive-container-open {
	box-sizing: border-box;
	width: 44px;
	height: 44px;
	min-width: 44px;
	min-height: 44px;
	padding: 0;
	border: 0;
	border-radius: var(--v4-r-btn);
	background: transparent;
	color: var(--v4-ink);
}

html body .rc-nav .wp-block-navigation__responsive-container-open::after {
	content: none;
}

html body .rc-nav .wp-block-navigation__responsive-container-open svg {
	width: 24px;
	height: 24px;
}

html body .rc-nav .wp-block-navigation__responsive-container-open:hover {
	background: var(--v4-fill);
}

html body .rc-cart-link {
	box-sizing: border-box;
	width: 44px;
	height: 44px;
	border: 0;
	border-radius: var(--v4-r-btn);
	background: transparent;
	color: var(--v4-ink);
}

html body .rc-cart-link:hover {
	background: var(--v4-fill);
	color: var(--v4-ink);
}

.rc-cart-link svg {
	width: 24px;
	height: 24px;
}

html body .rc-cart-link__count {
	top: 4px;
	right: 2px;
	min-width: 18px;
	height: 18px;
	padding: 0 4px;
	background: var(--v4-ink);
	font-size: 11px;
	line-height: 18px;
}

@media (max-width: 781px) {
	/* Порядок: меню слева, логотип, корзина справа */
	html body .rc-header__inner {
		position: relative;
	}

	html body .rc-header__inner > .rc-logo {
		order: 2;
		margin-inline: auto;
	}

	html body .rc-header__actions {
		display: contents;
	}

	html body .rc-header__actions > .rc-nav {
		order: 1;
	}

	html body .rc-header__actions > .rc-cart-link {
		order: 3;
	}

	html body .rc-header__inner > .rc-logo {
		position: absolute;
		left: 50%;
		transform: translateX(-50%);
	}

	html body .rc-header__inner > .rc-cart-link,
	html body .rc-header__actions > .rc-cart-link {
		margin-left: auto;
	}
}

/* Мобильное меню (v3) — дошлифовка под шкалу */
@media (max-width: 781px) {
	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item__content {
		font-size: 20px;
		font-weight: 600;
		letter-spacing: -0.01em;
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
		font-size: 16px;
		font-weight: 500;
		color: var(--v4-ink) !important;
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .rc-nav-ico {
		color: var(--v4-ink);
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-dialog::before {
		font-size: 12px;
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
		border: 0;
		border-radius: var(--v4-r-btn);
		background: var(--v4-fill);
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open :is(.current-menu-item > .wp-block-navigation-item__content, .wp-block-navigation-item__content[aria-current]) {
		color: var(--v4-accent) !important;
	}

	.rc-menu-extra .rc-menu-extra__tg {
		border-radius: var(--v4-r-btn);
		background: var(--v4-fill);
		border-color: transparent;
	}

	.rc-menu-extra .rc-menu-extra__tg .rc-ico {
		color: var(--v4-ink);
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
		animation: v4-menu-in 200ms var(--v4-ease) both;
	}
}

@keyframes v4-menu-in {
	from {
		opacity: 0;
		transform: translateY(8px);
	}

	to {
		opacity: 1;
		transform: none;
	}
}

/* ==========================================================================
   7. Hero
   ========================================================================== */
html body .rc-hero {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 24px;
	overflow: visible;
	border-radius: 0;
	background: transparent;
	color: var(--v4-ink);
}

.rc-hero::before {
	content: none !important;
}

html body .rc-hero__media {
	overflow: hidden;
	margin: 0;
	aspect-ratio: 4 / 3;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

html body .rc-hero__img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: 60% 50%;
}

html body .rc-hero__content {
	position: static;
	padding: 0;
	background: none;
}

html body .rc-hero--no-media .rc-hero__content {
	padding: 48px 0;
	background: none;
}

html body .rc-hero__content > * + * {
	margin-block-start: 16px;
}

html body .rc-hero__kicker {
	color: var(--v4-muted);
}

html body .rc-hero__title {
	max-width: 14ch;
	margin-block-start: 12px;
	color: var(--v4-ink);
	font-size: var(--v4-fs-hero);
	font-weight: 600;
	line-height: 1.05;
	letter-spacing: -0.035em;
	hyphens: manual;
}

html body .rc-hero__text {
	max-width: 44ch;
	color: var(--v4-muted);
	font-size: 1.0625rem;
	line-height: 1.55;
}

html body .rc-hero__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 12px 24px;
	margin-block-start: 28px !important;
}

.rc-hero__actions .rc-btn {
	padding-inline: 24px;
}

.rc-hero__link {
	display: inline-flex;
	min-height: 44px;
	align-items: center;
	color: var(--v4-ink);
	font-weight: 600;
	text-decoration: underline;
	text-decoration-color: var(--v4-control);
	text-underline-offset: 0.3em;
}

.rc-hero__link:hover {
	color: var(--v4-ink);
	text-decoration-color: var(--v4-ink);
}

.rc-hero__promo {
	padding-top: 20px;
	border-top: 1px solid var(--v4-line);
	color: var(--v4-muted);
	font-size: var(--v4-fs-small);
	line-height: 1.45;
}

.rc-hero__promo .rc-code {
	color: var(--v4-accent);
	font-weight: 600;
	letter-spacing: 0.06em;
}

.rc-start-number {
	display: none;
}

@media (max-width: 599px) {
	.rc-hero__actions .rc-btn {
		flex: 1 1 100%;
	}

	.rc-hero__link {
		margin-inline: auto;
	}
}

@media (min-width: 1024px) {
	html body .rc-hero:not(.rc-hero--no-media) {
		grid-template-columns: minmax(0, 520px) minmax(0, 1fr);
		grid-template-areas: "content media";
		align-items: center;
		gap: clamp(40px, 5vw, 80px);
		min-height: clamp(520px, 42vw, 600px);
	}

	html body .rc-hero:not(.rc-hero--no-media) > * {
		grid-area: auto;
	}

	html body .rc-hero:not(.rc-hero--no-media) .rc-hero__media {
		grid-area: media;
		height: 100%;
		min-height: 520px;
		max-height: 600px;
		aspect-ratio: auto;
	}

	html body .rc-hero:not(.rc-hero--no-media) .rc-hero__content {
		grid-area: content;
		align-self: center;
		max-width: 520px;
		padding: 0;
	}

	html body .rc-hero__title {
		max-width: none;
	}
}

/* ==========================================================================
   8. Плитки категорий
   ========================================================================== */
.rc-tiles {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.rc-tile {
	margin: 0;
}

.rc-tile:last-child:nth-child(odd) {
	grid-column: 1 / -1;
}

.rc-tile__link {
	position: relative;
	box-sizing: border-box;
	display: flex;
	height: 100%;
	min-height: 128px;
	flex-direction: column;
	justify-content: space-between;
	gap: 16px;
	padding: 18px;
	border-radius: var(--v4-r-card);
	background: var(--v4-surface);
	color: var(--v4-ink);
	text-decoration: none;
}

.rc-tile__link:hover {
	background: var(--v4-fill);
	color: var(--v4-ink);
}

.rc-tile__icon {
	display: inline-flex;
	width: 28px;
	height: 28px;
	color: var(--v4-ink);
}

.rc-tile__icon .rc-ico {
	width: 26px;
	height: 26px;
	stroke-width: 1.5;
	vertical-align: 0;
}

.rc-tile__arrow {
	position: absolute;
	top: 18px;
	right: 18px;
	display: inline-flex;
	color: var(--v4-muted);
}

.rc-tile__arrow .rc-ico {
	width: 20px;
	height: 20px;
	stroke-width: 1.5;
	vertical-align: 0;
}

.rc-tile__body {
	display: flex;
	flex-direction: column;
	gap: 2px;
}

.rc-tile__name {
	font-family: var(--rc-font-display);
	font-size: 17px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: -0.01em;
}

.rc-tile__count {
	color: var(--v4-muted);
	font-size: var(--v4-fs-small);
	line-height: 20px;
}

@media (min-width: 768px) {
	.rc-tiles {
		grid-template-columns: repeat(6, minmax(0, 1fr));
		gap: 16px;
	}

	.rc-tile,
	.rc-tile:last-child:nth-child(odd) {
		grid-column: span 2;
	}

	/* 5 плиток: 3 + 2 без дыр */
	.rc-tile:nth-child(4):nth-last-child(2),
	.rc-tile:nth-child(5):last-child {
		grid-column: span 3;
	}

	.rc-tile__link {
		min-height: 148px;
		padding: 22px;
	}

	.rc-tile__arrow {
		top: 22px;
		right: 22px;
	}

	.rc-tile__name {
		font-size: 18px;
	}
}

@media (min-width: 1200px) {
	.rc-tiles {
		grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
		grid-auto-flow: column;
		gap: 24px;
	}

	.rc-tile,
	.rc-tile:last-child:nth-child(odd),
	.rc-tile:nth-child(4):nth-last-child(2),
	.rc-tile:nth-child(5):last-child {
		grid-column: auto;
	}

	.rc-tile__link {
		min-height: 160px;
	}
}

/* Старые плитки с фото, если где-то остался [rc_categories] */
.rc-cat__media {
	display: none;
}

/* ==========================================================================
   9. Карточки товаров (классика)
   ========================================================================== */
html body ul.products[class] {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 28px 12px;
	margin: 0 0 32px;
}

html body ul.products[class] li.product[class] {
	overflow: visible;
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	transform: none;
}

html body ul.products[class] li.product[class]:hover {
	box-shadow: none;
	transform: none;
}

html body ul.products[class] li.product[class] > a.woocommerce-LoopProduct-link {
	color: var(--v4-ink);
}

html body ul.products[class] li.product[class] .rc-card-media {
	position: relative;
	display: block;
	overflow: hidden;
	margin: 0 0 14px;
	aspect-ratio: 4 / 5;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

html body ul.products[class] li.product[class] .rc-card-media img,
html body ul.products[class] li.product[class] > a > img {
	box-sizing: border-box;
	display: block;
	width: 100%;
	height: 100%;
	margin: 0;
	padding: 3%;
	aspect-ratio: 4 / 5;
	border: 0;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
	object-fit: contain;
	mix-blend-mode: multiply;
}

html body ul.products[class] li.product[class] .rc-card-media img {
	background: transparent;
}

html body ul.products[class] li.product[class] .rc-card-meta {
	padding: 0;
	color: var(--v4-muted);
	font-size: var(--v4-fs-micro);
	font-weight: 600;
	line-height: 16px;
	letter-spacing: 0.1em;
}

html body ul.products[class] li.product[class] .woocommerce-loop-product__title {
	display: -webkit-box;
	min-height: 44px;
	margin: 6px 0 0;
	padding: 0;
	overflow: hidden;
	color: var(--v4-ink);
	font-family: var(--rc-font);
	font-size: 15px !important;
	font-weight: 500;
	line-height: 22px;
	letter-spacing: 0;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
	line-clamp: 2;
	overflow-wrap: break-word;
	hyphens: manual;
}

html body ul.products[class] li.product[class] .price {
	margin: 6px 0 12px !important;
	padding: 0;
	color: var(--v4-accent);
	font-size: 16px;
	font-weight: 600;
	line-height: 24px;
}

html body ul.products[class] li.product[class] .price ins {
	color: var(--v4-accent);
}

html body ul.products[class] li.product[class] .button.button {
	width: 100%;
	min-height: 40px;
	margin: auto 0 0;
	padding: 8px 12px;
	border: 1px solid var(--v4-control);
	background: transparent;
	color: var(--v4-ink);
	font-size: 14px;
	font-weight: 600;
	white-space: normal;
}

html body ul.products[class] li.product[class] .button.button:hover {
	border-color: var(--v4-ink);
	background: var(--v4-ink);
	color: #fff;
}

html body ul.products[class] li.product[class] .added_to_cart {
	margin: 8px 0 0;
	color: var(--v4-ink);
}

html body ul.products[class] li.product[class] :is(.onsale, .rc-badge) {
	display: none;
}

@media (min-width: 768px) {
	html body ul.products[class] {
		grid-template-columns: repeat(3, minmax(0, 1fr));
		gap: 40px 24px;
	}

	html body ul.products[class] li.product[class] .woocommerce-loop-product__title {
		font-size: 16px !important;
	}

	html body ul.products[class] li.product[class] .price {
		font-size: 17px;
	}
}

@media (min-width: 1024px) {
	html body ul.products[class] {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 48px 24px;
	}
}

@media (max-width: 339px) {
	html body ul.products[class] {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* Кнопка появляется при наведении только на устройствах с мышью */
@media (hover: hover) and (pointer: fine) {
	html body ul.products[class] li.product[class] .button.button {
		opacity: 0;
		transform: translateY(4px);
	}

	html body ul.products[class] li.product[class]:hover .button.button,
	html body ul.products[class] li.product[class]:focus-within .button.button {
		opacity: 1;
		transform: none;
	}
}

/* Блочные карточки WooCommerce */
.wc-block-product-template .wc-block-product {
	border: 0;
	border-radius: 0;
	background: transparent;
}

.wc-block-product .wc-block-components-product-image {
	overflow: hidden;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

.wc-block-product .wc-block-components-product-image img {
	box-sizing: border-box;
	aspect-ratio: 4 / 5 !important;
	padding: 8%;
	background: transparent;
	object-fit: contain !important;
	mix-blend-mode: multiply;
}

.wc-block-product .wp-block-post-title,
.wc-block-product .wp-block-woocommerce-product-price,
.wc-block-product .wc-block-components-product-price {
	padding: 0 !important;
}

.wc-block-product .wc-block-components-product-price {
	color: var(--v4-accent);
}

.wc-block-components-product-sale-badge {
	display: none !important;
}

/* ==========================================================================
   10. Каталог
   ========================================================================== */
.rc-crumbs {
	padding-block-start: 20px;
}

.rc-breadcrumbs {
	color: var(--v4-muted);
	font-size: 13px;
}

.rc-breadcrumbs a {
	min-height: 32px;
	color: var(--v4-muted);
	text-decoration: none;
}

.rc-breadcrumbs a:hover {
	color: var(--v4-ink);
	text-decoration: underline;
}

.rc-breadcrumbs__sep {
	color: var(--v4-control);
}

.rc-breadcrumbs [aria-current] {
	color: var(--v4-ink);
	font-weight: 500;
}

html body .woocommerce-products-header__title.page-title {
	margin: 16px 0 12px;
	font-size: var(--v4-fs-h1);
	font-weight: 600;
	line-height: 1.12;
	letter-spacing: -0.03em;
}

.woocommerce-products-header {
	margin-block-end: 32px;
}

.woocommerce-products-header :is(.page-description, .term-description) {
	max-width: 70ch;
	color: var(--v4-muted);
	font-size: var(--v4-fs-body);
}

body.woocommerce .woocommerce-result-count {
	color: var(--v4-muted);
	font-size: var(--v4-fs-small);
}

body.woocommerce .woocommerce-ordering select {
	min-height: 44px;
	font-size: 15px;
}

body.woocommerce nav.woocommerce-pagination ul li :is(a, span) {
	border-color: transparent;
	border-radius: var(--v4-r-btn);
	background: transparent;
}

body.woocommerce nav.woocommerce-pagination ul li a:hover {
	background: var(--v4-fill);
}

body.woocommerce nav.woocommerce-pagination ul li span.current {
	background: var(--v4-ink);
	color: #fff;
}

/* ==========================================================================
   11. Страница товара
   ========================================================================== */
html body.woocommerce div.product {
	gap: 24px;
	margin-block-start: 16px;
}

html body.woocommerce div.product div.images {
	overflow: visible;
	border: 0;
	border-radius: 0;
	background: transparent;
}

html body.woocommerce div.product .woocommerce-product-gallery__image {
	overflow: hidden;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

html body.woocommerce div.product .woocommerce-product-gallery__image a {
	display: block;
}

html body.woocommerce div.product .woocommerce-product-gallery__image img {
	box-sizing: border-box;
	width: 100%;
	height: auto;
	padding: 6%;
	aspect-ratio: 4 / 5;
	object-fit: contain;
	mix-blend-mode: multiply;
}

html body.woocommerce div.product div.images .flex-control-thumbs {
	display: grid;
	grid-template-columns: repeat(5, minmax(0, 1fr));
	gap: 8px;
	margin: 8px 0 0;
	padding: 0;
}

html body.woocommerce div.product div.images .flex-control-thumbs li {
	overflow: hidden;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

html body.woocommerce div.product div.images .flex-control-thumbs img {
	box-sizing: border-box;
	width: 100%;
	height: auto;
	padding: 6%;
	aspect-ratio: 4 / 5;
	border-radius: var(--v4-r-img);
	object-fit: contain;
	mix-blend-mode: multiply;
	opacity: 0.6;
	cursor: pointer;
}

html body.woocommerce div.product div.images .flex-control-thumbs img.flex-active,
html body.woocommerce div.product div.images .flex-control-thumbs img:hover {
	opacity: 1;
	outline: 1.5px solid var(--v4-ink);
	outline-offset: -1.5px;
}

@media (max-width: 1023px) {
	html body.woocommerce div.product div.images .flex-control-thumbs {
		display: flex;
		padding: 0;
	}

	html body.woocommerce div.product div.images .flex-control-thumbs li {
		flex: 0 0 64px;
		width: 64px;
	}

	html body.woocommerce div.product div.images .flex-control-thumbs img {
		width: 64px;
		height: 80px;
	}
}

html body.woocommerce div.product span.onsale {
	display: none;
}

html body.woocommerce div.product .product_title {
	margin: 0 0 12px;
	font-size: clamp(1.75rem, 1.45rem + 1.2vw, 2.5rem);
	font-weight: 600;
	line-height: 1.15;
	letter-spacing: -0.025em;
	hyphens: manual;
}

html body.woocommerce div.product p.price,
html body.woocommerce div.product span.price {
	margin: 0 0 20px;
	color: var(--v4-accent);
	font-size: 1.5rem;
	font-weight: 600;
	line-height: 1.3;
}

html body.woocommerce div.product .woocommerce-product-details__short-description {
	max-width: 60ch;
	color: var(--v4-muted);
	font-size: 15px;
	line-height: 1.6;
}

html body.woocommerce div.product form.cart {
	margin: 24px 0;
}

html body.woocommerce div.product form.cart table.variations th.label {
	color: var(--v4-ink);
	font-size: var(--v4-fs-small);
	font-weight: 600;
}

html body.woocommerce div.product form.cart table.variations select {
	min-height: 48px;
	padding-block: 11px;
	border-color: var(--v4-control);
	border-radius: var(--v4-r-btn);
	font-weight: 500;
}

html body.woocommerce div.product form.cart table.variations select:focus {
	outline: 2px solid var(--v4-ink);
	outline-offset: 0;
	border-color: var(--v4-ink);
}

html body.woocommerce .quantity .qty {
	min-height: 48px;
	border-radius: var(--v4-r-btn);
}

html body .woocommerce div.product form.cart button.single_add_to_cart_button.button {
	min-height: 52px;
	font-size: 16px;
}

html body.woocommerce div.product .stock.in-stock {
	color: #176b45;
}

html body.woocommerce div.product .product_meta {
	border-top-color: var(--v4-line);
	font-size: 13px;
}

html body.woocommerce div.product .product_meta a {
	color: var(--v4-ink);
}

/* Блок доверия — нейтральные иконки */
html body .rc-trust {
	padding: 4px 16px;
	border-color: var(--v4-line);
	border-radius: var(--v4-r-card);
	background: var(--v4-surface);
}

html body .rc-trust__ico {
	flex: 0 0 32px;
	border-radius: var(--v4-r-btn);
	background: var(--v4-fill);
	color: var(--v4-ink);
}

html body .rc-trust__ico .rc-ico {
	stroke-width: 1.5;
}

html body .rc-trust .rc-trust__item {
	font-size: 14px;
}

.rc-trust__text a {
	color: var(--v4-ink);
}

/* Табы — подчёркивание вместо пилюль */
html body.woocommerce div.product .woocommerce-tabs {
	margin-block-start: 48px;
}

html body.woocommerce div.product .woocommerce-tabs ul.tabs {
	gap: 24px;
	margin: 0 0 28px;
	border-bottom: 1px solid var(--v4-line);
}

html body.woocommerce div.product .woocommerce-tabs ul.tabs li a {
	min-height: 48px;
	margin-bottom: -1px;
	padding: 0;
	border: 0;
	border-bottom: 2px solid transparent;
	border-radius: 0;
	background: transparent;
	color: var(--v4-muted);
	font-size: 15px;
	font-weight: 600;
}

html body.woocommerce div.product .woocommerce-tabs ul.tabs li a:hover {
	color: var(--v4-ink);
}

html body.woocommerce div.product .woocommerce-tabs ul.tabs li.active a {
	border-bottom-color: var(--v4-ink);
	background: transparent;
	color: var(--v4-ink);
}

html body.woocommerce div.product .woocommerce-tabs .panel {
	max-width: 70ch;
	font-size: var(--v4-fs-body);
	line-height: 1.65;
}

html body.woocommerce div.product .woocommerce-tabs .panel > h2:first-child {
	font-size: var(--v4-fs-h3);
}

html body.woocommerce table.shop_attributes :is(th, td) {
	border-bottom-color: var(--v4-line);
	font-size: 15px;
}

html body.woocommerce table.shop_attributes th {
	color: var(--v4-muted);
	font-weight: 500;
}

html body.woocommerce div.product :is(section.related, section.upsells) > h2 {
	margin-block: var(--v4-section) var(--v4-head-gap);
	font-size: var(--v4-fs-h2);
}

#reviews #comments h2,
#reviews .comment-reply-title {
	font-size: var(--v4-fs-h3);
	font-weight: 600;
}

@media (min-width: 1024px) {
	html body.woocommerce div.product {
		grid-template-columns: minmax(0, 58fr) minmax(0, 42fr);
		column-gap: clamp(40px, 4.5vw, 72px);
	}

	html body.woocommerce div.product div.summary {
		position: sticky;
		top: calc(var(--v4-header-h) + 24px + var(--wp-admin--admin-bar--height, 0px));
	}

	html body.woocommerce div.product div.images .flex-control-thumbs {
		grid-template-columns: repeat(6, minmax(0, 1fr));
	}
}

@media (max-width: 781px) {
	html body.woocommerce div.product .product_title {
		font-size: 1.75rem;
	}

	html body.woocommerce div.product p.price,
	html body.woocommerce div.product span.price {
		font-size: 1.375rem;
	}

	html body.woocommerce div.product .woocommerce-tabs ul.tabs {
		gap: 20px;
	}
}

/* ==========================================================================
   12. Преимущества, соцсети, новости, SEO
   ========================================================================== */
.rc-benefits {
	gap: 32px 24px;
	grid-template-columns: repeat(2, minmax(0, 1fr));
}

html body .rc-benefit {
	padding: 0;
	border: 0;
	border-radius: 0;
	background: transparent;
}

html body .rc-benefit__icon {
	width: 28px;
	height: 28px;
	place-items: start;
	border-radius: 0;
	background: transparent;
	color: var(--v4-ink);
}

html body .rc-benefit__icon svg {
	width: 24px;
	height: 24px;
	stroke-width: 1.5;
}

html body .rc-benefit__title {
	font-size: 17px;
	font-weight: 600;
	line-height: 1.3;
}

html body .rc-benefit__text {
	color: var(--v4-muted);
	font-size: var(--v4-fs-small);
	line-height: 1.5;
}

@media (min-width: 1024px) {
	.rc-benefits {
		grid-template-columns: repeat(4, minmax(0, 1fr));
		gap: 48px;
	}
}

@media (max-width: 419px) {
	.rc-benefits {
		grid-template-columns: minmax(0, 1fr);
	}
}

/* Соцсети — монохром */
html body .rc-social svg {
	color: var(--v4-ink);
}

html body .rc-socials--cards .rc-social {
	padding: 24px;
	border: 0;
	border-radius: var(--v4-r-card);
	background: var(--v4-bg);
}

html body .rc-socials--cards .rc-social__icon,
html body .rc-socials--cards .rc-social--instagram .rc-social__icon {
	width: 44px;
	height: 44px;
	border-radius: var(--v4-r-btn);
	background: var(--v4-surface);
}

html body .rc-socials--cards .rc-social--instagram .rc-social__icon svg {
	color: var(--v4-ink);
}

html body .rc-socials--cards .rc-social__title {
	font-size: 18px;
	font-weight: 600;
}

html body .rc-socials--cards .rc-social .rc-social__link {
	min-height: 40px;
	padding: 8px 18px;
	border-color: var(--v4-control);
	border-radius: var(--v4-r-btn);
	font-size: 14px;
}

html body .rc-socials--cards .rc-social .rc-social__link:hover {
	background: var(--v4-surface);
}

html body .rc-socials--icons {
	gap: 8px;
}

html body .rc-socials--icons .rc-social,
html body .rc-socials--icons .rc-social--instagram {
	width: 44px;
	height: 44px;
	border-radius: var(--v4-r-btn);
	background: var(--v4-fill);
	box-shadow: none;
}

html body .rc-socials--icons .rc-social--instagram svg {
	color: var(--v4-ink);
}

html body .rc-socials--icons .rc-social:hover {
	background: var(--v4-fill-2);
	box-shadow: none;
}

html body .rc-socials--icons .rc-social svg {
	width: 22px;
	height: 22px;
}

.rc-contact-line {
	color: var(--v4-muted);
	font-weight: 500;
}

.rc-contact-line a {
	color: var(--v4-ink);
	font-weight: 600;
}

/* Новости */
html body :is(.rc-news-card, .rc-post-card) {
	border: 0;
	border-radius: 0;
	background: transparent;
	box-shadow: none;
	transform: none;
}

html body :is(.rc-news-card, .rc-post-card):hover {
	box-shadow: none;
	transform: none;
}

html body .rc-news-card img,
html body .rc-post-card .wp-block-post-featured-image img {
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
}

html body .rc-post-card .wp-block-post-featured-image {
	overflow: hidden;
	border-radius: var(--v4-r-img);
}

html body :is(.rc-news-card__body, .rc-post-card__body) {
	padding: 16px 0 0;
}

html body :is(.rc-news-card__meta, .rc-post-card .wp-block-post-date) {
	color: var(--v4-accent);
	font-size: 13px;
	font-weight: 500;
}

html body :is(.rc-news-card__cat, .rc-post-card .wp-block-post-terms a) {
	color: var(--v4-muted);
	font-size: var(--v4-fs-micro);
	letter-spacing: 0.1em;
}

html body :is(.rc-news-card__title, .rc-post-card .wp-block-post-title) {
	font-size: 1.25rem !important;
	font-weight: 600;
	line-height: 1.3;
}

html body :is(.rc-news-card__title, .rc-post-card .wp-block-post-title) a:hover {
	color: var(--v4-ink);
	text-decoration: underline;
	text-decoration-color: var(--v4-control);
}

html body :is(.rc-post-card .wp-block-read-more, .rc-read-more) {
	color: var(--v4-ink);
	font-size: var(--v4-fs-small);
	text-decoration-color: var(--v4-control);
}

.rc-news-empty,
.rc-no-results {
	border: 0;
	border-radius: var(--v4-r-card);
	background: var(--v4-surface);
}

.rc-news-empty a {
	color: var(--v4-ink);
}

/* Рубрики-чипсы */
html body .rc-chips a {
	min-height: 40px;
	padding: 8px 16px;
	border-color: var(--v4-control);
	border-radius: var(--v4-r-btn);
	font-size: 14px;
	font-weight: 500;
}

html body .rc-chips a:hover {
	background: var(--v4-fill);
}

html body .rc-chips a[aria-current] {
	border-color: var(--v4-ink);
	background: var(--v4-ink);
	color: #fff;
}

.wp-block-query-pagination a,
.wp-block-query-pagination .page-numbers {
	border-color: transparent;
	border-radius: var(--v4-r-btn);
	background: transparent;
}

.wp-block-query-pagination .page-numbers.current {
	background: var(--v4-ink);
	color: #fff;
}

/* SEO-текст */
html body .rc-seo > * {
	max-width: 70ch;
}

html body .rc-seo .rc-section-title {
	font-size: var(--v4-fs-h3);
}

html body .rc-seo p {
	color: var(--v4-muted);
	font-size: 16px;
	line-height: 1.65;
}

html body .rc-seo strong {
	color: var(--v4-muted);
	font-weight: 500;
}

/* ==========================================================================
   13. Контентные страницы, записи
   ========================================================================== */
html body .rc-page-title,
html body .rc-entry-title {
	margin-block: 16px 0;
	font-size: var(--v4-fs-h1);
	font-weight: 600;
	line-height: 1.12;
	letter-spacing: -0.03em;
}

.rc-page .wp-block-post-content,
.rc-article {
	font-size: var(--v4-fs-body);
	line-height: 1.7;
}

.wp-block-post-content > * + * {
	margin-block-start: 1em;
}

.wp-block-post-content :is(h2, h3) {
	margin-block: 1.8em 0.5em;
}

.wp-block-post-content h2 {
	font-size: var(--v4-fs-h3);
}

.wp-block-post-content a {
	color: var(--v4-ink);
	text-decoration-color: var(--v4-accent);
}

.wp-block-post-content a:hover {
	color: var(--v4-accent-hover);
}

.wp-block-post-content strong {
	font-weight: 600;
}

.wp-block-quote {
	border-left-width: 2px;
	border-left-color: var(--v4-ink);
	font-size: 1.125rem;
}

/* Запись */
.rc-article {
	max-width: 720px;
	margin-inline: auto;
}

.rc-article > .wp-block-post-content > p:first-of-type {
	color: var(--v4-ink);
	font-size: 1.1875rem;
	line-height: 1.6;
}

html body .rc-entry-terms a {
	min-height: 0;
	padding: 0;
	border-radius: 0;
	background: transparent;
	color: var(--v4-muted);
	font-size: var(--v4-fs-micro);
	letter-spacing: 0.1em;
}

.rc-entry-meta .wp-block-post-date {
	color: var(--v4-accent);
	font-weight: 500;
}

html body .rc-entry-image img {
	border-radius: var(--v4-r-img);
}

.wp-element-caption,
figcaption {
	margin-top: 8px;
	color: var(--v4-muted);
	font-size: 13px;
	line-height: 1.45;
	text-align: left;
}

.rc-post-nav {
	border-top-color: var(--v4-line);
}

.rc-post-nav a {
	color: var(--v4-ink);
	text-decoration: none;
}

.rc-post-nav a:hover {
	color: var(--v4-ink);
	text-decoration: underline;
}

.rc-related h2,
.rc-related-products h2 {
	font-size: var(--v4-fs-h2);
}

/* Инфо-карточки (v3) */
html body .rc-info-grid {
	gap: 16px;
	margin-block: 32px 48px;
}

html body .rc-info-grid .rc-info-card {
	padding: 24px;
	border: 0;
	border-radius: var(--v4-r-card);
	background: var(--v4-surface);
}

html body .rc-info-card .rc-info-card__icon {
	width: 28px;
	height: 28px;
	place-items: start;
	border-radius: 0;
	background: transparent;
	color: var(--v4-ink);
}

html body .rc-info-card .rc-info-card__icon .rc-ico {
	stroke-width: 1.5;
}

html body .rc-info-card .rc-info-card__title {
	margin: 4px 0 0;
	font-size: 17px;
	font-weight: 600;
	line-height: 1.3;
}

html body .rc-info-card .rc-info-card__text {
	font-size: 14px;
	line-height: 1.5;
}

html body .rc-info-card .rc-info-card__link a {
	color: var(--v4-ink);
	font-size: 14px;
	text-decoration: none;
}

html body .rc-info-card .rc-info-card__link a .rc-ico {
	color: var(--v4-accent);
}

html body .rc-info-card .rc-info-card__link a:hover {
	text-decoration: underline;
}

/* Карта сайта (v3) */
html body .rc-sitemap .rc-sitemap__section {
	border: 0;
	border-radius: var(--v4-r-card);
	background: var(--v4-surface);
}

html body .rc-sitemap .rc-sitemap__title {
	font-size: 18px;
	font-weight: 600;
}

html body .rc-sitemap .rc-sitemap__title .rc-ico {
	color: var(--v4-ink);
}

html body .rc-sitemap .rc-sitemap__item > a {
	font-weight: 500;
}

html body .rc-sitemap .rc-sitemap__item > a:hover,
html body .rc-sitemap .rc-sitemap__subitem a:hover {
	color: var(--v4-ink);
	text-decoration: underline;
}

html body .rc-sitemap .rc-sitemap__item > a:hover .rc-ico {
	color: var(--v4-ink);
}

html body .rc-sitemap .rc-sitemap__sublist {
	border-left-width: 1px;
}

/* ==========================================================================
   14. Уведомления, корзина, оформление (только стилистика)
   ========================================================================== */
.woocommerce-error,
.woocommerce-info,
.woocommerce-message,
.wc-block-components-notice-banner {
	border-radius: var(--v4-r-card) !important;
}

/* Уведомления orders-closed внутри страниц остаются видимыми */
.rc-orders-closed-notice:not(.rc-orders-closed-notice--top) {
	display: block !important;
	border-left: 3px solid var(--v4-accent) !important;
	border-radius: var(--v4-r-btn);
	font-size: 15px !important;
}

.woocommerce table.shop_table {
	border-color: var(--v4-line);
	border-radius: var(--v4-r-card);
}

.woocommerce table.shop_table thead th {
	background: var(--v4-bg);
	font-size: var(--v4-fs-micro);
	letter-spacing: 0.1em;
}

.woocommerce table.cart .product-thumbnail img {
	box-sizing: border-box;
	padding: 4px;
	border-radius: var(--v4-r-img);
	background: var(--v4-fill);
	object-fit: contain;
	mix-blend-mode: multiply;
}

.woocommerce .cart-collaterals .cart_totals,
.woocommerce-page .cart-collaterals .cart_totals,
.woocommerce-checkout :is(.woocommerce-billing-fields, .woocommerce-shipping-fields, .woocommerce-additional-fields),
.woocommerce-checkout #order_review,
.woocommerce form.checkout_coupon,
.woocommerce form.woocommerce-form-login {
	border-color: var(--v4-line);
	border-radius: var(--v4-r-card);
}

.woocommerce .cart_totals > h2,
.woocommerce-checkout :is(.woocommerce-billing-fields, .woocommerce-shipping-fields, .woocommerce-additional-fields) h3,
.woocommerce-checkout #order_review_heading {
	font-size: 1.25rem;
	font-weight: 600;
}

.woocommerce ul#shipping_method li {
	border-radius: var(--v4-r-btn);
}

.woocommerce a.remove:hover {
	background: var(--v4-fill);
	color: var(--v4-ink) !important;
}

/* ==========================================================================
   15. Подвал
   ========================================================================== */
html body .rc-footer {
	padding-block: 72px 28px;
	background: var(--v4-ink);
	color: var(--v4-on-dark);
	font-size: 14px;
}

.rc-footer::before {
	content: none;
	display: none;
}

.rc-footer :focus-visible {
	outline-color: #fff;
}

html body .rc-footer__title {
	margin-bottom: 4px;
	color: var(--v4-on-dark-muted);
	font-family: var(--rc-font);
	font-size: var(--v4-fs-micro);
	font-weight: 600;
	letter-spacing: 0.1em;
	text-transform: uppercase;
}

.rc-footer__col > * + * {
	margin-block-start: 12px;
}

.rc-footer__about {
	color: var(--v4-on-dark-muted);
	line-height: 1.6;
}

html body .rc-footer-list a,
html body .rc-footer .wp-block-navigation-item__content {
	min-height: 36px;
	color: var(--v4-on-dark);
	font-size: 14px;
	text-decoration: none;
}

html body .rc-footer-list a:hover,
html body .rc-footer .wp-block-navigation-item__content:hover {
	color: #fff;
	text-decoration: underline;
	text-decoration-color: rgb(255 255 255 / 40%);
}

.rc-footer a {
	text-decoration-color: rgb(255 255 255 / 30%);
}

html body .rc-footer .rc-socials--icons .rc-social,
html body .rc-footer .rc-socials--icons .rc-social--instagram {
	background: rgb(255 255 255 / 8%);
}

html body .rc-footer .rc-socials--icons .rc-social svg,
html body .rc-footer .rc-socials--icons .rc-social--max svg {
	color: #fff;
}

html body .rc-footer .rc-socials--icons .rc-social:hover {
	background: rgb(255 255 255 / 16%);
}

html body .rc-footer__bottom {
	margin-block-start: 56px !important;
	padding-block-start: 20px;
	border-top-color: rgb(255 255 255 / 12%);
	color: var(--v4-on-dark-muted);
	font-size: 13px;
}

.rc-footer__legal a {
	display: inline-flex;
	min-height: 44px;
	align-items: center;
	color: var(--v4-on-dark-muted);
	text-decoration: none;
}

.rc-footer__legal a:hover {
	color: #fff;
	text-decoration: underline;
}

@media (max-width: 767px) {
	html body .rc-footer {
		padding-block: 56px 24px;
	}

	html body .wp-block-columns.rc-footer__cols {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 36px 20px;
	}

	.rc-footer__col--about {
		grid-column: 1 / -1;
	}

	html body .rc-footer__bottom {
		margin-block-start: 40px !important;
	}
}

@media (min-width: 1024px) {
	html body .wp-block-columns.rc-footer__cols {
		grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
		gap: 48px;
	}
}

/* ==========================================================================
   16. 404
   ========================================================================== */
.rc-404::after {
	content: none;
}

.rc-404__code {
	color: var(--v4-muted);
}

/* ==========================================================================
   17. Микроанимации
   ========================================================================== */
@media (prefers-reduced-motion: no-preference) {
	.rc-btn,
	.wp-block-button__link,
	.button,
	.rc-cart-link,
	.rc-nav .wp-block-navigation__responsive-container-open,
	.rc-tile__link,
	.rc-chips a,
	.rc-social,
	.rc-hero__link,
	.rc-link-arrow a {
		transition:
			background-color var(--v4-dur) var(--v4-ease),
			color var(--v4-dur) var(--v4-ease),
			border-color var(--v4-dur) var(--v4-ease),
			text-decoration-color var(--v4-dur) var(--v4-ease),
			opacity var(--v4-dur) var(--v4-ease),
			transform var(--v4-dur) var(--v4-ease);
	}

	html body ul.products[class] li.product[class] .button.button {
		transition:
			background-color var(--v4-dur) var(--v4-ease),
			color var(--v4-dur) var(--v4-ease),
			border-color var(--v4-dur) var(--v4-ease),
			opacity var(--v4-dur) var(--v4-ease),
			transform var(--v4-dur) var(--v4-ease);
	}

	html body ul.products[class] li.product[class] .rc-card-media img,
	.wc-block-product .wc-block-components-product-image img,
	.rc-post-card .wp-block-post-featured-image img {
		transition: transform 220ms var(--v4-ease);
	}

	html body ul.products[class] li.product[class]:hover .rc-card-media img,
	.wc-block-product:hover .wc-block-components-product-image img,
	.rc-post-card:hover .wp-block-post-featured-image img {
		transform: scale(1.03);
	}

	.rc-tile__arrow,
	.rc-link-arrow a::after {
		transition: transform var(--v4-dur) var(--v4-ease), color var(--v4-dur) var(--v4-ease);
	}

	.rc-tile__link:hover .rc-tile__arrow {
		color: var(--v4-ink);
		transform: translateX(4px);
	}

	.rc-link-arrow a:hover::after {
		transform: translateX(3px);
	}

	.rc-nav .wp-block-navigation__container > .wp-block-navigation-item > .wp-block-navigation-item__content::after {
		transition: transform 200ms var(--v4-ease);
	}
}

@media (prefers-reduced-motion: reduce) {
	html body ul.products[class] li.product[class] .button.button {
		transform: none !important;
	}

	html body .rc-nav .wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
		animation: none;
	}

	.rc-tile__link:hover .rc-tile__arrow,
	html body ul.products[class] li.product[class]:hover .rc-card-media img {
		transform: none;
	}
}

/* ==========================================================================
   18. Высокая контрастность
   ========================================================================== */
@media (forced-colors: active) {
	.rc-tile__link,
	.rc-info-card,
	.rc-sitemap__section,
	.rc-socials--cards .rc-social {
		border: 1px solid CanvasText;
	}

	html body ul.products[class] li.product[class] .button.button {
		opacity: 1;
	}
}
/* --- v4 правки после скриншотов --- */
html body .rc-section--cats { padding-block-end: 0; }
html body .rc-section--cats + .rc-section { padding-block-start: calc(var(--v4-section) * 0.75); }
.rc-main > .rc-section + .rc-section { margin-block-start: 0; }
/* Кнопка в карточке видна всегда (outline), чтобы не оставлять пустоту под ценой */
@media (hover: hover) and (pointer: fine) {
	html body ul.products[class] li.product[class] .button.button { opacity: 1; transform: none; }
}
html body ul.products[class] li.product[class] .button.button { margin-top: 12px; }
/* Галерея товара: фото заполняет контейнер 4:5, как в карточках */
html body.woocommerce div.product .woocommerce-product-gallery__image img { padding: 3%; }
/* SEO-блок: заголовок и текст в одной колонке */
html body .rc-seo > *, html body .rc-seo > .rc-section-title { max-width: 760px !important; margin-inline: auto !important; }
