* {
  box-sizing: border-box;
}

html {
  scrollbar-width: none;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: #fff;
    background:
        radial-gradient(circle at 10% 5%, rgba(255, 55, 177, 0.22), transparent 30%),
        radial-gradient(circle at 80% 15%, rgba(104, 191, 206, 0.15), transparent 30%),
        radial-gradient(circle at 50% 95%, rgba(255, 55, 177, 0.15), transparent 35%),
        linear-gradient(180deg, #080813 0%, #111024 45%, #160f27 100%);
    overflow-x: hidden;
}

.container {
    width: min(1100px, calc(100% - 20px));
    margin: clamp(80px, 6vw, 100px) auto 25px;
}

/* Layout */

.layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 0;
    min-width: 0;
    width: 100%;
    min-height: 77vh;
    align-items: start;
    transition: grid-template-columns .6s ease;
}

.layout > * {
    min-width: 0;
}

.layout.filters-visible {
    grid-template-columns: minmax(0, 1fr) 225px;
    transition: grid-template-columns .4s ease;
}

/* Content */

.content {
    min-width: 0;
    width: 100%;
    padding: clamp(15px, 2.4vw, 25px);
    background: rgba(10, 15, 30, 0.68);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 50px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 
        0 0 40px rgba(0, 0, 0, 0.62), 
        0 0 24px rgba(120, 140, 255, 0.14);
}

/* Topbar */

.topbar {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60px;
    margin-bottom: 20px;
}

.title-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-width: 0;
  max-width: calc(100% - 55px);
}

.topbar h1 {
    min-width: 0;
    margin: 0;
    font-size: clamp(18px, 3vw, 25px);
    letter-spacing: clamp(1.5px, 0.25vw, 2.5px);
    color: #e7ebff;
    font-weight: 750;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

/* Info tooltip */

.info-icon {
    width: 22px;
    opacity: .7;
    cursor: pointer;
    transition: transform .2s ease, opacity .2s ease;
    vertical-align: middle;
}

.info-icon:hover {
    opacity: 1;
    transform: scale(1.1);
}

.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip-content {
    position: absolute;
    top: calc(100% + 20px);
    right: -20px;

    width: min(500px, 80vw);
    padding: 14px;

    background: rgba(10,15,35);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 16px;
    box-shadow:
        0 16px 42px rgba(0, 0, 0, 0.65), 
        0 0 18px rgba(109, 247, 255, 0.12);

    color: #dce3ff;
    font-size: 14px;
    line-height: 1.4;
    text-align: left;

    display: none;
    z-index: 100;
}

.tooltip:hover .tooltip-content {
    display: block;
}

/* Filter button */

.filter-toggle {
    position: absolute;
    right: 0;
    width: 32px;
    height: 32px;
    cursor: pointer;
    opacity: .8;
    transition:
        transform .2s ease,
        opacity .2s ease;
}

.filter-toggle:hover {
    opacity: 1;
    transform: scale(1.08);
}

.filter-toggle.active {
    transform: rotate(90deg) scale(1.1);
}

/* Table */

.table-container {
    position: relative;
    min-width: 0;
    width: 100%;
    max-width: 100%;
    background: rgba(5, 8, 20, .72);
    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 16px;
    overflow: hidden;
}

.table-scroll {
    min-width: 0;
    width: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: visible;
    border-radius: 16px;
    -webkit-overflow-scrolling: touch;
}

.table-scroll::-webkit-scrollbar {
    height: 8px;
}

.table-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.04);
    border-radius: 999px;
}

.table-scroll::-webkit-scrollbar-thumb {
    background: rgba(104, 191, 206, 0.45);
    border-radius: 999px;
}

.table-scroll::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 56, 184, 0.55);
}

.table-scroll {
    scrollbar-width: thin;
    scrollbar-color: rgba(104, 191, 206, 0.5) rgba(255, 255, 255, 0.04);
}

table {
    width: 100%;
    min-width: 680px;
    border-collapse: separate;
    border-spacing: 0;
}

th, 
td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.075);
    padding: 5px;
    text-align: center;
    font-size: clamp(12px, 2.2vw, 16px);
}

th {
    background: linear-gradient(180deg, rgba(31, 39, 82, 0.98), rgba(12, 17, 39, 0.98));
    color: #e6e9ff;
    cursor: pointer;
    position: sticky;
    top: 0;
    z-index: 2;
    font-size: clamp(16px, 2.2vw, 20px);
    padding: 14px;
    letter-spacing: 0.4px;
    white-space: nowrap;
}

tbody {
    position: relative;
}

tbody tr {
    background: rgba(255, 255, 255, 0.03);
    transition: 
        transform .2s ease, 
        box-shadow .2s ease, 
        background .2s ease;
}

tbody tr:nth-child(even) {
    background: rgba(120, 140, 255, 0.055);
}

tbody tr:hover,
tbody tr:nth-child(even):hover {
    background: rgba(255,255,255,.15);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,.35);
}

.icon-cell img,
.outfit-cell img {
    width: clamp(42px, 6vw, 50px);
    height: clamp(42px, 6vw, 50px);
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 16px;
    object-fit: cover;
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 0 16px rgba(109, 247, 255, 0.1);
}

.name-cell {
    text-align: center;
    font-weight: 750;
}

.t1 img, 
.t2 img, 
.t3 img {
    width: clamp(42px, 6vw, 50px);
    height: clamp(42px, 6vw, 50px);
}

/* Outfit tooltip - description */

.outfit-tooltip{
    position: fixed;
    display: none;
    z-index: 99999;

    padding: 3px;

    background: rgba(10,15,35,.95);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 12px;

    box-shadow:
        0 0 18px rgba(0,0,0,.6),
        0 0 10px rgba(120,140,255,.25);

    pointer-events: none;
}

.outfit-tooltip img{
    display: block;
    width: 300px;
    border-radius: 10px;
}


/* Skin Tier badge in table */

.skin-tier-cell {
    text-align: center;
}

.skin-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    
    width: clamp(32px, 4vw, 36px);
    height: clamp(32px, 4vw, 36px);
    
    border-radius: 10px;
    border: 1px solid color-mix(in srgb, currentColor 70%, transparent);
    
    font-weight: 700;
    font-size: clamp(12px, 2.4vw, 16px);
    line-height: 1;
    
    background: color-mix(in srgb, currentColor 12%, rgba(10, 15, 35, 0.94));
    box-shadow:
    inset 0 0 7px rgba(0, 0, 0, 0.4),
    0 0 5px color-mix(in srgb, currentColor 16%, transparent);
    
    text-shadow: 0 0 4px color-mix(in srgb, currentColor 55%, transparent);
}

/* Skin Tier colors */

.skin-S { color: #ffe600; }
.skin-A { color: #ff00ff; }
.skin-B { color: #00e5ff; }
.skin-C { color: #00ff66; }
.skin-D { color: #b0ffb0; }
.skin-E { color: #c27501; }
.skin-F { color: #ff9900; }
.skin-none { color: #ffb000; }

/* Skin Tier header */

.skin-title {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.skin-info-btn {
    width: 16px;
    height: 16px;
    cursor: pointer;
    opacity: .7;
    transition: transform .2s ease, opacity .2s ease;
}

.skin-info-btn:hover {
    opacity: 1;
    transform: scale(1.1);
}

/* Skin Tier tooltip */

.skin-tooltip {
    position: fixed;
    display: none;
    z-index: 99999;
    
    width: 180px;
    padding: 12px;
    
    background: rgba(10,15,35,.95);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 16px;
    box-shadow: 
    0 0 18px rgba(0,0,0,.6),
    0 0 10px rgba(120,140,255,.25);
    
    font-size: 14px;
    line-height: 1.2;
    text-align: left;
    
    pointer-events: none;
    white-space: normal;
}

.skin-description {
    font-size: 16px;
    font-weight: 750;
}

/* Bottombar */

.bottombar {
  height: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 20px;
}

.bottombar p {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: 15px;
  color: #cfcfe6;
}

.bottombar-icon {
  width: 18px;
  height: 18px;

  fill: none;
  stroke: #bfc7ee;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;

  opacity: .85;
  filter: drop-shadow(0 0 5px rgba(109, 247, 255, .18));
}

/* Sidebar hidden */

.sidebar.hidden {
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    transform: translateX(20px) scale(0.95);
}

/* Sidebar */

.sidebar {
    position: sticky;
    top: 100px;
    width: 225px;
    max-height: calc(100vh - 48px);
    padding: 20px;
    overflow: auto;
    background: rgba(12, 16, 35, 0.88);
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 50px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 
        0 0 40px rgba(0, 0, 0, 0.62), 
        0 0 24px rgba(120, 140, 255, 0.14);
    transform-origin: top right;
    transition: transform 0.35s ease, opacity 0.35s ease, visibility 0.35s ease;
}

.sidebar h2,
.sidebar h3 {
  margin: 0;
  color: #e7ebff;
  text-align: center;
  letter-spacing: 1.4px;
}

.sidebar h2 {
    font-size: 22px;
    margin-top: 0;
    padding: 10px;
    text-decoration: underline;
    text-decoration-color: rgba(109, 247, 255, 0.35);
    text-underline-offset: 8px;
}

.sidebar h3 {
    font-size: 16px;
    color: #bfc7ee;
    margin: 12px 0;
}

/* Search */

.search {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  height: 40px;
  margin-top: 20px;
}

.search::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.055), transparent 45%),
    linear-gradient(180deg, rgba(20, 25, 47, 0.98), rgba(8, 12, 28, 0.98));
  border: 1px solid rgba(191, 199, 238, 0.18);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 14px rgba(109, 247, 255, 0.055);
  pointer-events: none;
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}

.search:focus-within::before {
  border-color: rgba(109, 247, 255, 0.58);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 0 16px rgba(109, 247, 255, 0.18);
}

.search-icon {
  position: absolute;
  left: 15px;
  top: 35%;
  z-index: 2;

  display: grid;
  place-items: center;

  width: 20px;
  height: 20px;

  color: #f2f5ff;
  font-size: 28px;
  line-height: 1;

  transform: translateY(-50%);
  pointer-events: none;
  transition: color 0.22s ease, text-shadow 0.22s ease;
}

.search:focus-within .search-icon {
  color: rgba(109, 247, 255, 0.95);
  text-shadow: 0 0 8px rgba(109, 247, 255, 0.28);
}

.search-input {
  position: relative;
  z-index: 1;

  width: 100%;
  height: 40px;
  padding: 0 40px 0 40px;

  border: 0;
  outline: none;

  color: #f4f5ff;
  background: transparent;

  font-size: 16px;
  font-weight: 650;
  line-height: 40px;
  letter-spacing: 0.2px;
}

.search-input::placeholder {
  color: rgba(191, 199, 238, 0.58);
  font-weight: 600;
}

.search-reset {
  position: absolute;
  right: 5px;
  top: 50%;
  z-index: 2;

  display: grid;
  place-items: center;

  width: 30px;
  height: 30px;
  padding: 0;

  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;

  color: #f2f5ff;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.035));

  font-size: 20px;
  font-weight: 800;
  line-height: 1;

  cursor: pointer;
  transform: translateY(-50%);
  transition:
    transform 0.16s ease,
    color 0.16s ease,
    border-color 0.16s ease,
    background 0.16s ease,
    box-shadow 0.16s ease;
}

.search-reset:hover {
  color: #ffe6f8;
  border-color: rgba(255, 118, 215, 0.38);
  background: rgba(255, 118, 215, 0.16);
  box-shadow: 0 0 10px rgba(255, 118, 215, 0.16);
  transform: translateY(-50%) scale(1.06);
}

.search-reset:active {
  transform: translateY(-50%) scale(0.96);
}

/* Skin Tier filter */

.skin-filter {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-top: 10px;
}

.skin-filter button {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: clamp(32px, 4vw, 36px);
    height: clamp(32px, 4vw, 36px);

    border-radius: 10px;
    border: 1px solid color-mix(in srgb, currentColor 70%, transparent);

    font-weight: 700;
    font-size: clamp(12px, 2.4vw, 16px);
    line-height: 1;

    background: color-mix(in srgb, currentColor 12%, rgba(10, 15, 35, 0.94));
    color: currentColor;

    box-shadow:
        inset 0 0 7px rgba(0, 0, 0, 0.4),
        0 0 5px color-mix(in srgb, currentColor 16%, transparent);

    text-shadow: 0 0 4px color-mix(in srgb, currentColor 55%, transparent);

    opacity: .75;
    cursor: pointer;

    transition:
        transform .15s ease,
        opacity .2s ease,
        border .2s ease,
        box-shadow .2s ease,
        background .2s ease;
}

.skin-filter button:hover {
    transform: scale(1.08);
    opacity: 1;

    background: color-mix(in srgb, currentColor 18%, rgba(10, 15, 35, 0.92));
    border: 1px solid color-mix(in srgb, currentColor 90%, transparent);

    box-shadow:
        inset 0 0 8px rgba(0, 0, 0, 0.45),
        0 0 8px color-mix(in srgb, currentColor 24%, transparent);
}

.skin-filter button.active {
    transform: scale(1.14);
    opacity: 1;

    background: color-mix(in srgb, currentColor 24%, rgba(10, 15, 35, 0.9));
    border: 1px solid currentColor;

    box-shadow:
        inset 0 0 9px rgba(0, 0, 0, 0.5),
        0 0 10px color-mix(in srgb, currentColor 32%, transparent);
}

/* Skin Tier filter colors */

.skin-filter button[data-value="S"] { color: #ffe600; }
.skin-filter button[data-value="A"] { color: #ff00ff; }
.skin-filter button[data-value="B"] { color: #00e5ff; }
.skin-filter button[data-value="C"] { color: #00ff66; }
.skin-filter button[data-value="D"] { color: #b0ffb0; }
.skin-filter button[data-value="E"] { color: #c27501; }
.skin-filter button[data-value="F"] { color: #ff9900; }
.skin-filter button[data-value="-"] { color: #ffb000; }

/* Gift filter icons */

.gift-filter {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 10px;
}

.gift-filter img {
    width: 55px;
    height: 55px;
    cursor: pointer;
    opacity: .6;
    border-radius: 20px;
    border: 1px solid rgba(255,255,255,.08);
    padding: 5px;
    transition:
        transform .15s ease,
        opacity .2s ease,
        box-shadow .2s ease,
        border .2s ease;
}

.gift-filter img:hover {
    opacity: .9;
    transform: scale(1.06);
    border: 1px solid rgba(255,255,255,.2);
    box-shadow:
        0 0 6px rgba(255, 255, 255, .15),
        0 0 10px rgba(255, 255, 255, .2);

}

.gift-filter img.active {
    opacity: 1;
    transform: scale(1.1);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow:
        0 0 8px rgba(255, 255, 255, .6),
        0 0 16px rgba(255, 255, 255, .35),
        inset 0 0 6px rgba(255, 255, 255, .4);
}

/* Separator */

.separator-block {
    height: 1px;
    margin: 20px 0;
    background: linear-gradient(90deg, transparent, rgba(109, 247, 255, 0.32), transparent);
}

/* Reset filters */

.reset-filters {
    width: 100%;
    padding: 10px;
    border-radius: 18px;
    border: 1px solid rgba(255,120,120,.35);
    background: linear-gradient(#301010,#160707);
    color: #ffd0d0;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition:
        transform .15s ease,
        box-shadow .2s ease,
        border .2s ease;
}

.reset-filters:hover {
    transform: scale(1.02);
    border: 1px solid rgba(255,120,120,.6);
    box-shadow:
        0 0 8px rgba(255,80,80,.4),
        inset 0 0 6px rgba(0,0,0,.6);
}

/* Counter */

.counter {
    margin-top: 12px;
    padding: 10px;
    border-radius: 18px;
    background: rgba(255,180,60,.15);
    border: 1px solid rgba(255,180,60,.4);
    color: #ffcc7a;
    font-weight: 700;
    font-size: 15px;
    text-align: center
}

/* Mobile */

@media (max-width: 980px) {
  .layout,
  .layout.filters-visible {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  
  td {
    padding: 4px;
  }

  .outfit-tooltip img{
    width: 250px;
  }
  
  .sidebar {
    position: relative;
    top: auto;
    order: -1;
    width: 100%;
    max-height: none;
  }

  .sidebar.hidden {
    display: none;
  }
}

@media (max-width: 680px) {
  .container {
    width: calc(100% - 14px);
    margin-top: 80px;
  }

  .content,
  .sidebar {
    border-radius: 28px;
  }

  .content {
    padding: 14px;
  }

  .topbar {
    justify-content: flex-start;
    min-height: auto;
    margin-bottom: 16px;
    padding: 14px 44px 14px 14px;
  }

  .title-wrap {
    justify-content: flex-start;
    max-width: 100%;
  }

  .topbar h1 {
    text-align: left;
    font-size: 18px;
    letter-spacing: 1.4px;
  }

  .filter-toggle {
    right: 4px;
  }

  th {
    padding: 12px 10px;
    font-size: 15px;
  }

  td {
    padding: 4px;
    font-size: 13px;
  }

  .icon-cell img,
  .outfit-cell img,
  .t1 img,
  .t2 img,
  .t3 img {
    width: 42px;
    height: 42px;
  }

  .outfit-tooltip img{
    width: 200px;
  }

  .skin-badge {
    width: 32px;
    height: 32px;
    font-size: 13px;
  }

  .points-input {
    width: 94px;
  }
}

@media (max-width: 480px) {
  .container {
    width: calc(100% - 10px);
    margin-top: 72px;
  }

  .content,
  .sidebar {
    border-radius: 22px;
  }

  .content {
    padding: 12px;
  }

  .sidebar {
    padding: 16px;
  }

  .sidebar h2 {
    font-size: 20px;
  }

  .search-input {
    font-size: 15px;
  }

  .skin-filter {
    gap: 10px;
  }

  .gift-filter {
    gap: 8px;
  }

  .gift-filter img {
    width: 50px;
    height: 50px;
    border-radius: 18px;
  }

  table {
    min-width: 660px;
  }

  .bottombar p {
    font-size: 13px;
    text-align: center;
  }
}

/* =========================
   Hide Page Scrollbar Only
========================= */

html {
    scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
    display: none;
}