/* TSS Event Manager - スタイルシート */

/* ===== カレンダーラッパー ===== */
.tss-calendar-wrapper {
    max-width: 100%;
    margin: 0 auto;
    scroll-margin-top: 100px;
    transition: opacity 0.2s ease;
}
.tss-calendar-wrapper.is-loading {
    opacity: 0.45;
    pointer-events: none;
}

/* ===== ナビゲーション ===== */
.tss-calendar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    gap: 8px;
}
.tss-btn {
    display: inline-block;
    padding: 8px 18px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.9rem;
    transition: opacity 0.2s;
}
.tss-btn:hover { opacity: 0.75; }
.tss-btn-prev,
.tss-btn-next {
    background: transparent;
    border: 2px solid currentColor;
    color: var(--vk-color-primary, #004471);
}
.tss-btn-today {
    background: transparent;
    border: 1px solid #999;
    color: #666;
    font-size: 0.85rem;
    padding: 6px 14px;
}

/* ===== 2ヶ月並びカレンダー ===== */
.tss-calendar-flex {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}
.tss-calendar-multi {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

/* ===== 月間カレンダー ===== */
.tss-month-table {
    border: 1px solid #ddd;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
}
.tss-month-table h3 {
    text-align: center;
    background: var(--vk-color-primary, #004471);
    color: #fff;
    margin: 0;
    padding: 8px;
    font-size: 1rem;
    font-weight: bold;
}
.tss-month-table table {
    width: 100%;
    table-layout: fixed;
    border-collapse: collapse;
    font-size: 12px;
}
.tss-month-table thead th {
    background: #f8f9fa;
    border-bottom: 1px solid #ddd;
    padding: 5px 0;
    text-align: center;
}
.tss-month-table thead th.sun { color: #d9534f; }
.tss-month-table thead th.sat { color: #428bca; }
.tss-month-table td {
    border: 1px solid #f0f0f0;
    height: 42px;
    vertical-align: top;
    padding: 2px;
}
.tss-month-table td.sun { background-color: #fff5f5; }
.tss-month-table td.sat { background-color: #f5faff; }
.tss-day-num {
    font-weight: bold;
    font-size: 11px;
    display: block;
    line-height: 1.2;
    margin-bottom: 1px;
}
.tss-month-table td.sun .tss-day-num { color: #d9534f; }
.tss-month-table td.sat .tss-day-num { color: #428bca; }

/* ===== イベントバッジ ===== */
.tss-event-badge {
    display: block;
    color: #fff;
    text-decoration: none;
    margin-top: 1px;
    padding: 1px 3px;
    font-size: 10px;
    border-radius: 2px;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background: var(--vk-color-primary, #004471);
}

/* ===== 直近イベント一覧（カレンダー内・大和法人会スタイル準拠） ===== */
.tss-upcoming-container {
    margin-top: 30px;
    padding: 25px 30px;
    border-radius: 4px;
    background: #fff;
}
.tss-upcoming-title {
    font-size: 1.15rem;
    font-weight: bold;
    text-align: center;
    margin: 0 0 20px;
    padding-bottom: 0;
    color: #333;
}
.tss-upcoming-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 0 10px 12px;
    border-bottom: 1px solid #f0f0f0;
    flex-wrap: wrap;
}
.tss-event-date {
    font-weight: bold;
    font-size: 0.9rem;
    white-space: nowrap;
}
.tss-event-link {
    text-decoration: none;
    font-weight: bold;
}
.tss-event-link:hover { text-decoration: underline; }
.tss-no-events {
    color: #444;
    font-size: 1rem;
    margin: 10px 0 0;
}

/* ===== ショートコード：イベントリスト ===== */
.tss-event-list {
    list-style: none;
    padding: 0;
    margin: 0;
}
.tss-event-list-item {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 16px;
}
.tss-event-list-meta {
    display: inline-flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 0;
    white-space: nowrap;
}
.tss-event-list-date {
    font-weight: bold;
    color: #333;
    font-size: 0.95rem;
}
.tss-event-list-bell {
    color: #666;
    font-size: 0.85rem;
}
.tss-event-list-title {
    flex: 1;
    min-width: 220px;
}
.tss-event-list-title a {
    text-decoration: none;
    font-weight: bold;
    font-size: 1rem;
    line-height: 1.4;
}
.tss-event-list-title a:hover { text-decoration: underline; }

/* サイドバー内の場合はコンパクトに表示 */
.widget_tss_sidebar_events .tss-event-list-item {
    display: block;
    padding: 8px 0;
}
.widget_tss_sidebar_events .tss-event-list-meta {
    display: flex;
    margin-bottom: 4px;
}
.widget_tss_sidebar_events .tss-event-list-title {
    min-width: auto;
}

/* ===== サイドバーウィジェット ===== */
.widget_tss_sidebar_events {
    margin-bottom: 30px;
}
.widget_tss_sidebar_events .widget-title {
    font-size: 1.1rem;
    font-weight: bold;
    background: #f8f9fa;
    margin-bottom: 15px;
}

/* ===== 詳細ページ情報ボックス ===== */
.tss-event-info-box {
    padding: 25px 30px;
    margin-bottom: 35px;
    border-radius: 8px;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,.05);
}
.tss-event-info-box .tss-event-info-title {
    margin: 0 0 20px;
    font-size: 1.2rem;
    padding-bottom: 12px;
    border-bottom: 2px solid #eee;
    color: #333;
}
.tss-event-info-dl {
    display: grid;
    grid-template-columns: 8em 1fr;
    gap: 12px 0;
    margin: 0 0 20px;
}
.tss-event-info-dl dt {
    font-weight: bold;
    color: #555;
}
.tss-event-info-dl dd {
    margin: 0;
}
.tss-single-cat {
    color: #fff;
    padding: 2px 10px;
    border-radius: 3px;
    font-size: 0.8rem;
    display: inline-block;
    vertical-align: middle;
}
.tss-maps-link {
    font-size: 0.85rem;
    margin-left: 8px;
    text-decoration: underline;
    color: var(--vk-color-primary, #004471);
}
.tss-event-summary {
    margin: 0 0 20px;
    font-size: 1.2rem;
    padding: 10px 0 10px 15px;
    line-height: 1.5;
    background: #f0f7ff;
}
.tss-event-remarks {
    padding: 15px;
    background: #f9f9f9;
    border: 1px dashed #ccc;
    border-radius: 4px;
    font-size: 1rem;
    line-height: 1.6;
    color: #444;
    margin-bottom: 15px;
}
.tss-event-staff {
    border-top: 1px solid #eee;
    padding-top: 12px;
    color: #666;
    font-size: 1rem;
}
.tss-event-staff span { font-weight: bold; }
.tss-event-report { margin-top: 30px; }
.tss-card-date {
    font-size: 0.85em;
    color: #666;
    margin-bottom: 4px;
}
