/* Variables  */

:root {
  --main-white: #ffffff;
  --main-cream: #f7f6f5;
  --main-gold: #f5df4d;
  --main-charcoal: #353535;
  --text-black: rgba(0,0,0,1);
  --text-gray: rgba(29,29,29,.75);
  --text-lightgray: rgba(29,29,29,.2);
  --text-white: #f7f6f5;
  --nav-overlay: rgba(0,0,0, 0.9);
  --button-gray: rgba(29,29,29,.8);
}

/* Base reset */
* {
  margin: 0;
  padding: 0;
}

/* Box-sizing and font sizing */
*,
*::before,
*::after {
  box-sizing: inherit;
}

html {
  box-sizing: border-box;
  /* Set font size for easy rem calculations
   * default document font size = 16px, 1rem = 16px, 100% = 16px
   * (100% / 16px) * 10 = 62.5%, 1rem = 10px, 62.5% = 10px
  */
  font-size: 62.5%;
  scroll-behavior: smooth;
}

/* Base styles */

html, body {
  height: 100%;
  width: 100%;
}

body {
  display: flex;
  flex-direction: column;
  font-family: "Arial", "Helvetica", "sans-serif";
  color: var(--text-gray);
  font-weight: 400;
  font-style: normal;
  letter-spacing: .09rem;
  line-height: 2.1rem;
  font-variant: normal;
}

main {
  flex: 1 0 auto;
  margin: 0 5vw;
  padding-bottom: 2rem;
}

a {
  color: inherit;
}

a:hover {
  color: var(--main-gold);
}

ul{
  list-style-type: none;
}

h1, h2, .book-info-emphasis {
  font-family: "Special Elite", Courier, monospace;
  color: var(--main-charcoal);
  font-size: 2.25rem;
  line-height: 3rem;
  padding-top: 1.5rem;
}

h3 {
  color: var(--text-gray);
  font-size: 1.75rem;
}

p {
  font-size: 1.5rem;
}


/* Responsive iframes */

iframe {
  display: block;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.iframe-container {
  overflow: hidden;
  padding-top: 56.25%; /* 16:9 */
  position: relative;
}

.iframe-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  border: 0;
  width: 100%;
  height: 100%;
}


/* Header */

header {
  height: auto;
  width: auto;
  display: flex;
  align-items: center;
  padding: 1rem 1.5rem 0rem 1.5rem;
  justify-content: space-between;
  -webkit-justify-content: space-between;
}

#logo-container {
  height: 100%;
  display: flex;
  align-items: end;
}

.logo-header {
  height: 5rem;
}

/* Nav, Mobile First w/ JavaScript overlay container. */
/* See media calls for responsive styling for large screens.*/

.overlay {
  height: 100%;
  width: 100%;
  display: none;
  position: fixed;
  z-index: 1;
  top: 0;
  left: 0;
  background-color: rgba(0,0,0, 0.9);
}

nav {
  position: relative;
  top: 25%;
  width: 100%;
  text-align: center;
  margin-top: 30px;
  line-height: 4rem;
}

nav ul {
  display: flex;
  flex-direction: column;
}

#navbar-counter-target {
  vertical-align: top;
  padding: 0em .2em;
  line-height: .5em;
  font-size: 1rem;
}


.overlay a, .fa-shopping-cart, .fa-bars {
  text-decoration: none;
  font-size: 3.5rem;
  line-height: 4rem;
  margin-top: 1.5rem;
  color: var(--text-white);
  display: block;
}

#cart-icon a{
  text-decoration: none;
}

.overlay a:hover, #ui-cluster span:hover{
    -webkit-transform: translate(0px,-3px);
    transform: translate(0px,-3px);
}

.overlay .closebtn {
  position: absolute;
  top: 4rem;
  right: 4rem;
  font-size: 6rem;
}

#ui-cluster{
  display: flex;
  align-items: flex-end;
}

.fa-bars, .fa-shopping-cart {
  color: var(--main-charcoal);
  padding: 1rem;
  font-size: 2rem;
  margin-bottom: .4rem;
}


/* Events */

.subscription-event {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  position: fixed;
  z-index: 2;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  height: 30rem;
  width: 53rem;
  max-width: 95%;
  padding: 2.0rem;
  background-color: var(--main-cream);
  border: 3px solid rgba(29,29,29,.85);
  color: rgba(29,29,29,.85);
}

.subscription-event-close {
  direction: rtl;
  font-size: 3rem;
}

.subscription-event-close:hover {
  color: inherit;
  cursor: pointer;
}

.subscription-event-title {
  font-size: 3.5rem;
  line-height: 4rem;
  text-align: center;
}

.subscription-event-pitch {
  width: 97%;
  margin: 0 auto;
}


/* Sections */

.standard-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-around;
  padding: 2.5rem;
}

.book-image, .repeater-image {
  box-shadow: .4rem .5rem 1.8rem .4rem #505050;
  margin-top: 1.5rem;
  width: 100%;
  align-self: start;
}

.book-information {
  margin: 0 auto;
  margin-top: 1.5rem;
  padding-top: 2.5rem;
}

.book-image, .book-information {
  width: 100%;
  max-width: 35rem;
}

.title {
  font-style: italic;
}

.big {
  font-size: 2.5rem;
}

.catalog-repeater {
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  justify-items: center;
  padding: 2.5em;
  column-gap: 3rem;
}

.repeater-tile {
  display: flex;
  flex-direction: column;
  max-width: 25rem;
  padding-top: 1rem;
}

.repeater-tile:first-of-type {
  padding-top: 0;
}

.repeater-text {
  padding-top: 3.5rem;
}

/* Things We Love Blog */

.blog-container-index, .blog-container-twl {
  width: 100%;
  margin: 2rem 0;
  height: auto;
  display: flex;
  flex-flow: row wrap;
  align-items: flex-start;
}

.blog-container-index {
  justify-content: space-evenly;
}

.blog-container-twl {
  justify-content: space-between;
}

.blog-container-index a:link {
  text-decoration: none;
}

.blog-preview {
 width: 100%;
 margin-top: 1.5rem;
 display: flex;
 align-items: flex-start;
}

.blog-preview:first-of-type {
  flex-direction: column;
  padding-bottom: 1rem;
}

.blog-preview:first-of-type .blog-information, .blog-preview:first-of-type .blog-image {
  width: 100%;
}

.blog-information {
  padding-left: 1rem;
  width: 65%;
}

.blog-information-feature-page {
  width: 100%;
}

.blog-information-feature-page p {
  margin: 0;
  padding: 1rem 0 0 0;
}

.blog-category {
  font-size: 1.2rem;
  color: #cc00cc;
  display: inline-block;
}

.blog-category::first-letter {
  text-transform: uppercase;
}

.blog-title {
 font-size: 1.5rem;
 font-weight: bold;
 letter-spacing: .02rem;
}

.blog-title-feature-page {
  align-self: flex-start;
  font-size: 3rem;
  font-family: "Arial", "Helvetica", "sans-serif";
  font-weight: bold;
  letter-spacing: .02rem;
}

.blog-image{
  width: 35%;
  object-fit: cover;
  aspect-ratio: 1.91 / 1;
  border: 4px solid var(--main-charcoal);
}

.blog-image-feature-page {
  width: 100%;
  object-fit: cover;
  aspect-ratio: 1.91 / 1;
  border: 4px solid var(--main-charcoal);
  margin-top: 2rem;
}

.blog-display {
  margin: 0 auto;
  display: flex;
  flex-wrap: nowrap;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  max-width: 800px;
}

.blog-entry {
  padding: 1rem 2rem;
  margin-bottom: 2rem;
}

#more-twl {
  width: 30rem;
  letter-spacing: .09rem;
  margin-top: 5rem;
}

/* Subscribe Page */

.newsletter {
  display: block;
  margin-left: auto;
  margin-right: auto;
  height: 110rem;
  width: 70rem;
  max-width: 100%;
}

/* Visual Line Breaks */

.stripes {
  margin: 1rem auto;
  width: 100%;
  border-bottom: .2rem solid var(--main-gold);
  border-top: .2rem solid var(--main-gold);
  height: 1.5rem;
}

.divide {
  margin: 1rem auto;
  border-bottom: .2rem solid var(--text-lightgray);
  width: 100%;
}

/* Buttons */

.addToCart, .btn-fxo {
  border: none;
  background: var(--button-gray);
  outline: 2px solid var(--button-gray);
  color: var(--text-white);
  padding: 1rem;
  margin: 2rem 0;
  font-size: 1.75rem;
  cursor: pointer;
  width: 100%;
}

.addToCart:hover, .btn-fxo:hover {
  --webkit-transform: translate(0px,-2px);
  transform: translate(0px,-2px);
}

.btn-fxo:active{
  box-shadow: 2px 2px 5px var(--button-gray);
}

/* Rename the following to alt button */
.button a, .check-promo-button {
  background: var(--main-gold);
  color: var(--main-charcoal);
  border: 1px solid var(--main-charcoal);
  border-radius: 5px;
  text-decoration: none;
  font-size: 1.5rem;
  padding: .75rem 5rem;
  display: inline-block;
  margin: 10px 0 0 25px;
  transition: all ease-in-out 300ms;
}

.button a:active, .check-promo-button:active{
  background: var(--main-charcoal)
}

.button a:hover, .check-promo-button:hover{
  --webkit-transform: translate(0px,-5px);
  transform: translate(0px,-5px);
}

/* our-books-display smartcart info */

.smartcart-information-display {
  padding: 0 1rem;
  font-size: 1.4rem;
}


/* Checkout Page */

.cart-column {
  width: 100%;
  max-width: 40rem;
}

.checkout-padding {
  padding-left: 0;
  padding-right: 0;
}

.outline-unit {
    border: 3px solid var(--main-charcoal);
}

/* Cart Items Container */
/* Constructed in JS CheckoutTile */

.cart-items-container {
  padding: 1rem;
  margin-bottom: 1.5rem;
  display: flex;
  height: 15rem;
}

.cart-items-image-container{
  width: 25%;
  margin: 1rem;
}

.cart-items-controls{
  width: 75%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.smartcart-clear {
  background: none;
  color: inherit;
  border: none;
  padding: 0;
  font: inherit;
  font-size: 1.9rem;
  cursor: pointer;
  outline: inherit;
}

.cart-item-title-link{
  text-decoration: none;
}

.cart-items-image{
  max-width: 100%;
  max-height: 100%;
}

.smartcart-controls {
  display: flex;
  border: 1px solid #353535;
  height: 100%;
  margin-top: .5rem;
}

.smartcart-controls div, .smartcart-controls button{

  border: 1px solid #353535;
  background-color: #ffffff;
  height: 25px;
  width: 25px;
}

.smartcart-quantity{
  text-align: center;
  line-height: 2.35rem;
  font-size: 1.3rem;
  color: black;
}

.smartcart-controls button:active{
  background-color: var(--main-charcoal);
}

.smartcart-plus, .smartcart-minus {
  cursor: pointer;
}

/* Cart Total Container */

.cart-total-container {
  padding: 1rem;
}

.cart-total-container div{
  display: flex;
  justify-content: space-between;
  padding-top: 1em;
}

.cart-total-container div p{
  display: block;
}

.cart-total {
  border-top: 1px solid rgba(29,29,29,.8);
  padding-top: .7em;
  margin-top: .7em;
  padding-bottom: .7em;
}

/*Paypal Button*/

.paypal-buttons {
  margin: 2em auto;
  width: 90%;
  max-width: 500px;
}

/* Promotions */

#promotion-container {
  padding:1rem;
  margin: 1.5rem 0;
}

#promo-input-container{
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

#promo {
  height: 3rem;
  margin: auto, 0;
  padding: .5rem;
  width: 40%;
}

#promo:focus{
  outline: none;
  border: 2px solid var(--main-charcoal);
  border-radius: 3px;
}

#promo-display{
  margin-top: 1rem;
}

/* Footer */

footer {

  background-color: #f7f6f5;
  margin-top: 1.25rem;
  padding-top: 2rem;
  line-height: 2rem;
  font-size: 1.75rem;
}

.footer-link-container{
  display: flex;
  justify-content: space-evenly;
  margin: 0 auto;
  padding-bottom: 3rem;
  max-width: 750px;
}

.footer-link-title {
  color: var(--main-charcoal);
  font-size: 1.75rem;
  font-family: "Special Elite", Courier, monospace;
  padding: 1rem 0;
}


.footer-link:link, .footer-link:visited {
  color: var(--main-charcoal);
  font-size: 1.3rem;
  line-height: 1.3rem;
  text-decoration: none;
}

#watermark {
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--main-charcoal);
  height: 75px;
}

#footer-logo-container {
  display: flex;
  align-items: center;
  width: 3rem;
  height: 4rem;
  border-radius: 50%;
  background-color: var(--main-cream);
  border: 1px solid black;
  box-shadow: 0 0 0 .25rem var(--main-cream);
}

#footer-logo {
  height: 2rem;
  margin: auto auto;
}

/* Privacy Banner */

.privacy-banner {
  height: 2rem;
  width: 100%;
  height: 120px;
  background-color: rgba(0,0,0, 0.80);
  position: fixed;
  bottom: 0;
  left: 0;
  color: white;
  padding: 2rem;
  font-size: 14px;
  line-height: 20px;
}

.privacy-banner div:nth-child(2){
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

.privacy-banner-buttons{
  background-color: inherit;
  border: none;
  color: inherit;
  padding-left: 2rem;
}

.privacy-banner-buttons:hover{
  cursor: pointer;
}

.privacy-banner-txt-1{
  color: #f5df4d;
}

.privacy-banner-check{
  line-height: 18px;
  padding-left: 10px;
}


@media screen and (min-width: 600px) {
  .privacy-banner {
    margin: 0 0 2rem 2rem;
    width: 435px;
  }
}



/* Privacy Settings Overlay */

.privacy-overlay{
  z-index: 2;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: rgba(0,0,0, 0.80);
}

.privacy-controls {
  background: white;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  margin: 3rem 5%;
  border-radius: 10px;
  padding: 3rem;
}

.privacy-container {
  padding-left: 1rem;
  max-height: 90%;
  overflow-y: auto;
}

.privacy-controls-entry{
  padding: 1rem 0;
}

.privacy-controls-entry-title  {
  font-size: 18px;
  font-weight: bold;
  padding-bottom: 1rem;
  border: none;
  background-color: inherit;
  cursor: pointer;
}

.drop-menu-closed::before{
  border-color: black;
  top: -.35rem;
  transform: rotate(-225deg);
  border-style: solid;
  border-width: .2rem .2rem 0 0;
  content: "";
  display: inline-block;
  width: 1.1rem;
  height: 1.1rem;
  left: 0;
  margin-right: 1.8rem;
  position: relative;
}

.drop-menu-open::before{
  border-color: black;
  top: 0rem;
  transform: rotate(315deg);
  border-style: solid;
  border-width: .2rem .2rem 0 0;
  content: "";
  display: inline-block;
  width: 1.1rem;
  height: 1.1rem;
  left: 0;
  margin-right: 1.8rem;
  position: relative;
}

.privacy-controls-consent{
  background: linear-gradient(rgba(255,255,255,0), rgba(255,255,255,1), rgba(255,255,255,1));
  z-index: 2;
  height: 180px;
  width: 100%;
  position: absolute;
  bottom: 0;
  padding: 0 10rem;
  margin: 0 -3rem;
  display: flex;
  flex-direction: column-reverse;

}



/* Toggle Buttons */

:root {
  --toggle-width: 50px;
}

.toggle-container {
  width: var(--toggle-width);
  display: flex;
  align-items: center;
  justify-content: center;
}

.toggle-cookies {
  margin: 0 50px 25px 0;
}

.toggle-input{
  display: none;
}

.toggle, .toggle-on, .toggle-off {
  width: var(--toggle-width);
  height: calc( var(--toggle-width) / 2);
  background-color: #d2d2d2;
  border-radius: var(--toggle-width);
  cursor: pointer;
  position: relative;
  transition: 0.2s;
}

.toggle::before, .toggle-on::before, .toggle-off::before{
  position: absolute;
  content: "";
  width: calc(calc( var(--toggle-width) / 2) - calc( var(--toggle-width) / 20));
  height: calc(calc( var(--toggle-width) / 2) - calc( var(--toggle-width) / 20));
  background-color: #fff;
  border-radius: var(--toggle-width);
  margin: calc( var(--toggle-width) / 40);
  transition: 0.2s;
}

input:checked + .toggle, .toggle-on{
  background-color: goldenrod;
}

input:checked + .toggle::before, .toggle-on::before{
  transform: translateX(calc( var(--toggle-width) / 2));
}

.cookie-expand-container div{
  margin: 2rem 1rem 0 1rem;
  padding: 1rem;
  border: 1px gray solid;
  border-radius: .5rem;
}




/* Responsive Screen Breaks */

@media screen and (min-width: 450px) {

  header{
    padding-top: 2rem;
    padding-left: 2.5rem;
    padding-right: 2.5rem;
  }

  .logo-header {
    height: 7rem;
  }

  /* Sections */

  .page-block {
    max-width: 100rem;
    padding: 1rem;
    margin: 0 1rem;
  }

  .book-image{
    width: 90%;
  }

  .catalog-repeater {
    justify-items: left;
  }

  .repeater-tile {
    padding-top: 0;
  }

  .repeater-tile:first-of-type{
    margin: 0;
  }

  /* Footer */

  .footer-link-container{
    padding-left: 0;
    width: 95vw;
    max-width: 75rem;
  }

  .footer-link-title{
    font-size: 2rem;
  }

  .footer-link:link {
    font-size: 1.5rem;
  }

  #watermark{
    height: 120px;
  }

  #footer-logo-container {
    width: 4.75rem;
    height: 6.25rem;
  }

  #footer-logo {
    height: 3.5rem;
  }

  /* Sections */


  .catalog-repeater {
    column-gap: 5rem;
  }

  #more-twl {
    width: 35rem;
  }

  /* Subscribe Page */
  .newsletter {
    height: 70rem;
  }
}


@media screen and (min-width: 900px) {

  /*Nav styles for when displayed on wide screens w/o JavaScript overlay*/

  nav {
    margin: 0;
    top: auto;
    width: auto;
  }

  nav ul {
    flex-direction: row;
  }

  .fa-bars {
    display: none;
  }

  .overlay .closebtn {
    display: none;
  }

  .overlay{
    display: flex;
    justify-content: flex-end;
    position: relative;
    z-index: 0;
    background-color: inherit;
  }

  .overlay a {
    color: var(--main-charcoal);
    text-align: center;
    padding: 1.5rem 1.75rem;
    font-size: 1.75rem;
  }

  /* Blog Element Index Page */

  .blog-preview {
   width: 30%;
   margin: 1rem;
  }

  .blog-preview {
    flex-direction: column;
  }

  .blog-information, .blog-image {
    width: 100%;
  }

  .blog-information {
    padding-left: .5rem;
  }

  .iframe-container iframe {
    top: 5%;
    left: 5%;
    width: 90%;
    height: 90%;
  }

  /* Base Styles */
  .book-information {
    padding-top: 0;
  }

}

/* Class-based Style Stand Ins*/


.center {
  text-align: center;
}

.limit-width{
  max-width: 525px;
}

.indent {
  padding-left: 2rem;
}

.flex {
  display: flex;
  justify-content: space-between;
}

.flex-start{
  display: flex;
  align-items: flex-end;
}

.hide {
  display: none;
}

.show {
  display: inline;
}

.small-text {
  font-size: 1.1rem;
}

.scroll {
  overflow: scroll;
}



/* Accessability */

.sr-only {
  border: 0 !important;
  clip: rect(1px,1px,1px,1px) !important;
  clip-path: inset(50%) !important;
  -webkit-clip-path: inset(50%) !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  white-space: nowrap !important;
  position: absolute !important;
  padding: 0 !important;
  margin: -1px !important;
}

/*Border classes for element visualization during development.*/

.b-red{
  border: 3px solid red;
}
.b-orange{
  border: 3px solid orange;
}
.b-yellow{
  border: 3px solid yellow;
}
.b-green{
  border: 3px solid green;
}
.b-blue{
  border: 3px solid blue;
}
.b-purple{
  border: 3px solid purple;
}

.b-black{
  border: 3px solid black;
}


/* Stored Styles */

/* Dictionary Definition Box */
.definition {
  border: 1px solid gray;
  padding: 1rem;
  font-size: 1.5rem;
  box-shadow: 1px 5px 10px 2px #505050;
  max-width: 670px;
  margin: 0 5%;
}
