/* Marcos de tarjeta por mejor medalla (Home y Commissions). Imágenes en ./frames, 9 cortes (esquinas fijas, lados estirados). */
@property --cfh{syntax:"<angle>";initial-value:0deg;inherits:false}
[data-cf]{position:relative}
.comm3-card[data-cf]{overflow:visible!important;contain:none!important;content-visibility:visible!important}
.comm3-card[data-cf] .comm3-banner{border-radius:12px 12px 0 0}
.cf-el{position:absolute;inset:calc(var(--bw,19px) * -1 + 6px);z-index:8;pointer-events:none;display:none;border:var(--bw,38px) solid transparent;border-image:var(--img) var(--sl) / var(--bw,38px) stretch}
[data-cf] > .cf-el{display:block}
[data-cf=gold] > .cf-el{--img:url(./frames/oro.webp);--sl:84;--bw:19px}
[data-cf=silver] > .cf-el{--img:url(./frames/plata.webp);--sl:82;--bw:19px}
[data-cf=bronze] > .cf-el{--img:url(./frames/bronce.webp);--sl:71;--bw:14px}
[data-cf=legend] > .cf-el{--img:url(./frames/leyenda.webp);--sl:104;--bw:23px;animation:cfHue 7s linear infinite;filter:drop-shadow(0 0 4px #ff657855)}
[data-cf=founder] > .cf-el{--img:url(./frames/fundador.webp);--sl:99;--bw:21px;animation:cfPulse 3s ease-in-out infinite;
 background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%23fff1b0'/%3E%3Cstop offset='1' stop-color='%23d9962b'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M12 1.5l3 6.6 7.2.7-5.4 4.8 1.6 7.1L12 17l-6.4 3.7 1.6-7.1L1.8 8.8 9 8.1z' fill='url(%23g)' stroke='%237a0614' stroke-width='1.3' stroke-linejoin='round'/%3E%3C/svg%3E") 50% 0/18px 18px no-repeat}
@keyframes cfHue{to{filter:hue-rotate(360deg) drop-shadow(0 0 4px #ff657855)}}
@keyframes cfPulse{0%,100%{filter:brightness(1) drop-shadow(0 0 3px #ff657844)}50%{filter:brightness(1.18) drop-shadow(0 0 6px #ff657877)}}
@media(prefers-reduced-motion:reduce){.cf-el{animation:none!important}}

/* Marcos de avatar (imagen) por medalla: reemplazan los aros de color */
.comm3-av[data-af]{border:3px solid #111820!important;background:#1b2631!important;box-shadow:none!important;animation:none!important;overflow:visible!important}
.comm3-feat .comm3-av[data-af],.comm3-mini .comm3-av[data-af]{border:2px solid #111820!important;width:34px;height:34px}
.comm3-av[data-af]:before{content:"";position:absolute;inset:var(--ai,-12%);background:var(--aimg) center/contain no-repeat;pointer-events:none;z-index:4}
.comm3-av[data-af=gold]{--aimg:url(./frames/avatar-oro.webp);--ai:-12%}
.comm3-av[data-af=silver]{--aimg:url(./frames/avatar-plata.webp);--ai:-11%}
.comm3-av[data-af=legend]{--aimg:url(./frames/avatar-leyenda.webp);--ai:-7%}
.comm3-av[data-af=founder]{--aimg:url(./frames/avatar-fundador.webp);--ai:-14%}
.comm3-av[data-af=bronze]{--aimg:none}
/* tarjeta: borde un poco más fino */
[data-cf=gold] > .cf-el{--bw:16px}[data-cf=silver] > .cf-el{--bw:16px}[data-cf=bronze] > .cf-el{--bw:12px}[data-cf=legend] > .cf-el{--bw:19px}[data-cf=founder] > .cf-el{--bw:17px}

[data-cf=legend] > .cf-el{--bw:16px}
