/* FoozySkins — gothic × cartoon */

:root {
  --ink: #06030a;
  --bg: #0c0711;
  --bg-2: #120a19;
  --panel: #190e22;
  --panel-2: #22132e;
  --panel-3: #2d1a3d;
  --line: #3b2552;
  --purple: #b55cff;
  --purple-2: #8a3be0;
  --purple-deep: #3c1260;
  --crimson: #ff3463;
  --blood: #a3163a;
  --bone: #f6ecd8;
  --text: #ece4f5;
  --muted: #a898bb;
  --dim: #6f5f84;
  --green: #3ee38f;

  --r-ulu: #fff1a8;
  --r-hasmetli: #ffd166;
  --r-ihtisamli: #ff9f1c;
  --r-ebedi: #c77dff;
  --r-efsanevi: #ff4d6d;
  --r-destansi: #4cc9f0;
  --r-normal: #9aa1ad;

  --font-goth: 'Grenze Gotisch', 'Times New Roman', serif;
  /* Paytone One: chunky cartoon face with full Turkish coverage (İ ş ğ) and ₺ */
  --font-toon: 'Paytone One', 'Rubik', system-ui, sans-serif;
  --font-body: 'Rubik', system-ui, sans-serif;

  --gutter: clamp(16px, 4vw, 48px);
  --topbar-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--topbar-h) + 12px); }
body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 85% 40%, rgba(138, 59, 224, 0.09), transparent 70%),
    radial-gradient(900px 500px at 10% 75%, rgba(163, 22, 58, 0.08), transparent 70%),
    var(--bg);
  color: var(--text);
  font: 400 15px/1.5 var(--font-body);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { flex-shrink: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px;
  font-family: var(--font-toon); font-size: 17px; letter-spacing: 0.03em;
  color: var(--bone);
  border: 3px solid var(--ink); border-radius: 14px;
  box-shadow: 4px 4px 0 var(--ink);
  text-shadow: 2px 2px 0 var(--ink);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s;
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(2px 2px 0 var(--ink)); }
.btn:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); filter: brightness(1.08); }
.btn:active { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn--primary { background: linear-gradient(180deg, #c97bff 0%, var(--purple-2) 100%); }
.btn--blood { background: linear-gradient(180deg, #ff5a80 0%, #c01a46 100%); }
.btn--ghost { background: rgba(12, 7, 17, 0.72); backdrop-filter: blur(6px); }
.btn--sm { padding: 8px 14px; font-size: 15px; border-radius: 12px; }

.link-btn { background: none; border: 0; padding: 0; color: var(--muted); font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.link-btn:hover { color: var(--crimson); }

/* ---------- Top bar ---------- */
.topbar {
  position: fixed; inset: 0 0 auto; z-index: 50;
  height: var(--topbar-h);
  display: flex; align-items: center; gap: clamp(14px, 3vw, 36px);
  padding: 0 var(--gutter);
  transition: background 0.3s, box-shadow 0.3s, border-color 0.3s;
  border-bottom: 3px solid transparent;
}
.topbar.is-scrolled {
  background: rgba(12, 7, 17, 0.88);
  backdrop-filter: blur(12px);
  border-bottom-color: var(--ink);
  box-shadow: 0 5px 0 rgba(0, 0, 0, 0.35);
}
/* Wordmark stays hidden while the big hero logo is on screen */
.brand {
  font-family: var(--font-goth); font-weight: 800; font-size: 32px; line-height: 1;
  color: var(--bone);
  text-shadow: 2px 2px 0 var(--ink), 0 0 18px rgba(181, 92, 255, 0.4);
  opacity: 0; transform: translateY(-6px);
  transition: opacity 0.3s, transform 0.3s;
  white-space: nowrap;
}
.brand b { font-weight: 800; color: var(--purple); }
.topbar.is-scrolled .brand { opacity: 1; transform: none; }
.nav { display: flex; gap: 6px; }
.nav a {
  font-family: var(--font-toon); font-size: 16px; letter-spacing: 0.03em;
  padding: 6px 12px; border-radius: 10px;
  text-shadow: 2px 2px 0 var(--ink);
  transition: background 0.15s, color 0.15s;
}
.nav a:hover { background: rgba(181, 92, 255, 0.16); color: #fff; }

/* Search (top-right corner) */
.search { position: relative; margin-left: auto; width: min(400px, 38vw); min-width: 0; }
.search-box {
  display: flex; align-items: center; gap: 10px;
  height: 48px; padding: 0 10px 0 14px;
  background: rgba(18, 10, 25, 0.88);
  border: 3px solid var(--ink); border-radius: 999px;
  box-shadow: 4px 4px 0 var(--ink), inset 0 0 0 1px var(--line);
  transition: box-shadow 0.15s, transform 0.15s;
  cursor: text;
}
.search-box:focus-within { box-shadow: 5px 5px 0 var(--ink), inset 0 0 0 1px var(--purple), 0 0 24px rgba(181, 92, 255, 0.35); transform: translate(-1px, -1px); }
.search-ico { width: 20px; height: 20px; fill: none; stroke: var(--purple); stroke-width: 2.6; stroke-linecap: round; }
.search-box input {
  flex: 1; width: 100%; min-width: 0; height: 100%;
  background: none; border: 0; outline: none;
  font-size: 14.5px; color: var(--text);
}
.search-box input::placeholder { color: var(--dim); }
.search-box input::-webkit-search-cancel-button { filter: invert(0.7); }
.search-box kbd {
  font: 600 12px var(--font-body); color: var(--muted);
  border: 2px solid var(--line); border-bottom-width: 3px; border-radius: 7px;
  padding: 1px 7px;
}
.search-results {
  position: absolute; top: calc(100% + 12px); right: 0;
  width: min(460px, calc(100vw - 32px));
  background: var(--panel);
  border: 3px solid var(--ink); border-radius: 18px;
  box-shadow: 7px 7px 0 var(--ink), 0 24px 60px rgba(0, 0, 0, 0.6);
  overflow: hidden;
  animation: pop 0.16s ease-out;
}
.sr-head { padding: 10px 14px 6px; font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--dim); }
.sr-item {
  display: grid; grid-template-columns: 46px 1fr auto; gap: 12px; align-items: center;
  padding: 8px 14px; cursor: pointer;
  border-top: 1px solid rgba(59, 37, 82, 0.5);
}
.sr-item:hover, .sr-item.is-active { background: var(--panel-3); }
.sr-thumb { width: 46px; height: 46px; border-radius: 12px; border: 2px solid var(--ink); object-fit: cover; background: var(--bg-2); }
.sr-text { min-width: 0; }
.sr-name { display: flex; align-items: center; gap: 6px; font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-name .ri { width: 16px; height: 16px; }
.sr-sub { font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-name mark, .sr-sub mark { background: none; color: var(--purple); }
.sr-stock {
  font-family: var(--font-toon); font-size: 12px; letter-spacing: 0.03em;
  padding: 3px 9px; border-radius: 999px;
  background: var(--green); color: var(--ink); border: 2px solid var(--ink);
}
.sr-stock--none { background: transparent; color: var(--dim); border-color: var(--line); }
.sr-all { display: flex; align-items: center; gap: 8px; width: 100%; padding: 12px 14px; background: var(--bg-2); border: 0; border-top: 2px solid var(--ink); color: var(--muted); font-size: 13px; text-align: left; }
.sr-all:hover, .sr-all.is-active { color: var(--bone); background: var(--panel-2); }
.sr-all b { color: var(--purple); }
.sr-empty { padding: 18px 14px; color: var(--muted); font-size: 14px; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate;
  height: 100svh; min-height: 660px;
  overflow: hidden;
  background: var(--ink);
}
.hero-art { position: absolute; inset: 0; }
.slab { position: absolute; inset: 0; }
.slab img {
  position: absolute; top: 0; height: 100%;
  object-fit: cover;
  animation: kenburns 18s ease-out both;
}
.slab--1 { clip-path: url(#cut-1); }
.slab--1 img { left: 0; width: 47%; object-position: 64% 30%; filter: saturate(1.1) brightness(0.82); }
.slab--2 { clip-path: url(#cut-2); }
.slab--2 img { left: 25%; width: 52%; object-position: 50% 26%; filter: brightness(0.7) contrast(1.08); animation-delay: -2s; }
.slab--3 { clip-path: url(#cut-3); }
.slab--3 img { left: 55%; width: 45%; object-position: 50% 22%; filter: saturate(1.05) brightness(0.8); animation-delay: -4s; }

.slab-cuts { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.slab-cuts--tall { display: none; }
.slab-cuts path { fill: none; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.cut-ink { stroke: var(--ink); stroke-width: 18; }
.cut-glow { stroke: var(--purple); stroke-width: 2.5; filter: drop-shadow(0 0 6px var(--purple)); opacity: 0.9; }
.cut-glow--blood { stroke: var(--crimson); filter: drop-shadow(0 0 6px var(--crimson)); }

.hero-shade {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 46% 44% at 50% 47%, rgba(6, 3, 10, 0.78) 0%, rgba(6, 3, 10, 0.35) 55%, transparent 80%),
    linear-gradient(180deg, rgba(6, 3, 10, 0.75) 0%, transparent 16%, transparent 58%, var(--bg) 100%),
    linear-gradient(100deg, rgba(60, 18, 96, 0.35), rgba(12, 7, 17, 0) 45%, rgba(163, 22, 58, 0.25));
}
.hero-dots {
  position: absolute; inset: 0;
  background: radial-gradient(circle, rgba(0, 0, 0, 0.6) 1.2px, transparent 1.7px) 0 0 / 7px 7px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, transparent 35%, #000 100%);
          mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, transparent 35%, #000 100%);
  opacity: 0.55;
}
.hero-grain {
  position: absolute; inset: -50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
  opacity: 0.13; mix-blend-mode: overlay;
  animation: grain 1.2s steps(4) infinite;
  pointer-events: none;
}

.hero-content {
  position: relative; z-index: 2;
  height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: calc(var(--topbar-h) + 10px) 16px 130px;
  text-align: center;
}
.hero-logo {
  width: clamp(260px, min(46vw, 64vh), 740px); height: auto;
  filter: drop-shadow(0 0 36px rgba(181, 92, 255, 0.45)) drop-shadow(0 12px 0 rgba(0, 0, 0, 0.55));
  animation: rise 0.9s cubic-bezier(0.2, 0.9, 0.3, 1.2) both, float 7s ease-in-out 1s infinite;
}
.hero-tag {
  margin: -6px 0 0;
  display: inline-flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: center;
  padding: 8px 20px;
  font-family: var(--font-toon); font-size: clamp(15px, 1.9vw, 22px); letter-spacing: 0.05em;
  color: var(--bone);
  background: linear-gradient(180deg, #c21a46, var(--blood));
  border: 3px solid var(--ink); border-radius: 12px;
  box-shadow: 5px 5px 0 var(--ink);
  text-shadow: 2px 2px 0 var(--ink);
  transform: rotate(-2deg);
  animation: stamp 0.5s 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.4) both;
}
.hero-tag i { font-style: normal; color: var(--ink); text-shadow: none; }
.hero-sub {
  margin: 20px 0 0; max-width: 500px;
  font-size: 16px; color: var(--text);
  text-shadow: 0 2px 10px #000, 0 0 2px #000;
  animation: fade-up 0.6s 0.8s both;
}
.hero-cta { margin-top: 26px; display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; animation: fade-up 0.6s 0.95s both; }

.scroll-cue {
  position: absolute; z-index: 3; left: 50%; bottom: 52px; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-family: var(--font-toon); font-size: 13px; letter-spacing: 0.12em; color: var(--muted);
  text-shadow: 2px 2px 0 var(--ink);
}
.scroll-cue svg { width: 26px; height: 26px; fill: none; stroke: var(--bone); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; animation: bounce 1.6s ease-in-out infinite; filter: drop-shadow(2px 2px 0 var(--ink)); }

/* ---------- Marquee bands ---------- */
.bands { position: relative; z-index: 4; height: 70px; margin-top: -46px; overflow-x: clip; }
.band { position: absolute; left: -5%; right: -5%; top: 10px; height: 54px; border-block: 4px solid var(--ink); }
.band--back { background: var(--purple-deep); transform: rotate(1.6deg); box-shadow: 0 6px 0 rgba(0, 0, 0, 0.35); }
.band--front { background: linear-gradient(180deg, #c21a46, var(--blood)); transform: rotate(-1.8deg); overflow: hidden; box-shadow: 0 8px 0 rgba(0, 0, 0, 0.4); }
.band-track { display: flex; align-items: center; width: max-content; height: 100%; animation: marquee 34s linear infinite; }
.band-track span, .band-track i {
  font-family: var(--font-toon); font-size: 20px; letter-spacing: 0.06em; white-space: nowrap;
  color: var(--bone); text-shadow: 2px 2px 0 var(--ink);
  padding: 0 16px;
}
.band-track i { font-style: normal; color: var(--ink); text-shadow: none; padding: 0; }

/* ---------- Section heads ---------- */
.section-head { text-align: center; margin-bottom: 42px; }
.section-head h2 {
  display: inline-flex; align-items: center; gap: 18px;
  margin: 0;
  font-family: var(--font-goth); font-weight: 800; font-size: clamp(46px, 6vw, 76px); line-height: 1;
  color: var(--bone);
  text-shadow: 3px 3px 0 var(--ink), 0 0 34px rgba(181, 92, 255, 0.45);
}
.section-head p { margin: 12px auto 0; max-width: 560px; color: var(--muted); }
.flourish {
  width: clamp(40px, 9vw, 120px); height: 20px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 20'%3E%3Cpath d='M0 10H86' stroke='%23b55cff' stroke-width='2'/%3E%3Cpath d='M8 10 L18 4 M8 10 L18 16' stroke='%23b55cff' stroke-width='2' fill='none'/%3E%3Ccircle cx='92' cy='10' r='3' fill='%23ff3463'/%3E%3Cpath d='M106 1 L114 10 L106 19 L98 10 Z' fill='%23f6ecd8' stroke='%2306030a' stroke-width='2'/%3E%3C/svg%3E") center / contain no-repeat;
}
.flourish--r { transform: scaleX(-1); }

/* ---------- Market ---------- */
.market { position: relative; max-width: 1480px; margin: 0 auto; padding: 84px var(--gutter) 70px; }
.market-grid { display: grid; grid-template-columns: 272px minmax(0, 1fr); gap: 28px; align-items: start; }

.sidebar {
  position: sticky; top: calc(var(--topbar-h) + 14px);
  padding: 18px 18px 6px;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 3px solid var(--ink); border-radius: 20px;
  box-shadow: 6px 6px 0 var(--ink);
}
.sidebar::before {
  content: '✠';
  position: absolute; top: -17px; left: 50%; transform: translateX(-50%);
  width: 30px; height: 30px; display: grid; place-items: center;
  font-size: 16px; color: var(--bone);
  background: var(--blood); border: 3px solid var(--ink); border-radius: 50%;
}
.sidebar-head { display: flex; align-items: baseline; justify-content: space-between; margin: 4px 0 16px; }
.sidebar-head span { font-family: var(--font-goth); font-weight: 800; font-size: 28px; color: var(--bone); text-shadow: 2px 2px 0 var(--ink); }

.fgroup { margin-bottom: 20px; }
.ftitle {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 10px;
  font-family: var(--font-toon); font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--purple);
}
.ftitle::after { content: ''; flex: 1; height: 2px; background: linear-gradient(90deg, var(--line), transparent); }
.fsel {
  width: 100%;
  padding: 10px 12px;
  background: var(--bg-2);
  border: 2px solid var(--ink); border-radius: 12px;
  box-shadow: inset 0 0 0 1px var(--line);
  font-size: 14px; color: var(--text);
  outline: none;
  transition: box-shadow 0.15s;
}
select.fsel {
  appearance: none; cursor: pointer; padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b55cff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center; background-size: 16px;
}
select.fsel option { background: var(--panel); }
.fsel:focus { box-shadow: inset 0 0 0 1px var(--purple), 0 0 0 3px rgba(181, 92, 255, 0.22); }
.fsel::placeholder { color: var(--dim); }

.rarity-grid { display: grid; gap: 8px; }
.rbtn {
  display: flex; align-items: center; gap: 10px; width: 100%;
  padding: 8px 12px;
  background: var(--bg-2);
  border: 2px solid var(--ink); border-radius: 12px;
  box-shadow: inset 0 0 0 1px var(--line), 3px 3px 0 var(--ink);
  font-size: 14px; color: var(--muted); text-align: left;
  transition: transform 0.12s, box-shadow 0.12s, color 0.12s, background 0.12s;
}
.rbtn:hover { color: var(--text); transform: translate(-1px, -1px); box-shadow: inset 0 0 0 1px var(--purple-2), 4px 4px 0 var(--ink); }
.rbtn:active { transform: translate(2px, 2px); box-shadow: inset 0 0 0 1px var(--purple-2), 1px 1px 0 var(--ink); }
.rbtn.active {
  background: linear-gradient(180deg, rgba(181, 92, 255, 0.3), rgba(138, 59, 224, 0.16));
  box-shadow: inset 0 0 0 1px var(--purple), 3px 3px 0 var(--ink);
  color: var(--bone); font-weight: 600;
}
.rbtn .count { margin-left: auto; font-size: 12px; color: var(--dim); font-weight: 500; }
.rbtn.is-empty:not(.active) { opacity: 0.5; }
.rbtn.active .count { color: var(--purple); }

.pet-icon { width: 24px; height: 24px; border-radius: 50%; background: center / contain no-repeat; filter: drop-shadow(0 0 3px rgba(0, 0, 0, 0.7)); flex-shrink: 0; }
.pet--gust { background-image: url("../assets/icons/gustwalker.webp"); }
.pet--scorch { background-image: url("../assets/icons/scorchpup.webp"); }
.pet--moss { background-image: url("../assets/icons/mosstomper.webp"); }

.ri { display: inline-block; width: 22px; height: 22px; background: center / contain no-repeat; flex-shrink: 0; filter: drop-shadow(0 0 2px rgba(0, 0, 0, 0.6)); }

/* Toolbar */
.toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; min-height: 44px; }
.filters-toggle { display: none; }
.filters-toggle svg { width: 16px; height: 16px; }
.result-count { font-family: var(--font-toon); font-size: 19px; color: var(--bone); text-shadow: 2px 2px 0 var(--ink); }
.result-count b { color: var(--purple); font-weight: 400; }
.active-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.fchip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 6px 4px 11px;
  font-size: 13px; color: var(--text);
  background: var(--panel-3); border: 2px solid var(--ink); border-radius: 999px;
  box-shadow: 2px 2px 0 var(--ink);
}
.fchip button { display: grid; place-items: center; width: 18px; height: 18px; padding: 0; border: 0; border-radius: 50%; background: var(--ink); color: var(--muted); font-size: 12px; line-height: 1; }
.fchip button:hover { background: var(--crimson); color: #fff; }
.sort { width: auto; margin-left: auto; }

/* Cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 26px; }
.card {
  position: relative;
  display: flex; flex-direction: column;
  background: linear-gradient(180deg, var(--panel-2), var(--panel) 60%);
  border: 3px solid var(--ink); border-radius: 22px;
  box-shadow: 6px 6px 0 var(--ink);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  animation: card-in 0.5s cubic-bezier(0.2, 0.9, 0.3, 1.1) both;
  animation-delay: calc(var(--i, 0) * 70ms);
}
.card:hover { transform: translate(-3px, -4px); box-shadow: 9px 10px 0 var(--ink), 0 18px 50px rgba(181, 92, 255, 0.18); }
.card-banner {
  position: relative; height: 176px;
  border-radius: 19px 19px 0 0; overflow: hidden;
  clip-path: polygon(0 0, 100% 0, 100% 78%, 0 100%);
  background: var(--bg-2);
}
.card-banner img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; transition: transform 0.6s ease; }
.card:hover .card-banner img { transform: scale(1.07); }
.card-banner::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(6, 3, 10, 0.45) 0%, transparent 32%, transparent 55%, rgba(25, 14, 34, 0.9) 100%);
}
.pill {
  position: absolute; z-index: 1; top: 12px;
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px;
  font-family: var(--font-toon); font-size: 14px; letter-spacing: 0.03em; color: var(--bone);
  background: rgba(6, 3, 10, 0.78); border: 2px solid var(--ink); border-radius: 10px;
  text-shadow: 1px 1px 0 var(--ink);
}
.pill img { width: 18px; height: 18px; object-fit: contain; }
.pill--id { left: 12px; }
.pill--id small { color: var(--muted); font-size: 11px; }
.pill--server { right: 12px; }
.feature-name {
  position: absolute; z-index: 1; right: 14px; bottom: 44px;
  font-size: 11px; color: rgba(246, 236, 216, 0.75); text-align: right;
  text-shadow: 0 1px 4px #000;
}
.feature-name b { display: block; font-size: 13px; color: var(--bone); }

.card-badges { position: relative; z-index: 2; display: flex; align-items: flex-end; gap: 8px; margin-top: -40px; padding: 0 16px; }
.lvl-coin {
  width: 64px; height: 64px; flex-shrink: 0;
  display: grid; place-content: center; text-align: center;
  font-family: var(--font-toon); line-height: 0.85; color: #fff;
  background: radial-gradient(circle at 34% 28%, #e2b8ff 0%, #9a45e8 45%, #4b167a 100%);
  border: 3px solid var(--ink); border-radius: 50%;
  box-shadow: 3px 3px 0 var(--ink), inset 0 -4px 0 rgba(0, 0, 0, 0.25);
  text-shadow: 2px 2px 0 var(--ink);
}
.lvl-coin b { font-size: 26px; font-weight: 400; }
.lvl-coin small { font-size: 11px; letter-spacing: 0.08em; }
.tag {
  margin-bottom: 4px;
  padding: 4px 10px;
  font-family: var(--font-toon); font-size: 13px; letter-spacing: 0.05em;
  color: var(--ink);
  border: 2px solid var(--ink); border-radius: 8px;
  box-shadow: 2px 2px 0 var(--ink);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.tag-wrap {
  position: relative;
  display: inline-flex;
}
.tag-ico {
  width: 16px;
  height: 16px;
  object-fit: contain;
  vertical-align: middle;
  flex-shrink: 0;
  display: inline-block;
}
.tag--unranked { background: var(--bone); }
.tag--fresh { background: var(--green); }
.tag--ranked { background: #C8AA6E; color: var(--ink); cursor: help; }
.tag--std { background: var(--panel-3); color: var(--text); text-shadow: 1px 1px 0 var(--ink); }

.tag-tooltip {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: #061314;
  border: 1.5px solid #C8AA6E;
  border-radius: 9px;
  color: #E8F5F2;
  font-family: var(--font-body, system-ui, sans-serif);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  padding: 6px 12px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.7);
  pointer-events: none;
  z-index: 100;
}
.tag-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border-width: 5px;
  border-style: solid;
  border-color: #C8AA6E transparent transparent transparent;
}
.tag-wrap:hover .tag-tooltip {
  display: block;
  animation: pop 0.15s ease-out;
}

.card-sticker {
  position: absolute; z-index: 3; top: -14px; right: 22px;
  padding: 5px 12px;
  font-family: var(--font-toon); font-size: 14px; letter-spacing: 0.04em; color: #fff;
  background: var(--crimson); border: 3px solid var(--ink); border-radius: 10px;
  box-shadow: 3px 3px 0 var(--ink);
  text-shadow: 2px 2px 0 var(--ink);
  transform: rotate(6deg);
}

.card-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 16px 12px; }
.stat {
  display: flex; align-items: center; gap: 8px;
  padding: 7px 9px;
  background: var(--bg-2); border: 2px solid var(--ink); border-radius: 12px;
  box-shadow: inset 0 0 0 1px rgba(59, 37, 82, 0.6);
  min-width: 0;
}
.stat img { width: 22px; height: 22px; object-fit: contain; }
.stat div { min-width: 0; line-height: 1.1; }
.stat b { display: block; font-family: var(--font-toon); font-weight: 400; font-size: 15px; letter-spacing: 0.02em; }
.stat small { display: block; font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--dim); white-space: nowrap; }
.stat--be b { color: var(--r-destansi); }
.stat--oe b { color: var(--r-ihtisamli); }
.stat--rp b { color: var(--r-hasmetli); }

.skins-head { display: flex; justify-content: space-between; align-items: center; padding: 0 16px; font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.skins-head .chest { display: inline-flex; align-items: center; gap: 4px; color: var(--bone); letter-spacing: 0.04em; }
.skins-head .chest img { width: 18px; height: 18px; }
.skin-list { display: flex; flex-wrap: wrap; gap: 6px; padding: 10px 16px 16px; }
.skin-chip {
  --c: var(--r-normal);
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 9px 4px 6px;
  font-size: 12.5px; color: var(--text);
  background: color-mix(in srgb, var(--c) 9%, var(--bg-2));
  border: 1.5px solid color-mix(in srgb, var(--c) 40%, var(--ink));
  border-radius: 9px;
  cursor: default;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.skin-chip .ri { width: 16px; height: 16px; }
.skin-chip:hover { background: color-mix(in srgb, var(--c) 22%, var(--bg-2)); border-color: var(--c); transform: translateY(-1px); }
.skin-chip.is-match {
  background: color-mix(in srgb, var(--c) 32%, var(--bg-2));
  border-color: var(--c); color: #fff; font-weight: 600;
  box-shadow: 0 0 14px color-mix(in srgb, var(--c) 55%, transparent);
}
.skin-chip--more { color: var(--purple); border-style: dashed; border-color: var(--purple-2); background: transparent; cursor: pointer; }
.skin-chip--more:hover { color: #fff; background: rgba(181, 92, 255, 0.15); }

.card-foot {
  margin-top: auto;
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px 16px;
  border-top: 2px dashed var(--line);
}
.price { font-family: var(--font-toon); font-size: 32px; line-height: 1; color: var(--bone); text-shadow: 3px 3px 0 var(--ink); white-space: nowrap; }
.price small { font-size: 20px; margin-left: 2px; }
.price s { display: block; margin-bottom: 3px; font-family: var(--font-body); font-size: 12px; color: var(--dim); text-shadow: none; }
.price-old { display: flex; align-items: center; gap: 6px; margin-bottom: 4px; }
.price-old s { margin: 0; }
.price-old em {
  font-style: normal; font-size: 12px; letter-spacing: 0.02em;
  padding: 1px 6px; color: var(--ink); background: var(--r-hasmetli);
  border: 2px solid var(--ink); border-radius: 6px; text-shadow: none;
  transform: rotate(-4deg);
}
.card-foot .actions { margin-left: auto; display: flex; gap: 8px; }
.card-foot .btn { padding: 9px 15px; font-size: 15px; }
.icon-btn { width: 44px; justify-content: center; padding: 0 !important; }
.icon-btn svg { width: 20px; height: 20px; }

.empty {
  grid-column: 1 / -1;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
  padding: 50px 20px;
  text-align: center; color: var(--muted);
  background: var(--panel); border: 3px dashed var(--line); border-radius: 22px;
}
.empty .ghost { font-size: 54px; line-height: 1; animation: float 4s ease-in-out infinite; }
.empty h3 { margin: 0; font-family: var(--font-goth); font-size: 34px; color: var(--bone); }

/* Hover preview for skin chips */
.skin-tip {
  position: fixed; z-index: 80; pointer-events: none;
  width: 220px;
  background: var(--panel); border: 3px solid var(--ink); border-radius: 14px;
  box-shadow: 5px 5px 0 var(--ink);
  overflow: hidden;
  animation: pop 0.12s ease-out;
}
.skin-tip img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; object-position: center 20%; background: var(--bg-2); }
.skin-tip div { display: flex; align-items: center; gap: 6px; padding: 7px 10px; font-size: 12.5px; font-weight: 600; }
.skin-tip .ri { width: 16px; height: 16px; }
.skin-tip span { margin-left: auto; font-weight: 400; color: var(--muted); font-size: 11px; }

/* ---------- Detail dialog ---------- */
.detail {
  width: min(1000px, calc(100vw - 32px)); max-height: calc(100vh - 48px);
  padding: 0;
  color: var(--text);
  background: var(--panel);
  border: 3px solid var(--ink); border-radius: 24px;
  box-shadow: 10px 10px 0 var(--ink);
  overflow: hidden;
}
.detail[open] { display: flex; flex-direction: column; animation: pop 0.2s ease-out; }
.detail::backdrop { background: rgba(6, 3, 10, 0.78); backdrop-filter: blur(5px); }
.detail-hero { position: relative; flex-shrink: 0; height: 210px; }
.detail-hero img { width: 100%; height: 100%; object-fit: cover; object-position: center 22%; }
.detail-hero::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6, 3, 10, 0.3), rgba(25, 14, 34, 0.97)); }
.detail-title { position: absolute; z-index: 1; left: 24px; bottom: 18px; right: 70px; display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; }
.detail-title h3 { margin: 0; font-family: var(--font-goth); font-weight: 800; font-size: 44px; line-height: 1; color: var(--bone); text-shadow: 3px 3px 0 var(--ink); }
.detail-title .tag { margin-bottom: 6px; }
.detail-close {
  position: absolute; z-index: 2; top: 14px; right: 14px;
  width: 42px; height: 42px; display: grid; place-items: center;
  font-size: 20px; color: var(--bone);
  background: var(--blood); border: 3px solid var(--ink); border-radius: 12px;
  box-shadow: 3px 3px 0 var(--ink);
}
.detail-close:hover { transform: rotate(8deg); }
.detail-body { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 22px; padding: 20px 24px 24px; overflow: auto; }
.skin-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(124px, 1fr)); gap: 12px; align-content: start; }
.skin-card {
  --c: var(--r-normal);
  position: relative; aspect-ratio: 308 / 560; margin: 0;
  border: 3px solid var(--ink); border-radius: 14px; overflow: hidden;
  box-shadow: 3px 3px 0 var(--ink), inset 0 0 0 2px var(--c);
  background: var(--bg-2);
}
.skin-card img { width: 100%; height: 100%; object-fit: cover; }
.skin-card figcaption {
  position: absolute; inset: auto 0 0; padding: 26px 8px 8px;
  font-size: 11.5px; font-weight: 600; line-height: 1.25;
  background: linear-gradient(180deg, transparent, rgba(6, 3, 10, 0.95) 45%);
}
.skin-card figcaption span { display: flex; align-items: center; gap: 4px; margin-top: 3px; font-weight: 500; font-size: 10.5px; color: var(--c); }
.skin-card .ri { width: 14px; height: 14px; }
.detail-side { display: flex; flex-direction: column; gap: 14px; }
.info-list { margin: 0; padding: 14px; list-style: none; background: var(--bg-2); border: 2px solid var(--ink); border-radius: 14px; }
.info-list li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; font-size: 13.5px; border-bottom: 1px dashed var(--line); }
.info-list li:last-child { border-bottom: 0; }
.info-list span { color: var(--muted); }
.info-list b { font-weight: 600; text-align: right; }
.perks { margin: 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.perks li::before { content: '✠'; margin-right: 8px; color: var(--purple); }
.detail-side .price { font-size: 38px; }
.detail-side .btn { justify-content: center; }

/* ---------- How it works ---------- */
.how { max-width: 1180px; margin: 0 auto; padding: 40px var(--gutter) 80px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.steps li {
  position: relative;
  padding: 30px 22px 22px;
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 3px solid var(--ink); border-radius: 20px;
  box-shadow: 6px 6px 0 var(--ink);
}
.steps li:nth-child(2) { transform: rotate(0.8deg); }
.steps li:nth-child(3) { transform: rotate(-0.8deg); }
.steps b {
  position: absolute; top: -20px; left: 20px;
  width: 44px; height: 44px; display: grid; place-items: center;
  font-family: var(--font-toon); font-weight: 400; font-size: 22px; color: #fff;
  background: var(--purple-2); border: 3px solid var(--ink); border-radius: 50%;
  box-shadow: 3px 3px 0 var(--ink); text-shadow: 2px 2px 0 var(--ink);
}
.steps h3 { margin: 6px 0 6px; font-family: var(--font-goth); font-weight: 800; font-size: 30px; color: var(--bone); }
.steps p { margin: 0; color: var(--muted); }

/* ---------- Footer ---------- */
.footer { padding: 40px var(--gutter) 50px; text-align: center; color: var(--muted); border-top: 3px solid var(--ink); background: var(--bg-2); }
.footer-logo { width: 150px; margin: 0 auto 14px; filter: drop-shadow(0 0 14px rgba(181, 92, 255, 0.3)); }
.footer p { margin: 4px 0; }
.footer b { color: var(--bone); }
.footer .legal { margin-top: 14px; font-size: 12px; color: var(--dim); }

/* ---------- Toast ---------- */
.toast {
  position: fixed; z-index: 90; left: 50%; bottom: 26px; transform: translateX(-50%) rotate(-1deg);
  padding: 12px 20px;
  font-family: var(--font-toon); font-size: 16px; color: var(--ink);
  background: var(--bone); border: 3px solid var(--ink); border-radius: 14px;
  box-shadow: 5px 5px 0 var(--ink);
  animation: toast-in 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.4);
}

/* ---------- Animations ---------- */
@keyframes kenburns { from { transform: scale(1.12); } to { transform: scale(1); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes rise { from { opacity: 0; transform: translateY(30px) scale(0.92); } to { opacity: 1; transform: none; } }
@keyframes stamp { from { opacity: 0; transform: rotate(-12deg) scale(1.6); } to { opacity: 1; transform: rotate(-2deg) scale(1); } }
@keyframes fade-up { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(6px); } }
@keyframes marquee { to { transform: translateX(-50%); } }
@keyframes grain { 0% { transform: translate(0, 0); } 25% { transform: translate(-3%, 2%); } 50% { transform: translate(2%, -3%); } 75% { transform: translate(-2%, -1%); } 100% { transform: translate(0, 0); } }
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(0.97); } to { opacity: 1; transform: none; } }
@keyframes card-in { from { opacity: 0; transform: translateY(24px) rotate(-1deg); } to { opacity: 1; transform: none; } }
@keyframes toast-in { from { opacity: 0; transform: translateX(-50%) translateY(20px) rotate(-6deg); } to { opacity: 1; transform: translateX(-50%) rotate(-1deg); } }

/* Motion setting: force animations enabled */

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav { display: none; }
}

@media (max-width: 900px) {
  .market-grid { grid-template-columns: 1fr; }
  .filters-toggle { display: inline-flex; }
  .sidebar {
    position: fixed; z-index: 60; top: 0; bottom: 0; left: 0;
    width: min(320px, 88vw); overflow-y: auto;
    border-radius: 0 20px 20px 0; border-left: 0;
    transform: translateX(-105%); transition: transform 0.25s ease;
    padding-top: 26px;
  }
  .sidebar::before { display: none; }
  .sidebar.is-open { transform: none; }
  body.filters-open::after { content: ''; position: fixed; inset: 0; z-index: 55; background: rgba(6, 3, 10, 0.7); }
  .detail-body { grid-template-columns: 1fr; }
  .detail-side { order: -1; }
  .steps { grid-template-columns: 1fr; gap: 30px; }
  .steps li { transform: none !important; }
}

@media (max-width: 720px) {
  :root { --topbar-h: 66px; }
  .brand { font-size: 24px; }
  .search { width: auto; flex: 1; }
  .search-box { height: 44px; }
  .search-box kbd { display: none; }
  .slab--1 { clip-path: url(#cut-1m); }
  .slab--2 { clip-path: url(#cut-2m); }
  .slab--3 { clip-path: url(#cut-3m); }
  .slab--1 img { left: 0; width: 100%; height: 43%; object-position: 58% 25%; }
  .slab--2 img { left: 0; width: 100%; top: 28%; height: 51%; object-position: 50% 28%; }
  .slab--3 img { left: 0; width: 100%; top: 64%; height: 36%; object-position: 50% 20%; }
  .slab-cuts--wide { display: none; }
  .slab-cuts--tall { display: block; }
  .scroll-cue { display: none; }
  .hero-tag { gap: 8px; padding: 6px 12px; font-size: 14px; }
  .hero-sub { font-size: 15px; }
  .cards { grid-template-columns: 1fr; }
  .sort { margin-left: 0; width: 100%; }
  .result-count { margin-right: auto; }
  .card-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
  .stat { padding: 6px; gap: 6px; }
  .stat img { width: 18px; height: 18px; }
  .detail-title h3 { font-size: 34px; }
}
