@charset "utf-8";

/* ==========================================================================
    トップページ（index.php）用CSS
    main-header.php / main-footer.php と組み合わせて使う（Bootstrap のグリッドには依存しない）
    レイアウト: 992px〜 2カラム / 768〜991px 1カラム（タブレット）/ 767px以下 1カラム（スマホ）
    目次
    1. 変数・共通
    2. 全体のレイアウト（grid）
    3. スライダー
    4. 検索ブロック
    5. ニュース
    6. サービス一覧
    7. サイドバナー・SP下部バナー
   ========================================================================== */

/* MARK: 1 変数・共通 */
:root {
    /* 検索のエリアボタンの色 */
    --area-hokkaido: rgba(126, 242, 255, 0.6);
    --area-tohoku: rgba(128, 194, 254, 0.6);
    --area-kosinetsu: rgba(127, 255, 207, 0.6);
    --area-kanto: rgba(255, 255, 45, 0.6);
    --area-tokai: rgba(27, 168, 141, 0.6);
    --area-kansai: rgba(255, 158, 129, 0.6);
    --area-hokuriku: rgba(255, 255, 45, 0.6);
    --area-shikoku: rgba(188, 127, 255, 0.6);
    --area-kyusyu: rgba(254, 128, 254, 0.6);
}
.main-index img {
    max-width: 100%;
    height: auto;
    image-rendering: -webkit-optimize-contrast;
    margin: 0 0 15px;
    &.-radius {
        border-radius: 10px;
    }
    &:hover {
        opacity: 0.5;
        cursor: pointer;
        transition: 0.3s ease;
    }
}
.main-index p {
    margin: 0;
}
.main-index a {
    color: inherit;
    text-decoration: none;
}
.main-index h2 {
    margin: 0;
    padding: 5px;
    background-color: var(--site-blue);
    color: white;
    font-size: 20px;
    font-weight: bold;
    line-height: 1.5;
}
.main-index ul {
    margin: 0;
    padding: 0;
    list-style: none;
}
.index-banner {
    margin: 0 auto 15px;
}
.index-banner img {
    display: block;
    width: 100%;
    border-radius: 10px;
    &:hover {
        opacity: 0.5;
        cursor: pointer;
        transition: 0.3s ease;
    }
}

/* MARK: 2 全体のレイアウト */
/* SP / タブレット: 1カラム（slider → search → main の順） */
.main-index {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
        "slider"
        "search"
        "main"
        "side"
        "bottom";
    max-width: 1140px;
    margin: 10px auto 0;
    padding: 0 15px;
}
/* 左右のカラムを包む箱 991px以下では箱が無いものとして扱い、上の1カラムの並び（grid-area）にそのまま従う */
.index-col {
    display: contents;
}
#top-slider {
    grid-area: slider;
    margin-bottom: 15px;
}
#search {
    grid-area: search;
}
#cnt-main {
    grid-area: main;
}
#side-pc {
    grid-area: side;
    display: none;
}
/* アプリのバナーは、992px〜では検索ブロックの中（.search-bnr）に出るので、右カラムの一覧のほうは隠す */
#side-pc .side-bnr-app {
    display: none;
}
/* 576〜991px: 右カラムのバナーを、メインの下に3列で出す（575px以下は、下の #sp-btm を出す）
   並びは HTML の順（クレジット・QR・寮設営・アプリ・酒類・広告主募集・ふらっと動画・DAZN） */
@media screen and (min-width: 576px) and (max-width: 991px) {
    #side-pc {
        display: block;
        margin-bottom: 15px;
    }
    #side-pc .side-bnr-app {
        display: block;
    }
    #side-pc .side-bnr-wrap {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 12px;
        margin-top: 0;
    }
    #side-pc .side-bnr-wrap img {
        display: block;
        width: 100%;
        margin-bottom: 0;
    }
}
#sp-btm {
    grid-area: bottom;
}
@media screen and (min-width: 576px) {
    .main-index h2 {
        font-size: 24px;
    }
}
@media screen and (min-width: 768px) {
    .main-index h2 {
        padding: 10px;
        font-size: 32px;
        margin: 0 0 10px;
    }
}
/* 992px〜: 2カラム（左 3 : 右 1）左右は別々の箱で縦に積むので、片方の1段目が高くても、もう片方に空白が出ない */
@media screen and (min-width: 992px) {
    .main-index {
        grid-template-columns: minmax(0, 1fr) clamp(240px, 24vw, 255px);
        grid-template-areas: none;
        align-items: start;
        column-gap: 15px;
    }
    .index-col {
        display: block;
        min-width: 0;
    }
    #top-slider {
        margin-bottom: 0;
    }
    #side-pc {
        display: block;
    }
    /* 右カラムの並び（HTML の順はタブレット用なので、ここで入れ替える） */
    #side-pc .side-bnr-wrap {
        display: flex;
        flex-direction: column;
    }
    #side-pc .side-bnr-credit {
        order: 1;
    }
    #side-pc .side-bnr-qr {
        order: 2;
    }
    #side-pc .side-bnr-drink {
        order: 3;
    }
    #side-pc .side-bnr-flatch {
        order: 4;
    }
    #side-pc .side-bnr-dazn {
        order: 5;
    }
    #side-pc .side-bnr-adrecruit {
        order: 6;
    }
    #side-pc .side-bnr-ryo {
        order: 7;
    }
}

/* MARK: 3 スライダー */
.thumb-item {
    margin: 0;
    padding: 0;
}
.topslide {
    display: block;
    width: 100%;
    max-width: 813px;
    height: auto;
    aspect-ratio: 813 / 426;
}
/* 画像の下の余白（.main-index img の margin）を消し、上下の間隔は箱の margin だけで決める */
.index-cleaning {
    margin: 10px auto 0;
}
.index-cleaning img {
    display: block;
    margin: 0;
}
@media screen and (min-width: 768px) {
    .index-cleaning {
        display: none;
    }
    .thumb-item img {
        padding: 0 0 5px;
    }
}
.thumb-item-nav {
    display: none;
    margin-top: 8px;
}
@media screen and (min-width: 768px) {
    .thumb-item-nav {
        display: block;
    }
}

.slide-arrow {
    position: absolute;
    top: 50%;
    z-index: 99;
    width: 7%;
}
@media screen and (min-width: 576px) {
    .slide-arrow {
        width: auto;
    }
}
.prev-arrow {
    left: 15px;
}
.next-arrow {
    right: 15px;
}
.slick-prev:before,
.slick-next:before {
    color: #000;
}
.slick-next ::before,
.slick-arrow::before {
    content: "";
}
.slick-dots li.slick-active button:before,
.slick-dots li button:before {
    color: white;
}

/* MARK: 4 検索ブロック */
/* SP / タブレットでは青い帯、992px〜は右カラム */
#search {
    padding: 0 0 10px;
    background-color: var(--site-blue);
    text-align: center;
}
#search h2 {
    font-size: 18px;
}
#search .search-title-bracket {
    display: inline;
}
#search .search-title-btn {
    border-radius: 5px;
    margin: 0;
}
#search .search-title-btn:hover {
    opacity: 0.5;
    cursor: pointer;
    transition: 0.3s ease;
    text-decoration: none;
}
#search .search-title-link:hover {
    color: white;
    text-decoration: none;
}
.search-form {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 6px 0;
}
/* 入力欄・セレクト: 枠は gray、角丸 5px */
.search-form .findshop,
.search-form .area {
    width: 100%;
    height: 40px;
    padding: 0 10px;
    border: 1px solid gray;
    border-radius: 5px;
    background-color: white;
    color: #212529;
    font-size: 1rem;
    &:hover {
        opacity: 0.5;
        cursor: pointer;
        transition: 0.3s ease;
    }
}

.search-form .findshop {
    flex: 1 1 38%;
    min-width: 0;
}
.search-form .select-box {
    flex: 1 1 38%;
    min-width: 0;
}
.search-form .search-btn02 {
    flex: 0 0 auto;
    width: 40px;
    height: 40px;
    border-radius: 5px;
    cursor: pointer;
}
.search-form .search-btn02:hover {
    opacity: 0.5;
    cursor: pointer;
    transition: 0.3s ease;
}
.search-form .-pc {
    display: none;
}
.search-area {
    display: none;
}
.search-bnr {
    display: none;
}
@media screen and (min-width: 992px) {
    #search {
        padding: 0;
        margin-top: 0;
        background-color: transparent;
        text-align: left;
    }
    #search .search-title-bracket {
        display: none;
    }
    #search h2 {
        font-size: 18px;
    }
    .search-form {
        flex-wrap: wrap;
        justify-content: flex-start;
        padding: 10px 0 0;
    }
    .search-form .findshop {
        flex: 1 1 0;
    }
    .search-form .-pc {
        display: block;
    }
    .search-form .-sp {
        display: none;
    }
    .search-form .select-box {
        flex: 1 0 100%;
    }
    .search-area {
        display: block;
        margin: 15px 0 0;
    }
    .search-bnr {
        display: block;
    }
}
.search-area-title {
    margin: 0;
    line-height: 1.8;
    font-size: 16px;
    font-weight: bold;
}
.search-area-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    background: url(../images/top/bg-jpn.png) no-repeat 0 0 / contain;
}
.search-area-list a {
    display: block;
    width: 100%;
    margin-bottom: 10px;
    padding: 5px 10px;
    border-radius: 5px;
    text-align: right;
}
.search-area-list a:hover {
    opacity: 0.5;
    cursor: pointer;
    transition: 0.3s ease;
}
.search-area-list .-half {
    width: 48%;
    text-align: left;
}
.search-area-list .-half.-right {
    text-align: right;
}
.search-area-list .-hokkaido {
    background-color: var(--area-hokkaido);
}
.search-area-list .-tohoku {
    background-color: var(--area-tohoku);
}
.search-area-list .-kosinetsu {
    background-color: var(--area-kosinetsu);
}
.search-area-list .-kanto {
    background-color: var(--area-kanto);
}
.search-area-list .-tokai {
    background-color: var(--area-tokai);
}
.search-area-list .-kansai {
    background-color: var(--area-kansai);
}
.search-area-list .-hokuriku {
    background-color: var(--area-hokuriku);
}
.search-area-list .-shikoku {
    background-color: var(--area-shikoku);
}
.search-area-list .-kyusyu {
    background-color: var(--area-kyusyu);
}

/* MARK: 5 ニュース */
/* .main-index h2 の padding・margin より強くして、ボタン画像を横幅いっぱいに出す */
.main-index .index-news-title-sp {
    margin: 15px 0;
    padding: 0;
    background-color: white;
}
.index-news-title-sp a {
    display: block;
}
/* 画像の影は小さく見えにくいので、下に影を足す（画像の下の余白は影の分） */
.index-news-title-sp img {
    display: block;
    width: 100%;
    margin: 0 0 8px;
    filter: drop-shadow(0 4px 4px rgba(0, 0, 0, 0.45));
}
#news {
    display: none;
    position: relative;
    margin: 15px 0;
}
@media screen and (min-width: 768px) {
    .index-news-title-sp {
        display: none;
    }
    #news {
        display: block;
    }
}
#news::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 4px solid var(--site-blue);
    pointer-events: none;
}
#news .wrapper {
    width: calc(100% - 5px);
    height: 185px;
    padding: 0 2px 0 15px;
    overflow-y: scroll;
    box-sizing: border-box;
}
#news a {
    display: flex;
    margin: 10px 0;
}
#news a:first-child {
    margin: 0 0 10px;
}
#news a:hover {
    background-color: rgb(190, 220, 240);
    border-radius: 5px 0 0 5px;
}
#news .news-ico {
    display: inline-block;
    width: 20%;
    padding: 10px 0;
    font-size: 4vw;
    border-radius: 5px;
    color: white;
    font-weight: bold;
    text-align: center;
    transition: opacity 0.2s ease-in-out;
}
@media screen and (min-width: 576px) {
    #news .news-ico {
        width: 15%;
        font-size: inherit;
    }
}
#news a:hover .news-ico {
    opacity: 0.5;
    cursor: pointer;
    transition: 0.3s ease;
}
#news .n-new {
    background-color: rgb(230, 0, 18);
}
#news .n-kanto {
    background-color: rgb(143, 195, 31);
}
#news .n-tokai {
    background-color: rgb(243, 152, 0);
}
#news .n-kansai {
    background-color: rgb(46, 167, 224);
}
#news .n-all {
    background-color: rgb(225, 0, 127);
}
#news p {
    display: inline-block;
    vertical-align: middle;
    width: 85%;
    padding: 10px 5px 10px 10px;
    border-bottom: 2px dashed #000;
}
.index-recruit,
.index-special {
    margin-bottom: 15px;
}
.index-special.-pc {
    display: block;
}
.index-special.-sp {
    display: none;
}
.index-recruit img,
.index-special img {
    display: block;
    width: 100%;
    border-radius: 10px;
}

/* MARK: 6 サービス一覧 */
#service {
    margin-bottom: 15px;
}
#service ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
}
#service li {
    display: flex;
    flex-direction: column;
    padding: 8px;
    border: 1px solid var(--site-blue);
}
#service h3 {
    margin: 5px 0 0;
    padding-left: 5px;
    border-left: 6px solid var(--site-blue);
    font-size: 4vw;
    font-weight: bold;
}
#service p {
    font-size: 3.3vw;
}
#service .link-wrap {
    margin-top: auto;
    text-align: right;
}
#service .link-wrap a {
    color: rgb(255, 115, 0);
    font-size: 3.2vw;
}
#service .link-wrap a::before {
    content: ">>";
}
#service .link-wrap a:hover {
    opacity: 0.5;
    text-decoration: underline;
}
@media screen and (min-width: 576px) {
    #service h3 {
        font-size: 19px;
    }
    #service p {
        font-size: 18px;
    }
    #service .link-wrap a {
        font-size: 16px;
    }
}
/* 画像（スプライト 12枚を横に並べた1枚）: 見出しとの間隔は margin で取る */
.service-img {
    display: block;
    width: 100%;
    max-width: 378px;
    margin-bottom: 10px;
    background-image: url(../images/top/sallb.jpg);
    background-size: 1200%;
}
.service-img::before {
    content: "";
    display: block;
    padding-top: calc(223 / 378 * 100%);
}

#service li:nth-child(1) .service-img {
    background-position-x: 0;
}
#service li:nth-child(2) .service-img {
    background-position-x: calc(100% / 11);
}
#service li:nth-child(3) .service-img {
    background-position-x: calc(100% * 2 / 11);
}
#service li:nth-child(4) .service-img {
    background-position-x: calc(100% * 4 / 11);
}
#service li:nth-child(5) .service-img {
    background-position-x: calc(100% * 5 / 11);
}
#service li:nth-child(6) .service-img {
    background-position-x: calc(100% * 6 / 11);
}
#service li:nth-child(7) .service-img {
    background-position-x: calc(100% * 7 / 11);
}
#service li:nth-child(8) .service-img {
    background-position-x: calc(100% * 8 / 11);
}
#service li:nth-child(9) .service-img {
    background-position-x: calc(100% * 9 / 11);
}
#service li:nth-child(10) .service-img {
    background-position-x: calc(100% * 10 / 11);
}
#service li:nth-child(11) .service-img {
    background-position-x: 100%;
}
@media screen and (min-width: 768px) {
    #service h3 {
        font-size: 24px;
    }
    #service p {
        font-size: 14px;
    }
    #service ul {
        gap: 12px;
    }
}

/* MARK: 7 サイドバナー・SP下部バナー */
.side-bnr-wrap {
    margin-top: 10px;
}
.side-bnr-wrap a {
    display: block;
}
#side-pc img {
    margin-bottom: 15px;
    &:hover {
        opacity: 0.5;
        cursor: pointer;
        transition: 0.3s ease;
    }
}
#sp-btm {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}
#sp-btm a {
    display: block;
}
#sp-btm .-left {
    width: 33%;
}
#sp-btm .-right {
    width: 63%;
}
/* 後ろに書いた display:flex が上の非表示指定に勝たないよう、ここで 576px〜を隠す（576px〜は右カラムのバナー一覧を出すため） */
@media screen and (min-width: 576px) {
    #sp-btm {
        display: none;
    }
}
@media screen and (min-width: 992px) {
    .index-special.-pc {
        display: none;
    }
    .index-special.-sp {
        display: block;
    }
}
