.legacy-overrides a:not(.button):not(.toggle):not(.nochildren):not(.current):not(.deepLevelDivider) {
  color: #0d7a9e;
  text-decoration: none;
}

.legacy-overrides a:hover:not(.button):not(.toggle):not(.nochildren):not(.current):not(.deepLevelDivider) {
  color: #176b87;
  text-decoration: none;
}

.horizontal-gradient {
  background: none;
  border: none;
}
hgroup.horizontal-gradient {
  background: none;
  border: none;
}

.legacy-overrides aside nav li {
  margin-left: 0 !important;
}

.legacy-overrides .alert-box {
  min-height: 65px;
}
.legacy-overrides .alert-box .alert-box__icon {
  width: auto;
  padding: 14px; /* new base font is 16px, so 1em made it too big */
}
.legacy-overrides .alert-box .alert-box__content {
  padding: 1em 1.2em 0 1em;
  max-width: 100%;
}
.legacy-overrides .alert-box .alert-box__content p {
  margin-bottom: 1em;
}

@media screen and (max-width: 767px) {
  /* give some spacing to table rows so data is readable in mobile */
  .legacy-overrides table tr {
    border: 1px dotted #dadada;
    padding: 0.5em;
    margin-bottom: 0.5em;
  }
}

/* pagerows template */
#aafp-body.template-pagerows .legacy-overrides #main {
  display: block;
}

/**************************************************
These are for the blog pages 
*/

#aafp-body.template-bloglandingpage .blogbannerimage {
  padding-top: 0px;
}

#aafp-body.template-bloglandingpage .legacy-overrides {
  padding: 1em 0;
}
#aafp-body.template-bloglandingpage #main {
  margin: 0 auto;
}
#aafp-body.template-blogarticle p.pagination {
  text-align: center;
}
#aafp-body.template-bloglandingpage section#content .news article a {
  margin-bottom: 0;
}

@media screen and (max-width: 767px) {
  /* remove padding/margin from left/right so width can be 100% */
  #aafp-body section h1,
  #aafp-body section h1.secondary,
  #aafp-body section h2,
  #aafp-body section h2.secondary,
  #aafp-body section h3,
  #aafp-body section h3.secondary,
  #aafp-body section h4,
  #aafp-body section h4.secondary,
  #aafp-body section h5,
  #aafp-body section h5.secondary,
  #aafp-body section h6,
  #aafp-body section h6.secondary,
  #aafp-body section p {
    margin-left: 0px;
    margin-right: 0px;
    padding-left: 0px;
    padding-right: 0px;
  }
  #aafp-body.template-bloglandingpage .legacy-overrides {
    padding: 1em 1.5em;
  }
  #aafp-body div.images .image-wrapper {
    padding: 0px;
    margin: 0px;
  }
  #aafp-body div.images .image-wrapper.right {
    padding-left: 1em;
  }
  #aafp-body div.images .image-wrapper.left {
    padding-right: 1em;
  }
  #aafp-body div.images .image-wrapper .image-container {
    padding: 0;
    margin: 0;
  }
  #aafp-body section#content .container {
    width: 100%;
  }

  #aafp-body section#content .block .title {
    background-position: 94% 50% !important;
  }
  section#content .block .container p.title:after {
    content: '\e5cc';
    font-family: 'Material Icons';
  }
  #aafp-body.template-blogarticle .legacy-overrides {
    padding: 1.5em;
  }
  #aafp-body.template-bloglandingpage #main,
  #aafp-body.template-blogarticle #main {
    width: 100%;
    display: block;
    margin: 0 auto;
    overflow: hidden;
  }
  #aafp-body.template-blogarticle #main #content {
    margin: auto;
  }
  #aafp-body.template-bloglandingpage section#content,
  #aafp-body.template-blogarticle section#content {
    width: 100%;
    display: block;
  }
  #aafp-body.template-bloglandingpage section#content.main-content,
  #aafp-body.template-blogarticle section#content.main-content {
    width: 100%;
    display: block;
  }
}
@media screen and (min-width: 1px) and (max-width: 479px) {
  #aafp-body div.images .image-wrapper {
    display: block;
    float: none;
    margin: 20px auto;
  }
  #aafp-body div.images .image-wrapper .image-container {
    padding: 0;
    margin: 0 auto;
  }
  #aafp-body.template-bloglandingpage #main {
    width: 100%;
  }
  #aafp-body section#content .container {
    width: 100%;
  }
}
/* end template-bloglandingpage */

/***** styles for Physican Health First *****/
#aafp-body #phf-header {
  background-color: #f6f6f6;
}
#aafp-body .phf-banner-buttons .phf-blue.phf-button {
  width: auto;
  min-width: 220px;
  margin-left: 20px;
  margin-right: 20px;
}
#aafp-body .phf-banner-buttons .phf-blue.phf-button:first-of-type {
  margin-left: 0px;
}
#aafp-body .phf-banner-buttons .phf-blue.phf-button:last-of-type {
  margin-right: 0px;
}
#aafp-body .phf-banner-buttons .phf-blue.phf-button .phf-button-title {
  font-size: 24px;
}
#aafp-body .phf-aqua a.phf-blue.phf-button {
  width: 250px;
}
#aafp-body .page-wrap .phf-aqua h4 {
  margin-bottom: 1.4em;
}
@media screen and (max-width: 767px) {
  #aafp-body .phf-banner-buttons {
    padding: 0.5em 0.5em 0 0.5em;
  }
  #aafp-body .phf-banner-buttons .phf-blue.phf-button {
    margin: 0 0 0.5em 0;
    width: 70%;
  }
  #aafp-body .phf-banner-buttons .phf-blue.phf-button .phf-button-title {
    font-size: 21px !important;
  }
}
/***** End styles for Physican Health First *****/

.legacy-overrides .comment-widget {
  font-family: 'Roboto', sans-serif;
  font-size: 16px;
}

.journal-article .comment-widget .form-row {
  margin-bottom: 10px;
}

.journal-article .comment-widget .button.orange:hover,
.journal-article .comment-widget .aafp-button.button-primary:hover {
  background: none;
  background-color: #db9f40 !important;
}

.legacy-overrides .comment-widget .form-row {
  clear: both;
}

.legacy-overrides .comment-widget .aafp-button.button-secondary {
  background: none;
  background-color: #444444 !important;
  color: #fff !important;
  border: none !important;
  text-decoration: none !important;
  margin-top: 0px;
  -webkit-border-radius: 6px;
  -moz-border-radius: 6px;
  border-radius: 6px;
  border: 0 none;
  display: inline-block;
  box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2);
  -moz-box-shadow: -1px 1px 1px rgba(0, 0, 0, 0.2);
  -webkit-box-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2);
  font: normal 15px/16px 'Arial', sans-serif;
  overflow: hidden;
  padding: 6px 15px;
  width: auto;
}

.legacy-overrides .comment-widget .aafp-button.button-secondary:hover {
  background: none;
  background-color: #666666 !important;
  color: #fff !important;
  border: none !important;
  text-decoration: none !important;
}
.legacy-overrides button.aafp-button.button-tertiary {
  box-shadow: none;
  -moz-box-shadow: none;
  -webkit-box-shadow: none;
}
.comment-widget .commentcontainer label.error,
.comment-widget .commentcontainer label-comment.error {
  color: #b65f63 !important;
  padding-bottom: 5px;
  padding-left: 0px;
  background-color: #fff !important;
  border: none !important;
}

.template-blogarticle #main .comment-widget .form-row label.error {
  background-color: #fff !important;
  border: 1px solid #ccc !important;
}

#aafp-body.template-pagerows .legacy-overrides #main {
  display: block;
}

.leaderboardAdRow {
  background-color: #f7f7f7;
  border-color: #f7f7f7;
}
