










.addons-row {
  margin-top: var(--s-7);
}

.radar-cell,
.leetcode-cell {
  display: flex;
  flex-direction: column;
  min-width: 0;
}





.addon-loading {
  display: block;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 2px;
  color: var(--ink-dim);
  padding: var(--s-4) 0;
  animation: addon-blink 1.1s step-end infinite;
}
@keyframes addon-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.25; }
}

.addon-err {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 1px;
  color: #ff7a3d;
  line-height: 1.7;
  margin-top: var(--s-2);
}





.heatmap-tip {
  position: fixed;
  z-index: 9000;
  pointer-events: none;

  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 1px;
  white-space: nowrap;
  color: var(--green);

  background: var(--bg-0);
  border: 1px solid var(--line-strong);
  padding: 5px 12px;

  box-shadow:
    0 0 12px rgba(57, 255, 20, 0.28),
    0 0 36px rgba(57, 255, 20, 0.1);

  
  opacity: 0;
  transform: translateY(5px);
  transition:
    opacity  100ms ease,
    transform 100ms ease;
}

.heatmap-tip.is-visible {
  opacity: 1;
  transform: translateY(0);
}





.radar-svg {
  width: 100%;
  height: auto;
  display: block;
}


.radar-cell .cell-frame {
  display: flex;
  align-items: center;
  justify-content: center;
}






:root {
  --lc-med:  #e8a227;
  --lc-hard: #ff5252;
}


.lc-layout {
  display: grid;
  grid-template-columns: 142px 1fr;
  gap: var(--s-4);
  align-items: start;
  width: 100%;
}

@media (max-width: 1200px) {
  .lc-layout { grid-template-columns: 1fr; }
}


.lc-donut {
  width: 130px;
  height: 130px;
  display: block;
  flex-shrink: 0;
}


.lc-meta {
  margin-top: var(--s-2);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 1px;
}
.lc-meta-row {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
  color: var(--ink-dim);
  border-bottom: 1px solid var(--line);
}
.lc-meta-row:last-child { border-bottom: none; }
.lc-meta-row .v { color: var(--green); font-weight: 600; }


.lc-tiles-col {
  display: flex;
  flex-direction: column;
  gap: var(--s-2);
  justify-content: center;
  min-width: 0;
}


.lc-tile {
  border: 1px solid var(--line);
  padding: var(--s-2) var(--s-3);
  background: rgba(57, 255, 20, 0.02);
  transition: border-color 200ms ease, background 200ms ease;
}
.lc-tile:hover {
  border-color: var(--line-strong);
  background: rgba(57, 255, 20, 0.04);
}

.lc-tile-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 7px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 2px;
}

.lc-diff         { font-weight: 700; text-transform: uppercase; }
.lc-diff-easy    { color: var(--green); }
.lc-diff-medium  { color: var(--lc-med); }
.lc-diff-hard    { color: var(--lc-hard); }

.lc-frac         { color: var(--ink-dim); font-size: 10px; }
.lc-frac-s       { color: var(--ink); }


.lc-bar {
  height: 3px;
  background: var(--line);
  overflow: hidden;
}
.lc-bar-fill {
  height: 100%;
  transition: width 900ms cubic-bezier(.2, .8, .2, 1);
  box-shadow: 0 0 6px currentColor;
}
.lc-bar-easy   { background: var(--green);    color: var(--green); }
.lc-bar-medium { background: var(--lc-med);   color: var(--lc-med); }
.lc-bar-hard   { background: var(--lc-hard);  color: var(--lc-hard); }






#achievements {
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
}


.ach-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3);
}


.ach-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  cursor: default;
}



.ach-img-wrap {
  position: relative;
  width: 72px;
  height: 72px;
  border: none;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  
  --rx: 0deg;
  --ry: 0deg;
  --mx: 50%;
  --my: 50%;
  --sc: 1;
  --charge: 0;
  
  transform: perspective(520px) rotateX(var(--rx)) rotateY(var(--ry)) scale(var(--sc));
  transform-style: preserve-3d;
  will-change: transform;
}

.ach-img-wrap.is-snap {
  transition: transform 0.28s cubic-bezier(0.22, 0.61, 0.36, 1);
}


.ach-img-wrap::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: radial-gradient(circle at var(--mx) var(--my),
    rgba(57,255,20,0.65) 0%,
    rgba(57,255,20,0.28) 24%,
    rgba(57,255,20,0) 56%);
  opacity: 0;
  transition: opacity 0.1s ease;
  mix-blend-mode: screen;
  pointer-events: none;
  z-index: 3;
}
.ach-badge:hover .ach-img-wrap::before { opacity: 1; }


.ach-img-wrap::after {
  content: '';
  position: absolute;
  inset: -5px;
  border-radius: 50%;
  background: conic-gradient(from -90deg,
    #39FF14 calc(var(--charge) * 360deg),
    rgba(57,255,20,0) 0);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3.5px), #000 calc(100% - 3.5px));
          mask: radial-gradient(farthest-side, transparent calc(100% - 3.5px), #000 calc(100% - 3.5px));
  filter: drop-shadow(0 0 calc(2px + var(--charge) * 9px) #39FF14);
  pointer-events: none;
  z-index: 2;
}


.ach-img {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  display: block;
  filter:
    drop-shadow(0 0 4px rgba(57,255,20,0.35))
    drop-shadow(0 0 12px rgba(57,255,20,0.15));
  
  box-shadow:
    0 0 calc(var(--charge, 0) * 30px) calc(var(--charge, 0) * 4px)
    color-mix(in srgb, #39FF14 calc(var(--charge, 0) * 80%), transparent);
  transition: filter 280ms ease;
}

.ach-badge:hover .ach-img {
  filter:
    drop-shadow(0 0 6px rgba(57,255,20,0.9))
    drop-shadow(0 0 18px rgba(57,255,20,0.55))
    drop-shadow(0 0 40px rgba(57,255,20,0.25));
}


.ach-img-fallback {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--bg-1);
  border: 1px solid var(--line-strong);
  font-size: 28px;
  color: var(--ink-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  filter:
    drop-shadow(0 0 4px rgba(57,255,20,0.2))
    drop-shadow(0 0 10px rgba(57,255,20,0.08));
  transition: filter 280ms ease, transform 280ms ease;
}
.ach-badge:hover .ach-img-fallback {
  filter:
    drop-shadow(0 0 6px rgba(57,255,20,0.7))
    drop-shadow(0 0 20px rgba(57,255,20,0.4));
  transform: scale(1.08);
}


.ach-tier {
  position: absolute;
  bottom: -8px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 600;
  letter-spacing: 2.2px;
  text-indent: 2.2px;            
  padding: 3px 10px;
  border-radius: 999px;
  text-transform: uppercase;
  white-space: nowrap;
  z-index: 4;
  
  background: linear-gradient(180deg, rgba(22,26,22,0.97), rgba(8,10,8,0.97));
  -webkit-backdrop-filter: blur(4px);
          backdrop-filter: blur(4px);
  
  color: #d8dee3;
  border: 1px solid rgba(216,222,227,0.38);
  box-shadow:
    0 2px 7px rgba(0,0,0,0.55),
    inset 0 1px 0 rgba(255,255,255,0.14);
}


.ach-tier--bronze {
  color: #d79a6a;
  border-color: rgba(215,154,106,0.42);
  text-shadow: 0 0 7px rgba(215,154,106,0.35);
}
.ach-tier--silver {
  color: #dfe6ec;
  border-color: rgba(223,230,236,0.42);
  text-shadow: 0 0 7px rgba(223,230,236,0.30);
}
.ach-tier--gold {
  color: #eccb63;
  border-color: rgba(236,203,99,0.46);
  text-shadow: 0 0 8px rgba(236,203,99,0.40);
}
.ach-tier--platinum {
  color: #ecf6ff;
  border-color: rgba(236,246,255,0.52);
  text-shadow: 0 0 9px rgba(190,225,255,0.45);
}


.ach-mult {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 21px;
  height: 21px;
  padding: 0 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1;
  color: #042b00;
  background: linear-gradient(180deg, #5dff2e, #2fd60f);
  border: 1px solid rgba(190,255,160,0.65);
  box-shadow:
    0 0 10px rgba(57,255,20,0.55),
    0 1px 4px rgba(0,0,0,0.45),
    inset 0 1px 0 rgba(255,255,255,0.45);
  z-index: 5;
}


.ach-label {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 1px;
  color: var(--ink-dim);
  text-align: center;
  max-width: 72px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  opacity: 0;
  transform: translateY(-3px);
  transition: opacity 200ms ease, transform 200ms ease;
}

.ach-badge:hover .ach-label {
  opacity: 1;
  transform: translateY(0);
  
  max-width: none;
  white-space: normal;
  overflow: visible;
  word-break: break-all;
}




.ach-reveal {
  position: relative;
  display: flex;
  justify-content: center;
  width: 100%;
  
  margin-top: 10px;
}


.ach-scanline {
  position: absolute;
  top: 0;
  left: 50%;
  width: 60px;
  height: 2px;
  transform: translate(-50%, -2px);
  background: #39FF14;
  border-radius: 2px;
  box-shadow:
    0 0 6px #39FF14,
    0 0 14px rgba(57,255,20,0.85),
    0 0 26px rgba(57,255,20,0.45);
  opacity: 0;
  pointer-events: none;
  z-index: 5;
}



.ach-badge.fx-on .ach-label {
  opacity: 1;
  transform: none;
  transition: none;
  max-width: 88px;
  white-space: normal;
  overflow: visible;
  word-break: break-all;
  color: var(--green);
  text-shadow:                       
    0 0 5px rgba(57,255,20,0.55),
    0 0 11px rgba(57,255,20,0.30);
  clip-path: inset(0 0 100% 0);      
}


.ach-badge.fx-on.is-revealed .ach-label {
  animation: ach-print 380ms cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}
.ach-badge.fx-on.is-revealed .ach-scanline {
  animation: ach-scan 380ms cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
}


@keyframes ach-print {
  from { clip-path: inset(0 0 100% 0); }
  to   { clip-path: inset(0 0 0 0); }
}


@keyframes ach-scan {
  0%   { transform: translate(-50%, -2px);              opacity: 0; }
  14%  {                                                opacity: 1; }
  86%  {                                                opacity: 1; }
  100% { transform: translate(-50%, var(--rh, 16px));   opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .ach-badge.fx-on.is-revealed .ach-label,
  .ach-badge.fx-on.is-revealed .ach-scanline { animation: none; }
}


.ach-log {
  border-top: 1px dashed var(--line);
  padding-top: var(--s-3);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--ink-dim);
  line-height: 1;
}

.ach-log-line {
  padding: 2px 0;
  opacity: 0;
  animation: ach-fadein 80ms ease forwards;
}
@keyframes ach-fadein { to { opacity: 1; } }

.ach-log-header { color: var(--green); }
.ach-log-done   { color: var(--green); opacity: 0.6; }








.avatar-stage {
  perspective: 900px;
}
.avatar-frame {
  
  --tilt-rx: 0deg;
  --tilt-ry: 0deg;
  --glow: 0;
  --gx: 50%;
  --gy: 50%;
  transform: rotateX(var(--tilt-rx)) rotateY(var(--tilt-ry));
  transform-style: preserve-3d;
  transition:
    transform 0.5s cubic-bezier(0.22, 0.61, 0.36, 1),
    box-shadow 0.45s ease,
    filter 0.45s ease;
}

.avatar-frame.is-tilting {
  transition:
    transform 0.12s ease-out,
    box-shadow 0.12s ease,
    filter 0.12s ease;
  filter: brightness(1.08);
  box-shadow:
    0 18px 48px -14px rgba(57, 255, 20, calc(0.4 * var(--glow))),
    0 0 0 1px rgba(57, 255, 20, calc(0.22 * var(--glow)));
}


.avatar-glare {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  opacity: var(--glow);
  transition: opacity 0.35s ease;
  background: radial-gradient(
    130px 130px at var(--gx) var(--gy),
    rgba(190, 255, 160, 0.3),
    rgba(57, 255, 20, 0.1) 45%,
    transparent 72%
  );
  mix-blend-mode: screen;
}



.avatar-corners span {
  position: absolute;
  width: 18px;
  height: 18px;
  z-index: 6;
  pointer-events: none;
  border: 2px solid rgba(57, 255, 20, 0.28);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}
.avatar-corners .ac-tr { top: 10px; right: 10px; border-left: 0; border-bottom: 0; }
.avatar-corners .ac-bl { bottom: 10px; left: 10px; border-right: 0; border-top: 0; }
.avatar-frame.is-tilting .avatar-corners span {
  border-color: var(--green);
  box-shadow: 0 0 10px rgba(57, 255, 20, 0.5);
}

@media (prefers-reduced-motion: reduce) {
  .avatar-frame { transform: none; }
  .avatar-glare { display: none; }
}
