/* Scoped catalogue layout; compact screens reflow, large desktops scale together. */
#missions {
  background: linear-gradient(135deg, var(--m5-surface,#fff), var(--m5-surface-blue,#f4fbff) 55%, var(--m5-surface,#fbf8ff));
  color: var(--m5-foreground,#151344);
  padding: 0 0 30px;
  overflow: clip;
}
#missions * {
  box-sizing: border-box;
}
#missions svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  vertical-align: middle;
}
#missions button,
#missions select,
#missions input {
  font: inherit;
}
#missions button {
  cursor: pointer;
}
#missions button:focus-visible,
#missions select:focus-visible,
#missions input:focus-visible {
  outline: 3px solid #aa91ff;
  outline-offset: 3px;
}
#missions [hidden] {
  display: none !important;
}
.m5-list-hero {
  background: linear-gradient(110deg, var(--m5-surface,#f7faff), var(--m5-surface-purple,#eef6ff) 70%, var(--m5-surface-purple,#f4f0ff));
  position: relative;
  isolation: isolate;
}
.m5-list-hero:after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 65px;
  background: linear-gradient(100deg, var(--m5-surface-purple,#e9e5ff), var(--m5-surface-purple,#d7cfff));
  clip-path: polygon(
    0 0,
    15% 100%,
    50% 100%,
    58% 0,
    76% 100%,
    100% 0,
    100% 100%,
    0 100%
  );
  z-index: -1;
}
.m5-list-hero-inner {
  max-width: 1180px;
  margin: auto;
  min-height: 230px;
  position: relative;
  padding: 24px 0 32px;
  display: flex;
  align-items: center;
}
.m5-list-hero-copy {
  position: relative;
  z-index: 2;
  max-width: 650px;
}
.m5-list-kicker {
  display: inline-block;
  border-radius: 20px;
  background: var(--m5-surface-purple,#eeebff);
  color: var(--m5-foreground-muted,#5929ff);
  font-size: 10px;
  font-weight: 800;
  padding: 8px 14px;
}
#missions h1 {
  font-size: 48px;
  line-height: 1.1;
  letter-spacing: -1.6px;
  margin: 5px 0 6px;
  font-weight: 850;
  color: var(--m5-foreground,#100d51);
}
#missions h1 span {
  color: var(--m5-foreground,#009454);
}
.m5-list-hero-copy > p {
  margin: 0;
  color: var(--m5-foreground-muted,#606794);
  font-size: 16px;
  line-height: 1.3;
}
.m5-list-count {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
  font-size: 15px;
}
.m5-list-count > span {
  background: var(--m5-surface-purple,#ede7ff);
  color: var(--m5-foreground-muted,#673cff);
  padding: 3px 8px;
  border-radius: 50%;
  margin-right: 6px;
}
.m5-list-count > b {
  color: var(--m5-foreground,#00a556);
  font-size: 20px;
}
.m5-list-hero-art {
  position: absolute;
  right: 0;
  top: 0;
  width: 470px;
  height: 230px;
  overflow: hidden;
  pointer-events: none;
}
.m5-list-hero-art > img {
  position: absolute;
  height: 235px;
  right: 95px;
  top: 0;
  object-fit: contain;
  max-width: 260px;
}
.m5-list-hero-art > .m5-list-hero-dog {
  height: 145px;
  right: 192px;
  top: 84px;
  max-width: 155px;
  border-radius: 80px;
}
.m5-list-hero-heart {
  position: absolute;
  left: 0;
  top: 18px;
  color: #d9d0ff;
  font-size: 110px;
  transform: rotate(-18deg);
}
.m5-list-hero-art > p {
  position: absolute;
  right: 0;
  top: 25px;
  width: 132px;
  font-size: 17px;
  line-height: 1.3;
  font-style: italic;
  color: var(--m5-foreground-muted,#6734ff);
  transform: rotate(-9deg);
}
.m5-list-controls {
  max-width: 1180px;
  margin: -24px auto 8px;
  position: relative;
  z-index: 3;
}
.m5-list-search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px;
  border: 4px solid var(--m5-surface,white);
  border-radius: 19px;
  background: var(--m5-surface,#fff);
  box-shadow: 0 4px 15px #6553b515;
}
.m5-list-search > span {
  font-size: 28px;
  color: var(--m5-foreground-muted,#7a72b8);
  padding-left: 12px;
}
#missions .m5-list-search input {
  border: 0;
  box-shadow: none;
  outline: 0;
  background: transparent;
  min-width: 0;
  flex: 1;
  height: 40px;
  font-size: 13px;
  color: var(--m5-foreground,#28224f);
  padding: 0 8px;
}
.m5-list-search > button {
  border: 0;
  color: white;
  background: linear-gradient(#9173ff, #5221ff);
  border-radius: 13px;
  height: 44px;
  padding: 0 30px;
  font-size: 14px;
  font-weight: 750;
}
.m5-list-filters {
  display: flex;
  gap: 10px;
  margin: 10px 0 8px;
  flex-wrap: wrap;
}
.m5-list-filters label {
  display: flex;
  gap: 8px;
  align-items: center;
  min-width: 105px;
  flex: 1;
  border: 1px solid var(--m5-border,#e6e6fc);
  border-radius: 11px;
  background: var(--m5-surface,#fff);
  padding: 0 12px;
  box-shadow: 0 2px 5px #33257908;
  color: var(--m5-foreground,#332798);
}
#missions .m5-list-filters select {
  border: 0;
  background: transparent;
  box-shadow: none;
  max-width: 100%;
  width: 100%;
  height: 38px;
  padding: 0;
  font-size: 12px;
  color: var(--m5-foreground,#27215f);
  cursor: pointer;
}
.m5-list-filters label.m5-list-sort {
  margin-left: 50px;
  min-width: 165px;
}
.m5-list-tools {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
}
.m5-list-tools button {
  background: var(--m5-surface-purple,#eee8ff);
  border: 0;
  border-radius: 8px;
  color: var(--m5-foreground-muted,#5d31df);
  padding: 7px;
}
.m5-list-tools p:empty {
  display: none;
}
.m5-list-tools p {
  margin: 0 0 8px;
}
.m5-list-tip {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 8px 16px;
  border: 1px solid var(--m5-border,#dceeed);
  border-radius: 10px;
  background: var(--m5-surface-green,#ebf6f3);
  color: var(--m5-foreground-muted,#656195);
  font-size: 12px;
}
.m5-list-tip > span {
  color: var(--m5-foreground,#009b57);
  font-size: 24px;
}
.m5-list-tip p {
  margin: 0;
  flex: 1;
}
.m5-list-tip strong {
  color: var(--m5-foreground,#009b57);
}
.m5-list-tip button {
  border: 0;
  background: transparent;
  color: var(--m5-foreground-muted,#686093);
  font-size: 22px;
}
.m5-list-grid-wrap {
  max-width: 1570px;
  margin: 0 auto;
  padding: 0 30px;
}
.m5-list-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 17px;
}
.m5-list-card {
  background: var(--m5-surface,#fff);
  border: 1px solid var(--m5-border,#e8eafb);
  border-radius: 13px;
  overflow: hidden;
  box-shadow: 0 4px 9px #40377b07;
  min-width: 0;
}
.m5-list-photo {
  position: relative;
  height: 170px;
  background: var(--m5-surface-purple,#f1edf9);
}
.m5-list-photo > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.m5-list-category {
  position: absolute;
  left: 12px;
  top: 10px;
  background: #f8f6ffed;
  border-radius: 10px;
  padding: 6px 12px;
  font-weight: 750;
  font-size: 12px;
  color: var(--m5-foreground-muted,#5521ff);
}
.m5-list-favorite {
  position: absolute;
  right: 12px;
  top: 8px;
  display: grid;
  place-items: center;
  width: 35px;
  height: 35px;
  background: #15134428;
  border: 0;
  border-radius: 50%;
  color: white;
}
#missions .m5-list-favorite svg {
  width: 25px;
  height: 25px;
}
.m5-list-favorite[aria-pressed="true"] {
  color: var(--m5-foreground-muted,#8145ff);
  background: var(--m5-surface,white);
}
.m5-list-favorite[aria-pressed="true"] svg {
  fill: currentColor;
}
.m5-list-copy {
  padding: 9px 16px 8px;
}
#missions .m5-list-copy h3 {
  font-size: 16px;
  margin: 0 0 2px;
  line-height: 1.25;
  overflow-wrap: anywhere;
}
.m5-list-copy > p {
  font-size: 12px;
  color: var(--m5-foreground-muted,#636690);
  line-height: 1.3;
  margin: 0 0 5px;
  min-height: 31px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.m5-list-meta,
.m5-list-details {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 18px;
  color: var(--m5-foreground-muted,#646793);
  font-size: 11px;
  margin: 5px 0;
}
.m5-list-meta > span,
.m5-list-details > span {
  display: inline-flex;
  gap: 8px;
  align-items: center;
  min-width: 0;
}
.m5-list-meta > span > span {
  overflow-wrap: anywhere;
}
.m5-list-details > b {
  color: var(--m5-foreground,#009650);
  font-size: 17px;
  min-width: 62px;
}
.m5-list-details {
  align-items: center;
}
.m5-list-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
}
.m5-list-author {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex-wrap: wrap;
}
.m5-list-avatar {
  width: 35px;
  height: 35px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--m5-surface-purple,#eee8ff);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  font-size: 17px;
}
.m5-list-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.m5-list-author-copy {
  font-size: 11px;
  display: flex;
  flex-direction: column;
  gap: 1px;
  max-width: 160px;
  overflow-wrap: anywhere;
}
.m5-list-rating {
  color: var(--m5-foreground-muted,#d9980d);
}
.m5-list-verified {
  font-size: 10px;
  color: var(--m5-foreground-muted,#568174);
  display: flex;
  align-items: center;
  gap: 4px;
}
.m5-list-verified svg {
  color: var(--m5-foreground,#00a65b);
}
#missions .m5-list-open {
  background: var(--m5-surface-purple,#f0ebff);
  border: 0;
  border-radius: 10px;
  color: var(--m5-foreground-muted,#5f24ff);
  white-space: nowrap;
  font-weight: 750;
  font-size: 12px;
  padding: 10px 14px;
  display: flex;
  gap: 8px;
  align-items: center;
}
.m5-list-empty {
  grid-column: 1/-1;
  display: grid;
  justify-items: center;
  gap: 20px;
  padding: 50px 15px;
  color: var(--m5-foreground-muted,#646793);
}
.m5-list-empty button {
  padding: 10px 20px;
  border: 1px solid var(--m5-border,#c8b6ff);
  border-radius: 10px;
  background: var(--m5-surface,#fff);
  color: var(--m5-foreground-muted,#652dff);
}
#m5ListMore {
  display: block;
  margin: 20px auto 0;
}
body.m5-listing-active main {
  min-height: 0;
}
body.m5-listing-active header {
  background: var(--m5-surface,#fff);
}
@media (min-width: 1680px) {
  #missions {
    zoom: var(--m5-home-scale, 1);
  }
  body.m5-listing-active header,
  body.m5-listing-active footer {
    zoom: var(--m5-home-scale, 1);
  }
}
@media (max-width: 1250px) {
  .m5-list-hero-inner,
  .m5-list-controls {
    margin-left: 30px;
    margin-right: 30px;
  }
  .m5-list-hero-copy {
    max-width: 60%;
  }
  .m5-list-hero-art {
    right: -10px;
    width: 400px;
  }
  .m5-list-hero-art > p {
    right: 0;
  }
  .m5-list-hero-art > img {
    right: 100px;
  }
  .m5-list-filters label.m5-list-sort {
    margin-left: 0;
  }
  .m5-list-footer {
    flex-wrap: wrap;
  }
  .m5-list-verified {
    display: none;
  }
}
@media (max-width: 950px) {
  .m5-list-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .m5-list-hero-art {
    width: 300px;
  }
  .m5-list-hero-art > p {
    display: none;
  }
  .m5-list-hero-art > img {
    right: 0;
  }
  .m5-list-hero-art > .m5-list-hero-dog {
    right: 100px;
  }
  .m5-list-hero-heart {
    display: none;
  }
  #missions h1 {
    font-size: 38px;
  }
  .m5-list-filters label {
    min-width: 135px;
  }
  .m5-list-footer {
    flex-wrap: nowrap;
  }
}
@media (max-width: 600px) {
  .m5-list-hero-inner {
    margin: 0 18px;
    padding: 20px 0 40px;
    min-height: 200px;
  }
  .m5-list-hero-copy {
    max-width: 100%;
  }
  .m5-list-hero-art {
    display: none;
  }
  #missions h1 {
    font-size: 34px;
  }
  .m5-list-hero-copy > p {
    font-size: 14px;
  }
  .m5-list-controls {
    margin: -23px 14px 12px;
  }
  .m5-list-search {
    gap: 0;
    border-width: 2px;
    border-radius: 14px;
  }
  .m5-list-search > button {
    padding: 0 12px;
    font-size: 12px;
  }
  .m5-list-search > span {
    padding-left: 5px;
  }
  .m5-list-filters {
    gap: 7px;
  }
  .m5-list-filters label {
    min-width: calc(50% - 7px);
    max-width: calc(50% - 3.5px);
    padding: 0 9px;
  }
  .m5-list-filters label.m5-list-sort {
    min-width: 100%;
    max-width: 100%;
  }
  .m5-list-tip {
    gap: 8px;
    padding: 8px 10px;
  }
  .m5-list-grid-wrap {
    padding: 0 14px;
  }
  .m5-list-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .m5-list-photo {
    height: 180px;
  }
  .m5-list-copy {
    padding: 10px 12px;
  }
  .m5-list-meta,
  .m5-list-details {
    gap: 6px 12px;
  }
  .m5-list-author-copy {
    max-width: 130px;
  }
  #missions .m5-list-open {
    padding: 10px;
    font-size: 11px;
  }
  .m5-list-verified {
    display: none;
  }
}
/* Keep the dog's face visible in the portrait fallback, including wide cards. */
.m5-list-photo > img[src="/assets/m5-home-mission-dog.webp"] {
  object-position: center 28%;
}
.m5-list-hero-art > img {
  width: 350px;
  max-width: none;
  object-fit: contain;
}
.m5-list-status {
  position: absolute;
  bottom: 10px;
  left: 12px;
  padding: 5px 10px;
  border-radius: 8px;
  background: var(--m5-surface-green,#e5f9ef);
  color: var(--m5-foreground,#078b50);
  font-size: 11px;
  font-weight: 700;
}
