

.reloading-recipes {
  border: 1px solid #666;
  padding: 30px;
  border-radius: 10px;
  background: #f1f1ff;
  text-align: center;
}

.recipe-card {

  border: 1px solid #ddd;
  border-radius: 5px;
  box-shadow: #ddd 5px 5px 20px;
  display: block;
  padding: 15px;
  margin: 20px 0px;
  
  h3 {
  	margin-bottom: 15px; 
  } 
  
  h4 {
  	margin-top: 10px;
  	margin-bottom: 10px;
  }
  
  ul, ol {
    margin: 10px 20px !important;
  }

  .row.header {
   
    display: flex;
    flex-direction: row;
    
    .block {
      padding: 10px;
      
      &.content {
        flex-basis: 50%;
        order: 1;
      }
      
      &.image {
        flex-basis: 50%;
        order: 2;
      }
    }
    
    
  }
  
  .share-buttons {
    text-align: center;
    margin: 20px 0px 20px;
    display: flex;
    justify-content: center;
    flex-flow: row wrap;
  }

  .share-button {
    padding: 10px 20px !important;
    border: 1px solid #000;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    color: #000;
    background: #fff;
    margin: 10px;
  }

  .share-button.facebook:hover {
    color: #fff !important;
    background: #4267b2;
    border-color: #4267b2;
  }

  .share-button.pinterest:hover {
    color: #fff !important;
    background: #c8232c;
    border-color: #c8232c;
    cursor: pointer;
  }

  .share-button.print:hover {
    color: #fff !important;
    background: #000;
    cursor: pointer;
  }
  
  .share-button.twitter:hover {
    color: #fff !important;
    background: #1EA1F3;
    border-color: #1EA1F3;
    cursor: pointer;
  }

  .ingred-instruction-tabs {
    display: none;
    padding: 10px;
  }
  
  .ingred-instruction-row {
  	display: flex;
    flex-direction: row;
    
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    
    .block {
      padding: 10px;

      &.ingredients {
        flex-basis: 36%; 
      }

      &.instructions {
        flex-basis: 63%; 
      }

    }
  }
  
  .nutrition-notes-row {
  	display: flex;
    flex-direction: row;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    
    .block {
      padding: 10px;

      &.nutrition {
        padding-right: 30px;
      }

      &.instructions {
        flex-grow: 4;
      }
    }

    .block.nutrition {

      th, td {
        border: none;
      }
  
      .performance-facts {
        border: 1px solid black;
        margin: 0px;
        max-width: 320px;
      width: 320px;
        padding: 0.5rem;
        table {
          border-collapse: collapse;
        }
      }
      .performance-facts__title {
        font-weight: bold;
        font-size: 2rem;
        margin: 0 0 0.25rem 0;
      }
      .performance-facts__header {
        border-bottom: 10px solid black;
        padding: 0 0 0.25rem 0;
        margin: 0 0 0.5rem 0;
        p {
          margin: 0;
        }
      }
      .performance-facts__table {
        width: 100%;
        thead tr {
          th, td {
            border: 0;
          }
        }
        th, td {
          font-weight: normal;
          text-align: left;
          padding: 0.25rem 0;
          border-top: 1px solid black; 
          white-space: nowrap;
        }
        
        .secondary th {
          padding-left: 5%;
        }	
        
        td {
          &:last-child {
            text-align: right;
          }
        }
        .blank-cell {
          width: 10px;
          border-top: 0;
        }
        .thick-row {
          th, td {
            border-top-width: 5px;
          }
        }
      }
      .small-info {
        font-size: 0.7rem;
      }
  
      .performance-facts__table--small {
        @extend .performance-facts__table;
        border-bottom: 1px solid #999;
        margin: 0 0 0.5rem 0;
        thead {
          tr {
            border-bottom: 1px solid black; 
          }
        }
        td {
          &:last-child {
            text-align: left;
          }
        }
        th, td {
          border: 0;
          padding: 0;
        }
      }
  
      .performance-facts__table--grid {
        @extend .performance-facts__table;
        margin: 0 0 0.5rem 0;
        td {
          &:last-child {
            text-align: left;
            &::before {
              content: "•";
              font-weight: bold;
              margin: 0 0.25rem 0 0;
            }
          }
        }
      }
  
      .text-center {
        text-align: center;
      }
      .thick-end {
        border-bottom: 10px solid black;
      }
      .thin-end {
        border-bottom: 1px solid black;
      }
  
    }
  }
  
}


@media screen and (max-width: 768px) {
  
  .recipe-card {
    
    border: 1px solid #ddd;
    border-radius: 5px;
    box-shadow: #ddd 3px 3px 10px;
    display: block;
    padding: 10px;
    margin: 10px 0px;
    
    .row.header {
   
      display: flex;
      flex-direction: row;
      flex-wrap: wrap;

      .block {
        padding: 5px;

        &.content {
          flex-basis: 100%;
          order: 2;
        }

        &.image {
          flex-basis: 100%;
          order: 1;
          margin-bottom: 10px;
        }
      }


    }
    
    .ingred-instruction-tabs {
      display: flex;
      flex-direction: row;
      margin-top: 20px;
      padding: 0px;
      border-top: 1px solid #ddd;
      
      .block {
        flex-basis: 50%; 

        h3 {
          padding: 20px;
          padding-bottom: 5px;
          margin: 0px;
          margin-bottom: 15px;
        }

        div.active h3 {
          border-bottom: 3px solid #ddd;
        }
      }
    }
    
    .ingred-instruction-row {
      display: flex;
      flex-direction: row;
      flex-wrap: wrap;

      margin-top: 0px;
      padding-top: 0px;
      border-top: none;

      .block {
        padding: 10px;

        &.ingredients {
          flex-basis: 100%;
          
        }

        &.instructions {
          flex-basis: 100%;
          display: none;
        }

      }

      h3.title {
        display: none; 
      }

    }
  
  .nutrition-notes-row {
  	display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    
    .block {
      padding: 10px;

      &.nutrition {
        padding-right: 10px;
        margin-bottom: 20px;
        max-width: 100%;
      }

      &.instructions {
        flex-grow: 4;

      }

    }

    .block.nutrition {

      .performance-facts {
        border: 1px solid black;
        margin: 0px;
        max-width: 100%;
        width: 100%;
        padding: 0.5rem;
        table {
          border-collapse: collapse;
        }
      }
      .performance-facts__title {
        font-weight: bold;
        font-size: 2rem;
        margin: 0 0 0.25rem 0;
      }
      .performance-facts__header {
        border-bottom: 10px solid black;
        padding: 0 0 0.25rem 0;
        margin: 0 0 0.5rem 0;
        p {
          margin: 0;
        }
      }
      .performance-facts__table {
        width: 100%;
        thead tr, th, td {
          border: none;
          th, td {
            border: none;
          }
        }
        
        th, td {
          font-weight: normal;
          text-align: left;
          padding: 0.25rem 0;
          border-top: 1px solid black; 
          white-space: nowrap;
        }
        
        .secondary th {
          padding-left: 5%;
        }	
        
        td {
          &:last-child {
            text-align: right;
          }
        }
        .blank-cell {
          width: 10px;
          border-top: 0;
        }
        .thick-row {
          th, td {
            border-top-width: 5px;
          }
        }
      }
      .small-info {
        font-size: 0.7rem;
      }
  
      .performance-facts__table--small {
        @extend .performance-facts__table;
        border-bottom: 1px solid #999;
        margin: 0 0 0.5rem 0;
        thead {
          tr {
            border-bottom: 1px solid black; 
          }
        }
        td {
          &:last-child {
            text-align: left;
          }
        }
        th, td {
          border: 0;
          padding: 0;
        }
      }
  
      .performance-facts__table--grid {
        @extend .performance-facts__table;
        margin: 0 0 0.5rem 0;
        td {
          &:last-child {
            text-align: left;
            &::before {
              content: "•";
              font-weight: bold;
              margin: 0 0.25rem 0 0;
            }
          }
        }
      }
  
      .text-center {
        text-align: center;
      }
      .thick-end {
        border-bottom: 10px solid black;
      }
      .thin-end {
        border-bottom: 1px solid black;
      }
  
    }
  }
  
    
  }
  
}

@media print {
  
  @page { margin: 0; }
  body { margin: 0.5cm; }
 
  #shopify-section-header, #shopify-section-footer, #preview-bar-iframe, .ingred-instruction-tabs, .share-buttons, .hide-print {
    display: none !important; 
  }
  
  .pagebreakbefore {
    page-break-before: always;
    padding-top: 1cm;
  }
  
  .small-up--one-half {
   width: 45%; 
  }
  
  .print-logo {
    display: block;
    text-align: center;
  }
  
  .avoid-page-break {
    page-break-inside: avoid;
    padding-top: 1cm;
  }
  
  .recipe-card {
    border: none;
    max-width: 100%;
    box-shadow: none;
    display: block;
  }
  
}