import { jsxs as c, jsx as t } from "react/jsx-runtime";
import { forwardRef as x } from "react";
import { c as k } from "./index.Bxix3KXR.js";
import { _ as s } from "./twind.BLUk_ZzT.js";
import { b } from "./use-section-style.Cg6VYj5D.js";
import { u as v } from "./use-color-preset.DHRwRNwD.js";
const T = x(({ brick: l, editable: n }, m) => {
  var r;
  const o = l.props, p = v(l), d = b(l), f = Object.values(d), u = n ? (e) => {
    e.preventDefault(), k(
      `This link is not clickable in edit mode but will lead to "${e.target.href}" when published.`,
      {
        style: {
          minWidth: "max-content"
        }
      }
    );
  } : void 0;
  return (
    // Force 2 cols on mobile
    /* @__PURE__ */ c(
      "footer",
      {
        ref: m,
        className: s(
          "flex-1 grid gap-6 @desktop:grid-flow-col @mobile:grid-cols-2 @desktop:auto-cols-fr ",
          f,
          p.container
        ),
        children: [
          o.logo && /* @__PURE__ */ t(
            "div",
            {
              className: s(
                "items-center @desktop:(mr-10 col-span-1) @mobile:(flex col-start-1 col-span-2 justify-center)"
              ),
              "data-brick-group": "brand",
              children: /* @__PURE__ */ t("img", { src: o.logo.src, alt: o.logo.alt ?? "Logo", className: "h-full max-h-[80px] w-auto" })
            }
          ),
          (r = o.linksSections) == null ? void 0 : r.map((e, h) => {
            var a;
            return /* @__PURE__ */ c("nav", { className: s("flex flex-col @mobile:gap-3 @desktop:gap-2", o.fontSize), children: [
              /* @__PURE__ */ t("h6", { className: s("uppercase font-bold opacity-80"), children: e.sectionTitle }),
              (a = e.links) == null ? void 0 : a.map((i, g) => /* @__PURE__ */ t("a", { href: i.url, onClick: u, className: s("link link-hover max-w-fit"), children: i.title }, g))
            ] }, h);
          })
        ]
      }
    )
  );
});
export {
  T as default
};
//# sourceMappingURL=footer.D1ovKbGp.js.map
