:root {
	--wood: #8b5e3c;
	--graphite: #232323;
	--white: #ffffff;
	--light: #f5f5f5;
}

* {
	margin: 0;
	padding: 0;
	box-sizing: border-box;
}

html {
	scroll-behavior: smooth;
}

body {
	font-family: Poppins, sans-serif;
	background: #fff;
	color: #232323;
	position: relative;
}

body::after {
	content: "";
	position: fixed;
	inset: 0;
	pointer-events: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160' viewBox='0 0 160 160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
	opacity: 0.03;
	z-index: 9999;
}

.container {
	width: min(1200px, 90%);
	margin: auto;
}

header {
	position: fixed;
	width: 100%;
	background: rgba(35, 35, 35, 0.92);
	backdrop-filter: blur(10px);
	z-index: 1000;
}

nav {
	height: 80px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.logo {
	color: #fff;
	font-weight: 700;
	letter-spacing: 2px;
}

.nav-links {
	display: flex;
	list-style: none;
	gap: 40px;
}

.nav-links a {
	color: white;
	text-decoration: none;
	transition: 0.3s;
}

.nav-links a:hover {
	color: var(--wood);
}

.hero {
	min-height: 100svh;
	height: auto;
	background: none;
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 170px 0 90px;
	overflow: hidden;
}

.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: url("../images/hero_drzwi_debowe_premium_baldor_desktop.webp");
	background-position: center;
	background-size: cover;
	background-repeat: no-repeat;
	background-color: #111;
	animation: heroMove 28s ease-in-out infinite alternate;
	z-index: 0;
}

/* tablet */
@media (max-width: 1200px) {
	.hero::before {
		background-image: url("../images/hero_drzwi_debowe_premium_baldor_tablet.webp");
	}

	.hero h1 {
		font-size: clamp(4.2rem, 8vw, 5.8rem);
	}

	.hero h2 {
		font-size: clamp(1.45rem, 3.2vw, 2.35rem);
	}
}

/* telefon */
@media (max-width: 576px) {
	.hero::before {
		background-image: url("../images/hero_drzwi_debowe_premium_baldor_mobile.webp");
	}
}

.overlay {
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	z-index: 1;
}

.hero-content {
	position: relative;
	color: white;
	text-align: center;
	width: min(800px, calc(100% - 32px));
	max-width: 800px;
	padding: 20px;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 16px;
	z-index: 2;
}

@keyframes heroMove {
	from {
		transform: scale(1);
	}

	to {
		transform: scale(1.05) translateY(-8px);
	}
}

.hero h1 {
	font-size: clamp(3.1rem, 8vw, 5.5rem);
	line-height: 0.92;
	letter-spacing: -0.02em;
	margin-bottom: 0;
}

.hero h2 {
	font-size: clamp(1.6rem, 4vw, 2.7rem);
	line-height: 1.15;
	margin: 0;
	text-wrap: balance;
}

.hero p {
	font-size: clamp(1rem, 2vw, 1.25rem);
	line-height: 1.75;
	margin-bottom: 0;
	max-width: 62ch;
	text-wrap: pretty;
}

.btn {
	display: inline-block;
	background: linear-gradient(
		120deg,
		#6f4528 0%,
		#8b5e3c 38%,
		#c8a06c 50%,
		#8b5e3c 62%,
		#6f4528 100%
	);
	background-size: 220% 100%;
	background-position: 0% 50%;
	padding: 15px 35px;
	color: white;
	text-decoration: none;
	border: none;
	cursor: pointer;
	transition: background-position 0.65s ease, transform 0.3s ease;
}

.btn:hover {
	background-position: 100% 50%;
	transform: translateY(-1px);
}

@media (max-width: 768px) {
	.hero {
		padding: 140px 0 70px;
	}

	.hero-content {
		width: min(100% - 24px, 640px);
		padding: 16px;
		gap: 14px;
	}

	.hero h1 {
		font-size: clamp(2.95rem, 8.2vw, 4.35rem);
	}

	.hero p {
		max-width: 100%;
	}
}

@media (max-width: 576px) {
	.hero {
		padding: 140px 0 58px;
	}

	.hero-content {
		width: calc(100% - 20px);
		gap: 12px;
	}

	.hero h1 {
		font-size: clamp(3.5rem, 17vw, 4.65rem);
	}

	.hero h2 {
		font-size: clamp(1.35rem, 6vw, 1.95rem);
	}

	.hero p {
		font-size: 0.88rem;
		line-height: 1.65;
	}

	.btn {
		width: 100%;
		max-width: 320px;
		text-align: center;
		padding: 14px 20px;
	}
}

section {
	padding: 100px 0;
}

#home {
	padding: 0;
}

h2 {
	text-align: center;
	margin-bottom: 50px;
	font-size: 40px;
}

.why h2,
#process h2,
#our-story h2,
.gallery h2,
.faq h2,
#reviews h2 {
	position: relative;
	padding-bottom: 18px;
	margin-bottom: 42px;
}

.why h2::after,
#process h2::after,
#our-story h2::after,
.gallery h2::after,
.faq h2::after,
#reviews h2::after {
	content: "";
	display: block;
	width: 260px;
	height: 4px;
	margin: 18px auto 0;
	background-repeat: no-repeat;
	background-position: center;
	background-size: 100% 100%;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='10' viewBox='0 0 220 10' preserveAspectRatio='none'%3E%3Cpath d='M2 5H218' fill='none' stroke='%238b6a46' stroke-width='1' stroke-linecap='round'/%3E%3C/svg%3E");
	opacity: 0.95;
}

.cards {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 30px;
}

.card {
	background: white;
	padding: 35px;
	border-radius: 15px;
	box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

.why .card {
	position: relative;
	overflow: hidden;
	transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.why .card::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0;
	width: 0;
	height: 2px;
	background: linear-gradient(90deg, #c8a96a, #e6cc8f);
	transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.why .card:hover,
.why .card:focus-within {
	transform: translateY(-6px);
	box-shadow: 0 20px 50px rgba(0, 0, 0, 0.16);
}

.why .card:hover::before,
.why .card:focus-within::before {
	width: 100%;
}

.card h3 {
	margin-bottom: 15px;
}

.why-footer {
	margin-top: 60px;
	padding: 20px;
	background: #f5f5f5;
	border-radius: 15px;
	text-align: center;
	line-height: 1.8;
	color: #555;
	max-width: 900px;
	margin-left: auto;
	margin-right: auto;
}

.gallery{

    background:#faf9f7;
    padding:120px 0;
}

.gallery-desc{

    max-width:700px;
    margin:25px auto 70px;
    text-align:center;
    color:#666;
    line-height:1.8;
}

.projects{

    display:grid;
	grid-template-columns:repeat(4,minmax(0,1fr));
	gap:24px;
}

.project{

    text-decoration:none;
    color:inherit;
}

.project-image{

    position:relative;
    overflow:hidden;
	border-radius:14px;
	aspect-ratio: 3 / 5;
}

.project-image img{

    width:100%;
	height:100%;
    object-fit:cover;

    transition:.6s;
}

.project:hover img{

    transform:scale(1.04);
}

.project-count{

    position:absolute;
	top:14px;
	right:14px;

    background:rgba(255,255,255,.92);

    backdrop-filter:blur(10px);

	padding:7px 12px;

    border-radius:30px;

	font-size:.72rem;

    letter-spacing:.08em;

    text-transform:uppercase;
}

.project-content{

	padding:14px 6px 4px;
}

.project-location{

	font-size:.66rem;

    text-transform:uppercase;

	letter-spacing:.15em;

    color:#8a8a8a;

	margin-bottom:6px;
}

.project h3{

	font-size:1.03rem;

	font-weight:600;

    margin:0;

    transition:.3s;
}

.project:hover h3{

    color:#8d6b3f;
}

.project-placeholder {
	cursor: default;
}

.project-image-placeholder {
	background: linear-gradient(145deg, #f2eee8, #ede7df);
	border: 2px dashed #d3c6b6;
}

.project-image-placeholder::before {
	content: "Brak zdjęcia";
	display: grid;
	place-items: center;
	width: 100%;
	height: 100%;
	color: #9a8875;
	font-size: 0.8rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 600;
}

@media (max-width: 1024px) {
	.projects {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 22px;
	}

	.project h3 {
		font-size: 1rem;
	}
}

@media (max-width: 576px) {
	.projects {
		grid-template-columns: 1fr;
		gap: 20px;
	}

	.project-image {
		aspect-ratio: 3 / 4;
	}
}

.lightbox {
	position: fixed;
	inset: 0;
	display: none;
	align-items: center;
	justify-content: center;
	padding: 24px;
	background: rgba(0, 0, 0, 0.88);
	z-index: 3000;
}

.lightbox.open {
	display: flex;
}

.lightbox-figure {
	margin: 0;
	max-width: min(1100px, 88vw);
	max-height: 86vh;
	text-align: center;
}

.lightbox-image {
	display: block;
	max-width: 100%;
	max-height: 78vh;
	object-fit: contain;
	border-radius: 10px;
	box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.lightbox-caption {
	margin-top: 14px;
	color: #f0f0f0;
	font-size: 14px;
	letter-spacing: 0.03em;
}

.lightbox-close,
.lightbox-nav {
	position: absolute;
	border: none;
	background: rgba(255, 255, 255, 0.18);
	backdrop-filter: blur(10px);
	color: #fff;
	cursor: pointer;
	transition: background 0.25s ease, transform 0.25s ease;
}

.lightbox-close:hover,
.lightbox-nav:hover,
.lightbox-close:focus-visible,
.lightbox-nav:focus-visible {
	background: rgba(255, 255, 255, 0.28);
	transform: translateY(-1px);
}

.lightbox-close {
	top: 22px;
	right: 22px;
	width: 44px;
	height: 44px;
	border-radius: 50%;
	font-size: 30px;
	line-height: 1;
}

.lightbox-nav {
	top: 50%;
	transform: translateY(-50%);
	width: 52px;
	height: 52px;
	border-radius: 50%;
	font-size: 28px;
	line-height: 1;
}

.lightbox-prev {
	left: 24px;
}

.lightbox-next {
	right: 24px;
}

.faq {
	padding-top: 0;
}

.grid {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
	gap: 20px;
}

.process-intro {
	max-width: 700px;
	margin: 0 auto 50px;
	text-align: center;
	line-height: 1.8;
	color: #555;
}

.timeline {
	display: flex;
	flex-direction: column;
	gap: 20px;
	max-width: 700px;
	margin: auto;
	counter-reset: step;
}

.timeline-step {
	padding: 30px 30px 30px 80px;
	position: relative;
	background: #f5f5f5;
	border-radius: 10px;
}

.timeline-step::before {
	content: counter(step);
	counter-increment: step;
	position: absolute;
	left: 20px;
	top: 50%;
	transform: translateY(-50%);
	width: 37px;
	height: 37px;
	background: #20252d;
	color: white;
	border-radius: 50%;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
}

.timeline-step h3 {
	font-size: 18px;
	margin-bottom: 10px;
	color: #20252d;
}

.timeline-step p {
	line-height: 1.8;
	color: #444;
}

.timeline .arrow {
	background: transparent;
	padding: 30px 0;
	font-size: 24px;
	color: white;
}

.faq {
	background: url("../images/faq_drzwi_debowe_premium_baldor.webp") center/cover;
	position: relative;
	color: white;
	height: 100vh;
	overflow: hidden;
}

.faq::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	z-index: 0;
}

.faq .container {
	position: relative;
	z-index: 1;
	max-width: 1000px;
	padding: 20px;
	height: 100%;
	display: flex;
	flex-direction: column;
}

.faq h2 {
	color: white;
	flex-shrink: 0;
	padding: 40px 0 20px;
}

.faq-list {
    flex: 1;
    overflow-y: auto;
}

.faq-item {
	margin-bottom: 20px;
}

.faq-item button {
	width: 100%;
	padding: 20px;
	background: transparent;
	color: white;
	border: none;
	text-align: left;
	cursor: pointer;
	font-size: 18px;
	font-weight: 600;
	display: flex;
	align-items: center;
	gap: 12px;
}

.faq-item button::before {
	content: "❯";
	display: inline-block;
	transition: transform 0.8s ease;
	transform-origin: center;
}

.faq-item button.active::before {
	transform: rotate(90deg);
}

.answer {
	max-height: 0;
	overflow: hidden;
	transition: max-height 0.4s ease, padding 0.4s ease;
	padding: 0 20px;
	background: transparent;
	color: white;
}

.answer.open {
	max-height: 300px;
	padding: 15px 20px;
}

#contact {
	background: none;
	position: relative;
	color: white;
	height: 100vh;
	display: flex;
	align-items: center;
	overflow: hidden;
}

#contact::after {
	content: "";
	position: absolute;
	inset: 0;
	background: url("../images/contact_drzwi_drewniane_premium_baldor.webp") center/cover;
	animation: heroMove 28s ease-in-out infinite alternate;
	z-index: 0;
}

#contact::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(0, 0, 0, 0.55);
	z-index: 1;
}

#contact .container {
	position: relative;
	z-index: 2;
	max-width: 600px;
	width: min(600px, 100%);
	padding: clamp(20px, 4vw, 40px);
	margin: 0 auto 0 clamp(30px, 6vw, 110px);
}

#contact h2 {
	color: white;
	margin-bottom: 40px;
}

#contact form {
	order: -1;
}

.about {
	max-width: 800px;
	margin: auto;
	text-align: center;
	line-height: 1.8;
}

#our-story {
	background: #20252d;
	color: white;
	padding: 100px 0;
}

#our-story h2 {
	text-align: center;
	margin-bottom: 60px;
}

.our-story-layout {
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
	gap: 48px;
	align-items: start;
}

.our-story-article {
	font-size: 16px;
	line-height: 1.8;
	color: #d6d6d6;
}

.story-image {
	width: 100%;
	height: min(560px, 70vh);
	object-fit: cover;
	display: block;
	border-radius: 12px;
	box-shadow: 0 18px 42px rgba(0, 0, 0, 0.35);
	filter: grayscale(40%);
	transform: scale(1);
	transition: filter 0.45s ease, transform 0.45s ease;
}

.our-story-figure:hover .story-image,
.our-story-figure:focus-within .story-image {
	filter: grayscale(25%);
	transform: scale(1.015);
}

.our-story-figure {
	margin: 0;
}

.our-story-article h3 {
  font-size: 24px;
  color: white;
	margin: 0 0 20px;
}

.our-story-article h3 + p {
	margin-top: 0;
}

.our-story-article p {
  margin-bottom: 18px;
  text-align: justify;
}

@media (max-width: 1024px) {
	.our-story-layout {
		grid-template-columns: 1fr;
		gap: 28px;
	}

	.our-story-figure {
		order: -1;
	}

	.story-image {
		height: auto;
		max-height: 520px;
	}
}

@media (max-width: 768px) {
	#our-story {
		padding: 80px 0;
	}

	#our-story h2 {
		margin-bottom: 36px;
	}

	.our-story-article h3 {
		font-size: 22px;
  }

  .our-story-article p {
    text-align: left;
  }
}

#reviews {
	background: var(--light);
	color: #232323;
	padding: 100px 0;
}

#reviews h2 {
	text-align: center;
	margin-bottom: 50px;
	color: #232323;
}

#reviews .reviews {
	width: 100%;
}

.reviews {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
	gap: 25px;
	margin-top: 50px;
}

.review {
	padding: 30px;
	background: white;
	box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
	border-radius: 12px;
	position: relative;
	overflow: hidden;
	transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
		box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.review::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0;
	width: 0;
	height: 2px;
	background: linear-gradient(90deg, #c8a96a, #e6cc8f);
	transition: width 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.review:hover,
.review:focus-within {
	transform: translateY(-6px);
	box-shadow: 0 20px 50px rgba(0, 0, 0, 0.16);
}

.review:hover::before,
.review:focus-within::before {
	width: 100%;
}

.review-rating {
	margin-bottom: 15px;
	font-size: 20px;
	letter-spacing: 2px;
	color: #d4af37;
}

.review-meta {
	margin-top: 16px;
	padding-top: 14px;
	border-top: 1px solid #ececec;
	display: flex;
	justify-content: space-between;
	gap: 12px;
	font-size: 14px;
	line-height: 1.4;
}

.review-name {
	font-weight: 600;
	color: #232323;
}

.review-city {
	color: #666;
}

form {
	max-width: 100%;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.contact-content {
	max-width: 100%;
}

.contact-header {
	font-size: 24px;
	font-weight: 700;
	margin-bottom: 20px;
}

.contact-content h3 {
	font-size: 32px;
	font-weight: 600;
	margin-bottom: 20px;
}

.contact-content p {
	font-size: 16px;
	line-height: 1.6;
	margin-bottom: 20px;
}

.contact-info {
	margin-top: 40px;
	display: flex;
	flex-direction: column;
	gap: 15px;
}

.contact-item {
	font-size: 14px;
}

.contact-item a {
	color: inherit;
	text-decoration: none;
}

.contact-item a:hover,
.contact-item a:focus-visible {
	text-decoration: underline;
}

input,
textarea {
	padding: 18px;
	border: 1px solid #ddd;
	font-family: inherit;
	background: white;
	color: #232323;
}

textarea {
	height: 180px;
	resize: none;
}

footer {
	background: #232323;
	color: white;
	text-align: center;
	padding: 8px;
	font-size: 12px;
}

.burger {
	display: none;
	flex-direction: column;
	gap: 5px;
	cursor: pointer;
}

.burger span {
	width: 26px;
	height: 3px;
	background: white;
}

@media (max-width: 768px) {
	.lightbox {
		padding: 16px;
	}

	.lightbox-nav {
		width: 44px;
		height: 44px;
		font-size: 24px;
	}

	.lightbox-prev {
		left: 10px;
	}

	.lightbox-next {
		right: 10px;
	}

	.lightbox-close {
		top: 10px;
		right: 10px;
	}

	.lightbox-image {
		max-height: 74vh;
	}

	.nav-links {
		position: absolute;
		top: 80px;
		right: -100%;
		width: 260px;
		height: calc(100vh - 80px);
		background: #232323;
		flex-direction: column;
		padding: 40px;
		transition: 0.4s;
	}

	.nav-links.active {
		right: 0;
	}

	.burger {
		display: flex;
	}

	.cards {
		grid-template-columns: 1fr;
	}

	#contact {
		height: auto;
		min-height: 100vh;
		align-items: flex-start;
		padding: 80px 0;
	}

	#contact .container {
		width: 100%;
		padding: 20px;
	}

}
