/* =============================================
   Film Festival Info — festival.css
   Lightning Free テーマに合わせたスタイル
============================================= */

/* ── 変数 ── */
:root {
    --ffi-blue:    #185FA5;
    --ffi-blue-lt: #E6F1FB;
    --ffi-blue-bd: #85B7EB;
    --ffi-green:   #0F6E56;
    --ffi-green-lt:#E1F5EE;
    --ffi-green-bd:#5DCAA5;
    --ffi-amber:   #BA7517;
    --ffi-amber-lt:#FAEEDA;
    --ffi-gray:    #5F5E5A;
    --ffi-gray-lt: #F1EFE8;
    --ffi-border:  rgba(0,0,0,.12);
    --ffi-radius:  8px;
    --ffi-radius-lg:12px;
}

/* =============================================
   バッジ
============================================= */
.ffi-badge {
    display: inline-block;
    font-size: 11px;
    padding: 2px 10px;
    border-radius: 20px;
    line-height: 1.6;
    vertical-align: middle;
}
.ffi-badge-recruiting { background: var(--ffi-blue-lt); color: var(--ffi-blue); }
.ffi-badge-event      { background: var(--ffi-green-lt);color: var(--ffi-green); }
.ffi-badge-upcoming   { background: var(--ffi-amber-lt); color: var(--ffi-amber); }
.ffi-badge-scheduled  { background: #F0EFEB; color: #888; }
.ffi-badge-ended      { background: var(--ffi-gray-lt);  color: var(--ffi-gray); }
/* 地域限定バッジ（v8.9.67追加）：カード背景がグレー系(.ffi-card-local)になるため、
   同化して見えなくならないよう一段濃いグレーで視認性を確保する */
.ffi-badge-local      { background: #D8D8D8; color: #555; }
.ffi-badge-days  { font-size:11px; padding:2px 8px; border-radius:20px; background:#f0f0f0; color:#555; }
.ffi-badge-date  { font-size:11px; padding:2px 8px; border-radius:20px; background:#f5f5f5; color:#666; }

/* =============================================
   フィルターバー
============================================= */
/* フリーワード検索：フィルターバーより上に独立させ、大きく目立たせる */
.ffi-search-bar-wrap {
    margin-bottom: 12px;
}
.ffi-search-bar-input {
    width: 100%;
    box-sizing: border-box;
    font-size: 16px;
    padding: 14px 18px;
    border: 1.5px solid var(--ffi-blue-bd, #85B7EB);
    border-radius: 10px;
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.ffi-search-bar-input:focus {
    outline: none;
    border-color: var(--ffi-blue);
    box-shadow: 0 0 0 3px var(--ffi-blue-lt);
}
.ffi-search-bar-input::placeholder {
    color: #999;
}

.ffi-filter-bar {
    background: #fff;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    padding: 10px 14px;
    margin-bottom: 14px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    align-items: center;
}
.ffi-filter-label  { font-size: 12px; color: #666; }
.ffi-filter-select { font-size: 12px; padding: 4px 10px; border: 0.5px solid #ccc; border-radius: var(--ffi-radius); }

/* =============================================
   カードグリッド
============================================= */
.ffi-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}
.ffi-card {
    display: block;
    background: #fff;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius-lg);
    padding: 12px;
    text-decoration: none;
    color: inherit;
    position: relative;
    overflow: hidden;
    transition: border-color .15s, box-shadow .15s;
}
.ffi-card:hover {
    border-color: #aaa;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    text-decoration: none;
    color: inherit;
}
/* 地域限定の映画祭：一覧で他の投稿と見分けられるよう背景をグレー系にする（v8.9.65追加） */
.ffi-card.ffi-card-local {
    background: #F2F2F2;
}
.ffi-card.ffi-card-local:hover {
    background: #ECECEC;
}
.ffi-card-bar {
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
}
.ffi-card-bar-recruiting { background: var(--ffi-blue); }
.ffi-card-bar-event      { background: var(--ffi-green); }
.ffi-card-bar-upcoming   { background: var(--ffi-amber); }
.ffi-card-bar-scheduled  { background: #AAA; }
.ffi-card-bar-ended      { background: #ccc; }
.ffi-card-thumb {
    margin: -12px -12px 10px;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border-radius: var(--ffi-radius-lg) var(--ffi-radius-lg) 0 0;
    background: #F0EFEB;
}
.ffi-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.ffi-single-banner {
    width: 100%;
    max-height: 360px;
    overflow: hidden;
    border-radius: var(--ffi-radius-lg);
    margin-bottom: 16px;
    background: #F0EFEB;
}
.ffi-single-banner img {
    width: 100%;
    height: 100%;
    max-height: 360px;
    object-fit: cover;
    display: block;
}
.ffi-card-name {
    font-size: 13px;
    font-weight: 500;
    margin: 6px 0 6px;
    line-height: 1.35;
}
.ffi-card-days { margin: 6px 0 2px; }
.ffi-card-days-num  { font-size: 26px; font-weight: 500; color: var(--ffi-blue); line-height: 1; }
.ffi-card-days-label{ font-size: 11px; color: #888; }
.ffi-card-price {
    font-size: 14px;
    font-weight: 600;
    color: #1B5E20;
    margin-top: 8px;
    padding: 8px 12px;
    background: #fff;
    border: 1px solid #C5E1A5;
    border-radius: 6px;
}
.ffi-card-meta  { font-size: 12px; color: #555; margin-top: 6px; }
.ffi-card-pref  { font-size: 11px; color: #888; margin-top: 4px; }
.ffi-card-score { margin-top: 6px; display: flex; align-items: center; gap: 4px; }
.ffi-card-score-num { font-size: 13px; font-weight: 500; color: var(--ffi-blue); }
.ffi-no-results { color: #888; font-size: 13px; padding: 12px 0; }

/* =============================================
   星評価
============================================= */
.ffi-stars { font-size: 14px; letter-spacing: 1px; }
.ffi-star-full  { color: var(--ffi-amber); }
.ffi-star-half,
.ffi-star-empty { color: #ccc; }

/* =============================================
   ランキング
============================================= */
.ffi-rank-list { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.ffi-rank-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #fff;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius-lg);
    padding: 10px 14px;
    text-decoration: none;
    color: inherit;
    transition: border-color .15s;
}
.ffi-rank-item:hover { border-color: #aaa; text-decoration: none; color: inherit; }
.ffi-rank-gold   { border-color: #EF9F27; background: #FAEEDA; }
.ffi-rank-silver { border-color: #B4B2A9; background: #F1EFE8; }
.ffi-rank-bronze { border-color: #F0997B; background: #FAECE7; }
.ffi-rank-num {
    font-size: 22px;
    font-weight: 500;
    min-width: 32px;
    text-align: center;
}
.ffi-rank-num.ffi-rank-gold   { color: #BA7517; }
.ffi-rank-num.ffi-rank-silver { color: #5F5E5A; }
.ffi-rank-num.ffi-rank-bronze { color: #993C1D; }
.ffi-rank-body { flex: 1; min-width: 0; }
.ffi-rank-name { font-size: 13px; font-weight: 500; margin-bottom: 3px; }
.ffi-rank-meta { font-size: 11px; color: #888; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.ffi-rank-score { text-align: right; min-width: 65px; }
.ffi-rank-score-num   { font-size: 22px; font-weight: 500; color: var(--ffi-blue); line-height: 1; }
.ffi-rank-score-label { font-size: 10px; color: #888; }
.ffi-score-bar-wrap { width: 60px; height: 4px; background: #e5e7eb; border-radius: 2px; margin-top: 4px; }
.ffi-score-bar      { height: 4px; border-radius: 2px; background: var(--ffi-blue); }

/* =============================================
   地図
============================================= */
.ffi-map-wrap { }
.ffi-map-stats {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 8px;
    margin-bottom: 16px;
}
.ffi-stat-box {
    background: #f5f5f5;
    border-radius: var(--ffi-radius);
    padding: 10px;
    text-align: center;
}
/* 統計ボックスがリンク（<a>）の場合の見た目調整：下線なし・ホバーで軽く反応 */
a.ffi-stat-box {
    display: block;
    text-decoration: none;
    color: inherit;
    transition: background-color .15s, transform .1s;
}
a.ffi-stat-box:hover {
    background: #ececec;
}
a.ffi-stat-box:active {
    transform: scale(0.98);
}
.ffi-stat-num   { display: block; font-size: 22px; font-weight: 500; line-height: 1; }
.ffi-stat-label { display: block; font-size: 11px; color: #888; margin-top: 3px; }
.ffi-color-blue  { color: var(--ffi-blue); }
.ffi-color-green { color: var(--ffi-green); }
.ffi-color-amber { color: var(--ffi-amber); }
.ffi-color-blue-bg { background: var(--ffi-blue); }

.ffi-map-layout {
    display: grid;
    grid-template-columns: 1fr 260px;
    gap: 14px;
}
@media (max-width: 640px) {
    .ffi-map-layout { grid-template-columns: 1fr; }
}

.ffi-region-tabs {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}
.ffi-rtab {
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 20px;
    border: 0.5px solid #ccc;
    background: #fff;
    color: #555;
    cursor: pointer;
    transition: all .12s;
}
.ffi-rtab.on {
    background: var(--ffi-blue);
    color: #fff;
    border-color: var(--ffi-blue);
}

.ffi-pref-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(68px, 1fr));
    gap: 5px;
    margin-bottom: 10px;
}
.ffi-pb {
    padding: 5px 4px;
    font-size: 11px;
    border: 0.5px solid #ddd;
    border-radius: var(--ffi-radius);
    background: #fff;
    color: #888;
    cursor: pointer;
    text-align: center;
    line-height: 1.3;
    transition: all .12s;
}
.ffi-pb.has-festival {
    border-color: var(--ffi-blue-bd);
    color: var(--ffi-blue);
    background: var(--ffi-blue-lt);
}
.ffi-pb.has-festival:hover { background: #B5D4F4; }
.ffi-pb.selected {
    background: var(--ffi-blue);
    color: #fff;
    border-color: var(--ffi-blue);
}
.ffi-pb.selected .ffi-pb-count { background: #fff; color: var(--ffi-blue); }
.ffi-pb-count {
    display: inline-block;
    font-size: 10px;
    font-weight: 500;
    background: var(--ffi-blue);
    color: #fff;
    border-radius: 20px;
    padding: 0 5px;
    margin-left: 2px;
    line-height: 1.5;
}
.ffi-map-legend {
    display: flex;
    gap: 12px;
    font-size: 11px;
    color: #888;
    margin-top: 6px;
}
.ffi-legend-item   { display: flex; align-items: center; gap: 4px; }
.ffi-legend-dot    { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.ffi-legend-dot-empty { background: #ccc; }

.ffi-map-result {
    background: #fff;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius-lg);
    padding: 12px;
    min-height: 100px;
}
.ffi-map-placeholder { text-align: center; padding: 20px 0; font-size: 12px; color: #aaa; }
.ffi-map-pref-name  { font-size: 15px; font-weight: 500; margin-bottom: 2px; }
.ffi-map-pref-count { font-size: 12px; color: #888; margin-bottom: 10px; }
.ffi-map-fest-list  { display: flex; flex-direction: column; gap: 8px; }
.ffi-map-fest-item  {
    padding: 8px 10px;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    font-size: 12px;
}
.ffi-map-fest-name  { font-weight: 500; margin-bottom: 4px; }
.ffi-map-fest-name a { color: inherit; text-decoration: none; }
.ffi-map-fest-name a:hover { color: var(--ffi-blue); }
.ffi-map-fest-badges { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 5px; }
.ffi-map-fest-links  { display: flex; gap: 5px; flex-wrap: wrap; margin-top: 4px; }
.ffi-link-chip {
    font-size: 11px;
    padding: 2px 9px;
    border-radius: 20px;
    text-decoration: none;
    transition: opacity .15s;
}
.ffi-link-chip:hover { opacity: .8; text-decoration: none; }
.ffi-chip-rec { background: var(--ffi-blue-lt); color: var(--ffi-blue); }
.ffi-chip-ev  { background: var(--ffi-green-lt); color: var(--ffi-green); }

.ffi-loading    { color: #aaa; font-size: 13px; text-align: center; padding: 12px; }

/* =============================================
   個別ページ（single-film_festival.php 用）
============================================= */
.ffi-single-hero {
    border-bottom: 0.5px solid var(--ffi-border);
    padding-bottom: 14px;
    margin-bottom: 0;
}
.ffi-single-title { font-size: 22px; font-weight: 500; margin-bottom: 6px; }
.ffi-single-meta  { display: flex; gap: 14px; font-size: 12px; color: #666; flex-wrap: wrap; margin-top: 8px; }
.ffi-hero-badges  { display: flex; gap: 6px; flex-wrap: wrap; margin: 6px 0; }

/* 表示切り替えタブ */
.ffi-view-tabs {
    display: flex;
    border-bottom: 0.5px solid var(--ffi-border);
    background: #f9f9f9;
    margin: 0 -20px;
    padding: 0 20px;
    overflow-x: auto;
}
.ffi-vtab {
    padding: 10px 18px;
    font-size: 13px;
    cursor: pointer;
    color: #666;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
    transition: all .15s;
    text-decoration: none;
    display: block;
}
.ffi-vtab:hover { color: #333; text-decoration: none; }
.ffi-vtab.on { font-weight: 500; }
.ffi-vtab.on.ffi-vtab-rec  { color: var(--ffi-blue);  border-bottom-color: var(--ffi-blue); }
.ffi-vtab.on.ffi-vtab-ev   { color: var(--ffi-green); border-bottom-color: var(--ffi-green); }
.ffi-vtab.on.ffi-vtab-info { color: #333; border-bottom-color: #333; }

/* 年度タブ */
.ffi-year-tabs { display: flex; gap: 5px; margin-bottom: 12px; flex-wrap: wrap; }
.ffi-ytab {
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 20px;
    border: 0.5px solid #ccc;
    background: #fff;
    color: #555;
    cursor: pointer;
    transition: all .12s;
}
.ffi-ytab.on { background: #333; color: #fff; border-color: #333; }

/* セクション（作品募集情報・開催情報・映画祭について）
   3つのセクションが同じカード形状で統一感を持つようにし、
   区切りをはっきりさせる。上部の色帯でセクション種別を示す。 */
.ffi-info-section {
    position: relative;
    background: #fff;
    border: 0.5px solid var(--ffi-border, #e2e2e2);
    border-radius: var(--ffi-radius-lg, 10px);
    padding: 18px 20px 20px;
    margin-bottom: 18px;
    overflow: hidden;
}
.ffi-info-section::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
}
.ffi-info-section-recruiting::before { background: var(--ffi-blue); }
.ffi-info-section-event::before      { background: var(--ffi-green); }
.ffi-info-section-info::before       { background: #999; }
.ffi-section-head { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.ffi-section-icon {
    width: 24px; height: 24px;
    border-radius: 6px;
    display: flex; align-items: center; justify-content: center;
    font-size: 14px;
}
.ffi-section-icon-rec  { background: var(--ffi-blue-lt); color: var(--ffi-blue); }
.ffi-section-icon-ev   { background: var(--ffi-green-lt); color: var(--ffi-green); }
.ffi-section-icon-info { background: #f0f0f0; color: #555; }
.ffi-section-title { font-size: 14px; font-weight: 500; margin: 0; }

/* ページ上部カウントダウン（個別ページ）
   背景：薄い黄色　数字：赤　ラベル：グレー */
.ffi-countdown {
    text-align: center;
    background: #fffde7;
    border: 1px solid #f0d060;
    border-radius: var(--ffi-radius);
    padding: 10px;
    margin-bottom: 10px;
}
.ffi-countdown-num   { font-size: 36px; font-weight: 700; color: #e53935; line-height: 1; }
.ffi-countdown-label { font-size: 11px; color: #888; margin-top: 2px; }

/* フェーズカード */
.ffi-phase-card {
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    padding: 10px 12px;
    margin-bottom: 8px;
}
.ffi-phase-card.is-active {
    border-color: var(--ffi-blue-bd);
    background: var(--ffi-blue-lt);
}
.ffi-phase-card.is-upcoming {
    border-color: #D9C99A;
    background: #FAF7EE;
}
.ffi-phase-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-size: 12px;
    padding: 2px 0;
}
.ffi-phase-label { color: #666; }
.ffi-phase-value { font-weight: 500; font-size: 13px; }
.ffi-phase-value.ffi-accent { color: var(--ffi-blue); }

/* 開催日ボックス */
.ffi-event-dates { display: flex; gap: 10px; margin-bottom: 12px; }
.ffi-event-date-box {
    flex: 1;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    padding: 8px 10px;
    text-align: center;
    background: var(--ffi-blue-lt);
    border-color: var(--ffi-blue-bd);
}
.ffi-event-date-box-end {
    background: #FEE8E8;
    border-color: #F0A0A0;
}
.ffi-event-date-box.is-active {
    background: var(--ffi-green-lt);
    border-color: var(--ffi-green-bd);
}
.ffi-event-date-box-end.is-active {
    background: var(--ffi-green-lt);
    border-color: var(--ffi-green-bd);
}
.ffi-event-date-label { font-size: 10px; color: #888; }
.ffi-event-date-val   { font-size: 14px; font-weight: 500; margin-top: 2px; }

/* 受賞結果テーブル */
.ffi-award-table { width: 100%; border-collapse: collapse; font-size: 12px; margin-bottom: 12px; }
.ffi-award-table th { background: #f5f5f5; padding: 6px 10px; text-align: left; font-weight: 500; border-bottom: 1px solid #e0e0e0; }
.ffi-award-table td { padding: 6px 10px; border-bottom: 0.5px solid #eee; }

/* スコアグリッド */
.ffi-score-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
}
.ffi-score-box {
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    padding: 8px 10px;
}
.ffi-score-box-label { font-size: 11px; color: #888; margin-bottom: 4px; }
.ffi-score-total-box {
    background: #f5f5f5;
    border-radius: var(--ffi-radius);
    padding: 12px;
    text-align: center;
    margin-top: 4px;
}
.ffi-score-total-num { font-size: 32px; font-weight: 500; color: var(--ffi-blue); line-height: 1; }

/* 通知バナー */
.ffi-notice {
    border-radius: var(--ffi-radius);
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
}
.ffi-notice-rec  { background: var(--ffi-blue-lt);  border: 0.5px solid var(--ffi-blue-bd);  color: #0C447C; }
.ffi-notice-ev   { background: var(--ffi-green-lt); border: 0.5px solid var(--ffi-green-bd); color: #085041; }

/* ウォッチボタン */
.ffi-watch-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    border-radius: var(--ffi-radius);
    border: 1px solid var(--ffi-blue);
    background: #fff;
    color: var(--ffi-blue);
    font-size: 13px;
    cursor: pointer;
    transition: all .15s;
}
.ffi-watch-btn:hover { background: var(--ffi-blue); color: #fff; }
.ffi-watch-btn.is-watching { background: var(--ffi-blue); color: #fff; }

/* 情報テーブル */
.ffi-info-table { width: 100%; font-size: 12px; border-collapse: collapse; }
.ffi-info-table tr { border-bottom: 0.5px solid #eee; }
.ffi-info-table tr:last-child { border-bottom: none; }
.ffi-info-table td { padding: 6px 0; }
.ffi-info-table td:first-child { color: #888; width: 90px; }
.ffi-info-table td:last-child  { font-weight: 500; }

/* =============================================
   レスポンシブ
============================================= */
@media (max-width: 640px) {
    .ffi-card-grid { grid-template-columns: 1fr 1fr; }
    .ffi-score-grid { grid-template-columns: 1fr 1fr; }
    .ffi-rank-score-num { font-size: 18px; }
}
@media (max-width: 480px) {
    .ffi-card-grid { grid-template-columns: 1fr; }
}

/* =============================================
   基本情報カード（映画祭について）
============================================= */
.ffi-info-cards {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius-lg);
    overflow: hidden;
}
.ffi-info-card-item {
    display: grid;
    grid-template-columns: 28px 90px 1fr;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-bottom: 0.5px solid var(--ffi-border);
    transition: background .12s;
}
.ffi-info-card-item:last-child { border-bottom: none; }
.ffi-info-card-item:hover { background: var(--ffi-blue-lt); }

.ffi-info-card-icon {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: var(--ffi-blue-lt);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.ffi-info-card-icon .dashicons {
    font-size: 15px;
    color: var(--ffi-blue);
    width: 15px;
    height: 15px;
}
.ffi-info-card-label {
    font-size: 11px;
    color: #888;
    white-space: nowrap;
}
.ffi-info-card-value {
    font-size: 13px;
    font-weight: 500;
    color: var(--ffi-gray, #333);
}
.ffi-info-link {
    color: var(--ffi-blue);
    text-decoration: none;
    font-size: 13px;
}
.ffi-info-link:hover { text-decoration: underline; }

/* =============================================
   固定タブのアクティブ状態（viewパラメータで切替）
============================================= */
.ffi-vtab.on.ffi-vtab-recruiting { color: var(--ffi-blue);  border-bottom-color: var(--ffi-blue); }
.ffi-vtab.on.ffi-vtab-event      { color: var(--ffi-green); border-bottom-color: var(--ffi-green); }
.ffi-vtab.on.ffi-vtab-info       { color: #333;             border-bottom-color: #333; }

/* セクション：非アクティブは薄く表示 */
.ffi-section-secondary {
    opacity: .72;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 0.5px solid #eee;
}

/* =============================================
   ジャンルタグ
============================================= */
.ffi-genre-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}
.ffi-genre-tag {
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 20px;
    font-weight: 500;
    white-space: nowrap;
    transition: all .15s;
}
.ffi-genre-tag.is-on {
    background: var(--ffi-blue-lt);
    color: var(--ffi-blue);
    border: 0.5px solid var(--ffi-blue-bd);
}
.ffi-genre-tag.is-off {
    background: #F0EFEB;
    color: #BBB;
    border: 0.5px solid #DDD;
}
/* 対象外ジャンル（応募不可のジャンル）の表示 */
.ffi-genre-tags-excluded {
    align-items: center;
}
.ffi-genre-excl-label {
    font-size: 11px;
    color: #B71C1C;
    font-weight: 600;
    margin-right: 2px;
}
.ffi-genre-tag-excluded {
    background: #FDECEA;
    color: #B71C1C;
    border: 0.5px solid #F1A9A0;
}

/* =============================================
   募集終了バナー
============================================= */
.ffi-recruiting-closed {
    display: flex;
    align-items: center;
    gap: 7px;
    background: var(--ffi-gray-lt, #F1EFE8);
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 500;
    color: var(--ffi-gray, #5F5E5A);
    margin-bottom: 12px;
}
.ffi-recruiting-closed .ti {
    font-size: 16px;
    color: var(--ffi-gray, #5F5E5A);
}

/* =============================================
   募集要項リンク
============================================= */
.ffi-guidelines-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    color: var(--ffi-blue);
    text-decoration: none;
    padding: 6px 14px;
    border: 0.5px solid var(--ffi-blue-bd);
    border-radius: var(--ffi-radius);
    background: var(--ffi-blue-lt);
    margin-bottom: 10px;
    transition: opacity .15s;
}
.ffi-guidelines-link:hover { opacity: .8; text-decoration: none; }

/* =============================================
   募集要項テキストボックス
============================================= */
.ffi-guidelines-box {
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius);
    overflow: hidden;
    margin-bottom: 10px;
}
.ffi-guidelines-title {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 500;
    padding: 7px 12px;
    background: var(--ffi-blue-lt);
    color: var(--ffi-blue);
    border-bottom: 0.5px solid var(--ffi-blue-bd);
}
.ffi-guidelines-body {
    font-size: 12px;
    line-height: 1.8;
    padding: 10px 12px;
    color: var(--color-text-secondary, #555);
    white-space: pre-wrap;
}

/* 募集要項の「情報提供あり」バッジと、著作権配慮についての注意喚起。
   「募集要項を見る」ボタンの直下に単独のブロックとして表示する */
.ffi-guidelines-provided,
.ffi-guidelines-disclaimer {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    font-size: 12px;
    line-height: 1.7;
    padding: 8px 12px;
    margin: 8px 0;
    border-radius: 6px;
}
.ffi-guidelines-provided {
    color: #2e7d32;
    background: rgba(46,125,50,.07);
    border: 1px solid rgba(46,125,50,.25);
}
/* 見落とされないよう赤字で強調する */
.ffi-guidelines-disclaimer {
    color: #C62828;
    background: rgba(198,40,40,.05);
    border: 1px solid rgba(198,40,40,.25);
    font-weight: 600;
}
.ffi-guidelines-provided .dashicons,
.ffi-guidelines-disclaimer .dashicons {
    font-size: 15px;
    width: 15px;
    height: 15px;
    line-height: 1.4;
    flex-shrink: 0;
}

/* =============================================
   備考ボックス
============================================= */
.ffi-note-box {
    font-size: 12px;
    line-height: 1.8;
    padding: 9px 12px;
    background: var(--ffi-gray-lt, #F1EFE8);
    border-radius: var(--ffi-radius);
    color: var(--color-text-secondary, #666);
    border-left: 3px solid var(--ffi-border);
    margin-bottom: 10px;
    white-space: pre-wrap;
}

/* =============================================
   追加情報（テーマ・審査員・賞・住所など）
============================================= */
.ffi-extra-info {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 0.5px solid var(--ffi-border);
    border-radius: var(--ffi-radius-lg);
    overflow: hidden;
    margin-bottom: 12px;
}
.ffi-extra-item {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: 8px;
    padding: 9px 14px;
    border-bottom: 0.5px solid var(--ffi-border);
    font-size: 13px;
}
.ffi-extra-item:last-child { border-bottom: none; }
.ffi-extra-label {
    font-size: 11px;
    color: var(--color-text-secondary, #888);
    display: flex;
    align-items: flex-start;
    gap: 4px;
    padding-top: 1px;
    white-space: nowrap;
}
.ffi-extra-value {
    font-size: 13px;
    color: var(--color-text-primary, #333);
    line-height: 1.7;
}

/* =============================================
   SNSリンクボタン
============================================= */
.ffi-sns-links {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 14px;
}
.ffi-sns-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 13px;
    border-radius: 20px;
    border: 0.5px solid var(--ffi-border);
    background: var(--color-background-secondary, #f5f5f5);
    color: var(--color-text-secondary, #555);
    font-size: 12px;
    text-decoration: none;
    transition: all .15s;
}
.ffi-sns-btn:hover {
    background: var(--ffi-blue-lt);
    color: var(--ffi-blue);
    border-color: var(--ffi-blue-bd);
    text-decoration: none;
}
.ffi-sns-btn .ti { font-size: 15px; }

/* =============================================
   info-card-icon Tabler アイコン対応
============================================= */
.ffi-info-card-icon .ti {
    font-size: 15px;
    color: var(--ffi-blue);
}

/* =============================================
   タブ：非活性（募集なし映画祭）
============================================= */
.ffi-vtab.disabled {
    color: #bbb;
    cursor: not-allowed;
    border-bottom-color: transparent;
    background: transparent;
    opacity: .6;
    pointer-events: none;
    filter: grayscale(1);
}
.ffi-vtab.disabled:hover {
    color: #bbb;
    background: transparent;
}

/* =============================================
   入選・受賞ランキングリスト
============================================= */
.ffi-results-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.ffi-result-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 8px 10px;
    /* ページ背景が白だと白いカードが埋もれてしまうため、淡い青系の
       背景と左端のアクセント線で「入選作品の一覧」だと分かるようにする */
    background: rgba(24, 95, 165, .045);
    border: 0.5px solid rgba(24, 95, 165, .18);
    border-left: 3px solid var(--ffi-blue, #185FA5);
    border-radius: var(--ffi-radius);
    font-size: 12px;
}
.ffi-result-num {
    min-width: 22px;
    height: 22px;
    border-radius: 50%;
    /* カード背景を淡い青にしたため、同系色のバッジだと輪郭が消える。
       白地＋青枠にしてはっきり見えるようにする */
    background: #fff;
    border: 1px solid rgba(24, 95, 165, .30);
    box-sizing: border-box;
    color: var(--ffi-blue);
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.ffi-result-award-badge {
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 20px;
    background: var(--ffi-amber-lt, #FAEEDA);
    color: var(--ffi-amber);
    white-space: nowrap;
    flex-shrink: 0;
    align-self: flex-start;
    margin-top: 2px;
}
.ffi-result-body { flex: 1; min-width: 0; }
.ffi-result-work {
    font-weight: 500;
    font-size: 13px;
    margin-bottom: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ffi-result-meta { font-size: 11px; color: var(--color-text-secondary, #888); }

/* =============================================
   作品募集：条件チェック（参加必須・賞金・交通費）
   ボタン風スタイル
============================================= */
.ffi-condition-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
    margin-bottom: 12px;
}
.ffi-condition-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 13px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
    border: 1px solid transparent;
}
.ffi-chip-attendance {
    background: #fff3e0;
    color: #b45309;
    border-color: #fcd34d;
}
.ffi-chip-prize {
    background: #fefce8;
    color: #a16207;
    border-color: #fde68a;
}
.ffi-chip-travel {
    background: #f0fdf4;
    color: #15803d;
    border-color: #86efac;
}
/* 対象外（グレーアウト） */
.ffi-condition-chip.is-off {
    background: #F0EFEB;
    color: #BBB;
    border-color: #DDD;
}
.ffi-condition-chip.is-off .dashicons {
    color: #CCC;
}

/* =============================================
   フェーズカード カラーリング（既存サイト準拠）
============================================= */
.ffi-phase-card {
    border: 1px solid #dcdcde;
    border-radius: 6px;
    padding: 12px 14px;
    margin-bottom: 8px;
    background: #f9f9fb;
    font-size: 13px;
    line-height: 1.7;
}

/* 現在フェーズ：薄黄色背景 */
.ffi-phase-card.is-active {
    background: #e8f0fe;
    border-color: #90a4d4;
}

/* 募集開始前：淡いベージュ背景（募集中とは区別する） */
.ffi-phase-card.is-upcoming {
    background: #FAF7EE;
    border-color: #D9C99A;
    color: #7a6a3a;
}
.ffi-phase-card.is-upcoming .ffi-phase-label,
.ffi-phase-card.is-upcoming .ffi-phase-value,
.ffi-phase-card.is-upcoming .ffi-phase-name {
    color: #7a6a3a;
}

/* 次回フェーズ：薄緑背景 */
.ffi-phase-card.is-next {
    background: #edf7ed;
    border-color: #a5d6a7;
    color: #2e7d32;
}
.ffi-phase-card.is-next .ffi-phase-label,
.ffi-phase-card.is-next .ffi-phase-value,
.ffi-phase-card.is-next .ffi-phase-name {
    color: #2e7d32;
}

/* 締切済み：グレー */
.ffi-phase-card.is-past {
    background: #f5f5f5;
    border-color: #bdbdbd;
    color: #888;
    opacity: 0.9;
}
.ffi-phase-card.is-past .ffi-phase-label,
.ffi-phase-card.is-past .ffi-phase-value {
    color: #999;
}

/* フェーズ名（カード上部） */
.ffi-phase-name {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 4px;
    color: #333;
}
.ffi-phase-card.is-next .ffi-phase-name {
    color: #2e7d32;
}

/* カウントダウン（既存サイト準拠：黄色背景・赤数字） */
.ffi-phase-countdown {
    background: #fffde7;
    border-radius: 4px;
    padding: 5px 10px;
    margin: 6px 0;
    font-size: 13px;
    font-weight: 500;
    display: inline-block;
}
.ffi-phase-countdown-num {
    color: #e53935;
    font-size: 22px;
    font-weight: 700;
}

.ffi-phase-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-bottom: 3px;
    font-size: 13px;
    line-height: 1.6;
}
.ffi-phase-label {
    color: #666;
    font-size: 12px;
    flex-shrink: 0;
}
.ffi-phase-value { color: #333; }
.ffi-phase-card.is-active .ffi-deadline-value {
    color: #c0392b;
    font-weight: 600;
}

/* フェーズバッジ（小さめ） */
.ffi-phase-badge {
    display: inline-block;
    font-size: 10px;
    font-weight: 600;
    padding: 1px 7px;
    border-radius: 10px;
    margin-bottom: 5px;
    letter-spacing: 0.02em;
}
.ffi-phase-badge-active { background: #f9a825; color: #fff; }
.ffi-phase-badge-next   { background: #66bb6a; color: #fff; }
.ffi-phase-badge-past   { background: #9e9e9e; color: #fff; }

/* =============================================
   カード：次回フェーズ・フェーズ件数
============================================= */
.ffi-card-deadline {
    font-size: 12px;
    color: #555;
    margin: 3px 0;
}
.ffi-card-next-phase {
    font-size: 11px;
    color: #2e7d32;
    background: #edf7ed;
    border-radius: 4px;
    padding: 3px 8px;
    margin-top: 5px;
}
.ffi-card-phase-count {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    color: #fff;
    background: var(--ffi-blue, #185FA5);
    border-radius: 10px;
    padding: 0 7px;
    margin-left: 6px;
    vertical-align: middle;
}
.ffi-filter-count {
    font-size: 12px;
    color: #888;
    margin-left: 8px;
}

/* =============================================
   カード：フェーズブロック（現在＝白・次回＝緑・最終締切＝赤）
============================================= */
.ffi-card-phase-block {
    border-radius: 5px;
    padding: 7px 10px;
    margin-top: 7px;
    font-size: 12px;
    line-height: 1.6;
}
.ffi-card-phase-active {
    background: #fff;
    border: 1px solid #90a4d4;
}
.ffi-card-phase-next {
    background: #edf7ed;
    border: 1px solid #a5d6a7;
    color: #2e7d32;
}
/* 地域限定カテゴリー（複数カテゴリー中の一部のみが地域限定の場合、v8.9.69追加）：
   カード全体は白のまま、このカテゴリーの締切ブロックだけをグレー系にする。
   「次回」の緑（.ffi-card-phase-next）とは別ブロックのため干渉しない。 */
.ffi-card-phase-block.ffi-card-phase-local {
    background: #F2F2F2;
    border: 1px solid #ccc;
}
/* 最終締切：背景は白のまま、枠はグレーにして控えめに区別する
   （「最終締切」ラベルの文字で分かりやすく明示） */
.ffi-card-phase-final {
    background: #fff;
    border: 1px solid #dcdcde;
}
.ffi-card-phase-final-label {
    display: inline-block;
    font-size: 10px;
    font-weight: 700;
    color: #fff;
    background: #D9534F;
    border-radius: 3px;
    padding: 1px 6px;
    margin-left: 6px;
    vertical-align: middle;
}
.ffi-card-phase-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 3px;
}
.ffi-card-phase-label {
    font-weight: 600;
    font-size: 12px;
}
.ffi-card-phase-active .ffi-card-phase-label { color: #1a3a6b; }
.ffi-card-phase-next   .ffi-card-phase-label { color: #1b5e20; }

.ffi-card-phase-deadline {
    font-size: 12px;
    color: #444;
    margin-bottom: 3px;
}
.ffi-card-phase-next .ffi-card-phase-deadline { color: #2e7d32; }

/* 「あと〇日」インライン表示：数字は赤 */
.ffi-card-days-inline {
    margin-left: 8px;
    font-size: 12px;
    font-weight: 500;
    color: #555;
}
.ffi-card-days-inline .ffi-card-days-num,
.ffi-card-phase-active .ffi-card-days-inline {
    color: #e53935;
    font-weight: 700;
}
.ffi-card-phase-active .ffi-card-days-num { color: #e53935; font-weight: 700; }

.ffi-card-price-next { color: #2e7d32; }
/* 次回枠の部門数が多く価格リストが極端に長くなる場合、後半を省略して
   カードの縦幅を抑える（短い場合は表示に変化なし。次回枠が無いカードには
   このセレクタ自体が該当しないため影響しない） */
.ffi-card-phase-next .ffi-card-price {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 現在フェーズ：「あと〇日」部分だけ黄色背景 */
.ffi-card-phase-active .ffi-card-days-inline {
    background: #fffde7;
    border: 1px solid #f0d060;
    border-radius: 4px;
    padding: 1px 7px;
}
/* 本日締切：赤文字・黄色背景で強調 */
.ffi-card-days-today {
    color: #C53030 !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    background: #FFF8E1 !important;
    border: 1.5px solid #FFD54F !important;
    border-radius: 6px !important;
    padding: 6px 12px !important;
    text-align: center;
    margin-top: 6px;
}
/* 個別ページ：カウントダウン本日締切 */
.ffi-countdown-today { background: #FFF8E1 !important; border-color: #FFD54F !important; }
.ffi-countdown-today .ffi-countdown-num { color: #C53030 !important; }
.ffi-countdown-today .ffi-countdown-label { color: #C53030 !important; font-weight: 700; }
/* 個別ページ：フェーズ締切日の強調表示 */
.ffi-phase-deadline-highlight {
    display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
    font-size: 13px; margin-bottom: 6px;
    padding: 6px 10px; background: #FFFDE7; border: 1px solid #F0D060;
    border-radius: 6px;
}
.ffi-phase-dl-date { color: #333; font-weight: 600; }
.ffi-phase-dl-days { color: #C53030; font-weight: 600; font-size: 13px; }
.ffi-phase-dl-today { color: #C53030; font-weight: 700; font-size: 14px; }
/* v8_9_160: ここに「セレクタの無い宣言ブロック」が残っていた。
   （margin-left / font-size / color の3行と閉じ括弧だけが浮いていた）
   過去の編集でセレクタ行が失われたものと思われる。
   CSSとしては構文エラーで、ブラウザは復帰位置を探す過程で
   **直後のルールごと読み飛ばすことがある**ため削除した。
   .ffi-phase-dl-* はプラグイン内のどこからも使われていない。 */

/* =============================================
   受賞結果カード（モダン）
============================================= */
.ffi-award-cards {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.ffi-award-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #fffdf5;
    border: 1px solid #f5e0a0;
    border-left: 4px solid #e0a020;
    border-radius: 6px;
    padding: 10px 14px;
    transition: box-shadow 0.15s;
}
.ffi-award-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.ffi-award-card-badge {
    flex-shrink: 0;
    background: linear-gradient(135deg, #f5c842, #e0a020);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 12px;
    /* 【修正 v8.9.78】white-space:nowrap のまま長い部門名・賞名が
       入ると、枠(max-width:140px)からテキストがはみ出して隣の
       作品名エリアに重なって見えていた。折り返し可能にして解消する。 */
    white-space: normal;
    word-break: break-word;
    max-width: 140px;
    text-align: center;
    line-height: 1.4;
    letter-spacing: 0.02em;
}
.ffi-award-card-body {
    flex: 1;
    min-width: 0;
}
.ffi-award-card-work {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ffi-award-card-meta {
    font-size: 12px;
    color: #888;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
}
.ffi-award-meta-sep { color: #ccc; }
.ffi-award-meta-item { color: #777; }

/* =============================================
   TOP作品募集カード：2列グリッド
============================================= */
.ffi-card-grid-2col {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}
@media (max-width: 600px) {
    .ffi-card-grid-2col {
        grid-template-columns: 1fr;
    }
}

/* =============================================
   特徴タグ（個別ページ・カード共通）
============================================= */
.ffi-feature-tags,
.ffi-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin: 6px 0;
}
.ffi-feature-tag,
.ffi-card-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 500;
    padding: 2px 10px;
    border-radius: 12px;
    background: #f0f5fb;
    color: var(--ffi-blue, #185FA5);
    border: 1px solid #b8cfea;
    white-space: nowrap;
}

/* カード：表示用サブタイトル */
.ffi-card-sub-title {
    font-size: 11px;
    color: #94a3b8;
    margin: -4px 0 4px;
}

/* 個別ページ：サブタイトル */
.ffi-single-subtitle {
    font-size: 13px;
    color: #94a3b8;
    margin: -6px 0 8px;
}

/* =============================================
   開催情報：会場カード・マップボタン
============================================= */

/* 会場カードラッパー（ffi-info-cardsと同スタイルを継承、マージン調整） */
.ffi-venue-cards {
    margin-bottom: 14px;
}

/* 複数会場の区切り線 */
.ffi-venue-divider {
    height: 0;
    border-top: 1px dashed var(--ffi-border);
    margin: 0;
}

/* マップ行：iframeが入るので上揃えに */
.ffi-venue-map-row {
    align-items: flex-start !important;
}
.ffi-venue-map-row .ffi-info-card-icon {
    margin-top: 2px;
}

/* Googleマップで開くボタン */
.ffi-map-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 14px;
    font-size: 12px;
    font-weight: 500;
    color: #fff;
    background: var(--ffi-green);
    border-radius: var(--ffi-radius);
    text-decoration: none;
    transition: opacity .15s;
    white-space: nowrap;
}
.ffi-map-btn:hover {
    opacity: .85;
    color: #fff;
    text-decoration: none;
}

/* =============================================
   バッジ式チェックボックス（管理画面メタボックス用）
   未選択はグレーアウト、選択中はカラー表示
============================================= */
.ffi-badge-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.ffi-badge-check {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 20px;
    cursor: pointer;
    transition: all .15s ease;
    border: 1px solid transparent;
    line-height: 1.4;
}
.ffi-badge-check input[type="checkbox"] {
    display: none;
}
.ffi-badge-check.is-on {
    background: #E6F1FB;
    color: #185FA5;
    border-color: #85B7EB;
    font-weight: 500;
}
.ffi-badge-check.is-off {
    background: #F0EFEB;
    color: #AAA;
    border-color: #DDD;
}
.ffi-badge-check.is-off:hover {
    background: #E8E7E3;
    color: #888;
    border-color: #CCC;
}

/* スコアボックスのグレーアウト状態 */
.ffi-score-box.is-off {
    background: #F0EFEB;
    border-color: #DDD;
}
.ffi-score-box.is-off .ffi-score-box-label {
    color: #BBB;
}

/* 連絡先バッジ（長丸・チェック入り） */
.ffi-contact-badge {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 11px; padding: 4px 12px; border-radius: 20px;
    white-space: nowrap; font-weight: 500;
}
.ffi-contact-badge.is-on {
    background: #E1F5EE; color: #0F6E56;
    border: 1px solid #5DCAA5;
}
.ffi-contact-badge.is-on::before {
    content: '✓'; font-weight: 700; margin-right: 1px;
}
.ffi-contact-badge.is-off {
    background: #F0EFEB; color: #BBB;
    border: 1px solid #DDD;
}
.ffi-contact-badge.is-off::before {
    content: '✕'; font-weight: 700; color: #C53030; margin-right: 1px;
}

/* SNSボタン（ブランドカラー） */
.ffi-sns-btn {
    display: inline-flex; align-items: center; gap: 4px;
    font-size: 12px; font-weight: 500;
    padding: 5px 14px; border-radius: 20px;
    text-decoration: none; transition: opacity .15s;
    border: 1px solid;
}
.ffi-sns-btn:hover { opacity: .75; text-decoration: none; color: inherit; filter: brightness(1.15); }

/* =============================================
   一覧カード：最終締切の強調（薄い赤系背景）
   .ffi-card-phase-active と併用され、次のフェーズが
   存在しない＝最終締切の場合にラベル・締切日の文字色も
   赤系に上書きする（カスケード優先のためファイル末尾に配置）
============================================= */
.ffi-card-phase-final .ffi-card-phase-label,
.ffi-card-phase-final .ffi-card-phase-deadline {
    color: #B71C1C;
}

/* =============================================
   一覧のページネーション
   表示件数が多い場合にページ切り替えで表示する
============================================= */
.ffi-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 20px;
}
.ffi-page-btn,
.ffi-page-num {
    min-width: 32px;
    height: 32px;
    padding: 0 10px;
    font-size: 13px;
    border: 0.5px solid #ccc;
    border-radius: var(--ffi-radius);
    background: #fff;
    color: #333;
    cursor: pointer;
    transition: background-color .15s, color .15s;
}
.ffi-page-btn:hover:not([disabled]),
.ffi-page-num:hover:not([disabled]) {
    background: var(--ffi-blue-lt);
    color: var(--ffi-blue);
}
.ffi-page-num.is-active {
    background: var(--ffi-blue);
    border-color: var(--ffi-blue);
    color: #fff;
    cursor: default;
}
.ffi-page-btn[disabled],
.ffi-page-num[disabled]:not(.is-active) {
    opacity: .4;
    cursor: not-allowed;
}
.ffi-page-ellipsis {
    padding: 0 4px;
    color: #999;
    font-size: 13px;
}

/* 認証済みバッジ（運営が内容を確認済みの映画祭） */
.ffi-verified-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    background: #E8F5E9;
    color: #1B5E20;
    border: 1px solid #66BB6A;
    white-space: nowrap;
}


/* =============================================
   詳細タイムテーブル（既存の受賞・入選カードと同じ見た目に統一）
============================================= */
.ffi-tt-wrap { margin-bottom: 10px; }
.ffi-tt-day { margin-bottom: 22px; }
.ffi-tt-day-heading {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .02em;
    color: #333;
    margin-bottom: 10px;
}
.ffi-tt-single-venue-name {
    font-size: 11px;
    color: #888;
    margin-bottom: 6px;
}

/* 時系列一覧：既存の受賞・入選カードと同じ構造（バッジ＋本文） */
.ffi-tt-cards {
    display: flex;
    flex-direction: column;
    border: 1px solid #E4E1D8;
    border-radius: 8px;
    overflow: hidden;
}
.ffi-tt-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #f7fafd;
    border-left: 4px solid var(--ffi-blue);
    padding: 10px 14px;
    transition: background-color 0.15s;
}
.ffi-tt-card + .ffi-tt-card { border-top: 1px solid rgba(0,0,0,.06); }
.ffi-tt-card:hover {
    background: #eef5fc;
}
/* 区分ごとに背景・アクセント線の色を変える */
.ffi-tt-card-event {
    background: #FAF8F2;
    border-left-color: #C99C4A;
}
.ffi-tt-card-event:hover { background: #F5F0E3; }
.ffi-tt-card-event .ffi-tt-card-badge { background: linear-gradient(135deg, #D9A94E, #C99C4A); }
.ffi-tt-card-break {
    background: #F5F4F2;
    border-left-color: #A8A29A;
}
.ffi-tt-card-break:hover { background: #EFEDE9; }
.ffi-tt-card-break .ffi-tt-card-badge { background: linear-gradient(135deg, #B9B3A8, #A8A29A); }
.ffi-tt-card-break .ffi-tt-card-work { color: #777; font-weight: 500; }
.ffi-tt-card-badge {
    flex-shrink: 0;
    background: linear-gradient(135deg, #3E86D6, var(--ffi-blue));
    color: #fff;
    font-family: "SF Mono","Consolas",monospace;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 12px;
    white-space: nowrap;
    text-align: center;
    line-height: 1.4;
    letter-spacing: 0.02em;
}
.ffi-tt-card-body { flex: 1; min-width: 0; }
.ffi-tt-card-work {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ffi-tt-card-meta {
    font-size: 12px;
    color: #888;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 3px;
}
.ffi-tt-meta-sep { color: #ccc; }
.ffi-tt-card-note {
    font-size: 11.5px;
    color: #999;
    margin-top: 4px;
    line-height: 1.6;
}
.ffi-tt-meta-item { color: #777; }

/* 1つのプログラムに複数作品が含まれる場合の作品一覧 */
.ffi-tt-film-count {
    display: inline-block;
    font-size: 10.5px;
    font-weight: 600;
    color: var(--ffi-blue);
    background: rgba(24, 95, 165, .08);
    border-radius: 10px;
    padding: 1px 8px;
    margin-left: 6px;
    vertical-align: middle;
    white-space: nowrap;
}
.ffi-tt-films {
    list-style: none;
    margin: 8px 0 0;
    padding: 0;
    counter-reset: ffi-tt-film;
    border-top: 1px dashed rgba(0,0,0,.10);
}
.ffi-tt-film {
    counter-increment: ffi-tt-film;
    position: relative;
    padding: 6px 0 6px 26px;
    line-height: 1.6;
}
.ffi-tt-film + .ffi-tt-film { border-top: 1px dotted rgba(0,0,0,.07); }
/* 上映順が分かるよう、作品ごとに連番を表示する */
.ffi-tt-film::before {
    content: counter(ffi-tt-film);
    position: absolute;
    left: 0;
    top: 7px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(24, 95, 165, .10);
    color: var(--ffi-blue);
    font-size: 10px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}
.ffi-tt-film-title {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #444;
}
.ffi-tt-film-meta {
    display: block;
    font-size: 11.5px;
    color: #888;
    margin-top: 1px;
}
.ffi-tt-film-note {
    display: block;
    font-size: 11px;
    color: #a0a0a0;
    margin-top: 2px;
    line-height: 1.55;
}
/* 区分に合わせて連番の色味をそろえる */
.ffi-tt-card-event .ffi-tt-film::before { background: rgba(201,156,74,.14); color: #A67F35; }
.ffi-tt-card-event .ffi-tt-film-count   { background: rgba(201,156,74,.14); color: #A67F35; }

/* グリッド比較／一覧表示の切り替えトグル */
.ffi-tt-view-toggle {
    display: flex;
    gap: 6px;
    margin: 4px 0 12px;
}
.ffi-tt-toggle-btn {
    font-size: 11px;
    padding: 4px 14px;
    border: 1px solid var(--ffi-blue-bd);
    border-radius: 20px;
    background: #fff;
    color: var(--ffi-blue);
    cursor: pointer;
    transition: all .15s ease;
}
.ffi-tt-toggle-btn:hover { background: var(--ffi-blue-lt); }
.ffi-tt-toggle-btn.is-active {
    background: var(--ffi-blue);
    border-color: var(--ffi-blue);
    color: #fff;
}

/* 複数会場の比較グリッド：一覧と同じ配色（水色＋青のアクセント）で統一する */
.ffi-tt-grid-wrap {
    display: flex;
    overflow-x: auto;
    background: #FAFBFC;
    border: 1px solid #ECEDEF;
    border-radius: 8px;
    padding: 14px 14px 14px 0;
}
.ffi-tt-axis {
    position: relative;
    flex: none;
    width: 42px;
}
.ffi-tt-axis-mark {
    position: absolute;
    left: 0;
    right: 10px;
    text-align: right;
    font-family: "SF Mono","Consolas",monospace;
    font-size: 9.5px;
    color: #aaa;
    transform: translateY(-50%);
}
.ffi-tt-venue-col {
    flex: 1 0 132px;
    min-width: 132px;
    padding: 0 8px;
    border-left: 1px solid #F0F1F3;
}
.ffi-tt-venue-name {
    font-size: 11px;
    font-weight: 600;
    color: var(--ffi-blue);
    text-align: center;
    padding: 0 0 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ffi-tt-venue-track { position: relative; }
.ffi-tt-entry {
    position: absolute;
    left: 2px;
    right: 2px;
    background: #f7fafd;
    border: 1px solid #cfe0f0;
    border-left: 3px solid var(--ffi-blue);
    border-radius: 4px;
    overflow: hidden;
    cursor: pointer;
    font-size: 10px;
    padding: 3px 6px;
    transition: box-shadow .15s ease, background .15s ease;
}
.ffi-tt-entry:hover, .ffi-tt-entry:focus {
    background: #eaf2fa;
    box-shadow: 0 2px 8px rgba(0,0,0,.08);
    z-index: 5;
}
.ffi-tt-entry-event {
    background: #FAF8F2;
    border-color: #E5D4A8;
    border-left-color: #C99C4A;
}
.ffi-tt-entry-event:hover, .ffi-tt-entry-event:focus { background: #F5F0E3; }
.ffi-tt-entry-event .ffi-tt-entry-time { color: #A67F35; }
.ffi-tt-entry-break {
    background: #F5F4F2;
    border-color: #DBD7CF;
    border-left-color: #A8A29A;
}
.ffi-tt-entry-break:hover, .ffi-tt-entry-break:focus { background: #EFEDE9; }
.ffi-tt-entry-break .ffi-tt-entry-time { color: #8A857C; }
.ffi-tt-entry-time {
    font-family: "SF Mono","Consolas",monospace;
    font-weight: 700;
    color: var(--ffi-blue);
}
.ffi-tt-tooltip {
    display: none;
    position: absolute;
    left: 50%;
    top: 0;
    transform: translate(-50%, -100%);
    margin-top: -8px;
    background: #fff;
    color: #555;
    font-size: 11.5px;
    line-height: 1.7;
    padding: 9px 13px;
    border: 1px solid #E4E1D8;
    border-radius: 8px;
    white-space: nowrap;
    z-index: 20;
    box-shadow: 0 8px 20px rgba(0,0,0,.12);
}
.ffi-tt-entry:hover .ffi-tt-tooltip,
.ffi-tt-entry:focus .ffi-tt-tooltip {
    display: block;
}
.ffi-tt-hint { font-size: 10.5px; color: #aaa; margin-top: 8px; }

@media (max-width: 640px) {
    .ffi-tt-venue-col { flex: 1 0 104px; min-width: 104px; }
    .ffi-tt-tooltip { white-space: normal; max-width: 180px; }
}

/* ============================================================
   新着・更新の映画祭ウィジェット（v8_9_122追加 / v8_9_123 デザイン刷新）

   方針: 彩度を抑えた濃色でシックにまとめつつ、
   アクセント1色（サイトロゴに合わせた深紅）と NEW バッジで視線を集める。
   アクセント色は --ffi-cl-accent を上書きすれば変更できる。
============================================================ */
.ffi-change-log-widget {
    --ffi-cl-accent: #9e1b32;   /* 深紅。ロゴの赤に合わせた沈んだトーン */
    --ffi-cl-ink:    #1b1b1f;   /* 本文。真っ黒を避けて柔らかく */
    --ffi-cl-muted:  #8b8b91;
    --ffi-cl-line:   #e4e2e0;
    font-size: 13px;
    line-height: 1.6;
}

.ffi-cl-list {
    margin: 0;
    padding: 0;
    list-style: none;
    border-top: 2px solid var(--ffi-cl-ink);   /* 上端の太罫で見出しを引き締める */
}

.ffi-cl-item {
    position: relative;
    padding: 13px 2px 13px 15px;
    border-bottom: 1px solid var(--ffi-cl-line);
    transition: background-color .25s ease;
}
.ffi-cl-item:last-child { border-bottom: 0; }
.ffi-cl-item:hover { background-color: #faf8f7; }

/* 左端の縦罫。通常は淡く、ホバーで色が立ち上がる */
.ffi-cl-item::before {
    content: "";
    position: absolute;
    left: 0; top: 13px; bottom: 13px;
    width: 2px;
    background: var(--ffi-cl-accent);
    opacity: .18;
    transition: opacity .25s ease;
}
.ffi-cl-item:hover::before,
.ffi-cl-item.is-fresh::before { opacity: 1; }

.ffi-cl-meta {
    display: flex;
    align-items: center;
    gap: 7px;
    margin-bottom: 3px;
}

.ffi-cl-date {
    font-size: 10.5px;
    letter-spacing: .08em;
    color: var(--ffi-cl-muted);
    font-variant-numeric: tabular-nums;   /* 日付の桁を揃える */
}

.ffi-cl-new {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .14em;
    line-height: 1;
    color: #fff;
    background: var(--ffi-cl-accent);
    padding: 3px 6px 2px;
    border-radius: 1px;
}

.ffi-cl-title {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    color: var(--ffi-cl-ink);
    text-decoration: none;
    overflow-wrap: anywhere;   /* 長い映画祭名でもサイドバーからはみ出さない */
    transition: color .2s ease;
}
.ffi-cl-title:hover,
.ffi-cl-title:focus { color: var(--ffi-cl-accent); }

/* 種別バッジと補足文の行。バッジは折り返さず、補足だけが回り込む */
.ffi-cl-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px;
    margin-top: 6px;
}

/* 種別バッジ。塗りつぶさず細い輪郭にして主張を抑える。
   色は3系統だけに絞り、意味でまとめている
   result=結果発表 / open=募集・開催 / meta=その他 */
.ffi-cl-kind {
    flex: 0 0 auto;
    font-size: 10.5px;
    line-height: 1.5;
    padding: 1px 8px;
    border: 1px solid currentColor;
    border-radius: 999px;
    white-space: nowrap;
}
.ffi-cl-tone-result { color: #9e1b32; }
.ffi-cl-tone-open   { color: #0b6e4f; }
.ffi-cl-tone-meta   { color: #5a6472; }

.ffi-cl-summary {
    flex: 1 1 auto;
    min-width: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;      /* 変更項目が多いときは2行で打ち切る */
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 12px;
    color: #6c6c72;
}

.ffi-cl-empty { margin: 0; font-size: 12px; color: var(--ffi-cl-muted); }

/* 情報提供バッジ（映画祭側から情報の提供・掲載の許諾を受けているもの・v8_9_161）
   認証済み（内容の正確さ）とは意味が違うので、色を分けて並べても区別できるようにする。 */
.ffi-provided-badge {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 20px;
    background: #EEF3FC;
    color: #1E4D9A;
    border: 1px solid #7FA9E8;
    white-space: nowrap;
}
