/* https://medium.com/@axel/mosaic-layouts-with-css-grid-d13f4e3ed2ae */

html{
	font-size: 20px;
	border-top: 16px solid #c9591a;
	border-bottom: 16px solid #ffbd4b;
	background-color: #f8f5ef;
	padding: 0px;
	margin: 0px;
}

body{
	font-family: 'Open Sans', helvetica-light, helvetica, arial, sans-serif;
	color: #a0928c;
    font-size: 0.8em;
	
	margin: 0px;
	padding: 0px 64px 0px 64px;
	background: url('images/splatter.png') left top no-repeat;
	background-size: 130px 218px;
	min-height: calc( 100vh - 32px );
}


a {
	color: #c9591a;
	text-decoration: none;
}



header {
	display: flex;
	flex-direction: row;
	flex-wrap: wrap;
	justify-content: space-between;
	align-items: flex-end;

	max-width: 1200px;
	padding-top: 64px;
	padding-bottom: 55px;
	margin-left: auto;
	margin-right: auto;
	
	font-family: Florence-Regular; 
	
}

nav {
	font-size: 1.9em;
	letter-spacing: 0.1em;
}

nav a {
	display: inline-block;
	transition: all .2s ease-in-out; 
}

nav a:hover {
	transform: scale(1.15);
}


h1 {
	width: 380px;
	height: 77px;
	margin: 0px;
	padding: 0px 0px 9px 0px;
}

h1 a {
	display: block;
	width: 380px;
	height: 0px;
	padding-top: 77px;
	overflow: hidden;
	background: url('images/obm-logo.png') center top no-repeat;
	background-size: 380px 77px;
	margin: 0px auto 0px auto;
}



.container{
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-gap: 0.6rem;
    max-width: 1200px;
    margin: 0 auto;
    
   grid-auto-rows: minmax(0, 0.25fr);
}


.tile img {
	background-color: #c9bfb7;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
	transition: all .2s ease-in-out; 
}


.tile img:hover { 
	transform: scale(1.01);
	box-shadow: 0px 2px 10px #a99;
}


.tile:nth-child(1),
.tile:nth-child(13) {
    grid-column: span 4;
    grid-row: span 2;
}

.tile:nth-child(2),
.tile:nth-child(3),
.tile:nth-child(7),
.tile:nth-child(8),
.tile:nth-child(12) {
    grid-column: span 2;
    grid-row: span 2;
}

.tile:nth-child(4){
    grid-column: span 2;
    grid-row: span 4;
}

.tile:nth-child(5),
.tile:nth-child(6),
.tile:nth-child(9),
.tile:nth-child(10),
.tile:nth-child(11) {
    grid-column: span 2;
    grid-row: span 1;
}


footer {
	font-family: Florence-Regular; 
	color: #d0c2bc;
	text-align: center;
	padding: 100px 0px 20px 0px;
}

footer p {
	margin: 0px;
	font-size: 1.2em;
}

footer img {
	margin-left: auto;
	margin-right: auto;
}



/* ----- DETAIL PAGES ----- */

.detail {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-gap: 1rem;
	grid-template-rows: minmax(0, min-content) 1fr minmax(0, min-content);
	
	max-width: 964px;
    margin: 0 auto;
    
    
}


/* default - image side by side */

.detail .artwork img {
	display: block;
	width: 100%;
	border-radius: 8px;
}

.detail .artwork {
    grid-column: span 4;
    grid-row: span 3;
}



.detail .metatext {
	grid-column: span 2;
	padding-left: 20px;
}

.detail .metatext h2 {
	margin: 0px;
	line-height: 0.9em;
}

.detail .metatext h3 {
	margin: 4px 0px 0px 0px;
	font-size: 0.8em;
}



.detail .info {
	grid-column: span 2;
	padding-left: 20px;
}

.detail .info p {
	margin: 4px 0px 12px 0px;
}



.detail .nav-home {
	padding-left: 20px;
	align-self: end;
}

.detail .nav-home a {
	display: block;
	padding-left: 24px;
	min-height: 16px;
	background: url('images/icon-all.png') left center no-repeat;
	background-size: 16px 16px;
	line-height: 0.9em;
	margin-bottom: 3px;
}


.detail .nav-previous-next {
	align-self: end;
	justify-self: end;
	display: flex;
	flex-wrap: nowrap;
}

.detail .nav-previous-next a {
	display: block;
	width: 12px;
	height: 0px;
	padding: 24px 0px 0px 0px;
	overflow: hidden;
}

.detail .nav-previous-next a.previous {
	background: url('images/icon-previous.png') center center no-repeat;
	background-size: 10px 18px;
	margin-right: 20px;
}

.detail .nav-previous-next a.next {
	background: url('images/icon-next.png') center center no-repeat;
	background-size: 10px 18px;
}





/* image at top */



.detail.top-image {
    max-width: 1200px;
    
}


.detail.top-image .artwork {
    grid-column: span 6;
}


.detail.top-image .metatext {
	grid-column-start: 1;
	grid-column-end: 3;
	padding-left: 0px;
}

.detail.top-image .info {
	grid-column-start: 4;
	grid-column-end: 7;
	padding-left: 0px;
}



.detail.top-image .nav-home {
	padding-left: 0px;
	grid-column-start: 4;
	grid-column-end: 5;
	
}


.detail.top-image .nav-previous-next {
	grid-column-start: 5;
	grid-column-end: 7;
	
}





/* ----- ABOUT PAGE ----- */

.about {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-gap: 1rem;
	grid-template-rows: minmax(0, min-content) 1fr minmax(0, min-content);
	
	max-width: 964px;
    margin: 0 auto;
   
}

.about .text {
	grid-column: span 3;
}

.about .text p {
	margin-top: 0px;
	margin-bottom: 16px;
}

.about .photo {
	grid-column: span 3;
}

.about .photo img {
	max-width: 100%;
	height: auto;
	border-radius: 8px;
}



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

	/* home page */

	body {
		padding: 0px 24px 64px 24px;
	}

	h1 {
		margin-left: auto;
		margin-right: auto;
		width: 100%;
		height: auto;
	}
	
	h1 a {
		width: 100%;
		max-width: 380px;
		background-size: 100% auto;
	}

	nav {
		margin-top: 20px;
		margin-left: auto;
		margin-right: auto;
	}
	
    .container{
        display: block;
    }

    .tile{
        margin-bottom: 1rem;
    }
    
    
    /* detail pages */
    
    .detail {
    	display: block;
    }
    
    .detail div {
    	margin-bottom: 1rem;
    }
    
    .detail .metatext, .detail .info, .detail .nav-home, .detail .nav-previous-next {
    	padding: 0px 12px 0px 12px;
    }
    
     .detail .nav-home {
     	float: left;
     	margin-top: 6px;
     }
     
     .detail .nav-previous-next {
     	float: right;
     }
     
     
     /* about page */
    
    .about {
    	display: block;
    }
    
    .about div {
    	margin-bottom: 1rem;
    }
    
}




