/* =========================================================================
   OMK — компоненты: hero, карточки, технологии, процесс, кейсы, CTA
   ========================================================================= */

/* ---------- Hero ---------- */
.hero {
	position: relative;
	background: var(--white);
	background-image: url('../img/hero-bg.jpg');
	background-size: cover;
	background-position: center;
	color: var(--text);
	overflow: hidden;
}

.hero-inner {
	position: relative;
	display: grid;
	grid-template-columns: 0.92fr 1.08fr;
	align-items: stretch;
	gap: 0;
}

.hero-content {
	padding: 96px 0 88px;
	padding-right: 48px;
}

.hero h1 {
	font-size: clamp(34px, 4.6vw, 56px);
	font-weight: 600;
	letter-spacing: -0.025em;
	margin-bottom: 22px;
	color: var(--text);
}

.hero-sub {
	font-size: 18px;
	line-height: 1.6;
	color: var(--text-2);
	max-width: 520px;
	margin-bottom: 36px;
}

.hero-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	margin-bottom: 48px;
}

/* Преимущества: иконка + заголовок + подзаголовок */
.hero-features {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 18px 28px;
	list-style: none;
	margin: 0;
	padding: 0;
	max-width: 520px;
}
.hero-features li {
	display: flex;
	align-items: center;
	gap: 14px;
}
.hf-icon {
	flex: none;
	width: 46px;
	height: 46px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	background: var(--bg-alt);
	color: var(--text);
	border: 1px solid var(--border);
}
.hf-text {
	display: flex;
	flex-direction: column;
	line-height: 1.3;
}
.hf-text strong {
	font-family: var(--font-heading);
	font-size: 15.5px;
	font-weight: 700;
	color: var(--text);
}
.hf-text small {
	font-size: 12.5px;
	color: var(--text-2);
}

/* Визуал: изделие крупное, выходит за контейнер вправо до края экрана */
.hero-visual {
	position: relative;
	color: var(--white);
	display: flex;
	align-items: center;
	justify-content: flex-end;
	overflow: hidden;
	margin-right: calc(50% - 50vw);
	padding: 36px 0 84px 12px;
}
.hero-visual::after {
	content: '';
	position: absolute;
	inset: 0;
	background: radial-gradient(520px 420px at 65% 40%, rgba(204,255,0,.12), transparent 60%);
	pointer-events: none;
}

.hero-visual img.hero-product {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: contain;
}

.hero-video-link {
	position: absolute;
	bottom: 26px;
	right: 24px;
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 13px;
	color: #AAB3C5;
	max-width: 260px;
	line-height: 1.35;
}
.hero-video-link .play {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: var(--accent);
	color: var(--accent-ink);
	flex: none;
}
.hero-video-link:hover { color: var(--white); }

/* ---------- Секции ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-alt); }
.section-dark { background: var(--dark); color: #AAB3C5; }
.section-dark h2 { color: var(--white); }

/* ---------- Карточка «Что можно заказать» ---------- */
.offer-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 16px;
}

.offer-card {
	display: flex;
	flex-direction: column;
	padding: 20px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: #f0f0f0;
	transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.offer-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: #D1D5DB; }

.offer-visual {
	height: 130px;
	display: flex;
	align-items: center;
	justify-content: center;
	margin-bottom: 18px;
	border-radius: var(--radius-sm);
	background:
		linear-gradient(rgba(11,14,20,.03) 1px, transparent 1px),
		linear-gradient(90deg, rgba(11,14,20,.03) 1px, transparent 1px),
		var(--bg-alt);
	background-size: 20px 20px;
	overflow: hidden;
}
.offer-visual svg { width: 96px; height: 96px; }

.offer-visual.offer-photo {
	padding: 0;
	background: var(--bg-alt);
}
.offer-photo img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .3s ease;
}
.offer-card:hover .offer-photo img { transform: scale(1.04); }

.offer-card h3 { font-size: 17px; margin-bottom: 8px; }
.offer-card p { font-size: 13.5px; color: var(--text-2); margin-bottom: 0px; line-height: 1.55; flex: 1; }

.offer-link {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 6px;
	font-size: 13.5px;
	font-weight: 600;
	color: var(--text);
	margin-top: auto;
}

/* Хаб: карточки дочерних разделов на страницах-родителях */
.hub-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-top: 40px;
}
.hub-card {
	display: flex;
	flex-direction: column;
	padding: 24px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: #f0f0f0;
	transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.hub-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: #D1D5DB; }
.hub-card h3 { font-size: 16px; margin-bottom: 8px; }
.hub-card p { font-size: 13.5px; color: var(--text-2); margin-bottom: 16px; line-height: 1.55; flex: 1; }
.offer-link .icon { transition: transform .15s ease; }
.offer-link:hover .icon { transform: translateX(3px); }

/* ---------- Карточка «С чего начинаем» ---------- */
.start-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 16px;
}

.start-card {
	display: flex;
	flex-direction: column;
	padding: 26px 22px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
	transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}
.start-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); border-color: var(--accent); }

.start-icon {
	width: 48px;
	height: 48px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 12px;
	background: var(--dark);
	color: var(--accent);
	margin-bottom: 18px;
}
.start-icon svg { width: 24px; height: 24px; }

.start-card h3 { font-size: 16.5px; margin-bottom: 8px; }
.start-card p { font-size: 13.5px; color: var(--text-2); margin: 0; line-height: 1.55; }

/* ---------- Технологии ---------- */
.tech-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 16px;
}

.tech-card {
	display: flex;
	flex-direction: column;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
	overflow: hidden;
	transition: box-shadow .2s ease, transform .2s ease;
}
.tech-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }

.tech-visual {
	position: relative;
	height: 150px;
	background: var(--dark);
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	color: rgba(255,255,255,.92);
}
.tech-visual::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
	background-size: 24px 24px;
}
.tech-visual svg { position: relative; width: 84px; height: 84px; }
.tech-visual img {
	position: relative;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform .3s ease;
}
.tech-card:hover .tech-visual img { transform: scale(1.04); }
.tech-num {
	position: absolute;
	top: 12px;
	left: 14px;
	font-family: var(--font-mono);
	font-size: 12px;
	color: var(--accent);
	opacity: .85;
}

.tech-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.tech-body h3 { font-size: 17px; margin-bottom: 10px; }
.tech-body ul { list-style: none; margin: 0 0 16px; padding: 0; flex: 1; }
.tech-body li {
	position: relative;
	padding-left: 16px;
	font-size: 13px;
	color: var(--text-2);
	line-height: 1.55;
	margin-bottom: 7px;
}
.tech-body li::before {
	content: '';
	position: absolute;
	left: 0;
	top: 8px;
	width: 5px;
	height: 5px;
	border-radius: 50%;
	background: var(--accent);
}

/* ---------- Процесс (timeline) ---------- */
.steps-grid {
	display: grid;
	grid-template-columns: repeat(7, 1fr);
	gap: 14px;
	counter-reset: step;
}

.step-card {
	position: relative;
	padding: 24px 18px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
}
.step-card::after {
	content: '';
	position: absolute;
	top: 50%;
	right: -14px;
	width: 14px;
	height: 1px;
	background: var(--border);
}
.step-card:last-child::after { display: none; }

.step-num {
	font-family: var(--font-mono);
	font-size: 16px;
	font-weight: 700;
	color: var(--accent);
	background: var(--dark);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	border-radius: 8px;
	margin-bottom: 14px;
}

.step-card h3 { font-size: 14.5px; margin-bottom: 6px; line-height: 1.35; }
.step-card p { font-size: 12.5px; color: var(--text-2); margin: 0; line-height: 1.5; }

/* ---------- Кейсы ---------- */
.cases-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 20px;
}

.case-card {
	display: flex;
	flex-direction: column;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
	overflow: hidden;
	transition: box-shadow .2s ease, transform .2s ease;
}
.case-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }

.case-visual {
	position: relative;
	height: 190px;
	background: var(--dark);
	display: flex;
	align-items: center;
	justify-content: center;
	overflow: hidden;
	color: rgba(255,255,255,.92);
}
.case-visual::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
	background-size: 26px 26px;
}
.case-visual svg { position: relative; width: 120px; height: 120px; }

.case-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.case-body h3 { font-size: 17px; margin-bottom: 10px; }

.case-specs {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 14px;
}
.case-spec {
	font-size: 12px;
	font-weight: 500;
	color: var(--text-2);
	background: var(--bg-alt);
	border: 1px solid var(--border);
	padding: 5px 10px;
	border-radius: 100px;
}

.case-link {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	font-size: 14px;
	font-weight: 600;
	margin-top: auto;
}
.case-link .icon { transition: transform .15s ease; }
.case-link:hover .icon { transform: translateX(3px); }

.cases-more { text-align: center; margin-top: 40px; }

/* ---------- Преимущества (тёмные карточки) ---------- */
.adv-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 16px;
}

.adv-card {
	padding: 26px 22px;
	border: 1px solid var(--border-dark);
	border-radius: var(--radius);
	background: var(--dark-3);
	color: #AAB3C5;
	transition: border-color .2s ease, transform .2s ease;
}
.adv-card:hover { border-color: rgba(204,255,0,.4); transform: translateY(-3px); }

.adv-icon {
	width: 44px;
	height: 44px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: 10px;
	background: rgba(204,255,0,.12);
	color: var(--accent);
	margin-bottom: 16px;
}
.adv-icon svg { width: 22px; height: 22px; }

.adv-card h3 { font-size: 15.5px; color: var(--white); margin-bottom: 8px; }
.adv-card p { font-size: 13px; margin: 0; line-height: 1.55; }

/* ---------- Акцентный блок «1 изделие — это тоже заказ» ---------- */
.one-piece {
	position: relative;
	background: var(--accent);
	border-radius: 16px;
	padding: 56px 60px;
	overflow: hidden;
}
.one-piece::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(11,14,20,.06) 1px, transparent 1px),
		linear-gradient(90deg, rgba(11,14,20,.06) 1px, transparent 1px);
	background-size: 32px 32px;
	pointer-events: none;
}
.one-piece h2 { color: var(--accent-ink); font-size: clamp(26px, 3.2vw, 38px); margin-bottom: 14px; position: relative; }
.one-piece p { color: rgba(11,14,20,.75); font-size: 16px; max-width: 620px; margin-bottom: 24px; position: relative; }
.one-piece-list {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 28px;
	list-style: none;
	margin: 0;
	padding: 0;
	position: relative;
}
.one-piece-list li {
	display: flex;
	align-items: center;
	gap: 8px;
	font-weight: 600;
	font-size: 14.5px;
	color: var(--accent-ink);
}
.one-piece-list .check {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 20px;
	height: 20px;
	border-radius: 50%;
	background: var(--accent-ink);
	color: var(--accent);
	flex: none;
}

/* ---------- Финальный CTA ---------- */
.cta-final {
	position: relative;
	background: var(--dark);
	overflow: hidden;
}
.cta-final::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
	background-size: 56px 56px;
	pointer-events: none;
}
.cta-final-inner {
	position: relative;
	display: grid;
	grid-template-columns: 1.15fr 0.85fr;
	gap: 60px;
	align-items: center;
	padding: 88px 0;
}
.cta-final h2 { color: var(--white); margin-bottom: 16px; }
.cta-final .lead { margin-bottom: 36px; }

.cta-form { max-width: 560px; }
.cta-form .form-row { margin-bottom: 14px; }

.cta-drawing svg.blueprint { width: 100%; max-width: 420px; height: auto; margin-left: auto; }

/* ---------- Фильтры кейсов ---------- */
.filters {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 36px;
}
.filter-btn {
	padding: 9px 18px;
	border: 1px solid var(--border);
	border-radius: 100px;
	background: var(--white);
	font-size: 14px;
	font-weight: 500;
	color: var(--text-2);
	transition: all .15s ease;
}
.filter-btn:hover { border-color: var(--dark); color: var(--dark); }
.filter-btn.active { background: var(--dark); color: var(--white); border-color: var(--dark); }

/* ---------- Внутренние страницы: hero-блок ---------- */
.page-hero {
	background: var(--dark);
	color: var(--white);
	padding: 72px 0 64px;
	position: relative;
	overflow: hidden;
}
.page-hero::before {
	content: '';
	position: absolute;
	inset: 0;
	background-image:
		linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
		linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
	background-size: 56px 56px;
	pointer-events: none;
}
.page-hero .container { position: relative; }
.page-hero h1 { color: var(--white); margin-bottom: 14px; }
.page-hero .lead { color: #AAB3C5; }

/* Контентная сетка внутренней страницы */
.page-wrap {
	display: grid;
	grid-template-columns: 1fr 300px;
	gap: 48px;
	padding: 16px 0 80px;
}
.page-wrap-main { min-width: 0; }

.sidebar-card {
	border: 1px solid var(--border);
	border-radius: var(--radius);
	padding: 24px;
	margin-bottom: 20px;
	background: var(--white);
}
.sidebar-card h3 { font-size: 15px; margin-bottom: 14px; }
.sidebar-menu { list-style: none; margin: 0; padding: 0; }
.sidebar-menu li { margin-bottom: 8px; }
.sidebar-menu a { font-size: 14px; color: var(--text-2); }
.sidebar-menu a:hover { color: var(--dark); }
.sidebar-menu .current a { color: var(--dark); font-weight: 600; }

/* ---------- Блок связанных услуг/статей ---------- */
.related-block { margin-top: 56px; }
.related-block h2 { font-size: 24px; margin-bottom: 24px; }

.related-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}

.related-item {
	padding: 20px;
	border: 1px solid var(--border);
	border-radius: var(--radius);
	background: var(--white);
	transition: box-shadow .2s ease, transform .2s ease;
}
.related-item:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.related-item h3 { font-size: 15.5px; margin-bottom: 8px; }
.related-item p { font-size: 13px; color: var(--text-2); margin: 0; }

/* ---------- Контакты ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 460px; gap: 60px; align-items: start; }
.contact-card { display: flex; gap: 16px; align-items: flex-start; padding: 18px 0; border-bottom: 1px solid var(--border); }
.contact-icon { flex: none; width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; border-radius: 12px; background: var(--dark); color: var(--accent); }
.contact-label { display: block; font-size: 13px; color: var(--muted); margin-bottom: 3px; }
.contact-value { font-size: 17px; font-weight: 600; color: var(--text); display: block; }
a.contact-value:hover { color: var(--dark); }
@media (max-width: 992px) { .contact-grid { grid-template-columns: 1fr; gap: 40px; } }

/* ---------- Заглушки изображений (до загрузки фото) ---------- */
.placeholder-tag {
	position: absolute;
	bottom: 10px;
	right: 12px;
	font-family: var(--font-mono);
	font-size: 10.5px;
	color: rgba(255,255,255,.35);
	letter-spacing: .04em;
}

/* =========================================================================
   Адаптив
   ========================================================================= */

@media (max-width: 1180px) {
	.offer-grid, .start-grid, .tech-grid, .adv-grid { grid-template-columns: repeat(3, 1fr); }
	.hub-grid { grid-template-columns: repeat(2, 1fr); }
	.steps-grid { grid-template-columns: repeat(4, 1fr); row-gap: 20px; }
	.step-card::after { display: none; }
	.cases-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 992px) {
	.hero-inner { grid-template-columns: 1fr; }
	.hero-content { padding: 56px 0 48px; padding-right: 0; }
	.hero-visual { order: -1; min-height: 300px; margin-right: 0; padding: 48px 24px 80px; }
	.hero-visual img.hero-product { position: static; height: auto; }
	.cta-final-inner { grid-template-columns: 1fr; gap: 40px; }
	.cta-drawing { display: none; }
	.page-wrap { grid-template-columns: 1fr; }
	.sidebar { order: 2; }
}

@media (max-width: 768px) {
	.section { padding: 64px 0; }
	.section-head { flex-direction: column; align-items: flex-start; gap: 12px; margin-bottom: 28px; }
	.offer-grid, .start-grid, .tech-grid, .adv-grid { grid-template-columns: repeat(2, 1fr); }
	.steps-grid { grid-template-columns: repeat(2, 1fr); }
	.cases-grid { grid-template-columns: 1fr; }
	.one-piece { padding: 40px 28px; }
	.hero-features { gap: 14px 20px; }
	.hero-video-link { right: 16px; bottom: 16px; }
	.cta-final-inner { padding: 64px 0; }
}

@media (max-width: 480px) {
	.offer-grid, .start-grid, .tech-grid, .adv-grid { grid-template-columns: 1fr; }
	.hub-grid { grid-template-columns: 1fr; }
	.hero-actions .btn { width: 100%; }
	.hero-features { grid-template-columns: 1fr; }
	.page-hero { padding: 52px 0 48px; }
}
