/* Letam portál: tmavý FPV / Cyber vzhled, mobile-first, bez frameworku */
:root {
  --bg: #0a0f14; --panel: #111820; --panel2: #17212b; --line: #223040;
  --neon: #39ff88; --cyan: #2dd4ff; --fg: #e6edf3; --muted: #8b9aab;
  --danger: #ff5c7a; --warn: #ffc857;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace;
  --sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg); color: var(--fg);
  font: 16px/1.55 var(--sans); overflow-x: hidden; -webkit-tap-highlight-color: transparent; }
main { flex: 1; }
a { color: var(--cyan); }
::selection { background: rgba(57, 255, 136, .35); }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5em; }
h1 { font-size: 1.75rem; font-weight: 800; }
h2 { font-size: 1.35rem; font-weight: 800; margin-top: 1.4em; }
h3 { font-size: 1.05rem; font-weight: 700; margin-top: 1.2em; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.2em; margin: 0 0 1em; }
img, video { max-width: 100%; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.neon { color: var(--neon); }
.cyan { color: var(--cyan); }
.danger { color: var(--danger); }
.breakall { word-break: break-all; }
.label { font: 11px/1.2 var(--mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin-bottom: .8em; }
.label.cyan { color: var(--cyan); }
.wrap { width: 100%; max-width: 64rem; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 42rem; }
.section { padding-top: 2rem; padding-bottom: 2rem; }
.skip { position: absolute; left: -999px; top: 0; background: var(--neon); color: var(--bg); padding: .5em 1em; z-index: 10; }
.skip:focus { left: 8px; top: 8px; }

/* hlavička a patička */
.top { border-bottom: 1px solid var(--line); background: rgba(10, 15, 20, .92); position: sticky; top: 0; z-index: 5; backdrop-filter: blur(6px); }
.top-in { display: flex; align-items: center; justify-content: space-between; min-height: 56px; gap: 12px; }
.brand { font: 800 1.1rem var(--mono); letter-spacing: .14em; color: var(--fg); text-decoration: none; }
.brand-mark { color: var(--neon); margin-right: .35em; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a:not(.btn) { color: var(--muted); text-decoration: none; padding: 8px 8px; font-size: .9rem; border-radius: 6px; }
.nav a:not(.btn):hover, .nav a[aria-current] { color: var(--fg); }
.foot { border-top: 1px solid var(--line); margin-top: 2rem; padding: 18px 0; font-size: .85rem; }
.foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
@media (max-width: 520px) { .nav a:nth-child(-n+2) { display: none; } }

/* panely, tlačítka, formuláře */
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 16px; margin-bottom: 16px; }
.panel > :last-child { margin-bottom: 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 8px 16px; border: 1px solid var(--line);
  border-radius: 8px; background: var(--panel2); color: var(--fg); font: 600 .9rem var(--sans); text-decoration: none; cursor: pointer; touch-action: manipulation; }
.btn:hover { border-color: var(--cyan); color: var(--cyan); }
.btn-primary { background: var(--neon); border-color: var(--neon); color: var(--bg); box-shadow: 0 0 18px -4px rgba(57, 255, 136, .6); }
.btn-primary:hover { color: var(--bg); border-color: var(--neon); filter: brightness(1.1); }
.btn-danger { border-color: var(--danger); color: var(--danger); background: transparent; }
.btn-danger:hover { border-color: var(--danger); color: #fff; background: var(--danger); }
.btn-sm { min-height: 36px; padding: 4px 12px; font-size: .8rem; }
.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.inline { display: inline-block; margin: 0 8px 8px 0; }
.inline.row { display: inline-flex; }
.grid2 { display: grid; gap: 16px; grid-template-columns: 1fr; }
.grid2 > .panel { margin-bottom: 0; }
@media (min-width: 760px) { .grid2 { grid-template-columns: 1fr 1fr; } h1 { font-size: 2.1rem; } }
.form .field, .field { margin-bottom: 18px; border: 0; padding: 0; min-width: 0; }
.field > label, legend { display: block; font-weight: 600; margin-bottom: 6px; padding: 0; }
.input { width: 100%; min-height: 44px; padding: 8px 12px; background: var(--bg); color: var(--fg); border: 1px solid var(--line); border-radius: 8px; font: 16px var(--sans); }
.row > .input { width: auto; flex: 1 1 10rem; }
textarea.input { resize: vertical; }
.input.mono { font-family: var(--mono); }
.input:focus { border-color: var(--cyan); outline: none; }
.input::placeholder { color: rgba(139, 154, 171, .6); }
input[type=file].input { padding: 8px; }
.hint { color: var(--muted); font-size: .85rem; margin: 6px 0 0; }
.field-err { color: var(--danger); font-size: .9rem; margin: 6px 0 0; }
.has-err .input { border-color: var(--danger); }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; margin-bottom: 10px; cursor: pointer; }
.check input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--neon); flex: none; }
.pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 8px; }
.sub { display: block; font-size: .85rem; color: var(--muted); font-weight: 400; }
.sub .input { margin-top: 4px; }
.grow { flex: 1 1 14rem; }
.narrow-in { width: 6rem !important; flex: none !important; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 12px 14px; border-radius: 8px; border: 1px solid; margin: 16px 0; }
.alert-ok { border-color: rgba(57, 255, 136, .4); background: rgba(57, 255, 136, .08); color: var(--neon); }
.alert-err { border-color: rgba(255, 92, 122, .5); background: rgba(255, 92, 122, .1); color: var(--danger); }
.panel .alert { margin-top: 0; }

/* landing */
.hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.hero-grid { position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(to right, rgba(45, 212, 255, .09) 1px, transparent 1px), linear-gradient(to bottom, rgba(45, 212, 255, .09) 1px, transparent 1px);
  background-size: 36px 36px; -webkit-mask-image: radial-gradient(ellipse at 50% 30%, #000 20%, transparent 75%); mask-image: radial-gradient(ellipse at 50% 30%, #000 20%, transparent 75%); }
.scanlines { position: absolute; inset: 0; pointer-events: none; opacity: .7; background-image: repeating-linear-gradient(to bottom, rgba(255, 255, 255, .035) 0 1px, transparent 1px 4px); }
.hero-in { position: relative; padding-top: 2.2rem; padding-bottom: 2.5rem; }
.hero h1 { font-size: 1.9rem; max-width: 46rem; font-weight: 800; }
.glow { text-shadow: 0 0 24px rgba(57, 255, 136, .35); }
.lead { max-width: 40rem; font-size: 1.05rem; color: var(--muted); }
@media (min-width: 760px) { .hero h1 { font-size: 3rem; } .hero-in { padding-top: 4rem; } .lead { font-size: 1.15rem; } }
.steps { list-style: none; padding: 0; display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .steps { grid-template-columns: 1fr 1fr; } }
.step { display: flex; gap: 12px; margin: 0; }
.step h3 { margin: 0 0 .3em; }
.step p { margin: 0; font-size: .92rem; }
.step-n { flex: none; width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid rgba(57, 255, 136, .5); border-radius: 8px; color: var(--neon); font-size: 1.1rem; }
.limits ul { margin: 0; color: var(--muted); }
.limits li { margin-bottom: .4em; }
.limits strong { color: var(--fg); }
.cta { position: relative; overflow: hidden; border-color: rgba(57, 255, 136, .3); }
.cta-in { position: relative; max-width: 32rem; }

/* before / after slider */
.ba { max-width: 48rem; margin-top: 1.5rem; }
.ba-box { position: relative; width: 100%; aspect-ratio: 1.7; background: #000; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; cursor: ew-resize; user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.ba-box video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #000; pointer-events: none; }
.ba-before { clip-path: inset(0 50% 0 0); }
.ba-tag { position: absolute; top: 8px; padding: 2px 6px; border-radius: 4px; background: rgba(0, 0, 0, .6); font-size: 11px; font-weight: 700; letter-spacing: .12em; pointer-events: none; }
.ba-tag-l { left: 8px; color: var(--cyan); }
.ba-tag-r { right: 8px; color: var(--neon); }
.ba-line { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: var(--neon); box-shadow: 0 0 10px var(--neon); pointer-events: none; }
.ba-handle { position: absolute; top: 50%; left: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; display: grid; place-items: center; border: 2px solid var(--neon); border-radius: 50%;
  background: rgba(10, 15, 20, .8); color: var(--neon); box-shadow: 0 0 14px var(--neon); font-size: 12px; }
.ba-play { position: absolute; right: 8px; bottom: 8px; width: 40px; height: 40px; border: 0; border-radius: 6px; background: rgba(0, 0, 0, .6); color: var(--fg); cursor: pointer; font-size: 14px; }

/* stav objednávky */
.status-badge { display: inline-flex; align-items: center; gap: 10px; font-size: 1.1rem; font-weight: 700; margin-bottom: .6em; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--muted); display: inline-block; margin-right: 8px; }
.status-badge .dot { margin: 0; }
.status-faze1 .dot, .status-faze2 .dot, .status-stahuje_se .dot { background: var(--cyan); animation: pulse 1.4s ease-in-out infinite; }
.status-kontrola .dot, .status-hotovo .dot { background: var(--neon); }
.status-chyba .dot, .status-zrusena .dot { background: var(--danger); }
.status-nova .dot, .status-ceka_na_stazeni .dot { background: var(--warn); }
@keyframes pulse { 50% { opacity: .3; } }
@media (prefers-reduced-motion: reduce) { .dot { animation: none !important; } }
.krok { font-size: .9rem; color: var(--cyan); }
.osa { list-style: none; display: flex; gap: 4px; padding: 0; margin: 16px 0 0; overflow-x: auto; }
.osa li { flex: 1 1 0; min-width: 4.2rem; text-align: center; font: 11px var(--mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); border-top: 3px solid var(--line); padding-top: 6px; }
.osa li.done { border-color: var(--neon); color: var(--fg); }
.osa li.now { border-color: var(--cyan); color: var(--cyan); }
.player { width: 100%; max-height: 70vh; background: #000; border: 1px solid var(--line); border-radius: 10px; }
.fb { display: flex; gap: 12px; margin-bottom: 14px; }
.fb-opt { cursor: pointer; }
.fb-opt input { position: absolute; opacity: 0; }
.fb-opt span { display: grid; place-items: center; width: 56px; height: 56px; font-size: 1.6rem; border: 1px solid var(--line); border-radius: 12px; background: var(--panel2); }
.fb-opt input:checked + span { border-color: var(--neon); box-shadow: 0 0 12px -2px var(--neon); }
.fb-opt input:focus-visible + span { outline: 2px solid var(--cyan); }
.timeline { list-style: none; padding: 0; margin: 0; }
.timeline li { display: flex; flex-direction: column; gap: 2px; padding: 8px 0 8px 14px; border-left: 2px solid var(--line); font-size: .92rem; }
.timeline time { font-size: .75rem; color: var(--muted); }
.timeline .tl-klient { border-color: var(--cyan); }
.timeline .tl-most { border-color: var(--neon); }
.timeline .tl-admin { border-color: var(--warn); }
@media (min-width: 640px) { .timeline li { flex-direction: row; gap: 14px; } .timeline time { flex: none; width: 9.5rem; padding-top: 2px; } }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 14px; margin: 0 0 1em; }
.kv dt { color: var(--muted); font-size: .85rem; padding-top: 2px; }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.olist { list-style: none; padding: 0; }
.olist-item { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.olist-item p { margin: 0 0 .3em; }
.chip { display: inline-block; padding: 1px 10px; border: 1px solid var(--line); border-radius: 99px; font: 12px var(--mono); color: var(--muted); white-space: nowrap; }
.chip-nova, .chip-ceka_na_stazeni { border-color: var(--warn); color: var(--warn); }
.chip-stahuje_se, .chip-faze1, .chip-faze2 { border-color: var(--cyan); color: var(--cyan); }
.chip-kontrola, .chip-hotovo { border-color: var(--neon); color: var(--neon); }
.chip-chyba { border-color: var(--danger); color: var(--danger); }
.chip-zrusena { color: var(--muted); text-decoration: line-through; }
.prose h2 { margin-top: 1.6em; }
.prose li { margin-bottom: .4em; }

/* administrace */
.admin .top { position: static; }
.anav { display: flex; gap: 4px; overflow-x: auto; padding-bottom: 8px; }
.anav a { color: var(--muted); text-decoration: none; padding: 8px 12px; border-radius: 8px; white-space: nowrap; font-size: .9rem; }
.anav a:hover { color: var(--fg); }
.anav a[aria-current] { background: var(--panel2); color: var(--neon); }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 1rem; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(5, 1fr); } }
.card { display: flex; flex-direction: column; align-items: center; padding: 12px 6px; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--fg); }
.card-n { font-size: 1.6rem; font-weight: 800; }
.card-l { font-size: .75rem; color: var(--muted); text-align: center; }
.card:hover { border-color: var(--cyan); }
.bridge .dot { background: var(--danger); }
.bridge-ok .dot { background: var(--neon); }
.bridge-ok { border-color: rgba(57, 255, 136, .3); }
.bridge-bad { border-color: rgba(255, 92, 122, .4); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.filters .input { width: auto; flex: 1 1 11rem; }
.tablewrap { margin-bottom: 1rem; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; font: 11px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--muted); padding: 8px; border-bottom: 1px solid var(--line); }
.table td { padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tbody tr:hover { background: rgba(255, 255, 255, .02); }
@media (max-width: 700px) {
  .table thead { display: none; }
  .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
  .table tr { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-bottom: 10px; }
  .table td { border: 0; padding: 4px 0; display: flex; justify-content: space-between; gap: 12px; text-align: right; }
  .table td::before { content: attr(data-l); color: var(--muted); font: 11px var(--mono); text-transform: uppercase; text-align: left; flex: none; padding-top: 3px; }
}
.pager { display: flex; gap: 12px; align-items: center; justify-content: center; }
.files { list-style: none; padding: 0; }
.files li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.files li strong { min-width: 5rem; }
.ref { max-width: 100%; max-height: 260px; border-radius: 8px; border: 1px solid var(--line); }
.kodbox h3 { margin-top: 0; }
