'use strict';

var clsx = require('clsx');
var tailwindMerge = require('tailwind-merge');
var React = require('react');
var jsxRuntime = require('react/jsx-runtime');

function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }

var React__default = /*#__PURE__*/_interopDefault(React);

// lib/utils.ts
function cn(...inputs) {
  return tailwindMerge.twMerge(clsx.clsx(inputs));
}
var maxWidthStyles = {
  sm: "max-w-screen-sm",
  md: "max-w-screen-md",
  lg: "max-w-screen-lg",
  xl: "max-w-7xl",
  "2xl": "max-w-screen-2xl",
  "4xl": "max-w-[1536px]",
  full: "max-w-full"
};
var Container = React__default.default.forwardRef(
  ({ children, maxWidth = "xl", className, as = "div", ...props }, ref) => {
    const Component = as;
    return /* @__PURE__ */ jsxRuntime.jsx(
      Component,
      {
        ref,
        className: cn(
          "mx-auto w-full px-2 sm:px-4 lg:px-8",
          maxWidthStyles[maxWidth],
          className
        ),
        ...props,
        children
      }
    );
  }
);
Container.displayName = "Container";
var backgroundStyles = {
  white: "bg-background text-foreground",
  gray: "bg-muted/30 text-foreground",
  dark: "bg-foreground text-background",
  gradient: "bg-linear-to-br from-primary via-primary/90 to-foreground text-primary-foreground",
  primary: "bg-primary text-primary-foreground",
  secondary: "bg-secondary text-secondary-foreground",
  muted: "bg-muted text-muted-foreground"
};
var spacingStyles = {
  none: "py-0 md:py-0",
  sm: "py-12 md:py-16",
  md: "py-16 md:py-24",
  lg: "py-20 md:py-32",
  xl: "py-24 md:py-40"
};
var Section = React__default.default.forwardRef(
  ({
    id,
    title,
    subtitle,
    children,
    className,
    style,
    background = "white",
    spacing = "lg",
    ...props
  }, ref) => {
    return /* @__PURE__ */ jsxRuntime.jsx(
      "section",
      {
        ref,
        id,
        className: cn(
          backgroundStyles[background],
          spacingStyles[spacing],
          className
        ),
        style,
        ...props,
        children: /* @__PURE__ */ jsxRuntime.jsxs(Container, { children: [
          (title || subtitle) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center mb-12 md:mb-16", children: [
            subtitle && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-semibold uppercase tracking-wider mb-2 text-primary", children: subtitle }),
            title && /* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-3xl md:text-4xl lg:text-5xl font-bold tracking-tight", children: title })
          ] }),
          children
        ] })
      }
    );
  }
);
Section.displayName = "Section";
function AlternatingBlocks({
  sections,
  title,
  subtitle,
  background = "white",
  spacing = "lg",
  className,
  contentClassName
}) {
  return /* @__PURE__ */ jsxRuntime.jsx(
    Section,
    {
      title,
      subtitle,
      background,
      spacing,
      className,
      children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: cn("mx-auto w-full max-w-[900px]", contentClassName), children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-12", children: sections?.map((section, index) => /* @__PURE__ */ jsxRuntime.jsxs(
        "div",
        {
          className: "grid items-center gap-8 md:grid-cols-2 md:gap-12",
          children: [
            /* @__PURE__ */ jsxRuntime.jsx("div", { className: section.mediaLeft ? "md:order-2" : "", children: section.content }),
            /* @__PURE__ */ jsxRuntime.jsx(
              "div",
              {
                className: cn(
                  "aspect-4/3 overflow-hidden rounded-lg border",
                  section.mediaLeft ? "md:order-1" : ""
                ),
                children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex h-full w-full items-center justify-center", children: section.media })
              }
            )
          ]
        },
        index
      )) }) })
    }
  );
}

exports.AlternatingBlocks = AlternatingBlocks;
//# sourceMappingURL=alternating-blocks.cjs.map
//# sourceMappingURL=alternating-blocks.cjs.map