/*
Theme Name: FX Blank
Theme URI: https://flextra.medizine.eu/
Description: Тема сайту Флекстра Адванс (Delta Medical / SCHONEN). Без Elementor і WPML, блочна верстка, мови через DM Lang.
Version: 1.0.0
Author: Delta Medical
Requires at least: 6.3
Requires PHP: 7.4
Text Domain: fx-blank
*/

/* ---------- Шрифт (у темі, без Google Fonts) ---------- */
@font-face {
	font-family: "Rubik";
	font-style: normal;
	font-weight: 300 900;
	font-display: swap;
	src: url("assets/fonts/rubik-cyr.woff2") format("woff2");
	unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
	font-family: "Rubik";
	font-style: normal;
	font-weight: 300 900;
	font-display: swap;
	src: url("assets/fonts/rubik-lat.woff2") format("woff2");
	unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Змінні ---------- */
:root {
	--fx-red: #e10019;
	--fx-red-dark: #b80015;
	--fx-blue: #004a99;
	--fx-sky: #009ddf;
	--fx-sky-soft: #e6f5fc;
	--fx-ice: #f3f9fd;
	--fx-ink: #0f2540;
	--fx-text: #33475e;
	--fx-muted: #6b7c90;
	--fx-line: #d9e6f0;
	--fx-white: #fff;
	--fx-radius: 22px;
	--fx-radius-s: 12px;
	--fx-shadow: 0 18px 40px -22px rgba(0, 74, 153, .35);
	--fx-wrap: 1180px;
	--fx-font: "Rubik", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
}

/* ---------- База ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
body {
	margin: 0;
	font-family: var(--fx-font);
	font-size: 17px;
	line-height: 1.6;
	color: var(--fx-text);
	background: var(--fx-white);
	overflow-x: hidden;
}
img, svg, video, iframe { max-width: 100%; }
img { height: auto; vertical-align: middle; }
a { color: var(--fx-blue); text-underline-offset: 3px; }
a:hover { color: var(--fx-red); }
h1, h2, h3, h4 { color: var(--fx-ink); line-height: 1.2; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(28px, 4.2vw, 46px); letter-spacing: -.01em; }
h2 { font-size: clamp(24px, 3.2vw, 36px); }
h3 { font-size: clamp(19px, 2.2vw, 24px); }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--fx-sky); outline-offset: 2px; }
.screen-reader-text, .skip-link:not(:focus) {
	position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 1000; background: #fff; padding: 10px 16px; border-radius: 8px; }

.fx-wrap { width: 100%; max-width: var(--fx-wrap); margin: 0 auto; padding: 0 20px; }

/* ---------- Верхня смуга ---------- */
.fx-top { background: var(--fx-white); border-bottom: 1px solid var(--fx-line); }
.fx-top .fx-wrap { display: flex; align-items: center; justify-content: space-between; min-height: 46px; gap: 16px; }
.fx-top__schonen img { display: block; width: 118px; height: auto; }

.dm-lang-switch ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 3px; background: var(--fx-ice); border-radius: 999px; }
.dm-lang-switch li > * { display: block; padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 600; text-decoration: none; color: var(--fx-blue); line-height: 1.4; }
.dm-lang-switch .is-current > * { background: var(--fx-blue); color: #fff; }
.dm-lang-switch a:hover { background: #fff; color: var(--fx-red); }

/* ---------- Шапка ---------- */
.fx-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.4) blur(8px); transition: box-shadow .2s; }
.fx-header.is-scrolled { box-shadow: 0 6px 24px -14px rgba(0, 40, 90, .45); }
.fx-header .fx-wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 78px; }
.fx-brand { display: flex; flex-direction: column; gap: 2px; text-decoration: none; min-width: 0; }
.fx-brand img { display: block; width: 220px; height: auto; }
.fx-brand__tag { margin: 0; font-size: 12px; line-height: 1.35; color: var(--fx-sky); font-style: italic; max-width: 330px; }

.fx-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; flex-wrap: wrap; }
.fx-nav a { display: block; padding: 10px 14px; border-radius: 999px; font-size: 15px; font-weight: 600; text-transform: uppercase; letter-spacing: .03em; color: var(--fx-ink); text-decoration: none; }
.fx-nav a:hover, .fx-nav .current-menu-item > a { background: var(--fx-sky-soft); color: var(--fx-blue); }
.fx-burger { display: none; width: 46px; height: 46px; border: 0; border-radius: 12px; background: var(--fx-sky-soft); color: var(--fx-blue); cursor: pointer; padding: 0; }
.fx-burger span, .fx-burger span::before, .fx-burger span::after { display: block; width: 22px; height: 2px; background: currentColor; margin: 0 auto; position: relative; border-radius: 2px; transition: transform .2s, background .2s; }
.fx-burger span::before, .fx-burger span::after { content: ""; position: absolute; left: 0; }
.fx-burger span::before { top: -7px; }
.fx-burger span::after { top: 7px; }
.fx-burger[aria-expanded="true"] span { background: transparent; }
.fx-burger[aria-expanded="true"] span::before { transform: translateY(7px) rotate(45deg); }
.fx-burger[aria-expanded="true"] span::after { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px) {
	.fx-burger { display: block; flex: none; }
	.fx-brand img { width: 170px; }
	.fx-brand__tag { font-size: 11px; max-width: 240px; }
	.fx-nav { position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-top: 1px solid var(--fx-line); box-shadow: 0 20px 30px -20px rgba(0, 40, 90, .4); display: none; }
	.fx-nav.is-open { display: block; }
	.fx-nav ul { flex-direction: column; padding: 10px 16px 18px; }
	.fx-nav a { padding: 13px 14px; border-radius: 12px; }
}

/* ---------- Контент ---------- */
.fx-main { display: block; }
.fx-page { padding: 48px 0 72px; }
.fx-page__head { margin-bottom: 28px; }
.fx-entry > * { max-width: 820px; margin-left: auto; margin-right: auto; }
.fx-entry > .alignwide { max-width: var(--fx-wrap); }
.fx-entry > .alignfull { max-width: none; }
.fx-entry ul, .fx-entry ol { padding-left: 1.3em; }
.fx-entry li { margin-bottom: .35em; }
.fx-entry img { border-radius: var(--fx-radius-s); }
.fx-entry iframe { width: 100%; min-height: 300px; border: 0; border-radius: var(--fx-radius-s); }

/* Класична тема обгортає вміст групи в inner-container — робимо його «прозорим» для сітки. */
.wp-block-group__inner-container { display: contents; }
.fx-landing .fx-sec > .wp-block-group__inner-container > * { max-width: var(--fx-wrap); margin-left: auto; margin-right: auto; }
.fx-faq > .wp-block-group__inner-container > .wp-block-details { max-width: 860px; }
.fx-legal > .wp-block-group__inner-container > p { max-width: var(--fx-wrap); margin: 0 auto; }

/* Лендінг: секції на всю ширину, вміст у межах fx-wrap */
.fx-landing > * { margin: 0; }
.fx-landing .fx-sec { padding: clamp(48px, 7vw, 96px) 20px; position: relative; }
.fx-landing .fx-sec > * { max-width: var(--fx-wrap); margin-left: auto; margin-right: auto; }
.fx-landing .wp-block-columns { gap: clamp(24px, 4vw, 56px); margin-bottom: 0; }

/* Кнопки */
.wp-block-buttons { display: flex; flex-wrap: wrap; gap: 12px; }
.wp-block-button__link, .fx-btn {
	display: inline-flex; align-items: center; gap: 10px; padding: 15px 28px; border-radius: 999px;
	background: var(--fx-red); color: #fff; font-weight: 600; font-size: 17px; text-decoration: none; line-height: 1.2;
	box-shadow: 0 12px 24px -12px rgba(225, 0, 25, .7); transition: transform .15s, background .15s;
}
.wp-block-button__link:hover, .fx-btn:hover { background: var(--fx-red-dark); color: #fff; transform: translateY(-2px); }
.wp-block-button__link::after { content: "→"; font-weight: 400; }
.is-style-outline .wp-block-button__link { background: #fff; color: var(--fx-blue); border: 2px solid var(--fx-blue); box-shadow: none; }
.is-style-outline .wp-block-button__link:hover { background: var(--fx-blue); color: #fff; }

/* Hero */
.fx-hero { background: radial-gradient(1200px 600px at 85% 20%, #d7effb 0%, rgba(215, 239, 251, 0) 60%), linear-gradient(180deg, #f6fbfe 0%, #fff 100%); overflow: hidden; }
.fx-hero .wp-block-columns { align-items: center; }
.fx-hero h1 { margin-bottom: 22px; }
.fx-hero h1 strong, .fx-hero h1 mark { color: var(--fx-red); background: none; }
.fx-hero__media { position: relative; }
.fx-hero__media .fx-pack { margin: 0; filter: drop-shadow(0 30px 40px rgba(0, 60, 120, .22)); }
.fx-hero__media .fx-pack img { border-radius: 0; width: 100%; }
.fx-hero__media .fx-months { position: absolute; right: -2%; bottom: -6%; width: 30%; max-width: 170px; margin: 0; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .15)); }
.fx-hero__media .fx-months img { border-radius: 50%; background: #fff; }

/* Бейдж дозування */
.fx-dose { display: inline-flex; align-items: baseline; flex-wrap: wrap; gap: 6px; padding: 12px 20px; margin: 0 0 26px; border-radius: 999px; background: #fff; box-shadow: var(--fx-shadow); color: var(--fx-ink); font-size: 18px; }
.fx-dose strong { color: var(--fx-red); font-size: 22px; }

/* Про сухожилля */
.fx-about { background: var(--fx-ice); }
.fx-about .wp-block-columns { align-items: center; }
.fx-about .fx-circle img { border-radius: 50%; box-shadow: var(--fx-shadow); background: #fff; }
.fx-about p { font-size: clamp(16px, 1.6vw, 19px); line-height: 1.75; color: var(--fx-ink); }

/* Переваги */
.fx-features { background: linear-gradient(135deg, var(--fx-blue) 0%, #0074c4 55%, var(--fx-sky) 100%); color: #fff; overflow: hidden; }
.fx-features .wp-block-columns { align-items: center; }
.fx-features h2 { color: #fff; margin: 0; }
.fx-feat-title { display: flex; gap: 18px; align-items: center; margin-bottom: 28px; }
.fx-features .fx-check { width: 56px; flex: none; margin: 0; }
.fx-features .fx-check img { border-radius: 0; }
.fx-features .fx-leg img { border-radius: 50%; background: #fff; }
.fx-features .wp-block-button__link { background: #fff; color: var(--fx-red); }
.fx-features .wp-block-button__link:hover { background: var(--fx-red); color: #fff; }
.fx-zones { display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 16px !important; margin-top: 36px !important; }
.fx-zone { background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .25); border-radius: var(--fx-radius); padding: 22px 16px; text-align: center; margin: 0 !important; }
.fx-zone figure { margin: 0 auto 12px; width: 92px; height: 92px; border-radius: 50%; background: #fff; display: grid; place-items: center; }
.fx-zone figure img { width: 64px; height: 64px; border-radius: 0; }
.fx-zone p { margin: 0; font-weight: 600; color: #fff; font-size: 17px; }

/* Склад */
.fx-comp .wp-block-columns { align-items: center; }
.fx-comp-list { list-style: none; padding: 0 !important; margin: 0 0 28px; display: grid; gap: 10px; }
.fx-comp-list li { position: relative; margin: 0; padding: 12px 18px 12px 52px; background: #fff; border: 1px solid var(--fx-line); border-radius: var(--fx-radius-s); color: var(--fx-ink); font-weight: 500; }
.fx-comp-list li::before { content: ""; position: absolute; left: 16px; top: 50%; width: 22px; height: 12px; margin-top: -6px; background: var(--fx-red); clip-path: polygon(0 0, 100% 0, 80% 100%, 0 100%); }
.fx-comp .fx-pack img { border-radius: 0; }
.fx-circles { display: flex !important; gap: 16px; justify-content: center; flex-wrap: wrap; margin: 0 0 28px !important; }
.fx-circles p { width: 150px; height: 150px; margin: 0; border-radius: 50%; background: #fff; border: 3px solid var(--fx-sky); outline: 2px dashed rgba(225, 0, 25, .55); outline-offset: 6px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; line-height: 1.2; color: var(--fx-blue); font-size: 17px; }
.fx-circles strong { color: var(--fx-red); font-size: 30px; display: block; }

/* Компоненти */
.fx-ingr { background: var(--fx-ice); }
.fx-ingr h2 { text-align: center; }
.fx-chips { display: flex !important; flex-wrap: wrap; justify-content: center; gap: 12px; list-style: none; padding: 0 !important; margin: 28px auto 0 !important; max-width: 860px !important; }
.fx-chips li { margin: 0; padding: 12px 22px; border-radius: 999px; background: #fff; border: 2px solid var(--fx-sky); color: var(--fx-red); font-weight: 600; }
.fx-ingr .fx-pack { max-width: 460px !important; margin: 32px auto 0 !important; }
.fx-ingr .fx-pack img { border-radius: 0; }

/* Питання */
.fx-faq h2.fx-faq__title { text-align: center; }
.fx-faq .wp-block-details { background: #fff; border: 1px solid var(--fx-line); border-radius: var(--fx-radius-s); padding: 0; margin: 0 auto 12px !important; max-width: 860px !important; box-shadow: 0 6px 20px -16px rgba(0, 40, 90, .5); }
.fx-faq summary { cursor: pointer; list-style: none; padding: 20px 56px 20px 22px; position: relative; font-weight: 700; color: var(--fx-ink); font-size: 18px; }
.fx-faq summary::-webkit-details-marker { display: none; }
.fx-faq summary::after { content: "+"; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%; background: var(--fx-sky-soft); color: var(--fx-blue); display: grid; place-items: center; font-size: 20px; font-weight: 400; }
.fx-faq details[open] summary::after { content: "–"; background: var(--fx-red); color: #fff; }
.fx-faq details > :not(summary) { padding: 0 22px 18px; margin: 0; }

/* Застереження */
.fx-legal { padding: 28px 20px !important; background: #fff; border-top: 1px solid var(--fx-line); }
.fx-legal p { max-width: var(--fx-wrap); margin: 0 auto; font-size: 13px; line-height: 1.55; color: var(--fx-muted); }
.fx-legal strong { font-weight: 500; }

@media (max-width: 781px) {
	.fx-hero .wp-block-column.fx-hero__media { order: -1; }
	.fx-hero__media { max-width: 440px; margin: 0 auto; }
	.fx-zones { grid-template-columns: 1fr; }
	.fx-zone { display: flex; align-items: center; gap: 16px; text-align: left; padding: 14px 16px; }
	.fx-zone figure { margin: 0; width: 64px; height: 64px; flex: none; }
	.fx-zone figure img { width: 44px; height: 44px; }
	.fx-circles p { width: 128px; height: 128px; font-size: 15px; }
	.fx-about .fx-circle { max-width: 260px; margin: 0 auto; }
	.fx-features .fx-leg { max-width: 280px; margin: 0 auto; }
}

/* ---------- Статті ---------- */
.fx-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 28px; margin-top: 12px; }
.fx-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--fx-line); border-radius: var(--fx-radius); overflow: hidden; box-shadow: var(--fx-shadow); transition: transform .2s; }
.fx-card:hover { transform: translateY(-4px); }
.fx-card__img { display: block; aspect-ratio: 3 / 2; background: var(--fx-ice); overflow: hidden; }
.fx-card__img img { width: 100%; height: 100%; object-fit: cover; }
.fx-card__body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.fx-card__date { font-size: 13px; color: var(--fx-muted); margin-bottom: 8px; }
.fx-card h2 { font-size: 21px; margin-bottom: 10px; }
.fx-card h2 a { color: var(--fx-ink); text-decoration: none; }
.fx-card h2 a:hover { color: var(--fx-red); }
.fx-card p { font-size: 15px; color: var(--fx-text); }
.fx-card__more { margin-top: auto; font-weight: 600; text-decoration: none; color: var(--fx-red); }

.fx-article__cover { max-width: 980px; margin: 0 auto 32px; }
.fx-article__cover img { width: 100%; border-radius: var(--fx-radius); }
.fx-article__meta { font-size: 14px; color: var(--fx-muted); }
.fx-back { display: inline-block; margin-top: 36px; font-weight: 600; text-decoration: none; }

.fx-crumbs { font-size: 14px; color: var(--fx-muted); margin-bottom: 14px; }
.fx-crumbs a { color: var(--fx-muted); }

/* Контакти: офіси карточками */
.fx-entry > .fx-offices { max-width: var(--fx-wrap); display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 24px; margin-top: 8px; margin-bottom: 0; }
.fx-office { display: flex; flex-direction: column; background: var(--fx-ice); border: 1px solid var(--fx-line); border-radius: var(--fx-radius); padding: 22px 22px 22px; }
.fx-office p { margin: 0 0 .4em; font-size: 16px; line-height: 1.55; }
.fx-office p strong { display: inline-block; font-size: 18px; color: var(--fx-ink); margin-bottom: 4px; }
.fx-office p:last-of-type { margin-bottom: 16px; }
.fx-office iframe { display: block; width: 100%; height: 240px; min-height: 0; margin-top: auto; border-radius: var(--fx-radius-s); }
.fx-entry > p > iframe, .fx-entry > iframe { display: block; }

/* ---------- 404 ---------- */
.fx-404 { text-align: center; padding: 90px 20px 110px; }
.fx-404 b { display: block; font-size: clamp(80px, 14vw, 150px); line-height: 1; color: var(--fx-sky-soft); -webkit-text-stroke: 2px var(--fx-sky); }

/* ---------- Підвал ---------- */
.fx-footer { background: var(--fx-ink); color: #c9d6e4; padding: 48px 0 28px; font-size: 15px; }
.fx-footer a { color: #fff; }
.fx-footer__grid { display: grid; grid-template-columns: auto 1fr 1.4fr; gap: 32px; align-items: start; }
.fx-footer__logo { display: block; width: 84px; background: #fff; border-radius: 14px; padding: 8px; }
.fx-footer__logo img { display: block; width: 100%; height: auto; }
.fx-footer__fb { font-weight: 600; font-size: 17px; text-decoration: none; line-height: 1.35; }
.fx-footer__fb:hover { color: var(--fx-sky) !important; }
.fx-footer p { margin: 0 0 .5em; }
.fx-footer strong { color: #fff; }
.fx-footer__copy { border-top: 1px solid rgba(255, 255, 255, .12); margin-top: 32px; padding-top: 18px; font-size: 13px; color: #8ea3ba; }
@media (max-width: 781px) {
	.fx-footer__grid { grid-template-columns: 1fr; gap: 20px; }
}
