/* Assessed Genes & Diseases page-specific CSS */

.page {
  width: min(1100px, calc(100% - 40px));
  margin: 0 auto;
  padding: 18px 0 60px;
}

h1 {
  text-align: center;
  color: white;
  font-size: 48px;
  font-weight: bold;
  margin: 5px 0 10px 0;
}

/* Search bar */
.search-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 20px auto;
}

.search-wrapper input[type="text"] {
  height: 42px;
  padding: 0 12px;
  font-size: 16px;
  border: none;
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
  outline: none;
  box-sizing: border-box;
}

.search-button {
  height: 42px;
  padding: 0 16px;
  font-size: 16px;
  background-color: var(--n1c-red);
  color: white;
  border: none;
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
  font-weight: bold;
  cursor: pointer;
  box-sizing: border-box;
}

.search-button:hover {
  background-color: var(--n1c-red-dark);
}

/* Main table */
table {
  width: 90%;
  margin: 20px auto;
  border-collapse: collapse;
  background: white;
  color: black;
  font-size: 14px;
  box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.1);
}

th,
td {
  padding: 12px;
  border: 1px solid #ddd;
  text-align: center;
}

th {
  background-color: var(--n1c-red);
  color: white;
  font-size: 18px;
  position: sticky;
  top: 0;
  z-index: 1;
}

tr:nth-child(even) {
  background: #f9f9f9;
}

tr:hover {
  background: #c7c4bc;
  cursor: pointer;
}

/* Buttons */
button,
.submit-button {
  background-color: var(--n1c-red);
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  text-decoration: none;
}

button:hover,
.submit-button:hover {
  background-color: var(--n1c-red-dark);
}

/* Scroll top */
.scroll-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: var(--n1c-red);
  color: white;
  border: none;
  padding: 10px 14px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.2);
  z-index: 999;
}

.scroll-top:hover {
  background-color: var(--n1c-red-dark);
}

/* Footer */
footer {
  margin-top: 40px;
  text-align: center;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.95rem;
  line-height: 1.6;
}

footer p {
  margin: 6px 0;
}

/* Details / grouped sections */
details summary {
  font-size: 28px;
  font-weight: bold;
  color: var(--n1c-red);
  background-color: white;
  padding: 10px 16px;
  border-radius: 6px;
  cursor: pointer;
  margin: 10px auto;
  border: 1px solid #ccc;
  list-style: none;
  text-align: center;
}

details summary::-webkit-details-marker {
  display: none;
}

details summary:hover {
  background-color: #fde4e2;
  color: var(--n1c-red-dark);
}

details tr {
  transition: background-color 0.2s;
}

details tr:hover {
  background-color: #fde4e2;
  cursor: pointer;
}

details table {
  table-layout: fixed;
  width: 100%;
  border-collapse: collapse;
}

details th,
details td {
  padding: 10px;
  border: 1px solid #ddd;
  text-align: center;
  word-wrap: break-word;
}

/* Column widths for assessed genes & diseases */
details th:nth-child(1),
details td:nth-child(1) {
    width: 5%;   /* Gene */
}

details th:nth-child(2),
details td:nth-child(2) {
    width: 22%;  /* Disease */
}

details th:nth-child(3),
details td:nth-child(3) {
    width: 8%;  /* Eligibility */
}

details th:nth-child(4),
details td:nth-child(4) {
    width: 24%;  /* Recommended Approach */
}

details th:nth-child(5),
details td:nth-child(5) {
    width: 21%;  /* Therapeutic Modality */
}

details th:nth-child(6),
details td:nth-child(6) {
    width: 20%;  /* Therapeutic Status */
}

/* Under construction note */
.construction-note {
  display: inline-block;
  background: rgba(222, 59, 56, 0.12);
  border: 1px solid rgba(222, 59, 56, 0.45);
  color: black;
  padding: 10px 14px;
  border-radius: 10px;
  font-weight: 600;
  margin-bottom: 18px;
}

@media (max-width: 720px) {
  .page {
    width: min(1100px, calc(100% - 24px));
  }

  details summary {
    font-size: 22px;
  }
}

details summary {
    text-align: center;
}

#loading {
  display: block;
  width: 100%;
  text-align: center;
  color: white;
  font-size: 18px;
  margin: 40px 0;
}
