/*
  Theme Name:   GeneratePress Child
  Theme URI:    https://generatepress.com
  Description:  GeneratePress の子テーマ（genome-portal 用カスタム）
  Author:       genome-portal
  Author URI:   https://generatepress.com
  Template:     generatepress
  Version:      1.0.0
  License:      GNU General Public License v2 or later
  License URI:  http://www.gnu.org/licenses/gpl-2.0.html
  Text Domain:  generatepress-child
*/

/* 全体のcss */

body {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 100vh;
}

.page-title {
  font-size: 36px;
  margin-bottom: 20px;
  line-height: 1.2em;
  font-weight: 400;
}

.wp-block-list {
  margin: 0 0 1.5em 2em;
}

.wp-block-genome-portal-download {
  margin: 0;
}
.wp-block-genome-portal-download li {
  list-style: none;
}

.wp-block-table.is-style-stripes {
  border-bottom: 0 !important;
}
.post a {
  color: #915ff0 !important;
  text-decoration: none;
}

.post a:hover {
  color: #915ff0 !important;
  text-decoration: underline;
}
.post a[target="_blank"] {
  position: relative;
  width: fit-content;
}

.post a[target="_blank"]::after {
  content: "↗";
  display: inline-block;
  margin-left: 0.25em;
  font-size: 0.85em;
  line-height: 1;
}

.post .wp-block-heading {
  margin-top: 32px;
  font-size: 28px;
}

.grid-container {
  width: 100% !important;
}

/* ヘッダー */
.site-header {
  position: fixed;
  width: 100%;
  top: 0;
  left: 0;
}

/* フッター */
.inside-site-info {
  padding: 50px 40px;
}
/* メインコンテンツ */
.separate-containers .site-main {
  margin: 60px 0;
}

.page_item {
  display: none;
}

/* ヘッダー内レイアウト */
.inside-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1em;
  padding: 20px;
}

.header_search {
  margin-left: auto;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

/* サイトブランディング：リンクリスト */
.header_links {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0;
}

.header_links a {
  font-size: 16px;
  margin-bottom: 0;
}

.header_links h1 {
  font-size: 16px;
  margin-bottom: 0;
}

.header_links li {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
}

.header_links li + li {
  border-left: 1px solid var(--contrast, #222);
  padding-left: 0.75em;
  margin-left: 0.75em;
}

.header_links a {
  color: var(--contrast, #222);
  text-decoration: none;
}

.header_links a:hover {
  color: var(--contrast, #222);
  text-decoration: underline;
}

.header_search form {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 0.35em;
  font-size: 16px;
}

.header_search_text {
  display: block;
  margin-bottom: 5px;
  padding-left: 5px;
  font-size: 12px;
}

/* クエリーループのスタイル */
.gb-loop-item:nth-of-type(even),
.search_table-row:nth-of-type(even) {
  background-color: #f7f7f7;
}

.gb-loop-item .gb-text:empty,
.gb-loop-item p:empty {
  display: none;
}

.strainsTable p,
.search_table-wrapper p {
  margin-bottom: 0;
}

.strainsTable a,
.search_table-wrapper a {
  overflow-wrap: anywhere;
}

.strainsTable .gb-loop-item:not(:last-of-type) .gb-text,
.search_table-row:not(:last-of-type) .search_table-cell {
  border-bottom: 0;
}

/* 検索結果のテーブルスタイル */
.search_table {
  width: 100%;
  margin-bottom: 0;
  border-collapse: collapse;
  table-layout: fixed;
}

.search_table-head-cell,
.search_table-cell {
  width: 25%;
  padding: 10px;
  vertical-align: middle;
}

.search_table-cell a {
  color: #915ff0;
}

.search_table-head-cell {
  height: 50px;
  text-align: center;
  border: 0;
  font-size: 16px;
}

.search_table-row {
  height: 75px;
}

.search_table-head {
  background-color: #915ff0;
  color: #fff;
  font-weight: 700;
}

.search_table-row + .search_table-row .search_table-cell {
  border-top: 1px solid #e0e0e0;
}

.entry-title {
  font-size: 36px;
  font-weight: 500;
}

/* フッター */
.footer-bar .gb-text {
  margin-bottom: 0;
}

.footer-bar a {
  color: #915ff0;
}

/* シングル投稿のフッターメタ（カテゴリー・タグ・前後ナビ）は非表示 */
.single footer.entry-meta {
  display: none;
}

.copyright-bar {
  display: none;
}

/* SP用のスタイル */
@media (max-width: 767px) {
  .header_links,
  .header_links a {
    font-size: 14px;
  }

  .search_table-head-cell,
  .search_table-cell {
    font-size: 14px;
  }

  .inside-header .header_search {
    position: fixed;
    top: 100px;
    right: 0;
    width: 100%;
    padding: 16px;
    box-sizing: border-box;
    background-color: #fff;
    border-bottom: 1px solid #e0e0e0;
    transform: translateX(100%);
    transition: none;
    z-index: 1000;
  }

  .inside-header .header_search.is-open {
    transform: translateX(0);
  }

  /* クリック時だけトランジションを付与 */
  .inside-header .header_search.is-animating {
    transition: transform 0.25s ease-out;
  }

  .inside-header .header_search form {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 0.5em;
  }

  .inside-header .header_search form label {
    width: 100%;
  }

  .inside-header .header_search form input {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .inside-header .header_search form button {
    width: 100%;
  }
}

/* 検索結果ページネーション（BEM: search_pagination） */
.search_pagination {
  align-items: center;
  column-gap: 10px;
  display: flex;
  justify-content: center;
  margin-top: 20px;
  row-gap: 10px;
}

.search_pagination_link,
.search_pagination_link:link,
.search_pagination_link:visited,
.search_pagination_link:hover,
.search_pagination_link:focus {
  color: #000000 !important;
  text-decoration: none !important;
}

.search_pagination_link {
  background-color: #ffffff;
  border: 1px solid #000;
  display: inline-flex;
  font-size: 14px;
  line-height: 1;
  padding: 1rem;
  text-decoration: none;
}

.search_pagination_numbers {
  align-items: center;
  column-gap: 5px;
  display: flex;
  justify-content: center;
  row-gap: 5px;
}

.search_pagination_numbers .page-numbers {
  background-color: #ffffff;
  border: 1px solid #000;
  color: #000000;
  display: inline-flex;
  font-size: 14px;
  line-height: 1;
  padding: 1rem;
  text-decoration: none !important;
}

.search_pagination_numbers .page-numbers:link,
.search_pagination_numbers .page-numbers:visited,
.search_pagination_numbers .page-numbers:hover,
.search_pagination_numbers .page-numbers:focus,
.search_pagination_numbers .page-numbers.current {
  color: #000000;
}

.search_pagination_numbers .page-numbers.current,
.search_pagination_numbers .page-numbers.dots {
  border-bottom-width: 0;
  border-left-width: 0;
  border-right-width: 0;
  border-top-width: 0;
}

/* ページネーション: 768px以下では先頭・現在・末尾のみ表示（…は非表示） */
@media (max-width: 768px) {
  .gb-query-page-numbers-4c28435b
    a.page-numbers:not(:first-of-type):not(:last-of-type),
  .search_pagination_numbers
    a.page-numbers:not(:first-of-type):not(:last-of-type) {
    display: none;
  }
  .gb-query-page-numbers-4c28435b .page-numbers.dots,
  .search_pagination_numbers .page-numbers.dots {
    display: none;
  }
}

.tableButton a {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.tableButton a:after {
  display: none !important;
}

.tableButton a svg {
  fill: #915ff0;
}
