/* Layout moderno — Flexbox & CSS Grid (substitui floats + Less Framework) */

:root {
	--wrapper-max: 940px;
	--gap: 20px;
	--gap-lg: 24px;
}

/* Container centralizado (conteúdo principal) */
.wrapper {
	width: 100%;
	max-width: var(--wrapper-max);
	margin-inline: auto;
	padding-inline: 0;
	box-sizing: border-box;
}

/* Header: logo + menu no início da coluna central (alinhado ao banner) */
header .wrapper {
	display: flex;
	flex-wrap: nowrap;
	align-items: flex-end;
	justify-content: flex-start;
	column-gap: 4px;
}

#logo {
	flex: 0 0 auto;
	padding-top: 28px;
	padding-bottom: 10px;
	margin-left: 0;
}

#logo img {
	display: block;
}

nav {
	flex: 0 1 auto;
	display: block;
	height: auto;
	margin: 0;
	padding: 0 0 10px;
	min-width: 0;
	align-self: flex-end;
}

.sf-menu {
	display: flex;
	flex-wrap: nowrap;
	justify-content: flex-start;
	align-items: flex-end;
	gap: 0;
	list-style: none;
	margin: 0;
	padding: 0;
	width: auto;
}

.sf-menu > li {
	float: none;
	flex: 0 0 auto;
	width: auto;
	min-width: 0;
}

#nav li {
	margin-right: 14px;
}

#nav li:last-child {
	margin-right: 0;
}

#nav > li > a {
	white-space: nowrap;
	font-size: 12px;
	padding-bottom: 7px;
	border-bottom: 5px solid transparent;
	box-sizing: border-box;
}

#nav > li.current-menu-item > a,
#nav > li.current_page_item > a {
	border-bottom-color: #ebebe8;
	color: #444;
}

#nav > li > a img {
	display: block;
}

#comboNav {
	float: none;
	width: 100%;
	margin-top: 0;
}

#combo-holder {
	display: none;
	width: auto;
	flex: none;
}

/* Slider + headline */
#slider-holder {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-start;
	gap: var(--gap);
}

.home-slider {
	float: none;
	flex: 1 1 100%;
	min-width: 0;
	max-width: 100%;
	width: 100%;
}

#slider-holder .flexslider {
	width: 100%;
}

#slider-holder #headline {
	float: none;
	flex: 0 1 260px;
	min-width: 0;
}

.home-slider-clearfix {
	display: none;
}

/* Cards da home e portfólio */
.one-third-thumbs,
.one-fourth-thumbs,
.portfolio-thumbs,
.related-projects .related-list {
	display: grid;
	gap: var(--gap);
}

.one-third-thumbs {
	grid-template-columns: repeat(3, 1fr);
}

.one-fourth-thumbs {
	grid-template-columns: repeat(4, 1fr);
}

.portfolio-thumbs {
	grid-template-columns: repeat(3, 1fr);
	width: 100%;
	max-width: 100%;
}

.related-projects .related-list {
	grid-template-columns: repeat(4, 1fr);
}

.one-third-thumbs figure,
.one-fourth-thumbs figure,
.portfolio-thumbs figure,
.related-projects figure {
	float: none;
	width: auto;
	margin-right: 0;
}

/* Sidebar + conteúdo */
#page-content {
	display: flow-root;
}

#page-content:has(#contactForm) {
	display: grid;
	grid-template-columns: 1fr 220px;
	gap: var(--gap);
	align-items: start;
}

#contactForm,
#sidebar {
	float: none;
	width: auto;
	max-width: 100%;
}

#contact-sidebar {
	float: none;
	width: auto;
}

/* Rodapé */
.widget-cols {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: var(--gap);
	list-style: none;
	margin: 0;
	padding: 0;
}

.widget-cols > li {
	float: none;
	width: auto;
	margin-right: 0;
}

.footer-bottom {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: var(--gap);
	overflow: visible;
}

.footer-bottom .left,
.footer-bottom .right {
	float: none;
	width: auto;
	flex: 1 1 auto;
}

.footer-bottom .right {
	display: flex;
	justify-content: flex-end;
}

#social-bar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
	list-style: none;
	margin: 0;
	padding: 0;
}

#social-bar li {
	float: none;
}

/* Pager e navegação de projeto */
.project-heading {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--gap);
}

.project-heading h2,
.project-heading .launch {
	float: none;
}

.project-description,
.project-info {
	float: none;
}

.project-layout {
	display: grid;
	grid-template-columns: 1fr 220px;
	gap: var(--gap);
	align-items: start;
}

.project-pager {
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.project-pager .prev-project,
.project-pager .next-project {
	float: none;
}

.pager {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 5px;
}

.pager li,
.pager .paged {
	float: none;
}

.pager .paged {
	margin-left: auto;
}

.page-navigation {
	display: flex;
	flex-wrap: wrap;
	justify-content: space-between;
	gap: var(--gap);
}

.page-navigation .nav-next,
.page-navigation .nav-previous {
	float: none;
}

/* Equipe — contato (substitui margin negativo inline) */
.box001,
.box002 {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: var(--gap);
	position: static;
	float: none;
	left: auto;
	margin-bottom: var(--gap);
}

.box001 > div,
.box002 > div {
	margin: 0 !important;
}

/* Conteúdo centralizado (substitui align="center") */
.fullwidth-content [align="center"] {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: var(--gap);
}

.fullwidth-content img.s01 {
	max-width: 100%;
	height: auto;
}

/* Utilitários legados — neutralizados onde o layout cuida do fluxo */
header .wrapper::after,
.clearfix::after,
.right::after {
	content: none;
	display: none;
	height: auto;
}

/* Tablet */
@media (max-width: 991px) {
	#nav > li > a {
		font-size: 11px;
	}

	#nav li {
		margin-right: 8px;
	}

	.one-third-thumbs {
		grid-template-columns: repeat(2, 1fr);
	}

	.one-fourth-thumbs,
	.related-projects .related-list {
		grid-template-columns: repeat(2, 1fr);
	}

	.portfolio-thumbs {
		grid-template-columns: repeat(2, 1fr);
	}

	.widget-cols {
		grid-template-columns: repeat(2, 1fr);
	}

	#page-content:has(#contactForm) {
		grid-template-columns: 1fr;
	}

	#slider-holder #headline {
		flex: 1 1 100%;
		width: 100%;
		margin-top: 0;
	}

	.box001,
.box002 {
		grid-template-columns: repeat(2, 1fr);
	}
}

/* Mobile */
@media (max-width: 767px) {
	#nav {
		display: none;
	}

	#comboNav {
		display: block;
	}

	#combo-holder {
		display: block;
		width: 100%;
		margin-top: 10px;
	}

	header .wrapper {
		flex-direction: column;
		align-items: stretch;
	}

	nav {
		justify-content: stretch;
	}

	.one-third-thumbs,
	.one-fourth-thumbs,
	.portfolio-thumbs,
	.related-projects .related-list,
	.widget-cols,
	.box001,
	.box002 {
		grid-template-columns: 1fr;
	}

	.footer-bottom {
		flex-direction: column;
		align-items: flex-start;
	}

	.footer-bottom .right {
		justify-content: flex-start;
	}

	.home-slider {
		flex: 1 1 100%;
		width: 100%;
	}

	.page-heading {
		text-align: center;
	}

	.page-heading span {
		font-size: 21px;
		margin-left: 0;
	}

	#headline h1,
	.home-block-heading {
		font-size: 24px;
		line-height: 1.2em;
		margin-bottom: 15px;
	}

	.widget-cols > li {
		border-bottom: 1px solid #ccc;
		padding-bottom: 20px;
		margin-bottom: 35px;
	}

	.widget-cols > li.fourth-col {
		border-bottom: none;
		margin-bottom: 0;
	}
}
