/* Sua's content, arranged within the existing light portfolio template. */
.midnight:is(.page-project, .page-partner) #main {
  width: min(760px, calc(100% - 48px));
  padding-bottom: 44px;
}
.midnight:is(.page-project, .page-partner) .cherin-page-intro {
  padding: 64px 0 38px;
  border: 0;
  position: relative;
}
.midnight:is(.page-project, .page-partner)
  .cherin-page-intro
  .page-intro-bottom {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  text-align: center;
}
.midnight .cherin-page-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 16px;
  border: 1px solid #171717;
  border-radius: 12px;
  background: #171717;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: -0.02em;
}
.midnight:is(.page-project, .page-partner) .cherin-page-intro h1 {
  margin: 20px 0 14px;
  font: 700 32px/1.35 var(--sans);
  letter-spacing: -0.055em;
  color: #111;
  word-break: keep-all;
}
.midnight:is(.page-project, .page-partner)
  .cherin-page-intro
  .page-description {
  min-width: 0;
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  letter-spacing: -0.025em;
  color: #737373;
  word-break: keep-all;
}
.midnight .cherin-category-heading {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 0 0 18px;
}
.midnight .cherin-category-heading h2 {
  flex: none;
  font: 600 14px/1.5 var(--sans);
  letter-spacing: -0.025em;
  color: #333;
}
.midnight .cherin-category-heading > span {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, #dedede, #ededed);
}
.midnight .cherin-category-spaced {
  margin-top: 30px;
}

/* Project cards retain their filters, anchors, full captures, and destinations. */
.midnight.page-project .project-toolbar {
  margin: 0 0 20px;
  gap: 12px;
  flex-wrap: wrap;
}
.midnight.page-project .filter-group {
  gap: 6px;
  flex-wrap: wrap;
}
.midnight.page-project .filter-group button {
  font-size: 11px;
  line-height: 1.5;
  border-radius: 8px;
  padding: 6px 11px;
  min-height: 32px;
}
.midnight.page-project .filter-group button span {
  font-size: 10px;
  margin-left: 5px;
}
.midnight.page-project .project-toolbar > .kicker {
  font-size: 10px;
  letter-spacing: 0.04em;
}
.midnight.page-project .project-collection {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}
.midnight.page-project .project-case {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid #e5e5e5;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 1px 3px #00000003;
  scroll-margin-top: 100px;
  transition:
    box-shadow 0.2s,
    border-color 0.2s;
}
.midnight.page-project .project-case:hover {
  border-color: #d4d4d4;
  box-shadow: 0 3px 12px #00000007;
}
.midnight.page-project .project-case[hidden] {
  display: none;
}
.midnight.page-project .project-case:nth-child(n) .case-visual {
  order: 0;
  grid-column: auto;
  grid-row: auto;
  min-width: 0;
}
.midnight.page-project .project-case:nth-child(n) .case-copy {
  order: 1;
  grid-column: auto;
  grid-row: auto;
  min-width: 0;
  padding: 20px;
}
.midnight.page-project .case-visual .project-art,
.midnight.page-project .case-visual .project-capture {
  height: 192px;
  min-height: 192px;
  aspect-ratio: auto;
  margin: 0;
  padding: 0;
  border: 0;
  border-bottom: 1px solid #ededed;
  border-radius: 0;
  background: #f5f5f5;
}
.midnight.page-project .case-visual .project-capture {
  display: flex;
  align-items: stretch;
  justify-content: center;
  background: #191919;
}
.midnight.page-project .project-capture .capture-open,
.midnight.page-project .capture-identity .capture-open {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 192px;
  max-height: 192px;
  min-height: 0;
  width: 100%;
  border-radius: 0;
  background: transparent;
}
.midnight.page-project .project-capture .capture-open > img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 0;
  box-shadow: none;
}
.midnight.page-project .case-visual .capture-identity {
  background: #aed5f1;
}
.midnight.page-project .project-capture .capture-caption {
  display: none;
}
.midnight.page-project .case-copy h2 {
  font: 600 16px/1.5 var(--sans);
  letter-spacing: -0.025em;
  color: #111;
  margin: 0;
}
.midnight.page-project .case-copy > .kicker {
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: -0.015em;
  color: #737373;
  margin: 3px 0 0;
}
.midnight.page-project .case-copy h3 {
  font: 500 12px/1.65 var(--sans);
  letter-spacing: -0.015em;
  color: #404040;
  margin: 12px 0 0;
  word-break: keep-all;
}
.midnight.page-project .case-copy > p:not(.kicker) {
  font-size: 12px;
  line-height: 1.8;
  letter-spacing: -0.015em;
  color: #737373;
  margin: 7px 0 0;
  word-break: keep-all;
}
.midnight.page-project .case-details {
  margin: 12px 0 0;
  color: #737373;
  font-size: 11px;
  line-height: 1.7;
}
.midnight.page-project .case-details > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  width: 100%;
  padding: 3px 0;
  list-style: none;
  cursor: pointer;
  color: #525252;
  font-weight: 500;
}
.midnight.page-project .case-details > summary::-webkit-details-marker {
  display: none;
}
.midnight.page-project .case-details > summary span {
  font-size: 13px;
  color: #a3a3a3;
  transition: rotate 0.2s;
}
.midnight.page-project .case-details[open] > summary span {
  rotate: 180deg;
}
.midnight.page-project .case-features {
  font-size: 11px;
  line-height: 1.75;
  color: #737373;
  margin: 8px 0 0;
  gap: 5px;
}
.midnight.page-project .case-features li::before {
  color: #a3a3a3;
}
.midnight.page-project .tag-list {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.midnight.page-project .tag-list > span {
  font-size: 11px;
  line-height: 1.5;
  font-weight: 500;
  padding: 3px 7px;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 6px;
  color: #525252;
}
.midnight.page-project .case-links {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  justify-content: flex-end;
  gap: 5px;
  max-width: calc(100% - 16px);
  margin: 0;
  flex-wrap: wrap;
  z-index: 2;
}
.midnight.page-project .case-links a.primary-link,
.midnight.page-project .case-links a.text-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 5px 8px;
  border: 1px solid #171717;
  border-radius: 6px;
  background: #171717;
  color: #fff;
  font: 500 10px/1.5 var(--sans);
  letter-spacing: 0;
  box-shadow: 0 1px 3px #0002;
  text-decoration: none;
}
.midnight.page-project .case-links a:hover {
  background: #333;
  border-color: #333;
}
.midnight.page-project .art-orbit {
  isolation: isolate;
}
.midnight.page-project .art-orbit > img {
  width: 72px;
  height: 72px;
  position: absolute;
  inset: 38px auto auto calc(50% - 36px);
  transform: none;
  opacity: 1;
}
.midnight.page-project .art-orbit .art-name {
  font: 600 26px/1 var(--sans);
  letter-spacing: -0.05em;
  position: absolute;
  inset: auto 0 34px;
  text-align: center;
  color: #525252;
  transform: none;
}
.midnight.page-project .art-orbit .art-category,
.midnight.page-project .art-orbit .art-caption,
.midnight.page-project .art-orbit .art-corner,
.midnight.page-project .art-orbit .art-spark {
  display: none;
}
.midnight.page-project .art-orbit .art-ring {
  width: 260px;
  height: 260px;
  opacity: 0.3;
}
.midnight.page-project .experience {
  margin: 48px 0 0;
  padding: 0;
}
.midnight.page-project .cherin-community-copy {
  font-size: 12px;
  color: #737373;
  margin: -7px 0 14px;
  line-height: 1.8;
  word-break: keep-all;
}
.midnight.page-project .experience-row {
  padding: 18px 0;
  gap: 15px;
  border-color: #ededed;
}
.midnight.page-project .experience-row h3 {
  font-size: 14px;
  font-weight: 500;
  color: #333;
}
.midnight.page-project .experience-row small {
  font-size: 11px;
  color: #737373;
}
.midnight.page-project .experience-row > span:first-child {
  font-size: 9px;
  color: #a3a3a3;
}

/* Partner cards use the existing people and descriptions without adding claims. */
.midnight.page-partner .partner-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 0;
}
.midnight.page-partner .partner-list > .cherin-category-heading {
  margin-bottom: 3px;
}
.midnight.page-partner .partner-list > .cherin-category-spaced {
  margin-top: 24px;
}
.midnight.page-partner .partner-row {
  position: relative;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr) auto;
  align-items: center;
  gap: 22px;
  padding: 28px;
  border: 1px solid #ededed;
  border-radius: 14px;
  background:
    radial-gradient(ellipse at 0 0, #f6f8ff88, transparent 70%),
    linear-gradient(120deg, #fff, #fdfcff);
  box-shadow: 0 4px 16px #00000004;
  min-width: 0;
}
.midnight.page-partner .partner-row:nth-of-type(2n) {
  background:
    radial-gradient(ellipse at 100% 100%, #fff1f755, transparent 70%), #fff;
}
.midnight.page-partner .partner-number {
  display: none;
}
.midnight.page-partner .partner-portrait {
  width: 76px;
  height: 76px;
  border-radius: 50%;
  border: 1px solid #eee;
  overflow: hidden;
  box-shadow: 0 0 0 4px #fff8;
  background: #f5f5f5;
  grid-column: 1;
  grid-row: 1;
}
.midnight.page-partner .partner-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: none;
}
.midnight.page-partner .portrait-fallback {
  font-size: 23px;
  color: #a3a3a3;
}
.midnight.page-partner .partner-copy {
  min-width: 0;
  grid-column: 2;
  grid-row: 1;
}
.midnight.page-partner .partner-copy > .kicker {
  font-size: 9px;
  color: #a3a3a3;
  letter-spacing: 0.05em;
}
.midnight.page-partner .partner-copy h2 {
  font: 600 18px/1.5 var(--sans);
  letter-spacing: -0.035em;
  color: #171717;
  margin: 3px 0 0;
}
.midnight.page-partner .partner-handle {
  display: block;
  font-size: 10px;
  line-height: 1.6;
  letter-spacing: 0;
  color: #a3a3a3;
  margin: 2px 0 0;
}
.midnight.page-partner .partner-copy p {
  font-size: 12px;
  line-height: 1.8;
  letter-spacing: -0.02em;
  color: #737373;
  margin: 9px 0 0;
  word-break: keep-all;
}
.midnight.page-partner .partner-row .round-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: auto;
  height: auto;
  min-height: 34px;
  padding: 7px 13px;
  background: #171717;
  border: 1px solid #171717;
  border-radius: 999px;
  color: #fff;
  font: 500 11px/1.5 var(--sans);
  letter-spacing: -0.015em;
  white-space: nowrap;
  grid-column: 3;
  grid-row: 1;
}
.midnight.page-partner .partner-row .round-arrow:hover {
  background: #333;
  border-color: #333;
}
.midnight.page-partner .partner-heart {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  font-size: 23px;
  color: #c7b6c4;
  grid-column: 3;
  grid-row: 1;
}
.midnight.page-partner .partner-invite {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  margin: 42px 0 0;
  padding: 26px;
  border: 1px solid #ededed;
  border-radius: 12px;
  background: #fafafa;
}
.midnight.page-partner .partner-invite > span {
  width: 28px;
  flex: none;
  color: #737373;
}
.midnight.page-partner .partner-invite > div {
  flex: 1;
  min-width: 190px;
}
.midnight.page-partner .partner-invite .kicker {
  font-size: 9px;
  color: #a3a3a3;
}
.midnight.page-partner .partner-invite h2 {
  font: 600 18px/1.6 var(--sans);
  letter-spacing: -0.04em;
  color: #333;
  margin: 5px 0 0;
}
.midnight.page-partner .partner-invite h2 em {
  font: inherit;
  color: inherit;
}
.midnight.page-partner .partner-invite p {
  font-size: 12px;
  color: #737373;
  line-height: 1.8;
  margin-top: 5px;
  word-break: keep-all;
}
.midnight.page-partner .partner-invite .primary-link {
  margin: 0;
  padding: 8px 12px;
  min-height: 34px;
  gap: 12px;
  background: #171717;
  border: 1px solid #171717;
  border-radius: 8px;
  color: #fff;
  font-size: 11px;
  white-space: nowrap;
}
@media (max-width: 639px) {
  .midnight:is(.page-project, .page-partner) #main {
    width: calc(100% - 40px);
    padding-bottom: 28px;
  }
  .midnight:is(.page-project, .page-partner) .cherin-page-intro {
    padding: 46px 0 32px;
  }
  .midnight:is(.page-project, .page-partner) .cherin-page-intro h1 {
    font-size: 28px;
    line-height: 1.4;
    margin: 18px 0 12px;
  }
  .midnight:is(.page-project, .page-partner)
    .cherin-page-intro
    .page-description {
    font-size: 12px;
    line-height: 1.8;
  }
  .midnight.page-project .project-collection {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .midnight.page-project .project-toolbar > .kicker {
    font-size: 9px;
  }
  .midnight.page-project .filter-group button {
    font-size: 10px;
    padding-inline: 9px;
  }
  .midnight.page-project .filter-group button span {
    display: inline;
    font-size: 9px;
  }
  .midnight.page-project .project-case:nth-child(n) .case-copy {
    padding: 20px;
  }
  .midnight.page-project .case-links a.primary-link,
  .midnight.page-project .case-links a.text-link {
    font-size: 10px;
  }
  .midnight.page-project .experience-row {
    grid-template-columns: 68px 1fr 24px;
    gap: 12px;
  }
  .midnight.page-project .experience-row h3 {
    font-size: 13px;
  }
  .midnight.page-project .experience-row small {
    font-size: 10px;
  }
  .midnight.page-project .experience-row > span:first-child {
    font-size: 8px;
  }
  .midnight.page-partner .partner-row {
    grid-template-columns: 62px minmax(0, 1fr);
    gap: 17px;
    padding: 23px 20px;
  }
  .midnight.page-partner .partner-portrait {
    width: 62px;
    height: 62px;
    align-self: start;
    margin-top: 6px;
  }
  .midnight.page-partner .partner-copy h2 {
    font-size: 17px;
  }
  .midnight.page-partner .partner-copy p {
    font-size: 12px;
    margin-top: 8px;
  }
  .midnight.page-partner .partner-copy > .kicker {
    font-size: 8px;
  }
  .midnight.page-partner .partner-row .round-arrow {
    grid-column: 2;
    grid-row: 2;
    justify-self: start;
    min-height: 32px;
    padding: 6px 12px;
    font-size: 10px;
    margin-top: -4px;
  }
  .midnight.page-partner .partner-heart {
    position: absolute;
    right: 17px;
    top: 17px;
    width: 24px;
    height: 24px;
    font-size: 19px;
    opacity: 0.7;
  }
  .midnight.page-partner .partner-invite {
    padding: 22px 20px;
    gap: 14px;
  }
  .midnight.page-partner .partner-invite > span {
    display: none;
  }
  .midnight.page-partner .partner-invite > div {
    min-width: 100%;
  }
  .midnight.page-partner .partner-invite h2 {
    font-size: 17px;
  }
  .midnight.page-partner .partner-invite .primary-link {
    font-size: 11px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .midnight.page-project .project-case,
  .midnight.page-project .case-details > summary span {
    transition: none;
  }
}
