@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Source+Sans+Pro:wght@200&display=swap');

@font-face {
  font-family: 'D-DIN';
  font-weight: bold;
  src: url("D-DIN-Bold.otf") format("opentype");
  font-display: auto;
}

@font-face {
  font-family: 'D-DIN Condensed';
  src: url("D-DINCondensed.otf") format("opentype");
  font-display: auto;
}

@font-face {
  font-family: 'Garamond';
  src: url("Garamond-Regular.otf") format("opentype");
  font-display: auto;
}

:root {
  --font-color: #4b4b4b;
  --font-color-2: #6e6e6e;
  --font-color-3: #423522;
  --font-color-title:
    --border-color: #cabcb1;
  --background-color: #f9f0e9;
  --background-color-translucent: #f9f0e97a;
  --background-color-beige: #f9f6f1;
  --a-background-color: #6e6e6e20;
  --button-color-1: #FEDB96;
  --button-color-2: #FFE4B1;
  --button-color-3: #fdf1da;
  --button-border-color: #ceae59;
  --font: 'Garamond', serif;
  --font-title: 'D-DIN', sans-serif;
  --font-subtitle: 'D-DIN Condensed', sans-serif;
  --padding: max(10vw, calc((100vw - 1000px) / 2))
}

* {
  box-sizing: border-box;
}

html {
  --scroll-behavior: smooth;
  scroll-behavior: smooth;
  font-family: "scroll-behavior: smooth", sans-serif;
}

body {
  font-family: var(--font);
  font-size: 1rem;
  color: var(--font-color-3);
  margin: 0;
  touch-action: manipulation;
}

.hidden {
  visibility: hidden;
}

/**********/
/* Header */
/**********/

.title {
  text-transform: uppercase;
  text-align: center;
  font-size: 2rem;
  color: var(--font-color);
  margin-bottom: 0.7rem;
}

.title .montessori {
  text-transform: uppercase;
  display: block;
  font-size: 4rem;
  font-family: var(--font-title);
}

.title .children {
  font-size: 2rem;
  text-transform: uppercase;
  font-family: var(--font-subtitle);
}

.subtitle {
  font-size: 1.3rem;
  text-align: center;
  font-family: var(--font);
  color: var(--font-color);
}

/********/
/* Main */
/********/

main {
  text-align: left;
}

a {
  font-weight: bold;
  color: #e7bc21;
}

/************/
/* Sections */
/************/

section {
  padding: 2rem var(--padding);
  text-align: justify;
}

section h3 {
  text-transform: uppercase;
  font-family: var(--font-subtitle);
}

.beige {
  background-color: var(--background-color-beige);
}

.section-1 {
  min-height: 400px;
  display: flex;
  flex-direction: row;
  align-items: flex-start;
}

.section-2 {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.section-3 {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
}

.section-3-middle-column {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.section-4 {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
}

.section-4>.bullet {
  flex-grow: 1;
  flex-shrink: 1;
  flex-basis: 0;
}

.section-5 {
  text-align: center;
}

.section-6 {
  min-height: 400px;
}

.row {
  display: flex;
  justify-content: center;
}

.column {
  flex: 0 1 auto;
  margin: 2rem;
  text-align: left;
}

blockquote {
  text-align: left;
  font-size: 2rem;
  width: 65%;
  margin: 1rem auto;
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--font-color-3);
  padding: 1.2em 30px 1.2em 75px;
  line-height: 1.6;
  position: relative;
}

blockquote::before {
  font-family: var(--font);
  content: "\201C";
  color: var(--button-border-color);
  font-size: 8rem;
  position: absolute;
  left: -4px;
  top: -25px;
}

blockquote span {
  font-size: 1.3rem;
  text-align: right;
  display: block;
  color: var(--font-color-3);
  font-style: normal;
  font-weight: bold;
  margin-top: 1em;
}

.author-section {
  min-height: 500px;
  display: flex;
  flex-direction: row;
  justify-content: space-evenly;
  align-items: flex-start;
}

.author-text {
  max-width: 40%;
  flex-grow: 1;
  flex-shrink: 0;
  flex-basis: 0;
}

.author {
  flex-grow: 0;
  flex-shrink: 0;
  flex-basis: 0;
  width: 300px;
}

img.left-float {
  padding: 1rem 1rem 1rem 0;
  float: left;
}

img.right-float {
  float: right;
  padding: 1rem 0 1rem 1rem;
}

.casa-bambini {
  width: 500px;
  padding: 0 !important;
  padding-left: 1rem !important;
}

.sweater {
  width: 334px;
  transform: rotate(-10deg);
}

.cookies {
  width: 85px;
}

.socks {
  width: 110px;
  align-self: flex-end;
  position: relative;
  top: -1rem;
  transform: rotate(35deg);
}

.light-bulb {
  width: 150px;
  float: right;
  padding: 1rem 0 1rem 1rem;
}

.materials {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-around;
}

.seguin-board {
  width: 150px;
  transform: rotate(-18deg);
  align-self: flex-end;
}

.stair {
  width: 500px;
}

.interlocking-discs {
  width: 107px;
  align-self: flex-start;
  position: relative;
  left: -3rem;
}

.rainbow {
  width: 280px;
  float: right;
  position: relative;
  bottom: 6rem;
  right: 4rem;
  transform: rotate(3deg);
  opacity: 0.7;
  z-index: -1;
}

.sun {
  width: 120px;
  float: left;
  margin-right: 1rem;
}

.cloud-1 {
  width: 200px;
  float: left;
  position: relative;
  bottom: 7rem;
  left: 1rem;
  z-index: -1;
  opacity: 0.3;
}

.cloud-2 {
  width: 100px;
  float: right;
  opacity: 0.3;
}

.book {
  width: 400px;
  padding: 1rem 1rem 0 0;
}

header {
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.leaf {
  position: absolute;
  right: 0;
  top: -68px;
}

/***********/
/* Gallery */
/***********/

.gallery-container {
  position: relative;
}

#gallery-indicator {
  color: #e0c98a;
  position: relative;
  top: -20px;
  font-size: 2rem;
}

.gallery {
  margin-top: 1rem;
  padding-bottom: 1rem;
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  overflow: scroll;
}

.gallery figure {
  width: 100%;
  margin: 0 0.5rem 0 0;
}

.gallery figure img {
  width: 120px;
  border: 1px solid #e0c98a;
  border-radius: 8px;
}

.gallery figure figcaption {
  display: none;
}

#left-shadow {
  pointer-events: none;
  position: absolute;
  left: 0px;
  top: 0px;
  right: 0px;
  bottom: 20px;

  box-shadow: inset 12px 0px 9px -10px rgba(0, 0, 0, .55);
}

#right-shadow {
  pointer-events: none;
  position: absolute;
  left: 0px;
  top: 0px;
  right: 0px;
  bottom: 20px;

  box-shadow: inset -12px 0px 9px -10px rgba(0, 0, 0, .55);
}

/********/
/* Text */
/********/

h1 {
  margin: 0;
}

h2 {
  margin: 0;
}

.handwritten {
  font-family: 'Great Vibes', cursive;
}

.col-1 ul {
  column-count: 1;
}

.col-2 ul {
  column-count: 2;
}

.bullet ul {
  padding-left: 10px;
  list-style: none;
}

.bullet li {
  text-align: left;
  display: flex;
  margin-bottom: 1rem;
}

.bullet li:before {
  content: "✓";
  width: 23x;
  min-width: 23px;
  height: 20px;
  padding-top: 3px;
  font-size: 14px;
  text-align: center;
  border-radius: 50%;
  display: block;
  font-family: serif;
  margin-right: 8px;
  border: 1px solid #8f7f3f;
  color: #8f7f3f;
  position: relative;
}

.buy-section {
  position: relative;
  float: right;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
}

.quantity-buttons>span {
  cursor: pointer;
}

.quantity-buttons {
  padding-top: 1rem;
}

#minus,
#plus {
  width: 28px;
  height: 34px;
  background: #f2f2f2;
  border-radius: 4px;
  padding: 8px 5px 8px 5px;
  border: 1px solid #ddd;
  display: inline-block;
  vertical-align: middle;
  text-align: center;
}

.quantity-buttons>input {
  height: 34px;
  width: 100px;
  text-align: center;
  color: var(--font-color);
  font-size: 26px;
  border: 1px solid #ddd;
  border-radius: 4px;
  display: inline-block;
  vertical-align: middle;
}

/**********/
/* Button */
/**********/

.button {
  position: relative;
  padding: 8px 24px;
  border-radius: 16.5px;
  color: var(--font-color-3);
  cursor: pointer;
  background-color: var(--button-color-1);
  border: none;
  font-size: 1rem;
  transition-duration: 0.15s, 0.15s;
  transition-property: all;
  transition-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1), cubic-bezier(0.215, 0.61, 0.355, 1);
  white-space: nowrap;
  transition-property: background-color, opacity;
}

.button:hover {
  background-color: var(--button-color-2);
}

.button:active {
  position: relative;
  top: 1px;
}

.button--loading .button__text {
  visibility: hidden;
}

.button--loading::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  border: 4px solid transparent;
  border-top-color: var(--button-color-3);
  border-radius: 50%;
  animation: button-loading-spinner 1s ease infinite;
}

#more-than-one {
  padding-top: 0.5rem;
  color: var(--font-color-3);
}

@keyframes button-loading-spinner {
  from {
    transform: rotate(0turn);
  }

  to {
    transform: rotate(1turn);
  }
}

.dialog {
  position: fixed;
  z-index: 9999999;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: var(--background-color-translucent);
  opacity: 0;
  top: -100%;
  transition: opacity .2s;
}

.dialog.show {
  top: 0;
  opacity: 1;
}

.dialog-content {
  background-color: #fff;
  margin: 15% auto;
  padding: 20px;
  border: 2px solid var(--background-color-beige);
  border-radius: 4px;
  box-shadow: 0px 0px 20px -10px rgba(0, 0, 0, .5);
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: var(--font-color);
}

.dialog-rainbow {
  width: 100px;
}

.dialog-cloud {
  width: 150px;
}

.dialog-content>p {
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

.dialog-content-title {
  font-size: 1.2rem;
}

.close {
  color: var(--font-color-2);
  cursor: pointer;
  align-self: flex-end;
  font-size: 14px;
  font-weight: bold;
  margin-top: -8px;
  margin-right: -4px;
}

.close:hover,
.close:focus {
  color: black;
  text-decoration: none;
  cursor: pointer;
}

.close:active {
  color: var(--font-color-2);
}

.section-3-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.diary>button {
  float: none;
}

.micro {
  position: fixed;
  bottom: 50px;
  z-index: 9999;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  width: 100%;
  border-radius: 8px;
  text-decoration: none;
  pointer-events: none;
}

.micro > a {
  margin-right: 50px;
  max-width: min(80%, 220px);
  background-color: var(--button-color-1);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-decoration: none;
  cursor: pointer;
  color: var(--font-color-3);
  pointer-events: auto;
}

#close-promo {
  position: absolute;
  margin-right: 60px;
  top: 0;
  color: white;
  padding: 5px;
  cursor: pointer;
  pointer-events: auto;
}

.micro-img {
  width: 100%;
  object-fit: cover;
  overflow: hidden;
  border-radius: 8px 8px 0 0px;
  background-color: var(--button-color-1);
}

.micro > a > .button__text {
  padding-top: 8px;
  padding-bottom: 8px;
  padding-left: 16px;
  padding-right: 16px;
}

#ig-button {
  position: fixed;
  bottom: 50px;
  right: 50px;
  z-index: 9998;
  padding: 8px 24px;
  border-radius: 16.5px;
  color: var(--font-color-3);
  cursor: pointer;
  background-color: var(--button-color-1);
  border: none;
  font-size: 1rem;
  transition-duration: 0.15s, 0.15s;
  transition-property: all;
  transition-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1), cubic-bezier(0.215, 0.61, 0.355, 1);
  white-space: nowrap;
  transition-property: background-color, opacity;
  border: 1px solid var(--button-border-color);
  text-decoration: none;
}

#ig-button:hover {
  background-color: var(--button-color-2);
}

/**********/
/* Mobile */
/**********/
@media (min-width:676px) {
  .mobile {
    display: none;
  }
}

@media (max-width:675px) {
  .micro {
    bottom: 20px;
    right: unset;
  }

  #close-promo {
    margin-right: 10px;
    right: calc(50vw - 110px);
  }

  .micro > a {
    margin-right: unset;
  }

  .micro {
    align-items: center;
  }

  .web {
    display: none;
  }

  header {
    position: relative;
    overflow: hidden;
  }

  body {
    font-size: 1.15rem;
  }

  .title .montessori {
    font-size: 3rem;
  }

  .title .children {
    font-size: 1.2rem;
  }

  .subtitle {
    font-size: 1.2rem;
  }

  .leaf {
    position: absolute;
    transform: rotate(10deg);
    height: 130%;
    top: 0px;
    left: 10px;
    z-index: -1;
  }

  section {
    padding: 2rem 1.4rem;
  }

  .section-1 {
    flex-direction: column-reverse;
    padding-bottom: 0;
  }

  .section-1 div {
    z-index: 100;
  }

  .buy-section {
    float: left;
  }

  .book {
    position: relative;
    top: -50px;
    width: 85vw;
    z-index: 1;
    padding: 1rem 0.5rem 0 0.5rem;
  }

  .section-2 {
    flex-direction: column;
  }

  .casa-bambini {
    width: 90vw;
    padding: 0 !important;
  }

  .sweater {
    width: 300px;
    margin-bottom: 1rem;
  }

  .socks {
    margin-top: 1rem;
    right: 1rem;
  }

  .section-3 ul {
    margin: 0;
  }

  .section-3 {
    flex-direction: column;
  }

  .section-3-title {
    flex-direction: column-reverse;
  }

  .diary {
    align-self: flex-end;
  }

  .section-4 ul {
    margin: 0;
  }

  .section-4 {
    padding-top: 1rem;
    flex-direction: column;
  }

  .seguin-board {
    width: 25vw;
    position: relative;
    left: 1.5rem;
  }

  .stair {
    width: 60vw;
    position: relative;
    left: 1rem;
  }

  .interlocking-discs {
    width: 15vw;
    left: -2rem;
  }

  .section-5 {
    flex-direction: column;
  }

  .section-6 {
    flex-direction: column;
  }

  .sun {
    width: 90px;
    float: right;
  }

  .cloud-1 {
    float: right;
    bottom: 20rem;
  }

  .cloud-2 {
    position: relative;
    float: left;
    z-index: -1;
    bottom: 2rem;
  }

  blockquote {
    width: 100%;
    padding: 0.8em 20px 0.8em 45px;
  }

  blockquote p {
    font-size: 1.5rem;
  }

  blockquote::before {
    top: -60px;
    left: -20px;
  }

  blockquote span {
    font-size: 1.1rem;
  }

  .author-section {
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .author-text {
    max-width: 100%;
  }

  .dialog-content {
    margin: 30% auto;
    width: 90%;
  }
}
