/* Aukuro – aukuro.lt. Minecraft-style one-pager. Sky colours come from sky.js (--sky-top/--sky-bot). */
:root {
  --sky-top: #3f7fe0;
  --sky-bot: #9cc8f7;
  --light: 1;            /* 0.2 (night) … 1 (day): hills, clouds */
  --star-a: 0;
  --panel: rgba(14, 14, 22, 0.86);
  --panel-hi: rgba(255, 255, 255, 0.10);
  --panel-lo: rgba(0, 0, 0, 0.55);
  --text: #f4f4f4;
  --muted: #b9bccb;
  --mc-shadow: #3f3f3f;
  --green: #55ff55;
  --gold: #ffc83d;
  --silver: #c9d1d9;
  --bronze: #cd7f32;
  --red: #ff5555;
  --blue: #6f8cff;
  /* Pixel style only where it reads well: VT323 (renders every Lithuanian letter) for headings, nav, buttons, labels
     and numbers, enlarged via the "Aukuro Pixel" face (fonts.css, size-adjust); long text in a readable system sans. */
  --font-head: "Aukuro Pixel", "VT323", ui-monospace, monospace;
  --font-pixel: "Aukuro Pixel", "VT323", ui-monospace, monospace;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "VT323", ui-monospace, monospace;
  --gutter: 16px;
  /* page widths: --page-w = main page, receptai; --page-w-board = the board pages (main.cl-main.zv-main / .rk-main:
     /kova/, /zvejyba/, /sezonai/, /sunys/, /zaidejai/, /rinkimai/). Both grow on wide screens (the breakpoints below);
     reading pages (/naujienos/, svc forms, the vadovas) keep their own widths. */
  --page-w: 1180px;
  --page-w-board: 920px;
  color-scheme: dark;
}
@media (min-width: 1600px) { :root { --page-w: 1400px; --page-w-board: 1280px; } }
@media (min-width: 2000px) { :root { --page-w: 1680px; --page-w-board: 1560px; } }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; color: var(--text); background: #0f1630;
  font: 400 17px/1.55 var(--font-body);
  font-synthesis-weight: none;  /* no smeared fake-bold pixel font */
  overflow-x: hidden;
}
img { image-rendering: pixelated; }
a { color: #9fd3ff; }
code { font-family: var(--font-mono); font-size: 1.15em; background: rgba(0,0,0,.45); padding: 0 6px; border: 1px solid rgba(255,255,255,.12); color: var(--green); white-space: nowrap; }
.muted { color: var(--muted); }
.small { font-size: 15px; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }

/* ------------------------------------------------------------------ sky */
#sky { position: fixed; inset: 0; z-index: -1; overflow: hidden;
  background: linear-gradient(180deg, var(--sky-top) 0%, var(--sky-bot) 78%, var(--sky-bot) 100%); }
#stars { position: absolute; inset: 0; width: 100%; height: 100%; opacity: var(--star-a); }
.celestial { position: absolute; left: 0; top: 0; width: 72px; height: 72px; margin: -36px 0 0 -36px; will-change: transform, opacity; }
.celestial canvas { width: 100%; height: 100%; image-rendering: pixelated; }
#sun canvas { filter: drop-shadow(0 0 18px rgba(255, 230, 120, .85)) drop-shadow(0 0 48px rgba(255, 200, 80, .45)); }
#moon canvas { filter: drop-shadow(0 0 14px rgba(200, 215, 255, .55)); }
#clouds { position: absolute; inset: 0 0 30% 0; filter: brightness(calc(0.5 + var(--light) * 0.5)); }
.cloud { position: absolute; left: 0; height: 40px; background-repeat: no-repeat; background-size: 100% 100%;
  image-rendering: pixelated; opacity: calc(0.22 + var(--light) * 0.6); animation: drift linear infinite; will-change: transform; }
#sky.rain .cloud, #sky.thunder .cloud { opacity: .92; }
#sky:not(.rain):not(.thunder) .cloud.storm { display: none; }
#sky.rain #clouds { filter: brightness(calc(0.25 + var(--light) * 0.4)) saturate(.6); }
#sky.thunder #clouds { filter: brightness(calc(0.18 + var(--light) * 0.3)) saturate(.5); }
@keyframes drift { from { transform: translateX(-30vw); } to { transform: translateX(130vw); } }
.hills { position: absolute; left: 0; right: 0; bottom: 0; background-repeat: repeat-x; background-position: 0 100%;
  image-rendering: pixelated; will-change: transform; }
.hills.far { height: 34vh; filter: brightness(calc(0.22 + var(--light) * 0.6)) saturate(.8); opacity: .9; }
.hills.near { height: 22vh; filter: brightness(calc(0.18 + var(--light) * 0.82)); }
#fx { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
#flash { position: absolute; inset: 0; background: #e8eeff; opacity: 0; pointer-events: none; }

/* ------------------------------------------------------------------ shared UI */
.panel { background: var(--panel); border: 2px solid #000;
  box-shadow: inset 2px 2px 0 var(--panel-hi), inset -2px -2px 0 var(--panel-lo), 0 8px 0 rgba(0,0,0,.28);
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.mc-btn { font: 400 16px var(--font-pixel); color: #fff; text-shadow: 2px 2px 0 var(--mc-shadow); cursor: pointer;
  padding: 10px 16px; background: linear-gradient(#8a8a8a, #6c6c6c); border: 2px solid #000;
  box-shadow: inset 2px 2px 0 #b8b8b8, inset -2px -3px 0 #4a4a4a; transition: transform .08s; }
.mc-btn:hover { background: linear-gradient(#8d9fe0, #6d7fc4); box-shadow: inset 2px 2px 0 #c3ceff, inset -2px -3px 0 #3e4d8f; }
.mc-btn:active { transform: translateY(2px); box-shadow: inset 2px 2px 0 #4a4a4a, inset -2px -2px 0 #9a9a9a; }
.dot { display: inline-block; width: 10px; height: 10px; background: #888; box-shadow: 0 0 0 2px rgba(0,0,0,.5); flex: none; }
[data-state="online"] .dot { background: var(--green); animation: pulse 1.8s ease-out infinite; }
[data-state="offline"] .dot { background: var(--red); }
@keyframes pulse { 0% { box-shadow: 0 0 0 2px rgba(0,0,0,.5), 0 0 0 0 rgba(85,255,85,.7); }
  70% { box-shadow: 0 0 0 2px rgba(0,0,0,.5), 0 0 0 10px rgba(85,255,85,0); }
  100% { box-shadow: 0 0 0 2px rgba(0,0,0,.5), 0 0 0 0 rgba(85,255,85,0); } }
.badge { font: 600 14px var(--font-head); padding: 4px 8px; background: rgba(0,0,0,.45); border: 2px solid rgba(255,255,255,.18); white-space: nowrap; }

/* ------------------------------------------------------------------ top bar */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 20px;
  padding: 10px max(var(--gutter), env(safe-area-inset-left)); background: rgba(8, 8, 14, .72);
  border-bottom: 2px solid #000; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font: 400 17px var(--font-pixel);
  text-shadow: 2px 2px 0 var(--mc-shadow); white-space: nowrap; }
.online-pill { display: inline-flex; align-items: center; gap: 8px; font: 600 15px var(--font-head); padding: 6px 10px;
  background: rgba(0,0,0,.5); border: 2px solid rgba(255,255,255,.15); white-space: nowrap; }

/* ------------------------------------------------------------------ hero */
main { width: min(var(--page-w), 100%); margin: 0 auto; padding: 0 var(--gutter) 64px; }
main.cl-main.zv-main, main.cl-main.rk-main { width: min(var(--page-w-board), 100%); }
.hero { text-align: center; padding: clamp(44px, 9vh, 96px) 0 40px; }
.kicker { display: inline-block; font: 400 15px var(--font-pixel); letter-spacing: 2px; color: #ffff55; margin: 0 0 12px; padding: 2px 8px;
  text-shadow: 2px 2px 0 #3f3f15; background: rgba(0,0,0,.4); }
/* Aukuro logo: pixel art from amatai-pack tools/brand.py (1x PNGs, numbers from aukuro-logo.json: logo 129 x 30,
   flame box x 6, y 0, 15 x 13, 6 frames). Shown only at whole multiples (--k) so every texel stays a crisp square;
   the flame is a sprite strip over the logo drawn without it. */
.logo { margin: 4px 0 0; line-height: 0; }
.logo-art { --k: 4; position: relative; display: inline-block; width: calc(129px * var(--k)); height: calc(30px * var(--k));
  filter: drop-shadow(0 calc(1px * var(--k)) 0 rgba(0, 0, 0, .35)); }
.logo-art img { display: block; width: 100%; height: 100%; }
.logo-flame { position: absolute; left: calc(6px * var(--k)); top: 0; width: calc(15px * var(--k)); height: calc(13px * var(--k));
  background: url(/assets/img/brand/aukuro-flame.png) 0 0 / calc(90px * var(--k)) 100% no-repeat; image-rendering: pixelated;
  animation: flame 1.5s steps(6, jump-none) infinite; }
@keyframes flame { from { background-position: 0 0; } to { background-position: 100% 0; } }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.brand-logo { display: block; width: 129px; height: 30px; }
.brand-icon { display: none; width: 32px; height: 32px; }
.tagline { display: block; width: fit-content; font-size: clamp(18px, 2.4vw, 22px); margin: 18px auto 26px; max-width: 760px; padding: 4px 14px;
  background: rgba(0,0,0,.38); text-shadow: 2px 2px 0 #000; }
.join { display: inline-block; text-align: left; padding: 16px 18px; max-width: 100%; }
.join-label { display: block; font: 600 14px var(--font-head); color: var(--muted); margin-bottom: 8px; }
.join-row { display: flex; gap: 10px; align-items: stretch; position: relative; flex-wrap: wrap; }
.address { font: 400 34px/1 var(--font-mono); color: var(--green); background: #000; border: 2px solid #5a5a5a;
  box-shadow: inset 2px 2px 0 #222; padding: 8px 14px; width: 12.2ch; min-width: 0; flex: 1 1 auto; text-shadow: 0 0 10px rgba(85,255,85,.35); }
.copied { position: absolute; right: 0; top: -38px; font: 600 15px var(--font-head); color: #ffff55; background: #000;
  border: 2px solid #ffff55; padding: 4px 8px; opacity: 0; transform: translateY(8px); pointer-events: none; transition: opacity .2s, transform .2s; }
.copied.show { opacity: 1; transform: translateY(0); animation: pop .35s; }
@keyframes pop { 0% { transform: translateY(8px) scale(.8); } 60% { transform: translateY(-2px) scale(1.08); } 100% { transform: none; } }
.join-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 12px; }
.status-line { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.world-caption { display: inline-flex; align-items: center; gap: 10px; margin: 20px auto 0; padding: 6px 12px; font-size: 16px;
  background: rgba(0,0,0,.45); border: 2px solid rgba(255,255,255,.12); text-shadow: 1px 1px 0 #000; }
.wc-icon { width: 16px; height: 16px; display: inline-block; }
/* server down: the site shows the plugin's offline copy (/snapshot/) */
.offline-banner { display: inline-flex; align-items: center; gap: 10px; margin: 20px auto 0; padding: 8px 14px; max-width: 100%;
  font: 600 17px var(--font-head); color: #ffe9a8; background: rgba(36, 22, 0, .78); border: 2px solid rgba(255, 200, 61, .55);
  text-shadow: 1px 1px 0 #000; text-align: left; }
.ob-dot { width: 10px; height: 10px; flex: none; background: var(--gold); box-shadow: 0 0 6px var(--gold); }
.pf-snapshot { margin: 0 0 14px; padding: 6px 10px; font-size: 15px; color: #ffe9a8; background: rgba(255, 200, 61, .10);
  border-left: 3px solid var(--gold); }

/* ------------------------------------------------------------------ sections */
.section { padding: 22px clamp(14px, 3vw, 28px) 26px; margin-top: 26px; }
.section-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.section h2 { margin: 0; font: 600 clamp(24px, 3.4vw, 32px)/1.15 var(--font-head); color: #fff; text-shadow: 3px 3px 0 var(--mc-shadow); letter-spacing: .5px; }
.section h3, .sub { font: 600 19px var(--font-head); color: #ffff55; text-shadow: 2px 2px 0 #3f3f15; margin: 22px 0 12px; }
.lead { margin: 0 0 18px; color: #dfe2ee; max-width: 760px; }
.count-chip, .season-chip { font: 600 15px var(--font-head); padding: 4px 10px; background: rgba(85,255,85,.14); color: var(--green); border: 2px solid rgba(85,255,85,.45); }
.season-chip { background: rgba(255,200,61,.12); color: var(--gold); border-color: rgba(255,200,61,.5); }
.columns { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 26px; align-items: start; }
.columns > .section { margin-top: 0; }

/* ------------------------------------------------------------------ player cards */
.player-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 16px; }
.pcard { position: relative; display: flex; flex-direction: column; align-items: center; padding: 12px 8px 12px;
  background: linear-gradient(180deg, rgba(255,255,255,.05), rgba(0,0,0,.25)); border: 2px solid #000;
  box-shadow: inset 2px 2px 0 rgba(255,255,255,.08), inset -2px -2px 0 rgba(0,0,0,.5); cursor: pointer;
  transition: transform .15s, box-shadow .15s; animation: card-in .45s both; color: inherit; font: inherit; text-align: center; }
.pcard::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--vc, #777); }
.pcard:hover, .pcard:focus-visible { transform: translateY(-4px); box-shadow: inset 2px 2px 0 rgba(255,255,255,.12), inset -2px -2px 0 rgba(0,0,0,.5), 0 10px 0 rgba(0,0,0,.3); }
@keyframes card-in { from { opacity: 0; transform: translateY(12px) scale(.97); } to { opacity: 1; transform: none; } }
.pcard.winner { box-shadow: inset 2px 2px 0 rgba(255,255,255,.08), 0 0 0 2px var(--gold), 0 0 22px rgba(255,200,61,.45); animation: card-in .45s both, glow 2.8s ease-in-out infinite; }
@keyframes glow { 50% { box-shadow: inset 2px 2px 0 rgba(255,255,255,.08), 0 0 0 2px #ffe08a, 0 0 34px rgba(255,200,61,.75); } }
.winner-ribbon { position: absolute; top: -13px; right: -6px; font: 600 12px var(--font-head); color: #2b1a00; background: var(--gold);
  padding: 3px 6px; border: 2px solid #000; box-shadow: 2px 2px 0 rgba(0,0,0,.4); transform: rotate(4deg); z-index: 2; }
.nametag { display: flex; flex-direction: column; align-items: center; gap: 4px; min-height: 52px; z-index: 1; max-width: 100%; }
.tag-line { display: inline-flex; align-items: center; gap: 4px; background: rgba(0,0,0,.42); padding: 2px 6px 3px; max-width: 100%; }
.tag-line img { width: 18px; height: 18px; flex: none; }
.pname { font-weight: 600; font-size: 18px; line-height: 1.2; color: #fff; text-shadow: 2px 2px 0 var(--mc-shadow); min-width: 0; overflow-wrap: anywhere; text-align: center; }
.staff { font-weight: 700; text-shadow: 2px 2px 0 rgba(0,0,0,.6); }
.staff.admin { color: var(--red); }
.staff.moderatorius { color: var(--blue); }
.stage { position: relative; width: 150px; height: 200px; display: grid; place-items: center; }
.stage canvas.viewer { width: 150px; height: 200px; }
.stage .head2d { width: 72px; height: 72px; image-rendering: pixelated; box-shadow: 0 6px 0 rgba(0,0,0,.35); }
.stage::after { content: ""; position: absolute; bottom: 4px; width: 70px; height: 10px; background: rgba(0,0,0,.35); border-radius: 50%; filter: blur(2px); }
.pfoot { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 15px; width: 100%; }
.village-chip { font-weight: 600; text-shadow: 1px 1px 0 #000; }
.prof-badge { display: inline-flex; align-items: center; gap: 4px; }
.prof-badge img { width: 22px; height: 22px; }
.stars-line { color: var(--gold); letter-spacing: 1px; text-shadow: 1px 1px 0 #6b4a00; font-size: 14px; }
.titles-count { font-size: 13px; color: var(--muted); }

/* title plaques */
.plaque { display: inline-block; max-width: 100%; padding: 2px 8px 3px; font: 600 15px/1.3 var(--font-head); letter-spacing: .3px;
  border: 2px solid var(--tc, var(--bronze)); background: linear-gradient(180deg, rgba(0,0,0,.75), rgba(20,10,30,.9));
  color: var(--tc, var(--bronze)); text-shadow: 1px 1px 0 #000; overflow-wrap: anywhere;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.6); position: relative; }
.plaque.tier-silver { --tc: var(--silver); background: linear-gradient(180deg, rgba(40,46,56,.9), rgba(12,14,20,.95)); }
.plaque.tier-gold { --tc: var(--gold); background: linear-gradient(180deg, rgba(60,40,0,.92), rgba(24,14,0,.95));
  box-shadow: 0 0 10px rgba(255,200,61,.45), inset 0 0 0 1px rgba(0,0,0,.6); }
.plaque.tier-gold .pl-text, .plaque.tier-silver .pl-text {
  background: linear-gradient(100deg, var(--tc) 0%, var(--tc) 40%, #fff 50%, var(--tc) 60%, var(--tc) 100%);
  background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none;
  animation: shimmer 3.2s linear infinite; }
.plaque.tier-silver .pl-text { animation-duration: 5s; }
@keyframes shimmer { from { background-position: 120% 0; } to { background-position: -120% 0; } }
.plaque.locked { --tc: #555; color: #666; background: repeating-linear-gradient(45deg, #151515 0 6px, #1c1c1c 6px 12px); }

/* recently seen */
.recent-row { display: flex; flex-wrap: wrap; gap: 10px; }
.rchip { display: inline-flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; background: rgba(0,0,0,.35);
  border: 2px solid #000; border-left: 4px solid var(--vc, #666); cursor: pointer; color: inherit; font: inherit; text-align: left; }
.rchip:hover { background: rgba(255,255,255,.08); }
.rchip canvas { width: 32px; height: 32px; image-rendering: pixelated; }
.rchip .rname { font-weight: 600; line-height: 1.1; }
.rchip .rwhen { display: block; font-size: 13px; color: var(--muted); }

.empty { display: flex; align-items: center; gap: 18px; padding: 18px; background: rgba(0,0,0,.28); border: 2px dashed rgba(255,255,255,.18); }
.empty p { margin: 0; }
.empty-art { width: 64px; height: 64px; flex: none; background: url("../img/skins/steve.png"); background-size: 512px 512px;
  background-position: -64px -64px; image-rendering: pixelated; animation: bob 3s ease-in-out infinite; box-shadow: 0 6px 0 rgba(0,0,0,.35); }

/* ------------------------------------------------------------------ feed */
.feed { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; max-height: 640px; overflow: auto; }
.feed li { display: grid; grid-template-columns: 26px 1fr; gap: 10px; align-items: start; padding: 8px 10px;
  background: rgba(0,0,0,.32); border-left: 4px solid var(--fc, #555); }
.feed li.new { animation: slide-in .6s cubic-bezier(.2,.9,.3,1.2) both; }
@keyframes slide-in { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
.feed .ficon { width: 24px; height: 24px; display: grid; place-items: center; font: 600 20px var(--font-head); color: var(--gold); }
.feed .ficon img { width: 24px; height: 24px; }
.feed .ftext { font-size: 16px; line-height: 1.3; }
.feed .ftext b { color: #fff; }
.feed .fwhen { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }

/* ------------------------------------------------------------------ villages */
.village-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.vcard { position: relative; display: grid; grid-template-columns: 64px 1fr; gap: 14px; padding: 14px; background: rgba(0,0,0,.3);
  border: 2px solid #000; box-shadow: inset 2px 2px 0 rgba(255,255,255,.07); animation: card-in .5s both; }
/* biome strip (only when the API sends villages[].biomeGroup): sky in the village colour + pixel landscape layer */
.vscene { grid-column: 1 / -1; position: relative; height: 72px; margin: -14px -14px 0; border-bottom: 2px solid #000;
  background-image: var(--biome), linear-gradient(180deg, color-mix(in srgb, var(--vc) 38%, #0c0b16) 0%,
    color-mix(in srgb, var(--vc) 55%, #fff 18%) 100%);
  background-repeat: repeat-x, no-repeat; background-position: left bottom, 0 0; background-size: 480px 96px, 100% 100%;
  image-rendering: pixelated; }
.vbiome { position: absolute; top: 6px; right: 8px; padding: 1px 8px; font: 600 13px/1.4 var(--font-head); color: #fff;
  background: rgba(0,0,0,.45); border: 2px solid #000; text-shadow: 1px 1px 0 #000; }
.vbiome-line { font-size: 15px; color: var(--muted); margin-top: -4px; }
.vbanner { position: relative; width: 64px; height: 112px; background: var(--vc);
  clip-path: polygon(0 0, 100% 0, 100% 100%, 75% 88%, 50% 100%, 25% 88%, 0 100%);
  box-shadow: inset 0 -12px 0 rgba(0,0,0,.18); display: grid; place-items: start center; padding-top: 18px;
  transform-origin: top center; animation: sway 5s ease-in-out infinite; }
.vbanner::before { content: ""; position: absolute; left: -6px; right: -6px; top: -6px; height: 8px; background: #6b4a2b; box-shadow: inset 0 -2px 0 #3d2a17; }
.vbanner img { width: 36px; height: 36px; filter: drop-shadow(2px 2px 0 rgba(0,0,0,.35)); }
@keyframes sway { 0%, 100% { transform: skewX(0deg); } 50% { transform: skewX(-2.5deg); } }
.vcard h3.vname { font: 600 21px/1.15 var(--font-head); color: #fff; text-shadow: 2px 2px 0 var(--mc-shadow); margin: 0 0 2px; overflow-wrap: anywhere; }
.vage { font-size: 15px; color: var(--muted); margin-bottom: 8px; }
.track { display: grid; grid-template-columns: repeat(5, 1fr); gap: 4px; margin-bottom: 10px; }
.track span { height: 16px; background: rgba(255,255,255,.08); border: 2px solid #000; position: relative; font: 600 11px/12px var(--font-head); color: rgba(255,255,255,.55); text-align: center; }
.track span.on { background: var(--vc); color: rgba(0,0,0,.6); box-shadow: inset 0 -3px 0 rgba(0,0,0,.25), inset 0 2px 0 rgba(255,255,255,.3); }
.track span.locked { background: repeating-linear-gradient(45deg, #222 0 4px, #2e2e2e 4px 8px); color: #666; }
.vstats { display: flex; flex-wrap: wrap; gap: 2px 14px; font-size: 15px; }
.vstats b { color: #fff; }
.season-bar { flex: 1 0 100%; margin-top: 8px; }
.season-bar .bar { height: 12px; background: rgba(255,255,255,.08); border: 2px solid #000; overflow: hidden; }
.season-bar .bar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--vc), #fff8); transition: width 1.2s cubic-bezier(.2,.8,.2,1); }
.season-bar .lbl { display: flex; justify-content: space-between; font-size: 14px; color: var(--muted); margin-bottom: 3px; }
.rank1 { color: var(--gold); }

/* ------------------------------------------------------------------ records */
.record-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 18px; }
.rcard { padding: 14px; background: rgba(0,0,0,.3); border: 2px solid #000; box-shadow: inset 2px 2px 0 rgba(255,255,255,.07); }
.rcard h3 { margin: 0 0 12px; font: 600 18px var(--font-head); color: #ffff55; text-shadow: 2px 2px 0 #3f3f15; }
.podium { display: grid; grid-template-columns: 1fr 1fr 1fr; align-items: end; gap: 6px; min-height: 170px; }
.pod { display: flex; flex-direction: column; align-items: center; gap: 4px; cursor: pointer; background: none; border: 0; color: inherit; font: inherit; padding: 0; }
.pod canvas { width: 44px; height: 44px; image-rendering: pixelated; box-shadow: 0 4px 0 rgba(0,0,0,.35); }
.pod .pn { font-weight: 600; font-size: 14px; line-height: 1.2; max-width: 100%; text-align: center; overflow-wrap: anywhere; }
.pod .pv { font-size: 13px; color: var(--muted); }
.pod .block { width: 100%; display: grid; place-items: center; font: 400 20px var(--font-pixel); color: rgba(0,0,0,.55);
  border: 2px solid #000; box-shadow: inset 3px 3px 0 rgba(255,255,255,.45), inset -3px -3px 0 rgba(0,0,0,.25); }
.pod.p1 .block { height: 74px; background: #f5c542; }
.pod.p2 .block { height: 52px; background: #c9ced6; }
.pod.p3 .block { height: 36px; background: #c77b45; }
.pod.p1 canvas { width: 52px; height: 52px; animation: bob 3s ease-in-out infinite; }
.pod.empty-slot { opacity: .35; cursor: default; }
.rest { list-style: none; margin: 10px 0 0; padding: 0; font-size: 15px; }
.rest li { display: flex; justify-content: space-between; gap: 10px; padding: 3px 4px; border-top: 1px solid rgba(255,255,255,.07); cursor: pointer; }
.rest li span:first-child { color: var(--muted); }

/* ------------------------------------------------------------------ how to join */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.steps li { display: grid; grid-template-columns: 42px 1fr; gap: 14px; align-items: center; padding: 10px 12px; background: rgba(0,0,0,.28); border: 2px solid #000; }
.step-n { width: 42px; height: 42px; display: grid; place-items: center; font: 400 20px var(--font-pixel); color: #fff;
  background: #8b8b8b; border: 2px solid #000; box-shadow: inset 2px 2px 0 #c6c6c6, inset -2px -2px 0 #555; text-shadow: 2px 2px 0 #3f3f3f; }
.howto { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cmds, .rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cmds li { display: grid; grid-template-columns: 110px 1fr; gap: 10px; align-items: baseline; }
.rules li { padding-left: 22px; position: relative; }
.rules li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 9px; height: 9px; background: var(--green); box-shadow: 2px 2px 0 #1d5a1d; }
.prof-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.prof-card { display: flex; gap: 12px; align-items: center; padding: 12px; background: rgba(0,0,0,.28); border: 2px solid #000; transition: transform .15s; }
.prof-card:hover { transform: translateY(-3px); }
.prof-card img { flex: none; filter: drop-shadow(2px 3px 0 rgba(0,0,0,.4)); }
.prof-card strong { display: block; font: 600 19px var(--font-head); color: #fff; }
.prof-card span { font-size: 15px; color: #d6d9e4; }

/* ------------------------------------------------------------------ footer */
.footer { margin-top: 30px; }
.ground { height: 40px; background:
  linear-gradient(180deg, #6aa84f 0 10px, #4f8a37 10px 14px, transparent 14px),
  repeating-linear-gradient(90deg, #866043 0 16px, #7a5536 16px 32px);
  background-color: #7a5536; border-top: 2px solid #000; }
.footer-inner { background: #4a3322; padding: 16px var(--gutter) 22px; display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: center; align-items: center;
  border-top: 2px solid #2c1d12; text-shadow: 1px 1px 0 #000; }

/* ------------------------------------------------------------------ profile modal */
dialog.profile { width: min(980px, calc(100% - 24px)); max-height: calc(100vh - 32px); padding: 0; color: var(--text);
  background: #12101c; border: 2px solid #000; box-shadow: inset 0 0 0 2px #2b0f5c, inset 0 0 0 4px #160832, 0 20px 60px rgba(0,0,0,.6); overflow: auto; }
dialog.profile::backdrop { background: rgba(4, 4, 10, .72); backdrop-filter: blur(3px); }
dialog.profile[open] { animation: modal-in .28s cubic-bezier(.2,.9,.3,1.1); }
@keyframes modal-in { from { opacity: 0; transform: translateY(18px) scale(.97); } to { opacity: 1; transform: none; } }
.profile .close { position: sticky; float: right; top: 10px; right: 10px; margin: 10px 10px 0 0; z-index: 3; padding: 6px 12px; }
.profile-body { display: grid; grid-template-columns: 300px 1fr; gap: 22px; padding: 22px; }
.pf-side { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.pf-stage { width: 260px; height: 340px; position: relative; background: radial-gradient(ellipse at 50% 85%, rgba(255,255,255,.08), transparent 60%); }
.pf-stage canvas { width: 260px; height: 340px; }
.pf-name { font: 600 30px/1.1 var(--font-head); color: #fff; text-shadow: 3px 3px 0 var(--mc-shadow); margin: 0; overflow-wrap: anywhere; }
.pf-online { font-size: 15px; color: var(--muted); display: inline-flex; gap: 8px; align-items: center; }
.pf-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 8px; background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.12); font-size: 15px; }
.chip img { width: 20px; height: 20px; }
.lvlbar { width: 100%; }
.lvlbar .bar { height: 12px; border: 2px solid #000; background: #222; }
.lvlbar .bar i { display: block; height: 100%; background: linear-gradient(90deg, #4fd14f, #b8ff6a); }
.lvlbar .lbl { font-size: 14px; color: var(--muted); display: flex; justify-content: space-between; }
.pf-main h3 { font: 600 19px var(--font-head); color: #ffff55; margin: 4px 0 10px; text-shadow: 2px 2px 0 #3f3f15; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 20px; }
.stat { padding: 10px; background: rgba(255,255,255,.04); border: 2px solid #000; box-shadow: inset 2px 2px 0 rgba(255,255,255,.06); }
.stat .sv { font: 600 24px/1.1 var(--font-head); color: #fff; text-shadow: 2px 2px 0 var(--mc-shadow); display: block; overflow-wrap: anywhere; }
.stat .sn { display: block; font-size: 14px; color: var(--muted); }
.stat .sr { display: inline-block; margin-top: 4px; font: 600 13px var(--font-head); padding: 2px 6px; background: rgba(255,255,255,.08); color: #ddd; }
.stat .sr.r1 { background: var(--gold); color: #2b1a00; }
.stat .sr.r2 { background: var(--silver); color: #1d2228; }
.stat .sr.r3 { background: var(--bronze); color: #231000; }
.title-wall { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.title-wall .plaque { font-size: 15px; padding: 4px 10px; }
.title-wall .plaque.worn::after { content: "✔"; margin-left: 6px; color: var(--green); -webkit-text-fill-color: var(--green); }
.locked-note { font-size: 14px; color: var(--muted); margin: 0 0 18px; }
.books { display: grid; gap: 8px; margin-bottom: 18px; }
.book .lbl { display: flex; justify-content: space-between; font-size: 15px; }
.book .bar { height: 12px; border: 2px solid #000; background: #222; }
.book .bar i { display: block; height: 100%; background: linear-gradient(90deg, #7a4dd8, #c79bff); }
.fish-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 6px; margin-bottom: 18px; }
.fish { display: grid; grid-template-columns: 32px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 8px; align-items: center;
  padding: 6px 8px; background: rgba(255,255,255,.04); border: 2px solid #000; border-left: 4px solid var(--rc, #aaa); }
.fish img, .fish .fish-q { grid-row: span 2; width: 32px; height: 32px; }
.fish .fish-q { display: grid; place-items: center; font: 600 20px var(--font-head); color: var(--muted); }
.fish .fn { min-width: 0; font-size: 15px; line-height: 1.2; color: var(--rc, #fff); overflow-wrap: anywhere; }
.fish .fs { min-width: 0; font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.fish.missing { border-left-color: #333; }
.fish.missing img { filter: brightness(0.12) saturate(0); }
.fish.missing .fn { color: var(--muted); }
.pf-feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 15px; }
.pf-feed li { padding: 6px 8px; background: rgba(0,0,0,.3); border-left: 4px solid var(--fc, #555); }
.loading { padding: 60px; text-align: center; color: var(--muted); }

/* ------------------------------------------------------------------ responsive */
@media (max-width: 1020px) {
  .columns { grid-template-columns: 1fr; }
  .feed { max-height: 360px; }
  .prof-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 760px) {
  .logo-art { --k: 3; }
  .profile-body { grid-template-columns: 1fr; padding: 16px; }
  .pf-stage, .pf-stage canvas { width: 220px; height: 280px; }
  .howto { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  body { font-size: 17px; }
  .logo-art { --k: 2; }
  .kicker { font-size: 12px; letter-spacing: 1px; }
  .player-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stage, .stage canvas.viewer { width: 120px; height: 160px; }
  .pname { font-size: 15px; }
  .tag-line { gap: 3px; padding: 2px 4px; }
  .tag-line img { width: 14px; height: 14px; }
  .tag-line img.lvl { display: none; }
  .pcard { padding: 12px 4px; }
  .address { font-size: 28px; width: 100%; }
  .join { display: block; }
  .join-row .copy { flex: 1; }
  .prof-grid { grid-template-columns: 1fr; }
  .cmds li { grid-template-columns: 1fr; gap: 0; }
  .record-grid, .village-grid { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
}

/* ------------------------------------------------------------------ reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .cloud { animation: none !important; }
  .plaque .pl-text { animation: none !important; }
}

/* ---- cosmetics: chat badge before the name ([ženkliukas] [vardas]) ---- */
.tag-line img.cbadge, .pf-name img.cbadge { image-rendering: pixelated; width: 18px; height: 18px; }
.pf-name .pname { font: inherit; text-shadow: inherit; }
.chip.cosm { color: #d9c4ff; }

/* ---- guide link in the top bar (one-pager and /vadovas/) ---- */
.guide-cta { display: inline-flex; align-items: center; gap: 8px; flex: none; padding: 6px 12px; text-decoration: none;
  font: 600 16px var(--font-head); color: #2b1a00; text-shadow: 1px 1px 0 rgba(255,255,255,.35); background: linear-gradient(#ffd95e, #f0a92a);
  border: 2px solid #000; box-shadow: inset 2px 2px 0 #fff2b8, inset -2px -3px 0 #a86a10; transition: transform .08s; }
.guide-cta:hover { background: linear-gradient(#ffe68a, #ffbe45); }
.guide-cta:active { transform: translateY(2px); }
.guide-cta img { image-rendering: pixelated; }
.guide-cta.active { outline: 2px solid #ffff55; outline-offset: 2px; }
a.prof-card { color: inherit; text-decoration: none; }
a.prof-card:hover { border-color: #ffff55; }
.sub-link { font: 600 15px var(--font-head); color: #9fd3ff; margin-left: 10px; text-shadow: none; }
.cmd-link { font: 600 17px var(--font-head); color: #ffd95e; }
@media (max-width: 760px) {
  .guide-cta { margin-left: auto; }
  .guide-cta + .online-pill { margin-left: 0; }
}
@media (max-width: 420px) {
  .topbar { gap: 10px; }
  .brand-logo { display: none; }
  .brand-icon { display: block; }
}
@media (max-width: 360px) {
  .guide-cta { padding: 6px 8px; }
  .guide-cta img { display: none; }
  .online-pill { padding: 6px 8px; }
}

/* ---- web map card (Kaimai section) + footer links + nav current page ---- */
.map-cta { display: flex; align-items: center; gap: 14px; margin-top: 18px; padding: 12px 14px; color: inherit; text-decoration: none;
  background: rgba(0,0,0,.32); border: 2px solid rgba(255,255,255,.14); }
.map-cta:hover { border-color: #ffff55; }
.map-cta img { width: 40px; height: 40px; image-rendering: pixelated; flex: none; }
.map-cta-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.map-cta-text strong { font: 600 19px var(--font-head); color: #ffff55; text-shadow: 2px 2px 0 #3f3f15; }
.map-cta-text span { color: #dfe2ee; font-size: 16px; line-height: 1.3; }
.map-cta-go { margin-left: auto; flex: none; font: 600 16px var(--font-head); color: #9fd3ff; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 18px; width: 100%; }
.footer-links a { color: #ffd95e; font: 600 16px var(--font-head); text-decoration: none; }
.footer-links a:hover { text-decoration: underline; }
@media (max-width: 520px) {
  .map-cta { flex-wrap: wrap; }
  .map-cta-go { margin-left: 54px; }
}

/* ------------------------------------------------------------------ homepage: Pasiūlymai ir klaidos (bendruomene.js) */
.cm-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
.cm-col .sub { margin-top: 6px; }
.cm-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 6px; }
.cm-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; color: var(--text); text-decoration: none; background: rgba(0,0,0,.3);
  border: 2px solid #000; transition: transform .12s; }
.cm-item:hover { transform: translateX(3px); }
.cm-votes { flex: none; min-width: 44px; font: 600 15px var(--font-head); color: var(--muted); }
.cm-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cm-btn { text-decoration: none; display: inline-block; font-size: 14px; }
.st { flex: none; display: inline-block; padding: 1px 7px 2px; font: 600 13px var(--font-head); color: #10121a; border: 2px solid #000; white-space: nowrap; }
.st-naujas { background: #c9d1d9; } .st-svarstomas { background: #ffc83d; } .st-priimtas { background: #55ff55; }
.st-atmestas { background: #ff7070; } .st-padaryta { background: #55ffff; }
@media (max-width: 760px) { .cm-grid { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------------------------------------------------ sticky footer: short pages keep the footer at the bottom */
body { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
body > main { flex: 1 0 auto; }
body > .footer { flex-shrink: 0; }

/* ---- title tooltips (site.js showTip): pixel panel with the tier-coloured rim; legendary plaques ---- */
.plaque.tier-legendinis { --tc: #ffc86a; background: linear-gradient(180deg, rgba(66,22,50,.92), rgba(22,6,22,.95));
  box-shadow: 0 0 12px rgba(255,150,90,.55), inset 0 0 0 1px rgba(0,0,0,.6); }
.plaque.tier-legendinis .pl-text { background: linear-gradient(100deg, var(--tc) 0%, var(--tc) 38%, #fff 50%, #ff9e6a 56%, var(--tc) 64%, var(--tc) 100%);
  background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none;
  animation: shimmer 2.6s linear infinite; }
.plaque.has-tip { cursor: pointer; }
.plaque.has-tip:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.plaque.temp { border-style: dashed; }
.title-tip { position: fixed; left: 0; top: 0; z-index: 1000; box-sizing: border-box; width: max-content; max-width: min(300px, calc(100vw - 16px));
  padding: 7px 10px 9px; font: 400 16px/1.3 var(--font-pixel); color: #ece8f8; text-align: left; white-space: normal; pointer-events: none;
  background: #15111f; border: 2px solid var(--tc, #8a7bd8);
  box-shadow: 0 0 0 2px #000, 4px 4px 0 2px rgba(0,0,0,.55), inset 0 0 0 1px rgba(255,255,255,.07);
  opacity: 0; transition: opacity .12s ease-out; }
.title-tip[hidden] { display: none; }
.title-tip.show { opacity: 1; }
.title-tip.pinned { pointer-events: auto; }
.title-tip::after { content: ""; position: absolute; top: 100%; left: var(--ax, 50%); width: 12px; height: 6px; margin-left: -6px;
  background: var(--tc, #8a7bd8); clip-path: polygon(0 0, 100% 0, 66% 50%, 66% 66%, 50% 100%, 34% 66%, 34% 50%); }
.title-tip.below::after { top: auto; bottom: 100%; clip-path: polygon(50% 0, 66% 34%, 66% 50%, 100% 100%, 0 100%, 34% 50%, 34% 34%); }
.title-tip .tt-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 3px; }
.title-tip .tt-name { font: 600 17px/1.2 var(--font-head); color: var(--tc); text-shadow: 1px 1px 0 #000; }
.title-tip .tt-tier { flex: none; font: 400 12px/1.4 var(--font-head); padding: 0 5px; color: #140c00; background: var(--tc); border: 1px solid #000; }
.title-tip p { margin: 3px 0 0; }
.title-tip .tt-k { color: #a9a2c6; }
.title-tip .tt-when { color: #a9a2c6; font-size: 15px; }
.title-tip .tt-temp { margin-top: 6px; padding: 2px 6px; color: #241600; background: var(--gold); border: 1px solid #000; font-weight: 600; }
.plaque.locked.tier-legendinis { --tc: #555; background: repeating-linear-gradient(45deg, #151515 0 6px, #1c1c1c 6px 12px); }
/* relics (Amatai relics module): the tile frame in the rarity colour */
.relic { border: 2px solid var(--rc, #aaa); border-left-width: 4px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.55), 0 0 7px color-mix(in srgb, var(--rc, #aaa) 30%, transparent); }
.relic.rar-legendinis:not(.missing) { animation: relic-glow 2.4s ease-in-out infinite; }
@keyframes relic-glow { 50% { box-shadow: inset 0 0 0 1px rgba(0,0,0,.55), 0 0 14px color-mix(in srgb, var(--rc) 60%, transparent); } }
.relic.missing { border-color: #333; box-shadow: none; }
@media (prefers-reduced-motion: reduce) { .relic.rar-legendinis { animation: none; } }

/* ---- meistrystė (Atgimimas): emblem, rank line, rank IV+ card outline; honour tiers ---- */
img.emblem { image-rendering: pixelated; vertical-align: middle; }
.tag-line img.emblem { margin-right: -2px; }
.rank-line { font-weight: 600; text-shadow: 1px 1px 0 rgba(0,0,0,.6); }
.pcard.rank-high { outline: 4px double var(--rc, #6CD3FF); outline-offset: -8px; }
.honor-tier { font-weight: 700; }
.honor-tier.tier-1 { color: #E8A15A; } .honor-tier.tier-2 { color: #DDE3EA; } .honor-tier.tier-3 { color: #FFD84A; }
.honor-tier.tier-4 { background: linear-gradient(90deg, #FFF3A0, #FF8A2E); -webkit-background-clip: text; background-clip: text; color: transparent; }
.vstats .festival { color: #FFD84A; font-weight: 700; }

/* UI chrome is not text: no selection highlight, no I-beam/help cursors on cards, plaques, badges, buttons, rings,
   stats labels; player names, numbers in stat rows and real text (guide, news, posts) stay selectable. */
button, .mc-btn, nav, .topbar, .pcard, .pod, .rest li, .plaque, .prof-badge, .titles-count, .ring, .stat, .pf-stage,
.pf-handle, .pf-profbadge, .pf-group h3, .pf-row dt, .vbanner, .tabs, .catpick, .vote, .chip, .badge, img, canvas,
dialog.profile .close, .title-wall, .fish, .bar {
  -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
dialog.profile { -webkit-user-select: none; user-select: none; cursor: default; }
dialog.profile .pname, dialog.profile .pf-row dd, dialog.profile .pf-feed li { -webkit-user-select: text; user-select: text; }
img, canvas { -webkit-user-drag: none; }

/* ---- Discord logo (top bar, menu, hero button). The top bar menu itself: nav.css (tools/gen_nav.py). */
.dc-ico { display: block; flex: none; }
@media (max-width: 520px) {  /* the small brand icon from 520px (was 420px): the wide logo pushed the bar off narrow phones */
  .topbar { gap: 10px; }
  .brand-logo { display: none; }
  .brand-icon { display: block; }
}

