/* 
 * Shared Header CSS
 * Version: 2.9.1
 * Last Updated: 2025-09-13
 * 
 * 全てのヘッダーテンプレートで共通するベーススタイル
 * header-template-common.cssの機能を統合
 * 
 * 変更履歴:
 * v2.9.1 - href属性がないa要素でもホバー時にcursor: pointerを適用
 * v2.9 - 既存shared-header.cssとheader-template-common.cssを統合
 */

/* ====================
 * 既存テーマのリセット
 * ==================== */
/* 既存テーマのヘッダーを非表示 */
.site-header,
.main-navigation,
#masthead,
.site-branding,
.navigation-top,
.custom-header,
#tessera-header-menu {
    display: none !important;
}

/* コンテンツエリアの調整 */
.site-content,
#content,
#main,
.content-area {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* Avada用追記 */
#wrapper .fusion-header {
    display: none !important;
}

#wrapper #or-submenu-202408-wrapper {
    z-index: 100;
}

#wrapper #or-submenu-202408 {
    top: 58px !important;
}

#wrapper #or-submenu-202408-sticky {
    top: 59px !important;
}

/* ====================
 * デスクトップヘッダー基本スタイル
 * ==================== */
.go-top-navi {
    position: fixed;
    top: 0;
    width: 100%;
    height: 60px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    padding: 0 10px;
    margin-bottom: 80px;
    border-bottom: 1px solid #d3d3d3;
    box-shadow: 0px 1px 6px 0px rgba(0, 0, 0, 0.25);
    font-size: 15px;
    z-index: 10005;
}

.go-top-navi .go-top-logo {
    padding: 5px;
}

.go-top-navi .go-top-logo > a {
    display: block;
    width: 100%;
    height: auto;
    overflow: hidden;
    transition: ease-out .1s;
}

.go-top-navi .go-top-logo img {
    aspect-ratio: 380 / 76;
    width: calc(380px * .5);
    max-width: calc(380px * .5);
}

/* ====================
 * デスクトップメニュー基本
 * ==================== */
.go-top-navi .go-menu {
    height: 100%;
    display: flex;
    align-items: stretch;
    list-style: none;
    padding: 0 5px;
    margin: 0;
}

.go-top-navi .go-menu-item {
    position: relative;
    margin: 0;
}

.go-top-navi .go-menu-item::before {
    content: '';
    position: absolute;
    top: calc((60px - 1em - 20px) / 2 + 1px);
    left: 0;
    width: 100%;
    height: calc(1em + 20px);
    background: rgba(84, 138, 255, 0);
    border-radius: 9999px;
    transform: scale(.7);
    transition: background-color .2s ease-out, transform .2s ease-out;
}

.go-top-navi .go-menu-item.go-menu-sale::before {
    background: rgba(255, 145, 0, .2);
    transform: scale(.9);
}

.go-top-navi .go-menu-item:hover::before {
    background: rgba(84, 138, 255, .2);
    transform: scale(1);
}

.go-top-navi .go-menu-link {
    display: block;
    position: relative;
    padding: calc((60px - 1em) / 2) 16px;
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    color: #000;
    text-decoration: none;
}

/* href属性がないa要素でもpointerカーソルを適用 v2.9.1 */
.go-top-navi .go-menu-link:hover {
    cursor: pointer;
}

/* 検索アイコン */
.go-top-navi .go-icon-search {
    width: 3em;
    text-indent: -9999px;
}

.go-top-navi .go-icon-search::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-size: 1em;
    background: url(./images/go-search.svg) no-repeat;
    background-size: 1em;
    background-position: center center;
}

/* ====================
 * 2階層・3階層メニュー（デスクトップ）
 * ==================== */
.go-menu-2nd {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 50px;
    display: none;
    justify-content: center;
    align-items: center;
    background: linear-gradient(180deg, rgba(227, 227, 227, 1) 0%, rgba(233, 233, 233, 1) 6%);
    border-bottom: 1px solid #d9d9d9;
    box-shadow: 0px 1px 6px 0px rgba(0, 0, 0, 0.25);
    transition: ease-out .3s;
    z-index: 10004;
}

.go-menu-item:hover .go-menu-2nd {
    top: 60px;
    display: flex;
}

.go-menu-3rd {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: auto;
    display: none;
    justify-content: center;
    align-items: center;
    background: linear-gradient(180deg, rgba(243, 243, 243, 1) 0%, rgba(249, 249, 249, 1) 6%);
    padding: 30px 0;
    border-bottom: 1px solid #d9d9d9;
    box-shadow: 0px 1px 6px 0px rgba(0, 0, 0, 0.25);
    transition: ease-out .3s;
    z-index: 10003;
}

.go-top-navi .go-menu-2nd .go-menu-item:hover .go-menu-3rd {
    top: 110px;
    display: flex;
}

/* デスクトップメニューの詳細スタイル */
@media (min-width: 769px) {
    .go-top-navi .go-menu-2nd .go-menu-item {
        margin: 0;
    }

    .go-top-navi .go-menu-2nd .go-menu-item:hover::before {
        top: calc((50px - 1em - 20px) / 2 + 1px);
    }

    .go-top-navi .go-menu-2nd .go-menu-link {
        padding: calc((50px - 1em) / 2) 20px;
    }

    /* 2階層目メニューのカーソル対応 v2.9.1 */
    .go-top-navi .go-menu-2nd .go-menu-link:hover {
        cursor: pointer;
    }

    /* 3階層メニューの詳細 */
    .go-menu-3rd > .go-menu {
        width: 1400px;
        justify-content: center;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-row {
        padding: 0 30px;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-row-separate {
        border-right: 1px dotted #bbb;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-series {
        position: relative;
        font-size: 1.2rem;
        font-weight: 600;
        line-height: 1.2;
        height: 20px;
        overflow: visible;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-series > img {
        display: block;
        position: relative;
        top: 0;
        left: 0;
        max-width: auto;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item-wrap {
        list-style: none;
        padding: 0;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item-wrap:not(:last-child) {
        margin: 0 0 40px 0;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item {
        position: relative;
        line-height: 1.5;
        margin: 15px 0;
        padding: 0 10px;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item::before {
        content: '';
        position: absolute;
        top: -5px;
        left: 0;
        width: 100%;
        height: calc(1em + 10px);
        background: rgba(84, 138, 255, 0);
        border-radius: 9999px;
        transform: scale(.7);
        transition: background-color .2s ease-out, transform .2s ease-out;
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item:hover::before {
        background: rgba(84, 138, 255, .2);
        transform: scale(1);
    }

    .go-top-navi .go-menu-3rd .go-menu-3rd-item.go-2lines::before {
        height: calc(2em + 10px);
    }

    .go-top-navi .go-menu-3rd .go-menu-link {
        font-size: 15px;
        font-weight: 400;
        padding: 0;
    }

    /* 3階層目メニューのカーソル対応 v2.9.1 */
    .go-top-navi .go-menu-3rd .go-menu-link:hover {
        cursor: pointer;
    }

    .go-top-navi .go-item-separator {
        color: #999;
        font-weight: 200;
    }
}

/* ====================
 * 検索バー共通スタイル
 * ==================== */
.go-top-navi-search {
    position: fixed;
    top: 0;
    width: 100%;
    height: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(180deg,rgba(243, 243, 243, 1) 0%, rgba(210, 210, 210, 1) 80%);
    border-bottom: 1px solid #999;
    padding: 0 10px;
    font-size: 15px;
    z-index: 10006;
    opacity: 0;
    transform: translateY(-100%);
    transition: opacity .3s ease-in, transform .3s ease-in;
}

.go-top-navi-search.active {
    opacity: 1;
    transform: translateY(0);
}

.go-top-navi-search .go-header-search-inner {
    display: flex;
    align-items: center;
}

.go-top-navi-search .go-header-search-inner > label {
    margin: 0;
}

.go-top-navi-search .go-header-search-submit {
    position: relative;
    display: inline-block;
    width: 32px;
    height: 32px;
    margin-left: 2px;
    opacity: .6;
    transform: scale(1);
    transition: opacity ease-out .2s;
}

.go-top-navi-search .go-header-search-submit:hover {
    opacity: 1;
}

.go-top-navi-search .go-header-search-close {
    position: relative;
    display: inline-block;
    width: 32px;
    height: 32px;
    margin-left: 10px;
    opacity: .6;
    transform: scale(1);
    transition: opacity ease-out .2s;
}

.go-top-navi-search .go-header-search-close:hover {
    opacity: 1;
}

.go-top-navi-search .go-header-search-field {
    width: 500px;
    font-size: 18px;
    outline: none;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 2px .5em;
    margin: 0 8px 0 1px;
}

.go-top-navi-search .go-header-search-field::placeholder {
    color: #999;
}

.go-top-navi-search .go-header-search-field:focus {
    background: rgba(245,245,255,1);
    border: 2px solid royalblue;
}

/* デスクトップ用検索バー詳細スタイル */
@media (min-width: 769px) {
    .go-top-navi .go-header-search-inner {
        display: flex;
        align-items: center;
        padding-right: 2em;
    }

    .go-top-navi .go-header-search-submit {
        width: 1.2em;
        height: 1.2em;
    }

    .go-top-navi .go-header-search-field {
        font-size: 16px;
        outline: none;
        border: 1px solid #bbb;
        border-radius: 4px;
        padding: 2px .5em;
        margin: 0 1px 0 8px;
    }

    .go-top-navi .go-header-search-field::placeholder {
        color: #999;
    }

    .go-top-navi .go-header-search-field:focus {
        border: 2px solid royalblue;
        margin: 0 0 0 7px;
    }
}

/* ====================
 * モバイルヘッダー基本設定
 * ==================== */
.go-mobile-header {
    display: none;
}

.go-mobile-menu-overlay {
    display: none;
}

/* ====================
 * モバイルレスポンシブ
 * ==================== */
@media (max-width: 768px) {
    /* デスクトップヘッダーを非表示 */
    .go-desktop-header {
        display: none !important;
    }

    /* モバイルヘッダーを表示 */
    .go-mobile-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        position: fixed;
        top: 0;
        width: 100%;
        height: 60px;
        background: #f3f3f3;
        padding: 0 15px;
        border-bottom: 1px solid #d9d9d9;
        box-shadow: 0px 1px 6px 0px rgba(0, 0, 0, 0.25);
        z-index: 10005;
    }

    .go-mobile-logo img {
        aspect-ratio: 380 / 76;
        width: calc(380px * .5);
        max-width: calc(380px * .5);
    }

    /* ハンバーガーメニューボタン */
    .go-mobile-menu-toggle {
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        width: 30px;
        height: 30px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
    }

    .go-hamburger-line {
        width: 20px;
        height: 2px;
        background: #000;
        margin: 2px 0;
        transition: 0.3s;
        border-radius: 1px;
    }

    .go-mobile-menu-toggle.active .go-hamburger-line:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .go-mobile-menu-toggle.active .go-hamburger-line:nth-child(2) {
        opacity: 0;
    }

    .go-mobile-menu-toggle.active .go-hamburger-line:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }

    /* モバイルメニューオーバーレイ */
    .go-mobile-menu-overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.8);
        z-index: 10010;
        overflow-y: auto;
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
    }

    .go-mobile-menu-overlay.active {
        display: block;
        transform: translateX(0);
    }

    .go-mobile-menu-container {
        width: 85%;
        max-width: 350px;
        height: 100%;
        background: #fff;
        overflow-y: auto;
    }

    .go-mobile-menu-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 15px 20px;
        border-bottom: 1px solid #eee;
        background: #f8f8f8;
    }

    .go-mobile-menu-overlay .go-mobile-logo > span {
        display: block;
        width: 40px;
        overflow: hidden;
    }
  
    .go-mobile-menu-close {
        width: 30px;
        height: 30px;
        background: none;
        border: none;
        cursor: pointer;
        position: relative;
    }

    .go-close-icon::before,
    .go-close-icon::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        width: 16px;
        height: 2px;
        background: #000;
        border-radius: 1px;
    }

    .go-close-icon::before {
        transform: translate(-50%, -50%) rotate(45deg);
    }

    .go-close-icon::after {
        transform: translate(-50%, -50%) rotate(-45deg);
    }

    /* モバイルメニューコンテンツ */
    .go-mobile-menu-content {
        padding: 0;
    }

    .go-mobile-menu-list {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .go-mobile-menu-item {
        border-bottom: 1px solid #eee;
    }

    .go-mobile-menu-link {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 15px 20px;
        font-size: 16px;
        font-weight: 500;
        color: #000;
        font-family: 'Noto Sans JP', sans-serif;
        text-decoration: none;
        background: none;
        border: none;
        width: 100%;
        text-align: left;
        cursor: pointer;
    }

    .go-mobile-menu-link:hover,
    .go-mobile-menu-link:focus {
        background: #f5f5f5;
    }

    /* モバイルメニューのカーソル対応 v2.9.1 */
    .go-mobile-menu-link:hover {
        cursor: pointer;
    }

    /* 矢印アイコン */
    .go-arrow-icon {
        width: 0;
        height: 0;
        border-left: 6px solid transparent;
        border-right: 6px solid transparent;
        border-top: 6px solid #666;
        transition: transform 0.3s;
    }

    .go-submenu-toggle.active .go-arrow-icon {
        transform: rotate(180deg);
    }

    /* サブメニュー */
    .go-mobile-submenu {
        list-style: none;
        padding: 0;
        margin: 0;
        background: #f9f9f9;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-out;
    }

    .go-mobile-submenu.active {
        max-height: 10000px;
    }

    .go-mobile-submenu .go-mobile-menu-link {
        padding-left: 30px;
        font-size: 14px;
        font-weight: 400;
    }

    .go-mobile-submenu .go-mobile-submenu .go-mobile-menu-link {
        padding-left: 70px;
        font-size: 13px;
    }

    /* カテゴリー表示 */
    .go-mobile-menu-category {
        margin: 10px 0;
    }

    .go-mobile-category-title {
        font-size: 14px;
        font-weight: 600;
        color: #333;
        padding: 10px 20px 10px 40px;
        margin: 0;
        background: #f0f0f0;
        border-bottom: 1px solid #ddd;
    }

    .go-mobile-category-title::before {
        content: '＞';
        position: relative;
        left: -.5em;
        color: #aaa;
    }

    .go-mobile-category-list {
        list-style: none;
        padding: 0;
        margin: 0;
    }

    .go-mobile-category-list li {
        border-bottom: 1px solid #f0f0f0;
    }

    .go-mobile-submenu .go-mobile-submenu .go-mobile-category-list .go-mobile-menu-link {
        padding: 10px 20px 10px 60px;
        font-size: 13px;
    }

    /* ヘッダーの高さ調整 */
    .go-header-dummy {
        height: 60px;
    }
}

/* ====================
 * レスポンシブ調整
 * ==================== */
@media (max-width: 1100px) {
    .go-top-navi {
        font-size: 14px;
    }
    
    .go-top-navi .go-top-logo > a {
        width: 40px;
    }
    
    .go-top-navi .go-menu-link {
        padding-right: 10px;
        padding-left: 10px;
    }
}

@media (max-width: 480px) {
    .go-mobile-menu-container {
        width: 90%;
    }
}