/* GAMING CAT home layout */
@scope ([data-public-site]) {
  .top_page {
    width: 100%;
    padding: 30px 0;
}

  .top_page_wrap {
    max-width: 950px;
    margin: auto;
}
@media (max-width: 1200px) {
  .top_page_wrap {
        width: 95%;
    }
}

  .top_search_wrap {
    margin-bottom: 40px;
}

  .top_search_wrap .searchform {
    max-width: 100%;
}

  .top_search_wrap .search-form {
    position: relative;
}

  .top_search_wrap .search-text {
    width: 100%;
    padding: 14px 20px 14px 44px;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 15px;
}

  .top_search_wrap .search-form::before {
    content: "\f002";

  /* fa-search */
    font-family: "Gaming Cat Site Symbols";
    font-weight: 900;
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

  .top_section {
    margin-bottom: 50px;
}

  .top_section_head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

  .top_section_ttl {
    font-size: 20px;
    font-weight: 600;
    padding-left: 10px;
    border-left: 4px solid #337ab7;
}

  .top_section_more {
    font-size: 13px;
    white-space: nowrap;
}

  .top_card_scroll,
.top_card_grid {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
}

  .top_card {
    flex: 0 0 200px;
    width: 200px;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid;
}

  .top_card_link {
    display: block;
    text-decoration: none !important;
}

  .top_card_thumb {
    position: relative;
}

  .top_card_thumb img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

  .top_card_thumb--round {
    padding: 16px 16px 0;
    box-sizing: border-box;
}

  .top_card_thumb--round img,
.top_card_thumb--round .noimage {
    width: 100px;
    height: 100px;
    aspect-ratio: 1 / 1;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto;
}

  .top_card_badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background-color: #337ab7;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 4px;
}

  .top_card_body {
    padding: 10px;
}

  .top_card_ttl {
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

  .top_category_grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

  .top_category_card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px;
    border-radius: 10px;
    border: 1px solid;
    text-decoration: none !important;
}

  .top_category_icon {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 18px;
}

  .top_category_body {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
}

  .top_category_name {
    font-size: 15px;
    font-weight: 600;
}

  .top_category_desc {
    font-size: 12px;
    margin-top: 4px;
}

  .top_category_arrow {
    flex: 0 0 auto;
}

  :where(:scope):is([data-site-theme="dark"],.dark-theme:where(:not([data-site-theme]))) .top_search_wrap .search-text {
    background-color: #2E2E2E;
    border: 1px solid #3F3F3F;
    color: #e8e8e8;
}
@media (prefers-color-scheme: dark) {
  :where(:scope)[data-site-theme="system"] .top_search_wrap .search-text {
    background-color: #2E2E2E;
    border: 1px solid #3F3F3F;
    color: #e8e8e8;
}
}

  :where(:scope):is([data-site-theme="dark"],.dark-theme:where(:not([data-site-theme]))) .top_card {
    background-color: #2E2E2E;
    border-color: #3F3F3F;
}
@media (prefers-color-scheme: dark) {
  :where(:scope)[data-site-theme="system"] .top_card {
    background-color: #2E2E2E;
    border-color: #3F3F3F;
}
}

  :where(:scope):is([data-site-theme="dark"],.dark-theme:where(:not([data-site-theme]))) .top_category_card {
    background-color: #2E2E2E;
    border-color: #3F3F3F;
}
@media (prefers-color-scheme: dark) {
  :where(:scope)[data-site-theme="system"] .top_category_card {
    background-color: #2E2E2E;
    border-color: #3F3F3F;
}
}

  :where(:scope):is([data-site-theme="dark"],.dark-theme:where(:not([data-site-theme]))) .top_category_icon {
    background-color: #3F3F3F;
    color: #e8e8e8;
}
@media (prefers-color-scheme: dark) {
  :where(:scope)[data-site-theme="system"] .top_category_icon {
    background-color: #3F3F3F;
    color: #e8e8e8;
}
}

  :where(:scope):is([data-site-theme="light"],.white-theme:where(:not([data-site-theme]))) .top_search_wrap .search-text {
    background-color: #F8F8F8;
    border: 1px solid #E8E8E8;
    color: #333;
}
@media (prefers-color-scheme: light) {
  :where(:scope)[data-site-theme="system"] .top_search_wrap .search-text {
    background-color: #F8F8F8;
    border: 1px solid #E8E8E8;
    color: #333;
}
}

  :where(:scope):is([data-site-theme="light"],.white-theme:where(:not([data-site-theme]))) .top_card {
    background-color: #F8F8F8;
    border-color: #E8E8E8;
}
@media (prefers-color-scheme: light) {
  :where(:scope)[data-site-theme="system"] .top_card {
    background-color: #F8F8F8;
    border-color: #E8E8E8;
}
}

  :where(:scope):is([data-site-theme="light"],.white-theme:where(:not([data-site-theme]))) .top_category_card {
    background-color: #F8F8F8;
    border-color: #E8E8E8;
}
@media (prefers-color-scheme: light) {
  :where(:scope)[data-site-theme="system"] .top_category_card {
    background-color: #F8F8F8;
    border-color: #E8E8E8;
}
}

  :where(:scope):is([data-site-theme="light"],.white-theme:where(:not([data-site-theme]))) .top_category_icon {
    background-color: #F0F0F0;
    color: #333;
}
@media (prefers-color-scheme: light) {
  :where(:scope)[data-site-theme="system"] .top_category_icon {
    background-color: #F0F0F0;
    color: #333;
}
}
@media (max-width: 768px) {
  .top_page {

        /* ヘッダーがposition: fixedになるため、既存の.main_postと同じ量だけ上に余白を確保し
           検索バーがヘッダーの下に隠れないようにする */
        margin-top: 55px;
        padding: 30px 2.5%;
        box-sizing: border-box;
    }

  .top_page_wrap {
        width: 100%;
    }

  .top_category_grid {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 480px) {
  .top_card {
        flex: 0 0 160px;
        width: 160px;
    }

  .top_category_card {
        padding: 14px;
    }
}

  .top_youtube .top_card_thumb img { display: block; height: auto; object-fit: contain; }

  .top_youtube_noimage { display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 9; }

  .top_youtube .top_card_link:focus-visible { outline: 2px solid currentColor; outline-offset: -3px; }

  :where(:scope):is([data-site-theme="dark"],.dark-theme:where(:not([data-site-theme]))) .top_youtube .top_card_thumb { background: #27272A; color: #e8e8e8; }
@media (prefers-color-scheme: dark) {
  :where(:scope)[data-site-theme="system"] .top_youtube .top_card_thumb { background: #27272A; color: #e8e8e8; }
}

  :where(:scope):is([data-site-theme="light"],.white-theme:where(:not([data-site-theme]))) .top_youtube .top_card_thumb { background: #F8F8F8; color: #333; }
@media (prefers-color-scheme: light) {
  :where(:scope)[data-site-theme="system"] .top_youtube .top_card_thumb { background: #F8F8F8; color: #333; }
}

  .top_youtube_play { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: grid; place-items: center; width: 52px; height: 36px; border-radius: 10px; background: #d90000; color: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.3); pointer-events: none; }

  .top_youtube_play::before { content: ""; display: block; width: 0; height: 0; border-top: 8px solid transparent; border-bottom: 8px solid transparent; border-left: 13px solid currentColor; margin-left: 3px; }

  .top_youtube .top_card_link:hover .top_youtube_play,
.top_youtube .top_card_link:focus-visible .top_youtube_play { background: #b80000; }

  .top_youtube .top_section_head { flex-wrap: wrap; gap: 8px 16px; }

  .top_youtube .top_section_ttl { margin-right: 0; }
}
