/* --------------FLEXBOX------------------ */
/* Use this stylesheet for layout styling. Edit as needed to match your own design. */

/* ////////// Flexbox parent classes ////////// */

.inner-wrapper {
	/* We're setting every inner-wrapper to be a flexbox parent, but setting the default flex-direction to column, so that it's still a vertical stacked layout unless we add a .row inside it, and/or use child classes on the children. */
	display: flex;
	flex-direction: column;
	flex-grow: 1;
	margin: 0 auto;
	max-width: 94vw;
}
/* this wrapper controls the global width, keeping content readable and allowing flexible layouts in it */

.row {
	width: 100%;
	display: flex;
	flex-direction: row;
	flex-grow: 1;
	gap: 100px;
}
.row.full-width {
	justify-content: flex-start;
}
/* row is used as a horizontal layout pattern that is being used in different areas, gap controls spacing between children */

/* ////////// Flexbox child classes ////////// */

.flex-item {
	display: flex;
	flex-grow: 1;
	flex-direction: column;
}
.nav {
	display: flex;
	flex-direction: row;
	align-items: center;
	justify-content: space-between;
}
/* Remember that elements can be both a flex child and a flex parent. This class can be added onto any flex child, creating it as a flex parent and allowing you to center content vertically and horizontally. */

.center-item {
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
}

/* flex is used here because header content is a row and it needs consistent alignment on all screen sizes */
.contact-icons {
	display: flex;
	flex-direction: row;
	justify-content: center;
	align-items: center;
	gap: 30px;
	margin-top: 10px;
}
.contact-link {
	display: inline-block;
	transition: transform 300ms ease;
}
.contact-icon {
	width: 60px;
	height: 60px;
	display: block;
}

/* .logo-link {
	display: inline-block;
} */

.header-link {
	display: flex;
	align-items: center;
	gap: 50px;
}
.hamburger {
	display: none;
	background: none;
	border: none;
	cursor: pointer;
	padding: 0;
}
.hamburger-icon {
	display: block;
	width: 90px;
	height: auto;
}

.nav-link {
	display: inline-block;
}
.portfolio-section {
	padding: 50px 0;
}
.portfolio-container {
	display: grid;
	grid-template-columns: repeat(2, 1fr);
	gap: 60px;
	justify-items: center;
	padding: 40px 0;
	border-bottom: 3px solid var(--black);
}
.project-layout {
	display: grid;
	grid-template-columns: 1fr 1.6fr;
	align-items: start;
	gap: 64px 0;
}
.project-card {
	display: block;
	position: relative;
	width: 100%;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	text-decoration: none;
	transform: scale(1);
	transition: transform 400ms ease;
}
.project-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.project-title {
	position: absolute;
	top: 12px;
	left: 12px;
	z-index: 2;
	/* used to make sure image stays above */
}
.project-overlay {
	position: absolute;
	inset: 0;
	z-index: 1;
	opacity: 0;
	transition: opacity 400ms ease;
	display: flex;
	align-items: center;
	padding: 16px;
	text-align: left;
	background-color: rgba(255, 253, 249, 0.95);
	pointer-events: none;
}
.project-card:hover,
.project-card:focus,
.project-card:focus-visible {
	transform: scale(1.04);
}
.project-card:hover .project-overlay,
.project-card:focus .project-overlay,
.project-card:focus-visible .project-overlay {
	opacity: 1;
}
.work-hero {
	padding: 80px 0;
	position: relative;
	z-index: 0;
}
/* position is used so taht big number can work */
.work-layout {
	display: grid;
	grid-template-columns: 1fr 1.6fr;
	gap: 64px;
	align-items: start;
	position: relative;
}
.work-info {
	position: relative;
	overflow: visible;
	padding-bottom: 40px;
}
.work-title,
.work-description {
	position: relative;
	z-index: 3;
}
.work-pages-inner {
	display: flex;
	justify-content: center;
	align-items: center;
	gap: 150px;
}
.hero-section {
	min-height: calc(100vh - 80px);
	display: flex;
	align-items: flex-start;
	border-bottom: 3px solid var(--black);
}
.project-hero {
	position: relative;
	overflow: hidden;
	border-bottom: 3px solid var(--black);
}
.projects-preview-section {
	border-bottom: 3px solid var(--black);
}
.projects-preview-bar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 1em 40px;
	width: 100%;
	background: none;
	border: none;
	cursor: pointer;
	color: var(--black);
	text-align: left;
	transition: color 400ms ease;
}
.projects-preview-bar:hover {
	color: var(--red);
}
.arrow-icon {
	width: 30px;
	height: auto;
	transition: transform 400ms ease;
	flex-shrink: 0;
}
.arrow-icon.flipped {
	transform: rotate(180deg);
}
.projects-overlay {
	display: none;
	border-top: 3px solid var(--black);
}
.projects-overlay.open {
	display: block;
}
.preview-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 50px;
	padding: 40px;
}
.preview-item {
	display: block;
	aspect-ratio: 1 / 1;
	overflow: hidden;
	border: 2px solid transparent;
	transform: scale(1);
	transition:
		transform 400ms ease,
		border-color 400ms ease;
}
.preview-item:hover,
.preview-item:focus {
	border-color: var(--red);
	transform: scale(1.04);
}

.preview-item img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}
.preview-footer {
	text-align: center;
	padding: 20px 40px 40px;
}
.mobile-menu {
	display: none;
}
.mobile-nav-link {
	display: block;
	padding: 0.75em 20px;
	font-size: 40px;
	line-height: 38px;
	color: var(--black);
	text-decoration: none;
	transition: color 400ms ease;
}
.mobile-nav-link:first-child {
	border-top: 3px solid var(--black);
	border-bottom: 3px solid var(--black);
}
.mobile-nav-link:hover,
.mobile-nav-link:focus {
	color: var(--red);
}
.about-section {
	border-bottom: 3px solid var(--black);
	padding: 40px 0;
}
.about-layout {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 60px;
	align-items: start;
	margin-top: 40px;
}
.about-image img {
	width: 100%;
	height: auto;
	display: block;
}
.about-text h1 {
	margin-top: 0;
}

.gallery {
	position: relative;
	width: 100%;
}
.gallery-slide {
	display: none;
}
.gallery-slide.active {
	display: block;
}
.gallery-img {
	width: 100%;
	height: auto;
	display: block;
}
.gallery-arrow {
	position: absolute;
	top: 50%;
	transform: translateY(-50%);
	background: var(--white);
	border: 2px solid var(--black);
	border-radius: 50%;
	cursor: pointer;
	padding: 10px;
	color: var(--black);
	display: flex;
	align-items: center;
	justify-content: center;
	transition:
		background-color 300ms ease,
		color 300ms ease,
		border-color 300ms ease;
	z-index: 5;
}
.gallery-arrow:hover,
.gallery-arrow:focus {
	background-color: var(--red);
	border-color: var(--red);
	color: var(--white);
}
.gallery-arrow-left {
	left: -20px;
}
.gallery-arrow-right {
	right: -20px;
}
.gallery-dots {
	display: flex;
	justify-content: center;
	gap: 10px;
	margin-top: 16px;
}
.gallery-dot {
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background-color: var(--dgray);
	border: none;
	cursor: pointer;
	padding: 0;
	transition: background-color 300ms ease;
}
.gallery-dot.active {
	background-color: var(--black);
}
/* //////////----Responsive layout - Media queries--------////////// */
/* You can edit the rules inside of these media queries, but you can also edit the breakpoints. */

@media (max-width: 600px) {
	/* anything you only want applied at mobile sizes can go here */
	.flex-item {
		width: 100vw;
		height: auto;
	}
}

@media (min-width: 768px) {
	/* anything you want to kick in at small tablet and above can go here */
}

@media (min-width: 900px) {
	/* Half widths */
	.flex-item.one-half {
		flex-grow: unset;
		width: 50%;
	}

	.flex-gap-sm .flex-item.one-half {
		width: calc(50% - 5px);
	}

	.flex-gap-md .flex-item.one-half {
		width: calc(50% - 10px);
	}

	.flex-gap-lg .flex-item.one-half {
		width: calc(50% - 20px);
	}
}

@media (min-width: 1300px) {
	/* anything you want to kick in at larger desktop and above can go here */
	.inner-wrapper {
		max-width: 90vw;
		/* this max-width can be edited to your fit your design. Check how your design will look on large screens by pressing CMMD- in your browser, and decide if and how you want to constrain the overall content width. */
	}
}
@media (max-width: 700px) {
	.portfolio-container {
		grid-template-columns: 1fr;
	}
	.project-card {
		max-width: 520px;
	}

	.header-link {
		display: none;
	}
	.hamburger {
		display: block;
	}
	.mobile-menu {
		display: none;
	}
	.mobile-menu.open {
		display: block;
	}
	.work-layout {
		grid-template-columns: 1fr;
	}
	.work-number {
		left: -40px;
		top: -50px;
	}
	.work-media {
		padding: 0;
		margin: auto;
	}
	.work-media .gallery-img {
		width: 100%;
	}
	.project-hero {
		padding-bottom: 60px;
	}
	.row {
		flex-direction: column;
		gap: 40px;
	}
	.row .flex-item {
		width: 100%;
	}
	.work-pages-inner {
		flex-direction: column;
		align-items: flex-start;
		gap: 20px;
	}
	.about-layout {
		grid-template-columns: 1fr;
	}
	.preview-grid {
		grid-template-columns: 1fr;
		gap: 30px;
	}
	.projects-preview-bar {
		padding: 1em 20px;
	}
	.gallery-arrow-left {
		left: 10px;
	}
	.gallery-arrow-right {
		right: 10px;
	}
}
