/*
 * Layout
 *
 */






/* The great reset
–––––––––––––––––––––––––––––––––––––––––––––––––– */
* {
	box-sizing: border-box;
}
html,
body {
	margin: 0;
	padding: 0;
	border: none;
}




/* Base Styles
–––––––––––––––––––––––––––––––––––––––––––––––––– */
/* NOTE
html is set to 62.5% so that all the REM measurements throughout Skeleton
are based on 10px sizing. So basically 1.5rem = 15px :) */

html {
 	font-size: 62.5%;
}
html,
body {
	min-height: 100dvh;
	height: auto;
	width: 100%;
	overflow-x: hidden;
	background: var(--bg-color-main);
	scroll-behavior: smooth;
}
body {
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	gap: 0;
}




body.noscroll,
body.mobile-menu-open,
body.search-bar-open {
	overflow: hidden;
	min-height: 100vh;
	max-height: 100vh;
	position: fixed;
}
main {
	flex: 1;
}
section,
main article main,
main article main.container {
	position: relative;
	padding-top: var(--section-padding-default);
	padding-bottom: var(--section-padding-default);
}
main article main.container {
	z-index: 2;
}
details summary { 
	cursor: pointer;
}  
details summary > * {
	display: inline;
}





/*
 * 6col grid 
 * ======================================================== */
main {
	flex: 1;
/*
	max-width: 80rem;
	margin: auto;
	padding: 18rem 2rem 10rem 2rem;
*/
	width: 100%;
}
article,
.z-grid  {
	width: 100%;
	height: 100%;
	position: relative;
	display: grid;
	grid-template-columns: var(--grid--colums-default);
}
article > *,
.z-grid > * {
	grid-column: 2 / -2;
}

.z-grid.wide > *,
.z-grid.section-wide > * {
	grid-column: 1 / -1;
}

article > .text-with-image > *,
.z-grid > .text-with-image > * {
	grid-column: 2 / -2;
}

article.has-full-sidebar > aside + *,
.z-grid.has-full-sidebar > aside + * {
	grid-column: 2 / 5;
}
article.has-full-sidebar .sidebar-float,
.z-grid.has-full-sidebar .sidebar-float {
	grid-column: -3 /-1;
	grid-row: 2;
}






article > .wide,
.z-grid > .wide,
article > .full,
.z-grid > .full,
article > .section-wide,
.z-grid > .section-wide,
article > * > .wide,
.z-grid > * > .wide {
	grid-column: 1 / -1;
	justify-self: center;
	width: 100%;
	max-width: var(--container-normal-max-width);
	padding: 2rem;
}
@media only screen and (max-width: 600px) {
	article > .wide,
	.z-grid > .wide,
	article > .full,
	.z-grid > .full,
	article > .section-wide,
	.z-grid > .section-wide,
	article > * > .wide,
	.z-grid > * > .wide {
		padding: 3ch 2ch;
	}
}




article > .full,
.z-grid > .full {
	max-width: unset;
}
article > .wide-extra,
.z-grid > .wide-extra {
	max-width: 134rem;
}


article > .wide-right,
.z-grid > .wide-right,
article > * > .wide-right,
.z-grid > * > .wide-right {
	grid-column: 4 / -1;
	justify-self: start;
	width: 100%;
}
article > .wide-left,
.z-grid > .wide-left,
article > * > .wide-left,
.z-grid > * > .wide-left {
	grid-column: 1 / -4;
	justify-self: end;
	width: 100%;
}
article > .half-right,
.z-grid > .half-right,
article > * > .half-right,
.z-grid > * > .half-right {
	grid-column: 4 / 6;
	justify-self: start;
	width: 100%;
}
article > .half-left,
.z-grid > .half-left,
article > * > .half-left,
.z-grid > * > .half-left {
	grid-column: 2 / -4;
	justify-self: end;
	width: 100%;
}
article > .text-with-image {
	grid-column: 1 / -1;
	justify-self: center;
	width: 100%;
	position: relative;
	display: grid;
	grid-template-columns: var(--grid--colums-default);
	grid-template-rows: max-content max-content;
}
article > .text-with-image h2 {
   grid-row: 1;
}
article > .text-with-image .text {
	grid-row: 2;
	grid-column: 4 / 6;
}
article > .text-with-image.image-wide-right .text {
	grid-column: 2 / 4;
}
	
.text.text-columns.onecol .text {
	text-align: left;
	line-height: 2;
}
.text-columns.twocol > .text,
.text-columns.col-two > .text {
	columns: 2;
	column-gap: calc( 2 * var(--default-gap) );
}
.text-columns.col-three > .text {
	columns: auto 3;
}
.text-columns > .text > * {
	margin-top: 0;
	/* margin-bottom: 0; */
}


.full-split {
	display:grid;
	grid-template-columns: repeat(auto-fit, minmax(30rem, 1fr));
}

article > .full-split > *:first-of-type {
	justify-self: end;
	max-width: calc( var(--container-normal-max-width) / 2);
}
article > .full-split > *:last-of-type {
	justify-self: start;
	max-width: calc( var(--container-normal-max-width) / 2);
}
/*
--grid--colums-half-left: minmax(2rem, 1fr) repeat(2, minmax(auto, calc( var(--container-size) / 4) ));
--grid--colums-half-right: repeat(2, minmax(auto, calc( var(--container-size) / 4) )) minmax(2rem, 1fr);
*/	





article *:has(+ h2):not(a[id]),
article a[id]:has(+ h2):not(section) {
	margin-bottom: 5rem;
}
article section {
	margin: 5rem 0;
}
article section.has-bg {
	margin-top: 10rem;
}
article section:has(+ a[id]) {
	margin-bottom: 0;
}
body main > article > a[id] {
	margin-bottom: 5rem;
}
body main > article > .hero + a[id],
body main > article > #notes + a[id] {
	margin-bottom: 1rem;
}



@media only screen and (max-width: 550px) {
	article *:has(+ h2):not(a[id]),
	article a[id]:has(+ h2):not(section) {
		margin-bottom: 5rem;
	}
}

/*
 * Containers
 * ======================================================== */
/*
.container {
	position: relative;
	width: 100%;
	max-width: var(--container-normal-max-width);
	margin: 0 auto;
	padding-left: var(--container-padding-side);
	padding-right: var(--container-padding-side);
}
.main ul.container {
	padding-left: var(--container-padding-side);
	padding-right: var(--container-padding-side);
}
@media only screen and (min-width: var(--container-normal-max-width)) {
	.container {
		width: 100%;
	}
}

.container-small,
.small-text-col .main > .container {
	max-width:  var(--container-small-max-width);
}
.container.container-small {
	width: 100%;
	max-width:  var(--container-small-max-width);
}
.container-medium {
	max-width: var(--container-medium-max-width);
}
.container.container-medium {
	width: 100%;
	max-width: var(--container-medium-max-width);
}
.container-wide {
	max-width: var(--container-wide-max-width);
	width: auto;
}
.container.container-wide {
	width: 100%;
	max-width: var(--container-wide-max-width);
}
.container.container-portfolio {
	width: 100%;
	max-width: var(--container-portfolio-max-width);
}
.container-max {
	max-width: 9999px;
	width: auto;
	padding-left: 0;
	padding-right: 0;
}
.main ul.container-max {
	padding-left: 0;
	padding-right: 0;
}
/* prevent double width */
.container .container {
	width: 100%;
	padding-top: 0;
	padding-bottom: 0;
	padding-left: 0;
	padding-right: 0;
}

/*
.auto-col .container {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(28em,1fr));
}
@media screen and (max-width: 28em) {
	.auto-col .container {
		grid-template-columns: repeat(auto-fit, minmax(12em,1fr));
	}
}
@media screen and (max-width: 550px) {
	.auto-col .container {
		display: block;
	}
}
*/





@media only screen and (max-width: 600px) {

}
@media only screen and (min-width: 1000px) {

}

body .padding-bottom-20 {
	padding-bottom: 20px !important;
}
body .padding-bottom-40 {
	padding-bottom: 40px !important;
}
body .padding-bottom-80 {
	padding-bottom: 80px !important;
}

.two-col {
	column-count: 2;
}
@media only screen and (max-width: 600px) {
	.two-col {
		column-count: 1;
	}
}


/*
 * Flex and Grid
 * ======================================================== */

.flex {
	display: flex;
	justify-content: space-between;
	align-items: center;
	align-content: center;
    flex-wrap: wrap;
	gap: var(--default-gap);
}
.flex-center {
	justify-content: center;
}
.flex-center > * {
	margin-left: 20px;
	margin-right: 20px;
}
.flex-top {
	align-items: flex-start;
}
.flex-bottom {
	align-items: flex-end;
}
.flex-right {
	justify-content: flex-end !important;
}
.flex-half {
	align-items: flex-start;
	gap: 50px;
}
.flex-half.flex-bottom {
	align-items: flex-end;
}
.flex-half.container > * {
	width: calc(50% - 25px);
}
.hero .flex-half.container > * {
	align-self: center;
}

@media (max-width: 800px) {
	.flex-half.container > * {
		width: 100%;
	}
	.hero .flex-half.container > * {
		align-self: start;
	}
}




/* correct floating columns */
.flex .columns {
	margin-left: 0 !important;
}

.grid {
    display: grid;
	/* grid-auto-rows: 1fr; *//* make rows the same height */
    grid-template-columns: repeat(auto-fill, minmax(34rem, 1fr));
    grid-gap: var(--default-gap);
	list-style: none;
}
ul.grid:not(.container) {
	padding-left: 0;
	list-style: none;
}
.grid.grid-half {
	grid-template-columns: repeat(auto-fill, minmax(38rem, 1fr));
	grid-gap: calc(2 * var(--default-gap));
}




/*
 * Panels
 * ======================================================== */

.panels-holder,
.panels {
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding-bottom: 4rem;
	flex-wrap: wrap;
	gap: var(--default-gap);
}
.panels .panel .panel {
	width: 100%;
}
.panels-holder .item-box,
.panels .panel {
	width: 31.33%;
	margin-bottom: 20px;
}
.panels-holder .item-box.item-box-2col,
.panels .panel.item-box-2col {
	width: 65.66%;
}
.panels.col2 .panel {
	width: calc(100%/2 - 30px);
}
.panels-holder.col4 .item-box,
.panels.col4 .panel {
	width: calc(100%/4 - 3*30px); /* 23.5% */
}
.panels-holder.col4 .item-box.item-box-2col,
.panels.col4 .panel.item-box-2col {
	width: 49%;
}
@media only screen and (max-width: 1200px) {
	.panels-holder .item-box,
	.panels-holder .item-box.item-box-2col,
	.panels .panel,
	.panels .panel.item-box-2col {
		width: 49%;
		width: 47.5%;
		margin-bottom: 20px;
	}
	.panels-holder.col4 .item-box,
	.panels.col4 .panel {
		width: 31.33%;
	}
}
@media only screen and (max-width: 960px) {
	.panels-holder .item-box,
	.panels-holder .item-box.item-box-2col,
	.panels .panel,
	.panels .panel.item-box-2col {
		width: 49%;
		width: 47.5%;
	}
	.panels-holder.col4 .item-box,
	.panels.col4 .panel {
		width: 47.5%;
	}
}
@media (max-width: 800px) {
	.panels-holder,
	.panels {
   		display: block;
	}
	.panels-holder .item-box,
	.panels-holder .item-box.item-box-2col,
	.panels .panel,
	.panels .panel.item-box-2col {
		width: 100%;
	}
	.panels-holder.col4 .item-box,
	.panels.col4 .panel {
		width: 100%;
	}
	.panels.col2 .panel {
		width: 100%;
	}
}
@media only screen and (max-width: 480px) {
	.panels-holder,
	.panels {
   		display: block;
	}
}



.panel {
	display: inline-block;
	width: 100%;
	position: relative;
	box-shadow: 0px 0px 14px 0px rgba(0,0,0,0.14);
}
.panel.transparent {
	background: transparent;
}
.panel.no-shade {
	box-shadow: 0px 0px 0px 0px rgba(0,0,0,0);
}
.panel.rounded {
	border-radius: 1rem;
}

.panel .inner {
	padding: var(--default-gap);
}
@media (max-width: 900px) {
	.panel .inner {
		padding: 2rem;
	}
}



.panel h2 {
	margin-top: 0;
}
.panel h2 .sub-title {
	display: block;
	font-size: 1.6rem;
	font-weight: 400;
	color: rgba(0,0,0,0.4);
}
.panel h3 {
	margin-top: 0;
}
.panel .inner p:last-child {
	margin-bottom: 0;
}





/*
 * Tables
 * ======================================================== */

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eaeaea;
}
th {
    font-weight: 600;
    font-size: 12px;
    text-transform: uppercase;
    border-bottom: 1px solid #bbb;
    letter-spacing: 1px;
}




/*
 * Grid (isotope)
 * ======================================================== */

.grid-item,
.grid-sizer { width: 100%;}
.grid-item--width2 { width: 100%; }


/* Larger than mobile */
@media (min-width: 400px) {}

/* Larger than phablet (also point when grid becomes active) */
@media (min-width: 550px) {
	.grid-item,
	.grid-sizer { width: calc( 50% - 15px ); }
	.grid-item--width2 { width: 100%; }
}

/* Larger than tablet */
@media (min-width: 750px) {
	.grid-item,
	.grid-sizer { width: calc( 33.33% - 20px ); }
	.grid-item--width2 { width: calc( 66.67% - 40px ); }
}
/* Larger than desktop */
@media (min-width: 1000px) {}
/* Larger than Desktop HD */
@media (min-width: 1200px) {}




/*
 * Modals
 * ======================================================== */
.modal-open body {
	width: 100vw;
	height: 100vh;
	overflow: hidden;
}
#modals {
	overflow: hidden;
}
.modal {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    -webkit-tap-highlight-color: transparent;
    -ms-touch-action: manipulation;
    touch-action: manipulation;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
	
	position: fixed;
	top: 0;
	bottom: 0;
	left: 0;
	right: 0;
	width: 100vw;
	height: 100vh;
	z-index: 1001;
	background-color: rgba(0,0,0,0.5);
	box-shadow: 0 0 0 9999px rgba(0,0,0,0.5);
	justify-content: center;
	align-content: center;
	flex-direction: row;
	align-items: center;
	overflow: hidden;
	
	display: flex;
	display: none;
}
.modal.open {
	display: flex;
}
.modal-inner {
	max-width: 750px;
	min-width: 250px;
	width: 90%;
	max-height: 90%;
	min-height: 50%;
	height: auto;
	top: 0;
	bottom: 0;
	right: 0;
	left: 0;
	background-color: var(--base-bg-color);
	overflow-x: hidden;
	overflow-y: auto;
	position: relative;
}
@media only screen and (min-width : 890px) {
	.modal-inner {
		max-width: 800px;
	}
}
@media only screen and (min-width : 1200px) {
	.modal-inner {
		max-width: 1070px;
	}
}
.close-modal {
	position: absolute;
	cursor: pointer;
}
@media only screen and (max-width : 400px) {
	.close-modal {
		background-color: rgba(0,0,0,0.5);
		border-radius: 4px;
	}
	.modal-inner .close-modal {
		background-color: rgba(0,0,0,0);
		border-radius: 0px;
	}
}
.close-modal-cross {
    display: flex;
    justify-content: flex-start;
    align-items: flex-end;
    right: 6px;
    top: 6px;
    width: 40px;
    height: 40px;
    color: var(--color-white);
    font-size: 3rem;
    opacity: 0.7;
}
.close-modal-cross img {
    width: 40px;
    height: 40px;
}
.close-modal:hover {
    opacity: 1;
}
.primary.inline.close-modal {
    position: absolute;
    right: 10px;
    bottom: 10px;
	padding: 10px 19px;
}
.modal-form {
    background: #fff;
    min-width: 80rem;
    min-height: 40rem;
    box-shadow: 0 0 6px 1px rgba(0,0,0,1);
    padding: 3rem 4rem;
    position: relative;
}
.modal-content {
	position: relative;
    border: 2px solid rgba(0,0,0,0);
    background: var(--base-bg-color);
    padding: 5rem;
	font-size: 16px;
}
.modal-content {
	min-width: 80rem;
	min-height: 40rem;
}
@media only screen and (max-width : 840px) {
	.modal-content {
		min-width: 28rem;
		max-width: 96%;
		min-height: 40rem;
		padding: 2rem;
	}	

}



/*
 * Sidebars
 * ======================================================== */
aside.sidebar-float {
	margin-left: var(--large-gap);
	float: right;
	position: relative;
	width: 50%;
	max-width: 50%;
	margin-right: -13ch;
	z-index: 2;
}
.has-full-sidebar aside.sidebar-float {
	width: 100%;
	max-width: 26ch;
	max-height: max-content;
}
aside.sidebar-float .inner {
	padding: var(--large-gap);
	background: rgba(255,255,255,0.05);
}
aside.sidebar-float .inner > * {
	margin: var(--large-gap) 0 0 0;
}
aside.sidebar-float .inner > *:first-child {
	margin-top: 0;
}

article.has-full-sidebar aside.sidebar-float {
	grid-column: -3 / -1;
	grid-row-start: 3; /* if has header */
}
article.has-full-sidebar.hide-h1 aside.sidebar-float {
	grid-column: -3 / -1;
	grid-row-start: 2; /* if has header and hidden h1 */
}


@media (max-width: 960px) {
	 aside.sidebar-float {
		 margin-left: 0;
		 padding: 5rem 0px;
	 }
}
section.with-sidebar {
	padding-top: 0;
	padding-bottom: 0;
	margin-top: 0;
}
section.content-main {
	padding-top: 0;
	padding-bottom: 0;
	margin-top: 0;
	margin-bottom: 0;
}

