/* ===== IR Filter ===== */
.ir-filter {
    width: 100%;
    font-family: "Noto Sans JP", "Hiragino Sans", "Yu Gothic", sans-serif;
}

/* --- 年セレクト --- */
.ir-filter__year-wrap {
    margin-bottom: 20px;
}

.ir-filter__year {
    appearance: none;
    -webkit-appearance: none;
    background: #fff url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="6"><polyline points="0,0 5,6 10,0" fill="none" stroke="%23333" stroke-width="1.5"/></svg>') no-repeat right 12px center;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 8px 36px 8px 14px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    min-width: 120px;
}

.ir-filter__year:focus {
    outline: none;
    border-color: #1a2e56;
}

/* --- カテゴリタブ --- */
.ir-filter__tabs {
    list-style: none;
    margin: 0 0 24px;
    padding: 0;
    display: flex;
    border-bottom: 2px solid #1a2e56;
}

.ir-filter__tab {
    flex: 1;
    text-align: center;
    padding: 10px 8px;
    font-size: 14px;
    color: #1a2e56;
    background: #e8ecf1;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    border-right: 1px solid #d0d5dc;
    user-select: none;
}

.ir-filter__tab:last-child {
    border-right: none;
}

.ir-filter__tab:hover {
    background: #cdd4de;
}

.ir-filter__tab.is-active {
    background: #1a2e56;
    color: #fff;
}

/* --- 投稿テーブル --- */
.ir-filter__table {
    width: 100%;
    border-collapse: collapse;
}

.ir-filter__row {
    border-bottom: 1px solid #e5e5e5;
}

.ir-filter__row:hover {
    background: #f8f9fa;
}

.ir-filter__date {
    width: 110px;
    padding: 14px 12px;
    font-size: 14px;
    color: #666;
    white-space: nowrap;
    vertical-align: top;
}

.ir-filter__cat-label {
    width: 130px;
    padding: 14px 8px;
    vertical-align: top;
}

.ir-filter__badge {
    display: inline-block;
    font-size: 12px;
    color: #1a2e56;
    border: 1px solid #1a2e56;
    border-radius: 2px;
    padding: 2px 8px;
    white-space: nowrap;
}

.ir-filter__title {
    padding: 14px 12px;
    font-size: 14px;
    vertical-align: top;
}

.ir-filter__title a {
    color: #333;
    text-decoration: none;
}

.ir-filter__title a:hover {
    text-decoration: underline;
    color: #1a2e56;
}

/* --- 投稿エリア --- */
.ir-filter__posts {
    width: 100%;
    min-height: 200px;
}

/* --- 空 / ローディング --- */
.ir-filter__empty {
    text-align: center;
    padding: 40px 0;
    color: #999;
    font-size: 14px;
}

.ir-filter__loading {
    text-align: center;
    padding: 40px 0;
    color: #999;
    font-size: 14px;
}

.ir-filter__posts.is-loading {
    opacity: 0.5;
    pointer-events: none;
}

/* --- SP: カテゴリプルダウン（デフォルト非表示） --- */
.ir-filter__cat-wrap {
    display: none;
}

.ir-filter__cat-select {
    appearance: none;
    -webkit-appearance: none;
    background: #fff url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" width="10" height="6"><polyline points="0,0 5,6 10,0" fill="none" stroke="%23333" stroke-width="1.5"/></svg>') no-repeat right 12px center;
    border: 1px solid #ccc;
    border-radius: 4px;
    padding: 8px 36px 8px 14px;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    width: 100%;
}

.ir-filter__cat-select:focus {
    outline: none;
    border-color: #1a2e56;
}

/* ===== SP (768px以下) ===== */
@media (max-width: 768px) {

    /* カテゴリ: タブ非表示 → プルダウン表示 */
    .ir-filter__tabs {
        display: none;
    }

    .ir-filter__cat-wrap {
        display: block;
        margin-bottom: 16px;
    }

    /* 年セレクトもフル幅に */
    .ir-filter__year {
        width: 100%;
    }

    /* テーブル → カード型リスト */
    .ir-filter__table {
        display: block;
    }

    .ir-filter__table tbody {
        display: block;
    }

    .ir-filter__row {
        display: flex;
        flex-wrap: wrap;
        padding: 12px 0;
        border-bottom: 1px solid #e5e5e5;
    }

    .ir-filter__date,
    .ir-filter__cat-label,
    .ir-filter__title {
        display: block;
    }

    .ir-filter__date {
        width: auto;
        padding: 0 8px 0 0;
        font-size: 13px;
    }

    .ir-filter__cat-label {
        width: auto;
        padding: 0;
    }

    .ir-filter__title {
        width: 100%;
        padding: 6px 0 0;
    }
}
