/* =========================================================
   Pety Random — styl à la Magic UI / Aceternity / Motion Primitives
   ========================================================= */
:root {
  --bg: #09090b;
  --card: #0c0c0f;
  --fg: #fafafa;
  --muted: #a1a1aa;
  --dim: #71717a;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);

  --ig-1: #feda75;
  --ig-2: #fa7e1e;
  --ig-3: #d62976;
  --ig-4: #962fbf;
  --ig-5: #4f5bd5;
  --wall: #8fc1d4;   /* světle modrá zeď z jeho videí */
  --sun: #f2cf5b;    /* žlutá zeď */
  --beam-a: var(--sun);
  --beam-b: var(--wall);

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --spring: cubic-bezier(0.34, 1.4, 0.64, 1);
  --font: "Geist", "Inter", system-ui, -apple-system, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; color-scheme: dark; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--fg);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  letter-spacing: -0.01em;
}
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
code { font-family: var(--mono); font-size: .88em; padding: .12em .4em; border-radius: 6px; background: rgba(255,255,255,.06); border: 1px solid var(--line); }
kbd { font-family: var(--mono); font-size: 11px; padding: 2px 6px; border-radius: 6px; border: 1px solid var(--line-2); border-bottom-width: 2px; color: var(--muted); background: rgba(255,255,255,.03); }
::selection { background: rgba(143, 193, 212, .45); color: #000; }

.i { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.i--sm { width: 16px; height: 16px; }

/* ---------- pozadí ---------- */
.bg { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.dots {
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.16) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 60% 55% at 50% 35%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 60% 55% at 50% 35%, #000 20%, transparent 75%);
}
.beam {
  position: absolute; top: -40%; left: -10%; width: 140%; height: 169%; opacity: 0;
  animation: spotlight 2s var(--ease) .4s forwards;
}
@keyframes spotlight { from { opacity: 0; transform: translate(-72%, -62%) scale(.5); } to { opacity: 1; transform: translate(-50%, -40%) scale(1); } }
.glow {
  position: absolute; width: 700px; height: 500px; right: -10%; top: 5%;
  background: radial-gradient(closest-side, rgba(143,193,212,.13), transparent);
  filter: blur(40px);
}

/* ---------- avatar + IG ring (navbar) ---------- */
@property --a { syntax: "<angle>"; initial-value: 0deg; inherits: false; }
@keyframes spin { to { --a: 360deg; } }
.ring {
  --size: 44px; --pad: 2px;
  position: relative; display: inline-grid; place-items: center;
  width: var(--size); height: var(--size); border-radius: 50%; flex: none;
  isolation: isolate;
}
.ring::before {
  content: ""; position: absolute; inset: 0; border-radius: 50%; z-index: -2;
  background: conic-gradient(from var(--a), var(--ig-1), var(--ig-2), var(--ig-3), var(--ig-4), var(--ig-5), var(--ig-1));
  animation: spin 4s linear infinite;
}
.ring::after { content: ""; position: absolute; inset: var(--pad); border-radius: 50%; background: var(--bg); z-index: -1; }
.ring--sm { --size: 38px; }
.avatar, .avatar__fallback { grid-area: 1/1; width: calc(100% - 7px); height: calc(100% - 7px); border-radius: 50%; object-fit: cover; }
.avatar__fallback { display: grid; place-items: center; font-weight: 700; font-size: 13px; background: #27272a; }
.avatar:not([src]) { display: none; }
.avatar[src] + .avatar__fallback { display: none; }

/* ---------- nav ---------- */
.nav {
  position: fixed; top: 16px; left: 50%; translate: -50% 0; z-index: 50;
  width: min(1120px, calc(100% - 32px));
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 7px 7px 7px 9px; border-radius: 999px;
  background: rgba(15,15,18,.6); border: 1px solid var(--line);
  backdrop-filter: blur(18px) saturate(160%); -webkit-backdrop-filter: blur(18px) saturate(160%);
  box-shadow: 0 10px 40px -10px rgba(0,0,0,.6);
  animation: drop .9s var(--ease) both;
}
@keyframes drop { from { opacity: 0; translate: -50% -30px; } }
.nav__brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; }
.nav__name { display: inline-flex; align-items: center; gap: 5px; }
.verified { width: 16px; height: 16px; color: #3897f0; }
.nav__links { display: flex; align-items: center; gap: 4px; font-size: 14px; color: var(--muted); }
.nav__links > a:not(.btn-border) { padding: 8px 14px; border-radius: 999px; transition: color .2s, background .2s; }
.nav__links > a:not(.btn-border):hover { color: var(--fg); background: rgba(255,255,255,.05); }
.btn-border { position: relative; padding: 1.5px; border-radius: 999px; overflow: hidden; color: var(--fg); font-weight: 600; }
.btn-border::before {
  content: ""; position: absolute; inset: -200%;
  background: conic-gradient(from var(--a), transparent 0 60%, var(--ig-2), var(--ig-3), var(--ig-4), transparent 90%);
  animation: spin 3s linear infinite;
}
.btn-border span { position: relative; display: block; padding: 8px 16px; border-radius: 999px; background: #111114; }

/* ---------- layout ---------- */
main { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.hero {
  min-height: 100svh; padding: 120px 0 72px;
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: clamp(40px, 7vw, 96px);
}

/* blur-fade (Magic UI) */
.fade { opacity: 0; filter: blur(6px); transform: translateY(10px); transition: opacity .8s var(--ease), filter .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
.fade.in { opacity: 1; filter: none; transform: none; }
.fade-io { opacity: 0; filter: blur(6px); transform: translateY(14px); transition: opacity .8s var(--ease), filter .8s var(--ease), transform .8s var(--ease); }
.fade-io.in { opacity: 1; filter: none; transform: none; }

/* profil */
.profile {
  display: inline-flex; align-items: center; gap: 12px; padding: 6px 14px 6px 6px; border-radius: 999px;
  border: 1px solid var(--line); background: rgba(255,255,255,.03); transition: border-color .3s, background .3s;
}
.profile:hover { border-color: var(--line-2); background: rgba(255,255,255,.05); }
.ring--lg { --size: 52px; --pad: 2px; }
.ring--lg .avatar { width: calc(100% - 8px); height: calc(100% - 8px); }
.profile__text { display: flex; flex-direction: column; gap: 2px; text-align: left; }
.profile__text b { display: inline-flex; align-items: center; gap: 5px; font-size: 15px; font-weight: 600; }
.profile__text .shiny-badge__text { font-size: 13px; }
.profile__arrow { color: var(--dim); margin-left: 6px; transition: transform .3s var(--ease), color .3s; }
.profile:hover .profile__arrow { color: var(--fg); transform: translate(2px, -2px); }

/* animated shiny text (Magic UI) */
.shiny-badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px 6px 14px; border-radius: 999px; font-size: 13px;
  border: 1px solid var(--line); background: rgba(255,255,255,.03);
  color: var(--muted); transition: border-color .3s, background .3s;
}
.shiny-badge:hover { border-color: var(--line-2); background: rgba(255,255,255,.05); }
.shiny-badge .i { transition: transform .3s var(--ease); }
.shiny-badge:hover .i { transform: translateX(3px); }
.shiny-badge__text {
  background: linear-gradient(110deg, var(--muted) 0 40%, #fff 50%, var(--muted) 60% 100%) 0 0 / 250% 100%;
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: shiny 3.2s linear infinite;
}
.shiny-badge__text span { font-variant-numeric: tabular-nums; }
@keyframes shiny { from { background-position: 100% 0; } to { background-position: 0% 0; } }

/* title — text generate effect (Aceternity) */
.title {
  font-size: clamp(48px, 7.2vw, 88px); font-weight: 600; line-height: 1; letter-spacing: -0.045em;
  margin: 26px 0 22px;
}
.title .w {
  display: inline-block; opacity: 0; filter: blur(10px); animation: word .7s var(--ease) forwards; animation-delay: var(--d);
  background: linear-gradient(180deg, #fff 35%, rgba(255,255,255,.55));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  padding-bottom: .08em;
}
@keyframes word { to { opacity: 1; filter: blur(0); } }

.lede { color: var(--muted); font-size: 18px; line-height: 1.6; max-width: 36ch; }
/* flip words (Aceternity) */
.flip { display: inline-block; color: var(--fg); font-weight: 500; position: relative; }
.flip .l { display: inline-block; opacity: 0; filter: blur(8px); transform: translateY(8px); animation: letterIn .45s var(--ease) forwards; animation-delay: var(--d); }
.flip.out { animation: flipOut .35s var(--ease) forwards; }
@keyframes letterIn { to { opacity: 1; filter: blur(0); transform: none; } }
@keyframes flipOut { to { opacity: 0; filter: blur(8px); transform: translate(10px, -10px) scale(1.3); } }

.cta { display: flex; align-items: center; gap: 18px; margin-top: 34px; flex-wrap: wrap; }
.hint { font-size: 13px; color: var(--dim); display: inline-flex; align-items: center; gap: 8px; }

/* shimmer button (Magic UI) */
.btn-shimmer {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px; border-radius: 999px; font-size: 15px; font-weight: 500; color: #fff;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.1);
  box-shadow: 0 10px 30px -10px rgba(143,193,212,.35);
  transition: transform .3s var(--ease), box-shadow .3s;
}
.btn-shimmer:hover { box-shadow: 0 10px 36px -8px rgba(143,193,212,.55); }
.btn-shimmer:active { transform: translateY(1px) scale(.98); }
.btn-shimmer > :not(.btn-shimmer__spark):not(.btn-shimmer__bg) { position: relative; z-index: 1; }
.btn-shimmer__spark { position: absolute; inset: 0; z-index: -2; overflow: visible; container-type: size; filter: blur(2px); }
.btn-shimmer__spark span {
  position: absolute; inset: 0; aspect-ratio: 1; height: 100cqh;
  animation: slide 3s ease-in-out infinite alternate;
}
.btn-shimmer__spark span::before {
  content: ""; position: absolute; inset: -100%; width: auto;
  background: conic-gradient(from 225deg, transparent 0, #fff 90deg, transparent 90deg);
  animation: spin-around 6s infinite linear;
}
.btn-shimmer__bg { position: absolute; inset: 1.5px; z-index: -1; border-radius: inherit; background: #050507; box-shadow: inset 0 -8px 10px rgba(255,255,255,.1); transition: box-shadow .3s; }
.btn-shimmer:hover .btn-shimmer__bg { box-shadow: inset 0 -6px 10px rgba(255,255,255,.2); }
@keyframes slide { to { transform: translateX(calc(100cqw - 100%)); } }
@keyframes spin-around { 0% { transform: rotate(0); } 15%,35% { transform: rotate(90deg); } 65%,85% { transform: rotate(270deg); } 100% { transform: rotate(360deg); } }
#shuffleIcon { transition: transform .6s var(--ease); }
.btn-shimmer.spin #shuffleIcon { transform: rotate(360deg); }

/* stats */
.stats { display: flex; margin-top: 52px; border-top: 1px solid var(--line); padding-top: 22px; max-width: 420px; }
.stats > div { flex: 1; padding-right: 18px; }
.stats > div + div { padding-left: 18px; border-left: 1px solid var(--line); }
.stats dt { font-size: 11px; color: var(--dim); text-transform: uppercase; letter-spacing: .1em; font-family: var(--mono); }
.stats dd { font-size: 28px; font-weight: 600; margin-top: 6px; font-variant-numeric: tabular-nums; letter-spacing: -0.03em; }
.stats small { color: var(--dim); font-size: 16px; font-weight: 500; }

/* ---------- player ---------- */
.stage { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.player {
  position: relative; border-radius: 24px;
  width: min(360px, calc((100svh - 250px) * 9 / 16)); min-width: 270px; aspect-ratio: 9 / 16;
  background: var(--card); border: 1px solid var(--line);
  box-shadow: 0 0 0 6px rgba(255,255,255,.02), 0 40px 80px -30px rgba(0,0,0,.9);
}
.player__inner { position: absolute; inset: 0; border-radius: inherit; overflow: hidden; }

/* border beam (Magic UI) */
.border-beam {
  position: absolute; inset: -1px; border-radius: inherit; pointer-events: none; z-index: 4;
  padding: 1.5px;
  background: conic-gradient(from var(--a), transparent 0 78%, var(--beam-a) 88%, var(--beam-b) 96%, transparent 100%);
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude; -webkit-mask-composite: xor;
  animation: spin 6s linear infinite;
}
.player.is-loading .border-beam { animation-duration: 1.2s; }

#video { width: 100%; height: 100%; object-fit: cover; display: block; background: #000; transition: opacity .5s var(--ease), filter .5s var(--ease), transform .7s var(--ease); }
#video.is-hidden { opacity: 0; filter: blur(16px); transform: scale(1.04); }

.skeleton {
  position: absolute; inset: 0; opacity: 0; transition: opacity .3s; pointer-events: none;
  background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.06) 50%, transparent 70%) 0 0 / 200% 100% no-repeat, var(--card);
  animation: skel 1.2s linear infinite;
}
.player.is-loading .skeleton { opacity: 1; }
.skeleton::before, .empty::before {
  content: ""; position: absolute; inset: -20px; z-index: -1;
  background: var(--poster, none) center / cover; filter: blur(18px) brightness(.45) saturate(1.1);
}
.skeleton { isolation: isolate; }
@keyframes skel { from { background-position: 150% 0, 0 0; } to { background-position: -50% 0, 0 0; } }

.empty { isolation: isolate; overflow: hidden; position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; text-align: center; gap: 10px; padding: 32px; z-index: 2; background: var(--card); }
.empty[hidden] { display: none; }
.empty__avatar { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-2); margin-bottom: 6px; }
.empty h3 { font-size: 18px; font-weight: 600; }
.empty p { color: rgba(255,255,255,.7); font-size: 14px; line-height: 1.6; max-width: 24ch; }

.overlay { position: absolute; inset: 0; z-index: 3; display: flex; flex-direction: column; justify-content: space-between; pointer-events: none; }
.overlay > * { pointer-events: auto; }
.player.is-empty .overlay { display: none; }
.overlay__top { display: flex; justify-content: space-between; align-items: center; padding: 14px; }
.chip, .icon-btn {
  background: rgba(0,0,0,.4); border: 1px solid rgba(255,255,255,.1);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 5px 10px; border-radius: 999px; font: 500 12px var(--mono); font-variant-numeric: tabular-nums; }
.chip__dot { width: 6px; height: 6px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.icon-btn { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; transition: background .2s, transform .2s var(--ease); }
.icon-btn:hover { background: rgba(0,0,0,.6); }
.icon-btn:active { transform: scale(.92); }

.overlay__bottom { padding: 60px 16px 16px; background: linear-gradient(transparent, rgba(0,0,0,.72)); }
.author { display: flex; align-items: center; gap: 10px; font-size: 14px; text-align: left; }
.author__img { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; border: 1px solid rgba(255,255,255,.25); flex: none; }
.author > div { min-width: 0; }
.caption { font-size: 13px; color: rgba(255,255,255,.75); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.caption.scrambling { font-family: var(--mono); }
.progress { height: 2px; margin-top: 14px; border-radius: 2px; background: rgba(255,255,255,.18); overflow: hidden; }
.progress span { display: block; height: 100%; width: 0; background: #fff; }

.tap-hint {
  position: absolute; z-index: 4; left: 50%; top: 50%; translate: -50% -50%;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-radius: 999px; font-size: 13px; font-weight: 500; white-space: nowrap;
  background: rgba(0,0,0,.5); border: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  opacity: 0; scale: .95; pointer-events: none; transition: opacity .3s, scale .3s var(--ease);
}
.tap-hint.is-on { opacity: 1; scale: 1; }
.heart-pop { position: absolute; z-index: 5; left: 50%; top: 50%; translate: -50% -50%; width: 96px; height: 96px; pointer-events: none; opacity: 0; }
.heart-pop svg { width: 100%; height: 100%; fill: #fff; filter: drop-shadow(0 8px 24px rgba(0,0,0,.4)); }
.heart-pop.pop { animation: heart .8s var(--spring); }
@keyframes heart { 0% { opacity: 0; scale: .4; } 25% { opacity: 1; scale: 1.1; } 55% { opacity: 1; scale: 1; } 100% { opacity: 0; scale: 1.1; translate: -50% -80%; } }

/* dock (Magic UI) */
.dock {
  position: relative; z-index: 5;
  display: flex; align-items: flex-end; gap: 6px; height: 58px; padding: 8px;
  border-radius: 18px; border: 1px solid var(--line);
  background: rgba(255,255,255,.03); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
}
.dock__sep { width: 1px; height: 26px; align-self: center; background: var(--line-2); margin: 0 2px; }
.dock__item {
  --s: 40px;
  position: relative; width: var(--s); height: var(--s); border-radius: 50%;
  display: grid; place-items: center; color: var(--muted);
  background: rgba(255,255,255,.04);
  transition: width .18s var(--ease), height .18s var(--ease), color .2s, background .2s;
}
.dock__item .i { width: calc(var(--s) * .45); height: calc(var(--s) * .45); }
.dock__item:hover { color: var(--fg); background: rgba(255,255,255,.08); }
.dock__item::after {
  content: attr(data-label); position: absolute; top: calc(100% + 12px); left: 50%;
  translate: -50% -4px; opacity: 0; pointer-events: none; white-space: nowrap;
  padding: 4px 8px; border-radius: 8px; font-size: 12px; color: var(--fg);
  background: #18181b; border: 1px solid var(--line-2);
  transition: opacity .2s, translate .2s var(--ease);
}
.dock__item:hover::after { opacity: 1; translate: -50% 0; }
.dock__count {
  position: absolute; top: -4px; right: -6px; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 99px; font: 600 10px/18px var(--mono); text-align: center;
  background: #fff; color: #000; scale: 0; transition: scale .3s var(--spring);
}
#dLike.is-liked { color: #f43f5e; }
#dLike.is-liked .i { fill: currentColor; }
#dLike.has-count .dock__count { scale: 1; }
#dLike:not(.is-liked) .dock__count { background: #3f3f46; color: #fff; }
#dLike.bump .i { animation: bump .45s var(--spring); }
@keyframes bump { 40% { transform: scale(1.35); } }
#dAuto[aria-pressed="true"] { color: #000; background: #fff; }

/* ---------- hero pozadí: 3D marquee z jeho fotek (Aceternity) ---------- */
.hero { position: relative; isolation: isolate; }
.hero > .hero__copy, .hero > .stage { position: relative; z-index: 2; }
.hero__bg {
  position: absolute; z-index: 0; top: 0; bottom: 0; left: 50%; width: 100vw; translate: -50% 0;
  overflow: hidden; pointer-events: none; perspective: 2200px;
  mask-image: linear-gradient(180deg, transparent 0, #000 16%, #000 68%, transparent 100%);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 16%, #000 68%, transparent 100%);
  opacity: 0; transition: opacity 1.6s var(--ease) .3s;
}
.hero__bg.in { opacity: 1; }
/* scrim, aby byl text čitelný */
.hero__bg::after {
  content: ""; position: absolute; inset: 0; z-index: 2;
  background:
    linear-gradient(90deg, rgba(9,9,11,.95) 0%, rgba(9,9,11,.86) 32%, rgba(9,9,11,.5) 62%, rgba(9,9,11,.62) 100%);
}
.m3d__plane {
  position: absolute; left: 55%; top: 50%; width: 2500px;
  display: grid; grid-template-columns: repeat(var(--cols, 9), 1fr); gap: 18px;
  transform: translate(-50%, -50%) rotateX(50deg) rotateZ(-38deg) scale(.8);
  transform-style: preserve-3d;
}
.m3d__col { --g: 9px; display: flex; flex-direction: column; gap: 18px; animation: colUp var(--dur, 70s) linear infinite; will-change: transform; }
.m3d__col:nth-child(even) { animation-direction: reverse; }
.m3d__img {
  width: 100%; aspect-ratio: 9 / 16; border-radius: 16px; object-fit: cover; display: block;
  border: 1px solid var(--line-2); box-shadow: 0 20px 40px -20px rgba(0,0,0,.8);
  filter: saturate(.8) brightness(.8);
}
@keyframes colUp { to { transform: translateY(calc(-50% - var(--g, 9px))); } }

/* čitelnost textu nad fotkami */
.lede { color: #c4c4cc; }
.stats { border-top-color: var(--line-2); }
.stats > div + div { border-left-color: var(--line-2); }
.stats dt { color: #9a9aa5; }
.profile { background: rgba(9,9,11,.55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.hint kbd { background: rgba(9,9,11,.6); }

/* ---------- pixel glitch přechod (React Bits) ---------- */
.pixels {
  position: absolute; inset: 0; z-index: 6; pointer-events: none;
  display: grid; grid-template-columns: repeat(10, 1fr); grid-template-rows: repeat(18, 1fr);
}
.px { opacity: 0; transition: opacity 0s; transition-delay: var(--d2, 0ms); }
.pixels.on .px { opacity: 1; transition-delay: var(--d, 0ms); }
.player__inner.glitch #video { animation: glitch .32s steps(2, end) 1; }
@keyframes glitch {
  0%   { transform: translate(0); filter: none; clip-path: inset(0); }
  20%  { transform: translate(-8px, 2px); filter: hue-rotate(90deg) saturate(3); clip-path: inset(12% 0 48% 0); }
  40%  { transform: translate(7px, -3px); filter: hue-rotate(-60deg) contrast(1.6); clip-path: inset(55% 0 8% 0); }
  60%  { transform: translate(-4px, 0); filter: invert(.15) saturate(2); clip-path: inset(4% 0 72% 0); }
  80%  { transform: translate(5px, 2px); filter: hue-rotate(180deg); clip-path: inset(38% 0 30% 0); }
  100% { transform: translate(0); filter: none; clip-path: inset(0); }
}

/* ---------- image trail (React Bits) ---------- */
.trail { position: absolute; z-index: 1; top: 0; bottom: 0; left: 50%; width: 100vw; translate: -50% 0; pointer-events: none; overflow: hidden; }
.trail__img {
  position: absolute; width: 112px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 12px;
  translate: -50% -50%; opacity: 0; will-change: transform, opacity;
  border: 1px solid rgba(255,255,255,.22); box-shadow: 0 18px 40px -12px rgba(0,0,0,.8);
}
.trail__img.show { animation: trail 1.1s var(--ease) forwards; }
@keyframes trail {
  0%   { opacity: 0; transform: scale(.3) rotate(var(--r)); }
  14%  { opacity: 1; transform: scale(1.04) rotate(var(--r)); }
  55%  { opacity: 1; transform: scale(1) rotate(var(--r)) translate(calc(var(--dx) * .4), calc(var(--dy) * .4)); }
  100% { opacity: 0; transform: scale(.7) rotate(var(--r)) translate(var(--dx), var(--dy)); }
}

/* ---------- scroll velocity text (Magic UI) ---------- */
.vel { margin: 10px calc(50% - 50vw) 0; padding: 20px 0; overflow: hidden; display: grid; gap: 4px; }
.vel__row { overflow: hidden; }
.vel__inner { display: flex; width: max-content; will-change: transform; }
.vel__inner span {
  padding-right: .5em; white-space: nowrap;
  font-size: clamp(44px, 8vw, 112px); font-weight: 600; letter-spacing: -0.05em; line-height: 1.05;
  background: linear-gradient(180deg, #fff 40%, rgba(255,255,255,.55));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.vel__row--outline .vel__inner span {
  background: none; color: transparent; -webkit-text-stroke: 1.2px rgba(255,255,255,.35);
}

/* ---------- hero parallax (Aceternity) ---------- */
.hp {
  position: relative; height: 230vh; margin: 0 calc(50% - 50vw); padding-top: 110px;
  overflow: hidden; perspective: 1000px;
}
.hp[hidden] { display: none; }
.hp__head { width: min(1120px, calc(100% - 40px)); margin: 0 auto 70px; position: relative; z-index: 2; }
.hp__head h2 { font-size: clamp(40px, 6.4vw, 84px); font-weight: 600; letter-spacing: -0.05em; line-height: 1; margin-top: 18px; }
.hp__head p { color: var(--muted); margin-top: 18px; max-width: 40ch; font-size: 17px; line-height: 1.6; }
.hp__stage { display: flex; flex-direction: column; gap: 34px; transform-style: preserve-3d; will-change: transform, opacity; }
.hp__row { display: flex; gap: 24px; will-change: transform; }
.hp__row--rev { flex-direction: row-reverse; }
.hp__card {
  position: relative; flex: none; width: 230px; aspect-ratio: 9 / 16; border-radius: 18px; overflow: hidden;
  background: var(--card); border: 1px solid var(--line-2); padding: 0; display: block;
  box-shadow: 0 30px 60px -25px rgba(0,0,0,.9);
  transition: transform .45s var(--ease), box-shadow .45s;
}
.hp__card:hover { transform: translateY(-18px); box-shadow: 0 40px 70px -25px rgba(0,0,0,.95); }
.hp__card img, .hp__card video { width: 100%; height: 100%; object-fit: cover; display: block; transition: filter .4s; filter: brightness(.9); }
.hp__card:hover img, .hp__card:hover video { filter: brightness(1.05); }
.hp__card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(transparent 55%, rgba(0,0,0,.7)); pointer-events: none; }
.hp__label {
  position: absolute; left: 12px; bottom: 12px; z-index: 1; display: inline-flex; align-items: center; gap: 6px;
  font: 500 12px var(--mono); color: rgba(255,255,255,.85); opacity: 0; translate: 0 6px;
  transition: opacity .3s, translate .3s var(--ease);
}
.hp__label .i { fill: currentColor; stroke: none; }
.hp__card:hover .hp__label { opacity: 1; translate: 0 0; }
.hp__card--video { cursor: pointer; }
.hp__card--video .hp__label { opacity: 1; translate: 0 0; }

/* ---------- hromádka fotek (Aceternity Draggable Card) ---------- */
.desk-sec { padding: 40px 0 40px; }
.desk-sec[hidden] { display: none; }
.desk {
  position: relative; height: 620px; border-radius: 28px; overflow: hidden; border: 1px solid var(--line);
  background-color: #0e0e11;
  /* jemná šachovnice — jeho šachy */
  background-image: conic-gradient(rgba(255,255,255,.035) 25%, transparent 0 50%, rgba(255,255,255,.035) 0 75%, transparent 0);
  background-size: 110px 110px;
  touch-action: pan-y;
}
.desk::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at center, transparent 40%, rgba(9,9,11,.75)); z-index: 0; }
.desk__hint {
  position: absolute; right: 22px; bottom: 18px; z-index: 1; font: 700 26px "Caveat", cursive; color: rgba(255,255,255,.45);
  rotate: -4deg; transition: opacity .5s;
}
.desk__hint.gone { opacity: 0; }
.polaroid {
  position: absolute; left: 0; top: 0; z-index: 1; margin: 0;
  width: 188px; padding: 10px 10px 0; border-radius: 3px;
  background: #f3f0e8; box-shadow: 0 18px 36px -12px rgba(0,0,0,.75);
  cursor: grab; user-select: none; -webkit-user-select: none; touch-action: none;
  opacity: 0; scale: 1.35;
  transition: opacity .5s var(--ease), scale .55s var(--spring), box-shadow .3s;
}
.polaroid.in { opacity: 1; scale: 1; }
.polaroid::before { /* izolepa */
  content: ""; position: absolute; top: -10px; left: 50%; width: 70px; height: 22px; translate: -50% 0; rotate: -3deg;
  background: rgba(255,255,255,.35); border: 1px solid rgba(255,255,255,.25); backdrop-filter: blur(1px);
}
.polaroid img { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 28%; pointer-events: none; background: #ddd; }
.polaroid figcaption { font: 700 23px/1 "Caveat", cursive; color: #2a2a2a; text-align: center; padding: 9px 0 12px; }
.polaroid.dragging { cursor: grabbing; scale: 1.06; box-shadow: 0 40px 60px -18px rgba(0,0,0,.85); }

/* ---------- Pety vykukuje ---------- */
.peek {
  position: fixed; right: 32px; bottom: 0; z-index: 55;
  translate: 0 115%; transition: translate .8s var(--spring);
  display: block; padding: 0;
}
.peek.on { translate: 0 22%; }
.peek__face {
  display: block; width: 128px; height: 128px; border-radius: 50%; object-fit: cover; object-position: 50% 30%;
  border: 3px solid #fff; box-shadow: 0 20px 50px -10px rgba(0,0,0,.8); rotate: -10deg;
}
.peek.on .peek__face { animation: wobble 2.2s ease-in-out infinite .8s; }
@keyframes wobble { 0%,100% { rotate: -10deg; } 50% { rotate: 6deg; } }
.peek__bubble {
  position: absolute; bottom: calc(100% - 8px); right: 78%; white-space: nowrap;
  padding: 9px 13px; border-radius: 16px 16px 3px 16px; background: #fff; color: #09090b;
  font-size: 14px; font-weight: 600; box-shadow: 0 12px 30px -8px rgba(0,0,0,.6);
  opacity: 0; scale: .6; transform-origin: bottom right; transition: opacity .3s, scale .4s var(--spring);
}
.peek.on .peek__bubble { opacity: 1; scale: 1; transition-delay: .55s; }
.peek:hover .peek__face { border-color: var(--sun); }

/* ---------- vyhledávání: tlačítka ---------- */
.nav__search {
  display: inline-flex; align-items: center; gap: 8px; padding: 7px 10px 7px 12px; border-radius: 999px;
  color: var(--muted); font-size: 14px; transition: color .2s, background .2s;
}
.nav__search:hover { color: var(--fg); background: rgba(255,255,255,.05); }
.nav__search kbd { font-size: 10px; padding: 1px 5px; }
.nav__links > a.nav__suggest { display: inline-flex; align-items: center; gap: 6px; color: var(--fg); }
.nav__suggest .i { color: var(--sun); }
.search-trigger {
  display: flex; align-items: center; gap: 10px; width: min(440px, 100%); margin-top: 22px;
  padding: 11px 12px 11px 14px; border-radius: 14px; text-align: left; font-size: 14px; color: var(--dim);
  background: rgba(9,9,11,.55); border: 1px solid var(--line-2);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  transition: border-color .25s, color .25s, background .25s;
}
.search-trigger span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-trigger:hover { border-color: rgba(255,255,255,.28); color: var(--muted); background: rgba(9,9,11,.7); }
.i--fill { fill: currentColor; stroke: none; }

/* ---------- command palette (cmdk) ---------- */
.cmdk { position: fixed; inset: 0; z-index: 80; display: grid; place-items: start center; padding: min(14vh, 120px) 16px 16px; }
.cmdk[hidden] { display: none; }
.cmdk__backdrop { position: absolute; inset: 0; background: rgba(5,5,7,.6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; transition: opacity .18s; }
.cmdk__panel {
  position: relative; width: min(640px, 100%); max-height: min(70vh, 620px); display: flex; flex-direction: column;
  border-radius: 18px; border: 1px solid var(--line-2); background: rgba(16,16,20,.92);
  box-shadow: 0 30px 80px -20px rgba(0,0,0,.9), 0 0 0 1px rgba(255,255,255,.03) inset;
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  opacity: 0; transform: translateY(-8px) scale(.98); transition: opacity .18s, transform .22s var(--ease);
  overflow: hidden;
}
.cmdk.open .cmdk__backdrop { opacity: 1; }
.cmdk.open .cmdk__panel { opacity: 1; transform: none; }
.cmdk__input { display: flex; align-items: center; gap: 12px; padding: 16px 18px; border-bottom: 1px solid var(--line); color: var(--dim); }
.cmdk__input input { flex: 1; min-width: 0; background: none; border: 0; outline: 0; color: var(--fg); font: 400 17px var(--font); }
.cmdk__input input::-webkit-search-cancel-button { display: none; }
.cmdk__input input::placeholder { color: var(--dim); }
.cmdk__input kbd { cursor: pointer; }
.cmdk__results { overflow-y: auto; padding: 8px; flex: 1; transition: opacity .2s; }
.cmdk__results.loading { opacity: .55; }
.cmdk__empty { padding: 26px 14px; text-align: center; color: var(--dim); font-size: 14px; line-height: 1.6; }
.cmdk__item {
  display: flex; flex-direction: column; gap: 6px; width: 100%; text-align: left; padding: 12px 14px; border-radius: 12px;
  border: 1px solid transparent; transition: background .12s, border-color .12s;
}
.cmdk__item.active { background: rgba(255,255,255,.06); border-color: var(--line); }
.cmdk__snippet { font-size: 15px; line-height: 1.5; color: #d4d4d8; }
.cmdk__snippet mark { background: rgba(242,207,91,.22); color: #fff; border-radius: 4px; padding: 0 3px; box-shadow: inset 0 -2px 0 var(--sun); }
.cmdk__meta { font: 400 12px var(--mono); color: var(--dim); }
.cmdk__foot { display: flex; gap: 16px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12px; color: var(--dim); }
.cmdk__foot kbd { margin-right: 3px; }
.cmdk__count { margin-left: auto; font-family: var(--mono); }

/* ---------- titulky v přehrávači ---------- */
.subs {
  position: absolute; left: 14px; right: 14px; bottom: 96px; z-index: 4; pointer-events: none; text-align: center;
  font-size: 15px; font-weight: 600; line-height: 1.45; letter-spacing: -0.01em;
  opacity: 0; transform: translateY(6px); transition: opacity .25s, transform .25s var(--ease);
}
.subs.on { opacity: 1; transform: none; }
.subs span {
  color: rgba(255,255,255,.95); text-shadow: 0 1px 2px rgba(0,0,0,.9), 0 0 12px rgba(0,0,0,.6);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.subs span.next { color: rgba(255,255,255,.62); }
.subs span.cur { color: var(--sun); }
#dSubs[aria-pressed="true"] { color: #000; background: #fff; }

/* ---------- citát dne ---------- */
.quote { position: relative; max-width: 880px; margin: 30px auto 0; padding: 70px 24px 40px; text-align: center; }
.quote[hidden] { display: none; }
.quote::before {
  content: "“"; position: absolute; top: -10px; left: 50%; translate: -50% 0; font: 700 220px/1 Georgia, serif;
  color: rgba(255,255,255,.04); pointer-events: none;
}
.quote__text { margin: 26px 0 30px; font-size: clamp(28px, 4.4vw, 52px); font-weight: 600; line-height: 1.15; letter-spacing: -0.035em; }
.quote__text .qw { display: inline-block; opacity: 0; filter: blur(8px); transform: translateY(6px); }
.quote.in .quote__text .qw { animation: word .6s var(--ease) forwards; animation-delay: var(--d); }
.quote.in .quote__text .qw { transform: none; }
.quote__foot { display: flex; align-items: center; justify-content: center; gap: 22px; flex-wrap: wrap; }
.quote__who { display: inline-flex; align-items: center; gap: 10px; color: var(--muted); font-size: 14px; }
.quote__who img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; border: 1px solid var(--line-2); }
.quote__date { color: var(--dim); }
.btn-shimmer--sm { padding: 11px 18px; font-size: 14px; }

/* ---------- návrh videa ---------- */
.suggest { padding: 20px 0 90px; }
.suggest__card {
  display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; align-items: center;
  padding: clamp(24px, 4vw, 44px); border-radius: 28px; border: 1px solid var(--line);
  background: radial-gradient(600px circle at 0% 0%, rgba(143,193,212,.08), transparent 60%), var(--card);
}
.suggest__copy h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 600; letter-spacing: -0.04em; margin-top: 14px; }
.suggest__copy p { color: var(--muted); margin-top: 10px; line-height: 1.6; }
.suggest__form { display: grid; gap: 10px; }
.field {
  width: 100%; padding: 13px 14px; border-radius: 12px; font: 400 15px var(--font); color: var(--fg);
  background: rgba(255,255,255,.03); border: 1px solid var(--line-2); outline: 0; transition: border-color .2s, background .2s;
}
.field::placeholder { color: var(--dim); }
.field:focus { border-color: rgba(143,193,212,.6); background: rgba(255,255,255,.05); }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.btn-primary {
  justify-self: start; padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 15px;
  background: #fff; color: #09090b; transition: transform .2s var(--ease), opacity .2s;
}
.btn-primary:hover { transform: translateY(-1px); }
.btn-primary:disabled { opacity: .55; cursor: progress; }
.suggest__msg { min-height: 1.4em; font-size: 14px; color: var(--muted); }
.suggest__msg.ok { color: #86efac; }
.suggest__msg.err { color: #fca5a5; }

/* ---------- feed ---------- */
.feed { padding: 80px 0 100px; }
.section-head { text-align: center; margin-bottom: 44px; }
.eyebrow { display: inline-block; font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: .12em; color: var(--dim); padding: 5px 10px; border: 1px solid var(--line); border-radius: 999px; }
.section-head h2 { font-size: clamp(32px, 4.5vw, 48px); font-weight: 600; letter-spacing: -0.04em; margin-top: 16px; }
.section-head p { color: var(--muted); margin-top: 8px; }
.section-head--slim { margin-bottom: 22px; }
.hp__head p a { color: var(--fg); }
.hp__head p a:hover { text-decoration: underline; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
/* magic card — spotlight sleduje kurzor */
.card {
  --mx: -300px; --my: -300px;
  position: relative; border-radius: 18px; padding: 1px; text-align: left; display: block; width: 100%;
  background: radial-gradient(260px circle at var(--mx) var(--my), rgba(255,255,255,.28), transparent 60%), var(--line);
  opacity: 0; transform: translateY(16px); filter: blur(6px);
  transition: opacity .7s var(--ease), transform .7s var(--ease), filter .7s var(--ease);
  transition-delay: var(--d, 0s);
}
.card.in { opacity: 1; transform: none; filter: none; }
.card__inner { position: relative; border-radius: 17px; overflow: hidden; background: var(--card); }
.card__media { position: relative; aspect-ratio: 9 / 13; overflow: hidden; background: #111; }
.card video { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .7s var(--ease); }
.card:hover video { transform: scale(1.04); }
.card__play {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(255,255,255,.92); color: #000;
  opacity: 0; scale: .8; transition: opacity .25s, scale .3s var(--ease);
}
.card__play .i { fill: currentColor; stroke: none; margin-left: 2px; }
.card:hover .card__play { opacity: 1; scale: 1; }
.card__meta { display: flex; justify-content: space-between; align-items: center; padding: 11px 13px; font-size: 13px; gap: 8px; }
.card__meta > span:first-child { font-family: var(--mono); color: var(--dim); }
.card__tags { display: inline-flex; gap: 8px; color: var(--muted); font-size: 12px; }
.card .tag-seen { display: none; }
.card.is-seen .tag-seen { display: inline; }
.card.is-current { background: linear-gradient(135deg, var(--beam-a), var(--beam-b)); }
.grid-empty { text-align: center; padding: 56px 20px; color: var(--muted); border: 1px dashed var(--line-2); border-radius: 18px; }
.grid-empty[hidden] { display: none; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); }
.footer__inner { width: min(1120px, calc(100% - 40px)); margin: 0 auto; padding: 28px 0 36px; display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 14px; }
.footer__me { display: inline-flex; align-items: center; gap: 10px; }
.footer__me img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; }
.footer__links { display: inline-flex; gap: 20px; }
.footer__links a:hover { color: var(--fg); }

/* ---------- toast + fx ---------- */
.toast {
  position: fixed; bottom: 24px; left: 50%; z-index: 70; translate: -50% calc(100% + 40px); visibility: hidden;
  padding: 11px 16px; border-radius: 12px; font-size: 14px;
  background: #18181b; border: 1px solid var(--line-2); box-shadow: 0 16px 40px -12px rgba(0,0,0,.7);
  transition: translate .45s var(--spring), visibility 0s .45s;
}
.toast.is-on { translate: -50% 0; visibility: visible; transition: translate .45s var(--spring), visibility 0s; }
#fx { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 60; }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; padding-top: 96px; min-height: 0; gap: 44px; text-align: center; }
  .hero__copy { display: flex; flex-direction: column; align-items: center; }
  .stage { order: -1; }
  .player { width: min(340px, 82vw); }
  .title { margin: 22px 0 16px; }
  .lede { margin-inline: auto; }
  .cta { justify-content: center; }
  .stats { width: 100%; margin-top: 40px; }
  .search-trigger { margin-inline: auto; }
  .suggest__card { grid-template-columns: 1fr; gap: 24px; text-align: left; }
  .nav__search kbd { display: none; }
  .hp { height: 190vh; padding-top: 80px; }
  .hp__head { margin-bottom: 44px; }
  .hp__card { width: 150px; border-radius: 14px; }
  .hp__row { gap: 14px; }
  .hp__stage { gap: 18px; }
  .desk { height: 520px; }
  .polaroid { width: 138px; padding: 7px 7px 0; }
  .polaroid figcaption { font-size: 18px; padding: 7px 0 9px; }
  .peek { right: 16px; }
  .peek__face { width: 96px; height: 96px; }
  .m3d__plane { left: 50%; width: 1500px; gap: 12px; }
  .m3d__col { gap: 12px; --g: 6px; }
  .hero__bg::after {
    background: linear-gradient(180deg, rgba(9,9,11,.5) 0%, rgba(9,9,11,.62) 40%, rgba(9,9,11,.88) 60%, rgba(9,9,11,.92) 100%);
  }
  .nav__links > a:not(.btn-border):not(.nav__suggest) { display: none; }
  .nav__suggest { font-size: 0; gap: 0 !important; padding: 8px 10px !important; }
  .nav__suggest .i { width: 18px; height: 18px; }
}
@media (max-width: 520px) {
  .cards { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .hint { display: none; }
  .stats dd { font-size: 24px; }
}
@media (hover: none) { .dock__item::after { display: none; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001s !important; animation-iteration-count: 1 !important; transition-duration: .001s !important; }
}
