:root{--ink:#172a2c;--muted:#52666b;--accent:#0f6b66;--wash:#e6f3ef;--bg:#f4f6f7;--line:#d7e1df;--paper:#fff;--radius:12px;--rail:252px;font:16px/1.5 system-ui,sans-serif;color:var(--ink);background:var(--bg)}*{box-sizing:border-box}body{margin:0}a{color:var(--accent);text-decoration:none;font-weight:600}a:hover{text-decoration:underline}a:focus-visible,select:focus-visible,textarea:focus-visible{outline:3px solid #177baf;outline-offset:3px}.skip{position:fixed;top:-80px;background:white;padding:10px;z-index:5}.skip:focus{top:0}aside{background:var(--paper);border-right:1px solid var(--line);width:var(--rail);position:fixed;inset:0 auto 0 0;padding:24px 16px;display:flex;flex-direction:column}.brand{display:flex;align-items:center;gap:10px;font-size:21px;color:var(--ink);letter-spacing:-.8px}.mark,footer b{display:grid;place-items:center;background:var(--accent);color:white;border-radius:8px;width:34px;height:34px}.mark{font-size:30px;line-height:1}.eyebrow,aside small,.poster span,.reel span{font:650 11px/1.4 ui-monospace,monospace;letter-spacing:.11em}.eyebrow{color:var(--accent)}aside small{color:var(--muted);margin:52px 10px 12px}nav{display:grid;gap:4px}nav a,.button{display:inline-flex;align-items:center;gap:10px;border-radius:7px;padding:10px 12px;font-size:14px}nav a{color:var(--muted)}nav a[aria-current],nav a:hover{background:var(--wash);color:var(--accent);text-decoration:none}svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}footer{margin-top:auto;border-top:1px solid var(--line);padding:18px 4px 0;display:flex;align-items:center;gap:11px;font-size:14px}footer b{background:var(--wash);color:var(--accent)}em{font-style:normal;color:var(--muted);font-size:12px}.workspace{margin-left:var(--rail)}header{display:flex;justify-content:space-between;align-items:center;gap:12px;background:var(--paper);border-bottom:1px solid var(--line);padding:15px clamp(18px,4vw,60px);font-size:13px;color:var(--muted)}header i{font-style:normal;margin:0 10px;color:#899a9b}.badge{background:var(--wash);color:#205d54;padding:4px 10px;border-radius:20px;white-space:nowrap}main{max-width:1280px;margin:auto;padding:clamp(24px,4vw,60px);outline:none}h1,h2,p{margin:0}h1{font-size:clamp(32px,3vw,44px);line-height:1.18;letter-spacing:-.055em;margin:8px 0}h2{font-size:22px;letter-spacing:-.035em}.lead,.hero p{color:var(--muted);margin-bottom:26px}.hero{border-radius:var(--radius)}.panel,.card{background:transparent}.hero{background:#e8f2ef;padding:clamp(20px,3vw,40px);display:flex;align-items:center;justify-content:space-between;gap:24px;overflow:hidden}.hero h2{font-size:clamp(26px,3vw,38px);margin:6px 0}.hero p{margin-bottom:18px}.button{background:white;border:1px solid var(--line);justify-content:center;min-height:42px}.button.primary{background:var(--accent);color:white;border-color:transparent}.button:hover{filter:brightness(.93);text-decoration:none}.reel{min-width:170px;width:23%;background:repeating-linear-gradient(115deg,#113e3a 0 16px,#174740 17px 32px);border-radius:6px;color:white;padding:14px;transform:rotate(-3deg)}.reel div{font-size:38px;text-align:center}.reel span{font-size:9px}.sectionhead,.actions{display:flex;align-items:center;justify-content:space-between;gap:12px}.sectionhead{margin:32px 0 14px}.sectionhead a{font-size:14px}.sectionhead small{font-size:13px;color:var(--muted)}.cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.card{overflow:hidden;color:var(--ink)}.card:hover strong,.card:focus-visible strong{color:var(--accent);text-decoration:underline}.card:hover{text-decoration:none}.card .poster{border-radius:7px}.poster{position:relative;aspect-ratio:16/9;overflow:hidden}.atrium{background:repeating-linear-gradient(117deg,transparent 0 15%,#23463c58 15.4% 19%,transparent 19.5% 23%),linear-gradient(32deg,#36524b,#a1b29d 48%,#ede7cf 49%,#abbfae)}.product{background:radial-gradient(ellipse at 63% 70%,#debe98 0 16%,#c19774 17% 21%,transparent 22%),linear-gradient(130deg,#a77f68 0 34%,#e0c3a5 35% 51%,#bf9779 52%)}.landscape{background:radial-gradient(circle at 73% 30%,#f2dfbe 0 7%,transparent 7.5%),linear-gradient(155deg,transparent 55%,#5a7376 56% 64%,#324f58 65%),linear-gradient(24deg,#728d8e 0 36%,#adc2bd 37% 44%,#d4d8c8 45%,#cad6d4)}.poster span{position:absolute;bottom:10px;right:10px;background:#172a2ce6;color:white;padding:3px 7px;border-radius:4px}.caption{padding:10px 0}.caption small{color:var(--muted);font-weight:500}.caption strong{display:block;font-size:18px}.caption i{float:right;font-style:normal;color:var(--accent)}.panel{padding:4px 0;max-width:780px}.panel h2{margin-bottom:22px}label,dt{display:block;font-size:14px;font-weight:600}.fields,.detailgrid{display:grid;gap:18px}.fields{grid-template-columns:1fr 1fr;margin:18px 0 28px}select,textarea{width:100%;margin-top:7px;border:1px solid #aebfbc;border-radius:7px;padding:11px;background:white;font:inherit;color:var(--ink)}textarea{resize:vertical}.actions{border-top:1px solid var(--line);padding-top:18px}.detailgrid{grid-template-columns:1.6fr 1fr;align-items:start;margin-bottom:20px}.large{border-radius:var(--radius)}dt{color:var(--muted);font-weight:500}dd{margin:0 0 12px;font-weight:650}
@media(max-width:850px){:root{--rail:218px}.cards{gap:10px}.detailgrid{grid-template-columns:1fr}.reel{min-width:122px}.caption{padding:8px 0}.caption strong{font-size:16px}}
@media(max-width:680px){aside{position:static;width:auto;padding:12px 16px;border-right:0;border-bottom:1px solid var(--line);gap:12px}.brand{font-size:18px}.mark{width:28px;height:28px}.workspace{margin:0}aside small,footer,.reel{display:none}nav{display:flex;flex-wrap:wrap}nav a{padding:8px 9px}header{padding:10px 18px}.cards{grid-template-columns:1fr}.fields{grid-template-columns:1fr}.hero{padding:22px}.actions{flex-wrap:wrap}.detailgrid{gap:12px}main{padding:24px 16px}.sectionhead{margin-top:24px}}
video { max-width: 100%; }
.library-heading { margin: 0 0 .25rem; }
.clip-gallery { grid-template-columns: repeat(auto-fill,minmax(min(100%,240px),1fr)); gap: 20px; }
.clip-tile { min-width: 0; display: flex; flex-direction: column; border: 1px solid var(--line); background: var(--paper); border-radius: var(--radius); overflow: hidden; color: var(--ink); }
.clip-tile:hover, .clip-tile:focus-visible { text-decoration: none; border-color: var(--accent); }
.clip-frame { position: relative; aspect-ratio: 16/9; overflow: hidden; background: var(--ink); }
.clip-frame > small { position: absolute; inset: 0; display: grid; place-items: center; color: white; }
.clip-frame video[hidden] { display: none; }
.clip-frame video { position: relative; width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.clip-frame span { position: absolute; bottom: 8px; right: 8px; padding: 1px 8px; background: #12282ce6; color: white; border-radius: 6px; font-size: .8rem; }
.clip-caption { display: grid; gap: .55rem; padding: 14px 16px; }
.clip-caption strong { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.clip-caption small { color: var(--muted); font-weight: 400; }
.clip-back { display: inline-block; margin-bottom: 20px; }
.clip-detail { max-width: 54rem; margin-inline: auto; overflow-wrap: anywhere; }
.clip-detail h1 { font-size: clamp(24px, 3vw, 36px); }
.clip-player { display: block; margin-inline: auto; width: 100%; max-height: 65vh; border-radius: var(--radius); background: var(--ink); }
.clip-sheet { margin-top: 20px; padding: clamp(16px,3vw,28px); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.action-upravit { --action:#245d9c; } .action-prodlouzit { --action:#117052; } .action-spojit { --action:#744397; } .action-kos { --action:#ad292e; }
.button[class*="action-"] { border-color:var(--action); color:var(--action); background:white; display:inline-flex; align-items:center; gap:.45rem; }
.button[class*="action-"]:disabled { opacity:.55; cursor:not-allowed; }
.button[class*="action-"]:not(:disabled):hover { background:color-mix(in srgb,var(--action) 8%,white); }
.trash-dialog { box-sizing:border-box; width:min(28rem, calc(100% - 2rem)); border:1px solid var(--line); border-radius:var(--radius); padding:1.5rem; color:var(--ink); background:white; box-shadow:0 12px 50px #10242033; }
.trash-dialog::backdrop { background:#10242088; }
.trash-dialog p { margin:1rem 0; overflow-wrap:anywhere; }
.rail-tools { display:flex; align-items:center; justify-content:space-between; margin:32px 0 8px; }
.rail-tools small { margin:0 10px; }
.rail-toggle { display:grid; place-items:center; width:38px; height:38px; color:var(--muted); background:white; border:1px solid var(--line); border-radius:7px; cursor:pointer; }
.rail-toggle:hover { background:var(--wash); color:var(--accent); }
.rail-version { margin-top:auto; padding:16px 10px 0; color:var(--muted); font-size:.8rem; }
aside { overflow-y:auto; }
aside.compact .brand-name,aside.compact .rail-tools small,aside.compact nav a span,aside.compact .rail-version { display:none; }
aside.compact .rail-tools { margin:0 0 12px; justify-content:center; }
aside.compact nav a { justify-content:center; min-height:40px; }
@media(min-width:681px){aside.compact {width:64px;padding-inline:8px;} aside.compact + .workspace {margin-left:64px;}}
@media(max-width:680px){aside { position:relative; } .rail-tools {position:absolute;top:10px;right:16px;margin:0;} aside .brand {margin-right:44px;} .rail-version {padding:0;} aside.compact {display:flex;flex-direction:row;align-items:center;} aside.compact .rail-tools {position:static;margin:0;} }
.hc-logo { display:inline-flex; width:44px; flex:none; }
aside.compact .brand { justify-content:center; margin:0 0 12px; }
@media(max-width:680px){aside.compact {flex-wrap:wrap;} aside.compact .brand {margin:0;} aside.compact .hc-logo {width:36px;} }
.hc-logo svg { width:100%; height:auto; display:block; }
.clip-tools { display: flex; flex-wrap: wrap; gap: .6rem; margin-block: .6rem; }
.clip-sheet h2 { font-size: 19px; margin-bottom: 14px; }
.clip-prompt { white-space: pre-wrap; line-height: 1.65; }
.clip-facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,15rem),1fr)); gap: 14px 24px; }
.clip-facts dd { margin: 3px 0 0; }
.clip-id { grid-column: 1/-1; }
.clip-id dd { font-family: ui-monospace,monospace; font-size: .88rem; }

/* Přihlášení má vlastní rozvržení; světlý formulář zůstává čitelný i bez grafiky. */
body:has(form[action="/prihlaseni"]) {
  min-height: 100vh; min-height: 100svh; display: grid; place-items: center;
  padding: clamp(16px, 4vw, 48px);
  background: radial-gradient(ellipse at 50% 25%, #f9fbff, transparent 70%), #edf1f7;
  color: #172941;
}
body:has(form[action="/prihlaseni"]) > main {
  width: min(100%, 28rem); margin: 0; padding: clamp(24px, 5vw, 44px);
  background: white; border: 1px solid #d5dfec; border-radius: 20px;
  box-shadow: 0 16px 48px -20px #2c436b50;
}
main:has(form[action="/prihlaseni"]) {
  &::before { content: "VIDEOTVŮRCE"; display: block; margin-bottom: 20px; font-size: .73rem; font-weight: 750; letter-spacing: .16em; color: #43618a; }
  & h1 { margin: 0; font-size: clamp(1.65rem, 5vw, 2rem); line-height: 1.18; letter-spacing: -.035em; color: #172941; }
  & > p { margin: 12px 0 26px; font-size: .95rem; line-height: 1.55; color: #495c73; }
  & form { display: grid; gap: 18px; margin: 0; }
  & label { display: grid; gap: 7px; color: #273951; font-size: .92rem; font-weight: 630; }
  & input { width: 100%; min-width: 0; min-height: 52px; border: 1px solid #899bb1; border-radius: 9px; background: #fff; padding: 10px 14px; color: #172941; font: 400 1rem/1.5 system-ui,sans-serif; }
  & .primary { width: 100%; min-height: 52px; margin-top: 5px; background: #294d83; color: white; border: 0; border-radius: 9px; font: 650 1rem/1.4 system-ui,sans-serif; cursor: pointer; }
  & .primary:hover { background: #1c3c6b; }
  & :is(input,button):focus-visible { outline: 3px solid #356abd; outline-offset: 3px; }
  & [role="alert"]:empty { display: none; }
  & [role="alert"]:not(:empty) { margin: 18px 0 0; padding: 10px 14px; border-left: 3px solid #ac3434; background: #fff4f3; color: #832727; }
}
