/* /events (event hub), from the event page mockup. Scoped to the page so /pages and the top page are not affected. */
#js-event-page .section-head { align-items: flex-end; gap: .5em 1.5em; }
#js-event-page .calendar-subscribe { margin: 0 0 .25em; }
#js-event-page .section-lead { margin-top: 1em; }
#js-event-page .calendar-subscribe-note { margin-top: .75em; }
#js-event-page .p-relationList__wrap { margin-top: 1.5em; }

@media screen and (min-width: 1071px) {
  #js-event-page .l-underwrap { padding-top: 60px; padding-bottom: 60px; }
}
@media screen and (max-width: 1070px) {
  #js-event-page .l-underwrap { padding-top: 52.5px; padding-bottom: 52.5px; }
  #js-event-page .l-3clm:last-child { margin-bottom: 0; }
}

/* cards of a row share the height; image, title, period, description and button each sit on their own row across the cards.
   PC only, like /pages and the top page: on SP one card shows at a time, so each card keeps its own heights */
@media screen and (min-width: 768px) {
  #js-event-page .slick-track { display: grid; grid-auto-flow: column; grid-template-rows: repeat(5, auto); }
  #js-event-page .slick-track::before,
  #js-event-page .slick-track::after { content: none; }
  #js-event-page .slick-slide { height: auto; }
  #js-event-page .p-relationList__inner { display: grid; height: auto; }
  #js-event-page .slick-track > .p-relationList__inner { grid-template-rows: subgrid; grid-row: span 5; }
  #js-event-page .p-centerPhBox__cap,
  #js-event-page .p-centerPhBox__cap > div { display: contents; }
  #js-event-page .p-relationList__ph { grid-row: 1; }
  #js-event-page .p-relationList__inner h3 { grid-row: 2; }
  #js-event-page .p-relationList__inner .c-text_03 { grid-row: 3; }
  #js-event-page .p-relationList__desc { grid-row: 4; }
  #js-event-page .p-relationList__inner > .u-pt__1 { grid-row: 5; }
}
#js-event-page .p-relationList__inner .c-text_03 + br { display: none; }

@media screen and (min-width: 1071px) {
  #js-event-page .p-relationList__wrap.flexWrap {
    display: grid;
    grid-template-columns: repeat(3, 32%);
    grid-template-rows: repeat(5, auto);
    column-gap: 1%;
    padding: 0 0.5%;
  }
  #js-event-page .p-relationList__wrap.flexWrap > .l-3clm { display: contents; }
  #js-event-page .l-3clm > .p-relationList__inner { grid-template-rows: subgrid; grid-row: span 5; }
}

/* title, period and description are shown in full; each subgrid row grows to the tallest card of the row */

/* Android calendar import dialog: Featherlight clones it into <body>, outside #js-event-page, so it is scoped by its own block */
.p-calendarModal { max-width: 560px; margin: 0 auto; text-align: center; }
.p-calendarModal input.p-calendarModal__url { width: 100%; margin: 1em 0 1.25em; padding: .6em .8em; border: 1px solid #ccc; font-size: 16px; box-sizing: border-box; }
/* fixed one-line box, so 「URLをコピーしました」 appearing does not resize the dialog */
.p-calendarModal__copied { height: 1.75em; line-height: 1.75em; margin: .5em 0; overflow: hidden; }
/* キャンセル and URLをコピー side by side; they share the row on SP, where 200px min-width buttons would not fit */
.p-calendarModal__btns { display: flex; justify-content: center; gap: .75em; }
.p-calendarModal__btns .c-typeBtn { flex: 1 1 0; min-width: 0; max-width: 200px; padding: .87em 1em; }

@media screen and (max-width: 767px) {
  #js-event-page .section-head { display: block; }
  #js-event-page .calendar-subscribe { margin-top: 1em; }
}
