/* General styles */
#climate-list button, #climate-list nav, #climate-list .navigation {
  font-family: 'Open Sans', sans-serif;
  font-weight: 600;
}

#climate-list .page-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
}

/* Filter Box */
#climate-list .filter-box {
  background-color: #CCDDE9;
  padding: 20px;
  border-radius: 5px;
  margin-bottom: 20px;
  display: flex;
  gap: 20px;
  align-items: flex-end;
  flex-wrap: wrap;
}

#climate-list .filter-box h2 {
  font-size: 18px;
  margin-bottom: 10px;
}

.filter-box .filter-item,
#climate-list .filter-box div.search {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  max-width: 300px;
  min-width: 200px;
}

input[type="text"],
#climate-list select {
  width: 100%;
  padding: 12px;
  font-size: 18px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
}

.filter-box button,
#climate-list .filter-actions button {
  padding: 10px 20px;
  border: none;
  background-color: #005493;
  color: white;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 500;
  font-size: 0.95em;
}

.filter-box button:hover,
#climate-list .filter-actions button:hover {
  background-color: #014477;
}

#climate-list .filter-actions-row {
  width: 100%;
  display: flex;
  justify-content: flex-start;
  margin-top: 10px;
}

#climate-list .filter-actions {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

@media (max-width: 768px) {
#climate-list .filter-box {
    flex-direction: column;
    align-items: stretch;
  }

  .filter-box .filter-item,
#climate-list .filter-actions button {
    width: 100%;
  }
}

/* Table */
#climate-list .table-container {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 1px;
  max-width: 100%;
  box-sizing: border-box;
}

#climate-list table {
  width: 100%;
  min-width: 800px;
  border-collapse: collapse;
}

#climate-list th, #climate-list td {
  padding: 12px;
  text-align: left;
  border: none;
}

/* Header and body row styles */
#climate-list table thead th {
  background-color: #fff;
  color: #000;
  border-top: 1px solid #000;
  border-bottom: 1px solid #000;
  font-weight: 600;
}

#climate-list table tbody tr {
  background-color: #fff;
  border-bottom: 1px solid #e0e0e0;
}

#climate-list table tbody tr:hover {
  background-color: #f9f9f9;
}

#climate-list .details-row td {
    transition: all 0.3s ease-in-out;
  }
  
/* Pagination & Info for Simple-DataTables */
#climate-list .dataTable-pagination .active a {
  background-color: #0055b7;
  color: white;
  border-color: #0055b7;
}

#climate-list .dataTable-pagination a {
  padding: 6px 12px;
  font-size: 18px;
  border: 1px solid #ccc;
  background-color: #f9f9f9;
  border-radius: 4px;
  text-decoration: none;
  color: #0055b7;
}

#climate-list .dataTable-pagination a:hover {
  background-color: #f2f2f2;
  border-color: #bbb;
}

#climate-list .dataTable-info {
  font-size: 18px;
  color: #333;
}

/*length dropdown*/
#climate-list .datatable-dropdown label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 18px;
  }
  
#climate-list .datatable-selector {
    width: 60px;
    text-align: left;
    padding: 6px 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    font-size: 18px;
  }

#climate-list .mobile-pagination-controls {
  margin-bottom: 10px;
  font-size: 0.9rem;
}

#climate-list .mobile-pagination-controls select {
  margin-left: 5px;
  padding: 4px 8px;
}

#climate-list .sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

#climate-list .card-pagination {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  gap: 1em;
  padding: 1em 0;
  max-width: 100%;
}

#climate-list .card-pagination button {
  padding: 0.4em 0.8em;
  font-size: 1rem;
  background-color: #eee;
  border: 1px solid #ccc;
  border-radius: 4px;
  cursor: pointer;
  white-space: nowrap;
}

#climate-list .page-selector-inline {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  min-width: 0;
  flex-grow: 1;
}

#climate-list .page-selector-inline select {
  width: 60px; /* control how wide the dropdown is */
  padding: 4px 8px;
  font-size: 1rem;
  white-space: nowrap;
}

#climate-list #totalPagesLabel {
  min-width: 40px;
  text-align: left;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .datatable-pagination,
  .datatable-info,
#climate-list .datatable-dropdown {
    display: none !important;
  }

#climate-list .card-pagination {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    text-align: center;
    width: 100%;
  }

#climate-list .page-selector-inline {
    margin: 0 auto;
    flex-grow: 0;
  }

#climate-list .page-selector-inline select {
    width: 60px;
  }

}


/* Utility */
#climate-list .truncate-multiline {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  max-height: 3.2em;
  line-height: 1.6em;
  transition: max-height 0.2s ease;
  cursor: help;
}

#climate-list .truncate-expanded {
  -webkit-line-clamp: unset;
  max-height: none;
}

#climate-list .bubbles span {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    margin: 3px 5px 3px 0;
    font-size: 0.85em;
    font-weight: 500;
  }
  
#climate-list .theme-bubbles span {
    background-color:  #002754;
    color: #fff;
  }
  
#climate-list .interest-bubbles span {
    background-color: #BEE7F9;
    color: #000;
  }
#climate-list .card-action-button {
  padding: 8px 16px;
  border: 1px solid #0055b7;
  background-color: transparent;
  color: #0055b7;
  border-radius: 4px;
  font-size: 0.95em;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

#climate-list .card-action-button:hover {
  background-color: #0055b7;
  color: white;
}


/* Modal */
#climate-list .modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0,0,0,0.4);
}

#climate-list .modal-content {
  background-color: #fff;
  margin: 10% auto;
  padding: 20px;
  border-radius: 8px;
  width: 80%;
  max-width: 600px;
  position: relative;
}

#climate-list .modal .close {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 28px;
  font-weight: bold;
  color: #333;
  cursor: pointer;
}

#climate-list .modal .close:hover {
  color: #000;
}

/* Card (mobile) */
#climate-list .card-container {
  display: none;
}

#climate-list #cardPagination {
    display: none;
    justify-content: center;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 10px;
  }
  
#climate-list #cardPagination button {
    padding: 6px 12px;
    font-size: 18px;
    border: 1px solid #ccc;
    background-color: #f9f9f9;
    border-radius: 4px;
    color: #0055b7;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
  }
  
#climate-list #cardPagination button:hover {
    background-color: #f2f2f2;
    border-color: #bbb;
  }
  
#climate-list #cardPagination button.current {
    background-color: #0055b7;
    color: white;
    border-color: #0055b7;
  }
  
#climate-list #cardPagination button:disabled {
    opacity: 0.4;
    cursor: default;
  }
  
#climate-list #cardInfo {
    display: none;
    text-align: left;
    font-size: 18px;
    color: #333;
    margin-top: 10px;
  }
@media (min-width: 769px) {
#climate-list .card-pagination {
    display: none !important;
  }
}

#climate-list .profile-card.no-results {
    text-align: center;
    background-color: #fff8f8;
    border: 1px solid #e0b4b4;
    color: #a94442;
    padding: 24px;
    border-radius: 6px;
}

@media (max-width: 768px) {
#climate-list .table-container {
    display: none;
  }

#climate-list #cardPagination {
    display: flex;
  }

#climate-list #cardInfo.show {
    display: block;
  }

#climate-list .card-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 10px;
  }

#climate-list .profile-card {
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    background-color: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  }

#climate-list .profile-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  }

#climate-list .profile-card h3 {
    margin: 0 0 12px;
    font-size: 1.25em;
    font-weight: 600;
    color: #1a1a1a;
  }

#climate-list .profile-card a {
    color: #0055b7;
    text-decoration: none;
    font-size: 0.95em;
  }

#climate-list .profile-card a:hover {
    text-decoration: underline;
  }

#climate-list .profile-card .section {
    margin-bottom: 12px;
    font-size: 0.95em;
    line-height: 1.5;
  }

#climate-list .profile-card .section strong {
    display: inline-block;
    margin-bottom: 4px;
    font-weight: 500;
  }
}