/*
 * restyle.css
 * 変数・レイアウト・コンポーネントの上書き。:root の変数は各 HTML の <style> で定義。
 * 新規クラスは接頭辞 ueki- または既存 BEM ブロック内に収めること（docs/contracts.md 参照）。
 */

/* ========== 共通表示（サイト名・電話番号）DRY のためこの 1 箇所のみ ========== */
.c_name::before {
    content: "Wize Plant";
}
.tel::before {
    content: "070-8991-7147";
}

/* ========== レイアウト（body・ローダー・ナビ・コンテナ等） ========== */
body {
    color: var(--custom-color-1);
    background-color: var(--custom-color-5);
}
.loader {
    display: none;
    position: fixed;
    z-index: 9999999;
    background: #ffffffd1;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    justify-content: center;
    align-items: center;
}
.loader.on{
    transition: 1s;
    display: flex;
}
.slick-slide img {
    display: block;
    margin: 0 auto;
}

/* ========== コンポーネント（成功メッセージ・フォーム・サブタイトル等） ========== */
.successOrder {
    display: flex;
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
}
.successOrder h1,
.successOrder h2 {
  color: #88B04B;
  font-family: "Nunito Sans", "Helvetica Neue", sans-serif;
  font-weight: 900;
  font-size: 40px;
}
.successOrder p {
  color: #404F5E;
  font-family: "Nunito Sans", "Helvetica Neue", sans-serif;
  font-size:20px;
  margin: 0;
}
.successOrder i {
    color: #9ABC66;
    font-size: 100px;
    background: var(--custom-color-2);
    padding: 0 51.8px;
    border-radius: 100%;
}
.successOrder > div {
    background: var(--custom-color-5);
    padding: 60px;
    border-radius: 4px;
    box-shadow: 0 2px 3px #C8D0D8;
    display: inline-block;
    margin: 0 auto;
}

/* お支払・送料ページ：お問い合わせ誘導 */
.sk_contact_cta {
    margin-top: 1.5rem;
    text-align: center;
}
.sk_contact_cta .btn-contact {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--custom-color-2, #28292f);
    color: var(--custom-color-5, #fff);
    text-decoration: none;
    border-radius: 4px;
    font-weight: normal;
}
.sk_contact_cta .btn-contact:hover {
    background: var(--custom-color-3, #595960);
    color: var(--custom-color-5);
}
#policy .btn-contact-inline {
    color: var(--custom-color-2);
    font-weight: bold;
    text-decoration: underline;
}
#policy .btn-contact-inline:hover {
    text-decoration: none;
}


.gNavRight,.gNavLeft{
    position: relative;
    right: initial;
    bottom: initial;
}
.gNavRight > .hSearch{
    margin-right: 25px;
}
.gNavRight {
    display: flex;
    align-items: center;
    /* min-width: 316px; */
    justify-content: space-between;
}

/* カートリンクをバッジの位置基準にする（アイコン右上に個数バッジを重ねるため） */
.gNavRight a[href*="cart"] {
    position: relative;
    display: inline-block;
}

/**
 * ヘッダーカートアイコン用の個数バッジ。
 * JS（cart-badge.js）で挿入・更新される。0 個のときは JS で非表示にする。
 */
.gNavRight__cartCount {
    position: absolute;
    top: -6px;
    right: -8px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    font-size: 11px;
    line-height: 18px;
    font-weight: bold;
    text-align: center;
    color: #fff;
    background: #e40020;
    border-radius: 9px;
    box-sizing: border-box;
}

.gNavWrap__inner {
    width: 100%;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 5px 0px;
}

/* ハンバーガーボタン（デスクトップでは非表示） */
.gNavHamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    min-width: 44px;
    min-height: 44px;
    padding: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    color: var(--custom-color-2);
}
.gNavHamburger__bar {
    display: block;
    width: 22px;
    height: 2px;
    background: currentColor;
    border-radius: 1px;
}

#sidemenu {
    position: fixed;
    top: calc( 50% - 10px );
    right: -180px;
    transform: rotate( -90deg );
    -moz-transform: rotate( -90deg );
    -webkit-transform: rotate( -90deg );
    -ms-transform: rotate( -90deg );
    border-right: 1px solid #4A3730;
    background: var(--custom-color-5);
    height: 20px;
    overflow: hidden;
    padding: 0px 24px;
}

#sidemenu > ul {
    display: flex;
    height: auto;
}
#sidemenu > ul > li {
    margin-right: 20px;
}

.container > .cInner.withSide{
    width:1200px;
    margin:0 auto;
}

#main.withSide{
    max-width:100%;
    width: 910px;
}

.subtitle {
    text-align: center;
    font-size: 15px;
    background: var(--custom-color-2);
    color: #ffffff;
    padding: 20px 0;
}

.subtitle input,
.subtitle button {
    outline: none;
    border: none;
    background: none;
    color: #ffffff;
    cursor: pointer;
}
form.register_user input,
form.loginForm input,
form.form_contact input,
form.form_contact .ueki-contact-input {
    width: 100%;
    height: 40px;
    padding: 8px;
    border: none;
    border: 1px solid;
}

form.register_user,
form.loginForm,
form.form_contact {
    max-width: 800px;
    margin: 0 auto;
}
form.form_contact textarea,
form.form_contact .ueki-contact-textarea {
    min-width: 100%;
    min-height: 140px;
    border: 1px solid;
    padding: 8px;
}

.contact-btn,
.ueki-contact-submit {
    border: none !important;
}

/* ========== お問い合わせフォーム：セマンティック構造用（label/fieldset 配置・余白） ========== */
.ueki-contact-form-intro {
    margin-bottom: 1rem;
    color: var(--custom-color-3);
}
.ueki-contact-fieldset {
    border: 0;
    margin: 0;
    padding: 0;
}
.ueki-contact-legend {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.ueki-contact-field {
    margin-bottom: 1.25rem;
}
.ueki-contact-field label {
    display: block;
    margin-bottom: 0.35rem;
    font-weight: 600;
}
.ueki-contact-field .ueki-contact-input,
.ueki-contact-field .ueki-contact-textarea {
    font-size: 16px;
    box-sizing: border-box;
}
/* お問い合わせフォーム：送信／確認画面のボタン群ラッパー（PCで横並び・間隔を確保し、各ボタンを独立したUIとして表示） */
.ueki-contact-submit-wrap {
    margin-top: 1.5rem;
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: center;
}

/**
 * お問い合わせページ専用の .c-button スタイル。
 * contact / contact-confirm は user_payment/css/index.css を読まないため、ここでボタン見た目を定義する。
 * a と button の両方に同じ見た目を当て、クリック領域を明確にする。
 */
.ueki-contact-submit-wrap .c-button,
.ueki-contact-submit-wrap .c-button:link,
.ueki-contact-submit-wrap .c-button:visited {
    display: inline-block;
    padding: 0.75em 1.5em;
    font-size: 16px;
    line-height: 1.4;
    text-align: center;
    text-decoration: none;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    background: #eff2f4;
    color: #35454c;
    min-height: 44px;
    box-sizing: border-box;
    white-space: nowrap;
}

.ueki-contact-submit-wrap .c-button:hover {
    background: #dfe5e8;
}

.ueki-contact-submit-wrap .c-button:active {
    opacity: 0.9;
}

/* メインアクション（送信する・確認画面へ）は目立つ色に */
.ueki-contact-submit-wrap .c-button--primary {
    background: #2196f3;
    color: #fff;
}

.ueki-contact-submit-wrap .c-button--primary:hover {
    background: #1e87da;
}

.ueki-contact-submit-wrap .c-button--primary:disabled,
.ueki-contact-submit-wrap .c-button--primary.disabled {
    background: #9ec9f5;
    cursor: not-allowed;
}

.ueki-contact-submit-wrap .c-button--lg {
    padding: 1em 2.5em;
    font-size: 16px;
}

/* FAQ セクション（セマンティック: dl / dt / dd） */
.ueki-contact-faq {
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #ccc;
}
.ueki-contact-faq-title {
    font-size: 1.125rem;
    margin-bottom: 1rem;
}
.ueki-contact-faq-list dt {
    font-weight: 600;
    margin-top: 0.75rem;
}
.ueki-contact-faq-list dt:first-child {
    margin-top: 0;
}
.ueki-contact-faq-list dd {
    margin-left: 0;
    margin-top: 0.25rem;
    color: var(--custom-color-3);
}
.fa,.fas,input {
    color:var(--custom-color-2);
}

/* ========== メディアクエリ（スマートフォン等） ========== */
@media (max-width: 500px) {
    /* 横スクロール防止（style.css の body min-width: 1200px 等の影響を封じ込める） */
    html {
        overflow-x: hidden;
    }
    #sidemenu{
        display: none;
    }
    /* ヘッダーがビューポートをはみ出さないようにする（style.css の .gNavWrap__inner width: 1200px を上書き） */
    .gNavWrap {
        max-width: 100vw;
        overflow: hidden;
    }
    .gNavWrap__inner {
        flex-wrap: nowrap;
        min-height: 56px;
        justify-content: space-between;
        padding: 8px 12px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        min-width: 0;
    }
    .gNavLeft {
        flex-shrink: 0;
        min-width: 0;
    }
    .gNavLeft img {
        max-height: 40px;
        max-width: 140px;
        width: auto;
        height: auto;
        object-fit: contain;
    }
    .gNavDrawer {
        position: fixed;
        top: 0;
        right: 0;
        bottom: 0;
        width: min(280px, 85vw);
        max-width: 280px;
        background: var(--custom-color-5);
        box-shadow: -2px 0 12px rgba(0,0,0,0.15);
        z-index: 999998;
        transform: translateX(100%);
        transition: transform 0.25s ease-out;
        overflow-y: auto;
        padding: 60px 20px 20px;
    }
    body.is-drawerOpen .gNavDrawer {
        transform: translateX(0);
    }
    .gNavDrawer .gNav {
        display: block;
        text-align: left;
    }
    .gNavDrawer .gNav__unit {
        display: block;
        margin: 0 0 4px 0;
    }
    .gNavDrawer .gNav__unit:nth-of-type(n+2) {
        margin-left: 0;
    }
    .gNavDrawer .gNav__link,
    .gNavDrawer .gNav__noLinkText {
        display: block;
        padding: 12px 0;
        min-height: 44px;
        box-sizing: border-box;
    }
    .gNavDrawer .gNav__drop {
        position: static;
        box-shadow: none;
    }
    .gNavDrawer .gNav__dropBg {
        position: static;
        padding: 0 0 0 16px;
    }
    .gNavDrawer .gNav__dropInner {
        padding: 0;
    }
    .gNavDrawer .gNav__unit3__box {
        margin-bottom: 12px;
    }
    .gNavDrawer .gNav__unit3 {
        margin-left: 0;
    }
    .gNavDrawer .gNav__dropLink {
        display: block;
        padding: 8px 0;
    }
    .gNavRight {
        display: flex;
        align-items: center;
        width: auto;
        justify-content: flex-end;
        padding: 0;
        flex-shrink: 0;
    }
    .gNavRight > .hSearch {
        margin-right: 0;
    }
    .gNavRight a[href*="cart"] {
        min-width: 44px;
        min-height: 44px;
        justify-content: center;
        align-items: center;
        display: inline-flex;
    }
    .gNavHamburger {
        display: flex;
        flex-shrink: 0;
    }
    .gNavDrawerBackdrop {
        position: fixed;
        inset: 0;
        background: rgba(0,0,0,0.35);
        z-index: 999997;
        pointer-events: none;
        opacity: 0;
        transition: opacity 0.2s ease-out;
    }
    body.is-drawerOpen .gNavDrawerBackdrop {
        pointer-events: auto;
        opacity: 1;
    }

    body {
        min-width: initial;
        width: 100%;
    }
    /* グループB（cart/checkout/myAccount）：共通 gNavWrap 表示時は従来のロゴエリアを非表示 */
    .p-page__wrap .title_area.p-shop__header {
        display: none;
    }
    #container {
        margin-top: 60px;
    }
    .cInner {
        width: 100%;
    }
    .section--main {
        margin-bottom: 50px;
    }
    .aboutShop {
        padding: 25px 0px;
    }
    .aboutShop__title img {
        max-width: 120px;
        height: auto;
    }
    .itemList--4 .itemList__unit {
        width: 47.5%;
        min-height: 230px;
    }
    .pickupBnrArea.section--main {
        display: none;
    }
    .itemList--3 .itemList__unit {
        width: 100%;
    }
    .fLogo {
        margin-bottom: 0;
    }
    .itemList--3 .itemList__unit:nth-child(n+2) {
        margin-left: 0;
        margin-top: 20px;
    }

    .clearfix {
        min-height: 1px;
        display: flex;
        flex-wrap: wrap;
        justify-content: space-around;
    }
    .clearfix > * {
        margin-left: 0px!important;
        margin-right: 0px!important;
        float: none !important;
        position: relative;
    }
    .clearfix:after{
        display: none;
    }
    .popBnr {
        display: block ;
        position: relative;
        top: initial;
        left: initial;
        text-align: center;
        width: 100%;
        height: auto;
        background: var(--custom-color-2);
        border-top: 2px solid white;
    }
    #middle_contents {
        display: flex;
        flex-wrap: wrap;
    }
    #main.withSide{
        max-width: 100%;
        width: 100%;
    }
    .container > .cInner.withSide {
        width: 100%;
        margin: 0 auto;
    }
    .footstamp {
        padding: 0px 10px;
    }
    .productDetailBoxRight , .productDetailBoxLeft {
        float: none;
        width: 100%;
    }
     .productDetailBoxLeft {
        padding: 0 20px;
    }
    #side {
        width: 100%;
        margin-top: 20px;
    }
    table.addCartTable {
        table-layout: initial;
    }
    
    .cartBtn--contact,.cartBtn--main {
        border-radius: 0;
    
    }
    #policy {
        line-height: 0.8;
        font-size: 12px;
        padding: 0 20px;
    }
    .sk_box th {
        width: 70px;
    }

    .sk_box td {
        display: flex;
        justify-content: center;
        align-items: center;
    }
    table:not(.addCartTable) tbody > tr {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
    }
    table:not(.addCartTable) tbody > tr > * {
        width: 100% !important;

    }
    table:not(.addCartTable) tbody > tr > th {
        text-align: center !important;
    }

    /* お問い合わせフォーム：スマホで入力しやすく（タッチターゲット 44px 以上・16px フォント・余白） */
    .ueki-contact-box .ueki-contact-field {
        margin-bottom: 1.5rem;
    }
    .ueki-contact-box .ueki-contact-input {
        min-height: 44px;
        height: auto;
        padding: 12px 10px;
        font-size: 16px;
    }
    .ueki-contact-box .ueki-contact-textarea {
        min-height: 160px;
        padding: 12px 10px;
        font-size: 16px;
    }
    .ueki-contact-box .ueki-contact-submit {
        min-height: 48px;
        min-width: 100%;
        padding: 14px 20px;
        font-size: 18px;
    }
    /* 確認画面の2ボタン：スマホでは縦並び・幅100%でタップしやすくする */
    .ueki-contact-box .ueki-contact-submit-wrap {
        flex-direction: column;
    }
    .ueki-contact-box .ueki-contact-submit-wrap .c-button {
        min-width: 100%;
        padding: 14px 20px;
        font-size: 18px;
    }
    .ueki-contact-box label {
        font-size: 16px;
    }
    .ueki-contact-main .mainTitle {
        margin-bottom: 1rem;
    }
}