{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "feature2",
  "title": "Alternating Rows With Mixed Media",
  "description": "Hero header with a CTA, then alternating image-left / image-right rows. Each row's media slot accepts an image, video, or live registry-component asset.",
  "dependencies": [
    "clsx",
    "tailwind-merge",
    "lucide-react"
  ],
  "registryDependencies": [
    "badge",
    "button"
  ],
  "files": [
    {
      "path": "registry/feature2/feature2.tsx",
      "content": "\"use client\";\n\nimport { Badge } from \"@/components/ui/badge\";\nimport { Browser27 } from \"@/components/beste/piece/browser27\";\nimport { Browser28 } from \"@/components/beste/piece/browser28\";\nimport { Button } from \"@/components/ui/button\";\nimport { Calendar19 } from \"@/components/beste/piece/calendar19\";\nimport Link from \"next/link\";\nimport { cn } from \"@/lib/utils\";\n\ntype ComponentBackground =\n  | { type: \"dots\" }\n  | { type: \"none\" }\n  | { type: \"image\"; src: string; alt?: string }\n  | { type: \"video\"; src: string; alt?: string };\n\ntype RowMedia =\n  | { type: \"image\"; src: string; alt?: string }\n  | { type: \"video\"; src: string; alt?: string }\n  | {\n      type: \"component\";\n      component: React.ReactNode;\n      background?: ComponentBackground;\n    };\n\ninterface FeatureRow {\n  title: string;\n  description: string;\n  media: RowMedia;\n}\n\ninterface ButtonItem {\n  label: string;\n  href?: string;\n  variant?: \"default\" | \"secondary\" | \"outline\" | \"ghost\" | \"link\" | \"destructive\";\n}\n\ninterface Feature2Props {\n  badge?: {\n    label: string;\n    variant?: \"default\" | \"secondary\" | \"outline\";\n  };\n  heading?: string;\n  description?: string;\n  buttons?: ButtonItem[];\n  rows?: FeatureRow[];\n  className?: string;\n}\n\nexport const feature2Demo: Feature2Props = {\n  badge: { label: \"Browser-grade surfaces\", variant: \"secondary\" },\n  heading: \"Three pieces of the customer-facing toolkit\",\n  description:\n    \"Tiny cards that mimic real browser and calendar chrome — drop them into hero shots, marketing pages, and product walkthroughs without rebuilding the surface from scratch.\",\n  buttons: [{ label: \"Read the playbook\", href: \"https://beste.co/playbook\" }],\n  rows: [\n    {\n      title: \"Site identity, made glanceable\",\n      description:\n        \"A site-info popover that mirrors the lock icon and permission list users already know from their browser. Useful for trust pages, security marketing, and developer docs.\",\n      media: {\n        type: \"component\",\n        component: <Browser27 domain=\"stripe.com\" />,\n      },\n    },\n    {\n      title: \"Stack the domains your customers ship\",\n      description:\n        \"Layered browser windows show the multi-tenant story without diagrams. Drop in the subdomains that matter, the layout adapts to any depth.\",\n      media: {\n        type: \"component\",\n        component: (\n          <Browser28\n            domains={[\"customer.beste.co\", \"project.beste.co\", \"jane.beste.co\", \"joe.beste.co\"]}\n          />\n        ),\n      },\n    },\n    {\n      title: \"Plan the day, not the week\",\n      description:\n        \"A vertical day planner with tone-coded blocks. Pulls focus, meetings, and admin into one column so the schedule reads as a single shape.\",\n      media: {\n        type: \"component\",\n        component: (\n          <Calendar19\n            date=\"Mon · Apr 27\"\n            blocks={[\n              { start: \"09:00\", label: \"Focus · API refactor\", tone: \"focus\" },\n              { start: \"10:30\", label: \"Standup\", tone: \"meeting\" },\n              { start: \"11:00\", label: \"Focus · API refactor\", tone: \"focus\" },\n              { start: \"12:00\", label: \"Lunch\", tone: \"break\" },\n              { start: \"13:00\", label: \"Design review\", tone: \"meeting\" },\n              { start: \"14:30\", label: \"Email & admin\", tone: \"admin\" },\n            ]}\n          />\n        ),\n      },\n    },\n  ],\n};\n\nexport function Feature2({\n  badge,\n  heading,\n  description,\n  buttons = [],\n  rows = [],\n  className,\n}: Feature2Props) {\n  return (\n    <section className={cn(\"py-16 md:py-24 w-full\", className)}>\n      <div className=\"mx-auto max-w-6xl px-4 md:px-6\">\n        <div className=\"flex max-w-2xl flex-col gap-4\">\n          {badge && (\n            <div>\n              <Badge variant={badge.variant ?? \"default\"}>{badge.label}</Badge>\n            </div>\n          )}\n          {heading && (\n            <h2 className=\"text-2xl font-semibold tracking-tight md:text-4xl\">{heading}</h2>\n          )}\n          {description && (\n            <p className=\"text-base md:text-lg text-muted-foreground\">{description}</p>\n          )}\n          {buttons.length > 0 && (\n            <div className=\"mt-2 flex flex-wrap gap-3\">\n              {buttons.map((button, index) => (\n                <Button key={index} variant={button.variant ?? \"default\"} asChild>\n                  <Link href={button.href ?? \"#\"}>{button.label}</Link>\n                </Button>\n              ))}\n            </div>\n          )}\n        </div>\n\n        <div className=\"mt-16 flex flex-col gap-10 md:gap-16\">\n          {rows.map((row, index) => {\n            const reverse = index % 2 === 1;\n            return (\n              <div\n                key={index}\n                className={cn(\n                  \"flex flex-col gap-6 md:items-center md:gap-10\",\n                  reverse ? \"md:flex-row-reverse\" : \"md:flex-row\"\n                )}\n              >\n                <div className=\"md:w-1/2\">\n                  <RowMediaSurface media={row.media} />\n                </div>\n                <div className=\"flex flex-col gap-3 md:w-1/2\">\n                  <h3 className=\"text-lg font-semibold md:text-2xl\">{row.title}</h3>\n                  <p className=\"text-sm text-muted-foreground md:text-base\">{row.description}</p>\n                </div>\n              </div>\n            );\n          })}\n        </div>\n      </div>\n    </section>\n  );\n}\n\nfunction RowMediaSurface({ media }: { media: RowMedia }) {\n  const componentBackground =\n    media.type === \"component\" ? (media.background ?? { type: \"dots\" }) : null;\n  const showDots = componentBackground?.type === \"dots\";\n\n  return (\n    <div\n      className=\"relative flex aspect-video items-center justify-center overflow-hidden rounded-md border bg-muted/30\"\n      style={\n        showDots\n          ? {\n              backgroundImage: \"radial-gradient(circle, var(--border) 1px, transparent 1px)\",\n              backgroundSize: \"16px 16px\",\n            }\n          : undefined\n      }\n    >\n      {componentBackground?.type === \"image\" && (\n        <img\n          className=\"absolute inset-0 size-full object-cover\"\n          src={componentBackground.src}\n          alt={componentBackground.alt ?? \"\"}\n          aria-hidden=\"true\"\n        />\n      )}\n      {componentBackground?.type === \"video\" && (\n        <video\n          src={componentBackground.src}\n          autoPlay\n          loop\n          muted\n          playsInline\n          className=\"absolute inset-0 size-full object-cover\"\n        />\n      )}\n\n      {media.type === \"video\" ? (\n        <video\n          src={media.src}\n          autoPlay\n          loop\n          muted\n          playsInline\n          aria-label={media.alt}\n          className=\"size-full object-cover\"\n        />\n      ) : media.type === \"image\" ? (\n        <img\n          className=\"absolute inset-0 size-full object-cover\"\n          src={media.src}\n          alt={media.alt ?? \"\"}\n        />\n      ) : (\n        <div className=\"relative flex size-full items-center justify-center\">{media.component}</div>\n      )}\n    </div>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/beste/block/feature2.tsx"
    },
    {
      "path": "registry-pieces/browser27/browser27.tsx",
      "content": "\"use client\";\n\nimport { Camera, Lock, MapPin, Mic, type LucideIcon } from \"lucide-react\";\nimport { cn } from \"@/lib/utils\";\n\ntype Surface = \"card\" | \"glass\";\n\ntype PermissionIcon = \"camera\" | \"location\" | \"mic\" | \"lock\";\n\ninterface Permission {\n  icon?: PermissionIcon;\n  label: string;\n  granted?: boolean;\n  grantedLabel?: string;\n  deniedLabel?: string;\n}\n\ninterface Browser27Props {\n  domain?: string;\n  connectionLabel?: string;\n  permissions?: Permission[];\n  defaultGrantedLabel?: string;\n  defaultDeniedLabel?: string;\n  surface?: Surface;\n  bordered?: boolean;\n  inverted?: boolean;\n  className?: string;\n}\n\nconst ICONS: Record<PermissionIcon, LucideIcon> = {\n  camera: Camera,\n  location: MapPin,\n  mic: Mic,\n  lock: Lock,\n};\n\n\n/* The card sets the colour and everything inside it is drawn in `current`, so\n   inverting is two classes rather than a condition on every element.\n   `glass` is a deliberate exception to the solid-surface rule: these pieces sit\n   over section background images, and a frosted panel is the point of it. */\nconst surfaceClasses: Record<Surface, { plain: string; inverted: string }> = {\n  card: {\n    plain: \"bg-card text-card-foreground\",\n    inverted: \"bg-foreground text-background\",\n  },\n  glass: {\n    plain: \"bg-card/60 text-card-foreground backdrop-blur-md\",\n    inverted: \"bg-foreground/60 text-background backdrop-blur-md\",\n  },\n};\n\nexport const browser27Demo: Browser27Props = {\n  surface: \"card\",\n  bordered: false,\n  inverted: false,\n  domain: \"stripe.com\",\n  connectionLabel: \"Connection is secure\",\n  permissions: [\n    { icon: \"camera\", label: \"Camera\", granted: true },\n    { icon: \"location\", label: \"Location\", granted: false },\n  ],\n  defaultGrantedLabel: \"Allowed\",\n  defaultDeniedLabel: \"Ask\",\n};\n\nexport function Browser27({\n  domain = \"example.com\",\n  connectionLabel = \"Connection is secure\",\n  permissions = [],\n  defaultGrantedLabel = \"Allowed\",\n  defaultDeniedLabel = \"Ask\",\n  surface = \"card\",\n  bordered = false,\n  inverted = false,\n  className,\n}: Browser27Props) {\n  const surfaceTone = surfaceClasses[surface][inverted ? \"inverted\" : \"plain\"];\n\n  return (\n    <div\n      className={cn(\n        \"relative flex size-full items-center justify-center p-4\",\n        className\n      )}\n    >\n      <div\n        className={cn(\n          \"flex w-full max-w-72 flex-col gap-2 rounded-lg p-3 shadow-md\",\n          surfaceTone,\n          bordered && \"border border-current/15\"\n        )}\n      >\n        <div className=\"flex items-center gap-2\">\n          <Lock\n            className=\"size-4 shrink-0 text-emerald-600 dark:text-emerald-400\"\n            aria-hidden=\"true\"\n          />\n          <div className=\"flex min-w-0 flex-1 flex-col\">\n            <span className=\"truncate text-sm font-semibold\">\n              {domain}\n            </span>\n            <span className=\"text-xs text-emerald-600 dark:text-emerald-400\">\n              {connectionLabel}\n            </span>\n          </div>\n        </div>\n        {permissions.length > 0 && (\n          <div className=\"flex flex-col gap-1 border-t border-current/15 pt-2 text-xs\">\n            {permissions.map((p, idx) => {\n              const Icon = ICONS[p.icon ?? \"lock\"];\n              const granted = p.granted ?? false;\n              return (\n                <div\n                  key={`${p.label}-${idx}`}\n                  className=\"flex items-center justify-between gap-2\"\n                >\n                  <div className=\"flex items-center gap-2\">\n                    <Icon\n                      className=\"size-3.5 text-current/60\"\n                      aria-hidden=\"true\"\n                    />\n                    <span>{p.label}</span>\n                  </div>\n                  <span\n                    className={cn(\n                      \"font-semibold\",\n                      granted\n                        ? \"text-emerald-600 dark:text-emerald-400\"\n                        : \"text-current/60\"\n                    )}\n                  >\n                    {granted\n                      ? p.grantedLabel ?? defaultGrantedLabel\n                      : p.deniedLabel ?? defaultDeniedLabel}\n                  </span>\n                </div>\n              );\n            })}\n          </div>\n        )}\n      </div>\n    </div>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/beste/piece/browser27.tsx"
    },
    {
      "path": "registry-pieces/browser28/browser28.tsx",
      "content": "\"use client\";\n\nimport { Lock } from \"lucide-react\";\nimport { cn } from \"@/lib/utils\";\n\ntype Surface = \"card\" | \"glass\";\n\ninterface Browser28Props {\n  domains?: string[];\n  surface?: Surface;\n  bordered?: boolean;\n  inverted?: boolean;\n  className?: string;\n}\n\n\n/* The card sets the colour and everything inside it is drawn in `current`, so\n   inverting is two classes rather than a condition on every element.\n   `glass` is a deliberate exception to the solid-surface rule: these pieces sit\n   over section background images, and a frosted panel is the point of it. */\nconst surfaceClasses: Record<Surface, { plain: string; inverted: string }> = {\n  card: {\n    plain: \"bg-card text-card-foreground\",\n    inverted: \"bg-foreground text-background\",\n  },\n  glass: {\n    plain: \"bg-card/60 text-card-foreground backdrop-blur-md\",\n    inverted: \"bg-foreground/60 text-background backdrop-blur-md\",\n  },\n};\n\nexport const browser28Demo: Browser28Props = {\n  surface: \"card\",\n  bordered: false,\n  inverted: false,\n  domains: [\n    \"customer.beste.co\",\n    \"project.beste.co\",\n    \"jane.beste.co\",\n    \"joe.beste.co\",\n  ],\n};\n\nconst LAYERS = [\n  {\n    radius: 8,\n    py: 8,\n    px: 12,\n    barH: 16,\n    fontSize: 12,\n    buttonSize: 8,\n    buttonGap: 4,\n    iconSize: 12.5,\n  },\n  {\n    radius: 7,\n    py: 6.75,\n    px: 10,\n    barH: 14,\n    fontSize: 9.5,\n    buttonSize: 7,\n    buttonGap: 4,\n    iconSize: 10.5,\n  },\n  {\n    radius: 6,\n    py: 6,\n    px: 8.75,\n    barH: 12,\n    fontSize: 7.75,\n    buttonSize: 6,\n    buttonGap: 2,\n    iconSize: 9,\n  },\n  {\n    radius: 5,\n    py: 5,\n    px: 7.5,\n    barH: 10,\n    fontSize: 6,\n    buttonSize: 5,\n    buttonGap: 2,\n    iconSize: 7,\n  },\n];\n\nconst TRAFFIC = [\"bg-rose-400\", \"bg-amber-400\", \"bg-emerald-400\"];\n\nexport function Browser28({ domains = [], surface = \"card\", bordered = false, inverted = false, className }: Browser28Props) {\n  const list = domains.slice(0, LAYERS.length);\n  const label = `Stacked browser windows for ${list.join(\", \")}`;\n\n  const surfaceTone = surfaceClasses[surface][inverted ? \"inverted\" : \"plain\"];\n\n  return (\n    <div\n      className={cn(\n        \"relative flex size-full items-center justify-center p-4\",\n        className\n      )}\n    >\n      <div\n        aria-label={label}\n        className=\"mx-auto flex h-full w-11/12 max-w-80 flex-col-reverse items-center justify-center\"\n      >\n        {list.map((domain, i) => {\n          const l = LAYERS[i]!;\n          return (\n            <div\n              key={i}\n              aria-hidden=\"true\"\n              className={cn(\"relative flex w-full items-center shadow-sm\", surfaceTone, bordered && \"border border-current/15\")}\n              style={{\n                width: `calc(100% - ${32 * i}px)`,\n                borderRadius: `${l.radius}px ${l.radius}px 0 0`,\n                padding: `${l.py}px ${l.px}px`,\n                zIndex: 10 - i,\n                opacity: 1 - i * 0.1,\n                marginBottom: -2,\n              }}\n            >\n              <div\n                className=\"flex items-center\"\n                style={{ gap: `${l.buttonGap}px` }}\n              >\n                {[0, 1, 2].map((d) => (\n                  <span\n                    key={d}\n                    className={cn(\n                      \"shrink-0 rounded-full\",\n                      i === 0 ? TRAFFIC[d] : \"bg-current/10\"\n                    )}\n                    style={{\n                      width: `${l.buttonSize}px`,\n                      height: `${l.buttonSize}px`,\n                    }}\n                    aria-hidden=\"true\"\n                  />\n                ))}\n              </div>\n              <div\n                className=\"mx-auto flex items-center justify-center gap-1 rounded-full\"\n                style={{\n                  height: `${l.barH}px`,\n                  fontSize: `${l.fontSize}px`,\n                }}\n              >\n                <Lock\n                  className=\"text-current/60\"\n                  style={{\n                    width: `${l.iconSize}px`,\n                    height: `${l.iconSize}px`,\n                  }}\n                  aria-hidden=\"true\"\n                />\n                <span className=\"truncate\">{domain}</span>\n              </div>\n            </div>\n          );\n        })}\n      </div>\n    </div>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/beste/piece/browser28.tsx"
    },
    {
      "path": "registry-pieces/calendar19/calendar19.tsx",
      "content": "\"use client\";\n\nimport { cn } from \"@/lib/utils\";\n\ntype Surface = \"card\" | \"glass\";\n\ninterface Block {\n  start: string;\n  label: string;\n  tone: \"focus\" | \"meeting\" | \"break\" | \"admin\";\n}\n\ninterface Calendar19Props {\n  date?: string;\n  blocks?: Block[];\n  surface?: Surface;\n  bordered?: boolean;\n  inverted?: boolean;\n  className?: string;\n}\n\nconst toneClasses: Record<Block[\"tone\"], string> = {\n  focus: \"bg-sky-500/15 text-sky-700 dark:text-sky-300\",\n  meeting: \"bg-violet-500/15 text-violet-700 dark:text-violet-300\",\n  break: \"bg-emerald-500/15 text-emerald-700 dark:text-emerald-300\",\n  admin: \"bg-amber-500/15 text-amber-700 dark:text-amber-300\",\n};\n\n\n/* The card sets the colour and everything inside it is drawn in `current`, so\n   inverting is two classes rather than a condition on every element.\n   `glass` is a deliberate exception to the solid-surface rule: these pieces sit\n   over section background images, and a frosted panel is the point of it. */\nconst surfaceClasses: Record<Surface, { plain: string; inverted: string }> = {\n  card: {\n    plain: \"bg-card text-card-foreground\",\n    inverted: \"bg-foreground text-background\",\n  },\n  glass: {\n    plain: \"bg-card/60 text-card-foreground backdrop-blur-md\",\n    inverted: \"bg-foreground/60 text-background backdrop-blur-md\",\n  },\n};\n\nexport const calendar19Demo: Calendar19Props = {\n  surface: \"card\",\n  bordered: false,\n  inverted: false,\n  date: \"Mon · Apr 27\",\n  blocks: [\n    { start: \"09:00\", label: \"API refactor\", tone: \"focus\" },\n    { start: \"10:30\", label: \"Standup\", tone: \"meeting\" },\n    { start: \"12:00\", label: \"Lunch\", tone: \"break\" },\n    { start: \"14:30\", label: \"Email & admin\", tone: \"admin\" },\n  ],\n};\n\nexport function Calendar19({\n  date,\n  blocks = [],\n  surface = \"card\",\n  bordered = false,\n  inverted = false,\n  className,\n}: Calendar19Props) {\n  const surfaceTone = surfaceClasses[surface][inverted ? \"inverted\" : \"plain\"];\n\n  return (\n    <div\n      className={cn(\n        \"relative flex size-full items-center justify-center p-4\",\n        className\n      )}\n    >\n      <div className={cn(\"flex w-full max-w-80 flex-col gap-2 rounded-xl p-3 shadow-sm\", surfaceTone, bordered && \"border border-current/15\")}>\n        {date && (\n          <span className=\"text-xs font-semibold text-current/60\">\n            {date}\n          </span>\n        )}\n        <div className=\"flex flex-col gap-1.5\">\n          {blocks.map((b, idx) => (\n            <div key={idx} className=\"flex items-center gap-3\">\n              <span className=\"w-12 shrink-0 text-right text-xs tabular-nums text-current/60\">\n                {b.start}\n              </span>\n              <div\n                className={cn(\n                  \"flex min-h-8 flex-1 items-center rounded-md px-2.5 py-1\",\n                  toneClasses[b.tone]\n                )}\n              >\n                <span className=\"text-sm font-medium\">\n                  {b.label}\n                </span>\n              </div>\n            </div>\n          ))}\n        </div>\n      </div>\n    </div>\n  );\n}\n",
      "type": "registry:component",
      "target": "components/beste/piece/calendar19.tsx"
    }
  ],
  "type": "registry:block"
}