/* Pure Native Styles for ElyDev Portfolio */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:ital,wght@0,300..800;1,300..800&family=Syne:wght@600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  --bg-primary: #0b0d11;
  --bg-card: #12151d;
  --bg-secondary: #141822;
  --border-color: #232733;
  --text-primary: #ededef;
  --text-muted: #94a3b8;
  --accent-amber: #facc15;
  --accent-cyan: #22d3ee;
  --accent-emerald: #34d399;
}

html {
  scroll-behavior: smooth;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

.font-display {
  font-family: 'Syne', sans-serif;
}

.font-mono {
  font-family: 'JetBrains Mono', monospace;
}

body {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  margin: 0;
  padding: 0;
}

/* Light Theme Variables */
html.light {
  --bg-primary: #f8fafc;
  --bg-card: #ffffff;
  --bg-secondary: #f1f5f9;
  --border-color: #e2e8f0;
  --text-primary: #0f172a;
  --text-muted: #64748b;
}

html.light body {
  background-color: #f8fafc;
  color: #0f172a;
}

html.light .bg-\[\#0b0d11\] {
  background-color: #f8fafc !important;
}

html.light .bg-\[\#12151d\] {
  background-color: #ffffff !important;
  border-color: #e2e8f0 !important;
}

html.light .bg-\[\#141822\] {
  background-color: #f1f5f9 !important;
  border-color: #e2e8f0 !important;
  color: #1e293b !important;
}

html.light .bg-\[\#10131b\] {
  background-color: #f1f5f9 !important;
}

html.light .text-white {
  color: #0f172a !important;
}

html.light .text-slate-300,
html.light .text-slate-400 {
  color: #475569 !important;
}

html.light .border-\[\#232733\],
html.light .border-\[\#1c212c\],
html.light .border-\[\#1e2330\] {
  border-color: #e2e8f0 !important;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #0b0d11;
}

::-webkit-scrollbar-thumb {
  background: #232733;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #facc15;
}

/* 16:9 Aspect Ratio Helper */
.aspect-16-9 {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 ratio */
  overflow: hidden;
}

.aspect-16-9 > iframe,
.aspect-16-9 > img,
.aspect-16-9 > video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Gallery Thumbnail Active State */
.gallery-thumb.active {
  border-color: #facc15 !important;
  box-shadow: 0 0 0 2px rgba(250, 204, 21, 0.4);
}

/* Star Rating */
.star-rating {
  color: #facc15;
  letter-spacing: 2px;
}

/* Smooth Hardware-Accelerated Hover Animation for Project Cards */
#projects-grid article {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.3s ease;
  will-change: transform, opacity;
  backface-visibility: hidden;
}

/* Card Exit & Collapse Backward (Efecto de colapso hacia atrás como la versión original con Framer Motion) */
.card-collapse-exit {
  transform: scale(0.85) translateY(14px) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  filter: blur(0.5px);
  transition: transform 0.24s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.2s cubic-bezier(0.22, 1, 0.36, 1), filter 0.2s ease !important;
}

/* Card Entrance (initial -> animate con entrada suave) */
@keyframes cardFilterEntrance {
  0% {
    opacity: 0;
    transform: scale(0.92) translateY(20px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.card-fade-in {
  animation: cardFilterEntrance 0.32s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* Stagger entrance for cards */
.card-fade-in:nth-child(1) { animation-delay: 0.02s; }
.card-fade-in:nth-child(2) { animation-delay: 0.05s; }
.card-fade-in:nth-child(3) { animation-delay: 0.08s; }
.card-fade-in:nth-child(4) { animation-delay: 0.11s; }
.card-fade-in:nth-child(5) { animation-delay: 0.14s; }
.card-fade-in:nth-child(6) { animation-delay: 0.17s; }
.card-fade-in:nth-child(7) { animation-delay: 0.20s; }
.card-fade-in:nth-child(8) { animation-delay: 0.23s; }
.card-fade-in:nth-child(9) { animation-delay: 0.26s; }
.card-fade-in:nth-child(10) { animation-delay: 0.29s; }
.card-fade-in:nth-child(11) { animation-delay: 0.32s; }
.card-fade-in:nth-child(12) { animation-delay: 0.35s; }

/* Animations */
@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: .5; }
}

.animate-pulse {
  animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Floating Status Notification System */
@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translate3d(115%, 0, 0) scale(0.96);
  }
  65% {
    opacity: 1;
    transform: translate3d(-6px, 0, 0) scale(1.01);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

@keyframes toastSlideOut {
  0% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
    max-height: 140px;
    margin-bottom: 10px;
  }
  100% {
    opacity: 0;
    transform: translate3d(120%, 0, 0) scale(0.92);
    max-height: 0;
    margin-bottom: 0;
    padding-top: 0;
    padding-bottom: 0;
    border-width: 0;
  }
}

@keyframes toastProgress {
  0% {
    width: 100%;
  }
  100% {
    width: 0%;
  }
}

.status-toast-enter {
  animation: toastSlideIn 0.38s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  will-change: transform, opacity;
}

.status-toast-exit {
  animation: toastSlideOut 0.32s cubic-bezier(0.4, 0, 1, 1) forwards !important;
  pointer-events: none !important;
}

.status-toast-progress {
  animation: toastProgress 3s linear forwards;
}

.status-toast-progress.paused {
  animation-play-state: paused;
}

/* Drag & Drop Reordering Styles */
.card-dragging {
  opacity: 0.45 !important;
  transform: scale(0.97) !important;
  border-color: #facc15 !important;
  box-shadow: 0 0 20px rgba(250, 204, 21, 0.35) !important;
  cursor: grabbing !important;
}

.card-drag-over {
  border-color: #facc15 !important;
  border-style: dashed !important;
  background-color: rgba(250, 204, 21, 0.06) !important;
  outline: 2px dashed #facc15 !important;
  outline-offset: -2px;
}

.drag-handle {
  cursor: grab;
  user-select: none;
}

.drag-handle:active {
  cursor: grabbing;
}

/* Image Dropzone Components */
.image-dropzone {
  border: 2px dashed #262c3b;
  border-radius: 0.875rem;
  background-color: #0b0d11;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-dropzone:hover {
  border-color: #facc15;
  background-color: rgba(250, 204, 21, 0.03);
}

.image-dropzone.drop-active {
  border-color: #facc15 !important;
  background-color: rgba(250, 204, 21, 0.08) !important;
  transform: scale(1.01);
}

/* Light Theme support for Toast */
html.light .status-notification-toast {
  background-color: rgba(255, 255, 255, 0.96) !important;
  border-color: #cbd5e1 !important;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1) !important;
  color: #0f172a !important;
}

html.light .status-notification-toast .toast-title {
  color: #0f172a !important;
}

html.light .status-notification-toast .toast-desc {
  color: #475569 !important;
}

@media print {
  .no-print,
  #status-notification-container {
    display: none !important;
  }
}


/* Asset action button effects */
#asset-modal-like-btn {
  isolation: isolate;
  transform-origin: center;
}

#asset-modal-like-btn.ely-heart-pop {
  animation: elyLikeButtonPop 0.48s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes elyLikeButtonPop {
  0% { transform: scale(1); }
  35% { transform: scale(1.08); }
  65% { transform: scale(0.96); }
  100% { transform: scale(1); }
}

.ely-like-heart {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 20;
  pointer-events: none;
  color: #fb7185;
  font-size: 14px;
  line-height: 1;
  text-shadow: 0 0 10px rgba(251, 113, 133, 0.85);
  transform: translate(-50%, -50%) scale(0.35);
  animation: elyHeartFloat 0.82s cubic-bezier(0.16, 1, 0.3, 1) var(--heart-delay) forwards;
}

@keyframes elyHeartFloat {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.35) rotate(-8deg);
  }
  20% { opacity: 1; }
  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--heart-x)), calc(-50% + var(--heart-y))) scale(1.05) rotate(8deg);
  }
}

.btn-101 {
  --thickness: 0.11rem;
  --roundness: 0.75rem;
  --color: #eff6ff;
  --opacity: 0.85;
  -webkit-tap-highlight-color: transparent;
  -webkit-mask-image: -webkit-radial-gradient(#000, #fff);
  backdrop-filter: blur(100px);
  background: hsla(0, 0%, 100%, 0.2) !important;
  border: none;
  border-radius: var(--roundness);
  color: var(--color);
  cursor: pointer;
  font-family: Poppins, sans-serif;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.5;
  position: relative;
  overflow: hidden;
}

.btn-101:hover {
  background: hsla(0, 0%, 100%, 0.3) !important;
  filter: brightness(1.2);
}

.btn-101:active {
  --opacity: 0;
  background: hsla(0, 0%, 100%, 0.1) !important;
}

.btn-101 svg {
  border-radius: var(--roundness);
  display: block;
  filter: url(#glow);
  height: 100%;
  left: 0;
  position: absolute;
  top: 0;
  width: 100%;
  pointer-events: none;
  overflow: visible;
}

.btn-101 rect {
  fill: none;
  stroke: var(--color);
  stroke-width: var(--thickness);
  stroke-linejoin: round;
  stroke-dasharray: 18 82;
  stroke-dashoffset: 0;
  vector-effect: non-scaling-stroke;
  animation: snake 1.7s linear infinite;
  animation-play-state: paused;
  opacity: 0;
  transition: opacity 0.2s, stroke 0.2s;
}

.btn-101:hover rect,
.btn-101.btn-101-active rect {
  animation-play-state: running;
  opacity: var(--opacity);
}

.btn-101.btn-101-active {
  animation: elyDownloadButtonPop 0.42s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes snake {
  to { stroke-dashoffset: -100; }
}

@keyframes elyDownloadButtonPop {
  0% { transform: scale(1); }
  35% { transform: scale(1.035); }
  100% { transform: scale(1); }
}

.toast-download-name {
  color: #34d399 !important;
  font-weight: 700 !important;
}

/* Asset counter update feedback */
.ely-counter-update {
  display: inline-block;
  transform-origin: center;
  animation: elyCounterZoomGlow 0.62s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform, filter, text-shadow;
}
.ely-counter-like {
  --counter-glow: rgba(251, 113, 133, 0.9);
}
.ely-counter-download {
  --counter-glow: rgba(52, 211, 153, 0.9);
}
@keyframes elyCounterZoomGlow {
  0% {
    transform: scale(1);
    filter: brightness(1);
    text-shadow: 0 0 0 transparent;
  }
  28% {
    transform: scale(1.38);
    filter: brightness(1.8);
    text-shadow: 0 0 5px var(--counter-glow), 0 0 14px var(--counter-glow);
  }
  55% {
    transform: scale(0.92);
    filter: brightness(1.35);
    text-shadow: 0 0 4px var(--counter-glow), 0 0 10px var(--counter-glow);
  }
  78% {
    transform: scale(1.12);
    filter: brightness(1.2);
    text-shadow: 0 0 3px var(--counter-glow);
  }
  100% {
    transform: scale(1);
    filter: brightness(1);
    text-shadow: 0 0 0 transparent;
  }
}

/* Restore asset action feedback even when the motion enhancement is reinitialized */
#asset-modal-like-btn,
[data-asset-like-btn],
[data-asset-download-btn] {
  transform-origin: center;
  will-change: transform, filter;
}
[data-asset-like-btn].ely-pop-like,
#asset-modal-like-btn.ely-pop-like {
  animation: elyLikeButtonPop 0.48s cubic-bezier(0.16, 1, 0.3, 1);
  filter: drop-shadow(0 0 8px rgba(251, 113, 133, 0.55));
}
[data-asset-download-btn].ely-pop-download,
.btn-101.btn-101-active {
  filter: drop-shadow(0 0 8px rgba(52, 211, 153, 0.45));
}

/* ElyDev discovery, quick preview, particles and responsive polish */
html { scroll-behavior: smooth; }
main > section { scroll-margin-top: 88px; }
.ely-section-transition { transition: opacity .45s ease, transform .55s cubic-bezier(.2,.8,.2,1); }
.asset-discovery-tabs { overflow-x: auto; scrollbar-width: none; flex-wrap: nowrap !important; padding-bottom: 2px; }
.asset-discovery-tabs::-webkit-scrollbar { display: none; }
.asset-discovery-btn { flex: 0 0 auto; padding: .48rem .72rem; border-radius: 999px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); color: #94a3b8; font-size: 10px; font-weight: 700; white-space: nowrap; transition: transform .2s ease, background .2s ease, color .2s ease, border-color .2s ease; }
.asset-discovery-btn:hover { color: #fff; border-color: rgba(251,191,36,.45); transform: translateY(-1px); }
.asset-discovery-btn.asset-discovery-active { background: rgba(251,191,36,.16); color: #fbbf24; border-color: rgba(251,191,36,.55); }
.asset-card-media { isolation: isolate; }
.asset-quick-preview { position: absolute; inset: auto 10px 10px 10px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 10px; border: 1px solid rgba(255,255,255,.16); border-radius: 10px; background: rgba(8,10,15,.72); backdrop-filter: blur(8px); color: #f8fafc; font-size: 10px; font-weight: 800; opacity: 0; transform: translateY(7px); transition: opacity .22s ease, transform .22s ease; pointer-events: none; }
.asset-quick-preview-icon { color: #fbbf24; }
#projects-grid > article:hover .asset-quick-preview { opacity: 1; transform: translateY(0); }
.ely-hero { position: relative; overflow: hidden; }
.ely-hero > *:not(#ely-hero-particles) { position: relative; z-index: 1; }
#ely-hero-particles { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.ely-hero-particle { position: absolute; left: var(--particle-x); top: var(--particle-y); width: 3px; height: 3px; border-radius: 999px; background: rgba(251,191,36,.5); box-shadow: 0 0 12px rgba(251,191,36,.35); opacity: 0; animation: elyHeroParticle var(--particle-duration) ease-in-out var(--particle-delay) infinite; }
@keyframes elyHeroParticle { 0%,100% { opacity: 0; transform: translate3d(0,12px,0) scale(.7); } 25%,70% { opacity: .65; } 50% { opacity: .9; transform: translate3d(12px,-18px,0) scale(1); } }
@media (max-width: 767px) {
  body { overflow-x: hidden; }
  main { width: 100%; }
  main > section { scroll-margin-top: 70px; }
  .ely-magnetic { transform: none !important; }
  #projects-grid { grid-template-columns: 1fr !important; gap: 1rem !important; }
  #projects-grid > article { transform: none !important; }
  .asset-discovery-tabs { margin-inline: -4px; padding-inline: 4px 8px; }
  .asset-discovery-btn { min-height: 38px; padding: .55rem .72rem; }
  .asset-card-media { aspect-ratio: 16 / 10; }
  .asset-quick-preview { opacity: .92; transform: none; inset: auto 8px 8px 8px; }
  #asset-tools { width: 100%; }
  #asset-tools > * { flex: 1 1 0; min-width: 0; }
  #projects-search-input { min-height: 42px; font-size: 12px; }
  #projects-search-clear { top: 13px; }
  .ely-hero-particle { width: 2px; height: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .ely-hero-particle { animation: none; display: none; }
  .ely-section-transition { transition: none; }
}


/* More noticeable asset counters */
[data-global-likes-id],
[data-global-downloads-id] {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  min-height: 26px;
  padding: 3px 9px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px !important;
  font-weight: 800 !important;
  line-height: 1;
  letter-spacing: -0.02em;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform .2s ease, background .2s ease, border-color .2s ease, box-shadow .2s ease;
}

[data-global-likes-id] {
  color: #fb7185 !important;
  background: rgba(251, 113, 133, 0.10);
  border-color: rgba(251, 113, 133, 0.28);
  box-shadow: 0 3px 14px rgba(251, 113, 133, 0.10), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

[data-global-downloads-id] {
  color: #34d399 !important;
  background: rgba(52, 211, 153, 0.10);
  border-color: rgba(52, 211, 153, 0.28);
  box-shadow: 0 3px 14px rgba(52, 211, 153, 0.10), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

[data-global-likes-id]:hover,
[data-global-downloads-id]:hover {
  transform: translateY(-1px) scale(1.04);
}

[data-global-likes-id].ely-counter-update,
[data-global-downloads-id].ely-counter-update {
  position: relative;
  z-index: 2;
}

@media (max-width: 767px) {
  [data-global-likes-id],
  [data-global-downloads-id] {
    min-width: 32px;
    min-height: 25px;
    padding: 3px 8px;
    font-size: 11px !important;
  }
}



/* Asset card metrics */
#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 {
  position: relative;
  min-height: 58px;
  padding: 10px 0 6px;
  gap: 8px;
  justify-content: flex-start;
}

#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-downloads-id],
#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-likes-id],
#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > .asset-view-resource-btn {
  width: 48px;
  min-width: 48px;
  height: 32px;
  min-height: 32px;
  padding: 0;
  border-radius: 9px;
  font-size: 11px !important;
  font-weight: 800 !important;
  line-height: 1;
  flex: 0 0 48px;
  box-sizing: border-box;
}

#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-downloads-id] {
  color: #34d399 !important;
  background: rgba(52,211,153,.10);
  border: 1px solid rgba(52,211,153,.30);
  box-shadow: 0 0 12px rgba(52,211,153,.08), inset 0 1px 0 rgba(255,255,255,.08);
}

#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-likes-id] {
  color: #fb7185 !important;
  background: rgba(251,113,133,.10);
  border: 1px solid rgba(251,113,133,.30);
  box-shadow: 0 0 12px rgba(251,113,133,.08), inset 0 1px 0 rgba(255,255,255,.08);
}

#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > .asset-view-resource-btn {
  position: absolute;
  right: 0;
  bottom: 0;
  margin: 0;
  border: 1px solid rgba(34,211,238,.38);
  background: rgba(34,211,238,.12);
  color: #67e8f9;
  font-size: 14px !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  box-shadow: 0 0 12px rgba(34,211,238,.08);
  transition: transform .2s ease, background .2s ease, border-color .2s ease;
}
#projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > .asset-view-resource-btn:hover {
  transform: translateY(-1px);
  background: rgba(34,211,238,.2);
  border-color: rgba(34,211,238,.55);
}

@media (max-width: 767px) {
  #projects-grid > article > .p-4 > .flex.items-center.justify-center.gap-3 {
    min-height: 54px;
    gap: 7px;
  }
  #projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-downloads-id],
  #projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > [data-global-likes-id],
  #projects-grid > article > .p-4 > .flex.items-center.justify-start.gap-3 > .asset-view-resource-btn {
    width: 46px;
    min-width: 46px;
    height: 30px;
    min-height: 30px;
    flex-basis: 46px;
    font-size: 10px !important;
    padding: 0;
  }
}

/* Colored particle burst for the asset Like button */
#asset-modal-like-btn {
  position: relative;
  overflow: visible;
}
.ely-like-particle {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 25;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--particle-color, #fb7185);
  box-shadow: 0 0 8px color-mix(in srgb, var(--particle-color, #fb7185) 55%, transparent);
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.25) rotate(0deg);
  animation: elyLikeParticleBurst .72s cubic-bezier(.2,.75,.25,1) var(--particle-delay, 0ms) forwards;
}
@keyframes elyLikeParticleBurst {
  20% { opacity: 1; }
  100% { opacity: 0; transform: translate(calc(-50% + var(--particle-x, 0px)), calc(-50% + var(--particle-y, -24px))) scale(1) rotate(135deg); }
}
@media (prefers-reduced-motion: reduce) {
  .ely-like-particle { display: none; animation: none; }
}

/* Clipboard animation for buttons that copy or share a link */
.ely-clipboard-button {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: .4rem;
}
.ely-clipboard-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 20px;
  flex: 0 0 16px;
  overflow: hidden;
  pointer-events: none;
}
.ely-clipboard-icon svg {
  display: block;
  width: 16px;
  height: 32px;
  overflow: visible;
  opacity: .92;
  flex: 0 0 32px;
}
.ely-clipboard-icon path {
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: transparent;
}
.ely-clipboard-icon .clip-back,
.ely-clipboard-icon .clip-top {
  fill: currentColor;
  stroke: currentColor;
}
.ely-clipboard-icon .page {
  transform-box: fill-box;
  transform-origin: center;
}
.ely-clipboard-icon .check {
  stroke: #83f5ad;
  stroke-dasharray: 8;
  stroke-dashoffset: 8;
  transform-box: fill-box;
  transform-origin: center;
}
.ely-clipboard-button:hover .ely-clipboard-icon svg { opacity: 1; }
.ely-clipboard-button.ely-clipboard-copied .ely-clipboard-icon .page {
  animation: elyClipboardPage 2s ease forwards;
}
.ely-clipboard-button.ely-clipboard-copied .ely-clipboard-icon .check {
  stroke-dasharray: 16;
  animation: elyClipboardCheck 2s ease forwards;
}
@keyframes elyClipboardPage {
  0%, 50% { transform: rotate(0) translateY(0); opacity: 1; }
  100% { transform: rotate(10deg) translateY(16px); opacity: 0; }
}
@keyframes elyClipboardCheck {
  0% { transform: rotate(0) translateY(0); opacity: 1; stroke-dashoffset: 8; }
  50% { transform: rotate(0) translateY(0); opacity: 1; stroke-dashoffset: 0; }
  100% { transform: rotate(10deg) translateY(16px); opacity: 0; stroke-dashoffset: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .ely-clipboard-button.ely-clipboard-copied .ely-clipboard-icon .page,
  .ely-clipboard-button.ely-clipboard-copied .ely-clipboard-icon .check {
    animation: none;
  }
}

/* Animated five-star rating controls */
.rating-panel {
  width: 100%;
  margin: 1rem 0 0;
  padding: 1rem 1.1rem 1.25rem;
  border: 1px solid rgba(250, 204, 21, .28);
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(250, 204, 21, .055), rgba(15, 23, 42, .25));
  text-align: center;
}
.rating-title {
  display: block;
  margin-bottom: .6rem;
  color: #f8fafc;
  font-size: .95rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.rating__source-select {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}
.rating[data-rating-widget] {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: clamp(.15rem, 1.4vw, .65rem);
  position: relative;
  width: 100%;
  padding: .1rem 0 1.5rem;
}
.rating[data-rating-widget] .rating__input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  -webkit-appearance: none;
  appearance: none;
}
.rating[data-rating-widget] .rating__input:focus-visible + .rating__label {
  outline: 2px solid #facc15;
  outline-offset: 3px;
  border-radius: .4rem;
}
.rating[data-rating-widget] .rating__label {
  cursor: pointer;
  padding: .125em;
}
.rating[data-rating-widget] .rating__star {
  display: block;
  overflow: visible;
  pointer-events: none;
  width: clamp(2.35rem, 8vw, 4.25rem);
  height: clamp(2.35rem, 8vw, 4.25rem);
}
.rating[data-rating-widget] .rating__star-ring,
.rating[data-rating-widget] .rating__star-fill,
.rating[data-rating-widget] .rating__star-line,
.rating[data-rating-widget] .rating__star-stroke {
  animation-duration: 1s;
  animation-timing-function: ease-in-out;
  animation-fill-mode: forwards;
}
.rating[data-rating-widget] .rating__star-ring,
.rating[data-rating-widget] .rating__star-fill,
.rating[data-rating-widget] .rating__star-line {
  stroke: var(--yellow, hsl(38,90%,55%));
}
.rating[data-rating-widget] .rating__star-fill {
  fill: var(--yellow, hsl(38,90%,55%));
  transform: scale(0);
  transform-box: fill-box;
  transform-origin: center;
  transition: fill .3s cubic-bezier(.42,0,.58,1), transform .3s cubic-bezier(.42,0,.58,1);
}
.rating[data-rating-widget] .rating__star-line {
  stroke-dasharray: 12 13;
  stroke-dashoffset: -13;
}
.rating[data-rating-widget] .rating__star-stroke {
  stroke: #c3ccd9;
  transform-box: fill-box;
  transform-origin: center;
  transition: stroke .3s;
}
.rating[data-rating-widget] .rating__label--delay1 .rating__star-ring,
.rating[data-rating-widget] .rating__label--delay1 .rating__star-fill,
.rating[data-rating-widget] .rating__label--delay1 .rating__star-line,
.rating[data-rating-widget] .rating__label--delay1 .rating__star-stroke { animation-delay: .05s; }
.rating[data-rating-widget] .rating__label--delay2 .rating__star-ring,
.rating[data-rating-widget] .rating__label--delay2 .rating__star-fill,
.rating[data-rating-widget] .rating__label--delay2 .rating__star-line,
.rating[data-rating-widget] .rating__label--delay2 .rating__star-stroke { animation-delay: .1s; }
.rating[data-rating-widget] .rating__label--delay3 .rating__star-ring,
.rating[data-rating-widget] .rating__label--delay3 .rating__star-fill,
.rating[data-rating-widget] .rating__label--delay3 .rating__star-line,
.rating[data-rating-widget] .rating__label--delay3 .rating__star-stroke { animation-delay: .15s; }
.rating[data-rating-widget] .rating__label--delay4 .rating__star-ring,
.rating[data-rating-widget] .rating__label--delay4 .rating__star-fill,
.rating[data-rating-widget] .rating__label--delay4 .rating__star-line,
.rating[data-rating-widget] .rating__label--delay4 .rating__star-stroke { animation-delay: .2s; }

/* Original StarRating checked-state animation selectors */
.rating[data-rating-widget] .rating__input-1:checked ~ .rating__label:first-of-type .rating__star-ring,
.rating[data-rating-widget] .rating__input-2:checked ~ .rating__label:nth-of-type(-n+2) .rating__star-ring,
.rating[data-rating-widget] .rating__input-3:checked ~ .rating__label:nth-of-type(-n+3) .rating__star-ring,
.rating[data-rating-widget] .rating__input-4:checked ~ .rating__label:nth-of-type(-n+4) .rating__star-ring,
.rating[data-rating-widget] .rating__input-5:checked ~ .rating__label:nth-of-type(-n+5) .rating__star-ring { animation-name: starRing; }

.rating[data-rating-widget] .rating__input-1:checked ~ .rating__label:first-of-type .rating__star-stroke,
.rating[data-rating-widget] .rating__input-2:checked ~ .rating__label:nth-of-type(-n+2) .rating__star-stroke,
.rating[data-rating-widget] .rating__input-3:checked ~ .rating__label:nth-of-type(-n+3) .rating__star-stroke,
.rating[data-rating-widget] .rating__input-4:checked ~ .rating__label:nth-of-type(-n+4) .rating__star-stroke,
.rating[data-rating-widget] .rating__input-5:checked ~ .rating__label:nth-of-type(-n+5) .rating__star-stroke { animation-name: starStroke; }

.rating[data-rating-widget] .rating__input-1:checked ~ .rating__label:first-of-type .rating__star-line,
.rating[data-rating-widget] .rating__input-2:checked ~ .rating__label:nth-of-type(-n+2) .rating__star-line,
.rating[data-rating-widget] .rating__input-3:checked ~ .rating__label:nth-of-type(-n+3) .rating__star-line,
.rating[data-rating-widget] .rating__input-4:checked ~ .rating__label:nth-of-type(-n+4) .rating__star-line,
.rating[data-rating-widget] .rating__input-5:checked ~ .rating__label:nth-of-type(-n+5) .rating__star-line { animation-name: starLine; }

.rating[data-rating-widget] .rating__input-1:checked ~ .rating__label:first-of-type .rating__star-fill,
.rating[data-rating-widget] .rating__input-2:checked ~ .rating__label:nth-of-type(-n+2) .rating__star-fill,
.rating[data-rating-widget] .rating__input-3:checked ~ .rating__label:nth-of-type(-n+3) .rating__star-fill,
.rating[data-rating-widget] .rating__input-4:checked ~ .rating__label:nth-of-type(-n+4) .rating__star-fill,
.rating[data-rating-widget] .rating__input-5:checked ~ .rating__label:nth-of-type(-n+5) .rating__star-fill { animation-name: starFill; }

/* Hover preview */
.rating[data-rating-widget][data-hover-value="1"] .rating__label:nth-of-type(-n+1) .rating__star-stroke,
.rating[data-rating-widget][data-hover-value="2"] .rating__label:nth-of-type(-n+2) .rating__star-stroke,
.rating[data-rating-widget][data-hover-value="3"] .rating__label:nth-of-type(-n+3) .rating__star-stroke,
.rating[data-rating-widget][data-hover-value="4"] .rating__label:nth-of-type(-n+4) .rating__star-stroke,
.rating[data-rating-widget][data-hover-value="5"] .rating__label:nth-of-type(-n+5) .rating__star-stroke {
  stroke: var(--yellow, hsl(38,90%,55%));
  transform: scale(1);
}
.rating[data-rating-widget] .rating__input:checked ~ .rating__label .rating__star-fill {
  fill: var(--yellow, hsl(38,90%,55%));
}
.rating[data-rating-widget] .rating__display {
  font-size: .8rem;
  font-weight: 700;
  min-height: 1.25em;
  position: absolute;
  top: calc(100% - 1.45rem);
  left: 0;
  width: 100%;
  color: #facc15;
  text-align: center;
}
.rating[data-rating-widget] .rating__display[hidden] { display: none; }
.rating[data-rating-widget] .rating__sr {
  clip: rect(1px,1px,1px,1px);
  overflow: hidden;
  position: absolute;
  width: 1px;
  height: 1px;
}

@keyframes starRing {
  from, 20% { animation-timing-function: ease-in; opacity: 1; r: 8px; stroke-width: 16px; transform: scale(0); }
  35% { animation-timing-function: ease-out; opacity: .5; r: 8px; stroke-width: 16px; transform: scale(1); }
  50%, to { opacity: 0; r: 16px; stroke-width: 0; transform: scale(1); }
}
@keyframes starFill {
  from, 40% { animation-timing-function: ease-out; transform: scale(0); }
  60% { animation-timing-function: ease-in-out; transform: scale(1.2); }
  80% { transform: scale(.9); }
  to { transform: scale(1); }
}
@keyframes starStroke {
  from { transform: scale(1); }
  20%, to { transform: scale(0); }
}
@keyframes starLine {
  from, 40% { animation-timing-function: ease-out; stroke-dasharray: 1 23; stroke-dashoffset: 1; }
  60%, to { stroke-dasharray: 12 13; stroke-dashoffset: -13; }
}
@media (max-width: 420px) {
  .rating-panel { padding: .85rem .35rem 1.15rem; }
  .rating[data-rating-widget] { gap: .05rem; }
  .rating[data-rating-widget] .rating__label { padding: .02rem; }
}
@media (prefers-reduced-motion: reduce) {
  .rating[data-rating-widget] *, .rating[data-rating-widget] *::before, .rating[data-rating-widget] *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}


/* Responsive moderator analytics dashboard: keep the panel inside the viewport */
#moderator-dashboard-modal {
  box-sizing: border-box;
  align-items: flex-start;
  justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) 12px max(12px, env(safe-area-inset-bottom));
  overflow-x: hidden;
  overflow-y: auto;
}
#moderator-dashboard-modal > div {
  box-sizing: border-box;
  width: 100%;
  max-width: min(48rem, calc(100vw - 24px));
  min-width: 0;
  max-height: calc(100vh - 24px);
  max-height: calc(100dvh - 24px);
  margin: auto 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
}
#moderator-dashboard-modal > div > *,
#moderator-dashboard-modal .grid,
#moderator-dashboard-modal .grid > *,
#moderator-dashboard-modal [id^="moderator-dashboard-"] {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
#moderator-dashboard-modal h3,
#moderator-dashboard-modal h4,
#moderator-dashboard-modal p,
#moderator-dashboard-modal a,
#moderator-dashboard-modal span,
#moderator-dashboard-modal button {
  overflow-wrap: anywhere;
}
#moderator-dashboard-modal button {
  flex-shrink: 0;
}
@media (max-width: 640px) {
  #moderator-dashboard-modal > div {
    padding: 14px;
    border-radius: 16px;
    max-width: calc(100vw - 24px);
  }
  #moderator-dashboard-modal > div > .grid.grid-cols-2 {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  #moderator-dashboard-modal .grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  #moderator-dashboard-modal .grid > * {
    grid-column: auto !important;
  }
}

/* Moderator tools and indie discovery controls */
#moderator-dashboard-history, #moderator-dashboard-cache-stats { min-width: 0; overflow-wrap: anywhere; }
#community-games-sort { max-width: 100%; }
@media (max-width: 640px) { #community-games-favorites-toggle, #community-games-sort { min-height: 40px; } }


/* Heart-only like control for the asset detail modal */
.asset-modal-heart-btn{display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;margin:0 auto;border-radius:9999px;border:1px solid rgba(251,113,133,.28);background:rgba(244,63,94,.08);color:#fda4af;font-size:27px;line-height:1;transition:transform .18s ease,background .18s ease,color .18s ease,border-color .18s ease,box-shadow .18s ease;}
.asset-modal-heart-btn:hover{transform:scale(1.08);background:rgba(244,63,94,.16);border-color:rgba(251,113,133,.6);}
.asset-modal-heart-btn.text-rose-300,.asset-modal-heart-btn[aria-pressed="true"]{color:#fb7185;background:rgba(244,63,94,.2);border-color:rgba(251,113,133,.65);box-shadow:0 0 16px rgba(251,113,133,.12);}
.asset-modal-heart-btn:disabled{opacity:.55;cursor:wait;transform:none;}


/* Compact asset detail popup without changing catalog cards */
#asset-detail-modal{padding:12px;}
#asset-detail-modal>div{max-height:calc(100dvh - 24px);display:flex;flex-direction:column;}
#asset-detail-modal>div>div:first-child{flex-shrink:0;}
#asset-detail-modal>div>div:nth-child(2){min-height:0;}
#asset-detail-modal #asset-modal-image-wrap img{display:block;margin-inline:auto;}
#asset-detail-modal .asset-modal-heart-btn{margin:0;width:38px;height:38px;flex:0 0 38px;font-size:24px;}
#asset-detail-modal #asset-modal-download-btn{min-width:0;}
@media(max-width:520px){#asset-detail-modal{padding:8px;}#asset-detail-modal>div>div:first-child{gap:8px;}#asset-detail-modal #asset-modal-title{font-size:1rem;}#asset-detail-modal>div>div:first-child button{font-size:10px;}#asset-detail-modal #asset-modal-image-wrap img{max-height:130px;}}


/* Asset detail: compact stats and clear primary download action */
#asset-detail-modal .asset-modal-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;padding:9px;border:1px solid #252c39;border-radius:12px;background:linear-gradient(145deg,#0c1018,#090b10);}
#asset-detail-modal .asset-modal-stat{display:flex;align-items:center;justify-content:center;gap:8px;min-width:0;padding:7px 5px;border-right:1px solid #252c39;}
#asset-detail-modal .asset-modal-stat:last-child{border-right:0;}
#asset-detail-modal .asset-modal-stat-icon{display:flex;align-items:center;justify-content:center;flex:0 0 28px;width:28px;height:28px;border-radius:9px;background:rgba(103,232,249,.08);border:1px solid rgba(103,232,249,.12);color:#67e8f9;font-size:17px;}
#asset-detail-modal .asset-modal-stat-likes .asset-modal-stat-icon{color:#fb7185;background:rgba(251,113,133,.08);border-color:rgba(251,113,133,.15);}
#asset-detail-modal .asset-modal-stat-views .asset-modal-stat-icon{color:#a5b4fc;background:rgba(165,180,252,.08);border-color:rgba(165,180,252,.15);}
#asset-detail-modal .asset-modal-stat>div{display:flex;flex-direction:column;gap:2px;min-width:0;}
#asset-detail-modal .asset-modal-stat-label{font-size:9px;line-height:1.2;letter-spacing:.07em;text-transform:uppercase;color:#7e899c;white-space:nowrap;}
#asset-detail-modal .asset-modal-stat strong{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:17px;line-height:1.1;font-weight:800;color:#f8fafc;font-variant-numeric:tabular-nums;}
#asset-detail-modal .asset-modal-stat-likes strong{color:#fda4af;}
#asset-detail-modal .asset-modal-stat-views strong{color:#a5b4fc;}
#asset-detail-modal .asset-modal-actions{display:flex;align-items:stretch;gap:10px;}
#asset-detail-modal .asset-modal-download-btn{position:relative;display:flex;align-items:center;justify-content:center;flex:1;min-width:0;min-height:50px;padding:0 18px;border:1px solid rgba(103,232,249,.7);border-radius:12px;background:linear-gradient(105deg,#67e8f9,#22d3ee 55%,#06b6d4);color:#07131b;box-shadow:0 5px 18px rgba(6,182,212,.15);font-size:13px;font-weight:850;letter-spacing:.015em;overflow:hidden;transition:transform .18s ease,filter .18s ease,box-shadow .18s ease;}
#asset-detail-modal .asset-modal-download-btn:hover{transform:translateY(-1px);filter:brightness(1.07);box-shadow:0 8px 24px rgba(6,182,212,.24);}
#asset-detail-modal .asset-modal-download-btn:active{transform:translateY(0) scale(.99);}
#asset-detail-modal .asset-modal-download-btn svg{position:absolute;inset:0;width:100%;height:100%;pointer-events:none;}
#asset-detail-modal .asset-modal-download-content{position:relative;z-index:2;display:flex;align-items:center;justify-content:center;gap:10px;width:100%;}
#asset-detail-modal .asset-modal-download-icon{font-size:21px;line-height:1;font-weight:900;}
#asset-detail-modal .asset-modal-download-arrow{margin-left:auto;font-size:16px;opacity:.7;}
#asset-detail-modal .asset-modal-heart-btn{width:50px;height:auto;min-height:50px;flex:0 0 50px;margin:0;border-radius:12px;font-size:27px;background:rgba(244,63,94,.07);}
#asset-detail-modal .asset-modal-heart-btn[aria-pressed="true"]{background:rgba(244,63,94,.17);box-shadow:0 0 18px rgba(244,63,94,.12);}
@media(max-width:520px){
 #asset-detail-modal .asset-modal-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:0;padding:6px;}
 #asset-detail-modal .asset-modal-stat{justify-content:flex-start;padding:8px;border-right:0;}
 #asset-detail-modal .asset-modal-stat:nth-child(odd){border-right:1px solid #252c39;}
 #asset-detail-modal .asset-modal-stat:nth-child(-n+2){border-bottom:1px solid #252c39;}
 #asset-detail-modal .asset-modal-stat-icon{flex-basis:25px;width:25px;height:25px;font-size:15px;}
 #asset-detail-modal .asset-modal-stat strong{font-size:16px;}
 #asset-detail-modal .asset-modal-download-btn{min-height:46px;padding:0 10px;font-size:12px;}
 #asset-detail-modal .asset-modal-heart-btn{min-height:46px;flex-basis:46px;width:46px;}
}


/* Compact asset modal stats and download action */
#asset-detail-modal .asset-modal-stats{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:6px;
  padding:0;
  border:0;
  background:transparent;
  box-shadow:none;
}
#asset-detail-modal .asset-modal-stat{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  min-width:0;
  padding:7px 5px;
  border:1px solid rgba(148,163,184,.13);
  border-radius:9px;
  background:rgba(255,255,255,.025);
}
#asset-detail-modal .asset-modal-stat-icon{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:0 0 20px;
  width:20px;
  height:20px;
  font-size:13px;
  border:0;
  background:transparent;
}
#asset-detail-modal .asset-modal-stat>div{
  display:flex;
  flex-direction:row;
  align-items:baseline;
  gap:5px;
}
#asset-detail-modal .asset-modal-stat-label{
  font-size:9px;
  letter-spacing:0;
  text-transform:none;
}
#asset-detail-modal .asset-modal-stat strong{font-size:12px;line-height:1;}
#asset-detail-modal .asset-modal-actions{
  justify-content:center;
  align-items:center;
  gap:8px;
}
#asset-detail-modal .asset-modal-download-btn{
  flex:0 1 230px;
  width:230px;
  min-height:38px;
  padding:0 12px;
  border-radius:9px;
  font-size:11px;
  box-shadow:0 3px 10px rgba(6,182,212,.10);
}
#asset-detail-modal .asset-modal-download-content{gap:7px;}
#asset-detail-modal .asset-modal-download-icon{font-size:16px;}
#asset-detail-modal .asset-modal-download-arrow{font-size:13px;}
#asset-detail-modal .asset-modal-heart-btn{
  flex:0 0 38px;
  width:38px;
  min-height:38px;
  height:38px;
  border-radius:9px;
  font-size:21px;
}
@media(max-width:520px){
  #asset-detail-modal .asset-modal-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:5px;padding:0;}
  #asset-detail-modal .asset-modal-stat{justify-content:flex-start;padding:6px 8px;border:1px solid rgba(148,163,184,.13)!important;}
  #asset-detail-modal .asset-modal-stat-icon{flex-basis:20px;width:20px;height:20px;font-size:13px;}
  #asset-detail-modal .asset-modal-stat strong{font-size:12px;}
  #asset-detail-modal .asset-modal-download-btn{flex:0 1 210px;width:210px;min-height:38px;padding:0 10px;font-size:11px;}
  #asset-detail-modal .asset-modal-heart-btn{flex-basis:38px;width:38px;min-height:38px;height:38px;}
}


/* Keep asset actions together at the bottom-right of the detail modal */
#asset-detail-modal .asset-modal-actions{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:7px;
  width:100%;
  margin-top:12px;
  padding-top:10px;
  border-top:1px solid rgba(148,163,184,.12);
}
#asset-detail-modal .asset-modal-download-btn{
  flex:0 0 auto;
  width:auto;
  min-width:150px;
  min-height:35px;
  padding:0 12px;
}
#asset-detail-modal .asset-modal-download-content{justify-content:center;gap:7px;}
#asset-detail-modal .asset-modal-download-arrow{margin-left:2px;}
#asset-detail-modal .asset-modal-heart-btn{
  flex:0 0 35px;
  width:35px;
  height:35px;
  min-height:35px;
}
@media(max-width:520px){
  #asset-detail-modal .asset-modal-actions{justify-content:flex-end;margin-top:9px;padding-top:8px;}
  #asset-detail-modal .asset-modal-download-btn{min-width:135px;min-height:34px;width:auto;flex:0 0 auto;}
  #asset-detail-modal .asset-modal-heart-btn{flex-basis:34px;width:34px;height:34px;min-height:34px;}
}


/* Asset detail modal refinements: green download and centered title */
#asset-detail-modal .asset-modal-download-btn{
  background:linear-gradient(110deg,#4ade80,#22c55e 58%,#16a34a)!important;
  border-color:rgba(74,222,128,.72)!important;
  color:#052e16!important;
  box-shadow:0 4px 14px rgba(34,197,94,.16)!important;
}
#asset-detail-modal .asset-modal-download-btn:hover{box-shadow:0 7px 20px rgba(34,197,94,.25)!important;}
#asset-detail-modal>div>div:first-child{
  position:relative;
  display:block;
  min-height:54px;
  padding-top:2px;
  padding-bottom:10px;
}
#asset-detail-modal>div>div:first-child>div:first-child{
  width:100%;
  display:flex;
  flex-direction:column;
  align-items:center;
}
#asset-detail-modal #asset-modal-title{width:100%;text-align:center;margin-top:6px;}
#asset-detail-modal>div>div:first-child>div:first-child>div:first-child{justify-content:center;flex-wrap:wrap;}
#asset-detail-modal>div>div:first-child>div:last-child{
  position:absolute;
  top:8px;
  right:10px;
}
#asset-detail-modal #asset-modal-related-panel.hidden{display:none!important;}
@media(max-width:520px){
  #asset-detail-modal>div>div:first-child{padding-top:36px;}
  #asset-detail-modal>div>div:first-child>div:last-child{top:5px;right:6px;}
}


/* Keep favorite, type and version badges at the top-left of the asset modal */
#asset-detail-modal>div>div:first-child{padding-top:36px;}
#asset-detail-modal>div>div:first-child>div:first-child>div:first-child{
  position:absolute;
  top:8px;
  left:10px;
  right:118px;
  width:auto;
  justify-content:flex-start;
  align-items:center;
  flex-direction:row;
  flex-wrap:wrap;
}
#asset-detail-modal #asset-modal-title{margin-top:0;padding-top:2px;}
@media(max-width:520px){
  #asset-detail-modal>div>div:first-child{padding-top:40px;}
  #asset-detail-modal>div>div:first-child>div:first-child>div:first-child{top:7px;left:6px;right:90px;}
}

/* Hide the moderator Assets Requests shortcut on the public Assets page. */
body[data-page="assets"] #assets-requests-nav-btn{display:none!important;}


/* Keep project store badges aligned at the bottom of equally stretched cards. */
#projects-grid { align-items: stretch; }
#projects-grid > article { height: 100%; min-width: 0; }
#projects-grid > article > .flex.flex-1.flex-col.p-5 { flex: 1 1 auto; min-height: 0; }
#projects-grid > article .project-store-badges { min-height: 54px; align-content: flex-end; margin-top: auto; box-sizing: border-box; }
#projects-grid > article .project-store-badges > a { flex-shrink: 0; }


/* Utility detail modal refinements */
#asset-detail-modal .asset-modal-stats .asset-modal-stat.hidden{display:none!important}
#asset-detail-modal #asset-modal-image-wrap{width:100%;height:clamp(180px,28vh,300px);min-height:180px;display:flex;align-items:center;justify-content:center;overflow:hidden;background:#07090e}
#asset-detail-modal #asset-modal-image-wrap.hidden{display:none!important}
#asset-detail-modal #asset-modal-image-wrap img{display:block;width:100%;height:100%;max-height:none!important;max-width:100%;object-fit:cover;object-position:center;margin:0}
#asset-detail-modal .asset-modal-tag{transform-style:preserve-3d;will-change:transform,background-color,border-color;transition:transform .12s ease-out,background-color .18s ease,border-color .18s ease,color .18s ease,box-shadow .18s ease}
@media(max-width:520px){#asset-detail-modal #asset-modal-image-wrap{height:clamp(180px,30vh,240px);min-height:180px}}
@media(prefers-reduced-motion:reduce){#asset-detail-modal .asset-modal-tag{transition:none}}


/* Utility cards: cyan titles and counters aligned at bottom-left */
#projects-grid .asset-card-title{color:#67e8f9!important;text-shadow:0 0 10px rgba(34,211,238,.2)}


/* Detail modal: keep Likes and Views at the bottom-left without changing outer utility cards. */
#asset-detail-modal .asset-modal-actions{display:flex;align-items:center;gap:9px;width:100%;margin-top:10px;}
#asset-detail-modal .asset-modal-footer-stats{display:flex;align-items:center;justify-content:flex-start;gap:10px;flex:0 0 auto;margin-right:auto;}
#asset-detail-modal .asset-modal-footer-stat{display:inline-flex;align-items:center;gap:6px;color:#b8c4d7;font-size:12px;line-height:1;white-space:nowrap;}
#asset-detail-modal .asset-modal-footer-stat>span:last-child{display:flex;flex-direction:column;align-items:flex-start;gap:4px;font-size:11px;}
#asset-detail-modal .asset-modal-footer-stat strong{font-family:ui-monospace,SFMono-Regular,Menlo,monospace;font-size:15px;line-height:1;font-weight:850;color:#f8fafc;font-variant-numeric:tabular-nums;}
#asset-detail-modal .asset-modal-footer-icon{display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;flex:0 0 38px;border-radius:9999px;border:1px solid rgba(103,232,249,.22);background:rgba(103,232,249,.08);color:#67e8f9;font-size:20px;}
#asset-detail-modal .asset-modal-footer-stat-likes .asset-modal-footer-icon{color:#fb7185;border-color:rgba(251,113,133,.3);background:rgba(251,113,133,.1);}
#asset-detail-modal .asset-modal-footer-stat-views .asset-modal-footer-icon{border-radius:9999px;color:#a5b4fc;border-color:rgba(165,180,252,.3);background:rgba(165,180,252,.1);}
@media(max-width:640px){#asset-detail-modal .asset-modal-actions{gap:6px;flex-wrap:wrap;}#asset-detail-modal .asset-modal-footer-stats{gap:9px;flex:1 1 100%;margin:0 0 5px;}#asset-detail-modal .asset-modal-footer-icon{width:38px;height:38px;flex-basis:38px;font-size:19px;}#asset-detail-modal .asset-modal-footer-stat strong{font-size:15px;}}