/* スケジュールカレンダー（トップページ）
   作り方は ../_カレンダー作成/README.md。
   大きさは横幅に合わせて伸び縮みする（cqw＝カレンダーの横幅の1%）。画像（横1460px）も同じ CSS で作る。 */
.cal-wrap { container-type: inline-size; margin: 0 0 12px; }
.cal {
  --navy: #1f2a6b; --blue: #2f6fd6; --red: #d8323c; --sat: #1e7fc4; --line: #d9dde8;
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic", "Meiryo", sans-serif;
  background: #fff; color: #222; line-height: 1.3; padding-bottom: 1.9cqw;
}
.cal *, .cal *::before, .cal *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* 見出し */
.cal-head {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--navy); color: #fff; padding: 1.8cqw 3cqw; position: relative; overflow: hidden;
}
.cal-head::after { /* チェッカーフラッグ */
  content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 11.6cqw;
  background: conic-gradient(#fff 25%, transparent 0 50%, #fff 0 75%, transparent 0) 0 0 / 2.33cqw 2.33cqw;
  opacity: .16;
  -webkit-mask-image: linear-gradient(to right, transparent, #000); mask-image: linear-gradient(to right, transparent, #000);
}
.cal-month { display: flex; align-items: baseline; gap: 1.2cqw; font-weight: 700; }
.cal-month .y { font-size: 2.33cqw; opacity: .85; }
.cal-month .m { font-size: 6.6cqw; font-weight: 900; line-height: 1; letter-spacing: -.14cqw; }
.cal-month .en { font-size: 2.05cqw; letter-spacing: .27cqw; color: #ffd23f; margin-left: .4cqw; }
.cal-brand { text-align: right; position: relative; z-index: 1; margin-right: 8.2cqw; }
.cal-brand .t1 { font-size: 2.05cqw; font-weight: 900; letter-spacing: .2cqw; }
.cal-brand .t2 { font-size: 1.5cqw; opacity: .8; letter-spacing: .14cqw; margin-top: .3cqw; }

/* 日付のマス */
.cal-grid {
  display: grid; grid-template-columns: repeat(7, minmax(0, 1fr));
  margin: 1.6cqw 1.9cqw 0; border-top: 2px solid var(--navy);
}
.cal-wd {
  text-align: center; font-size: max(11px, 1.92cqw); font-weight: 700; padding: .8cqw 0;
  color: #444; border-bottom: 1px solid var(--line);
}
.cal-wd.sun { color: var(--red); }
.cal-wd.sat { color: var(--sat); }
.cal-day {
  min-height: 13.4cqw; padding: .7cqw .8cqw .8cqw;
  border-bottom: 1px solid var(--line); border-right: 1px solid var(--line);
  display: flex; flex-direction: column; gap: .55cqw; min-width: 0;
}
.cal-day.c1 { border-left: 1px solid var(--line); }
.cal-day.empty { background: #fafbfd; }
.cal-day.closed { background: #fdeff0; }
.cal-num { font-size: max(12px, 2.74cqw); font-weight: 700; line-height: 1; }
.cal-day.sun .cal-num { color: var(--red); }
.cal-day.sat .cal-num { color: var(--sat); }

.cal-tag {
  display: block; text-align: center; border-radius: .7cqw; font-weight: 700;
  font-size: max(9px, 1.78cqw); line-height: 1.2; padding: .55cqw .2cqw; overflow-wrap: anywhere;
}
.cal-tag.run    { background: var(--navy); color: #fff; }
.cal-tag.plan   { border: 2px solid #9aa3c2; color: #5a6385; font-weight: 500; padding: .41cqw .2cqw; }
.cal-tag.event  { background: var(--blue); color: #fff; font-size: max(8px, 1.78cqw); padding-left: 0; padding-right: 0; letter-spacing: -.02em; }
.cal-tag.event span, .cal-tag.event small { display: block; white-space: nowrap; }
.cal-tag.closed { color: var(--red); font-size: max(9px, 1.92cqw); padding: .27cqw; }
.cal-tag small  { display: block; font-size: max(8px, 1.37cqw); font-weight: 500; opacity: .9; }
.cal-note { font-size: max(9px, 1.5cqw); font-weight: 700; color: #c26a00; text-align: center; }
.cal-note.gray { color: #777; }

.cal-bar { /* 冬季休業など、何日もまたがる帯 */
  align-self: end; z-index: 1; margin: 0 .7cqw 3.4cqw; height: 4.8cqw; border-radius: .7cqw;
  display: flex; align-items: center; justify-content: center;
  background: var(--red); color: #fff; font-size: max(11px, 2.05cqw); font-weight: 700; letter-spacing: .55cqw;
}

/* 凡例 */
.cal-legend {
  display: flex; flex-wrap: wrap; align-items: center; gap: .9cqw 2cqw;
  margin: 1.5cqw 1.9cqw 0; font-size: max(11px, 1.64cqw); color: #333;
}
.cal-legend .cal-tag { display: inline-block; width: 8.2cqw; min-width: 52px; font-size: max(9px, 1.5cqw); padding: .27cqw; margin-right: .5cqw; vertical-align: middle; }
.cal-legend .cal-tag.plan { padding: .14cqw .27cqw; }
.cal-legend .cal-tag.closed { background: #fdeff0; }
.cal-legend .tel { width: 100%; font-size: max(10px, 1.5cqw); color: #555; }

/* 画像を開くボタン（画像には出さない） */
.cal-imgbtn { text-align: right; margin: 6px 0 0; }
.cal-imgbtn a { /* カレンダーの青と区別するため、白地に灰色の枠 */
  display: inline-block; padding: 5px 14px; border-radius: 999px;
  background: #fff; color: #444; border: 1px solid #aaa;
  text-decoration: none; font-size: 12px;
}
.cal-imgbtn a:hover { background: #f2f2f2; border-color: #777; }
