:root {
  --ff-bg: #262626;
  --ff-bg-list: #1a1a1a;
  --ff-bg-list-alt: #222222;
  --ff-border: #404040;
  --ff-accent: #38bdf8;
  --ff-accent-translucent: rgba(56, 189, 248, 0.2);
  --ff-warning: #fbbf24;
  --ff-warning-translucent: rgba(251, 191, 36, 0.1);
  --ff-warning-border: rgba(251, 191, 36, 0.3);
  --ff-primary: #1d4ed8;
  --ff-primary-hover: #1e40af;
  --ff-primary-active: #1e3a8a;
  --ff-fg: #fafafa;
  --ff-fg-muted: #a3a3a3;
  --ff-fg-faint: #707070;

  --ff-font-sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --ff-font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  --ff-font-display: "Space Grotesk", var(--ff-font-sans);
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: dark;
}

body {
  margin: 0;
  background: var(--ff-bg);
  color: var(--ff-fg);
  font-family: var(--ff-font-sans);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Film-grain texture over the whole page — subtle, never blocks interaction. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a {
  color: var(--ff-accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img, video {
  max-width: 100%;
  display: block;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Disclaimer banner */

.disclaimer-card {
  display: flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  margin: 0 auto 32px;
  padding: 7px 16px;
  background: var(--ff-warning-translucent);
  border: 1px solid var(--ff-warning-border);
  border-radius: 12px;
  color: var(--ff-fg-muted);
  font-size: 24px;
  text-align: center;
  position: relative;
  z-index: 1;
}

.disclaimer-card strong {
  color: var(--ff-warning);
  font-weight: 600;
}

/* Hero */

.hero {
  position: relative;
  z-index: 2;
  overflow: visible;
  padding: 88px 0 72px;
}

.hero .container {
  position: relative;
  z-index: 1;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: center;
  gap: 40px;
}

@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
}

.accent-text {
  background: linear-gradient(100deg, var(--ff-accent), var(--ff-primary-hover) 110%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--ff-font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ff-accent);
  background: var(--ff-accent-translucent);
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 24px;
}

.hero h1 {
  font-family: var(--ff-font-display);
  font-size: clamp(34px, 4.6vw, 52px);
  font-weight: 600;
  line-height: 1.1;
  margin: 0 0 20px;
  letter-spacing: -0.02em;
}

.hero-sub {
  max-width: 480px;
  margin: 0 0 36px;
  font-size: 18px;
  color: var(--ff-fg-muted);
}

.hero-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

@media (max-width: 960px) {
  .hero-sub {
    margin: 0 auto 36px;
  }

  .hero-cta {
    align-items: center;
  }
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--ff-primary);
  color: var(--ff-fg);
  font-family: var(--ff-font-display);
  font-size: 17px;
  font-weight: 600;
  padding: 14px 28px;
  border-radius: 10px 0 0 10px;
  text-decoration: none;
  transition: background-color 0.15s ease, box-shadow 0.15s ease;
}

.btn-primary:hover {
  background: var(--ff-primary-hover);
  text-decoration: none;
}

.btn-primary:active {
  background: var(--ff-primary-active);
}

.hero-caption {
  font-size: 13px;
  color: var(--ff-fg-faint);
}

/* App mock — decorative, looping preview of the dual-pane UI + fuzzy search.
   Chrome/markup/colors adapted from web/landings' fuzzy-demo (same source of
   truth: apps/filefather-gpui/src/theme/filefather-dark.json + panel/*.rs),
   extended here with a second (unfocused) panel for the full dual-pane view. */

:root {
  --app-chrome-bg: #262626;
  --app-elevated-bg: #303030;
  --app-list-bg: #1a1a1a;
  --app-list-even-bg: #222222;
  --app-cursor-bg: #162530;
  --app-row-grid: 14px 1fr 52px;
}

.app-mock {
  position: relative;
  min-width: 0;
  transform: perspective(1400px) rotateY(-4deg) rotateX(2deg);
  transition: transform 0.2s ease-out;
}

@media (max-width: 960px) {
  .app-mock {
    transform: none;
  }
}

.fuzzy-demo {
  text-align: left;
  background: var(--app-chrome-bg);
  border: 1px solid var(--ff-border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 28px 64px rgba(0, 0, 0, 0.5);
}

.fuzzy-demo-titlebar {
  position: relative;
  display: flex;
  align-items: center;
  gap: 22px;
  height: 40px;
  padding: 0 16px;
  background: var(--app-chrome-bg);
}

.fuzzy-demo-dots {
  display: flex;
  gap: 8px;
}

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.dot-red { background: #ff5f56; }
.dot-yellow { background: #ffbd2e; }
.dot-green { background: #27c93f; }

.fuzzy-demo-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--ff-fg);
}

.nav-icon {
  width: 14px;
  height: 14px;
}

.nav-arrow-disabled {
  color: var(--ff-fg-faint);
}

.fuzzy-demo-titlebar-name {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  font-size: 14px;
  font-weight: 600;
  color: var(--ff-fg);
  white-space: nowrap;
}

.fuzzy-demo-titlebar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  color: var(--ff-fg);
}

.titlebar-icon svg {
  display: block;
  width: 14px;
  height: 14px;
}

.fuzzy-demo-panes {
  display: flex;
  align-items: flex-start;
}

.fuzzy-demo-panel {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  margin: 0 4px 8px 8px;
  border: 1px solid var(--ff-accent);
  border-radius: 0 0 0 8px;
  overflow: hidden;
}

.fuzzy-demo-panel-inactive {
  margin: 0 8px 8px 4px;
  border-color: var(--ff-border);
  border-radius: 0 0 8px 0;
}

.fuzzy-demo-tabs {
  display: flex;
  align-items: stretch;
  height: 32px;
  flex-shrink: 0;
  background: var(--app-chrome-bg);
  border-bottom: 1px solid var(--ff-border);
}

.fuzzy-demo-tabs-scroll {
  flex: 1;
  display: flex;
  align-items: stretch;
  min-width: 0;
}

.fuzzy-demo-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--ff-fg-muted);
  padding: 0 10px;
  border-right: 1px solid var(--ff-border);
  position: relative;
  white-space: nowrap;
}

.fuzzy-demo-tab-active {
  background: var(--app-elevated-bg);
  color: var(--ff-fg);
}

.fuzzy-demo-tab-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--ff-accent);
}

.fuzzy-demo-tab-close {
  color: var(--ff-fg-faint);
  font-size: 13px;
  line-height: 1;
}

.fuzzy-demo-tab-add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  flex-shrink: 0;
  color: var(--ff-fg-faint);
  font-size: 15px;
  border-left: 1px solid var(--ff-border);
  background: var(--app-chrome-bg);
}

.fuzzy-demo-breadcrumb {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  height: 32px;
  padding: 0 10px;
  font-size: 11px;
  color: var(--ff-fg-muted);
  background: var(--app-elevated-bg);
  white-space: nowrap;
  overflow: hidden;
  flex-shrink: 0;
}

.breadcrumb-path {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.breadcrumb-sep {
  color: var(--ff-fg-faint);
}

.breadcrumb-current {
  color: var(--ff-fg);
  font-weight: 600;
}

.breadcrumb-branch {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--ff-fg);
  font-size: 12px;
  flex-shrink: 0;
}

.branch-icon,
.branch-caret-icon {
  width: 13px;
  height: 13px;
}

.fuzzy-demo-frame {
  border-top: 1px solid var(--ff-border);
  border-bottom: 1px solid var(--ff-border);
}

ul.fuzzy-demo-list {
  list-style: none;
  margin: 0;
  padding: 0;
  height: 168px;
  overflow: hidden;
  font-size: 13px;
  background: var(--app-list-bg);
}

.fuzzy-row {
  display: grid;
  grid-template-columns: var(--app-row-grid);
  column-gap: 6px;
  align-items: center;
  height: 24px;
  padding: 0 6px;
  box-sizing: border-box;
  border-style: solid;
  border-width: 1px 6px;
  border-color: transparent;
  white-space: nowrap;
}

.fuzzy-row .row-icon {
  width: 15px;
  height: 15px;
  object-fit: contain;
}

.fuzzy-row:nth-child(even) {
  background: var(--app-list-even-bg);
}

.fuzzy-row-parent {
  color: var(--ff-fg-muted);
}

.fuzzy-row-name {
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--ff-fg);
}

.fuzzy-row-name mark {
  background: var(--ff-primary);
  color: var(--ff-fg);
  font-weight: 700;
  border-radius: 2px;
  padding: 0 1px;
}

.fuzzy-row-size {
  color: var(--ff-fg-muted);
  font-size: 12px;
  text-align: right;
}

.fuzzy-row.is-cursor {
  background: var(--app-cursor-bg);
  border-color: var(--ff-accent);
}

.fuzzy-row-empty {
  color: var(--ff-fg-faint);
  justify-content: center;
  grid-template-columns: 1fr;
  text-align: center;
}

.fuzzy-demo-searchbar {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 12px;
  background: var(--ff-primary);
  flex-shrink: 0;
}

.fuzzy-demo-searchbar span {
  font-size: 11px;
  font-weight: 700;
  font-family: var(--ff-font-mono);
  color: var(--ff-fg);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.fuzzy-demo-searchbar-idle {
  background: var(--app-elevated-bg);
}

.fuzzy-demo-searchbar-idle span {
  font-weight: 500;
  color: var(--ff-fg-faint);
}

.fuzzy-demo-caret {
  width: 2px;
  height: 13px;
  background: var(--ff-fg);
  animation: caret-blink 1s steps(1) infinite;
}

@keyframes caret-blink {
  50% { opacity: 0; }
}


@media (max-width: 460px) {
  .fuzzy-demo-nav {
    display: none;
  }
}


/* Split download button */

.split-button {
  position: relative;
  display: inline-flex;
  align-items: stretch;
  border-radius: 10px;
  transition: transform 0.15s ease-out, box-shadow 0.15s ease;
}

.split-button:hover {
  box-shadow: 0 0 0 6px color-mix(in srgb, var(--ff-primary) 25%, transparent);
}

.split-caret {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  border: none;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 0 10px 10px 0;
  background: var(--ff-primary);
  color: var(--ff-fg);
  font-size: 13px;
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.split-caret:hover {
  background: var(--ff-primary-hover);
}

.split-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  min-width: max(100%, 260px);
  display: flex;
  flex-direction: column;
  background: var(--ff-bg-list);
  border: 1px solid var(--ff-border);
  border-radius: 10px;
  overflow: hidden;
  z-index: 50;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.split-menu[hidden] {
  display: none;
}

.split-menu a {
  padding: 10px 16px;
  font-size: 14px;
  color: var(--ff-fg);
  text-align: left;
}

.split-menu a:hover {
  background: var(--ff-bg-list-alt);
  text-decoration: none;
}

.split-menu a + a {
  border-top: 1px solid var(--ff-border);
}

/* Bento feature grid */

main {
  position: relative;
  z-index: 1;
}

.bento {
  padding-bottom: 80px;
}

.bento h2 {
  font-family: var(--ff-font-display);
  font-weight: 600;
  font-size: 24px;
  margin: 0 0 12px;
  letter-spacing: -0.01em;
  /* text-align: center; */
}

.bento-lead {
  max-width: 640px;
  margin: 0 0 24px;
  font-size: 16px;
  line-height: 1.55;
  color: var(--ff-fg-muted);
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.bento-card {
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --reveal-y: 0px;
  position: relative;
  grid-column: span 1;
  padding: 22px 24px;
  background: var(--ff-bg-list);
  border: 1px solid var(--ff-border);
  border-radius: 14px;
  transform: translateY(var(--reveal-y)) perspective(600px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease-out, opacity 0.5s ease;
  overflow: hidden;
}

.bento-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  opacity: 0;
  transition: opacity 0.2s ease;
  background: radial-gradient(220px circle at var(--glare-x, 50%) var(--glare-y, 50%), rgba(255, 255, 255, 0.08), transparent 70%);
}

.bento-card:hover::after {
  opacity: 1;
}

.bento-card > * {
  position: relative;
  z-index: 1;
}

/* Reveal-on-scroll is progressive enhancement: main.ts only adds "reveal-ready"
   when JS runs and the visitor hasn't asked for reduced motion, so cards stay
   visible by default (no-JS, reduced-motion). */
.reveal-ready .bento-card {
  opacity: 0;
  --reveal-y: 12px;
}

.reveal-ready .bento-card.in-view {
  opacity: 1;
  --reveal-y: 0px;
}

.bento-card:hover {
  border-color: color-mix(in srgb, var(--ff-accent) 50%, var(--ff-border));
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--ff-accent) 25%, transparent), 0 16px 32px rgba(0, 0, 0, 0.3);
}

.bento-card-wide {
  grid-column: span 2;
}

.bento-chip {
  display: inline-block;
  font-family: var(--ff-font-mono);
  font-size: 12px;
  color: var(--ff-accent);
  background: var(--ff-accent-translucent);
  border: 1px solid rgba(56, 189, 248, 0.3);
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 14px;
}

.bento-card h3 {
  font-family: var(--ff-font-display);
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}

.bento-card p {
  font-size: 14px;
  color: var(--ff-fg-muted);
  margin: 0;
}

@media (max-width: 860px) {
  .bento-grid {
    grid-template-columns: 1fr;
  }

  .bento-card-wide {
    grid-column: span 1;
  }
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--ff-border);
  padding: 32px 0 48px;
}

.site-footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--ff-fg-faint);
  font-size: 13px;
}

@media (prefers-reduced-motion: reduce) {
  .fuzzy-demo-caret {
    animation: none;
  }

  .bento-card,
  .split-button,
  .app-mock {
    transition: none;
  }
}
