:root {
  --color-navy: #f1ebdb; --color-cyan: #2ba0e0; --color-cyan-bright: #1f8fce; --color-ice: #bfe6f5;
  --color-text: #34302a; --color-muted: #6c6350; --color-faint: #8a7d63;
  --color-border: rgba(150,125,90,0.3); --color-border-2: rgba(150,125,90,0.4); --color-border-strong: rgba(108,191,60,0.5);
  --tS: #f4a63c; --tA: #57c948; --tB: #2ba0e0; --tC: #b06be0; --tD: #7d7360;
  --shadow-card: 0 20px 46px rgba(60,78,112,0.13); --radius-xl: 26px; --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --pal-glyph: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 3c-4.4 0-8 3.2-8 7.2 0 2.5 1.4 4.7 3.5 6 .5.3.8.9.7 1.5l-.2 1c-.2.9.5 1.7 1.4 1.6 1-.1 1.7-.9 1.7-1.9v-.6c0-.3.2-.5.5-.5h.6c.3 0 .5.2.5.5v.6c0 1 .7 1.8 1.7 1.9.9.1 1.6-.7 1.4-1.6l-.2-1c-.1-.6.2-1.2.7-1.5 2.1-1.3 3.5-3.5 3.5-6C20 6.2 16.4 3 12 3Z'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; }
html {
  scrollbar-gutter: stable; min-height: 100%; background: var(--color-navy); color-scheme: light; }
body { min-height: 100vh; margin: 0; color: var(--color-text); font-family: "Manrope", system-ui, sans-serif; font-size: 15px; line-height: 1.5;
  background: radial-gradient(1200px 620px at 50% -8%, rgba(108,191,60,0.13), transparent 62%), radial-gradient(900px 520px at 88% 4%, rgba(108,191,60,0.09), transparent 60%), linear-gradient(180deg, #fbf5ea 0%, #f1ebdb 46%, #f1ebdb 100%); background-attachment: fixed; }
button, a { -webkit-tap-highlight-color: transparent; }
.wrap { position: relative; z-index: 1; width: min(1240px, calc(100% - 32px)); margin: 0 auto; padding: 40px 0 64px; }

.hero { max-width: 800px; margin-bottom: 22px; animation: rise 0.5s var(--ease) both; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px; padding: 5px 12px 5px 10px; border: 1px solid var(--color-border-2); border-radius: 999px; color: var(--color-cyan-bright); background: rgba(108,191,60,0.08); font-size: 0.68rem; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; }
.eyebrow::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--color-cyan); box-shadow: 0 0 10px rgba(108,191,60,0.8); }
.hero h1 { font-family: "Baloo 2", "Manrope", system-ui, sans-serif;  margin: 0; font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.14; letter-spacing: -0.012em; font-weight: 800; }
.hero h1 .grad { color: transparent; background: linear-gradient(120deg, #2494d6, #5aa62e); -webkit-background-clip: text; background-clip: text; font-weight: 700; }
.tagline { max-width: 640px; margin: 14px 0 0; color: var(--color-muted); font-size: clamp(0.95rem, 2vw, 1.04rem); }

.cat-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.cat-tab { padding: 9px 18px; border: 1px solid var(--color-border-2); border-radius: 12px; color: var(--color-muted); background: rgba(255,255,255,0.5); cursor: pointer; font-weight: 700; font-size: 0.9rem; transition: 150ms var(--ease); }
.cat-tab:hover { color: var(--color-text); border-color: var(--color-border-strong); transform: translateY(-1px); }
.cat-tab.on { color: #f5efe2; border-color: transparent; background: linear-gradient(135deg, var(--color-cyan-bright), var(--color-cyan)); box-shadow: 0 6px 16px rgba(60,78,112,0.1); }

.tier-board { display: grid; gap: 12px; }
.tier-row { display: grid; grid-template-columns: 64px 1fr; gap: 14px; align-items: stretch; border: 1px solid var(--color-border); border-radius: var(--radius-xl); background: linear-gradient(150deg, rgba(252, 248, 240, 0.95), rgba(247, 240, 225, 0.96)); overflow: hidden; box-shadow: var(--shadow-card); animation: rise 0.4s var(--ease) both; }
.tier-tag { display: grid; place-content: center; gap: 2px; font-size: 1.9rem; font-weight: 800; color: #f5efe2; text-align: center; }
.tier-tag small { font-size: 0.7rem; font-weight: 750; opacity: 0.7; }
.tier-row[data-tier="S"] .tier-tag { background: linear-gradient(160deg, var(--tS), #c47f12); }
.tier-row[data-tier="A"] .tier-tag { background: linear-gradient(160deg, var(--tA), #3a9130); }
.tier-row[data-tier="B"] .tier-tag { background: linear-gradient(160deg, var(--tB), #2f74c0); }
.tier-row[data-tier="C"] .tier-tag { background: linear-gradient(160deg, var(--tC), #8248b0); }
.tier-row[data-tier="D"] .tier-tag { background: linear-gradient(160deg, var(--tD), #71828d); }

.tier-pals { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px 12px 0; align-content: flex-start; }
.tp { width: 72px; display: grid; justify-items: center; gap: 4px; color: var(--color-text); text-decoration: none; background: none; border: 0; padding: 0; margin: 0; font: inherit; cursor: pointer; }
.tp span { max-width: 72px; overflow: hidden; font-size: 0.68rem; font-weight: 650; line-height: 1.2; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.tp:hover .pf { border-color: var(--color-border-strong); transform: translateY(-2px); box-shadow: 0 10px 22px rgba(60,78,112,0.11); }
.tier-empty { color: var(--color-faint); font-size: 0.85rem; padding: 12px 0; }

.pf { --s: 52px; position: relative; width: var(--s); height: var(--s); display: grid; place-items: center; overflow: hidden; border-radius: 50%; border: 1px solid rgba(150,125,90,0.3); background: radial-gradient(circle at 50% 34%, #fffefa 0%, #faf4e8 58%, #f7f1e4 100%); box-shadow: inset 0 0 0 1px rgba(60,78,112,0.08); transition: 160ms var(--ease); }
.pf img { width: 100%; height: 100%; object-fit: contain; transform: scale(1.16); filter: drop-shadow(0 3px 6px rgba(60,78,112,0.12)); }
.pf.failed::before { content: ""; width: 46%; height: 46%; background: var(--color-faint); opacity: 0.5; -webkit-mask: var(--pal-glyph) center / contain no-repeat; mask: var(--pal-glyph) center / contain no-repeat; }

.foot { margin: 26px 0 0; color: rgba(125,115,96,0.5); font-size: 0.72rem; text-align: center; }
:focus-visible { outline: 2px solid var(--color-cyan); outline-offset: 3px; }
* { scrollbar-width: thin; scrollbar-color: rgba(108,191,60,0.4) transparent; }
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-thumb { border: 3px solid transparent; border-radius: 999px; background-clip: padding-box; background-color: rgba(150,125,90,0.28); }

@media (max-width: 640px) { .tier-row { grid-template-columns: 48px 1fr; } .tier-tag { font-size: 1.4rem; } .tp { width: 60px; } .pf { --s: 46px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; } }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
