:root {
  --hf-accent: var(--hf-brand-red, #e3000b);
  --hf-ink: #131313;
  --hf-muted: #66605c;
  --hf-line: #d7cec6;
  --hf-paper: #f8f5f1;
  --hf-thumb-w: 122px;
  --hf-event-title-letter-spacing: 0.01em;
  --hf-event-summary-secondary-size: 1.05rem;
}

.hf-event-calendar-view .site-main.container {
  max-width: min(1100px, var(--hf-site-width));
  width: min(1100px, var(--hf-site-width), calc(100% - 3rem));
  margin-inline: auto;
}

.hf-event-calendar-view #content > .site-main.container {
  margin-right: auto;
  margin-left: auto;
}

.hf-event-calendar-view .site-main.container.hf-layout-media-left-experiment {
  max-width: 800px;
  width: min(800px, calc(100% - 3rem));
  background: #fff;
  padding-left: 30px;
  padding-right: 30px;
  box-sizing: border-box;
}

.hf-event-calendar-view .page-header.hf-headerbar {
  background: transparent;
  padding: clamp(1.5rem, 3vw, 2.5rem) 0 1rem;
  margin-bottom: 2rem;
}

.hf-headerbar .page-title {
  margin: 0 0 1.15rem;
}

.hf-event-calendar-view .page-header.hf-headerbar--program {
	margin-bottom: 0;
	padding-top: 10px;
	padding-bottom: 0;
}

.hf-event-calendar-view .site-main.hf-layout-media-left-experiment {
	margin-top: 0;
}

.hf-headerbar--program .page-title {
	margin-bottom: 0;
}

.hf-headerbar--program + .hf-indent #hf-events > .hf-month:first-child {
	margin-top: var(--hf-page-title-end-space);
}

.hf-search-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}

.hf-calendar-back {
  color: var(--hf-muted);
  font-size: 0.875rem;
  font-weight: 600;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

.hf-calendar-back:hover,
.hf-calendar-back:focus-visible {
  color: var(--hf-accent);
}

.hf-search {
  position: relative;
  display: flex;
  align-items: center;
  width: min(100%, 600px);
}

.hf-search-slot {
  display: flex;
  justify-content: center;
  min-width: 0;
  width: 100%;
}

.hf-search input[type=search] {
  width: 100%;
  min-width: 0;
  height: 52px;
  padding: 0.75rem 3.75rem 0.75rem 1.15rem;
  border: 1px solid #d8d2ca;
  border-radius: 999px;
  background: #fff;
  color: var(--hf-ink);
  box-sizing: border-box;
  appearance: none;
}

.hf-search--has-query input[type=search] {
  padding-right: 6.25rem;
}

.hf-search input[type=search]::-webkit-search-cancel-button {
  appearance: none;
}

.hf-search input[type=search]:focus {
  border-color: var(--hf-accent);
  outline: 2px solid rgba(228, 75, 52, 0.18);
  outline-offset: 2px;
}

.hf-search-action {
  position: absolute;
  top: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--hf-accent);
  text-decoration: none;
  transform: translateY(-50%);
}

.hf-search-action:hover {
  background: rgba(228, 75, 52, 0.08);
  color: var(--hf-accent);
}

.hf-search-action:focus-visible {
  outline: 2px solid var(--hf-accent);
  outline-offset: 2px;
}

.hf-search-action svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.hf-search-submit {
  right: 5px;
}

.hf-search.is-loading .hf-search-submit svg {
  visibility: hidden;
}

.hf-search.is-loading .hf-search-submit::after {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(228, 75, 52, 0.24);
  border-top-color: currentColor;
  border-radius: 50%;
  content: "";
  animation: hf-search-spin 0.7s linear infinite;
}

.hf-search-status {
  position: absolute;
  top: calc(100% + 0.45rem);
  left: 1.15rem;
  color: var(--hf-muted);
  font-size: 0.8rem;
  line-height: 1.2;
}

@keyframes hf-search-spin {
  to {
    transform: rotate(360deg);
  }
}

.hf-search-clear {
  right: 47px;
  color: var(--hf-muted);
}

.hf-indent {
  padding: 0;
}

#hf-events {
  display: grid;
}

.hf-calendar-archive-link {
	margin: 2rem 0 0;
  text-align: center;
}

.hf-calendar-archive-link a {
  color: var(--hf-muted);
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

.hf-calendar-archive-link a:hover,
.hf-calendar-archive-link a:focus-visible {
  color: var(--hf-accent);
}

.hf-calendar-closing {
  margin: 3.5rem auto 0;
  color: var(--hf-accent);
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
}

.hf-month {
  margin: 1.8rem 0 0.95rem;
  padding: 0.95rem 0 0.9rem;
  border-top: 2px dotted var(--hf-line);
  border-bottom: 2px dotted var(--hf-line);
}

.hf-month h2 {
  margin: 0;
  text-align: center;
  font-size: clamp(1.85rem, 2.5vw, 2.15rem);
  font-weight: 800;
  color: var(--hf-ink);
  letter-spacing: -0.03em;
  line-height: 1.06;
}

.hf-event {
  position: relative;
  display: grid;
  grid-template-columns: 102px 1fr var(--hf-thumb-w);
  gap: 1.25rem;
  padding: 1.35rem 0 1.5rem;
  border-bottom: 2px dotted var(--hf-line);
  align-items: start;
}

.hf-event-datebox {
  color: var(--hf-ink);
  text-align: left;
  line-height: 1;
}

.hf-event-day {
  font-size: 2.55rem;
  font-weight: 800;
  letter-spacing: -0.05em;
  margin-bottom: 0.12rem;
}

.hf-event-daynum {
  font-size: 2.55rem;
  font-weight: 800;
  letter-spacing: -0.08em;
  margin-bottom: 0.18rem;
}

.hf-event-time {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--hf-ink);
}

.hf-event-body {
  min-width: 0;
}

.hf-event-title {
  margin: 0;
  font-size: 1.56rem;
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: var(--hf-event-title-letter-spacing);
  text-transform: uppercase;
}

.hf-event-title a {
  color: var(--hf-ink);
  text-decoration: none;
}

.hf-event-sub {
  margin: 0.22rem 0 0;
  color: var(--hf-muted);
  font-size: 0.95rem;
  line-height: 1.2;
}

.hf-event-meta {
  margin-top: 0.5rem;
  font-size: 0.96rem;
  font-weight: 700;
}

.hf-event.open .hf-event-meta {
  display: none;
}

.hf-event-meta a,
.hf-detail-close,
.hf-detail-close--top {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--hf-accent);
  font: inherit;
  text-decoration: none;
  cursor: pointer;
}

.hf-event-meta a::before,
.hf-detail-close::before,
.hf-detail-close--top::before {
  content: "›";
  margin-right: 0.3rem;
}

.hf-event-visual {
  justify-self: end;
}

.hf-thumb {
  width: var(--hf-thumb-w);
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: var(--hf-paper);
}

.hf-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.hf-detail-close--top {
  position: absolute;
  top: 1.2rem;
  right: calc(var(--hf-thumb-w) + 1rem);
  display: none;
  font-weight: 700;
}

.hf-event.open .hf-detail-close--top {
  display: inline-flex;
}

.hf-detail {
  display: grid;
  grid-template-rows: 0fr;
  overflow: hidden;
  opacity: 0;
  visibility: hidden;
  transition:
    grid-template-rows 720ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 360ms ease,
    visibility 0s linear 720ms;
}

.hf-detail-inner {
  min-height: 0;
  overflow: hidden;
  transform: translateY(-4px);
  transition: transform 720ms cubic-bezier(0.22, 1, 0.36, 1);
}

.hf-event.open .hf-detail {
  grid-template-rows: 1fr;
  opacity: 1;
  visibility: visible;
  transition:
    grid-template-rows 720ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 360ms ease,
    visibility 0s;
}

.hf-event.open .hf-detail-inner {
  transform: translateY(0);
}

.hf-detail-main {
  margin-top: 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
  color: #2e2a27;
  max-width: 40rem;
}

.hf-detail-main p {
  margin: 0 0 1rem;
}

.hf-detail-meta {
  margin-top: 1rem;
  padding-top: 0.85rem;
  border-top: 1px solid #e1dad3;
  font-size: 0.98rem;
}

.hf-detail-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 0.25rem;
  color: #2e2a27;
}

.hf-detail-label {
  font-weight: 700;
}

.hf-detail-value a,
.hf-detail-links a {
  color: var(--hf-accent);
  text-decoration: none;
  font-weight: 600;
}

.hf-detail-links {
  display: grid;
  gap: 0.25rem;
  margin-top: 0.75rem;
  font-size: 0.98rem;
}

.hf-detail-payment-note,
.hf-sidebox-payment-note {
	margin: 0.7rem 0 0;
	padding-top: 0.65rem;
	border-top: 1px solid #d4d4d4;
	font-size: 0.82rem;
	font-weight: 600;
	line-height: 1.3;
	max-width: 100%;
	min-width: 0;
	white-space: normal;
	overflow-wrap: break-word;
}

.hf-detail-actions {
  display: flex;
  justify-content: flex-start;
  margin-top: 1.2rem;
}

.hf-detail-close {
  font-weight: 700;
}

.hf-layout-media-left-experiment .hf-event {
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 2rem;
  padding: 0.7rem 0 0.75rem;
  border-bottom: 0;
}

.hf-layout-media-left-experiment .hf-event-datebox,
.hf-layout-media-left-experiment .hf-event-visual {
  display: none;
}

.hf-layout-media-left-experiment .hf-event-media-stack {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-self: start;
}

.hf-layout-media-left-experiment .hf-thumb--list {
  width: 100%;
  aspect-ratio: 1 / 1;
}

.hf-layout-media-left-experiment .hf-thumb--list img {
  transition: filter 240ms ease;
}

.hf-layout-media-left-experiment .hf-event.open .hf-thumb--list img {
  filter: grayscale(1);
}

.hf-layout-media-left-experiment .hf-event-main {
  min-width: 0;
}

.hf-layout-media-left-experiment .hf-event-summary-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.hf-layout-media-left-experiment .hf-event-datetime,
.hf-layout-media-left-experiment .hf-detail-datetime {
  font-size: var(--hf-event-summary-secondary-size);
  font-weight: 700;
  line-height: 1;
  color: var(--hf-muted);
  margin-bottom: 0.55rem;
}

.hf-event-datetime__separator {
  display: none;
}

.hf-event-datetime__date,
.hf-event-datetime__time {
  display: block;
}

.hf-event-datetime__time {
  margin-top: 0.2rem;
}

.hf-layout-media-left-experiment .hf-event-title {
  font-size: 1.85rem;
}

.hf-layout-media-left-experiment .hf-event-sub {
  margin-top: 0.35rem;
  font-size: var(--hf-event-summary-secondary-size);
}

.hf-layout-media-left-experiment .hf-event-meta {
  margin-top: 0.8rem;
}

.hf-layout-media-left-experiment .hf-event.open .hf-event-meta {
  display: none;
}

.hf-layout-media-left-experiment .hf-detail-main--media-left {
  margin-top: 1.2rem;
  max-width: none;
}

.hf-detail-images {
  display: grid;
  gap: 1rem;
  margin-top: 1.5rem;
  max-width: 40rem;
}

.hf-detail-hero .hf-event-thumb {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
}

.hf-layout-media-left-experiment .hf-event-sidebox {
  display: grid;
  grid-template-rows: 0fr;
  padding: 0 1.05rem;
  background: #efefef;
  color: #2e2a27;
  font-size: 0.94rem;
  line-height: 1.15;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition:
    grid-template-rows 720ms cubic-bezier(0.22, 1, 0.36, 1),
    padding 720ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 360ms ease,
    transform 720ms cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s linear 720ms;
}

.hf-layout-media-left-experiment .hf-event.open .hf-event-sidebox {
  grid-template-rows: 1fr;
  padding: 1rem 1.05rem;
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  transition:
    grid-template-rows 720ms cubic-bezier(0.22, 1, 0.36, 1),
    padding 720ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 360ms ease,
    transform 720ms cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0s;
}

.hf-layout-media-left-experiment .hf-event-sidebox-inner {
  display: grid;
  gap: 0.4rem;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 0;
  box-sizing: border-box;
  overflow: hidden;
}

.hf-layout-media-left-experiment .hf-event-sidebox-inner > * {
  max-width: 100%;
  min-width: 0;
}

.hf-layout-media-left-experiment .hf-sidebox-row {
  display: flex;
  gap: 0.45rem;
  align-items: baseline;
  flex-wrap: wrap;
  max-width: 100%;
  min-width: 0;
  margin: 0;
}

.hf-layout-media-left-experiment .hf-sidebox-row--stacked {
  align-items: flex-start;
}

.hf-layout-media-left-experiment .hf-sidebox-label {
  font-weight: 700;
}

.hf-layout-media-left-experiment .hf-sidebox-value {
  display: grid;
  gap: 0.1rem;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hf-layout-media-left-experiment .hf-sidebox-value a,
.hf-layout-media-left-experiment .hf-sidebox-value > span {
  display: block;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.hf-layout-media-left-experiment .hf-sidebox-value a {
  color: var(--hf-accent);
  text-decoration: none;
}

.hf-layout-media-left-experiment .hf-sidebox-links {
  gap: 0.35rem;
}

.hf-layout-media-left-experiment .hf-sidebox-row--links {
  display: block;
  margin-top: 0.6rem;
}

.hf-layout-media-left-experiment .hf-detail-close--top {
  position: static;
  display: none;
  font-size: 0.94rem;
  line-height: 1;
  flex: 0 0 auto;
  margin-top: 0;
}

.hf-layout-media-left-experiment .hf-event.open .hf-detail-close--top {
  display: inline-flex;
}

@media (max-width: 760px) {
  :root {
    --hf-thumb-w: 104px;
  }

  .hf-headerbar .page-title,
  .hf-month h2,
  .hf-event-title {
    hyphens: none;
    overflow-wrap: normal;
    word-break: normal;
  }

  .hf-event-title,
  .hf-layout-media-left-experiment .hf-event-title {
    font-size: clamp(1.125rem, 5vw, 1.35rem);
    line-height: 1.08;
  }

  .hf-event-datetime__date,
  .hf-event-datetime__time,
  .hf-event-datetime__separator {
    display: inline;
  }

  .hf-event-datetime__time {
    margin-top: 0;
  }

  .hf-event-datetime__suffix {
    display: none;
  }

  .hf-search-row {
    gap: 0.85rem;
  }

  .hf-search {
    width: 100%;
  }

  .hf-search-slot {
    width: 100%;
  }

  #hf-events {
    grid-template-columns: minmax(0, 1fr);
  }

  .hf-event,
  .hf-event-title,
  .hf-event-sub,
  .hf-detail,
  .hf-detail-inner,
  .hf-detail-main,
  .hf-event-sidebox,
  .hf-event-sidebox-inner,
  .hf-sidebox-row,
  .hf-sidebox-value {
    min-width: 0;
    max-width: 100%;
  }

  .hf-event-title,
  .hf-event-sub,
  .hf-detail-main pre {
    overflow-wrap: anywhere;
  }

  .hf-detail-main pre {
    max-width: 100%;
    white-space: pre-wrap;
  }

  .hf-event {
    grid-template-columns: 84px 1fr;
  }

  .hf-layout-media-left-experiment .hf-event {
    display: flex;
    flex-direction: column;
    gap: 0;
  }

  .hf-layout-media-left-experiment .hf-event-media-stack,
  .hf-layout-media-left-experiment .hf-event-main,
  .hf-layout-media-left-experiment .hf-event-summary {
    display: contents;
  }

  .hf-layout-media-left-experiment .hf-event-summary-head {
    order: 1;
  }

  .hf-layout-media-left-experiment .hf-event-title {
    order: 2;
  }

  .hf-layout-media-left-experiment .hf-event-media-stack > .hf-event-thumb-wrap {
    display: block;
    order: 3;
    width: 100%;
    margin: 0.8rem 0 0.65rem;
    line-height: 0;
  }

  .hf-layout-media-left-experiment .hf-thumb--list {
    aspect-ratio: 2 / 1;
  }

  .hf-layout-media-left-experiment .hf-event-sub {
    order: 5;
  }

  .hf-layout-media-left-experiment .hf-event-meta {
    order: 6;
  }

  .hf-layout-media-left-experiment .hf-event-sidebox {
    order: 4;
    width: 100%;
    margin-top: 0;
    box-sizing: border-box;
  }

  .hf-layout-media-left-experiment .hf-detail {
    order: 7;
  }

  .hf-layout-media-left-experiment .hf-event.open .hf-event-media-stack > .hf-event-thumb-wrap {
    margin-bottom: 0;
  }

  .hf-layout-media-left-experiment .hf-event.open .hf-detail-close--top {
    display: none;
  }

  .hf-layout-media-left-experiment .hf-event.open .hf-thumb--list img {
    filter: none;
  }

  .hf-event-visual {
    grid-column: 2;
    justify-self: start;
    margin-top: 0.8rem;
  }

  .hf-thumb,
  .hf-detail-close--top {
    right: 0;
  }

  .hf-detail-images {
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hf-detail,
  .hf-detail-inner,
  .hf-layout-media-left-experiment .hf-event-sidebox,
  .hf-layout-media-left-experiment .hf-thumb--list img {
    transition: none;
  }
}
