@font-face {
    font-family: 'Marker';
    src: url('../fonts/PermanentMarker.woff2') format('woff2');
    font-weight: 400;
    font-display: block;
}

@font-face {
    font-family: 'Stencil';
    src: url('../fonts/SairaStencilOne.woff2') format('woff2');
    font-weight: 400;
    font-display: block;
}

@font-face {
    font-family: 'Barlow';
    src: url('../fonts/BarlowCondensed-500.woff2') format('woff2');
    font-weight: 500;
    font-display: block;
}

@font-face {
    font-family: 'Barlow';
    src: url('../fonts/BarlowCondensed-600.woff2') format('woff2');
    font-weight: 600;
    font-display: block;
}

@font-face {
    font-family: 'Barlow';
    src: url('../fonts/BarlowCondensed-700.woff2') format('woff2');
    font-weight: 700 900;
    font-display: block;
}

:root {
    --s: 1;
    --marker: 'Marker', 'Ink Free', 'Segoe Print', cursive;
    --stencil: 'Stencil', Impact, 'Arial Black', sans-serif;
    --type: 'Barlow', 'Bahnschrift', 'Segoe UI', sans-serif;
    --mono: 'Consolas', 'Courier New', monospace;
    --amber: #ffb020;
    --amber-rgb: 255, 176, 32;
    --red: #ff3b30;
    --red-rgb: 255, 59, 48;
    --green: #3fd16b;
    --green-rgb: 63, 209, 107;
    --blue: #4ea1ff;
    --ink: #ebe8de;
    --ink-dim: #9b978b;
    --ink-faint: #5f5c55;
    --site: #0c0d0f;
    --panel: #131417;
    --panel-2: #191b1f;
    --line: #26282d;
    --paper: #eceae1;
    --paper-ink: #141414;
    --noise: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 0.55 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background: transparent;
    font-family: var(--type);
    -webkit-font-smoothing: antialiased;
    user-select: none;
}

button {
    font: inherit;
    color: inherit;
    cursor: pointer;
    border: 0;
    background: none;
}

button:disabled {
    cursor: default;
    opacity: 0.4;
}

input, select, textarea {
    font: inherit;
    user-select: text;
}

.hidden {
    display: none !important;
}

.xr-defs {
    position: absolute;
    width: 0;
    height: 0;
}

.xr-toast {
    padding: 9px 18px;
    background: #111214;
    color: var(--ink);
    font: 600 16px/1.3 var(--type);
    letter-spacing: 0.02em;
    border-left: 5px solid var(--ink-faint);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55);
    transition: opacity 0.4s, transform 0.4s;
}

.xr-toast.t-ok { border-left-color: var(--green); }
.xr-toast.t-err { border-left-color: var(--red); }

.xr-toast.out {
    opacity: 0;
    transform: translateY(8px);
}

.rk {
    display: inline-block;
    padding: 2px 8px 1px;
    border-radius: 3px;
    font: 13px/1.2 var(--stencil);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #111;
    background: #9aa0a6;
    transform: rotate(-2deg);
    box-shadow: 0 2px 0 rgba(0, 0, 0, 0.35);
}

.rk.r2 { background: #3fd16b; }
.rk.r3 { background: #4ea1ff; }
.rk.r4 { background: #b48cff; }
.rk.r5 { background: #ffb020; }

.tag {
    display: inline-block;
    padding: 1px 6px;
    border-radius: 3px;
    font: 700 12px/1.25 var(--type);
    letter-spacing: 0.08em;
    color: #111;
    background: #e6edf3;
    vertical-align: 1px;
}

.av {
    position: relative;
    display: inline-flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 3px;
    overflow: hidden;
    vertical-align: middle;
    background: #1a1d17 center / cover no-repeat;
    box-shadow: 0 0 0 1px var(--ac, #3a3f33);
    color: #8d927f;
    font: 700 11px/1 var(--mono);
}

.av.has b { visibility: hidden; }

.av::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(180deg, rgba(0, 0, 0, 0.16) 0 1px, transparent 1px 3px);
    pointer-events: none;
}

.av.xs { width: 18px; height: 18px; font-size: 8px; border-radius: 2px; }
.av.sm { width: 26px; height: 26px; }
.av.md { width: 36px; height: 36px; font-size: 13px; }
.av.lg { width: 68px; height: 68px; font-size: 22px; }
.av.xl { width: 96px; height: 96px; font-size: 30px; box-shadow: 0 0 0 2px var(--ac, #3a3f33); }
