/**
 * 特集ページ共通 + カスタム記事（Feature/custom/*.twig）スタイル
 * 記事側では原則 <style> を書かず、このファイルに寄せる。
 */

/* アイキャッチ＋タイトル（naire ヒーローと同系統） */
.feature-hero {
    position: relative;
    margin-bottom: 16px;
    border-radius: 6px;
    overflow: hidden;
}

.feature-hero__image {
    width: 100%;
    max-height: 360px;
    object-fit: cover;
    display: block;
}

.feature-hero__overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: #fff;
    padding: 40px 24px 24px;
}

.feature-hero__title {
    font-size: 2rem;
    font-weight: bold;
    margin: 0;
    line-height: 1.3;
    color: #fff;
}

.feature-hero__title--plain {
    color: #222;
    font-size: 1.75rem;
    margin: 0 0 16px;
}

/* カスタム記事 → コラム一覧への戻り導線 */
.feature-hero__back {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    display: inline-block;
    padding: 5px 10px;
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.3;
    letter-spacing: 0.02em;
    text-decoration: none;
    transition: background-color 0.15s ease;
}

.feature-hero__back:hover,
.feature-hero__back:focus {
    background: rgba(0, 0, 0, 0.72);
    color: #fff;
    text-decoration: none;
}

/* アイキャッチ右上：お気に入り☆（コラム一覧の反対側） */
.feature-hero__favorite {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    margin: 0;
}

.feature-hero__favorite-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: rgba(128, 128, 128, 0.8);
    color: #fff;
    cursor: pointer;
    line-height: 1;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    transition: background-color 0.15s ease, transform 0.15s ease;
}

.feature-hero__favorite-btn:hover,
.feature-hero__favorite-btn:focus {
    background: rgba(110, 110, 110, 0.9);
    outline: none;
}

.feature-hero__favorite-btn.is-active {
    background: rgba(255, 196, 0, 0.8);
}

.feature-hero__favorite-btn.is-active:hover,
.feature-hero__favorite-btn.is-active:focus {
    background: rgba(230, 176, 0, 0.9);
    outline: none;
}

.feature-hero__favorite-star {
    display: block;
    font-size: 30px;
    font-weight: 400;
    line-height: 1;
    /* ☆ 字形は下に余白が多いので視覚中心を円の中央へ */
    transform: translateY(-0.1em);
}

.feature-hero--plain {
    position: relative;
    margin-bottom: 16px;
}

.feature-hero--plain .feature-hero__favorite {
    top: 0;
    right: 0;
}

.feature-hero--plain .feature-hero__title--plain {
    padding-right: 72px;
}

/* カテゴリ・タグ／コラム一覧（左）＋シェア（右） */
.feature-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    justify-content: space-between;
    gap: 8px 16px;
    margin: 0 0 16px;
}

.feature-meta-row--footer {
    margin: 28px 0 8px;
    padding-top: 16px;
    border-top: 1px solid #eee;
    align-items: center;
}

.feature-meta-row__main {
    flex: 1 1 200px;
    min-width: 0;
}

.feature-meta-row__main:empty {
    display: none;
}

@media only screen and (max-width: 767px) {
    .feature-meta-row {
        gap: 10px 12px;
    }

    /* 左ブロックが伸びてもシェアと被らないよう、狭い幅ではシェアを下段右へ */
    .feature-meta-row .site-share {
        flex: 1 1 100%;
        justify-content: flex-end;
        margin-left: 0;
    }
}

.feature-article-back {
    margin: 0;
}

.feature-article-back a {
    color: #666;
    text-decoration: none;
}

.feature-article-back a:hover,
.feature-article-back a:focus {
    color: #fe8f00;
    text-decoration: underline;
}

.feature-article-back--plain {
    margin: 0 0 8px;
}

.feature-article-back--plain a {
    font-size: 13px;
    font-weight: 600;
}

.feature-article-back--footer {
    margin: 0;
    text-align: left;
}

.feature-article-back--footer a {
    font-size: 14px;
    font-weight: 600;
}

@media only screen and (max-width: 767px) {
    .feature-hero__overlay {
        padding: 28px 16px 16px;
    }

    .feature-hero__title {
        font-size: 1.35rem;
    }

    .feature-hero__title--plain {
        font-size: 1.35rem;
    }

    .feature-hero__back {
        top: 8px;
        left: 8px;
        padding: 4px 8px;
        font-size: 11px;
    }

    .feature-hero__favorite {
        top: 8px;
        right: 8px;
    }

    .feature-hero__favorite-btn {
        width: 32px;
        height: 32px;
    }

    .feature-hero__favorite-star {
        font-size: 18px;
    }
}

/* カスタム記事本文。セレクタは .feature-custom 配下に閉じる */
.feature-custom .feature-custom__body {
    margin: 0 0 16px;
    font-size: 14px;
    line-height: 1.8;
    color: #333;
}

.feature-custom .feature-custom__lead {
    margin: 0 0 1.25em;
    font-size: 15px;
}

/* 補足・注意（リードや段落の直後など） */
.feature-custom .feature-custom__note {
    font-size: 12px;
    line-height: 1.7;
    color: #888;
}

.feature-custom .feature-custom__heading {
    margin: 2.5em 0 0.6em;
    padding-bottom: 0.35em;
    border-bottom: 1px solid #e5e5e5;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
    color: #222;
}

/* 商品カード内の品名・価格なども p のため、一旦 0。記事本文の直下 p だけ余白を残す */
.feature-custom .feature-custom__body p {
    margin: 0;
}

.feature-custom .feature-custom__body > p {
    margin: 0 0 1em;
}

.feature-custom .feature-custom__body > p.feature-custom__note {
    margin: -0.5em 0 1.25em;
    font-size: 12px;
    line-height: 1.7;
    color: #888;
}

.feature-custom .feature-custom__list {
    margin: 0 0 1.25em;
    padding: 0 0 0 1.2em;
}

.feature-custom .feature-custom__list li {
    margin: 0 0 0.85em;
}

.feature-custom .feature-custom__list li:last-child {
    margin-bottom: 0;
}

.feature-custom .feature-custom__list strong {
    display: inline;
    margin-right: 0.35em;
}

.feature-custom .feature-custom__products {
    margin: 2em 0;
}

.feature-custom .feature-custom__products .ec-shelfGrid {
    margin-bottom: 0;
    row-gap: 24px;
}

/* 一覧用の item 下余白(36px)がブロック下だけ広く見えるため、内側は gap で揃える */
.feature-custom .feature-custom__products .ec-shelfGrid__item {
    margin-bottom: 0;
}

.feature-custom .feature-custom__cta {
    margin: 0;
    padding: 0.9em 1em;
    background: #f7f7f7;
    border-left: 3px solid #c45c26;
    font-weight: 600;
}

/* パターンB記事トップ: 関連カテゴリ・関連タグ（商品詳細と同じ見た目） */
.feature-meta-row .feature-article-related.custom-category-area {
    margin: 0 0 8px;
}

.feature-meta-row .feature-article-related.custom-product-tags-card {
    margin: 0;
}

.feature-article-related.custom-category-area {
    margin: 0 0 8px;
    font-size: 12px;
    line-height: 1.6;
}

.feature-article-related.custom-category-area ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.feature-article-related.custom-category-area ul + ul {
    margin-top: 4px;
}

.feature-article-related.custom-category-area a {
    color: #2563eb;
    text-decoration: none;
}

.feature-article-related.custom-category-area a:hover {
    color: #1d4ed8;
    text-decoration: underline;
}

.feature-article-related.custom-category-area span {
    margin: 0 0.25em;
    color: #999;
}

.feature-article-related.custom-product-tags-card {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    list-style: none;
    padding: 0;
    margin: 0 0 16px;
}

.feature-article-related.custom-product-tags-card .custom-tag-card-item {
    display: inline-block;
    padding: 4px 8px;
    background-color: transparent;
    color: #000;
    font-size: 0.9em;
    border-radius: 4px;
    border: 1px solid #2563eb;
    font-weight: 500;
}

.feature-article-related.custom-product-tags-card .custom-tag-card-item a {
    color: inherit;
    text-decoration: none;
}

.feature-article-related.custom-product-tags-card .custom-tag-card-item:has(a) {
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.feature-article-related.custom-product-tags-card .custom-tag-card-item:has(a):hover {
    background-color: #2563eb;
    color: #fff;
}

.feature-article-related.custom-product-tags-card .custom-tag-card-item:has(a):hover a {
    color: #fff;
}

/* コラム一覧 /features */
.feature-column-list__header {
    width: 100%;
    margin: 0 0 20px;
    box-sizing: border-box;
}

.feature-column-list__lead {
    margin: 0 0 6px;
    color: #333;
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.5;
}

.feature-column-list__intro {
    margin: 0;
    width: 100%;
    max-width: none;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.7;
}

.feature-column-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.feature-column-list__item {
    margin: 0;
    min-width: 0;
}

.feature-column-list__card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    width: 100%;
    min-height: 72px;
    padding: 12px 16px;
    background: #fff;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    border-left: 4px solid #fe8f00;
    box-sizing: border-box;
    color: #333;
    text-decoration: none;
    transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.feature-column-list__card:hover {
    border-color: #fe8f00;
    box-shadow: 0 4px 12px rgba(254, 143, 0, 0.18);
    transform: translateY(-1px);
    color: #333;
    text-decoration: none;
}

.feature-column-list__thumb {
    flex: 0 0 96px;
    width: 96px;
    height: 64px;
    margin-top: 2px;
    border-radius: 4px;
    overflow: hidden;
    background: #f5f5f5;
}

.feature-column-list__thumb img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feature-column-list__body {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.feature-column-list__title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.45;
    color: #222;
}

.feature-column-list__excerpt {
    font-size: 13px;
    font-weight: 400;
    line-height: 1.55;
    color: #999;
}

.feature-column-list__card:hover .feature-column-list__excerpt {
    color: #888;
}

.feature-column-list__arrow {
    flex: 0 0 auto;
    align-self: center;
    color: #fe8f00;
    font-size: 18px;
    font-weight: 700;
    line-height: 1;
}

.feature-column-list__empty {
    margin: 24px 0 0;
    color: #666;
}

@media only screen and (max-width: 767px) {
    .feature-column-list__card {
        min-height: 64px;
        padding: 10px 12px;
        gap: 10px;
    }

    .feature-column-list__thumb {
        flex-basis: 72px;
        width: 72px;
        height: 52px;
    }

    .feature-column-list__title {
        font-size: 14px;
    }

    .feature-column-list__excerpt {
        font-size: 12px;
    }
}

/* マイページお気に入り：タブ（1:1 等幅） */
.ec-favoriteTabs {
    display: flex;
    width: 100%;
    gap: 0;
    margin: 0 0 20px;
    border-bottom: 1px solid #ddd;
}

.ec-favoriteTabs__item {
    position: relative;
    flex: 1 1 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 16px;
    color: #666;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    text-align: center;
}

.ec-favoriteTabs__item:hover,
.ec-favoriteTabs__item:focus {
    color: #333;
    text-decoration: none;
}

.ec-favoriteTabs__item.is-active {
    color: #222;
    border-bottom-color: #DE5D50;
}

.ec-favoriteTabs__count {
    display: inline-block;
    min-width: 1.4em;
    padding: 0 6px;
    border-radius: 10px;
    background: #f0f0f0;
    color: #555;
    font-size: 12px;
    font-weight: 600;
    line-height: 1.6;
    text-align: center;
}

.ec-favoriteTabs__item.is-active .ec-favoriteTabs__count {
    background: #fde8e6;
    color: #c44;
}

/* マイページお気に入り：特集・コラム一覧 */
.ec-favoriteFeatureList {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ec-favoriteFeatureList__item {
    position: relative;
}

.ec-favoriteFeatureList__card {
    position: relative;
    min-height: 88px;
    border: 1px solid #e5e5e5;
    border-radius: 6px;
    background: #fff;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.ec-favoriteFeatureList__card:hover {
    border-color: #ccc;
    background: #fafafa;
}

.ec-favoriteFeatureList__link {
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 88px;
    padding: 12px 40px 12px 14px;
    text-decoration: none;
    color: inherit;
}

.ec-favoriteFeatureList__link:hover,
.ec-favoriteFeatureList__link:focus {
    text-decoration: none;
    color: inherit;
}

.ec-favoriteFeatureList__remove {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #B8BEC4;
    text-decoration: none;
    box-shadow: none;
    transition: background-color 0.15s ease;
}

.ec-favoriteFeatureList__remove:hover,
.ec-favoriteFeatureList__remove:focus {
    background: #9aa1a8;
    outline: none;
}

.ec-favoriteFeatureList__remove img {
    display: block;
    width: 10px;
    height: 10px;
}

.ec-favoriteFeatureList__thumb {
    flex: 0 0 120px;
    width: 120px;
    height: 72px;
    border-radius: 4px;
    overflow: hidden;
    background: #f3f3f3;
}

.ec-favoriteFeatureList__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ec-favoriteFeatureList__body {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ec-favoriteFeatureList__badge {
    display: inline-block;
    align-self: flex-start;
    padding: 1px 8px;
    border-radius: 3px;
    background: #f5f5f5;
    color: #666;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.6;
}

.ec-favoriteFeatureList__title {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    color: #222;
}

.ec-favoriteFeatureList__arrow {
    flex: 0 0 auto;
    color: #999;
    font-size: 18px;
}

@media only screen and (max-width: 767px) {
    .ec-favoriteTabs__item {
        padding: 10px 8px;
        font-size: 13px;
    }

    .ec-favoriteFeatureList__card,
    .ec-favoriteFeatureList__link {
        min-height: 72px;
    }

    .ec-favoriteFeatureList__link {
        padding: 10px 34px 10px 12px;
        gap: 10px;
    }

    .ec-favoriteFeatureList__remove {
        top: 6px;
        right: 6px;
        width: 20px;
        height: 20px;
    }

    .ec-favoriteFeatureList__remove img {
        width: 9px;
        height: 9px;
    }

    .ec-favoriteFeatureList__thumb {
        flex-basis: 88px;
        width: 88px;
        height: 56px;
    }

    .ec-favoriteFeatureList__title {
        font-size: 14px;
    }
}
