/* ベースラッパー */
.tria-store-wrapper {
    margin: 2em 0;
    font-family: inherit;
}

/* --- フィルターエリア --- */
.tria-filters {
    /* 全体を囲うグレー背景をなくし、スッキリさせます */
    margin-bottom: 30px;
}

/* 各フィルターの囲み（おしゃれなカード風） */
.filter-group {
    background: #ffffff;
    border: 1px solid #eef2f5; /* 薄い囲み線 */
    border-radius: 12px;
    padding: 12px 20px;
    margin-bottom: 15px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.03); /* 柔らかい影で浮き出させる */
    display: flex;
    align-items: center;
}
.filter-group:last-child {
    margin-bottom: 0;
}

/* ラベルデザイン（太文字＋区切り線） */
.filter-label {
    font-weight: 800; /* 全て太文字に */
    color: #1e293b;
    padding-right: 18px; /* 右側の余白 */
    margin-right: 18px;
    border-right: 2px solid #e2e8f0; /* PC用の縦の区切り線 */
    flex-shrink: 0;
    font-size: 0.95em;
    letter-spacing: 0.5px;
}

/* スマホ対応: ボタンスワイプエリア */
.filter-btn-scroll-container {
    display: flex;
    gap: 10px;
    width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 2px;
}
.filter-btn-scroll-container::-webkit-scrollbar {
    display: none;
}

/* ボタンデザイン（太文字化） */
.filter-btn {
    flex: 1 0 calc(33.33% - 6px);
    min-width: 80px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    padding: 8px 10px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 700; /* 太文字に */
    color: #475569;
    transition: all 0.3s ease;
    text-align: center;
}
.filter-btn:hover {
    background: #e2e8f0;
}
.filter-btn.active {
    background: #1e293b;
    color: #fff;
    border-color: #1e293b;
    box-shadow: 0 3px 8px rgba(30,41,59,0.3);
}

/* プルダウンデザイン（太文字化） */
.filter-select-wrapper {
    width: 100%;
}
.filter-select {
    width: 100%;
    max-width: 300px;
    padding: 10px 15px;
    border: 2px solid #e2e8f0; /* 枠線を少し太くして高級感を */
    border-radius: 8px;
    background-color: #f8fafc;
    font-size: 0.95em;
    font-weight: 700; /* 太文字に */
    color: #1e293b;
    cursor: pointer;
    transition: border-color 0.3s ease;
}
.filter-select:focus {
    outline: none;
    border-color: #94a3b8;
}

/* --- スマホ向け微調整 --- */
@media (max-width: 600px) {
    .filter-group {
        flex-direction: column;
        align-items: stretch;
        padding: 15px;
    }
    .filter-label {
        /* スマホ時は縦並びになるため、区切り線を「下線」に変更 */
        padding-right: 0;
        margin-right: 0;
        border-right: none;
        padding-bottom: 10px;
        margin-bottom: 12px;
        border-bottom: 2px dotted #cbd5e1; /* スマホはおしゃれな点線の下線に */
        text-align: left;
        width: 100%;
    }
    .filter-select {
        max-width: 100%; /* スマホでは横幅いっぱいにする */
    }
}

/* --- リスト・カードレイアウト --- */
.tria-store-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* 高級感のあるカードスタイル */
.tria-store-card {
    display: flex;
    align-items: stretch; /* 左側の高さを揃える */
    padding: 20px;
    border-radius: 12px;
    background: #fff;
    border: 1px solid #ebebeb;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.tria-store-card:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

/* 利用可否で左端のボーダー色を変える */
.tria-store-card.status-usable { border-left: 5px solid #28a745; }
.tria-store-card.status-unusable { border-left: 5px solid #dc3545; }


/* --- 左側（アイコン＆カテゴリ） --- */
.tria-store-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 80px;
    flex-shrink: 0;
    margin-right: 20px;
}
.tria-store-icon {
    width: 80px;
    height: 80px;
    border-radius: 12px; /* 少し丸みを強く */
    overflow: hidden;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.05); /* 内側に微細な影 */
}
.tria-store-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.no-icon {
    font-size: 11px;
    color: #999;
}
/* --- タイトル横に来るカテゴリバッジ（文字幅に合わせて並べる） --- */
.tria-store-cat-badge {
    background: #eaf2fb;
    color: #2b5e94;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.8em;
    font-weight: bold;
    line-height: 1.2;
}


/* --- 右側（情報エリア） --- */
.tria-store-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.tria-store-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

/* 見出しの代わり */
.tria-store-title {
    margin: 0;
    font-size: 1.3em;
    font-weight: bold;
    color: #222;
    line-height: 1.3;
}

/* --- アイコン下に来るステータスバッジ（幅100%で中央揃え） --- */
.tria-status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.75em;
    font-weight: bold;
    color: #fff;
    text-align: center;
    line-height: 1.2;
    width: 100%;
    word-break: auto-phrase;
    letter-spacing: 0.5px;
}
.tria-status-badge.status-usable { background: #28a745; }
.tria-status-badge.status-unusable { background: #dc3545; }

/* 備考欄（一番下になるのでmargin-bottomを0に修正） */
.tria-store-bikou {
    background: #f9fbfd;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 0.9em;
    color: #444;
    margin-bottom: 0; /* ★変更: 一番下なので余白を無くす */
    border: 1px solid #eef2f5;
}

/* 公式サイトボタン（下に備考欄が来るための余白を追加） */
.tria-store-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    background: #1e293b;
    color: #fff !important;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9em;
    font-weight: 600;
    text-decoration: none !important;
    transition: background 0.3s ease;
    margin-bottom: 12px; /* ★追加: 下の備考欄との余白 */
}
.tria-store-link-btn:hover {
    background: #334155;
}


/* JSフィルター時の非表示クラス */
.tria-store-card.hidden {
    display: none !important;
}

/* --- スマホ向け微調整 --- */
@media (max-width: 600px) {
    .filter-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    .filter-label {
        margin-right: 0;
    }
    .tria-store-card {
        padding: 15px;
    }
}

/* 既存のCSSの最後などに追加 */

.filter-search-wrapper {
    width: 100%;
}

.filter-search-input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    background-color: #f8fafc;
    font-size: 0.95em;
    font-weight: 700; /* 太文字 */
    color: #1e293b;
    transition: all 0.3s ease;
    -webkit-appearance: none;
}

.filter-search-input:focus {
    outline: none;
    border-color: #1e293b;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(30,41,59,0.1);
}

/* スマホ表示での調整 */
@media (max-width: 600px) {
    .filter-search-input {
        font-size: 16px; /* iPhoneでのズーム防止 */
    }
}

/* --- フローティング開閉パネル関連のスタイル（完全版） --- */

/* 右下固定のFABボタン */
.tria-filter-fab {
    position: fixed;
    bottom: 100px; right: 25px;
    background-color: #1e293b;
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 14px 24px;
    font-size: 15px; font-weight: 700;
    box-shadow: 0 4px 15px rgba(30,41,59,0.3);
    cursor: pointer;
    z-index: 9990;
    display: flex; align-items: center; gap: 8px;
    transition: transform 0.2s, background 0.2s;
}
.tria-filter-fab:hover {
    background-color: #334155;
    transform: translateY(-2px);
}

/* ★新規：画面全体を覆う絶対領域コンテナ */
.tria-filter-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    visibility: hidden;
    overflow: hidden; /* ★ここを1行追加！画面外のハミ出しを完全に断ち切ります */
}
.tria-filter-modal.is-active {
    pointer-events: auto;
    visibility: visible;
}

/* モーダル背景（オーバーレイ） */
.tria-filter-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(3px);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.tria-filter-modal.is-active .tria-filter-overlay {
    opacity: 1;
}

/* フィルターパネル本体 */
.tria-filter-panel {
    position: relative;
    background: #ffffff;
    margin: 0; border: none;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    /* PC表示用 */
    width: 500px; max-width: 90vw;
    border-radius: 16px;
    opacity: 0;
    transform: scale(0.95);
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.tria-filter-modal.is-active .tria-filter-panel {
    opacity: 1;
    transform: scale(1);
}

/* --- スマホ表示時のパネル --- */
@media (max-width: 600px) {
    .tria-filter-fab { bottom: 80px; right: 20px; padding: 12px 20px; }
    
    .tria-filter-modal {
        justify-content: flex-end; /* スマホは下寄せ */
    }
    .tria-filter-panel {
        width: 100%; max-width: 100%;
        border-radius: 20px 20px 0 0;
        padding: 20px 20px 40px;
        max-height: 85vh;
        overflow-y: auto;
        /* 絶対領域内で下に隠すので安全 */
        transform: translateY(100%); 
        opacity: 1; 
    }
    .tria-filter-modal.is-active .tria-filter-panel {
        transform: translateY(0);
    }
}

/* ヘッダー・ボタン類 */
.tria-filter-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 20px; padding-bottom: 15px; border-bottom: 2px solid #f1f5f9;
}
.tria-filter-title { font-weight: 800; font-size: 1.1em; color: #1e293b; }
.tria-filter-close {
    background: #f1f5f9; border: none; border-radius: 50%;
    width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
    cursor: pointer; color: #64748b; transition: background 0.2s;
}
.tria-filter-close:hover { background: #e2e8f0; color: #1e293b; }
.tria-filter-apply-btn {
    width: 100%; background: #2563eb; color: #fff; border: none;
    padding: 14px; border-radius: 8px; font-size: 1em; font-weight: bold;
    cursor: pointer; margin-top: 10px; transition: background 0.2s;
}
.tria-filter-apply-btn:hover { background: #1d4ed8; }

/* --- wpautop（自動段落）暴走対策 --- */
.tria-store-wrapper p:empty,
.tria-store-wrapper br,
.tria-filter-modal p,
.tria-filter-modal br {
    display: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* --- トップセクション（ヒーローバナー＆CTA） --- */
.tria-top-section {
    margin-bottom: 40px;
}

/* ヒーローバナー（高級感のあるダークトーン） */
.tria-hero-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding: 35px 40px;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 25px;
}

/* --- 変更：クレカ画像の装飾（レイアウト調整と枠線の追加） --- */
.tria-hero-image {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px; /* 画像と下の文字の隙間 */
}
.tria-hero-image img {
    width: 160px;
    height: auto;
    border-radius: 8px;
    /* ★追加：カードの輪郭をはっきりさせる枠線 */
    border: 1px solid rgba(255, 255, 255, 0.25); 
    box-shadow: 0 15px 35px rgba(0,0,0,0.5);
    transform: rotate(-4deg) translateY(-2px);
    transition: transform 0.3s ease;
}
.tria-hero-image img:hover {
    transform: rotate(0deg) translateY(0) scale(1.03);
}

/* ★追加：カード下のテキスト */
.tria-card-caption {
    font-size: 0.75em;
    color: #94a3b8; /* 薄いグレーブルー */
    font-weight: bold;
    letter-spacing: 0.5px;
}

/* キャッチコピー */
.tria-hero-text {
    font-size: 1.7em;
    font-weight: 900;
    color: #ffffff;
    line-height: 1.4;
    margin: 0;
    letter-spacing: 0.5px;
}
.sp-only {
    display: none;
}

/* CTAボックス（情報提供フォームへの誘導） */
.tria-cta-box {
    background: #f8fafc;
    border: 2px dashed #cbd5e1; /* 点線で目立たせる */
    border-radius: 16px;
    padding: 25px 20px;
    text-align: center;
}
.tria-cta-title {
    font-size: 1.25em;
    font-weight: 800;
    color: #1e293b;
    margin: 0 0 10px 0;
}
.tria-cta-desc {
    font-size: 0.95em;
    color: #475569;
    font-weight: 600;
    margin: 0 0 20px 0;
    line-height: 1.5;
}

/* フォームボタン */
.tria-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #2563eb; /* 目を引く鮮やかなブルー */
    color: #fff !important;
    padding: 14px 35px;
    border-radius: 50px;
    font-size: 1.05em;
    font-weight: bold;
    text-decoration: none !important;
    box-shadow: 0 4px 15px rgba(37,99,235,0.3);
    transition: all 0.3s ease;
}
.tria-cta-btn:hover {
    background: #1d4ed8;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37,99,235,0.4);
}

/* --- スマホ表示時の微調整 --- */
@media (max-width: 600px) {
    .tria-hero-banner {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
        gap: 20px;
    }
    .tria-hero-image img {
        width: 150px;
        transform: rotate(-4deg); /* スマホではまっすぐに */
    }
    .tria-hero-image img:hover {
        transform: none;
    }
    .tria-hero-text {
        font-size: 1.35em;
    }
    .sp-only {
        display: block; /* スマホの時だけ改行を入れる */
    }
    .tria-cta-box {
        padding: 20px 15px;
    }
    .tria-cta-btn {
        width: 100%;
        justify-content: center;
    }
}

/* --- サービス一覧の見出し（hタグの代用） --- */
.tria-list-heading {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.4em;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid #e2e8f0;
    letter-spacing: 0.5px;
}
.tria-list-heading svg {
    color: #2563eb; /* アクセントのブルー */
}

/* スマホ表示時の微調整 */
@media (max-width: 600px) {
    .tria-list-heading {
        font-size: 1.25em;
        margin-bottom: 15px;
    }
}

/* リスト直上のクイックフィルター */
.tria-quick-filters {
    margin-bottom: 20px;
    padding: 0 5px;
}

/* スマホでボタンが横に並びすぎる場合の調整 */
@media (max-width: 600px) {
    .tria-quick-filters .filter-btn {
        font-size: 0.85em;
        padding: 10px 5px;
    }
}