/* ==========================================================================
   RESET & BASE STYLES
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    line-height: 1.5;
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Noto Sans JP", sans-serif;
    color: #000;
    background-color: #ffb243;
    text-align: center;
}

main{
    width: 600px;
}

ol, ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    vertical-align: bottom;
}

a {
    color: #888;
    text-decoration: none;
    transition: opacity 0.3s ease, color 0.3s ease;
}

a:hover {
    opacity: 0.6;
    color: #666;
}

:focus {
    outline: none;
}

p {
    line-height: 1.8;
}

/* ==========================================================================
   LAYOUT & CONTAINERS
   ========================================================================== */
.inner {
    max-width: 940px;
    margin-left: auto;
    margin-right: auto;
    padding: 10px 10px 30px 10px;

}

.mainImg {
    margin-left: auto;
    margin-right: auto;
    max-width: 940px;
    margin-bottom: 30px;
}

.subtext {
    text-align: left;
    padding: 1.5em 20px;
    max-width: 940px;
    margin: 0 auto;
    font-size: 1.1rem;
    letter-spacing: 1px;
    font-weight: 600;
    color: #fff;
    background: #4a433d;
    line-height: 1.4;
}

.present {
    width: 100%;
    max-width: 940px;
}

/* 応募締切ボックス */
.deadline-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 32px;
    border: 3px solid #ee7b00;
    padding: 14px 20px;
    background-color: #ffffff;
    font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Meiryo", sans-serif;
    font-weight: 800;
    box-sizing: border-box;
    width: 100%;
    margin: 20px auto;
}

.deadline-title {
    color: #ee7b00;
    font-size: 1.5rem;
    letter-spacing: 0.05em;
    /*white-space: nowrap;*/
}

.deadline-text {
    color: #1a1a1a;
    font-size: 1.3rem;
    letter-spacing: 0.02em;
    /*white-space: nowrap;*/
}

/* 表示切替（PC / スマホ） */
.forpc { display: block; }
.forsp { display: none; }

.imgsp { display: none; }
.imgpc { display: block; }

@media screen and (max-width: 640px) {
    .imgsp { display: block; margin: 0px 20px}
    .imgpc { display: none; }

    .inner {
    padding: 10px 10px;
    }
    .mainImg {
      margin: auto;
      padding:0px!important;
    }
}

/* ==========================================================================
   HEADER & FOOTER
   ========================================================================== */
header {
    width: 100%;
}

.pageTop {
    padding: 15px;
    text-align: left;
    background-color: #000;
}

.pageTop .logo {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

footer {
    width: 100%;
    padding: 40px 0;
    text-align: center;
    font-size: 12px;
    color: #fff;
    background-color: #000;
}

/* TOPへ戻るボタン */
.toTop {
    position: fixed;
    bottom: 20px;
    right: 5%;
    width: 40px;
    z-index: 100;
}

.toTop a img {
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.toTop a img:hover {
    opacity: 1;
}

/* ==========================================================================
   HEADINGS & TEXT STYLES
   ========================================================================== */
h1.img {
    max-width: 1300px;
    margin: 30px auto;
}

h3 {
    font-size: 1.625rem;
    color: #333;
    line-height: 1.4;
    text-align: left;
    border-bottom: solid 3px #333;
    margin: 30px 0 20px;
    padding: 5px;
}

h5 {
    font-size: 1.0em;
    /*color: #fff;*/
    margin-top: 10px;
}

/* 応募要項テキストエリア */
.oubotxt {
    text-align: left;
    margin: 20px 0 30px;
    padding: 20px;
    background-color: #fff;
    border-radius: 4px;
}

.oubotxt ul li {
    display: block;
    line-height: 1.6;
    margin-bottom: 2.4em;
    padding: 0 2rem;
}

.oubotxt ul li.note {
    margin-top: 1em;
    font-size: 0.9em;
    color: #000;
    padding: 20px 5px;
    border-top: 1px dotted #000;
}

.oubotxt ul li span.oubottl {
    color: #f18200;
    font-weight: 600;
}

.oubotxt ul li span.shimekiri {
    font-size: 1.1em;
    padding: auto 1rem;
    font-weight: bold;
    color: #FF0000;
}

/* 応募ボタン */
.ouboBtn {
    text-align: center;
    margin-top: 40px;
    width: 100%;
}

.ouboBtn a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 600px;
    padding: 0.8em 2em;
    font-size: 1.8em;
    font-weight: 600;
    color: #fff;
    background-color: #76a32d;
    border: 3px solid #fff;
    border-radius: 60px;
    position: relative;
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.ouboBtn a:hover {
    background-color: #5a7d22;
    transform: translateY(-1px);
}

.rakuten {
    margin: 40px auto 20px;
    width: 280px;
    font-size: 1.1em;
    padding: 10px 30px;
    background-color: #fdf100;
    border: 2px #888 solid;
}

/* ==========================================================================
   SNS SHARE BUTTONS
   ========================================================================== */
.sns {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
    padding-bottom: 30px;
    flex-wrap: wrap;
}

.x-share-button,
.fb-share-button,
.line-share-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 28px;
    border: 3px solid #ffffff;
    border-radius: 30px;
    background-color: #000000;
    color: #ffffff;
    font-weight: bold;
    font-size: 1rem;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

.x-share-button:hover,
.fb-share-button:hover,
.line-share-button:hover {
    background-color: #333;
    color: #fff;
}



/* ==========================================================================
   RITTOR ID (RMID)
   ========================================================================== */
.rmid {
    max-width: 100%;
    background-color: #dcdcdc;
    border-radius: 5px;
    margin: 30px auto;
    padding: 20px;
    color: #000;
    box-sizing: border-box;
}

.rmid h5 {
    color: #000;
    margin: 5px 0 15px 0;
    font-size: 1.0em;
}

.kochira {
    border: 0px solid #fff;
    padding: 2px 5px;
    background-color: rgba(0, 0, 0, 0.2);
    font-size: .9em;
    color: #fff;
    border-radius: 2px;
}

.rmid table {
    width: 100%;
    border-collapse: collapse;
}

.rmid table td {
    text-align: left;
    vertical-align: top;
    padding: 5px;
    font-size: 0.8em;
    line-height: 1.6;
}

.rmid table .td-logo {
    width: 15%;
    text-align: center;
    vertical-align: middle;
}

.rmid table .td-text {
    width: 55%;
}

.rmid table .td-list {
    width: 25%;
}

.rmid table .td-list ul {
    margin: 0;
    padding-left: 20px;
}

/* ==========================================================================
   BOOKS & SHOPS LISTS
   ========================================================================== */
/* 対象商品リスト */
.bookList {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}

.bookList li {
    display: block;
}

.bookList li a img {
    display: block;
    width: 100%;
    border: 1px solid #fff;
    transition: transform 0.2s ease;
}

.bookList li a:hover img {
    transform: scale(1.03);
}

/* 都道府県ナビゲーション */
ul.shop-sc {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin: 0 auto 30px;
}

ul.shop-sc li {
    flex: 1 1 80px;
    max-width: 100px;
    border: 2px solid #fdf100;
    background: #f3f5f8;
}

ul.shop-sc li a {
    display: block;
    color: #000;
    padding: 8px 0;
    font-size: 0.9rem;
}

ul.shop-sc li a:hover {
    background-color: #f18200;
    color: #fff;
}

/* 開催店舗テーブル */
.table-wrapper {
    overflow-x: auto;
}

table.shop {
    width: 49%;
    float: left;
    margin-bottom: 2em;
    border-collapse: separate;
}

table.shop.right {
    float: right;
}

table.shop td {
    text-align: left;
    padding: 10px;
    font-size: 0.9em;
    border: 0px #666 solid;
    line-height: 1.6;
    background-color: #fff;
}

table.shop td.ttl {
    background: #fdf100;
    color: #000;
    text-align: center;
    font-weight: bold;
}

table.shop td:nth-child(1) {
    white-space: nowrap;
}

.fairShop::after {
    content: "";
    display: table;
    clear: both;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.fade {
    padding: 10px;
    animation: fadeIn 2s ease 0s 1 normal;
}

/* ==========================================================================
   RESPONSIVE MEDIA QUERIES
   ========================================================================== */
@media screen and (max-width: 980px) {
    .forpc { display: none; }
    .forsp { display: block; }


}

@media (max-width: 768px) {
    .deadline-box {
        gap: 12px;
        padding: 10px 12px;
    }
    .deadline-title,
    .deadline-text {
        font-size: 14px;
    }

    /* RMIDテーブルの縦並び化 */
    .rmid table, 
    .rmid table tbody, 
    .rmid table tr, 
    .rmid table td {
        display: block;
        width: 100%;
    }
    
    .rmid table td {
        width: 100% !important;
        box-sizing: border-box;
        border-bottom: none;
    }
    
    .rmid table td:last-child {
        border-bottom: 1px solid #666;
    }
    
    .rmid table .td-logo img {
        display: none;
        width: 150px;
        margin: 20px auto;
    }

    .rmid table .td-list ul {
        padding-left: 0px;
    }
}

@media screen and (max-width: 700px) {
    h3 {
        font-size: 1.25rem;
    }

    table.shop,
    table.shop.right {
        float: none;
        width: 100%;
        margin-bottom: 1em;
    }

    .oubotxt ul li {
        display: block;
        line-height: 1.6;
        margin-bottom: 2.4em;
        padding: 0 .1rem;
    }

    .ouboBtn a {
        font-size: 1.3em;
        padding: 0.8em 1em;
    }

    .bookList {
        grid-template-columns: repeat(4, 1fr);
    }

    .x-share-button,
    .fb-share-button,
    .line-share-button {
        padding: 8px 18px;
        font-size: 0.85rem;
    }
}

@media screen and (max-width: 480px) {
    .subtext {
        font-size: .8rem;
        font-weight: 400;
        padding: 5px;
    }
    .bookList {
        grid-template-columns: repeat(3, 1fr);
    }
    ul.shop-sc{
        gap:4px;
    }
    ul.shop-sc li a{
        padding: 2px 0px;
                font-size: .8rem;
    }
    table.shop td{
        padding: 5px;
        font-size: .8rem;
    }
        .sns{
            padding-bottom: 0px;
    }
    ul.shop-sc li {
        flex: 1 1 20%;
    }
    .sns{
        gap: 4px;
        margin-bottom: 20px;
        flex-wrap:nowrap;
    }
    .x-share-button,
    .fb-share-button,
    .line-share-button {
    /*display: inline-flex;
    align-items: center;
    justify-content: center;*/
    gap: 4px;
    border: 3px solid #ffffff;
    border-radius: 30px;
    background-color: #000000;
    color: #ffffff;
    font-weight: normal;
    font-size: .65rem;
    text-decoration: none;
    transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

}



/* 画面幅が1024px以上の時は */
@media screen and (min-width: 1024px) {
  .ps-br{
    display: block; /* PCを改行して */
  }

  .sp-br{
    display: none; /* SPの改行を隠す */
  }
}

/* 画面幅が560px以下の時は */
@media screen and (max-width: 480px) {
  .ps-br{
    display: none; /* PCの改行を隠して */
  }

  .sp-br{
    display: block; /* SPを改行する */
  }
}