:root {
  --xy-bg: #0b0910;
  --xy-panel: rgba(27, 23, 34, .82);
  --xy-panel-strong: #1c1823;
  --xy-text: #f7f3fb;
  --xy-muted: #a9a0b5;
  --xy-line: rgba(255, 255, 255, .09);
  --xy-accent: #d9b8ff;
  --xy-accent-2: #a98bff;
  --xy-rose: #ffb7d7;
  --xy-shadow: 0 24px 80px rgba(0, 0, 0, .34);
}

html.xy-fast-lobby-active {
  background: var(--xy-bg);
  color-scheme: dark;
}

body.xy-fast-lobby-body {
  margin: 0;
  min-width: 320px;
  min-height: 100dvh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 12% -6%, rgba(142, 99, 201, .28), transparent 33rem),
    radial-gradient(circle at 94% 9%, rgba(157, 72, 126, .16), transparent 29rem),
    var(--xy-bg);
  color: var(--xy-text);
  font-family: Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.xy-fast-lobby,
.xy-fast-lobby *,
.xy-fast-lobby *::before,
.xy-fast-lobby *::after {
  box-sizing: border-box;
}

.xy-fast-lobby {
  min-height: 100dvh;
  isolation: isolate;
}

.xy-fast-lobby::before {
  position: fixed;
  z-index: -1;
  inset: 0;
  content: "";
  pointer-events: none;
  opacity: .22;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.86' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.14'/%3E%3C/svg%3E");
}

.xy-fast-lobby button,
.xy-fast-lobby input {
  color: inherit;
  font: inherit;
}

.xy-fast-lobby button {
  border: 0;
  cursor: pointer;
}

.xy-fast-lobby button:focus-visible,
.xy-role-card:focus-visible,
.xy-fast-lobby input:focus-visible {
  outline: 2px solid var(--xy-accent);
  outline-offset: 3px;
}

.xy-topbar {
  position: sticky;
  z-index: 30;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 12px max(24px, calc((100vw - 1480px) / 2));
  border-bottom: 1px solid rgba(255, 255, 255, .07);
  background: rgba(11, 9, 16, .76);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .16);
  backdrop-filter: blur(22px) saturate(135%);
}

.xy-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--xy-text);
  text-decoration: none;
}

.xy-brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 14px;
  background: linear-gradient(145deg, #f4deff, #ba95f5 54%, #9975e9);
  box-shadow: 0 10px 28px rgba(175, 126, 255, .28), inset 0 1px rgba(255, 255, 255, .55);
  color: #24182f;
  font-family: "Songti SC", SimSun, serif;
  font-size: 21px;
  font-weight: 900;
}

.xy-brand-copy {
  display: grid;
  gap: 1px;
}

.xy-brand-copy strong {
  letter-spacing: .06em;
  font-size: 15px;
}

.xy-brand-copy small {
  color: var(--xy-muted);
  font-size: 10px;
  letter-spacing: .14em;
}

.xy-topnav {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--xy-muted);
  font-size: 13px;
}

.xy-nav-active,
.xy-model-state {
  padding: 9px 12px;
  border-radius: 999px;
}

.xy-nav-active {
  background: rgba(255, 255, 255, .06);
  color: var(--xy-text);
}

.xy-model-state i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 3px;
  border-radius: 50%;
  background: #7bf2b2;
  box-shadow: 0 0 0 4px rgba(123, 242, 178, .1), 0 0 14px rgba(123, 242, 178, .6);
}

.xy-group-entry,
.xy-primary-button {
  min-height: 40px;
  padding: 0 17px;
  border: 1px solid rgba(255, 255, 255, .26);
  border-radius: 13px;
  background: linear-gradient(135deg, #ead6ff, #b899f7);
  box-shadow: 0 10px 28px rgba(159, 117, 230, .22);
  color: #261a34 !important;
  font-weight: 750 !important;
  transition: transform .2s ease, filter .2s ease, box-shadow .2s ease;
}

.xy-group-entry:hover,
.xy-primary-button:hover:not(:disabled) {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow: 0 14px 34px rgba(159, 117, 230, .32);
}

.xy-group-entry.is-quiet {
  border-color: var(--xy-line);
  background: rgba(255, 255, 255, .06);
  box-shadow: none;
  color: var(--xy-text) !important;
}

.xy-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(420px, .65fr);
  align-items: end;
  gap: 40px;
  max-width: 1480px;
  margin: 0 auto;
  padding: clamp(62px, 8vw, 110px) 24px 48px;
}

.xy-eyebrow,
.xy-result-heading p {
  margin: 0 0 12px;
  color: var(--xy-accent);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: .17em;
  text-transform: uppercase;
}

.xy-hero h1 {
  margin: 0;
  background: linear-gradient(110deg, #fff 15%, #dfc8f7 62%, #d2a5c4);
  background-clip: text;
  color: transparent;
  font-family: "Songti SC", STSong, serif;
  font-size: clamp(48px, 6.5vw, 88px);
  font-weight: 800;
  letter-spacing: -.06em;
  line-height: .98;
}

.xy-hero-description {
  max-width: 700px;
  margin: 22px 0 0;
  color: #bcb3c6;
  font-size: clamp(14px, 1.4vw, 17px);
  line-height: 1.8;
}

.xy-hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  overflow: hidden;
  border: 1px solid var(--xy-line);
  border-radius: 22px;
  background: linear-gradient(145deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .025));
  box-shadow: var(--xy-shadow);
  backdrop-filter: blur(18px);
}

.xy-stat {
  display: grid;
  min-height: 108px;
  align-content: center;
  justify-items: center;
  gap: 7px;
  padding: 20px 10px;
}

.xy-stat + .xy-stat {
  border-left: 1px solid var(--xy-line);
}

.xy-stat strong {
  font-family: "SF Pro Display", Inter, sans-serif;
  font-size: clamp(19px, 2vw, 28px);
  letter-spacing: -.04em;
}

.xy-stat strong.xy-online {
  color: #8af0b9;
  font-size: 19px;
}

.xy-stat span {
  color: var(--xy-muted);
  font-size: 11px;
}

.xy-content {
  max-width: 1480px;
  margin: 0 auto;
  padding: 0 24px 100px;
}

.xy-controls {
  position: relative;
  z-index: 4;
  padding: 18px;
  border: 1px solid var(--xy-line);
  border-radius: 24px;
  background: rgba(24, 20, 30, .72);
  box-shadow: 0 22px 70px rgba(0, 0, 0, .24);
  backdrop-filter: blur(18px);
}

.xy-search-row {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) auto auto;
  align-items: center;
  gap: 12px;
}

.xy-search {
  display: flex;
  align-items: center;
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 15px;
  background: rgba(0, 0, 0, .18);
  transition: border-color .2s ease, background .2s ease, box-shadow .2s ease;
}

.xy-search:focus-within {
  border-color: rgba(210, 178, 255, .5);
  background: rgba(0, 0, 0, .25);
  box-shadow: 0 0 0 4px rgba(189, 151, 247, .08);
}

.xy-search > span {
  margin-right: 11px;
  color: var(--xy-accent);
  font-size: 21px;
}

.xy-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  font-size: 14px;
}

.xy-search input::placeholder {
  color: #746c7e;
}

.xy-sort-tabs {
  display: flex;
  padding: 4px;
  border: 1px solid var(--xy-line);
  border-radius: 14px;
  background: rgba(0, 0, 0, .16);
}

.xy-sort-button,
.xy-filter-trigger {
  min-height: 42px;
  padding: 0 14px;
  border-radius: 10px;
  background: transparent;
  color: var(--xy-muted) !important;
  font-size: 12px !important;
  transition: background .18s ease, color .18s ease;
}

.xy-sort-button.is-active {
  background: rgba(255, 255, 255, .09);
  color: #fff !important;
  box-shadow: inset 0 1px rgba(255, 255, 255, .06);
}

.xy-filter-trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-width: 90px;
  border: 1px solid var(--xy-line) !important;
  background: rgba(255, 255, 255, .035);
}

.xy-filter-trigger.is-active {
  border-color: rgba(202, 166, 255, .38) !important;
  background: rgba(189, 151, 247, .12);
  color: var(--xy-text) !important;
}

.xy-filter-trigger b {
  display: grid;
  width: 18px;
  height: 18px;
  place-items: center;
  border-radius: 50%;
  background: var(--xy-accent);
  color: #23182e;
  font-size: 10px;
}

.xy-filter-trigger i {
  font-style: normal;
}

.xy-primary-filters {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 15px;
}

.xy-filter-label {
  flex: 0 0 auto;
  color: #847b8d;
  font-size: 11px;
  letter-spacing: .05em;
}

.xy-filter-options {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.xy-choice,
.xy-category-chip {
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid transparent !important;
  border-radius: 999px;
  background: transparent;
  color: #aaa1b4 !important;
  font-size: 11px !important;
  white-space: nowrap;
  transition: border-color .18s ease, background .18s ease, color .18s ease, transform .18s ease;
}

.xy-choice:hover,
.xy-category-chip:hover {
  background: rgba(255, 255, 255, .05);
  color: #eee8f4 !important;
}

.xy-choice.is-active,
.xy-category-chip.is-active {
  border-color: rgba(213, 184, 255, .22) !important;
  background: rgba(202, 166, 255, .13);
  color: #eadcff !important;
}

.xy-favorite-filter {
  margin-left: auto;
}

.xy-favorite-filter.is-active {
  border-color: rgba(255, 164, 205, .25) !important;
  background: rgba(255, 164, 205, .1);
  color: #ffc5df !important;
}

.xy-advanced-filters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
  gap: 18px;
  margin-top: 16px;
  padding: 18px;
  border: 1px solid rgba(213, 184, 255, .12);
  border-radius: 17px;
  background: rgba(8, 7, 12, .3);
  animation: xy-sheet-in .2s ease both;
}

.xy-advanced-filters[hidden] {
  display: none;
}

.xy-filter-group {
  display: grid;
  align-content: start;
  gap: 8px;
}

.xy-reset-button {
  align-self: end;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid var(--xy-line) !important;
  border-radius: 11px;
  background: rgba(255, 255, 255, .035);
  color: var(--xy-muted) !important;
  font-size: 11px !important;
}

.xy-categories {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  margin-top: 14px;
  padding: 12px 0 2px;
  border-top: 1px solid var(--xy-line);
  scrollbar-width: none;
}

.xy-categories::-webkit-scrollbar {
  display: none;
}

.xy-results {
  scroll-margin-top: 92px;
  margin-top: 44px;
}

.xy-result-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}

.xy-result-heading p {
  margin-bottom: 6px;
}

.xy-result-heading h2 {
  margin: 0;
  font-family: "Songti SC", STSong, serif;
  font-size: clamp(28px, 3vw, 40px);
  letter-spacing: -.045em;
}

.xy-result-heading > span {
  color: var(--xy-muted);
  font-size: 12px;
}

.xy-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.xy-role-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--xy-line);
  border-radius: 21px;
  background: linear-gradient(155deg, rgba(38, 32, 47, .95), rgba(20, 17, 26, .96));
  box-shadow: 0 16px 40px rgba(0, 0, 0, .17);
  cursor: pointer;
  content-visibility: auto;
  contain-intrinsic-size: 420px;
  animation: xy-card-in .46s cubic-bezier(.2, .8, .2, 1) both;
  animation-delay: var(--xy-delay, 0ms);
  transition: transform .24s ease, border-color .24s ease, box-shadow .24s ease;
}

.xy-role-card:hover {
  transform: translateY(-5px);
  border-color: rgba(216, 185, 255, .28);
  box-shadow: 0 24px 55px rgba(0, 0, 0, .32), 0 0 0 1px rgba(189, 151, 247, .06);
}

.xy-role-card.is-selected {
  border-color: rgba(215, 186, 255, .72);
  box-shadow: 0 0 0 2px rgba(189, 151, 247, .24), 0 24px 55px rgba(0, 0, 0, .3);
}

.xy-role-card.is-disabled {
  cursor: not-allowed;
  opacity: .5;
  filter: grayscale(.35);
}

.xy-card-visual {
  position: relative;
  display: grid;
  overflow: hidden;
  aspect-ratio: 1.38 / 1;
  place-items: center;
  background:
    radial-gradient(circle at 28% 22%, rgba(221, 184, 255, .32), transparent 45%),
    linear-gradient(145deg, #3a2f49, #18141f);
}

.xy-card-fallback {
  color: rgba(255, 255, 255, .22);
  font-family: "Songti SC", STSong, serif;
  font-size: 68px;
  font-weight: 800;
}

.xy-card-visual img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  object-fit: cover;
  transition: opacity .35s ease, transform .5s ease;
}

.xy-card-visual img.is-loaded {
  opacity: 1;
}

.xy-role-card:hover .xy-card-visual img {
  transform: scale(1.035);
}

.xy-card-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(8, 7, 11, .76), transparent 52%);
  pointer-events: none;
}

.xy-card-gender,
.xy-card-complete,
.xy-card-select,
.xy-card-enter {
  position: absolute;
  z-index: 2;
}

.xy-card-gender,
.xy-card-complete {
  top: 12px;
  min-height: 26px;
  padding: 0 9px;
  border: 1px solid rgba(255, 255, 255, .15);
  border-radius: 999px;
  background: rgba(16, 13, 20, .62);
  color: rgba(255, 255, 255, .88);
  font-size: 10px;
  line-height: 24px;
  backdrop-filter: blur(10px);
}

.xy-card-gender {
  left: 12px;
}

.xy-card-complete {
  right: 48px;
  color: #dfc7ff;
}

.xy-card-favorite {
  position: absolute;
  z-index: 3;
  top: 10px;
  right: 10px;
  display: grid;
  width: 32px;
  height: 32px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .16) !important;
  border-radius: 50%;
  background: rgba(16, 13, 20, .64);
  color: #fff !important;
  font-size: 16px !important;
  backdrop-filter: blur(10px);
}

.xy-card-favorite.is-active {
  color: #ffb9d6 !important;
}

.xy-card-select {
  right: 13px;
  bottom: 12px;
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .34);
  border-radius: 50%;
  background: rgba(18, 14, 24, .74);
  color: #fff;
  font-size: 17px;
  font-weight: 800;
}

.xy-role-card.is-selected .xy-card-select {
  border-color: #e5ceff;
  background: #d5b4ff;
  color: #21162c;
}

.xy-card-enter {
  right: 13px;
  bottom: 13px;
  transform: translateY(6px);
  opacity: 0;
  color: #f1e5ff;
  font-size: 11px;
  transition: opacity .2s ease, transform .2s ease;
}

.xy-role-card:hover .xy-card-enter {
  transform: translateY(0);
  opacity: 1;
}

.xy-card-body {
  display: grid;
  gap: 11px;
  padding: 17px 17px 16px;
}

.xy-card-title-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.xy-card-title-row h3 {
  overflow: hidden;
  margin: 0;
  font-size: 16px;
  font-weight: 750;
  letter-spacing: -.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.xy-card-title-row span {
  flex: 0 0 auto;
  color: #8e8499;
  font-size: 10px;
}

.xy-card-description {
  display: -webkit-box;
  min-height: 3.2em;
  overflow: hidden;
  margin: 0;
  color: #aaa2b3;
  font-size: 12px;
  line-height: 1.6;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.xy-card-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding-top: 11px;
  border-top: 1px solid var(--xy-line);
  color: #817888;
  font-size: 10px;
}

.xy-card-meta span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.xy-skeleton {
  pointer-events: none;
}

.xy-skeleton .xy-card-visual,
.xy-skeleton .xy-card-body span {
  background: linear-gradient(100deg, rgba(255, 255, 255, .035) 20%, rgba(255, 255, 255, .09) 42%, rgba(255, 255, 255, .035) 64%);
  background-size: 240% 100%;
  animation: xy-shimmer 1.25s linear infinite;
}

.xy-skeleton .xy-card-body span {
  display: block;
  width: 62%;
  height: 11px;
  border-radius: 999px;
}

.xy-skeleton .xy-card-body span:first-child {
  width: 82%;
  height: 16px;
}

.xy-skeleton .xy-card-body span:last-child {
  width: 44%;
}

.xy-empty {
  grid-column: 1 / -1;
  display: grid;
  min-height: 330px;
  place-items: center;
  align-content: center;
  gap: 10px;
  border: 1px dashed rgba(255, 255, 255, .12);
  border-radius: 22px;
  background: rgba(255, 255, 255, .02);
  text-align: center;
}

.xy-empty-mark {
  display: grid;
  width: 50px;
  height: 50px;
  margin-bottom: 5px;
  place-items: center;
  border-radius: 17px;
  background: rgba(213, 184, 255, .12);
  color: var(--xy-accent);
  font-family: "Songti SC", STSong, serif;
  font-size: 22px;
}

.xy-empty strong {
  font-size: 18px;
}

.xy-empty p {
  margin: 0 0 10px;
  color: var(--xy-muted);
  font-size: 12px;
}

.xy-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 30px;
}

.xy-page-button,
.xy-page-number {
  min-height: 38px;
  padding: 0 13px;
  border: 1px solid var(--xy-line) !important;
  border-radius: 11px;
  background: rgba(255, 255, 255, .035);
  color: var(--xy-muted) !important;
  font-size: 11px !important;
}

.xy-page-number {
  width: 38px;
  padding: 0;
}

.xy-page-number.is-active {
  border-color: rgba(213, 184, 255, .36) !important;
  background: rgba(202, 166, 255, .15);
  color: #f2e7ff !important;
}

.xy-page-button:disabled {
  cursor: not-allowed;
  opacity: .38;
}

.xy-page-ellipsis {
  color: #716978;
}

.xy-group-dock {
  position: fixed;
  z-index: 40;
  right: 24px;
  bottom: max(20px, env(safe-area-inset-bottom));
  left: 24px;
  display: grid;
  grid-template-columns: minmax(210px, 1fr) auto auto;
  align-items: center;
  gap: 18px;
  max-width: 980px;
  min-height: 82px;
  margin: auto;
  padding: 14px 16px;
  border: 1px solid rgba(224, 202, 255, .2);
  border-radius: 23px;
  background: rgba(24, 20, 30, .9);
  box-shadow: 0 24px 80px rgba(0, 0, 0, .5), inset 0 1px rgba(255, 255, 255, .06);
  backdrop-filter: blur(24px) saturate(140%);
  animation: xy-dock-in .3s cubic-bezier(.2, .8, .2, 1) both;
}

.xy-group-dock[hidden] {
  display: none;
}

.xy-group-copy {
  display: flex;
  align-items: center;
  gap: 11px;
}

.xy-group-icon {
  display: grid;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(145deg, #e6ceff, #ad8aea);
  color: #261930;
  font-weight: 800;
}

.xy-group-copy > div {
  display: grid;
  gap: 4px;
}

.xy-group-copy strong {
  font-size: 13px;
}

.xy-group-copy small {
  color: var(--xy-muted);
  font-size: 10px;
}

.xy-group-avatars {
  display: flex;
  align-items: center;
  min-width: 88px;
}

.xy-group-avatar,
.xy-group-empty {
  position: relative;
  display: grid;
  width: 40px;
  height: 40px;
  overflow: hidden;
  margin-left: -7px;
  place-items: center;
  border: 2px solid #251f2d !important;
  border-radius: 50%;
  background: #443650;
  color: #e8d9f7;
  font-size: 12px;
}

.xy-group-avatar:first-child,
.xy-group-empty:first-child {
  margin-left: 0;
}

.xy-group-avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.xy-group-avatar i {
  position: absolute;
  display: none;
  inset: 0;
  place-items: center;
  background: rgba(12, 9, 15, .7);
  color: #fff;
  font-size: 16px;
  font-style: normal;
}

.xy-group-avatar:hover i {
  display: grid;
}

.xy-group-empty {
  border-style: dashed !important;
  background: transparent;
  color: #776d80;
}

.xy-group-actions {
  display: flex;
  gap: 8px;
}

.xy-secondary-button {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--xy-line) !important;
  border-radius: 12px;
  background: rgba(255, 255, 255, .04);
  color: var(--xy-muted) !important;
  font-size: 12px !important;
}

.xy-primary-button:disabled {
  cursor: not-allowed;
  filter: grayscale(.7);
  opacity: .42;
}

.xy-toast {
  position: fixed;
  z-index: 60;
  top: 88px;
  left: 50%;
  padding: 11px 16px;
  transform: translate(-50%, -12px);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  background: rgba(25, 21, 31, .92);
  box-shadow: 0 14px 40px rgba(0, 0, 0, .35);
  opacity: 0;
  color: #f2e9fa;
  font-size: 12px;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  backdrop-filter: blur(18px);
}

.xy-toast.is-visible {
  transform: translate(-50%, 0);
  opacity: 1;
}

@keyframes xy-sheet-in {
  from { transform: translateY(-6px); opacity: 0; }
}

@keyframes xy-card-in {
  from { transform: translateY(13px); opacity: 0; }
}

@keyframes xy-dock-in {
  from { transform: translateY(18px) scale(.98); opacity: 0; }
}

@keyframes xy-shimmer {
  to { background-position-x: -140%; }
}

@media (max-width: 1120px) {
  .xy-hero {
    grid-template-columns: 1fr;
  }

  .xy-hero-stats {
    max-width: 620px;
  }

  .xy-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .xy-advanced-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 820px) {
  .xy-topbar {
    min-height: 64px;
    padding: 10px 16px;
  }

  .xy-nav-active,
  .xy-model-state {
    display: none;
  }

  .xy-hero {
    padding: 52px 18px 34px;
  }

  .xy-hero h1 {
    font-size: clamp(44px, 13vw, 68px);
  }

  .xy-content {
    padding: 0 14px 90px;
  }

  .xy-controls {
    padding: 13px;
    border-radius: 19px;
  }

  .xy-search-row {
    grid-template-columns: 1fr auto;
  }

  .xy-search {
    grid-column: 1 / -1;
  }

  .xy-sort-tabs {
    justify-self: start;
  }

  .xy-primary-filters {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .xy-primary-filters > .xy-filter-options {
    order: 3;
    width: 100%;
  }

  .xy-favorite-filter {
    margin-left: auto;
  }

  .xy-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 13px;
  }

  .xy-group-dock {
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
    left: 10px;
    grid-template-columns: 1fr auto;
    gap: 10px;
    border-radius: 19px;
  }

  .xy-group-avatars {
    justify-self: end;
  }

  .xy-group-actions {
    grid-column: 1 / -1;
  }

  .xy-group-actions > button {
    flex: 1;
  }
}

@media (max-width: 540px) {
  .xy-brand-copy small {
    display: none;
  }

  .xy-group-entry {
    min-height: 38px;
    padding: 0 12px;
    font-size: 12px !important;
  }

  .xy-hero {
    gap: 28px;
    padding-top: 44px;
  }

  .xy-hero-stats {
    border-radius: 18px;
  }

  .xy-stat {
    min-height: 84px;
    padding: 14px 6px;
  }

  .xy-stat strong {
    font-size: 19px;
  }

  .xy-controls {
    margin: 0 -3px;
  }

  .xy-search-row {
    gap: 9px;
  }

  .xy-sort-button {
    min-height: 38px;
    padding: 0 11px;
  }

  .xy-filter-trigger {
    min-height: 40px;
    min-width: 78px;
  }

  .xy-advanced-filters {
    grid-template-columns: 1fr;
    max-height: 56vh;
    overflow-y: auto;
  }

  .xy-result-heading {
    align-items: start;
  }

  .xy-result-heading > span {
    max-width: 110px;
    text-align: right;
  }

  .xy-card-grid {
    grid-template-columns: 1fr;
  }

  .xy-card-visual {
    aspect-ratio: 1.55 / 1;
  }

  .xy-pagination {
    flex-wrap: wrap;
  }

  .xy-page-number:nth-of-type(n+5) {
    display: none;
  }

  .xy-group-copy small {
    max-width: 175px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .xy-fast-lobby *,
  .xy-fast-lobby *::before,
  .xy-fast-lobby *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
