{"$schema":"https://ui.shadcn.com/schema/registry-item.json","name":"marketing-faq-sections-sidebar-navigation","type":"registry:block","title":"Sidebar Navigation","files":[{"path":"components/blocks/marketing/faq-sections/sidebar-navigation.tsx","content":"import { useState } from 'react';\n\nimport { cn } from '@/lib/utils';\nimport { Button } from '@/components/ui/button';\nimport { ChevronDown, ChevronUp } from 'lucide-react';\nimport {\n  Select,\n  SelectContent,\n  SelectItem,\n  SelectTrigger,\n  SelectValue,\n} from '@/components/ui/select';\n\nconst categories = [\n  {\n    name: 'Getting Started',\n    slug: 'getting-started',\n    questions: [\n      {\n        question: 'How do I create an account?',\n        answer:\n          \"Creating an account is simple. Click the 'Sign Up' button in the top-right corner of our website, fill in your details, and follow the on-screen instructions to complete your registration.\",\n      },\n      {\n        question: 'What are the system requirements?',\n        answer:\n          'Our platform works on all modern browsers including Chrome, Firefox, Safari, and Edge. For the best experience, we recommend keeping your browser updated to the latest version.',\n      },\n      {\n        question: 'How do I install the desktop app?',\n        answer:\n          'You can download our desktop app from the Downloads section of your account dashboard. We provide installers for Windows, MacOS, and Linux.',\n      },\n    ],\n  },\n  {\n    name: 'Account & Settings',\n    slug: 'account',\n    questions: [\n      {\n        question: 'How do I change my email address?',\n        answer:\n          \"You can change your email address in your Account Settings. After updating, we'll send a verification link to your new email to confirm the change.\",\n      },\n      {\n        question: 'Can I have multiple profiles?',\n        answer:\n          'No, each user account is limited to one profile. However, our team plans allow you to switch between different workspaces.',\n      },\n      {\n        question: 'How do I delete my account?',\n        answer:\n          'You can request account deletion from your Account Settings. Please note that this action is permanent and all your data will be removed from our systems.',\n      },\n    ],\n  },\n  {\n    name: 'Billing & Payments',\n    slug: 'billing',\n    questions: [\n      {\n        question: 'When will I be charged?',\n        answer:\n          \"For monthly subscriptions, you'll be charged on the same date each month. For annual plans, you'll be charged once per year on your subscription anniversary.\",\n      },\n      {\n        question: 'How do I update my payment method?',\n        answer:\n          'You can update your payment method in the Billing section of your account. We securely store your payment information using industry-standard encryption.',\n      },\n      {\n        question: 'Can I get a refund?',\n        answer:\n          'We offer a 30-day money-back guarantee for all new subscriptions. After this period, refunds are handled on a case-by-case basis.',\n      },\n    ],\n  },\n  {\n    name: 'Troubleshooting',\n    slug: 'troubleshooting',\n    questions: [\n      {\n        question: 'The app is running slow, what can I do?',\n        answer:\n          'Try clearing your browser cache, restarting the app, or checking your internet connection. If problems persist, our support team can help troubleshoot specific issues.',\n      },\n      {\n        question: 'I forgot my password, how do I reset it?',\n        answer:\n          \"Click the 'Forgot Password' link on the login page, enter your email address, and follow the instructions sent to your email to create a new password.\",\n      },\n      {\n        question: 'Why am I seeing error messages?',\n        answer:\n          \"Error messages typically indicate a temporary issue or missing information. The message should provide specific guidance, but if you're stuck, please contact our support team.\",\n      },\n    ],\n  },\n];\n\nexport default function SidebarNavigation() {\n  const [activeCategory, setActiveCategory] = useState(categories[0]!.slug);\n  const [expandedQuestion, setExpandedQuestion] = useState<string | null>(null);\n\n  const currentCategory = categories.find((cat) => cat.slug === activeCategory);\n\n  const toggleQuestion = (question: string) => {\n    if (expandedQuestion === question) {\n      setExpandedQuestion(null);\n    } else {\n      setExpandedQuestion(question);\n    }\n  };\n\n  return (\n    <div className=\"container mx-auto max-w-[85rem] px-4 py-24 md:px-6 lg:py-32 2xl:max-w-[1400px]\">\n      {/* Title */}\n      <div className=\"mx-auto mb-10 max-w-2xl text-center lg:mb-14\">\n        <h2 className=\"text-2xl font-bold md:text-4xl md:leading-tight\">\n          Help & Resources\n        </h2>\n        <p className=\"text-muted-foreground mt-4\">\n          Browse our comprehensive FAQ or get in touch with support\n        </p>\n      </div>\n      {/* End Title */}\n\n      {/* Mobile Dropdown */}\n      <div className=\"mb-6 lg:hidden\">\n        <Select value={activeCategory} onValueChange={setActiveCategory}>\n          <SelectTrigger className=\"w-full\">\n            <SelectValue placeholder=\"Select category\" />\n          </SelectTrigger>\n          <SelectContent>\n            {categories.map((category) => (\n              <SelectItem key={category.slug} value={category.slug}>\n                {category.name}\n              </SelectItem>\n            ))}\n          </SelectContent>\n        </Select>\n      </div>\n\n      <div className=\"grid gap-10 lg:grid-cols-4\">\n        {/* Sidebar Navigation (Desktop) */}\n        <div className=\"hidden lg:block\">\n          <div className=\"sticky top-8 space-y-1\">\n            {categories.map((category) => (\n              <Button\n                key={category.slug}\n                variant=\"ghost\"\n                className={cn(\n                  'w-full justify-start text-left',\n                  activeCategory === category.slug ? 'bg-muted' : ''\n                )}\n                onClick={() => setActiveCategory(category.slug)}\n              >\n                {category.name}\n              </Button>\n            ))}\n          </div>\n        </div>\n\n        {/* FAQ Content */}\n        <div className=\"lg:col-span-3\">\n          <div className=\"bg-muted/30 rounded-lg p-6 md:p-8\">\n            <h3 className=\"mb-6 text-xl font-semibold\">\n              {currentCategory?.name}\n            </h3>\n            <div className=\"space-y-4\">\n              {currentCategory?.questions.map((item, index) => (\n                <div key={index} className=\"bg-background rounded-lg border\">\n                  <button\n                    className=\"flex w-full items-center justify-between p-4 text-left font-medium\"\n                    onClick={() => toggleQuestion(item.question)}\n                  >\n                    {item.question}\n                    {expandedQuestion === item.question ? (\n                      <ChevronUp className=\"text-muted-foreground h-4 w-4 shrink-0\" />\n                    ) : (\n                      <ChevronDown className=\"text-muted-foreground h-4 w-4 shrink-0\" />\n                    )}\n                  </button>\n                  {expandedQuestion === item.question && (\n                    <div className=\"text-muted-foreground p-4 pt-0\">\n                      <p>{item.answer}</p>\n                    </div>\n                  )}\n                </div>\n              ))}\n            </div>\n          </div>\n\n          {/* Contact Support */}\n          <div className=\"bg-muted/30 mt-8 rounded-lg p-6 text-center md:p-8\">\n            <h3 className=\"mb-2 text-lg font-semibold\">Still need help?</h3>\n            <p className=\"text-muted-foreground mb-4\">\n              Our support team is just a click away\n            </p>\n            <a href=\"#\">\n              <Button>Contact Support</Button>\n            </a>\n          </div>\n        </div>\n      </div>\n    </div>\n  );\n}\n","type":"registry:component","target":"components/blocks/marketing/faq-sections/sidebar-navigation.tsx"},{"path":"components/ui/button.tsx","content":"import * as React from \"react\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { Slot } from \"radix-ui\"\n\nimport { cn } from \"@/lib/utils\"\n\nconst buttonVariants = cva(\n  \"group/button inline-flex shrink-0 items-center justify-center rounded-md border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n  {\n    variants: {\n      variant: {\n        default: \"bg-primary text-primary-foreground hover:bg-primary/80\",\n        outline:\n          \"border-border bg-background shadow-xs hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50\",\n        secondary:\n          \"bg-secondary text-secondary-foreground hover:bg-secondary/80 aria-expanded:bg-secondary aria-expanded:text-secondary-foreground\",\n        ghost:\n          \"hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50\",\n        destructive:\n          \"bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40\",\n        link: \"text-primary underline-offset-4 hover:underline\",\n      },\n      size: {\n        default:\n          \"h-9 gap-1.5 px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2\",\n        xs: \"h-6 gap-1 rounded-[min(var(--radius-md),8px)] px-2 text-xs in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3\",\n        sm: \"h-8 gap-1 rounded-[min(var(--radius-md),10px)] px-2.5 in-data-[slot=button-group]:rounded-md has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5\",\n        lg: \"h-10 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2\",\n        icon: \"size-9\",\n        \"icon-xs\":\n          \"size-6 rounded-[min(var(--radius-md),8px)] in-data-[slot=button-group]:rounded-md [&_svg:not([class*='size-'])]:size-3\",\n        \"icon-sm\":\n          \"size-8 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-md\",\n        \"icon-lg\": \"size-10\",\n      },\n    },\n    defaultVariants: {\n      variant: \"default\",\n      size: \"default\",\n    },\n  }\n)\n\nfunction Button({\n  className,\n  variant = \"default\",\n  size = \"default\",\n  asChild = false,\n  ...props\n}: React.ComponentProps<\"button\"> &\n  VariantProps<typeof buttonVariants> & {\n    asChild?: boolean\n  }) {\n  const Comp = asChild ? Slot.Root : \"button\"\n\n  return (\n    <Comp\n      data-slot=\"button\"\n      data-variant={variant}\n      data-size={size}\n      className={cn(buttonVariants({ variant, size, className }))}\n      {...props}\n    />\n  )\n}\n\nexport { Button, buttonVariants }\n","type":"registry:ui","target":"components/ui/button.tsx"},{"path":"components/ui/select.tsx","content":"\"use client\"\n\nimport * as React from \"react\"\nimport { Select as SelectPrimitive } from \"radix-ui\"\n\nimport { cn } from \"@/lib/utils\"\nimport { ChevronDownIcon, CheckIcon, ChevronUpIcon } from \"lucide-react\"\n\nfunction Select({\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Root>) {\n  return <SelectPrimitive.Root data-slot=\"select\" {...props} />\n}\n\nfunction SelectGroup({\n  className,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Group>) {\n  return (\n    <SelectPrimitive.Group\n      data-slot=\"select-group\"\n      className={cn(\"scroll-my-1 p-1\", className)}\n      {...props}\n    />\n  )\n}\n\nfunction SelectValue({\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Value>) {\n  return <SelectPrimitive.Value data-slot=\"select-value\" {...props} />\n}\n\nfunction SelectTrigger({\n  className,\n  size = \"default\",\n  children,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Trigger> & {\n  size?: \"sm\" | \"default\"\n}) {\n  return (\n    <SelectPrimitive.Trigger\n      data-slot=\"select-trigger\"\n      data-size={size}\n      className={cn(\n        \"flex w-fit items-center justify-between gap-1.5 rounded-md border border-input bg-transparent py-2 pr-2 pl-2.5 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 data-placeholder:text-muted-foreground data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-1.5 dark:bg-input/30 dark:hover:bg-input/50 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4\",\n        className\n      )}\n      {...props}\n    >\n      {children}\n      <SelectPrimitive.Icon asChild>\n        <ChevronDownIcon className=\"pointer-events-none size-4 text-muted-foreground\" />\n      </SelectPrimitive.Icon>\n    </SelectPrimitive.Trigger>\n  )\n}\n\nfunction SelectContent({\n  className,\n  children,\n  position = \"item-aligned\",\n  align = \"center\",\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Content>) {\n  return (\n    <SelectPrimitive.Portal>\n      <SelectPrimitive.Content\n        data-slot=\"select-content\"\n        data-align-trigger={position === \"item-aligned\"}\n        className={cn(\"relative z-50 max-h-(--radix-select-content-available-height) min-w-36 origin-(--radix-select-content-transform-origin) overflow-x-hidden overflow-y-auto rounded-md bg-popover text-popover-foreground shadow-md ring-1 ring-foreground/10 duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95\", position ===\"popper\"&&\"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1\", className )}\n        position={position}\n        align={align}\n        {...props}\n      >\n        <SelectScrollUpButton />\n        <SelectPrimitive.Viewport\n          data-position={position}\n          className={cn(\n            \"data-[position=popper]:h-(--radix-select-trigger-height) data-[position=popper]:w-full data-[position=popper]:min-w-(--radix-select-trigger-width)\",\n            position === \"popper\" && \"\"\n          )}\n        >\n          {children}\n        </SelectPrimitive.Viewport>\n        <SelectScrollDownButton />\n      </SelectPrimitive.Content>\n    </SelectPrimitive.Portal>\n  )\n}\n\nfunction SelectLabel({\n  className,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Label>) {\n  return (\n    <SelectPrimitive.Label\n      data-slot=\"select-label\"\n      className={cn(\"px-2 py-1.5 text-xs text-muted-foreground\", className)}\n      {...props}\n    />\n  )\n}\n\nfunction SelectItem({\n  className,\n  children,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Item>) {\n  return (\n    <SelectPrimitive.Item\n      data-slot=\"select-item\"\n      className={cn(\n        \"relative flex w-full cursor-default items-center gap-2 rounded-sm py-1.5 pr-8 pl-2 text-sm outline-hidden select-none focus:bg-accent focus:text-accent-foreground not-data-[variant=destructive]:focus:**:text-accent-foreground data-disabled:pointer-events-none data-disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4 *:[span]:last:flex *:[span]:last:items-center *:[span]:last:gap-2\",\n        className\n      )}\n      {...props}\n    >\n      <span className=\"pointer-events-none absolute right-2 flex size-4 items-center justify-center\">\n        <SelectPrimitive.ItemIndicator>\n          <CheckIcon className=\"pointer-events-none\" />\n        </SelectPrimitive.ItemIndicator>\n      </span>\n      <SelectPrimitive.ItemText>{children}</SelectPrimitive.ItemText>\n    </SelectPrimitive.Item>\n  )\n}\n\nfunction SelectSeparator({\n  className,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.Separator>) {\n  return (\n    <SelectPrimitive.Separator\n      data-slot=\"select-separator\"\n      className={cn(\"pointer-events-none -mx-1 my-1 h-px bg-border\", className)}\n      {...props}\n    />\n  )\n}\n\nfunction SelectScrollUpButton({\n  className,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollUpButton>) {\n  return (\n    <SelectPrimitive.ScrollUpButton\n      data-slot=\"select-scroll-up-button\"\n      className={cn(\n        \"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4\",\n        className\n      )}\n      {...props}\n    >\n      <ChevronUpIcon\n      />\n    </SelectPrimitive.ScrollUpButton>\n  )\n}\n\nfunction SelectScrollDownButton({\n  className,\n  ...props\n}: React.ComponentProps<typeof SelectPrimitive.ScrollDownButton>) {\n  return (\n    <SelectPrimitive.ScrollDownButton\n      data-slot=\"select-scroll-down-button\"\n      className={cn(\n        \"z-10 flex cursor-default items-center justify-center bg-popover py-1 [&_svg:not([class*='size-'])]:size-4\",\n        className\n      )}\n      {...props}\n    >\n      <ChevronDownIcon\n      />\n    </SelectPrimitive.ScrollDownButton>\n  )\n}\n\nexport {\n  Select,\n  SelectContent,\n  SelectGroup,\n  SelectItem,\n  SelectLabel,\n  SelectScrollDownButton,\n  SelectScrollUpButton,\n  SelectSeparator,\n  SelectTrigger,\n  SelectValue,\n}\n","type":"registry:ui","target":"components/ui/select.tsx"}],"description":"An FAQ layout with a sidebar of categories beside the answers. Lets visitors switch topics quickly and keeps large help sections organized and navigable.","dependencies":["class-variance-authority","lucide-react","radix-ui"]}