@import url('//fonts.googleapis.com/css?family=Open+Sans');

* {
  box-sizing: border-box;
}

html {
  background-image: url(../images/background.png);
}

body {
  max-width: 980px;
  margin: auto;
  border: 1px solid #e0e0e0;
  background-color: white;
  padding: 0 10px;
  font-family: 'Open Sans', sans-serif;
  font-size: 12px;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-weight: normal;
}

img {
  max-width: 100%;
  height: auto;
}

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

input[type="text"],
input[type="password"] {
  border: 1px solid #c4bbb2;
  padding: 2px 10px;
  height: 24px;
}

input[type="submit"] {
  background-color: #ce1719;
  border: 0 none;
  padding: 3px 10px;
  color: white;
  text-transform: uppercase;
  font-weight: bold;
  width: 100%;
}

.centered-column {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.pagination-nav {
  text-align: center;
}

.pagination-nav {
  color: #ce1719;
}

.pagination-nav .pagination-current {
  font-weight: bold;
  text-decoration: underline;
}

#title-and-login {
  display: flex;
  justify-content: space-between;
  background-color: #f8f8f8;
}

#title-and-login > * {
  display: flex;
  flex-direction: column;
  justify-content: space-around;
}

#site-title {
  flex-grow: 1;
  padding: 20px;
}

#logo-map img {
  width: 200px;
  padding: 15px;
}

#login-box {
  flex-basis: 240px;
  flex-shrink: 0;
  background-color: #c4bbb2;
  padding: 20px;
}

#login-box ::-moz-placeholder {
  font-style: italic;
}
#login-box ::-webkit-placeholder {
  font-style: italic;
}
#login-box :-ms-input-placeholder {
  font-style: italic;
}
#login-box ::placeholder {
  font-style: italic;
}

#login-box a {
  color: white;
  text-decoration: underline;
}

#login-box input[type="text"],
#login-box input[type="password"] {
  margin: 1px 0;
}

#lost-password {
  font-size: 0.9em;
  margin-top: 5px;
  margin-bottom: 10px;
}

#user-register {
  margin-top: 10px;
}

#search-container {
  background-color: #ce1719;
  padding: 5px 10px;
  margin-top: 10px;
}

#breadcrumbs-container {
  margin-top: 10px;
  padding-left: 20px;
  font-size: 0.9em;
}

#breadcrumbs-container a {
  color: #bbbbbb;
  font-weight: bold;
}

#breadcrumbs-container .separator {
  color: #bbbbbb;
  font-weight: bold;
  margin: 0 5px;
}

article[role="main"] {
  margin-top: 10px;
  overflow: hidden;
}

article[role="main"] > main {
  flex-grow: 1;
}

footer {
  color: white;
  font-size: 0.9em;
  margin-top: 10px;
  background-color: #615f60;
  padding: 30px 15px;
}

footer h2 {
  text-transform: uppercase;
}

footer a {
  color: white;
}

footer > * {
  display: flex;
  justify-content: space-around;
}

#sitemap {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#sitemap h2 {
    visibility: hidden;
}

#sitemap ul {
  -moz-column-count: 2;
  -webkit-column-count: 2;
  column-count: 2;
  -moz-column-gap: 100px;
  -webkit-column-gap: 100px;
  column-gap: 100px;
  margin: 0;
  padding: 0;
}

#sitemap li {
  display: block;
}

footer address {
  font-style: normal;
}

#login-links {
  background-color: #c4bbb2;
}

#search-container form {
  display: flex;
}

#search-container input[type="text"] {
  border: 0 none;
  flex-grow: 1;
}

#search-container button[type="submit"] {
  background-color: white;
  border: 0 none;
  height: 24px;
  width: 24px;
  padding: 3px;
}

#search-container button[type="submit"] img {
  vertical-align: middle;
}

#search-container fieldset {
  display: inline-block;
  border: 0 none;
  padding: 0;
}

#search-container legend {
  background-color: white;
  color: #d2d2d2;
  font-weight: bold;
  font-size: 0.9em;
  padding: 2px 50px 2px 10px;
  line-height: 20px;
  margin-left: 30px;
  background-image: url(../images/picto-select.svg);
  background-repeat: no-repeat;
  background-position: calc(100% - 8px) center;
  background-size: 18px 18px;
  cursor: pointer;
}

#search-container .fieldset-content {
  background-color: #ce1719;
  padding: 0 10px 10px 10px;
}

#search-container .field-checkboxes {
  -moz-column-count: 2;
  column-count: 2;
}

#search-container .field-checkboxes label {
  display: block;
}

#home #content {
  display: flex;
}

#home #content main {
  overflow: hidden;
}

#home #content aside {
  flex-shrink: 0;
  flex-basis: 240px;
  margin-left: 15px;
}

#home #block-navigation ul {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  padding: 0;
  margin: 0;
}

#home #block-navigation li {
  display: inline-block;
}

#home #block-navigation li a {
  color: white;
  background-image: linear-gradient(0deg, rgba(206, 23, 25, 0.5), rgba(206, 23, 25, 0.5)), linear-gradient(0deg, #f0f0f0, #f0f0f0);
  background-size: 100% 70px, cover;
  background-position: bottom center, 0% 0%;
  background-repeat: no-repeat;
  display: inline-block;
  height: 170px;
  width: 170px;
  padding: 115px 15px 15px 15px;
  line-height: 20px;
  text-transform: uppercase;
  font-size: 1.3em;
}

#home #block-navigation #navigation-themes {
  background-image: linear-gradient(to bottom, rgba(255, 0, 0, 0.5), rgba(255, 0, 0, 0.5)), url(../images/home-themes.jpg);
  line-height: 40px;
}

#home #block-navigation #navigation-fonds-specifiques {
  background-image: linear-gradient(to bottom, rgba(255, 0, 0, 0.5), rgba(255, 0, 0, 0.5)), url(../images/home-fonds-specifiques.jpg);
}

#home #block-navigation #navigation-exhibits {
  background-image: linear-gradient(to bottom, rgba(255, 0, 0, 0.5), rgba(255, 0, 0, 0.5)), url(../images/home-dossiers-expositions.jpg);
}

#home #block-navigation #navigation-collections {
  background-image: linear-gradient(to bottom, rgba(255, 0, 0, 0.5), rgba(255, 0, 0, 0.5)), url(../images/home-collections.jpg);
}

.block-homepage {
  background-color: #f0f0f0;
  margin-top: 15px;
}

.block-homepage > div {
  padding: 15px;
}

.block-homepage:first-child {
  margin-top: 0;
}

.block-homepage h2 {
  text-transform: uppercase;
  margin: 0;
  padding: 15px 15px 0 15px;
  font-size: 22px;
}

.block-homepage a {
  color: black;
}

#block-discover h2,
#block-did-you-know h2 {
  padding: 0;
}

#block-discover h2::before,
#block-did-you-know h2::before {
  content: '';
  display: inline-block;
  width: 50px;
  height: 50px;
  background-repeat: no-repeat;
  background-size: 40px 40px, 50px 50px;
  background-position: 5px 5px, top left;
  vertical-align: -50%;
  margin-right: 1em;
}

#block-discover h2::before {
  background-image: url(../images/picto-normannia.svg), linear-gradient(0deg, #ce1719, #ce1719);
}

#block-did-you-know h2::before {
  background-image: url(../images/picto-normannia.svg), linear-gradient(0deg, #eacd95, #eacd95);
}

#block-discover .jcarousel-wrapper {
  margin: 0;
  border: 0 none;
  box-shadow: none;
}

#block-discover .jcarousel {
  border-left: 50px solid transparent;
  border-right: 50px solid transparent;
}

#block-discover .jcarousel li {
  background-color: #c4bbb2;
  border-left: 4px solid #f0f0f0;
  border-right: 4px solid #f0f0f0;
  padding: 10px 0;
}

#block-discover .jcarousel-pagination {
  display: none;
}

#block-what-is-normannia {
  background-color: #c4bbb2;
}

#block-some-numbers {
  background-color: #eacd95;
}

#search-results #content {
  display: flex;
}

#solr-facets-wrapper {
  flex-basis: 25%;
  flex-shrink: 0;
}

#solr-results-wrapper {
  margin-left: 15px;
}

#solr-facets {
  background-color: #c4bbb2;
  color: white;
  float: none;
  width: auto;
}

#solr-facets-content {
  padding: 0 20px 20px 20px;
}

#solr-facets h2 {
  color: #615f60;
  text-transform: uppercase;
  margin: 0;
  text-indent: 15px;
  padding-top: 15px;
  font-size: 1.4em;
}

#solr-facets h2::after {
  content: '';
  display: block;
  height: 0;
  width: 100%;
  border-top: 1px solid #b1a7a0;
  border-bottom: 1px solid #cfc5bc;
  margin-top: 15px;
}

#solr-facets h3 {
  margin: 20px 0 0 0;
  font-size: 1.2em;
  font-weight: bold;
}

#solr-facets ul {
  padding: 0;
  margin: 10px 0 0 10px;
}

#solr-facets li {
  display: block;
  margin: 5px 0;
}

#solr-facets li a {
  color: white;
}

#solr-results {
  margin-left: 0;
}

#solr-results .result {
  display: flex;
  align-items: center;
  padding: 10px 10px 10px 10px;
  background-color: #f0f0f0;
}

#solr-results .result:first-child {
  margin-top: 0;
}

#solr-results .result-thumbnail {
  margin-right: 10px;
  flex-shrink: 0;
  width: 120px;
}

#solr-results .result-thumbnail img {
  display: block;
}

#solr-results div.result a.result-title {
  font-size: 1.3em;
  font-weight: normal;
}

#solr-results div.result .result-header {
  padding-left: 50px;
  min-height: 40px;
  background-repeat: no-repeat;
  background-size: 40px 40px;
  background-position: left center;
}

#solr-results div.result-type-presse_ancienne .result-header {
  background-image: url(../images/picto-book.svg);
}

#solr-results div.result-type-livre_num_ris_ .result-header {
  background-image: url(../images/picto-ebook.svg);
}

#solr-results div.result-type-photo .result-header {
  background-image: url(../images/picto-photo.svg);
}

body.collections header[role="presentation"] {
  background-color: #c4bbb2;
  margin-bottom: 20px;
  padding: 0.1px;
}

body.collections header[role="presentation"] h1,
body.collections header[role="presentation"] h2,
body.collections header[role="presentation"] h3,
body.collections header[role="presentation"] h4,
body.collections header[role="presentation"] h5,
body.collections header[role="presentation"] h6 {
  text-transform: uppercase;
  margin: 0;
}

body.collections header[role="presentation"] h1::before {
  content: '';
  display: inline-block;
  width: 50px;
  height: 50px;
  background-repeat: no-repeat;
  background-size: 40px 40px, 50px 50px;
  background-position: 5px 5px, top left;
  vertical-align: -50%;
  margin-right: 1em;
  background-image: url(../images/picto-normannia.svg), linear-gradient(0deg, #ce1719, #ce1719);
}

body.collections header[role="presentation"] h1 {
  font-size: 22px;
}

body.collections header[role="presentation"] h2,
body.collections header[role="presentation"] h3,
body.collections header[role="presentation"] h4,
body.collections header[role="presentation"] h5,
body.collections header[role="presentation"] h6 {
  margin: 0.5em 10px;
}

body.collections header[role="presentation"] > div {
  margin: 0;
  padding: 10px;
  font-size: 0.9em;
}

body.collections #content {
  display: flex;
}

body.collections #content > aside {
  flex-shrink: 0;
  flex-basis: 240px;
  margin-left: 15px;
}

body.collections .collections,
body.collections .items {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

body.collections .collection,
body.collections .item {
  background-color: #f0f0f0;
  flex-basis: 49%;
  display: flex;
  padding: 10px 10px 10px 10px;
  margin-bottom: 20px;
}

body.collections .collection img,
body.collections .item img {
    max-width: 100px;
}

body.collections .collection .collection-metadata,
body.collections .item .item-metadata {
  margin-left: 10px;
}

body.collections .collection h2,
body.collections .item h2 {
  margin: 0;
}

body.collections .collection[data-title] h2 {
    display: flex;
    align-items: center;
}

body.collections .collection[data-title] h2::before {
    display: inline-block;
    margin-right: 0.5em;
    flex-shrink: 0;
    width: 40px;
    height: 33px;
    box-sizing: border-box;
}

body.collections .collection[data-title="Presse ancienne"] h2::before {
    content: url(../images/picto-book.svg);
}

body.collections .collection[data-title="Photos"] h2::before {
    content: url(../images/picto-photo.svg);
}

body.collections .collection[data-title="Livres numérisés"] h2::before {
    content: url(../images/picto-ebook.svg);
    padding-left: 9px;
    padding-right: 8px;
}

body.collections .collection[data-title="Catalogue collectif normand"] h2::before {
    content: url(../images/picto-classeur.svg);
    padding-left: 5px;
    padding-right: 5px;
}

body.collections .collection[data-title="Bibliographie normande"] h2::before {
    content: url(../images/picto-map.svg);
    height: 29px;
}

body.collections .collection p {
  margin: 0;
}

body.item.show #content h1 {
  color: #ce1719;
}

body.item.show #metadata-wrapper {
  display: flex;
  justify-content: space-between;
}

body.item.show .metadata > * {
  display: inline-block;
  vertical-align: top;
}

body.item.show .metadata-label {
  color: #c4bbb2;
}

body.item.show .universalviewer-wrapper {
  background-color: #f0f0f0;
  padding: 20px;
}

body.item.show #metadata {
  padding: 20px;
}

body.item.show #metadata .description {
  margin-top: 20px;
}

body.item.show #files {
  padding: 20px;
}

body.item.show #files h3 {
  display: inline-block;
  background-color: #eacd95;
  border-bottom: 1px solid #d5b888;
  padding: 0 60px 0 20px;
  margin: 0;
  text-transform: uppercase;
  height: 40px;
  line-height: 40px;
  border-radius: 3px;
  position: relative;
  cursor: pointer;
}

body.item.show #files h3::after {
  content: '';
  display: inline-block;
  position: absolute;
  right: 0;
  border-left: 1px solid #d5b888;
  width: 40px;
  height: 40px;
  background-image: url(../images/picto-select.svg);
  background-repeat: no-repeat;
  background-position: center center;
  background-size: 20px 20px;
}

body.item.show #files ul {
  position: absolute;
  background-color: white;
  border: 1px solid #d5b888;
  margin: 0;
  padding: 0 10px 10px 10px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  width: 450px;
}

body.item.show #files ul li {
  padding: 10px;
  background-color: #f0f0f0;
  display: inline-block;
  width: 100px;
  margin-top: 10px;
}

body.item.show #element-texts {
  padding: 20px;
  background-color: #f0f0f0;
}

body.item.show #element-texts .metadata-label {
  min-width: 250px;
}

body.files.show h1 {
  color: #ce1719;
}

body.files.show #primary {
  display: flex;
}

body.files.show #primary .item-file {
  padding: 10px;
  background-color: #f0f0f0;
  flex-shrink: 0;
  width: 350px;
}

body.files.show #primary #transcription-download-wrapper {
  padding-left: 20px;
}

body.files.show #primary #transcription h2 {
  margin-top: 0;
  color: #c4bbb2;
  font-style: italic;
}

body.files.show #save-link {
  background-color: #eacd95;
  color: #615f60;
  padding: 8px 20px;
  text-transform: uppercase;
  height: 40px;
  line-height: 40px;
  border-radius: 3px;
  border-bottom: 1px solid #d5b888;
}

body.exhibits.browse #content {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
}

body.exhibits.browse .exhibit-wrapper {
  flex-basis: 50%;
}

body.exhibits.browse .exhibit-wrapper:nth-child(even) {
  padding-left: 10px;
}
body.exhibits.browse .exhibit-wrapper:nth-child(odd) {
  padding-right: 10px;
}
body.exhibits.browse .exhibit-wrapper:nth-child(n+3) {
  padding-top: 20px;
}

body.exhibits.browse .exhibit {
  background-color: #f0f0f0;
  display: flex;
}

body.exhibits.browse .exhibit-thumbnail img {
  display: block;
}

body.exhibits.browse .exhibit .exhibit-metadata {
  padding: 10px;
}

body.exhibits.browse .exhibit h2 {
  margin-top: 0;
}

/* Google Maps style */
.gm-style {
    font-family: 'Open Sans', sans-serif;
}