/* 公開サイト STINGER 風スタイル */
:root {
  --pub-bg: #fefefe;
  --pub-text: #333;
  --pub-muted: #6c757d;
  --pub-accent: #6c7b46;
  --pub-accent-dark: #4f5a32;
  --pub-border: #e1e1e1;
  --pub-soft: #f7f7f2;
  --pub-highlight: #fff7d6;
}

* { box-sizing: border-box; }

body.public-site {
  margin: 0;
  padding: 0;
  font-family: -apple-system, "Hiragino Kaku Gothic ProN", "ヒラギノ角ゴ ProN", "Yu Gothic", "Meiryo", sans-serif;
  background: var(--pub-bg);
  color: var(--pub-text);
  line-height: 1.7;
  font-size: 16px;
}

body.public-site a {
  color: var(--pub-accent);
  text-decoration: none;
}
body.public-site a:hover {
  color: var(--pub-accent-dark);
  text-decoration: underline;
}

/* ヘッダー */
.pub-header {
  background: #fff;
  border-bottom: 1px solid var(--pub-border);
}
.pub-header-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.pub-logo img {
  max-height: 70px;
  width: auto;
  display: block;
}
.pub-header-contact {
  font-size: 14px;
}

/* ナビゲーション */
.pub-nav {
  background: var(--pub-soft);
  border-bottom: 1px solid var(--pub-border);
}
.pub-nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-wrap: wrap;
}
.pub-nav-inner a {
  display: block;
  padding: 14px 18px;
  color: var(--pub-text);
  font-size: 14px;
  border-right: 1px solid var(--pub-border);
}
.pub-nav-inner a:first-child { border-left: 1px solid var(--pub-border); }
.pub-nav-inner a:hover {
  background: #fff;
  color: var(--pub-accent-dark);
  text-decoration: none;
}
.pub-nav-inner a.active {
  background: #fff;
  color: var(--pub-accent-dark);
  font-weight: bold;
}

/* メインコンテナ */
.pub-main {
  max-width: 1100px;
  margin: 30px auto;
  padding: 0 20px;
}
.pub-page-title {
  font-size: 24px;
  font-weight: normal;
  border-left: 6px solid var(--pub-accent);
  padding: 6px 14px;
  margin: 0 0 24px;
  color: var(--pub-accent-dark);
}

/* 2カラム */
.pub-grid {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 30px;
}
@media (max-width: 900px) {
  .pub-grid { grid-template-columns: 1fr; }
}

/* イベントリスト */
.pub-event-list { list-style: none; padding: 0; margin: 0; }
.pub-event-item {
  padding: 18px 20px;
  border: 1px solid var(--pub-border);
  border-left: 4px solid var(--pub-accent);
  margin-bottom: 16px;
  background: #fff;
  border-radius: 4px;
  transition: box-shadow .15s;
}
.pub-event-item:hover { box-shadow: 0 2px 8px rgba(0,0,0,.05); }
.pub-event-date {
  font-size: 14px;
  color: var(--pub-muted);
  margin-bottom: 4px;
}
.pub-event-date .badge-new {
  background: var(--pub-accent);
  color: #fff;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 3px;
  margin-left: 6px;
}
.pub-event-title {
  font-size: 18px;
  font-weight: bold;
  margin: 6px 0;
}
.pub-event-title a { color: var(--pub-text); }
.pub-event-title a:hover { color: var(--pub-accent-dark); }
.pub-event-meta { font-size: 13px; color: var(--pub-muted); }
.pub-event-meta dl { margin: 4px 0; display: flex; flex-wrap: wrap; gap: 6px 20px; }
.pub-event-meta dt { font-weight: normal; color: var(--pub-muted); margin-right: 4px; }
.pub-event-meta dd { margin: 0; }
body.public-site a.pub-event-apply,
body.public-site a.pub-event-apply:visited {
  display: inline-block;
  margin-top: 10px;
  padding: 6px 14px;
  background: var(--pub-accent);
  color: #fff;
  border-radius: 3px;
  font-size: 14px;
  text-decoration: none;
}
body.public-site a.pub-event-apply:hover {
  background: var(--pub-accent-dark);
  color: #fff;
  text-decoration: none;
}
body.public-site a.pub-event-apply.is-disabled {
  background: #999;
}

.pub-empty {
  padding: 40px 20px;
  text-align: center;
  color: var(--pub-muted);
  background: var(--pub-soft);
  border-radius: 4px;
}

/* カレンダー */
.pub-calendar {
  background: #fff;
  border: 1px solid var(--pub-border);
  border-radius: 4px;
  padding: 16px;
}
.pub-calendar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}
.pub-calendar-title {
  font-size: 16px;
  font-weight: bold;
}
.pub-calendar-nav a {
  display: inline-block;
  padding: 4px 10px;
  margin: 0 2px;
  border: 1px solid var(--pub-border);
  border-radius: 3px;
  font-size: 14px;
  color: var(--pub-text);
}
.pub-calendar-nav a:hover {
  background: var(--pub-soft);
  text-decoration: none;
}
.pub-calendar table {
  width: 100%;
  border-collapse: collapse;
}
.pub-calendar table {
  table-layout: fixed;
}
.pub-calendar th, .pub-calendar td {
  padding: 0;
  text-align: center;
  font-size: 13px;
  border: 1px solid var(--pub-border);
  width: 14.28%;
}
.pub-calendar th {
  background: var(--pub-soft);
  font-weight: normal;
  font-size: 12px;
  padding: 6px 0;
}
.pub-calendar th.sun, .pub-calendar td.sun { color: #c0392b; }
.pub-calendar th.sat, .pub-calendar td.sat { color: #2980b9; }
.pub-calendar td.other-month { background: #fafafa; color: #ccc; }
.pub-calendar td.today { background: var(--pub-highlight); font-weight: bold; }
.pub-calendar td.has-event { background: #eef3e4; }

/* 全セル共通の内部コンテナ: 日付 + インジケータ領域を常に確保 */
.pub-calendar .day-cell {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  height: 56px;
  padding: 6px 2px;
  color: inherit;
  text-decoration: none;
  border-radius: 3px;
}
.pub-calendar .day-link {
  cursor: pointer;
}
.pub-calendar .day-link:hover {
  background: rgba(108, 123, 70, .25);
  text-decoration: none;
}
.pub-calendar .day-num {
  display: block;
  font-size: 14px;
  line-height: 1;
}
/* インジケータ領域は常に一定高さを確保（ドット/バッジ/空のどれでも） */
.pub-calendar .day-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 18px;
  margin-top: 6px;
}
.pub-calendar .event-dot {
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--pub-accent);
  border-radius: 50%;
}
.pub-calendar .event-count-badge {
  display: inline-block;
  min-width: 18px;
  height: 16px;
  padding: 0 4px;
  background: var(--pub-accent);
  color: #fff;
  font-size: 10px;
  line-height: 16px;
  border-radius: 8px;
  font-weight: bold;
}

/* ポップオーバー（日付クリック時のイベント一覧） */
.day-popover[hidden] { display: none; }
.day-popover {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.day-popover-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, .45);
}
.day-popover-panel {
  position: relative;
  background: #fff;
  border-radius: 6px;
  width: 90%;
  max-width: 460px;
  max-height: 80vh;
  overflow: auto;
  box-shadow: 0 6px 24px rgba(0, 0, 0, .2);
}
.day-popover-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--pub-border);
  background: var(--pub-soft);
}
.day-popover-close {
  background: none;
  border: none;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  color: var(--pub-muted);
  padding: 0 4px;
}
.day-popover-close:hover { color: #000; }
.day-popover-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.day-popover-list li {
  border-bottom: 1px solid var(--pub-border);
}
.day-popover-list li:last-child { border-bottom: none; }
.day-popover-list a {
  display: block;
  padding: 14px 18px;
  color: var(--pub-text);
  text-decoration: none;
}
.day-popover-list a:hover {
  background: var(--pub-soft);
  text-decoration: none;
}
.day-popover-time {
  font-size: 13px;
  color: var(--pub-muted);
  margin-bottom: 4px;
}
.day-popover-list .day-popover-title {
  font-size: 15px;
  font-weight: bold;
  color: var(--pub-accent-dark);
  margin-bottom: 2px;
}
.day-popover-venue {
  font-size: 12px;
  color: var(--pub-muted);
}

/* フッター */
.pub-footer {
  background: #f0f0ea;
  border-top: 1px solid var(--pub-border);
  margin-top: 60px;
  padding: 20px 0;
  text-align: center;
  color: var(--pub-muted);
  font-size: 13px;
}
.pub-footer-nav {
  margin-bottom: 10px;
}
.pub-footer-nav a {
  display: inline-block;
  padding: 0 10px;
  color: var(--pub-text);
  border-right: 1px solid var(--pub-border);
}
.pub-footer-nav a:last-child { border-right: none; }

/* 汎用 */
.pub-section-title {
  font-size: 18px;
  font-weight: bold;
  margin: 0 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--pub-accent);
}
