/**
 * NT Projektai – "Paslaugos": service cards and completed works grid on the
 * Services page (built on nt-home-section.css), and the shared single work
 * page (hero, gallery, description).
 *
 * Every rule is scoped to the widgets' own classes or to the work template's
 * <main class="nt-work-main">. Values below are defaults; the widgets' Style
 * controls override them through the custom properties.
 */

/* ------------------------------------------------------------------ */
/* Section header (service cards, works grid)                          */
/* ------------------------------------------------------------------ */

.nt-home-section .nt-works-header {
	margin: 0 0 var(--nth-block-gap);
}

.nt-works-header--center .nt-works-header {
	max-width: 760px;
	margin-right: auto;
	margin-left: auto;
	text-align: center;
}

.nt-works-header--center .nt-home-section__intro {
	margin-right: auto;
	margin-left: auto;
}

/* ------------------------------------------------------------------ */
/* Service cards                                                       */
/* ------------------------------------------------------------------ */

.nt-services {
	--nts-columns: 3;
	--nts-gap: 28px;
	--nts-card-bg: #fff;
	--nts-card-border: #ece7dd;
	--nts-radius: 20px;
	--nts-ratio: 16 / 10;
	--nts-fit: cover;
	--nts-focus: center center;
	--nts-check: #1f5d48;
	--nts-check-bg: #e7ede4;
	--nts-items-gap: 10px;
	--nts-card-dir: column;
	--nts-media-w: 100%;
	--nts-media-ratio: var(--nts-ratio);
	background-color: #f7f4ee;
	scroll-margin-top: 90px;
}

.nt-services .nt-services__grid {
	display: grid;
	grid-template-columns: repeat(var(--nts-columns), minmax(0, 1fr));
	gap: var(--nts-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

.nt-services .nt-services__card {
	display: flex;
	flex-direction: var(--nts-card-dir);
	min-width: 0;
	margin: 0;
	padding: 0;
	overflow: hidden;
	border: 1px solid var(--nts-card-border);
	border-radius: var(--nts-radius);
	background: var(--nts-card-bg);
	box-shadow: 0 1px 2px rgba(15, 42, 33, 0.04), 0 12px 32px rgba(15, 42, 33, 0.05);
	/* Card anchors (e.g. footer links): land below the sticky header. */
	scroll-margin-top: 110px;
}

.nt-services .nt-services__media {
	flex: none;
	width: var(--nts-media-w);
	aspect-ratio: var(--nts-media-ratio);
	margin: 0;
	padding: 0;
	overflow: hidden;
	background: #ece8df;
}

.nt-services .nt-services__image {
	display: block;
	width: 100%;
	max-width: none;
	height: 100%;
	margin: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	object-fit: var(--nts-fit);
	object-position: var(--nts-focus);
}

.nt-services .nt-services__body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-width: 0;
	padding: 28px 28px 32px;
}

.nt-services .nt-services__title {
	margin: 0 0 10px;
	padding: 0;
	color: var(--nth-heading);
	font-family: var(--nth-font-heading);
	font-size: 23px;
	font-weight: 600;
	line-height: 1.25;
	letter-spacing: -0.01em;
	text-transform: none;
}

.nt-services .nt-services__text {
	margin: 0 0 20px;
	padding: 0;
	color: var(--nth-text);
	font-size: 16px;
	line-height: 1.6;
}

.nt-services .nt-services__list {
	display: flex;
	flex-direction: column;
	gap: var(--nts-items-gap);
	margin: 0;
	padding: 18px 0 0;
	border-top: 1px solid #efebe3;
	list-style: none;
}

.nt-services .nt-services__item {
	display: flex;
	align-items: flex-start;
	gap: 12px;
	margin: 0;
	padding: 0;
	color: var(--nth-heading);
	font-size: 15.5px;
	line-height: 1.5;
}

.nt-services .nt-services__check {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 22px;
	height: 22px;
	margin-top: 1px;
	border-radius: 50%;
	background: var(--nts-check-bg);
	color: var(--nts-check);
}

.nt-services .nt-services__check svg {
	display: block;
}

/* ------------------------------------------------------------------ */
/* Completed works grid                                                */
/* ------------------------------------------------------------------ */

.nt-works {
	--ntw-columns: 3;
	--ntw-gap: 28px;
	--ntw-card-bg: #fff;
	--ntw-card-border: #ece7dd;
	--ntw-radius: 20px;
	--ntw-ratio: 3 / 2;
	--ntw-fit: cover;
	--ntw-arrow: #1f5d48;
	--ntw-arrow-bg: #e7ede4;
	--ntw-page-color: #26292a;
	--ntw-page-border: #e3ddd1;
	--ntw-page-active-bg: #1f5d48;
	--ntw-page-active-color: #fff;
	--ntw-pagination-gap: 48px;
	scroll-margin-top: 90px;
}

.nt-works .nt-works__grid {
	display: grid;
	grid-template-columns: repeat(var(--ntw-columns), minmax(0, 1fr));
	gap: var(--ntw-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

.nt-works .nt-works__item {
	display: flex;
	min-width: 0;
	margin: 0;
	padding: 0;
}

.nt-works .nt-work-card {
	position: relative;
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-width: 0;
	overflow: hidden;
	border: 1px solid var(--ntw-card-border);
	border-radius: var(--ntw-radius);
	background: var(--ntw-card-bg);
	transition:
		box-shadow var(--nth-duration) var(--nth-ease),
		transform var(--nth-duration) var(--nth-ease);
}

.nt-works .nt-work-card:hover,
.nt-works .nt-work-card:focus-within {
	box-shadow: 0 18px 44px rgba(15, 42, 33, 0.12), 0 2px 8px rgba(15, 42, 33, 0.06);
	transform: translateY(-3px);
}

.nt-works .nt-work-card__media {
	aspect-ratio: var(--ntw-ratio);
	overflow: hidden;
	background: #ece8df;
}

.nt-works .nt-work-card__image {
	display: block;
	width: 100%;
	max-width: none;
	height: 100%;
	margin: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
	object-fit: var(--ntw-fit);
}

.nt-works .nt-work-card__placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	color: #a9b3a6;
}

.nt-works .nt-work-card__placeholder .ntp-icon {
	width: 48px;
	height: 48px;
}

.nt-works .nt-work-card__body {
	flex: 1 1 auto;
	padding: 22px 76px 26px 24px;
}

.nt-works .nt-work-card__title {
	margin: 0;
	padding: 0;
	color: var(--nth-heading);
	font-family: var(--nth-font-heading);
	font-size: 20px;
	font-weight: 600;
	line-height: 1.3;
	text-transform: none;
}

.nt-works .nt-work-card__link,
.nt-works .nt-work-card__link:visited,
.nt-works .nt-work-card__link:hover {
	color: inherit;
	text-decoration: none;
}

.nt-works .nt-work-card__link:focus-visible {
	outline: none;
}

/* The title link covers the whole card. */
.nt-works .nt-work-card__link::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	border-radius: inherit;
}

.nt-works .nt-work-card:focus-within {
	outline: 2px solid var(--nth-accent);
	outline-offset: 3px;
}

.nt-works .nt-work-card__excerpt {
	margin: 8px 0 0;
	padding: 0;
	color: var(--nth-text);
	font-size: 15px;
	line-height: 1.55;
}

.nt-works .nt-work-card__arrow {
	position: absolute;
	right: 22px;
	bottom: 24px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: var(--ntw-arrow-bg);
	color: var(--ntw-arrow);
	transition:
		background-color var(--nth-duration) var(--nth-ease),
		color var(--nth-duration) var(--nth-ease),
		transform var(--nth-duration) var(--nth-ease);
}

.nt-works .nt-work-card:hover .nt-work-card__arrow,
.nt-works .nt-work-card:focus-within .nt-work-card__arrow {
	background: var(--ntw-arrow);
	color: #fff;
	transform: translateX(2px);
}

.nt-works .nt-works__empty {
	margin: 0 auto;
	color: var(--nth-text);
	font-size: 16px;
	text-align: center;
}

/* Pagination */
.nt-works .nt-works__pagination {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 8px;
	margin-top: var(--ntw-pagination-gap);
}

.nt-works .nt-works__page,
.nt-works .nt-works__page:visited {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	height: 44px;
	padding: 0 12px;
	border: 1px solid var(--ntw-page-border);
	border-radius: 999px;
	background: #fff;
	color: var(--ntw-page-color);
	font-size: 15px;
	font-weight: 500;
	line-height: 1;
	text-decoration: none;
	transition:
		background-color var(--nth-duration) var(--nth-ease),
		border-color var(--nth-duration) var(--nth-ease),
		color var(--nth-duration) var(--nth-ease);
}

.nt-works a.nt-works__page:hover,
.nt-works a.nt-works__page:focus-visible {
	border-color: var(--ntw-page-active-bg);
	color: var(--ntw-page-active-bg);
	text-decoration: none;
}

.nt-works a.nt-works__page:focus-visible {
	outline: 2px solid var(--ntw-page-active-bg);
	outline-offset: 2px;
}

.nt-works .nt-works__page.is-current {
	border-color: var(--ntw-page-active-bg);
	background: var(--ntw-page-active-bg);
	color: var(--ntw-page-active-color);
}

.nt-works .nt-works__page--gap {
	min-width: 24px;
	padding: 0;
	border-color: transparent;
	background: transparent;
}

.nt-works .screen-reader-text,
.nt-works-scope .nt-works-sr-only {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* ------------------------------------------------------------------ */
/* Single work page                                                    */
/* ------------------------------------------------------------------ */

/* Lift the theme's boxed .site-main limits on this template's own <main> only. */
html body .site-main.nt-work-main {
	width: 100%;
	max-width: none;
	margin: 0;
	padding-inline-start: 0;
	padding-inline-end: 0;
}

.nt-works-scope {
	--ntw-width: 1300px;
	--ntw-gutter: 20px;
	--ntw-pad-top: 80px;
	--ntw-pad-bottom: 80px;
	--ntw-accent: #1f5d48;
	--ntw-heading: #26292a;
	--ntw-text: #595c5d;
	--ntw-ease: cubic-bezier(0.25, 0.1, 0.25, 1);
	--ntw-font-heading: var(--e-global-typography-secondary-font-family, "Libre Franklin"), sans-serif;
	--ntw-font-body: var(--e-global-typography-text-font-family, "Roboto"), sans-serif;
	box-sizing: border-box;
	display: block;
	width: 100%;
	color: var(--ntw-text);
	font-family: var(--ntw-font-body);
	font-size: 16px;
	line-height: 1.65;
}

.nt-works-scope *,
.nt-works-scope *::before,
.nt-works-scope *::after {
	box-sizing: border-box;
}

.nt-works-scope .nt-works-inner {
	width: 100%;
	max-width: var(--ntw-width);
	margin: 0 auto;
}

.nt-works-scope .nt-works-eyebrow {
	margin: 0 0 12px;
	padding: 0;
	color: var(--ntw-accent);
	font-family: var(--ntw-font-body);
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

.nt-works-scope .nt-works-heading {
	margin: 0;
	padding: 0;
	color: var(--ntw-heading);
	font-family: var(--ntw-font-heading);
	font-size: clamp(28px, 2.6vw, 38px);
	font-weight: 600;
	line-height: 1.2;
	letter-spacing: -0.015em;
	text-transform: none;
}

.nt-works-notice {
	box-sizing: border-box;
	max-width: 1300px;
	margin: 16px auto;
	padding: 14px 18px;
	border: 1px dashed #c9b98f;
	border-radius: 10px;
	background: #fbf8f1;
	color: #5b4e2e;
	font-family: var(--e-global-typography-text-font-family, "Roboto"), sans-serif;
	font-size: 14px;
	line-height: 1.5;
}

/* Hero */
.nt-work-hero {
	--ntw-hero-height: 540px;
	--ntw-hero-box: 780px;
	--ntw-hero-pos: center center;
	--ntw-hero-overlay: #0f2a21;
	--ntw-hero-opacity: 0.82;
	position: relative;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	min-height: var(--ntw-hero-height);
	padding: 40px var(--ntw-gutter) 72px;
	overflow: hidden;
	background-color: #1f4a3a;
	isolation: isolate;
}

.nt-work-hero .nt-work-hero__image {
	position: absolute;
	inset: 0;
	z-index: -2;
	display: block;
	width: 100%;
	max-width: none;
	height: 100%;
	margin: 0;
	border: 0;
	border-radius: 0;
	object-fit: cover;
	object-position: var(--ntw-hero-pos);
}

.nt-work-hero .nt-work-hero__overlay {
	position: absolute;
	inset: 0;
	z-index: -1;
	background-image: linear-gradient(
		90deg,
		var(--ntw-hero-overlay) 0%,
		color-mix(in srgb, var(--ntw-hero-overlay) 70%, transparent) 45%,
		color-mix(in srgb, var(--ntw-hero-overlay) 15%, transparent) 100%
	);
	opacity: var(--ntw-hero-opacity);
	pointer-events: none;
}

.nt-work-hero--no-image .nt-work-hero__overlay {
	display: none;
}

.nt-work-hero .nt-work-hero__inner {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	justify-content: space-between;
	gap: 40px;
	width: 100%;
	max-width: var(--ntw-width);
	margin: 0 auto;
}

.nt-work-hero .nt-work-hero__box {
	max-width: var(--ntw-hero-box);
	margin-top: auto;
}

.nt-work-hero .nt-work-hero__back,
.nt-work-hero .nt-work-hero__back:visited {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	gap: 8px;
	padding: 8px 16px 8px 12px;
	border: 1px solid rgba(255, 255, 255, 0.28);
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.08);
	color: #fff;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.2;
	text-decoration: none;
	backdrop-filter: blur(4px);
	transition: background-color 0.3s var(--ntw-ease);
}

.nt-work-hero .nt-work-hero__back:hover,
.nt-work-hero .nt-work-hero__back:focus-visible {
	background: rgba(255, 255, 255, 0.2);
	color: #fff;
	text-decoration: none;
}

.nt-work-hero .nt-work-hero__back:focus-visible {
	outline: 2px solid #fff;
	outline-offset: 2px;
}

.nt-work-hero .nt-work-hero__eyebrow {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 18px;
	padding: 0;
	color: #fff;
	font-size: 14px;
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: 0.18em;
	text-transform: uppercase;
}

.nt-work-hero .nt-work-hero__eyebrow::before {
	content: "";
	display: block;
	flex: 0 0 auto;
	width: 40px;
	height: 2px;
	border-radius: 2px;
	background-color: #a3b18a;
}

.nt-work-hero .nt-work-hero__title {
	margin: 0;
	padding: 0;
	color: #fff;
	font-family: var(--ntw-font-heading);
	font-size: clamp(36px, 4.2vw, 60px);
	font-weight: 600;
	line-height: 1.1;
	letter-spacing: -0.02em;
	text-transform: none;
	text-wrap: balance;
}

.nt-work-hero .nt-work-hero__text {
	max-width: 620px;
	margin: 18px 0 0;
	padding: 0;
	color: rgba(255, 255, 255, 0.88);
	font-size: 18px;
	line-height: 1.6;
}

.nt-work-hero .nt-work-hero__meta {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin: 22px 0 0;
	padding: 8px 14px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
	color: #fff;
	font-size: 14px;
	line-height: 1.2;
}

.nt-work-hero .nt-work-hero__meta .ntp-icon {
	width: 18px;
	height: 18px;
}

/* Gallery: justified rows. Each cell grows in proportion to its photo's aspect
   ratio (--r), so every row shares one height and no photo is cropped. */
.nt-work-gallery {
	--ntw-row-h: 300px;
	--ntw-gallery-gap: 14px;
	--ntw-tile-radius: 14px;
	padding: var(--ntw-pad-top) var(--ntw-gutter) var(--ntw-pad-bottom);
	background-color: #fff;
}

.nt-work-gallery .nt-work-gallery__head {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 12px 24px;
	margin: 0 0 32px;
}

.nt-work-gallery .nt-work-gallery__count {
	margin: 0;
	color: var(--ntw-text);
	font-size: 15px;
}

.nt-work-gallery .nt-work-gallery__grid {
	display: flex;
	flex-wrap: wrap;
	gap: var(--ntw-gallery-gap);
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Keeps the last row at its natural height instead of stretching it. */
.nt-work-gallery .nt-work-gallery__grid::after {
	content: "";
	flex-grow: 1000000;
}

.nt-work-gallery .nt-work-gallery__cell {
	flex-grow: var(--r);
	flex-basis: calc(var(--r) * var(--ntw-row-h));
	min-width: 0;
	margin: 0;
	padding: 0;
}

.nt-work-gallery .nt-work-gallery__figure {
	margin: 0;
}

.nt-work-gallery .nt-work-gallery__item {
	position: relative;
	display: block;
	overflow: hidden;
	border-radius: var(--ntw-tile-radius);
	background: transparent;
	isolation: isolate;
}

.nt-work-gallery .nt-work-gallery__item:focus-visible {
	outline: 2px solid var(--ntw-accent);
	outline-offset: 3px;
}

.nt-work-gallery .nt-work-gallery__image {
	display: block;
	width: 100%;
	max-width: none;
	/* Natural height from the width keeps the original proportions: never cropped or stretched. */
	height: auto;
	aspect-ratio: var(--r);
	margin: 0;
	padding: 0;
	border: 0;
	border-radius: 0;
	box-shadow: none;
}

.nt-work-gallery .nt-work-gallery__zoom {
	position: absolute;
	right: 12px;
	bottom: 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	border-radius: 50%;
	background: #fff;
	color: var(--ntw-accent);
	box-shadow: 0 2px 8px rgba(15, 42, 33, 0.15);
	opacity: 0;
	transform: translateY(4px);
	transition:
		opacity 0.3s var(--ntw-ease),
		transform 0.3s var(--ntw-ease);
}

.nt-work-gallery .nt-work-gallery__item:hover .nt-work-gallery__zoom,
.nt-work-gallery .nt-work-gallery__item:focus-visible .nt-work-gallery__zoom {
	opacity: 1;
	transform: none;
}

.nt-work-gallery .nt-work-gallery__caption {
	margin: 8px 2px 0;
	color: var(--ntw-text);
	font-size: 14px;
	line-height: 1.5;
}

/* Description */
.nt-work-content {
	--ntw-width: 820px;
	padding: var(--ntw-pad-top) var(--ntw-gutter) var(--ntw-pad-bottom);
	background-color: #fff;
}

.nt-work-content .nt-works-heading {
	margin-bottom: 22px;
}

.nt-work-content .nt-work-content__body {
	color: var(--ntw-text);
	font-size: 17px;
	line-height: 1.75;
}

.nt-work-content .nt-work-content__body > :first-child {
	margin-top: 0;
}

.nt-work-content .nt-work-content__body > :last-child {
	margin-bottom: 0;
}

.nt-work-content .nt-work-content__body p,
.nt-work-content .nt-work-content__body ul,
.nt-work-content .nt-work-content__body ol {
	margin: 0 0 1.1em;
}

.nt-work-content .nt-work-content__body h2,
.nt-work-content .nt-work-content__body h3,
.nt-work-content .nt-work-content__body h4 {
	margin: 1.6em 0 0.6em;
	color: var(--ntw-heading);
	font-family: var(--ntw-font-heading);
	line-height: 1.3;
}

.nt-work-content .nt-work-content__body a {
	color: var(--ntw-accent);
}

.nt-work-content .nt-work-content__body img {
	max-width: 100%;
	height: auto;
	border-radius: 12px;
}

.nt-work-content .nt-work-content__back,
.nt-work-content .nt-work-content__back:visited {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	margin-top: 36px;
	color: var(--ntw-accent);
	font-size: 16px;
	font-weight: 500;
	text-decoration: none;
}

.nt-work-content--back-only .nt-work-content__back {
	margin-top: 0;
}

.nt-work-content .nt-work-content__back:hover,
.nt-work-content .nt-work-content__back:focus-visible {
	text-decoration: underline;
	text-underline-offset: 4px;
}

/* ------------------------------------------------------------------ */
/* Responsive (Elementor breakpoints)                                  */
/* ------------------------------------------------------------------ */

@media (max-width: 1024px) {
	.nt-services {
		--nts-columns: 1;
		--nts-card-dir: row;
		--nts-media-w: 40%;
		--nts-media-ratio: auto;
	}

	.nt-works {
		--ntw-columns: 2;
	}

	.nt-works-scope {
		--ntw-gutter: 32px;
	}

	.nt-work-hero {
		--ntw-hero-height: 460px;
		padding-bottom: 56px;
	}
}

@media (max-width: 767px) {
	.nt-services {
		--nts-card-dir: column;
		--nts-media-w: 100%;
		--nts-media-ratio: var(--nts-ratio);
	}

	.nt-services .nt-services__body {
		padding: 22px 20px 26px;
	}

	.nt-services .nt-services__title {
		font-size: 21px;
	}

	.nt-works {
		--ntw-columns: 1;
	}

	.nt-works .nt-work-card__body {
		padding: 20px 72px 22px 20px;
	}

	.nt-works .nt-works__page {
		min-width: 40px;
		height: 40px;
	}

	.nt-works-scope {
		--ntw-gutter: 20px;
	}

	.nt-work-hero {
		--ntw-hero-height: 420px;
		padding-top: 24px;
		padding-bottom: 40px;
	}

	.nt-work-hero .nt-work-hero__eyebrow {
		font-size: 13px;
	}

	.nt-work-hero .nt-work-hero__title {
		font-size: 34px;
	}

	.nt-work-hero .nt-work-hero__text {
		font-size: 16px;
	}

	/* Phones: one photo per row, full width, natural height. */
	.nt-work-gallery .nt-work-gallery__cell {
		flex-basis: 100%;
	}

	.nt-work-gallery .nt-work-gallery__head {
		margin-bottom: 22px;
	}

	.nt-work-content .nt-work-content__body {
		font-size: 16px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.nt-works .nt-work-card,
	.nt-works .nt-work-card__arrow,
	.nt-work-gallery .nt-work-gallery__zoom {
		transition: none;
	}

	.nt-works .nt-work-card:hover,
	.nt-works .nt-work-card:focus-within {
		transform: none;
	}
}
