@charset "utf-8";
/* ================================================================
 *  calendar.css  ―  施設ページのイベントカレンダー
 * ----------------------------------------------------------------
 *  学びナビ（manabinavi/css/index.css）のカレンダー部分を
 *  そのまま抜き出したものです。中身は変えていません。
 *  施設ページで「スケジュール」のかたまりを使うときに読み込みます。
 * ================================================================ */

/* ============= calendar カレンダー============= */

#data {
    text-align: center;
    font-size: 40px;
    font-family: "M PLUS 1", sans-serif;
    font-optical-sizing: auto;
    font-weight: bold;
    width: 100%;
    margin: 1rem 0 0;
}

#calendar {
    text-align: center;
    width: 100%;
}

#calendar td.has-custom {
    font-weight: bold;
}

/* 日曜・祝日・土曜 */
td:first-child,
td.holiday {
    color: red;
}

/* 前後月の日付 */
td.disabled {
    color: #ccc;
}

/* 本日 */
td.today {
    background-color: #D65E72;
    border-radius: 10px;
    color: #fff;
}

/* ボタン */
#next-prev-button {
    display: flex;
    justify-content: space-between;
}

#next-prev-button button {
    cursor: pointer;
    background: #535cdf;
    color: #fff;
    border-radius: 4px;
    font-size: 1.2em;
    font-weight: bold;
    padding: 0.5rem 2rem;
    margin: 1rem 0;
}

#next-prev-button button:hover {
    background-color: #92b4d4;
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 30px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    position: relative;

}

/* モーダル：複数イベント対応 */
.modal-event-title {
    font-size: 1.1rem;
    font-weight: bold;
    margin: 10px 0 6px;
}

.modal-divider {
    border: none;
    border-top: 2px dashed #ddd;
    margin: 24px 0;
}

.modal-no-event {
    padding: 20px 0;
    color: #888;
    text-align: center;
}

.modal-event-url {
    margin-top: 10px;
    text-align: right;
}

.modal-event-url a {
    color: #4d4ade;
    text-decoration: underline;
}

/* =========================================
   カレンダー＋サイドパネル レイアウト
========================================= */

/* 2カラム：カレンダー左 / サイドパネル右 */
/* モーダル */
.modal {
    display: none;
    position: fixed;
    z-index: 99999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);

}
.close-button {
    color: #aaa;
    font-size: 30px;
    font-weight: bold;
    position: absolute;
    top: 10px;
    right: 20px;
    cursor: pointer;
}
.close-button:hover,
.close-button:focus {
    color: #333;
    text-decoration: none;
}
/* イベント詳細 */
.event-image {
    max-width: 100%;
    height: auto;
    display: block;
    margin: 15px auto;
    border-radius: 5px;
}

/* =========================================
   カレンダーの表そのもの
   （学びナビでは共通CSSに頼っていた部分を、ここに明記します）
========================================= */

#calendar table {
    width: 100%;
    table-layout: fixed;
    border-collapse: separate;
    border-spacing: 2px;
}

#calendar th,
#calendar td {
    padding: 10px 0;
    text-align: center;
    font-size: 15px;
    line-height: 1.2;
    vertical-align: middle;
}

#calendar tr.dayOfWeek th {
    padding: 6px 0;
    font-size: 13px;
    font-weight: bold;
    color: #46617f;
    border-bottom: 1px solid #e0e6ee;
}

#calendar td.calendar_td {
    cursor: pointer;
    border-radius: 6px;
}

#calendar td.calendar_td:hover {
    outline: 2px solid #4a90e2;
    outline-offset: -2px;
}

#data {
    margin: 0 0 10px;
    font-size: 26px;
}

#next-prev-button {
    margin-bottom: 6px;
}

#next-prev-button button {
    cursor: pointer;
}

/* =========================================
   カレンダーのレイアウト
   （右側のサイドパネルは使いません。日付を押すとモーダルで出ます）
========================================= */

.calLayout {
    display: block;
    padding: 40px 0;
}

.calLayout.calOnly {
    /* タブの幅いっぱいに広げます */
    display: block;
    width: 100%;
    margin: 0;
}

.calContArea,
.calLayout .calContArea,
.calLayout.calOnly .calContArea {
    /* 学びナビでは 50% 幅の2カラムでしたが、
       施設ページではタブの中いっぱいに広げます */
    width: 100%;
    padding: 0;
    min-width: 0;
}

.calHelp {
    margin: 12px 0 0;
    text-align: center;
    font-size: 13px;
    color: #6b8199;
}

/* モーダルの中に複数のイベントが並ぶときの区切り */
.modal-divider {
    border: 0;
    border-top: 1px solid #e0e6ee;
    margin: 20px 0;
}

.modal-event-time {
    margin: 4px 0 0;
    color: #46617f;
    font-weight: bold;
}

.calHelp .calMark {
    display: inline-block;
    width: 12px;
    height: 12px;
    border-radius: 3px;
    background: #e2703a;
    vertical-align: -1px;
    margin: 0 4px;
}

/* ============================================================
   このファイルが読み込まれているかの確認用
   検証ツールで <html> を選び、Styles に
   --facility-calendar-css: 2026-09-03b; が出れば最新です。
   ============================================================ */
:root {
    --facility-calendar-css: 2026-09-03b;
}

/* ================================================================
   日付のマス（色の付いた角丸）
   ================================================================ */
#calendar td.calendar_td {
    border-radius: 8px;
    font-weight: bold;
    transition: filter .15s;
}

/* この施設で行うイベントがある日 */
#calendar td.has-custom {
    color: #fff;
}

#calendar td.calendar_td:hover {
    outline: none;
    filter: brightness(.92);
}

/* ================================================================
   カレンダーの下：色の説明と、予約状況へのリンク
   ================================================================ */
.calLegend {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
    justify-content: center;
    margin: 16px 0 0;
    font-size: 13px;
    color: #46617f;
}

.calLegend span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.calLegend i {
    width: 14px;
    height: 14px;
    border-radius: 4px;
    display: inline-block;
}

.calLegend .isOwn {
    background: #e2703a;
}

.calLegend .isOther {
    background: #dfe4ea;
}

.calReserve {
    margin: 18px 0 0;
    text-align: center;
    font-size: 14px;
    line-height: 1.7;
}

.calReserve a {
    color: #1f6feb;
    text-decoration: underline;
    word-break: break-all;
}

/* ================================================================
   ポップアップの中身
   ================================================================ */
#modalDate {
    margin: 0 0 4px;
    padding-bottom: 6px;
    border-bottom: 2px solid #e2703a;
    color: #e2703a;
    font-size: 18px;
}

.cal-event {
    padding: 14px 0 4px;
}

/* 会場名の札 */
.cal-place-tag {
    display: inline-block;
    margin: 0 0 10px;
    padding: 5px 16px;
    border-radius: 999px;
    background: #dfe4ea;
    color: #46617f;
    font-size: 13px;
    font-weight: bold;
}

.cal-place-tag.isOwn {
    background: #e2703a;
    color: #fff;
}

.cal-event-title {
    margin: 0 0 6px;
    font-size: 17px;
    font-weight: bold;
    line-height: 1.5;
}

.cal-event-time {
    margin: 0;
    color: #7a8593;
    font-size: 14px;
}

.cal-more {
    margin: 12px 0 0;
    text-align: right;
}

.cal-more a {
    display: inline-block;
    padding: 9px 28px;
    border-radius: 999px;
    background: #e2703a;
    color: #fff;
    font-weight: bold;
    text-decoration: none;
}

.cal-more a:hover {
    filter: brightness(1.08);
}
