/* Self-hosted Google Fonts (generated from fonts.googleapis.com css2, Latin + Cyrillic subsets only) */
/* Handjet 400 cyrillic-ext */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/handjet-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Handjet 400 cyrillic */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/handjet-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Handjet 400 latin-ext */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/handjet-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Handjet 400 latin */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/handjet-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Handjet 600 cyrillic-ext */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/handjet-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Handjet 600 cyrillic */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/handjet-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Handjet 600 latin-ext */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/handjet-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Handjet 600 latin */
@font-face {
  font-family: 'Handjet';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/handjet-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Rubik 400 cyrillic-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Rubik 400 cyrillic */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Rubik 400 latin-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Rubik 400 latin */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Rubik 500 cyrillic-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Rubik 500 cyrillic */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Rubik 500 latin-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Rubik 500 latin */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Rubik 700 cyrillic-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Rubik 700 cyrillic */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/rubik-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Rubik 700 latin-ext */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Rubik 700 latin */
@font-face {
  font-family: 'Rubik';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/rubik-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Silkscreen 700 latin-ext */
@font-face {
  font-family: 'Silkscreen';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/silkscreen-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Silkscreen 700 latin */
@font-face {
  font-family: 'Silkscreen';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/silkscreen-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Tiny5 400 cyrillic-ext */
@font-face {
  font-family: 'Tiny5';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/tiny5-cyrillic-ext.woff2) format('woff2');
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Tiny5 400 cyrillic */
@font-face {
  font-family: 'Tiny5';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/tiny5-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Tiny5 400 latin-ext */
@font-face {
  font-family: 'Tiny5';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/tiny5-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Tiny5 400 latin */
@font-face {
  font-family: 'Tiny5';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/tiny5-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ==========================================================================
   Kavadarci Public status page, design C "Tikvesh Retro".
   Fonts: Silkscreen (title, Latin only), Tiny5 (labels, Latin + Macedonian
   Cyrillic), Handjet (numbers / scoreboard), Rubik (body). All self-hosted,
   SIL Open Font License (OFL-*.txt next to the font files).
   ========================================================================== */

:root {
  --ground: #140A2A;
  --panel: #22154A;
  --line: #4B3A86;
  --line-2: #3A2A6B;
  --shadow: #0A0518;
  --text: #F4EEFF;
  --soft: #E4DCFA;
  --muted: #BDB1E3;
  --accent: #FFD166;
  --accent-ink: #1A0B33;
  --t: #FF8F80;
  --ct: #7FD8FF;
  --ok: #8BF0A0;
  --ok-dot: #43D16A;
  --title-shadow: #2A1155;
  --pixel: 'Tiny5', ui-monospace, monospace;
  --title: 'Silkscreen', 'Tiny5', ui-monospace, monospace;
  --digits: 'Handjet', ui-monospace, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--ground);
  color: var(--text);
  font: 16px/1.5 'Rubik', system-ui, -apple-system, 'Segoe UI', sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); }
a:hover { color: #FFE29A; }
code { font-family: var(--digits); font-size: 1.2em; color: #FFFFFF; }
h1, h2 { margin: 0; font-weight: 400; }
.hidden { display: none; }
.muted { color: var(--muted); font-size: 14px; }
.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
@media (max-width: 560px) { .wrap { padding-left: 16px; padding-right: 16px; } }

/* ---- buttons -------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 18px;
  background: var(--ground); color: var(--text);
  border: 2px solid var(--text); border-radius: 0;
  font: 18px/1 var(--pixel); text-decoration: none; cursor: pointer;
}
.btn:hover { color: var(--text); background: #1D1040; }
.btn:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.btn-go { background: var(--accent); color: var(--accent-ink); font-size: 19px; padding: 0 20px; }
.btn-go:hover { background: #FFDD8A; color: var(--accent-ink); }
.btn-wide { width: 100%; min-height: 52px; }

.panel {
  background: var(--panel);
  border: 3px solid var(--line);
  box-shadow: 8px 8px 0 var(--shadow);
  padding: 24px;
}

/* ---- hero ------------------------------------------------------------------ */
.hero { position: relative; overflow: hidden; min-height: 700px; display: flex; flex-direction: column; }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; }
.scan {
  position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(180deg, rgba(10,5,24,0.22) 0, rgba(10,5,24,0.22) 2px, rgba(10,5,24,0) 2px, rgba(10,5,24,0) 4px);
}
.hero-fade { position: absolute; left: 0; right: 0; bottom: 0; height: 200px; background: linear-gradient(180deg, rgba(20,10,42,0) 0%, var(--ground) 100%); }

.nav {
  position: relative; padding-top: 22px;
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  font: 18px/1.2 var(--pixel);
}
.tag { padding: 4px 12px; background: rgba(20,10,42,0.72); border: 2px solid var(--text); letter-spacing: 0.04em; }
.nav-links { display: flex; gap: 24px; flex-wrap: wrap; }
.nav-links a { color: var(--text); text-decoration: none; }
.nav-links a:hover { color: var(--accent); }

.hero-body {
  position: relative; flex: 1;
  padding-top: 56px; padding-bottom: 64px;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between; gap: 40px;
  text-align: center;
}
.hero-copy { display: flex; flex-direction: column; align-items: center; gap: 14px; }
.eyebrow { font: 20px/1.2 var(--pixel); letter-spacing: 0.16em; color: #FFD9B0; }
.hero h1 {
  font-family: var(--title); font-weight: 700;
  font-size: clamp(48px, 7.4vw, 108px); line-height: 0.95; letter-spacing: 0.01em;
  color: #FFFFFF; text-shadow: 6px 6px 0 var(--title-shadow);
}
.hero-copy p { margin: 0; max-width: 580px; font-size: 19px; text-shadow: 0 2px 0 var(--title-shadow); }

.connect {
  width: 100%; max-width: 680px; padding: 20px; text-align: left;
  border-color: var(--text);
  display: flex; flex-direction: column; gap: 14px;
}
.connect-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; font: 18px/1.2 var(--pixel); }
.state { display: inline-flex; align-items: center; gap: 8px; }
.state .dot { width: 10px; height: 10px; }
.state.on { color: var(--ok); }
.state.on .dot { background: var(--ok-dot); }
.state.off { color: var(--t); }
.state.off .dot { background: var(--t); }
.connect-map { color: var(--muted); }
.connect-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: stretch; }
.ip {
  flex: 1 1 260px; display: flex; align-items: center; min-height: 54px; padding: 0 16px;
  background: var(--ground); border: 2px solid var(--line);
  font: 600 32px/1 var(--digits); letter-spacing: 0.04em; word-break: break-all;
}
.hint { font-size: 14px; color: var(--muted); }

/* ---- main -------------------------------------------------------------- */
.main { padding-top: 16px; padding-bottom: 80px; display: flex; flex-direction: column; gap: 64px; }
.section { display: flex; flex-direction: column; gap: 18px; }
.section > h2 { font: 40px/1.1 var(--pixel); letter-spacing: 0.02em; }
.c-t { color: var(--t); }
.c-ct { color: var(--ct); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px; }
.tile { background: var(--panel); border: 2px solid var(--line); padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.tile .k { font: 15px/1.2 var(--pixel); color: var(--muted); }
.tile .v { font: 600 34px/1 var(--digits); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.board { background: rgba(10,5,24,0.86); border: 3px solid var(--line); box-shadow: 8px 8px 0 var(--shadow); overflow-x: auto; }
.board table { width: 100%; min-width: 560px; border-collapse: collapse; font: 26px/1.2 var(--digits); }
.board td, .board th { padding: 5px 10px; text-align: left; }
.board td:first-child, .board th:first-child { padding-left: 20px; }
.board td:last-child, .board th:last-child { padding-right: 20px; }
.board .n { text-align: right; width: 110px; }
.board .hdr th { font: 18px/1.2 var(--pixel); font-weight: 400; padding-top: 14px; padding-bottom: 10px; border-bottom: 2px solid var(--line-2); }
.board .hdr-2 th { padding-top: 20px; border-top: 2px solid var(--line-2); }
.board td:first-child { overflow-wrap: anywhere; }
.board .none td { color: var(--muted); font-size: 22px; }
.board .spec { padding-top: 14px; padding-bottom: 16px; color: var(--muted); font-size: 22px; }
.note { margin: 0; color: var(--muted); font-size: 15px; }

.maps { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.map { background: var(--panel); border: 3px solid var(--line); box-shadow: 6px 6px 0 var(--shadow); display: flex; flex-direction: column; }
.map-img { aspect-ratio: 4 / 3; overflow: hidden; background: #E6E6E8; }
.map-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.map-foot { padding: 12px 14px; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.map-name { font: 600 30px/1 var(--digits); }
.map-tag { font: 16px/1.2 var(--pixel); color: var(--muted); }
.map.now { border-color: var(--accent); }
.map.now .map-tag { color: var(--accent); }
.map.next .map-tag { color: var(--text); }

.split { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.scores { flex: 999 1 560px; min-width: 0; padding-bottom: 18px; display: flex; flex-direction: column; gap: 12px; }
.scores-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.scores-head h2 { font: 36px/1.1 var(--pixel); color: var(--accent); }
.top { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.top li { display: flex; align-items: baseline; gap: 14px; font: 30px/1.15 var(--digits); color: var(--soft); }
.top li.r1 { color: var(--accent); }
.top li.r2 { color: #FFFFFF; }
.top .rk { width: 44px; flex: none; }
.top .nm { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top .dots { flex: 1 1 40px; border-bottom: 2px dotted var(--line); transform: translateY(-6px); }
.top .kl { min-width: 80px; text-align: right; flex: none; }
.top .top-empty { font: 16px/1.5 'Rubik', system-ui, sans-serif; color: var(--muted); }

.aside { flex: 1 1 320px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.aside .panel { display: flex; flex-direction: column; gap: 12px; }
.aside h2 { font: 30px/1.1 var(--pixel); }
.rules { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; color: var(--soft); }
.cmds { margin: 0; font: 26px/1.3 var(--digits); color: #FFFFFF; }

.foot { border-top: 2px solid #2E1F5C; }
.foot-row { padding-top: 24px; padding-bottom: 24px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; color: var(--muted); font-size: 14px; }

/* ---- phones -------------------------------------------------------------------
   Silkscreen is wide: "KAVADARCI" is 7.7 em, so the title follows the viewport
   width below 520px (fits a 320px screen). */
@media (max-width: 520px) {
  .hero { min-height: 0; }
  .hero-body { padding-top: 40px; padding-bottom: 48px; gap: 32px; }
  .hero h1 { font-size: 10.5vw; text-shadow: 4px 4px 0 var(--title-shadow); }
  .eyebrow { font-size: 15px; letter-spacing: 0.1em; }
  .hero-copy p { font-size: 17px; }
  .connect { padding: 16px; }
  .ip { font-size: 25px; flex-basis: 100%; }
  .connect-row .btn { flex: 1 1 auto; }
  .section > h2 { font-size: 32px; }
  .scores-head h2 { font-size: 30px; }
  .top li { font-size: 26px; gap: 10px; }
  .top .rk { width: 36px; }
  .top .kl { min-width: 64px; }
  .board table { min-width: 0; font-size: 21px; }
  .board td, .board th { padding: 4px 6px; }
  .board td:first-child, .board th:first-child { padding-left: 12px; }
  .board td:last-child, .board th:last-child { padding-right: 12px; }
  .board .n { width: auto; }
  .board .hdr th { font-size: 13px; }
  .board .none td, .board .spec { font-size: 18px; }
}
