:root {
  color-scheme: light dark;
  --ink: #1a181e;
  --ink-soft: #514b54;
  --muted: #756e78;
  --muted-light: #9d949d;
  --canvas: #f7f1e9;
  --paper: #fffaf5;
  --line: rgba(67, 51, 57, .14);
  --line-strong: rgba(67, 51, 57, .23);
  --accent: #d95091;
  --accent-deep: #9d2f63;
  --accent-soft: #f7d6e6;
  --violet: #6659d8;
  --green: #178269;
  --glass-fill: rgba(255, 250, 246, .5);
  --glass-fill-strong: rgba(255, 250, 246, .72);
  --glass-edge: rgba(255, 255, 255, .72);
  --glass-shadow: 0 16px 45px rgba(55, 39, 43, .11), 0 2px 9px rgba(55, 39, 43, .05);
  --ambient-background:
    radial-gradient(circle at 7% 12%, rgba(104, 89, 216, .11), transparent 24%),
    radial-gradient(circle at 85% 1%, rgba(232, 121, 180, .16), transparent 27%),
    radial-gradient(circle at 52% 100%, rgba(241, 212, 82, .1), transparent 29%);
  --radius-small: 11px;
  --radius-medium: 20px;
  --radius-large: 30px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  min-height: 100dvh;
  margin: 0;
  color: var(--ink);
  background-color: var(--canvas);
  background-image: var(--ambient-background);
  background-attachment: fixed;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(112deg, rgba(255, 255, 255, .2), transparent 42%),
    var(--ambient-background);
  background-size: 100vw 100vh;
}
body:has(dialog[open]) { overflow: hidden; }
button, a { color: inherit; font: inherit; -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; }
a { text-decoration: none; }
[hidden] { display: none !important; }
button:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.glass-filter-defs { position: absolute; pointer-events: none; }

/* Web Liquid Glass approximation: cloned ambient scene, SVG displacement,
   real backdrop blur, a restrained chromatic rim and a moving specular highlight. */
.liquid-glass,
.glass-popover {
  --glass-hot-x: 18%;
  --glass-hot-y: 0%;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border: 1px solid var(--glass-edge);
  background: var(--glass-fill);
  -webkit-backdrop-filter: blur(22px) saturate(145%) contrast(1.035);
  backdrop-filter: blur(22px) saturate(145%) contrast(1.035);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, .62),
    inset 0 -1px 0 rgba(104, 76, 89, .09),
    var(--glass-shadow);
}
.liquid-glass::before,
.glass-popover::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  pointer-events: none;
  background:
    radial-gradient(circle at var(--glass-hot-x) var(--glass-hot-y), rgba(255, 255, 255, .78), transparent 28%),
    linear-gradient(118deg, rgba(255, 255, 255, .3), rgba(255, 255, 255, .04) 42%, rgba(225, 120, 168, .06));
  mix-blend-mode: soft-light;
}
.liquid-glass::after,
.glass-popover::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  padding: 1px;
  border-radius: inherit;
  pointer-events: none;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .78), transparent 34% 64%, rgba(255, 255, 255, .24)),
    linear-gradient(90deg, rgba(88, 199, 215, .26), transparent 14% 84%, rgba(232, 91, 151, .28));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: .7;
}
.glass-background-clone {
  position: absolute !important;
  inset: -18px !important;
  z-index: -1 !important;
  pointer-events: none;
  background-color: rgba(247, 241, 233, .28);
  background-image: var(--ambient-background);
  background-attachment: fixed;
  background-position: center;
  background-size: 100vw 100vh;
  filter: url(#collector-glass-displace) saturate(1.08);
  opacity: .58;
  transform: translateZ(0) scale(1.035);
}
.liquid-glass > :not(.glass-background-clone),
.glass-popover > :not(.glass-background-clone) { position: relative; z-index: 2; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  width: 100%;
  height: 66px;
  display: grid;
  grid-template-columns: 280px 1fr 280px;
  align-items: center;
  margin: 0;
  padding: 0 max(28px, calc((100vw - 1240px) / 2));
  border-bottom: 1px solid var(--line);
  background: var(--canvas);
  overflow: visible;
}
.brand {
  width: max-content;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: .12em;
}
.brand strong { font-size: 14px; }
.brand-mark {
  width: 30px;
  height: 30px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 2px;
  padding: 6px;
  border-radius: 9px;
  background: linear-gradient(145deg, #7164e5, #5c4ed1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 7px 16px rgba(93, 77, 205, .23);
}
.brand-mark i { width: 4px; border-radius: 2px; background: #fffdf9; }
.brand-mark i:nth-child(1) { height: 7px; }
.brand-mark i:nth-child(2) { height: 15px; }
.brand-mark i:nth-child(3) { height: 11px; }
.product-nav {
  justify-self: center;
  align-self: stretch;
  display: flex;
  align-items: center;
  gap: 26px;
}
.product-nav a {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  transition: color .2s ease;
}
.product-nav a:hover,
.product-nav a.active { color: var(--ink); }
.product-nav a.active::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: var(--accent);
}
.topbar-status {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 10px;
}
.topbar-status i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #2aaa83;
  box-shadow: 0 0 0 4px rgba(42, 170, 131, .12);
}

main { width: min(1920px, 100%); margin: 0 auto; }
.filter-dock {
  --filter-control-height: 52px;
  --filter-control-width: 210px;
  position: sticky;
  top: 78px;
  z-index: 35;
  width: min(1480px, calc(100% - 48px));
  display: grid;
  grid-template-columns: var(--filter-control-width) minmax(250px, 1fr) var(--filter-control-width);
  align-items: center;
  gap: 14px;
  margin: 22px auto 0;
  padding: 0;
  overflow: visible;
}
.filter-scroll-marker {
  width: 1px;
  height: 1px;
  display: block;
  margin: 0 auto;
  pointer-events: none;
}
.filter-menu { min-width: 0; position: relative; }
.menu-trigger {
  width: 100%;
  min-height: var(--filter-control-height);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 3px 14px;
  padding: 8px 14px 9px;
  text-align: left;
  border: 1px solid rgba(255, 255, 255, .78);
  border-radius: 15px;
  background: rgba(255, 252, 249, .44);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .74), 0 8px 24px rgba(55, 39, 43, .08);
  transition: background .22s ease, border-color .22s ease, box-shadow .22s ease, transform .22s cubic-bezier(.2,.8,.2,1);
}
.menu-trigger:hover,
.menu-trigger.open {
  border-color: rgba(217, 80, 145, .34);
  background: rgba(255, 252, 249, .62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .82), 0 10px 28px rgba(55, 39, 43, .1);
  transform: translateY(-1px);
}
.menu-trigger > span:not(.glass-background-clone) {
  grid-column: 1;
  grid-row: 1;
  overflow: hidden;
  color: var(--muted);
  font-size: 8px;
  font-weight: 550;
  line-height: 1;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.menu-trigger > strong {
  grid-column: 1;
  grid-row: 2;
  overflow: hidden;
  font-size: 11px;
  font-weight: 720;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.menu-trigger > small { color: var(--muted); font-size: 8px; }
.menu-trigger > b {
  grid-column: 2;
  grid-row: 1 / 3;
  color: var(--muted);
  font-size: 16px;
  font-weight: 500;
  line-height: 1;
  transition: transform .24s ease;
}
.menu-trigger.open > b { transform: rotate(180deg); }
.glass-popover {
  position: absolute;
  top: calc(100% + 10px);
  z-index: 20;
  border-radius: 18px;
  background: var(--glass-fill-strong);
  -webkit-backdrop-filter: blur(30px) saturate(155%) contrast(1.04);
  backdrop-filter: blur(30px) saturate(155%) contrast(1.04);
}
.category-switcher {
  left: 0;
  width: 270px;
  padding: 7px;
}
.category-option {
  width: 100%;
  min-height: 50px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  padding: 9px 11px;
  text-align: left;
  border: 0;
  border-radius: 12px;
  background: transparent;
  transition: background .2s ease, transform .2s ease;
}
.category-option:hover { background: rgba(255, 255, 255, .38); transform: translateX(2px); }
.category-option span { font-size: 12px; font-weight: 800; }
.category-option small { color: var(--muted); font-size: 8px; }
.category-option.active { color: var(--accent-deep); background: rgba(248, 217, 232, .56); }
.category-option.active::after { content: "✓"; color: var(--accent); font-size: 12px; }
.featured-tags { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 7px; padding: 0 2px; }
.featured-tag {
  min-height: 32px;
  padding: 6px 11px;
  color: var(--ink-soft);
  white-space: nowrap;
  border: 1px solid rgba(255, 255, 255, .7);
  border-radius: 999px;
  background: rgba(255, 252, 249, .32);
  font-size: 8px;
  font-weight: 720;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .62), 0 5px 16px rgba(55, 39, 43, .055);
  transition: color .2s ease, border-color .2s ease, background .2s ease, box-shadow .2s ease, transform .2s ease;
}
.featured-tag > span:not(.glass-background-clone) { position: relative; z-index: 2; }
.featured-tag:hover { color: var(--accent-deep); border-color: rgba(217, 80, 145, .34); transform: translateY(-1px); }
.featured-tag.active { color: #fffaf6; border-color: var(--ink); background: var(--ink); }
.filter-actions { display: flex; align-items: center; gap: 9px; }
.clear-filter {
  padding: 6px 2px;
  color: var(--accent-deep);
  white-space: nowrap;
  border: 0;
  background: transparent;
  font-size: 9px;
  font-weight: 750;
}
.tag-menu { width: var(--filter-control-width); }
.tag-toggle > strong { grid-row: 2; }
.tag-toggle > small { display: none; }
.tag-panel {
  right: 0;
  width: min(720px, calc(100vw - 48px));
  padding: 18px;
}
.tag-panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 18px; padding: 2px 3px 13px; }
.tag-panel-head strong { font-size: 12px; }
.tag-panel-head span { color: var(--muted); font-size: 8px; }
.tag-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 5px;
  max-height: 380px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: rgba(118, 97, 106, .25) transparent;
}
.tag-item {
  min-width: 0;
  display: block;
  padding: 10px 11px;
  text-align: left;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(255, 255, 255, .18);
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}
.tag-item strong { display: block; overflow: hidden; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.tag-item:hover { border-color: rgba(217, 80, 145, .22); background: rgba(255, 255, 255, .42); transform: translateY(-1px); }
.tag-item.active { color: var(--accent-deep); border-color: rgba(217, 80, 145, .32); background: rgba(248, 217, 232, .5); }

@media (hover: hover) and (pointer: fine) {
  .featured-tags {
    transform-origin: center top;
    transition: opacity .2s ease, transform .28s cubic-bezier(.2, .8, .2, 1);
  }
  .filter-dock.is-collapsed {
    grid-template-columns: repeat(2, 180px);
    justify-content: center;
    gap: 8px;
  }
  .filter-dock.is-collapsed .featured-tags {
    position: absolute;
    opacity: 0;
    transform: translateY(-8px) scale(.94);
    pointer-events: none;
  }
  .filter-dock.is-collapsed .category-menu { grid-column: 1; }
  .filter-dock.is-collapsed .filter-actions {
    grid-column: 2;
    width: 100%;
  }
  .filter-dock.is-collapsed .clear-filter {
    position: absolute;
    opacity: 0;
    pointer-events: none;
  }
  .filter-dock.is-collapsed .tag-menu { width: 100%; }
  .filter-dock.is-collapsed .menu-trigger {
    min-height: 42px;
    grid-template-rows: 1fr;
    padding: 7px 11px;
    border-radius: 12px;
  }
  .filter-dock.is-collapsed .menu-trigger > span:not(.glass-background-clone),
  .filter-dock.is-collapsed .menu-trigger > small {
    position: absolute;
    opacity: 0;
    pointer-events: none;
  }
  .filter-dock.is-collapsed .menu-trigger > strong {
    grid-column: 1;
    grid-row: 1;
    font-size: 10px;
  }
  .filter-dock.is-collapsed .menu-trigger > b {
    grid-column: 2;
    grid-row: 1;
  }
}

.gallery-region { min-height: 68vh; padding: 18px 24px 80px; }
.masonry { columns: 6 230px; column-gap: 14px; }
.pin {
  margin: 0 0 21px;
  break-inside: avoid;
  perspective: 900px;
  animation: reveal .42s cubic-bezier(.2,.8,.2,1) both;
}
.pin > button {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  width: 100%;
  position: relative;
  display: block;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius-small);
  background: #e8dfd7;
  transform: rotateX(var(--tilt-x)) rotateY(var(--tilt-y)) translateZ(0);
  transform-origin: center;
  transform-style: preserve-3d;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .54);
  transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease;
}
.pin > button.tilting {
  z-index: 1;
  will-change: transform;
  box-shadow: 0 13px 30px rgba(48, 36, 40, .14);
  transition-duration: .09s, .2s;
  transition-timing-function: linear, ease;
}
.pin img {
  width: 100%;
  height: auto;
  display: block;
  background: #e8dfd7;
  transition: transform .42s cubic-bezier(.2,.8,.2,1), filter .25s ease;
}
.pin:hover img { transform: scale(1.015); filter: saturate(1.025); }
.pin figcaption {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  align-items: center;
  padding: 8px 2px 0;
}
.pin figcaption strong { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.pin figcaption small { max-width: 110px; overflow: hidden; color: var(--muted-light); font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
@keyframes reveal { from { opacity: 0; transform: translateY(8px) scale(.992); } }

.empty-state {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, .65fr);
  border-radius: var(--radius-large);
}
.empty-visual { min-height: 520px; overflow: hidden; border-radius: 24px; background: var(--accent-soft); }
.empty-visual img { width: 100%; height: 100%; display: block; object-fit: cover; filter: saturate(.92); }
.empty-copy { display: flex; flex-direction: column; justify-content: flex-end; padding: 48px; }
.empty-copy > span { color: var(--accent-deep); font-size: 9px; font-weight: 800; }
.empty-copy h2 { max-width: 380px; margin: 12px 0 0; font-size: clamp(28px, 3vw, 46px); line-height: 1.05; letter-spacing: -.04em; }
.empty-copy p { max-width: 380px; margin: 18px 0 24px; color: var(--muted); font-size: 11px; line-height: 1.7; }
.empty-copy a { align-self: flex-start; color: var(--accent-deep); font-size: 10px; font-weight: 800; }
.load-sentinel { min-height: 88px; padding-top: 12px; }
.load-state { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; opacity: .7; }
.load-state i { height: 52px; overflow: hidden; position: relative; border-radius: var(--radius-small); background: rgba(235, 225, 218, .68); }
.load-state i::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .66), transparent);
  animation: shimmer 1.4s ease-in-out infinite;
}
.load-state i:nth-child(2)::after { animation-delay: .12s; }
.load-state i:nth-child(3)::after { animation-delay: .24s; }
.load-state i:nth-child(4)::after { animation-delay: .36s; }
@keyframes shimmer { to { transform: translateX(100%); } }

.lightbox {
  width: min(1280px, calc(100vw - 48px));
  height: min(820px, calc(100dvh - 48px));
  max-height: calc(100dvh - 48px);
  padding: 0;
  overflow: visible;
  color: var(--ink);
  border: 0;
  background: transparent;
}
.lightbox[open] { display: grid; grid-template-columns: minmax(0, 1fr) 370px; gap: 14px; }
.lightbox::backdrop {
  background:
    radial-gradient(circle at 14% 16%, rgba(102, 89, 216, .12), transparent 30%),
    radial-gradient(circle at 86% 74%, rgba(232, 121, 180, .14), transparent 28%),
    rgba(246, 240, 233, .76);
  -webkit-backdrop-filter: blur(24px) saturate(.88);
  backdrop-filter: blur(24px) saturate(.88);
}
.lightbox-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 8;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  overflow: hidden;
  color: var(--ink);
  border-radius: 50%;
  font-size: 24px;
  line-height: 1;
}
.lightbox-media {
  min-width: 0;
  min-height: 0;
  position: relative;
  display: grid;
  place-items: center;
  padding: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .66);
  border-radius: var(--radius-large);
  background: rgba(228, 218, 210, .58);
  box-shadow: 0 28px 80px rgba(39, 29, 33, .16), inset 0 1px 0 rgba(255, 255, 255, .6);
}
.lightbox-media img { max-width: 100%; max-height: 100%; display: block; object-fit: contain; border-radius: 16px; }
.lightbox aside {
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: 68px 25px 24px;
  overflow-y: auto;
  border-radius: var(--radius-large);
}
.lightbox-head { padding: 0 2px 22px; }
.lightbox-category { color: var(--accent-deep); font-size: 9px; font-weight: 800; }
.lightbox h2 { margin: 10px 0 0; font-size: 25px; line-height: 1.2; letter-spacing: -.03em; }
.lightbox-meta { display: flex; flex-wrap: wrap; gap: 7px 12px; margin-top: 12px; color: var(--muted); font-size: 8px; }
.lightbox-caption,
.lightbox-tag-section {
  border-top: 1px solid var(--line);
}
.lightbox summary {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  list-style: none;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
}
.lightbox summary::-webkit-details-marker { display: none; }
.lightbox summary::after { content: "+"; color: var(--muted); font-size: 17px; font-weight: 400; }
.lightbox details[open] summary::after { content: "−"; }
.lightbox-caption p {
  max-height: 220px;
  margin: 0 0 20px;
  overflow-y: auto;
  overflow-x: hidden;
  color: var(--ink-soft);
  font-size: 10px;
  line-height: 1.72;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  scrollbar-color: var(--line-strong) transparent;
}
.lightbox-tags { display: flex; flex-wrap: wrap; gap: 6px; padding-bottom: 18px; }
.lightbox-tags button {
  padding: 6px 8px;
  color: var(--accent-deep);
  border: 1px solid rgba(217, 80, 145, .22);
  border-radius: 999px;
  background: rgba(248, 217, 232, .44);
  font-size: 8px;
}
.lightbox-actions { display: grid; grid-template-columns: 1fr 1.35fr; gap: 7px; margin-top: auto; padding-top: 22px; }
.lightbox-actions a {
  min-height: 42px;
  display: grid;
  place-items: center;
  padding: 9px 11px;
  white-space: nowrap;
  border: 1px solid var(--ink);
  border-radius: 999px;
  font-size: 9px;
  font-weight: 750;
  transition: transform .2s ease, box-shadow .2s ease;
}
.lightbox-actions a:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(39, 29, 33, .11); }
.creator-link { background: rgba(255, 255, 255, .22); }
.original-link { color: #fffaf6; background: var(--ink); }

@media (max-width: 1100px) {
  .topbar { grid-template-columns: 1fr auto; }
  .product-nav { display: none; }
  .filter-dock {
    --filter-control-width: 188px;
    grid-template-columns: var(--filter-control-width) minmax(0, 1fr) var(--filter-control-width);
  }
  .featured-tag:nth-child(n + 5) { display: none; }
  .tag-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lightbox[open] { grid-template-columns: minmax(0, 1fr) 340px; }
}

@media (max-width: 760px) {
  .topbar { top: 0; width: 100%; height: 58px; gap: 8px; margin: 0; padding: 0 15px; }
  .brand { min-height: 0; padding: 0; border-radius: 0; }
  .brand strong { font-size: 12px; }
  .brand-mark { width: 28px; height: 28px; }
  .topbar-status { min-width: 28px; min-height: 0; justify-content: center; padding: 0; }
  .topbar-status span { display: none; }
  .filter-dock {
    --filter-control-height: 50px;
    top: 68px;
    width: calc(100% - 16px);
    min-height: 0;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 7px;
    margin-top: 16px;
    padding: 0;
  }
  .menu-trigger { min-height: var(--filter-control-height); padding: 8px 11px; border-radius: 14px; }
  .featured-tags { grid-column: 1 / -1; grid-row: 2; flex-wrap: nowrap; overflow: hidden; padding: 2px 1px 0; }
  .featured-tag { min-height: 28px; padding: 5px 9px; font-size: 8px; }
  .featured-tag:nth-child(n + 4) { display: none; }
  .filter-actions { display: contents; }
  .clear-filter { display: none; }
  .tag-menu { width: auto; }
  .category-switcher,
  .tag-panel {
    position: fixed;
    top: 132px;
    right: 8px;
    left: 8px;
    width: auto;
    max-height: calc(100dvh - 148px);
  }
  .category-switcher { padding: 7px; }
  .tag-panel { padding: 13px; }
  .tag-panel-head { padding: 1px 2px 10px; }
  .tag-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: calc(100dvh - 210px); }
  .gallery-region { padding: 20px 8px 56px; }
  .masonry { columns: 2; column-gap: 8px; }
  .pin { margin-bottom: 16px; }
  .pin > button { border-radius: 8px; }
  .pin figcaption { display: block; padding: 7px 2px 0; }
  .pin figcaption strong, .pin figcaption small { display: block; max-width: 100%; }
  .pin figcaption small { margin-top: 3px; }
  .load-state { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .load-state i { height: 42px; }
  .empty-state { min-height: 0; grid-template-columns: 1fr; border-radius: 22px; }
  .empty-visual { min-height: 45dvh; border-radius: 17px; }
  .empty-copy { min-height: 250px; padding: 25px 20px; }
  .empty-copy h2 { font-size: 32px; }
  .lightbox {
    width: 100vw;
    max-width: none;
    height: 100dvh;
    max-height: none;
    margin: 0;
  }
  .lightbox[open] { grid-template-columns: 1fr; grid-template-rows: minmax(0, 58dvh) minmax(0, 42dvh); gap: 0; }
  .lightbox-media { padding: 8px; border: 0; border-radius: 0; background: rgba(225, 215, 208, .7); box-shadow: none; }
  .lightbox-media img { border-radius: 11px; }
  .lightbox aside { padding: 26px 18px calc(16px + env(safe-area-inset-bottom)); border-radius: 24px 24px 0 0; }
  .lightbox-close { position: fixed; top: 12px; right: 12px; }
  .lightbox-head { padding-bottom: 17px; }
  .lightbox h2 { font-size: 21px; }
  .lightbox-caption p { max-height: none; }
  .lightbox-actions { position: sticky; bottom: 0; padding-top: 10px; }
}

@media (hover: none), (pointer: coarse) {
  .pin > button { transform: none; }
  .glass-background-clone { filter: none; opacity: .34; }
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #f2ebed;
    --ink-soft: #d2c8cc;
    --muted: #aba1a6;
    --muted-light: #8d8589;
    --canvas: #1d1a1e;
    --paper: #272328;
    --line: rgba(255, 242, 247, .12);
    --line-strong: rgba(255, 242, 247, .2);
    --accent: #ec80b5;
    --accent-deep: #f09ac2;
    --accent-soft: #512d40;
    --glass-fill: rgba(44, 37, 43, .48);
    --glass-fill-strong: rgba(44, 37, 43, .7);
    --glass-edge: rgba(255, 245, 248, .16);
    --glass-shadow: 0 18px 50px rgba(0, 0, 0, .28), 0 2px 9px rgba(0, 0, 0, .18);
    --ambient-background:
      radial-gradient(circle at 7% 12%, rgba(104, 89, 216, .14), transparent 24%),
      radial-gradient(circle at 85% 1%, rgba(232, 121, 180, .15), transparent 27%),
      radial-gradient(circle at 52% 100%, rgba(241, 212, 82, .05), transparent 29%);
  }
  .glass-background-clone { background-color: rgba(29, 26, 30, .34); }
  .liquid-glass::before, .glass-popover::before { opacity: .55; }
  .menu-trigger {
    border-color: rgba(255, 245, 248, .18);
    background: rgba(44, 37, 43, .54);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16), 0 8px 24px rgba(0, 0, 0, .18);
  }
  .menu-trigger:hover,
  .menu-trigger.open {
    border-color: rgba(236, 128, 181, .38);
    background: rgba(54, 46, 52, .7);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), 0 10px 28px rgba(0, 0, 0, .22);
  }
  .featured-tag {
    border-color: rgba(255, 245, 248, .16);
    background: rgba(44, 37, 43, .46);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 5px 16px rgba(0, 0, 0, .14);
  }
  .brand-mark i { background: #f8f3ec; }
  .featured-tag.active, .original-link { color: #1a181e; background: #f4edf0; }
  .lightbox::backdrop { background: rgba(22, 19, 23, .82); }
}

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .liquid-glass,
  .glass-popover { background: color-mix(in srgb, var(--paper) 94%, transparent); }
  .glass-background-clone { display: none; }
}

@media (prefers-reduced-transparency: reduce) {
  .liquid-glass,
  .glass-popover { background: var(--paper); -webkit-backdrop-filter: none; backdrop-filter: none; }
  .glass-background-clone { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .pin > button { transform: none !important; will-change: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
