/* Písma jsou uložená lokálně (fonts/, licence SIL OFL 1.1), hra tak nic nenačítá z cizích serverů. */
@font-face { font-family: 'Bangers'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/bangers-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; }
@font-face { font-family: 'Bangers'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/bangers-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; }
@font-face { font-family: 'Patrick Hand'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/patrick-hand-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; }
@font-face { font-family: 'Patrick Hand'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/patrick-hand-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; }

/* =========================================================================
   KYBERDOBRODRUŽSTVÍ – vzhled ve stylu moderního komiksu
   Papír s rastrem, černé obrysy, tvrdé stíny, bubliny a výbuchy.
   ========================================================================= */
:root {
  --paper: #eef9f1;
  --ink: #141414;
  --white: #ffffff;
  /* brand Guardians.cz: #34C759 (hlavní), #FFFFFF, #D9D9D9, #FF9500, #007AFF, #000000 */
  --brand: #34c759;
  --brand-dark: #1e9e45;
  --brand-light: #d6f5de;
  --sky: #cce4ff;
  --red: #ff3d3d;
  --blue: #007aff;
  --green: #34c759;
  --orange: #ff9500;
  --gray: #d9d9d9;
  --muted: #5b5468;
  --border: 4px solid var(--ink);
  --shadow: 6px 6px 0 var(--ink);
  --shadow-sm: 4px 4px 0 var(--ink);
  --radius: 10px;
  --font: 'Patrick Hand', 'Comic Sans MS', system-ui, sans-serif;
  --head: 'Bangers', 'Impact', system-ui, sans-serif;
  --doc: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --burst: polygon(50% 0%, 61% 18%, 82% 6%, 78% 30%, 100% 33%, 84% 50%, 100% 67%, 78% 70%, 82% 94%, 61% 82%, 50% 100%, 39% 82%, 18% 94%, 22% 70%, 0% 67%, 16% 50%, 0% 33%, 22% 30%, 18% 6%, 39% 18%);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: var(--font);
  font-size: 19px;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    radial-gradient(rgba(20, 20, 20, .10) 1.3px, transparent 1.6px),
    radial-gradient(circle at 0% 0%, rgba(52, 199, 89, .22), transparent 40%),
    radial-gradient(circle at 100% 100%, rgba(0, 122, 255, .12), transparent 45%);
  background-size: 14px 14px, 100% 100%, 100% 100%;
  background-attachment: fixed;
  min-height: 100vh;
  line-height: 1.4;
}
h1, h2, h3 { font-family: var(--head); font-weight: 400; letter-spacing: 1px; line-height: 1.05; margin: 0 0 .4em; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
p { margin: 0 0 .8em; }
.muted { color: var(--muted); }
.small { font-size: .88rem; }
.app { max-width: 1100px; margin: 0 auto; padding: 16px; }

/* ---------- tlačítka ---------- */
.btn {
  font-family: var(--head); font-size: 1.2rem; letter-spacing: 1px; color: var(--ink);
  background: var(--white); border: 3px solid var(--ink); border-radius: 8px;
  padding: 8px 18px; cursor: pointer; box-shadow: var(--shadow-sm);
  transition: transform .1s, box-shadow .1s, background .15s;
}
.btn:hover:not(:disabled) { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--ink); }
.btn:active:not(:disabled) { transform: translate(3px, 3px); box-shadow: 1px 1px 0 var(--ink); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.primary { background: var(--brand); }
.btn.ghost { background: var(--white); }
.btn.danger { background: #ffd6d6; }
.btn.big { padding: 12px 26px; font-size: 1.5rem; }
.btn.small { padding: 4px 12px; font-size: 1.05rem; box-shadow: 3px 3px 0 var(--ink); }
button:focus-visible, .flag:focus-visible, input:focus-visible { outline: 4px solid var(--blue); outline-offset: 3px; }

.panel {
  background: var(--white); border: var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow); margin-bottom: 20px;
}

/* ---------- společné komiksové prvky ---------- */
.cap {
  font-family: var(--head); letter-spacing: 1px; text-transform: uppercase;
  background: var(--brand); border: 3px solid var(--ink); box-shadow: 3px 3px 0 var(--ink);
  padding: 4px 12px; display: inline-block;
}
.burst {
  position: absolute; display: grid; place-items: center; text-align: center; z-index: 1; isolation: isolate;
  font-family: var(--head); letter-spacing: 1px; color: var(--ink);
  filter: drop-shadow(3px 0 0 var(--ink)) drop-shadow(-3px 0 0 var(--ink)) drop-shadow(0 3px 0 var(--ink)) drop-shadow(0 -3px 0 var(--ink)) drop-shadow(5px 5px 0 rgba(0,0,0,.35));
}
.burst::before { content: ''; position: absolute; inset: 0; clip-path: var(--burst); background: var(--brand); z-index: -1; }

/* ---------- titulní strana (obálka) ---------- */
.cover {
  background: var(--white); border: 5px solid var(--ink); box-shadow: 10px 10px 0 var(--ink);
  margin: 12px auto 24px; max-width: 980px; overflow: hidden;
}
.cover-top {
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
  background: var(--ink); color: var(--white); font-family: var(--head); letter-spacing: 2px; font-size: 1.1rem;
  padding: 6px 16px; text-transform: uppercase;
}
.cover-top span:last-child { background: var(--orange); color: var(--ink); padding: 0 10px; transform: rotate(-3deg); }
.cover-logo {
  text-align: center; margin: 0; padding: 14px 10px 16px; text-transform: uppercase;
  background-color: var(--blue);
  background-image: radial-gradient(rgba(0, 0, 0, .14) 1.5px, transparent 1.8px);
  background-size: 9px 9px; border-bottom: 5px solid var(--ink);
}
.cover-logo span { display: block; color: var(--brand); -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 6px 6px 0 var(--ink); }
.cover-logo .l1 { font-size: clamp(2.4rem, 7vw, 4rem); color: var(--white); transform: rotate(-2deg); }
.cover-logo .l2 { font-size: clamp(2.6rem, 9vw, 5.6rem); line-height: .95; }
.title-art { position: relative; aspect-ratio: 16 / 7; overflow: hidden; border-bottom: 5px solid var(--ink); }
.title-art svg { width: 100%; height: 100%; display: block; }
.cover-burst { right: 3%; top: 8%; width: 170px; height: 120px; font-size: 1.6rem; transform: rotate(10deg); color: var(--white); -webkit-text-stroke: 1px var(--ink); }
.cover-burst::before { background: var(--orange); }
.cover-cap { position: absolute; left: 3%; bottom: 8%; font-size: 1.1rem; transform: rotate(-2deg); }
.title-card { padding: 20px 24px 22px; text-align: center; }
.lead { max-width: 640px; margin: 0 auto 18px; font-size: 1.2rem; }
.title-btns { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }

/* ---------- tvorba postavy ---------- */
.create-screen { max-width: 640px; margin: 24px auto; }
.create-screen h2 { font-size: 2.6rem; }
.gender-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 16px 0; }
.gender-card {
  font: inherit; color: var(--ink); background-color: var(--white); border: var(--border); border-radius: var(--radius);
  padding: 14px 10px 12px; cursor: pointer; display: grid; justify-items: center; gap: 6px; box-shadow: var(--shadow-sm);
  background-image: radial-gradient(rgba(0, 0, 0, .08) 1.3px, transparent 1.6px); background-size: 10px 10px;
  transition: transform .12s, box-shadow .12s, background-color .15s;
}
.gender-card svg { width: 110px; height: 200px; }
.gender-card span { font-family: var(--head); font-size: 1.7rem; letter-spacing: 1px; }
.gender-card:hover { transform: translate(-2px, -2px) rotate(-1deg); box-shadow: var(--shadow); }
.gender-card[aria-pressed="true"] { background-color: var(--brand); transform: rotate(-1.5deg); box-shadow: var(--shadow); }
.field { display: grid; gap: 6px; font-family: var(--head); font-size: 1.2rem; letter-spacing: 1px; }
.field input {
  font-family: var(--font); font-size: 1.3rem; padding: 10px 14px; border-radius: 8px; border: var(--border);
  background: var(--white); color: var(--ink); box-shadow: inset 3px 3px 0 rgba(0, 0, 0, .1);
}
.create-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 20px; flex-wrap: wrap; }

/* ---------- horní lišta ---------- */
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: var(--white); border: var(--border); border-radius: var(--radius);
  padding: 6px 12px; margin-bottom: 20px; box-shadow: var(--shadow);
}
.tb-player { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tb-avatar { width: 50px; height: 54px; background: var(--sky); border: 3px solid var(--ink); border-radius: 50%; flex: none; }
.tb-name { font-family: var(--head); font-size: 1.35rem; letter-spacing: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tb-sub { font-size: .9rem; color: var(--muted); }
.tb-right { display: flex; align-items: center; gap: 10px; }
.tb-score { font-family: var(--head); letter-spacing: 1px; background: var(--brand); border: 3px solid var(--ink); border-radius: 999px; padding: 2px 14px; white-space: nowrap; font-size: 1.15rem; }
.tb-score b { font-weight: 400; font-size: 1.4rem; }
.tb-score span { margin-left: 3px; }

/* ---------- mapa ---------- */
.screen-title {
  font-size: clamp(2.2rem, 6vw, 3.2rem); color: var(--brand); -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill;
  text-shadow: 4px 4px 0 var(--ink); transform: rotate(-1.5deg); display: inline-block; margin-bottom: 18px;
}
.banner {
  background: var(--green); border: var(--border); box-shadow: var(--shadow); border-radius: var(--radius);
  padding: 10px 16px; margin-bottom: 20px; display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap;
  font-family: var(--head); font-size: 1.4rem; letter-spacing: 1px; color: var(--white); -webkit-text-stroke: 1px var(--ink);
}
.banner .btn { -webkit-text-stroke: 0; }
.loc-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.loc-card {
  font: inherit; color: var(--ink); text-align: left; padding: 0; cursor: pointer; overflow: hidden; position: relative;
  background: var(--white); border: var(--border); border-radius: 4px; box-shadow: var(--shadow);
  transition: transform .15s, box-shadow .15s;
}
.loc-card:nth-child(4n+1) { transform: rotate(-.8deg); }
.loc-card:nth-child(4n+2) { transform: rotate(.6deg); }
.loc-card:nth-child(4n+3) { transform: rotate(.5deg); }
.loc-card:nth-child(4n) { transform: rotate(-.6deg); }
.loc-card:hover { transform: rotate(0) translate(-3px, -3px); box-shadow: 10px 10px 0 var(--ink); }
.loc-card.complete::after {
  content: 'HOTOVO!'; position: absolute; top: 16px; right: -38px; transform: rotate(35deg);
  background: var(--green); color: var(--white); font-family: var(--head); letter-spacing: 1px; font-size: 1.1rem;
  padding: 2px 44px; border-top: 3px solid var(--ink); border-bottom: 3px solid var(--ink);
}
.loc-art { aspect-ratio: 16 / 7; overflow: hidden; border-bottom: var(--border); }
.loc-art svg { width: 100%; height: 100%; display: block; }
.loc-info { padding: 10px 16px 14px; }
.loc-name { font-family: var(--head); font-size: 1.9rem; letter-spacing: 1px; line-height: 1; }
.loc-name small { font-family: var(--head); font-size: 1rem; background: var(--orange); color: var(--ink); padding: 1px 8px; border: 2px solid var(--ink); margin-left: 6px; vertical-align: middle; }
.loc-desc { color: var(--muted); font-size: 1rem; margin: 6px 0 8px; }
.loc-progress { font-family: var(--head); letter-spacing: 1px; font-size: 1.1rem; display: flex; align-items: center; gap: 8px; }
.dots { display: inline-flex; gap: 5px; }
.dots i { width: 16px; height: 16px; border-radius: 50%; background: var(--white); border: 3px solid var(--ink); display: block; }
.dots i.on { background: var(--green); }

/* ---------- místo ---------- */
.loc-hero { position: relative; border: var(--border); box-shadow: var(--shadow); overflow: hidden; aspect-ratio: 16 / 6; margin-bottom: 22px; border-radius: 4px; }
.loc-hero svg { width: 100%; height: 100%; display: block; }
.loc-hero-title { position: absolute; left: 16px; top: 14px; display: grid; gap: 6px; justify-items: start; }
.loc-hero-title h2 { font-size: clamp(2.2rem, 6vw, 3.2rem); margin: 0; color: var(--white); -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--ink); }
.loc-hero-title p { margin: 0; font-family: var(--head); letter-spacing: 1px; background: var(--brand); border: 3px solid var(--ink); padding: 2px 10px; text-transform: uppercase; }
.ep-list { display: grid; gap: 14px; margin-bottom: 20px; }
.ep-card {
  font: inherit; color: var(--ink); text-align: left; cursor: pointer; display: flex; align-items: center; gap: 14px;
  background: var(--white); border: var(--border); border-radius: var(--radius); padding: 10px 14px; box-shadow: var(--shadow-sm);
  transition: transform .12s, box-shadow .12s;
}
.ep-card:hover { transform: translate(-2px, -2px); box-shadow: var(--shadow); }
.ep-card.done { background: #eafbea; }
.ep-num { width: 52px; height: 52px; flex: none; border-radius: 50%; background: var(--brand); border: 3px solid var(--ink); display: grid; place-items: center; font-family: var(--head); font-size: 1.6rem; }
.ep-body { flex: 1; min-width: 0; }
.ep-title { font-family: var(--head); letter-spacing: 1px; font-size: 1.45rem; line-height: 1.1; }
.ep-teaser { color: var(--muted); font-size: 1rem; }
.ep-score { font-family: var(--head); letter-spacing: 1px; font-size: 1.3rem; white-space: nowrap; }

/* ---------- scéna (komiksový panel) ---------- */
.scene-screen { display: flex; flex-direction: column; gap: 10px; }
.scene-head { display: flex; align-items: center; gap: 10px; justify-content: space-between; margin-bottom: 6px; }
.scene-title { display: none; }
.scene-title b { color: var(--ink); }
.scene-step { font-family: var(--head); letter-spacing: 1px; white-space: nowrap; background: var(--white); border: 3px solid var(--ink); padding: 0 10px; }
.stage-wrap { position: relative; }
.stage {
  border: 5px solid var(--ink); border-radius: 4px; overflow: hidden; aspect-ratio: 16 / 9; max-height: 58vh; width: 100%;
  box-shadow: var(--shadow); cursor: pointer; background: var(--white);
}
.stage svg { width: 100%; height: 100%; display: block; }
.panel-cap { position: absolute; left: -6px; top: -12px; font-size: 1.05rem; transform: rotate(-1.5deg); max-width: 70%; }
.ink text { stroke: none; }
.person .body { transform-box: fill-box; }
.person.talking .body { animation: bob .5s ease-in-out infinite alternate; }
.mouth-talk { transform-box: fill-box; transform-origin: center; animation: talk .16s ease-in-out infinite alternate; }
@keyframes bob { from { transform: translateY(0); } to { transform: translateY(-5px); } }
@keyframes talk { from { transform: scaleY(.3); } to { transform: scaleY(1); } }

/* bublina / vypravěč / telefon */
.dialog {
  --tail-x: 50%;
  position: relative; margin-top: 20px;
  background: var(--white); border: var(--border); border-radius: 26px;
  padding: 20px 22px 24px; min-height: 130px; box-shadow: var(--shadow); cursor: pointer;
}
.dialog.bubble::before, .dialog.bubble::after {
  content: ''; position: absolute; left: var(--tail-x); width: 0; height: 0; border-style: solid; border-color: transparent;
}
.dialog.bubble::before { top: -34px; margin-left: -20px; border-width: 0 6px 34px 24px; border-bottom-color: var(--ink); }
.dialog.bubble::after { top: -23px; margin-left: -14px; border-width: 0 3px 25px 16px; border-bottom-color: var(--white); }
.dialog.narr { background: var(--brand); border-radius: 2px; transform: rotate(-.4deg); }
.dialog.narr .say { font-size: 1.3rem; }
.dialog.phone { background: #ffe9ec; border-style: dashed; border-color: var(--red); outline: 4px solid var(--ink); outline-offset: 3px; border-radius: 6px; animation: buzz .25s 3; }
@keyframes buzz { 25% { transform: translateX(-3px) rotate(-.5deg); } 75% { transform: translateX(3px) rotate(.5deg); } }
.dialog.choosing { cursor: default; border-radius: var(--radius); }
.speaker {
  position: absolute; top: -18px; left: 22px;
  font-family: var(--head); letter-spacing: 1px; font-size: 1.15rem; color: var(--ink); background: var(--sc);
  border: 3px solid var(--ink); border-radius: 4px; padding: 0 10px; transform: rotate(-2deg); box-shadow: 2px 2px 0 var(--ink);
}
.say { font-size: 1.35rem; min-height: 2.8em; line-height: 1.35; }
.cont { position: absolute; right: 18px; bottom: 6px; font-size: .85rem; color: var(--muted); animation: blink 1.2s infinite; }
@keyframes blink { 50% { opacity: .3; } }
.q { font-size: 1.35rem; margin-bottom: 12px; }
.q-tag { font-family: var(--head); letter-spacing: 1px; background: var(--orange); color: var(--ink); border: 3px solid var(--ink); padding: 0 8px; margin-right: 6px; display: inline-block; transform: rotate(-2deg); }
.choices { display: grid; gap: 10px; }
.choice {
  font: inherit; font-size: 1.15rem; color: var(--ink); text-align: left; cursor: pointer; display: flex; gap: 12px; align-items: flex-start;
  background: var(--white); border: 3px solid var(--ink); border-radius: 12px; padding: 8px 14px; box-shadow: 3px 3px 0 var(--ink);
  transition: transform .1s, box-shadow .1s, background .15s;
}
.choice:hover { background: var(--brand-light); transform: translate(-2px, -2px) rotate(-.4deg); box-shadow: 5px 5px 0 var(--ink); }
.choice kbd { font-family: var(--head); font-size: 1.2rem; background: var(--sky); border: 3px solid var(--ink); border-radius: 50%; width: 34px; height: 34px; display: grid; place-items: center; flex: none; }

/* ---------- modaly ---------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; animation: fade .18s;
  background-color: rgba(20, 16, 40, .55);
  background-image: radial-gradient(rgba(0, 0, 0, .35) 1.5px, transparent 1.8px); background-size: 8px 8px;
}
.modal {
  background: var(--white); border: 5px solid var(--ink); border-radius: var(--radius); box-shadow: 10px 10px 0 var(--ink);
  width: min(580px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 22px; animation: pop .22s cubic-bezier(.2, 1.6, .5, 1);
}
.modal.wide { width: min(860px, 100%); }
.modal.inspect-modal { width: min(1060px, 100%); padding: 16px; background: #f3f6ff; }
.modal-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 18px; flex-wrap: wrap; }
.modal-actions.col { flex-direction: column; align-items: stretch; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: scale(.85) rotate(-2deg); opacity: 0; } }
.howto { padding-left: 0; list-style: none; display: grid; gap: 8px; }
.howto li { background: var(--brand-light); border: 3px solid var(--ink); border-radius: 8px; padding: 6px 12px; }
.menu-list { display: grid; gap: 12px; }

/* zvukový efekt u vyhodnocení */
.sfx { position: relative; height: 130px; display: grid; place-items: center; margin: -6px 0 4px; }
.sfx::before, .sfx::after { content: ''; position: absolute; clip-path: var(--burst); }
.sfx::before { width: 270px; height: 130px; background: var(--ink); }
.sfx::after { width: 252px; height: 114px; background: var(--brand); }
.sfx.good::after { background: var(--green); }
.sfx.mid::after { background: var(--orange); }
.sfx.bad::after { background: var(--red); }
.sfx span {
  position: relative; z-index: 1; font-family: var(--head); font-size: 3.4rem; letter-spacing: 2px; color: var(--white);
  -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--ink); transform: rotate(-6deg);
  animation: boom .45s cubic-bezier(.2, 1.8, .4, 1);
}
.sfx.mid span { color: var(--white); }
@keyframes boom { from { transform: scale(.2) rotate(-30deg); } }
.verdict { font-family: var(--head); font-size: 1.7rem; letter-spacing: 1px; text-align: center; margin-bottom: 8px; }
.verdict.good { color: #1d8a40; }
.verdict.mid { color: #c76a00; }
.verdict.bad { color: #d32020; }
.your { color: var(--muted); font-size: 1.05rem; }
.best { background: #e3f9e8; border: 3px solid var(--ink); border-left: 10px solid var(--green); padding: 8px 12px; border-radius: 6px; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; top: 14px; transform: translateX(-50%) rotate(-4deg); z-index: 100;
  font-family: var(--head); letter-spacing: 1px; font-size: 1.3rem; color: var(--ink);
  padding: 8px 18px; background: var(--white); border: 3px solid var(--ink); box-shadow: 4px 4px 0 var(--ink);
  animation: drop .3s cubic-bezier(.2, 1.8, .4, 1); transition: opacity .4s, transform .4s;
}
.toast.good { background: var(--green); color: var(--white); -webkit-text-stroke: 1px var(--ink); }
.toast.mid { background: var(--orange); }
.toast.out { opacity: 0; transform: translate(-50%, -14px) rotate(-4deg); }
@keyframes drop { from { transform: translateX(-50%) scale(.3) rotate(-20deg); opacity: 0; } }

/* ---------- zkoumání ---------- */
.inspect { display: grid; grid-template-columns: 1.4fr 1fr; gap: 18px; align-items: start; }
.inspect-side { background: var(--white); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 14px; position: sticky; top: 0; }
.inspect-side h3 { font-size: 1.6rem; }
.meter { height: 18px; background: var(--white); border: 3px solid var(--ink); border-radius: 99px; overflow: hidden; margin-top: 6px; }
.meter-fill { height: 100%; width: 0; background: repeating-linear-gradient(45deg, var(--green) 0 10px, #58d97f 10px 20px); transition: width .3s; }
.meter-txt { font-family: var(--head); letter-spacing: 1px; font-size: 1.2rem; margin: 4px 0 8px; }
.found-list { margin: 0; padding-left: 22px; display: grid; gap: 8px; max-height: 42vh; overflow: auto; font-size: 1.02rem; }
.found-list li { background: #e3f9e8; border: 2px solid var(--ink); border-radius: 8px; padding: 6px 10px; }
.found-list li.rev { background: #fff0d6; }
.found-list b { font-family: var(--doc); font-size: .9rem; }

.doc { border: var(--border); border-radius: 12px; overflow: hidden; color: #1d2333; background: #fff; box-shadow: var(--shadow); font-family: var(--doc); font-size: .98rem; line-height: 1.5; }
.inspect-doc .doc { cursor: pointer; }
.flag { border-radius: 10px; transition: background .15s, box-shadow .15s; }
.flag.found { background: rgba(255, 61, 61, .14); box-shadow: 0 0 0 3px var(--red); }
.flag.revealed { background: rgba(255, 154, 31, .18); box-shadow: 0 0 0 3px var(--orange); }

.email .mail-bar { background: var(--blue); color: #fff; padding: 8px 14px; font-weight: 700; border-bottom: 3px solid var(--ink); }
.mail-head { padding: 12px 16px; border-bottom: 1px solid #e3e6ee; display: grid; gap: 3px; font-size: .92rem; }
.mail-head .lbl { color: #7a8299; display: inline-block; width: 46px; }
.mail-subj { font-weight: 800; font-size: 1.1rem; margin-top: 6px; }
.mail-body { padding: 12px 16px; }
.mail-body p { margin: 0 0 .7em; }
.mail-attach { margin: 0 16px 16px; padding: 10px 12px; background: #f1f3f8; border: 2px dashed #8a93ab; border-radius: 10px; display: inline-block; font-weight: 700; }

.chat { background-color: #efe7da; background-image: radial-gradient(rgba(0, 0, 0, .05) 1.2px, transparent 1.5px); background-size: 12px 12px; }
.chat-head { background: #1f8a6a; color: #fff; padding: 10px 14px; border-bottom: 3px solid var(--ink); }
.chat-app { font-size: .78rem; opacity: .9; }
.chat-title { font-weight: 800; font-size: 1.05rem; }
.chat-status { font-size: .8rem; opacity: .9; }
.chat-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.msg { max-width: 84%; padding: 8px 12px; border-radius: 14px; background: #fff; border: 2px solid #2a2a2a; align-self: flex-start; border-top-left-radius: 4px; }
.msg.me { align-self: flex-end; background: #d6f5c8; border-radius: 14px; border-top-right-radius: 4px; }

.web { background: #fafafa; }
.web-bar { background: #e6e8ee; padding: 8px 12px; display: flex; gap: 10px; align-items: center; border-bottom: 3px solid var(--ink); }
.dots3 { display: flex; gap: 5px; }
.dots3 i { width: 12px; height: 12px; border-radius: 50%; background: #ff5f57; border: 1.5px solid var(--ink); display: block; }
.dots3 i:nth-child(2) { background: #febc2e; }
.dots3 i:nth-child(3) { background: #28c840; }
.web-url { background: #fff; border-radius: 999px; padding: 4px 12px; font-size: .88rem; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.web-body { padding: 0 0 12px; }
.shop-banner { background: #e8273d; color: #fff; text-align: center; font-weight: 800; padding: 8px; }
.shop-product { display: grid; grid-template-columns: 110px 1fr; gap: 14px; padding: 14px 16px; align-items: center; }
.shop-img { font-size: 4.4rem; text-align: center; background: #f0f2f7; border-radius: 14px; padding: 10px 0; }
.shop-product h3 { color: #1d2333; font-family: var(--doc); font-weight: 800; letter-spacing: 0; font-size: 1.15rem; margin-bottom: 4px; }
.shop-price { font-size: 1.5rem; font-weight: 800; color: #d11a2a; }
.shop-price s { font-size: 1rem; color: #888; font-weight: 400; margin-left: 6px; }
.shop-stock { color: #b55400; font-weight: 800; font-size: .9rem; margin: 4px 0; }
.shop-pay { font-size: .9rem; color: #444; margin-bottom: 8px; }
.shop-btn { font: inherit; font-weight: 800; background: #ffb400; border: 0; border-radius: 8px; padding: 8px 22px; color: #222; pointer-events: none; }
.shop-reviews { margin: 0 16px 8px; padding: 8px 10px; background: #fff7e0; border-radius: 8px; font-size: .9rem; color: #6b5200; }
.shop-footer { margin: 0 16px; font-size: .82rem; color: #777; border-top: 1px solid #ddd; padding-top: 8px; }

/* ---------- konec epizody ---------- */
.end-ep { text-align: center; }
.end-ep h2 { font-size: 2.4rem; color: var(--brand); -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; text-shadow: 3px 3px 0 var(--ink); }
.stars { font-size: 2.4rem; letter-spacing: 6px; animation: boom .5s cubic-bezier(.2, 1.8, .4, 1); }
.item-get { display: flex; gap: 14px; align-items: center; text-align: left; background: var(--white); border: var(--border); border-radius: var(--radius); padding: 12px 14px; margin: 14px 0; box-shadow: var(--shadow-sm); }
.item-get.new { background: var(--brand-light); animation: wiggle .5s ease-in-out 2; }
@keyframes wiggle { 25% { transform: rotate(-1.5deg); } 75% { transform: rotate(1.5deg); } }
.item-icon { font-size: 2.4rem; flex: none; width: 64px; height: 64px; display: grid; place-items: center; background: var(--sky); border: 3px solid var(--ink); border-radius: 50%; }
.item-label { font-family: var(--head); letter-spacing: 1px; color: var(--brand-dark); font-size: 1rem; }
.item-name { font-family: var(--head); letter-spacing: 1px; font-size: 1.5rem; line-height: 1.05; }
.item-desc { color: var(--muted); font-size: 1rem; }
.tip { text-align: left; background: var(--brand); border: 3px solid var(--ink); padding: 10px 12px; border-radius: 4px; transform: rotate(-.5deg); }

/* ---------- batoh ---------- */
.bag-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.bag-item { display: flex; gap: 12px; background: var(--white); border: 3px solid var(--ink); border-radius: var(--radius); padding: 10px 12px; box-shadow: 3px 3px 0 var(--ink); }
.bag-item.locked { opacity: .5; background: #eee; box-shadow: none; border-style: dashed; }
.bag-icon { font-size: 2rem; flex: none; }
.bag-name { font-family: var(--head); letter-spacing: 1px; font-size: 1.3rem; }
.bag-desc { font-size: .98rem; color: var(--muted); }
.bag-tip { font-size: .98rem; margin-top: 6px; background: var(--brand-light); border-radius: 6px; padding: 4px 8px; }

/* ---------- hodnocení (obálka osvědčení) ---------- */
.cert {
  position: relative; text-align: center; padding: 30px 22px; margin-bottom: 24px;
  background-color: var(--brand); border: 5px solid var(--ink); box-shadow: 10px 10px 0 var(--ink);
  background-image: radial-gradient(rgba(0, 0, 0, .12) 1.6px, transparent 1.9px), repeating-conic-gradient(from 0deg at 50% 40%, rgba(255,255,255,.35) 0 6deg, transparent 6deg 18deg);
  background-size: 10px 10px, 100% 100%;
}
.cert-badge { font-size: 3.2rem; }
.cert-small { font-family: var(--head); letter-spacing: 3px; font-size: 1.1rem; background: var(--ink); color: var(--white); display: inline-block; padding: 2px 12px; }
.cert h1 { font-size: clamp(2.6rem, 8vw, 4.4rem); margin: 10px 0 4px; color: var(--white); -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 6px 6px 0 var(--ink); }
.cert-name {
  font: inherit; letter-spacing: inherit; color: inherit; -webkit-text-stroke: inherit; paint-order: inherit; text-shadow: inherit;
  background: none; border: 0; padding: 0 6px; margin: 0; cursor: pointer; border-radius: 8px; overflow-wrap: anywhere;
}
.cert-name.long { font-size: .62em; }
.cert-name:hover, .cert-name:focus-visible { background: rgba(255, 255, 255, .35); outline: 3px dashed var(--ink); outline-offset: 2px; }
.cert-edit {
  display: inline-grid; place-items: center; width: 34px; height: 34px; margin-left: 10px; vertical-align: middle;
  font-size: 18px; line-height: 1; background: var(--white); border: 3px solid var(--ink); border-radius: 50%;
  box-shadow: 3px 3px 0 var(--ink); -webkit-text-stroke: 0; text-shadow: none; transform: rotate(8deg);
}
.cert-name:hover .cert-edit, .cert-name:focus-visible .cert-edit { background: var(--brand); }
.cert-name-form { display: grid; gap: 8px; max-width: 460px; margin: 0 auto; font-family: var(--font); font-size: 1rem; color: var(--ink); -webkit-text-stroke: 0; text-shadow: none; letter-spacing: 0; text-align: left; }
.cert-name-form label { font-family: var(--head); font-size: 1.2rem; letter-spacing: 1px; }
.cert-name-form input { font: inherit; font-size: 1.3rem; padding: 8px 12px; border: 3px solid var(--ink); border-radius: 8px; box-shadow: var(--shadow-sm); }
.cert-name-actions { display: flex; gap: 10px; }
.cert-name-note { margin: 0; font-size: .9rem; line-height: 1.3; }
.cert-rank { font-family: var(--head); font-size: 2rem; letter-spacing: 1px; background: var(--orange); color: var(--white); -webkit-text-stroke: 1.5px var(--ink); paint-order: stroke fill; display: inline-block; padding: 0 16px; border: 3px solid var(--ink); transform: rotate(-2deg); box-shadow: 4px 4px 0 var(--ink); }
.cert-score { margin: 14px 0 8px; font-size: 1.2rem; }
.cert-score b { font-family: var(--head); font-weight: 400; font-size: 2rem; }
.cert-bar { height: 18px; background: var(--white); border: 3px solid var(--ink); border-radius: 99px; overflow: hidden; max-width: 420px; margin: 0 auto 14px; }
.cert-bar div { height: 100%; background: repeating-linear-gradient(45deg, var(--green) 0 10px, #58d97f 10px 20px); }
.cert p { max-width: 560px; margin: 0 auto 8px; font-size: 1.15rem; }
.cert .warn { color: #a01010; }
.cert-items { font-size: 1.8rem; letter-spacing: 4px; margin: 8px 0; }
.cert-date { font-family: var(--head); letter-spacing: 2px; }
.rules { padding-left: 26px; display: grid; gap: 6px; font-size: 1.1rem; }
.cheat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 16px; }
.cheat-card { background: #f5fcf7; border: 3px solid var(--ink); border-radius: var(--radius); padding: 10px 14px 6px; box-shadow: 3px 3px 0 var(--ink); }
.cheat-card h4 { font-family: var(--head); font-weight: 400; font-size: 1.3rem; letter-spacing: 1px; margin: 0 0 4px; }
.cheat-card ul { margin: 0; padding-left: 20px; display: grid; gap: 4px; font-size: 1rem; }
@media (max-width: 760px) { .cheat-grid { grid-template-columns: 1fr; } }
.contacts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.contacts-sub { font-family: var(--head); font-weight: 400; font-size: 1.3rem; letter-spacing: 1px; margin: 18px 0 10px; }
.contact { display: flex; gap: 10px; align-items: flex-start; background: #f3f6ff; border: 3px solid var(--ink); border-radius: var(--radius); padding: 8px 12px; }
.c-icon { font-size: 1.6rem; }
.c-val { font-family: var(--head); letter-spacing: 1px; font-size: 1.2rem; color: var(--blue); margin-left: 4px; }
.c-link { display: inline-block; margin-top: 2px; font-size: .95rem; font-weight: 700; color: var(--blue); text-decoration: underline; text-underline-offset: 2px; }
.c-link:hover, .c-link:focus-visible, a.c-val:hover, a.c-val:focus-visible { background: var(--brand); outline: none; }
a.c-val { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.end-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; margin: 8px 0 30px; }
.cert-actions { display: grid; justify-items: center; gap: 12px; margin: -8px 0 26px; text-align: center; }
.share { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; }
.share-label { font-family: var(--head); font-size: 1.3rem; letter-spacing: 1px; }
.share-btn { text-decoration: none; color: var(--white); display: inline-block; }
.share-fb { background: #1877f2; }
.share-li { background: #0a66c2; }
.share-ig { background: linear-gradient(45deg, #f9a825, #e1306c 50%, #833ab4); }
.share-note { max-width: 560px; margin: 0; }
.share-main { font-size: 1.35rem; }
[hidden] { display: none !important; } /* atribut hidden musí vyhrát i nad display z tříd */
.cert-form { display: grid; gap: 12px; margin-top: 8px; }
.ts-box { min-height: 0; }
.cert-form .check { display: flex; gap: 10px; align-items: flex-start; font-size: 1rem; line-height: 1.35; }
.cert-form .check input { width: 20px; height: 20px; flex: none; margin-top: 2px; accent-color: var(--blue); }
.cert-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.form-msg { margin: 0; min-height: 1.2em; font-weight: 700; }
.form-msg.bad { color: #a01010; }
.cert-done p { font-size: 1.1rem; }
.share-steps { padding-left: 22px; display: grid; gap: 6px; margin: 0 0 12px; }
.share-text { width: 100%; font: inherit; font-size: .95rem; padding: 8px 10px; border: 3px solid var(--ink); border-radius: 8px; resize: vertical; background: #f5fcf7; }

/* ---------- mobil ---------- */
@media (max-width: 760px) {
  body { font-size: 17px; }
  .app { padding: 10px 16px; }
  .loc-grid, .bag-grid, .contacts { grid-template-columns: 1fr; }
  .inspect { grid-template-columns: 1fr; }
  .inspect-side { position: static; }
  .found-list { max-height: none; }
  .hide-sm { display: none; }
  .scene-title { display: none; }
  .say { font-size: 1.15rem; }
  .loc-hero { aspect-ratio: 16 / 8; }
  .shop-product { grid-template-columns: 1fr; }
  .tb-score span { display: none; }
  .cover-burst { width: 120px; height: 86px; font-size: 1.1rem; }
  .cover-cap { font-size: .9rem; }
  .panel-cap { font-size: .9rem; }
  .sfx span { font-size: 2.6rem; }
  .sfx::before { width: 220px; height: 110px; }
  .sfx::after { width: 204px; height: 96px; }
}
@media (max-width: 420px) {
  .gender-card svg { width: 80px; height: 150px; }
  .stage { aspect-ratio: 4 / 3; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- patička: autor, ochrana osobních údajů, SBOM ---------- */
.site-footer {
  max-width: 1100px; margin: 8px auto 24px; padding: 10px 16px;
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px;
  text-align: center; font-family: var(--head); font-size: 1.15rem; letter-spacing: 1px; color: var(--ink);
}
.site-footer .sep { opacity: .45; }
.site-footer a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.site-footer a:hover, .site-footer a:focus-visible { background: var(--brand); outline: none; }

/* ---------- tisk osvědčení ---------- */
@media print {
  body { background: #fff; }
  .topbar, .panel, .end-actions, .cert-actions, .toast, .site-footer { display: none !important; }
  .cert-edit { display: none; }
  .cert { box-shadow: none; margin: 40px auto; max-width: 700px; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ---------- platební stránka a Wi-Fi portál (zkoumané dokumenty) ---------- */
.pay-box, .portal { padding: 16px; display: grid; gap: 10px; }
.pay-box h3, .portal h3 { font-family: var(--doc); font-weight: 800; letter-spacing: 0; font-size: 1.1rem; margin: 0; }
.pay-price { font-size: 1.6rem; font-weight: 800; color: #1d2333; }
.pay-field { background: #f1f3f8; border: 1px solid #cfd5e3; border-radius: 8px; padding: 8px 10px; font-size: .92rem; }
.pay-field span:not(.flag) { display: block; color: #8a93ab; letter-spacing: 2px; margin-top: 2px; }
.pay-note { background: #fff4d6; border-radius: 8px; padding: 8px 10px; font-size: .92rem; }
.pay-small { font-size: .8rem; color: #6b7280; }
.portal-logo { font-weight: 800; font-size: 1.3rem; color: #2a5bd7; }
.portal p { margin: 0; }

/* ---------- potvrzovací okno (nad ostatními okny) ---------- */
.overlay-backdrop { z-index: 60; }
.confirm-backdrop { z-index: 70; }
.modal.confirm { width: min(440px, 100%); text-align: center; }
.modal.confirm .modal-actions { justify-content: center; }

/* ---------- cookie lišta (js/consent.js) ---------- */
.consent {
  position: fixed; left: 50%; bottom: 14px; transform: translateX(-50%); z-index: 90;
  width: min(760px, calc(100% - 32px)); max-height: calc(100vh - 28px); overflow: auto;
  background: var(--white); border: var(--border); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 14px 18px 16px; animation: fade .18s;
}
.consent-title {
  display: inline-block; margin: 0 0 8px; padding: 2px 12px; background: var(--brand); border: 3px solid var(--ink);
  font-family: var(--head); font-weight: normal; font-size: 1.45rem; letter-spacing: 1px; transform: rotate(-1.5deg);
}
.consent-text { margin: 0 0 12px; line-height: 1.35; }
.consent-text a { color: var(--blue); }
.consent-age { margin: -4px 0 12px; padding: 4px 10px; background: var(--paper); border-left: 4px solid var(--brand); line-height: 1.3; }
.consent-settings { display: grid; gap: 8px; margin: 0 0 12px; }
.consent-row {
  display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: start;
  padding: 8px 10px; border: 2px solid var(--ink); border-radius: 8px; background: var(--paper); line-height: 1.3; cursor: pointer;
}
.consent-row input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--blue); }
.consent-row input:disabled { cursor: not-allowed; }
.consent-row code { font-size: .85em; }
.consent-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.consent-actions [data-c="reject"], .consent-actions [data-c="accept"] { background: var(--brand); min-width: 130px; }
.consent-actions [data-c="settings"], .consent-actions [data-c="save"] { margin-left: auto; }
@media (max-width: 520px) {
  .consent-actions [data-c="reject"], .consent-actions [data-c="accept"] { flex: 1 1 40%; min-width: 0; }
  .consent-actions [data-c="settings"], .consent-actions [data-c="save"] { margin-left: 0; flex: 1 1 100%; }
}
@media print { .consent { display: none !important; } }

/* ---------- nápověda a hlášení chyb ---------- */
.help { display: grid; gap: 8px; text-align: left; }
.help details { border: 3px solid var(--ink); border-radius: 8px; background: var(--white); box-shadow: var(--shadow-sm); }
.help summary { cursor: pointer; padding: 8px 12px; font-family: var(--head); font-size: 1.3rem; letter-spacing: 1px; }
.help details[open] summary { background: var(--brand); border-bottom: 3px solid var(--ink); }
.help details > :not(summary) { margin: 10px 14px; line-height: 1.4; }
.help ul { padding-left: 20px; }
.help li { margin: 4px 0; }
kbd { display: inline-block; padding: 0 6px; border: 2px solid var(--ink); border-bottom-width: 3px; border-radius: 5px; background: var(--paper); font-family: var(--font); font-size: .9em; line-height: 1.3; }
.bug-form select, .bug-form textarea {
  font: inherit; font-family: var(--font); font-size: 1.05rem; letter-spacing: 0; padding: 8px 10px;
  border: 3px solid var(--ink); border-radius: 8px; background: var(--white); color: var(--ink);
}
.bug-form textarea { resize: vertical; min-height: 110px; }
.bug-ctx summary { cursor: pointer; font-size: .95rem; }
.bug-ctx pre { margin: 6px 0; padding: 8px; background: var(--paper); border: 2px dashed var(--ink); border-radius: 6px; font-size: .8rem; white-space: pre-wrap; overflow-wrap: anywhere; }
.field .muted { font-family: var(--font); letter-spacing: 0; font-size: .95rem; }

/* ---------- logo Guardians.cz ---------- */
.cert-brand { margin-top: 12px; }
.cert-logo { width: min(240px, 60%); height: auto; display: inline-block; }
.footer-brand { flex-basis: 100%; display: flex; justify-content: center; margin-top: 10px; }
.footer-logo { width: 170px; height: auto; display: block; }
.site-footer a.brand-link { text-decoration: none; display: inline-block; padding: 2px 4px; border-radius: 4px; }
/* logo v patičce: černé, bez efektu po najetí myší; pro ovládání klávesnicí jen obrys */
.site-footer a.brand-link:hover { background: none; }
.site-footer a.brand-link:focus-visible { background: none; outline: 3px solid var(--ink); outline-offset: 2px; }
