/* tabs */
.tab-panels {
  border-top: 1px solid #E6E6E6;
  padding-top: 30px;
}

.tab-panels > [role="tabpanel"] {
  display: none;
}

.tab-panel-header,
.no-result-container {
  margin: 0 0 30px 0;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-direction: column;
}

.tab-panel-header .tab-buttons-button-filter,
.tab-panel-header .download-csv-btn,
.no-result-container .download-csv-btn,
.tab-panel-header .tab-maps-button,
.tab-panel-header .toggle-grid-layout-btn,
.tab-panel-header .toggle-maps-layout-btn,
.no-result-container .tab-maps-button,
.no-result-container .toggle-grid-layout-btn,
.no-result-container .toggle-maps-layout-btn,
.no-result-container .tab-buttons-button-filter {
  margin-right: 0;
  display: none;
}

.tab-panel-header .tab-panel-header-content .pagination {
  padding-right: 4px;
}

.tab-panel-header .tab-panel-header-content {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-direction: row;
  margin-bottom: 10px;
}

.tab-buttons-container {
  float: right;
  display: flex;
  flex-direction: row;
  justify-content: center;
}

.tab-buttons-container .button {
  padding: 8px 15px;
}

.tab-buttons-container a .button {
  padding: 8px 15px;
}

.tab-buttons-button-filter {
  margin-right: 15px;
  position: relative;
}
.tab-buttons-button-filter .icon-fill {
  fill: #000;
}
.tab-buttons-button-filter svg,
.tab-maps-button svg {
  height: 12px;
  padding-right: 0;
  margin-bottom: -1px;
}

.tab-buttons-total-filter-badge {
  padding: 1px;
  background: #EC2024;
  color: white;
  width: 24px;
  height: 24px;
  justify-content: center;
  align-items: center;
  border-radius: 24px;
  display: none;
  position: absolute;
  top: -15px;
  right: -10px;
  margin-left: -15px;
}

/* toggle layout buttons */
.tab-buttons-container .card-layout-btns {
  display: flex;
  flex-direction: row;
  flex-flow: row-reverse;
  margin-top: -4px;
}

.tab-container-input {
  display: none;
}

.tab-container-input[data-local='local'] {
  
}

.tab-container-label, .tab-container-label--collections {
  padding: .5rem;
  display: inline-block;
  text-decoration: none;
  border-bottom: 4px solid transparent;
  cursor: pointer;
  font-weight: 600;
}

.tab-container-item-divider {
  display: none;
}

.tab-container-label:hover,
.tab-container-label--collections:hover,
.tab-container-label--collections:active,
.tab-container-input:checked + .tab-container-label {
  border-bottom: 4px solid #ec2024;
}

.tab-container .tab-panels .tab-all,
.tab-container .tab-panels .tab-cases,
.tab-container .tab-panels .tab-methods,
.tab-container .tab-panels .tab-organizations,
.tab-container .tab-panels .tab-contributions,
.tab-container .tab-panels .tab-bookmarks,
.tab-container .tab-panels .tab-drafts,
.tab-container .tab-panels .tab-collections,
.tab-container .tab-panels .tab-review-new,
.tab-container .tab-panels .tab-review-edits {
  display: block;
}

.tab-select-container {
  display: none;
}
.draft-container {
  margin-top: 60px;
  margin-bottom: 60px;
}

 /* cards and card layout */
 .cards-container {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr;
  column-gap: 30px;
  grid-column-gap: 30px;
}

.cards-container-draft {
  display: list-item;
}

.article-card .article-card-draft{
  margin-bottom: 30px;
  overflow: hidden;
}

.article-card a {
  text-decoration: none;
}

.article-draft-content {
  display: flex;
  flex-direction: row;
}

.article-card-img {
  width: 100%;
  height: 200px;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
}

.article-card-img-draft {
  width: 200px;
  height: 200px;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
}

.article-card .bookmark-btn {
  align-self: flex-start;
}

.article-card-meta {
  margin-right: 15px;
  flex-basis: 100%;
}

.article-card-meta h5 {
  margin: 0;
  font-weight: normal;
  text-transform: uppercase;
}

.article-card button {
  padding: 0;
}

.article-card-title {
  margin: 0;
}

.article-card .close-card-btn {
  display: none;
}

.article-card-description {
  display: none;
}

.article-card-content {
  margin-top: 15px;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}

.article-card-content-draft {
  margin-top: 15px;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  position: relative;
  margin-left: 20px;
}

.article-card-draft-updated {
  width: 200px;
  position: absolute;
  bottom: 0px;
}

hr.solid {
  height: 0; 
  border: 0; 
  border-top: 1px solid #B6B6B6; 
}

[data-card-layout="list"] .cards-container {
  grid-template-columns: 1fr;
}

[data-card-layout="list"] .cards-container .article-card {
  border-bottom: 1px solid #e6e6e6;
  padding-bottom: 30px;
  display: flex;
}

[data-card-layout="list"] .cards-container .article-card a {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
}

[data-card-layout="list"] .cards-container .article-card-content {
  flex: 1;
  margin-top: 0;
}

[data-card-layout="list"] .cards-container .article-card-img {
  width: 280px;
  margin-right: 30px;
}

[data-card-layout="list"] .cards-container .article-card-description {
  display: block;
}

[data-card-layout="list"] .cards-container .article-card-meta {
  margin-top: 0;
}

[data-card-layout="list"] .cards-container .article-card-title,
[data-card-layout="list"] .cards-container .article-card-description {
  margin-right: 30px;
}

[data-card-layout="maps"] .cards-container {
  display: none;
}

[data-card-layout="list"] .search-map-block {
  display: none;
}

[data-card-layout="list"] .search-map-container-block {
  display: none;
}

[data-card-layout="grid"] .search-map-block {
  display: none !important;
}

[data-card-layout="grid"] .search-map-container-block {
  display: none;
}

[data-card-layout="null"] .search-map-container-block {
  display: none;
}

/* PopOver on map */
.pop-over .article-card {
  background-color: #fff;
  padding: 15px;
  height: 300px;
  width: 300px;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.pop-over .article-card-img {
  width: 100%;
  height: 125px;
}

.pop-over .close-card-btn {
  display: block;
  align-self: flex-end;
}

.pop-over .bookmark-btn {
  display: none;
}

.pop-over .article-card-meta .small {
  margin-bottom: 0;
}
.toggle-grid-layout-btn, .toggle-grid-layout-btn {
  padding: 0;
}

[data-card-layout="grid"] .toggle-grid-layout-btn .icon-fill {
  fill: #EC2024;
}
[data-card-layout="grid"] .toggle-list-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="grid"] .toggle-maps-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="list"] .toggle-grid-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="list"] .toggle-maps-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="list"] .toggle-list-layout-btn .icon-fill {
  fill: #EC2024;
}
[data-card-layout="maps"] .toggle-grid-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="maps"] .toggle-list-layout-btn .icon-fill {
  fill: #B3B3B3;
}
[data-card-layout="maps"] .toggle-maps-layout-btn .icon-fill {
  fill: #EC2024;
}

[data-card-layout="maps"] .tab-container .js-tab-items .tab-collections {
  display: none;
}
[data-card-layout="maps"] .tab-container .js-tab-items .tab-method {
  display: none;
}
[data-card-layout="grid"] .tab-container .js-tab-items .tab-collections {
  display: inline block;
}
[data-card-layout="grid"] .tab-container .js-tab-items .tab-method {
  display: inline block;
}
[data-card-layout="list"] .tab-container .js-tab-items .tab-collections {
  display: inline block;
}
[data-card-layout="list"] .tab-container .js-tab-items .tab-method {
  display: inline block;
}

[data-card-layout="maps"] .tab-select-container .select-collections {
  display: none;
}
[data-card-layout="maps"] .tab-select-container .select-method {
  display: none;
}
[data-card-layout="grid"] .tab-select-container .select-collections {
  display: inline block;
}
[data-card-layout="grid"] .tab-select-container .select-method {
  display: inline block;
}
[data-card-layout="list"] .tab-select-container .select-collections {
  display: inline block;
}
[data-card-layout="list"] .tab-select-container .select-method {
  display: inline block;
}

[data-card-layout="maps"] .tab-container .tab-panels div .pagination .pagination-nav {
  display: none;
}
[data-card-layout="maps"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-string {
  display: none;
}
[data-card-layout="grid"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-string {
  display: block;
}
[data-card-layout="list"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-string {
  display: block;
}

[data-card-layout="maps"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-maps {
  display: block;
}
[data-card-layout="grid"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-maps {
  display: none;
}
[data-card-layout="list"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-maps {
  display: none;
}
[data-card-layout="null"] .tab-container .tab-panels .tab-panel-header .tab-panel-header-content .pagination .pagination-maps {
  display: none;
}

.download-csv-btn {
  margin-right: 15px;
}

.tab-maps-button {
  margin-right: 30px;
  position: relative;
}

.tab-maps-button a {
  text-decoration: none;
}

.download-csv-btn .icon-fill,
.tab-maps-button .icon-fill {
  fill: #000;
}

/* pagination */
.pagination {
  display: flex;
  flex-direction: row;
}

.pagination.tab {
  justify-content: center;
}

.pagination-nav {
  display: flex;
  flex-direction: row;
}

.pagination-nav li {
  margin: 7px;
}

.pagination-nav li .icon-only,
.pagination-nav li .page-number.active {
  border-radius: 50%;
}

.pagination-nav li .icon-only {
  box-shadow: 0px 2px 4px #d5d5d5;
  padding: 12px 14px;
}

.pagination-nav li .page-number {
  display: flex;
  font-weight: bold;
  padding: 8px;
  text-decoration: none;
}

.pagination-nav li .page-number.hellip {
  line-height: 1;
}

.pagination-nav li .page-number.active {
  padding: 1px;
  background: #2C2C2C;
  color: white;
  min-width: 35px;
  height: 35px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.pagination-nav li .icon-only .icon-fill {
  fill: #2C2C2C;
}

.pagination-nav li:last-child {
  margin-right: 0;
}

/* button with dropdown menu */
.dropdown-button-container {
  position: relative;
}

.dropdown-button-container .dropdown-button-items {
  opacity: 0;
  z-index: -10;
  position: absolute;
  left: -120px;
  background-color: #fff;
  box-shadow: 0 0 5px 0 rgba(0, 0, 0, 0.1);
  width: 200px;
  display: flex;
  flex-direction: column;
  padding: 25px;
}

.dropdown-button-container .dropdown-button-items a {
  justify-content: flex-start;
  text-decoration: none;
  display: block;
  margin-bottom: 15px;
}

.dropdown-button-container .dropdown-button-items a:last-of-type {
  margin-bottom: 0;
}

.dropdown-button-container .dropdown-button-items a:hover {
  color: #808080;
}

@media (max-width: 1000px) {
  .cards-container {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

@media (max-width: 850px) {
  .cards-container {
    grid-template-columns: 1fr 1fr;
  }

  .tab-buttons-container .tab-buttons-button-filter {
    padding-left: 15px;
    padding-right: 15px;
  }
  .tab-buttons-container .card-layout-btns {
    width: auto;
  }
}

@media (max-width: 650px) {
  .cards-container {
    grid-template-columns: 1fr;
  }

  /* hide toggle layout button */
  .tab-buttons-container {
    display: none;
  }

  .toggle-maps-layout-btn {
    padding: 8px;
    position: relative;
    right: -40px;
  }

  .tab-buttons-button-filter {
    right: -60px;
  }

  /* change tabs to select dropdown */
  .tab-select-container {
    display: block;
  }
  .tab-container-label, .tab-container-item-divider--collections, .tab-container-label--collections {
    display: none;
  }

  .tab-panels {
    margin-top: 30px;
  }

  .tab-panel-header .tab-buttons-button-filter,
  .tab-panel-header .download-csv-btn,
  .tab-panel-header .toggle-maps-layout-btn,
  .tab-panel-header .toggle-grid-layout-btn,
  .no-result-container .download-csv-btn,
  .tab-panel-header .tab-maps-button,
  .no-result-container .tab-maps-button,
  .no-result-container .toggle-maps-layout-btn,
  .no-result-container .toggle-grid-layout-btn,
  .no-result-container .tab-buttons-button-filter {
    display: block;
    padding: 8px 10px;
  }
}

@media (max-width: 580px) {
  .pagination-nav {
    margin-top: 16px;
  }
}

@media (max-width: 400px) {
  .pop-over .article-card {
    width: 230px;
  }

  .pop-over .article-card h3 {
    font-size: 16px;
  }
}
