:root {
  --bg: #0c0c11;
  --bg-2: #13131a;
  --card: #18181f;
  --card-2: #1f1f28;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.14);
  --text: #f4f4f7;
  --muted: #a0a0ae;
  --faint: #6f6f7d;
  --accent: #ff8a1f;
  --accent-2: #ff4f6a;
  --grad: linear-gradient(120deg, var(--accent), var(--accent-2));
  --radius: 18px;
  --font: "Segoe UI Variable Display", "Segoe UI", -apple-system, BlinkMacSystemFont, "SF Pro Display", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Language: both are in the page, one is hidden. */
html:not([data-lang="cs"]) [data-l="cs"],
html[data-lang="cs"] [data-l="en"] { display: none !important; }

a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
b { font-weight: 650; }
code { font-family: var(--mono); font-size: 0.88em; background: rgba(255, 255, 255, 0.07); padding: 0.1em 0.4em; border-radius: 6px; }

kbd {
  display: inline-block;
  font-family: var(--font);
  font-size: 0.82em;
  font-weight: 600;
  line-height: 1.2;
  padding: 0.15em 0.5em;
  border-radius: 7px;
  background: linear-gradient(#2c2c36, #22222a);
  border: 1px solid var(--line-2);
  box-shadow: 0 2px 0 rgba(0, 0, 0, 0.5);
  color: var(--text);
  white-space: nowrap;
}

.glow {
  position: fixed;
  inset: -20vh -10vw auto -10vw;
  height: 90vh;
  pointer-events: none;
  background:
    radial-gradient(40vw 34vh at 72% 26%, rgba(255, 79, 106, 0.18), transparent 70%),
    radial-gradient(36vw 30vh at 58% 8%, rgba(255, 138, 31, 0.16), transparent 70%),
    radial-gradient(40vw 40vh at 12% 4%, rgba(110, 80, 200, 0.14), transparent 70%);
  z-index: 0;
}

/* Navigation */
.nav {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 14px max(16px, calc((100vw - 1180px) / 2));
  background: rgba(12, 12, 17, 0.72);
  backdrop-filter: saturate(1.4) blur(14px);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; text-decoration: none; letter-spacing: -0.01em; }
.brand img { border-radius: 8px; }
.nav-links { display: flex; gap: 22px; margin-left: 12px; }
.nav-links a { color: var(--muted); text-decoration: none; font-size: 15px; transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }
.nav-end { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.lang {
  font: inherit;
  font-size: 13px;
  font-weight: 650;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--line-2);
  border-radius: 999px;
  padding: 5px 11px;
  cursor: pointer;
}
.lang:hover { color: var(--text); border-color: rgba(255, 255, 255, 0.3); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 650;
  text-decoration: none;
  border-radius: 14px;
  padding: 14px 22px;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(0.99); }
.btn-small { padding: 8px 16px; font-size: 15px; border-radius: 999px; background: var(--grad); color: #fff; }
.btn-primary {
  background: var(--grad);
  color: #fff;
  box-shadow: 0 10px 34px -8px rgba(255, 79, 106, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.btn-primary:hover { box-shadow: 0 14px 44px -8px rgba(255, 79, 106, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.25); transform: translateY(-1px); }
.btn-ghost { border: 1px solid var(--line-2); color: var(--text); background: rgba(255, 255, 255, 0.03); }
.btn-ghost:hover { background: rgba(255, 255, 255, 0.07); }
.ico { width: 20px; height: 20px; fill: currentColor; flex: none; }

main, .footer { position: relative; z-index: 1; }

/* Hero */
.hero {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 72px 16px 40px;
}
.pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 14px 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  font-size: 14px;
  text-decoration: none;
}
.pill:hover { color: var(--text); }
.pill-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--grad); box-shadow: 0 0 12px var(--accent-2); }
h1 {
  font-size: clamp(40px, 6vw, 72px);
  line-height: 1.02;
  letter-spacing: -0.035em;
  margin: 22px 0 20px;
  font-weight: 750;
}
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: clamp(17px, 1.6vw, 20px); color: var(--muted); max-width: 34em; margin: 0 0 30px; }
.lead b { color: var(--text); }
.cta { display: flex; flex-wrap: wrap; gap: 12px; }
.meta { color: var(--faint); font-size: 14px; margin: 16px 0 0; }
.meta b { color: var(--muted); font-weight: 600; }

/* Demo stage */
.hero-demo { display: flex; flex-direction: column; align-items: center; }
.stage {
  position: relative;
  width: 100%;
  max-width: 540px;
  aspect-ratio: 1;
  border-radius: 28px;
  background:
    radial-gradient(120% 90% at 30% 0%, rgba(80, 70, 140, 0.35), transparent 60%),
    linear-gradient(160deg, #23233a, #2d2340 55%, #3a2742);
  border: 1px solid var(--line-2);
  box-shadow: 0 40px 100px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(0, 0, 0, 0.4);
  overflow: hidden;
  user-select: none;
}
.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.07) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: linear-gradient(transparent, #000 30%, #000 70%, transparent);
}
.doc {
  position: relative;
  width: 54px;
  height: 66px;
  border-radius: 8px;
  background: linear-gradient(#ffffff, #e9e9f0);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  display: grid;
  place-items: end center;
  padding-bottom: 9px;
  clip-path: polygon(0 0, 70% 0, 100% 22%, 100% 100%, 0 100%);
}
.doc::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 30%;
  height: 22%;
  background: #c9c9d6;
  border-bottom-left-radius: 6px;
}
.doc span {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #fff;
  background: var(--grad);
  padding: 2px 6px;
  border-radius: 5px;
}
.doc-small { transform: scale(0.82); }
.desk-file {
  position: absolute;
  left: 12%;
  top: 14%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  transition: opacity 0.3s;
}
.desk-name {
  font-size: 12px;
  color: #fff;
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 8px;
  border-radius: 6px;
}
.desk-file.ghost { opacity: 0.35; }
.wheel {
  position: absolute;
  left: 9%;
  top: 9%;
  width: 82%;
  height: 82%;
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.18s ease-out, transform 0.18s cubic-bezier(0.33, 1, 0.68, 1);
  overflow: visible;
}
.wheel.open { opacity: 1; transform: scale(1); }
.wheel.dropped { opacity: 0; transform: scale(1.06); transition: opacity 0.25s, transform 0.3s; }
/* The app's dark palette (src/FileAction.App/UI/Theme.cs). */
.wheel .backdrop { fill: rgba(22, 22, 27, 0.9); stroke: rgba(255, 255, 255, 0.15); stroke-width: 1; filter: url(#shadow); }
.wheel .pop { transition: transform 0.13s cubic-bezier(0.33, 1, 0.68, 1); }
.wheel .grow { transform-box: view-box; transform-origin: 221px 221px; transform: scale(0.82); opacity: 0; transition: transform 0.17s cubic-bezier(0.33, 1, 0.68, 1), opacity 0.17s; }
.wheel.open .grow { transform: none; opacity: 1; }
.wheel .slice { fill: #26262e; stroke: rgba(255, 255, 255, 0.08); stroke-width: 1; transition: fill 0.12s; }
.wheel .hot .slice { fill: url(#hot); stroke: transparent; filter: url(#glow); }
.wheel .label { fill: #f5f5f7; font: 600 13px var(--font); text-anchor: middle; dominant-baseline: central; }
.wheel .label.fmt { font-size: 19px; }
.wheel .sub { fill: #9c9ca8; font: 400 10.5px var(--font); text-anchor: middle; dominant-baseline: central; }
.wheel .icon { fill: none; stroke: #f5f5f7; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.wheel .hot .label, .wheel .hot .sub { fill: #fff; }
.wheel .hot .sub { opacity: 0.85; }
.wheel .hot .icon { stroke: #fff; }
.wheel .hub { fill: #1d1d24; stroke: rgba(255, 255, 255, 0.14); stroke-width: 1; filter: url(#hub-shadow); }
.wheel .doc-page { fill: #f4f4f8; }
.wheel .doc-fold { fill: #c9c9d6; }
.wheel .doc-badge { fill: url(#hot); }
.wheel .hub-title { fill: #f5f5f7; font: 600 16px var(--font); text-anchor: middle; dominant-baseline: central; }
.wheel .hub-detail { fill: #9c9ca8; font: 400 11.5px var(--font); text-anchor: middle; dominant-baseline: central; }
.wheel .track { fill: rgba(255, 255, 255, 0.19); }
.wheel .tab-on { fill: url(#hot); }
.wheel .tab { fill: #9c9ca8; font: 600 10.5px var(--font); text-anchor: middle; dominant-baseline: central; }
.wheel .tab.on { fill: #fff; }

.chip, .cursor {
  position: absolute;
  left: 0;
  top: 0;
  transition: transform 0.75s cubic-bezier(0.45, 0, 0.2, 1), opacity 0.25s;
  will-change: transform;
}
.chip { z-index: 3; margin: 10px 0 0 6px; opacity: 0; }
.chip.held { opacity: 0.92; }
.chip.held .doc { box-shadow: 0 14px 30px rgba(0, 0, 0, 0.5); }
.chip.gone { opacity: 0; }
.cursor { z-index: 4; width: 26px; height: 26px; fill: #fff; stroke: #111; stroke-width: 1.2; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.5)); }
.keycap {
  position: absolute;
  left: 5%;
  bottom: 5%;
  transform: translateY(10px);
  opacity: 0;
  padding: 9px 20px 11px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 15px;
  background: linear-gradient(#34343f, #26262f);
  border: 1px solid rgba(255, 255, 255, 0.16);
  box-shadow: 0 5px 0 #121217, 0 10px 24px rgba(0, 0, 0, 0.45);
  transition: opacity 0.2s, transform 0.12s;
  z-index: 5;
}
.keycap.show { opacity: 1; transform: none; }
.keycap.down { transform: translateY(4px); box-shadow: 0 1px 0 #121217, 0 6px 14px rgba(0, 0, 0, 0.45); background: var(--grad); }
.toast {
  position: absolute;
  right: 5%;
  bottom: 5%;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 200px;
  padding: 12px 16px;
  border-radius: 14px;
  background: rgba(31, 31, 38, 0.96);
  border: 1px solid var(--line-2);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.3s, transform 0.35s cubic-bezier(0.2, 1.2, 0.4, 1);
  z-index: 5;
}
.toast.show { opacity: 1; transform: none; }
.toast-icon { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, 0.08); transition: background 0.3s; }
.toast-icon svg { width: 18px; height: 18px; fill: #fff; opacity: 0; transition: opacity 0.3s; }
.toast.done .toast-icon { background: #3cc36e; }
.toast.done .toast-icon svg { opacity: 1; }
.toast-body { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; flex: 1; }
.bar { height: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.1); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; background: var(--grad); border-radius: 4px; }
.toast.run .bar i { width: 100%; transition: width 1s cubic-bezier(0.3, 0, 0.3, 1); }
.demo-caption { margin: 18px 0 0; color: var(--muted); font-size: 15px; min-height: 1.6em; text-align: center; }
.demo-caption kbd { margin: 0 2px; }

/* Stats */
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  max-width: 1180px;
  margin: 24px auto 0;
  padding: 0 16px;
  gap: 1px;
}
.stats div {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 22px 10px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.stats b { font-size: clamp(28px, 3.4vw, 40px); letter-spacing: -0.03em; line-height: 1.1; }
.stats span { color: var(--muted); font-size: 14px; }

/* Sections */
.section { max-width: 1180px; margin: 0 auto; padding: 96px 16px 0; }
h2 { font-size: clamp(30px, 4vw, 46px); letter-spacing: -0.03em; line-height: 1.1; margin: 0 0 16px; font-weight: 720; text-align: center; }
h3 { margin: 0 0 6px; font-size: 20px; letter-spacing: -0.01em; }
.section-lead { color: var(--muted); max-width: 42em; margin: 0 auto 44px; text-align: center; font-size: 18px; }
.section-lead b { color: var(--text); }
.center { text-align: center; }
.small { color: var(--faint); font-size: 14px; }
.small a { color: var(--muted); }

.wheels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.wheel-card {
  background: linear-gradient(180deg, var(--card), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.25s, border-color 0.25s;
}
.wheel-card:hover { transform: translateY(-4px); border-color: var(--line-2); }
.shot { aspect-ratio: 1; overflow: hidden; }
.shot img { width: 100%; height: 100%; object-fit: cover; }
.wheel-text { padding: 22px 24px 26px; }
.wheel-text p { color: var(--muted); margin: 0; font-size: 16px; }
kbd.big { font-size: 13px; padding: 4px 10px; margin-bottom: 12px; background: var(--grad); border-color: transparent; box-shadow: 0 3px 0 rgba(120, 30, 40, 0.6); }

.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 44px; }
.feature {
  padding: 26px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
}
.feature svg { width: 26px; height: 26px; fill: var(--accent); margin-bottom: 14px; }
.feature p { color: var(--muted); margin: 0; font-size: 16px; }

.formats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 40px; }
.fmt {
  padding: 18px 22px;
  border-radius: 14px;
  background: var(--card);
  border: 1px solid var(--line);
}
.fmt h3 { font-size: 16px; color: var(--accent); margin-bottom: 4px; }
.fmt p { margin: 0; color: var(--muted); font-size: 15px; }
.fmt .to { color: var(--accent-2); font-weight: 700; padding: 0 4px; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split h2, .split .section-lead { text-align: left; margin-left: 0; }
.split .section-lead { margin-bottom: 20px; }
.note { color: var(--muted); font-size: 15.5px; }
.note a { color: var(--text); }
.terminal {
  margin: 0;
  background: #0a0a0e;
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  padding: 0 0 20px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 14px;
  line-height: 1.7;
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.9);
}
.terminal code { display: block; padding: 0 22px; background: none; font-size: inherit; white-space: pre; }
.t-bar { display: flex; gap: 7px; padding: 14px 16px 16px; }
.t-bar i { width: 11px; height: 11px; border-radius: 50%; background: #3a3a44; }
.t-bar i:first-child { background: #ff5f57; }
.t-bar i:nth-child(2) { background: #febc2e; }
.t-bar i:nth-child(3) { background: #28c840; }
.terminal .c { color: #6f6f7d; }
.terminal .p { color: var(--accent); }
.terminal .o { color: #3cc36e; }

.downloads { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 14px; margin-bottom: 22px; }
.dl {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
  text-decoration: none;
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}
.dl:hover { transform: translateY(-3px); border-color: var(--line-2); background: var(--card-2); }
.dl-os { width: 28px; height: 28px; fill: var(--text); margin-bottom: 14px; }
.dl-title { font-weight: 700; font-size: 18px; }
.dl-sub { color: var(--muted); font-size: 14px; }
.dl-size { margin-top: 14px; color: var(--faint); font-size: 13px; font-family: var(--mono); }
.dl-main {
  background: linear-gradient(140deg, rgba(255, 138, 31, 0.22), rgba(255, 79, 106, 0.22)), var(--card);
  border-color: rgba(255, 120, 80, 0.45);
}
.dl-main:hover { background: linear-gradient(140deg, rgba(255, 138, 31, 0.3), rgba(255, 79, 106, 0.3)), var(--card); border-color: rgba(255, 120, 80, 0.7); }
.dl-main .dl-size { color: #ffc2a8; }

.faq { max-width: 780px; }
.faq h2 { margin-bottom: 30px; }
details {
  border-bottom: 1px solid var(--line);
  padding: 18px 4px;
}
summary {
  cursor: pointer;
  font-weight: 650;
  font-size: 18px;
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--accent); font-size: 24px; line-height: 1; transition: transform 0.2s; }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--muted); margin: 12px 0 0; }

.footer {
  max-width: 1180px;
  margin: 110px auto 0;
  padding: 30px 16px 40px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 28px;
  color: var(--faint);
  font-size: 14px;
}
.footer p { margin: 0; flex: 1; min-width: 240px; }
.footer a { color: var(--muted); }
.footer .brand { color: var(--text); font-size: 16px; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.6s, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; padding-top: 48px; gap: 36px; text-align: center; }
  .lead { margin-left: auto; margin-right: auto; }
  .cta { justify-content: center; }
  .wheels, .features { grid-template-columns: 1fr 1fr; }
  .downloads { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; }
  .split h2, .split .section-lead { text-align: center; margin-left: auto; }
  .note { text-align: center; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  .nav { gap: 12px; }
  .nav-links { display: none; }
  .stats { grid-template-columns: 1fr 1fr; }
  .wheels, .features, .formats, .downloads { grid-template-columns: 1fr; }
  .section { padding-top: 72px; }
  .btn { width: 100%; justify-content: center; }
  .toast { min-width: 0; left: 5%; right: 5%; }
  .keycap { bottom: auto; top: 5%; left: auto; right: 5%; }
  .desk-name { font-size: 11px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .reveal { opacity: 1; transform: none; }
}
