/* grinditosrs.com
   Taken from the clan badge: black and white, pixel lettering, and the heavy
   rules above and below "GRIND IT". One accent colour, set by the theme. The
   clan chat keeps the game's own parchment, as the one thing in colour. */

/* Fonts are self-hosted (SIL Open Font Licence, see fonts/OFL.txt). */
@font-face { font-family: 'Geist Pixel'; font-weight: 400; font-display: swap; src: url(fonts/geist-pixel-square.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-weight: 400; font-display: swap; src: url(fonts/atkinson-hyperlegible-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-weight: 400; font-style: italic; font-display: swap; src: url(fonts/atkinson-hyperlegible-latin-400-italic.woff2) format('woff2'); }
@font-face { font-family: 'Atkinson Hyperlegible'; font-weight: 700; font-display: swap; src: url(fonts/atkinson-hyperlegible-latin-700-normal.woff2) format('woff2'); }

:root, [data-theme="mono"] {
  --bg: #151515;
  --bg-2: #1f1f1f;
  --bg-3: #2a2a2a;
  --line: #3a3a3a;
  --ink: #f5f5f3;
  --ink-2: #b9b9b6;
  --ink-3: #85857f;
  --accent: #f5f5f3;        /* the badge's white */
  --accent-ink: #111;
  --accent-hover: #ffffff;
  --link: #f5f5f3;
  --gain: #f5f5f3;
  --gold: #ffffff; --silver: #b9b9b6; --bronze: #85857f;
}
[data-theme="rune"], [data-theme="dragon"] {
  --gain: #00ff80;
  --gold: #f5c542; --silver: #c9d1d9; --bronze: #d08a4c;
}
[data-theme="rune"] {
  --accent: #3fb7e6;         /* rune blue */
  --accent-ink: #061820;
  --accent-hover: #6fcbef;
  --link: #6fcbef;
}
[data-theme="dragon"] {
  --accent: #e0412f;         /* dragon red */
  --accent-ink: #fff;
  --accent-hover: #ef5a48;
  --link: #f07d6f;
}
:root {
  --parch: #cdbb8e; --parch-2: #bba878; --wood: #4a3b28;
  --chat-blue: #1d2ea8; --chat-red: #6b0b00;
  --gp-yellow: #ffff00; --gp-white: #ffffff; --gp-green: #00ff80;
  --pvm: #e2493a; --skilling: #3ccf7a; --social: #4f9fe0; --other: #c9a45a;
  --pixel: 'Geist Pixel', ui-monospace, monospace;
  --display: var(--pixel);
  --body: 'Atkinson Hyperlegible', system-ui, sans-serif;
  --measure: 66ch;
  --notch: polygon(4px 0, calc(100% - 4px) 0, 100% 4px, 100% calc(100% - 4px), calc(100% - 4px) 100%, 4px 100%, 0 calc(100% - 4px), 0 4px);
}
/* Plain black and white: OSRS stack colours and event-type colours go grey too */
[data-theme="mono"] {
  --gp-yellow: #f5f5f3; --gp-white: #f5f5f3; --gp-green: #f5f5f3;
  --pvm: #f5f5f3; --skilling: #f5f5f3; --social: #f5f5f3; --other: #f5f5f3;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { font-synthesis-weight: none; scroll-behavior: smooth; }
body { background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 1.0625rem; line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
img { display: block; max-width: 100%; }
.skip { position: absolute; left: -999px; top: 0; background: var(--accent); color: var(--accent-ink); padding: .5rem 1rem; z-index: 99; }
.skip:focus { left: 1rem; }
.cc { font-family: var(--pixel); color: var(--ink); background: var(--bg-3); padding: 0 .3em; white-space: nowrap; }

/* ── Header ── */
.top {
  position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 2rem;
  padding: .6rem clamp(1rem, 4vw, 3rem); background: rgba(21,21,21,.94); backdrop-filter: blur(8px);
  border-bottom: 4px solid var(--ink);
}
.brand { display: flex; align-items: center; gap: .7rem; text-decoration: none; color: var(--ink); }
.brand img { width: 44px; height: 44px; }
.brand span { font-family: var(--display); font-weight: 400; font-size: 1.3rem; letter-spacing: 0; line-height: 1; }
.top nav { display: flex; gap: 1.6rem; margin-left: auto; }
.top nav a { color: var(--ink-2); text-decoration: none; font-weight: 700; font-size: .98rem; padding: .3rem 0; border-bottom: 3px solid transparent; }
.top nav a:hover { color: var(--ink); }
.top nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }

/* ── Buttons: notched, like the badge's stepped letters ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem; text-decoration: none; cursor: pointer;
  font-family: var(--display); font-weight: 400; font-size: 1rem; letter-spacing: 0; color: var(--accent-ink);
  background: var(--accent); padding: .6rem 1.2rem; border: 0; clip-path: var(--notch);
}
.btn:hover { background: var(--accent-hover); color: var(--accent-ink); }
.btn-big { font-size: 1.2rem; padding: .85rem 1.6rem; }
.btn-quiet { background: var(--bg-3); color: var(--ink); }
.btn-quiet:hover { background: var(--line); color: var(--ink); }
.link { font-weight: 700; }

/* ── Hero ── */
.hero {
  display: grid; grid-template-columns: minmax(220px, 380px) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center; max-width: 1180px; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1rem, 4vw, 3rem) clamp(2rem, 4vw, 3rem);
}
.hero-logo { width: 100%; height: auto; filter: drop-shadow(0 18px 40px rgba(0,0,0,.6)); }
.hero h1 {
  font-family: var(--display); font-weight: 400; line-height: .98; letter-spacing: 0;
  font-size: clamp(2.4rem, 5.4vw, 4.4rem); color: var(--ink); text-wrap: balance;
  padding: .35em 0; border-top: 6px solid var(--ink); border-bottom: 6px solid var(--ink);
}
.lede { margin-top: 1.4rem; font-size: 1.2rem; max-width: 36em; }
.lede-2 { margin-top: .6rem; color: var(--ink-2); max-width: 36em; }
.cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.8rem; }

/* ── Bands ── */
.band { max-width: 1180px; margin: 0 auto; padding: clamp(2rem, 4.5vw, 3.2rem) clamp(1rem, 4vw, 3rem); }
.band-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem 1.2rem; margin-bottom: 1.2rem; }
.band-head h2, .prose h2, .hof-side h2 {
  font-family: var(--display); font-weight: 400; font-size: clamp(1.45rem, 2.8vw, 1.95rem); line-height: 1.1; letter-spacing: 0; color: var(--ink);
}
.band-head h2 { padding-bottom: .25rem; border-bottom: 4px solid var(--accent); }
.band-head p { color: var(--ink-2); flex-basis: 100%; max-width: var(--measure); }
.band-head .link { margin-left: auto; }
.empty { color: var(--ink-3); font-style: italic; }

.week-card, .comp, .cal-ev, .hof-side, .empty-big, .ev-card { background: var(--bg-2); border: 2px solid var(--line); }

/* On this week */
.week { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1rem; }
/* Bingo: a 3×3 board when one's on, a face-down card when it's still a secret */
.week-art.bingo-art { display: grid; grid-template: repeat(3, 1fr) / repeat(3, 1fr); gap: 4px; padding: 10px; align-items: stretch; justify-content: stretch; }
.bingo-art i { background: var(--ink); opacity: .85; }
.bingo-art i:nth-child(2n) { opacity: .3; }
.card-back { background: repeating-linear-gradient(45deg, rgba(255,255,255,.07) 0 6px, transparent 6px 12px), #0d0d0d; }
.card-back span { font-family: var(--display); font-weight: 400; font-size: 2.4rem; color: var(--ink-2); }
.teaser { border-style: dashed; }
.teaser-text { color: var(--ink-2); font-size: .98rem; margin-bottom: .2rem; }
.week-card { display: grid; grid-template-columns: 88px 1fr; gap: 1rem; padding: 1rem; align-items: start; }
.week-art { width: 88px; height: 88px; display: flex; align-items: center; justify-content: center; background: var(--bg); border: 2px solid var(--line); overflow: hidden; }
.week-art img { width: 100%; height: 100%; object-fit: cover; }
.week-art img.icon { width: 50px; height: 50px; object-fit: contain; }
.week-card.w-turael .week-art img { object-fit: contain; padding: .5rem; }
.glyph { font-family: var(--display); font-weight: 400; font-size: 2rem; color: var(--ink); }
.week-kind { color: var(--ink-2); font-size: .9rem; }
.week-card h3 { font-family: var(--body); font-weight: 700; font-size: 1.45rem; letter-spacing: -.01em; line-height: 1.1; margin: .1rem 0 .4rem; }
.leaders { list-style: none; counter-reset: ld; margin: .1rem 0 .45rem; display: grid; gap: .1rem; }
.leaders li { counter-increment: ld; display: grid; grid-template-columns: 1.1rem 1fr auto; gap: .45rem; font-size: .95rem; }
.leaders li::before { content: counter(ld); font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink-3); }
.leaders li:first-child::before { color: var(--gold); }
.ld-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ld-gain { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--gain); font-size: .9rem; }
.week-ends { font-size: .92rem; color: var(--ink-2); }

/* Clan chat + biggest drops. The chat is the site's own monochrome now: a
   dark panel, names in white, the rest in grey, and the notable lines marked
   with a white bar, like a highlighted line in game. */
.chat-band { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: clamp(2rem, 4vw, 3.5rem); align-items: start; }
.chatbox { background: #0d0d0d; border: 2px solid var(--line); font-family: var(--pixel); display: flex; flex-direction: column; }
.chat-lines {
  height: 236px; overflow-y: auto; padding: .6rem .8rem .35rem; scrollbar-width: thin; scrollbar-color: var(--line) transparent;
  mask-image: linear-gradient(180deg, transparent 0, #000 1.6rem);
}
.ln { font-size: .93rem; line-height: 1.4; padding: .08rem 0 .08rem .55rem; color: var(--ink-2); word-break: break-word; border-left: 2px solid transparent; }
.ln time { color: var(--ink-3); margin-right: .35rem; font-variant-numeric: tabular-nums; }
.ln time:empty { display: none; }
.ln .tag { color: var(--ink-3); }
.ln .who { color: var(--ink); font-weight: 600; }
.ln.rare { color: var(--ink); border-left-color: var(--ink); background: rgba(255,255,255,.06); }
.ln.quiet { color: var(--ink-3); }
.ln.new { animation: lnIn 1.2s ease-out; }
@keyframes lnIn { from { background-color: rgba(255,255,255,.18); } }
.chat-tabs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 2px; border-top: 2px solid var(--line); background: var(--line); }
.chat-tabs button { font-family: var(--pixel); font-size: .84rem; font-weight: 400; color: var(--ink-2); background: #151515; cursor: pointer; border: 0; padding: .45rem .2rem; }
.chat-tabs button:hover { color: var(--ink); background: #1d1d1d; }
.chat-tabs button[aria-selected="true"] { color: var(--accent-ink); background: var(--accent); }
.chat-sum { margin-top: .6rem; color: var(--ink-3); font-size: .9rem; }

/* Biggest drops: gp coloured like coin stacks in game */
.loot { list-style: none; display: grid; }
.loot li { display: grid; grid-template-columns: 4.6rem 1fr; grid-template-rows: auto auto; column-gap: 1rem; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.loot li:last-child { border-bottom: 0; }
.loot-gp { grid-row: span 2; font-family: var(--display); font-weight: 400; font-size: 1.15rem; color: var(--gp-white); text-shadow: 1px 1px 0 #000; align-self: center; }
.loot-gp.g-yellow { color: var(--gp-yellow); } .loot-gp.g-green { color: var(--gp-green); }
.loot-item { font-weight: 700; line-height: 1.3; }
.loot-who { color: var(--ink-2); font-size: .92rem; }

/* Coming up */
.ev-row { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.ev-card { padding: 1rem 1.1rem; border-top: 4px solid var(--evc, var(--other)); }
.ev-when { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink); font-size: 1.05rem; }
.ev-card h3 { font-size: 1.12rem; line-height: 1.3; margin-top: .3rem; }
.ev-meta { color: var(--ink-2); font-size: .92rem; margin-top: .25rem; }
.ev-type { display: inline-block; font-weight: 700; color: var(--evc, var(--other)); }
.ev-pvm { --evc: var(--pvm); } .ev-skilling { --evc: var(--skilling); } .ev-social { --evc: var(--social); } .ev-other { --evc: var(--other); }
.live { margin-left: .4rem; font-weight: 700; color: #000; background: var(--skilling); padding: 0 .45rem; font-size: .82rem; }

/* Joining */
.join { border-top: 4px solid var(--ink); margin-top: 1.5rem; }
.steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; margin-bottom: 2rem; }
.steps li { counter-increment: step; position: relative; padding-top: 3.2rem; }
.steps li::before {
  content: counter(step); position: absolute; top: 0; left: 0; width: 2.4rem; height: 2.4rem; display: flex; align-items: center; justify-content: center;
  font-family: var(--display); font-weight: 400; font-size: 1.5rem; color: var(--accent-ink); background: var(--accent); clip-path: var(--notch);
}
.steps h3 { font-size: 1.15rem; margin-bottom: .3rem; }
.steps p { color: var(--ink-2); font-size: .98rem; }

/* ── Inner pages ── */
.page-head { max-width: 1180px; margin: 0 auto; padding: clamp(2.5rem, 6vw, 4rem) clamp(1rem, 4vw, 3rem) .5rem; }
.page-head h1 { font-family: var(--display); font-weight: 400; letter-spacing: 0; font-size: clamp(2.2rem, 5.4vw, 3.6rem); line-height: 1; display: inline-block; padding: .25em 0; border-top: 6px solid var(--ink); border-bottom: 6px solid var(--ink); }
.page-head p { margin-top: 1rem; color: var(--ink-2); max-width: var(--measure); font-size: 1.1rem; }
.page-head.lost { min-height: 50vh; }

/* Events */
.cal { list-style: none; display: grid; gap: 1rem; }
.cal-ev { display: grid; grid-template-columns: 10rem 1fr auto; gap: 1.4rem; padding: 1.2rem 1.3rem; border-left: 6px solid var(--evc, var(--other)); }
.cal-when { display: flex; flex-direction: column; }
.cal-day { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; font-size: 1.35rem; line-height: 1.1; }
.cal-time { font-weight: 700; color: var(--ink); font-size: 1.05rem; }
.cal-dur { color: var(--ink-3); font-size: .88rem; }
.cal-body h2 { font-size: 1.35rem; line-height: 1.25; margin: .15rem 0 .5rem; }
.cal-desc { color: var(--ink-2); max-width: var(--measure); display: grid; gap: .5rem; }
.cal-img { width: 140px; height: 100px; object-fit: cover; }
.past { list-style: none; max-width: 900px; }
.past li { display: grid; grid-template-columns: 7rem 6rem 1fr; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.past-title { color: var(--ink); }
.empty-big { padding: 2rem; max-width: 640px; }
.empty-big h2 { font-family: var(--display); font-size: 1.8rem; margin-bottom: .4rem; }
.empty-big p { color: var(--ink-2); margin-bottom: 1.2rem; }

/* Hall of fame */
.hof-switch { max-width: 1180px; margin: 1.6rem auto 0; padding: 0 clamp(1rem, 4vw, 3rem); display: flex; gap: .4rem; }
.hof-switch button {
  font-family: var(--display); font-weight: 400; font-size: 1rem; color: var(--ink-2); background: var(--bg-2); border: 0; cursor: pointer;
  padding: .55rem 1.1rem; clip-path: var(--notch);
}
.hof-switch button[aria-selected="true"] { color: var(--accent-ink); background: var(--accent); }
.hof { max-width: 1180px; margin: 0 auto; padding: 1.6rem clamp(1rem, 4vw, 3rem) 3rem; display: grid; grid-template-columns: 320px 1fr; gap: 2rem; align-items: start; }
.hof[hidden] { display: none; }
.hof-side { padding: 1.3rem; position: sticky; top: 5.5rem; }
.hof-side h2 { font-size: 1.6rem; margin-bottom: .6rem; }
.hof-side h2:not(:first-child) { margin-top: 1.6rem; }
.hint { color: var(--ink-3); font-size: .9rem; margin-bottom: .5rem; }
.wins { list-style: none; }
.wins li { display: flex; justify-content: space-between; padding: .35rem 0; border-bottom: 1px solid var(--line); }
.w-n { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink); }
.records { list-style: none; max-height: 360px; overflow-y: auto; scrollbar-width: thin; }
.records li { display: grid; grid-template-columns: 25px 1fr auto; column-gap: .6rem; align-items: center; padding: .4rem 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
.r-metric { font-weight: 700; }
.r-gain { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--gain); text-align: right; }
.r-icon { grid-column: 1; grid-row: 1 / 3; width: 25px; height: 25px; }
.r-metric { grid-column: 2; }
.r-name { grid-column: 2 / -1; color: var(--ink-2); font-size: .88rem; }
.hof-main { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1rem; }
.comp { padding: 1rem 1.1rem 1.1rem; }
.comp header { display: grid; grid-template-columns: auto 1fr auto; align-items: center; column-gap: .8rem; row-gap: .15rem; margin-bottom: .7rem; }
.c-icon { grid-row: 1 / 3; width: 50px; height: 50px; padding: 4px; box-sizing: content-box; background: var(--bg); border: 2px solid var(--line); }
.c-glyph { display: grid; place-items: center; font-family: var(--display); font-weight: 400; font-size: 1.1rem; color: var(--ink-2); }
.comp h3 { grid-column: 2 / -1; align-self: end; }
.comp header time { grid-column: 2; grid-row: 2; align-self: start; }
.comp header .link { grid-column: 3; grid-row: 2; align-self: start; }
.comp h3 { font-family: var(--body); font-weight: 700; font-size: 1.3rem; letter-spacing: -.01em; line-height: 1; }
.comp time { color: var(--ink-3); font-size: .88rem; }
.comp .link { font-size: .88rem; }
.podium { list-style: none; display: grid; gap: .3rem; }
.podium li { display: grid; grid-template-columns: 1.8rem 1fr auto; gap: .6rem; align-items: center; padding: .3rem .5rem; background: var(--bg); }
.p-place { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; font-size: 1.2rem; text-align: center; }
.p1 .p-place { color: var(--gold); } .p2 .p-place { color: var(--silver); } .p3 .p-place { color: var(--bronze); }
.p1 { box-shadow: inset 3px 0 0 var(--gold); }
.podium .p-gap { background: none; border: 1px dashed var(--line); }
.p-gap .p-name { font-weight: 400; color: var(--ink-3); font-style: italic; }
.p-name { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.p-gain { font-family: var(--body); font-weight: 700; font-variant-numeric: tabular-nums; color: var(--gain); font-size: .92rem; white-space: nowrap; }

/* About */
.prose-wrap { padding-top: 1rem; }
.prose { max-width: var(--measure); }
.prose h2 { margin: 1.8rem 0 .7rem; }
.prose h2:first-child { margin-top: 0; }
.prose p + p { margin-top: .9rem; }
.runs dt { font-weight: 700; font-size: 1.1rem; margin-top: 1.1rem; }
.runs dd { color: var(--ink-2); }
.ranks { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .2rem 2rem; max-width: 1000px; }
.ranks li { display: grid; grid-template-columns: 2.4rem 1fr auto; grid-template-rows: auto auto; column-gap: .9rem; align-items: center; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.gem { grid-column: 1; grid-row: 1 / 3; width: 2.1rem; height: 2.1rem; background: linear-gradient(135deg, color-mix(in srgb, var(--gem) 70%, #fff), var(--gem) 55%, color-mix(in srgb, var(--gem) 55%, #000));
  clip-path: polygon(50% 0, 100% 38%, 82% 100%, 18% 100%, 0 38%); filter: drop-shadow(1px 1px 0 #000); }
.rk-name { grid-column: 2; grid-row: 1; font-family: var(--display); font-weight: 400; font-size: 1.3rem; line-height: 1.1; }
.rk-count { grid-column: 3; grid-row: 1 / 3; color: var(--ink-2); font-size: .92rem; text-align: right; }
.rk-cost { grid-column: 2; grid-row: 2; color: var(--ink-2); font-size: .9rem; }

/* ── Footer ── */
.foot { margin-top: 3rem; border-top: 4px solid var(--ink); background: #0f0f0f; }
.foot-in { max-width: 1180px; margin: 0 auto; padding: 2.2rem clamp(1rem, 4vw, 3rem); display: grid; grid-template-columns: 1fr auto; gap: 1.2rem 2rem; align-items: center; }
.foot-brand { display: flex; gap: 1rem; align-items: center; color: var(--ink-2); }
.foot-brand img { width: 64px; height: 64px; }
.foot-brand strong { color: var(--ink); font-family: var(--display); font-size: 1.3rem; }
.foot-links { list-style: none; display: flex; gap: 1.4rem; flex-wrap: wrap; }
.foot-small { grid-column: 1 / -1; color: var(--ink-3); font-size: .85rem; }

/* ── Small screens ── */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; justify-items: start; }
  .hero-logo { width: min(240px, 60vw); }
  .chat-band { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .hof { grid-template-columns: 1fr; }
  .hof-side { position: static; }
  .cal-ev { grid-template-columns: 1fr; gap: .6rem; }
  .cal-when { flex-direction: row; gap: .8rem; align-items: baseline; flex-wrap: wrap; }
  .cal-img { width: 100%; height: 160px; }
}
@media (max-width: 640px) {
  .top { gap: .8rem; flex-wrap: wrap; }
  .top nav { order: 3; width: 100%; margin: 0; gap: 1.1rem; overflow-x: auto; }
  .btn-join { margin-left: auto; padding: .45rem .8rem; font-size: .92rem; }
  .hero { justify-items: center; text-align: left; }
  .chat-tabs button { font-size: .72rem; }
  .ln { font-size: .86rem; }
  .steps { grid-template-columns: 1fr; }
  .past li { grid-template-columns: 5.5rem 1fr; }
  .past li .ev-type { display: none; }
  .foot-in { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Some skill icons are near-black (Thieving's mask): a faint light edge keeps them visible */
img[src*="/icons/skill/"] { image-rendering: pixelated; filter: drop-shadow(0 0 1px rgba(245,245,243,.55)) drop-shadow(0 0 4px rgba(245,245,243,.12)); }

/* Pets tab */
.pet-total { color: var(--ink-2); margin-bottom: 1.6rem; }
.pet-total b { font-family: var(--display); font-size: 2rem; color: var(--ink); display: block; line-height: 1.1; }
.rare-pets { list-style: none; }
.rare-pets li { display: grid; grid-template-columns: 1fr auto; padding: .4rem 0; border-bottom: 1px solid var(--line); font-size: .95rem; }
.rp-pet { font-weight: 700; }
.rp-n { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; font-size: .88rem; }
.rp-who { grid-column: 1 / -1; color: var(--ink-2); font-size: .88rem; }
.pet-board { list-style: none; display: grid; gap: 4px; }
.pet-board li { display: grid; grid-template-columns: 2.4rem 1fr minmax(0, 14rem) 4rem; align-items: center; gap: .8rem; padding: .55rem .9rem; background: var(--bg-2); }
.pet-board:not(:has(.pb-rare)) li { grid-template-columns: 2.4rem 1fr 4rem; }
.pet-board .pb-head { background: none; padding-top: 0; padding-bottom: .2rem; color: var(--ink-3); font-size: .85rem; }
.pet-board .p-name { font-weight: 700; }
.pb-rare { color: var(--ink-2); font-size: .92rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pb-n { text-align: right; font-variant-numeric: tabular-nums; }
.pb-n b { font-size: 1.15rem; }
.pet-board li.p1 { box-shadow: inset 3px 0 0 var(--gold); }
.pb-foot { margin-top: 1rem; }
@media (max-width: 560px) {
  .pet-board li { grid-template-columns: 2rem 1fr 3rem; }
  .pet-board .pb-rare { display: none; }
}
#hof-pets .hof-main { display: block; }
