/*
Theme Name: Lysterra
Template: twentytwentyfive
Description: Дочерняя тема Twenty Twenty-Five для lysterra.com (замена Motors + WPBakery)
Version: 1.0.0
Text Domain: lysterra
*/

:root {
	--lys-blue: #00a7d4;
	--lys-green: #a6ce39;
	--lys-dark: #273f44;
	--lys-text: #888;
	--lys-w: 1170px;
}

body { background: #eee; font-family: 'Open Sans', sans-serif; font-weight: 400; color: #232628; font-size: 15px; line-height: 1.55; }
.wp-site-blocks { min-height: 100vh; display: flex; flex-direction: column; }
.wp-site-blocks > main { flex: 1 0 auto; }
h1, h2, h3, h4, h5, h6 { font-family: Montserrat, sans-serif; color: var(--lys-dark); font-weight: 700; }
a { color: var(--lys-blue); }

/* header / footer */
.lys-header { background: var(--lys-blue); }
.lys-header__in { max-width: 1110px; margin: 0 auto; padding: 0; display: flex; align-items: center; gap: 40px; min-height: 96px; flex-wrap: wrap; }
.lys-logo img { height: 52px; width: auto; display: block; }
.lys-menu { list-style: none; margin: 0 auto; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 48px; }
.lys-menu a { color: #fff; text-decoration: none; text-transform: uppercase; font-weight: 700; font-size: 13px; letter-spacing: .01em; }
.lys-menu a:hover, .lys-menu .current-menu-item a { text-decoration: underline; text-underline-offset: 6px; }
.lys-footer { background: var(--lys-blue); color: #fff; padding: 22px 0; font-size: 13px; }
.lys-footer__in { max-width: 1110px; margin: 0 auto; padding-left: 0; }

main.lys-main { margin: 0; padding: 0; max-width: none; }
.lys-page-title { max-width: var(--lys-w); margin: 0 auto; padding: 40px 15px 10px; font-size: 30px; text-transform: uppercase; }

/* rows from converted WPBakery pages */
.lys-row { background-size: cover; background-position: center; }
.lys-row:not(.is-full):not(.is-inner) { max-width: var(--lys-w); margin-left: auto; margin-right: auto; padding-left: 15px; padding-right: 15px; box-sizing: border-box; }
.lys-cols { display: flex; flex-wrap: wrap; margin: 0 auto; max-width: var(--lys-w); }
.is-full > .lys-cols { max-width: none; }
.is-inner > .lys-cols { margin: 0; max-width: none; }
.lys-col { box-sizing: border-box; padding: 0 15px; width: var(--w, 100%); }
.is-full > .lys-cols > .lys-col { padding: 0; }
.is-full > .lys-cols > .lys-col > .lys-text { padding-left: 15px; padding-right: 15px; }
.is-equal > .lys-cols > .lys-col:first-child > .lys-text { padding-left: max(15px, calc((100vw - var(--lys-w)) / 2 + 15px)); padding-right: 40px; }
.stm-stretch-image-right { background-size: cover; background-position: center; min-height: 380px; }
.lys-text p { margin: 0 0 13px; }
.lys-text h1, .lys-text h2 { font-size: 36px; margin: 0 0 22px; line-height: 1.2; }
.lys-text h3 { font-size: 24px; margin: 0 0 10px; line-height: 1.25; }
.lys-heading { margin: 0 0 20px; font-weight: 600; }
.lys-figure { margin: 0 0 25px; }
.lys-img { max-width: 100%; height: auto; display: block; }
.lys-sep { border: 0; border-top: 1px solid #e5e5e5; margin: 0 0 19px; }
.lys-video { max-width: 100%; height: auto; display: block; }

.lys-iconbox { display: flex; gap: 14px; margin-bottom: 30px; padding-right: 20px; }
.lys-icon { flex: none; width: 46px; height: 46px; border-radius: 50%; background: var(--lys-blue); display: flex; align-items: center; justify-content: center; }
.lys-icon svg { width: 24px; height: 24px; fill: #fff; }
.lys-iconbox h4 { margin: 0 0 8px; font-size: 14px; text-transform: uppercase; font-weight: 400; }
.lys-iconbox p { margin: 0; font-size: 12px; line-height: 20px; color: var(--lys-text); }

.lys-quotes { display: flex; flex-wrap: wrap; gap: 20px; margin: 0 -5px 40px; }
.lys-quote { flex: 1 1 260px; margin: 0; padding: 20px 25px; border: 1px solid #e0e0e0; text-align: center; background: #fafafa; font-size: 12px; }
.lys-quote cite { display: block; font-style: normal; font-size: 15px; margin-bottom: 8px; color: var(--lys-dark); }
.lys-quote p { margin: 0; }

.lys-map { width: 100%; background: #e8eef0; position: relative; z-index: 0; }

/* hero (was Revolution Slider) */
.lys-hero { position: relative; min-height: 610px; background-size: cover; background-position: center top; background-color: #e7e7e7; overflow: hidden; }
.lys-hero__in { max-width: 1240px; margin: 0 auto; position: relative; min-height: 610px; padding: 46px 15px 0 58px; box-sizing: border-box; font-family: Oswald, sans-serif; text-transform: uppercase; }
.lys-hero h2 { font-family: Oswald, sans-serif; font-weight: 400; font-size: 61px; line-height: 1.1; color: var(--lys-green); margin: 0 0 22px; }
.lys-hero__sub { display: flex; justify-content: space-between; font-size: 26px; line-height: 1; color: #959595; max-width: 1120px; }
.lys-hero__sub a { color: var(--lys-blue); text-decoration: none; }
.lys-hero ul { list-style: none; margin: 0; padding: 0; position: absolute; left: 50px; top: 360px; display: grid; grid-template-columns: repeat(3, 300px); grid-auto-flow: column; grid-template-rows: repeat(3, 60px); color: #fff; font-size: 45px; line-height: 36px; }
@media (max-width: 960px) {
	.lys-col { width: 100%; }
	.lys-hero, .lys-hero__in { min-height: 0; }
	.lys-hero__in { padding: 30px 15px; }
	.lys-hero h2 { font-size: 34px; }
	.lys-hero__sub { flex-direction: column; gap: 8px; font-size: 18px; }
	.lys-hero ul { position: static; grid-template-columns: 1fr 1fr; grid-template-rows: none; grid-auto-flow: row; font-size: 26px; line-height: 1.6; margin-top: 30px; }
	.is-equal > .lys-cols > .lys-col:first-child > .lys-text { padding: 20px 15px; }
}

.lys-menu li { position: relative; }
.lys-menu .sub-menu { display: none; position: absolute; left: 0; top: 100%; z-index: 20; min-width: 200px; margin: 0; padding: 10px 14px; list-style: none; background: var(--lys-blue); }
.lys-menu li:hover > .sub-menu, .lys-menu li:focus-within > .sub-menu { display: block; }
.lys-text h3 a { color: #fff; text-decoration: none; }

body.lys-white { background: #fff; }
.lys-banner { background: #273f44 url(images/title-bg.jpg) center / cover; min-height: 222px; display: flex; align-items: center; justify-content: center; padding: 20px 15px; box-sizing: border-box; }
.lys-banner h1 { color: #fff; font-size: 36px; font-weight: 700; margin: 0; text-transform: uppercase; text-align: center; }
.lys-iconbox.is-plain { gap: 14px; margin-bottom: 14px; }
.lys-iconbox.is-plain .lys-icon { width: 22px; height: 22px; background: none; border-radius: 0; margin-top: 3px; }
.lys-iconbox.is-plain .lys-icon svg { width: 22px; height: 22px; fill: var(--ic, #f0c540); }
.lys-iconbox.is-plain p, .lys-iconbox.is-plain span { color: #2a4045; font-size: 15px; line-height: 22px; font-weight: 300; }

.lys-text a { color: inherit; text-decoration: none; }
.lys-text a:hover { text-decoration: underline; }

.lys-text table, .lys-text th, .lys-text td { border-color: #e5e5e5 !important; }
.lys-text table { border-collapse: collapse; max-width: 100%; }

.is-full:not(.is-equal) > .lys-cols > .lys-col:first-child > .lys-text { padding-inline: max(15px, calc((100vw - var(--lys-w)) / 2 + 15px)); }

/* --- правки по сверке с продом --- */
body { font-size: 14px; color: #2a4045; letter-spacing: normal; }
h1, h2, h3, h4, h5, h6 { font-weight: 700; letter-spacing: normal; }
.lys-text h3 { font-size: 24px; margin: 0 0 18px; }
.lys-text p { margin: 0 0 16px; }
.wp-site-blocks > header { position: sticky; top: 0; z-index: 100; }
.lys-menu a, .lys-menu li a { font-family: Montserrat, sans-serif; }
.lys-menu a:hover { text-decoration: underline; text-underline-offset: 6px; }
.lys-menu .current-menu-item > a { text-decoration: none; }
.lys-menu .sub-menu { background: #fff; box-shadow: 0 8px 20px rgba(0,0,0,.15); padding: 12px 20px; }
.lys-menu .sub-menu a { color: #232628; text-transform: none; font-weight: 400; font-size: 14px; white-space: nowrap; }
.lys-menu .sub-menu a:hover { color: var(--lys-blue); text-decoration: none; }
.lys-hero h2 { font-family: Roboto, sans-serif; }
.lys-iconbox h4 { font-size: 17px; font-weight: 400; }
.lys-iconbox p { font-family: Montserrat, sans-serif; font-size: 14px; color: #232628; }
.lys-quote { background: transparent; border: 1px dashed #c9c9c9; }
.lys-quote a { color: #6c98e1; font-size: 13px; text-decoration: none; }
.lys-parallax { min-height: 350px; background-size: cover; background-position: center; background-attachment: fixed; }
.lys-videobox { position: relative; }
.lys-play { position: absolute; inset: 0 0 52px; margin: auto; width: 76px; height: 76px; border: 3px solid #fff; border-radius: 50%; background: rgba(0,0,0,.15); cursor: pointer; }
.lys-play::before { content: ""; position: absolute; left: 30px; top: 21px; border-style: solid; border-width: 15px 0 15px 25px; border-color: transparent transparent transparent #fff; }
.lys-videobox.is-playing .lys-play { display: none; }
.lys-lightbox { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,.88); display: flex; align-items: center; justify-content: center; padding: 30px; cursor: zoom-out; }
.lys-lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; }
.lys-lightbox button { position: absolute; top: 12px; right: 18px; background: none; border: 0; color: #fff; font-size: 40px; line-height: 1; cursor: pointer; }
.lys-burger, .lys-subtoggle { display: none; }
@media (max-width: 960px) {
	.lys-header__in { gap: 0; justify-content: space-between; min-height: 70px; padding: 0 15px; }
	.lys-burger { display: block; width: 44px; height: 44px; background: none; border: 0; cursor: pointer; position: relative; z-index: 1002; }
	.lys-burger::before, .lys-burger::after, .lys-burger span { content: ""; position: absolute; left: 9px; right: 9px; height: 3px; background: #fff; }
	.lys-burger::before { top: 14px; } .lys-burger span { top: 21px; } .lys-burger::after { top: 28px; }
	.lys-nav { position: fixed; top: 0; right: 0; bottom: 0; width: min(320px, 85vw); background: #273f44; padding: 70px 0 20px; transform: translateX(100%); transition: transform .25s; z-index: 1001; overflow-y: auto; }
	.lys-nav-open .lys-nav { transform: none; }
	.lys-nav .lys-menu { display: block; margin: 0; }
	.lys-nav .lys-menu > li { border-bottom: 1px solid rgba(255,255,255,.12); position: relative; }
	.lys-nav .lys-menu a { display: block; padding: 14px 40px 14px 24px; }
	.lys-subtoggle { display: block; position: absolute; right: 0; top: 0; width: 44px; height: 48px; background: none; border: 0; color: #fff; font-size: 22px; cursor: pointer; }
	.lys-subtoggle::before { content: "+"; }
	.is-open > .lys-subtoggle::before { content: "\2212"; }
	.lys-nav .sub-menu { display: none; position: static; box-shadow: none; background: rgba(0,0,0,.18); padding: 0; }
	.lys-nav .is-open > .sub-menu { display: block; }
	.lys-nav .sub-menu a { color: #fff; padding-left: 40px; }
	.lys-menu li:hover > .sub-menu { display: none; }
	.lys-menu .is-open:hover > .sub-menu { display: block; }
	.lys-parallax { background-attachment: scroll; min-height: 220px; }
}

/* --- правки по повторной сверке --- */
.wp-block-post-content > *:not(.lys-row), .lys-main > *:not(.wp-block-post-content) { margin-block: 0 !important; }
.wp-block-post-content > .lys-row { margin-block: 0; }
.lys-text h3 { margin-bottom: 34px; }
.is-full .is-inner .lys-text p { margin-bottom: 33px; }
.lys-iconbox { padding-right: 4px; }
.lys-heading { font-weight: 700; }
.lys-row:has(> .lys-cols > .lys-col > .lys-quotes) { padding-top: 40px; }
@media (min-width: 961px) { .lys-text h3 { white-space: nowrap; } }
@media (max-width: 960px) {
	.lys-nav-open .lys-burger span { opacity: 0; }
	.lys-nav-open .lys-burger::before { top: 21px; transform: rotate(45deg); }
	.lys-nav-open .lys-burger::after { top: 21px; transform: rotate(-45deg); }
}
.is-full .is-inner .lys-text:last-child p:last-child { margin-bottom: 0; }

/* анимация hero (как в Revolution Slider: слева с проявлением, задержки из слайда) */
@keyframes lys-in-left { from { opacity: 0; transform: translateX(-70vw); } to { opacity: 1; transform: none; } }
@keyframes lys-fade { from { opacity: 0; } to { opacity: 1; } }
.lys-hero h2 { animation: lys-fade 1s ease-out .1s both; }
.lys-hero__sub > * { animation: lys-in-left .85s cubic-bezier(.215, .61, .355, 1) 1.23s both; }
.lys-hero li { animation: lys-in-left .6s cubic-bezier(.215, .61, .355, 1) 3.86s both; }
.lys-hero li:nth-child(1) { animation-delay: 1.55s; }
.lys-hero li:nth-child(2) { animation-delay: 1.92s; }
.lys-hero li:nth-child(3) { animation-delay: 2.34s; }
.lys-hero li:nth-child(4) { animation-delay: 2.68s; }
.lys-hero li:nth-child(5) { animation-delay: 3.03s; }
.lys-hero li:nth-child(6) { animation-delay: 3.46s; }
@media (prefers-reduced-motion: reduce) { .lys-hero h2, .lys-hero__sub > *, .lys-hero li { animation: none; } }

/* карусель «Lysterra in Media»: на мобильных по одной карточке, на десктопе три подряд */
.lys-dots { display: none; justify-content: center; gap: 8px; margin: 0 0 30px; }
.lys-dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: #c9c9c9; cursor: pointer; }
.lys-dots button.is-active { background: var(--lys-blue); }
@media (max-width: 768px) {
	.lys-quotes { flex-wrap: nowrap; overflow-x: auto; scroll-snap-type: x mandatory; gap: 0; margin: 0 0 14px; scrollbar-width: none; }
	.lys-quotes::-webkit-scrollbar { display: none; }
	.lys-quote { flex: 0 0 100%; box-sizing: border-box; scroll-snap-align: center; }
	.lys-dots { display: flex; }
}
