:root {
  --window-bg: #F5F1E9;
  --green: #16623F;
  --green-light: #4c7f67;
  --dark: #1B2A23;
}

@font-face {
  font-family: "Instrument";
  src: url("./fonts/InstrumentSerif-Regular.ttf");
}
@font-face {
  font-family: "Instrument Italic";
  src: url("./fonts/InstrumentSerif-Italic.ttf");
}

* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html, body {
  font-family: "Instrument";
  background-color: var(--window-bg);
  color: var(--green);
  font-size: 14px;
  max-width: 100%;
  overflow: visible;
}

body {
  padding: 2rem 2rem 4rem 2rem;
}

h1 {
  font-family: "Instrument Italic", serif;
  font-size: 6rem;
  color: var(--green);
  font-weight: 400;
}
h2 {
  color: var(--green);
  font-weight: 400;
  font-size: 3rem;
}
h3 {
  font-family: 'Instrument Italic', serif;
  font-weight: 400;
  font-size: 1.5rem;
}

.header {
  text-align: center;
}

.photo-scroll {
  position: relative;
  text-align: center;
  display: block;
  margin: 0 auto;
  max-width: 90rem;
}

.row {
  margin-top: 6rem;
}

.polaroid {
  display: inline-block;
  background: white;
  border-radius: 2px;
  box-shadow: 1px 1px 5px rgba(0,0,0,0.15);
  margin: 2rem;
  padding: 1rem 1rem 4rem 1rem;
  position: relative;
}
.polaroid > img {
  width: 300px;
}
/* .polaroid:hover {
  margin: 6rem;
  z-index: 100;
} */

.dim {
  display: none;
  position: fixed;
  background-color: var(--window-bg);
  width: 100vw;
  height: 100vh;
  top: 50%;
  left: 50%;
  transform: translateX(-50%) translateY(-50%) scale(1.1);
  opacity: 0;
}

.polaroid.enlarged {
  position: fixed;
  box-shadow: 1px 1px 8px rgba(0,0,0,0.2);
  width: 800px;
  max-width: 70vh;
  margin: 0;
  top: 50%;
  left: 50%;
  transform: translateX(-50%) translateY(-50%);
  opacity: 0;
}
.polaroid.enlarged > img {
  width: 100%;
}

button {
  border: 1px solid var(--green-light);
  border-radius: 2px;
  color: var(--green);
  cursor: pointer;
  margin: 0;
  padding: 0.5rem 1rem;
  width: auto;
  overflow: visible;
  background: transparent;
  font-family: "Instrument Italic", serif;
  font-size: 1rem;

  /* Normalize `line-height`. Cannot be changed from `normal` in Firefox 4+. */
  line-height: normal;

  /* Corrects font smoothing for webkit */
  -webkit-font-smoothing: inherit;
  -moz-osx-font-smoothing: inherit;

  /* Corrects inability to style clickable `input` types in iOS */
  -webkit-appearance: none;
}

@media only screen
and (max-width: 500px) {
  .polaroid {
    margin: 2.5rem 0;
    width: calc(80vw - 2rem);
  }
  .polaroid > img {
    width: 100%;
  }
}

@media only screen
and (max-device-width: 400px)
and (-webkit-min-device-pixel-ratio: 3) {
  h1 {
    font-size: 8rem;
  }
  h2 {
    font-size: 4rem;
  }
  .polaroid {
    box-shadow: 1px 1px 5px rgba(0,0,0,0.15);
    margin: 2.5rem 0;
    padding: 2rem 2rem 5rem 2rem;
    width: calc(80vw - 4rem);
  }
  .polaroid > img {
    width: 100%;
  }
}
@media only screen
and (max-device-width: 400px)
and (-webkit-min-device-pixel-ratio: 2) {
  h1 {
    font-size: 8rem;
  }
  h2 {
    font-size: 4rem;
  }
  .polaroid {
    box-shadow: 1px 1px 5px rgba(0,0,0,0.15);
    margin: 2.5rem 0;
    padding: 2rem 2rem 5rem 2rem;
    width: calc(80vw - 4rem);
  }
  .polaroid > img {
    width: 100%;
  }
}

/* and (-webkit-min-device-pixel-ratio: 2)  */